:root {
  --bg: #FFFFFF; --ink: #111111; --muted: #6B6B6B; --rule: #DDDDDD; --hover: #F2F2F2;
  --bar: #111111; --bar-hover: #6B6B6B; --header: rgba(255, 255, 255, 0.85);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111111; --ink: #F2F2F2; --muted: #999999; --rule: #333333; --hover: #1E1E1E;
    --bar: #E6E6E6; --bar-hover: #999999; --header: rgba(17, 17, 17, 0.85);
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.5 "Helvetica Neue", Helvetica, Arial, sans-serif;
  min-height: 100vh; display: flex; flex-direction: column;
}
.wrap { width: 100%; max-width: 760px; margin: 0 auto; padding: 0 24px; }
main { flex: 1; display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }

/* Header stays on top while scrolling; links jump to the sections. */
.top {
  position: sticky; top: 0; z-index: 10;
  background: var(--header); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ink);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 52px; }
.brand { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
nav { display: flex; gap: 4px; margin-right: -10px; }
nav a {
  font-size: 14px; color: var(--muted); padding: 6px 10px; border-radius: 999px;
  transition: color 0.15s, background-color 0.15s;
}
nav a:hover { color: var(--ink); background: var(--hover); }
nav a.on { color: var(--ink); background: var(--hover); }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.hero { display: flex; flex-direction: column; justify-content: center; gap: 12px; padding: 64px 0; min-height: 56vh; }
.question { margin: 0; font-size: 17px; color: var(--muted); }
.big { margin: 0; font-size: clamp(72px, 24vw, 160px); font-weight: 700; line-height: 0.9; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.big.long { font-size: clamp(56px, 17vw, 120px); }
.action { margin: 0; font-size: 22px; font-weight: 700; line-height: 1.2; }
.detail { margin: 0; font-size: 17px; max-width: 46ch; }
.detail.warn { font-weight: 700; }

/* Sections are separated by space only. */
section { padding: 0 0 64px; }
h2 { margin: 0 0 12px; font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.note { margin: 12px 0 0; color: var(--muted); max-width: 60ch; }
.note:empty { display: none; }

/* Lists: rows light up under the pointer. The table is pulled out by the
   row padding so the text still lines up with the headings. */
table.list { width: calc(100% + 20px); margin: 0 -10px; border-collapse: separate; border-spacing: 0; }
table.list th { text-align: left; font-weight: 400; color: var(--muted); padding: 4px 10px; }
table.list td { padding: 4px 10px; vertical-align: baseline; transition: background-color 0.1s; }
table.list tbody tr:hover td { background: var(--hover); }
table.list tbody tr td:first-child { border-radius: 6px 0 0 6px; }
table.list tbody tr td:last-child { border-radius: 0 6px 6px 0; }
.n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; padding-left: 16px !important; }
.sub { color: var(--muted); }
code, .path { font: 14px/1.5 ui-monospace, "SF Mono", Menlo, Consolas, monospace; overflow-wrap: anywhere; }

.family { margin-bottom: 20px; }
.family:last-child { margin-bottom: 0; }
.family-head { display: flex; justify-content: space-between; color: var(--muted); padding: 4px 0; }
.family-head .n { padding-left: 16px; }

/* Daily chart: one series, one colour, bars on a baseline. */
.chart { position: relative; padding-top: 32px; }
.bars { display: flex; align-items: flex-end; gap: 2px; height: 160px; border-bottom: 1px solid var(--ink); }
.bars div { flex: 1 1 0; min-width: 0; height: 100%; display: flex; align-items: flex-end; cursor: default; }
.bars span { display: block; width: 100%; background: var(--bar); min-height: 1px; border-radius: 2px 2px 0 0; transition: background-color 0.1s; }
.bars div:hover span { background: var(--bar-hover); }
.bars div.today span { opacity: 0.4; }
.chart-axis { display: flex; justify-content: space-between; font-size: 14px; color: var(--muted); padding-top: 4px; }
.tip { position: absolute; top: 0; transform: translateX(-50%); pointer-events: none; white-space: nowrap; font-size: 14px; }

details { margin-top: 16px; }
details summary {
  display: inline-block; list-style: none; cursor: pointer; font-size: 14px; color: var(--muted);
  border: 1px solid var(--rule); border-radius: 999px; padding: 5px 14px;
  transition: color 0.15s, border-color 0.15s;
}
details summary::-webkit-details-marker { display: none; }
details summary:hover, details[open] summary { color: var(--ink); border-color: var(--ink); }
details table { margin-top: 12px !important; }

.hall { list-style: none; margin: 0; padding: 0; }
.hall li + li { margin-top: 14px; }
.hall .path { display: block; }
.hall .sub { display: block; }

footer { margin-top: auto; padding: 24px 0 32px; border-top: 1px solid var(--rule); font-size: 14px; color: var(--muted); }
footer p { margin: 0; max-width: 70ch; }
footer p + p { margin-top: 8px; }
footer .stale { color: var(--ink); font-weight: 700; }
.live { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ink); margin-right: 8px; vertical-align: 1px; animation: pulse 2.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.25; } }
@media (prefers-reduced-motion: reduce) { .live { animation: none; } }
[hidden] { display: none !important; }

@media (max-width: 520px) {
  .wrap { padding: 0 18px; }
  nav a { padding: 6px 8px; font-size: 13px; }
  .bars { height: 120px; gap: 1px; }
}
