/* Fair-Weather Seats. One stylesheet for every page.
   Brand: navy ink from the wordmark, rain blue from the logo's drops for all data.
   Maroon belongs to the logo only. */

:root {
  color-scheme: light;
  --paper: #ffffff;
  --ink: #1c2431;
  --ink-2: #5a6472;
  --rule: #e3e6ea;
  --rule-strong: #c9cfd6;
  --raised: #ffffff;
  --hover: #f3f5f7;
  --link: #2f5a86;
  --focus: #3d6995;
  --none: #e3e6ea;
  --r1: #b5cfe9; --r2: #8bb1d6; --r3: #5f8ab4; --r4: #3d6995; --r5: #224870; --r6: #0f2a45;
  --lab1: #1c2431; --lab2: #1c2431; --lab3: #1c2431; --lab4: #ffffff; --lab5: #ffffff;
  --label-on-light: #1c2431;
  --label-on-dark: #ffffff;
  --bar: #3d6995;
  --tab-on-bg: #1c2431; --tab-on-fg: #ffffff;
  --tip-bg: #1c2431; --tip-fg: #ffffff; --tip-rule: transparent;
  --panel-shadow: 0 14px 36px rgba(20, 28, 40, 0.14), 0 2px 6px rgba(20, 28, 40, 0.08);

  --display: "Anton", "Impact", "Arial Narrow", sans-serif;
  --text: "Libre Franklin", "Franklin Gothic Medium", "Helvetica Neue", Arial, sans-serif;
  --fs-13: 0.8125rem; --fs-15: 0.9375rem; --fs-18: 1.125rem; --fs-24: 1.5rem; --fs-40: 2.5rem; --fs-112: 7rem;
  --radius: 6px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #0e1319;
    --ink: #e6ebf1;
    --ink-2: #9aa5b2;
    --rule: #232b35;
    --rule-strong: #38434f;
    --raised: #161d26;
    --hover: #18212b;
    --link: #8fb7de;
    --focus: #8fb7de;
    --none: #232b35;
    --r1: #1b3f66; --r2: #265484; --r3: #3a6ea3; --r4: #5e93c7; --r5: #97bfe6; --r6: #d4e7f9;
    --lab1: #e6ebf1; --lab2: #e6ebf1; --lab3: #e6ebf1; --lab4: #0e1319; --lab5: #0e1319;
    --label-on-light: #0e1319;
    --label-on-dark: #e6ebf1;
    --bar: #5e93c7;
    --tab-on-bg: #e6ebf1; --tab-on-fg: #0e1319;
    --tip-bg: #1d2631; --tip-fg: #e6ebf1; --tip-rule: #38434f;
    --panel-shadow: 0 14px 36px rgba(0, 0, 0, 0.5);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0e1319;
  --ink: #e6ebf1;
  --ink-2: #9aa5b2;
  --rule: #232b35;
  --rule-strong: #38434f;
  --raised: #161d26;
  --hover: #18212b;
  --link: #8fb7de;
  --focus: #8fb7de;
  --none: #232b35;
  --r1: #1b3f66; --r2: #265484; --r3: #3a6ea3; --r4: #5e93c7; --r5: #97bfe6; --r6: #d4e7f9;
  --lab1: #e6ebf1; --lab2: #e6ebf1; --lab3: #e6ebf1; --lab4: #0e1319; --lab5: #0e1319;
  --label-on-light: #0e1319;
  --label-on-dark: #e6ebf1;
  --bar: #5e93c7;
  --tab-on-bg: #e6ebf1; --tab-on-fg: #0e1319;
  --tip-bg: #1d2631; --tip-fg: #e6ebf1; --tip-rule: #38434f;
  --panel-shadow: 0 14px 36px rgba(0, 0, 0, 0.5);
}

