/* ==========================================================
   Story layer: editorial, full-screen, scroll-choreographed.
   Palette and type are inherited from styles.css tokens.
   ========================================================== */
:root {
  --text-mega: clamp(3.2rem, 0.6rem + 8.4vw, 10.5rem);
  --text-giant: clamp(2.6rem, 0.8rem + 5.6vw, 7.4rem);
  --text-number: clamp(4.2rem, 1rem + 10vw, 12.5rem);
  --rail-space: clamp(0px, 4vw, 56px);
  --night-red: #ff6a50;
  --night-red-soft: #ff8a73;
  --night-amber: #e0a100;
}

body { background: var(--paper); }
main { max-width: none; padding: 0; position: relative; z-index: 1; }
.topbar { z-index: 30; }
.field { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }

.kicker { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.kicker-green { color: var(--green-ink); }

/* ---------- Pop: insights "activate" ---------- */
.pop {
  opacity: 0; transform: translate3d(0, 24px, 0) scale(0.95); filter: blur(12px);
  transition: opacity 900ms var(--ease-out), transform 1100ms var(--ease-out), filter 900ms var(--ease-out);
}
.pop.is-on { opacity: 1; transform: none; filter: none; }

.scene { position: relative; }
.scene .sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }

/* ---------- Chapter rail ---------- */
.rail {
  position: fixed; left: 18px; top: 50%; transform: translateY(-50%); z-index: 25;
  display: grid; gap: 12px; padding: 14px 10px; border-radius: 999px;
  background: rgba(243, 240, 232, 0.72); backdrop-filter: blur(10px); border: 1px solid var(--line);
}
.rail.is-away { display: none; }
.rail button { display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 2px; color: var(--ink-2); }
.rail i { width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--ink-2); transition: transform 300ms var(--ease-out), background 300ms, border-color 300ms; }
.rail span { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase; width: 0; overflow: hidden; opacity: 0; transition: opacity 300ms; white-space: nowrap; }
.rail:hover span, .rail:focus-within span { width: auto; opacity: 1; }
.rail button.is-active i { background: var(--green); border-color: var(--green); transform: scale(1.5); }
.rail button.is-active span { color: var(--ink); }

/* ---------- Hero: the opening film ---------- */
.hero {
  min-height: calc(100svh - 62px); max-width: 1440px; margin: 0 auto;
  padding: 7vh var(--gutter) 14vh calc(var(--gutter) + var(--rail-space));
  display: flex; flex-direction: column; justify-content: center; position: relative;
}
.hero-eyebrow { opacity: 0; transition: opacity 1s var(--ease-out) 200ms; }
body.is-ready .hero-eyebrow { opacity: 1; }
.hero-title {
  font-family: var(--font-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.8rem, 0.4rem + 7.4vw, 9rem); line-height: 0.9; letter-spacing: -0.01em;
  margin: 3vh 0 0; display: grid;
}
.hl { display: block; overflow: hidden; padding-bottom: 0.05em; }
.hl-in { display: inline-block; transform: translate3d(0, 108%, 0); transition: transform 1300ms var(--ease-out); }
.hl:nth-child(2) .hl-in { transition-delay: 140ms; }
.hl-energy .hl-in { transition-delay: 820ms; color: var(--ink-2); }
body.is-ready .hl-in { transform: none; }
.hl-energy { margin-top: 0.08em; }
.glow-word { color: var(--green-ink); }
.glow-word span { display: inline-block; animation: glow 3.6s ease-in-out infinite; animation-delay: calc(var(--i) * 140ms + 1.6s); }
@keyframes glow {
  0%, 100% { color: var(--green-ink); text-shadow: none; transform: none; }
  45% { color: var(--green); text-shadow: 0 0 34px rgba(61, 205, 88, 0.55); transform: translate3d(0, -0.035em, 0); }
}

