/* KeenHand — "One Night of Work" · draft 2026-07-10
   Binding brand reference: Night Shift brand sheet (approved 2026-07-09).
   Sanctioned pairings only · ≤8% Lamplight · no gradients, no glows, no purple. */

@font-face {
  font-family: 'Archivo';
  src: url('fonts/archivo-var-latin.woff2') format('woff2');
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  /* Night system */
  --char: #191C21;
  --iron: #2A2F37;
  --bone: #E7E4DC;
  --lamp: #EFB644;
  --patina: #7FB5A8;
  --fog: #8B919B;
  --ember: #E08573; /* alerts only — unused on this page by design */
  --line: #333944;
  /* Daylight system */
  --paper: #F4F2EC;
  --card: #FFFFFF;
  --soot: #1E1B16;
  --lamp-deep: #7A5509;
  --patina-deep: #35695D;
  --paper-line: #DAD5C8;
  --paper-muted: #6E675A;
  /* Live tokens — the scroll engine retunes these as night turns to day.
     Defaults are the night values, so the page is correct without JS. */
  --sky: #191C21;
  --ink: #E7E4DC;
  --mut: #8B919B;
  --lin: #333944;
  --kick: #EFB644;
  --gh: #2A2F37;
}

* { box-sizing: border-box; }

html { color-scheme: dark; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--char);
  color: var(--bone);
  font: 400 1.02rem/1.65 'Archivo', ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- utilities ---------- */

.tnum { font-variant-numeric: tabular-nums; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -999px; top: 0;
  background: var(--lamp); color: var(--char);
  padding: .6rem 1rem; font-weight: 700; border-radius: 0 0 7px 0; z-index: 99;
}
.skip:focus { left: 0; }

:focus-visible { outline: 3px solid var(--patina); outline-offset: 2px; }
[data-ground="paper"] :focus-visible { outline-color: var(--patina-deep); }

::selection { background: var(--lamp); color: var(--char); }

/* ---------- nav ---------- */

.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 1rem;
  background: var(--char);
  border-bottom: 1px solid var(--line);
  padding: .7rem clamp(1rem, 4vw, 2rem);
}

.wordmark {
  margin: 0;
  font-weight: 800; font-stretch: 110%;
  font-size: 1.1rem; letter-spacing: -.02em;
  color: var(--bone);
}
.wm-dot { color: var(--lamp); }

.nav-clock {
  margin: 0 auto;
  display: inline-flex; align-items: center; gap: .45rem;
  font-weight: 600; font-size: .85rem;
  font-variant-numeric: tabular-nums;
  color: var(--bone);
  border: 1px solid var(--line); border-radius: 99px;
  padding: .28rem .8rem;
  white-space: nowrap;
}
.nav-clock .clock-label {
  color: var(--fog); font-size: .72rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
}

.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--lamp); flex: none; }
.dot--fog { background: var(--fog); }
.dot--patina { background: var(--patina); }
.dot--patina-deep { background: var(--patina-deep); }

/* nav orb: fog moon by night, amber sun by day — the lamp is lit in both */
.orb { position: relative; width: 13px; height: 13px; flex: none; }
.orb-moon, .orb-sun { position: absolute; inset: 0; border-radius: 50%; }
.orb-moon { background: var(--fog); overflow: hidden; }
.orb-moon::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: var(--char); transform: translate(30%, -16%);
}
.orb-sun { background: var(--lamp); opacity: 0; transform: scale(.5); }
html.day .orb-moon { opacity: 0; }
html.day .orb-sun { opacity: 1; transform: none; }
@media (prefers-reduced-motion: no-preference) {
  .orb-moon, .orb-sun { transition: opacity .45s ease, transform .45s ease; }
}

.nav-cta {
  color: var(--patina); font-weight: 600; font-size: .88rem;
  text-decoration: none; white-space: nowrap;
}
.nav-cta:hover { text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 600px) {
  .nav-cta { display: none; } /* hero CTA is on the first screen */
}

