/* Sajag. A printed flood bulletin: warm paper, ink, one river blue, one ordered risk ramp. */
:root {
  --paper: #F6F1E7;
  --paper-2: #EEE7D8;
  --land: #EAE3D3;
  --rule: #D5CBB8;
  --rule-2: #A89E8B;
  --ink: #1E1B16;
  --ink-2: #47423A;
  --ink-3: #635C50;
  --blue: #1C5A87;
  --l1: #D9932A;
  --l2: #B85419;
  --l3: #7C2512;
  --font: "IBM Plex Sans", "IBM Plex Sans Devanagari", system-ui, sans-serif;
  --mast-h: 57px;
  --gutter: 20px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: var(--blue); text-underline-offset: 2px; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
main:focus { outline: none; }
.defs { position: absolute; }
.vh {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 8px; top: -60px; z-index: 3000; padding: 8px 12px;
  background: var(--ink); color: var(--paper);
}
.skip:focus { top: 8px; }

.mock-banner {
  padding: 4px var(--gutter); background: var(--ink); color: var(--paper);
  font-size: 12.5px; text-align: center;
}

/* Masthead */
.top { position: sticky; top: 0; z-index: 1500; }
.mast {
  min-height: 57px;
  display: flex; align-items: center; gap: 22px; padding: 0 var(--gutter);
  background: var(--paper); border-bottom: 2px solid var(--ink);
}
.brand { display: flex; align-items: baseline; gap: 8px; color: var(--ink); text-decoration: none; }
.brand-word { font-size: 24px; font-weight: 600; letter-spacing: -0.015em; }
.brand-hi { font-size: 19px; font-weight: 500; color: var(--ink-2); }
.brand-line { font-size: 13px; color: var(--ink-2); padding-left: 18px; border-left: 1px solid var(--rule-2); }
.tabs-main { display: flex; gap: 2px; align-self: stretch; margin-left: 8px; }
.tabs-main a {
  display: flex; align-items: center; padding: 0 13px; color: var(--ink-2); text-decoration: none;
  font-size: 14.5px; font-weight: 500; border-bottom: 3px solid transparent; margin-bottom: -2px;
}
.tabs-main a:hover { color: var(--ink); border-bottom-color: var(--rule-2); }
.tabs-main a[aria-current="page"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.today-strip {
  margin-left: auto; display: flex; gap: 10px; align-items: baseline; font-size: 12.5px;
  color: var(--ink-2); text-decoration: none; white-space: nowrap;
}
.today-strip:hover { color: var(--ink); text-decoration: underline; }
.strip-label { font-weight: 600; color: var(--ink); }

/* Shared controls */
.ctl-label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ink-3); white-space: nowrap;
}
.ctl { display: inline-flex; align-items: center; gap: 8px; }
.ctl-unit { font-size: 13px; color: var(--ink-2); }
select {
  height: 32px; padding: 0 26px 0 9px; border: 1px solid var(--rule-2); border-radius: 2px;
  background-color: var(--paper);
  background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 13px) 14px, calc(100% - 9px) 14px;
  background-size: 4px 4px; background-repeat: no-repeat; appearance: none;
  font-size: 14px; font-variant-numeric: tabular-nums;
}
.choice { display: inline-flex; }
.choice button {
  min-width: 34px; height: 32px; padding: 0 11px; border: 1px solid var(--rule-2); margin-left: -1px;
  background: transparent; font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap;
}
.choice button:first-child { margin-left: 0; border-radius: 2px 0 0 2px; }
.choice button:last-child { border-radius: 0 2px 2px 0; }
.choice button:hover { background: var(--paper-2); }
.choice button[aria-checked="true"], .choice button[aria-selected="true"] {
  position: relative; background: var(--ink); border-color: var(--ink); color: var(--paper); font-weight: 500;
}
.choice button:disabled { color: var(--ink-3); cursor: not-allowed; background: transparent; }
.choice button:focus-visible { position: relative; z-index: 1; }
.btn {
  height: 34px; padding: 0 14px; border: 1px solid var(--ink); border-radius: 2px;
  background: transparent; font-size: 14px; font-weight: 500;
}
.btn:hover { background: var(--paper-2); }

