/* Soulcounter: Deadlock's look (11-01 pass; the 10-31 "calm" Apple direction read as AI-made). Warm ink (or parchment) ground, square-cornered panels with a hairline and a lighter top edge, no blur or glow, Deadlock's own typefaces
   from the game files (fonts/: VALVE Oracle, the game's UI face, for everything; VALVE Pulp, its pulp-magazine masthead, for the name in the top bar only), normal-case semibold headings, tabular figures, and one accent: gold, kept under its
   old token name --brass so the rules below read the same. Semantic colours (good, warn, bad; weapon, vitality, spirit) are the game's own muted item colours and appear only
   where they mean something. The system is written up in docs/design-2026-10.md. Light mode is the same page on parchment. Every class the renderers
   (app.js, live.js, planner.js, coach.js) emit is styled here. */
@font-face { font-family: "VALVE Pulp"; src: url(fonts/valvepulp-bold.woff2) format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "VALVE Oracle"; src: url(fonts/valveoracle-medium.woff2) format("woff2"); font-weight: 100 500; font-display: swap; }
@font-face { font-family: "VALVE Oracle"; src: url(fonts/valveoracle-semibold.woff2) format("woff2"); font-weight: 600 900; font-display: swap; }
:root {
  color-scheme: light dark;
  --bg: light-dark(#ebe4d4, #0e0d0b); --bg-2: light-dark(#e2dac7, #15130f); --panel: light-dark(#f6f1e5, #1b1915); --panel-2: light-dark(#ebe3d1, #26231d); --panel-3: light-dark(#ddd3bd, #332f27);
  --line: light-dark(rgba(52,40,20,.1), rgba(236,224,196,.08)); --line-2: light-dark(rgba(52,40,20,.17), rgba(236,224,196,.14)); --line-3: light-dark(rgba(52,40,20,.3), rgba(236,224,196,.26));
  --fg: light-dark(#1f1a12, #ece4d2); --fg-2: light-dark(#4d4536, #c4baa5); --muted: light-dark(#635947, #9c927f);
  --surf-0: var(--bg); --surf-1: var(--bg-2); --surf-2: var(--panel); --surf-3: var(--panel-2); --surf-4: var(--panel-3);
  --state-hover: light-dark(rgba(31, 26, 18, .06), rgba(236, 224, 196, .08));
  --state-press: light-dark(rgba(31, 26, 18, .11), rgba(236, 224, 196, .13));
  --state-brass: color-mix(in srgb, var(--brass) 16%, transparent);
  --state-brass-hi: color-mix(in srgb, var(--brass) 24%, transparent);
  --brass: light-dark(#b5832a, #d4a34a); --brass-2: light-dark(#7c5710, #e8c27a); --brass-hi: light-dark(#d3a546, #f0d595); --focus: light-dark(#7c5710, #f0d595); --brass-lo: light-dark(#8d6519, #a87c30); --brass-ink: #1a1206;
  --glow: light-dark(rgba(181,131,42,.18), rgba(212,163,74,.2)); --scrim: light-dark(rgba(36,28,14,.45), rgba(8,7,5,.72));
  --weapon-fill: light-dark(#bf6a14, #e08a2e); --vitality-fill: light-dark(#4f8a2a, #7cab45); --spirit-fill: light-dark(#7d4bb8, #a676d6); --weapon: light-dark(#82480e, #e08a2e); --vitality: light-dark(#37611d, #7cab45); --spirit: light-dark(#6a3da3, #a676d6);   /* 11-21 pass: the light halves of the semantic colours darkened to 4.5:1 or more on the parchment panels and on their own 16% tints (they read as small chip, tag and delta text) */
  --good: light-dark(#315d1f, #8db552); --good-bg: light-dark(rgba(49,93,31,.13), rgba(141,181,82,.14)); --warn: light-dark(#734a05, #dca345); --warn-bg: light-dark(rgba(115,74,5,.13), rgba(220,163,69,.14)); --bad: light-dark(#96301e, #e36d55); --bad-bg: light-dark(rgba(150,48,30,.12), rgba(227,109,85,.15));
  --seg-on: light-dark(#f6f1e5, #332f27);
  --sapphire: light-dark(#235891, #4f8de0);   /* the enemy team: Deadlock's Sapphire Flame against your Amber Hand (the brass) */
  --shadow: 0 18px 40px -12px light-dark(rgba(40,28,10,.3), rgba(0,0,0,.8));
  --elev-1: 0 1px 2px light-dark(rgba(40,28,10,.09), rgba(0,0,0,.42)), 0 1px 0 light-dark(rgba(52,40,20,.06), rgba(0,0,0,.35));
  --elev-2: 0 6px 18px -6px light-dark(rgba(40,28,10,.18), rgba(0,0,0,.62)), 0 1px 2px light-dark(rgba(40,28,10,.08), rgba(0,0,0,.35));
  --shadow-card: var(--elev-1);
  --co-you: light-dark(#7c5710, #d9ab57); --co-up: light-dark(#7146b4, #bf5af2); --co-lane: light-dark(#2a69ad, #4a8ad0); --co-mid: light-dark(#8f5207, #c28f2c); --co-late: light-dark(#8a2fa0, #a072dc); --co-peer: light-dark(#87948f, #5f6e74);   /* coach charts (validated on the panel colour) */
  --display: "VALVE Oracle", -apple-system, BlinkMacSystemFont, "Segoe UI Variable Display", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --body: "VALVE Oracle", -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text", "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --pulp: "VALVE Pulp", "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;   /* the masthead face: the name in the top bar, nothing else */
  --serif: var(--body);   /* the voice (ledes, verdicts): the same face, upright; the token keeps its old name so the rules below read the same */
  --mono: var(--body);    /* figures: the same face with tabular numerals, kept as a token for the same reason */
  --code: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, Menlo, monospace;   /* a true monospace only for commands and keys */
  --r: 6px; --r-sm: 4px; --r-pill: 999px;
  --deco: color-mix(in srgb, var(--brass) 48%, transparent);
  --ease: cubic-bezier(.2, 0, 0, 1);
  --ease-emph: cubic-bezier(.05, .7, .1, 1);
  --ease-spring: cubic-bezier(.34, 1.32, .64, 1);
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { scrollbar-width: thin; scrollbar-color: var(--line-3) transparent; background: var(--bg); }
html::before {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(960px 380px at 50% -110px, color-mix(in srgb, var(--brass) 16%, transparent), transparent 72%),
    radial-gradient(125% 105% at 50% 45%, transparent 56%, light-dark(rgba(52, 40, 20, .09), rgba(0, 0, 0, .54)) 100%);
}
body {
  margin: 0; color: var(--fg); font: 400 15px/1.47 var(--body); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; min-height: 100dvh; background: transparent;
  text-rendering: optimizeLegibility;
}
/* no decoration behind the header: the aurora (three blurred gold, violet and teal ellipses, 10-31) came out on 11-01 (Rauli: "i dont like the rainbow background") */
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
::selection { background: color-mix(in srgb, var(--brass) 35%, transparent); }
p, .lede { text-wrap: pretty; }
img { max-width: 100%; display: block; }
.num, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; font-weight: 600; }
.muted { color: var(--muted); }
.wrap { max-width: 1520px; margin: 0 auto; padding-inline: 24px; }   /* a wide screen gets wider columns, not a longer page */
@media (max-width: 560px) { .wrap { padding-inline: 14px; } }
@media (max-width: 380px) { .wrap { padding-inline: 12px; } }

/* ---------- header ---------- */
.top {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30;
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 72%, var(--bg)), var(--bg));
  border-bottom: 1px solid var(--line);
}
.top::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: linear-gradient(90deg, color-mix(in srgb, var(--brass) 25%, transparent), color-mix(in srgb, var(--brass) 75%, transparent) 50%, color-mix(in srgb, var(--brass) 25%, transparent)); pointer-events: none; }   /* double-weight brass Deco trim under the masthead */
.top-row { display: flex; align-items: center; gap: 18px; padding-block: 12px 8px; flex-wrap: wrap; }
/* Soulcounter Desktop (html.desk-bar, set by glue/desktop.js): the window has no title bar, Windows draws only its three buttons over the top-right corner of the
   page, so the header row is the drag handle and keeps clear of them (Rauli, 11-01: the bar "is like a separate tab from the actual app") */
html.desk-bar .top-row { -webkit-app-region: drag; padding-right: 156px; }   /* the three buttons take about 153 px at 100% scale */
/* fixed, not sticky: Chromium places a sticky element's drag region by its offset from the scroll before, so once the page had scrolled a strip in mid-page
   dragged the window and swallowed clicks while the header did not drag (0.7.28-0.7.34). The glue keeps --desk-top at the header's height. */
html.desk-bar header.top { position: fixed; top: 0; left: 0; right: 0; }   /* header.top: the top threat's row is .thr.top */
html.desk-bar body { padding-top: var(--desk-top, 0px); }
html.desk-bar { scroll-padding-top: var(--desk-top, 0px); }
/* the drawer, the picker and search scrims and the respawn shop start under Windows' three buttons (as tall as the header row, --desk-cap): the hero
   drawer's close button sat under the window's own close button, so it hid the app instead (0.7.28-0.7.34) */
html.desk-bar :is(.drawer, .scrim, .respawn) { top: var(--desk-cap, 0px); -webkit-app-region: no-drag; }
html.desk-bar .modal { max-height: calc(100dvh - var(--desk-cap, 0px) - 40px); }   /* the picker and search boxes fit the shorter scrim */
html.desk-bar #paletteScrim .modal { max-height: calc(100dvh - var(--desk-cap, 0px) - min(10vh, 60px) - 24px); }
html.desk-bar .top-row :is(a, button, input, select, label, summary, [role="button"], .menu-b) { -webkit-app-region: no-drag; }   /* summary: the Settings menu opens from one, and a drag region swallowed its clicks (0.7.28-0.7.34); .menu-b: the open menu is page, not title bar */
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--fg); }
.brand .sigil { width: 28px; height: 28px; flex: none; border-radius: 3px; }   /* no ring or shadow: the tile sits flat like the other icons (Rauli, 11-01: "the lock has gray outlines") */
.brand b { font: 700 23px/1 var(--pulp); letter-spacing: .04em; text-transform: uppercase; margin-top: -1px; }
.brand small { font: 600 11px/1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 1px 0 0 4px; white-space: nowrap; }
/* the patch pills sit at the right end of the tab strip (Detailed only), so the top row stays one clean line in both modes */
.patchline { display: flex; gap: 6px; align-items: center; flex-wrap: nowrap; margin-left: auto; padding-left: 16px; flex: none; align-self: center; }
@media (max-width: 1199px) { .patchline { display: none; } }
.patchline .pill { font: 500 11.5px/1 var(--mono); color: var(--muted); border-radius: var(--r-pill); padding: 5px 10px; white-space: nowrap; background: var(--surf-3); }
.patchline .pill.live { color: var(--brass-2); background: var(--state-brass); }
.top-tools { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.seg { display: inline-flex; gap: 2px; border-radius: var(--r-sm); padding: 2px; min-height: 36px; background: var(--surf-1); border: 1px solid var(--line-2); }
.seg button { border: 0; background: transparent; padding: 5px 11px; font-size: 13px; font-weight: 500; color: var(--fg-2); border-radius: calc(var(--r-sm) - 1px); transition: background .16s var(--ease), color .16s var(--ease), box-shadow .16s var(--ease); }
.seg button:hover { color: var(--fg); background: var(--state-hover); }
.seg button[aria-pressed="true"] { background: var(--state-brass); color: light-dark(#6f4d0c, var(--brass-2)); font-weight: 600; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brass) 52%, transparent); }
.kbd-btn { border: 1px solid var(--line); background: var(--surf-3); border-radius: var(--r-sm); padding: 7px 11px; min-height: 36px; font-size: 13px; font-weight: 500; color: var(--fg-2); display: inline-flex; gap: 7px; align-items: center; transition: color .16s var(--ease), background .16s var(--ease), border-color .16s var(--ease); }
.kbd-btn:hover { color: var(--fg); background: var(--surf-4); border-color: var(--line-2); }
a.kbd-btn, a.btn { text-decoration: none; color: var(--fg-2); }
.kbd-btn.get-app { color: var(--brass-2); background: var(--state-brass); border-color: color-mix(in srgb, var(--brass) 45%, transparent); font-weight: 600; }
.kbd-btn.get-app:hover { background: var(--state-brass-hi); border-color: color-mix(in srgb, var(--brass) 65%, transparent); color: var(--brass-2); }
.kbd-btn.tip { background: transparent; border-color: transparent; }
.kbd-btn.tip svg.ti { color: var(--brass-2); }   /* the header's Ko-fi tip link (11-12, Rauli: "the tip button should be more visible"): a plain link like the footer's, with only its heart in gold so Get the app stays the one gold button */
.kbd-btn.tip:hover { color: var(--brass-2); background: var(--state-hover); border-color: var(--line); }
@media (max-width: 939px) { .kbd-btn.tip { display: none; } }   /* measured 11-12: the header row holds Tip on one line down to 920 px and wrapped to a second from 900 to 860 (and again near 760, and on a phone, where it took a row of its own); narrower screens keep the footer's link */
.kbd-btn svg.ti { width: 15px; height: 15px; }
kbd { font: 500 11px/1 var(--code); border: 1px solid var(--line-2); border-radius: 3px; padding: 2px 5px; color: var(--muted); background: transparent; }
.tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; margin-left: -10px; padding-bottom: 8px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { position: relative; display: inline-flex; align-items: center; min-height: 36px; font: 600 12.5px/1 var(--body); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: var(--r-sm) var(--r-sm) 0 0; white-space: nowrap; transition: color .16s var(--ease), background .18s var(--ease); }
.tabs a:hover { color: var(--fg); background: var(--state-hover); }
.tabs a[aria-current="page"] { color: var(--brass-2); background: linear-gradient(180deg, transparent 10%, var(--state-brass)); box-shadow: inset 0 -2.5px 0 var(--brass); }
.tabs a:focus-visible { outline-offset: -2px; }   /* 11-21: the strip scrolls sideways, so a ring outside the tab lost its top edge */
/* 560 px and below: the strip wraps instead of scrolling sideways, so every tab is on the screen. At 390 px Tier list was cut off with no sign that the row scrolls
   (11-10). Inline flow, not flex, so text-wrap: balance evens the rows out (three and three in Simple, four and four in Detailed); a browser without it wraps where the
   row ends. font-size 0 takes the spaces between the links out of the row; each link sets its own font. Only where the header is not sticky: a second row of tabs that
   stays on the screen costs a landscape phone too much, so from 561 px the strip still scrolls (Detailed cuts Patch off up to about 670 px). */
@media (max-width: 560px) {
  .tabs { display: block; overflow: visible; font-size: 0; text-wrap: balance; }
  .tabs a { margin: 0 4px 4px 0; }
  :root:not([data-mode]) .tabs a:is([data-tab="matrix"], [data-tab="patch"]) { display: none; }   /* until app.js sets the mode: Simple is the default, and two tabs leaving a wrapped strip would move the other six on every first visit (a layout shift, measured 11-10) */
}
:root:not([data-mode]) .tabs a[data-tab="shop"] { display: none; }
svg.ti { width: 1em; height: 1em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
/* the close and remove buttons draw Lucide's x (#i-x), not the × character: VALVE Oracle draws × as a dot (launch audit, 11-02) */
.closebtn svg.ti { width: 18px; height: 18px; }
.slot .x svg.ti { width: 13px; height: 13px; stroke-width: 2.5; }
.iconbtn svg.ti { width: 14px; height: 14px; stroke-width: 2.25; }
.pchip svg.ti { width: 11px; height: 11px; stroke-width: 2.5; color: var(--muted); }

/* ---------- page furniture ---------- */
main { padding-block: 28px 70px; }
.view[hidden] { display: none !important; }
h2.sec { font: 700 clamp(24px, 2.6vw, 32px)/1.05 var(--pulp); letter-spacing: .02em; text-transform: uppercase; margin: 0 0 6px; text-wrap: balance; }
.lede { font: 400 15px/1.5 var(--serif); color: var(--fg-2); margin: 0 0 22px; max-width: 72ch; }
/* the Build lab's lede on a hero with an author's row and a common row: the other row's lede (data-alt) is laid out hidden in the same cell, so
   the build chips under it stand still when you switch rows (final review M-4, 11-18) */
.lede-pair { display: grid; }
.lede-pair > span, .lede-pair::after { grid-area: 1 / 1; }
.lede-pair::after { content: attr(data-alt); visibility: hidden; }
.eyebrow { font: 600 11px/1.3 var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.card, .icard, .rcard, .way {
  background-color: var(--surf-2);
  background-image: linear-gradient(180deg, color-mix(in srgb, var(--surf-3) 26%, var(--surf-2)) 0px, var(--surf-2) 44px);
}
.card { position: relative; border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--r); box-shadow: var(--elev-1); }
.card-h { display: flex; align-items: baseline; gap: 8px 14px; justify-content: space-between; padding: 15px 20px 11px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.card-h h3 { display: inline-flex; align-items: center; gap: 8px; font: 600 13px/1.25 var(--display); letter-spacing: .08em; text-transform: uppercase; margin: 0; }   /* Deadlock's shop and HUD label panels in tracked caps */
.card-h h3::before { content: ""; width: 5px; height: 5px; flex: none; transform: rotate(45deg); background: var(--brass); }
.card-h .eyebrow, .card-h .muted { font: 400 12.5px/1.4 var(--body); letter-spacing: 0; text-transform: none; color: var(--muted); }   /* a card's subtitle reads as a quiet sentence, not a label */
.card-b { padding: 14px 20px 20px; }
.stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-content: start; min-width: 0; }
.stack > *, .patch-grid > *, .igrid > * { min-width: 0; }
.example-note, .share-note { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--fg-2); background: var(--warn-bg); border: 1px dashed color-mix(in srgb, var(--warn) 45%, transparent); border-radius: var(--r-sm); padding: 7px 12px; margin-bottom: 14px; }
.example-note button, .share-note button { border: 0; background: var(--panel); border-radius: 2px; padding: 4px 9px; font-size: 12.5px; font-weight: 600; }
.example-note button:hover, .share-note button:hover { background: var(--panel-2); }
.share-note[hidden] { display: none; }   /* the strip above the page while a board opened from a link is on screen (app.js shareNote) */
/* an empty card: the soul glyph (img/art/soul.svg, ours: a brass soul with the lock's keyhole) and one calm line */
.empty-state { position: relative; border: 1px dashed var(--line-2); border-radius: var(--r-sm); padding: 16px 18px 16px 64px; color: var(--fg-2); font: 400 14px/1.45 var(--serif); min-height: 64px; display: block; align-content: center; }
.empty-state::before { content: ""; position: absolute; left: 16px; top: 50%; width: 36px; height: 36px; margin-top: -18px; background: url(img/art/soul.svg) no-repeat 50% 50% / contain; opacity: .9; }   /* one brass soul with the lock's keyhole (11-01, from the design canvas; Rauli did not like the three souls) */
.empty-state b { font-weight: 600; color: var(--fg); }
.empty-state .linkish { color: var(--brass-2); text-decoration: underline; text-underline-offset: 2px; font-weight: 500; }

/* ---------- board ---------- */
.board { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 10px; margin-bottom: 20px; }   /* eight equal columns, no panel boxes: Your lane spans two and Enemy team six, so all eight portraits are one width and start on one line (11-01) */
.side { position: relative; min-width: 0; }
.board .side.you { grid-column: span 2; }
.board .side.enemy { grid-column: span 6; }
@media (max-width: 900px) { .board { grid-template-columns: 1fr; } .board .side.you, .board .side.enemy { grid-column: auto; } .board .slots.two { grid-template-columns: repeat(2, minmax(0, 160px)); } }
.side-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; height: 22px; margin-bottom: 10px; white-space: nowrap; overflow: hidden; }   /* a fixed 22px, the hint with its Clear button: both titles sit on one line and the slot rows under them start together */
.side-h h3 { display: flex; align-items: center; gap: 8px; font: 600 13px/1.25 var(--display); letter-spacing: .08em; text-transform: uppercase; margin: 0; white-space: nowrap; color: var(--side-ac, var(--fg)); }
.side-h h3::before { content: ""; flex: none; width: 7px; height: 7px; margin-left: 2px; transform: rotate(45deg); background: var(--side-ac, var(--muted)); }   /* a small diamond, the game's waypoint shape, says whose side: amber yours, sapphire theirs. The header clips its overflow (a ring was cut off there, Rauli 11-01), so the 2px margin keeps the rotated corner inside */
.side.enemy { --side-ac: var(--sapphire); }
.side.you { --side-ac: var(--brass-2); }
.side.you .slot-btn:not(.empty) { border-color: color-mix(in srgb, var(--brass) 75%, var(--line)); border-top: 2px solid var(--brass-hi); box-shadow: 0 2px 6px -2px rgba(0,0,0,.35), 0 0 0 1px color-mix(in srgb, var(--brass) 35%, transparent); }   /* Amber Hand cards carry a burnished brass crown */
.side.you .slot-btn:not(.empty) .art { background: radial-gradient(120% 90% at 50% 25%, color-mix(in srgb, var(--brass) 16%, var(--panel-3)), var(--bg-2) 85%); }
.side.enemy .slot-btn:not(.empty) { border-color: color-mix(in srgb, var(--sapphire) 32%, var(--line)); border-top: 2px solid color-mix(in srgb, var(--sapphire) 55%, var(--line)); }
.side.enemy .slot-btn:not(.empty) .art { background: radial-gradient(120% 90% at 50% 25%, color-mix(in srgb, var(--sapphire) 14%, var(--panel-3)), var(--bg-2) 85%); }
.slot:has(.lane-t[aria-pressed="true"]) .slot-btn { border-color: var(--sapphire); border-top: 2px solid var(--sapphire); box-shadow: 0 2px 8px -2px color-mix(in srgb, var(--sapphire) 35%, transparent), 0 0 0 1px color-mix(in srgb, var(--sapphire) 45%, transparent); }
.slot:has(.threat-badge) .slot-btn { border-top: 2px solid var(--bad); }
.side-h .hint { font: 500 12px/1.3 var(--mono); color: var(--muted); min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.slots { display: grid; gap: 10px; }
.slots.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.slots.six { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 700px) { .slots.six { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.slot { position: relative; min-width: 0; }
.slot-btn { width: 100%; border: 1px solid var(--line); background: var(--bg-2); border-radius: 4px; padding: 0; overflow: hidden; display: grid; text-align: left; transition: border-color .18s, box-shadow .18s, transform .18s var(--ease); }
.slot-btn .art { aspect-ratio: 280 / 300; background: radial-gradient(120% 90% at 50% 25%, var(--panel-3), var(--bg-2) 85%); overflow: hidden; position: relative; max-width: 100%; }
.slot-btn .art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; transition: transform .6s var(--ease); }
.slot-btn .art::after { content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: linear-gradient(180deg, transparent 58%, var(--bg-2) 100%); }
.slot-btn .nm { position: relative; z-index: 1; font: 600 13px/1.15 var(--display); letter-spacing: 0; padding: 0 10px 2px; margin-top: -8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slot-btn .sub { font: 400 11.5px/1.3 var(--mono); color: var(--muted); padding: 0 10px 9px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (min-width: 901px) and (max-width: 1199px) { .slot-btn .sub .lk { display: block; } .slot-btn .sub .lk-dot { display: none; } .slot-btn .sub { min-height: calc(2.6em + 15px); } }   /* 11-21: the slots are about 130 px wide here and "Lane partner · 52.1% WR" was cut mid-number: the label takes its own line and the win rate the next (the phone rule hides the label part up to 560 px; the cards are wide enough from 701 to 900 px and above 1199 px, and the min-height keeps all eight cards level) */
.slot-btn.empty {
  border-style: dashed; border-color: var(--line-2); background-color: color-mix(in srgb, var(--panel) 54%, transparent); box-shadow: none;
  background-image:
    linear-gradient(var(--slot-corner, var(--line-3)), var(--slot-corner, var(--line-3))),
    linear-gradient(var(--slot-corner, var(--line-3)), var(--slot-corner, var(--line-3))),
    linear-gradient(var(--slot-corner, var(--line-3)), var(--slot-corner, var(--line-3))),
    linear-gradient(var(--slot-corner, var(--line-3)), var(--slot-corner, var(--line-3)));
  background-size: 8px 1px, 1px 8px, 8px 1px, 1px 8px;
  background-position: 0 0, 0 0, 100% 0, 100% 0;
  background-repeat: no-repeat;
}
.side.you .slot-btn.empty { --slot-corner: color-mix(in srgb, var(--brass) 65%, transparent); border-color: color-mix(in srgb, var(--brass) 40%, var(--line-2)); }
.side.enemy .slot-btn.empty { --slot-corner: color-mix(in srgb, var(--sapphire) 65%, transparent); border-color: color-mix(in srgb, var(--sapphire) 40%, var(--line-2)); }
.slot-btn.empty .art { display: grid; place-items: center; color: var(--muted); font: 200 40px/1 var(--body); background: none; }
.slot-btn.empty .art::after { display: none; }
.slot-btn.empty .nm { margin-top: 0; padding-top: 4px; color: var(--fg-2); }
.slot-btn:hover { border-color: color-mix(in srgb, var(--brass) 60%, var(--line)); box-shadow: 0 0 0 1px color-mix(in srgb, var(--brass) 60%, transparent); }
.slot-btn:hover .art img { transform: scale(1.04); }
.slot .x { position: absolute; top: 7px; right: 7px; z-index: 2; width: 24px; height: 24px; border-radius: 50%; border: 0; background: rgba(12,10,7,.84); color: #fff; font-size: 14px; line-height: 1; display: grid; place-items: center; opacity: .85; transition: opacity .15s, background .15s; }
.slot:hover .x, .slot .x:focus-visible { opacity: 1; }
.slot .x:hover { background: var(--bad); }
.slot .lane-t { position: absolute; top: 7px; left: 7px; z-index: 2; border: 0; background: rgba(12,10,7,.84); color: #fff; border-radius: 2px; font: 600 10.5px/1 var(--body); letter-spacing: .04em; text-transform: uppercase; padding: 5px 7px; transition: background .15s; }
.slot .lane-t:hover { background: rgba(12,10,7,.96); }
.slot .lane-t[aria-pressed="true"] { background: var(--sapphire); color: #fff; }
.slot .threat-badge { position: absolute; left: 7px; bottom: 7px; z-index: 1; background: var(--bad); color: #fff; border-radius: 2px; font: 700 10px/1 var(--body); letter-spacing: .05em; padding: 5px 7px; text-transform: uppercase; }
.slot .role-tag { position: absolute; left: 7px; bottom: 7px; z-index: 1; background: rgba(12,10,7,.84); color: #fff; border-radius: 2px; font: 600 10px/1 var(--body); letter-spacing: .05em; padding: 5px 7px; text-transform: uppercase; }
.slot .dir-t { position: absolute; right: 7px; bottom: 7px; z-index: 2; border: 0; background: rgba(12,10,7,.84); color: #fff; border-radius: 2px; font: 600 10px/1 var(--body); letter-spacing: .03em; padding: 5px 6px; text-transform: uppercase; max-width: calc(100% - 14px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: background .15s; }
.slot:has(.threat-badge) .dir-t { top: 38px; bottom: auto; }
.slot .dir-t:hover { background: rgba(12,10,7,.96); }
.slot .dir-t.gun { background: var(--weapon-fill); color: #1b1305; }
.slot .dir-t.spirit { background: var(--spirit); color: #fff; }
.setup { display: inline-block; width: 46px; height: 5px; border-radius: 1px; background: var(--panel-3); overflow: hidden; vertical-align: middle; margin-right: 6px; }
.setup i { display: block; height: 100%; background: var(--brass); border-radius: 1px; }

/* ---------- match grid ---------- */
.match-grid { display: grid; grid-template-columns: minmax(0, 1fr) 390px; gap: 20px; align-items: start; }
/* phones and tablets: one column, with the shop call (golden item, buy next, spend) right under the board */
@media (max-width: 1080px) {
  .match-grid { display: flex; flex-direction: column; align-items: stretch; gap: 16px; }
  .match-grid > .stack, .match-grid .main-flow { display: contents; }
  .match-grid [data-m="top"] { order: -1; }
}

.verdict-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.verdict { position: relative; border-radius: var(--r-sm); padding: 14px 16px; background: var(--bg-2); min-width: 0; overflow: hidden; }
.verdict .who { display: flex; align-items: center; gap: 10px; }
.verdict .who img { width: 44px; height: 44px; border-radius: 3px; }
.verdict .who b { font: 600 15px/1.2 var(--display); letter-spacing: 0; }
.verdict .big { font: 600 28px/1 var(--serif); letter-spacing: 0; margin-top: 12px; }
.verdict .line { font-size: 13px; color: var(--fg-2); margin-top: 5px; }
.verdict p { margin: 10px 0 0; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--fg-2); }
.chip { display: inline-flex; align-items: center; gap: 5px; border-radius: 2px; padding: 2px 7px; font: 600 11px/1.6 var(--body); letter-spacing: .03em; text-transform: uppercase; border: 0; white-space: nowrap; }
.chip.good { background: var(--good-bg); color: var(--good); }
.chip.bad { background: var(--bad-bg); color: var(--bad); }
.chip.warn { background: var(--warn-bg); color: var(--warn); }
.chip.weapon { background: color-mix(in srgb, var(--weapon) 16%, transparent); color: var(--weapon); } .chip.spirit { background: color-mix(in srgb, var(--spirit) 16%, transparent); color: var(--spirit); }   /* "Went gun" / "Went spirit" on the threat list */
.chip.neutral { background: var(--panel-2); color: var(--fg-2); }
.chip.brass { background: color-mix(in srgb, var(--brass) 16%, transparent); color: var(--brass-2); }
.warnbar { display: flex; gap: 10px; align-items: baseline; border-radius: var(--r-sm); padding: 11px 14px; font-size: 13.5px; margin-top: 12px; }
.warnbar b { white-space: nowrap; font: 600 14px/1.3 var(--serif); }
.warnbar.bad { background: var(--bad-bg); }
.warnbar.bad b { color: var(--bad); }
.warnbar.warn { background: var(--warn-bg); }
.warnbar.warn b { color: var(--warn); }
.warnbar.good { background: var(--good-bg); }
.warnbar.good b { color: var(--good); }

/* tables */
.tbl-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.t th { text-align: left; font: 600 11px/1.3 var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 8px 9px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
table.t td { padding: 9px 9px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr { transition: background .12s; }
table.t tbody tr:hover { background: color-mix(in srgb, var(--panel-2) 65%, transparent); }
table.t td.n, table.t th.n { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; }
.thbtn { min-height: 24px; background: none; border: 0; padding: 0; font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit; cursor: pointer; }
.thbtn:hover { color: var(--fg); }
.hcell { display: flex; align-items: center; gap: 9px; min-width: 150px; }
.hcell img { width: 32px; height: 32px; border-radius: 3px; flex: none; }
.hcell b { font-weight: 600; }
.hcell .sub { display: block; font-size: 11.5px; color: var(--muted); }
.linkish { min-height: 24px; background: none; border: 0; padding: 0; color: inherit; text-align: left; }   /* 11-21: 24 px tall at least (WCAG 2.5.8); the inline variant (.linkish.inl) sets min-height 0 so it does not stretch its line of text (a target inside a sentence is exempt) */
.linkish:hover b { color: var(--brass-2); }

/* bars */
.bar { position: relative; height: 6px; border-radius: 1px; background: var(--panel-3); overflow: hidden; min-width: 60px; }
.bar i { position: absolute; top: 0; bottom: 0; border-radius: 1px; }

/* needs */
.needs { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 18px; }
.need { display: grid; grid-template-columns: 1fr auto; gap: 3px 8px; align-items: center; font-size: 13px; min-width: 0; }
.need .bar { grid-column: 1 / -1; height: 5px; }
.need .who { grid-column: 1 / -1; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* live reasons under the needs: what a teammate covers, the gaps, what the enemies bought */
.need-notes { list-style: none; margin: 12px 0 0; padding: 10px 0 0; border-top: 1px solid var(--line); display: grid; gap: 5px; font-size: 12.5px; color: var(--fg-2); }
.need-notes li { display: grid; grid-template-columns: 62px minmax(0, 1fr); gap: 8px; align-items: baseline; }
.need-notes .chip { font-size: 10.5px; padding: 1px 6px; justify-content: center; }
/* gun or spirit: one panel per build lean, the one the plan follows lit */
.lean-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.lean-row > .lean:only-child { max-width: 540px; }
.lean { position: relative; border-radius: var(--r-sm); padding: 10px 14px 10px 16px; background: var(--bg-2); min-width: 0; overflow: hidden; }
.lean::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--weapon-fill); opacity: .35; }
.lean.spirit::before { background: var(--spirit-fill); }
.lean.on { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brass) 45%, transparent); }
.lean.on::before { opacity: 1; }
.lean-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13.5px; }
.lean-wr { display: flex; align-items: baseline; gap: 8px; margin: 4px 0 2px; }
.lean-wr .big { font: 600 22px/1 var(--display); letter-spacing: 0; }
/* Simple: the gun-or-spirit strip and the threat rows stay slim so the Match page fits one screen */
:root[data-mode="simple"] .c-lean .card-b > p.muted { display: none; }
:root[data-mode="simple"] .c-lean .card-b { padding-top: 10px; padding-bottom: 12px; }
:root[data-mode="simple"] .lean { padding: 7px 12px 7px 15px; display: flex; align-items: center; flex-wrap: wrap; gap: 4px 16px; }   /* Simple: the build, its win rate and the share on one line */
:root[data-mode="simple"] .lean-row > .lean:only-child { width: max-content; max-width: 100%; }
:root[data-mode="simple"] .lean-h { font-size: 13px; }
:root[data-mode="simple"] .lean-wr { margin: 0; }
:root[data-mode="simple"] .lean-wr .big { font-size: 19px; }
:root[data-mode="simple"] .lean .line { font-size: 12px; }
:root[data-mode="simple"] .c-lane .verdict > p { display: none; }   /* the lane tips are Detailed material: Simple shows the verdict and the win rate */
:root[data-mode="simple"] .queue { gap: 2px; } :root[data-mode="simple"] .qrow { padding-block: 4px; }   /* five rows of Buy next under the golden item on one 900p screen */
:root[data-mode="simple"] .c-lane .verdict-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }   /* the two lane verdicts side by side even in a narrow column */
:root[data-mode="simple"] .c-lane .verdict .big { font-size: 24px; margin-top: 8px; }
:root[data-mode="simple"] #goldenCard .golden-body > div > p:not(.muted) { display: none; }   /* Simple: the item, its cost and whether you can afford it; the description is Detailed */
:root[data-mode="simple"] .card-h { padding: 12px 16px 8px; }
:root[data-mode="simple"] .card-b { padding: 10px 16px 14px; }
:root[data-mode="simple"] .c-lean .card-h { padding-top: 11px; }
:root[data-mode="simple"] #goldenCard .card-b, :root[data-mode="simple"] .c-queue .card-b { padding-bottom: 12px; }
:root[data-mode="simple"] #goldenCard .card-h, :root[data-mode="simple"] .c-queue .card-h { padding-top: 11px; }
:root[data-mode="simple"] #view-match > .match-grid > .rail { gap: 12px; }
:root[data-mode="simple"] .c-lane .verdict { padding: 12px 14px; }
:root[data-mode="simple"] .thr { grid-template-columns: 32px minmax(0, 1fr) auto; gap: 8px; padding: 6px 0; }
:root[data-mode="simple"] .thr-who img { width: 32px; height: 32px; border-radius: 3px; }
:root[data-mode="simple"] .thr-h { font-size: 13px; }
:root[data-mode="simple"] .thr-main { display: flex; align-items: center; flex-wrap: wrap; gap: 2px 10px; }   /* Simple: one line per enemy (name, chips, the ability), so the list reads as a list */
:root[data-mode="simple"] .thr-line { font-size: 12px; margin-top: 0; }
.lean .line { font-size: 12.5px; color: var(--fg-2); }
.lean-tag { font: 600 10px/1 var(--body); letter-spacing: .05em; text-transform: uppercase; color: var(--weapon); background: color-mix(in srgb, var(--weapon) 14%, transparent); border-radius: 2px; padding: 3px 5px; }
.lean-tag.spirit { color: var(--spirit); background: color-mix(in srgb, var(--spirit) 14%, transparent); }
.lean-tag.hybrid { color: var(--fg-2); background: var(--panel-2); }
.dmgsplit { display: flex; height: 10px; border-radius: 2px; overflow: hidden; margin: 6px 0 4px; }
.dmgsplit i { display: block; height: 100%; }

/* items: the slot colour is the tile's frame (weapon orange, vitality green, spirit violet), enameled bevel */
.itile { display: block; width: 44px; height: 44px; border-radius: var(--r); flex: none; padding: 3px; position: relative; background-color: var(--panel-3); box-shadow: inset 0 1px 0 rgba(255,255,255,.32), inset 0 -1px 0 rgba(0,0,0,.45), 0 1px 3px rgba(0,0,0,.3); }
.itile img { width: 100%; height: 100%; border-radius: var(--r-sm); object-fit: cover; }
.itile.weapon { background-color: var(--weapon-fill); }
.itile.vitality { background-color: var(--vitality-fill); }
.itile.spirit { background-color: var(--spirit-fill); }
.itile.sm { width: 34px; height: 34px; border-radius: var(--r-sm); padding: 2px; }
.itile.sm img { border-radius: 1.5px; }
.itile.lg { width: 78px; height: 78px; border-radius: 4px; padding: 4px; }
.itile.lg img { border-radius: var(--r); }
.slot-word { font: 600 10.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.slot-word.weapon { color: var(--weapon); } .slot-word.vitality { color: var(--vitality); } .slot-word.spirit { color: var(--spirit); }
.cost { font: 600 12.5px/1 var(--mono); color: var(--brass-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.cost::before { content: ""; display: inline-block; width: 11px; height: 11px; margin: 0 3px -1px 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='11' fill='%23ff8a1f' fill-opacity='.25'/%3E%3Ccircle cx='12' cy='12' r='6' fill='%23ffc55c'/%3E%3Ccircle cx='10' cy='10' r='2' fill='%23fff2c4'/%3E%3C/svg%3E") center / contain no-repeat; }   /* a soul, the game's currency, before every price (11-01) */

.golden {
  border-color: color-mix(in srgb, var(--brass) 48%, var(--line)); border-top: 2px solid var(--brass-hi);
  background-color: var(--panel);
  background-image:
    linear-gradient(var(--brass-hi), var(--brass-hi)),
    linear-gradient(var(--brass-hi), var(--brass-hi)),
    linear-gradient(var(--brass-hi), var(--brass-hi)),
    linear-gradient(var(--brass-hi), var(--brass-hi)),
    linear-gradient(135deg, color-mix(in srgb, var(--brass) 18%, var(--panel)) 0%, color-mix(in srgb, var(--brass) 6%, var(--panel)) 55%, var(--panel) 100%);
  background-size: 14px 1px, 1px 14px, 14px 1px, 1px 14px, 100% 100%;
  background-position: 0 0, 0 0, 100% 0, 100% 0, 0 0;
  background-repeat: no-repeat;
}   /* Curiosity Shop relic plaque: burnished brass corner brackets + diagonal gold wash */
.golden .card-h h3 { color: var(--brass-2); }
.golden .card-h h3::before { background: var(--brass-hi); }
.golden .itile.lg { box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--brass), inset 0 1px 0 rgba(255,255,255,.32); }
.golden-body { display: flex; gap: 16px; align-items: flex-start; }
.golden-body h4 { font: 600 21px/1.1 var(--display); letter-spacing: 0; margin: 2px 0 6px; }
.golden-body p { margin: 6px 0 0; font-size: 13.5px; color: var(--fg-2); }

.queue { display: grid; gap: 2px; }
.qrow { display: grid; grid-template-columns: 24px auto minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 7px 8px; border-radius: var(--r-sm); }
.qrow:hover { background: color-mix(in srgb, var(--panel-2) 70%, transparent); }
.qrow .rank { font: 600 13px/1 var(--mono); color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.qrow:first-child { background: color-mix(in srgb, var(--brass) 8%, transparent); border-left: 2px solid var(--brass); padding-left: 6px; }
.qrow:first-child .rank { color: var(--brass-2); }
.qrow .nm { font-weight: 600; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qrow .qmeta { display: block; font-size: 12px; color: var(--fg-2); margin-top: 1px; }
.qrow .why { font-size: 12px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 1px; }
.qrow .acts { display: flex; gap: 4px; align-items: center; }
.iconbtn { border: 1px solid var(--line); background: var(--surf-3); border-radius: var(--r-sm); height: 32px; min-width: 32px; padding: 0 9px; font-size: 12px; font-weight: 600; color: var(--fg-2); display: inline-flex; align-items: center; justify-content: center; gap: 4px; transition: color .16s var(--ease), background .16s var(--ease), border-color .16s var(--ease); }
.iconbtn:hover { color: var(--fg); background: var(--surf-4); border-color: var(--line-2); }
.trace { grid-column: 2 / -1; display: grid; grid-template-columns: 112px minmax(0, 1fr) 46px; gap: 4px 8px; align-items: center; font-size: 12px; color: var(--fg-2); padding: 6px 0 4px; }
.trace .bar { height: 5px; }
.trace .v { text-align: right; font-family: var(--mono); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.trace .note { grid-column: 1 / -1; color: var(--muted); font-size: 12px; }

.field { display: grid; gap: 6px; }
.field label { font: 600 11px/1.3 var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.inp { border: 1px solid var(--line-2); background: var(--surf-1); border-radius: var(--r-sm); padding: 7px 12px; min-height: 40px; width: 100%; min-width: 0; transition: border-color .16s var(--ease), box-shadow .16s var(--ease); }   /* 40px like .btn: a field and its button make one line */
.inp:hover { border-color: var(--line-3); }
.inp::placeholder { color: var(--muted); }
.inp:focus { border-color: var(--focus); outline: none; box-shadow: 0 0 0 1px var(--focus), 0 0 0 4px var(--glow); }
.souls-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: end; }
.quick-souls { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.quick-souls button { border: 1px solid var(--line); background: var(--surf-3); border-radius: var(--r-pill); min-height: 30px; padding: 4px 11px; font: 500 12px/1.4 var(--mono); color: var(--fg-2); font-variant-numeric: tabular-nums; transition: color .16s var(--ease), background .16s var(--ease), border-color .16s var(--ease); }
.quick-souls button:hover { background: var(--surf-4); border-color: var(--line-2); color: var(--fg); }
.spend-list { display: grid; gap: 6px; margin-top: 10px; }
.spend-item { display: flex; gap: 10px; align-items: center; }
.spend-item .nm { font-weight: 600; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spend-total { display: flex; justify-content: space-between; border-top: 1px solid var(--line-2); padding-top: 8px; margin-top: 4px; font-size: 13px; }

/* one control height: a button and a text field that share a row are both 40px; the header chrome (seg, kbd-btn) is 36px */
.btn { border: 1px solid var(--line-2); background: var(--surf-3); border-radius: var(--r-sm); padding: 8px 15px; min-height: 40px; font-weight: 600; font-size: 13.5px; color: var(--fg); display: inline-flex; gap: 8px; align-items: center; justify-content: center; transition: background .16s var(--ease), border-color .16s var(--ease), transform .12s var(--ease), box-shadow .16s var(--ease), filter .16s var(--ease); }
.btn:hover { background: var(--surf-4); border-color: var(--line-3); }
.btn:active { transform: scale(.98); }
.btn.primary, a.btn.primary { border-color: transparent; background: linear-gradient(180deg, var(--brass-hi), var(--brass)); color: var(--brass-ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.38), 0 1px 3px rgba(0,0,0,.32); }
.btn.primary:hover { filter: brightness(1.06); box-shadow: inset 0 1px 0 rgba(255,255,255,.42), 0 3px 10px -2px color-mix(in srgb, var(--brass) 40%, rgba(0,0,0,.4)); }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

.owned { display: flex; gap: 6px; flex-wrap: wrap; }
.owned button { border: 0; padding: 0; background: none; position: relative; }
.owned button svg.ti { position: absolute; top: -5px; right: -5px; width: 16px; height: 16px; padding: 3.5px; border-radius: 50%; background: var(--panel-3); stroke-width: 3; color: var(--fg-2); transition: background .15s, color .15s; }
.owned button:hover svg.ti { background: var(--bad); color: #fff; }

.log { display: grid; gap: 6px; font-size: 12.5px; max-height: 220px; overflow: auto; }
.log div { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; color: var(--fg-2); }
.log .plus { color: var(--good); font-weight: 600; } .log .minus { color: var(--bad); font-weight: 600; } .log .eq { color: var(--muted); font-weight: 600; }

.whatif-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; background: color-mix(in srgb, var(--spirit) 12%, var(--panel)); border-radius: var(--r-sm); padding: 10px 14px; margin-bottom: 16px; font-size: 13.5px; }
.whatif-bar b { font: 600 12px/1 var(--body); letter-spacing: .04em; text-transform: uppercase; color: var(--spirit); }

.pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
/* before the match: bans for the heroes you play, picks for your lane partner */
:root[data-mode="simple"] .pick-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }   /* three bans to a row in a half-width card */
.pick { display: flex; gap: 9px; align-items: center; border: 0; border-radius: var(--r-sm); padding: 7px; background: var(--bg-2); text-align: left; min-width: 0; transition: background .15s, transform .15s var(--ease), box-shadow .15s; }
.pick:hover { background: var(--panel-2); transform: translateY(-1px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brass) 45%, transparent); }
.pick img { width: 38px; height: 38px; border-radius: 3px; flex: none; }
.pick b { display: block; font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pick span { font: 500 12px/1.2 var(--mono); font-variant-numeric: tabular-nums; }

.ask-out { white-space: pre-wrap; font-size: 13.5px; color: var(--fg-2); margin-top: 10px; max-height: 340px; overflow: auto; }

/* ---------- tier list ---------- */
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.filters > .inp { min-height: 36px; padding-block: 4px; }   /* the search box is as tall as the slot seg next to it */
.fchip { border: 1px solid var(--line-2); background: var(--surf-2); border-radius: var(--r-pill); min-height: 34px; padding: 6px 14px; font-size: 13px; font-weight: 500; color: var(--fg-2); transition: color .16s var(--ease), background .16s var(--ease), border-color .16s var(--ease); }
.fchip:hover { color: var(--fg); background: var(--surf-3); border-color: var(--line-3); }
.fchip[aria-pressed="true"] { background: var(--state-brass); border-color: color-mix(in srgb, var(--brass) 60%, transparent); color: light-dark(#6f4d0c, var(--brass-2)); box-shadow: none; font-weight: 600; }
.tiers { display: grid; gap: 10px; margin-bottom: 24px; }
.tier { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: stretch; background: var(--panel); border: 1px solid var(--line); border-top-color: var(--line-3); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow-card); }
.tier .lbl { display: grid; place-items: center; font: 600 24px/1 var(--display); letter-spacing: 0; color: var(--tc); background: color-mix(in srgb, var(--tc) 14%, var(--panel)); border-right: 1px solid color-mix(in srgb, var(--tc) 18%, transparent); }
.tier .heads { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 12px 12px 2px; }
.thead { display: grid; grid-template-rows: auto 1fr auto; justify-items: center; gap: 4px; width: 66px; border: 0; background: none; padding: 0; transition: transform .18s var(--ease); }
.thead img { width: 54px; height: 54px; border-radius: 4px; transition: box-shadow .18s; }
.thead span { font-size: 11.5px; font-weight: 500; text-align: center; line-height: 1.1; max-width: 66px; white-space: normal; text-wrap: balance; overflow-wrap: anywhere; }   /* 11-21: "Deadman Danny" wraps to two lines like on the Match slot, not "Deadman D..." */
.thead em { font: normal 500 10.5px/1 var(--mono); color: var(--muted); font-variant-numeric: tabular-nums; }
.thead:hover { transform: translateY(-2px); }
.thead:hover img { box-shadow: 0 0 0 2px var(--brass); }
.t-Splus { --tc: light-dark(#7c5710, #e3b24c); } .t-S { --tc: light-dark(#8a4a0a, #d79d3e); } .t-A { --tc: light-dark(#2f6420, #7fb86a); } .t-B { --tc: light-dark(#1f5a6d, #6fa8b8); } .t-C { --tc: light-dark(#6c45a8, #a68bd6); } .t-D { --tc: light-dark(#96301e, #d68a80); }
.tierchip { display: inline-grid; place-items: center; min-width: 30px; height: 22px; border-radius: 2px; font: 600 11.5px/1 var(--display); color: var(--tc); padding: 0 6px; background: color-mix(in srgb, var(--tc) 16%, transparent); }
.dirchip { font: 600 10.5px/1 var(--body); letter-spacing: .04em; text-transform: uppercase; padding: 4px 6px; border-radius: 2px; }
.dirchip.buff { background: var(--good-bg); color: var(--good); } .dirchip.nerf { background: var(--bad-bg); color: var(--bad); } .dirchip.adjust, .dirchip.rework { background: var(--warn-bg); color: var(--warn); } .dirchip.new { background: color-mix(in srgb, var(--spirit) 18%, transparent); color: var(--spirit); } .dirchip.removed { background: var(--panel-2); color: var(--muted); }

/* ---------- shop tab ---------- */
.igrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 10px; align-items: stretch; }   /* auto-fit: a row of two cards fills the width; stretch: the cards of a row share one height, with the tags row pinned to the bottom, so the text starts at the same height in every card (Rauli, 11-01: "the text is all over the place and it isn't uniform") */
.icard { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; padding: 14px 14px 12px; border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--r); min-width: 0; box-shadow: var(--elev-1); transition: border-color .18s var(--ease), box-shadow .22s var(--ease), transform .18s var(--ease); }
.icard:hover { border-color: color-mix(in srgb, var(--brass) 45%, var(--line-2)); box-shadow: var(--elev-2); transform: translateY(-1px); }
.igrid > .icard { max-width: 660px; }   /* a lone card takes half the row, never the whole width; two share it, three or four fill it */
.ic-b { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ic-h { display: flex; align-items: baseline; gap: 8px; flex-wrap: nowrap; white-space: nowrap; min-width: 0; }   /* one line always: the chips live in the tags row since 11-01, so nothing wraps under the name */
.ic-h b { overflow: hidden; text-overflow: ellipsis; font-size: 14.5px; font-weight: 600; }
.ic-b .tags { margin-top: auto; }
.icard .one { font-size: 12.5px; color: var(--fg-2); margin-top: 3px; }
.icard .tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 7px; }
.icard .tg { font-size: 11px; font-weight: 500; padding: 2px 7px; border-radius: 2px; background: var(--panel-2); color: var(--fg-2); }
.icard .tg.hot { background: color-mix(in srgb, var(--brass) 16%, transparent); color: var(--brass-2); font-weight: 600; }
.icard .tg.auto { background: transparent; border: 1px dashed var(--line); }   /* tags read from the item stats, not yet checked by a person (11-02) */
:root[data-mode="simple"] .icard .tg.auto, :root[data-mode="simple"] .icard .tg:not(.hot) { display: none; }
.ic-more { margin-top: 6px; font-size: 12.5px; color: var(--fg-2); }
.ic-more summary { cursor: pointer; color: var(--muted); font-size: 12px; width: max-content; }
.ic-more summary:hover { color: var(--fg); }
.ic-more p { margin: 5px 0 0; }
.tierlabel { display: flex; align-items: center; gap: 10px; font: 600 12px/1.3 var(--body); letter-spacing: .04em; color: var(--muted); margin: 22px 0 10px; text-transform: uppercase; }
.tierlabel::after { content: ""; flex: 1; height: 1px; background: var(--line); }
#shopCols > .tierlabel:first-child { margin-top: 4px; }
.tierlabel .need-plan { font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--fg-2); }   /* the plan's own answer to a need, when it is not one of the cards under it */
/* no enemy team yet (11-10): the tab asks for one, with the ways to get there, instead of listing the whole shop; a search or a tag lists its matches under one line (.shop-note) that says they are not ranked */
.empty-state.shop-ask { align-items: flex-start; padding-block: 18px; max-width: 660px; }
.empty-state.shop-ask::before { top: 18px; margin-top: 0; }
.shop-ask p { margin: 0 0 12px; }
.shop-ask .btn-row { align-items: center; gap: 8px 10px; }
.shop-note { margin: 0 0 12px; font-size: 13px; color: var(--fg-2); }

/* ---------- builds ---------- */
.build-head { display: flex; gap: 16px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.build-head img { width: 64px; height: 64px; border-radius: 4px; border: 1px solid var(--line-2); box-shadow: var(--shadow-card); }
.build-head h2 { margin: 0; }
/* build planner: header, archetype chips, the step path, and the rail (next buy, skill order, swaps, final build, pace) */
.build-head .bh-t { min-width: 0; flex: 1 1 260px; }
.bh-src { font: 400 13.5px/1.35 var(--serif); color: var(--muted); margin-top: 3px; }
.bh-src.bh-name, .bh-src.bh-one { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }   /* a trusted hero's two lines: one line each, so the header keeps its height across builds */
.bh-src.bh-name { color: var(--fg-2); font-weight: 500; }
.bh-tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.bh-tools .inp { width: auto; max-width: 100%; }
.bh-tools .btn[aria-pressed="true"] { color: light-dark(#6f4d0c, var(--brass-2)); background: color-mix(in srgb, var(--brass) 16%, transparent); }
.itile.xs { width: 24px; height: 24px; border-radius: 2px; padding: 2px; }
.itile.xs img { border-radius: 2px; }
.bcards { margin-bottom: 14px; }
.bcards-h { display: flex; align-items: baseline; justify-content: space-between; gap: 6px 14px; flex-wrap: wrap; margin-bottom: 10px; }
.bcards-h h3 { font: 600 13px/1.25 var(--display); letter-spacing: .08em; text-transform: uppercase; margin: 0; }
.bcards-tools { display: flex; align-items: center; gap: 14px; font-size: 12.5px; }
.bcards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }   /* two or three cards stretch to end on the rail's right edge; the cards in a row share one height */
.bcards-solo { margin-bottom: 10px; } .bcards-none { margin: 0; font: 400 13px/1.4 var(--body); color: var(--muted); }
.bcard { position: relative; display: flex; flex-direction: column; min-width: 0; background: var(--panel); border: 1px solid var(--line); border-top-color: var(--line-3); border-radius: var(--r); box-shadow: var(--shadow-card); transition: background .15s; }
.bcard:hover:not(.inuse) { background: var(--panel-2); }
.bcard.inuse { border-color: transparent; border-top-color: var(--brass); box-shadow: inset 0 1px 0 var(--brass), var(--shadow-card); background: color-mix(in srgb, var(--brass) 5%, var(--panel)); }   /* the golden item's treatment: a 2 px gold top edge and no ring */
.bcard.data:not(.inuse) { background: var(--bg); box-shadow: none; }   /* the match-data build is not a player build: the page's own fill and a hairline, in both themes */
.bcard.data:not(.inuse):hover { background: var(--bg-2); }
.bcard.data.inuse { background: color-mix(in srgb, var(--brass) 5%, var(--bg)); }
.bc-sep { font-style: normal; }
.bcard-pick { flex: none; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 16px; min-width: 0; width: 100%; background: none; border: 0; border-radius: inherit; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.bcard-pick:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.bc-tags { display: flex; gap: 6px; align-items: center; height: 20px; }   /* a fixed row, so every card's name starts at the same height */
.bc-tags .chip, .bc-tags .lean-tag { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; font: 600 10.5px/1 var(--body); letter-spacing: .04em; border-radius: 2px; }
.bc-name { font: 600 14.5px/1.25 var(--body); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (min-width: 561px) { .bc-name { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; min-height: 2.5em; } }   /* 11-21: a long player handle gets a second line before the ellipsis (the 560 px and narrower rows stay one line); two lines kept on every card so the facts below start level */
.bc-sig { display: flex; gap: 4px; }
.bc-facts { display: grid; gap: 1px; font: 400 12.5px/1.45 var(--body); color: var(--fg-2); font-variant-numeric: tabular-nums; max-width: 100%; }
.bc-age, .bc-wr { white-space: nowrap; }
.bcard-copy { align-self: flex-start; margin: -4px 0 14px 16px; padding: 0; font-size: 12.5px; line-height: 1.3; }
.bcard-copy-ghost { visibility: hidden; }   /* holds the line on the cards not in use */
.bcards-note { font: 400 12px/1.4 var(--body); color: var(--muted); margin: 8px 0 0; }
@media (max-width: 385px) { .bh-src.bh-one { white-space: normal; min-height: calc(2em * 1.35); } .bh-src.bh-one > span { white-space: nowrap; } }   /* narrower phones (375, 360): a trusted build's stats line wraps, and both sides keep room for two lines, so switching builds moves nothing */
.btools { display: flex; gap: 10px 14px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.prefs { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; min-width: 0; }
.pchip { display: inline-flex; gap: 6px; align-items: center; border: 1px solid var(--line); background: var(--surf-3); border-radius: var(--r-pill); padding: 3px 10px 3px 4px; font-size: 12.5px; font-weight: 500; max-width: 100%; min-width: 0; transition: border-color .15s var(--ease), background .15s var(--ease); }
.pchip span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pchip.pin { background: var(--good-bg); }
.pchip.ban { background: var(--bad-bg); }
.linkish.inl { color: var(--brass-2); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, var(--brass) 45%, transparent); font: inherit; display: inline; min-height: 0; }
.linkish.inl.bcard-copy { min-height: 24px; }
.linkish.inl:hover { text-decoration-color: var(--brass-2); }
/* value tiers (docs/build-lab.md "Value tiers"): the mode bar, the tier letters and the ranking */
.vt { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; border-radius: 2px; padding: 0 5px; font: 600 11px/1 var(--mono); color: var(--brass-ink); background: var(--muted); flex: none; }
.vt-S { background: var(--brass); } .vt-A { background: var(--good); color: light-dark(#fff, var(--brass-ink)); } .vt-B { background: var(--panel-3); color: var(--fg-2); } .vt-C { background: var(--panel-2); color: var(--muted); }
.vgrid { display: grid; }
.vrow { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 12px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.vrow:last-child { border-bottom: 0; }
.vrow .vn { font-size: 14px; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.vrow .vn b { font-weight: 600; }
.vrow .vs { font-size: 12.5px; color: var(--fg-2); margin-top: 2px; }
.vrow .vr { font: 600 15px/1 var(--mono); font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.vrow .vr small { display: block; font: 400 11px/1.3 var(--mono); color: var(--muted); margin-top: 3px; }
.vc { display: flex; gap: 4px 14px; flex-wrap: wrap; }
.vc > span { display: inline-flex; gap: 6px; align-items: center; font-size: 12.5px; color: var(--fg-2); padding: 3px 0; }
.vc > span b { color: var(--fg); font-weight: 600; }
table.vprices td:first-child { font-weight: 600; white-space: nowrap; }
table.vprices td.muted { font-size: 12.5px; }
@media (max-width: 560px) { .vrow { grid-template-columns: auto minmax(0, 1fr); } .vrow .vr { grid-column: 2; text-align: left; } .vrow .vr small { display: inline; margin-left: 6px; } }
.bstart { display: flex; gap: 8px 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.have { display: flex; gap: 8px 12px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border-radius: var(--r-sm); background: var(--bg-2); margin-bottom: 12px; }
.have-items { display: flex; gap: 5px; flex-wrap: wrap; flex: 1; min-width: 0; }
.slotm { font-size: 12px; color: var(--muted); }
.have-none { font-size: 13px; margin: 0 0 12px; }
.bpath { display: grid; gap: 18px; }
.bphase-h { display: flex; gap: 10px; align-items: baseline; padding: 0 0 7px; border-bottom: 1px solid var(--line-2); margin-bottom: 2px; }
.bphase-h b { font: 600 12px/1.3 var(--body); letter-spacing: .05em; text-transform: uppercase; }
.bphase-h span { font: 400 12px/1.3 var(--mono); color: var(--muted); }
.bphase.late .bphase-h b { color: var(--muted); }
.bstep { display: grid; grid-template-columns: 24px auto minmax(0, 1fr) auto; gap: 4px 10px; align-items: start; padding: 9px 8px; border-bottom: 1px solid var(--line); border-radius: 0; }
.bstep:last-child { border-bottom: 0; }
.bnum { font: 500 13px/34px var(--mono); color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; }
.bmain { min-width: 0; }
.bact { font-size: 14px; line-height: 1.35; display: flex; gap: 4px 6px; align-items: baseline; flex-wrap: wrap; }
.bact b { font-weight: 600; }
.bact .from { color: var(--fg-2); font-size: 13px; }
.verb { font: 600 10.5px/1 var(--body); letter-spacing: .05em; text-transform: uppercase; color: var(--fg-2); background: var(--panel-2); border-radius: 2px; padding: 3px 5px; white-space: nowrap; }
.verb.up { color: var(--brass-2); background: color-mix(in srgb, var(--brass) 16%, transparent); }
.verb.sell { color: var(--warn); background: var(--warn-bg); }
.bwhy { font-size: 12.5px; color: var(--fg-2); margin-top: 2px; }
.bmeta { font: 400 11.5px/1.35 var(--mono); color: var(--muted); margin-top: 2px; }
.bmeta .due, .bside .due { color: var(--good); font-weight: 600; }
.bside { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.bside .full { font: 400 11px/1 var(--mono); color: var(--muted); }
.bsub { display: flex; gap: 8px; align-items: center; }
.balt { display: flex; gap: 3px; align-items: center; font-size: 11px; color: var(--muted); }
.balt > span:first-child { margin-right: 2px; }
.bacts { display: flex; gap: 4px; }
.bstep.is-next { background: color-mix(in srgb, var(--good) 9%, transparent); border-radius: var(--r-sm); box-shadow: inset 3px 0 0 var(--good); }
.bstep.is-counter .bnum { color: var(--brass-2); }
.bstep.k-sell .bnum { color: var(--warn); }
.bstep.k-skill { padding-block: 6px; grid-template-columns: 24px 34px minmax(0, 1fr) auto; align-items: center; }
.bstep.k-skill .bact { font-size: 12.5px; gap: 5px 10px; color: var(--fg-2); }
.akey { width: 34px; height: 22px; border-radius: 2px; display: grid; place-items: center; font: 600 10px/1 var(--body); letter-spacing: .03em; color: var(--muted); border: 1px dashed var(--line-2); }
.apt { display: inline-flex; gap: 5px; align-items: center; white-space: nowrap; }
.appath { display: inline-flex; flex-wrap: wrap; gap: 4px 7px; align-items: center; vertical-align: middle; color: var(--fg); }
.apt i, .sklegend i, .uorder i, .skgrid .sk { font: 600 10px/1 var(--body); font-style: normal; width: 18px; height: 18px; border-radius: 2px; display: inline-grid; place-items: center; background: color-mix(in srgb, var(--ac, var(--brass)) 22%, transparent); color: var(--fg); flex: none; }
.s1 { --ac: var(--brass); } .s2 { --ac: var(--spirit); } .s3 { --ac: var(--vitality); } .s4 { --ac: var(--weapon); }
.bnote { font-size: 12px; margin: 12px 0 0; }
.then { display: grid; gap: 6px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.sklegend { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 13px; }
.sklegend span { display: inline-flex; gap: 6px; align-items: center; }
.uorders { display: flex; flex-wrap: wrap; gap: 6px; }
.uorder { display: inline-flex; gap: 4px; align-items: center; border-radius: 3px; padding: 4px 8px; background: var(--bg-2); font-size: 12px; color: var(--muted); }
.uorder small { font: 500 11px/1 var(--mono); margin-left: 4px; }
.skgrid { display: grid; grid-template-columns: 20px repeat(16, minmax(0, 1fr)); gap: 2px; align-items: center; }
.skgrid b { font: 500 9.5px/1 var(--mono); color: var(--muted); text-align: center; padding-bottom: 2px; }
.skgrid b.nx { color: var(--good); font-weight: 600; }
.skgrid .sk { width: 18px; }
.skgrid i { height: 18px; border-radius: 2px; background: var(--panel-2); display: grid; place-items: center; font: 600 10.5px/1 var(--mono); font-style: normal; min-width: 0; }
.skgrid i.on { background: color-mix(in srgb, var(--ac) 50%, var(--panel)); color: var(--fg); }
.skgrid i.on.done { opacity: .45; }
.skgrid i.nx { box-shadow: inset 0 0 0 1.5px var(--good); }
.forks { margin: 0; padding-left: 18px; font-size: 12.5px; color: var(--fg-2); display: grid; gap: 3px; }
.swap { padding: 10px 0; border-bottom: 1px solid var(--line); }
.swap:first-child { padding-top: 0; }
.swap:last-of-type { border-bottom: 0; }
.swap-trig { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 12.5px; margin-bottom: 6px; }
.swap-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 13.5px; }
.fin { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.fin .itile { width: 100%; height: auto; aspect-ratio: 1; }
.pace { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 10px; align-items: center; font-size: 12px; color: var(--muted); margin-top: 10px; }
.bstats td { vertical-align: middle; }
.icell { display: flex; gap: 9px; align-items: center; min-width: 170px; }
.icell b { font-weight: 600; margin-right: 6px; }
.icell .chip { font-size: 10.5px; padding: 0 6px; }
.icell .sub { display: block; font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.iqr-c { min-width: 150px; font-size: 12px; }
.iqr { position: relative; display: block; height: 6px; border-radius: 1px; background: var(--panel-3); margin-bottom: 4px; }
.iqr i { position: absolute; top: 0; bottom: 0; border-radius: 1px; background: color-mix(in srgb, var(--brass) 40%, transparent); }
.iqr b { position: absolute; top: -2px; bottom: -2px; width: 2px; margin-left: -1px; background: var(--brass-2); border-radius: 1px; }
.pb { display: flex; gap: 4px; }
.pb .iconbtn[aria-pressed="true"][data-act="bpin"] { background: var(--good-bg); color: var(--good); }
.pb .iconbtn[aria-pressed="true"][data-act="bban"] { background: var(--bad-bg); color: var(--bad); }
.qrow.sell .nm { display: flex; gap: 6px; align-items: center; }
.qrow .verb, .spend-item .verb { font-size: 10px; padding: 2px 4px; }

/* ---------- patch ---------- */
.patch-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
@media (max-width: 900px) { .patch-grid { grid-template-columns: 1fr; } }
.wl { display: grid; gap: 10px; }
.wl-row { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; align-items: center; }
.wl-row img { width: 40px; height: 40px; border-radius: 3px; }
.wl-row b { font-weight: 600; }
.wl-row p { margin: 2px 0 0; font-size: 13px; color: var(--fg-2); }
.timeline { display: grid; gap: 0; }
.tl { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: baseline; padding: 10px 0; border-bottom: 1px solid var(--line); }
.tl:last-child { border-bottom: 0; }
.tl .d { font: 500 12px/1.3 var(--mono); color: var(--brass-2); font-variant-numeric: tabular-nums; }
.tl b { display: block; font-weight: 600; }
.tl p { margin: 2px 0 0; font-size: 13px; color: var(--fg-2); }
.changes { display: grid; gap: 6px; }
.chg { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.chg:last-child { border-bottom: 0; }
.chg img { width: 32px; height: 32px; border-radius: 3px; }
.chg .t { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.chg p { margin: 3px 0 0; font-size: 13px; color: var(--fg-2); }
.chg details { font-size: 12.5px; color: var(--fg-2); margin-top: 4px; }
.chg details summary { cursor: pointer; color: var(--muted); }
.chg details summary:hover { color: var(--fg); }
.chg ul { margin: 4px 0 0; padding-left: 18px; }
.movers { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .movers { grid-template-columns: 1fr; } }

/* ---------- matrix ---------- */
.mx-wrap { overflow: auto; max-height: 78vh; border: 1px solid var(--line); border-top-color: var(--line-3); border-radius: var(--r); background: var(--panel); box-shadow: var(--shadow-card); }
table.mx { border-collapse: separate; border-spacing: 0; font: 500 11px/1 var(--mono); font-variant-numeric: tabular-nums; }
table.mx th, table.mx td { width: 30px; min-width: 30px; height: 28px; text-align: center; padding: 0; }
table.mx thead th { position: sticky; top: 0; background: var(--panel); z-index: 2; height: 40px; border-bottom: 1px solid var(--line-2); }
table.mx thead th img { width: 26px; height: 26px; border-radius: 2px; margin: 0 auto; }
table.mx tbody th { position: sticky; left: 0; background: var(--panel); z-index: 1; text-align: left; padding: 0 8px; min-width: 132px; width: 132px; font: 500 12px/1 var(--body); white-space: nowrap; border-right: 1px solid var(--line-2); }
table.mx tbody th button { display: flex; gap: 6px; align-items: center; min-height: 24px; background: none; border: 0; padding: 0; }
table.mx tbody th button:hover { color: var(--brass-2); }
table.mx tbody th img { width: 20px; height: 20px; border-radius: 2px; }
table.mx thead th.corner { left: 0; z-index: 3; text-align: left; padding: 0 8px; font: 600 9.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
table.mx td { color: var(--fg); }
table.mx td.self { background: var(--panel-2); }
table.mx tr:hover th, table.mx tr:hover td { box-shadow: inset 0 1px 0 var(--brass), inset 0 -1px 0 var(--brass); }
.legend { display: flex; align-items: center; gap: 10px; font: 500 11.5px/1 var(--mono); color: var(--muted); flex-wrap: wrap; }
.legend .ramp { width: 180px; height: 8px; border-radius: 2px; }

/* ---------- drawer / modals ---------- */
.scrim { position: fixed; inset: 0; background: var(--scrim); z-index: 75; display: grid; }
.scrim[hidden] { display: none !important; }
.modal { background: var(--surf-2); border: 1px solid var(--line-2); border-radius: calc(var(--r) + 2px); box-shadow: var(--shadow); width: min(860px, calc(100vw - 24px)); max-height: calc(100dvh - 40px); margin: auto; display: grid; grid-template-rows: auto minmax(0, 1fr); overflow: hidden; overscroll-behavior: contain; }
.modal-h { display: flex; gap: 10px; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.modal-h h3 { font: 600 14px/1.2 var(--display); letter-spacing: .07em; text-transform: uppercase; margin: 0; }
.modal-b { overflow: auto; overscroll-behavior: contain; padding: 14px 16px 18px; }
.closebtn { margin-left: auto; display: grid; place-items: center; flex: none; border: 1px solid transparent; background: transparent; border-radius: var(--r-sm); width: 40px; height: 40px; font-size: 18px; color: var(--fg-2); transition: background .16s var(--ease), border-color .16s var(--ease), color .16s var(--ease); }
.closebtn:hover { background: var(--state-hover); border-color: var(--line-2); color: var(--fg); }
.picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pcell { border: 0; border-radius: var(--r-sm); background: var(--bg-2); padding: 7px; display: grid; gap: 5px; justify-items: center; transition: background .15s, transform .15s var(--ease), box-shadow .15s; }
.pcell img { width: 64px; height: 64px; border-radius: 4px; }
.pcell span { font-size: 12px; font-weight: 500; text-align: center; line-height: 1.15; }
.pcell em { font: normal 500 10.5px/1 var(--mono); font-variant-numeric: tabular-nums; }
.pcell:hover, .pcell.kb { background: var(--panel-2); transform: translateY(-1px); box-shadow: 0 0 0 2px var(--brass); }
.pcell[disabled] { opacity: .35; cursor: not-allowed; transform: none; box-shadow: none; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); background: var(--surf-2); border-left: 1px solid var(--line-2); box-shadow: var(--shadow); z-index: 70; display: grid; grid-template-rows: auto minmax(0, 1fr); overscroll-behavior: contain; }
.drawer[hidden] { display: none !important; }
.drawer-b { overflow: auto; overscroll-behavior: contain; padding: 0 20px 30px; }
.intel-hero { position: relative; display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 16px; padding: 18px 0; align-items: end; }
.intel-hero::before { content: ""; position: absolute; inset: 0 -20px; z-index: -1; background: radial-gradient(400px 180px at 0% 100%, var(--glow), transparent 70%); pointer-events: none; }
.intel-hero img { width: 150px; border-radius: 4px; aspect-ratio: 280/380; object-fit: cover; border: 1px solid var(--line-2); background: radial-gradient(120% 90% at 50% 25%, var(--panel-3), var(--bg-2) 85%); box-shadow: var(--shadow-card); }
.intel-hero h2 { font: 600 26px/1.1 var(--display); letter-spacing: 0; margin: 0 0 6px; }
.statline { display: flex; gap: 16px; flex-wrap: wrap; font: 600 11px/1.3 var(--body); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin-top: 10px; }
.statline b { display: block; font: 600 17px/1.1 var(--mono); letter-spacing: 0; text-transform: none; color: var(--fg); margin-bottom: 2px; font-variant-numeric: tabular-nums; }
.intel-sec { border-top: 1px solid var(--line); padding: 14px 0; }
.intel-sec h4 { font: 600 12px/1.3 var(--body); letter-spacing: .05em; text-transform: uppercase; margin: 0 0 10px; color: var(--muted); }
.abil { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 8px; align-items: baseline; padding: 6px 0; }
.abil .k { font: 600 13px/1.2 var(--mono); color: var(--brass-2); }
.abil b { font-weight: 600; }
.abil p { margin: 2px 0 0; font-size: 13px; color: var(--fg-2); }
.ratings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 18px; }
.rt { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 8px; align-items: center; font-size: 12.5px; color: var(--fg-2); }
.pips { display: flex; gap: 3px; }
.pips i { flex: 1; height: 6px; border-radius: 1px; background: var(--panel-3); }
.pips i.on { background: var(--brass); }
.mini-list { display: grid; gap: 5px; }
.mini { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; align-items: center; font-size: 13px; }
.mini img { width: 28px; height: 28px; border-radius: 2px; }
.spark { width: 100%; height: 70px; display: block; }
.palette-list { display: grid; gap: 2px; }
.prow { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 7px 9px; border-radius: 3px; border: 0; background: none; text-align: left; width: 100%; }
.prow img { width: 30px; height: 30px; border-radius: 2px; }
.prow .ph { width: 30px; height: 30px; border-radius: 2px; background: var(--panel-2); display: grid; place-items: center; font: 600 12px/1 var(--body); color: var(--brass-2); }
.prow small { color: var(--muted); font-size: 12px; }
.prow b { font-weight: 600; }
.prow.kb, .prow:hover { background: var(--panel-2); }
.prow.kb { box-shadow: inset 2px 0 0 var(--brass); }

/* respawn mode */
.respawn { position: fixed; inset: 0; z-index: 80; background: var(--bg); display: grid; grid-template-rows: auto minmax(0, 1fr); padding: max(16px, env(safe-area-inset-top)) 24px 24px; }
.respawn[hidden] { display: none !important; }
.respawn-h { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.respawn-h h2 { font: 700 32px/1.05 var(--pulp); text-transform: uppercase; margin: 0; letter-spacing: 0; }
.clock { width: 68px; height: 68px; position: relative; }
.clock svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.clock b { position: absolute; inset: 0; display: grid; place-items: center; font: 600 20px/1 var(--mono); font-variant-numeric: tabular-nums; }
.respawn-b { overflow: auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; align-content: start; padding-top: 20px; }
.rcard { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: center; border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--r); padding: 16px; box-shadow: var(--elev-1); }
.rcard .nm { font: 600 18px/1.15 var(--display); letter-spacing: 0; }
.rcard .r { font-size: 13.5px; color: var(--fg-2); margin-top: 4px; }

.toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 90; background: var(--fg); color: var(--bg); border: 1px solid color-mix(in srgb, var(--bg) 18%, transparent); border-radius: var(--r); padding: 11px 20px; font-weight: 600; font-size: 13.5px; box-shadow: var(--shadow); width: max-content; max-width: calc(100vw - 32px); text-align: center; opacity: 0; pointer-events: none; transition: opacity .15s; }   /* 11-21: always in the page, so a screen reader hears it when its text changes; .show fades it in (display:none or visibility:hidden would keep the text from being announced) */
.toast.show { opacity: 1; }   /* 11-21: toast() in app.js adds .show; the region is never display:none, so its text is announced */
.ph-hero { width: 40px; height: 40px; border-radius: 3px; background: var(--panel-2); display: grid; place-items: center; font: 600 14px/1 var(--body); color: var(--brass-2); }
.respawn-souls { display: flex; gap: 8px; align-items: center; }
.respawn-souls .inp { width: 130px; font-size: 18px; }
#paletteScrim .modal { max-height: calc(100dvh - min(10vh, 60px) - 24px); }
/* See all ranked builds (Build lab) */
.rank-modal { width: min(1180px, calc(100vw - 24px)); }
.rank-modal:focus { outline: none; }
.rank-modal .modal-h > div { flex: 1 1 260px; min-width: 0; }
.rank-sub { margin: 4px 0 0; font-size: 12.5px; color: var(--muted); }
.rank-how { margin: 0 0 14px; max-width: 92ch; font-size: 13px; line-height: 1.5; color: var(--fg-2); }
.rank-how p { margin: 0; }
.rank-more { margin-top: 2px; }
.rank-more > summary { display: inline-block; cursor: pointer; color: var(--brass-2); font-size: 12.5px; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, var(--brass) 45%, transparent); }
.rank-more[open] > summary { margin-bottom: 4px; }
.rank-more[open] > p { color: var(--fg-2); }
.rank-t { display: grid; grid-template-columns: 40px minmax(0, 1fr) 132px 64px 72px 70px 84px 100px 164px; }
.rank-t.rank-all { grid-template-columns: 36px minmax(0, 1fr) 112px 58px 64px 62px 76px 92px 168px; }   /* All heroes: the idle status column gives its width to the name */   /* one grid for the whole table: the name takes what the other columns leave */
.rank-t thead, .rank-t tbody, .rank-t tr { display: contents; }
.rank-t th { position: sticky; top: 0; z-index: 2; background: var(--panel); display: flex; align-items: flex-end; min-width: 0; }
.rank-t th.n { justify-content: flex-end; }
.rank-t td { display: flex; align-items: center; min-width: 0; }
.rank-t td.n { justify-content: flex-end; font-weight: 400; }
.rank-t td.rk-n { color: var(--muted); }
.rank-t td.rk-a, .rank-t td.rk-u { color: var(--fg-2); font-size: 12.5px; }
.rk-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-t td.rank-score { color: var(--brass-2); font-weight: 700; }
.rank-t tr.rank-card > td:first-child { box-shadow: inset 2px 0 0 var(--brass); }
.rank-t tr.rank-card { cursor: pointer; }
.rank-t tbody tr:hover > td { background: color-mix(in srgb, var(--panel-2) 65%, transparent); }
.rank-t td.rk-m { display: none; }
.rank-pick { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; }
button.rank-pick { cursor: pointer; }
.rank-tiles { display: inline-flex; justify-content: flex-start; gap: 3px; flex: none; width: 78px; }   /* three tiles wide, so a row with fewer icons keeps the names lined up */

.rank-bn { display: grid; min-width: 0; }
.rank-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-bn small { font-size: 11.5px; color: var(--muted); }
.rank-hero { width: 28px; height: 28px; border-radius: 3px; flex: none; }
.rank-pick .chip { flex: none; }
.rank-st { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; min-width: 0; font-size: 12.5px; color: var(--fg-2); }
.rank-copy { font-size: 12px; }
.rk-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.rank-out { margin-top: 18px; }
.rank-out > summary { cursor: pointer; padding: 6px 0; font: 600 11px/1.3 var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.rank-out > summary:hover { color: var(--fg); }
.rank-out td:not(.rk-s) { opacity: .6; }   /* left-out rows dim every cell evenly; only the reason keeps full ink */
.rank-out td.rk-s { color: var(--fg-2); }
@media (max-width: 640px) {
  .rank-modal { width: 100vw; max-height: 100dvh; height: 100dvh; border-radius: 0; border-width: 0; }
}
/* 11-21: the card layout starts at 1000 px, not 640: the table's fixed columns need about 730 px, so between 641 and about 1000 px the Build column had no width and the icon tiles lay over the Author text */
@media (max-width: 1000px) {
  .rank-t, .rank-t tbody { display: block; }
  .rank-t thead { display: none; }
  .rank-t tr { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; grid-template-areas: "n b sc" "n m m" "n st st"; column-gap: 8px; row-gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .rank-t tr:last-child { border-bottom: 0; }
  table.rank-t td { display: block; padding: 0; border: 0; }
  table.rank-t td.rk-n { grid-area: n; padding-left: 8px; } table.rank-t td.rk-b { grid-area: b; } table.rank-t td.rank-score { grid-area: sc; font-size: 20px; line-height: 1.1; text-align: right; }
  table.rank-t td.rk-m { grid-area: m; display: block; color: var(--muted); font-size: 12.5px; } table.rank-t td.rk-s { grid-area: st; justify-self: start; }   /* the status takes its own line, so a long one ("Same core items as ...") never widens the score column */
  table.rank-t td.rk-a, table.rank-t td.rk-g, table.rank-t td.rk-p, table.rank-t td.rk-w, table.rank-t td.rk-u { display: none; }
  .rank-t tbody tr:hover > td { background: none; }
  .rank-hero { width: 24px; height: 24px; }
  .rank-pick { align-items: flex-start; } .rank-name { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } .rank-tiles { padding-top: 1px; }
  .rank-st { justify-content: flex-start; margin-top: 4px; }
}
.foot { position: relative; color: var(--muted); font-size: 12.5px; padding-block: 30px 36px; display: grid; gap: 7px; margin-top: 10px; border-top: 1px solid var(--line); }
.foot a { color: var(--fg-2); text-decoration-color: var(--line-3); text-underline-offset: 3px; padding-block: 5px; }   /* the padding makes each link a 24 px tall target without moving the text */
.foot-more summary { cursor: pointer; color: var(--fg-2); width: max-content; list-style: none; padding-block: 4px; }
.foot-more summary::-webkit-details-marker { display: none; }
.foot-more summary::after { content: " ▸"; color: var(--muted); }
.foot-more[open] summary::after { content: " ▾"; }
.foot-more summary:hover { color: var(--fg); }
.foot-more-b { display: grid; gap: 7px; margin-top: 8px; }
.foot a:hover { color: var(--brass-2); }
.foot b { color: var(--fg-2); font-weight: 600; }

/* ---------- live tab: status strip, roster board, build reads, alerts (markup from live.js) ---------- */
.live-strip { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; }
.live-acct { display: flex; align-items: center; gap: 8px; min-width: 0; }
.live-acct img, .live-acct .ph { width: 28px; height: 28px; border-radius: 3px; flex: none; background: var(--panel-2); object-fit: cover; }
.live-acct .ph { display: grid; place-items: center; color: var(--muted); font: 600 11px/1 var(--body); }
.live-acct b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 180px; font-weight: 600; }
.live-state { flex: 1 1 320px; min-width: 0; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13.5px; color: var(--fg-2); }
.live-state .pill { background: var(--surf-3); border-radius: var(--r-pill); padding: 5px 12px; white-space: nowrap; font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.live-state .pill.live { color: var(--good); background: var(--good-bg); }
.live-state .pill.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 0 color-mix(in srgb, var(--good) 60%, transparent); animation: pulse 1.8s ease-out infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--good) 55%, transparent); } 100% { box-shadow: 0 0 0 7px transparent; } }
.live-mid { display: inline-flex; gap: 6px; align-items: center; }
.live-mid .inp { width: 130px; font-size: 14px; }
.live-ctl { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
/* live win chance from the souls lead: the number, the lead and the match so far */
.live-wc { display: inline-flex; align-items: center; gap: 8px; padding: 5px 11px; border-radius: var(--r-sm); background: var(--bg-2); white-space: nowrap; }
.live-wc .wc-h { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.live-wc .wc-p { font: 600 17px/1 var(--serif); font-variant-numeric: tabular-nums; letter-spacing: 0; }
.live-wc.up .wc-p { color: var(--good); } .live-wc.down .wc-p { color: var(--bad); }
.live-wc .wc-l { font-size: 12px; color: var(--fg-2); font-variant-numeric: tabular-nums; }
.live-wc .wc-spark { display: block; overflow: visible; }
.live-wc .wc-spark polyline { fill: none; stroke: var(--brass); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.live-wc .wc-spark .wc-mid { stroke: var(--line-3); stroke-width: 1; stroke-dasharray: 2 3; }
.live-lane { margin: 12px 0 2px; }
.team-split { font-size: 12.5px; color: var(--fg-2); margin: -2px 0 6px; }
.team-split .dmgsplit { height: 8px; margin: 5px 0 0; }
.rbar { display: inline-flex; flex-direction: column; gap: 3px; width: 112px; }
.rbar .dmgsplit { height: 5px; margin: 0; border-radius: 1px; }
.rbar .rl { font: 500 11px/1 var(--mono); color: var(--fg-2); white-space: nowrap; }
.rbar.kit { opacity: .5; }
.live-set summary { cursor: pointer; font-size: 13px; color: var(--muted); width: max-content; }
.live-set summary:hover { color: var(--fg); }
.live-set-b { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; margin-top: 10px; }
.lrow { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 6px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); min-width: 0; }
.lrow img.hero { width: 36px; height: 36px; border-radius: 3px; background: var(--panel-2); }
.lrow .who { min-width: 0; font-size: 13.5px; }
.lrow .who b { font-weight: 600; }
.lrow .who .muted { font-size: 12px; margin-left: 6px; }
.lrow .meta { font-size: 11.5px; color: var(--muted); }
.lrow .chips { display: flex; gap: 5px; flex-wrap: wrap; justify-content: flex-end; align-items: center; }
.lrow .items { grid-column: 2 / -1; display: flex; gap: 4px; flex-wrap: wrap; align-items: center; font-size: 12px; min-height: 20px; }
.lrow.dead { opacity: .55; }
.dirb.gun { background: var(--weapon-fill); color: #1b1305; }
.thrb { margin-left: 6px; }
.thrb.on { background: var(--bad); color: #fff; }
.thr-note { margin: 10px 0 0; font-size: 13px; }
.dirb.spirit { background: var(--spirit); color: #fff; }
.alerts { display: grid; gap: 6px; font-size: 12.5px; max-height: 320px; overflow: auto; }
.alerts > div { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 8px; align-items: baseline; color: var(--fg-2); }
.alerts .mono { font-size: 11.5px; }
.alerts .chip { font-size: 10.5px; padding: 1px 7px; }
@media (max-width: 560px) {
  .live-state { flex-basis: 100%; }
  .live-mid { width: 100%; }
  .live-mid .inp { flex: 1; width: auto; min-width: 0; }
  .lrow { grid-template-columns: 32px minmax(0, 1fr); }
  .lrow img.hero { width: 32px; height: 32px; }
  .lrow .chips { grid-column: 1 / -1; justify-content: flex-start; }
}
/* ---------- coach ---------- */
#view-coach > h2.sec { margin-bottom: 16px; }   /* air between the title and the first card */
.co-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin: 0 0 18px; }   /* a long command line scrolls, it never widens the page */
.co-who { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.co-who img { border-radius: 3px; }
.co-name { font: 600 16px/1.2 var(--display); letter-spacing: 0; }
.co-sub { margin: 6px 0 0; font-size: 13px; color: var(--fg-2); }
.co-heroes { display: flex; flex-wrap: wrap; gap: 8px; padding-bottom: 4px; }
.co-hc { display: flex; gap: 8px; align-items: center; border: 1px solid var(--line); background: var(--panel); border-radius: var(--r-sm); padding: 5px 10px 5px 5px; flex: none; text-align: left; transition: border-color .15s, background .15s; }
.co-hc img { border-radius: 2px; }
.co-hc b { display: block; font: 600 12px/1.15 var(--display); }
.co-hc small { display: block; font-size: 11.5px; color: var(--muted); }
.co-hc[aria-pressed="true"] { border-color: var(--brass); background: color-mix(in srgb, var(--brass) 10%, var(--panel)); box-shadow: inset 0 0 0 1px var(--brass); }
.co-hc:hover { border-color: var(--line-3); }
.co-all { width: 28px; height: 28px; border-radius: 2px; display: grid; place-items: center; background: var(--panel-2); font: 600 11px/1 var(--body); color: var(--brass-2); }
.co-prog { position: relative; border-radius: 3px; padding: 8px 11px; font-size: 13px; color: var(--fg-2); overflow: hidden; background: var(--panel-2); }
.co-prog i { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--brass); transition: width .3s ease; }
.co-err { color: var(--bad); margin: 8px 0 0; }
.co-h3 { font: 600 14px/1.2 var(--display); letter-spacing: 0; margin: 6px 0 0; }
.co-strip { display: flex; gap: 4px; margin: 0 0 16px; overflow-x: auto; padding-bottom: 2px; }
.co-g { position: relative; width: 38px; flex: none; border: 0; padding: 0 0 4px; background: none; display: grid; gap: 3px; justify-items: center; transition: transform .15s var(--ease); }
.co-g:hover { transform: translateY(-2px); }
.co-g img { width: 34px; height: 34px; border-radius: 3px; }
.co-g span { font: 600 10px/1 var(--body); }
.co-g.w span { color: var(--good); } .co-g.l span { color: var(--bad); }
.co-g::after { content: ""; position: absolute; left: 3px; right: 3px; bottom: 0; height: 3px; border-radius: 1px; }
.co-g.w::after { background: var(--good); } .co-g.l::after { background: var(--bad); }
.co-cols { margin-top: 4px; }
.co-focus h4 { font: 600 22px/1.2 var(--serif); letter-spacing: 0; margin: 6px 0 0; text-wrap: balance; }
.co-tip .co-tip-h { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.co-tip h3 { font: 600 14.5px/1.2 var(--display); letter-spacing: 0; margin: 0; flex: 1 1 200px; }
.co-n { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--panel-2); font: 600 12px/1 var(--mono); color: var(--brass-2); flex: none; }
.co-ev { margin: 10px 0 0; color: var(--fg); }
.co-act { margin: 8px 0 0; color: var(--fg-2); }
.co-foot, .co-note { font-size: 12.5px; margin-top: 10px; }
.co-list { display: grid; gap: 8px; }
.co-pbs { display: grid; gap: 14px; }
.co-rc-meta, .co-focus-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.co-gbadge { min-width: 26px; height: 22px; font-weight: 700; font-size: 12px; letter-spacing: .02em; }
.co-gstat { font-size: 11.5px; font-weight: 600; }
.co-gstat.good { color: var(--good); } .co-gstat.neutral { color: var(--fg-2); } .co-gstat.bad { color: var(--bad); }
.co-pb { display: grid; gap: 5px; outline-offset: 4px; }
.co-pb-h { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 600; }
.co-pb-l { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.co-pb-r { display: inline-flex; align-items: baseline; gap: 6px; flex: none; font-size: 12.5px; }
.co-pb-t { position: relative; height: 8px; border-radius: 2px; background: var(--panel-3); }
.co-pb-t i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 2px; }
.co-pb-t s { position: absolute; top: -3px; bottom: -3px; width: 1px; background: var(--line-3); text-decoration: none; }
.co-pb-f { display: flex; justify-content: space-between; gap: 10px; font-size: 11.5px; flex-wrap: wrap; }
.co-why { font-size: 12px; margin-top: -9px; }
.co-more { margin-top: 14px; }
.co-more summary { cursor: pointer; font-weight: 600; font-size: 13.5px; color: var(--fg-2); }
.co-more summary:hover { color: var(--fg); }
.co-more .co-pbs { margin-top: 12px; }
.co-leg { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--fg-2); margin: 2px 0 8px; }
.co-leg span { display: inline-flex; gap: 6px; align-items: center; }
.co-leg i { width: 12px; height: 3px; border-radius: 1px; display: inline-block; }
.co-leg i.ln { width: 2px; height: 12px; background: var(--fg-2); }
.co-chart { position: relative; }
.co-chart svg, .co-map svg { width: 100%; height: auto; display: block; overflow: visible; }
.co-grid { stroke: var(--line); stroke-width: 1; }
.co-base { stroke: var(--muted); stroke-width: 1.5; }
.co-band { fill: color-mix(in srgb, var(--brass) 12%, transparent); }
.co-ax { fill: var(--muted); font: 500 11px var(--mono); }
.co-axn { font-size: 11px; text-align: center; margin-top: -2px; }
.co-xh { stroke: var(--fg-2); stroke-width: 1; }
.co-death { fill: none; pointer-events: bounding-box; stroke: var(--bad); stroke-width: 2.2; stroke-linecap: round; transform-box: fill-box; transform-origin: center; }   /* a drawn x: VALVE Oracle draws the × character as a dot */
.co-map { max-width: 360px; margin: 14px auto 0; }
.co-dphs { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.co-dph { display: grid; gap: 5px; }
.co-dph-h { display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; }
.co-dbar { display: flex; align-items: center; gap: 8px; }
.co-dtrack { flex: 1; min-width: 0; }
.co-dbar i { display: block; height: 10px; border-radius: 0 4px 4px 0; min-width: 2px; }
.co-dbar i.you { background: var(--co-you); } .co-dbar i.peer { background: var(--co-peer); }
.co-tl { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; margin-top: 16px; height: 110px; }
.co-tlc { display: grid; grid-template-rows: minmax(0, 1fr) auto; gap: 4px; min-width: 0; outline-offset: 2px; }
.co-tlb { display: flex; align-items: flex-end; justify-content: center; gap: 2px; border-bottom: 1px solid var(--line-2); }
.co-tlb i { width: min(12px, 40%); border-radius: 2px 2px 0 0; min-height: 1px; }
.co-tlb i.you { background: var(--co-you); } .co-tlb i.peer { background: var(--co-peer); }
.co-tlc span { font: 500 10.5px var(--mono); color: var(--muted); text-align: center; white-space: nowrap; overflow: hidden; }
.co-ctr { margin-top: 8px; font-size: 13px; }
.co-ctr td { vertical-align: top; }
.co-ctr .itile { display: inline-block; vertical-align: middle; margin-right: 4px; }
.co-dbar b { font-size: 12px; }
.co-lane { position: relative; display: flex; gap: 2px; height: 120px; border-bottom: 0; }
.co-lane::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--line-2); }
.co-lc { position: relative; flex: 1 1 0; max-width: 24px; border: 0; background: transparent; padding: 0; }
.co-lc i { position: absolute; left: 2px; right: 2px; }
.co-lc i.up { background: var(--good); border-radius: 2px 2px 0 0; } .co-lc i.dn { background: var(--bad); border-radius: 0 0 2px 2px; }
.co-lc:hover i, .co-lc:focus-visible i { filter: brightness(1.2); }
.co-kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; margin-top: 12px; }
.co-kv div { display: grid; gap: 2px; font-size: 12px; }
.co-kv b { font: 600 16px/1 var(--display); letter-spacing: 0; font-variant-numeric: tabular-nums; }
.co-spk { position: relative; height: 54px; margin: 6px 6px 20px; border-bottom: 1px solid var(--line); }
.co-sd { position: absolute; bottom: 10px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--co-you); box-shadow: 0 0 0 2px var(--panel); }
.co-sd.died { background: var(--bad); }
.co-sd:nth-child(3n) { bottom: 24px; } .co-sd:nth-child(3n+1) { bottom: 38px; }
.co-spk > s { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--fg-2); text-decoration: none; }
.co-spk-ax { position: absolute; left: 0; right: 0; top: 100%; height: 16px; }
.co-spk-ax span { position: absolute; transform: translateX(-50%); font: 500 11px var(--mono); color: var(--muted); padding-top: 3px; }
.co-games { display: grid; gap: 6px; }
.co-gr { display: grid; grid-template-columns: 28px auto auto minmax(0, 1fr); gap: 10px; align-items: center; border: 0; background: var(--bg-2); border-radius: 3px; padding: 7px 9px; text-align: left; font-size: 13px; transition: background .15s; }
.co-gr img { border-radius: 2px; }
.co-gr:hover { background: var(--panel-2); }
.co-gw { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; }
.co-match { margin-bottom: 16px; border-color: color-mix(in srgb, var(--brass) 40%, var(--line)); }
.co-three { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 6px; }
.co-tgt { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.co-tgt select { width: auto; padding: 6px 8px; }
.co-target { border-color: color-mix(in srgb, var(--co-up) 40%, var(--line)); background: linear-gradient(180deg, color-mix(in srgb, var(--co-up) 7%, var(--panel)), var(--panel)); }
.co-trows { display: grid; gap: 14px; margin-top: 12px; }
.co-trow { display: grid; gap: 5px; }
.co-trow-h { display: flex; justify-content: space-between; gap: 10px; align-items: center; font-size: 13.5px; }
.co-trow-v { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--fg-2); }
.co-trow-v b { color: var(--fg); font-weight: 600; }
.co-worth { margin-left: auto; color: var(--bad); font-weight: 600; }
@media (max-width: 560px) { .co-who .btn-row { margin-left: 0 !important; width: 100%; } .co-tgt { flex: 1 1 auto; min-width: 0; flex-wrap: wrap; } .co-tgt select { flex: 1 1 auto; max-width: 100%; } }   /* the rank list drops under its label before it would widen the page */
.co-miss { border-color: color-mix(in srgb, var(--warn) 40%, var(--line)); background: linear-gradient(180deg, var(--warn-bg), var(--panel)); }
.co-miss p, .co-head .co-more p { margin: 8px 0 0; font-size: 13.5px; color: var(--fg-2); }
.co-miss a, .co-head .co-more a { color: var(--brass-2); }
.co-cmd { display: flex; gap: 8px; align-items: center; margin-top: 10px; }
.co-dlrow { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.co-dlrow .muted { flex: 1 1 220px; font-size: 12.5px; }
.co-dl { margin: 8px 0 0; padding-left: 18px; font-size: 13px; color: var(--fg-2); }
.co-cmd code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; font: 500 12px/1.5 var(--code); background: var(--surf-1); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 10px 12px; }   /* 40px, the Copy button beside it */
.co-tipbox { position: fixed; z-index: 60; display: none; max-width: 300px; background: var(--panel-2); color: var(--fg); border: 1px solid var(--line-2); border-radius: 3px; padding: 7px 10px; font-size: 12.5px; box-shadow: var(--shadow); pointer-events: none; }
@media (max-width: 560px) {
  .co-chart .co-ax { font-size: 22px; } .co-chart .co-death { transform: scale(1.85); }   /* the 640-unit charts render at about half size on a phone */
  .co-tlc span { font-size: 9px; }
  .co-gr { grid-template-columns: 28px auto minmax(0, 1fr); }
  .co-gr .co-gw { grid-column: 1 / -1; white-space: normal; }
  .co-focus h4 { font-size: 19px; }
}

/* ---------- motion: M3 Expressive emphasized curves inside reduced-motion guard ---------- */
@media (prefers-reduced-motion: no-preference) {
  .qrow, .verdict, .icard { transition: background-color .16s var(--ease), border-color .16s var(--ease), box-shadow .2s var(--ease), transform .18s var(--ease); }
  .view { animation: rise .28s var(--ease-emph) both; }
  @keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
  .scrim:not([hidden]) .modal { animation: pop .24s var(--ease-emph) both; }
  @keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
  .drawer:not([hidden]) { animation: slidein .28s var(--ease-emph) both; }
  @keyframes slidein { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: none; } }
  .toast.show { animation: toastin .26s var(--ease-spring) backwards; }
  @keyframes toastin { from { transform: translate(-50%, 8px); } }   /* 11-21: only the slide; opacity is the transition, so the toast also fades out */
  /* 11-13: after one of your clicks the cards it changed settle in (fxPaint in app.js), and a new golden item sweeps its brass top edge once */
  .fx-settle { animation: fx-settle .22s var(--ease-emph) both; }
  @keyframes fx-settle { from { opacity: .4; transform: translateY(4px); } to { opacity: 1; transform: none; } }
  #goldenCard.fx-sweep::after { content: ''; position: absolute; left: -1px; right: -1px; top: -2px; height: 2px; border-radius: var(--r) var(--r) 0 0; background: var(--brass-2); transform-origin: left center; animation: fx-sweep .52s var(--ease-emph) both; pointer-events: none; }
  @keyframes fx-sweep { 0% { transform: scaleX(0); opacity: 1; } 60% { transform: scaleX(1); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }
}
@media (prefers-reduced-motion: reduce) {
  .live-state .pill.live::before, .live-state .pill.wait::before { animation: none; }
  .slot-btn .art img, .thead, .pick, .pcell, .btn, .way, .icard, .bcard, .tabs a, .seg button { transition: none; }
}

/* ---------- small screens ---------- */
@media (max-width: 760px) { .brand small { display: none; } }
@media (max-width: 560px) {
  .top { position: relative; }
  .top-row { padding-block: 8px 6px; gap: 6px 10px; flex-wrap: nowrap; align-items: center; }
  .brand { gap: 6px; flex: 0 1 auto; min-width: 0; }
  .brand b { font-size: 16.5px; letter-spacing: .02em; }
  .brand .sigil { width: 24px; height: 24px; }
  .top-tools { gap: 5px; width: auto; flex-wrap: nowrap; }
  .top-tools .seg { min-height: 36px; }
  .top-tools .seg button { padding: 5px 9px; font-size: 12px; }
  #openPalette kbd { display: none; }
  .kbd-btn { padding: 6px 10px; gap: 5px; min-height: 36px; font-size: 12px; }
  .kbd-btn svg.ti { width: 14px; height: 14px; }
  .kbd-btn.get-app { display: none; }
  #openPalette, #settingsMenu > summary { width: 38px; height: 38px; min-height: 38px; padding: 0; gap: 0; font-size: 0; justify-content: center; border: 1px solid var(--line-2); }
  #openPalette svg.ti, #settingsMenu > summary svg.ti { width: 16px; height: 16px; }
  .top-tools .menu { margin-left: 0; }
  .menu-b { border-top: 2px solid var(--brass); }
  .tabs { margin-left: 0; padding: 6px 0 8px; border-top: 1px solid var(--line); }
  .tabs a { min-height: 34px; padding: 7px 10px; border-radius: var(--r-sm); font-size: 11.5px; letter-spacing: .06em; background: color-mix(in srgb, var(--panel) 72%, transparent); border: 1px solid var(--line); }   /* a step under the desktop 12.5px, as before the caps */
  .tabs a[aria-current="page"] { border-color: color-mix(in srgb, var(--brass) 55%, var(--line)); background: linear-gradient(180deg, color-mix(in srgb, var(--brass) 8%, var(--panel)), color-mix(in srgb, var(--brass) 18%, var(--panel))); box-shadow: inset 0 -2px 0 var(--brass); }
  h2.sec { font-size: 22px; }
  .lede { font-size: 14.5px; }
  .card-h { padding: 11px 14px 8px; } .card-b { padding: 12px 14px 14px; }
  .side { padding: 14px 16px 16px; }
  .landing { padding: 10px 0 12px; gap: 8px; }
  .landing h1 { font-size: 27px; }
  .landing p { font-size: 14px; }
  .landing .steps { gap: 8px 14px; font-size: 13px; margin-top: 2px; }
  .landing .steps .linkish { padding: 5px 10px; border-radius: var(--r-sm); background: color-mix(in srgb, var(--brass) 14%, transparent); border: 1px solid color-mix(in srgb, var(--brass) 45%, transparent); font-weight: 600; }
  .ways { gap: 10px; margin: 14px 0 6px; }
  .way { padding: 12px 14px; gap: 12px; }
  .verdict .big { font-size: 26px; }
  :root[data-mode="simple"] .c-lane .verdict-row { grid-template-columns: 1fr; }
  .golden-body { gap: 12px; } .golden .itile.lg { width: 64px; height: 64px; } .golden-body h4 { font-size: 19px; }
  .qrow { grid-template-columns: 18px auto minmax(0, 1fr) auto; gap: 7px; padding: 7px 6px; }
  .qrow .itile { width: 38px; height: 38px; } .qrow .acts { gap: 3px; } .qrow .iconbtn { min-height: 34px; min-width: 34px; height: auto; padding: 0 8px; font-size: 11.5px; }
  .thr { grid-template-columns: 36px minmax(0, 1fr); gap: 6px 10px; align-items: start; }
  .thr-who img { width: 36px; height: 36px; }
  .thr-act { grid-column: 2; justify-self: start; margin-top: 2px; }
  :root[data-mode="simple"] .thr { grid-template-columns: 32px minmax(0, 1fr); align-items: center; }
  .pick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .pick { padding: 6px; gap: 7px; } .pick img { width: 32px; height: 32px; } .pick b { font-size: 12.5px; }
  .souls-row .btn { padding-inline: 11px; font-size: 13px; }
  .quick-souls { gap: 5px; } .quick-souls button { min-height: 34px; padding: 5px 11px; }
  .tier { grid-template-columns: 1fr; gap: 0; }
  .tier .lbl { justify-items: start; padding: 6px 12px; font-size: 15px; letter-spacing: .04em; border-right: 0; border-bottom: 1px solid color-mix(in srgb, var(--tc) 25%, transparent); }
  .tier .heads { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 6px; padding: 10px; }
  .thead { width: 100%; } .thead img { width: 48px; height: 48px; } .thead span { max-width: 100%; font-size: 11px; }
  .c-herostats .tbl-wrap { margin-inline: -14px; padding-inline: 14px; -webkit-overflow-scrolling: touch; }
  .c-herostats table.t th, .c-herostats table.t td { padding: 7px 6px; font-size: 12px; }
  .c-herostats table.t th:first-child, .c-herostats table.t td:first-child { position: sticky; left: -14px; background: var(--panel); z-index: 1; padding-left: 14px; box-shadow: 1px 0 0 var(--line); }
  .c-herostats .hcell { min-width: 118px; gap: 7px; } .c-herostats .hcell img { width: 26px; height: 26px; }
  #shopSearch { max-width: none !important; width: 100%; }
  #shopSlot .seg { width: 100%; } #shopSlot .seg button { flex: 1; padding-inline: 6px; font-size: 12.5px; }
  #view-shop .filters + .filters, #view-heroes .filters, #view-patch .filters, #pickerRoles { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; gap: 6px; margin-inline: -14px; padding-inline: 14px; padding-bottom: 2px; }
  #view-shop .filters + .filters::-webkit-scrollbar, #view-heroes .filters::-webkit-scrollbar, #view-patch .filters::-webkit-scrollbar, #pickerRoles::-webkit-scrollbar { display: none; }
  #view-shop .filters + .filters .fchip, #view-heroes .filters .fchip, #view-patch .filters .fchip, #pickerRoles .fchip { flex: none; white-space: nowrap; padding: 6px 11px; font-size: 12.5px; }
  #shopCols .igrid { grid-template-columns: minmax(0, 1fr); } .tierlabel { flex-wrap: wrap; gap: 4px 8px; }
  .tl { grid-template-columns: minmax(0, 1fr); gap: 4px; padding: 10px 0; }
  .tl .d { display: flex; gap: 8px; align-items: baseline; } .tl .d br { display: none; }
  .mx-wrap { max-height: 70dvh; -webkit-overflow-scrolling: touch; }
  table.mx tbody th { min-width: 112px; width: 112px; padding: 0 6px; font-size: 11px; }
  table.mx tbody th button { display: block; max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; }   /* 11-21: 112 px so "Deadman Danny" fits, and a block (not the flex above) so a longer name ends in an ellipsis: text-overflow does not reach a text node inside a flex container */
  table.mx tbody th img { display: inline-block; vertical-align: middle; margin-right: 6px; width: 18px; height: 18px; flex: none; }
  table.mx th, table.mx td { width: 28px; min-width: 28px; height: 26px; font-size: 10.5px; }
  .bcard.inuse .bc-facts { padding-right: 76px; }
  #paletteScrim .modal { width: calc(100vw - 16px); margin-top: 12px; }
  #paletteScrim .modal-h { flex-wrap: nowrap; gap: 8px; padding: 10px 12px; }
  #paletteInput { flex: 1 1 auto; min-width: 0; font-size: 15px; }
  #pickerScrim .modal { width: calc(100vw - 12px); max-height: calc(100dvh - 16px); }
  #pickerScrim .modal-h { padding: 12px 14px; } #pickerScrim .modal-b { padding: 10px 14px 16px; }
  #pickerScrim .modal-h #pickerSearch { order: 2; max-width: none; width: 100%; }
  .picker-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .pcell { padding: 6px 4px; } .pcell img { width: 52px; height: 52px; }
  #rankScrim .modal-h #rankSeg { order: 2; }
  .drawer-b { padding: 0 14px 24px; }
  .intel-hero { grid-template-columns: 104px minmax(0, 1fr); gap: 12px; padding: 14px 0; }
  .intel-hero img { width: 104px; } .intel-hero h2 { font-size: 22px; }
  .statline { gap: 10px 14px; } .ratings { grid-template-columns: 1fr; }
  .trace { grid-template-columns: 90px minmax(0, 1fr) 42px; }
  .build-head { column-gap: 12px; }
  .build-head img { width: 52px; height: 52px; border-radius: 4px; }
  .bh-src { font-size: 12.5px; }   /* a trusted build's "Ascendant 6 player · 806 games · 53.5% WR · 5 days ago" fits one line at 390 */
  .bh-tools { width: 100%; }
  .bh-tools .inp { flex: 1 1 140px; }
  /* a phone: the builds are compact rows (tag and name on one line, games and win rate under it), so the plan starts on the first screen (ruling R14) */
  .bcards-grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .bcard-pick { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "tags name" "facts facts"; align-items: center; column-gap: 8px; row-gap: 2px; padding: 10px 12px; }
  .bc-tags { grid-area: tags; } .bc-tags:empty { display: none; } .bc-name { grid-area: name; }
  .bc-sig, .bc-age, .bc-facts > span:first-child, .bcard-copy-ghost { display: none; }
  .bc-facts { grid-area: facts; display: block; } .bc-facts > span:last-child { display: block; }
  .bcard-copy { position: absolute; right: 12px; bottom: 9px; margin: 0; }
  .iqr { display: none; }
  table.bstats thead { display: none; }
  table.bstats, table.bstats tbody { display: block; }
  table.bstats tr { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
  table.bstats td { border: 0; padding: 0; text-align: left; font-size: 12.5px; min-width: 0; }
  table.bstats td:first-child { flex: 1 1 60%; }
  table.bstats td[data-l] { order: 2; white-space: nowrap; }
  table.bstats td[data-l]::before { content: attr(data-l); font: 600 10px/1 var(--body); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin-right: 5px; }
  table.bstats td.nil { display: none; }
  .icell { min-width: 0; }
  .bstep { grid-template-columns: 20px auto minmax(0, 1fr); padding-inline: 4px; }
  .bstep .bside { grid-column: 3; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 6px 10px; }
  .bstep.k-skill { grid-template-columns: 20px 34px minmax(0, 1fr); }
  .bstep.k-skill .bside { grid-column: 3; }
  .bnum { font-size: 12px; }
  .skgrid { grid-template-columns: 18px repeat(16, minmax(0, 1fr)); gap: 1px; }
  .skgrid i { height: 16px; font-size: 10.5px; }
  .skgrid b { font-size: 10px; }
  .fin { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .swap-row { grid-template-columns: auto minmax(0, 1fr); }
  .swap-row > .chip { grid-column: 2; justify-self: start; }
  .iqr-c { min-width: 120px; }
  .respawn { padding-inline: 14px; }
  .respawn-h { gap: 10px 12px; } .respawn-h h2 { font-size: 26px; }
  .clock { width: 52px; height: 52px; } .clock b { font-size: 16px; }
  .respawn-h .btn-row { margin-left: 0 !important; width: 100%; } .respawn-h .btn-row .btn { flex: 1; }
  .respawn-h kbd { display: none; }
  .empty-state { padding-left: 58px; } .empty-state::before { left: 12px; width: 32px; height: 32px; margin-top: -16px; }
  .foot a, .foot-more summary { padding-block: 7px; }
  .foot { padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- settings menu (rank bracket, theme): power-user switches out of the header ---------- */
.menu { position: relative; }
.menu > summary { list-style: none; gap: 6px; }
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary svg { width: 15px; height: 15px; }
.menu[open] > summary { color: var(--fg); background: var(--surf-4); }
.menu-b { position: absolute; right: 0; top: calc(100% + 8px); z-index: 45; min-width: 260px; max-width: calc(100vw - 32px); display: grid; gap: 14px; padding: 16px; background: var(--surf-2); border: 1px solid var(--line-2); border-radius: calc(var(--r) + 2px); box-shadow: var(--shadow); overscroll-behavior: contain; }
.menu-b .seg { justify-self: start; }
.menu-b .kbd-btn { justify-self: start; }
.menu-note { font-size: 12px; color: var(--muted); line-height: 1.35; }
@media (prefers-reduced-motion: no-preference) { .menu[open] > .menu-b { animation: pop .2s var(--ease-emph) both; } }

/* ---------- the landing (11-01): one line, one sentence and the three steps, shown on the Match tab until a hero is on the board; the empty board sits under it,
   then the two other ways in (.ways: Live, the desktop app). The example match is a link here, not the default board. ---------- */
.landing { display: none; flex-direction: column; gap: 11px; align-items: flex-start; padding: 24px 0 22px; }
.landing::before { content: ""; width: 44px; height: 2px; background: var(--brass); }
.landing h1 { margin: 0; font: 700 clamp(32px, 4.2vw, 48px)/.98 var(--pulp); letter-spacing: .025em; text-transform: uppercase; }
.landing p { margin: 0; font-size: 16px; color: var(--fg-2); max-width: 640px; }
.landing .steps { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 4px; font-size: 14px; color: var(--fg-2); }
.landing .steps > span { display: inline-flex; align-items: center; gap: 9px; }
.landing .steps b { width: 22px; height: 22px; border-radius: 2px; display: grid; place-items: center; background: color-mix(in srgb, var(--brass) 14%, var(--panel)); border: 1px solid color-mix(in srgb, var(--brass) 60%, transparent); color: var(--brass-2); font: 600 11px/1 var(--mono); }
.landing .steps .linkish { font-size: 13px; color: var(--brass-2); }
.landing .fresh { font-size: 12.5px; line-height: 1.45; color: var(--muted); max-width: none; }   /* how fresh the numbers are (11-10): the stats window's patch, its match count and the day of the data, filled by freshLine() in app.js; in Simple too, where the header's patch pills are hidden */
.landing .fresh b { font-weight: 600; color: var(--fg-2); }
main:has(#view-match:not([hidden]) .slot-btn.empty[data-kind="me"]) .landing { display: flex; }
.ways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 24px 0 8px; }
.way { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--r); border: 1px solid var(--line); border-top-color: var(--line-2); color: var(--fg); text-decoration: none; text-align: left; box-shadow: var(--elev-1); font: inherit; transition: border-color .16s var(--ease), box-shadow .2s var(--ease), transform .18s var(--ease); }
.way:hover { border-color: color-mix(in srgb, var(--brass) 50%, var(--line)); box-shadow: var(--elev-2); transform: translateY(-1px); }
.way b { display: block; font: 600 15px/1.25 var(--display); letter-spacing: 0; }
.way small { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.way-i { width: 40px; height: 40px; border-radius: 3px; display: grid; place-items: center; flex: none; }
.way-i.live { background: var(--good-bg); }
.way-i.live::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 4px color-mix(in srgb, var(--good) 25%, transparent); }
.way-i.app { background: var(--glow); color: var(--brass); }
@media (max-width: 700px) { .landing { padding: 16px 0 18px; } .landing h1 { font-size: 26px; } .ways { grid-template-columns: 1fr; } }

/* ---------- Simple mode (the default): the essentials only. Detailed brings back counter needs, patch notes, midgame calls, the change log,
   the stats table under the tier list, build pins and bans, and the method notes. ---------- */
:root[data-mode="simple"] .c-needs, :root[data-mode="simple"] .c-bpatch, :root[data-mode="simple"] .c-calls, :root[data-mode="simple"] .c-log, :root[data-mode="simple"] .c-ask,
:root[data-mode="simple"] .c-herostats, :root[data-mode="simple"] .btools .prefs, :root[data-mode="simple"] .pb, :root[data-mode="simple"] .thr-note { display: none; }
:root[data-mode="simple"] #view-match:has(.slot-btn:not(.empty)[data-kind="me"]) .c-picks { display: none; }
/* 11-21: with the lede gone the title sat 6 px above the first card; the Coach tab has its own 16 px (#view-coach rule) */
:root[data-mode="simple"] .view > h2.sec { margin-bottom: 14px; }
:root[data-mode="simple"] .view > .lede { display: none; }   /* a tab gets no lede in Simple: a clamped one cut mid-sentence */

/* ---------- Deadlock art: your hero's card ghosted into the header band (--hero-art, set by the Match and Build Lab renderers), a root pseudo-element
   at z -1: above the page background, below everything on the page. ---------- */
body { isolation: isolate; }
html::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: .26;
  background: var(--hero-art, none) no-repeat right 20% top -28px / 310px auto;
  -webkit-mask-image: linear-gradient(180deg, #000 0, #000 72px, transparent 220px); mask-image: linear-gradient(180deg, #000 0, #000 72px, transparent 220px);
  filter: saturate(.78); transition: opacity .4s;
}
html[data-theme="light"]::after { opacity: .16; }
@media (prefers-color-scheme: light) { html:not([data-theme="dark"])::after { opacity: .16; } }
@media (max-width: 1099px) { html::after { display: none; } }
/* the threat list reads as a list: name, then what to respect, with room for the words */
/* who to watch out for: one compact row per enemy */
.threats { display: flex; flex-direction: column; }
.thr { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.thr:last-child { border-bottom: 0; }
.thr-who { display: block; padding: 0; }
.thr-who img { width: 40px; height: 40px; border-radius: 3px; display: block; }
.thr.top .thr-who img { box-shadow: 0 0 0 2px var(--bad); }
.thr-main { min-width: 0; }
.thr-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13.5px; line-height: 1.3; }
.thr-h .linkish b { font-weight: 600; }
.thr-role, .thr-wr { font: 400 11.5px/1.3 var(--mono); color: var(--muted); }
.thr-line { font-size: 12.5px; color: var(--fg-2); margin-top: 3px; }
.thr-foe { font-size: 12px; color: var(--muted); margin-top: 2px; }   /* live: this player's tendency on the hero (Simple: one fact; Detailed: the line) */
:root[data-mode="simple"] .thr-foe-f, :root:not([data-mode="simple"]) .thr-foe-s { display: none; }
.thr-more {margin-top: 3px; font-size: 12.5px; color: var(--fg-2); }
.thr-more summary { cursor: pointer; color: var(--muted); font-size: 11.5px; list-style: none; }
.thr-more summary::before { content: "▸ "; } .thr-more[open] summary::before { content: "▾ "; }
.thr-more p { margin: 4px 0 0; }
.thr-act { padding-top: 0; }
.side-h .hint .clearb { height: 22px; font-size: 11px; padding: 0 8px; margin-left: 2px; vertical-align: middle; }
#view-match:has(.example-note) .board .hint .clearb { display: none; }

/* ---------- the screen-fitting layout: on a desktop the page never scrolls. The board stays put and each column scrolls on its own; other tabs scroll inside their frame. ---------- */
@media (min-width: 1100px) and (min-height: 640px) {
  body { height: 100dvh; min-height: 0; overflow: hidden; display: flex; flex-direction: column; }
  .top { position: relative; flex: none; background: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .top-row { padding-block: 10px 6px; }
  .tabs { padding-bottom: 6px; }
  main { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; padding-block: 14px 8px; width: 100%; }
  .landing { flex: none; padding: 14px 0 16px; }
  .share-note { flex: none; }
  .view { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: auto; scrollbar-width: none; padding-bottom: 18px; }   /* the wheel still moves a tab, but no bar is drawn (Rauli, 11-01: "so clean and simple that it doesn't have any scroll wheels") */
  .view::-webkit-scrollbar { display: none; }
  .view > * { flex: none; }
  #view-matrix { overflow: hidden; }   /* the matrix fits the screen; every other tab scrolls as one page since 11-01 (Rauli: a scrollbar per column "looks very cluttered") */
  #view-match > .match-grid > .rail, #view-builds > .match-grid > .rail { align-content: start; }
  .board { margin-bottom: 14px; }
  .mx-wrap { max-height: none; flex: 1 1 auto; min-height: 0; }
  .foot { flex: none; display: flex; align-items: center; gap: 16px; padding-block: 9px 8px; margin-top: 8px; font-size: 11.5px; }
  .foot > div:first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
  .foot-more { margin-left: auto; position: relative; flex: none; }
  .foot-more-b { position: absolute; right: 0; bottom: calc(100% + 10px); width: min(680px, 80vw); margin: 0; background: var(--surf-2); border: 1px solid var(--line-2); border-radius: calc(var(--r) + 2px); padding: 14px 16px; box-shadow: var(--shadow); overscroll-behavior: contain; font-size: 12.5px; z-index: 50; }
}
/* a wide desktop in Simple mode: the lane verdicts and the threat list side by side, the shop call on the right (Detailed stacks them: its tables need the width) */
@media (min-width: 1360px) {
  /* Simple on a wide screen: one grid of cards, so every edge lines up. Row 1: the gun-or-spirit strip and the golden item, both one line; row 2: your lane beside
     the threats, Buy next down the right (11-01: the spike and pre-match cards are gone, and nothing scrolls inside a cell; the page scrolls as a whole).
     The two stacks become display: contents so their cards are the grid items. */
  :root[data-mode="simple"] #view-match { overflow: auto; }
  /* 11-01 (Rauli: the cards were "all over the place"): the base two columns stay, the main column and the 390 px rail, each a plain stack from the top; inside the main
     column the strip spans both halves and the lane card sits beside the threats */
  :root[data-mode="simple"] #view-match > .match-grid { gap: 14px; align-items: start; }
  :root[data-mode="simple"] #view-match > .match-grid #askSlot { display: none; }
  :root[data-mode="simple"] #view-match > .match-grid .main-flow { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: start; }
  :root[data-mode="simple"] #view-match > .match-grid .main-flow > * { grid-column: 1 / -1; }
  :root[data-mode="simple"] #view-match > .match-grid .main-flow > .c-lane { grid-column: 1; }
  :root[data-mode="simple"] #view-match > .match-grid .main-flow > .c-threat { grid-column: 2; }
  :root[data-mode="simple"] #view-match > .match-grid .queue > .qrow:nth-child(n+6):nth-child(-n+10) { display: grid; }   /* the rail has room for ten buys */
  :root[data-mode="simple"] #view-match > .match-grid .c-lean, :root[data-mode="simple"] #view-match > .match-grid .golden { display: flex; flex-direction: column; }   /* the two strips: the body sits centred in whatever height the row gives */
  :root[data-mode="simple"] #view-match > .match-grid .c-lean .card-b, :root[data-mode="simple"] #view-match > .match-grid .golden .card-b { flex: 1; display: flex; flex-direction: column; justify-content: center; }
  :root[data-mode="simple"] #view-match > .match-grid .golden-body { align-items: center; gap: 12px; }   /* the golden item as one line: tile, cost, name, tags, whether you can afford it */
  :root[data-mode="simple"] #view-match > .match-grid .golden .itile.lg { width: 48px; height: 48px; border-radius: 3px; padding: 3px; }
  :root[data-mode="simple"] #view-match > .match-grid .golden .itile.lg img { border-radius: 3px; }
  :root[data-mode="simple"] #view-match > .match-grid .golden-body > div { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
  :root[data-mode="simple"] #view-match > .match-grid .golden-body h4 { margin: 0; font-size: 18px; order: -1; }
  :root[data-mode="simple"] #view-match > .match-grid .golden-body p { margin: 0; }
}

/* ---------- Simple mode, deeper: the whole app shows just what a first game needs. Hidden until Detailed: the Matchups and Patch tabs, the patch pills,
   Spend my souls, Bought, the tools row, the stat lines under a lane verdict, the win-rate and matchup columns and Make threat, the Why buttons and reasons,
   buy-next rows past six, the shop's tag filters and its need groups past the third (two cards each), and the build path's reasons and alternatives. ---------- */
:root[data-mode="simple"] .tabs a[data-tab="shop"], :root[data-mode="simple"] .tabs a[data-tab="matrix"], :root[data-mode="simple"] .tabs a[data-tab="patch"], :root[data-mode="simple"] .patchline, :root[data-mode="simple"] #openPalette kbd,
:root[data-mode="simple"] #spendCard, :root[data-mode="simple"] .c-tools,
:root[data-mode="simple"] .verdict > .line ~ .line,
:root[data-mode="simple"] .c-threat .thrb, :root[data-mode="simple"] .c-threat .thr-wr, :root[data-mode="simple"] .c-threat .thr-role, :root[data-mode="simple"] .c-threat .abil-why, :root[data-mode="simple"] .c-threat .thr-more,
:root[data-mode="simple"] .qrow .why, :root[data-mode="simple"] .qrow .iconbtn[data-act="trace"], :root[data-mode="simple"] .queue > .qrow:nth-child(n+6), :root[data-mode="simple"] .queue ~ p.muted:last-child,
:root[data-mode="simple"] #view-shop .filters + .filters, :root[data-mode="simple"] .bwhy, :root[data-mode="simple"] .balt,
:root[data-mode="simple"] .slot .dir-t, :root[data-mode="simple"] .slot-btn .sub,
:root[data-mode="simple"] .c-lane .card-b > p.muted, :root[data-mode="simple"] .c-lane .eyebrow, :root[data-mode="simple"] .verdict .who .line,
:root[data-mode="simple"] #goldenCard .slot-word, :root[data-mode="simple"] #goldenCard .chip.neutral,
:root[data-mode="simple"] .bc-age { display: none; }
:root[data-mode="simple"] .tabs a[data-tab="shop"][aria-current="page"], :root:not([data-mode]) .tabs a[data-tab="shop"][aria-current="page"] { display: inline-flex; }   /* 11-21: the Counter items tab stays on the strip while it is the open one (a link to it from the palette or a board link): the extra attribute outweighs both hiding rules above, which stay as they are */
:root[data-mode="simple"] .btools, :root[data-mode="simple"] .bstep.k-skill, :root[data-mode="simple"] .bacts [data-act="bban"], :root[data-mode="simple"] [data-act="bcopy"], :root[data-mode="simple"] #view-builds .rail > .card:not(.golden),
:root[data-mode="simple"] .ic-more, :root[data-mode="simple"] .icard .tags .chip:not(.plan),
:root[data-mode="simple"] .c-picks .pick .muted, :root[data-mode="simple"] .c-picks .card-b > p.muted { display: none; }
:root[data-mode="simple"] #shopCols > :nth-child(n+7 of :not(.ptr)), :root[data-mode="simple"] #shopCols > :nth-child(n+7 of :not(.ptr)) ~ .ptr { display: none; }   /* Simple: the first three need groups with cards; a top ask the plan answers later (.ptr, one line) does not take a slot. Alone in its rule: a browser without nth-child(of) only shows more */
:root[data-mode="simple"] #view-match:has(.slot-btn.empty[data-kind="me"]) > .match-grid { grid-template-columns: minmax(0, 1fr); }
:root[data-mode="simple"] #view-match:has(.slot-btn.empty[data-kind="me"]) > .match-grid > .rail { display: none; }
:root[data-mode="simple"] #view-match:has(.slot-btn.empty[data-kind="me"]) :is(.c-lane, .c-threat, #goldenCard, .c-queue) { display: none; }   /* no hero yet: the guide says what to do, the empty cards would only repeat it */
:root[data-mode="simple"] .verdict p { border-top: 0; padding-top: 0; margin-top: 8px; }
/* the portraits keep their full 280 / 300 card art in every layout since 11-01 (Rauli, on the app's 1360 x 900 window: "prioritize being able to see the full hero icon"); the screen-fitting layout
   and the 900p rule used to shorten them to 280 / 236, 1 / 1 and 280 / 225 to make room for the cards below, which now flow under the fold instead */
:root[data-mode="simple"] .slot-btn .nm { padding-bottom: 8px; }
@media (max-width: 700px) {
  :root[data-mode="simple"] .side.you .slots.two { grid-template-columns: repeat(2, minmax(0, 130px)); }
  :root[data-mode="simple"] .slots.six { gap: 6px; }
}

/* ---------- the phone board (11-10): at 560 px and below the eight portraits are one grid of four columns and two rows (yours and the first two enemies, then the other
   four) with the board's status as one line under them, so the golden item and the top of Buy next are on the first screen. They started about 830 px down, under three
   rows of tall portraits, and a first visit saw a board, not an answer. Every portrait keeps its full 280 / 300 card art, only smaller (85 px wide at 390). The two sides,
   their slot lists and the enemy title row become display: contents, so the two titles, the eight slots and the status line are the grid's own items. Nothing above
   560 px changes. ---------- */
@media (max-width: 560px) {
  main { padding-top: 18px; }
  .board { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-bottom: 14px; }
  .board .side, .board .slots, .board .side.enemy .side-h { display: contents; }
  .board .side.you .side-h { grid-area: 1 / 1 / 2 / 3; margin: 0; }
  .board .side.enemy .side-h h3 { grid-area: 1 / 3 / 2 / 5; height: 22px; }
  .board .side-h .hint { grid-area: 4 / 1 / 5 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; min-height: 28px; white-space: normal; overflow: visible; }   /* the status line: what to do next, and Clear board, which the one-line title row cut off at this width */
  .board .hint .hint-n { display: none; }   /* "Add 5 more enemies" already says "1 of 6 enemies" */
  .board .hint .setup { margin-right: 2px; }
  .board .side-h .hint .clearb { margin-left: auto; height: 28px; padding: 0 10px; font-size: 12px; }   /* a finger's height */
  #view-match:has(.example-note) .board .hint { display: none; }   /* the example strip above the board already says what it is and clears it */
  .example-note { flex-wrap: nowrap; padding: 6px 10px; font-size: 12.5px; line-height: 1.35; margin-bottom: 10px; }
  .example-note .ex-more { display: none; }
  .example-note button { flex: none; }
  .slot-btn { height: 100%; align-content: start; }   /* a row's portraits end on one line, also when one name takes two lines */
  .slot-btn .nm { font-size: 12px; padding-inline: 6px; white-space: normal; }   /* "Deadman Danny" wraps on an 85 px portrait instead of ending in an ellipsis */
  :root[data-mode="simple"] .slot-btn .nm { padding-bottom: 6px; }
  .slot-btn .sub { font-size: 10.5px; padding: 0 6px 6px; }
  .slot-btn.empty .art { font-size: 30px; }
  .slot-btn.empty .nm { text-transform: capitalize; }   /* "Lane partner" without its .lk part is "partner" */
  .slot .x { top: 4px; right: 4px; width: 22px; height: 22px; }
  .slot .lane-t { top: 4px; left: 4px; padding: 6px 5px; font-size: 9.5px; }   /* 24 px tall, the x beside it: the smallest target a finger gets */
  .slot .lane-t .ck, .slot .lk { display: none; }   /* the sapphire fill and ring say "lane"; the grey chip says the read is automatic; a threat you set reads "Threat" */
  .slot .threat-badge, .slot .role-tag { left: 4px; bottom: 9px; padding: 3px 4px; font-size: 10px; letter-spacing: .02em; max-width: calc(100% - 8px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }   /* clear of the name, which sits 8 px into the art; tighter so badges don't crowd the face at 360-390px */
  .slot .dir-t { right: 4px; top: 28px; bottom: auto; padding: 3px 4px; font-size: 10px; max-width: calc(100% - 8px); }
  .slot:has(.threat-badge) .dir-t { top: 28px; }
  /* a larger target around the two small buttons on a portrait. Each grows only toward its own corner of the portrait, never toward the other button or down
     onto Detailed's gun/spirit chip: grown toward each other, a tap on the Lane tag's edge removed the enemy at 320 px (11-10 review) */
  .slot .x::after, .slot .lane-t::after { content: ""; position: absolute; }
  .slot .x::after { inset: -4px -4px -2px 0; }
  .slot .lane-t::after { inset: -4px 0 -6px -4px; }
}
@media (max-width: 395px) {
  .brand b { font-size: 15px; }
  .top-tools { gap: 4px; }
  .top-tools .seg button { padding: 4px 7px; font-size: 11px; }
  #openPalette, #settingsMenu > summary { width: 34px; height: 34px; min-height: 34px; }
}
@media (max-width: 380px) {
  .c-herostats .tbl-wrap, #view-shop .filters + .filters, #view-heroes .filters, #view-patch .filters { margin-inline: -12px; padding-inline: 12px; }
  .c-herostats table.t th:first-child, .c-herostats table.t td:first-child { left: -12px; padding-left: 12px; }
}
@media (max-width: 359px) { .slot .lane-t { padding-inline: 4px; } .slot .threat-badge, .slot .role-tag, .slot .dir-t { font-size: 9px; padding-inline: 3px; } }   /* under 360 px a portrait is 67 to 77 px wide: the Lane tag and the x would touch, and "Top threat" or "Controller" would be cut (every phone that narrow draws 2 pixels to the px, so 9 px type is clean there) */
@media (max-width: 335px) { .top-row { flex-wrap: wrap; } }

/* ---------- coach: one status line for games on the way, a short hero row with a list for the rest, numbers in the rail, Simple keeps the coaching ---------- */
.co-miss-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 9px 14px; font-size: 13.5px; }
.co-miss-ic { color: var(--warn); font-size: 17px; line-height: 1; }
.co-miss-sub { flex: 1 1 240px; min-width: 0; font-size: 12.5px; }
.co-miss-btn { min-height: 30px; padding: 5px 10px; font-size: 12.5px; }
.co-miss .co-more { margin: 0; }
.co-miss .co-more > summary { font-size: 12.5px; font-weight: 600; color: var(--brass-2); }
.co-miss .co-more[open] { flex: 1 1 100%; margin-top: 2px; padding-top: 8px; border-top: 1px dashed color-mix(in srgb, var(--warn) 45%, transparent); }
.co-miss .co-more p { font-size: 13px; }
.co-heroes { align-items: center; }
.co-hsel { width: auto; max-width: 190px; flex: none; align-self: stretch; padding: 6px 8px; font-size: 12.5px; }   /* as tall as the hero chips in its row */
.c-co-deaths, .c-co-hero, .c-co-more, .c-co-how { display: contents; }
/* item timing: your net worth at your big buys against winners of the hero (a number, not a tip) */
.co-it { display: grid; gap: 6px; }
.co-it-r { display: grid; grid-template-columns: 34px minmax(90px, 150px) minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 12.5px; color: var(--fg-2); }
.co-it-n { display: flex; flex-direction: column; min-width: 0; } .co-it-n b { color: var(--fg); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .co-it-n .muted { font-size: 11px; }
.co-it-v b { color: var(--fg); font-variant-numeric: tabular-nums; font-weight: 600; }
.co-it-g { font-weight: 600; font-variant-numeric: tabular-nums; color: var(--fg-2); } .co-it-g.early { color: var(--muted); }   /* neutral: a number, not a verdict */
@media (max-width: 560px) { .co-it-r { grid-template-columns: 34px minmax(0, 1fr) auto; } .co-it-r .co-it-v { grid-column: 2 / -1; } }
:root[data-mode="simple"] .co-it-r:nth-child(n+3) { display: none; }
/* your biggest leak (the build's first two core items against your rank, your strongest pick) and did it help (before / since you started); Simple keeps the lines */
.co-leak .co-ev { font-size: 15px; }
.co-leak-t { margin-top: 10px; }
.co-leak-t th, .co-leak-t td { font-size: 12.5px; }
.co-leak-t td:nth-child(2) { white-space: nowrap; }
.co-leak-t .itile { display: inline-block; vertical-align: middle; margin-right: 4px; }
.co-pick { margin: 12px 0 0; font-size: 13.5px; }
.co-picks { display: grid; gap: 5px; margin-top: 8px; }
.co-pk { display: grid; grid-template-columns: 24px minmax(70px, 130px) 34px minmax(0, 1fr) auto; gap: 8px; align-items: center; font-size: 12.5px; }
.co-pk img { width: 24px; height: 24px; border-radius: 3px; }
@media (max-width: 560px) { .co-pk { grid-template-columns: 24px minmax(0, 1fr) 34px auto; } .co-pk .muted { order: 1; grid-column: 2 / -1; } }   /* the record drops under the name */
.co-sr { padding: 9px 0; border-top: 1px solid var(--line); }
.co-sr:first-of-type { border-top: 0; }
.co-sr-h { display: flex; justify-content: space-between; gap: 8px; align-items: center; font-size: 13.5px; }
.co-sr-v { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-top: 4px; font-size: 13px; }
.co-sr-v b { font-size: 16px; font-variant-numeric: tabular-nums; }
.co-sr-t { margin: 4px 0 0; font-size: 12.5px; }
.co-since .co-more { margin-top: 6px; }
.co-since input[type="date"] { width: auto; }
:root[data-mode="simple"] .co-leak-t, :root[data-mode="simple"] .co-picks { display: none; }
.c-co-how .co-more { margin-top: 0; border: 1px solid var(--line); border-top-color: var(--line-3); border-radius: var(--r); padding: 12px 20px; background: var(--panel); box-shadow: var(--shadow-card); }
.c-co-how .co-more summary { font-size: 13px; }
:root[data-mode="simple"] .co-games::after { content: "Detailed shows every game."; font-size: 12.5px; color: var(--muted); }
:root[data-mode="simple"] .c-co-deaths, :root[data-mode="simple"] .c-co-hero, :root[data-mode="simple"] .c-co-more, :root[data-mode="simple"] .c-co-how,
:root[data-mode="simple"] .co-since, :root[data-mode="simple"] .co-leak, :root[data-mode="simple"] .co-tgt, :root[data-mode="simple"] .co-str,
:root[data-mode="simple"] .co-tip .co-ev, :root[data-mode="simple"] article.co-tip:nth-of-type(n+4), :root[data-mode="simple"] .co-pb-f,
:root[data-mode="simple"] .co-foot, :root[data-mode="simple"] .co-note, :root[data-mode="simple"] .co-more[data-open="ctx"], :root[data-mode="simple"] .co-more[data-open="miss"],
:root[data-mode="simple"] .co-games > .co-gr:nth-child(n+9) { display: none; }

/* ---------- live: the setup is one question (your name), the profile link folded under it; the Desktop pointer is a quiet line under the card ---------- */
.live-setup { max-width: 680px; margin: clamp(8px, 6vh, 64px) auto 16px; text-align: center; }
.live-setup .card-b { padding: 30px 28px 24px; }
.live-setup .card-b::before { content: ""; display: block; width: 72px; height: 72px; margin: 0 auto 14px; background: url(img/art/soul.svg) no-repeat 50% 50% / contain; }   /* one brass soul with the lock's keyhole (img/art/soul.svg, 11-01; Rauli did not like the three souls) */
.ls-title { font: 600 clamp(22px, 2.6vw, 28px)/1.1 var(--display); letter-spacing: 0; margin: 6px 0 8px; }
.ls-lede { font: 400 15px/1.5 var(--serif); color: var(--fg-2); max-width: 54ch; margin: 0 auto 18px; }
.ls-search { display: flex; gap: 8px; max-width: 540px; margin: 0 auto; }
.ls-search .ls-inp { flex: 1; min-width: 0; font-size: 16px; padding: 12px 14px; border-radius: 3px; }
.ls-search .btn { padding-inline: 18px; font-size: 15px; flex: none; border-radius: 3px; }
.live-setup .btn-row { justify-content: center; margin-top: 10px; }
.ls-msg { font-size: 13px; margin: 10px 0 0; }
.ls-alt { max-width: 540px; margin: 16px auto 0; text-align: left; }
.ls-alt > summary { cursor: pointer; list-style: none; text-align: center; font-size: 13.5px; color: var(--brass-2); }
.ls-alt > summary::-webkit-details-marker { display: none; }
.ls-alt > summary:hover { text-decoration: underline; text-underline-offset: 3px; }
.ls-alt[open] > summary { margin-bottom: 10px; }
.live-setup #liveAdv { max-width: 540px; margin: 16px auto 0; text-align: left; }
.ls-note { font-size: 12px; margin: 16px 0 0; }
.live-promo { max-width: 680px; margin: 0 auto 16px; }
.live-promo .card-b { display: flex; gap: 10px 14px; align-items: center; flex-wrap: wrap; padding: 10px 14px; font-size: 13px; }
.live-promo-t { flex: 1 1 240px; min-width: 0; color: var(--fg-2); }
.live-promo .btn { padding: 6px 11px; font-size: 13px; }
.live-state .pill.wait { color: var(--brass-2); background: color-mix(in srgb, var(--brass) 14%, transparent); }
.live-state .pill.wait::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--brass); }
@media (prefers-reduced-motion: no-preference) { .live-state .pill.wait::before { animation: pulse-brass 1.8s ease-out infinite; } }   /* 11-21: was declared after the reduced-motion block and won, so the dot pulsed for people who asked it not to */
@keyframes pulse-brass { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--brass) 55%, transparent); } 100% { box-shadow: 0 0 0 7px transparent; } }
#liveStatus:has(.pill.live) { border-color: color-mix(in srgb, var(--good) 40%, var(--line)); }
#liveStatus:has(.pill.wait) { border-color: color-mix(in srgb, var(--brass) 35%, var(--line)); }
:root[data-mode="simple"] #liveAdv { display: none; }
@media (max-width: 560px) { .live-setup .card-b { padding: 22px 16px 18px; } .ls-search { flex-wrap: wrap; } .ls-search .btn { flex: 1 1 100%; } }

/* ---------- lobby scout: enemy & allied threat rankings, mastery badges, quirks and signature items ---------- */
#view-scout > .lede { margin-bottom: 14px; }
.sc-bar-b { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 14px; padding: 12px 16px; }
.sc-bar-l { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
.sc-bar-l strong { font: 600 14.5px/1.2 var(--display); letter-spacing: .01em; }
.sc-bar-r { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.sc-lookup { display: flex; gap: 6px; align-items: center; }
.sc-lookup .inp { width: 196px; min-height: 36px; padding: 7px 10px; font-size: 13px; }
.sc-err { padding: 0 16px 12px; margin: 0; }
.sc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 16px; }
@media (max-width: 960px) { .sc-grid { grid-template-columns: 1fr; } }
.sc-team { display: grid; gap: 10px; align-content: start; min-width: 0; }
.sc-team-h { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding-bottom: 7px; border-bottom: 2px solid var(--line-2); }
.sc-team.enemy .sc-team-h { border-bottom-color: color-mix(in srgb, var(--sapphire) 55%, var(--line-2)); }
.sc-team.yours .sc-team-h { border-bottom-color: color-mix(in srgb, var(--brass) 55%, var(--line-2)); }
.sc-team-h h3 { margin: 0; font: 700 16.5px/1.2 var(--display); letter-spacing: .03em; text-transform: uppercase; }
.sc-team.enemy .sc-team-h h3 { color: var(--sapphire); }
.sc-team.yours .sc-team-h h3 { color: var(--brass-2); }
.sc-calls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.sc-call { display: grid; gap: 5px; align-content: center; min-height: 62px; padding: 9px 11px; background: var(--panel); border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--r-sm); min-width: 0; font-size: 12.5px; box-shadow: var(--elev-1); }
.sc-call-h { display: flex; align-items: center; gap: 7px; min-width: 0; }
.sc-call-h .chip { flex: none; }
.sc-call-h img { width: 22px; height: 22px; border-radius: 3px; flex: none; }
.sc-call-h b { font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-call-sub { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-list { display: grid; gap: 8px; grid-auto-rows: 1fr; }
.sc-card { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 11px; align-items: start; min-height: 100px; height: 100%; padding: 11px 13px; background: var(--panel); border: 1px solid var(--line); border-top-color: var(--line-2); border-radius: var(--r); box-shadow: var(--elev-1); min-width: 0; }
.sc-card.me { background: color-mix(in srgb, var(--brass) 7%, var(--panel)); border-color: color-mix(in srgb, var(--brass) 35%, var(--line)); }
.sc-card.best { border-left: 3px solid var(--bad); }
.sc-team.yours .sc-card.best { border-left-color: var(--good); }
.sc-card.worst { border-left: 3px solid var(--good); }
.sc-team.yours .sc-card.worst { border-left-color: var(--warn); }
.sc-hero { width: 44px; height: 44px; border-radius: 4px; object-fit: cover; flex: none; }
.sc-body { display: grid; gap: 5px; min-width: 0; }
.sc-top { display: flex; align-items: center; justify-content: space-between; gap: 6px 10px; flex-wrap: nowrap; min-width: 0; min-height: 22px; }
.sc-id { display: flex; align-items: center; gap: 7px; flex-wrap: nowrap; min-width: 0; overflow: hidden; }
.sc-id b { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-id > .chip { flex: none; }
.sc-id > .muted { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.sc-badges { display: flex; align-items: center; gap: 5px; flex-wrap: nowrap; flex: none; }
.sc-stats { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: nowrap; font-size: 12.5px; color: var(--fg-2); min-width: 0; }
.sc-stats > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.sc-extra { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: nowrap; min-height: 24px; margin-top: 2px; min-width: 0; }
.sc-quirks { display: flex; align-items: center; gap: 5px; flex-wrap: nowrap; min-width: 0; overflow: hidden; }
.sc-fav { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--fg-2); margin-left: auto; white-space: nowrap; flex: none; }
.sc-fav b { color: var(--fg); font-weight: 600; }
@media (max-width: 560px) {
  .sc-calls { grid-template-columns: 1fr; }
  .sc-bar-r { width: 100%; margin-left: 0; }
  .sc-lookup { flex: 1 1 240px; }
  .sc-lookup .inp { flex: 1; width: auto; min-width: 0; }
  .sc-list { grid-auto-rows: auto; }
  .sc-card { min-height: 0; height: auto; }
  .sc-top, .sc-id, .sc-stats, .sc-extra, .sc-quirks { flex-wrap: wrap; }
  .sc-fav { margin-left: 0; }
}