/* ---------- scenes (shared) ---------- */

.scene {
  padding: clamp(4rem, 11vh, 7.5rem) clamp(1.25rem, 5vw, 2.5rem);
  border-top: 1px solid var(--line);
}
.scene > .inner { max-width: 960px; margin: 0 auto; }

.scene[data-ground="iron"] { background: var(--iron); }
.scene[data-ground="paper"] {
  background: var(--paper); color: var(--soot);
  border-top: none;
}
.scene[data-ground="paper"] + .scene[data-ground="paper"] { padding-top: 0; }

.kicker {
  margin: 0 0 1rem;
  font-size: .74rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--lamp);
}
[data-ground="paper"] .kicker { color: var(--lamp-deep); }

.ruler {
  height: 9px; margin-bottom: 1.6rem;
  background: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 14px);
}
[data-ground="paper"] .ruler {
  background: repeating-linear-gradient(90deg, var(--paper-line) 0 1px, transparent 1px 14px);
}

.scene-time {
  margin: 0 0 -.14em -.06em;
  font-weight: 900; font-stretch: 125%;
  font-size: clamp(4.2rem, 15vw, 10rem);
  line-height: .9; letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
  color: var(--iron);
  user-select: none;
}
.scene-time small {
  font-size: .32em; font-weight: 800; font-stretch: 110%;
  letter-spacing: 0; vertical-align: .28em; margin-left: .12em;
}
[data-ground="iron"] .scene-time { color: var(--line); }
[data-ground="paper"] .scene-time { color: var(--paper-line); }

.scene h1, .scene h2 {
  margin: 0 0 1rem;
  font-weight: 800; font-stretch: 110%;
  letter-spacing: -.02em; line-height: 1.06;
  text-wrap: balance;
  position: relative; z-index: 1;
}
h1 { font-size: clamp(2.5rem, 6.5vw, 4.4rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-weight: 700; letter-spacing: -.01em; }

.scene p { max-width: 62ch; }
.lede { font-size: clamp(1.05rem, 2vw, 1.2rem); color: var(--bone); }
.muted { color: var(--fog); }
[data-ground="paper"] .muted { color: var(--paper-muted); }

.micro {
  font-size: .82rem; color: var(--fog);
  max-width: 52ch;
}
[data-ground="paper"] .micro { color: var(--paper-muted); }

/* ---------- hero ---------- */

.hero {
  border-top: none;
  min-height: calc(92vh - 56px);
  display: flex; align-items: center;
}

.chips {
  list-style: none; display: flex; flex-wrap: wrap; gap: .55rem;
  padding: 0; margin: 1.6rem 0 2.2rem;
}
.chips li {
  font-size: .78rem; font-weight: 600;
  color: var(--bone); background: var(--iron);
  border: 1px solid var(--line); border-radius: 99px;
  padding: .34rem .8rem;
}

.cta-row { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; margin: 0 0 .8rem; }

.btn {
  display: inline-block;
  background: var(--lamp); color: var(--char);
  font-weight: 700; font-size: .95rem;
  padding: .78rem 1.4rem; border-radius: 7px;
  border: none; cursor: pointer;
  text-decoration: none;
  font-family: inherit;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
[data-ground="paper"] .btn { color: var(--soot); }

.scroll-hint {
  margin-top: clamp(2.5rem, 7vh, 4.5rem);
  font-size: .8rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--fog);
}

/* ---------- console card (9:41 PM) ---------- */

.console-fig { margin: 2.2rem 0 0; position: relative; z-index: 1; }
.console-fig figcaption, .report-fig figcaption {
  font-size: .78rem; color: var(--fog);
  margin-bottom: .6rem;
}
.report-fig figcaption { color: var(--paper-muted); }

.console-card {
  max-width: 640px;
  background: var(--iron);
  border: 1px solid var(--line); border-radius: 9px;
  padding: 1.3rem 1.4rem 1.15rem;
  display: flex; flex-direction: column; gap: .9rem;
}
[data-ground="iron"] .console-card { background: var(--char); }

.console-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  font-size: .74rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--fog);
}
.console-head time { font-variant-numeric: tabular-nums; color: var(--bone); }

