/* =========================
   Theme + Base
========================= */

:root {
  --sky: #79c9ff;
  --sky-light: #c4e6ff;
  --leaf: #9ad63b;
  --purple: #b036c9;
  --blue-monster: #36a3c9;
  --text-dark: #141924;
  --nav-accent: #2f80ed;
  --text-level-one: #f747ba;
  --text-level-two: #c71f2e;
  --text-level-three: #f8c409;
  --text-level-four: #44ccdf;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--text-dark);
  background: linear-gradient(to bottom, var(--sky-light), #ffffff);
}

/* With a fixed navbar, ensure anchor jumps land below it */
section {
  padding: 5rem 0;
  scroll-margin-top: 80px;
}

/* =========================
   Text Elements
========================= */

.level-one {
  color: var(--text-level-one);
}

.level-two {
  color: var(--text-level-two);
}

.level-three {
  color: var(--text-level-three);
}

.level-four {
  color: var(--text-level-four);
}

/* =========================
   Navbar
========================= */

.navbar {
  background: #ffffff;
  font-family: "Nunito", sans-serif;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.navbar-brand {
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #374957;
}

.navbar-brand span {
  color: #374957;
}

.navbar-logo {
  height: 48px;
}

.navbar-nav .nav-link {
  color: #4b5c6b;
  font-weight: 600;
  position: relative;
  padding-inline: 1.1rem;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus {
  color: var(--nav-accent);
}

.navbar-nav .nav-link.active {
  color: var(--nav-accent);
}

/* Active indicator under nav item */
.navbar-nav .nav-link.active::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0.2rem;
  width: 40%;
  height: 3px;
  border-radius: 999px;
  background: var(--nav-accent);
}

/* =========================
   Welcome
========================= */

.welcome-section {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  /* margin-top: 70px; offset for fixed navbar */
}

.welcome-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.6);
  z-index: 1;
}

.welcome-banner {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.welcome-content {
  position: relative;
  z-index: 2;
  color: var(--text-dark);
}

/* ---------- Motion-safe defaults (never hide content) ---------- */
.welcome-title,
.welcome-subtitle,
.welcome-highlighted-text {
  font-family: "Nunito", sans-serif;
}

/* Typography polish */
.welcome-title {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: clamp(2.8rem, 6vw, 4.3rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.welcome-subtitle {
  font-weight: 650; /* more premium than 600 */
  font-size: clamp(1.15rem, 2.6vw, 1.75rem);
  line-height: 1.35;
  margin: 0;
  color: rgba(26, 31, 43, 0.82); /* or use your --text-dark w/ alpha */
}

.welcome-highlighted-text {
  color: var(--purple);
  font-weight: 900;
  position: relative;
  display: inline-block;
}

/* ---------- Animations only when allowed ---------- */
@media (prefers-reduced-motion: no-preference) {
  .welcome-title {
    opacity: 1;
    transform: translateY(18px) scale(0.98);
    animation: zoomInHero 1600ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
  }

  .welcome-subtitle {
    opacity: 0;
    transform: translateY(18px);
    animation: heroFadeUp 1400ms cubic-bezier(0.22, 1, 0.36, 1) 400ms forwards;
  }

  .welcome-highlighted-text {
    opacity: 0;
    transform: translateY(10px);
    animation: highlightPop 1200ms cubic-bezier(0.22, 1, 0.36, 1) 900ms forwards;
  }

  .welcome-highlighted-text::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -0.15em;
    height: 0.35em;
    background: #5aa517; /* darker green */
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: left;
    animation: underlineSweep 1800ms cubic-bezier(0.22, 1, 0.36, 1) 1200ms
      forwards;
    z-index: -1;
  }
}
/* ---------- Keyframes ---------- */
@keyframes heroEnter {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes heroFadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes highlightPop {
  60% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes zoomInHero {
  0% {
    opacity: 1;
    transform: scale(0.5);
  }
  60% {
    opacity: 1;
  }
  100% {
    transform: scale(1);
  }
}

/* =========================
   Shared Section Typography
========================= */

.section-title {
  font-weight: 800;
  color: var(--blue-monster);
}

.section-kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--purple);
}

.module-pill {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: rgba(154, 214, 59, 0.18);
  color: #416400;
  font-weight: 600;
}

/* =========================
   Intro
========================= */

.intro-section {
  background: #ffffff;
  min-height: 80vh;
}

.intro-video-placeholder {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 1.25rem;
  background: linear-gradient(135deg, #f3f5f7, #e8ebee);
  display: grid;
  place-items: center;
  overflow: hidden;
}

/* Hide both by default (prevents flash on load) */
.intro-video {
  display: none;
}

/* Show correct video based on <html lang=""> */
html[lang="en"] .lang-en {
  display: block;
}

html[lang="fr"] .lang-fr {
  display: block;
}

/* =========================
   Get Started (Hero)
========================= */

#get-started {
  background: radial-gradient(
    circle at top left,
    #ffffff 0,
    #ffffff 45%,
    var(--sky-light) 100%
  );
  min-height: 100vh;
}

.hero-title {
  font-size: clamp(2.1rem, 4vw, 2.8rem);
  font-weight: 800;
  color: var(--blue-monster);
}

.step-pill {
  background: #fff;
  border-radius: 1.5rem;
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.09);
  gap: 0.7rem;
}

.step-pill-number {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--leaf);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #275000;
  flex-shrink: 0;
}

/* =========================
   Modules
========================= */

#modules {
  background: #ffffff;
}

.module-pill-btn {
  padding: 0.5rem 2rem;
  width: 180px;
  border: 0;
  border-radius: 20px;
  font-size: 1.2rem;
  text-decoration: none;
  color: inherit;
  background: transparent;
  text-align: center;
  font-size: 1rem;
}

.module-pill-btn:hover {
  background: rgba(0, 0, 0, 0.04);
  text-decoration: none;
}

.module-icon {
  width: 120px;
  height: 120px;
  object-fit: contain;
}

.module-pill-btn:hover {
  filter: brightness(1.15);
  transform: translateY(-2px);
}

/* =========================
   FAQ (Accordion)
========================= */

#faq {
  background: linear-gradient(to bottom, #ffffff, var(--sky-light));
}

.accordion-button {
  background-color: #b036c908;
  color: var(--text-dark);
}

.accordion-button:not(.collapsed) {
  background-color: #b036c923;
  color: var(--text-dark);
  font-weight: 500;
}

.accordion-button:focus {
  box-shadow: 0 0 0 0.15rem rgba(154, 214, 59, 0.6);
}

/* =========================
   Footer
========================= */

footer {
  font-size: 0.85rem;
  color: rgba(0, 0, 0, 0.6);
}

/* =========================
   Responsive
========================= */

@media (max-width: 767.98px) {
  section {
    padding: 3.5rem 0;
  }

  .hero-title {
    text-align: center;
  }

  #get-started p.lead {
    text-align: center;
  }

  .step-pill {
    margin-inline: auto;
  }
}
