/* ==========================================================================
   Torchpass — homepage
   Implements project/Torchpass.dc.html from the Claude Design handoff.

   Layout contract: every row on the page — header, mega menus, hero, each
   section, the footer and the footer's meta row — is a .wrap. That is the
   ONLY thing allowed to set horizontal width, so nothing can drift out of
   alignment with anything else.
   ========================================================================== */

:root {
  /* the one container, used by every row */
  --maxw: 1320px;
  --pad: clamp(20px, 5vw, 48px);

  --sect: clamp(84px, 10vw, 130px);
  --sect-lg: clamp(100px, 12vw, 150px);

  --bg: #fefefe;
  --ink: #141414;
  --muted: #5c5c5c;
  --line: #e8e8e6;
  --line-2: #dcdcd8;
  --card: #ffffff;
  --wash: rgba(20, 20, 20, 0.04);

  --sans: "Helvetica Neue", Helvetica, Arial, "Segoe UI", Roboto, system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --hdr-h: 73px;
}

:root.dark {
  --bg: #131313;
  --ink: #f2f2f0;
  --muted: #9a9a97;
  --line: #2b2b2b;
  --line-2: #383836;
  --card: #1b1b1b;
  --wash: rgba(242, 242, 240, 0.06);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  /* anchor links must clear the sticky header */
  scroll-padding-top: calc(var(--hdr-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* the page is a stack of full-bleed rows; nothing may scroll sideways */
  overflow-x: hidden;
  transition: background 0.4s ease, color 0.4s ease;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, p, figure, ol, ul { margin: 0; }
ol, ul { padding: 0; list-style: none; }

::selection { background: var(--ink); color: var(--bg); }

:where(a, button, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 3px;
}

.skip {
  position: fixed; top: 10px; left: 10px; z-index: 200;
  padding: 12px 20px; border-radius: 99px;
  background: var(--ink); color: var(--bg); font-size: 14px; font-weight: 600;
  transform: translateY(-160%); transition: transform 0.2s var(--ease);
}
.skip:focus-visible { transform: translateY(0); }

/* ---------- the container ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ---------- shared type ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 20px;
  font-weight: 400;
}

.h2 {
  font-size: clamp(30px, 3vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 600;
  margin: 0 0 18px;
  text-wrap: balance;
}
.h2-lg {
  font-size: clamp(34px, 4vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.lede {
  font-size: 17px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 20px;
  max-width: 62ch;
  text-wrap: pretty;
}
.lede:last-of-type { margin-bottom: 32px; }

.lede-block { max-width: 760px; }
.centred { max-width: 720px; margin-inline: auto; text-align: center; }
.centred .lede { margin-inline: auto; }

/* ---------- buttons / links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 15px 30px; border-radius: 99px;
  font-size: 16px; font-weight: 500; white-space: nowrap;
  border: 1px solid transparent;
  transition: opacity 0.15s var(--ease), background 0.15s var(--ease), border-color 0.15s var(--ease);
}
.btn-solid { background: var(--ink); color: var(--bg); }
.btn-solid:hover { opacity: 0.86; }
.btn-line { border-color: var(--line-2); color: var(--ink); }
.btn-line:hover { border-color: var(--ink); }
.btn-lg { padding: 17px 36px; font-size: 17px; }

.link-go {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 16px; font-weight: 500;
  padding-bottom: 3px;
  box-shadow: inset 0 -1px 0 0 var(--ink);
  transition: gap 0.15s var(--ease);
}
.link-go:hover { gap: 12px; }
.link-go svg { flex-shrink: 0; }
.sect-go { margin-top: 52px; }

/* ==========================================================================
   HEADER
   ========================================================================== */
.hdr {
  position: fixed; top: 0; left: 0; right: 0; z-index: 90;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.hdr-in {
  display: flex; align-items: center; gap: clamp(16px, 3vw, 44px);
  height: var(--hdr-h);
}

.hdr-logo { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.hdr-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ink); flex-shrink: 0; }
.hdr-word { font-family: var(--mono); font-size: 15px; letter-spacing: 0.3em; font-weight: 600; }

.hdr-nav { display: flex; align-items: center; gap: 2px; flex: 1; }

.nav-it {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: 0; cursor: pointer;
  font-size: 15px; font-weight: 500;
  padding: 9px 13px; border-radius: 99px;
  white-space: nowrap;
  transition: background 0.15s var(--ease);
}
.nav-it:hover, .nav-it[aria-expanded="true"] { background: var(--wash); }
.nav-it svg { transition: transform 0.18s var(--ease); }
.nav-it[aria-expanded="true"] svg { transform: rotate(180deg); }

.hdr-cta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.hdr-theme {
  background: none; border: 1px solid var(--line-2); cursor: pointer;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em;
  padding: 9px 15px; border-radius: 99px; color: var(--muted);
  transition: border-color 0.15s var(--ease), color 0.15s var(--ease);
}
.hdr-theme:hover { border-color: var(--ink); color: var(--ink); }

.hdr-login { font-size: 15px; font-weight: 500; padding: 10px 8px; }
.hdr-login:hover { opacity: 0.7; }
.hdr-go {
  background: var(--ink); color: var(--bg);
  padding: 11px 22px; border-radius: 99px;
  font-size: 15px; font-weight: 500; white-space: nowrap;
  transition: opacity 0.15s var(--ease);
}
.hdr-go:hover { opacity: 0.86; }

.burger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: 1px solid var(--line-2); border-radius: 99px;
  padding: 13px 15px; cursor: pointer;
}
.burger span { display: block; width: 18px; height: 1.6px; background: var(--ink); transition: transform 0.2s var(--ease); }
.burger[aria-expanded="true"] span:first-child { transform: translateY(3.3px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { transform: translateY(-3.3px) rotate(-45deg); }

/* ---------- mega menu ---------- */
.mega {
  position: absolute; left: 0; right: 0; top: 100%;
  background: var(--bg);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 40px 70px -44px rgba(0, 0, 0, 0.35);
  animation: mega-in 0.18s var(--ease) both;
}
.mega[hidden] { display: none; }
@keyframes mega-in { from { opacity: 0; transform: translateY(-6px); } }

.mega-in {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) minmax(260px, 0.62fr);
  gap: clamp(24px, 3vw, 44px);
  padding-block: 34px 38px;
  align-items: stretch;
}
.mega-intro .eyebrow { margin-bottom: 12px; }
.mega-intro p:last-child { font-size: 14px; line-height: 1.55; color: var(--muted); margin: 0; }

.mega-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 4px 16px;
  align-content: start;
}
.mega-link {
  display: block; padding: 12px 14px; border-radius: 10px;
  transition: background 0.15s var(--ease);
}
.mega-link:hover { background: var(--wash); }
.mega-link b { display: block; font-size: 15.5px; font-weight: 600; margin-bottom: 2px; }
.mega-link span { font-size: 13.5px; line-height: 1.45; color: var(--muted); }

.mega-feat {
  display: flex; flex-direction: column;
  padding: 24px; border-radius: 12px;
  background: var(--ink); color: var(--bg);
  min-height: 100%;
}
.mega-feat-k {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em;
  text-transform: uppercase; opacity: 0.62;
}
.mega-feat-h {
  margin: 14px 0 0; font-size: clamp(17px, 1.4vw, 20px);
  font-weight: 600; line-height: 1.24; letter-spacing: -0.01em;
}
.mega-feat-m { margin: 11px 0 0; font-size: 13.5px; line-height: 1.55; opacity: 0.66; }
.mega-feat-go {
  margin-top: auto; padding-top: 20px;
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14.5px; font-weight: 500;
}
.mega-feat:hover .mega-feat-go svg { transform: translateX(3px); }
.mega-feat-go svg { transition: transform 0.15s var(--ease); }

/* ---------- mobile sheet ---------- */
.mob {
  position: fixed; inset: 0; z-index: 95;
  display: none; flex-direction: column;
  background: var(--bg);
}
.mob.open { display: flex; }
.mob-bar {
  flex-shrink: 0; display: flex; align-items: center; justify-content: space-between;
  height: var(--hdr-h); border-bottom: 1px solid var(--line);
}
.mob-close { background: none; border: 0; cursor: pointer; padding: 8px; margin-right: -8px; }
.mob-scroll {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  padding-block: 10px 24px; display: flex; flex-direction: column;
}
.mob-link, .mob-sec-btn {
  display: flex; align-items: center; min-height: 56px;
  font-size: 19px; font-weight: 500; text-align: left;
  border-bottom: 1px solid var(--line);
  background: none; border-left: 0; border-right: 0; border-top: 0;
  width: 100%; cursor: pointer; padding: 0;
}
.mob-sec-btn { justify-content: space-between; gap: 12px; }
.mob-sec-btn svg { flex-shrink: 0; color: var(--muted); transition: transform 0.18s var(--ease); }
.mob-sec-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.mob-sec-btn[aria-expanded="true"] { border-bottom-color: transparent; }
.mob-sec-links { display: flex; flex-direction: column; padding: 0 0 12px; border-bottom: 1px solid var(--line); }
.mob-sec-links[hidden] { display: none; }
.mob-sec-links a {
  display: flex; align-items: center; min-height: 46px;
  padding: 8px 0 8px 16px; margin-left: 2px;
  border-left: 2px solid var(--line);
  font-size: 16px; font-weight: 500; color: var(--muted);
}
.mob-sec-links a b { color: var(--ink); font-weight: 600; }
.mob-ctas {
  flex-shrink: 0; display: flex; flex-direction: column; gap: 10px;
  padding-block: 16px calc(18px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
}
.mob-ctas .btn { width: 100%; }

@media (max-width: 1000px) {
  .hdr-nav, .hdr-login, .hdr-go { display: none; }
  .burger { display: inline-flex; }
  .hdr-cta { margin-left: auto; }
}
@media (min-width: 1001px) {
  .mob { display: none !important; }
}
@media (max-width: 900px) {
  .mega-in { grid-template-columns: 1fr; gap: 20px; padding-block: 24px 28px; }
}

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative;
  min-height: min(100svh, 940px);
  display: flex; flex-direction: column; justify-content: center;
  padding-top: calc(var(--hdr-h) + clamp(48px, 6vw, 76px));
  padding-bottom: 0;
  overflow: hidden;
}

/* the Three.js thread field, fanning out to the right */
.hero-field {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: 62%;
  pointer-events: none;
  z-index: 0;
}
/* keeps the fan from competing with the headline where the two overlap */
.hero-wash {
  position: absolute; top: 0; bottom: 0; left: 0;
  width: 70%;
  pointer-events: none; z-index: 1;
  background: linear-gradient(90deg, var(--bg) 34%, color-mix(in srgb, var(--bg) 55%, transparent) 72%, transparent 100%);
}

.hero-in { position: relative; z-index: 2; }
/* the copy measure sits INSIDE the container, so it starts on the same left
   edge as every other row rather than centring itself in the page */
.hero-copy { max-width: 700px; }

.hero-h {
  font-size: clamp(36px, 4.5vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin: 0 0 28px;
  text-wrap: balance;
}
/* the headline rises INTO place out of its mask — nothing on this page falls */
.line-mask { display: block; overflow: hidden; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.line { display: block; }

.hero-lede {
  font-size: 19px; line-height: 1.6; color: var(--muted);
  margin: 0 0 36px; max-width: 520px; text-wrap: pretty;
}

.hero-acts { display: flex; align-items: center; flex-wrap: wrap; gap: 20px 28px; }

/* trust strip — same .wrap as everything else, so it lines up with the copy above */
.hero-strip {
  position: relative; z-index: 2;
  margin-top: clamp(44px, 5.5vw, 76px);
  padding-top: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
}
.hero-fact {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 24px 28px 30px;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.hero-fact:first-child { padding-left: 0; border-left: 0; }
.hero-fact:last-child { padding-right: 0; }
.hero-ic { width: 22px; height: 22px; flex-shrink: 0; color: var(--ink); margin-top: 1px; }
.hero-fact-h { margin: 0; font-size: 15px; font-weight: 600; }
.hero-fact-p { margin: 5px 0 0; font-size: 14px; line-height: 1.5; color: var(--muted); }

/* ==========================================================================
   SECTIONS
   ========================================================================== */
.sect { padding-block: var(--sect); border-top: 1px solid var(--line); }
.sect-cta { padding-block: var(--sect-lg); }

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: clamp(40px, 5vw, 60px);
  align-items: start;
}

/* ---------- 7-stage protocol ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0;
  margin-top: 64px;
  border-top: 1px solid var(--line);
}
.step { padding: 26px 18px 0; border-right: 1px solid var(--line); }
.step:first-child { padding-left: 0; }
.step:last-child { padding-right: 0; border-right: 0; }
.step-k {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.14em;
  text-transform: uppercase; margin: 0 0 10px;
}
.step-p { font-size: 14px; line-height: 1.55; color: var(--muted); margin: 0; }

@media (max-width: 1120px) {
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .step { padding: 26px 18px; border-bottom: 1px solid var(--line); }
  .step:first-child { padding-left: 0; }
  .step:last-child { border-right: 0; }
  .step:nth-child(4n) { border-right: 0; padding-right: 0; }
  .step:nth-child(4n + 1) { padding-left: 0; }
}

/* ---------- security gates ---------- */
.gates {
  display: grid; gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
}
.gate { background: var(--card); padding: 32px; }
.gate-k {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--muted); margin: 0 0 12px;
}
.gate-p { font-size: 16px; line-height: 1.6; margin: 0; }

/* ---------- FAQ ---------- */
.faq { margin-top: 4px; }
.faq-item { border-top: 1px solid var(--line); }
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-item summary {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 20px;
  padding: 18px 0; cursor: pointer; list-style: none;
  font-size: 16px; font-weight: 600; line-height: 1.4;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-ic {
  position: relative; flex-shrink: 0; width: 13px; height: 13px; margin-top: 5px;
}
.faq-ic::before, .faq-ic::after {
  content: ""; position: absolute; inset: 50% 0 auto; height: 1.5px; background: var(--ink);
  transition: transform 0.2s var(--ease);
}
.faq-ic::after { transform: rotate(90deg); }
.faq-item[open] .faq-ic::after { transform: rotate(0deg); }
.faq-item p {
  font-size: 15px; line-height: 1.6; color: var(--muted);
  margin: 0; padding: 0 0 18px; max-width: 58ch;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.foot {
  position: relative;
  border-top: 1px solid var(--line);
  background: var(--bg);
  /* the clip that cuts the wordmark off at the bottom of the page */
  overflow: hidden;
}

.foot-in { padding-block: clamp(72px, 8vw, 104px) 0; }

.foot-top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.85fr);
  gap: clamp(40px, 6vw, 88px);
  padding-bottom: clamp(48px, 6vw, 72px);
}
.foot-lead { max-width: 420px; }
.foot-h {
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.08; letter-spacing: -0.025em; font-weight: 600;
  margin: 0 0 18px; text-wrap: balance;
}
.foot-lede { font-size: 15px; line-height: 1.6; color: var(--muted); margin: 0 0 28px; }
.foot-acts { display: flex; gap: 12px; flex-wrap: wrap; }
.foot-acts .btn { padding: 14px 26px; font-size: 15px; }

.foot-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px 24px;
}
.foot-col { display: flex; flex-direction: column; gap: 12px; }
.foot-k {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--muted);
  margin: 0 0 4px; font-weight: 400;
}
.foot-col a { font-size: 15px; color: var(--muted); transition: color 0.15s var(--ease); }
.foot-col a:hover { color: var(--ink); }

/* status band — one row, four equal cells, flush to the container edges */
.foot-status {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
}
.foot-stat { background: var(--bg); padding: 20px 22px; }
.foot-stat-h { margin: 0 0 6px; display: flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 600; }
.foot-stat-p { margin: 0; font-size: 13px; line-height: 1.5; color: var(--muted); }
.foot-stat-k {
  margin: 0 0 6px; font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted);
}
.foot-stat-v { margin: 0; font-family: var(--mono); font-size: 14px; text-transform: uppercase; }