.msg {
  background: var(--char);
  border: 1px solid var(--line); border-radius: 7px;
  padding: .85rem 1rem;
  font-size: .93rem;
}
.console-card .msg { max-width: none; margin: 0; }
.msg .msg-label {
  display: block; font-size: .68rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--fog); margin-bottom: .3rem;
}
.msg--draft { border-left: 3px solid var(--patina); }

.pill {
  display: inline-flex; align-items: center; gap: .45rem;
  font-size: .78rem; font-weight: 600;
  padding: .32rem .75rem; border-radius: 99px;
  background: var(--char); color: var(--bone);
  border: 1px solid var(--line);
  white-space: nowrap;
}
[data-ground="iron"] .pill, .console-card .pill { background: var(--iron); }
.console-card .pill { background: var(--char); }

/* drafting → waiting swap (JS adds/removes .drafting; no-JS shows final state) */
.pill-swap { position: relative; display: inline-flex; }
.pill-swap .state-a { display: none; }
.drafting .pill-swap .state-a { display: inline-flex; }
.drafting .pill-swap .state-b { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .pill-swap .state-b { transition: opacity .45s ease; }
}

.instrument {
  font-size: .78rem; color: var(--fog);
  font-variant-numeric: tabular-nums;
  margin: 0;
}

/* ---------- ledger (1:12 AM) ---------- */

.ledger {
  list-style: none; padding: 0;
  margin: 2.2rem 0 0;
  max-width: 720px;
  border: 1px solid var(--line); border-radius: 9px;
  background: var(--iron);
  overflow: hidden;
  position: relative; z-index: 1;
}
.ledger li {
  display: grid;
  grid-template-columns: 5.4rem 1fr auto;
  gap: 1rem; align-items: center;
  padding: .85rem 1.1rem;
  border-bottom: 1px solid var(--line);
  font-size: .93rem;
}
.ledger li:last-child { border-bottom: none; }
.ledger time {
  font-variant-numeric: tabular-nums;
  font-weight: 700; font-size: .82rem;
  color: var(--fog);
  white-space: nowrap;
}
.ledger .pill { font-size: .72rem; padding: .24rem .65rem; }
.ledger-caption { margin-top: .6rem; }

@media (max-width: 560px) {
  .ledger li { grid-template-columns: 1fr auto; }
  .ledger time { grid-column: 1 / -1; }
}

/* ---------- lanes ---------- */

