@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo-latin-ext.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --paper: #f9dcc9;
  --paper-2: #f2cdb6;
  --paper-3: #e9bea3;
  --ink: #1d1a17;
  --ink-2: #5a3526;
  --ink-3: #6e4632;
  --rule: #e2b598;
  --up: #066643;
  --down: #a32520;
  --gold: #a87b22;
  --gold-text: #7a5814;
  --on-ink: #f9dcc9;
  --on-ink-2: #b9a897;
  --up-on-ink: #4cc38a;
  --down-on-ink: #ff8577;
  --focus: #1d1a17;

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --step--1: 0.8125rem;
  --step-0: 0.9375rem;
  --step-1: 1.0625rem;
  --step-2: 1.375rem;
  --step-3: 2rem;
  --step-4: 3rem;

  --gutter: clamp(16px, 2.2vw, 28px);
  --max: 1360px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.45;
  font-variant-numeric: tabular-nums;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--ink); color: var(--paper); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
button { font: inherit; color: inherit; }
html { scrollbar-color: var(--ink-3) var(--paper-2); }
::-webkit-scrollbar { height: 10px; width: 10px; }
::-webkit-scrollbar-track { background: var(--paper-2); }
::-webkit-scrollbar-thumb { background: var(--ink-3); border: 2px solid var(--paper-2); border-radius: 6px; }

.icon { width: 1em; height: 1em; flex: none; vertical-align: -0.125em; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- masthead ---------- */
.mast {
  border-bottom: 2px solid var(--ink);
}
.mast .wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: end;
  gap: 8px 32px;
  padding-top: 18px;
  padding-bottom: 12px;
}
.brand { display: flex; align-items: baseline; gap: 12px; text-decoration: none; }
.brand b {
  font-stretch: 125%;
  font-weight: 850;
  font-size: var(--step-3);
  line-height: 0.9;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}
.brand span { font-stretch: 85%; font-weight: 600; font-size: var(--step-1); color: var(--ink-2); }
.dateline { font-size: var(--step--1); color: var(--ink-2); line-height: 1.35; }
.dateline strong { color: var(--ink); font-weight: 650; }
.nav { display: flex; gap: 4px; }
.nav a {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  font-weight: 650; font-size: var(--step--1); text-decoration: none;
  letter-spacing: 0.02em; text-transform: uppercase; font-stretch: 112%;
  border: 1px solid transparent; border-radius: 3px;
}
.nav a:hover { border-color: var(--ink); }
.nav a[aria-current="page"] { background: var(--ink); color: var(--paper); }

/* ---------- index strip (signature) ---------- */
.ticker {
  background: var(--ink);
  color: var(--on-ink);
  position: relative;
}
.ticker ol {
  list-style: none; margin: 0 auto; padding: 0 var(--gutter);
  max-width: var(--max);
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(92px, 1fr);
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}
.ticker ol::-webkit-scrollbar { display: none; }
.ticker li { scroll-snap-align: start; border-right: 1px solid rgba(249, 220, 201, 0.14); }
.ticker li:first-child { border-left: 1px solid rgba(249, 220, 201, 0.14); }
.ticker a {
  position: relative;
  display: grid; gap: 1px;
  padding: 9px 10px 10px;
  text-decoration: none;
  transition: background-color 600ms cubic-bezier(0.16, 1, 0.3, 1);
}
.ticker a:hover { background: rgba(249, 220, 201, 0.08); }
.ticker .code { font-stretch: 112%; font-weight: 800; font-size: var(--step--1); letter-spacing: 0.06em; }
.ticker .px { font-size: var(--step-1); font-weight: 600; font-stretch: 85%; }
.ticker .chg { font-size: var(--step--1); font-weight: 600; font-stretch: 85%; display: inline-flex; align-items: center; gap: 3px; }
.ticker .chg.up { color: var(--up-on-ink); }
.ticker .chg.down { color: var(--down-on-ink); }
.ticker .chg.flat { color: var(--on-ink-2); }
.ticker a[aria-current] { background: var(--paper); color: var(--ink); }
.ticker a[aria-current] .chg.up { color: var(--up); }
.ticker a[aria-current] .chg.down { color: var(--down); }
.ticker a[aria-current] .chg.flat { color: var(--ink-3); }
.ticker a.flash-up { background: rgba(76, 195, 138, 0.22); }
.ticker a.flash-down { background: rgba(255, 133, 119, 0.2); }
.ticker-note {
  max-width: var(--max); margin: 0 auto; padding: 6px var(--gutter) 0;
  font-size: var(--step--1); color: var(--ink-3);
}

