/*
  Goalbound Insights (2026-09-24) — shared styles for the article section.
  The rest of the site is one self-contained file per page; Insights breaks that rule
  on purpose, because it will hold many articles that must look identical. Shell
  tokens, nav and footer are copied from about.html — change them together.
*/
:root {
  --ground: #0a0b0c; --panel: #101113; --lift: #15171a; --ink: #f4f4f2; --muted: #8b8f94; --dim: #55595e; --line: #212327;
  --display: "Barlow Condensed", "Arial Narrow", Impact, sans-serif;
  --body: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
  /* Chart marks. Pure neutrals, not the blue-tinted UI greys, so the tier ramp is one
     hue; validated with the dataviz palette checker against --ground (all pass,
     lightest-to-surface contrast 3.18:1). */
  --m1: #f4f4f4; --m2: #9d9d9d; --m3: #616161; --m-rest: #6b7075;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 15px/1.5 var(--body); -webkit-font-smoothing: antialiased; min-height: 100vh; display: flex; flex-direction: column; }
a { color: inherit; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 32px; width: 100%; }
main .wrap { max-width: 760px; }
main { flex: 1; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.0; letter-spacing: -0.005em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(36px, 4.4vw, 58px); }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
@media (max-width: 720px) { .wrap { padding: 0 16px; } }

header { border-bottom: 1px solid var(--line); }
nav { display: flex; align-items: center; gap: 28px; padding: 16px 0; }
.logo { font: 700 20px/1 var(--display); letter-spacing: .05em; text-decoration: none; display: flex; align-items: center; gap: 9px; margin-right: auto; }
.logo i { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); display: inline-block; }
.logo sup { font-size: .46em; vertical-align: super; letter-spacing: 0; }
nav .links { display: flex; gap: 22px; }
nav a.n { font: 500 13px var(--body); text-decoration: none; color: var(--muted); }
nav a.n:hover, nav a.n[aria-current="page"] { color: var(--ink); }
nav a.cta { font: 600 13px var(--body); text-decoration: none; color: var(--ground); background: var(--ink); padding: 8px 14px; border-radius: 4px; white-space: nowrap; }
nav a.cta:hover { background: #fff; }
@media (max-width: 720px) {
  nav { flex-wrap: wrap; gap: 0 16px; }
  nav .links {
    order: 3; width: 100%; margin-top: 12px; padding-top: 12px;
    border-top: 1px solid var(--line); gap: 18px;
    overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  nav .links::-webkit-scrollbar { display: none; }
  nav a.n { white-space: nowrap; }
}

.eyebrow { font: 500 10.5px/1 var(--mono); letter-spacing: .13em; text-transform: uppercase; color: var(--muted); }
.eyebrow a { text-decoration: none; }
.eyebrow a:hover { color: var(--ink); }
.hero { padding: 64px 0 8px; }
.hero h1 { margin-top: 16px; }
.byline { margin-top: 18px; font: 400 12px/1.5 var(--mono); color: var(--dim); letter-spacing: .03em; }
@media (max-width: 720px) { .hero { padding: 40px 0 6px; } }

/* Article body: one reading column. */
.prose .lede { font-size: 19px; line-height: 1.5; color: var(--ink); margin: 26px 0 0; }
.prose p { font-size: 16px; line-height: 1.7; color: var(--muted); margin-top: 20px; }
.prose p b, .prose li b { color: var(--ink); font-weight: 500; }
.prose h2 { font-size: 30px; margin: 46px 0 0; }
.prose ul { margin: 16px 0 0; padding-left: 20px; }
.prose li { font-size: 16px; line-height: 1.65; color: var(--muted); margin-top: 8px; }
.prose a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--dim); }
.prose a:hover { border-bottom-color: var(--ink); }

/* Figures: a live query over the site's own Parquet, drawn as an HTML bar table so
   the chart is also its own table view. */
