@import url('https://fonts.googleapis.com/css2?family=Alegreya:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=IBM+Plex+Mono:wght@400;500;600&family=IBM+Plex+Sans:wght@400;500;600;700&display=swap');

:root {
  --ink: #11252d;
  --ink-soft: #35525a;
  --deep: #0a151a;
  --water: #1c5d68;
  --water-deep: #103f4b;
  --foam: #eef2e8;
  --paper: #e8eadc;
  --paper-warm: #d8d3b9;
  --peat: #6b5a43;
  --moss: #9ba86f;
  --reed: #c6be83;
  --amber: #d79b52;
  --coral: #d17a66;
  --line: rgba(17, 37, 45, 0.19);
  --line-light: rgba(238, 242, 232, 0.2);
  --shadow: 0 24px 80px rgba(10, 21, 26, 0.16);
  --sans: 'IBM Plex Sans', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --serif: 'Alegreya', Georgia, serif;
  --mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;
  --measure: 70rem;
}

* { box-sizing: border-box; }

html {
  background: var(--deep);
  color: var(--ink);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 280px;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

body::selection { background: var(--amber); color: var(--deep); }

a { color: inherit; }
a:hover { color: var(--water-deep); }

button, input { font: inherit; }
button { cursor: pointer; }

:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  top: 0.6rem;
  left: 0.6rem;
  z-index: 100;
  padding: 0.65rem 0.9rem;
  border: 2px solid var(--amber);
  background: var(--deep);
  color: var(--foam);
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(238, 242, 232, 0.12);
  background: rgba(10, 21, 26, 0.94);
  color: var(--foam);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.1rem;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  color: var(--foam);
  text-decoration: none;
  white-space: nowrap;
}

.brand-mark {
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
}