.ask {
  margin-top: 7vh; display: flex; align-items: center; gap: 14px; max-width: 920px;
  border-bottom: 2px solid var(--ink); padding-bottom: 12px;
  opacity: 0; transform: translate3d(0, 16px, 0); transition: opacity 900ms var(--ease-out) 1400ms, transform 900ms var(--ease-out) 1400ms;
}
body.is-ready .ask { opacity: 1; transform: none; }
.ask:focus-within { border-color: var(--green-ink); }
#ambition {
  flex: 1; min-width: 0; border: 0; outline: none; background: transparent; resize: none; overflow: hidden;
  font-family: var(--font-display); font-size: clamp(1.4rem, 1rem + 1.2vw, 2.2rem); line-height: 1.2; color: var(--ink);
  field-sizing: content; max-height: 3.8em; padding: 6px 0;
}
#ambition::placeholder { color: rgba(18, 22, 20, 0.32); }
.count { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); }
.mic { width: 44px; height: 44px; border: 1px solid var(--line-strong); color: var(--ink-2); position: relative; flex: none; }
.mic svg { width: 18px; height: 18px; }
.mic.is-listening { color: #fff; background: var(--risk); border-color: var(--risk); }
.mic.is-listening::after { content: ''; position: absolute; inset: -1px; border-radius: 50%; border: 2px solid var(--risk); animation: ping 1.2s var(--ease-out) infinite; }
.ask-go {
  flex: none; display: inline-flex; align-items: center; gap: 10px; border: 0; cursor: pointer;
  background: var(--ink); color: var(--paper); padding: 14px 22px; border-radius: 999px; font-weight: 600;
  transition: background 250ms, transform 250ms var(--ease-out);
}
.ask-go svg { width: 18px; height: 18px; transition: transform 250ms var(--ease-out); }
.ask-go:hover { background: var(--green-ink); }
.ask-go:hover svg { transform: translateX(4px); }
.ask-go:active { transform: scale(0.97); }
.ask-go.is-busy { background: var(--green); color: var(--night); animation: busy 900ms ease-in-out infinite; }
@keyframes busy { 50% { transform: scale(0.96); } }

.examples { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 20px; opacity: 0; transition: opacity 900ms 1700ms; }
body.is-ready .examples { opacity: 1; }
.chip {
  border: 0; background: none; padding: 4px 0; color: var(--muted); font-size: 0.9rem;
  border-bottom: 1px solid transparent; transition: color 200ms, border-color 200ms;
}
.chip:hover, .chip:focus-visible { color: var(--ink); border-color: var(--green); }

.scroll-cue {
  position: absolute; left: calc(var(--gutter) + var(--rail-space)); bottom: 5vh;
  display: flex; align-items: center; gap: 14px; font-family: var(--font-mono); font-size: 0.7rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.scroll-cue i { width: 64px; height: 1px; background: var(--line-strong); position: relative; overflow: hidden; }
.scroll-cue i::after { content: ''; position: absolute; inset: 0; background: var(--green); transform: translateX(-100%); animation: cue 2.2s var(--ease-out) infinite; }
@keyframes cue { to { transform: translateX(100%); } }

/* ---------- Translation: business → energy ---------- */
.scene-tx { height: 430vh; }
.scene-tx .sticky {
  display: grid; grid-template-columns: 1fr minmax(60px, 12vw) 1fr; align-items: center; gap: 2vw;
  padding: 0 var(--gutter) 0 calc(var(--gutter) + var(--rail-space));
}
.tx-business { opacity: var(--fade, 1); }
.tx-ambition {
  font-family: var(--font-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.2rem, 0.8rem + 4vw, 5.8rem); line-height: 0.95; margin-top: 2vh;
}
.word { display: inline-block; white-space: nowrap; }
.ch { display: inline-block; will-change: transform, opacity; transition: color 500ms; }
.ch.is-energised { color: var(--green); }
.tx-meta { font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-top: 3vh; }
.tx-flow { width: 100%; height: 56vh; opacity: 0; overflow: visible; }
.tx-flow-line { fill: none; stroke: rgba(61, 205, 88, 0.4); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.tx-flow-dot { fill: var(--green); }
.tx-rows { list-style: none; margin: 2.4vh 0 0; padding: 0; display: grid; gap: 2.6vh; }
.tx-row {
  display: grid; grid-template-columns: auto 1fr; column-gap: 0.4em; align-items: end;
  opacity: 0; transform: translate3d(0, 26px, 0) scale(0.95); filter: blur(10px);
  transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out), filter 700ms var(--ease-out);
}
.tx-row[data-stage="1"], .tx-row[data-stage="2"] { opacity: 1; transform: none; filter: none; }
.tx-plus { font-family: var(--font-display); color: var(--green-ink); font-size: clamp(1.6rem, 1rem + 2vw, 3rem); line-height: 1; }
.tx-word, .tx-val { grid-column: 2; grid-row: 1; font-family: var(--font-display); line-height: 0.95; }
.tx-word {
  text-transform: uppercase; font-size: clamp(2rem, 0.8rem + 3.4vw, 4.6rem);
  transition: opacity 500ms var(--ease-out), transform 600ms var(--ease-out), filter 500ms;
}
.tx-row[data-stage="2"] .tx-word { opacity: 0; transform: translate3d(0, -40%, 0); filter: blur(8px); }
.tx-val { font-size: clamp(1.9rem, 0.8rem + 3vw, 4.2rem); opacity: 0; white-space: nowrap; transition: opacity 400ms; }
.tx-val::before {
  content: attr(data-word); display: block; font-family: var(--font-mono); font-size: 0.7rem;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--green-ink); margin-bottom: 0.7em;
}
.tx-row[data-stage="2"] .tx-val { opacity: 1; }
.is-lead .tx-word { font-size: clamp(2.6rem, 1rem + 5vw, 6.4rem); }
.is-lead .tx-val { font-size: clamp(3rem, 1rem + 6.6vw, 8.8rem); color: var(--green-ink); letter-spacing: -0.02em; }
.tx-done { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4vh; opacity: 0; transform: translate3d(0, 12px, 0); transition: opacity 600ms, transform 600ms var(--ease-out); }
.tx-done.is-on { opacity: 1; transform: none; }
.chip-btn {
  border: 1px solid var(--line-strong); background: rgba(251, 250, 246, 0.8); border-radius: 999px;
  padding: 9px 16px; font-size: 0.86rem; color: var(--ink); transition: background 200ms, color 200ms, border-color 200ms;
}
.chip-btn:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.tx-progress { position: absolute; left: calc(var(--gutter) + var(--rail-space)); right: var(--gutter); bottom: 5vh; height: 2px; background: var(--line); }
.tx-bar { display: block; height: 100%; background: var(--green); transform-origin: left; transform: scaleX(0); }

/* ---------- Energy moments ---------- */
.moment { height: 185vh; }
.moment .sticky {
  display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 4vw;
  padding: 0 var(--gutter) 0 calc(var(--gutter) + var(--rail-space));
}
.moment.is-flip .m-visual { order: 2; }
.m-watermark {
  position: absolute; left: 0; right: 0; bottom: 4vh; margin: 0; text-align: center; z-index: 0; pointer-events: none;
  font-family: var(--font-display); text-transform: uppercase; white-space: nowrap;
  font-size: clamp(6rem, 1rem + 20vw, 24rem); line-height: 0.8;
  color: transparent; -webkit-text-stroke: 1px rgba(18, 22, 20, 0.08);
}
.m-visual { position: relative; z-index: 1; height: 64vh; display: grid; place-items: center; }
.m-copy { position: relative; z-index: 2; }
.m-number {
  font-family: var(--font-display); font-size: var(--text-number); line-height: 0.84; letter-spacing: -0.03em;
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.1em;
}
.m-number small { font-family: var(--font-mono); font-size: clamp(1rem, 0.6rem + 1vw, 1.6rem); color: var(--muted); letter-spacing: 0; }
.m-number.is-word { font-size: clamp(2.6rem, 1rem + 4.6vw, 6rem); line-height: 0.95; }
.m-label { font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--green-ink); margin-top: 2.4vh; }
.m-more {
  margin-top: 3vh; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line-strong);
  background: transparent; font-size: 1.3rem; line-height: 1; color: var(--ink);
  transition: transform 300ms var(--ease-out), background 200ms, color 200ms;
}
.m-more:hover { background: var(--ink); color: var(--paper); }
.m-more[aria-expanded="true"] { transform: rotate(45deg); }
.m-detail { max-width: 38ch; color: var(--ink-2); margin-top: 14px; opacity: 0; transform: translate3d(0, 8px, 0); transition: opacity 400ms, transform 400ms var(--ease-out); }
.m-detail.is-open { opacity: 1; transform: none; }

