/* HoopAtlas v2: the OPP Spectrum world. Charcoal continuum (dark) or a warm grey sheet (light);
   colour only as thin emission lines; state as line form (solid, dashed, short), not hue. */
@font-face {
  font-family: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url(/v2/fonts/schibsted-grotesk-latin.woff2) format("woff2");
  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: "Schibsted Grotesk";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url(/v2/fonts/schibsted-grotesk-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Light: warm grey sheet, ink legends, deep emission inks. */
:root {
  --ground: #e8e7e3;
  --plate: #f5f4f1;
  --plate-2: #dad9d4;
  --rule: #cac9c3;
  --rule-strong: #979690;
  --ink: #1b1c1e;
  --ink-2: #464541;
  --ink-3: #5c5b56;
  --line-g: #1a62ab;
  --line-f: #136b38;
  --line-c: #ad281b;
  --sodium: #c48a00;
  --sodium-ink: #1b1c1e;
  --sel-row: #f3e3b3;
  --warn: #a35d00;
  --bad: #b3261e;
  --focus: #1a62ab;
  --rail-fade: 0.9;
  --rail-alpha: 0.4;

  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  --radius: 2px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* Names the labelling page (labels.html) still reads. */
  --bg: var(--ground);
  --surface: var(--plate);
  --surface-2: var(--plate-2);
  --line: var(--rule);
  --line-strong: var(--rule-strong);
  --text: var(--ink);
  --text-2: var(--ink-2);
  --text-3: var(--ink-3);
  --accent: var(--line-g);
  --accent-soft: var(--sel-row);
  --good: var(--line-f);
  --row-hover: var(--plate-2);
  color-scheme: light;
}

/* Dark: charcoal continuum, bone legends, bright emission lines. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #1b1c1e;
    --plate: #232427;
    --plate-2: #2c2e31;
    --rule: #34363a;
    --rule-strong: #55575c;
    --ink: #ebe6da;
    --ink-2: #b9b3a5;
    --ink-3: #959083;
    --line-g: #5cb8ff;
    --line-f: #63e08f;
    --line-c: #ff6b5b;
    --sodium: #ffd23f;
    --sodium-ink: #1b1c1e;
    --sel-row: #3a3423;
    --warn: #f0b75a;
    --bad: #ff7a6b;
    --focus: #ffd23f;
    --rail-fade: 0.55;
    --rail-alpha: 0.62;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #1b1c1e;
  --plate: #232427;
  --plate-2: #2c2e31;
  --rule: #34363a;
  --rule-strong: #55575c;
  --ink: #ebe6da;
  --ink-2: #b9b3a5;
  --ink-3: #959083;
  --line-g: #5cb8ff;
  --line-f: #63e08f;
  --line-c: #ff6b5b;
  --sodium: #ffd23f;
  --sodium-ink: #1b1c1e;
  --sel-row: #3a3423;
  --warn: #f0b75a;
  --bad: #ff7a6b;
  --focus: #ffd23f;
  --rail-fade: 0.55;
  --rail-alpha: 0.62;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--ground);
  color: var(--ink);
  font: 14px/1.45 var(--font);
  font-feature-settings: "tnum" 0;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--sodium); color: var(--sodium-ink); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--rule-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
.num, td.n, th.n { font-variant-numeric: tabular-nums; text-align: right; }
.muted { color: var(--ink-3); }
.small { font-size: 12px; }
html { scrollbar-color: var(--rule-strong) var(--ground); }

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 28px;
  height: 52px; padding: 0 32px;
  background: var(--ground); border-bottom: 1px solid var(--rule);
}
.wordmark { font-weight: 900; letter-spacing: 0.06em; font-size: 15px; color: var(--ink); text-decoration: none; }
.topbar nav { display: flex; gap: 22px; align-self: stretch; }
.topbar nav a {
  display: flex; align-items: center; color: var(--ink-2); font-weight: 500; text-decoration: none; white-space: nowrap;
  box-shadow: inset 0 -2px 0 transparent; transition: box-shadow 160ms var(--ease-out), color 160ms;
}
.topbar nav a:hover { color: var(--ink); }
.topbar nav a.active { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
.topbar .spacer { flex: 1; }
.topbar .meta { color: var(--ink-3); font-size: 12px; }
.theme-toggle {
  border: 1px solid var(--rule-strong); background: transparent; color: var(--ink-2);
  border-radius: var(--radius); height: 30px; padding: 0 12px; font: 500 13px var(--font); cursor: pointer; white-space: nowrap; flex: 0 0 auto;
}
.theme-toggle:hover { color: var(--ink); border-color: var(--ink-2); }

main { padding: 0 32px 48px; }

/* The rail: the instrument every view hangs off. */
.spectrum { padding: 28px 0 0; }
.spectrum-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: end; }
.spectrum-head h1 { margin: 0; font-size: 44px; line-height: 0.98; font-weight: 900; letter-spacing: -0.035em; text-wrap: balance; }
.spectrum-head .lede { margin: 10px 0 0; color: var(--ink-2); max-width: 60ch; text-wrap: pretty; }
.model-card { text-align: right; color: var(--ink-2); font-size: 13px; line-height: 1.55; }
.model-card b { color: var(--ink); font-weight: 700; }
.keys { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 16px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.keys span { display: inline-flex; align-items: center; gap: 8px; }
.keys i { display: inline-block; width: 2px; height: 14px; background: currentColor; }
.keys .g { color: var(--line-g); } .keys .f { color: var(--line-f); } .keys .c { color: var(--line-c); }
.keys .s { color: var(--ink); } .keys .s i { background: var(--sodium); box-shadow: 4px 0 0 var(--sodium); margin-right: 4px; }
.keys .short i { height: 7px; background: var(--ink-3); }

.rail-wrap { position: relative; margin-top: 18px; user-select: none; touch-action: none; }
.rail-wrap canvas { display: block; width: 100%; height: 230px; cursor: crosshair; }
.rail-tip {
  position: absolute; top: 0; transform: translateX(-50%); pointer-events: none; white-space: nowrap;
  background: var(--ink); color: var(--ground); font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: var(--radius);
  opacity: 0; transition: opacity 120ms;
}
.rail-tip.on { opacity: 1; }
.rail-tip span { font-weight: 400; opacity: 0.8; margin-left: 6px; font-variant-numeric: tabular-nums; }

.range { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 14px; font-size: 13px; color: var(--ink-2); }
.range label { display: inline-flex; align-items: center; gap: 6px; }
.range input {
  width: 64px; height: 30px; padding: 0 8px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: var(--plate); color: var(--ink); font: 500 13px var(--font); font-variant-numeric: tabular-nums; text-align: right;
}
.range .hint { color: var(--ink-3); }
.range button, .linkish { border: 0; background: none; color: var(--ink); font: 600 13px var(--font); cursor: pointer; padding: 0; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--rule-strong); }

/* Board */
.board-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 28px 0 10px; padding-top: 18px; border-top: 1px solid var(--rule-strong); }
.board-bar h2 { margin: 0 14px 0 0; font-size: 20px; font-weight: 800; letter-spacing: -0.015em; }
.board-bar .count { color: var(--ink-2); font-variant-numeric: tabular-nums; margin-right: auto; }
.filters { display: contents; }
.filters input, .filters select {
  height: 34px; padding: 0 10px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: var(--plate); color: var(--ink); font: 500 13px var(--font);
}
.filters input::placeholder { color: var(--ink-3); }
.filters input[type="search"] { width: 240px; }
.filters .clear { border: 0; background: none; color: var(--ink); font: 600 13px var(--font); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

.table-wrap { border-top: 2px solid var(--ink); }
@media (max-width: 1400px) {
  .table-wrap { overflow-x: auto; }
  /* Inside a scrolling wrapper the sticky header is relative to the wrapper, not the page. */
  .table-wrap table.data thead th { top: 0; }
}
table.data { width: 100%; border-collapse: collapse; white-space: nowrap; font-variant-numeric: tabular-nums; }
table.data th, table.data td { padding: 0 10px; height: 36px; border-bottom: 1px solid var(--rule); }
table.data thead th {
  position: sticky; top: 52px; z-index: 1; height: 34px; background: var(--ground);
  color: var(--ink-2); font-size: 12px; font-weight: 600; text-align: left; user-select: none;
  border-bottom: 1px solid var(--rule-strong);
}
table.data thead th.n { text-align: right; }
table.data thead th[data-sort] { cursor: pointer; }
table.data thead th[data-sort]:hover, table.data thead th.sorted { color: var(--ink); }
table.data thead th.sorted::after { content: ""; display: inline-block; width: 7px; height: 2px; margin-left: 6px; vertical-align: 3px; background: var(--ink); box-shadow: 0 4px 0 var(--ink); }
table.data thead th.sorted.asc::after { box-shadow: 0 -4px 0 var(--ink); vertical-align: 7px; }
table.data tbody tr.link { cursor: pointer; }
table.data tbody tr.link:hover td { background: var(--plate); }
table.data tbody tr.link:focus-visible { outline-offset: -2px; }
table.data tbody tr.hot td { background: var(--sel-row); }
table.data td.rank { color: var(--ink-3); width: 1%; }
table.data td.player .name { font-weight: 700; color: var(--ink); }
table.data td.player .sub { color: var(--ink-3); font-size: 12px; margin-left: 8px; }
table.data td.dim, table.data td .dim { color: var(--ink-3); }
table.data td.key { font-weight: 700; }
table.data td.sep, table.data th.sep { border-left: 1px solid var(--rule); }
td.opp { position: relative; padding-left: 16px !important; }
td.opp .v { font-weight: 800; font-size: 15px; }
td.opp .p { color: var(--ink-3); font-size: 12px; margin-left: 6px; display: inline-block; min-width: 28px; }
td.opp::before { content: ""; position: absolute; left: 6px; top: 9px; bottom: 9px; width: 2px; background: var(--pos, var(--ink-3)); }
td.opp.low::before { top: 14px; bottom: 14px; }
.pos-g { --pos: var(--line-g); } .pos-f { --pos: var(--line-f); } .pos-c { --pos: var(--line-c); }

.pager { display: flex; align-items: center; gap: 12px; justify-content: flex-end; margin-top: 14px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.pager button {
  height: 32px; padding: 0 14px; border: 1px solid var(--rule-strong); background: transparent;
  color: var(--ink); border-radius: var(--radius); font: 600 13px var(--font); cursor: pointer;
}
.pager button:hover:not(:disabled) { border-color: var(--ink); }
.pager button:disabled { opacity: 0.4; cursor: default; }
.footnote { margin-top: 18px; color: var(--ink-3); font-size: 12px; max-width: 80ch; line-height: 1.55; }

/* Player page */
.back { display: inline-block; margin: 22px 0 0; font-size: 13px; font-weight: 600; }
.player-top { margin-top: 16px; }
.who { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 22px; align-items: end; }
.headshot { width: 112px; height: 112px; object-fit: cover; background: var(--plate-2); filter: grayscale(1) contrast(1.05); border-bottom: 2px solid var(--ink); }
.who h1 { margin: 0; font-size: 64px; line-height: 0.92; font-weight: 900; letter-spacing: -0.04em; text-wrap: balance; }
.who .team { margin-top: 10px; color: var(--ink-2); font-size: 16px; font-weight: 500; }
.who .team .moved { display: block; margin-top: 4px; font-size: 14px; color: var(--ink-3); }
.facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 18px; color: var(--ink-2); }
.facts b { color: var(--ink); font-weight: 700; }
.links { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 16px; font-size: 13px; font-weight: 600; }

.plate { max-width: 460px; background: var(--ink); color: var(--ground); padding: 22px 24px 20px; }
.plate .k { font-size: 12px; font-weight: 600; opacity: 0.75; }
.plate .big { font-size: 72px; line-height: 0.95; font-weight: 900; letter-spacing: -0.045em; font-variant-numeric: tabular-nums; margin-top: 4px; }
.plate .row { display: flex; flex-wrap: wrap; gap: 26px; margin-top: 14px; }
.plate .row b { display: block; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.plate .drivers { margin-top: 16px; padding-top: 12px; border-top: 1px solid color-mix(in srgb, var(--ground) 30%, transparent); font-size: 14px; line-height: 1.5; }
.plate .drivers ol { margin: 6px 0 0; padding-left: 20px; }
.plate .fine { margin-top: 12px; font-size: 12px; opacity: 0.75; line-height: 1.5; }
.below { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 440px; grid-template-areas: "main plate"; gap: 0 40px; padding-top: 34px; }
.below-main { grid-area: main; min-width: 0; }
.below-main .statline { margin-top: 0; }
.below-main .table-wrap { overflow-x: auto; }
.below-main table.data thead th { top: 0; }
.below-main table.data .hide-sm { display: none; } /* made-attempted columns; the percentages stay */
.plate-anchor { grid-area: plate; }
.leader { position: absolute; left: 0; top: 0; width: 100%; height: 34px; overflow: visible; }
.leader path { fill: none; stroke: var(--sodium); stroke-width: 2; }
.plate.anchored { clip-path: inset(0 0 100% 0); transition: clip-path 480ms var(--ease-out); }
.plate.anchored.open { clip-path: inset(0 0 0 0); }
.plate.none { background: var(--plate); color: var(--ink-2); border: 1px dashed var(--rule-strong); }

.prov { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.prov span { display: inline-flex; align-items: center; gap: 8px; height: 26px; padding: 0 10px; border: 1px solid var(--rule-strong); font-size: 12px; font-weight: 600; color: var(--ink-2); }
.prov span::before { content: ""; width: 14px; height: 0; border-top: 2px solid var(--ink-2); }
.prov span.calc::before { border-top: 4px double var(--ink-2); height: 4px; }
.prov span.unv { border-style: dashed; }
.prov span.unv::before { border-top: 2px dashed var(--ink-2); }

.player-rail { margin-top: 30px; }
.player-rail .rail-wrap { margin-top: 0; }
.player-rail canvas { height: 120px; }

.statline {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  margin-top: 30px; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule-strong);
}
.statline > div { padding: 12px 0 14px; }
.statline .v { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.statline .l { color: var(--ink-3); font-size: 12px; font-weight: 600; }

section.block { margin-top: 34px; }
section.block h2 { font-size: 20px; font-weight: 800; letter-spacing: -0.015em; margin: 0 0 10px; }
section.block h2 .muted { font-weight: 500; font-size: 13px; margin-left: 8px; letter-spacing: 0; }
table.data tr.current td { background: var(--sel-row); }

.empty { padding: 40px 0; color: var(--ink-3); }
.error { padding: 16px 0; color: var(--bad); font-weight: 600; }
.loading { padding: 40px 0; color: var(--ink-3); }

@media (prefers-reduced-motion: reduce) {
  .topbar nav a, .rail-tip, .plate.anchored { transition: none; }
}

@media (max-width: 900px) {
  .below { grid-template-columns: minmax(0, 1fr); grid-template-areas: "plate" "main"; gap: 30px; }
  .plate { max-width: none; }
  .spectrum-head { grid-template-columns: 1fr; }
  .model-card { text-align: left; }
}
@media (max-width: 720px) {
  main { padding: 0 16px 40px; }
  .topbar { padding: 0 16px; gap: 10px; overflow-x: auto; scrollbar-width: none; }
  .topbar nav { gap: 12px; }
  .wordmark { font-size: 14px; }
  .topbar .meta { display: none; }
  .spectrum-head h1 { font-size: 32px; }
  .rail-wrap canvas { height: 170px; }
  .filters input[type="search"] { width: 100%; }
  .who { grid-template-columns: 1fr; }
  .who h1 { font-size: 44px; }
  .plate .big { font-size: 56px; }
  table.data .hide-sm, table.data td.player .sub { display: none; }
  table.data thead th { top: 0; }
}

/* ---------- Tracking: sign-in, My players, boards, the player's tracking bar and notes ---------- */
.auth-slot { display: flex; align-items: center; gap: 12px; font-size: 13px; white-space: nowrap; }
.who-am-i { font-weight: 700; }
.sign-in-link { font-weight: 600; }

.btn {
  display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px;
  border: 1px solid var(--ink); border-radius: var(--radius); background: transparent; color: var(--ink);
  font: 600 13px var(--font); cursor: pointer; white-space: nowrap; list-style: none;
}
.btn::-webkit-details-marker { display: none; }
.btn:hover { background: var(--plate); }
.btn.primary, .btn.on { background: var(--ink); color: var(--ground); }
.btn.primary:hover, .btn.on:hover { background: var(--ink-2); }
.linkish.danger { color: var(--bad); }

.signin { max-width: 420px; padding-top: 40px; }
.signin h1, .home-head h1 { margin: 0; font-size: 44px; line-height: 1; font-weight: 900; letter-spacing: -0.035em; }
.signin .lede, .home-head .lede { margin: 10px 0 0; color: var(--ink-2); max-width: 60ch; }
.stack { display: grid; gap: 14px; margin-top: 24px; }
.stack label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.stack input, .inline-form input, .inline-form select, .track-field select, .note-form textarea, .note-form select {
  height: 36px; padding: 0 10px; border: 1px solid var(--rule-strong); border-radius: var(--radius);
  background: var(--plate); color: var(--ink); font: 500 14px var(--font);
}
.stack .btn { justify-self: start; }
.form-error { color: var(--bad); font-weight: 600; font-size: 13px; }

.home-head { padding-top: 28px; }
.home-head .linkish { margin-top: 12px; }
.empty-line { color: var(--ink-3); margin: 8px 0 0; }

.boards-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; padding-top: 18px; border-top: 1px solid var(--rule-strong); }
.board-list { list-style: none; margin: 0; padding: 0; }
.board-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; padding: 9px 0; border-bottom: 1px solid var(--rule); }
.board-list a { font-weight: 700; }
.board-list .count { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.inline-form { display: grid; gap: 10px; align-content: start; }
.inline-form h2 { margin: 0 0 4px; }
.inline-form .btn { justify-self: start; }

.crm-cols { display: grid; grid-template-columns: repeat(6, minmax(150px, 1fr)); gap: 0; border-top: 2px solid var(--ink); overflow-x: auto; }
.crm-col { padding: 10px 12px 14px; border-right: 1px solid var(--rule); min-width: 0; }
.crm-col:last-child { border-right: 0; }
.crm-col h3 { margin: 0 0 8px; font-size: 13px; font-weight: 700; display: flex; justify-content: space-between; gap: 8px; }
.crm-col h3 .count { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.crm-col ul { list-style: none; margin: 0; padding: 0; }
.crm-col li { display: grid; padding: 6px 0; border-bottom: 1px solid var(--rule); font-size: 13px; }
.crm-col li a { font-weight: 600; text-decoration: none; }
.crm-col li .dim { font-size: 12px; color: var(--ink-3); }
.sub-head { margin: 22px 0 6px; font-size: 14px; font-weight: 700; }
.activity { list-style: none; margin: 0; padding: 0; font-size: 13px; }
.activity li { padding: 6px 0; border-bottom: 1px solid var(--rule); }

.track-signed-out { margin: 18px 0 0; color: var(--ink-2); }
.track-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--rule); }
.track-field { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.track-meta { font-size: 12px; }
.board-picker { position: relative; }
.board-picker summary { list-style: none; }
.board-picker .picker {
  position: absolute; z-index: 20; top: 40px; left: 0; min-width: 260px; display: grid; gap: 8px; padding: 12px 14px;
  background: var(--plate); border: 1px solid var(--ink); box-shadow: 0 8px 24px rgb(0 0 0 / 0.18);
}
.board-picker .picker label { display: flex; align-items: baseline; gap: 8px; font-size: 13px; }
.board-picker .picker .dim { color: var(--ink-3); font-size: 12px; }
.on-boards { margin: 10px 0 0; font-size: 13px; color: var(--ink-2); }

.notes-block { margin-top: 30px; }
.note-form { display: grid; gap: 8px; }
.note-form textarea { height: auto; min-height: 76px; padding: 8px 10px; line-height: 1.5; resize: vertical; }
.note-actions { display: flex; justify-content: space-between; gap: 10px; }
.notes { list-style: none; margin: 14px 0 0; padding: 0; }
.notes li { padding: 10px 0 12px; border-bottom: 1px solid var(--rule); }
.notes li.private { border-bottom-style: dashed; border-bottom-color: var(--ink-3); }
.note-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; font-size: 12px; color: var(--ink-3); }
.note-meta b { color: var(--ink); }
.note-meta .linkish { font-size: 12px; margin-left: auto; }
.notes p { margin: 6px 0 0; max-width: 64ch; }

@media (max-width: 900px) {
  .boards-grid { grid-template-columns: 1fr; gap: 22px; }
  .crm-cols { grid-template-columns: repeat(6, 170px); }
}
@media (max-width: 720px) {
  .signin h1, .home-head h1 { font-size: 34px; }
  .auth-slot .who-am-i { display: none; }
}

/* ---------- Full player data: tags, tier band, advanced, availability, similar; board column switch ---------- */
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tag-chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border: 1px solid var(--ink); font-size: 12px; font-weight: 700; cursor: help; }
table.data td.player .tag { margin-left: 8px; font-size: 11px; font-weight: 700; color: var(--ink-2); border: 1px solid var(--rule-strong); padding: 1px 6px; }