.pulse {
  width: 8px; height: 8px; border-radius: 50%; background: #3d9a5f; flex-shrink: 0;
  animation: tp-pulse 2.6s ease-in-out infinite;
}
@keyframes tp-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }

.foot-meta {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 16px 28px;
  margin-top: clamp(32px, 4vw, 48px);
  padding-block: 22px;
  border-top: 1px solid var(--line);
  font-size: 13px; color: var(--muted);
}
.foot-copy, .foot-motto { margin: 0; }
.foot-legal { display: flex; gap: 22px; flex-wrap: wrap; }
.foot-legal a:hover { color: var(--ink); }
.foot-motto { font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; }

/* ---------- the cut-off wordmark ----------
   Sits inside the footer's overflow:hidden box and is pushed past the bottom
   edge, so the lower third of the letterforms is sliced clean off by the end
   of the page. Nothing falls, nothing animates — it is just cropped. */
.foot-mark {
  margin-top: clamp(18px, 2.6vw, 34px);
  /* sized against the container, so the wordmark is exactly as wide as every
     other row on the page instead of tracking the raw viewport */
  container-type: inline-size;
  pointer-events: none;
  user-select: none;
}
.foot-mark span {
  display: block;
  text-align: center;
  font-size: 21cqw;              /* "Torchpass" ≈ the full container width */
  line-height: 0.74;
  font-weight: 600;
  letter-spacing: -0.045em;
  white-space: nowrap;
  color: var(--ink);
  opacity: 0.13;
  /* the crop — the last third of the letterforms runs past the footer's
     bottom edge, which is overflow:hidden, so the page ends mid-glyph */
  margin-bottom: -0.235em;
}
:root.dark .foot-mark span { opacity: 0.16; }