/* Theme-specific images: light by default, swapped by the same rules as the tokens. */
.only-dark { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .only-dark { display: inline-block; }
  :root:not([data-theme="light"]) .only-light { display: none; }
}
:root[data-theme="dark"] .only-dark { display: inline-block; }
:root[data-theme="dark"] .only-light { display: none; }

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 var(--fs-15)/1.55 var(--text);
  font-variant-numeric: tabular-nums;
}
a { color: var(--link); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
h1, h2, h3 { margin: 0; }
p { margin: 0; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.measure { max-width: 36em; }
.muted { color: var(--ink-2); }
.small { font-size: var(--fs-13); }
[hidden] { display: none !important; }

/* ---------- masthead ---------- */
.masthead { border-bottom: 1px solid var(--rule); }
.masthead .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand img { width: 44px; height: 44px; object-fit: contain; }
.brand .wm { display: flex; flex-direction: column; line-height: 1; }
.brand .wm b { font: 400 1.625rem/1 var(--display); letter-spacing: 0.01em; }
.brand .wm span { font: 600 0.6875rem/1 var(--text); letter-spacing: 0.3em; color: var(--link); margin-top: 4px; }
.nav { display: flex; align-items: center; gap: 20px; }
.nav a { color: var(--ink); text-decoration: none; }
.nav a:hover { text-decoration: underline; }
.nav a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; }
.theme-btn {
  display: inline-grid; place-items: center; width: 36px; height: 36px; padding: 0;
  border: 1px solid var(--rule-strong); border-radius: var(--radius); background: transparent; color: var(--ink); cursor: pointer;
}
.theme-btn:hover { background: var(--hover); }
.theme-btn svg { width: 18px; height: 18px; }
@media (max-width: 560px) {
  .nav { gap: 14px; }
  .nav .hide-sm { display: none; }
  .brand .wm b { font-size: 1.375rem; }
}

/* ---------- footer ---------- */
.site-foot { border-top: 1px solid var(--rule); margin-top: 72px; }
.site-foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; padding-top: 24px; padding-bottom: 40px; }
.site-foot p { color: var(--ink-2); font-size: var(--fs-13); max-width: 36em; }
.site-foot nav { display: flex; gap: 20px; font-size: var(--fs-13); }

/* ---------- the poll (homepage, the one loud place) ---------- */
.poll-head { padding: 48px 0 28px; }
.poll-head h1 { font: 400 var(--fs-40)/1 var(--display); text-transform: uppercase; letter-spacing: 0.005em; }
.poll-head .dateline { margin-top: 10px; font-size: var(--fs-13); color: var(--ink-2); }
.poll-head .dek { margin-top: 14px; font-size: var(--fs-18); line-height: 1.5; max-width: 34em; }

.poll-table { border-top: 2px solid var(--ink); }
.poll { list-style: none; margin: 0; padding: 0; }
.poll-cols, .poll-row {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) 140px 150px 172px;
  column-gap: 20px;
  align-items: end;
}
.poll-cols { padding: 10px 0; border-bottom: 1px solid var(--rule); font-size: var(--fs-13); color: var(--ink-2); }
.poll-cols span:nth-child(n+3) { text-align: right; }
.poll-row {
  grid-template-areas: "rank team two every rating" "rank bar bar bar bar";
  row-gap: 12px;
  padding: 18px 0 20px;
  border-bottom: 1px solid var(--rule);
  color: inherit;
  text-decoration: none;
}
.poll-row .rank { grid-area: rank; align-self: center; font: 400 var(--fs-112)/0.8 var(--display); letter-spacing: -0.01em; }
.poll-row .team { grid-area: team; min-width: 0; }
.poll-row .team b { display: block; font: 400 var(--fs-40)/1 var(--display); text-transform: uppercase; text-underline-offset: 0.12em; }
.poll-row .team span { display: block; margin-top: 6px; color: var(--ink-2); }
.poll-row .fig { text-align: right; }
.poll-row .fig .k { display: none; }
.poll-row .fig .v { font-size: var(--fs-18); font-weight: 500; }
.poll-row .two { grid-area: two; }
.poll-row .every { grid-area: every; }
.poll-row .rating { grid-area: rating; }
.poll-row .rating .v { font: 400 var(--fs-40)/1 var(--display); }
.poll-row .bar { grid-area: bar; height: 6px; background: var(--none); }
.poll-row .bar i { display: block; height: 100%; width: 0; background: var(--bar); border-radius: 0 3px 3px 0; transition: width 0.85s cubic-bezier(0.2, 0.75, 0.2, 1); }
.poll-row:hover .team b, .poll-row:focus-visible .team b { text-decoration: underline; text-decoration-thickness: 3px; }
.poll-row:focus-visible { outline-offset: 4px; }
@media (max-width: 860px) {
  .poll-cols { display: none; }
  .poll-row {
    grid-template-columns: 68px minmax(0, 1fr) auto;
    grid-template-areas: "rank team rating" "rank figs figs" "rank bar bar";
    row-gap: 8px; column-gap: 14px; align-items: start;
  }
  .poll-row .rank { font-size: 4.5rem; align-self: start; }
  .poll-row .team b { font-size: var(--fs-24); }
  .poll-row .team span { margin-top: 2px; font-size: var(--fs-13); }
  .poll-row .rating .v { font-size: var(--fs-24); }
  .poll-row .figs { grid-area: figs; display: flex; flex-wrap: wrap; gap: 4px 18px; }
  .poll-row .two, .poll-row .every { grid-area: auto; text-align: left; }
  .poll-row .fig .k { display: inline; color: var(--ink-2); font-size: var(--fs-13); margin-right: 6px; }
  .poll-row .fig .v { font-size: var(--fs-15); }
  .poll-row .rating .k { display: none; }
}
.poll-row .figs { display: contents; }
@media (max-width: 860px) { .poll-row .figs { display: flex; } }