.v-svg { width: 100%; height: 100%; overflow: visible; }

/* Power: a giant line grows across the screen */
.moment-line .sticky { align-items: start; padding-top: 16vh; }
.moment-line .m-visual { position: absolute; left: 0; right: 0; top: 42vh; height: 52vh; z-index: 1; }
.moment-line .m-copy { grid-column: 1; }
.moment-line.is-flip .m-copy { grid-column: 2; }
.v-line { fill: none; stroke: var(--green); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.v-line-glow { fill: none; stroke: rgba(61, 205, 88, 0.16); stroke-width: 26; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.v-dots circle { fill: #7ef096; }
.v-dots { opacity: 0; transition: opacity 400ms; }

/* Cooling: a heat field expands, then cooling closes around it */
.v-heat { position: relative; width: min(44vh, 32vw); aspect-ratio: 1; }
.heat-ring, .heat-cool { position: absolute; inset: 0; border-radius: 50%; }
.r0 { background: radial-gradient(circle, rgba(194, 54, 31, 0.55), rgba(194, 54, 31, 0) 62%); transform: scale(var(--heat, 0.4)); animation: breathe 3.4s ease-in-out infinite; }
.r1 { background: radial-gradient(circle, rgba(224, 161, 0, 0.32), rgba(224, 161, 0, 0) 66%); transform: scale(calc(var(--heat, 0.4) * 1.15)); }
.r2 { border: 1px dashed rgba(194, 54, 31, 0.32); transform: scale(calc(var(--heat, 0.4) * 1.05)); }
.r3 { border: 1px solid rgba(194, 54, 31, 0.14); transform: scale(calc(var(--heat, 0.4) * 1.25)); }
.heat-cool { border: 3px solid var(--green); opacity: var(--cool, 0); transform: scale(calc(1.45 - var(--cool, 0) * 0.35)); box-shadow: 0 0 60px rgba(61, 205, 88, 0.25) inset; }
@keyframes breathe { 50% { filter: brightness(1.12); } }

/* Resilience: an interconnected network appears */
.v-edge { stroke: rgba(18, 22, 20, 0.1); stroke-width: 1.5; transition: stroke 500ms; }
.v-edge.is-lit { stroke: var(--green); }
.v-node { fill: var(--paper); stroke: rgba(18, 22, 20, 0.2); stroke-width: 2; transform-box: fill-box; transform-origin: center; transform: scale(0.4); opacity: 0.35; transition: transform 600ms var(--ease-out), opacity 400ms, fill 400ms; }
.v-node.is-lit { fill: var(--green); stroke: var(--green-ink); transform: scale(1); opacity: 1; }
.v-node.is-hub.is-lit { fill: var(--night); stroke: var(--green); stroke-width: 3; }

/* Load: a growing vertical scale */
.v-scale { height: 62vh; display: flex; gap: 18px; align-items: stretch; }
.scale-ticks { display: flex; flex-direction: column; justify-content: space-between; }
.scale-ticks span { width: 18px; height: 1px; background: var(--line-strong); }
.scale-ticks span:nth-child(5n + 1) { width: 30px; }
.scale-col { width: clamp(72px, 8vw, 128px); background: var(--paper-2); border-radius: 12px; overflow: hidden; display: flex; align-items: flex-end; }
.scale-fill { width: 100%; height: 100%; background: linear-gradient(to top, var(--green-ink), var(--green)); transform-origin: bottom; transform: scaleY(0); }

/* Charging: ports light up */
.v-dotgrid { display: grid; grid-template-columns: repeat(12, 1fr); gap: clamp(8px, 1.2vw, 16px); width: min(42vw, 520px); }
.v-dotgrid span { aspect-ratio: 1; border-radius: 50%; background: var(--line); transition: background 300ms, transform 300ms var(--ease-out); }
.v-dotgrid span.is-lit { background: var(--green); transform: scale(1.15); }

/* Carbon: a counter that runs with the scroll */
.moment-counter .sticky { display: grid; grid-template-columns: 1fr; place-items: center; text-align: center; padding: 0 var(--gutter); }
.m-counter { position: relative; z-index: 2; }
.m-counter-num { font-family: var(--font-display); font-size: clamp(4rem, 1rem + 13vw, 16rem); line-height: 0.84; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }

/* ---------- Consequence (dark chapter) ---------- */
.scene-dark { background: var(--night); color: var(--night-text); }
.scene-dark .kicker { color: var(--night-muted); }
.consequence-intro { height: 230vh; }
.consequence-intro::before {
  content: ''; position: absolute; left: 0; right: 0; top: -40vh; height: 40vh; pointer-events: none;
  background: linear-gradient(rgba(13, 22, 18, 0), var(--night));
}
.consequence-intro .sticky { display: grid; place-items: center; }
.ci-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: var(--text-mega); line-height: 0.88; text-align: center; display: grid; }
.ci-line { display: block; opacity: 0; }
.ci-line:last-child { color: var(--night-red-soft); font-style: italic; }
.risk-pulse { position: absolute; left: 50%; bottom: 12vh; width: 16px; height: 16px; border-radius: 50%; background: var(--night-red); transform: translateX(-50%) scale(0); transition: transform 600ms var(--ease-out); }
.risk-pulse::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--night-red); animation: ping 1.4s var(--ease-out) infinite; }
.risk-pulse.is-on { transform: translateX(-50%) scale(1); }

