/* ===========================================
   VERCAM CONTATTI - Modern CSS
   =========================================== */

/* CSS Custom Properties */
:root {
  --vercam-primary: #43e97b;
  --vercam-secondary: #198754;
  --vercam-accent: #00b4d8;
  --vercam-dark: #0d6efd;
  --text-primary: #222;
  --text-secondary: #666;
  --bg-white: #ffffff;
  --bg-light: #f8f9fa;
  --shadow-light: rgba(67, 233, 123, 0.07);
  --shadow-medium: rgba(67, 233, 123, 0.15);
  --shadow-strong: rgba(67, 233, 123, 0.25);
  --border-radius-sm: 8px;
  --border-radius-md: 12px;
  --border-radius-lg: 16px;
  --border-radius-xl: 20px;
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ===========================================
   ANIMATIONS
   =========================================== */

.fade-in {
  animation: fadeInBase 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeInBase {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes badgePulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(67, 233, 123, 0.3);
  }
  50% {
    box-shadow: 0 0 20px 10px rgba(67, 233, 123, 0.3);
  }
}

@keyframes fadeInBadge {
  from {
    opacity: 0;
    transform: scale(0.8) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes floatParticle {
  0% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-40px) scale(1.2);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}

/* ===========================================
   BACKGROUND & LAYOUT
   =========================================== */

.web3-bg {
  min-height: 100vh;
  background: const(--bg-white);
  position: relative;
  overflow: hidden;
}

.web3-particles-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.web3-particle {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(120deg, const(--vercam-primary) 0%, const(--vercam-accent) 100%);
  opacity: 0.15;
  animation: floatParticle 8s infinite ease-in-out;
}

.web3-p1 {
  width: 32px;
  height: 32px;
  top: 10%;
  left: 8%;
  animation-delay: 0s;
}

.web3-p2 {
  width: 24px;
  height: 24px;
  top: 80%;
  left: 80%;
  animation-delay: 2s;
}

.web3-p3 {
  width: 20px;
  height: 20px;
  top: 50%;
  left: 60%;
  animation-delay: 1s;
}

.web3-p4 {
  width: 36px;
  height: 36px;
  top: 70%;
  left: 20%;
  animation-delay: 3s;
}

.web3-p5 {
  width: 18px;
  height: 18px;
  top: 25%;
  left: 90%;
  animation-delay: 1.5s;
}

/* ===========================================
   CONTACT BOX
   =========================================== */

.contact-box {
  max-width: 1200px;
  margin: 2.5rem auto;
  padding: 4rem 3rem;
  animation: fadeInBase 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===========================================
   WEB3 CARD
   =========================================== */

.web3-card {
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  background: rgba(255, 255, 255, 0.9);
  border-radius: const(--border-radius-xl);
  box-shadow: 0 16px 64px const(--shadow-medium), 0 2px 12px rgba(0, 180, 216, 0.1);
  border: 1px solid rgba(67, 233, 123, 0.15);
  transition: all const(--transition-normal);
}

.web3-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 80px const(--shadow-strong), 0 4px 16px rgba(0, 180, 216, 0.15);
}

/* ===========================================
   WEB3 BADGE
   =========================================== */

.badge-web3 {
  display: inline-block;
  background: linear-gradient(135deg, const(--vercam-primary) 0%, const(--vercam-accent) 100%);
  color: const(--bg-white);
  font-weight: 700;
  font-size: 1.0625rem;
  padding: 0.625rem 1.75rem;
  border-radius: const(--border-radius-xl);
  box-shadow: 0 4px 16px const(--shadow-medium);
  letter-spacing: 0.5px;
  margin-bottom: 1rem;
  animation: badgePulse 2.5s infinite, fadeInBadge 1.1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  opacity: 1;
  position: relative;
  overflow: hidden;
}

.badge-web3::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s ease;
}

.badge-web3:hover::before {
  left: 100%;
}

/* ===========================================
   TYPOGRAPHY
   =========================================== */

.contact-title {
  font-size: 2.5rem;
  font-weight: 900;
  color: const(--vercam-secondary);
  letter-spacing: 1px;
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  text-shadow: 0 2px 16px const(--shadow-light);
  animation: fadeInBase 1s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
  margin-bottom: 1.5rem;
  position: relative;
}

.contact-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(135deg, const(--vercam-primary) 0%, const(--vercam-secondary) 100%);
  border-radius: 2px;
}

.contact-sub {
  font-size: 1.1875rem;
  color: const(--text-primary);
  margin-bottom: 1rem;
  line-height: 1.6;
  animation: fadeInBase 1.1s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
}

