:root {
  --bg: #ffffff;
  --fg: #4472c4;
  --accent: #4472c4;
  --border: rgba(68, 114, 196, 0.2);
  --dim: rgba(68, 114, 196, 0.68);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--fg); }
body {
  font-family: "Inter", system-ui, sans-serif;
  font-feature-settings: "ss01";
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, canvas { display: block; max-width: 100%; }
button { font: inherit; }

/* ── Typography ───────────────────────────────────────────────────── */
.display {
  font-size: clamp(64px, 10vw, 140px);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.035em;
}

.eyebrow {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--dim);
}

/* ── Buttons ──────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  transition: transform 180ms ease, background 180ms ease;
  cursor: pointer;
  border: none;
}

.btn--pill {
  background: var(--accent);
  color: #ffffff;
  padding: 14px 28px;
  border-radius: 999px;
}

.btn--pill:hover { transform: scale(1.03); }
.btn--large {
  padding: 20px 40px;
  font-size: 18px;
  margin-top: clamp(12px, 2vh, 28px);
}

/* ── Nav ──────────────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px clamp(24px, 5vw, 64px);
  z-index: 100;
  transition: backdrop-filter 240ms ease, background 240ms ease, border-color 240ms ease;
  border-bottom: 1px solid transparent;
}

.nav.is-scrolled {
  backdrop-filter: blur(14px);
  background: rgba(255, 255, 255, 0.82);
  border-bottom-color: var(--border);
}

.nav__brand {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
}

.nav__logo {
  height: 32px;
  width: auto;
  display: block;
  object-fit: contain;
}

.hero__logo {
  height: 64px;
  width: auto;
  object-fit: contain;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 36px);
}

.nav__links a:not(.btn) {
  font-size: 14px;
  color: var(--dim);
  transition: color 180ms ease;
}

.nav__links a:not(.btn):hover { color: var(--fg); }

/* ── Hero pin + loading overlay ───────────────────────────────────── */
.hero__pin {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.hero__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
  opacity: 0;
  transition: opacity 300ms ease;
}

.hero__pin.is-video-active .hero__video {
  opacity: 1;
}

.hero__pin.is-video-active .hero__canvas {
  opacity: 0;
}

.hero__loading {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: var(--bg);
  transition: opacity 600ms ease;
  z-index: 10;
}

.hero__loading.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.hero__loading-bar {
  width: min(360px, 60vw);
  height: 2px;
  background: var(--border);
  overflow: hidden;
}

.hero__loading-bar span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 120ms ease;
}

.hero__loading-label {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--dim);
  margin: 0;
}

/* ── Hero overlays ────────────────────────────────────────────────── */
.hero__overlays {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 0 clamp(24px, 6vw, 120px);
  pointer-events: none;
  z-index: 5;
}

.hero__headline {
  grid-row: 1;
  grid-column: 1;
  text-align: center;
  font-size: clamp(56px, 9vw, 132px);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.035em;
  margin: 0;
  max-width: 18ch;
  visibility: hidden;
  padding: 0.18em 0.35em;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(68, 114, 196, 0.24);
  box-shadow: 0 6px 24px rgba(255, 255, 255, 0.28);
}