.statement { height: 175vh; }
.statement .sticky {
  display: grid; grid-template-columns: 1.15fr 1fr; align-items: center; gap: 4vw;
  padding: 0 var(--gutter) 0 calc(var(--gutter) + var(--rail-space));
}
.statement.is-flip .st-visual { order: -1; }
.st-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: var(--text-giant); line-height: 0.9; display: grid; }
.st-l2 { color: var(--night-amber); }
.sev-high .st-l2 { color: var(--night-red-soft); }
.st-sub { color: var(--night-muted); margin-top: 3vh; max-width: 40ch; font-size: 1.05rem; }
.st-visual { height: 56vh; display: grid; place-items: center; }

.fs-grid { fill: var(--green); }
.fs-line { stroke: var(--green); stroke-width: 4; fill: none; transition: stroke 500ms; }
.fs-machine { fill: var(--night-3); stroke: var(--green); stroke-width: 2; transition: stroke 500ms, fill 500ms; }
.fs-dots circle { fill: #7ef096; }
.fs-dots { transition: opacity 300ms; }
.fs.is-cut .fs-gap { stroke: transparent; }
.fs.is-cut .fs-late { stroke: var(--night-red); stroke-dasharray: 6 8; }
.fs.is-cut .fs-dots { opacity: 0; }
.fs.is-cut .fs-machine { stroke: var(--night-red); fill: rgba(255, 106, 80, 0.08); animation: dim 1.2s ease-in-out infinite; }
@keyframes dim { 50% { opacity: 0.4; } }

.dv-axis { stroke: rgba(232, 239, 233, 0.2); stroke-width: 1; }
.dv-output { fill: none; stroke: var(--night-muted); stroke-width: 3; stroke-dasharray: 1; stroke-dashoffset: 1; }
.dv-bill { fill: none; stroke: var(--night-red); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.dv-label { font: 500 13px var(--font-mono); letter-spacing: 0.12em; fill: var(--night-muted); opacity: 0; transition: opacity 400ms; }
.dv-label-bill { fill: var(--night-red-soft); }

.v-unstable { position: relative; width: min(42vh, 36vw); aspect-ratio: 1; display: grid; place-items: center; }
.u-ring { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(255, 106, 80, 0.4); animation: ring-out 2.4s var(--ease-out) infinite; }
.u-ring:nth-child(2) { animation-delay: 0.8s; }
.u-ring:nth-child(3) { animation-delay: 1.6s; }
.u-core { width: 18%; aspect-ratio: 1; border-radius: 50%; background: var(--night-red); box-shadow: 0 0 70px rgba(255, 106, 80, 0.6); animation: jitter 0.5s steps(2) infinite; }
@keyframes ring-out { from { transform: scale(0.25); opacity: 1; } to { transform: scale(1); opacity: 0; } }
@keyframes jitter {
  0% { transform: translate3d(calc(var(--shake, 0) * 7px), calc(var(--shake, 0) * -5px), 0); }
  50% { transform: translate3d(calc(var(--shake, 0) * -6px), calc(var(--shake, 0) * 4px), 0); }
}

/* ---------- Critical path: one continuous energy line ---------- */
.scene-path { height: 330vh; }
.scene-path .sticky { display: flex; flex-direction: column; justify-content: center; padding: 0 var(--gutter) 0 calc(var(--gutter) + var(--rail-space)); }
.cp-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: clamp(2.2rem, 0.8rem + 4.2vw, 5.6rem); line-height: 0.92; display: grid; margin-bottom: 14vh; }
.cp-title-2 { color: var(--green); }
.cp-stage { position: relative; height: 26vh; }
.cp-line { position: absolute; top: 50%; left: var(--from); width: var(--len); height: 3px; margin-top: -1.5px; background: linear-gradient(90deg, var(--green-ink), var(--green)); transform-origin: right; transform: scaleX(var(--draw, 0)); box-shadow: 0 0 18px rgba(61, 205, 88, 0.5); }
.cp-late { position: absolute; top: 50%; left: var(--from); width: var(--len); height: 3px; margin-top: -1.5px; background: repeating-linear-gradient(90deg, var(--night-red) 0 8px, transparent 8px 14px); opacity: 0; transition: opacity 500ms; }
.cp-today { position: absolute; top: 50%; left: var(--pos); height: 64px; margin-top: -32px; border-left: 1px dashed rgba(232, 239, 233, 0.5); opacity: 0; transition: opacity 500ms; }
.cp-today.is-on { opacity: 1; }
.cp-today em { position: absolute; top: calc(100% + 8px); left: -0.5px; transform: translateX(-50%); font: 500 0.68rem var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--night-muted); white-space: nowrap; font-style: normal; }
.cp-node { position: absolute; top: 50%; left: var(--pos); width: 0; height: 0; opacity: 0; transition: opacity 500ms; }
.cp-node.is-on { opacity: 1; }
.cp-dot { position: absolute; left: -9px; top: -9px; width: 18px; height: 18px; border-radius: 50%; background: var(--night); border: 3px solid var(--green); transform: scale(0.2); transition: transform 600ms var(--ease-out); }
.cp-node.is-on .cp-dot { transform: scale(1); }
.cp-node.is-late .cp-dot { border-color: var(--night-red); }
.cp-node.is-late.is-on .cp-dot::after { content: ''; position: absolute; inset: -3px; border-radius: 50%; border: 2px solid var(--night-red); animation: ping 1.3s var(--ease-out) infinite; }
.cp-label { position: absolute; left: 0; bottom: 22px; transform: translateX(-50%); display: grid; justify-items: center; gap: 6px; text-align: center; width: max-content; }
.cp-node.is-below .cp-label { bottom: 84px; }
.cp-node.is-below::before { content: ''; position: absolute; left: -0.5px; bottom: 12px; height: 66px; border-left: 1px solid rgba(232, 239, 233, 0.2); }
.cp-name { max-width: 14ch; font-family: var(--font-display); font-size: clamp(1rem, 0.8rem + 0.6vw, 1.45rem); line-height: 1.05; }
.cp-date { font: 500 0.66rem var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--green); white-space: nowrap; opacity: 0; transform: translate3d(0, 6px, 0); transition: opacity 500ms, transform 500ms var(--ease-out); }
.cp-node.is-late .cp-date { color: var(--night-red-soft); }
.show-dates .cp-date { opacity: 1; transform: none; }
.cp-target { position: absolute; top: 50%; left: var(--pos); width: 0; height: 0; opacity: 0; transition: opacity 700ms; }
.cp-target::before { content: ''; position: absolute; left: -14px; top: -14px; width: 28px; height: 28px; border-radius: 50%; background: var(--green); box-shadow: 0 0 40px rgba(61, 205, 88, 0.7); }
.cp-target.is-on { opacity: 1; }
.cp-target-kicker, .cp-target-date { position: absolute; right: -14px; text-align: right; white-space: nowrap; }
.cp-target-kicker { top: 30px; font: 500 0.72rem var(--font-mono); letter-spacing: 0.18em; text-transform: uppercase; color: var(--green); }
.cp-target-date { top: 52px; font-family: var(--font-display); text-transform: uppercase; font-size: clamp(2.2rem, 1rem + 3.6vw, 5rem); line-height: 0.9; }