.poll-empty { padding: 28px 0; border-bottom: 1px solid var(--rule); }
.poll-empty ul { margin: 12px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }

/* popover explainer by the dateline */
.howbtn {
  margin-left: 10px; padding: 3px 9px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: transparent; color: var(--ink); font: 500 var(--fs-13)/1.4 var(--text); cursor: pointer;
}
.howbtn:hover { background: var(--hover); }
.howto {
  width: min(520px, calc(100vw - 32px)); padding: 22px 24px; border: 1px solid var(--rule-strong); border-radius: 10px;
  background: var(--raised); color: var(--ink); box-shadow: var(--panel-shadow);
}
.howto::backdrop { background: rgba(12, 18, 26, 0.35); }
.howto h2 { font: 600 var(--fs-18)/1.3 var(--text); }
.howto p { margin-top: 10px; max-width: none; }
.howclose {
  margin-top: 16px; padding: 7px 14px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: transparent; color: var(--ink); font: 500 var(--fs-15)/1 var(--text); cursor: pointer;
}
.howclose:hover { background: var(--hover); }
.closing { margin-top: 40px; color: var(--ink-2); font-size: var(--fs-15); }

.explainer { margin-top: 48px; }
.explainer h2 { font: 600 var(--fs-24)/1.25 var(--text); column-span: all; margin-bottom: 12px; }
.explainer p { max-width: 36em; margin-top: 12px; }
/* Two columns on wide screens: fills the page without long, hard-to-read lines. */
@media (min-width: 900px) {
  .explainer { column-count: 2; column-gap: 48px; }
  .explainer p { max-width: none; }
}

/* other ways to read the weather: a dot plot, a range chart and ranked tables */
.boards-head { font: 600 var(--fs-24)/1.25 var(--text); margin-top: 52px; }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 32px 48px; margin-top: 20px; }
.charts.two { margin-top: 36px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); align-items: start; }
.chart.narrow { max-width: 560px; }
.chart h3 { font: 600 var(--fs-18)/1.3 var(--text); }
.chart .sub { margin-top: 4px; max-width: 34em; }
.keys { display: flex; gap: 16px; margin-top: 10px; font-size: var(--fs-13); color: var(--ink-2); }
.key { display: inline-flex; align-items: center; gap: 6px; }

.plot { margin-top: 14px; }
.prow {
  display: grid; grid-template-columns: minmax(96px, 150px) minmax(0, 1fr) auto;
  align-items: center; gap: 14px; padding: 9px 0; border-top: 1px solid var(--rule);
  color: inherit; text-decoration: none;
}
.prow:first-child { border-top: 1px solid var(--rule-strong); }
.prow:hover, .prow:focus-visible { background: var(--hover); }
.prow .lbl { font-weight: 600; line-height: 1.25; }
.sub2 { display: block; font-weight: 400; font-size: var(--fs-13); color: var(--ink-2); }
.prow .track { position: relative; height: 16px; }
.prow .track::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--rule); }
.prow .seg { position: absolute; top: 50%; height: 3px; margin-top: -1.5px; background: var(--r2); transition: width 0.85s cubic-bezier(0.2, 0.75, 0.2, 1); }
.mk { position: absolute; top: 50%; width: 11px; height: 11px; margin: -5.5px 0 0 -5.5px; border-radius: 50%; }
.mk.solid { background: var(--r5); }
.mk.hollow { background: var(--paper); border: 2px solid var(--r3); }
.keys .mk { position: static; margin: 0; }
.prow .val { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: var(--fs-13); text-align: right; }
.prow .val .sub2 { font-weight: 400; }
.axis { position: relative; height: 18px; margin-top: 4px; font-size: var(--fs-13); color: var(--ink-2); }
.axis span { position: absolute; transform: translateX(-50%); }
@media (max-width: 560px) {
  .prow { grid-template-columns: minmax(88px, 1fr) auto; grid-template-areas: "lbl val" "track track"; row-gap: 6px; }
  .prow .lbl { grid-area: lbl; } .prow .val { grid-area: val; } .prow .track { grid-area: track; }
}

