/* ============================================================
   HALO — Interactive Narrative ("The Descent")
   Scroll-driven scrollytelling · Pleiades Celestial palette
   Angel/Occult-Tarot inspired · gold-framed beats
   ============================================================ */

:root {
  /* Pleiades Celestial palette */
  --abyss:   #050f1c;
  --abyss-2: #081C2D;
  --abyss-3: #0c2740;
  --deep:    #143a59;
  --mid:     #2C6E91;
  --bright:  #4B9CD3;
  --aqua:    #A3D6D6;
  --star:    #FFFFFF;

  /* Gilded gold */
  --gold:      #E6C879;
  --gold-deep: #C9A24B;
  --gold-soft: rgba(230,200,121,0.14);
  --gold-line: rgba(230,200,121,0.55);

  /* Text */
  --ink:       #F4F8FB;
  --ink-2:     rgba(244,248,251,0.76);
  --ink-3:     rgba(244,248,251,0.52);
  --ink-4:     rgba(244,248,251,0.40);
  --ink-faint: rgba(244,248,251,0.30);

  --halo-grad: linear-gradient(120deg, #2EA8E8 0%, #4B9CD3 28%, #2BCB7A 72%, #B6E04D 100%);

  --font-display: "Instrument Serif", Georgia, serif;
  --font-arcana:  "Cinzel", "Instrument Serif", serif;
  --font-body:    "Lexend", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  /* Fluid type */
  --t-hero:     clamp(58px, 9.2vw, 150px);
  --t-display:  clamp(46px, 6.4vw, 104px);
  --t-title:    clamp(38px, 5vw, 84px);
  --t-subtitle: clamp(22px, 2.7vw, 42px);
  --t-body:     clamp(17px, 1.5vw, 25px);
  --t-small:    clamp(15px, 1.2vw, 21px);
  --t-arcana:   clamp(14px, 1.25vw, 22px);
  --t-stat:     clamp(56px, 8vw, 128px);

  --ease-out:   cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.4, 0.64, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-snap-type: y proximity; overflow-x: hidden; }

body {
  margin: 0;
  background: var(--abyss);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

/* ============================================================
   COSMOS BACKDROP — fixed, driven by --p (0..1 global scroll)
   ============================================================ */
#cosmos {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  --p: 0;
  background:
    radial-gradient(120% 80% at 50% 6%, var(--abyss-3) 0%, var(--abyss-2) 44%, var(--abyss) 100%);
}
/* darkens toward the end of the page so the starfield blends into the closing Earth */
#cosmos .darken {
  position: absolute; inset: 0; pointer-events: none;
  background: #03070e;
  opacity: calc(max(0, (var(--p) - 0.58)) * 1.5);
}
/* nebula bloom — fades as we descend */
#cosmos .neb {
  display: none;   /* removed: dull background bloom behind the hero archangel (faded out by The Mission) */
  position: absolute;
  inset: -10%;
  pointer-events: none;
  opacity: calc(0.9 - var(--p) * 0.7);
  background:
    radial-gradient(36% 26% at 64% 26%, rgba(75,156,211,0.30) 0%, transparent 70%),
    radial-gradient(30% 22% at 60% 22%, rgba(163,214,214,0.22) 0%, transparent 70%),
    radial-gradient(40% 30% at 30% 60%, rgba(44,110,145,0.22) 0%, transparent 70%);
}
/* photographic deep-space plate (user-fillable, sits behind stars) */
#cosmos .sky-photo {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  opacity: calc(0.55 - var(--p) * 0.5);
  --slot-radius: 0px;
}

/* Starfield layers (box-shadow dots set by JS), parallax via --p */
.stars {
  position: absolute;
  top: 0; left: 0;
  width: 2px; height: 2px;
  border-radius: 50%;
  background: transparent;
  will-change: transform;
}
.stars.l1 { transform: translateY(calc(var(--p) * -18vh)); opacity: calc(0.78 - var(--p)*0.18); }
.stars.l2 { transform: translateY(calc(var(--p) * -36vh)); opacity: calc(0.92 - var(--p)*0.18); }
.stars.l3 { transform: translateY(calc(var(--p) * -58vh)); opacity: calc(1 - var(--p)*0.2); }

/* drift animation layered on top of the scroll transform via a wrapper */
@keyframes twinkle-drift { from { transform: translate3d(0,0,0); } to { transform: translate3d(-30px,18px,0);} }
.stars-wrap { position:absolute; inset:0; }
.stars-wrap.d1 { animation: twinkle-drift 160s linear infinite alternate; }
.stars-wrap.d2 { animation: twinkle-drift 230s linear infinite alternate; }

