:root {
  --night: #071019;
  --night-2: #0b1822;
  --night-3: #10232d;
  --ink: #152127;
  --paper: #eee7d7;
  --paper-2: #d8cfbd;
  --muted: #9aa5a4;
  --gold: #e6b85c;
  --teal: #6ba7a0;
  --red: #cb6857;
  --orange: #e39a52;
  --line: rgba(238, 231, 215, 0.17);
  --glass: rgba(7, 16, 25, 0.72);
  --serif: "Newsreader", Georgia, serif;
  --sans: "Instrument Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --measure: 68rem;
  --prose: 38rem;
}

* { box-sizing: border-box; }

html {
  background: var(--night);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--night);
  color: var(--paper);
  font-family: var(--serif);
  font-size: clamp(1.05rem, 1.25vw, 1.18rem);
  font-weight: 300;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

body.menu-open { overflow: hidden; }

::selection { background: rgba(230, 184, 92, 0.32); }

a { color: inherit; }

button { font: inherit; }

button, a { -webkit-tap-highlight-color: transparent; }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

h1, h2, h3, p, blockquote { margin-top: 0; }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 0.98;
  text-wrap: balance;
}

p { text-wrap: pretty; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: 1rem;
  z-index: 200;
  padding: 0.7rem 1rem;
  background: var(--paper);
  color: var(--night);
  font-family: var(--sans);
  font-size: 0.8rem;
  transform: translateY(-200%);
}

.skip-link:focus { transform: translateY(0); }

#ambient-current {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100vw;
  height: 100svh;
  pointer-events: none;
  opacity: 0.42;
}

main, .site-chrome, .contents { position: relative; z-index: 2; }

.measure {
  width: min(var(--measure), calc(100% - 3rem));
  margin-inline: auto;
}

.prose {
  font-size: clamp(1.08rem, 1.35vw, 1.24rem);
  line-height: 1.72;
}

.prose p { margin-bottom: 1.35em; }

.prose em { color: #fff6e2; }

.essay-section { position: relative; }

.section-index,
.eyebrow,
.story-number,
.date,
.visual-caption,
.application-label {
  font-family: var(--mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  line-height: 1.5;
  text-transform: uppercase;
}

.section-index,
.eyebrow,
.story-number { color: var(--gold); }

/* Site chrome */
.site-chrome {
  position: fixed;
  inset: 0 0 auto;
  z-index: 90;
  display: grid;
  grid-template-columns: 1fr minmax(8rem, 22rem) 1fr;
  align-items: center;
  gap: 1rem;
  height: 4.1rem;
  padding: 0 1.3rem;
  color: rgba(238, 231, 215, 0.72);
  background: linear-gradient(to bottom, rgba(7, 16, 25, 0.82), transparent);
  transition: opacity 0.5s ease;
}

body.at-top .site-chrome { opacity: 0; pointer-events: none; }

.wordmark,
.contents-toggle {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-decoration: none;
  text-transform: uppercase;
}

.contents-toggle {
  justify-self: end;
  padding: 0;
  border: 0;
  color: inherit;
  background: none;
  cursor: pointer;
}

.progress-track {
  height: 1px;
  background: rgba(238, 231, 215, 0.2);
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--gold);
  box-shadow: 0 0 12px rgba(230, 184, 92, 0.55);
}

.contents {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  visibility: hidden;
  background: rgba(5, 12, 18, 0.97);
  opacity: 0;
  transition: opacity 0.35s ease, visibility 0s 0.35s;
}

.contents.open {
  visibility: visible;
  opacity: 1;
  transition-delay: 0s;
}

.contents ol {
  width: min(36rem, calc(100% - 3rem));
  margin: 0;
  padding: 0;
  list-style: none;
}

.contents a {
  display: flex;
  align-items: baseline;
  gap: 1.4rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--line);
  font-size: clamp(1.8rem, 5vw, 3.7rem);
  line-height: 1;
  text-decoration: none;
}