.hero__intro-brand {
  grid-row: 1;
  grid-column: 1;
  margin: 0;
  font-size: clamp(68px, 12vw, 190px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: #ffffff;
  text-shadow:
    0 10px 30px rgba(0, 0, 0, 0.25),
    0 2px 10px rgba(68, 114, 196, 0.35);
  pointer-events: none;
  text-transform: none;
}

/* ── Features (horizontal pinned) ─────────────────────────────────── */
.features {
  background: var(--bg);
  position: relative;
}

.features__pin {
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.features__track {
  display: flex;
  gap: clamp(32px, 5vw, 80px);
  padding: 0 10vw;
  will-change: transform;
}

.feature-card {
  flex: 0 0 auto;
  width: clamp(320px, 36vw, 520px);
  aspect-ratio: 3 / 4;
  border: 1px solid var(--border);
  padding: clamp(24px, 3vw, 48px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(180deg, rgba(68, 114, 196, 0.04), transparent 60%);
}

.feature-card__num {
  font-size: 14px;
  letter-spacing: 0.22em;
  color: var(--dim);
}

.feature-card__title {
  font-size: clamp(36px, 4vw, 60px);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.0;
  margin: 0;
}

.feature-card__body {
  font-size: clamp(16px, 1.15vw, 20px);
  color: var(--dim);
  max-width: 22ch;
  margin: 0;
}

/* ── Secondary pinned gauge ───────────────────────────────────────── */
.secondary {
  background: var(--bg);
  position: relative;
  margin-bottom: clamp(48px, 7vh, 96px);
}

.secondary__pin {
  position: relative;
  height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.secondary__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: translateY(clamp(28px, 5vh, 72px));
}

.secondary__headline {
  position: absolute;
  top: clamp(96px, 12vh, 160px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-size: clamp(28px, 3.2vw, 52px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  text-align: center;
  max-width: 18ch;
  margin: 0;
  padding: 0 24px;
}

.secondary--fallback .secondary__canvas { display: none; }

.secondary--fallback .secondary__pin {
  background:
    radial-gradient(ellipse at center, rgba(68, 114, 196, 0.18), transparent 60%),
    var(--bg);
}

/* ── Stats row ────────────────────────────────────────────────────── */
.stats {
  padding: clamp(96px, 14vw, 200px) clamp(24px, 5vw, 64px);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.stats__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(24px, 4vw, 80px);
  list-style: none;
  padding: 0;
  margin: 0;
  max-width: 1400px;
  margin-inline: auto;
}

.stat {
  --stagger: 0ms;
  display: flex;
  flex-direction: column;
  gap: 12px;
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 560ms ease var(--stagger),
    transform 560ms ease var(--stagger);
}

.stat.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.stat__value {
  font-size: clamp(56px, 7vw, 120px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.95;
  color: var(--fg);
}

.stat__label {
  font-size: 14px;
  color: var(--dim);
  letter-spacing: -0.005em;
  max-width: 20ch;
}

/* ── Final CTA ────────────────────────────────────────────────────── */
.cta {
  padding: clamp(140px, 20vw, 260px) clamp(24px, 5vw, 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(32px, 4vw, 56px);
  text-align: center;
}

.cta__headline {
  font-size: clamp(64px, 12vw, 180px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.045em;
  margin: 0;
  margin-bottom: clamp(18px, 3vh, 40px);
  padding-bottom: 0.14em;
  display: inline-block;
  background: linear-gradient(180deg, #5d84cb 0%, #4472c4 50%, #355da8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.btn--outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn--outline:hover {
  background: var(--accent);
  color: #ffffff;
}

/* ── Footer ───────────────────────────────────────────────────────── */
.footer {
  padding: 40px clamp(24px, 5vw, 64px);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--dim);
}

.footer p { margin: 0; }

.footer ul {
  display: flex;
  gap: 32px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer a { transition: color 180ms ease; }
.footer a:hover { color: var(--fg); }

/* ── Reduced motion fallback ──────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__pin { height: 70vh; }
  .hero__headline[data-overlay="2"] { visibility: visible; }
}

.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 700ms ease, transform 700ms ease;
}

.fade-in.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 900px) {
  .stats__list { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .features__pin {
    height: auto;
    padding: 96px 0;
    overflow: visible;
  }

  .features__track {
    flex-direction: column;
    padding: 0 24px;
  }

  .feature-card {
    width: 100%;
    aspect-ratio: auto;
  }
}

@media (max-width: 640px) {
  .nav__links a:not(.btn) { display: none; }

  .footer {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

@media (max-width: 520px) {
  .stats__list { grid-template-columns: 1fr; }
}