/* The Earth — grows + rises from below as --p increases */
#cosmos .earth {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 78vmin;
  height: 78vmin;
  border-radius: 50%;
  will-change: transform;
  transform:
    translate(-50%, calc(50vh + (1 - var(--p)) * 86vh))
    scale(calc(0.42 + var(--p) * 2.7));
  background:
    radial-gradient(125% 125% at 36% 26%, #2f6e98 0%, #245f86 22%, #184a6f 46%, #0c3050 70%, #06182a 100%);
  box-shadow:
    inset 6vmin 4vmin 14vmin rgba(163,214,214,0.12),
    inset -9vmin -6vmin 20vmin rgba(0,0,0,0.6),
    0 0 9vmin 1vmin rgba(75,156,211,0.34),
    0 0 24vmin 6vmin rgba(46,168,232,0.18);
}
/* realistic earth plate fills the disc when user supplies a photo */
#cosmos .earth .earth-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border-radius: 50%;
  overflow: hidden;
  opacity: calc(0.25 + var(--p) * 0.65);
}
/* atmosphere terminator highlight */
#cosmos .earth::after {
  content: "";
  position: absolute;
  inset: -2%;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 24%, rgba(163,214,214,0.30) 0%, transparent 34%);
  pointer-events: none;
}
/* city-lights / arrival warmth near the end */
#cosmos .arrival {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: calc(max(0, var(--p) - 0.78) * 4.5);
  background:
    radial-gradient(60% 40% at 50% 100%, rgba(255,196,120,0.22) 0%, transparent 70%),
    radial-gradient(8% 7% at 50% 82%, rgba(255,214,150,0.5) 0%, transparent 60%);
}
/* top + bottom vignette for legibility */
#cosmos .vignette {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(5,15,28,0.55) 0%, transparent 18%, transparent 78%, rgba(5,15,28,0.6) 100%);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .stars-wrap { animation: none !important; }
}

/* ============================================================
   SCENES
   ============================================================ */
main { position: relative; z-index: 1; }

.scene {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(80px, 12vh, 160px) clamp(28px, 7vw, 150px);
  scroll-snap-align: start;
}
.scene-inner { width: 100%; max-width: 1180px; margin: 0 auto; }
.scene.wide .scene-inner { max-width: 1360px; }

/* snap container */
.snap {
  height: 100vh;
  overflow-y: scroll;
  scroll-snap-type: y proximity;
  scroll-behavior: smooth;
  position: relative;
  z-index: 1;
}
.snap::-webkit-scrollbar { width: 0; background: transparent; }
.snap { scrollbar-width: none; }

/* ============================================================
   ARCANA / TYPE PRIMITIVES
   ============================================================ */
.arcana-label {
  font-family: var(--font-arcana);
  font-size: var(--t-arcana);
  font-weight: 600;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
}
.arcana-label .num { color: var(--gold); }
.arcana-label .rule {
  display: inline-block; width: clamp(36px,4vw,72px); height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
}
.arcana-label .rule.left { background: linear-gradient(90deg, transparent, var(--gold)); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--t-small);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--aqua);
}
.headline {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--t-title);
  line-height: 1.1;
  letter-spacing: 0.005em;
  margin: 0;
  text-wrap: balance;
  padding-bottom: 0.08em;
}
.headline em {
  font-style: italic;
  background: var(--halo-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.headline em.aqua {
  background: none; -webkit-text-fill-color: var(--aqua); color: var(--aqua);
}
.lede {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: var(--t-subtitle);
  line-height: 1.36;
  color: var(--ink-2);
  margin: 0;
  text-wrap: pretty;
}
.body {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: var(--t-body);
  line-height: 1.5;
  color: var(--ink-2);
  text-wrap: pretty;
}
.body strong { color: var(--ink); font-weight: 500; }
.mono { font-family: var(--font-mono); font-size: var(--t-small); letter-spacing: 0.02em; color: var(--aqua); }

/* Chat input mock (What Halo Recommends, founder view) */
.rec-chat-footer {
  padding: 12px 16px;
  border-top: 1px solid rgba(230,200,121,0.15);
  background: rgba(8,28,45,0.4);
}
.chat-input-mock {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(230,200,121,0.25);
  border-radius: 24px;
  padding: 10px 16px;
}
.chat-input-placeholder {
  flex: 1;
  font-family: var(--font-body);
  font-size: var(--t-small);
  color: var(--ink-3);
}
.chat-send-btn {
  display: flex;
  align-items: center;
  color: var(--gold);
  opacity: 0.7;
}

.stat-num {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--t-stat);
  line-height: 0.92;
  color: var(--aqua);
  letter-spacing: -0.01em;
}
.stat-label { font-family: var(--font-body); font-weight: 300; font-size: var(--t-small); line-height: 1.34; color: var(--ink-2); }

/* ============================================================
   GOLD TAROT FRAME (panels & plates)
   ============================================================ */
.frame {
  position: relative;
  border: 1px solid var(--gold-line);
  border-radius: 6px;
  background:
    radial-gradient(125% 120% at 50% 0%, rgba(44,110,145,0.26) 0%, rgba(8,28,45,0.55) 55%, rgba(8,28,45,0.72) 100%);
  box-shadow:
    0 0 0 7px rgba(8,28,45,0.4),
    0 0 0 8px rgba(230,200,121,0.28),
    0 40px 110px rgba(0,0,0,0.5),
    inset 0 0 120px rgba(75,156,211,0.08);
}
.frame::before {
  content: ""; position: absolute; inset: 13px;
  border: 1px solid rgba(230,200,121,0.26); border-radius: 3px; pointer-events: none;
}
.frame .corner { position: absolute; width: clamp(30px,3vw,46px); height: clamp(30px,3vw,46px); color: var(--gold); opacity: 0.85; }
.frame .corner.tl { top: 18px; left: 18px; }
.frame .corner.tr { top: 18px; right: 18px; transform: scaleX(-1); }
.frame .corner.bl { bottom: 18px; left: 18px; transform: scaleY(-1); }
.frame .corner.br { bottom: 18px; right: 18px; transform: scale(-1,-1); }

.divider-line { height: 1px; background: linear-gradient(90deg, var(--gold-line), transparent); }

/* glass card */
.card {
  background: linear-gradient(160deg, rgba(20,58,89,0.4), rgba(8,28,45,0.32));
  border: 1px solid rgba(163,214,214,0.16);
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.32), inset 0 1px 0 rgba(255,255,255,0.05);
  backdrop-filter: blur(3px);
}