/* ===========================================
   CONTACT FORM
   =========================================== */

.contact-form {
  animation: fadeInBase 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.contact-input {
  border-radius: const(--border-radius-lg);
  border: 2px solid rgba(234, 255, 242, 0.8);
  font-size: 1.0625rem;
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  transition: all const(--transition-normal);
  box-shadow: 0 2px 8px const(--shadow-light);
  background: const(--bg-white);
  padding: 0.875rem 1rem;
  margin-bottom: 1rem;
}

.contact-input:focus {
  border-color: const(--vercam-primary);
  box-shadow: 0 4px 16px const(--shadow-medium);
  transform: translateY(-2px);
}

.contact-input::placeholder {
  color: const(--text-secondary);
}

/* Solo checkbox privacy: bordo più visibile */
#privacy.form-check-input {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid var(--vercam-secondary);
}

#privacy.form-check-input:focus,
#privacy.form-check-input:focus-visible {
  border-color: var(--vercam-secondary);
  box-shadow: 0 0 0 0.2rem rgba(25, 135, 84, 0.2);
}

/* Privacy consent checkbox: larger, visible and accessible */
.privacy-consent {
  background: linear-gradient(180deg, rgba(67,233,123,0.08), rgba(255,255,255,0.95));
  border: 2px solid rgba(25,135,84,0.35);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  align-items: flex-start;
  box-shadow: 0 8px 24px rgba(67,233,123,0.1);
}

.privacy-checkbox {
  width: 30px;
  height: 30px;
  margin-top: 2px;
  accent-color: var(--vercam-secondary);
  border-radius: 8px;
  border: 2.5px solid var(--vercam-secondary);
  box-shadow: 0 0 0 3px rgba(67,233,123,0.15);
  flex: 0 0 34px;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.privacy-checkbox:hover {
  transform: scale(1.06);
  box-shadow: 0 0 0 4px rgba(67,233,123,0.22);
}

.privacy-checkbox:checked {
  background-color: var(--vercam-secondary);
  border-color: var(--vercam-secondary);
  box-shadow: 0 0 0 4px rgba(25,135,84,0.25);
}

.privacy-checkbox:focus,
.privacy-checkbox:focus-visible {
  outline: none;
  box-shadow: 0 0 0 5px rgba(25,135,84,0.3);
}

.privacy-label {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
  display: inline-block;
  line-height: 1.5;
}

.privacy-consent-body .form-text {
  margin-top: 0.35rem;
  color: #55606b;
  font-size: 0.9rem;
}

.privacy-consent:focus-within {
  border-color: rgba(25,135,84,0.6);
  box-shadow: 0 10px 28px rgba(67,233,123,0.2);
  transform: translateY(-1px);
}

/* Small screens: ensure label wraps nicely and checkbox aligns */
@media (max-width: 576px) {
  .privacy-consent { padding: 0.9rem; }
  .privacy-checkbox {
    width: 28px;
    height: 28px;
    flex-basis: 32px;
  }
}

/* ===========================================
   CONTACT BUTTON
   =========================================== */

.contact-btn {
  background: linear-gradient(135deg, const(--vercam-primary) 0%, const(--vercam-secondary) 100%);
  color: const(--bg-white);
  font-weight: 700;
  border-radius: const(--border-radius-xl);
  border: none;
  box-shadow: 0 4px 16px const(--shadow-medium);
  transition: all const(--transition-normal);
  font-size: 1.125rem;
  padding: 1rem 3rem;
  margin-top: 1rem;
  position: relative;
  overflow: hidden;
}

.contact-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s ease;
}

.contact-btn:hover::before {
  left: 100%;
}

.contact-btn:hover, .contact-btn:focus {
  background: linear-gradient(135deg, const(--vercam-secondary) 0%, const(--vercam-primary) 100%);
  box-shadow: 0 6px 24px const(--shadow-strong);
  transform: translateY(-2px) scale(1.05);
  color: const(--bg-white);
}

/* ===========================================
   CONTACT INFO
   =========================================== */