@media (max-width: 900px) {
  .foot-top { grid-template-columns: 1fr; }
  .foot-lead { max-width: none; }
  .foot-acts .btn { flex: 1 1 auto; }
  .foot-cols { grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); }
  .foot-status { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-meta { flex-direction: column; align-items: flex-start; gap: 14px; }
  /* a shallower slice on a phone — a deep crop leaves the word unreadable at
     the width a 390px container gives it */
  .foot-mark span { font-size: 22cqw; margin-bottom: -0.185em; }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 820px) {
  :root { --sect: clamp(72px, 12vw, 96px); }

  .hero {
    min-height: auto;
    padding-top: calc(var(--hdr-h) + 56px);
    padding-bottom: 8px;
    justify-content: flex-start;
  }
  /* the fan becomes a faint full-bleed backdrop rather than a right-hand panel */
  .hero-field { width: 100%; opacity: 0.42; }
  .hero-wash { width: 100%; background: linear-gradient(180deg, var(--bg) 8%, color-mix(in srgb, var(--bg) 62%, transparent) 55%, var(--bg) 100%); }
  .hero-copy { max-width: none; }
  .hero-h { font-size: clamp(34px, 8.4vw, 46px); }
  .hero-lede { font-size: 17px; max-width: none; }
  .hero-acts .btn { flex: 1 1 auto; }

  /* trust facts stack — this is where the prototype's absolute strip collided
     with the CTAs on a phone */
  .hero-strip { grid-template-columns: 1fr; }
  .hero-fact { padding: 20px 0 22px; border-left: 0; }
  .hero-fact:first-child { padding-left: 0; }

  .link-go { font-size: 15px; }
  .gate { padding: 24px 22px; }
}