/* image plate */
.plate { position: relative; border-radius: 8px; overflow: visible; }
.plate image-slot { display:block; width:100%; height:100%; border-radius: 4px; --slot-radius: 4px; }

/* ============================================================
   REVEAL ANIMATIONS (IntersectionObserver toggles .in)
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(56px);
  filter: blur(6px);
  transition: opacity 1s var(--ease-out), transform 1.1s var(--ease-out), filter 1s var(--ease-out);
  transition-delay: var(--d, 0ms);
}
.reveal.in { opacity: 1; transform: none; filter: none; }
.reveal.up   { transform: translateY(56px); }
.reveal.down { transform: translateY(-44px); }
.reveal.left { transform: translateX(-64px); }
.reveal.right{ transform: translateX(64px); }
.reveal.scale{ transform: scale(0.9); }
.reveal.in.up, .reveal.in.down, .reveal.in.left, .reveal.in.right, .reveal.in.scale { transform: none; }

/* parallax-on-scroll elements (JS sets --shift) */
.par { will-change: transform; transform: translateY(var(--shift, 0px)); }

/* ============================================================
   PROGRESS RAIL
   ============================================================ */
#rail {
  position: fixed;
  top: 50%; right: clamp(18px, 2.4vw, 42px);
  transform: translateY(-50%);
  z-index: 40;
  display: flex; flex-direction: column; align-items: flex-end; gap: 0;
  pointer-events: auto;
}
#rail .track {
  position: absolute; right: 5px; top: 8px; bottom: 8px; width: 1px;
  background: linear-gradient(180deg, transparent, var(--gold-line), transparent);
  opacity: 0.5;
}
#rail .beat {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  padding: 7px 0;
  cursor: pointer;
  background: none; border: 0;
  color: var(--ink-faint);
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  white-space: nowrap;
}
#rail .beat .lbl {
  opacity: 0; transform: translateX(8px);
  transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out), color 0.3s;
}
#rail .beat .dot {
  width: 10px; height: 10px; border-radius: 50%;
  border: 1px solid var(--gold-line); background: transparent;
  transition: all 0.35s var(--ease-out);
  flex-shrink: 0;
}
#rail:hover .beat .lbl { opacity: 0.7; transform: none; }
#rail .beat:hover { color: var(--ink); }
#rail .beat:hover .dot { border-color: var(--gold); }
#rail .beat.active { color: var(--aqua); }
#rail .beat.active .lbl { opacity: 1; transform: none; color: var(--aqua); }
#rail .beat.active .dot { background: var(--gold); border-color: var(--gold); box-shadow: 0 0 12px rgba(230,200,121,0.7); transform: scale(1.25); }
@media (max-width: 820px) { #rail { display: none; } }

/* ============================================================
   MOBILE NAV — hamburger + full-screen section menu
   (only where the desktop rail is hidden, <=820px)
   ============================================================ */
.nav-toggle { display: none; }
.mobile-nav { display: none; }

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    position: fixed; top: clamp(12px,3vw,20px); right: clamp(12px,3vw,20px);
    z-index: 95;
    width: 46px; height: 46px;
    border-radius: 12px;
    background: rgba(8,28,45,0.62);
    border: 1px solid var(--gold-line);
    -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
    cursor: pointer; -webkit-tap-highlight-color: transparent;
  }
  .nav-toggle-bars { position: relative; width: 20px; height: 14px; }
  .nav-toggle-bars i {
    position: absolute; left: 0; right: 0; height: 2px; border-radius: 2px;
    background: var(--gold);
    transition: transform .3s var(--ease-out), opacity .2s var(--ease-out);
  }
  .nav-toggle-bars i:nth-child(1) { top: 0; }
  .nav-toggle-bars i:nth-child(2) { top: 6px; }
  .nav-toggle-bars i:nth-child(3) { top: 12px; }
  .nav-toggle.open .nav-toggle-bars i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .nav-toggle.open .nav-toggle-bars i:nth-child(2) { opacity: 0; }
  .nav-toggle.open .nav-toggle-bars i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

  .mobile-nav {
    display: flex; flex-direction: column;
    position: fixed; inset: 0; z-index: 90;
    padding: clamp(74px,17vw,104px) clamp(24px,7vw,44px) clamp(28px,6vh,44px);
    background: rgba(5,13,24,0.975);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    overflow-y: auto; -webkit-overflow-scrolling: touch;
    opacity: 0; visibility: hidden; transform: translateY(-6px);
    transition: opacity .3s var(--ease-out), transform .35s var(--ease-out), visibility .3s;
  }
  .mobile-nav.open { opacity: 1; visibility: visible; transform: none; }
  .mobile-nav-list { list-style: none; margin: 0 0 auto; padding: 0; }
  .mobile-nav-list li { margin: 0; }
  .mobile-nav-list button {
    width: 100%; text-align: left; background: none; border: 0; cursor: pointer;
    display: flex; align-items: baseline; gap: 13px;
    padding: 11px 2px;
    font-family: var(--font-display); font-weight: 400;
    font-size: clamp(19px,5.4vw,26px); line-height: 1.1;
    color: var(--ink-2);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    transition: color .2s var(--ease-out), padding-left .2s var(--ease-out);
  }
  .mobile-nav-list button .mn-num {
    font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.04em;
    color: var(--gold); opacity: .65; min-width: 20px;
  }
  .mobile-nav-list button:active,
  .mobile-nav-list button.active { color: var(--ink); padding-left: 7px; }
  .mobile-nav-list button.active .mn-num { opacity: 1; }
  .mobile-nav-cta { align-self: flex-start; margin-top: clamp(22px,5vh,34px); }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-nav, .nav-toggle-bars i { transition: opacity .2s ease, visibility .2s ease; }
}