.plate .band { margin-top: 16px; padding-top: 12px; border-top: 1px solid color-mix(in srgb, var(--ground) 30%, transparent); }
.plate .band b { font-size: 20px; font-weight: 800; text-transform: capitalize; }
.plate .band .band-range { font-size: 12px; opacity: 0.75; }
.plate .band p { margin: 6px 0 0; font-size: 14px; line-height: 1.45; }

table.data tr.low-sample td { color: var(--ink-3); }
.avail-line { margin: 0; }
.avail-seasons, .similar { list-style: none; margin: 10px 0 0; padding: 0; }
.avail-seasons li { padding: 6px 0; border-bottom: 1px solid var(--rule); font-size: 13px; }
.similar li { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 8px 0; border-bottom: 1px solid var(--rule); }
.similar li a { font-weight: 700; }
.similar .dim { color: var(--ink-3); font-size: 13px; }
.sim-score { font-weight: 800; font-variant-numeric: tabular-nums; }

.view-switch { display: inline-flex; border: 1px solid var(--ink); border-radius: var(--radius); }
.view-switch button { height: 32px; padding: 0 12px; border: 0; background: transparent; color: var(--ink); font: 600 13px var(--font); cursor: pointer; }
.view-switch button + button { border-left: 1px solid var(--ink); }
.view-switch button[aria-pressed="true"] { background: var(--ink); color: var(--ground); }

