:root {
  --ink: #142A3A;
  --ink-muted: #526675;
  --accent: #0C766E;
  --accent-soft: #DCEDE8;
  --paper: #F7F6F2;
  --paper-deep: #ECEBE5;
  --surface: #FFFFFF;
  --line: #D6D9D2;
  --warm: #B66E52;
  --max: 1160px;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.52; }
a { color: inherit; text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible, select:focus-visible, details summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.skip-link { position: fixed; z-index: 100; top: 8px; left: 8px; padding: .7rem .9rem; background: var(--accent); color: #fff; font-weight: 700; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.site-header { position: sticky; top: 0; z-index: 20; background: var(--paper); border-bottom: 1px solid var(--line); }
.site-header-inner { max-width: var(--max); min-height: 74px; margin: auto; padding: 12px 28px; display: flex; align-items: center; gap: 28px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-size: 15px; font-weight: 780; letter-spacing: -.035em; line-height: .98; text-decoration: none; white-space: nowrap; }
.wordmark em { color: var(--accent); font-style: normal; }
.mark { display: inline-flex; align-items: end; gap: 3px; height: 25px; }
.mark i { display: block; width: 4px; height: 10px; background: var(--ink); }
.mark i:nth-child(2) { height: 20px; background: var(--accent); }
.mark i:nth-child(3) { height: 15px; background: #6B9BA1; }
.main-nav { display: flex; gap: 22px; margin-left: auto; font-size: 13px; font-weight: 650; }
.main-nav a { text-decoration: none; }
.language-switch { padding: .42rem .55rem; border: 1px solid var(--ink); color: var(--ink); font: 600 11px var(--sans); letter-spacing: .06em; text-decoration: none; }

.data-stamp, .kicker { margin: 0 0 12px; font: 600 10px/1.45 var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.data-stamp { color: var(--accent); }
.kicker { color: var(--accent); }
.button-link, button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 10px 14px; border: 1px solid var(--ink); border-radius: 0; background: var(--ink); color: #fff; cursor: pointer; font: 700 13px var(--sans); text-decoration: none; }
.button-link:hover, button:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.button-link.ghost { border-color: var(--line); background: transparent; color: var(--ink); }
.button-link.ghost:hover { border-color: var(--ink); background: var(--ink); color: #fff; }

.control-deck { background: var(--ink); color: #fff; }
.control-deck-inner { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); align-items: end; gap: 62px; max-width: var(--max); margin: auto; padding: 66px 28px 58px; }
.deck-intro h1 { max-width: 700px; margin: 0; font-size: clamp(38px, 5vw, 68px); font-weight: 760; letter-spacing: -.06em; line-height: .98; }
.deck-intro > p:not(.data-stamp) { max-width: 560px; margin: 20px 0 0; color: #D4DFE2; font-size: 17px; }
.status-chip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 20px; color: #D3DEE0; font: 500 13px/1.45 var(--sans); letter-spacing: 0; }
.status-dot { width: 8px; height: 8px; border: 2px solid #A9D9CE; border-radius: 50%; }
.primary-answer { padding-left: 28px; border-left: 1px solid #607582; }
.primary-answer p, .primary-answer span { display: block; margin: 0; color: #C4D1D5; font-size: 12px; }
.primary-answer strong { display: block; margin: 12px 0 8px; color: #B9EBDB; font-size: clamp(58px, 7vw, 94px); font-weight: 720; letter-spacing: -.08em; line-height: .86; }
.primary-answer small { display: block; margin-top: 18px; color: #fff; font-size: 12px; line-height: 1.45; }
.primary-answer small span { display: inline; }

.dashboard-kpis { display: grid; grid-template-columns: repeat(3, 1fr); max-width: var(--max); margin: 0 auto; border: 1px solid var(--line); border-top: 0; background: var(--surface); }
.dashboard-kpis article { display: flex; flex-direction: column; justify-content: space-between; min-height: 137px; padding: 22px 24px; border-right: 1px solid var(--line); }
.dashboard-kpis article:last-child { border-right: 0; }
.dashboard-kpis span, .dashboard-kpis small { color: var(--ink-muted); font: 10px/1.45 var(--sans); letter-spacing: .04em; }
.dashboard-kpis strong { display: block; font-size: 29px; letter-spacing: -.05em; line-height: 1.05; }
.kpi-action { align-self: flex-start; font-size: 18px; font-weight: 750; letter-spacing: -.03em; text-decoration: none; }
.kpi-action span { color: var(--accent); font: 22px var(--sans); }

.trend-panel, .entity-strip, .reuse-panel, .meaning-panel, .source-line, .content-page { max-width: var(--max); margin-right: auto; margin-left: auto; padding-right: 28px; padding-left: 28px; }
.trend-panel { padding-top: 70px; padding-bottom: 62px; }
.panel-heading { display: flex; align-items: end; justify-content: space-between; gap: 28px; margin-bottom: 24px; }
.panel-heading h2, .meaning-panel h2, .map-heading h2, .explorer-table h2, .prose h2 { margin: 0; font-size: clamp(27px, 3vw, 39px); letter-spacing: -.05em; line-height: 1.04; }
.panel-heading > p { max-width: 310px; margin: 0; color: var(--ink-muted); font-size: 12px; line-height: 1.45; }
.trend-figure { margin: 0; padding: 18px 18px 12px; border: 1px solid var(--line); background: var(--surface); }
.trend-figure svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-axis { stroke: #AEBBB8; stroke-width: 1; }
.chart-grid { stroke: #DDE5E1; stroke-width: 1; stroke-dasharray: 3 5; }
.chart-line { stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.chart-point { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; }
.chart-y-label, .chart-x-label { fill: var(--ink-muted); font-family: var(--sans); font-size: 11px; }
.chart-scale { display: none; }
.chart-periods { display: flex; justify-content: space-between; gap: 8px; margin: 2px 0 0 48px; color: var(--ink-muted); font: 10px var(--sans); }
.chart-summary { display: flex; flex-wrap: wrap; gap: 5px; margin: 6px 0 0 48px; color: var(--ink-muted); font-size: 11px; }
.chart-summary strong { color: var(--ink); }
.table-wrap { overflow-x: auto; border-top: 1px solid var(--line); }
table { width: 100%; min-width: 540px; border-collapse: collapse; text-align: left; font-size: 14px; }
th, td { padding: 13px 10px; border-bottom: 1px solid var(--line); }
thead th { color: var(--ink-muted); font: 600 10px var(--sans); letter-spacing: .07em; text-transform: uppercase; }
tbody th { font-weight: 700; letter-spacing: -.02em; }
tbody tr:hover { background: #F3F7F5; }
.quiet-state { padding: 28px 0; color: var(--ink-muted); }

.entity-strip { padding-top: 10px; padding-bottom: 64px; }
.entity-cards { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); background: var(--surface); }
.entity-card { display: flex; flex-direction: column; align-items: flex-start; min-height: 220px; padding: 23px; border-right: 1px solid var(--line); }
.entity-card:last-child { border-right: 0; }
.entity-card p { min-height: 31px; margin: 0; color: var(--ink-muted); font: 10px/1.45 var(--sans); letter-spacing: .05em; text-transform: uppercase; }
.entity-card strong { margin: 28px 0 7px; font-size: clamp(35px, 4vw, 50px); letter-spacing: -.07em; line-height: 1; }
.entity-card > span { color: var(--ink-muted); font-size: 12px; }
.entity-card small { margin-top: 12px; color: var(--ink); font: 11px var(--sans); }
.entity-card a { margin-top: auto; color: var(--accent); font-size: 12px; font-weight: 750; text-decoration: none; }

.reuse-panel { display: flex; justify-content: space-between; gap: 32px; margin-bottom: 64px; padding-top: 34px; padding-bottom: 34px; border-top: 3px solid var(--accent); border-bottom: 1px solid var(--line); background: #E8F1EE; }
.reuse-panel h2 { margin: 0; font-size: clamp(26px, 3vw, 37px); letter-spacing: -.05em; }
.reuse-panel p:not(.data-stamp) { max-width: 540px; margin: 10px 0 0; font-size: 15px; }
.reuse-actions { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; }
.copy-api { border-color: #8BA9A0; background: transparent; color: var(--ink); }
.copy-api:hover { border-color: var(--ink); background: var(--ink); color: #fff; }
.reuse-actions .text-link, .text-link { color: var(--ink); font-size: 12px; font-weight: 750; }
.meaning-panel { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 26px; padding-top: 52px; padding-bottom: 52px; border-top: 1px solid var(--line); }
.meaning-index { padding-top: 7px; color: var(--accent); font: 14px var(--sans); }
.meaning-panel p { max-width: 780px; margin: 15px 0; font-size: 17px; line-height: 1.52; }
.meaning-panel.compact { margin-top: 50px; border-bottom: 1px solid var(--line); }
.source-line { margin-top: 0; padding-top: 18px; padding-bottom: 44px; border-top: 1px solid var(--line); color: var(--ink-muted); font: 10px/1.65 var(--sans); }
.source-label { color: var(--ink); font-weight: 600; text-transform: uppercase; }
.source-line a { color: var(--ink); }

.content-page { min-height: 72vh; padding-top: 52px; padding-bottom: 0; }
.dashboard-page-head { max-width: 720px; margin-bottom: 32px; }
.dashboard-page-head .data-stamp, .territory-control .data-stamp { color: var(--accent); }
.dashboard-page-head h1, .territory-control h1 { margin: 0; font-size: clamp(40px, 5vw, 66px); letter-spacing: -.065em; line-height: .99; }
.dashboard-page-head > p:not(.data-stamp) { max-width: 670px; margin: 16px 0 0; color: var(--ink-muted); font-size: 17px; }
.compare-form { display: grid; grid-template-columns: minmax(205px, 1.2fr) minmax(200px, 1.25fr) minmax(190px, 1.35fr) minmax(78px, .55fr) minmax(145px, .9fr) auto; align-items: end; gap: 10px; margin-bottom: 10px; padding: 16px; border: 1px solid var(--line); background: var(--surface); }
.compare-form label { display: block; color: var(--ink-muted); font: 600 10px var(--sans); letter-spacing: .06em; text-transform: uppercase; }
select { display: block; width: 100%; margin-top: 7px; padding: 11px; border: 1px solid #B4C0BC; border-radius: 0; background: #fff; color: var(--ink); font: 500 13px var(--sans); }
.filter-context { min-height: 65px; padding: 10px 12px; border: 1px solid var(--line); background: #F7F8F5; }
.filter-context span { display: block; margin-bottom: 8px; color: var(--ink-muted); font: 600 10px var(--sans); letter-spacing: .06em; text-transform: uppercase; }
.filter-context strong { display: block; color: var(--ink); font-size: 13px; line-height: 1.25; }
.focus-filter.is-disabled { opacity: .5; }
.focus-filter.is-disabled select { cursor: not-allowed; }
.compare-help { max-width: 820px; margin: 0 0 18px; color: var(--ink-muted); font-size: 13px; line-height: 1.5; }
.selection-summary { display: flex; flex-wrap: wrap; gap: 7px; align-items: baseline; margin: 0 0 18px; padding: 12px 15px; border-left: 3px solid var(--accent); background: #EFF6F3; color: var(--ink); font-size: 13px; }
.selection-summary a { margin-left: auto; color: var(--ink); font-weight: 750; }
.export-action { display: grid; justify-items: end; gap: 6px; }
.export-action small { color: var(--ink-muted); font-size: 10px; text-align: right; }
.territory-note, .secondary-note { margin: 0 0 28px; padding: 12px 15px; border-left: 3px solid var(--accent); background: var(--accent-soft); color: var(--ink-muted); font-size: 13px; }
.explorer-pending { margin-bottom: 48px; }
.map-panel { margin-bottom: 46px; padding: 36px 0 24px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.map-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 18px; }
.map-heading p { max-width: 600px; margin: 9px 0 0; color: var(--ink-muted); font-size: 14px; }
.map-heading .map-coverage { max-width: 250px; text-align: right; font: 10px var(--sans); }
.map-canvas { display: grid; min-height: 430px; padding: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-muted); font-size: 13px; place-items: center; }
.map-canvas svg { display: block; width: 100%; height: auto; max-height: 680px; }
.map-area { cursor: pointer; stroke: var(--paper); stroke-width: 1.2; transition: filter .16s ease, stroke-width .16s ease; vector-effect: non-scaling-stroke; }
.map-area:focus-visible { outline: none; stroke: var(--ink); stroke-width: 3; }
.map-area:hover, .map-area.is-selected { filter: brightness(.93); stroke: var(--ink); stroke-width: 2.4; }
.map-area.is-shown { fill: #6DA595; }
.map-area.is-suppressed { fill: #C8906C; stroke-dasharray: 4 2; }
.map-area.is-missing { fill: #DFE5E0; }
.map-error { padding: 24px; text-align: center; }
.map-legend { display: flex; flex-wrap: wrap; gap: 16px; margin: 14px 0; color: var(--ink-muted); font-size: 11px; }
.map-legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend-swatch { width: 14px; height: 14px; border: 1px solid var(--line); }
.legend-swatch.is-shown { background: #6DA595; }
.legend-swatch.is-suppressed { background: repeating-linear-gradient(135deg, #C8906C 0, #C8906C 3px, #fff 3px, #fff 5px); }
.legend-swatch.is-missing { background: #DFE5E0; }
.map-detail { min-height: 48px; margin: 0; padding: 13px 15px; border-left: 3px solid var(--accent); background: #EFF6F3; font-size: 13px; }
.map-open-link { color: var(--ink); font-weight: 800; white-space: nowrap; }
.map-attribution { margin: 13px 0 0; color: var(--ink-muted); font: 10px var(--sans); }
.explorer-table { margin-bottom: 0; }
.territory-disclosures { margin-top: 34px; border-top: 1px solid var(--line); }
.territory-disclosures details { border-bottom: 1px solid var(--line); }
.territory-disclosures summary { padding: 17px 12px; cursor: pointer; font-size: 14px; font-weight: 750; list-style-position: inside; }
.territory-disclosures details[open] summary { border-bottom: 1px solid var(--line); }
.territory-disclosures .table-wrap { padding: 0 12px 12px; }

.breadcrumbs { display: flex; gap: 8px; margin: 0 0 24px; color: var(--ink-muted); font: 10px var(--sans); }
.territory-control { display: grid; grid-template-columns: minmax(0, 1fr) minmax(250px, .43fr); align-items: end; gap: 32px; padding: 32px; border: 1px solid var(--line); background: var(--surface); }
.territory-control > div > p:not(.data-stamp) { margin: 12px 0 0; color: var(--ink-muted); }
.territory-answer { padding-left: 28px; border-left: 1px solid var(--line); }
.territory-answer > span, .territory-answer small { display: block; color: var(--ink-muted); font-size: 12px; }
.territory-answer strong { display: block; margin: 10px 0; font-size: clamp(52px, 6vw, 78px); letter-spacing: -.08em; line-height: .9; }
.territory-answer .button-link { margin-top: 20px; }
.static-dashboard .prose { max-width: 760px; }
.prose h2 { margin: 42px 0 12px; }
.prose p { margin: 0 0 19px; font-size: 17px; line-height: 1.6; }
.page-lede { max-width: 700px; margin: 0 0 28px; color: var(--ink-muted); font-size: 17px; }
.status-grid { display: grid; grid-template-columns: repeat(2, 1fr); margin-bottom: 36px; border: 1px solid var(--line); background: var(--surface); }
.status-grid > div { min-height: 138px; padding: 22px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.status-grid span { display: block; margin-bottom: 27px; color: var(--ink-muted); font: 10px var(--sans); letter-spacing: .06em; text-transform: uppercase; }
.status-grid strong { display: block; font-size: 24px; letter-spacing: -.04em; line-height: 1.1; }
.unavailable { max-width: 760px; padding: 30px; border-left: 4px solid var(--warm); background: var(--surface); }
.unavailable h1 { margin: 0 0 10px; font-size: 42px; }
.site-footer { display: flex; justify-content: space-between; gap: 32px; max-width: var(--max); margin: 0 auto; padding: 32px 28px 42px; border-top: 1px solid var(--line); color: var(--ink-muted); font-size: 12px; }
.site-footer .small { color: var(--ink); font-size: 15px; }
.site-footer p { max-width: 430px; margin: 13px 0 0; }
.site-footer .site-credit { margin-top: 8px; color: var(--ink); font-size: 12px; }
.site-credit a { color: var(--ink); font-weight: 700; }
.footer-links { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 18px; }
.footer-links a { color: var(--ink); font-weight: 700; text-decoration: none; }

@media (max-width: 880px) {
  .site-header-inner { min-height: 68px; padding: 10px 16px; }
  .main-nav { display: none; }
  .language-switch { margin-left: auto; }
  .control-deck-inner, .trend-panel, .entity-strip, .reuse-panel, .meaning-panel, .source-line, .content-page { padding-right: 16px; padding-left: 16px; }
  .control-deck-inner { grid-template-columns: 1fr; gap: 36px; padding-top: 48px; padding-bottom: 44px; }
  .primary-answer { padding: 23px 0 0; border-top: 1px solid #607582; border-left: 0; }
  .dashboard-kpis { grid-template-columns: 1fr; margin-right: 16px; margin-left: 16px; }
  .dashboard-kpis article { min-height: 112px; padding: 19px 20px; border-right: 0; border-bottom: 1px solid var(--line); }
  .dashboard-kpis article:last-child { border-bottom: 0; }
  .trend-panel { padding-top: 48px; padding-bottom: 46px; }
  .panel-heading { display: block; }
  .panel-heading > p { margin-top: 11px; }
  .trend-figure { padding: 10px 5px 10px; }
  .chart-y-label, .chart-x-label { display: none; }
  .chart-scale { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 8px 0 0 56px; color: var(--ink-muted); font: 10px/1.35 var(--sans); }
  .chart-scale span:nth-child(2) { text-align: center; }
  .chart-scale span:last-child { text-align: right; }
  .chart-scale b { display: block; color: var(--ink); font-weight: 700; }
  .chart-periods { margin-left: 56px; font-size: 9px; }
  .chart-summary { margin-left: 56px; font-size: 10px; }
  .trend-table { overflow: visible; margin: 0; }
  .trend-table table { min-width: 0; }
  .trend-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
  .trend-table tbody, .trend-table tr, .trend-table td { display: block; width: 100%; }
  .trend-table tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "period total" "source source"; gap: 2px 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
  .trend-table td { padding: 0; border: 0; }
  .trend-table td:nth-child(1) { grid-area: period; font-weight: 700; }
  .trend-table td:nth-child(2) { grid-area: total; font-weight: 750; text-align: right; }
  .trend-table td:nth-child(3) { grid-area: source; color: var(--ink-muted); font: 10px var(--sans); }
  .trend-table td:nth-child(3)::before { content: attr(data-label) ": "; text-transform: uppercase; letter-spacing: .05em; }
  .entity-cards { grid-template-columns: 1fr; }
  .entity-card { min-height: 177px; border-right: 0; border-bottom: 1px solid var(--line); }
  .entity-card:last-child { border-bottom: 0; }
  .reuse-panel { display: block; margin-bottom: 50px; padding-top: 27px; padding-bottom: 27px; }
  .reuse-actions { align-items: stretch; margin-top: 21px; }
  .meaning-panel { grid-template-columns: 1fr; gap: 8px; padding-top: 40px; padding-bottom: 40px; }
  .meaning-index { padding-top: 0; }
  .meaning-panel p { font-size: 16px; }
  .compare-form { grid-template-columns: 1fr 1fr; }
  .compare-form .level-filter, .compare-form .parent-filter, .compare-form .filter-context, .compare-form .focus-filter, .compare-form button { grid-column: 1 / -1; }
  .selection-summary a { margin-left: 0; }
  .export-action { justify-items: start; margin-top: 15px; }
  .export-action small { text-align: left; }
  .map-heading { display: block; }
  .map-heading .map-coverage { margin-top: 14px; text-align: left; }
  .map-canvas { min-height: 305px; padding: 5px; }
  .territory-disclosures .table-wrap { margin-right: -16px; margin-left: -16px; padding-right: 16px; padding-left: 16px; }
  .territory-disclosures summary { padding-right: 0; padding-left: 0; }
  .compare-table { overflow: visible; }
  .compare-table table { min-width: 0; }
  .compare-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
  .compare-table tbody, .compare-table tr, .compare-table td, .compare-table th { display: block; width: 100%; }
  .compare-table tr { padding: 15px 0; border-bottom: 1px solid var(--line); }
  .compare-table td, .compare-table th { padding: 4px 0; border: 0; }
  .compare-table td::before { display: block; margin-bottom: 2px; color: var(--ink-muted); content: attr(data-label); font: 600 9px var(--sans); letter-spacing: .08em; text-transform: uppercase; }
  .territory-control { grid-template-columns: 1fr; padding: 24px; }
  .territory-answer { padding: 21px 0 0; border-top: 1px solid var(--line); border-left: 0; }
  .status-grid { grid-template-columns: 1fr; }
  .status-grid > div { border-right: 0; }
  .site-footer { display: block; padding: 30px 16px 38px; }
  .footer-links { margin-top: 24px; }
}

@media (max-width: 390px) {
  .deck-intro h1 { font-size: 38px; }
  .primary-answer strong { font-size: 58px; }
  .reuse-actions .button-link, .reuse-actions .copy-api { width: 100%; }
  .compare-form { grid-template-columns: 1fr; }
  .compare-form label { grid-column: 1 / -1; }
  .chart-x-label { font-size: 9px; }
}

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