/* ============================================================
   MOBILE SECTION PAGER — tap to advance section by section
   (replaces the "Learn More" hero cue on small screens)
   ============================================================ */
.section-pager { display: none; }
@media (max-width: 820px) {
  .scroll-cue { display: none !important; }   /* hidden on mobile: overlapped the hero CTA; pager replaces it */

  .section-pager {
    display: grid; place-items: center;
    position: fixed; right: clamp(14px,4vw,22px); bottom: clamp(16px,4.5vw,26px);
    z-index: 80;
    width: 50px; height: 50px; border-radius: 50%;
    background: rgba(8,28,45,0.7); border: 1px solid var(--gold-line);
    color: var(--gold);
    -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
    box-shadow: 0 8px 28px rgba(0,0,0,0.42);
    cursor: pointer; -webkit-tap-highlight-color: transparent;
    transition: opacity .3s var(--ease-out), transform .3s var(--ease-spring), background .2s;
  }
  .section-pager:active { transform: scale(0.9); background: var(--gold-soft); }
  .section-pager-icon { width: 22px; height: 22px; transition: transform .35s var(--ease-out); }
  .section-pager.at-end .section-pager-icon { transform: rotate(180deg); }  /* back-to-top at the end */
  /* hide the pager while the menu or a modal is open */
  html.nav-open .section-pager, html.modal-open .section-pager { opacity: 0; pointer-events: none; }
}