figure { margin: 34px 0 0; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 20px 20px 16px; }
figure h3 { font-size: 20px; letter-spacing: .01em; }
figure .sub { margin-top: 6px; font-size: 13px; line-height: 1.5; color: var(--muted); }
figure .ctl { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-top: 14px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.seg button { font: 500 12px var(--body); color: var(--muted); background: transparent; border: 0; padding: 6px 12px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--ground); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font: 400 11.5px/1 var(--mono); color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
figcaption { margin-top: 12px; font: 400 11.5px/1.55 var(--mono); color: var(--dim); }
figcaption a { text-decoration: none; border-bottom: 1px solid var(--line); }
figcaption a:hover { color: var(--ink); }

table.bars { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 13px; }
table.bars th { font: 500 10px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); text-align: left; padding: 0 0 8px; }
table.bars th.r, table.bars td.r { text-align: right; }
table.bars td { padding: 0; height: 24px; vertical-align: middle; color: var(--muted); }
table.bars td.name { width: 34%; padding-right: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 0; }
table.bars td.v { width: 64px; padding-left: 10px; font: 400 12px var(--mono); font-variant-numeric: tabular-nums; }
table.bars tr.hl td { color: var(--ink); }
table.bars tr.base td { color: var(--ink); border-bottom: 1px solid var(--line); }
table.bars tr.base td, table.bars tr.base + tr td { padding-top: 0; }
table.bars tr:hover td { background: var(--lift); }
table.bars .tag { font: 500 9.5px/1 var(--mono); letter-spacing: .08em; color: var(--ground); background: var(--ink); border-radius: 2px; padding: 2px 4px; margin-left: 6px; vertical-align: 1px; }
.track { position: relative; height: 12px; }
.bar { position: absolute; left: 0; top: 0; height: 12px; border-radius: 0 4px 4px 0; background: var(--m-rest); }
tr.hl .bar { background: var(--m1); }
.stack { display: flex; gap: 2px; height: 12px; }
.stack b { display: block; height: 12px; }
.stack b:last-child { border-radius: 0 4px 4px 0; }
.stack .s1 { background: var(--m1); } .stack .s2 { background: var(--m2); } .stack .s3 { background: var(--m3); }
/* On a phone the names wrap rather than truncate: the CAN tag is the non-colour
   marker for Canadian rows, and an ellipsis was cutting it off. */
@media (max-width: 560px) {
  table.bars td.name { width: 40%; white-space: normal; max-width: none; line-height: 1.25; padding: 3px 10px 3px 0; }
  table.bars td.v { width: 52px; }
  figure { padding: 16px 14px 14px; }
}

.fig-status { margin-top: 14px; font: 400 12px/1.5 var(--mono); color: var(--dim); }
.tip { position: fixed; z-index: 10; pointer-events: none; background: var(--lift); border: 1px solid var(--line); border-radius: 4px; padding: 8px 10px; font: 400 12px/1.45 var(--body); color: var(--muted); max-width: 260px; box-shadow: 0 6px 20px rgba(0,0,0,.5); }
.tip b { color: var(--ink); font-weight: 500; }

/* The next step: every article ends in the tool, with the question pre-filled. */
.next { margin: 38px 0 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 20px 0; display: grid; grid-template-columns: 44px 1fr; gap: 18px; }
.next .num { font: 500 10.5px/1.7 var(--mono); letter-spacing: .13em; color: var(--dim); }
.next p { font-size: 15px; line-height: 1.6; color: var(--muted); }
.next a { font: 500 14px/1.3 var(--body); text-decoration: none; color: var(--ink); display: inline-flex; gap: 7px; align-items: baseline; margin-top: 10px; }
.next a s { text-decoration: none; color: var(--dim); transition: transform .15s, color .15s; }
.next a:hover s { color: var(--ink); transform: translateX(3px); }
@media (prefers-reduced-motion: reduce) { .next a s { transition: none; } }
@media (max-width: 560px) { .next { grid-template-columns: 1fr; gap: 8px; } }

/* One sponsor slot per page, below the content, always labelled. Until a sponsor is
   sold it advertises itself. Never inside a figure, never above the article. */