/* Map screen */
.screen-map { display: grid; grid-template-columns: minmax(0, 1fr) 436px; align-items: start; }
.stage {
  position: sticky; top: var(--mast-h); height: calc(100dvh - var(--mast-h));
  display: flex; flex-direction: column; min-width: 0; transition: opacity .15s;
}
.stage.is-loading { opacity: .55; }
.stories { padding: 9px var(--gutter) 8px; }
.story-row { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 16px; }
.story {
  display: inline-flex; align-items: baseline; gap: 7px; padding: 3px 0; border: 0;
  border-bottom: 2px solid transparent; background: none; font-size: 14.5px; font-weight: 500;
  color: var(--ink-2);
}
.story:hover { color: var(--ink); border-bottom-color: var(--rule-2); }
.story[aria-pressed="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.story-tag { font-size: 11px; font-weight: 500; color: var(--blue); }
.story-caption { margin-top: 3px; font-size: 13.5px; color: var(--ink-2); max-width: 78ch; min-height: 20px; }
.controls {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 24px;
  padding: 7px var(--gutter); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
}
.mapwrap { flex: 1 1 auto; min-height: 280px; display: grid; grid-template-columns: minmax(0, 1fr) 276px; overflow: hidden; }
.mapcol { position: relative; min-width: 0; min-height: 0; }
#map { position: absolute; inset: 0; }
.keycol {
  display: flex; flex-direction: column; justify-content: space-between; gap: 10px; min-height: 0; overflow-y: auto;
  padding: 11px var(--gutter) 10px 14px; border-left: 1px solid var(--rule);
}
.leaflet-container { background: transparent; font: inherit; outline-offset: -2px; }
.mh-tags { display: flex; flex-wrap: wrap; gap: 5px 8px; align-items: center; }
.tag {
  font-size: 11px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-3);
}
.tag-blind {
  padding: 1px 6px; border-radius: 1px; background: var(--blue); color: #fff;
  letter-spacing: 0.02em; text-transform: none; font-size: 12px; font-weight: 500;
}
.mh-date { margin-top: 4px; font-size: 27px; line-height: 1.12; font-weight: 600; letter-spacing: -0.02em; }
.mh-sum { margin-top: 2px; font-size: 14px; color: var(--ink-2); font-variant-numeric: tabular-nums; }

.ev { margin-top: 9px; padding-top: 7px; border-top: 2px solid var(--blue); }
.ev-kicker { font-size: 11px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--blue); }
.ev-title { font-size: 15px; font-weight: 600; line-height: 1.25; }
.ev-sub { font-size: 12.5px; color: var(--ink-2); }
.ev-grid { margin-top: 5px; border-collapse: collapse; font-size: 12px; font-variant-numeric: tabular-nums; }
.ev-grid caption { text-align: left; font-size: 12px; font-weight: 500; color: var(--ink); padding-bottom: 2px; }
.ev-grid th { font-weight: 400; text-align: left; color: var(--ink-2); padding: 1px 10px 1px 0; white-space: nowrap; }
.ev-grid td { padding: 1px 8px 1px 0; vertical-align: middle; line-height: 0; }
.ev-grid td.num { line-height: 1.3; color: var(--ink); white-space: nowrap; font-weight: 500; }
.ev-grid rect { pointer-events: auto; }

.map-tools { position: absolute; z-index: 800; top: 10px; right: 12px; display: flex; gap: 4px; align-items: center; }
.tool {
  width: 30px; height: 30px; border: 1px solid var(--rule-2); border-radius: 2px; background: var(--paper);
  font-size: 17px; line-height: 1;
}
.tool:hover { background: var(--paper-2); }
.tool-wide { width: auto; padding: 0 7px; font-size: 12px; white-space: nowrap; }