.lanes-head { margin: 3rem 0 .4rem; font-size: 1.05rem; }
.lanes {
  list-style: none; padding: 0; margin: 1rem 0 0;
  display: grid; gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.lanes li {
  background: var(--iron);
  border: 1px solid var(--line); border-radius: 9px;
  padding: 1rem 1.1rem;
}
.lanes h3 { margin: 0 0 .25rem; font-size: .95rem; color: var(--bone); }
.lanes p { margin: 0; font-size: .84rem; color: var(--fog); }

/* ---------- rules (3:07 AM) ---------- */

.rules {
  list-style: none; padding: 0; margin: 2rem 0 0;
  display: grid; gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  max-width: 820px;
  position: relative; z-index: 1;
}
.rules li {
  background: var(--iron);
  border: 1px solid var(--line); border-radius: 9px;
  padding: 1.05rem 1.15rem;
  font-size: .93rem;
  display: grid; grid-template-columns: auto 1fr; gap: .7rem;
}
.rules .tick { color: var(--patina); font-weight: 800; }

.owner-note {
  margin-top: 2.4rem;
  padding-left: 1.1rem;
  border-left: 3px solid var(--patina);
}

/* ---------- dawn beat ---------- */

.dawn { text-align: center; padding-top: clamp(5rem, 14vh, 9rem); padding-bottom: clamp(5rem, 14vh, 9rem); }
.dawn .scene-time { margin: 0 0 .1em; }
.dawn p { max-width: none; margin: .4rem auto 0; }
.dawn .dawn-line {
  font-size: clamp(1.3rem, 2.8vw, 1.75rem);
  font-weight: 700; letter-spacing: -.01em;
}
.dawn-sub {
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  font-weight: 600; color: var(--bone);
}

/* ---------- morning report (7:00 AM) ---------- */

.report-fig { margin: 2.4rem 0 0; position: relative; z-index: 1; }
.report-card {
  max-width: 680px;
  background: var(--card);
  border: 1px solid var(--paper-line); border-radius: 9px;
  overflow: hidden;
}
.report-head {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: 1rem 1.3rem;
  border-bottom: 1px solid var(--paper-line);
}
.report-head .wordmark { color: var(--soot); font-size: 1rem; }
.report-head .report-meta {
  margin: 0; font-size: .74rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--paper-muted);
  font-variant-numeric: tabular-nums;
}

.report-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--paper-line);
}
.report-stats > div {
  padding: 1rem 1.3rem;
  border-right: 1px solid var(--paper-line);
}
.report-stats > div:last-child { border-right: none; }
.report-stats .num {
  display: block;
  font-size: 2rem; font-weight: 800; font-stretch: 110%;
  letter-spacing: -.02em; line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: var(--soot);
}
.report-stats .num--good { color: var(--patina-deep); }
.report-stats .lbl { font-size: .78rem; color: var(--paper-muted); line-height: 1.35; display: block; margin-top: .15rem; }

.report-rows { list-style: none; margin: 0; padding: 0; }
.report-rows li {
  display: grid; grid-template-columns: 4.6rem 1fr auto;
  gap: .9rem; align-items: center;
  padding: .8rem 1.3rem;
  border-bottom: 1px solid var(--paper-line);
  font-size: .9rem; color: var(--soot);
}
.report-rows time { font-variant-numeric: tabular-nums; font-weight: 700; font-size: .8rem; color: var(--paper-muted); }
.day-pill {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .72rem; font-weight: 600;
  padding: .24rem .65rem; border-radius: 99px;
  background: var(--paper); color: var(--soot);
  border: 1px solid var(--paper-line);
  white-space: nowrap;
}
.report-foot { padding: .85rem 1.3rem; }
.report-foot .instrument { color: var(--paper-muted); }

@media (max-width: 560px) {
  .report-stats { grid-template-columns: 1fr; }
  .report-stats > div { border-right: none; border-bottom: 1px solid var(--paper-line); }
  .report-stats > div:last-child { border-bottom: none; }
  .report-rows li { grid-template-columns: 1fr auto; }
  .report-rows time { grid-column: 1 / -1; }
}

/* ---------- missed-revenue calculator ---------- */

.calc {
  margin: 2.4rem 0; max-width: 680px;
  background: var(--card);
  border: 1px solid var(--paper-line); border-radius: 9px;
  padding: 1.3rem 1.4rem 1.1rem;
  position: relative; z-index: 1;
}
.calc h3 { margin: 0 0 .3rem; font-size: 1.02rem; }
.calc-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: .9rem; margin: 1rem 0 .4rem;
}
.calc .field { display: grid; gap: .35rem; align-content: start; }
.calc label {
  font-size: .72rem; font-weight: 700;
  letter-spacing: .05em; text-transform: uppercase;
  color: var(--paper-muted); line-height: 1.35;
}
.calc input {
  font: inherit; color: var(--soot); background: var(--paper);
  border: 1px solid var(--paper-line); border-radius: 7px;
  padding: .6rem .8rem; width: 100%;
  font-variant-numeric: tabular-nums;
}
.calc-out {
  margin: .8rem 0 .5rem;
  display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap;
  max-width: none;
}
.calc-num {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 800; font-stretch: 110%; letter-spacing: -.02em;
  color: var(--soot);
}
.calc-lbl { font-size: .85rem; color: var(--paper-muted); }
@media (max-width: 640px) { .calc-grid { grid-template-columns: 1fr; } }

