/* Home page (src/pages/index.html). Shared tokens/components: v2.css. */

/* ---------- hero ---------- */
.hero { position: relative; min-height: 600px; height: calc(100vh - var(--header-h)); height: calc(100svh - var(--header-h)); overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; }
.hero__film { position: absolute; inset: 0; }
.hero__film::after { content: ""; position: absolute; inset: 0; pointer-events: none;   /* legibility scrim for white type, bottom only */
  background: linear-gradient(to top, rgba(0,0,0,.72) 0%, rgba(0,0,0,.32) 34%, rgba(0,0,0,0) 62%); }
.hero__text { position: relative; z-index: 2; padding-bottom: clamp(56px, 9vh, 104px); }
.hero__text .kicker { color: rgba(255,255,255,.82); }
.hero .display { max-width: 9.5em; }
.hero .lead { margin-top: var(--s4); max-width: 30em; color: rgba(255,255,255,.9); }
.hero .btns { margin-top: var(--s5); }
.hero .btn:not(.btn--primary) { border-color: rgba(255,255,255,.7); }
.hero__caption { position: absolute; z-index: 2; left: max(var(--pad), env(safe-area-inset-left)); bottom: var(--s3); margin: 0; color: rgba(255,255,255,.7); }
.hero .film__toggle { z-index: 3; }
@media (max-width: 759px) {
  .hero { min-height: 560px; }
  .hero__text { padding-bottom: 84px; }
  .hero__caption { right: 84px; bottom: 24px; }
  .hero .display { font-size: clamp(48px, 14vw, 64px); }
}

/* ---------- 03 data to world (stepper.js) ---------- */
.steps-pin { --pin-h: 340vh; }
.steps { display: flex; align-items: center; }
.steps__in { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: var(--gap); align-items: center; width: 100%; }
.steps__side .h2 { font-size: clamp(30px, 3.4vw, 52px); margin-bottom: var(--s5); }
.steps__side .rule { margin-bottom: var(--s5); }
.steps__list { margin: 0; padding: 0; list-style: none; columns: 2; column-gap: var(--s4); }
.steps__list li { break-inside: avoid; }
.steps__list button { display: flex; gap: 10px; width: 100%; min-height: 34px; padding: 7px 0; background: none; border: 0; border-top: 1px solid var(--line);
  color: var(--fg-2); text-align: left; cursor: pointer; font: 500 12px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .07em; transition: color var(--t) var(--ease); }