/* Tables beside the OPP plate run in a narrower column, so their cells sit a little tighter. */
.below-main table.data th, .below-main table.data td { padding: 0 7px; }

/* Availability and similar players sit under the OPP plate, in its column. */
.side-blocks section.block { margin-top: 28px; }
.side-blocks .similar li { grid-template-columns: minmax(0, 1fr) auto; }
.side-blocks .similar .dim { grid-column: 1; grid-row: 2; }
.side-blocks .similar .sim-score { grid-row: 1 / span 2; align-self: center; }

/* ---------- AI panel, matchmaker, change log ---------- */
.ai-badge { display: inline-flex; align-items: center; height: 18px; padding: 0 6px; margin-left: 6px; vertical-align: 3px;
  border: 1px dashed var(--ink-2); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; color: var(--ink-2); }
.ai-label { margin: 0 0 10px; font-size: 13px; font-weight: 600; }
.ai-label .dim { font-weight: 400; }
.ai-outdated { margin: 0 0 10px; font-size: 13px; color: var(--bad); }
.ai-langs { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--rule-strong); margin-bottom: 12px; }
.ai-langs button { height: 28px; padding: 0 10px; border: 0; background: transparent; color: var(--ink-2); font: 600 12px var(--font); cursor: pointer; }
.ai-langs button + button { border-left: 1px solid var(--rule-strong); }
.ai-langs button[aria-pressed="true"] { background: var(--ink); color: var(--ground); }
.ai-body > p { max-width: 64ch; line-height: 1.6; margin: 0 0 10px; }
.ai-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 8px; }
.ai-cols h3 { margin: 0 0 6px; font-size: 13px; font-weight: 700; }
.ai-cols ul { margin: 0; padding-left: 18px; font-size: 13px; line-height: 1.5; }
.ai-cols li { margin-bottom: 6px; }
.cites { white-space: nowrap; }
.cite { border: 0; border-bottom: 1px dashed var(--ink-3); background: none; padding: 0 2px; margin: 0 1px; color: var(--ink-2);
  font: 600 11px var(--font); cursor: pointer; }