/* ---------- Action ---------- */
.plan-first { height: 175vh; }
.plan-first .sticky { display: grid; place-items: center; }
.pf-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: clamp(4rem, 1rem + 12vw, 15rem); line-height: 0.84; text-align: center; display: grid; }
.pf-line { display: block; will-change: transform; }
.pf-energy { color: var(--green-ink); font-style: italic; }

.scene-pillars { height: 330vh; }
.scene-pillars .sticky { display: flex; align-items: center; }
.pl-track { display: flex; gap: 8vw; padding: 0 12vw 0 calc(var(--gutter) + var(--rail-space) + 4vw); position: relative; will-change: transform; }
.pl-panel { flex: 0 0 min(64vw, 860px); opacity: 0.18; transition: opacity 700ms var(--ease-out); }
.pl-panel.is-on { opacity: 1; }
.pl-index { font-family: var(--font-mono); font-size: 0.8rem; color: var(--green-ink); letter-spacing: 0.16em; }
.pl-word { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: clamp(3.6rem, 1rem + 10vw, 13rem); line-height: 0.84; margin: 1vh 0 0; }
.pl-move { font-family: var(--font-display); font-size: clamp(1.4rem, 1rem + 1.4vw, 2.3rem); line-height: 1.12; max-width: 24ch; margin: 4vh 0 2vh; color: var(--ink-2); }
.pl-rail { position: absolute; left: calc(var(--gutter) + var(--rail-space) + 4vw); right: 12vw; top: calc(100% + 8vh); height: 3px; background: var(--green); transform-origin: left; transform: scaleX(0); }