.sponsor { margin: 34px 0 0; border: 1px dashed var(--line); border-radius: 6px; padding: 16px 18px; display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.sponsor .lbl { font: 500 9.5px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.sponsor p { margin-top: 6px; font-size: 14px; line-height: 1.5; color: var(--muted); }
.sponsor a { font: 500 13px var(--body); color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--dim); white-space: nowrap; }
.sponsor a:hover { border-bottom-color: var(--ink); }

.signup { margin: 34px 0 72px; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 22px 24px; }
.signup h3 { font-size: 24px; }
.signup p { margin-top: 8px; font-size: 14.5px; line-height: 1.6; color: var(--muted); }
.signup form { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.signup input { flex: 1 1 220px; min-width: 0; font: 400 14px var(--body); color: var(--ink); background: var(--ground); border: 1px solid var(--line); border-radius: 4px; padding: 10px 12px; }
.signup input::placeholder { color: var(--dim); }
.signup input:focus { outline: none; border-color: var(--muted); }
.signup button { font: 600 13px var(--body); color: var(--ground); background: var(--ink); border: 0; border-radius: 4px; padding: 10px 16px; cursor: pointer; }
.signup button:hover { background: #fff; }
.signup .msg { margin-top: 10px; font: 400 12px/1.5 var(--mono); color: var(--muted); min-height: 1em; }
@media (max-width: 720px) { .signup { margin-bottom: 44px; padding: 18px; } }

/* Index: the list of articles. */
.list { margin: 30px 0 0; border-top: 1px solid var(--line); }
.list a.item { display: grid; grid-template-columns: 96px 1fr; gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.list .date { font: 500 10.5px/1.9 var(--mono); letter-spacing: .1em; color: var(--dim); text-transform: uppercase; }
.list h2 { font-size: 26px; }
.list a.item:hover h2 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.list p { margin-top: 8px; font-size: 15px; line-height: 1.6; color: var(--muted); }
.list .for { margin-top: 10px; font: 500 10px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
@media (max-width: 560px) { .list a.item { grid-template-columns: 1fr; gap: 6px; } }

footer { border-top: 1px solid var(--line); padding: 16px 0 34px; font: 400 12px/1.5 var(--mono); color: var(--dim); }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); }
footer .tm { margin-top: 10px; font-size: 11px; opacity: .85; }
footer .tm sup { font-size: .72em; vertical-align: super; }

/* Histogram small multiples (town-records.html): real vs shuffled, one shared axis. */
.hpanel { margin-top: 16px; }
.hpanel .ht { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font: 500 12px/1.4 var(--body); color: var(--ink); }
.hpanel .hs { font: 400 11.5px/1.4 var(--mono); color: var(--muted); }
.hist { display: grid; grid-template-columns: repeat(11, 1fr); gap: 2px; height: 120px; align-items: end; margin-top: 8px; border-bottom: 1px solid var(--line); }
.hist b { display: block; background: var(--m1); border-radius: 4px 4px 0 0; min-height: 0; }
.hist.alt b { background: var(--m2); }
.hist b:hover { outline: 1px solid var(--ink); outline-offset: 1px; }
.hist .hit { height: 100%; display: flex; align-items: end; }
.hist .hit b { width: 100%; }
.haxis, .hnote { display: grid; grid-template-columns: repeat(11, 1fr); gap: 2px; margin-top: 5px; font: 400 10px/1.2 var(--mono); color: var(--dim); text-align: center; }
.hnote { color: var(--muted); font-size: 10.5px; }
.hnote span { white-space: nowrap; }
button.again { font: 500 12px var(--body); color: var(--ground); background: var(--ink); border: 0; border-radius: 4px; padding: 6px 12px; cursor: pointer; }
button.again:hover { background: #fff; }

/* Diverging bars (ohio-georgia.html): points above/below a player's own teammates,
   drawn from a centre line. Bright = beyond chance after testing every group. */
.dtrack { position: relative; height: 12px; }
.dtrack::before { content: ""; position: absolute; left: 50%; top: -4px; bottom: -4px; width: 1px; background: var(--dim); }
.dbar { position: absolute; top: 0; height: 12px; background: var(--m-rest); }
.dbar.pos { left: 50%; border-radius: 0 4px 4px 0; }
.dbar.neg { right: 50%; border-radius: 4px 0 0 4px; }
.dbar.sig { background: var(--m1); }
.mark { color: var(--ink); margin-left: 5px; font-size: 11px; }