.cite:hover { color: var(--ink); border-bottom-style: solid; }
.ai-inputs { margin-top: 14px; border-top: 1px solid var(--rule); padding-top: 10px; font-size: 13px; }
.ai-inputs summary { cursor: pointer; font-weight: 600; }
.ai-inputs ul { list-style: none; margin: 10px 0 0; padding: 0; }
.ai-inputs li { padding: 8px 0; border-bottom: 1px solid var(--rule); scroll-margin: 80px; transition: background 600ms var(--ease-out); }
.ai-inputs li.flash { background: var(--sel-row); }
.ai-inputs code { font: 500 11px var(--mono); color: var(--ink-3); }
.ai-inputs dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 2px 12px; margin: 6px 0 0; }
.ai-inputs dt { color: var(--ink-3); }
.ai-inputs dd { margin: 0; }
.ai-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 14px; }
.ai-ask { display: grid; gap: 8px; margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--rule-strong); }
.ai-ask h3 { margin: 0; font-size: 15px; font-weight: 800; }
.ai-ask textarea { min-height: 56px; padding: 8px 10px; border: 1px solid var(--rule-strong); border-radius: var(--radius); background: var(--plate); color: var(--ink); font: 500 14px var(--font); resize: vertical; }
.ai-answer { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--rule-strong); }
.ai-answer > p { max-width: 64ch; line-height: 1.6; }
.small { font-size: 12px; }