/* horizontal rails on small screens, mirroring the prototype's [data-slide-row] */
@media (max-width: 820px) {
  [data-rail] {
    display: flex !important;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: var(--pad);
    gap: 12px;
    margin-inline: calc(var(--pad) * -1);
    padding: 14px var(--pad);
    border: 0 !important;
    background: none !important;
    scrollbar-width: none;
  }
  [data-rail]::-webkit-scrollbar { display: none; }
  [data-rail] > * {
    flex: 0 0 78%;
    min-width: 0;
    scroll-snap-align: start;
    box-sizing: border-box;
    padding: 24px 20px !important;
    border: 1px solid var(--line) !important;
    border-radius: 4px;
    background: var(--card) !important;
  }
  .steps { margin-top: 40px; }
  .sect-go { margin-top: 32px; }
}

@media (max-width: 400px) {
  .hdr-word { font-size: 13px; letter-spacing: 0.24em; }
  .hdr-theme { display: none; }
}

/* ==========================================================================
   MOTION
   ========================================================================== */
/* Pre-hide only when GSAP is actually going to run, so a failed CDN fetch
   can never leave the page blank. site.js adds .tp-anim synchronously. */
.tp-anim .hero-rise,
.tp-anim [data-reveal],
.tp-anim [data-stagger] > * { opacity: 0; }
.tp-anim .line { transform: translateY(102%); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .tp-anim .hero-rise,
  .tp-anim [data-reveal],
  .tp-anim [data-stagger] > * { opacity: 1; }
  .tp-anim .line { transform: none; }
}

@media print {
  .hdr, .mob, .hero-field, .hero-wash, .foot-mark, .skip { display: none !important; }
  .hero { padding-top: 0; min-height: auto; }
}