.lg-title { font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 3px; }
.lg { display: grid; gap: 2px; font-size: 13px; }
.lg li { display: grid; grid-template-columns: 16px 1fr auto; gap: 7px; align-items: center; line-height: 1.3; }
.lg-marks { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--rule); font-size: 12px; }
.lg-marks li { grid-template-columns: 16px 1fr; }
.lg-n { font-variant-numeric: tabular-nums; font-weight: 600; min-width: 2ch; text-align: right; }
.lg-note { margin-top: 5px; font-size: 11.5px; line-height: 1.3; color: var(--ink-2); }
.swatch { display: block; flex: none; }
.bi { display: inline-flex; flex-wrap: wrap; gap: 0 7px; align-items: baseline; }
.bi-hi { color: var(--ink-2); }
.mk { display: block; width: 16px; }
.mk-flood { height: 11px; border: 2px solid var(--blue); outline: 1px solid var(--paper); outline-offset: -3px; background: var(--land); }
.mk-river { height: 2px; background: var(--blue); }
.mk-gauge { width: 9px; height: 9px; margin-left: 3px; border-radius: 50%; border: 1.5px solid var(--blue); background: var(--paper); }
.mk-gauge.is-high { background: var(--blue); }
.mk-village { width: 9px; height: 9px; margin-left: 3px; border-radius: 50%; background: var(--l3); }