table.rank { width: 100%; border-collapse: collapse; margin-top: 12px; }
table.rank td { padding: 9px 6px; border-top: 1px solid var(--rule); vertical-align: baseline; font-size: var(--fs-15); }
table.rank tr:first-child td { border-top: 1px solid var(--rule-strong); }
table.rank td.n { width: 1%; padding-right: 12px; color: var(--ink-2); font-size: var(--fs-13); white-space: nowrap; }
table.rank td.grow { width: 100%; }
table.rank td.wf, table.rank td.gl { width: 1%; padding-right: 12px; white-space: nowrap; }
.thermo { display: inline-flex; align-items: flex-end; width: 11px; height: 26px; padding: 2px; border: 1px solid var(--rule-strong); border-radius: 6px; }
.thermo i { display: block; width: 100%; border-radius: 4px; }
.sky { vertical-align: -4px; color: var(--ink-2); }
.runseats { display: inline-flex; gap: 2px; align-items: center; max-width: 76px; flex-wrap: wrap; }
.runseats i { width: 7px; height: 7px; border-radius: 50%; background: var(--r4); }
.stubs { position: relative; display: inline-block; width: 74px; height: 16px; }
.stubs i { position: absolute; width: 10px; height: 13px; border-radius: 2px; background: var(--r3); border: 1px solid var(--paper); }
.waffle { display: grid; grid-template-columns: repeat(10, 4px); grid-auto-rows: 4px; gap: 1px; width: 49px; }
.waffle i { background: var(--none); border-radius: 1px; }
.waffle i.on { background: var(--r4); }
.listnote { margin-top: 14px; }
table.rank td.big { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.rank td.up { color: var(--r5); }
table.rank td.down { color: var(--ink-2); }
table.rank tr.link { cursor: pointer; }
table.rank tr.link:hover td { background: var(--hover); }

/* sponsor a stadium */
.sponsor { margin-top: 56px; padding-top: 28px; border-top: 2px solid var(--ink); }
.sponsor h2 { font: 600 var(--fs-24)/1.25 var(--text); }
.sponsor-grid { margin-top: 16px; }
.sponsor h3 { margin-top: 32px; }
.sponsor p { margin-top: 12px; max-width: 36em; }
.sponsor .fineprint { font-size: var(--fs-13); color: var(--ink-2); }
.sponsor .cta { margin-top: 18px; }
.btn {
  display: inline-block; padding: 11px 18px; border-radius: var(--radius);
  background: var(--tab-on-bg); color: var(--tab-on-fg); font-weight: 600; text-decoration: none;
}
.btn:hover { text-decoration: underline; text-underline-offset: 0.2em; }
.sponsor h3 { font: 600 var(--fs-18)/1.3 var(--text); margin-top: 12px; }
.wantlist { list-style: none; margin: 10px 0 0; padding: 0; column-count: 3; column-gap: 40px; }
@media (max-width: 900px) { .wantlist { column-count: 2; } }
@media (max-width: 560px) { .wantlist { column-count: 1; } }
.wantlist li { padding: 7px 0; border-top: 1px solid var(--rule); break-inside: avoid; }
.wantlist li b { display: block; font-weight: 600; }
.wantlist span { color: var(--ink-2); font-size: var(--fs-13); }
.credit { margin-top: 10px; font-size: var(--fs-13); color: var(--ink-2); }

/* support line on a stadium page */
.support { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--rule); }
.support p { max-width: 36em; }
.support .cta { margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.support .fineprint { font-size: var(--fs-13); color: var(--ink-2); }

/* ---------- stadium page ---------- */
.stadium-head { padding: 28px 0 8px; }
.crumb { font-size: var(--fs-13); }
.stadium-head .title-row { margin-top: 14px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; }
.stadium-head .where { color: var(--ink-2); }
.lede { margin-top: 22px; font: 500 var(--fs-24)/1.3 var(--text); max-width: 22em; }
.lede .big { font: 400 var(--fs-40)/1 var(--display); margin-right: 0.2em; }
.lede-sub { margin-top: 8px; color: var(--ink-2); max-width: 36em; }

.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin: 28px 0 0; padding: 14px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.tabs { display: inline-flex; border: 1px solid var(--rule-strong); border-radius: var(--radius); overflow: hidden; }
.tabs button { font: 500 var(--fs-15)/1 var(--text); padding: 9px 14px; border: 0; background: transparent; color: var(--ink); cursor: pointer; }
.tabs button + button { border-left: 1px solid var(--rule-strong); }
.tabs button:hover { background: var(--hover); }
.tabs button[aria-pressed="true"] { background: var(--tab-on-bg); color: var(--tab-on-fg); }
.controls .label { color: var(--ink-2); }

.explore { display: grid; grid-template-columns: minmax(0, 1fr) 400px; }
.explore .map-col { padding: 20px 24px 0 0; min-width: 0; }
.explore .panel { padding: 20px 0 0 24px; border-left: 1px solid var(--rule); min-width: 0; }
@media (max-width: 980px) {
  .explore { grid-template-columns: 1fr; }
  .explore .map-col { padding-right: 0; }
  .explore .panel { padding-left: 0; border-left: 0; border-top: 1px solid var(--rule); margin-top: 20px; }
}

/* stadium map */
.map svg { display: block; width: 100%; height: auto; }
.map .sg-outline { fill: var(--paper); stroke: var(--rule-strong); stroke-width: 3; }
.map .sg-field { fill: var(--none); }
.map .sg-obj { fill: var(--none); }
.map .sg-sec path { fill: var(--none); stroke: var(--paper); stroke-width: 2; }
.map .sg-row { fill: none; }
.map .sg-sec > path:first-child { cursor: pointer; transition: fill 0.3s ease; }
.map .sg-sec:hover > path:first-child { stroke: var(--ink); stroke-width: 2; }
.map .sg-sec.selected > path:first-child { stroke: var(--ink); stroke-width: 3.5; }
.map .sg-seclabel, .map .sg-objlabel { fill: var(--ink-2); font-family: var(--text); font-weight: 600; pointer-events: none; transition: fill 0.3s ease; }
.map .sg-seclabel.on-light { fill: var(--label-on-light); }
.map .sg-seclabel.on-dark { fill: var(--label-on-dark); }
@media (prefers-reduced-motion: reduce) {
  .map .sg-sec > path:first-child, .map .sg-seclabel { transition: none; }
  .poll-row .bar i, .board .rbar i { transition: none; }
}

.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-top: 14px; font-size: var(--fs-13); color: var(--ink-2); }
.legend .sw { display: inline-block; width: 14px; height: 14px; margin-right: 6px; vertical-align: -2px; }
.legend .dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 6px; vertical-align: -1px; }
.caption { margin-top: 8px; font-size: var(--fs-13); color: var(--ink-2); max-width: 36em; }