.steps__list button span { color: inherit; }
.steps__list button:hover { color: var(--fg); }
.steps__list button[aria-current] { color: var(--fg); border-top-color: var(--fg); }
.steps__frame { background: #0b0b0b; }
.steps__frame picture, .steps__frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.steps__cone { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.steps__cone[hidden] { display: none; }   /* v2.css sets svg { display: block }, which beats the UA [hidden] rule */
.steps__cap { display: grid; grid-template-columns: auto 1fr auto; gap: var(--s3); align-items: baseline; margin-top: var(--s3); padding-top: var(--s2); border-top: 1px solid var(--line); }
.steps__text { font-size: 16px; line-height: 1.45; }
.steps__kind { margin: 0; }
@media (max-width: 959px) {
  .steps-pin { --pin-h: 300vh; }
  .steps { align-items: flex-start; padding-top: var(--s4); }
  .steps__in { grid-template-columns: 1fr; gap: var(--s3); }
  .steps__side { display: contents; }
  .steps__side .rule { order: 0; margin-bottom: 0; }
  .steps__side .h2 { order: 1; margin-bottom: 0; font-size: 28px; }
  .steps__fig { order: 2; }
  .steps__list { order: 3; display: flex; columns: auto; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
  .steps__list::-webkit-scrollbar { display: none; }
  .steps__list li { flex: 0 0 auto; }
  .steps__list button { width: auto; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); white-space: nowrap; }
  .steps__list button[aria-current] { border-color: var(--fg); }
  .steps__cap { grid-template-columns: auto 1fr; }
  .steps__kind { grid-column: 1 / -1; }
}
.reduced .steps-sec, html:not(.js) .steps-sec { padding: var(--sec) 0; }

/* ---------- 04 three maps ---------- */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin: var(--s6) 0 0; padding: 0; list-style: none; }
.card .muted { margin-top: var(--s2); max-width: 30em; }
.card__meta .tag { margin-left: 6px; }
.maps-sec__more { margin-top: var(--s5); }
@media (max-width: 759px) { .cards { grid-template-columns: 1fr; row-gap: var(--s6); } }

/* ---------- 05 alive (scrub.js: the film follows the scroll; flat = normal film for reduced motion, data saver, no JS) ---------- */
.alive__pin { --pin-h: 380vh; }
.alive__stage { background: #000; display: flex; flex-direction: column; }
.alive__media { position: relative; order: 2; aspect-ratio: 21 / 9; max-height: 86vh; width: 100%; margin-top: var(--s6); }
.alive__media > .film { position: absolute; inset: 0; }
.alive__gl { position: absolute; inset: 0; width: 100%; height: 100%; display: none; }
.alive__head { order: 1; padding-top: var(--s7); }
.alive__head .grid { margin-top: 0; }
.alive__foot { order: 3; width: 100%; padding-bottom: var(--s5); }
.alive__read, .alive__bar { display: none; }
.alive__cap { margin-top: var(--s3); }
.alive__nojs { margin-top: var(--s5); }
.alive__nojs video { width: 100%; height: auto; aspect-ratio: 16 / 9; background: #000; }
html.js .alive__nojs, html:not(.js) .alive__media { display: none; }
/* live: the stage is pinned, the film fills it, the text sits on top */
.alive__pin.is-live .alive__stage { display: block; }
.alive__pin.is-live .alive__media { position: absolute; inset: 0; aspect-ratio: auto; max-height: none; margin: 0; }
.alive__pin.is-live .alive__gl { display: block; }
.alive__pin.is-live .film__video, .alive__pin.is-live .film__toggle { display: none; }
.alive__pin.has-frame .film__poster { visibility: hidden; }
.alive__pin.is-live .alive__media { contain: layout paint; }   /* its own paint / layout island: the canvas repaints every frame without touching the text above */
.alive__pin.is-live .alive__stage::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to right, rgba(0,0,0,.66), rgba(0,0,0,.2) 46%, rgba(0,0,0,0) 68%), linear-gradient(to top, rgba(0,0,0,.6), rgba(0,0,0,0) 30%); }
.alive__pin.is-live .alive__head { position: relative; z-index: 2; padding-top: var(--s5); }
.alive__pin.is-live .alive__head .rule { border-top-color: rgba(255,255,255,.7); margin-bottom: var(--s5); }
.alive__pin.is-live .alive__head .grid { display: block; }
.alive__pin.is-live .alive__head .h2 { max-width: 9em; font-size: clamp(32px, 4.2vw, 64px); }
.alive__pin.is-live .alive__head .lead { margin-top: var(--s4); max-width: 22em; font-size: clamp(16px, 1.3vw, 20px); color: rgba(255,255,255,.82); }
.alive__pin.is-live .alive__foot { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; padding-bottom: var(--s4); }
.alive__pin.is-live .alive__read { display: flex; flex-direction: column; gap: 8px; margin-bottom: var(--s3); }
.alive__pin.is-live .alive__read .label { color: rgba(255,255,255,.75); }
.alive__pin.is-live .alive__nojs { display: none; }
.alive__pin.is-live .alive__bar { display: block; position: absolute; z-index: 2; right: max(var(--pad), env(safe-area-inset-right)); top: 22%; bottom: 22%; width: 1px; background: rgba(255,255,255,.3); }
.alive__bar i { position: absolute; left: -1px; right: -1px; bottom: 0; height: 100%; background: #fff; transform-origin: bottom; transform: scaleY(0); }
@media (max-width: 759px) {
  .alive__pin { --pin-h: 340vh; }
  .alive__media { aspect-ratio: 4 / 3; margin-top: var(--s5); }
  .alive__head { padding-top: var(--s6); }
  /* phones: heading on top, the film in a 4:3 window below it (a full-height 16:9 crop would be upscaled 3x) */
  .alive__pin.is-live .alive__stage { display: flex; }
  .alive__pin.is-live .alive__media { position: relative; order: 2; margin: var(--s4) var(--pad) 0; width: auto; aspect-ratio: 4 / 3; inset: auto; }
  .alive__pin.is-live .alive__stage::after { display: none; }
  .alive__pin.is-live .alive__head { padding-top: var(--s4); }
  .alive__pin.is-live .alive__head .h2 { font-size: 28px; }
  .alive__pin.is-live .alive__head .lead { font-size: 15px; margin-top: var(--s3); }
  .alive__pin.is-live .alive__foot { position: relative; order: 3; margin-top: auto; padding-bottom: var(--s3); }
  .alive__pin.is-live .alive__read .readout { font-size: 38px; }
  .alive__pin.is-live .alive__bar { display: none; }
}

/* ---------- 07 pilot ---------- */
.pilot__grid { align-items: center; }
.pilot__text .h3 { margin-bottom: var(--s4); font-size: clamp(28px, 3vw, 40px); }
.pilot__text p { font-size: clamp(17px, 1.4vw, 20px); }
.pilot__sign { font-weight: 600; }

/* ---------- 08 join ---------- */
.join__h { max-width: 8em; }
.join__btns { margin-top: var(--s6); }
.join__req { margin-top: var(--s5); }