.brand-name {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.nav {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  gap: clamp(0.65rem, 1.4vw, 1.3rem);
  overflow-x: auto;
  min-width: 0;
  scrollbar-width: none;
}

.nav::-webkit-scrollbar { display: none; }

.nav a,
.lang-link {
  color: rgba(238, 242, 232, 0.75);
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav a:hover,
.nav a:focus-visible,
.lang-link:hover,
.lang-link:focus-visible { color: var(--amber); }

.lang-link {
  padding: 0.52rem 0.68rem;
  border: 1px solid rgba(238, 242, 232, 0.28);
}

.hero {
  position: relative;
  isolation: isolate;
  min-height: min(54rem, calc(100vh - 4.1rem));
  overflow: hidden;
  background:
    radial-gradient(circle at 84% 22%, rgba(122, 172, 157, 0.24), transparent 29rem),
    linear-gradient(135deg, #0a171d 0%, #123b47 54%, #285c61 100%);
  color: var(--foam);
}

.hero::before,
.hero::after {
  position: absolute;
  z-index: -1;
  display: block;
  content: "";
  pointer-events: none;
}

.hero::before {
  inset: 0;
  opacity: 0.24;
  background-image:
    linear-gradient(90deg, transparent 49.5%, rgba(232, 234, 220, 0.09) 50%, transparent 50.5%),
    linear-gradient(0deg, transparent 49.5%, rgba(232, 234, 220, 0.09) 50%, transparent 50.5%);
  background-size: 6rem 6rem;
  mask-image: linear-gradient(120deg, transparent 7%, black 45%, transparent 95%);
}

.hero::after {
  right: -11rem;
  bottom: -17rem;
  width: 46rem;
  height: 46rem;
  border: 1px solid rgba(238, 242, 232, 0.2);
  border-radius: 52% 48% 45% 55%;
  box-shadow:
    0 0 0 2rem rgba(238, 242, 232, 0.03),
    0 0 0 5rem rgba(238, 242, 232, 0.03),
    0 0 0 9rem rgba(238, 242, 232, 0.03),
    0 0 0 14rem rgba(238, 242, 232, 0.02);
  transform: rotate(-18deg);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(26rem, 1.08fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 6rem);
  min-height: min(54rem, calc(100vh - 4.1rem));
  padding-block: clamp(4rem, 8vw, 7.5rem);
}

.eyebrow,
.section-kicker,
.mini-label,
.status-tag,
.source-kind,
.map-note,
.data-label,
.timeline-type {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.35;
  text-transform: uppercase;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--amber);
}

.eyebrow::before {
  width: 2.7rem;
  height: 1px;
  background: currentColor;
  content: "";
}

.hero h1 {
  max-width: 10ch;
  margin: 1.5rem 0 1.25rem;
  color: var(--foam);
  font-family: var(--serif);
  font-size: clamp(3.9rem, 9vw, 8.6rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.82;
}

.title-break {
  display: block;
  margin-top: 1.05rem;
  color: var(--reed);
  font-size: 0.56em;
  font-style: italic;
  letter-spacing: -0.025em;
  line-height: 0.92;
}

.hero-lede {
  max-width: 44rem;
  color: rgba(238, 242, 232, 0.79);
  font-family: var(--serif);
  font-size: clamp(1.24rem, 2vw, 1.65rem);
  line-height: 1.3;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.button,
.button-quiet,
.filter-button,
.core-button {
  display: inline-flex;
  min-height: 2.85rem;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  padding: 0.72rem 1rem;
  font-family: var(--mono);
  font-size: 0.73rem;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-decoration: none;
  text-transform: uppercase;
}

.button {
  background: var(--amber);
  color: var(--deep);
}

.button:hover,
.button:focus-visible { background: #efba6d; color: var(--deep); }

.button-quiet {
  border-color: rgba(238, 242, 232, 0.35);
  color: var(--foam);
}

.button-quiet:hover,
.button-quiet:focus-visible { border-color: var(--amber); color: var(--amber); }

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
  margin-top: 3.4rem;
  color: rgba(238, 242, 232, 0.63);
  font-family: var(--mono);
  font-size: 0.7rem;
}

.hero-meta strong { display: block; color: var(--foam); font-weight: 500; }

.hero-figure {
  position: relative;
  min-width: 0;
}

.hero-figure-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.8rem;
  color: rgba(238, 242, 232, 0.7);
}

.figure-caption {
  max-width: 20rem;
  font-family: var(--serif);
  font-size: 1rem;
  line-height: 1.15;
}

.hero-map,
.map-panel {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(238, 242, 232, 0.25);
  background: rgba(8, 26, 32, 0.48);
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.24);
}

.hero-map { aspect-ratio: 1.1 / 1; }
.hero-map svg,
.map-panel svg { display: block; width: 100%; height: 100%; }

.map-grid-line { stroke: rgba(238, 242, 232, 0.16); stroke-width: 0.7; vector-effect: non-scaling-stroke; }
.map-coast { fill: #cdd2bd; stroke: rgba(238, 242, 232, 0.8); stroke-width: 1; vector-effect: non-scaling-stroke; }
.map-coast-far { fill: #879d88; stroke: rgba(238, 242, 232, 0.26); stroke-width: 1; vector-effect: non-scaling-stroke; }
.map-land { fill: #aeb38e; stroke: rgba(238, 242, 232, 0.72); stroke-width: 1.15; vector-effect: non-scaling-stroke; }
.map-land-accent { fill: #d8c790; stroke: rgba(238, 242, 232, 0.76); stroke-width: 1; vector-effect: non-scaling-stroke; }
.map-water { fill: #15505d; }
.map-water-light { fill: #1d6972; opacity: 0.6; }
.map-river { fill: none; stroke: #d9d3a4; stroke-width: 2; opacity: 0.8; vector-effect: non-scaling-stroke; }
.map-tsunami-primary { stroke: var(--coral); stroke-width: 4; opacity: 0.9; }
.map-tsunami-secondary { stroke: var(--coral); stroke-width: 2; opacity: 0.6; }
.map-contour { fill: none; stroke: rgba(238, 242, 232, 0.18); stroke-width: 1; vector-effect: non-scaling-stroke; }
.map-marker { fill: var(--amber); stroke: var(--deep); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.map-label { fill: rgba(238, 242, 232, 0.82); font-family: var(--mono); font-size: 13px; letter-spacing: 0.05em; text-transform: uppercase; }
.map-label-small { fill: rgba(238, 242, 232, 0.58); font-family: var(--mono); font-size: 10px; letter-spacing: 0.04em; }

.stage { opacity: 0; visibility: hidden; transition: opacity 260ms ease; }
.stage-0 { opacity: 1; visibility: visible; }

#heroMap[data-active-stage="0"] .stage-0,
#heroMap[data-active-stage="1"] .stage-1,
#heroMap[data-active-stage="2"] .stage-2,
#heroMap[data-active-stage="3"] .stage-3,
#seaMap[data-active-stage="0"] .stage-0,
#seaMap[data-active-stage="1"] .stage-1,
#seaMap[data-active-stage="2"] .stage-2,
#seaMap[data-active-stage="3"] .stage-3 { opacity: 1; visibility: visible; }

.map-legend {
  position: absolute;
  right: 0.9rem;
  bottom: 0.9rem;
  max-width: 13rem;
  padding: 0.65rem 0.72rem;
  border-left: 2px solid var(--amber);
  background: rgba(10, 21, 26, 0.78);
  color: rgba(238, 242, 232, 0.78);
  font-family: var(--mono);
  font-size: 0.66rem;
  line-height: 1.35;
}

.chapter {
  padding-block: clamp(5rem, 11vw, 10rem);
  border-bottom: 1px solid var(--line);
}

.chapter-dark {
  background: var(--deep);
  color: var(--foam);
}

.chapter-water {
  background:
    radial-gradient(circle at 88% 12%, rgba(111, 177, 161, 0.17), transparent 24rem),
    linear-gradient(135deg, #123b47, #194e5a 56%, #0d2b34);
  color: var(--foam);
}

.chapter-peat {
  background: #d1c6a7;
  background-image: linear-gradient(rgba(107, 90, 67, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(107, 90, 67, 0.06) 1px, transparent 1px);
  background-size: 2.5rem 2.5rem;
}

.section-head {
  display: grid;
  grid-template-columns: minmax(10rem, 0.34fr) minmax(0, 1fr);
  gap: 2rem;
  margin-bottom: clamp(2.6rem, 6vw, 5rem);
}

.section-kicker { color: var(--water); }
.chapter-dark .section-kicker,
.chapter-water .section-kicker { color: var(--amber); }

.section-head h2,
.prose h2 {
  max-width: 18ch;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.5rem, 5.8vw, 5.5rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.92;
}

.section-head p {
  max-width: 48rem;
  margin: 1.45rem 0 0;
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: clamp(1.15rem, 1.9vw, 1.5rem);
  line-height: 1.28;
}

.chapter-dark .section-head p,
.chapter-water .section-head p { color: rgba(238, 242, 232, 0.72); }

.prose {
  max-width: 53rem;
  min-width: 0;
}

.claim-grid > *,
.evidence-layout > *,
.core-grid > *,
.ecology-grid > *,
.people-grid > *,
.dna-layout > *,
.footer-grid > * { min-width: 0; }

.prose p {
  margin: 0 0 1.35rem;
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: clamp(1.15rem, 1.9vw, 1.46rem);
  line-height: 1.4;
}

.chapter-dark .prose p,
.chapter-water .prose p { color: rgba(238, 242, 232, 0.76); }

.source-ref {
  color: var(--water);
  font-family: var(--mono);
  font-size: 0.68em;
  font-weight: 600;
  text-decoration: none;
  vertical-align: super;
}

.chapter-dark .source-ref,
.chapter-water .source-ref { color: var(--amber); }

.claim-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(18rem, 0.82fr);
  gap: clamp(2rem, 7vw, 8rem);
  align-items: start;
}

.quote-panel {
  padding: clamp(1.4rem, 3vw, 2.8rem);
  border: 1px solid rgba(17, 37, 45, 0.22);
  border-top: 5px solid var(--amber);
  background: rgba(238, 242, 232, 0.38);
}

.quote-panel .mini-label { color: var(--peat); }
.quote-panel blockquote {
  margin: 1rem 0 0;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.75rem, 3vw, 3rem);
  font-style: italic;
  line-height: 1;
}

.claim-conclusion {
  margin-top: 1.9rem;
  padding: 1.1rem 1.25rem;
  border-left: 3px solid var(--water);
  background: rgba(216, 211, 185, 0.46);
  color: var(--ink);
  font-size: 1rem;
  font-weight: 600;
}

.scale-stack {
  display: grid;
  gap: 0.65rem;
}
.scale-stack-spaced { margin-top: 1.35rem; }
.map-note.map-note-peat { color: var(--peat); }

.scale-card {
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr);
  gap: 0.75rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}

.scale-card:last-child { border-bottom: 1px solid var(--line); }
.scale-index { color: var(--water); font-family: var(--mono); font-size: 0.75rem; }
.scale-card h3 { margin: 0; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; line-height: 1.05; }
.scale-card p { margin: 0.35rem 0 0; color: var(--ink-soft); font-family: var(--mono); font-size: 0.72rem; line-height: 1.4; }
.scale-card small { display: block; margin-top: 0.4rem; color: var(--water); font-family: var(--mono); font-size: 0.68rem; text-transform: uppercase; }

.map-intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: end;
  margin-bottom: 2rem;
}

.map-intro-grid p { margin: 0; color: rgba(238, 242, 232, 0.7); font-family: var(--serif); font-size: 1.25rem; }

.map-interface {
  padding: 1rem;
  border: 1px solid rgba(238, 242, 232, 0.2);
  background: rgba(8, 26, 32, 0.42);
}

.map-interface-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
  color: rgba(238, 242, 232, 0.72);
}

.map-interface-head strong { color: var(--foam); font-family: var(--serif); font-size: 1.45rem; font-weight: 500; }
.map-interface-head span { font-family: var(--mono); font-size: 0.67rem; text-transform: uppercase; }

.map-panel { aspect-ratio: 1.9 / 1; }
.map-panel .map-legend { max-width: 18rem; }
.map-panel .stage { transition-duration: 400ms; }

.range-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.8rem;
  margin-top: 1rem;
  color: rgba(238, 242, 232, 0.62);
  font-family: var(--mono);
  font-size: 0.66rem;
  text-transform: uppercase;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--amber);
}

.stage-readout {
  display: grid;
  grid-template-columns: minmax(9rem, 0.3fr) minmax(0, 1fr);
  gap: 1rem;
  padding-top: 1.05rem;
  color: rgba(238, 242, 232, 0.73);
}

.stage-readout strong { display: block; color: var(--amber); font-family: var(--serif); font-size: 1.7rem; font-weight: 500; line-height: 1; }
.stage-readout p { margin: 0; font-family: var(--serif); font-size: 1.05rem; line-height: 1.3; }
.map-note { margin-top: 0.9rem; color: rgba(238, 242, 232, 0.51); }

.callout-line {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  margin-top: 1.7rem;
  color: var(--amber);
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2.5vw, 2.25rem);
  font-style: italic;
}

.callout-line::before { width: 4rem; height: 1px; background: currentColor; content: ""; }

.evidence-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(16rem, 0.72fr);
  gap: clamp(2rem, 7vw, 6rem);
  align-items: start;
}

.evidence-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid rgba(17, 37, 45, 0.2);
  background: rgba(17, 37, 45, 0.2);
}

.evidence-card {
  min-height: 15rem;
  padding: 1.5rem;
  background: var(--paper);
}

.evidence-card:nth-child(2n) { background: #e1e1d1; }
.evidence-card:last-child { grid-column: 1 / -1; min-height: auto; background: #d6d0b5; }
.evidence-card-index { color: var(--water); font-family: var(--mono); font-size: 0.72rem; }
.evidence-card h3 { margin: 2.25rem 0 0.25rem; font-family: var(--serif); font-size: 2rem; font-weight: 500; line-height: 1; }
.evidence-card .data-label { color: var(--ink-soft); }
.evidence-card p { margin: 0.8rem 0 0; color: var(--ink-soft); font-family: var(--serif); font-size: 1.08rem; line-height: 1.35; }

.method-card {
  position: sticky;
  top: 6rem;
  padding: 1.5rem;
  border-top: 5px solid var(--water);
  background: var(--deep);
  color: var(--foam);
}

.method-card .mini-label { color: var(--amber); }
.method-card h3 { margin: 1rem 0 0.8rem; color: var(--foam); font-family: var(--serif); font-size: 2.2rem; font-weight: 500; line-height: 0.98; }
.method-card p { margin: 0; color: rgba(238, 242, 232, 0.69); font-family: var(--serif); font-size: 1.1rem; line-height: 1.3; }

.core-grid {
  display: grid;
  grid-template-columns: minmax(15rem, 0.55fr) minmax(0, 1.45fr);
  gap: clamp(2rem, 7vw, 7rem);
  align-items: center;
}

.core-figure { min-width: 0; }
.core-shell {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 34rem;
  padding: 1.5rem 1.7rem 1.7rem;
  overflow: hidden;
  border: 1px solid rgba(17, 37, 45, 0.3);
  background: #b5aa8e;
  box-shadow: var(--shadow);
}

.core-shell::before,
.core-shell::after {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 9px;
  border: 1px solid rgba(17, 37, 45, 0.22);
  background: rgba(238, 242, 232, 0.22);
  content: "";
}

.core-shell::before { left: 1rem; }
.core-shell::after { right: 1rem; }

.core-line {
  position: absolute;
  top: 1.7rem;
  bottom: 1.7rem;
  left: 50%;
  width: min(68%, 11rem);
  overflow: hidden;
  border: 2px solid rgba(17, 37, 45, 0.27);
  border-radius: 45% 55% 42% 58% / 5% 8% 4% 6%;
  background: #76644b;
  transform: translateX(-50%);
}

.core-layer {
  position: relative;
  display: flex;
  min-height: 5.5rem;
  align-items: center;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(17, 37, 45, 0.23);
  color: rgba(238, 242, 232, 0.9);
  transition: filter 180ms ease, opacity 180ms ease;
}

.core-layer[data-layer="surface"] { min-height: 7.3rem; background: #397177; }
.core-layer[data-layer="coarse"] { min-height: 8.2rem; background: #8f7655; }
.core-layer[data-layer="fine"] { min-height: 8.8rem; background: #9b8d70; }
.core-layer[data-layer="river"] { min-height: 9rem; background: #584d3e; }
.core-layer:not(.is-active) { filter: saturate(0.56); opacity: 0.64; }
.core-layer span { position: relative; z-index: 1; font-family: var(--mono); font-size: 0.68rem; line-height: 1.25; text-transform: uppercase; }

.core-caption { position: relative; z-index: 2; margin-top: 1.4rem; color: var(--ink); font-family: var(--mono); font-size: 0.66rem; text-transform: uppercase; }
.core-caption strong { display: block; margin-top: 0.35rem; font-family: var(--serif); font-size: 1.7rem; font-weight: 500; line-height: 1; text-transform: none; }

.core-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-block: 1.4rem;
}

.core-button,
.filter-button { border-color: var(--line); background: transparent; color: var(--ink-soft); }
.core-button:hover,
.core-button:focus-visible,
.core-button.is-active,
.filter-button:hover,
.filter-button:focus-visible,
.filter-button.is-active { border-color: var(--water); background: var(--water); color: var(--foam); }

.core-copy { min-height: 12rem; }
.core-copy h3 { margin: 0 0 0.45rem; font-family: var(--serif); font-size: clamp(2rem, 4vw, 4rem); font-weight: 500; letter-spacing: -0.03em; line-height: 0.96; }
.core-copy p { max-width: 42rem; margin: 0; color: var(--ink-soft); font-family: var(--serif); font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.3; }
.core-copy .status-tag { display: inline-block; margin-bottom: 1rem; color: var(--water); }
.core-source { margin-top: 1.6rem; color: var(--peat); font-family: var(--mono); font-size: 0.68rem; text-transform: uppercase; }
.core-takeaway { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--ink); font-family: var(--serif); font-size: 1.3rem; font-style: italic; }

.wave-wrap { overflow: hidden; border: 1px solid rgba(238, 242, 232, 0.18); background: rgba(8, 26, 32, 0.35); }
.wave-figure { display: block; width: 100%; height: auto; }
.wave-sea { fill: none; stroke: var(--moss); stroke-width: 4; vector-effect: non-scaling-stroke; }
.wave-base { fill: none; stroke: rgba(238, 242, 232, 0.24); stroke-width: 1.4; stroke-dasharray: 5 8; vector-effect: non-scaling-stroke; }
.wave-spike { fill: none; stroke: var(--coral); stroke-width: 3; opacity: 0; vector-effect: non-scaling-stroke; transition: opacity 260ms ease; }
.wave-wrap.is-shock .wave-spike { opacity: 1; }
.wave-axis { fill: rgba(238, 242, 232, 0.65); font-family: var(--mono); font-size: 11px; letter-spacing: 0.03em; text-transform: uppercase; }
.wave-label { fill: var(--moss); font-family: var(--mono); font-size: 12px; letter-spacing: 0.05em; text-transform: uppercase; }
.wave-label-shock { fill: var(--coral); }
.wave-copy { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; align-items: start; padding: 1rem 1.2rem 1.2rem; }
.wave-copy p { max-width: 38rem; margin: 0; color: rgba(238, 242, 232, 0.68); font-family: var(--serif); font-size: 1.1rem; }
.wave-toggle { min-height: 2.7rem; padding: 0.65rem 0.8rem; border: 1px solid rgba(238, 242, 232, 0.32); background: transparent; color: var(--foam); font-family: var(--mono); font-size: 0.66rem; text-transform: uppercase; }
.wave-toggle:hover,
.wave-toggle:focus-visible { border-color: var(--coral); color: var(--coral); }
.wave-note { margin-top: 1.3rem; color: var(--amber); font-family: var(--serif); font-size: 1.45rem; font-style: italic; }

.prose-spaced,
.status-box-spaced,
.ecology-grid-spaced { margin-top: 2rem; }

.ecology-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(19rem, 0.66fr); gap: clamp(2rem, 7vw, 7rem); align-items: start; }
.metric-stack { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid rgba(238, 242, 232, 0.2); background: rgba(238, 242, 232, 0.2); }
.metric { min-height: 11rem; padding: 1.25rem; background: rgba(8, 26, 32, 0.32); }
.metric:nth-child(2n) { background: rgba(238, 242, 232, 0.05); }
.metric strong { display: block; color: var(--amber); font-family: var(--serif); font-size: clamp(2.4rem, 5vw, 4.6rem); font-weight: 500; letter-spacing: -0.05em; line-height: 0.82; }
.metric span { display: block; margin-top: 0.55rem; color: var(--foam); font-family: var(--mono); font-size: 0.66rem; text-transform: uppercase; }
.metric p { margin: 0.8rem 0 0; color: rgba(238, 242, 232, 0.65); font-family: var(--serif); font-size: 1rem; line-height: 1.2; }
.status-box { padding: 1.35rem; border-left: 3px solid var(--moss); background: rgba(8, 26, 32, 0.36); }
.status-box .status-tag { color: var(--moss); }
.status-box p { margin: 0.75rem 0 0; color: rgba(238, 242, 232, 0.75); font-family: var(--serif); font-size: 1.2rem; line-height: 1.28; }

.people-grid { display: grid; grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); gap: clamp(2rem, 7vw, 7rem); align-items: start; }
.people-copy p { margin: 0 0 1.2rem; }
.evidence-table { width: 100%; border-collapse: collapse; border-top: 1px solid rgba(17, 37, 45, 0.26); }
.evidence-table caption { margin-bottom: 0.9rem; color: var(--peat); font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.07em; text-align: left; text-transform: uppercase; }
.evidence-table th,
.evidence-table td { padding: 0.85rem 0.65rem; border-bottom: 1px solid rgba(17, 37, 45, 0.2); text-align: left; vertical-align: top; }
.evidence-table th { color: var(--ink); font-family: var(--serif); font-size: 1.1rem; font-weight: 600; line-height: 1.1; }
.evidence-table td { color: var(--ink-soft); font-family: var(--mono); font-size: 0.68rem; line-height: 1.35; }
.evidence-table .status-tag { color: var(--water); font-size: 0.6rem; }

.dna-layout { display: grid; grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr); gap: clamp(2rem, 7vw, 7rem); align-items: start; }
.dna-quote { margin-top: 2rem; padding: 1.5rem; border: 1px solid rgba(238, 242, 232, 0.2); border-left: 4px solid var(--amber); background: rgba(8, 26, 32, 0.32); color: var(--amber); font-family: var(--serif); font-size: clamp(1.55rem, 3vw, 2.6rem); font-style: italic; line-height: 1.02; }
.dna-machine { padding: 1.2rem; border: 1px solid rgba(238, 242, 232, 0.22); background: rgba(8, 26, 32, 0.42); }
.mode-buttons { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-bottom: 1.35rem; }
.mode-button { min-height: 2.7rem; padding: 0.62rem 0.8rem; border: 1px solid rgba(238, 242, 232, 0.28); background: transparent; color: rgba(238, 242, 232, 0.72); font-family: var(--mono); font-size: 0.68rem; text-transform: uppercase; }
.mode-button.is-active,
.mode-button:hover,
.mode-button:focus-visible { border-color: var(--amber); color: var(--amber); }
.tree-visual { position: relative; min-height: 20rem; overflow: hidden; border: 1px solid rgba(238, 242, 232, 0.12); background: #0c222b; }
.tree-visual::before { position: absolute; inset: 0; background-image: linear-gradient(90deg, transparent 24.5%, rgba(238, 242, 232, 0.08) 25%, transparent 25.5%), linear-gradient(0deg, transparent 24.5%, rgba(238, 242, 232, 0.08) 25%, transparent 25.5%); background-size: 5rem 5rem; content: ""; opacity: 0.65; }
.tree-title { position: absolute; top: 1rem; left: 1rem; color: rgba(238, 242, 232, 0.6); font-family: var(--mono); font-size: 0.66rem; text-transform: uppercase; }
.tree-root { position: absolute; bottom: 1.35rem; left: 50%; width: 0.9rem; height: 0.9rem; border: 2px solid var(--amber); border-radius: 50%; background: var(--deep); transform: translateX(-50%); }
.tree-trunk { position: absolute; bottom: 2.1rem; left: 50%; width: 2px; height: 14rem; background: var(--amber); transform: translateX(-50%); }
.tree-branch { position: absolute; bottom: 2.1rem; left: 50%; height: 2px; background: var(--moss); transform-origin: left center; transition: opacity 220ms ease, transform 220ms ease; }
.tree-branch.b1 { width: 8.8rem; transform: translateX(0) rotate(-40deg); }
.tree-branch.b2 { width: 7.6rem; transform: translateX(0) rotate(-21deg); }
.tree-branch.b3 { width: 7.4rem; transform: translateX(0) rotate(19deg); }
.tree-branch.b4 { width: 8.6rem; transform: translateX(0) rotate(39deg); }
.tree-branch.b5 { width: 5.6rem; transform: translate(-0.3rem, -4.4rem) rotate(-68deg); }
.tree-branch.b6 { width: 5.4rem; transform: translate(0.3rem, -4.2rem) rotate(67deg); }
.tree-node { position: absolute; width: 0.54rem; height: 0.54rem; border: 1px solid var(--foam); border-radius: 50%; background: var(--water); transition: opacity 220ms ease, background 220ms ease, transform 220ms ease; }
.tree-node.n1 { left: 19%; bottom: 12.9rem; }
.tree-node.n2 { left: 29%; bottom: 8.4rem; }
.tree-node.n3 { left: 68%; bottom: 8rem; }
.tree-node.n4 { left: 77%; bottom: 12.9rem; }
.tree-node.n5 { left: 39%; bottom: 15.7rem; }
.tree-node.n6 { left: 60%; bottom: 15.5rem; }
.dna-machine[data-mode="line"] .tree-branch,
.dna-machine[data-mode="line"] .tree-node { opacity: 0.14; }
.dna-machine[data-mode="line"] .tree-branch.b3,
.dna-machine[data-mode="line"] .tree-branch.b4,
.dna-machine[data-mode="line"] .tree-node.n3,
.dna-machine[data-mode="line"] .tree-node.n4 { opacity: 1; background: var(--amber); }
.dna-machine[data-mode="line"] .tree-trunk { box-shadow: 0 0 0 5px rgba(215, 155, 82, 0.08); }
.dna-copy { padding-top: 1.1rem; }
.dna-copy h3 { margin: 0; color: var(--foam); font-family: var(--serif); font-size: clamp(2rem, 4vw, 3.9rem); font-weight: 500; line-height: 0.94; }
.dna-copy p { margin: 0.8rem 0 0; color: rgba(238, 242, 232, 0.7); font-family: var(--serif); font-size: 1.2rem; line-height: 1.28; }
.dna-bridge { margin-top: 1.35rem; padding: 1rem; border-left: 3px solid var(--moss); background: rgba(238, 242, 232, 0.07); }
.dna-bridge .status-tag { color: var(--moss); }
.dna-bridge p { margin-top: 0.45rem; color: var(--foam); font-size: 1.05rem; }
.dna-warning { margin-top: 1.35rem; padding-top: 1rem; border-top: 1px solid rgba(238, 242, 232, 0.2); color: var(--amber); font-family: var(--serif); font-size: 1.35rem; font-style: italic; }

.timeline { position: relative; display: grid; gap: 0; }
.timeline::before { position: absolute; top: 0.5rem; bottom: 0.5rem; left: 7.7rem; width: 1px; background: var(--line); content: ""; }
.timeline-item { position: relative; display: grid; grid-template-columns: 8rem minmax(0, 1fr); gap: 2.3rem; padding-block: 1.35rem; }
.timeline-item::before { position: absolute; top: 1.75rem; left: 7.4rem; width: 0.65rem; height: 0.65rem; border: 2px solid var(--paper); border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 4px var(--paper); content: ""; }
.timeline-type { color: var(--water); }
.timeline-date { color: var(--peat); font-family: var(--mono); font-size: 0.7rem; line-height: 1.3; }
.timeline-content { padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); }
.timeline-content h3 { margin: 0; font-family: var(--serif); font-size: clamp(1.8rem, 3vw, 3rem); font-weight: 500; letter-spacing: -0.03em; line-height: 0.98; }
.timeline-content p { max-width: 45rem; margin: 0.55rem 0 0; color: var(--ink-soft); font-family: var(--serif); font-size: 1.15rem; line-height: 1.3; }

.sources-head { display: flex; align-items: end; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.sources-head p { max-width: 44rem; margin: 0; color: var(--ink-soft); font-family: var(--serif); font-size: 1.2rem; }
.filter-row { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-block: 1rem 2rem; }
.source-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid rgba(17, 37, 45, 0.2); background: rgba(17, 37, 45, 0.2); }
.source-card { display: flex; min-height: 23rem; flex-direction: column; padding: 1.25rem; background: var(--paper); }
.source-card:nth-child(3n + 2) { background: #dedfce; }
.source-card:nth-child(3n) { background: #d8d2b6; }
.source-card.is-hidden { display: none; }
.source-kind { color: var(--water); }
.source-card h3 { margin: 1.2rem 0 0.35rem; font-family: var(--serif); font-size: 1.55rem; font-weight: 600; line-height: 1.02; }
.source-byline { color: var(--ink); font-family: var(--mono); font-size: 0.66rem; text-transform: uppercase; }
.source-card p { margin: 1rem 0 0; color: var(--ink-soft); font-family: var(--serif); font-size: 1rem; line-height: 1.25; }
.source-card .source-limit { margin-top: 0.6rem; padding-top: 0.6rem; border-top: 1px solid var(--line); color: var(--ink); font-size: 0.92rem; }
.source-card a { display: inline-block; margin-top: auto; padding-top: 1rem; color: var(--water); font-family: var(--mono); font-size: 0.67rem; text-transform: uppercase; }
.source-card a:hover { color: var(--deep); }
.source-empty { display: none; margin: 1rem 0; padding: 1.3rem; border: 1px solid var(--line); color: var(--ink-soft); font-family: var(--serif); font-size: 1.2rem; }
.source-empty.is-visible { display: block; }
.source-cutoff { margin-top: 1.6rem; color: var(--peat); font-family: var(--mono); font-size: 0.68rem; }

.site-footer {
  position: relative;
  padding-block: 2.3rem 3rem;
  background: var(--deep);
  color: rgba(238, 242, 232, 0.68);
}

.footer-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(12rem, 0.7fr); gap: 2rem; align-items: end; }
.footer-note { max-width: 35rem; font-family: var(--serif); font-size: 1.35rem; line-height: 1.1; }
.footer-meta { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 1rem 1.4rem; font-family: var(--mono); font-size: 0.67rem; text-transform: uppercase; }
.footer-meta a { color: var(--foam); text-decoration: none; }
.footer-meta a:hover { color: var(--amber); }
.not-found { min-height: 100vh; }
.not-found-main { padding-block: 15vh; }
.not-found-title { max-width: 10ch; margin: 2rem 0; color: var(--foam); font-family: var(--serif); font-size: clamp(4rem, 10vw, 8rem); font-weight: 500; line-height: 0.86; }
.not-found-copy { max-width: 32rem; color: rgba(238, 242, 232, 0.72); font-family: var(--serif); font-size: 1.35rem; }
.no-script { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--line-light); color: rgba(238, 242, 232, 0.5); font-family: var(--mono); font-size: 0.68rem; }

.back-to-top {
  display: inline-flex;
  width: 2.85rem;
  height: 2.85rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--amber);
  background: var(--deep);
  color: var(--amber);
  font-family: var(--mono);
  font-size: 1.1rem;
  text-decoration: none;
}

html.js body:not(.js-ready) .back-to-top { position: static; margin-top: 1.2rem; }
html.js body.js-ready .back-to-top { position: fixed; right: max(1rem, env(safe-area-inset-right)); bottom: max(1rem, env(safe-area-inset-bottom)); z-index: 30; opacity: 0; pointer-events: none; transform: translateY(0.75rem); transition: opacity 180ms ease, transform 180ms ease; }
html.js body.js-ready .back-to-top.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.back-to-top:hover,
.back-to-top:focus-visible { background: var(--amber); color: var(--deep); }

.small-screen-only { display: none; }

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-figure { max-width: 44rem; }
  .claim-grid,
  .evidence-layout,
  .core-grid,
  .ecology-grid,
  .people-grid,
  .dna-layout { grid-template-columns: 1fr; }
  .method-card { position: static; max-width: 40rem; }
  .core-figure { max-width: 28rem; }
  .source-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .container { width: min(calc(100% - 1.4rem), var(--measure)); }
  .header-inner { min-height: 3.7rem; }
  .brand-mark { display: none; }
  .brand-name { font-size: 0.95rem; }
  .nav { gap: 0.8rem; }
  .nav a { font-size: 0.59rem; }
  .lang-link { width: 2.6rem; max-width: 2.6rem; overflow: hidden; padding: 0.44rem 0.35rem; font-size: 0; text-align: center; text-overflow: ellipsis; }
  html[lang="en"] .lang-link::after { content: "RO"; font-size: 0.63rem; }
  html[lang="ro"] .lang-link::after { content: "EN"; font-size: 0.63rem; }
  .hero { min-height: auto; }
  .hero-grid { min-height: auto; padding-block: 3.7rem 4.5rem; }
  .hero h1 { max-width: 8.2ch; font-size: clamp(3.4rem, 17vw, 6.4rem); letter-spacing: -0.065em; }
  .hero-lede { font-size: 1.24rem; }
  .hero-meta { margin-top: 2.5rem; }
  .section-head,
  .map-intro-grid { grid-template-columns: 1fr; gap: 1rem; }
  .section-head { margin-bottom: 2.5rem; }
  .section-head h2 { font-size: clamp(2.7rem, 13vw, 4.6rem); }
  .section-head p { margin-top: 0.5rem; font-size: 1.17rem; }
  .chapter { padding-block: 4.4rem; }
  .map-panel { aspect-ratio: 1 / 1.15; }
  .map-panel .map-legend { max-width: 12rem; font-size: 0.6rem; }
  .range-row { grid-template-columns: 1fr; gap: 0.35rem; }
  .range-row span:last-child { display: none; }
  .stage-readout { grid-template-columns: 1fr; gap: 0.55rem; }
  .callout-line { grid-template-columns: 1.8rem minmax(0, 1fr); gap: 0.6rem; font-size: 1.4rem; }
  .callout-line::before { width: 1.8rem; }
  .evidence-grid,
  .metric-stack,
  .source-grid { grid-template-columns: 1fr; }
  .evidence-card:last-child { grid-column: auto; }
  .evidence-card { min-height: auto; }
  .core-shell { min-height: 28rem; }
  .core-line { width: min(66%, 9rem); }
  .wave-copy { grid-template-columns: 1fr; }
  .wave-toggle { justify-self: start; }
  .timeline::before { left: 0.3rem; }
  .timeline-item { grid-template-columns: 1fr; gap: 0.45rem; padding-left: 1.6rem; }
  .timeline-item::before { top: 1.7rem; left: 0; }
  .timeline-date { font-size: 0.66rem; }
  .timeline-content h3 { font-size: 2rem; }
  .sources-head,
  .footer-grid { grid-template-columns: 1fr; display: grid; align-items: start; }
  .footer-meta { justify-content: flex-start; }
  .evidence-table { display: block; overflow-x: auto; }
  .evidence-table th, .evidence-table td { min-width: 8.5rem; }
  .dna-machine { padding: 0.8rem; }
  .tree-visual { min-height: 17rem; }
  .tree-trunk { height: 11rem; }
  .tree-node.n1 { left: 11%; bottom: 10rem; }
  .tree-node.n2 { left: 23%; bottom: 6.2rem; }
  .tree-node.n3 { left: 71%; bottom: 6rem; }
  .tree-node.n4 { left: 83%; bottom: 10rem; }
  .tree-node.n5 { left: 37%; bottom: 12.5rem; }
  .tree-node.n6 { left: 61%; bottom: 12.3rem; }
  .tree-branch.b1 { width: 6.4rem; }
  .tree-branch.b2 { width: 5.4rem; }
  .tree-branch.b3 { width: 5.1rem; }
  .tree-branch.b4 { width: 6.2rem; }
  .tree-branch.b5, .tree-branch.b6 { width: 4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.001ms !important; animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}

@media print {
  .site-header, .hero-actions, .hero-figure, .map-interface, .core-figure, .wave-wrap, .dna-machine, .filter-row, .back-to-top { display: none !important; }
  .hero, .chapter, .site-footer { color: #000; background: #fff; }
  .chapter { padding-block: 2rem; }
  .section-head { display: block; }
  .source-card { break-inside: avoid; }
}
