:root {
  --night: #0b0d10;
  --panel: #12151a;
  --panel-2: #171b22;
  --panel-3: #20242c;
  --ink: #f0eadb;
  --muted: #a2a8ae;
  --quiet: #737b85;
  --line: #343a43;
  --line-soft: rgba(255,255,255,.075);
  --brass: #c8a15a;
  --brass-2: #efd082;
  --green: #78b7a8;
  --amber: #d99a4e;
  --red: #c96b62;
  --blue: #7fa8cf;
  --violet: #a98dca;
  --focus: #efd082;
  --font-body: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", "IBM Plex Mono", Consolas, monospace;
  --font-display: "Songti SC", "STSong", "Noto Serif SC", Georgia, serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--night); color-scheme: dark; scroll-behavior: smooth; }
body { margin: 0; min-width: 0; color: var(--ink); background: var(--night); font-family: var(--font-body); line-height: 1.55; -webkit-font-smoothing: antialiased; }
button, select { font: inherit; }
button { color: inherit; }
a { color: inherit; }
.shell { width: min(1320px, calc(100% - 48px)); margin-inline: auto; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: fixed; z-index: 100; top: 8px; left: 8px; transform: translateY(-150%); padding: 10px 14px; color: var(--night); background: var(--brass-2); }
.skip-link:focus { transform: none; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }

.app-header { position: sticky; z-index: 20; top: 0; border-bottom: 1px solid rgba(200,161,90,.28); background: rgba(11,13,16,.94); backdrop-filter: blur(16px); }
.header-inner { min-height: 62px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand-lockup, .header-meta, .language-switch { display: flex; align-items: center; }
.brand-lockup { gap: 14px; min-width: 0; text-decoration: none; }
.brand { font-family: var(--font-display); font-size: 22px; letter-spacing: .14em; }
.product-name { padding-left: 14px; border-left: 1px solid var(--line); color: var(--muted); font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.header-meta { gap: 12px; }
.candidate-mark { color: var(--brass-2); font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; text-decoration: none; }
.language-switch { padding: 2px; border: 1px solid var(--line); }
.lang-button { min-width: 44px; min-height: 32px; border: 0; background: transparent; color: var(--quiet); font-family: var(--font-mono); font-size: 10px; cursor: pointer; }
.lang-button.is-active { color: var(--night); background: var(--brass); }

.console { padding-block: 44px 72px; }
.intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 430px); gap: 42px; align-items: end; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.eyebrow, .section-index, .context-key, .empty-code { margin: 0; color: var(--brass); font-family: var(--font-mono); font-size: 10px; letter-spacing: .13em; text-transform: uppercase; }
.intro h1 { max-width: 860px; margin: 10px 0 0; font-family: var(--font-display); font-size: clamp(36px, 5vw, 66px); font-weight: 500; line-height: 1; letter-spacing: .01em; text-wrap: balance; }
.intro-note { display: grid; gap: 8px; padding-left: 18px; border-left: 2px solid var(--brass); color: var(--muted); font-size: 13px; }
.intro-note strong { color: var(--ink); font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .04em; }

.context-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 24px; }
.context-cell { min-width: 0; min-height: 150px; display: flex; flex-direction: column; align-items: flex-start; gap: 5px; padding: 18px; border: 0; border-top: 1px solid var(--line); border-left: 1px solid var(--line); color: var(--muted); background: var(--panel); text-align: left; }
button.context-cell { cursor: pointer; transition: border-color .16s ease, background-color .16s ease; }
button.context-cell:hover { background: var(--panel-2); box-shadow: inset 0 2px 0 var(--brass); }
.context-cell strong { margin-top: auto; color: var(--ink); font-family: var(--font-display); font-size: 21px; font-weight: 500; line-height: 1.15; }
.context-cell span:not(.context-key) { font-size: 12px; }
.context-cell small { color: var(--quiet); font-family: var(--font-mono); font-size: 10px; }
.context-status { border-top-style: dashed; }