/* scroll cue (hero) */
.scroll-cue {
  position: absolute; left: 50%; bottom: 40px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  color: var(--ink-2);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.2s;
}
.scroll-cue:hover { opacity: 1; }
.scroll-cue .chev-group { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.scroll-cue .chev {
  display: block;
  width: 20px; height: 20px;
  border-right: 1.5px solid var(--gold);
  border-bottom: 1.5px solid var(--gold);
  transform: rotate(45deg);
  animation: cue 1.8s ease-in-out infinite;
}
.scroll-cue .chev--delay { animation-delay: 0.25s; opacity: 0.5; }
@keyframes cue {
  0%, 100% { opacity: 0; transform: rotate(45deg) translate(-4px, -4px); }
  50% { opacity: 1; transform: rotate(45deg) translate(0, 0); }
}

/* fades on hero mark */
.hero-mark { will-change: transform, opacity; }

/* ============================================================
   CTA
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 0.6em;
  font-family: var(--font-body); font-weight: 500; font-size: var(--t-body);
  color: var(--abyss); text-decoration: none;
  background: var(--gold); border: 0; border-radius: 999px;
  padding: 0.7em 1.5em;
  transition: transform 0.25s var(--ease-spring), box-shadow 0.25s, background 0.2s;
  box-shadow: 0 10px 30px rgba(230,200,121,0.28);
}
.btn:hover { background: #f0d792; box-shadow: 0 14px 40px rgba(230,200,121,0.42); }
.btn.ghost { background: transparent; color: var(--aqua); border: 1px solid var(--gold-line); box-shadow: none; }
.btn.ghost:hover { background: var(--gold-soft); }

.btn--primary {
  padding: 0.8em 2em;
  font-size: clamp(15px, 1.1vw, 17px);
  font-weight: 600;
  box-shadow: 0 12px 40px rgba(230,200,121,0.35), 0 0 0 0 rgba(230,200,121,0);
  transition: transform 0.25s var(--ease-spring, cubic-bezier(0.34,1.56,0.64,1)), box-shadow 0.25s, background 0.2s;
}
.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 50px rgba(230,200,121,0.5), 0 0 0 4px rgba(230,200,121,0.12);
}
.btn--secondary { font-size: clamp(14px, 1vw, 16px); padding: 0.7em 1.8em; letter-spacing: 0.02em; }
.btn--team { font-size: clamp(14px, 1vw, 16px); }

/* ====================================================
   SITE HEADER · brand logo (fixed top-left)
   ==================================================== */
.site-header {
  position: fixed; top: 0; left: 0; z-index: 45;
  padding: clamp(16px,2.2vw,26px) clamp(20px,3vw,46px);
  pointer-events: none;
}
.brand {
  display: inline-flex; align-items: center; gap: 11px;
  text-decoration: none; pointer-events: auto;
  transition: opacity 0.25s ease, transform 0.25s var(--ease-spring);
}
.brand:hover { opacity: 0.85; }
.brand-mark {
  height: clamp(34px,3.4vw,46px); width: auto; display: block;
  filter: drop-shadow(0 4px 18px rgba(46,168,232,0.40));
}
.brand-name {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(24px,2.3vw,32px);
  color: var(--ink); letter-spacing: 0.01em; line-height: 1;
}
@media (max-width: 640px) {
  .brand-name { font-size: 23px; }   /* keep the Halo wordmark visible on mobile too */
  .brand-mark { height: 32px; }
}

/* ====================================================
   SITE FOOTER
   ==================================================== */
.site-footer {
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap;
  gap: 6px 12px;
  padding: 30px 24px 38px;
  font-family: var(--font-mono);
  font-size: clamp(12.5px, 1.05vw, 14px);
  letter-spacing: 0.04em;
  line-height: 1.6;
  color: rgba(244,248,251,0.64);
  border-top: 1px solid rgba(255,255,255,0.09);
  position: relative;   /* lift above the fixed #cosmos backdrop (z-index:0) */
  z-index: 1;
  background: rgba(5,15,28,0.62);
}
.site-footer-link { color: var(--ink-2); text-decoration: none; border-bottom: 1px solid rgba(163,214,214,0.28); padding-bottom: 1px; transition: color 0.2s, border-color 0.2s; }
.site-footer-link:hover { color: var(--aqua); border-color: var(--aqua); }
.site-footer-dot { opacity: 0.4; }

/* ====================================================
   GET EARLY ACCESS · Airtable form modal
   ==================================================== */
html.modal-open, html.nav-open { overflow: hidden; }
.ea-modal {
  position: fixed; inset: 0; z-index: 100;
  display: none; align-items: center; justify-content: center;
  padding: clamp(14px,3.5vw,40px);
}
.ea-modal.open { display: flex; }
.ea-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(3,10,20,0.74);
  backdrop-filter: blur(6px);
  animation: eaFade 0.25s ease;
}
.ea-modal-card {
  position: relative; z-index: 1;
  width: min(620px, 100%);
  max-height: 92vh;
  display: flex; flex-direction: column;
  padding: clamp(16px,2.4vw,26px);
  border-radius: 16px;
  border: 1px solid var(--gold-line);
  background: linear-gradient(165deg, rgba(20,58,89,0.62), rgba(8,28,45,0.94));
  box-shadow: 0 40px 120px rgba(0,0,0,0.6), inset 0 0 90px rgba(75,156,211,0.06);
  animation: eaPop 0.3s var(--ease-spring);
}
.ea-modal-close {
  position: absolute; top: 12px; right: 12px;
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 999px; cursor: pointer;
  color: var(--ink); background: rgba(8,28,45,0.6);
  border: 1px solid var(--gold-line);
  transition: background 0.2s, transform 0.25s var(--ease-out);
  z-index: 2;
}
.ea-modal-close:hover { background: var(--gold-soft); transform: rotate(90deg); }
.ea-modal-close svg { width: 18px; height: 18px; }
.ea-modal-head { padding: 2px 44px 14px 4px; }
.ea-modal-eyebrow { display: block; color: var(--gold); letter-spacing: 0.16em; text-transform: uppercase; font-size: 11px; margin-bottom: 6px; }
.ea-modal-title { font-family: var(--font-display); font-weight: 400; font-size: clamp(26px,3vw,36px); line-height: 1.05; color: var(--ink); margin: 0; }
.ea-modal-body { flex: 1; min-height: 0; border-radius: 10px; overflow: hidden; background: rgba(255,255,255,0.02); }
.airtable-embed { display: block; width: 100%; height: min(533px, 64vh); border: 0; background: transparent; }
@keyframes eaFade { from { opacity: 0; } }
@keyframes eaPop { from { opacity: 0; transform: translateY(16px) scale(0.97); } }
@media (prefers-reduced-motion: reduce) {
  .ea-modal-backdrop, .ea-modal-card { animation: none; }
  .ea-modal-close { transition: background 0.2s; }
}