.mm-form { display: grid; gap: 10px; margin-top: 20px; max-width: 900px; }
.mm-form textarea { min-height: 72px; padding: 10px 12px; border: 1px solid var(--rule-strong); border-radius: var(--radius); background: var(--plate); color: var(--ink); font: 500 15px var(--font); resize: vertical; }
.mm-examples { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; font-size: 13px; }
.mm-examples .linkish { font-weight: 500; text-align: left; }
.mm-cons, .mm-ignored { list-style: none; margin: 8px 0 0; padding: 0; }
.mm-cons li, .mm-ignored li { padding: 7px 0; border-bottom: 1px solid var(--rule); font-size: 14px; }
.mm-cons li.implicit { border-bottom-style: dashed; }
td.reasons { white-space: normal; min-width: 260px; font-size: 12px; }
td.reasons span { display: inline-block; margin: 2px 10px 2px 0; color: var(--ink-2); }
td.reasons b { color: var(--ink); }

.changes { list-style: none; margin: 8px 0 0; padding: 0; }
.changes li { padding: 9px 0; border-bottom: 1px solid var(--rule); }
.changes p { margin: 4px 0 2px; font-size: 14px; }
.change-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; font-size: 13px; }
.change-type { font-weight: 700; }
.new-count { display: inline-grid; place-items: center; min-width: 22px; height: 20px; padding: 0 6px; background: var(--ink); color: var(--ground); font-size: 12px; }

@media (max-width: 900px) {
  .ai-cols { grid-template-columns: 1fr; }
}