/* ---------- sections ---------- */
main { padding-bottom: 64px; }
.sec { padding-top: 36px; }
.sec-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  border-top: 3px solid var(--ink);
  padding-top: 8px; margin-bottom: 14px;
}
.sec-head h2 {
  margin: 0; font-size: var(--step-2); line-height: 1.1; font-weight: 820; font-stretch: 78%;
  letter-spacing: -0.01em;
}
.sec-head p { margin: 0; color: var(--ink-2); font-size: var(--step--1); max-width: 70ch; }
.lead-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 0;
}
/* Newsprint column rules: a hairline between side-by-side columns. */
.lead-grid > :first-child, .coverage > :first-child { padding-right: 20px; }
.lead-grid > :last-child, .coverage > :last-child { padding-left: 20px; border-left: 1px solid var(--rule); }
.words > * + * { border-left: 1px solid var(--rule); padding-left: 20px; }
.words > :not(:last-child) { padding-right: 20px; }
/* Condensed figures and names, and column-group rules, belong to the public board only. */
#board td { font-stretch: 85%; }
#board th:nth-child(3), #board td:nth-child(3), #board th:nth-child(6), #board td:nth-child(6), #board th:nth-child(7), #board td:nth-child(7) { border-left: 1px solid var(--rule); }

/* ---------- movers ---------- */
.movers h3 {
  margin: 14px 0 4px; font-size: var(--step--1); font-weight: 750; font-stretch: 112%;
  letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-2);
}
.mover {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) 64px 108px;
  grid-template-areas: "code name px bar" "code head head head";
  gap: 2px 12px;
  align-items: baseline;
  padding: 10px 0 11px;
  border-bottom: 1px solid var(--rule);
}
.mover .code { grid-area: code; }
.mover .name { grid-area: name; font-weight: 650; text-decoration: none; font-stretch: 88%; }
.mover .px, .mover .bar { font-stretch: 85%; }
.mover .name:hover { text-decoration: underline; }
.mover .px { grid-area: px; text-align: right; }
.mover .bar { grid-area: bar; }
.mover .head {
  grid-area: head; font-size: var(--step--1); color: var(--ink-2);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none;
}
.mover .head:hover { text-decoration: underline; color: var(--ink); }
.code-chip {
  display: inline-block; min-width: 44px;
  font-stretch: 112%; font-weight: 800; font-size: 0.75rem; letter-spacing: 0.06em;
  padding: 2px 5px; border: 1.5px solid var(--ink); border-radius: 2px; text-align: center;
  text-decoration: none; line-height: 1.3;
}
a.code-chip:hover { background: var(--ink); color: var(--paper); }
.delta { display: inline-flex; align-items: center; gap: 4px; font-weight: 650; white-space: nowrap; }
.delta.up { color: var(--up); }
.delta.down { color: var(--down); }
.delta.flat { color: var(--ink-3); }
.dbar { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px; }
.dbar i { display: block; height: 8px; background: currentColor; border-radius: 1px; justify-self: start; }
.dbar.down i { justify-self: end; }

/* ---------- charts ---------- */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { font-family: var(--font); font-size: 11px; fill: var(--ink-3); font-variant-numeric: tabular-nums; }
.chart .grid line { stroke: var(--rule); stroke-width: 1; }
.chart .axis line { stroke: var(--ink); }
.gold-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 4px; }
.gold-px { font-size: var(--step-3); font-weight: 750; line-height: 1; color: var(--gold-text); letter-spacing: -0.01em; }
.gold-meta { font-size: var(--step--1); color: var(--ink-2); }
.caption { font-size: var(--step--1); color: var(--ink-3); margin: 6px 0 0; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: var(--step--1); color: var(--ink-2); margin-top: 8px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- board table ---------- */
.board-wrap { overflow-x: auto; }
table.board { width: 100%; border-collapse: collapse; min-width: 880px; }
.board th {
  text-align: left; font-weight: 700; font-size: 0.75rem; letter-spacing: 0.04em; text-transform: uppercase;
  font-stretch: 112%; color: var(--ink-2);
  border-bottom: 1.5px solid var(--ink); padding: 0;
  white-space: nowrap;
}
.board th.num, .board td.num { text-align: right; }
.board th button {
  all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 4px;
  padding: 8px 8px 7px; width: 100%; box-sizing: border-box;
}
.board th.num button { justify-content: flex-end; }
.board th button:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.board th button:hover { color: var(--ink); }
.board th[aria-sort] button { color: var(--ink); }
.board th .sort { opacity: 0; }
.board th[aria-sort] .sort { opacity: 1; }
.board th[aria-sort="ascending"] .sort { transform: rotate(180deg); }
.board td { padding: 9px 8px; border-bottom: 1px solid var(--rule); vertical-align: middle; }
.board tbody tr { cursor: pointer; }
.board tbody tr:hover { background: var(--paper-2); }
.board td.name a { font-weight: 650; text-decoration: none; }
.board td.name a:hover { text-decoration: underline; }
.board td.head { max-width: 340px; color: var(--ink-2); font-size: var(--step--1); }
.board td.head a { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none; }
.board td.head a:hover { text-decoration: underline; color: var(--ink); }
.board .spark { width: 120px; height: 28px; display: block; }

/* ---------- words ---------- */
.words { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
.words h3 { margin: 0 0 4px; font-size: var(--step--1); font-weight: 750; font-stretch: 112%; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-2); }
.words ol { list-style: none; margin: 0; padding: 0; }
.words li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 5px 0; border-bottom: 1px solid var(--rule); }
.words li span:last-child { color: var(--ink-2); }