/* side panel */
.panel h2 { font: 600 var(--fs-18)/1.3 var(--text); }
.panel .intro { margin-top: 4px; color: var(--ink-2); }
.figures { display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 12px 0 16px; }
.figures div { display: flex; flex-direction: column; }
.figures b { font-size: var(--fs-24); font-weight: 600; line-height: 1.1; }
.figures span { font-size: var(--fs-13); color: var(--ink-2); }
.seatwrap { position: relative; }
.seatview svg { display: block; width: 100%; height: auto; max-height: 340px; touch-action: pan-y; cursor: crosshair; }
.seatview circle.sel { stroke: var(--ink); stroke-width: 0.45; paint-order: stroke; }
.zoom { position: absolute; right: 6px; bottom: 6px; display: flex; gap: 4px; }
.zoom button {
  min-width: 34px; height: 34px; padding: 0 8px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: var(--paper); color: var(--ink); font: 600 var(--fs-15)/1 var(--text); cursor: pointer;
}
.zoom button[data-z="reset"] { font-size: var(--fs-13); font-weight: 500; }
.zoom button:hover { background: var(--hover); }
.seatinfo { margin-top: 10px; font-size: var(--fs-13); color: var(--ink-2); min-height: 2.4em; }
.seatinfo b { color: var(--ink); }
.seatview circle { fill: var(--none); }
.seatview circle.listed { fill: var(--r4); }
.seatview circle.g1 { fill: var(--r2); }
.seatview circle.g2 { fill: var(--r3); }
.seatview circle.g3 { fill: var(--r4); }
.seatview circle.g4 { fill: var(--r5); }
.seatview circle.g5 { fill: var(--r6); }
.table-scroll { max-height: 460px; overflow: auto; margin-top: 16px; border-top: 1px solid var(--rule); }
.table-scroll.tall { max-height: 680px; }
table { width: 100%; border-collapse: collapse; font-size: var(--fs-13); }
th { position: sticky; top: 0; background: var(--paper); text-align: left; font-weight: 600; color: var(--ink-2); padding: 8px 6px; border-bottom: 1px solid var(--rule-strong); }
td { padding: 7px 6px; border-bottom: 1px solid var(--rule); vertical-align: middle; }
td.num, th.num { text-align: right; }
th.gcol, td.gcol { width: 38px; padding-left: 2px; padding-right: 2px; text-align: center; }
th.gcol abbr { text-decoration: none; cursor: help; }
td .sub { display: block; color: var(--ink-2); }
.panel td:first-child, .panel th:first-child { min-width: 104px; }
tr.link { cursor: pointer; }
tr.link:hover td { background: var(--hover); }
.sq { display: inline-block; width: 12px; height: 12px; background: var(--none); vertical-align: middle; }
.sq.on { background: var(--bar); }
.empty { color: var(--ink-2); }

