/* ─── Base ──────────────────────────────────────────────────────────── */
html {
  scroll-behavior: smooth;
}

/* ─── Hero gradient ────────────────────────────────────────────────── */
.hero-gradient {
  background: linear-gradient(135deg, #312e81 0%, #4338ca 50%, #4f46e5 100%);
  position: relative;
  overflow: hidden;
}

.hero-gradient::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 20% 40%, rgba(99, 102, 241, 0.3) 0%, transparent 70%),
    radial-gradient(ellipse 60% 60% at 80% 60%, rgba(67, 56, 202, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

/* ─── Scroll animations ────────────────────────────────────────────── */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children in grids */
.animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }
.animate-on-scroll:nth-child(5) { transition-delay: 0.4s; }
.animate-on-scroll:nth-child(6) { transition-delay: 0.5s; }

/* ─── Navbar states ────────────────────────────────────────────────── */
#navbar {
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

#navbar.scrolled {
  background-color: #312e81;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Active nav link */
.nav-link.active {
  color: white;
  position: relative;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: white;
  border-radius: 1px;
}

/* ─── Mobile menu transition ───────────────────────────────────────── */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

#mobile-menu.open {
  display: block;
  max-height: 300px;
}

/* ─── Form focus ───────────────────────────────────────────────────── */
input:focus,
select:focus {
  background-color: rgba(255, 255, 255, 0.15);
}

/* Fix select option text in dark background */
select option {
  background: white;
  color: #1f2937;
}

/* ─── Print styles ─────────────────────────────────────────────────── */
@media print {
  #navbar,
  #waitlist,
  #mobile-menu {
    display: none !important;
  }

  .hero-gradient {
    background: white !important;
    color: black !important;
    min-height: auto !important;
  }

  .hero-gradient h1,
  .hero-gradient p {
    color: black !important;
  }

  .animate-on-scroll {
    opacity: 1 !important;
    transform: none !important;
  }
}