.contact-info {
  animation: fadeInBase 1.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.contact-info h5 {
  color: const(--vercam-secondary);
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.contact-info ul {
  padding-left: 0;
  list-style: none;
}

.contact-info li {
  font-size: 1.0625rem;
  color: const(--text-primary);
  display: flex;
  align-items: center;
  margin-bottom: 0.875rem;
  padding: 0.5rem;
  border-radius: const(--border-radius-md);
  transition: const(--transition-fast);
}

.contact-info li:hover {
  background: rgba(67, 233, 123, 0.05);
  transform: translateX(4px);
}

.contact-info i {
  color: const(--vercam-secondary);
  font-size: 1.25rem;
  margin-right: 0.75rem;
  width: 24px;
  text-align: center;
}

/* ===========================================
   SOCIAL ICONS
   =========================================== */

.contact-social {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-top: 1rem;
  text-align: center;
}

.contact-social-icon {
  color: const(--vercam-secondary);
  font-size: 1.5rem;
  background: rgba(234, 255, 242, 0.8);
  border-radius: 50%;
  padding: 0.75rem 0.875rem;
  box-shadow: 0 2px 8px const(--shadow-light);
  transition: all const(--transition-normal);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.contact-social-icon:hover, .contact-social-icon:focus {
  background: rgba(67, 233, 123, 0.2);
  color: const(--vercam-secondary);
  transform: translateY(-4px) scale(1.1);
  box-shadow: 0 6px 20px const(--shadow-medium);
}

/* ===========================================
   MOBILE RESPONSIVE DESIGN
   =========================================== */

/* ===========================================
   VERCAM ALERT (modern Web 2.0 style)
   =========================================== */
.vc-alert-container {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.vc-alert {
  width: 100%;
  max-width: 780px;
  display: flex;
  gap: 1rem;
  align-items: center;
  padding: 0.875rem 1rem;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(245, 255, 250, 0.85));
  box-shadow: 0 8px 30px rgba(3, 18, 22, 0.06), inset 0 1px 0 rgba(255,255,255,0.6);
  border: 1px solid rgba(13,110,253,0.06);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
  font-family: 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: var(--text-primary);
}

.vc-alert__icon {
  flex: 0 0 44px;
  height: 44px;
  border-radius: 10px;
  display: inline-grid;
  place-items: center;
  box-shadow: 0 6px 18px rgba(3,18,22,0.06);
}

.vc-alert__body {
  flex: 1 1 auto;
}

.vc-alert__title {
  font-weight: 700;
  color: var(--vercam-secondary);
  margin: 0;
  font-size: 1rem;
}

.vc-alert__text {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.vc-alert__close {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: button;
  padding: 0.25rem;
  border-radius: 8px;
  transition: background var(--transition-fast), transform var(--transition-fast);
}

.vc-alert__close:hover { background: rgba(0,0,0,0.04); transform: scale(1.05); }

/* Varianti */
.vc-alert--success { border-left: 6px solid var(--vercam-primary); }
.vc-alert--danger  { border-left: 6px solid #ff6b6b; }
.vc-alert--success .vc-alert__icon { background: linear-gradient(135deg, var(--vercam-primary), var(--vercam-accent)); color: white; }
.vc-alert--danger  .vc-alert__icon { background: linear-gradient(135deg, #ff6b6b, #ff8177); color: white; }

/* enter/exit */
.vc-alert--enter { animation: fadeInBase 0.5s ease; }
.vc-alert--exit { opacity: 0; transform: translateY(-8px) scale(0.995); transition: opacity 0.25s ease, transform 0.25s ease; }

@media (max-width: 768px) {
  main.web3-bg {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
  }

  .contact-box {
    max-width: 95vw;
    padding: 2.5rem 2rem;
    margin-top: 1rem;
    margin-bottom: 1rem !important;
    border-radius: const(--border-radius-xl);
    box-shadow: 0 8px 25px const(--shadow-medium);
  }

  .web3-bg {
    padding-bottom: 0 !important;
  }

  .web3-card {
    border-radius: const(--border-radius-xl);
    box-shadow: 0 8px 25px const(--shadow-medium);
    padding: 2.5rem 2rem;
  }

  .badge-web3 {
    font-size: 1.125rem;
    padding: 0.75rem 2rem;
    margin-bottom: 1.5rem;
    border-radius: const(--border-radius-lg);
  }

  .contact-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
  }

  .contact-sub {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    line-height: 1.6;
  }

  .contact-input {
    font-size: 1.125rem;
    padding: 1rem 0.875rem;
    border-radius: const(--border-radius-lg);
    margin-bottom: 1rem;
  }

  .contact-btn {
    font-size: 1.125rem;
    padding: 1.25rem 3rem;
    border-radius: const(--border-radius-xl);
    margin-top: 1rem;
    font-weight: 700;
  }

  .contact-info h5 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
  }

  .contact-info li {
    font-size: 1.0625rem;
    margin-bottom: 8px;
  }

  .contact-social {
    gap: 2rem;
    margin-top: 1.25rem;
  }

  .contact-social-icon {
    font-size: 2.125rem;
    padding: 0.875rem 1rem;
    border-radius: const(--border-radius-xl);
  }
}