/* sample test-report extras */
.stat-small { font-size: .45em; font-weight: 800; margin: 0 .08em; }
.report-note { padding: .95rem 1.3rem 0; }
.report-note p { margin: 0; font-size: .9rem; max-width: none; }

/* ---------- intake form ---------- */

.read-form {
  margin-top: 2rem;
  max-width: 560px;
  display: grid; gap: 1rem;
  position: relative; z-index: 1;
}
.read-form .field { display: grid; gap: .35rem; }
.read-form label {
  font-size: .74rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--paper-muted);
}
.read-form input {
  font: inherit; color: var(--soot);
  background: var(--card);
  border: 1px solid var(--paper-line); border-radius: 7px;
  padding: .7rem .9rem;
  width: 100%;
}
.read-form input::placeholder { color: var(--paper-muted); opacity: .75; }
.form-note {
  margin: 0; font-size: .88rem; font-weight: 600;
  color: var(--patina-deep);
}

/* ---------- footer ---------- */

.foot {
  background: var(--char); color: var(--bone);
  border-top: 1px solid var(--line);
  padding: clamp(3.5rem, 9vh, 5.5rem) clamp(1.25rem, 5vw, 2.5rem);
}
.foot .inner { max-width: 960px; margin: 0 auto; }
.foot .wordmark { font-size: 1.35rem; }
.foot-tag { margin: .5rem 0 1.2rem; color: var(--fog); font-size: .95rem; }
.foot-meta {
  margin-top: 2.6rem; padding-top: 1.2rem;
  border-top: 1px solid var(--line);
  font-size: .78rem; color: var(--fog);
  display: grid; gap: .3rem;
}
.foot-meta p { margin: 0; max-width: none; }

/* ---------- motion (enhancement only) ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .6s ease, transform .6s ease;
    transition-delay: var(--d, 0ms);
  }
  .js .reveal.in-view, .js .in-view .reveal { opacity: 1; transform: none; }
  .js .ledger li.reveal { transition-duration: .5s; }
}

@media (prefers-reduced-motion: reduce) {
  .btn:hover, .btn:active { transform: none; }
}

/* ============================================================
   SCRUB MODE — added only by JS when motion is allowed.
   The page background becomes one continuous sky (--sky, a flat
   color interpolated per frame: no rendered gradients), and page-
   level text runs on live tokens that relight at dawn. Without
   this class, the per-section solid grounds above stand as-is.
   ============================================================ */

/* ghost-clock drift is decorative — never a scrollbar (clip, not hidden,
   so the sticky dawn keeps working) */
html.scrub { overflow-x: clip; }
html.scrub body {
  background: transparent; color: var(--ink);
  overflow-x: clip;
}
html.scrub body::before {
  content: ""; position: fixed; inset: 0;
  background: var(--sky); z-index: -1;
}

html.scrub .scene { border-top-color: var(--lin); }
html.scrub .scene[data-ground="iron"],
html.scrub .scene[data-ground="paper"] { background: transparent; }
html.scrub .scene[data-ground="paper"] { color: var(--ink); }

html.scrub .kicker,
html.scrub [data-ground="paper"] .kicker { color: var(--kick); }