/* utility */
.center { text-align: center; }
.stack { display: flex; flex-direction: column; }
.row { display: flex; }
.grid { display: grid; }

/* ============================================================
   GUARDIANS · PLEIADES · EARTH · WINDOW  (descent imagery)
   ============================================================ */
.scene-inner { position: relative; z-index: 1; }

/* Inflection Point countdown */
.countdown-wrap { position: relative; display: flex; justify-content: center; }
.countdown-angel {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -54%);
  width: clamp(360px, 40vw, 560px);
  z-index: 0;
  opacity: 0.3;
  pointer-events: none;
  filter: drop-shadow(0 0 40px rgba(230,200,121,0.32));
  animation: guardian-float 9s ease-in-out infinite;
}
.countdown-frame {
  position: relative;
  z-index: 1;
  width: 100%;
  background: linear-gradient(165deg, rgba(12,39,64,0.82), rgba(8,28,45,0.88));
  backdrop-filter: blur(2px);
}
.countdown {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(6px, 1vw, 14px);
  margin: 4px 0 22px;
}
.cd-unit { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: clamp(56px, 7vw, 92px); }
.cd-val {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(48px, 6.4vw, 92px);
  line-height: 0.9;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}
.cd-lbl {
  font-family: var(--font-mono);
  font-size: clamp(11px, 1vw, 14px);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.cd-sep {
  font-family: var(--font-display);
  font-size: clamp(40px, 5vw, 76px);
  line-height: 1;
  color: rgba(230,200,121,0.4);
  margin-top: clamp(2px, 0.4vw, 6px);
}
.countdown-caption {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(20px, 2.1vw, 30px);
  line-height: 1.3;
  color: var(--ink);
  margin: 0 auto;
  max-width: 30ch;
  text-wrap: balance;
}

/* Hero, two-column: copy left, Michael right */
.hero { padding-left: clamp(28px, 6vw, 120px); padding-right: clamp(28px, 6vw, 120px); }
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: clamp(32px, 5vw, 88px);
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
}
.hero-copy { gap: clamp(18px, 2.4vh, 30px); text-align: left; align-items: flex-start; }
.hero-copy .hero-headline { font-family: var(--font-display); font-weight: 400; letter-spacing: 0.01em; font-size: var(--t-title); line-height: 1.05; max-width: 15ch; }
.hero-copy .body { font-size: clamp(17px, 1.5vw, 22px); }