.contents a span {
  color: var(--gold);
  font-family: var(--mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
}

/* Hero */
.hero {
  position: relative;
  display: grid;
  min-height: 100svh;
  place-items: center;
  overflow: hidden;
  background: #050b11;
}

.hero-art,
.hero-vignette {
  position: absolute;
  inset: -4%;
}

.hero-art {
  background-image: url("assets/pacific-current-hero.png");
  background-position: center 58%;
  background-size: cover;
  filter: saturate(0.86) contrast(1.05) brightness(0.68);
  transform: scale(1.05);
  animation: hero-breathe 18s ease-in-out infinite alternate;
}

@keyframes hero-breathe {
  to { transform: scale(1.09) translate3d(0, -0.7%, 0); }
}

.hero-vignette {
  background:
    radial-gradient(circle at 50% 34%, rgba(3, 10, 15, 0.18) 0, rgba(3, 10, 15, 0.68) 56%, #050a10 100%),
    linear-gradient(to bottom, rgba(5, 10, 16, 0.18), rgba(5, 10, 16, 0.18) 56%, rgba(5, 10, 16, 0.92));
}

.hero-copy {
  position: relative;
  z-index: 2;
  width: min(72rem, calc(100% - 3rem));
  padding: 8rem 0 7rem;
  text-align: center;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.88);
}

.hero .eyebrow { margin-bottom: 2rem; color: rgba(238, 231, 215, 0.66); }

.hero h1 {
  max-width: 19ch;
  margin: 0 auto;
  font-size: clamp(2.6rem, 6.6vw, 6.75rem);
  line-height: 0.98;
}

.hero h1 span,
.hero h1 em { display: block; }

.hero h1 span { color: var(--paper); }

.hero h1 em {
  margin-top: 0.18em;
  color: #efc976;
  font-weight: 400;
}

.hero .dek {
  max-width: 42rem;
  margin: 2rem auto 0;
  color: rgba(238, 231, 215, 0.84);
  font-size: clamp(1.03rem, 1.65vw, 1.3rem);
  font-style: italic;
}

.byline {
  margin: 1.8rem 0 0;
  color: rgba(238, 231, 215, 0.6);
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.scroll-prompt {
  position: absolute;
  bottom: 1.6rem;
  left: 50%;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  color: rgba(238, 231, 215, 0.65);
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.19em;
  text-decoration: none;
  text-transform: uppercase;
  transform: translateX(-50%);
}

.scroll-prompt i {
  display: block;
  width: 3.6rem;
  height: 1px;
  overflow: hidden;
  background: rgba(238, 231, 215, 0.25);
}

.scroll-prompt i::after {
  display: block;
  width: 55%;
  height: 100%;
  background: var(--gold);
  content: "";
  animation: cue 2.2s ease-in-out infinite;
}

@keyframes cue {
  0% { transform: translateX(-110%); }
  65%, 100% { transform: translateX(210%); }
}

/* Proposition */
.promise {
  padding: clamp(8rem, 15vw, 15rem) 0;
  background:
    radial-gradient(circle at 12% 20%, rgba(107, 167, 160, 0.08), transparent 36rem),
    var(--night);
}

.promise-grid {
  display: grid;
  grid-template-columns: minmax(14rem, 0.7fr) minmax(20rem, 1.3fr);
  gap: clamp(3rem, 8vw, 8rem);
  align-items: start;
}

.lazarus {
  position: sticky;
  top: 9rem;
  margin: 2.4rem 0 0;
  padding-left: 1.3rem;
  border-left: 1px solid var(--gold);
  color: var(--paper-2);
  font-size: clamp(1.25rem, 2.2vw, 1.85rem);
  font-style: italic;
  line-height: 1.48;
}

.lazarus cite {
  display: block;
  margin-top: 1.4rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.58rem;
  font-style: normal;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.lead-prose > p:first-child::first-letter {
  float: left;
  margin: 0.1em 0.11em -0.03em 0;
  color: var(--gold);
  font-size: 5.3em;
  line-height: 0.72;
}

.lead-prose .turn {
  margin-top: 3rem;
  color: var(--gold);
  font-size: 1.35em;
  font-style: italic;
}

/* Evidence, kept deliberately spare */
.evidence-strip {
  position: relative;
  z-index: 2;
  width: min(70rem, calc(100% - 3rem));
  margin: 0 auto clamp(8rem, 14vw, 15rem);
  padding: clamp(2rem, 4vw, 3.5rem) 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.evidence-kicker {
  font-family: var(--mono);
  font-size: .58rem;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.evidence-kicker { margin-bottom: 2rem; color: var(--gold); }
.evidence-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(3rem, 9vw, 8rem); }
.evidence-grid figure { margin: 0; }
.signal-number { display: flex; align-items: baseline; color: var(--paper); line-height: .8; letter-spacing: -.07em; }
.signal-number span { font-size: clamp(5rem, 12vw, 10rem); font-weight: 300; }
.signal-number i { margin: 0 .35em; color: var(--gold); font-size: clamp(1.4rem, 3vw, 2.7rem); font-style: normal; }
.signal-number b { margin-left: .15em; color: var(--gold); font-family: var(--mono); font-size: clamp(1rem, 2vw, 1.7rem); font-weight: 400; letter-spacing: 0; }
.evidence-grid figcaption { max-width: 28rem; margin-top: 1.5rem; color: var(--muted); font-size: .9rem; line-height: 1.55; }
.room-note { display: grid; grid-template-columns: 11rem 1fr; gap: 1rem clamp(2rem, 6vw, 6rem); margin: clamp(4rem, 8vw, 7rem) 0 0; padding: clamp(2rem, 4vw, 3rem) 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.room-note span, .room-note cite { color: var(--gold); font-family: var(--mono); font-size: .55rem; font-style: normal; letter-spacing: .16em; text-transform: uppercase; }
.room-note p { max-width: 48ch; margin: 0; color: var(--paper); font-size: clamp(1.2rem, 2vw, 1.75rem); font-style: italic; line-height: 1.38; }
.room-note cite { grid-column: 2; color: var(--muted); }

/* Chapter headers */
.chapter-head {
  padding: clamp(8rem, 14vw, 14rem) 0 clamp(5rem, 9vw, 9rem);
}

.chapter-head h2,
.split-intro h2,
.notes h2 {
  max-width: 14ch;
  margin: 1.3rem 0 1.5rem;
  font-size: clamp(3rem, 7vw, 7.2rem);
}

.chapter-head > p:last-child {
  max-width: 34rem;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* History */
.history {
  background: #050c12;
  border-top: 1px solid var(--line);
}

.history-scrolly {
  position: relative;
  width: min(92rem, 100%);
  margin: 0 auto;
}

.history-stage {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100svh;
  margin: 0;
  overflow: hidden;
  background: #071019;
}

.atlas {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(5, 12, 18, 0.08) 35%, rgba(5, 12, 18, 0.85) 82%),
    linear-gradient(to bottom, rgba(5, 12, 18, 0.25), rgba(5, 12, 18, 0.82)),
    url("assets/pacific-current-hero.png");
  background-position: 48% center;
  background-size: cover;
  filter: saturate(0.58) contrast(1.08) brightness(0.68);
  transform: scale(1.03);
  transition: filter 1.1s ease, transform 1.1s cubic-bezier(.2,.7,.2,1), background-position 1.1s ease;
}

.history-stage[data-state="fog"] .atlas { filter: grayscale(0.75) contrast(0.8) brightness(0.72); }
.history-stage[data-state="open"] .atlas { filter: saturate(0.72) contrast(1.08) brightness(0.74); }
.history-stage[data-state="valley"] .atlas {
  background-position: 73% center;
  filter: saturate(0.88) contrast(1.1) brightness(0.82);
  transform: scale(1.2);
}

#history-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* The Paper Current: archive becomes landscape, landscape becomes law */
.paper-current-world {
  --paper-era: 0;
  position: absolute;
  inset: 0;
  z-index: 3;
  overflow: hidden;
  pointer-events: none;
}

.history-era,
.paper-passage {
  position: absolute;
  inset: 0;
}

.history-era {
  --era-visibility: 0;
  --era-delta: 0;
  --era-distance: 0;
  opacity: var(--era-visibility);
  transform: translate3d(calc(var(--era-delta) * -1.4vw), calc(var(--era-distance) * .65vh), 0) scale(calc(1 - var(--era-distance) * .018));
  transform-origin: 42% 60%;
}

.paper-passage { opacity: var(--passage-visibility, 0); }

.history-paper-layer {
  position: absolute;
  z-index: 2;
  bottom: -2vh;
  left: -7vw;
  width: min(79vw, 74rem);
  max-width: none;
  filter: drop-shadow(0 2rem 3rem rgba(0,0,0,.42));
}

.gold-paper-layer { bottom: -3vh; width: min(82vw, 76rem); }
.exclusion-paper-layer { bottom: -1vh; width: min(74vw, 70rem); }
.hart-celler-paper-layer { bottom: -3vh; width: min(78vw, 73rem); }
.skilled-corridor-paper-layer { bottom: -2vh; width: min(79vw, 74rem); }
.peninsula-paper-layer { bottom: -3vh; width: min(82vw, 77rem); }

.archive-fragment {
  position: absolute;
  z-index: 1;
  margin: 0;
  color: #16212a;
  filter: drop-shadow(0 1.5rem 2.5rem rgba(0,0,0,.38));
}

.archive-fragment::before {
  position: absolute;
  inset: -.7rem -.65rem -2.45rem;
  z-index: -1;
  background: #d7ccb4;
  box-shadow: inset 0 0 0 1px rgba(26,33,35,.22);
  clip-path: polygon(1% 2%, 15% 0, 28% 2%, 43% .5%, 57% 2%, 72% 0, 86% 2%, 99% .5%, 100% 93%, 91% 97%, 76% 95%, 63% 98%, 46% 95%, 30% 98%, 14% 96%, 0 99%);
  content: "";
}

.archive-fragment img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: sepia(.18) saturate(.72) contrast(1.08);
  mix-blend-mode: multiply;
}

.archive-fragment figcaption {
  display: block;
  position: absolute;
  right: .1rem;
  bottom: -1.75rem;
  left: .1rem;
  color: #263039;
  font-family: var(--mono);
  font-size: .48rem;
  line-height: 1.25;
  letter-spacing: .055em;
  text-transform: none;
}

.archive-fragment figcaption span {
  margin-right: .45rem;
  color: #91503f;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.gold-map-archive {
  top: 7vh;
  left: 18vw;
  width: min(29vw, 25rem);
  height: clamp(14rem, 34vw, 31rem);
  transform: rotate(-1.4deg);
}

.gold-map-archive img { object-position: 45% 50%; }

.exclusion-act-archive {
  z-index: 3;
  top: 7vh;
  left: 44vw;
  width: min(17vw, 15rem);
  height: clamp(18rem, 39vw, 34rem);
  transform: rotate(-2deg);
}

.exclusion-act-archive img { object-position: top; }

.hart-celler-archive {
  top: 7vh;
  left: 24vw;
  width: min(36vw, 34rem);
  height: clamp(11rem, 18vw, 17rem);
  transform: rotate(-1.2deg);
}

.hart-celler-archive img { object-position: 50% 56%; }

.act-1990-archive {
  top: 6vh;
  left: 42vw;
  width: min(18vw, 15rem);
  height: clamp(18rem, 39vw, 35rem);
  transform: rotate(-1.8deg);
}

.act-1990-archive img { object-position: top; }

.bay-archive {
  top: 7vh;
  left: 3vw;
  width: min(47vw, 43rem);
  height: clamp(9rem, 19vw, 17rem);
  transform: rotate(-1.1deg);
}

.bay-archive img { object-position: center; filter: saturate(.52) sepia(.18) contrast(1.08); }

.angel-archive {
  top: 9vh;
  left: 10vw;
  width: min(49vw, 45rem);
  height: clamp(7rem, 14vw, 12.5rem);
  opacity: calc(1 - var(--paper-era) * .84);
  transform: translate3d(calc(var(--paper-era) * -3vw), calc(var(--paper-era) * -2vh), 0) rotate(-1.1deg);
}

.paper-angel-layer {
  position: absolute;
  z-index: 2;
  bottom: -2vh;
  left: -8vw;
  width: min(79vw, 74rem);
  max-width: none;
  opacity: calc(1 - var(--paper-era) * .57);
  filter: drop-shadow(0 2rem 3rem rgba(0,0,0,.38));
  transform: translate3d(calc(var(--paper-era) * -5vw), calc(var(--paper-era) * 4vh), 0) scale(calc(1 - var(--paper-era) * .04));
  transform-origin: 44% 78%;
}

.quota-map-archive {
  top: 7vh;
  left: 2.6vw;
  width: min(48vw, 45rem);
  height: clamp(10rem, 20vw, 18rem);
  opacity: calc(var(--paper-era) * .88);
  transform: translate3d(calc((1 - var(--paper-era)) * -4vw), calc((1 - var(--paper-era)) * 4vh), 0) rotate(-2deg) scale(calc(.96 + var(--paper-era) * .04));
}

.quota-map-archive img { object-position: center; }

.paper-flow {
  position: absolute;
  z-index: 3;
  top: 25vh;
  left: -2vw;
  width: min(72vw, 68rem);
  height: 55vh;
  overflow: visible;
}

.history-current-layer {
  position: absolute;
  z-index: 3;
  top: 25vh;
  left: -2vw;
  width: min(72vw, 68rem);
  height: 55vh;
  overflow: visible;
}

.era-current {
  --era-visibility: 0;
  opacity: var(--era-visibility);
}

.history-current-layer path { fill: none; stroke-linecap: round; }
.current-shadow { stroke: rgba(0,0,0,.78); stroke-width: 30; }
.current-dotted {
  stroke: #e6b85c;
  stroke-width: 9;
  stroke-dasharray: 1 19;
  filter: drop-shadow(0 0 10px rgba(230,184,92,.55));
  animation: paper-current-drift 7s linear infinite;
}
.current-ghost { stroke: rgba(230,184,92,.22); stroke-width: 5; stroke-dasharray: 1 18; }
.current-cut-mark { stroke: #bb604f; stroke-width: 3; filter: drop-shadow(0 0 10px rgba(187,96,79,.65)); }
.open-currents path,
.valley-currents path { stroke-width: 4; stroke-dasharray: 2 15; animation: paper-current-drift 9s linear infinite; }
.open-currents path:nth-child(1) { stroke: #5f9691; }
.open-currents path:nth-child(2) { stroke: #e6b85c; }
.open-currents path:nth-child(3) { stroke: #bb604f; }
.open-currents path:nth-child(4) { stroke: #d6cdb9; }
.valley-currents path:nth-child(1) { stroke: #5f9691; }
.valley-currents path:nth-child(2) { stroke: #e6b85c; }
.valley-currents path:nth-child(3) { stroke: #bb604f; }
.valley-currents path:nth-child(4) { stroke: #e6b85c; stroke-width: 7; }
.current-node { fill: #071019; stroke: #e6b85c; stroke-width: 2; filter: drop-shadow(0 0 8px rgba(230,184,92,.7)); }

.paper-current-shadow,
.paper-current-line {
  fill: none;
  stroke-linecap: round;
}

.paper-current-shadow {
  opacity: calc((1 - var(--paper-era)) * .4);
  stroke: rgba(0,0,0,.82);
  stroke-width: 34;
}

.paper-current-line {
  opacity: calc(1 - var(--paper-era));
  stroke: #e6b85c;
  stroke-width: 12;
  stroke-dasharray: 1 20;
  filter: drop-shadow(0 0 12px rgba(230,184,92,.6));
  animation: paper-current-drift 7s linear infinite;
}

@keyframes paper-current-drift { to { stroke-dashoffset: -126; } }

#paper-quota-bands {
  opacity: var(--paper-era);
  filter: drop-shadow(0 .45rem .55rem rgba(0,0,0,.38));
}

.paper-quota-band {
  stroke: rgba(238,231,215,.4);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.paper-quota-gate {
  position: absolute;
  z-index: 4;
  top: 24vh;
  left: -3.2vw;
  width: min(72vw, 68rem);
  max-width: none;
  opacity: var(--paper-era);
  filter: drop-shadow(0 2rem 3rem rgba(0,0,0,.5));
  transform: translate3d(calc((1 - var(--paper-era)) * 7vw), 0, 0) scale(calc(.965 + var(--paper-era) * .035));
  transform-origin: 72% 50%;
}

.paper-quota-ledger {
  position: absolute;
  z-index: 6;
  bottom: 3.2vh;
  left: 3vw;
  width: min(39rem, 43vw);
  padding: .9rem 1rem 1rem;
  background: rgba(221,209,182,.95);
  box-shadow: .65rem .8rem 0 rgba(8,18,26,.44), 0 2rem 4rem rgba(0,0,0,.3);
  color: #15212a;
  clip-path: polygon(.4% 2%, 9% 0, 21% 1.4%, 36% .2%, 52% 1.5%, 69% 0, 84% 1.2%, 99.5% .3%, 100% 96%, 91% 98%, 78% 96.8%, 62% 99%, 45% 97%, 29% 99.5%, 14% 97.5%, 0 99%);
  opacity: var(--paper-era);
  transform: translate3d(0, calc((1 - var(--paper-era)) * 3rem), 0) rotate(-.45deg);
}

.history-stage[data-state="fog"] .paper-quota-ledger { pointer-events: auto; }

.paper-quota-summary { display: grid; grid-template-columns: 8.2rem 1fr; align-items: end; gap: .4rem 1rem; }
.paper-quota-summary p,
.paper-quota-inspector label,
.paper-quota-method {
  font-family: var(--mono);
  font-size: .47rem;
  line-height: 1.45;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.paper-quota-summary p { margin: 0 0 .25rem; color: #91503f; }
.paper-quota-summary h3 { display: flex; gap: .5rem; align-items: baseline; margin: 0; font-size: clamp(1.5rem, 2.5vw, 2.35rem); line-height: .95; }
.paper-quota-summary h3 i { color: #91503f; font-family: var(--sans); font-size: .9rem; font-style: normal; }
.paper-quota-summary > div { grid-column: 2; display: flex; justify-content: space-between; color: #4b5457; font-family: var(--mono); font-size: .44rem; letter-spacing: .06em; }
.paper-quota-inspector { display: grid; grid-template-columns: 8.2rem minmax(9rem, 1fr) minmax(9rem, 1fr); gap: .65rem 1rem; align-items: center; margin-top: .75rem; padding-top: .7rem; border-top: 1px solid rgba(21,33,42,.22); }
.paper-quota-inspector label { color: #4b5457; }
.paper-quota-inspector select { min-width: 0; width: 100%; padding: .45rem 1.5rem .45rem .55rem; border: 1px solid rgba(21,33,42,.28); border-radius: 0; background: rgba(255,255,255,.22); color: #15212a; font-family: var(--mono); font-size: .58rem; }
.paper-quota-inspector .quota-readout { color: #263239; font-size: .58rem; }
.paper-quota-inspector .quota-readout strong { color: #9a4338; }
.paper-quota-method { margin: .7rem 0 0; color: #4b5457; font-size: .42rem; letter-spacing: .055em; text-transform: none; }

.history-instrument,
.quota-aperture {
  position: absolute;
  z-index: 4;
  top: 5.2rem;
  bottom: 3.2rem;
  left: clamp(1rem, 3vw, 3rem);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto auto;
  width: min(52rem, 61vw);
  padding: clamp(1.1rem, 2vw, 1.8rem);
  overflow: hidden;
  border: 1px solid rgba(238, 231, 215, 0.19);
  background:
    linear-gradient(rgba(238, 231, 215, 0.035) 1px, transparent 1px) 0 0 / 100% 3rem,
    linear-gradient(105deg, rgba(7, 18, 26, .94), rgba(10, 24, 33, .88));
  box-shadow: 0 3rem 8rem rgba(0, 0, 0, 0.48);
  color: var(--paper);
  backdrop-filter: blur(18px);
  opacity: 0;
  pointer-events: none;
  transform: translateY(1.4rem) scale(0.985);
  transition: opacity 0.65s ease, transform 0.85s cubic-bezier(.2,.7,.2,1);
}

.history-instrument::before,
.quota-aperture::before {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 12% 8%, rgba(230,184,92,.08), transparent 22rem);
  content: "";
  pointer-events: none;
}

.history-instrument {
  grid-template-rows: auto minmax(0, 1fr) auto;
}

#history-instrument { display: none !important; }

.history-stage:not([data-state="fog"]):not([data-state="island"]) .history-instrument {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.history-stage:is([data-state="island"], [data-state="fog"]) .history-instrument {
  visibility: hidden;
  opacity: 0 !important;
}

.instrument-head,
.instrument-plot,
.instrument-note { position: relative; z-index: 1; }
.instrument-head { display: grid; grid-template-columns: 10.5rem 1fr; gap: clamp(1rem, 3vw, 2.8rem); align-items: start; }
.instrument-head p,
.instrument-note {
  font-family: var(--mono);
  font-size: .5rem;
  letter-spacing: .14em;
  line-height: 1.5;
  text-transform: uppercase;
}
.instrument-head p { margin: .28rem 0 0; color: var(--gold); }
.instrument-head h3 { max-width: 18ch; margin: 0; font-size: clamp(1.65rem, 3vw, 2.7rem); line-height: 1; }
.instrument-plot { min-width: 0; min-height: 0; margin: .75rem 0 .25rem; overflow: hidden; }
.instrument-plot svg { display: block; width: 100%; max-width: 100%; height: 100%; min-height: 18rem; overflow: visible; }
.instrument-plot text { fill: var(--paper-2); font-family: var(--mono); }
.instrument-note { margin: .75rem 0 0; padding-top: .75rem; border-top: 1px solid var(--line); color: var(--muted); letter-spacing: .08em; text-transform: none; }
.instrument-grid { fill: none; stroke: rgba(238,231,215,.07); stroke-width: 1; }
.instrument-line { fill: none; stroke: var(--teal); stroke-width: 2; }
.instrument-line.gold { stroke: var(--gold); }
.instrument-line.red { stroke: var(--red); }
.instrument-line.faint { opacity: .28; stroke-width: 1; }
.instrument-route { fill: none; stroke-linecap: round; stroke-dasharray: 4 10; animation: instrument-route 16s linear infinite; }
.instrument-label { font-size: 10px; letter-spacing: .12em; }
.instrument-small { fill: var(--muted) !important; font-size: 8px; letter-spacing: .09em; }
.instrument-large { fill: var(--paper) !important; font-family: var(--serif) !important; font-size: 29px; letter-spacing: -.02em; }
.instrument-number { fill: var(--gold) !important; font-family: var(--serif) !important; font-size: 64px; letter-spacing: -.05em; }
.instrument-seal { fill: rgba(203,104,87,.1); stroke: var(--red); stroke-width: 1.5; }
.instrument-node { fill: #09151d; stroke: var(--gold); stroke-width: 1.5; }
.instrument-glow { fill: var(--gold); filter: drop-shadow(0 0 10px rgba(230,184,92,.75)); }
@keyframes instrument-route { to { stroke-dashoffset: -140; } }

.history-stage:is([data-state="island"], [data-state="fog"]) #history-canvas { opacity: .08; }
.history-stage .history-year,
.history-stage .history-status,
.history-stage > figcaption { opacity: 0; }

.quota-head,
.quota-plot-wrap,
.quota-inspector,
.quota-method { position: relative; z-index: 1; }

.quota-head { display: grid; grid-template-columns: 10.5rem 1fr; gap: clamp(1rem, 3vw, 2.8rem); align-items: start; }
.quota-head p,
.quota-inspector label,
.quota-method {
  font-family: var(--mono);
  font-size: .5rem;
  letter-spacing: .14em;
  line-height: 1.5;
  text-transform: uppercase;
}
.quota-head p { margin: .28rem 0 0; color: var(--gold); }
.quota-head h3 { max-width: 18ch; margin: 0; font-size: clamp(1.65rem, 3vw, 2.7rem); line-height: 1; }

.quota-plot-wrap { min-width: 0; min-height: 0; margin: .6rem 0 .25rem; overflow: hidden; }
.quota-plot { display: block; width: 100%; max-width: 100%; height: 100%; min-width: 0; min-height: 17rem; overflow: visible; }
.quota-plot text { fill: var(--paper-2); font-family: var(--mono); }
.quota-axis-label { font-size: 10px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }
.quota-axis-total { font-family: var(--serif) !important; font-size: 30px; font-weight: 400; letter-spacing: -.04em; }
.quota-axis-note { fill: var(--muted) !important; font-size: 8px; letter-spacing: .06em; }
.quota-gate-rule { stroke: rgba(238,231,215,.52); stroke-width: 1; }
.quota-gate-shutter { fill: #03080b; opacity: .96; }
.quota-gate-label { fill: #eee7d7 !important; font-size: 9px; font-weight: 500; letter-spacing: .13em; text-anchor: middle; }
.quota-gate-sub { fill: #c8b98d !important; font-size: 7px; letter-spacing: .08em; text-anchor: middle; }
.quota-band {
  cursor: pointer;
  opacity: .78;
  stroke: rgba(238, 231, 215, .24);
  stroke-width: .7;
  transform-origin: center;
  transition: opacity .2s ease, filter .2s ease;
}
.quota-band:hover,
.quota-band:focus { filter: saturate(1.25) contrast(1.08); opacity: 1; outline: none; }
.quota-region-label { font-size: 9px; font-weight: 500; letter-spacing: .055em; pointer-events: none; }
.quota-region-value { fill: var(--muted) !important; font-size: 8px; pointer-events: none; }
.quota-exclusion { fill: none; stroke: var(--paper); stroke-width: 4; stroke-dasharray: 2 3; }
.quota-exclusion-label { fill: var(--paper-2) !important; font-size: 7px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }
.quota-bypass { fill: none; stroke: var(--gold); stroke-width: 1.4; stroke-dasharray: 2 6; }
.quota-bypass-label { fill: var(--gold) !important; font-size: 8px; letter-spacing: .08em; }

.quota-inspector {
  display: grid;
  grid-template-columns: 10.5rem minmax(10rem, 1fr) minmax(13rem, 1.45fr);
  gap: .8rem 1rem;
  align-items: center;
  padding: .75rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.quota-inspector label { color: var(--muted); }
.quota-inspector select {
  width: 100%;
  min-width: 0;
  padding: .55rem 1.8rem .55rem .65rem;
  border: 1px solid rgba(238,231,215,.25);
  border-radius: 0;
  background: rgba(238,231,215,.08);
  color: var(--paper);
  color-scheme: dark;
  font-family: var(--mono);
  font-size: .66rem;
}
.quota-readout { min-width: 0; margin: 0; overflow-wrap: anywhere; color: var(--paper-2); font-family: var(--mono); font-size: .66rem; line-height: 1.45; }
.quota-readout strong { color: var(--red); font-weight: 500; }
.quota-method { margin: .75rem 0 0; color: var(--muted); letter-spacing: .08em; text-transform: none; }

.history-year {
  position: absolute;
  left: 3vw;
  bottom: 5vh;
  color: rgba(238, 231, 215, 0.13);
  font-size: clamp(6rem, 19vw, 17rem);
  line-height: 0.72;
  letter-spacing: -0.06em;
  transition: opacity .45s ease;
}

.history-status {
  position: absolute;
  top: 5.4rem;
  left: 3vw;
  max-width: 17rem;
  color: rgba(238, 231, 215, 0.7);
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transition: opacity .45s ease;
}

.history-stage figcaption {
  position: absolute;
  right: 1.2rem;
  bottom: 1.2rem;
  color: rgba(238, 231, 215, 0.42);
  font-family: var(--mono);
  font-size: 0.53rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: opacity .45s ease;
}

.history-stage .archive-fragment figcaption {
  right: .1rem;
  bottom: -1.75rem;
  left: .1rem;
  color: #263039;
  font-size: .48rem;
  line-height: 1.25;
  letter-spacing: .055em;
  text-align: left;
  text-transform: none;
}

.history-steps {
  position: relative;
  z-index: 2;
  width: min(30rem, 42vw);
  margin: -100svh 4vw 0 auto;
  padding-bottom: 45vh;
}

.history-step {
  min-height: 105svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16vh 0;
  opacity: 0.38;
  transform: translateY(1.5rem);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.history-step.active { opacity: 1; transform: translateY(0); }

.history-step::before {
  display: block;
  width: 2.2rem;
  height: 1px;
  margin-bottom: 1.3rem;
  background: var(--gold);
  content: "";
}

.history-step .date { color: var(--gold); }

.history-step h3 {
  margin: 0.65rem 0 1rem;
  font-size: clamp(2.1rem, 4vw, 3.4rem);
}

.history-step p {
  margin: 0;
  padding: 1.25rem 1.3rem;
  border: 1px solid rgba(238, 231, 215, 0.12);
  background: rgba(6, 14, 21, 0.79);
  box-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(10px);
}

/* Threshold */
.threshold {
  position: relative;
  display: grid;
  min-height: 110svh;
  place-items: center;
  overflow: hidden;
  background: #071019;
}

.threshold-art {
  position: absolute;
  inset: -12%;
  background:
    linear-gradient(to bottom, #050c12 0, rgba(5, 12, 18, 0.2) 28%, rgba(5, 12, 18, 0.38) 64%, #071019 100%),
    url("assets/pacific-current-hero.png") 80% 65% / cover;
  filter: saturate(0.75) brightness(0.72);
  transform: scale(1.25);
}

.road-lines {
  position: absolute;
  inset: 44% -10% auto;
  height: 48%;
  perspective: 900px;
  transform: rotateX(62deg);
  transform-origin: center top;
}

.road-lines i {
  position: absolute;
  top: 0;
  left: 50%;
  width: 1px;
  height: 160%;
  background: linear-gradient(var(--gold), rgba(230, 184, 92, 0));
  box-shadow: 0 0 18px rgba(230, 184, 92, 0.4);
  transform-origin: top;
}

.road-lines i:nth-child(1) { transform: rotate(18deg); }
.road-lines i:nth-child(2) { transform: rotate(0); }
.road-lines i:nth-child(3) { transform: rotate(-18deg); }

.threshold-copy {
  position: relative;
  z-index: 2;
  width: min(52rem, calc(100% - 3rem));
  text-align: center;
  text-shadow: 0 2px 30px #000;
}

.threshold-copy p {
  color: var(--gold);
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.threshold-copy h2 { margin: 0; font-size: clamp(3rem, 8vw, 7.7rem); }

/* Summer */
.summer {
  padding: clamp(9rem, 15vw, 15rem) 0;
  background:
    radial-gradient(circle at 90% 30%, rgba(230, 184, 92, 0.08), transparent 38rem),
    #09151d;
}

.split-intro {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(3rem, 8vw, 8rem);
}

.split-intro header { position: sticky; top: 8rem; align-self: start; }
.split-intro h2 { margin-top: 1.2rem; }

.narrative-plate {
  position: relative;
  width: min(78rem, calc(100% - 3rem));
  margin: clamp(6rem, 12vw, 12rem) auto 0;
  overflow: hidden;
  border: 1px solid rgba(238, 231, 215, .2);
  background: #071019;
  box-shadow: 0 4rem 9rem rgba(0, 0, 0, .45);
}

.narrative-plate::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(5, 12, 18, .8), transparent 28%);
  content: "";
  pointer-events: none;
}

.narrative-plate img { display: block; width: 100%; height: auto; }
.narrative-plate figcaption { position: absolute; z-index: 2; right: 1.4rem; bottom: 1.2rem; left: 1.4rem; display: flex; justify-content: space-between; color: rgba(238,231,215,.78); font-family: var(--mono); font-size: .58rem; letter-spacing: .14em; text-transform: uppercase; }
.narrative-plate figcaption span { color: var(--gold); }

.bus-window {
  position: relative;
  width: min(72rem, calc(100% - 3rem));
  aspect-ratio: 16 / 8;
  margin: clamp(6rem, 12vw, 12rem) auto 0;
  overflow: hidden;
  border: 1px solid rgba(238, 231, 215, 0.24);
  border-radius: min(12vw, 9rem) min(12vw, 9rem) 0 0;
  background: #0d1d26;
  box-shadow: 0 4rem 9rem rgba(0, 0, 0, 0.45);
}

.window-sky {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 76% 22%, rgba(246, 207, 123, 0.68) 0 1px, transparent 2px),
    linear-gradient(#0c1720 12%, #38525d 62%, #bd9f72 100%);
}

.window-land {
  position: absolute;
  inset: 53% -5% 0;
  background:
    linear-gradient(18deg, transparent 0 26%, #101d20 27% 52%, transparent 53%) 0 0 / 34% 100% repeat-x,
    linear-gradient(to top, #061014, #132a29);
  filter: drop-shadow(0 -10px 25px rgba(0, 0, 0, 0.5));
}

.window-route {
  position: absolute;
  right: 12%;
  bottom: -3%;
  width: 58%;
  height: 46%;
  border-top: 2px solid rgba(230, 184, 92, 0.5);
  border-radius: 50% 0 0 0;
  transform: rotate(-7deg);
}

.window-route span {
  position: absolute;
  top: -4px;
  left: 36%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 24px var(--gold);
}

.badge {
  position: absolute;
  top: 8%;
  right: 7%;
  width: 7.5rem;
  padding: 0.7rem;
  border: 1px solid rgba(238, 231, 215, 0.45);
  background: rgba(238, 231, 215, 0.08);
  box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.28);
  transform: rotate(4deg);
  backdrop-filter: blur(5px);
}

.badge i { display: block; aspect-ratio: 1; margin-bottom: 0.55rem; background: rgba(238, 231, 215, 0.14); }
.badge span { display: block; font-family: var(--mono); font-size: 0.45rem; letter-spacing: 0.08em; }

.bus-window figcaption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  justify-content: space-between;
  padding: 0.9rem 1.2rem;
  color: rgba(238, 231, 215, 0.68);
  background: rgba(5, 12, 18, 0.78);
  font-family: var(--mono);
  font-size: 0.58rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

/* Encounters */
.encounters { background: #071019; }

.story {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(22rem, 0.88fr);
  min-height: 180svh;
  border-top: 1px solid var(--line);
}

.story:nth-of-type(odd) { background: #08141c; }
.story:nth-of-type(even) { background: #0a1720; }

.story-visual {
  position: sticky;
  top: 0;
  display: grid;
  height: 100svh;
  margin: 0;
  place-items: center;
  overflow: hidden;
  border-right: 1px solid var(--line);
  background:
    radial-gradient(circle at 50% 48%, color-mix(in srgb, var(--story) 12%, transparent), transparent 39%),
    linear-gradient(145deg, #0c1b24, #050d13);
}

.scene-image { display: block; width: 100%; height: 100%; object-fit: cover; }
.story-visual::after { position: absolute; inset: 0; background: linear-gradient(to top, rgba(5,12,18,.78), transparent 32%), linear-gradient(to right, transparent 70%, rgba(5,12,18,.18)); content: ""; pointer-events: none; }
.story-arun .scene-image { object-position: 72% center; }
.story-eric .scene-image { object-position: 69% center; }
.story-kai .scene-image { object-position: 65% center; }
.story-andre .scene-image { object-position: 70% center; }

.story-copy {
  align-self: center;
  max-width: 42rem;
  padding: 24svh clamp(2rem, 5vw, 5.5rem);
}

.story-number { color: var(--story); }

.story-copy h3 {
  margin: 0 0 0.5rem;
  font-size: clamp(4rem, 8vw, 8rem);
}

.story-copy .standfirst {
  margin-bottom: 2.2rem;
  color: var(--story);
  font-size: 1.3em;
  font-style: italic;
}

.story-copy blockquote {
  position: relative;
  margin: 2.8rem 0;
  padding: 0.3rem 0 0.3rem 1.4rem;
  border-left: 2px solid var(--story);
  color: #fff8e9;
  font-size: clamp(1.7rem, 3.2vw, 2.65rem);
  font-style: italic;
  line-height: 1.24;
}

.story-copy blockquote cite {
  display: block;
  margin-top: 0.9rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.55rem;
  font-style: normal;
  letter-spacing: 0.14em;
  line-height: 1.5;
  text-transform: uppercase;
}

.closing-line { color: #fff5df; font-size: 1.22em; font-style: italic; }

.composite-label {
  display: inline-block;
  margin: 0 0 1.2rem;
  padding: 0.35rem 0.55rem;
  border: 1px solid var(--story);
  color: var(--story);
  font-family: var(--mono);
  font-size: 0.55rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.field-note-toggle {
  margin-top: 1rem;
  padding: 0.65rem 0;
  border: 0;
  border-bottom: 1px solid var(--story);
  color: var(--paper);
  background: none;
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
}

.field-note {
  display: grid;
  grid-template-rows: 0fr;
  margin-top: 1.5rem;
  overflow: hidden;
  color: var(--paper-2);
  transition: grid-template-rows 0.45s ease;
}

.field-note > p { min-height: 0; margin: 0; overflow: hidden; }
.field-note.open { grid-template-rows: 1fr; }

.visual-caption {
  position: absolute;
  right: 1.2rem;
  bottom: 1.2rem;
  left: 1.2rem;
  margin: 0;
  color: rgba(238, 231, 215, 0.5);
  text-align: center;
  z-index: 2;
}

/* Arun scene */
.queue-world { position: relative; width: min(74%, 42rem); height: 62%; }

.queue-door {
  position: absolute;
  top: 3%;
  left: 50%;
  width: 8rem;
  height: 13rem;
  border: 1px solid rgba(227, 154, 82, 0.5);
  background: linear-gradient(to bottom, rgba(227, 154, 82, 0.2), rgba(227, 154, 82, 0.02));
  box-shadow: 0 0 70px rgba(227, 154, 82, 0.12);
  transform: translateX(-50%) perspective(300px) rotateX(-3deg);
}

.queue-door::after {
  position: absolute;
  right: 0.65rem;
  top: 50%;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--orange);
  content: "";
  box-shadow: 0 0 14px var(--orange);
}

.queue-door span {
  position: absolute;
  top: -2rem;
  left: 50%;
  color: var(--orange);
  font-family: var(--mono);
  font-size: 0.5rem;
  letter-spacing: 0.16em;
  transform: translateX(-50%);
}

.queue-dots { position: absolute; inset: 24% 0 0; perspective: 500px; }

.queue-dots i {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(227, 154, 82, 0.8);
  box-shadow: 0 0 10px rgba(227, 154, 82, 0.5);
  animation: wait-pulse 3.8s ease-in-out infinite;
}

@keyframes wait-pulse { 50% { opacity: 0.3; } }

/* Eric scene */
.restaurant-world { position: relative; width: min(82%, 48rem); height: 67%; border: 1px solid rgba(202, 104, 88, 0.28); }
.restaurant-world::before { position: absolute; inset: 0; background: linear-gradient(90deg, transparent 49.8%, rgba(238,231,215,.08) 50%, transparent 50.2%), linear-gradient(transparent 49.8%, rgba(238,231,215,.06) 50%, transparent 50.2%); background-size: 5rem 5rem; content: ""; }
.restaurant-sign { position: absolute; top: 9%; left: 9%; padding: .65rem .9rem; border: 1px solid rgba(202,104,88,.65); color: var(--red); font-family: var(--mono); font-size: .68rem; letter-spacing: .2em; box-shadow: 0 0 35px rgba(202,104,88,.22); }
.restaurant-sign span { animation: sign-flicker 6s steps(1) infinite; }
@keyframes sign-flicker { 0%, 7%, 9%, 100% { opacity: 1; } 8% { opacity: .2; } }
.restaurant-counter { position: absolute; right: 7%; bottom: 19%; width: 45%; height: 14%; border-top: 2px solid var(--red); border-bottom: 1px solid rgba(238,231,215,.2); }
.restaurant-table { position: absolute; left: 10%; bottom: 14%; width: 31%; height: 22%; border-top: 2px solid rgba(238,231,215,.6); }
.restaurant-table i { position: absolute; top: -1rem; width: 1.5rem; height: 1rem; border: 1px solid rgba(238,231,215,.35); }
.restaurant-table i:nth-child(1) { left: 10%; }.restaurant-table i:nth-child(2) { left: 45%; }.restaurant-table i:nth-child(3) { right: 8%; }
.receipt { position: absolute; right: 13%; top: 19%; display: flex; flex-direction: column; gap: .55rem; width: 7.6rem; padding: 1rem; background: #ddd5c3; color: #182127; box-shadow: 0 1rem 3rem #000; font-family: var(--mono); font-size: .48rem; letter-spacing: .08em; transform: rotate(4deg); }
.receipt span { padding-bottom: .45rem; border-bottom: 1px dashed rgba(21,33,39,.35); }.receipt b { color: var(--red); font-weight: 500; }

/* Kai scene */
.mixer-world { position: relative; width: min(86%, 52rem); height: 68%; border: 1px solid rgba(231,194,92,.22); background: linear-gradient(to bottom, rgba(231,194,92,.05), transparent); }
.mixer-stage { position: absolute; top: 12%; left: 50%; width: 30%; height: 18%; border: 1px solid rgba(231,194,92,.52); background: rgba(231,194,92,.08); transform: translateX(-50%); }
.mixer-stage::after { position: absolute; bottom: 24%; left: 50%; width: 7px; height: 18px; border-radius: 50% 50% 30% 30%; background: var(--gold); content: ""; box-shadow: 0 0 20px var(--gold); }
.mixer-crowd { position: absolute; inset: 36% 7% 7%; }
.mixer-crowd i { position: absolute; width: 5px; height: 7px; border-radius: 50% 50% 30% 30%; background: rgba(238,231,215,.52); }
.one-way { position: absolute; top: 12%; left: 7%; padding: .7rem; border: 1px solid rgba(238,231,215,.3); color: var(--paper-2); font-family: var(--mono); font-size: .48rem; letter-spacing: .12em; transform: rotate(-7deg); }.one-way strong { color: var(--gold); font-size: 1rem; }
.knock-door { position: absolute; right: 5%; top: 12%; width: 5.6rem; height: 9rem; border: 1px solid var(--gold); background: rgba(231,194,92,.05); }.knock-door i { position: absolute; right: .6rem; top: 50%; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 16px var(--gold); }.knock-door span { position: absolute; right: 0; bottom: -1.8rem; left: 0; text-align: center; color: var(--gold); font-family: var(--mono); font-size: .48rem; letter-spacing: .17em; }

/* Andre scene */
.ranking-world { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: clamp(1rem, 4vw, 3rem); width: min(82%, 48rem); }
.rank { display: flex; flex-direction: column; gap: .9rem; padding: 1.5rem; border: 1px solid rgba(97,170,165,.26); }
.rank span { margin-bottom: .7rem; color: var(--teal); font-family: var(--mono); font-size: .52rem; letter-spacing: .18em; }
.rank i { display: block; height: 1px; background: rgba(238,231,215,.22); }.rank i.selected { height: 3px; background: var(--teal); box-shadow: 0 0 14px rgba(97,170,165,.55); }
.rank-old i.selected { width: 43%; }.rank-new i.selected { width: 84%; }
.rank-arrow { color: var(--teal); font-size: 2rem; }
.scale-words { position: absolute; right: 0; bottom: -4.5rem; left: 0; display: flex; justify-content: space-between; color: var(--muted); font-family: var(--mono); font-size: .5rem; letter-spacing: .1em; text-transform: uppercase; }.scale-words b { color: var(--teal); font-weight: 500; }

/* Reckoning */
.reckoning {
  padding-bottom: clamp(9rem, 16vw, 17rem);
  background: #e9e1d1;
  color: var(--ink);
}

.reckoning .section-index { color: #9b6b24; }

.braid-stage {
  position: relative;
  width: min(82rem, calc(100% - 3rem));
  aspect-ratio: 12 / 5.6;
  margin: 0 auto clamp(5rem, 10vw, 9rem);
}

.braid-stage svg { width: 100%; height: 100%; overflow: visible; }
.braid-stage circle { fill: var(--ink); }
.braid-path { fill: none; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 1400; stroke-dashoffset: 1400; transition: stroke-dashoffset 2.2s cubic-bezier(.2,.7,.2,1); }
.braid-stage.visible .braid-path { stroke-dashoffset: 0; }
.arun-path { stroke: var(--orange); }.eric-path { stroke: var(--red); }.kai-path { stroke: #ba8c24; }.andre-path { stroke: var(--teal); }
.finish { position: absolute; right: 0; display: flex; flex-direction: column; width: 17rem; padding: .35rem .5rem .35rem 1.4rem; border-left: 2px solid currentColor; background: linear-gradient(90deg, rgba(232, 224, 209, 0), var(--paper) 17%); font-size: .86rem; line-height: 1.3; }
.finish b { font-family: var(--mono); font-size: .55rem; letter-spacing: .18em; text-transform: uppercase; }.finish-arun { top: 9%; color: #b87033; }.finish-eric { top: 32%; color: #ad4f42; }.finish-kai { top: 56%; color: #8d6a19; }.finish-andre { top: 80%; color: #477e7a; }

.reckoning-copy { max-width: var(--prose); color: #29353a; }
.reckoning-copy p:nth-child(2) { margin: 2.8rem 0; color: var(--ink); font-size: 1.7em; font-style: italic; line-height: 1.35; }

.thesis-interlude {
  width: min(70rem, calc(100% - 3rem));
  margin: clamp(8rem, 15vw, 15rem) auto 0;
  padding-top: 2rem;
  border-top: 1px solid rgba(21,33,39,.22);
  font-size: clamp(2.4rem, 6vw, 6.4rem);
  line-height: .98;
  letter-spacing: -.04em;
}
.thesis-interlude p { max-width: 15ch; margin-bottom: .25em; }.thesis-interlude p:last-child { margin-left: auto; color: #9b6b24; font-style: italic; text-align: right; }

/* The edge */
.edge { padding: clamp(9rem, 15vw, 16rem) 0; background: #08141c; }
.edge .split-intro h2 { max-width: 12ch; }

.ante-stage { position: relative; width: min(82rem, calc(100% - 3rem)); margin: clamp(7rem, 12vw, 12rem) auto; overflow: hidden; border: 1px solid var(--line); background: #061019; box-shadow: 0 4rem 10rem rgba(0,0,0,.42); }
.ante-stage > img { display: block; width: 100%; height: auto; }
.ante-stage::after { position: absolute; inset: 0; background: linear-gradient(to right, transparent 43%, rgba(5,12,18,.1) 60%, rgba(5,12,18,.28)); content: ""; pointer-events: none; }
.ante-inscription { position: absolute; z-index: 2; top: 22%; right: 6%; width: 41%; }
.ante-inscription > span { color: var(--gold); font-family: var(--mono); font-size: .56rem; letter-spacing: .18em; text-transform: uppercase; }
.ante-inscription blockquote { margin: 2rem 0 0; color: var(--paper); font-size: clamp(1.8rem, 3.4vw, 3.9rem); font-style: italic; line-height: 1.07; letter-spacing: -.025em; }
.ante-stage figcaption { position: absolute; z-index: 2; right: 2rem; bottom: 1.4rem; max-width: 35rem; color: rgba(238,231,215,.48); font-family: var(--mono); font-size: .52rem; line-height: 1.6; text-align: right; text-transform: uppercase; }
.author-grid-solo { display: block; }
.author-grid-solo .author-copy { max-width: var(--prose); margin-left: auto; }

.cohort-field {
  position: relative;
  width: min(74rem, calc(100% - 3rem));
  min-height: 50rem;
  margin: clamp(7rem, 12vw, 12rem) auto;
  padding: 5rem clamp(1rem, 4vw, 4rem) 8rem;
  border: 1px solid var(--line);
  background: radial-gradient(circle at 50% 42%, rgba(107,167,160,.09), transparent 30rem), rgba(5,12,18,.55);
}

.cohort-grid { display: grid; grid-template-columns: repeat(21, 1fr); gap: clamp(.35rem, .7vw, .7rem); max-width: 58rem; margin: 0 auto; }
.cohort-grid i { display: block; aspect-ratio: 1; border: 1px solid rgba(238,231,215,.25); border-radius: 2px; background: rgba(238,231,215,.04); opacity: 0; transform: translateY(8px); transition: opacity .35s ease, transform .35s ease, background .35s ease; }
.cohort-field.visible .cohort-grid i { opacity: 1; transform: translateY(0); }
.cohort-grid i.friend { border-color: rgba(230,184,92,.7); background: rgba(230,184,92,.15); box-shadow: 0 0 12px rgba(230,184,92,.15); }
.cohort-grid i.restless { background: var(--gold); box-shadow: 0 0 18px var(--gold); }
.cohort-annotation { position: absolute; left: clamp(1rem,4vw,4rem); bottom: 2.5rem; color: var(--muted); font-family: var(--mono); font-size: .58rem; letter-spacing: .15em; text-transform: uppercase; }.cohort-annotation span { display: block; color: var(--paper); font-family: var(--serif); font-size: 4rem; letter-spacing: -.04em; line-height: .9; }
.friend-bracket { position: absolute; right: 7%; top: 24%; padding: .5rem .7rem; border: 1px solid var(--gold); color: var(--gold); font-family: var(--mono); font-size: .5rem; letter-spacing: .12em; text-transform: uppercase; opacity: 0; transition: opacity 1s 1.6s ease; }.cohort-field.visible .friend-bracket { opacity: 1; }
.cohort-field figcaption { position: absolute; right: clamp(1rem,4vw,4rem); bottom: 2.7rem; max-width: 28rem; color: rgba(238,231,215,.45); font-family: var(--mono); font-size: .52rem; line-height: 1.6; text-align: right; }

.author-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(3rem, 8vw, 8rem); align-items: start; }
.application { position: sticky; top: 8rem; padding: 1.5rem; border: 1px solid rgba(230,184,92,.45); background: #e6dfd0; color: var(--ink); box-shadow: 0 2rem 5rem rgba(0,0,0,.35); transform: rotate(-1deg); }
.application-label { color: #9b6b24; }
.application dl { margin: 1.5rem 0 0; font-family: var(--mono); font-size: .62rem; line-height: 1.55; }
.application dl div { display: grid; grid-template-columns: 7rem 1fr; gap: 1rem; padding: .8rem 0; border-bottom: 1px dotted rgba(21,33,39,.3); }.application dt { color: #6a7476; text-transform: uppercase; }.application dd { margin: 0; }.application .blank { color: #9b6b24; }.application .blank i { display: inline-block; width: .55rem; height: 1rem; background: #9b6b24; vertical-align: -.15rem; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Coda */
.coda { position: relative; display: grid; min-height: 130svh; place-items: center; overflow: hidden; background: #050c12; }
.fork { position: absolute; inset: 0; opacity: .75; }.fork i { position: absolute; left: 50%; bottom: -15%; width: 1px; height: 82%; background: linear-gradient(to top, rgba(230,184,92,0), var(--gold)); transform-origin: bottom; box-shadow: 0 0 18px rgba(230,184,92,.35); }.fork i:nth-child(1) { transform: rotate(-26deg); }.fork i:nth-child(2) { transform: rotate(0); }.fork i:nth-child(3) { transform: rotate(26deg); }
.coda::before { position: absolute; inset: 0; background: radial-gradient(circle at 50% 78%, rgba(230,184,92,.17), transparent 31rem), linear-gradient(to bottom, rgba(5,12,18,.4), #050c12 82%); content: ""; }
.coda-copy { position: relative; z-index: 2; width: min(70rem, calc(100% - 3rem)); padding: 10rem 0; text-align: center; text-shadow: 0 2px 25px #000; }
.coda-copy > p:first-child { max-width: 40rem; margin: 0 auto 5rem; color: var(--paper-2); font-style: italic; }
.coda h2 { max-width: 17ch; margin: 0 auto; font-size: clamp(2.8rem, 7vw, 7.2rem); }
.last-line { margin: .4em 0 0; color: var(--gold); font-size: clamp(3.2rem, 8vw, 8rem); font-style: italic; letter-spacing: -.04em; line-height: .95; }
.afterword { max-width: 38rem; margin: 5rem auto 0; color: var(--muted); font-family: var(--sans); font-size: .88rem; line-height: 1.65; }

/* Notes */
.notes { padding: clamp(8rem, 13vw, 13rem) 0 4rem; background: #e9e1d1; color: var(--ink); }
.notes-grid { display: grid; grid-template-columns: .7fr 1.3fr; gap: clamp(3rem, 8vw, 8rem); }.notes .section-index { color: #9b6b24; }.notes h2 { font-size: clamp(2.8rem,6vw,5.7rem); }.notes .prose { color: #344146; font-size: 1rem; }.source-list { padding-left: 1.3rem; font-family: var(--sans); font-size: .78rem; line-height: 1.65; }.source-list li { margin-bottom: .75rem; }.source-list a { text-decoration-color: rgba(21,33,39,.3); text-underline-offset: 3px; }
.notes footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; margin-top: 7rem; padding-top: 1.5rem; border-top: 1px solid rgba(21,33,39,.25); color: #5f6a6c; font-family: var(--mono); font-size: .58rem; letter-spacing: .08em; line-height: 1.6; text-transform: uppercase; }.notes footer p { margin: 0; }.notes footer a { color: #8b601f; }

/* Reveals */
.reveal-on-scroll { opacity: .35; transform: translateY(2rem); transition: opacity 1s ease, transform 1s cubic-bezier(.2,.7,.2,1); }
.reveal-on-scroll.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 900px) {
  .promise-grid,
  .split-intro,
  .author-grid,
  .notes-grid { grid-template-columns: 1fr; }

  .lazarus,
  .split-intro header,
  .application { position: relative; top: auto; }

  .history-steps { width: min(31rem, calc(100% - 2rem)); margin-right: auto; }
  .history-step { min-height: 100svh; justify-content: flex-end; padding-bottom: 10vh; }
  .history-year { bottom: 28vh; }
  .history-status { left: 1rem; }

  .history-instrument,
  .quota-aperture {
    top: 4.6rem;
    right: 1rem;
    bottom: auto;
    left: 1rem;
    width: auto;
    height: 57svh;
    min-height: 29rem;
    padding: 1rem;
  }
  .instrument-head,
  .quota-head { grid-template-columns: 8rem 1fr; }
  .instrument-head h3,
  .quota-head h3 { font-size: clamp(1.4rem, 4vw, 2.2rem); }
  .instrument-plot svg,
  .quota-plot { min-height: 14rem; }
  .quota-inspector { grid-template-columns: 8rem minmax(9rem, 1fr) 1.3fr; }
  .history-step[data-state="fog"] { padding-top: 62svh; }

  .angel-archive,
  .quota-map-archive,
  .gold-map-archive,
  .hart-celler-archive,
  .bay-archive { top: 5.2rem; left: 1.2rem; width: min(76vw, 36rem); }
  .gold-map-archive { left: 17vw; }
  .angel-archive { left: 9vw; }
  .angel-archive { height: clamp(6.5rem, 18vw, 10rem); }
  .quota-map-archive,
  .gold-map-archive,
  .hart-celler-archive,
  .bay-archive { height: clamp(9rem, 25vw, 14rem); }
  .hart-celler-archive { left: 14vw; width: min(66vw, 34rem); }
  .exclusion-act-archive,
  .act-1990-archive { top: 5.2rem; left: 1.2rem; width: min(27vw, 13rem); height: clamp(15rem, 46vw, 25rem); }
  .exclusion-act-archive { left: 54vw; width: min(25vw, 12rem); }
  .act-1990-archive { left: 52vw; width: min(25vw, 12rem); }
  .paper-angel-layer,
  .history-paper-layer { bottom: 24vh; left: -12vw; width: min(102vw, 58rem); }
  .paper-flow,
  .history-current-layer { top: 19vh; left: -8vw; width: 106vw; height: 43vh; }
  .paper-quota-gate { top: 19vh; left: -8vw; width: 106vw; }
  .paper-quota-ledger { top: 43vh; bottom: auto; left: 1rem; width: min(38rem, calc(100vw - 2rem)); }

  .story { grid-template-columns: 1fr; min-height: 0; }
  .story-visual { position: relative; height: 70svh; border-right: 0; border-bottom: 1px solid var(--line); }
  .story-copy { padding: 7rem 1.5rem 9rem; margin-inline: auto; }

  .braid-stage { aspect-ratio: 1 / 1; }
  .finish { width: 12rem; font-size: .72rem; }
  .cohort-grid { grid-template-columns: repeat(17, 1fr); }
  .friend-bracket { top: 22%; }
}

@media (max-width: 620px) {
  .site-chrome { grid-template-columns: 1fr 6rem auto; padding-inline: .8rem; }
  .wordmark { letter-spacing: .12em; }
  .hero-copy { padding-top: 7rem; }
  .hero h1 { font-size: clamp(2.5rem, 11.2vw, 4rem); }
  .hero .dek { max-width: 29rem; }
  .scroll-prompt span { display: none; }
  .promise-grid { gap: 4rem; }
  .evidence-grid { grid-template-columns: 1fr; }
  .signal-number span { font-size: 5.6rem; }
  .room-note { grid-template-columns: 1fr; }
  .room-note cite { grid-column: 1; }
  .chapter-head h2, .split-intro h2 { font-size: clamp(3rem, 14vw, 5rem); }

  .history-stage figcaption { display: none; }
  .history-year { font-size: 27vw; }
  .history-step p { font-size: 1rem; }
  .history-instrument,
  .quota-aperture { top: 4.2rem; right: 1rem; left: 1rem; width: calc(100vw - 2rem); max-width: calc(100vw - 2rem); height: 65svh; min-height: 33rem; padding: .8rem; }
  .instrument-head,
  .quota-head { display: block; }
  .instrument-head p,
  .quota-head p { margin-bottom: .35rem; }
  .instrument-head h3,
  .quota-head h3 { max-width: 24ch; font-size: 1.35rem; }
  .instrument-plot,
  .quota-plot-wrap { margin-top: 0; }
  .instrument-plot svg,
  .quota-plot { min-height: 13rem; }
  .quota-inspector { grid-template-columns: minmax(0, 1fr); gap: .35rem; padding: .5rem 0; }
  .quota-inspector label { grid-column: auto; }
  .quota-inspector select { max-width: 100%; text-overflow: ellipsis; }
  .quota-readout { font-size: .56rem; }
  .quota-method { margin-top: .45rem; font-size: .42rem; line-height: 1.35; }
  .history-step[data-state="fog"] { padding-top: 71svh; }

  .angel-archive,
  .quota-map-archive,
  .gold-map-archive,
  .hart-celler-archive,
  .bay-archive { top: 4.8rem; left: .8rem; width: calc(100vw - 1.6rem); }
  .gold-map-archive,
  .angel-archive { left: 7vw; width: 88vw; }
  .gold-map-archive { left: 12vw; width: 84vw; }
  .angel-archive { height: 6.2rem; }
  .quota-map-archive,
  .gold-map-archive,
  .hart-celler-archive,
  .bay-archive { height: 8.3rem; }
  .hart-celler-archive { left: 10vw; width: 88vw; height: 10.5rem; }
  .exclusion-act-archive,
  .act-1990-archive { top: 4.8rem; left: .8rem; width: 34vw; height: 13.5rem; }
  .exclusion-act-archive { left: 61vw; width: 30vw; }
  .act-1990-archive { left: 58vw; width: 32vw; }
  .archive-fragment::before { inset: -.42rem -.35rem -1.7rem; }
  .archive-fragment figcaption { display: block; bottom: -1.25rem; font-size: .39rem; }
  .paper-angel-layer,
  .history-paper-layer { bottom: 35vh; left: -21vw; width: 127vw; }
  .paper-flow,
  .history-current-layer { top: 15vh; left: -17vw; width: 123vw; height: 40vh; }
  .paper-quota-gate { top: 17vh; left: -16vw; width: 121vw; }
  .paper-quota-ledger { top: 39vh; left: .75rem; width: calc(100vw - 1.5rem); padding: .65rem .75rem .75rem; }
  .paper-quota-summary { grid-template-columns: 1fr; gap: .25rem; }
  .paper-quota-summary p { margin: 0; }
  .paper-quota-summary h3 { font-size: 1.55rem; }
  .paper-quota-summary > div { grid-column: 1; font-size: .36rem; }
  .paper-quota-inspector { grid-template-columns: 5.5rem minmax(0,1fr); gap: .4rem .6rem; margin-top: .5rem; padding-top: .5rem; }
  .paper-quota-inspector .quota-readout { grid-column: 2; font-size: .48rem; }
  .paper-quota-method { display: none; }

  .narrative-plate { aspect-ratio: 4 / 5; }
  .narrative-plate img { width: 100%; height: 100%; object-fit: cover; object-position: 59% center; }
  .narrative-plate figcaption { gap: 1rem; font-size: .48rem; line-height: 1.45; }

  .story-visual { height: 64svh; min-height: 31rem; }
  .story-copy h3 { font-size: 4.6rem; }
  .ranking-world { grid-template-columns: 1fr; gap: .6rem; }
  .rank-arrow { transform: rotate(90deg); text-align: center; }
  .scale-words { bottom: -3rem; }

  .braid-stage { display: grid; aspect-ratio: auto; min-height: 39rem; }
  .braid-stage svg { position: absolute; inset: 0; }
  .finish { right: auto; left: 28%; width: 68%; }.finish-arun { top: 7%; }.finish-eric { top: 31%; }.finish-kai { top: 55%; }.finish-andre { top: 79%; }
  .thesis-interlude { font-size: 2.7rem; }

  .ante-stage { overflow: visible; }
  .ante-stage::after { display: none; }
  .ante-stage > img { aspect-ratio: 4 / 3; object-fit: cover; object-position: 30% center; }
  .ante-inscription { position: relative; top: auto; right: auto; width: auto; padding: 2.4rem 1.2rem 4rem; }
  .ante-inscription blockquote { font-size: 2.2rem; }
  .ante-stage figcaption { right: 1.2rem; bottom: 1.1rem; left: 1.2rem; max-width: none; text-align: left; }
  .notes footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  #ambient-current { display: none; }
  .reveal-on-scroll { opacity: 1; transform: none; }
  .braid-path { stroke-dashoffset: 0; }
  .history-step { opacity: 1; transform: none; }
}