.scene-outcome { min-height: 100vh; display: grid; place-items: center; padding: 14vh var(--gutter); }
.oc-inner { text-align: center; width: 100%; max-width: 920px; }
.oc-big { font-family: var(--font-display); font-size: clamp(6rem, 2rem + 16vw, 20rem); line-height: 0.8; color: var(--green-ink); letter-spacing: -0.04em; margin-top: 3vh; }
.oc-what { font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.85rem; color: var(--ink-2); margin-top: 3vh; }
.oc-rows { list-style: none; margin: 9vh auto 0; padding: 0; display: grid; gap: 18px; max-width: 620px; text-align: left; }
.oc-row { display: grid; grid-template-columns: 130px 1fr; gap: 5px 18px; align-items: center; }
.oc-label { grid-row: span 2; font-size: 0.85rem; color: var(--muted); }
.oc-bar { height: 6px; border-radius: 3px; transform-origin: left; transform: scaleX(0); transition: transform 1300ms var(--ease-out) 400ms; }
.oc-before { background: var(--line-strong); }
.oc-after { background: var(--green); }
.pop.is-on .oc-bar { transform: scaleX(var(--w)); }

/* What if you changed one thing? */
.scene-whatif { min-height: 100vh; max-width: 1440px; margin: 0 auto; padding: 16vh var(--gutter) 14vh calc(var(--gutter) + var(--rail-space)); }
.wi-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: clamp(3rem, 0.8rem + 7vw, 9rem); line-height: 0.88; display: grid; }
.wi-one { color: var(--green-ink); font-style: italic; }
.wi-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 7vh; }
.wi-tab { border: 1px solid var(--line-strong); background: transparent; border-radius: 999px; padding: 8px 16px; font: 500 0.72rem var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-2); transition: background 200ms, color 200ms, border-color 200ms; }
.wi-tab:hover { border-color: var(--ink); color: var(--ink); }
.wi-tab.is-active { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.wi-control { margin-top: 4vh; display: grid; gap: 6px; max-width: 920px; }
.wi-value { font-family: var(--font-display); font-size: clamp(2.2rem, 1rem + 2.6vw, 3.8rem); line-height: 1; }
.wi-range { -webkit-appearance: none; appearance: none; width: 100%; height: 4px; border-radius: 4px; margin: 22px 0 10px; cursor: pointer; background: linear-gradient(90deg, var(--green) var(--pct, 50%), var(--paper-2) var(--pct, 50%)); }
.wi-range::-webkit-slider-thumb { -webkit-appearance: none; width: 34px; height: 34px; border-radius: 50%; background: var(--night); border: 4px solid var(--green); box-shadow: 0 10px 24px -8px rgba(13, 22, 18, 0.6); transition: transform 200ms var(--ease-out); }
.wi-range::-moz-range-thumb { width: 28px; height: 28px; border-radius: 50%; background: var(--night); border: 4px solid var(--green); }
.wi-range:hover::-webkit-slider-thumb, .wi-range:active::-webkit-slider-thumb { transform: scale(1.12); }
.wi-ends { display: flex; justify-content: space-between; font: 0.74rem var(--font-mono); color: var(--muted); }
.wi-select { font-family: var(--font-display); font-size: clamp(1.6rem, 1rem + 1.4vw, 2.4rem); background: transparent; border: 0; border-bottom: 2px solid var(--ink); padding: 6px 0; max-width: 560px; color: var(--ink); cursor: pointer; }
.wi-out { display: grid; grid-template-columns: 80px 1fr auto; gap: 5vw; align-items: end; margin-top: 9vh; }
.wi-load { height: 36vh; width: 64px; background: var(--paper-2); border-radius: 12px; overflow: hidden; display: flex; align-items: flex-end; }
.wi-load-fill { width: 100%; height: 100%; background: linear-gradient(to top, var(--green-ink), var(--green)); transform-origin: bottom; transition: transform 800ms var(--ease-out); }
.wi-num { font-family: var(--font-display); font-size: clamp(4rem, 1rem + 9vw, 11rem); line-height: 0.84; letter-spacing: -0.03em; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.1em; }
.wi-num small { font-family: var(--font-mono); font-size: clamp(1rem, 0.6rem + 1vw, 1.5rem); color: var(--muted); letter-spacing: 0; }
.wi-num-label { font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.78rem; color: var(--green-ink); margin-top: 16px; }
.wi-risk { display: grid; justify-items: center; gap: 8px; min-width: 120px; }
.wi-risk-dot { width: 22px; height: 22px; border-radius: 50%; background: var(--green); position: relative; transition: background 400ms; }
.wi-risk-dot::after { content: ''; position: absolute; inset: 0; border-radius: 50%; background: inherit; animation: ping 1.8s var(--ease-out) infinite; }
.wi-risk.tone-tight .wi-risk-dot { background: var(--night-amber); }
.wi-risk.tone-late .wi-risk-dot { background: var(--risk); animation: jitter 0.45s steps(2) infinite; --shake: 0.5; }
.wi-risk-score { font-family: var(--font-display); font-size: clamp(3rem, 1rem + 3vw, 4.6rem); line-height: 0.9; }
.wi-risk-label { font: 500 0.72rem var(--font-mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.wi-risk.tone-late .wi-risk-label { color: var(--risk); }
.wi-timeline { position: relative; height: 80px; margin-top: 9vh; }
.wi-tl-line { position: absolute; left: 0; right: 0; top: 50%; height: 2px; background: linear-gradient(90deg, var(--line-strong), var(--green)); }
.wi-step { position: absolute; inset: 0; transform: translate3d(var(--x, 0%), 0, 0); transition: transform 800ms var(--ease-out); pointer-events: none; }
.wi-step i { position: absolute; left: -7px; top: calc(50% - 7px); width: 14px; height: 14px; border-radius: 50%; background: var(--paper); border: 3px solid var(--green); transition: border-color 300ms, background 300ms; }
.wi-step.is-late i { border-color: var(--risk); background: var(--risk); }
.wi-today i { left: -1px; width: 2px; height: 44px; top: calc(50% - 22px); border: 0; border-radius: 1px; background: var(--ink); }
.wi-target i { left: -11px; top: calc(50% - 11px); width: 22px; height: 22px; border: 0; background: var(--green); box-shadow: 0 0 24px rgba(61, 205, 88, 0.6); }
.wi-step em { position: absolute; left: 0; top: calc(50% + 26px); transform: translateX(-50%); font: 500 0.66rem var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-style: normal; white-space: nowrap; }

/* Final screen */
.scene-final { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 16vh var(--gutter); }
.fn-title { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; font-size: clamp(2.8rem, 0.8rem + 7vw, 9.4rem); line-height: 0.88; display: grid; }
.fn-title span:last-child { color: var(--green-ink); }
.fn-brand { margin-top: 10vh; transition-delay: 300ms; }
.fn-product { font-family: var(--font-display); font-size: clamp(1.6rem, 1rem + 1vw, 2.2rem); }
.fn-sub { font: 500 0.72rem var(--font-mono); letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); margin-top: 8px; }
.fn-actions { margin-top: 6vh; display: flex; flex-wrap: wrap; gap: 10px 26px; align-items: center; justify-content: center; }
.link-btn { border: 0; background: none; padding: 6px 0; color: var(--ink-2); font-size: 0.95rem; border-bottom: 1px solid var(--line-strong); transition: color 200ms, border-color 200ms; }
.link-btn:hover, .link-btn:focus-visible { color: var(--ink); border-color: var(--green); }

/* Full translation drawer */
.modal-detail { width: min(1200px, calc(100% - 32px)); max-height: 92vh; overflow: auto; }
.modal-detail .card { margin: 0; border: 0; border-radius: 0; box-shadow: none; }
.modal-detail .modal-head { position: sticky; top: 0; z-index: 2; background: var(--paper-3); border-bottom: 1px solid var(--line); }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .rail { display: none; }
  :root { --rail-space: 0px; }
}

@media (max-width: 860px) {
  .ask { flex-wrap: wrap; }
  #ambition { flex-basis: calc(100% - 60px); }
  .count { display: none; }
  .ask-go { margin-left: auto; }
  .scene-tx .sticky { grid-template-columns: 1fr; grid-template-rows: auto 6vh auto; align-content: center; gap: 2vh; }
  .tx-flow { height: 6vh; }
  .tx-ambition { font-size: clamp(1.7rem, 1rem + 4vw, 2.6rem); }
  .is-lead .tx-val { font-size: clamp(2.6rem, 1rem + 8vw, 4rem); }
  .tx-val, .tx-word { font-size: clamp(1.5rem, 1rem + 3vw, 2.2rem); }
  .tx-rows { gap: 1.6vh; }
  .moment .sticky, .statement .sticky { grid-template-columns: 1fr; align-content: center; gap: 3vh; }
  .m-visual { height: 36vh; }
  .moment.is-flip .m-visual, .statement.is-flip .st-visual { order: -1; }
  .moment-line .m-visual { top: 8vh; height: 40vh; }
  .moment-line .m-copy, .moment-line.is-flip .m-copy { grid-column: 1; align-self: end; margin-bottom: 10vh; }
  .v-heat { width: min(36vh, 70vw); }
  .v-scale { height: 34vh; }
  .v-dotgrid { width: min(80vw, 360px); }
  .st-visual { height: 30vh; }
  .v-unstable { width: min(30vh, 60vw); }
  .cp-title { margin-bottom: 5vh; font-size: clamp(2rem, 1rem + 4vw, 2.8rem); }
  .cp-stage { height: 58vh; margin-left: 8px; }
  .cp-line, .cp-late { left: 0; width: 3px; top: var(--from); height: var(--len); margin: 0; transform-origin: bottom; transform: scaleY(var(--draw, 0)); }
  .cp-late { transform: none; background: repeating-linear-gradient(180deg, var(--night-red) 0 8px, transparent 8px 14px); }
  .cp-today, .cp-node, .cp-target { left: 1.5px; top: var(--pos); }
  .cp-today { height: 0; width: 40px; margin: 0 0 0 -20px; border-left: 0; border-top: 1px dashed rgba(232, 239, 233, 0.5); }
  .cp-today em { top: -1.8em; left: 48px; transform: none; }
  .cp-label, .cp-node.is-below .cp-label { left: 24px; bottom: auto; top: -0.7em; transform: none; display: flex; align-items: baseline; gap: 10px; text-align: left; }
  .cp-node.is-below::before { display: none; }
  .cp-name { max-width: 46vw; font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .show-dates .cp-date, .cp-date { transform: none; }
  .cp-target-kicker, .cp-target-date { right: auto; left: 28px; text-align: left; }
  .cp-target-kicker { top: 1.5rem; }
  .cp-target-date { top: -1.1rem; font-size: 2.2rem; }
  .pl-panel { flex-basis: 82vw; }
  .wi-out { grid-template-columns: 56px 1fr; }
  .wi-risk { grid-column: 1 / -1; grid-auto-flow: column; justify-content: start; align-items: center; }
  .wi-load { width: 48px; height: 26vh; }
}

@media (prefers-reduced-motion: reduce) {
  .pop { opacity: 1; transform: none; filter: none; }
  .hl-in { transform: none; }
  .ch { transform: none !important; opacity: 1 !important; }
}