/* shimmer on the hero emphasis line */
.shimmer {
  background-size: 200% auto !important;
  animation: shimmer-sweep 6s linear infinite;
}
@keyframes shimmer-sweep {
  to { background-position: 200% center; }
}
@media (prefers-reduced-motion: reduce) { .shimmer { animation: none; } }
.hero-figure {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
}
.hero-figure img {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: clamp(340px, 38vw, 560px);
  height: auto;
  filter: brightness(0.8) drop-shadow(0 30px 70px rgba(0,0,0,0.5));
  animation: hero-float 9s ease-in-out infinite;
}
@keyframes hero-float {
  0%,100% { filter: brightness(0.8) drop-shadow(0 26px 60px rgba(0,0,0,0.5)); }
  50%     { filter: brightness(0.8) drop-shadow(0 34px 80px rgba(0,0,0,0.55)); }
}
.hero-figure-glow {
  display: none;   /* removed: glow directly behind Archangel Michael */
  position: absolute;
  inset: -6% -4% -10%;
  z-index: 0;
  background:
    radial-gradient(46% 52% at 50% 46%, rgba(75,156,211,0.34) 0%, rgba(46,168,232,0.12) 42%, transparent 72%),
    radial-gradient(34% 40% at 50% 40%, rgba(230,200,121,0.18) 0%, transparent 70%);
  pointer-events: none;
}
@media (prefers-reduced-motion: reduce) { .hero-figure img, .countdown-angel { animation: none; } }

/* The Declaration, full-bleed luminous callout */
.declaration { overflow: hidden; }
.declaration .declaration-bg {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(60% 80% at 50% 50%, rgba(75,156,211,0.22) 0%, rgba(46,168,232,0.08) 40%, transparent 72%),
    radial-gradient(40% 50% at 50% 50%, rgba(230,200,121,0.12) 0%, transparent 70%);
}
.declaration .declaration-bg::before,
.declaration .declaration-bg::after {
  content: ""; position: absolute; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-line) 18%, var(--gold-line) 82%, transparent);
}
.declaration .declaration-bg::before { top: 0; }
.declaration .declaration-bg::after { bottom: 0; }

.guardian {
  position: absolute;
  inset: 0;
  margin: auto;
  width: clamp(260px, 30vw, 500px);
  height: max-content;
  z-index: 0;
  opacity: 0.62;
  filter: brightness(1.22);
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
  animation: guardian-float 9s ease-in-out infinite;
}
.guardian-hero { opacity: 0.5; width: clamp(300px, 36vw, 600px); top: 58vh; bottom: auto; }
.guardian-right { left: auto; right: clamp(-70px, -3vw, -20px); }
.guardian-left  { right: auto; left: clamp(-70px, -3vw, -20px); }
/* varied arrival heights, as if descending from different altitudes */
.guardian-hi  { top: -8vh;  bottom: auto; width: clamp(240px, 27vw, 440px); }
.guardian-mid { top: 6vh;   bottom: auto; width: clamp(270px, 31vw, 500px); }
.guardian-lo  { top: auto;  bottom: -10vh; width: clamp(280px, 33vw, 540px); }
@keyframes guardian-float {
  0%,100% { filter: brightness(1.22) drop-shadow(0 0 36px rgba(230,200,121,0.4)); }
  50%     { filter: brightness(1.22) drop-shadow(0 0 60px rgba(230,200,121,0.6)); }
}
@media (prefers-reduced-motion: reduce) { .guardian { animation: none; } }