.controls { position: sticky; z-index: 12; top: 62px; display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; gap: 12px; align-items: center; margin-top: 24px; padding: 10px; border: 1px solid var(--line); background: rgba(18,21,26,.96); }
.control-group { display: flex; min-width: 0; }
.control-button, .filter-button, .clear-button, .year-control select, .empty-state button, .inline-alert button { min-height: 40px; border: 1px solid transparent; background: transparent; color: var(--muted); cursor: pointer; font-family: var(--font-mono); font-size: 10px; letter-spacing: .03em; }
.control-button, .filter-button { padding: 9px 11px; }
.control-button + .control-button, .filter-button + .filter-button { border-left-color: var(--line); }
.control-button.is-active { color: var(--night); background: var(--brass-2); }
.filter-button.is-active { color: var(--ink); border-color: var(--brass); background: rgba(200,161,90,.12); }
.year-control { display: flex; align-items: center; gap: 8px; color: var(--quiet); font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; }
.year-control select { padding-inline: 10px; border-color: var(--line); }
.clear-button { padding-inline: 10px; border-color: var(--line); }

.inline-alert { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 14px; padding: 12px 14px; border-left: 3px solid var(--red); color: var(--muted); background: rgba(201,107,98,.09); font-size: 13px; }
.inline-alert strong { color: var(--ink); }
.inline-alert button { flex: 0 0 auto; min-width: 74px; border-color: var(--line); }

.timeline-section, .stream-section { margin-top: 54px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.section-heading h2 { margin: 5px 0 0; font-family: var(--font-display); font-size: 32px; font-weight: 500; line-height: 1; }
.section-heading > p { max-width: 520px; margin: 0; color: var(--quiet); font-family: var(--font-mono); font-size: 10px; text-align: right; }
.timeline-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; padding-block: 14px; color: var(--muted); font-family: var(--font-mono); font-size: 10px; }
.timeline-legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend-shape { width: 10px; height: 10px; display: inline-block; border: 1px solid var(--quiet); }
.legend-shape.released { border-radius: 50%; background: var(--muted); }
.legend-shape.scheduled { border-radius: 50%; background: transparent; }
.legend-shape.rescheduled { border-color: var(--amber); transform: rotate(45deg); }
.legend-shape.superseded { border-style: double; border-color: var(--violet); }

