:root {
  --bg: #fbfaf7;
  --panel: #ffffff;
  --ink: #1d1d1b;
  --muted: #66645e;
  --faint: #d9d6ce;
  --line: #e7e4dc;
  --accent: #b4441f;
  --accent-ink: #ffffff;
  --ref: #4a4a46;
  --good: #2f6f4f;
  --bad: #9b2f1f;
  --band: #ece9e1;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161614;
    --panel: #1f1f1c;
    --ink: #ecebe6;
    --muted: #a3a097;
    --faint: #3a3935;
    --line: #2e2d2a;
    --accent: #f0875e;
    --accent-ink: #161614;
    --ref: #c9c7bf;
    --good: #7cc29a;
    --bad: #f08a78;
    --band: #262522;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.5 var(--sans);
}
a { color: inherit; text-decoration-color: var(--faint); text-underline-offset: 2px; }
a:hover { text-decoration-color: var(--accent); }

header.site, main, footer.site { max-width: 1100px; margin: 0 auto; padding: 0 16px; }
header.site {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: 8px 24px; padding-top: 20px; padding-bottom: 12px; border-bottom: 1px solid var(--line);
}
.brand { font: 600 20px/1.2 var(--serif); text-decoration: none; }
.brand span { color: var(--muted); font-weight: 400; }
header nav { display: flex; gap: 18px; font-size: 15px; }
header nav a { text-decoration: none; color: var(--muted); padding-bottom: 2px; border-bottom: 2px solid transparent; }
header nav a.on { color: var(--ink); border-bottom-color: var(--accent); }

main { padding-top: 24px; padding-bottom: 48px; min-height: 60vh; }
footer.site { color: var(--muted); font-size: 13px; padding-bottom: 32px; border-top: 1px solid var(--line); }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; }
h1 { font-size: 30px; margin: 0 0 12px; }
h2 { font-size: 22px; margin: 36px 0 8px; }
h3 { font-size: 17px; margin: 20px 0 6px; }
.lede { font-size: 18px; max-width: 46em; }
.note, .muted { color: var(--muted); }
.note { font-size: 14px; max-width: 52em; }
p { max-width: 52em; }

.button {
  display: inline-block; background: var(--accent); color: var(--accent-ink);
  padding: 8px 14px; border-radius: 6px; text-decoration: none; font-weight: 600; font-size: 15px;
  border: 0; cursor: pointer;
}
button.ghost, .ghost {
  background: transparent; color: var(--ink); border: 1px solid var(--faint);
  border-radius: 6px; padding: 5px 10px; font: inherit; font-size: 14px; cursor: pointer;
}
button.ghost:hover { border-color: var(--accent); }

.toggle { display: inline-flex; border: 1px solid var(--faint); border-radius: 6px; overflow: hidden; }
.toggle button { background: transparent; border: 0; padding: 5px 12px; font: inherit; font-size: 14px; color: var(--muted); cursor: pointer; }
.toggle button.on { background: var(--ink); color: var(--bg); }
.toggle button:disabled { opacity: .4; cursor: not-allowed; }

.scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.data { border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; width: 100%; }
table.data th, table.data td { padding: 6px 8px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
table.data th:first-child, table.data td:first-child { text-align: left; white-space: normal; min-width: 12em; }
table.data thead th { font-weight: 600; color: var(--muted); font-size: 13px; vertical-align: bottom; position: sticky; top: 0; background: var(--bg); }
table.data thead th.sortable { cursor: pointer; }
table.data thead th.sorted { color: var(--ink); }
table.data tr.focus td { font-weight: 650; }
table.data tr.focus td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
table.data tr.ref td { color: var(--muted); font-style: italic; }
table.data tr.group td { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; padding-top: 14px; }
table.data td.cell { position: relative; }
table.data .sub { display: block; color: var(--muted); font-size: 12px; font-weight: 400; }
.marker { color: var(--muted); }

.explore { display: grid; grid-template-columns: 280px 1fr; gap: 24px; }
@media (max-width: 820px) { .explore { grid-template-columns: 1fr; } }
.controls { display: flex; flex-direction: column; gap: 14px; }
.controls label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; font-weight: 600; }
.controls select, .controls input[type=text] {
  width: 100%; font: inherit; font-size: 15px; padding: 6px 10px; border-radius: 6px;
  border: 1px solid var(--faint); background-color: var(--panel); color: var(--ink);
}
/* Own chevron, inset from the right edge as far as the text is from the left. */
.controls select {
  -webkit-appearance: none; appearance: none;
  padding-right: 32px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 16px) calc(50% + 1px), calc(100% - 11px) calc(50% + 1px);
  background-size: 5px 5px;
  background-repeat: no-repeat;
}
.controls select:disabled { opacity: .5; }
.controls .row { display: flex; gap: 8px; align-items: center; }
.controls .row select { flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 8px; border-radius: 999px;
  border: 1px solid var(--faint); font-size: 13px; background: var(--panel); max-width: 100%;
}
.chip i { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chip button { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 15px; line-height: 1; padding: 0 4px; }
.quick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.controls label.check {
  display: flex; gap: 8px; align-items: flex-start; margin: 0 0 6px;
  font-size: 14px; font-weight: 400; color: var(--ink);
}
.controls label.check input { margin: 3px 0 0; flex: none; }
.controls label.check input:disabled + * , .controls label.check:has(input:disabled) { color: var(--muted); }

.chart { min-height: 380px; }
.chart svg { overflow: visible; }
.chart-title { font: 600 18px/1.3 var(--serif); margin: 0 0 2px; }
.chart-sub { color: var(--muted); font-size: 14px; margin: 0 0 12px; }
.empty { padding: 60px 0; color: var(--muted); text-align: center; }
.bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; margin: 24px 0 8px; }
.bar h3 { margin: 0; }

details.caveats { margin-top: 20px; font-size: 14px; color: var(--muted); }
details.caveats summary { cursor: pointer; color: var(--ink); font-weight: 600; }
details.caveats ul { padding-left: 20px; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px 20px; padding: 0; list-style: none; font-size: 14px; }
.cards li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.cards .muted { font-size: 13px; }

.loading { color: var(--muted); }
.explore > * { min-width: 0; }

.faq { max-width: 46em; }
.faq h2 { font-size: 19px; margin-top: 30px; }
.faq ul { padding-left: 20px; }
.faq li { margin: 4px 0; }