/* Map labels */
.lb { width: 0; height: 0; }
.lb-in { position: absolute; display: flex; flex-direction: column; align-items: center; transform: translate(-50%, -50%); white-space: nowrap; line-height: 1.08; }
.lb-district .lb-name {
  font-size: 10.5px; font-weight: 500; color: var(--ink);
  text-shadow: 0 0 2px var(--land), 0 0 2px var(--land), 0 0 3px var(--land);
}
.lb-district .lb-val { font-size: 11.5px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; text-shadow: 0 0 2px #E3AE5A, 0 0 3px #E3AE5A; }
.lb-district.on-dark .lb-name, .lb-district.on-dark .lb-val { color: #fff; text-shadow: 0 0 2px #4A1508, 0 0 3px #4A1508, 0 0 4px #4A1508; }
.lb-district.is-selected .lb-name { font-weight: 600; }
.lb-river span { display: block; font-size: 11px; font-style: italic; color: var(--blue); text-shadow: 0 0 2px var(--paper), 0 0 2px var(--paper), 0 0 3px var(--paper); }
.lb-near { font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); }
.is-small .lb-district .lb-val { display: none; }
.is-small .lb-district .lb-name { font-size: 9.5px; }
.is-small .lb-near { display: none; }

/* Timeline */
.timeline { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 14px; padding: 6px var(--gutter) 8px; border-top: 1px solid var(--rule-2); }
.tl-side { display: flex; flex-direction: column; gap: 7px; padding-top: 19px; }
.btn-play { width: 100%; height: 36px; background: var(--ink); color: var(--paper); }
.btn-play:hover { background: var(--ink-2); }
.tl-range { display: flex; }
.tl-range button { flex: 1 1 0; min-width: 0; height: 26px; padding: 0 2px; font-size: 12px; }
.tl-title { font-size: 12px; color: var(--ink-2); }
.tl-plot { position: relative; }
.tl-art svg { display: block; }
#scrub {
  position: absolute; inset: 0; width: 100%; margin: 0; padding: 0; opacity: 0; cursor: ew-resize;
  -webkit-appearance: none; appearance: none; background: transparent;
}
#scrub::-webkit-slider-thumb { -webkit-appearance: none; width: 1px; height: 100%; }
#scrub::-moz-range-thumb { width: 1px; height: 100%; border: 0; }
.tl-plot:has(#scrub:focus-visible) { outline: 2px solid var(--blue); outline-offset: 2px; }
.tl-marks { position: absolute; inset: 0 0 auto 0; height: 22px; pointer-events: none; }
.tl-mark {
  position: absolute; top: 0; width: 24px; height: 22px; padding: 0; margin-left: -12px;
  border: 0; background: none; pointer-events: auto;
}
.tl-mark::before {
  content: ""; position: absolute; left: 6px; top: 8px; width: 12px; height: 11px; background: var(--blue);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
}
.tl-mark::after {
  content: ""; position: absolute; left: 11.25px; top: 18px; width: 1.5px; height: 78px; background: var(--blue); pointer-events: none;
}
.tl-mark-text {
  position: absolute; left: 21px; top: 3px; font-size: 12px; font-weight: 500; color: var(--blue); white-space: nowrap;
}
.tl-mark.flip .tl-mark-text { left: auto; right: 21px; }
.grid { stroke: var(--rule); stroke-width: 1; shape-rendering: crispEdges; }
.axis { stroke: var(--rule-2); stroke-width: 1; shape-rendering: crispEdges; }
.axis-tick { stroke: var(--rule-2); stroke-width: 1; }
.ax { font-size: 11px; fill: var(--ink-3); font-variant-numeric: tabular-nums; }
.ax-strong { fill: var(--ink); font-weight: 500; }
.ax-title { font-size: 11.5px; fill: var(--ink-2); font-weight: 500; }
.cross { stroke: var(--ink); stroke-width: 1; }

/* Panel */
.panel { min-width: 0; padding: 12px 22px 28px; border-left: 1px solid var(--rule-2); background: var(--paper); }
.p-pick select { width: 100%; }
.p-title { margin-top: 12px; }
.p-name { font-size: 29px; line-height: 1.15; font-weight: 600; letter-spacing: -0.015em; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; }
.p-name-hi { font-size: 21px; font-weight: 500; letter-spacing: 0; color: var(--ink-2); }
.panel-tabs { display: flex; margin-top: 11px; border-bottom: 1px solid var(--ink); }
.panel-tabs button {
  flex: 0 0 auto; height: 34px; border: 0; margin: 0; padding: 0 2px; margin-right: 20px; background: none;
  color: var(--ink-2); font-weight: 500; border-bottom: 3px solid transparent; border-radius: 0 !important;
}
.panel-tabs button:hover { background: none; color: var(--ink); }
.panel-tabs button[aria-selected="true"] { background: none; color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.sec { padding: 14px 0 15px; border-bottom: 1px solid var(--rule); }
.sec:last-child { border-bottom: 0; }
.sec-title { font-size: 11.5px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 7px; }
.sub-title { font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.read { font-size: 13.5px; color: var(--ink-2); margin-top: 7px; }
.read strong { color: var(--ink); }
.read-lg { font-size: 19px; line-height: 1.35; color: var(--ink); margin: 0 0 16px; }
.note { font-size: 12.5px; color: var(--ink-2); margin-top: 6px; }
.chip { display: inline-flex; align-items: center; gap: 8px; }
.p-level .chip { font-size: 19px; font-weight: 600; }
.p-level .swatch { width: 20px; height: 20px; }
.on-record { display: flex; align-items: center; gap: 8px; margin-top: 6px; font-size: 13.5px; font-weight: 500; }
.risk { display: grid; gap: 5px; }
.risk li { display: grid; grid-template-columns: 54px 1fr 40px; gap: 9px; align-items: center; font-size: 13.5px; color: var(--ink-2); }
.risk-track { display: block; height: 10px; background: var(--paper-2); }
.risk-fill { display: block; height: 100%; background: var(--rule-2); transition: width .24s ease-out; }
.risk-n { text-align: right; font-variant-numeric: tabular-nums; }
.risk li.is-on { color: var(--ink); font-weight: 600; }
.risk li.is-on .risk-fill { background: var(--ink); }
.why { display: grid; gap: 4px; font-size: 14.5px; }
.why li { padding-left: 13px; position: relative; }
.why li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 5px; height: 5px; background: var(--ink); }
.site-pick { margin-bottom: 8px; overflow-x: auto; }
.site-pick .choice button { font-size: 12px; height: 28px; padding: 0 7px; }
.chart svg { display: block; max-width: 100%; }
.twin { margin-top: 8px; font-size: 13px; }
.twin summary { cursor: pointer; color: var(--ink-2); }
.twin[open] summary { margin-bottom: 6px; }
.vill { display: grid; gap: 3px; }
.vill li { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) 26px 50px; gap: 8px; align-items: center; font-size: 13.5px; }
.vill-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vill-track { display: block; height: 8px; background: var(--paper-2); }
.vill-fill { display: block; height: 100%; }
.vill-fill.c0 { background: var(--rule-2); }
.vill-fill.c1 { background: var(--l1); }
.vill-fill.c2 { background: var(--l3); }
.vill-n { text-align: right; font-variant-numeric: tabular-nums; font-weight: 500; }
.vill-class { font-size: 12px; color: var(--ink-2); }
#p-villages .btn { margin-top: 8px; }
.rank { display: grid; }
.rank button {
  display: grid; grid-template-columns: 14px 1fr 64px 40px; gap: 8px; align-items: center; width: 100%;
  padding: 4px 0; border: 0; border-bottom: 1px solid var(--rule); background: none; text-align: left; font-size: 14px;
}
.rank button:hover { background: var(--paper-2); }
.rank-level { font-size: 12.5px; color: var(--ink-2); }
.rank-risk { text-align: right; font-variant-numeric: tabular-nums; font-weight: 500; }

/* Alert preview */
#panel-alert { padding-top: 14px; }
.al-row { display: flex; align-items: center; gap: 10px; margin-bottom: 9px; flex-wrap: wrap; }
.al-row .ctl-label { min-width: 62px; }
.al-tabs button { padding: 0 9px; }
.al-body { display: grid; grid-template-columns: 206px minmax(0, 1fr); gap: 16px; margin-top: 14px; }
.phone { padding: 16px 11px 26px; background: var(--ink); border-radius: 13px 13px 22px 22px; }
.phone-screen { display: flex; flex-direction: column; min-height: 148px; background: #D5D8C3; color: #1B1F14; border-radius: 2px; }
.phone-bar { display: flex; justify-content: space-between; padding: 2px 6px; font-size: 11px; font-weight: 600; border-bottom: 1px solid #1B1F14; font-variant-numeric: tabular-nums; }
.phone-soft { margin-top: auto; border-top: 1px solid #1B1F14; border-bottom: 0; font-weight: 500; }
.phone-text { padding: 7px 7px 9px; font-size: 15px; line-height: 1.45; }
.al-count { font-size: 14px; line-height: 1.35; color: var(--ink-2); }
.al-n { display: block; font-size: 40px; line-height: 1.05; font-weight: 600; color: var(--ink); letter-spacing: -0.02em; }
.al-over { color: var(--l3); font-weight: 600; }
.al-none { display: block; margin-top: 6px; color: var(--ink); font-weight: 500; }
.meter { display: block; height: 8px; margin-top: 8px; background: var(--paper-2); }
.meter-fill { display: block; height: 100%; background: var(--ink); transition: width .2s; }
.meter-fill.is-over { background: var(--l3); }
.al-voice { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--rule); }
.al-voice audio { display: block; width: 100%; height: 36px; }
.al-script { margin-top: 8px; font-size: 15px; line-height: 1.5; }

/* Tooltip */
.tip {
  position: fixed; left: 0; top: 0; z-index: 2000; max-width: 280px; padding: 6px 9px; background: var(--ink);
  color: var(--paper); font-size: 12.5px; line-height: 1.35; pointer-events: none;
}
.tip-head { font-weight: 600; }
.tip-row { display: flex; gap: 6px; align-items: baseline; }
.tip-row strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.tip-key { width: 10px; height: 2px; align-self: center; }

/* Evidence and Today */
.screen-doc { max-width: 1200px; margin: 0 auto; padding: 26px 32px 40px; }
.doc-head { padding-bottom: 18px; }
.doc-h1 { font-size: 44px; line-height: 1.1; font-weight: 600; letter-spacing: -0.025em; }
.doc-lede { margin-top: 5px; font-size: 18px; color: var(--ink-2); }
.doc-lead { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 56px; padding: 22px 0 34px; border-top: 2px solid var(--ink); }
.doc-n { font-size: 11.5px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.hero-figure { margin-top: 6px; font-size: 118px; line-height: 0.98; font-weight: 600; letter-spacing: -0.04em; }
.hero-line { margin-top: 8px; font-size: 23px; line-height: 1.28; font-weight: 500; max-width: 26em; }
.hero-sub { margin-top: 8px; font-size: 15px; color: var(--ink-2); max-width: 36em; }
.hero-num .doc-intro { margin-top: 14px; }
.limits { padding: 20px 26px 22px; background: var(--paper-2); border-top: 3px solid var(--ink); }
.limits .doc-title { margin-top: 3px; }
.plain-list { display: grid; gap: 11px; margin-top: 12px; counter-reset: n; font-size: 16px; line-height: 1.42; }
.plain-list li { position: relative; padding-left: 28px; counter-increment: n; }
.plain-list li::before { content: counter(n); position: absolute; left: 0; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.doc-sec { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 44px; padding: 26px 0 30px; border-top: 1px solid var(--rule-2); }
.doc-title { font-size: 22px; line-height: 1.2; font-weight: 600; letter-spacing: -0.01em; margin-top: 2px; }
.doc-intro { margin-top: 8px; font-size: 14.5px; color: var(--ink-2); }
.doc-side .lg { margin-top: 12px; }
.mult-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 26px 30px; }
.small-mult { min-width: 0; }
.key { display: flex; flex-wrap: wrap; gap: 3px 14px; margin-bottom: 6px; font-size: 12.5px; color: var(--ink-2); }
.key li { display: inline-flex; align-items: center; gap: 6px; }
.key-line { width: 14px; height: 2px; }
.key-box { width: 11px; height: 11px; }
.bars { display: grid; gap: 5px; }
.bars li { display: grid; grid-template-columns: minmax(118px, 42%) minmax(0, 1fr) 42px; gap: 8px; align-items: center; font-size: 13px; color: var(--ink-2); }
.bars-track { display: block; height: 11px; background: var(--paper-2); }
.bars-fill { display: block; height: 100%; background: var(--rule-2); }
.bars-value { text-align: right; font-variant-numeric: tabular-nums; }
.bars li.is-strong { color: var(--ink); font-weight: 600; }
.bars li.is-strong .bars-fill { background: var(--blue); }
.table-scroll { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; }
table.data th { text-align: left; font-size: 12px; font-weight: 600; color: var(--ink-2); vertical-align: bottom; padding: 5px 12px 5px 0; border-bottom: 1px solid var(--ink); }
table.data td { padding: 6px 12px 6px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
table.data .num { text-align: right; font-variant-numeric: tabular-nums; }
table.data tfoot th, table.data tfoot td { font-size: 14px; font-weight: 600; color: var(--ink); border-top: 1px solid var(--ink); border-bottom: 0; }
.status { padding: 20px 26px 22px; background: var(--paper-2); border-top: 3px solid var(--ink); margin-bottom: 26px; }
.status-head { margin-top: 4px; font-size: 30px; line-height: 1.18; font-weight: 600; letter-spacing: -0.015em; }
.status-note { margin-top: 6px; font-size: 17px; max-width: 46em; }
.split { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.mini-map svg { display: block; width: 100%; height: auto; }
.mini-map path:hover { stroke: var(--ink); stroke-width: 1.4; }
.plain-mini { display: grid; gap: 3px; font-size: 13.5px; color: var(--ink-2); }
.plain-mini strong { color: var(--ink); font-variant-numeric: tabular-nums; }
.split .sub-title + * { margin-bottom: 14px; }
.split .note + .sub-title { margin-top: 18px; }
.doc-wide { grid-template-columns: 1fr; gap: 14px; }
.doc-wide .doc-intro { max-width: 62em; }
.fan-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px 22px; }
.fan { min-width: 0; padding-top: 7px; border-top: 1px solid var(--rule-2); }
.fan.is-high { border-top: 2px solid var(--l2); }
.fan.is-extreme { border-top: 3px solid var(--l3); }
.fan-title { font-size: 13.5px; font-weight: 600; line-height: 1.25; }
.fan-read { font-size: 12.5px; color: var(--ink-2); margin-bottom: 2px; }
.fan-read strong { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.fan .note { margin-top: 2px; font-size: 11.5px; }

/* Footer */
.foot { padding: 14px var(--gutter) 18px; border-top: 2px solid var(--ink); font-size: 13.5px; color: var(--ink-2); }
.foot strong { color: var(--ink); }
.foot p + p { margin-top: 1px; }
.fatal { max-width: 40em; margin: 60px auto; padding: 0 20px; }

@media (max-width: 1260px) {
  .brand-line { display: none; }
  .screen-map { grid-template-columns: minmax(0, 1fr) 380px; }
  .mapwrap { grid-template-columns: minmax(0, 1fr) 248px; }
  .mh-date { font-size: 24px; }
}
@media (max-height: 860px) and (min-width: 1001px) {
  .lg-marks, .lg-note { display: none; }
  .story-caption { min-height: 0; }
}
@media (max-height: 700px) and (min-width: 1001px) {
  .stage { position: static; height: auto; }
  .mapwrap { flex: none; height: 520px; }
}
@media (max-width: 1000px) {
  :root { --gutter: 14px; }
  .top { position: static; }
  .mast { flex-wrap: wrap; gap: 0 12px; padding: 8px var(--gutter) 0; }
  .tabs-main { order: 3; width: 100%; margin: 4px 0 0; height: 38px; align-self: auto; }
  .tabs-main a { padding: 0 12px 0 0; margin-right: 8px; }
  .screen-map { display: block; }
  .today-strip { display: none; }
  /* The demo comes first on a phone: replay, date, map, timeline. Settings and the key follow. */
  .stage { position: static; height: auto; }
  .mapwrap, .keycol { display: contents; }
  .stories { order: 1; }
  .map-head { order: 2; padding: 4px var(--gutter) 4px; }
  .mapcol { order: 3; }
  .timeline { order: 4; }
  .controls { order: 5; border-bottom: 0; }
  .legend { order: 6; padding: 8px var(--gutter) 12px; border-top: 1px solid var(--rule); }
  #map { position: relative; inset: auto; width: 100%; height: 78vw; max-height: 560px; }
  .map-tools { top: 6px; right: 8px; }
  .story-row { flex-wrap: nowrap; overflow-x: auto; gap: 16px; scrollbar-width: none; }
  .story-row::-webkit-scrollbar { display: none; }
  .story-row .ctl-label { display: none; }
  .story { flex: none; min-height: 38px; align-items: center; }
  .lg { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 14px; }
  .lg-villages { grid-column: 1 / -1; }
  .controls { gap: 8px 16px; }
  .choice button { height: 40px; min-width: 40px; }
  select { height: 40px; }
  .tool { width: 40px; height: 40px; }
  .tool-wide { width: auto; padding: 0 9px; }
  .timeline { grid-template-columns: 1fr; gap: 6px; }
  .tl-side { flex-direction: row; padding-top: 0; }
  .btn-play { flex: 1 1 auto; width: auto; height: 40px; }
  .tl-zoom { flex: 0 0 158px; }
  .tl-range { width: 100%; }
  .tl-range button { height: 40px; font-size: 13px; }
  .panel { border-left: 0; border-top: 2px solid var(--ink); padding: 12px var(--gutter) 24px; }
  .al-body { grid-template-columns: minmax(0, 206px) minmax(0, 1fr); }
  .screen-doc { padding: 18px var(--gutter) 28px; }
  .doc-h1 { font-size: 34px; }
  .doc-lead { grid-template-columns: 1fr; gap: 24px; padding-bottom: 24px; }
  .hero-figure { font-size: 92px; }
  .hero-line { font-size: 20px; }
  .doc-sec { grid-template-columns: 1fr; gap: 12px; padding: 20px 0 22px; }
  .split { grid-template-columns: 1fr; gap: 18px; }
  .status { padding: 16px 16px 18px; }
  .status-head { font-size: 24px; }
  .limits { padding: 16px 16px 18px; }
  .fan-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px 14px; }
}
@media (max-width: 480px) {
  .al-body { grid-template-columns: 1fr; }
  .phone { max-width: 230px; }
  .mh-date { font-size: 27px; }
  .brand-word { font-size: 22px; }
  .rank button { padding: 8px 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* Evidence: two results stacked, the failure first. */
.hero-next { margin-top: 1.75rem; }
.hero-figure-2 { font-size: clamp(2rem, 4vw, 3rem); }