.timeline-grid { display: grid; grid-template-columns: repeat(12, minmax(0,1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.timeline-month { min-width: 0; min-height: 158px; padding: 10px 8px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.timeline-month.is-cutoff { box-shadow: inset 0 3px 0 var(--brass); }
.month-label { display: flex; justify-content: space-between; gap: 4px; color: var(--quiet); font-family: var(--font-mono); font-size: 9px; letter-spacing: .08em; }
.month-label strong { color: var(--ink); font-weight: 500; }
.timeline-nodes { display: grid; grid-template-columns: repeat(2, 44px); gap: 4px; margin-top: 12px; }
.timeline-node { position: relative; width: 44px; height: 44px; border: 1px solid var(--family-color, var(--line)); border-radius: 50%; color: var(--ink); background: var(--panel); cursor: pointer; font-family: var(--font-mono); font-size: 9px; }
.timeline-node[data-status="released"] { background: color-mix(in srgb, var(--family-color) 18%, var(--panel)); }
.timeline-node[data-status="scheduled"] { border-style: dashed; color: var(--muted); }
.timeline-node[data-status="rescheduled"] { border-color: transparent; }
.timeline-node[data-status="rescheduled"]::before { content: ""; position: absolute; inset: 7px; border: 1px solid var(--amber); border-radius: 3px; transform: rotate(45deg); }
.timeline-node[data-status="rescheduled"] > span { position: relative; z-index: 1; }
.timeline-node[data-status="superseded"] { border-style: double; }
.timeline-node .review-mark { position: absolute; top: -6px; right: -4px; width: 15px; height: 15px; display: grid; place-items: center; border-radius: 50%; color: var(--night); background: var(--brass-2); font-size: 9px; font-weight: 700; }
.month-jumps { display: none; }
.timeline-equivalent { margin: 12px 0 0; color: var(--quiet); font-size: 12px; }

.stream-section { scroll-margin-top: 130px; }
.sticky-heading { position: relative; }
.event-list { display: grid; }
.month-group { scroll-margin-top: 130px; }
.month-band { display: grid; grid-template-columns: 94px 1fr; gap: 18px; align-items: baseline; padding: 18px 14px 8px; border-bottom: 1px solid var(--line); color: var(--quiet); font-family: var(--font-mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
.month-band strong { color: var(--ink); font-family: var(--font-display); font-size: 22px; font-weight: 500; letter-spacing: 0; text-transform: none; }
.date-group { border-bottom: 1px solid var(--line); }
.date-group.is-paired { border-left: 2px solid var(--brass); }
.date-label { display: grid; grid-template-columns: 94px 1fr; gap: 18px; padding: 10px 14px 4px; color: var(--quiet); font-family: var(--font-mono); font-size: 10px; }
.date-label strong { color: var(--brass-2); font-weight: 500; }
.date-label span:last-child { text-transform: uppercase; letter-spacing: .08em; }
.event-row { width: 100%; min-height: 104px; display: grid; grid-template-columns: 94px 122px minmax(220px,1fr) minmax(230px,.86fr) 186px; gap: 18px; align-items: center; padding: 14px; border: 0; border-top: 1px solid var(--line-soft); color: var(--muted); background: transparent; text-align: left; cursor: pointer; transition: background-color .16s ease, box-shadow .16s ease; }
.event-row:hover { background: var(--panel); box-shadow: inset 3px 0 0 var(--family-color); }
.event-time, .family-code, .event-reference, .event-status { font-family: var(--font-mono); font-size: 10px; }
.event-time { color: var(--quiet); }
.family-code { display: inline-flex; align-items: center; gap: 7px; color: var(--family-color); letter-spacing: .08em; }
.family-code::before { content: attr(data-symbol); width: 24px; height: 24px; display: grid; place-items: center; border: 1px solid currentColor; border-radius: 50%; }
.event-title { min-width: 0; }
.event-title strong { display: block; color: var(--ink); font-family: var(--font-display); font-size: 19px; font-weight: 500; line-height: 1.2; }
.event-title span { display: block; margin-top: 5px; color: var(--quiet); font-size: 11px; }
.event-snapshot { color: var(--muted); font-size: 12.5px; line-height: 1.45; }
.event-snapshot strong { color: var(--ink); font-weight: 600; }
.event-status { display: grid; gap: 5px; justify-items: start; }
.status-label { display: inline-flex; align-items: center; gap: 6px; padding: 4px 7px; border: 1px solid var(--line); color: var(--muted); background: var(--panel); white-space: nowrap; }
.status-label::before { content: "○"; color: var(--quiet); }
.status-label.released::before { content: "●"; color: var(--green); }
.status-label.rescheduled::before { content: "↺"; color: var(--amber); }
.status-label.superseded::before { content: "◇"; color: var(--violet); }
.review-label { color: var(--brass-2); }
.review-label::before { content: "! "; font-weight: 700; }
.source-label { color: var(--amber); }

.empty-state { min-height: 300px; display: grid; place-items: center; align-content: center; gap: 10px; padding: 40px 20px; border-bottom: 1px solid var(--line); text-align: center; }
.empty-state h3 { margin: 0; font-family: var(--font-display); font-size: 28px; font-weight: 500; }
.empty-state p { max-width: 520px; margin: 0; color: var(--muted); }
.empty-state button { min-width: 140px; margin-top: 8px; border-color: var(--brass); color: var(--ink); }
.noscript-list { margin-top: 16px; padding: 18px; border: 1px dashed var(--line); color: var(--muted); }
.prototype-footer { display: flex; justify-content: space-between; gap: 20px; margin-top: 58px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--quiet); font-family: var(--font-mono); font-size: 9px; }
.prototype-footer a { color: var(--brass-2); text-decoration: none; }
.prototype-footer a:hover { text-decoration: underline; }

.ledger { width: min(560px, 100%); max-width: none; height: 100dvh; max-height: none; margin: 0 0 0 auto; padding: 0; border: 0; border-left: 1px solid rgba(200,161,90,.45); color: var(--ink); background: var(--panel); box-shadow: -24px 0 70px rgba(0,0,0,.42); }
.ledger::backdrop { background: rgba(0,0,0,.62); }
.ledger[open] { animation: ledger-in .2s ease-out both; }
.ledger-shell { min-height: 100%; display: flex; flex-direction: column; padding-bottom: env(safe-area-inset-bottom); }
.ledger-header { position: sticky; z-index: 2; top: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; padding: max(18px, env(safe-area-inset-top)) 20px 18px; border-bottom: 1px solid var(--line); background: var(--panel); }
.ledger-header h2 { max-width: 430px; margin: 5px 0 0; font-family: var(--font-display); font-size: 30px; font-weight: 500; line-height: 1.1; }
.ledger-close { width: 44px; height: 44px; flex: 0 0 auto; border: 1px solid var(--line); color: var(--ink); background: transparent; cursor: pointer; font-size: 24px; line-height: 1; }
.ledger-body { flex: 1; overflow: auto; padding: 20px; overscroll-behavior: contain; }
.ledger-section { padding-block: 16px; border-top: 1px solid var(--line); }
.ledger-section:first-child { padding-top: 0; border-top: 0; }
.ledger-section h3 { margin: 0 0 10px; color: var(--brass); font-family: var(--font-mono); font-size: 10px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; }
.identity-grid, .fact-grid { display: grid; grid-template-columns: 150px 1fr; gap: 8px 14px; margin: 0; }
.identity-grid dt, .fact-grid dt { color: var(--quiet); font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; }
.identity-grid dd, .fact-grid dd { margin: 0; color: var(--muted); font-size: 12.5px; overflow-wrap: anywhere; }
.fact-grid dd strong { color: var(--ink); }
.qualifier-box { padding: 12px 14px; border-left: 2px solid var(--brass); color: var(--muted); background: rgba(200,161,90,.07); font-size: 12.5px; }
.revision-chain { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.revision-step { display: grid; gap: 8px; padding: 11px 12px; border-left: 2px solid var(--line); color: var(--muted); background: var(--panel-2); font-size: 12px; }
.revision-step.is-selected { border-left-color: var(--brass-2); background: rgba(200,161,90,.09); }
.revision-step.is-later { border-left-style: dashed; opacity: .78; }
.revision-step > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 12px; }
.revision-step span:first-child { color: var(--quiet); font-family: var(--font-mono); font-size: 9px; text-transform: uppercase; }
.revision-step b { color: var(--brass-2); font-family: var(--font-mono); font-size: 9px; font-weight: 500; }
.revision-step strong { color: var(--ink); }
.revision-step small { color: var(--quiet); font-family: var(--font-mono); font-size: 9px; line-height: 1.6; }
.ledger details { border: 1px solid var(--line); }
.ledger summary { min-height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 12px; cursor: pointer; color: var(--ink); font-family: var(--font-mono); font-size: 10px; list-style: none; }
.ledger summary::after { content: "+"; color: var(--brass-2); }
.ledger details[open] summary::after { content: "−"; }
.detail-content { padding: 0 12px 12px; color: var(--muted); font-size: 12.5px; }
.source-link { display: block; padding: 10px 12px; border: 1px solid var(--line); color: var(--ink); background: var(--panel-2); font-size: 12px; text-decoration: none; overflow-wrap: anywhere; }
.source-link + .source-link { margin-top: 8px; }
.source-link small { display: block; margin-top: 4px; color: var(--quiet); font-family: var(--font-mono); font-size: 9px; }
.source-link:hover { border-color: var(--brass); background: var(--panel-3); }
.source-link::after { content: "↗"; float: right; margin-left: 10px; color: var(--brass-2); font-family: var(--font-mono); }
.source-note::after { content: none; }
.ledger-boundary { margin: 0; padding: 14px 20px max(14px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); color: var(--muted); background: var(--night); font-size: 11px; }

.family-FOMC { --family-color: var(--brass-2); }
.family-EMP { --family-color: var(--green); }
.family-CPI { --family-color: var(--red); }
.family-PCE { --family-color: var(--violet); }
.family-GDP { --family-color: var(--blue); }

@keyframes ledger-in { from { opacity: .7; transform: translateX(18px); } to { opacity: 1; transform: none; } }

@media (max-width: 1099px) {
  .shell { width: min(100% - 36px, 920px); }
  .intro { grid-template-columns: minmax(0,1fr) minmax(260px,340px); }
  .context-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .context-cell { min-height: 132px; }
  .controls { grid-template-columns: 1fr auto auto; }
  .view-control { grid-column: 1; }
  .family-control { grid-column: 1 / -1; grid-row: 2; }
  .year-control { grid-column: 2; grid-row: 1; }
  .clear-button { grid-column: 3; grid-row: 1; }
  .timeline-grid { grid-template-columns: repeat(6, minmax(0,1fr)); }
  .timeline-month { min-height: 146px; }
  .event-row { grid-template-columns: 74px 96px minmax(200px,1fr) minmax(190px,.8fr); }
  .event-status { grid-column: 3 / -1; grid-row: 2; display: flex; flex-wrap: wrap; }
}

@media (min-width: 1100px) and (max-width: 1359px) {
  .timeline-grid { grid-template-columns: repeat(6, minmax(0,1fr)); }
}

@media (max-width: 767px) {
  .shell { width: calc(100% - 28px); }
  .app-header { position: relative; }
  .header-inner { min-height: 58px; }
  .product-name { display: none; }
  .candidate-mark { display: none; }
  .console { padding-block: 28px 54px; }
  .intro { grid-template-columns: 1fr; gap: 20px; }
  .intro h1 { font-size: clamp(33px, 10.5vw, 46px); }
  .intro-note { padding-left: 14px; }
  .context-grid { grid-template-columns: 1fr 1fr; }
  .context-cell { min-height: 128px; padding: 14px; }
  .context-cell strong { font-size: 18px; }
  .controls { position: relative; top: auto; grid-template-columns: minmax(0,1fr) auto; gap: 8px; padding: 8px; }
  .view-control { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); }
  .control-button { min-width: 0; padding-inline: 4px; }
  .family-control { grid-column: 1 / -1; grid-row: 2; display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); }
  .filter-button { min-width: 0; padding-inline: 4px; }
  .year-control { grid-column: 1; grid-row: 3; }
  .clear-button { grid-column: 2; grid-row: 3; }
  .timeline-section, .stream-section { margin-top: 42px; }
  .section-heading { align-items: start; }
  .section-heading > p { max-width: 160px; }
  .timeline-legend { gap: 7px 12px; }
  .timeline-grid { display: none; }
  .month-jumps { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
  .month-jump { min-height: 54px; border: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--muted); background: transparent; cursor: pointer; font-family: var(--font-mono); font-size: 10px; }
  .month-jump strong { display: block; color: var(--ink); font-weight: 500; }
  .month-jump span { display: block; margin-top: 2px; color: var(--quiet); font-size: 9px; }
  .month-group { scroll-margin-top: 16px; }
  .month-band { grid-template-columns: 1fr; gap: 2px; padding-inline: 8px; }
  .date-label { grid-template-columns: 1fr auto; gap: 10px; padding-inline: 8px; }
  .event-row { min-height: 0; grid-template-columns: 68px minmax(0,1fr); gap: 9px 12px; padding: 14px 8px; }
  .event-time { grid-column: 1; grid-row: 1; }
  .family-code { grid-column: 1; grid-row: 2; }
  .event-title { grid-column: 2; grid-row: 1 / span 2; }
  .event-title strong { font-size: 17px; }
  .event-snapshot { grid-column: 1 / -1; grid-row: 3; padding-left: 80px; }
  .event-status { grid-column: 1 / -1; grid-row: 4; padding-left: 80px; }
  .prototype-footer { flex-direction: column; }
  .ledger { width: 100%; height: 100dvh; margin: 0; border-left: 0; }
  .ledger[open] { animation-name: ledger-up; }
  .ledger-header h2 { font-size: 26px; }
  .identity-grid, .fact-grid { grid-template-columns: 1fr; gap: 3px; }
  .identity-grid dd, .fact-grid dd { margin-bottom: 8px; }
}

@media (max-width: 360px) {
  .shell { width: calc(100% - 20px); }
  .brand { font-size: 19px; }
  .context-grid { grid-template-columns: 1fr; }
  .context-cell { min-height: 110px; }
  .section-heading { display: grid; gap: 8px; }
  .section-heading > p { max-width: none; text-align: left; }
  .month-jumps { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .event-row { grid-template-columns: 62px minmax(0,1fr); }
  .event-snapshot, .event-status { padding-left: 74px; }
  .status-label { white-space: normal; }
  .revision-step > div { display: grid; gap: 4px; }
}

@keyframes ledger-up { from { opacity: .7; transform: translateY(16px); } to { opacity: 1; transform: none; } }

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

html.reduce-motion { scroll-behavior: auto; }
html.reduce-motion *, html.reduce-motion *::before, html.reduce-motion *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
html.a11y-spacing body { line-height: 1.5; letter-spacing: .12em; word-spacing: .16em; }
html.a11y-spacing p { margin-bottom: 2em; }