html.scrub .muted,
html.scrub [data-ground="paper"] .muted,
html.scrub .micro,
html.scrub [data-ground="paper"] .micro,
html.scrub .scroll-hint,
html.scrub .console-fig figcaption,
html.scrub .report-fig figcaption,
html.scrub .instrument,
html.scrub .ledger time,
html.scrub .lanes p,
html.scrub .msg .msg-label,
html.scrub .console-head { color: var(--mut); }
html.scrub .console-head time { color: var(--ink); }
html.scrub .lanes h3 { color: var(--ink); }

html.scrub .scene-time,
html.scrub [data-ground="iron"] .scene-time,
html.scrub [data-ground="paper"] .scene-time { color: var(--gh); }

html.scrub .ruler,
html.scrub [data-ground="paper"] .ruler {
  background: repeating-linear-gradient(90deg, var(--lin) 0 1px, transparent 1px 14px);
}

/* the relight moment eases rather than snaps */
html.scrub .scene, html.scrub .scene[data-ground="paper"],
html.scrub .kicker, html.scrub [data-ground="paper"] .kicker,
html.scrub .muted, html.scrub .micro, html.scrub .scroll-hint,
html.scrub .console-fig figcaption, html.scrub .report-fig figcaption,
html.scrub .instrument, html.scrub .ledger time, html.scrub .lanes p,
html.scrub .lanes h3, html.scrub .scene-time, html.scrub .dawn-sub {
  transition: color .45s ease;
}

/* the footer stays night — the bookend */
html.scrub .foot { background: var(--char); }

/* ---------- celestial layer (JS-built, scrub mode only) ----------
   Flat discs and dots — no glows, no gradients. Stars twinkle and fade
   at dawn, the moon sets through the night, the sun rises with the sky. */
.sky {
  position: fixed; inset: 0; z-index: -1;
  pointer-events: none; overflow: clip;
}
.star {
  position: absolute; border-radius: 50%;
  background: var(--bone);
  animation: twinkle var(--tw, 3.2s) ease-in-out var(--twd, 0s) infinite alternate;
}
@keyframes twinkle {
  from { opacity: .14; }
  to   { opacity: .68; }
}
.sky-moon {
  position: absolute; top: 12vh; right: 11vw;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--fog); overflow: hidden;
}
.sky-moon::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: var(--char); transform: translate(26%, -14%);
}
.sky-sun {
  position: absolute; top: 0; right: 9vw;
  width: 64px; height: 64px;
  opacity: 0;
}
.sky-sun::before {
  content: ""; position: absolute; inset: 0;
  border-radius: 50%; background: var(--lamp);
}
.sun-rays {
  position: absolute; inset: 0;
  animation: sunspin 90s linear infinite;
}
@keyframes sunspin { to { transform: rotate(360deg); } }
.ray {
  position: absolute; left: 50%; top: 50%;
  width: 3px; height: 13px; margin: -6.5px 0 0 -1.5px;
  border-radius: 2px; background: var(--lamp);
  transform: rotate(var(--ra, 0deg)) translateY(var(--rayd, -46px));
}
.stars { position: absolute; inset: 0; }
.sky-moon, .sky-sun { transition: opacity .4s ease; }
@media (max-width: 700px) {
  .sky-moon { width: 40px; height: 40px; right: 9vw; }
  .sky-sun { width: 46px; height: 46px; }
  .ray { height: 10px; --rayd: -34px; }
}

/* hero parallax (engine drives --heroY / --heroO) */
html.scrub .hero .inner {
  transform: translateY(var(--heroY, 0px));
  opacity: var(--heroO, 1);
  will-change: transform, opacity;
}

/* ghost clocks drift as they pass (engine drives --gx) */
html.scrub .scene-time {
  transform: translateX(var(--gx, 0px));
  will-change: transform;
}

/* the drafted reply types itself in */
.caret { display: none; }
.typing .caret {
  display: inline-block; width: .5em; height: 1.05em;
  background: var(--patina);
  vertical-align: -.18em; margin-left: 2px;
}