/* ---------- coverage + footer ---------- */
.coverage { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 0; align-items: stretch; }
.coverage .notes p { margin: 0 0 10px; max-width: 62ch; color: var(--ink-2); }
.coverage .notes strong { color: var(--ink); }
footer { border-top: 2px solid var(--ink); padding: 18px 0 40px; font-size: var(--step--1); color: var(--ink-2); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 32px; justify-content: space-between; }

/* ---------- theme page ---------- */
.inst-head {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 24px; align-items: end;
  padding: 28px 0 18px; border-bottom: 1px solid var(--rule);
}
.inst-code {
  font-stretch: 125%; font-weight: 850; font-size: var(--step-4); line-height: 0.85; letter-spacing: -0.02em;
}
.inst-head h1 { margin: 0; font-size: var(--step-3); font-weight: 750; line-height: 1.05; letter-spacing: -0.015em; text-wrap: balance; }
.inst-quote { display: flex; gap: 20px; align-items: baseline; flex-wrap: wrap; margin-top: 6px; }
.inst-quote .px { font-size: var(--step-2); font-weight: 700; }
.inst-quote .meta { color: var(--ink-2); font-size: var(--step--1); }
.stepper { display: flex; gap: 6px; align-items: center; }
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 12px; border: 1.5px solid var(--ink); border-radius: 3px; background: transparent;
  font-weight: 650; font-size: var(--step--1); text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn kbd { font: inherit; font-size: 0.6875rem; padding: 0 4px; border: 1px solid currentColor; border-radius: 2px; opacity: 0.75; }
.back { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; font-size: var(--step--1); font-weight: 650; text-decoration: none; }
.back:hover { text-decoration: underline; }
.lists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; }
.titles { list-style: none; margin: 0; padding: 0; }
.titles li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.titles a { text-decoration: none; font-weight: 550; }
.titles a:hover { text-decoration: underline; }
.titles .when { font-size: var(--step--1); color: var(--ink-3); white-space: nowrap; }
.ext { display: inline; margin-left: 4px; color: var(--ink-3); }

/* ---------- states ---------- */
.state { padding: 64px 0; max-width: 56ch; }
.state h2 { margin: 0 0 8px; font-size: var(--step-2); }
.state p { margin: 0 0 16px; color: var(--ink-2); }
.loading .shimmer {
  height: 14px; margin: 10px 0; border-radius: 2px;
  background: linear-gradient(90deg, var(--paper-2), var(--paper-3), var(--paper-2));
  background-size: 200% 100%; animation: shimmer 1.4s linear infinite;
}
@keyframes shimmer { to { background-position: -200% 0; } }


@media (max-width: 1000px) {
  .lead-grid, .coverage { grid-template-columns: minmax(0, 1fr); }
  .lead-grid > *, .coverage > *, .words > * { padding-left: 0 !important; padding-right: 0 !important; border-left: 0 !important; }
  .words { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .lists { grid-template-columns: minmax(0, 1fr); gap: 24px; }
}
@media (max-width: 720px) {
  .mast .wrap { grid-template-columns: 1fr auto; }
  .dateline { grid-column: 1 / -1; grid-row: 2; }
  .brand b { font-size: var(--step-2); }
  .brand span { display: none; }
  table#board { min-width: 0; }
  #board th:nth-child(5), #board td:nth-child(5), #board th:nth-child(7), #board td:nth-child(7), #board th:nth-child(8), #board td:nth-child(8) { display: none; }
  #board td, #board th button { padding-left: 4px; padding-right: 4px; }
  #board th:nth-child(n), #board td:nth-child(n) { border-left: 0; }
  #board th:nth-child(1), #board td:nth-child(1) { display: none; }
  #board td.name a { font-stretch: 80%; }
  #board th { white-space: normal; }
  #board .spark { width: 56px; }
  .mover { grid-template-columns: 50px minmax(0, 1fr) 58px; grid-template-areas: "code name px" "code bar bar" "code head head"; }
  .inst-head { grid-template-columns: minmax(0, 1fr); }
  .inst-code { font-size: var(--step-3); }
  .inst-head h1 { font-size: var(--step-2); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