/* Pleiades named stars */
.star-name {
  font-family: var(--font-arcana);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  fill: rgba(230,200,121,0.85);
  text-anchor: middle;
}
.star-name.bright { fill: #FFFDF4; font-size: 14px; }
.pleiades .cluster path { filter: drop-shadow(0 0 6px rgba(255,246,218,0.85)); }

/* Promised-land faint Earth */
.promised-earth {
  width: clamp(150px, 20vw, 240px);
  aspect-ratio: 1;
  border-radius: 50%;
  position: relative;
  overflow: hidden;
  margin-top: 8px;
  background: radial-gradient(125% 125% at 36% 30%, #2f6e98 0%, #1d567f 40%, #123a59 72%, #081f33 100%);
  box-shadow:
    inset 6px 4px 22px rgba(163,214,214,0.18),
    inset -10px -8px 30px rgba(0,0,0,0.5),
    0 0 44px 6px rgba(75,156,211,0.28);
}
.promised-earth svg { position: absolute; inset: 0; width: 100%; height: 100%; }

/* On Earth — framed child plate */
.plate-img { position: relative; border-radius: 4px; overflow: hidden; }
.plate-img img {
  display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover;
  filter: sepia(0.16) saturate(0.95) brightness(0.97) contrast(1.03);
}
.plate-img::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  box-shadow: inset 0 0 55px rgba(8,28,45,0.5);
  background: radial-gradient(120% 100% at 50% 0%, transparent 56%, rgba(8,28,45,0.32) 100%);
}

/* Black Box — numbered commitments */
.bb-num {
  flex-shrink: 0; width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; margin-top: 2px;
  font-family: var(--font-mono); font-size: 17px; font-weight: 600;
  color: var(--gold); border: 1px solid var(--gold-line); background: var(--gold-soft);
}

/* Closing — Earth arrival backdrop */
.closing-scene { justify-content: center; min-height: auto; padding-top: clamp(36px,4.5vh,68px); padding-bottom: clamp(28px,3.5vh,48px); overflow: hidden; scroll-snap-align: none; }
.closing-scene .scene-inner { gap: clamp(12px,1.7vh,20px) !important; }
.closing-scene .scene-inner { z-index: 2; }
.closing-earth {
  position: absolute; left: 0; right: 0; bottom: 0; height: 64%;
  background: url('assets/earth-horizon.jpg') center top / cover no-repeat;
  filter: brightness(0.6) saturate(0.85);
  z-index: 0; pointer-events: none;
  -webkit-mask-image: linear-gradient(to top, #000 64%, transparent 100%);
  mask-image: linear-gradient(to top, #000 64%, transparent 100%);
}
.closing-tint {
  position: absolute; left: 0; right: 0; bottom: 0; height: 64%; z-index: 1; pointer-events: none;
  background: radial-gradient(80% 70% at 50% 40%, rgba(75,156,211,0.18), transparent 64%);
  mix-blend-mode: screen;
}
.closing-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(70% 50% at 50% 46%, rgba(5,15,28,0.82), rgba(5,15,28,0.4) 60%, transparent 82%),
    linear-gradient(180deg, var(--abyss) 0%, rgba(5,15,28,0.86) 30%, rgba(5,15,28,0.62) 55%, rgba(5,15,28,0.4) 78%, rgba(5,15,28,0.3) 100%);
}

/* ============================================================
   MOBILE  (<= 640px)
   ============================================================ */
@media (max-width: 640px) {
  html { scroll-snap-type: none; }
  .scene {
    padding: 86px 22px 86px;
    min-height: auto;
  }
  .scene-inner.grid { grid-template-columns: 1fr !important; gap: 22px !important; }
  .scene .grid[style*="repeat(4"] { grid-template-columns: repeat(2,1fr) !important; }
  .scene .grid[style*="repeat(3"] { grid-template-columns: 1fr !important; }
  .scene .grid[style*="1fr 1fr"] { grid-template-columns: 1fr !important; }
  .scene .grid[style*="0.9fr"] { grid-template-columns: 1fr !important; }
  .recommends-wrap { grid-template-columns: 1fr !important; }
  .scan-wrap { grid-template-columns: 1fr !important; }
  .guardian { opacity: 0.24; width: 80vw; }
  .guardian-hero { top: 70vh; width: 92vw; }
  .hero-grid { grid-template-columns: 1fr; gap: clamp(20px,4vh,40px); }
  /* mobile hero order: heading, subtext, CTA, stars, then Archangel Michael */
  .hero-figure { order: 5; }
  .hero-figure img { max-width: min(60vw, 300px); }
  .hero-copy { align-items: center; text-align: center; }
  .hero-copy .hero-headline { order: 1; max-width: 18ch; }
  .hero-copy .body { order: 2; }
  .hero-copy .hero-cta { order: 3; }
  .hero-copy .pleiades { order: 4; align-self: center !important; }
  .guardian-right, .guardian-left { left: 0; right: 0; }
  .pleiades { width: 88vw !important; }
  .promised-earth { width: 150px; }
  /* countdown + plates on phones */
  .plate { max-width: 88vw !important; margin-left: auto; margin-right: auto; }
  .countdown { gap: 4px; }
  .cd-unit { min-width: 0; flex: 1; gap: 6px; }
  .cd-val { font-size: clamp(34px, 13vw, 56px); }
  .cd-sep { font-size: clamp(26px, 9vw, 44px); }
  .cd-lbl { font-size: 11px; letter-spacing: 0.08em; }
  .tstat { gap: 14px; padding: 20px 22px; }
  .tstat-num { font-size: clamp(34px, 11vw, 48px); }
  .closing-scene .row { width: 100%; }
}

@media (max-width: 400px) {
  .cd-val { font-size: 30px; }
  .cd-sep { font-size: 22px; }
  .cd-lbl { font-size: 10px; }
}