/* ledger rows stamp in (reversible on scroll-back) */
html.scrub .stamp {
  opacity: 0; transform: translateX(-16px);
  transition: opacity .45s ease, transform .45s ease;
}
html.scrub .stamp.stamped { opacity: 1; transform: none; }

/* dawn becomes a held beat: the text pins while the sky turns */
html.scrub .dawn { min-height: 220vh; padding-top: 16vh; padding-bottom: 0; }
html.scrub .dawn .inner { position: sticky; top: 26vh; padding-bottom: 3rem; }
html.scrub .dawn-sub { color: var(--ink); }

/* time rail (desktop): the night, hour by hour */
.rail { display: none; }
@media (min-width: 1100px) {
  html.scrub .rail {
    display: flex; flex-direction: column; gap: 1.05rem;
    position: fixed; right: 1.3rem; top: 50%;
    transform: translateY(-50%); z-index: 15;
  }
}
.rail a {
  display: flex; align-items: center; justify-content: flex-end; gap: .55rem;
  text-decoration: none;
  font-size: .72rem; font-weight: 600; letter-spacing: .04em;
  font-variant-numeric: tabular-nums;
  color: var(--mut);
  transition: color .45s ease;
}
.rail a::after {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--mut); flex: none;
  transition: background .45s ease;
}
.rail a.active { color: var(--ink); }
.rail a.active::after { background: var(--kick); }
.rail .lbl { opacity: 0; transition: opacity .25s ease; }
.rail a.active .lbl, .rail:hover .lbl, .rail a:focus-visible .lbl { opacity: 1; }

/* ---------- launch chrome: links, honeypot, subpages ---------- */

.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

[data-ground="paper"] .micro a, .report-note a { color: var(--patina-deep); }
.foot-meta a, .scene a:not(.btn) { color: var(--patina); }
.foot-meta a:hover, [data-ground="paper"] .micro a:hover { text-decoration-thickness: 2px; }

.btn:disabled { opacity: .55; cursor: default; transform: none; }

/* static subpages (privacy, thanks, 404) — night ground, no scroll engine */
.subpage main {
  max-width: 720px; margin: 0 auto;
  padding: clamp(3rem, 8vh, 5rem) clamp(1.25rem, 5vw, 2.5rem) 4rem;
}
.subpage h1 { font-size: clamp(1.9rem, 5vw, 2.8rem); margin-bottom: 1rem; }
.subpage h2 { font-size: 1.15rem; margin-top: 2.2rem; }
.subpage p, .subpage li { max-width: 62ch; }
.subpage a:not(.btn) { color: var(--patina); }
.subpage .nav-home { color: var(--patina); font-weight: 600; font-size: .88rem; text-decoration: none; }
.subpage .nav-home:hover { text-decoration: underline; text-underline-offset: 3px; }
.subpage .scene-time { color: var(--iron); }
.subpage ol.steps { padding-left: 1.2rem; display: grid; gap: .6rem; }

/* ---------- /links/ — link-in-bio page ---------- */
.linklist { list-style: none; padding: 0; margin: 2rem 0 0; display: grid; gap: .7rem; max-width: 560px; }
.linkrow {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: .2rem .8rem;
  background: var(--iron); border: 1px solid var(--line); border-radius: 9px;
  padding: .9rem 1.1rem; text-decoration: none; color: var(--bone);
}
a.linkrow:hover { border-color: var(--fog); }
.linkrow-name { font-weight: 700; font-size: .98rem; color: var(--bone); grid-column: 1; }
.linkrow-sub { font-size: .82rem; color: var(--fog); grid-column: 1; }
.linkrow .pill { grid-column: 2; grid-row: 1 / span 2; }
.linkrow--primary { background: var(--lamp); border-color: var(--lamp); }
.linkrow--primary .linkrow-name, .linkrow--primary .linkrow-sub { color: var(--char); }
.linkrow.pending { opacity: .75; }
.soon-pill { font-size: .7rem; }