/* tooltip */
.tip {
  position: fixed; z-index: 50; display: none; pointer-events: none; max-width: 260px;
  padding: 8px 10px; border-radius: var(--radius); border: 1px solid var(--tip-rule);
  background: var(--tip-bg); color: var(--tip-fg); font-size: var(--fs-13); line-height: 1.45;
}
.tip b { font-weight: 600; }

/* ---------- dropdown ---------- */
.dd { position: relative; display: inline-block; }
.dd-btn {
  display: inline-flex; align-items: center; gap: 10px; max-width: 100%;
  padding: 8px 12px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: transparent; color: var(--ink); font: 500 var(--fs-15)/1.2 var(--text); text-align: left; cursor: pointer;
}
.dd-btn:hover { background: var(--hover); }
.dd-btn .val { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dd-btn .chev { flex: none; color: var(--ink-2); transition: transform 0.15s; }
.dd.open .dd-btn .chev { transform: rotate(180deg); }
.dd.title .dd-btn { padding: 0 6px 0 0; border: 0; font: 400 var(--fs-40)/1.05 var(--display); text-transform: none; }
.dd.title .dd-btn:hover { background: transparent; text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 0.12em; }
.dd.title .dd-btn .val { white-space: normal; }
.dd.title .dd-btn .chev { width: 22px; height: 22px; color: var(--ink); }
.dd-panel {
  position: absolute; top: calc(100% + 6px); left: 0; z-index: 40;
  min-width: 100%; width: max-content; max-width: min(360px, calc(100vw - 32px)); max-height: min(400px, 60vh); overflow: auto;
  padding: 6px; background: var(--raised); border: 1px solid var(--rule-strong); border-radius: var(--radius); box-shadow: var(--panel-shadow); outline: none;
}
.dd-group { padding: 10px 10px 4px; font-size: var(--fs-13); font-weight: 600; color: var(--ink-2); }
.dd-opt { display: flex; align-items: center; gap: 16px; padding: 8px 10px; border-radius: 4px; cursor: pointer; font: 400 var(--fs-15)/1.3 var(--text); text-transform: none; }
.dd-opt.active { background: var(--hover); }
.dd-opt .t { flex: 1; min-width: 0; }
.dd-opt .l { display: block; }
.dd-opt .s { display: block; font-size: var(--fs-13); color: var(--ink-2); }
.dd-opt .check { flex: none; color: var(--ink); visibility: hidden; }
.dd-opt[aria-selected="true"] .l { font-weight: 600; }
.dd-opt[aria-selected="true"] .check { visibility: visible; }
@media (max-width: 560px) { .dd.title .dd-btn { font-size: 2rem; } }

/* ---------- prose pages ---------- */
.prose { padding: 48px 0 0; }
.prose h1 { font: 700 var(--fs-40)/1.1 var(--text); }
.prose h2 { font: 600 var(--fs-24)/1.3 var(--text); margin-top: 36px; }
.prose p, .prose li { font-size: var(--fs-18); line-height: 1.6; max-width: 36em; margin-top: 14px; }
.prose .updated { font-size: var(--fs-15); color: var(--ink-2); margin-top: 8px; }
