/* On-demand overlays: scoreboard, death recap, settings dialogs. Tokens only. */

/* Room panel: invite link and bot takeover (clickable, unlike the hold-Tab board) */
.room-panel {
  position: absolute;
  left: 50%;
  top: 128px;
  transform: translateX(-50%);
  zoom: var(--ui-scale);
  width: 860px;
  max-width: calc(100vw / var(--ui-scale) - 32px);
  max-height: calc(100vh / var(--ui-scale) - 148px);
  overflow: auto;
  z-index: var(--z-overlay);
  padding: var(--s4) var(--s5);
}
.room-head { gap: var(--s3); align-items: center; }
.room-note { margin: var(--s2) 0 var(--s3); }
.room-teams { gap: var(--s5); align-items: flex-start; }
.room-team { flex: 1; gap: var(--s2); min-width: 0; }
.room-team .teamlabel { padding: var(--s1) 0; }
.room-row { display: flex; align-items: center; gap: var(--s3); padding: var(--s2); border: 1px solid var(--line); background: var(--bg-1); }
.room-row.you { border-color: var(--you); background: var(--you-soft); }
.room-row .who { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.room-row .who b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Scoreboard (hold Tab) */
.board {
  position: absolute;
  left: 50%;
  top: 128px;
  transform: translateX(-50%);
  zoom: var(--ui-scale);
  width: 1320px;
  max-width: calc(100vw / var(--ui-scale) - 32px);
  max-height: calc(100vh / var(--ui-scale) - 148px);
  overflow: auto;
  z-index: var(--z-overlay);
  pointer-events: none; /* clicks go through to the game while Tab is held */
}
/* The board carries data-hud, and hud.css's "#hud [data-hud] { pointer-events: auto }" outranks .board, so the board
   swallowed right-click moves and casts while Tab was held (Opus, HUD council round 6; since 20 October). Mute stays
   clickable through "#hud button". */
#hud #scoreboard { pointer-events: none; }
/* The combat console's frame (hud.css .combat): top corners cut at 18px with the gold edge following the cut, over a
   double steel inset; the bottom keeps the panel's stepped corners (hud council round 2). Drawn by the board's own
   clip and backgrounds, not ::before/::after, which would scroll away with its rows. The gold top is the panel's
   border; the two corner squares carry it down each cut, gold 18-21px from the corner and clear past it. */
.panel.board {
  clip-path: polygon(0 18px, 18px 0, calc(100% - 18px) 0, 100% 18px, 100% calc(100% - 4px), calc(100% - 4px) 100%, 4px 100%, 0 calc(100% - 4px));
  background:
    linear-gradient(135deg, transparent 42.86%, var(--trim) 42.86% 50%, transparent 50%) 0 0 / 21px 21px no-repeat border-box,
    linear-gradient(225deg, transparent 42.86%, var(--trim) 42.86% 50%, transparent 50%) 100% 0 / 21px 21px no-repeat border-box,
    var(--steel);
  box-shadow: inset 0 0 0 1px var(--steel-dark), inset 0 0 0 3px var(--steel-line), 0 8px 24px var(--shadow);
}
.board-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: var(--s3) var(--s5); border-bottom: 2px solid var(--line); }
.board-head .side { gap: var(--s4); }
.board-head .side.r { justify-content: flex-end; }
/* Each side's kills lead with the top bar's crossed swords, drawn whole in the team's colour as the tower icon is, the
   towers after them: 27px, three screen pixels to a glyph pixel at full scale (hud council round 6, Opus: the 40px
   "1" and "8" had no visible name). */
.board-kills { gap: var(--s2); }
.board-kills .ico { width: 27px; height: 27px; vertical-align: 0; }
.board-kills .ico path { fill: currentColor !important; } /* over the glyph's inline token fills (kit glyph_markup) */
/* The kill totals' name, for screen readers only: the board takes no pointer, so a tip could never open (scoreboard.rs). */
.board-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
/* The two bosses as two equal cells 8px apart: the name and status first, the reward under them at 14px in the
   secondary colour, so when each spawns leads (hud council round 4: two sentences across the board's width). */
.objs { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2); padding: var(--s2) var(--s5); border-bottom: 2px solid var(--line); }
.obj { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: var(--s1) var(--s3); border: 1px solid var(--line); }
.obj-status { gap: var(--s2); align-items: center; font-size: var(--t-s); line-height: 22px; }
.obj-reward { font-size: var(--t-xs); line-height: 20px; color: var(--text-dim); overflow-wrap: anywhere; }
.prow, .colhead { display: grid; grid-template-columns: 72px 260px 384px 190px 110px 1fr; align-items: center; gap: var(--s4); padding: var(--s2) var(--s5); }
.prow { border-bottom: 1px solid var(--line); }
.prow.you { background: var(--you-soft); box-shadow: inset 4px 0 0 var(--you); }
.prow .items { display: flex; gap: var(--s1); }
.prow .star { margin-left: var(--s2); image-rendering: pixelated; }
/* The name, Mute, Bot and bounty: one wrapping line, 8px apart and 4px between lines (hud council round 2: "ClericMute"). */
.board-name { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s1) var(--s2); }
.board-name > b { min-width: 0; overflow-wrap: anywhere; }
.board-name > .chip { box-sizing: border-box; height: 22px; display: inline-flex; align-items: center; padding: 0 var(--s2); font: 700 var(--t-badge)/1 var(--font-body); }
/* Mute is an action and Bot a status, so they no longer look alike (hud council round 6, Sol): Bot stays the quiet flat
   chip; Mute is a raised steel button, 14px or more on screen in the body colour, its face lighter and its edge gold on
   hover or focus. The board takes no pointer while Tab holds it open (.board), so this is how it reads. */
.board-name > .board-mute {
  box-sizing: border-box;
  min-height: 26px;
  padding: 2px var(--s3);
  font-size: clamp(14px, calc(14px / var(--ui-scale)), 31px);
  line-height: 1;
  color: var(--text);
  background: var(--face-steel);
  border: 2px solid var(--steel-line);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 14%), inset 0 -2px 0 var(--steel-dark);
}
.board-name > .board-mute:is(:hover, .virtual-hover) { background: var(--face-steel-hover); border-color: var(--trim); }
.board-name > .board-mute:focus-visible { outline: 3px solid var(--you-light); outline-offset: 2px; }
.prow .bounty { gap: var(--s1); color: var(--you); border-color: var(--you-deep); }
.prow .bounty svg { width: 14px; height: 14px; }
/* Each team's rows open on a 2px rule in its colour; the head above names the teams (scoreboard.rs). */
.board-team.ally { border-top: 2px solid var(--ally); }
.board-team.enemy { border-top: 2px solid var(--enemy); }
/* The headings say what the numbers under them are, so they read at 14px or more on screen in the body text colour,
   and the kills and last-hit digits come down to 22px, held at about 18px on screen as the board is zoomed down (hud
   council round 5, Sol: small dim headings beside 24px digits left a beginner to work out what the numbers meant). */
.colhead { font-size: clamp(14px, calc(14px / var(--ui-scale)), 31px); color: var(--text); padding-top: var(--s1); padding-bottom: var(--s1); }
.prow .board-stat { font-size: clamp(22px, calc(18px / var(--ui-scale)), 29px); }
.teamlabel { padding: var(--s1) var(--s5); font-weight: 700; font-size: var(--t-xs); letter-spacing: 0.12em; }
/* A row's card (scoreboard.rs): the banner the player chose is the row's ground, under the portrait and name and gone
   before the items, and the card's title leads the line under the name in gold. Neither adds a line, so every row is
   two lines high (Tyler, 11 November 2026: the strip over the name "takes up way too much vertical space"). The board
   is read mid-fight, so its ground is darker than the client's. */
.board-player { min-width: 0; }
.prow { position: relative; isolation: isolate; }
.prow .match-ground { right: auto; width: 470px; }
.prow.you .match-ground { left: 4px; }
.prow .match-ground::after { background: linear-gradient(90deg, rgb(10 14 30 / 52%), rgb(10 14 30 / 84%) 55%); }
.prow:has(.match-ground) .board-player { text-shadow: 0 1px 0 rgb(0 0 0 / 80%); }
.board-info { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.board-info .match-identity-title, .result-meta .match-identity-title { display: inline; padding: 0; font-size: inherit; background: none; }
.board-info .match-identity-title::after, .result-meta .match-identity-title::after { content: ' · '; white-space: pre; color: var(--text-dim); }

/* Death recap — left side, stays visible beside the shop */
.recap { width: 100%; }
.recap .sum { padding: var(--s3) var(--s4); gap: var(--s2); border-bottom: 2px solid var(--line); }
.recap .final-blow-note { margin: 0; padding: var(--s2) var(--s4) 0; color: var(--text); }
.split { display: flex; height: 14px; border: 1px solid var(--bg-0); background: var(--bg-2); }
.split.thin { height: 8px; }
.split i { display: block; height: 100%; }
.split .p { background: var(--physical); }
.split .m { background: var(--magic); }
.recap .src { display: grid; grid-template-columns: 52px 1fr; gap: var(--s3); padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line); }
.recap .src .row { align-items: flex-start; }
/* A source's breakdown: one line per ability or attacker, the name left and the amount right in even digits (hud
   council round 1: one joined line wrapped to "· Item effect 299"). The dock is zoomed by --ui-scale, so the size is
   held at 15px or more on screen as the HUD's numbers are, with 20px lines and the amounts bold (round 4: too small to
   read). */
.recap .parts { list-style: none; margin: 0; padding: 0; font-size: clamp(15px, calc(15px / var(--ui-scale)), 33px); line-height: 1.3333; color: var(--text-dim); }
.recap .parts li { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s3); }
.recap .parts li > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.recap .parts .v { flex: none; text-align: right; color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; }
.recap .parts .blocked, .recap .parts .blocked .v { color: var(--text-faint); }
/* The source's name takes its own width first and the spacer the slack, so the amount sits right and a name such as
   "Siege Catapult" stays on one line while the row has room (hud council round 3: `flex: 1` on the name split the
   space with the spacer and wrapped it beside ~150px of empty row). */
.recap .src .row > b { flex: 0 1 auto; min-width: 0; overflow-wrap: anywhere; }
.recap .src .row > .num { flex: none; text-align: right; }
.recap .src.killer { box-shadow: inset 4px 0 0 var(--enemy); background: var(--enemy-soft); }
.srcicon { display: grid; place-items: center; color: var(--text-dim); }
/* The chips' words are a pale tint of their colour, the border keeps it: the enemy's red words on the killer's
   red-washed row read poorly (hud council round 5, Sol). */
.killer-chip { color: #ffb4a8; border-color: var(--enemy); }
/* The final blow landed by a minion or tower when a champion gets the kill: marked, but not in the killer's red (Grok,
   round 10). "Final blow", as "last hit" is farming here (hud council round 2). */
.recap .src.final-blow { box-shadow: inset 4px 0 0 var(--physical); }
.final-blow-chip { color: #ffd2a8; border-color: var(--physical); }
/* The attacker inside a group that landed the blow: its line in the body colour with the chip after its name, held at
   13px or more on screen like the lines it sits in (hud council round 6, Sol: the Wyrmling that made the kill was one
   dim line of four under "Minions · Killing blow"). */
.recap .parts li.blow { color: var(--text); }
.recap .parts .blow-name { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0 var(--s2); }
.recap .parts .blow-name > .chip { font-size: clamp(var(--t-badge), calc(13px / var(--ui-scale)), 29px); line-height: 1.2; padding: 0 var(--s1); }
/* The dock scrolls when a long recap overruns it (hud.css, while dead); Shop stays in view at its foot. */
.recapfoot { position: sticky; bottom: 0; padding: var(--s3) var(--s4); background: var(--bg-1); }
/* One thing to try after this death, while tips are on (death_advice.rs, scorecard E7), above the foot it stays with. */
.recap-try { margin: 0; padding: var(--s3) var(--s4) 0; font-size: var(--t-m); line-height: 1.3; color: var(--text); }
.recap-try b { color: var(--you-light); font-weight: 700; }
.recapfoot { gap: var(--s2); flex-wrap: wrap; justify-content: flex-end; }

/* Settings and its leave-match prompt (native dialogs from settings.rs) */
dialog.game-settings {
  padding: 0;
  color: var(--text);
  width: min(920px, calc(94 * var(--vw, 1vw)));
  max-height: calc(90 * var(--vh, 1vh));
  overflow: auto;
  zoom: var(--ui-scale);
}
/* Over the menu client or the results, Settings takes the client's scale, so it keeps its size beside the pages on
   every monitor (kit/scale.rs `client_scale`); in a match it keeps the HUD's. */
@media (min-width: 1100px) {
  body:has(.client-shell, .results-screen) dialog.game-settings { zoom: var(--client-scale, 1); --vw: calc(1vw / var(--client-scale, 1)); --vh: calc(1vh / var(--client-scale, 1)); }
}
dialog.game-settings::backdrop { background: rgb(6 12 22 / 38%); } /* the match stays watchable behind it (GPT-6.1 Sol, round 9) */
/* Out of a match nothing behind it needs watching, and Home beside it read as a second screen (client UI council
   round 0). The size stays the same. */
dialog.game-settings.out-of-match::backdrop { background: var(--scrim-strong); }
.game-settings .tabs { padding: 0 var(--s4); margin-top: var(--s3); }
/* In a match it is a warning, not help text (GPT-6.1 Sol, round 5). */
.game-settings .live-note { padding: 8px 32px 0; margin: 0; color: var(--physical); font-weight: 700; }
.game-settings .set-feedback { display: none; }
.game-settings .save-note { margin-right: var(--s3); font-family: var(--font-body); font-weight: 400; letter-spacing: normal; text-transform: none; }
.setpane { padding: var(--s4) var(--s5); display: flex; flex-direction: column; gap: var(--s1); }
.setrow { display: grid; grid-template-columns: 1fr auto; gap: var(--s4); align-items: center; padding: var(--s3) 0; border-bottom: 1px solid var(--line); cursor: pointer; }
/* Options in a row, the lobby's lane picker in the dialog's colours: the chosen one gold (Tyler, 2026-10-27). */
.choice { display: flex; border: 2px solid var(--steel-line); background: var(--bg-0); border-radius: var(--radius); }
.choice label { position: relative; display: block; }
.choice label + label { border-left: 2px solid var(--steel-line); }
.choice input { position: absolute; inset: 0; margin: 0; opacity: 0; pointer-events: none; }
.choice span { display: block; padding: var(--s2) var(--s3); font: 700 var(--t-s)/1.2 var(--font-body); color: var(--text-dim); white-space: nowrap; cursor: pointer; }
.choice label:is(:hover, .virtual-hover) span { color: var(--text); background: var(--bg-2); }
.choice input:checked + span { color: var(--ink); background: linear-gradient(var(--you-light), var(--you)); }
.choice input:focus-visible + span { outline: 2px solid var(--you-light); outline-offset: -4px; }
.setrow small { display: block; color: var(--text-dim); font-size: var(--t-s); margin-top: 2px; }
/* Settings → Help: the terms and privacy links (settings/help.rs). Feedback has its own panel (pages.css). */
.help-links { display: flex; gap: var(--s4); }
.help-links a, .results-help a { color: var(--you-light); }
/* A switch says its state in words as well as position (Opus, round 3: off read as an empty checkbox). */
.toggle { appearance: none; width: 72px; height: 32px; background: var(--bg-0); border: 2px solid var(--line-strong); border-radius: var(--radius); position: relative; cursor: pointer; margin: 0; }
/* One knob colour, left for Off, right for On (Opus, round 9: the knobs read backwards). */
.toggle::after { content: ''; position: absolute; top: 4px; left: 4px; width: 20px; height: 20px; border-radius: var(--radius); background: var(--text); transition: left 0.12s; }
.toggle::before { content: 'Off'; position: absolute; right: 8px; top: 50%; translate: 0 -50%; font: 700 var(--t-s)/1 var(--font-body); color: var(--text-dim); }
.toggle:checked { background: var(--you); border-color: var(--you-light); }
.toggle:checked::after { left: 44px; background: var(--text); box-shadow: 0 0 0 1px var(--ink); }
.toggle:checked::before { content: 'On'; right: auto; left: 8px; color: var(--ink); }
.rangebox { display: flex; align-items: center; gap: var(--s3); }
.rangebox input { appearance: none; width: 220px; height: 20px; margin: 0; background: linear-gradient(var(--line-strong), var(--line-strong)) no-repeat 0 50% / 100% 6px; cursor: pointer; }
.rangebox input::-webkit-slider-thumb { appearance: none; width: 12px; height: 20px; border-radius: 0; background: var(--you); box-shadow: 0 0 0 2px var(--you-edge); }
.rangebox input::-moz-range-thumb { width: 12px; height: 20px; border: none; border-radius: 0; background: var(--you); box-shadow: 0 0 0 2px var(--you-edge); }
.rangebox input::-moz-range-track { height: 6px; background: var(--line-strong); }
.rangebox output { min-width: 88px; font-weight: 700; font-variant-numeric: tabular-nums; }
.section-label { font-weight: 700; font-size: var(--t-xs); letter-spacing: 0.12em; color: var(--text-dim); text-transform: uppercase; margin: var(--s4) 0 var(--s1); }
.refs { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2) var(--s4); }
.ref { display: flex; gap: var(--s3); align-items: center; font-size: var(--t-s); }
.binds { display: flex; flex-direction: column; }
.bind { display: grid; grid-template-columns: 1fr 260px 110px; align-items: center; gap: var(--s4); padding: var(--s1) 0; border-bottom: 1px solid var(--line); }
.keybtn { font-weight: 700; font-size: var(--t-m); background: var(--bg-0); border: 2px solid var(--line-strong); padding: var(--s2); text-align: center; color: var(--text); }
.keybtn:is(:hover, .virtual-hover) { border-color: var(--text-dim); }
.keybtn.capture { border-color: var(--you); color: var(--you); }
.conflict { margin: var(--s2) 0; padding: var(--s3) var(--s4); border: 2px solid var(--you); background: var(--you-soft); display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; }
.saved { color: var(--ready); font-size: var(--t-s); font-family: var(--font-body); }
.setbuttons { gap: var(--s3); padding: var(--s3) 0; }
.setfoot { padding: 16px 32px 20px; border-top: 2px solid var(--plate-edge); }
/* On the title both footer buttons are hidden: no empty bar. */
.setfoot:not(:has(button:not([hidden]))) { display: none; }
/* Leaving a match is the one action you cannot undo: red (UI council round 2). */
.setfoot [data-resume] { font-size: var(--t-m); padding: var(--s3) var(--s5); } /* the way back to the match, sized like one (GPT-6.1 Sol, round 10) */
.setfoot :is([data-leave], [data-leave-now]) { color: var(--enemy); }

/* Settings keep one size on every tab, and each tab scrolls inside it (Tyler, 2026-10-27: "every time I click on a new
   tab in settings, this window is a different size"; rounds 6 to 9 had sized it to each tab's rows). */
dialog.game-settings:not(.leave-prompt) { height: min(720px, calc(90 * var(--vh, 1vh))); overflow: hidden; }
dialog.game-settings[open] { display: flex; flex-direction: column; }
.game-settings .setpane { flex: 1; min-height: 0; overflow-y: auto; scrollbar-gutter: stable; padding-bottom: 24px; }
:is(.game-settings .setpane, .shop-col.quick, .shop-col.detail-col, .shop-col.browse) { mask-image: linear-gradient(#000 calc(100% - 24px), transparent); }
.game-settings .setpane[hidden] { display: none; }
.game-settings > :not(.setpane) { flex-shrink: 0; }
/* Settings is one dialog in the client and in a match (Tyler, 29 October 2026: "sometimes you have like big like
   texturized buttons, and sometimes they're flat buttons. Why isn't that consistent? ... it's different in the client
   than it is in game"): the accepted layout A look, the kit's feature frame and controls in place of the panel's. The
   left-click action is a row of steel buttons, a switch is the steel frame with its knob, a slider fills gold to its
   knob, and every action is a steel button. Only the backdrop differs. The outer size stays the same (border-box). */
dialog.game-settings { clip-path: none; border: 10px solid transparent; border-image: url('/c/9cd69333dc17ed5ade6bb46d5efcec31312af5d14fe544a36a658f159be82b62.png') 8 / 16px stretch; background: var(--panel-steel) padding-box; image-rendering: pixelated; box-shadow: 0 8px 24px var(--shadow); }
.game-settings .panel-title { padding: 22px 32px 6px; border: 0; font: 400 var(--t-xl-sm)/1.1 var(--font-head); letter-spacing: 2px; text-transform: uppercase; color: var(--you-light); }
.game-settings .tabs { margin: 8px 32px 0; padding: 0; }
.game-settings .setpane { padding: 6px 32px 24px; gap: 0; }
.game-settings .setrow { gap: 24px; padding: 18px 0; border-bottom: 2px solid var(--plate-edge); }
.game-settings .setrow b { font-size: var(--t-m); }
.game-settings .setrow small { margin-top: 4px; font-size: 15px; line-height: 1.35; }
.game-settings .choice { border: 0; background: none; gap: 0; }
.game-settings .choice label + label { border: 0; margin-left: -4px; }
.game-settings .choice span { padding: 7px 12px; border: 4px solid transparent; border-image: url('/c/21c428881f7c1c8e8af997a3b077a6db135f5fa9e4787d722abb9f29942ad5cd.png') 5 / 10px stretch; background: var(--face-steel) padding-box; image-rendering: pixelated; font-size: 15px; color: var(--text); }
.game-settings .choice label:is(:hover, .virtual-hover) span { border-image-source: url('/c/07193ecb182886b98126d5ebe6b4189811e17fbd0f8bc4cb2295069407ec45ca.png'); background: var(--face-steel-hover) padding-box; }
.game-settings .choice input:checked + span { border-image-source: url('/c/237b4ddb8b6a22cd95523b9185aecfac1bebc5a8cba46a3a7428d6a69a3fe737.png'); background: var(--face-steel) padding-box; color: var(--you-light); }
.game-settings .toggle { width: 92px; height: 38px; border: 4px solid transparent; border-image: url('/c/21c428881f7c1c8e8af997a3b077a6db135f5fa9e4787d722abb9f29942ad5cd.png') 5 / 10px stretch; background: var(--field) padding-box; image-rendering: pixelated; }
.game-settings .toggle::after { top: 5px; left: 4px; width: 20px; height: 20px; background: var(--line-strong); box-shadow: 0 0 0 2px var(--steel-dark); }
.game-settings .toggle::before { right: 12px; font-size: 15px; color: var(--text-dim); }
.game-settings .toggle:checked { border-image-source: url('/c/237b4ddb8b6a22cd95523b9185aecfac1bebc5a8cba46a3a7428d6a69a3fe737.png'); background: var(--field) padding-box; }
.game-settings .toggle:checked::after { left: 60px; background: var(--face-gold); box-shadow: 0 0 0 2px var(--steel-dark); }
.game-settings .toggle:checked::before { left: 12px; color: var(--you-light); }
.game-settings .rangebox { gap: 18px; }
/* The fill's width is --fill, which settings.rs sets from each slider's value. */
.game-settings .rangebox input { width: 260px; height: 28px; background: var(--face-gold) 2px 50% / calc(var(--fill, 0%) - 4px) 12px no-repeat, linear-gradient(var(--field), var(--field)) 2px 50% / calc(100% - 4px) 12px no-repeat, linear-gradient(var(--steel-line), var(--steel-line)) 0 50% / 100% 16px no-repeat; }
.game-settings .rangebox input::-webkit-slider-thumb { width: 20px; height: 28px; background: linear-gradient(#fff1b8, var(--you) 50%, var(--you-deep)); box-shadow: 0 0 0 2px var(--steel-dark); }
.game-settings .rangebox input::-moz-range-thumb { width: 20px; height: 28px; background: linear-gradient(#fff1b8, var(--you) 50%, var(--you-deep)); box-shadow: 0 0 0 2px var(--steel-dark); }
.game-settings .rangebox output { min-width: 64px; text-align: right; font-size: var(--t-m); }
.game-settings .bind { padding: 8px 0; border-bottom: 2px solid var(--plate-edge); }
.game-settings .keybtn { border: 4px solid transparent; border-image: url('/c/21c428881f7c1c8e8af997a3b077a6db135f5fa9e4787d722abb9f29942ad5cd.png') 5 / 10px stretch; background: var(--field) padding-box; image-rendering: pixelated; }
.game-settings .keybtn:is(:hover, .virtual-hover) { border-image-source: url('/c/07193ecb182886b98126d5ebe6b4189811e17fbd0f8bc4cb2295069407ec45ca.png'); }
.game-settings .keybtn.capture { border-image-source: url('/c/237b4ddb8b6a22cd95523b9185aecfac1bebc5a8cba46a3a7428d6a69a3fe737.png'); color: var(--you-light); }
.game-settings .section-label { margin: 24px 0 8px; font: 400 var(--t-s)/1 var(--font-head); letter-spacing: 2px; color: var(--trim); }
.game-settings .conflict { border: 2px solid var(--trim); background: var(--you-soft); }
/* A row of buttons sits 12px under what is above it, and its help line 8px under it or beside it: in a match the
   Display tab then fits above the footer instead of ending half under it in the fade (Ibara check, 29 October 2026). */
.game-settings .setbuttons { padding: 12px 0 0; }
.game-settings .setpane > p { margin: 8px 0 0; }
/* Leave match asks here first (settings/leave.rs): the same frame, sized to its question. */
dialog.leave-prompt { width: min(560px, calc(94 * var(--vw, 1vw))); }
.leave-prompt > p { margin: 0; padding: 12px 32px 20px; }
.leave-prompt .setfoot { gap: 12px; }
/* Account conversations, a friend's profile and the notifications: in the client's party and friends column and under
   its bell (client.css), and in the lobby and results. The match HUD remains the only owner in a match. */
.friends-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; } .friends-header :is(h2, h3) { min-width: 0; margin: 0; font: 400 var(--t-m)/1.2 var(--font-head); letter-spacing: 1px; color: var(--you-light); overflow-wrap: anywhere; } .friends-header .btn { flex: none; }
/* Every chat in the client reads like the match chat (Tyler, 2026-10-29: "Make it bottom aligned and make it stick to
   the bottom"): its heading, the history filling the panel with the newest line at the bottom, scrolling above the
   field pinned to the panel's foot. A note lies over the history's top, over older lines rather than the newest, so
   nothing moves when a line arrives, is sent or is refused. Owner: social_chat.rs; the docked chat's place on Quick play is play.css's. */
.social-chat { display: flex; flex-direction: column; gap: 8px; min-height: 0; }
.social-chat-head { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.social-chat-head h3 { margin: 0; }
.social-chat-body { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; }
.social-chat-log { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow-y: auto; overflow-wrap: anywhere; font-size: var(--t-s); scrollbar-width: thin; scrollbar-color: var(--text-dim) transparent; }
.social-chat-log > p { margin: auto 0 0; color: var(--text-faint); }
.social-chat-history { list-style: none; display: grid; gap: 4px; margin: auto 0 0; padding: 0; }
.social-chat-history:empty { display: none; }
.social-chat-history li { margin: 0; padding: 0; line-height: 1.35; }
/* The name and time stay on one line, and your own lines start where everyone's do (Ibara check, 29 October 2026: a
   wrapped own line stacked "Y / o / u" when results' .mine rule also styled it). */
.social-chat-meta { display: inline-flex; align-items: baseline; gap: 6px; margin-right: 6px; white-space: nowrap; }
.social-chat-meta b { color: var(--you-light); }
.social-chat-history li.own .social-chat-meta b { color: var(--ally); }
.social-chat-meta .dim { font-size: var(--t-xs); font-variant-numeric: tabular-nums; }
.social-chat-note { position: absolute; left: 0; right: 0; top: 0; z-index: 1; margin: 0; padding: 6px 8px; font-size: var(--t-xs); background: var(--scrim-strong); }
.social-chat-note[hidden] { display: none; }
.social-chat-composer { flex: none; display: flex; gap: 8px; margin: 0; }
.social-chat-composer .input { flex: 1; width: auto; min-width: 0; padding: 8px 10px; font-weight: 400; font-size: var(--t-s); background: var(--field); }
.social-chat-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.social-pane > .social-chat { height: 100%; }
.social-pane:has(> .social-chat) { overflow: hidden; }
.inbox-panel .social-chat { height: 360px; margin-top: 12px; }
/* The bell: its count once, as a badge on its corner, so it never moves the bar. */
.inbox-toggle { position: relative; pointer-events: auto; }
.unread-badge { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; padding: 0 5px; display: grid; place-items: center; background: var(--you); color: var(--ink); font: 700 var(--t-badge)/1 var(--font-body); box-shadow: 0 0 0 2px var(--steel-dark); }
.inbox-panel { position: absolute; right: 24px; top: 100%; max-height: calc(100vh / var(--ui-scale, 1) - 220px); width: min(380px, calc(100% - 24px)); overflow: hidden auto; pointer-events: auto; z-index: 4; padding: 16px; }
.inbox-list { list-style: none; margin: 0; padding: 4px; }
.inbox-item { display: grid; gap: 6px; padding: 12px 0; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.inbox-item .friends-actions { flex-wrap: wrap; }
.inbox-panel .inbox-header { padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.inbox-panel .inbox-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; }
.inbox-panel .inbox-item { margin: 6px 0; padding: 12px; border: 1px solid var(--line); background: #101b2a; }
.inbox-panel .inbox-unread { border-left: 3px solid var(--you); background: #17283a; }
.inbox-panel .inbox-item > span { line-height: 1.45; }
/* Every notice is heading, sentence, then one action row: the responses first, Mark read last and pushed to the row's
   right end, so all cards share one shape (client council round 14: in the heading it fell to its own line under the
   longer kinds only). The responses are 10px narrower at the sides than elsewhere, so Accept, Decline and Mark read
   (264px) and Open conversation and Mark read (261px) fit the 340px drawer's 280px row at full text size; only a room
   invitation's Join room, Decline and Mark read (288px) is wider, and its Mark read wraps under them at the right rather
   than spilling past the card. Owner: inbox.rs. */
.inbox-panel .inbox-actions { flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.inbox-panel .inbox-actions .btn.small { flex: none; white-space: nowrap; }
.inbox-panel .inbox-actions .btn.small:not(.inbox-read) { padding-inline: 10px; }
.inbox-panel .inbox-actions .inbox-read { margin-left: auto; }
/* Mark read and Refresh are the drawer's bookkeeping, so they are the kit's quiet text action, not framed buttons
   (client council round 18, Sol: three framed buttons made Mark read compete with Accept and Decline): no frame or face,
   the dim words lit gold when pointed at, the kit's focus ring and its one disabled look. Here they also keep the
   responses' 16px words (round 13: 14px read as fine print) over a steel underline that says they can be pressed, gold
   when pointed at or focused (round 16: dim words with nothing more read as disabled). The drawer reads again on every
   action and poll; Refresh stays for a player who wants it now. */
.inbox-panel :is(.inbox-actions .inbox-read, .inbox-toolbar .inbox-refresh) {
  padding-inline: 2px; font: 700 var(--t-s)/1.1 var(--font-body);
  text-decoration: underline; text-decoration-color: var(--line-strong); text-decoration-thickness: 2px; text-underline-offset: 5px;
}
.inbox-panel :is(.inbox-actions .inbox-read, .inbox-toolbar .inbox-refresh):is(:hover, .virtual-hover, :focus-visible):not(:disabled) { color: var(--you-light); text-decoration-color: currentColor; text-underline-offset: 5px; }
.inbox-panel :is(.inbox-actions .inbox-read, .inbox-toolbar .inbox-refresh):disabled { text-decoration-color: transparent; }

/* Notifications and the party and friends column in the lobby and results: a bell and a drawer, leaving the room's
   controls in their layout. */
.room-inbox { min-width: 0; max-width: 100%; }
.room-inbox .inbox-panel { position: fixed; right: 12px; z-index: 4; top: 66px; bottom: 16px; max-height: none; box-sizing: border-box; }
.room-inbox :is(button, input):focus-visible { outline: 3px solid var(--you-light); outline-offset: -3px; }
.room-social { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.room-social-drawer { position: fixed; top: 66px; right: 12px; bottom: 16px; width: var(--column-w); z-index: 4; display: flex; }
.room-social-drawer .social-column { flex: 1; box-shadow: -12px 0 30px var(--shadow); }
.lobby-top .invite, .resfoot { min-width: 0; max-width: 100%; flex-wrap: wrap; }

/* Match identity uses the worker's viewer-filtered decoration. */
/* A chosen banner as the ground of its player's row, cell or card (match_identity.rs `ground`): behind what is written
   there, darkened so a name reads on any art, and faded out to the right before the figures. Its host is
   `position: relative; isolation: isolate`, so the ground lies over the host's own background and under its content. */
.match-ground { position: absolute; inset: 0; z-index: -1; pointer-events: none; background-color: #101d30; background-position: center; background-size: cover;
  -webkit-mask-image: linear-gradient(90deg, #000 45%, transparent); mask-image: linear-gradient(90deg, #000 45%, transparent); }
.match-ground::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgb(10 14 30 / 30%), rgb(10 14 30 / 72%) 60%); }
/* The free banners are the title's night sky, far darker than the Store's: they are lifted so they read as a banner
   under a row (`--ground-lift`, match_identity.rs `ground_style`). */
.match-ground { filter: brightness(var(--ground-lift, 1)); }
/* A banner unfurls: it drops from its top edge in steps, as cloth let go, where a player has time to watch it (the
   loading card, their own card on Results, a player's card). Never on the board held open mid-fight. */
@keyframes banner-unfurl { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
.match-identity { display: block; width: min(100%, 150px); height: 22px; overflow: hidden; background-color: #101d30; background-position: center; background-size: cover; }
.match-identity-title { display: inline-block; padding: 2px 5px; color: #f6e1a4; background: #0a1222; font-size: 11px; }

/* Community members' names, in lobbies, loading and results (Tyler, 9 November 2026: "a badge for the membership"). */
.member-name { color: #f4c440; text-shadow: 0 1px 0 rgb(0 0 0 / 60%); }
.member-badge { display: inline-block; width: 10px; height: 10px; margin-left: 4px; vertical-align: middle; transform: rotate(45deg); background: var(--face-gold); box-shadow: 0 0 0 1px #6b4a10; }

/* What each touch does (settings/training.rs): a touch page's alone. */
.game-settings .touch-controls { display: none; }

/* Settings on a phone (Tyler, 2026-11-17: "a lot of the menus are kind of squished"): the whole screen at the menus'
   phone scale (kit/scale.rs `touch_client_scale`), in the menus and in a match alike, since the HUD's scale there drew
   its words at 8 px. A phone has no keys to bind, so Hotkeys goes. Upright, each row's control stands under its words. */
html.touch dialog.game-settings { zoom: var(--client-scale, 1); --vw: calc(1vw / var(--client-scale, 1)); --vh: calc(1vh / var(--client-scale, 1));
  width: calc(100 * var(--vw)); max-width: none; height: calc(100 * var(--vh)) !important; max-height: none; margin: 0; border-width: 6px;
  /* The whole screen, so its tabs and Close keep out of the Dynamic Island and the home bar of a home-screen web app
     (client.css, The safe area); 0 elsewhere. Divided by the dialog's zoom to measure the same on the glass. */
  padding: calc(env(safe-area-inset-top, 0px) / var(--client-scale, 1)) calc(env(safe-area-inset-right, 0px) / var(--client-scale, 1))
    calc(env(safe-area-inset-bottom, 0px) / var(--client-scale, 1)) calc(env(safe-area-inset-left, 0px) / var(--client-scale, 1)); }
html.touch .game-settings .panel-title { display: flex; align-items: center; gap: 12px; padding: 12px 16px 4px; font-size: var(--t-l); }
html.touch .game-settings .panel-title [data-close] { min-height: 44px; padding-inline: 18px; }
/* Feedback beside Close (settings/help.rs `HEAD_BUTTON`): Settings covers the top bar here, and Feedback stays in view
   on every screen (Tyler, 2026-11-14; mobile council round 3, both judges). The top bar's Feedback's look. */
html.touch .game-settings .panel-title .set-feedback { display: inline-flex; align-items: center; flex: none; min-height: 44px; padding-inline: 14px; }
html.touch .game-settings .tabs { margin: 4px 16px 0; overflow-x: auto; scrollbar-width: none; }
/* The tabs are functional labels, so on a phone they wear the top bar's tabs' face, bold body capitals, which read at
   a glance where the pixel face at 16 px read small (phone council round 1). */
html.touch .game-settings .tab { flex: none; min-height: 48px; font: 700 var(--t-s)/1 var(--font-body); letter-spacing: .5px; }
html.touch .game-settings .tab[data-tab="hotkeys"] { display: none; }
/* Only what a thumb uses (phone council round 0: Controls taught clicks, a cursor and keys). A touch page's camera
   stays on the champion (input/mod.rs `follow_camera`) and a tap is never the left-click setting's (input/touch.rs
   `on_tap`), so the click, quick cast, edge, respawn and pan rows do nothing here; nor does capturing a cursor or
   Escape. What each touch does stands in their place (settings/training.rs). */
html.touch .game-settings .setrow:has([name="leftClick"], [name="quickCast"], [name="edgePan"], [name="respawnCenter"], [name="cameraSpeed"]),
html.touch .game-settings [data-lock], html.touch .game-settings [data-pane="display"] > p { display: none; }
html.touch .game-settings .touch-controls { display: block; padding: 12px 0 6px; border-bottom: 2px solid var(--plate-edge); }
html.touch .game-settings .touch-controls .section-label { margin: 6px 0 10px; }
html.touch .game-settings .touch-controls dl { display: grid; gap: 10px; margin: 0; }
html.touch .game-settings .touch-controls dl > div { display: grid; grid-template-columns: 9em minmax(0, 1fr); gap: 12px; align-items: baseline; }
html.touch .game-settings .touch-controls dt { font-weight: 700; font-size: var(--t-s); color: var(--you-light); }
html.touch .game-settings .touch-controls dd { margin: 0; font-size: var(--t-s); line-height: 1.35; color: var(--text-dim); }
html.touch .game-settings .setpane { padding: 4px 16px 24px; }
html.touch .game-settings .choice span { padding: 10px 12px; }
html.touch .game-settings .setfoot { padding: 10px 16px 12px; }
@media (max-width: 600px) and (orientation: portrait) {
  html.touch .game-settings .save-note { display: none; }
  html.touch .game-settings .setrow { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  html.touch .game-settings .rangebox input { width: auto; flex: 1; min-width: 0; }
  html.touch .game-settings .refs { grid-template-columns: minmax(0, 1fr); }
  /* All five tabs in one row, so none hides off the edge (phone council round 0: Chat and Help scrolled out of sight). */
  html.touch .game-settings .tabs { gap: 0; margin-inline: 8px; }
  html.touch .game-settings .tab { flex: 1 1 auto; padding-inline: 4px; font-size: clamp(14px, 3.9vw, 16px); letter-spacing: 0; }
  html.touch .game-settings .tab:is(.on, [aria-selected="true"])::after { left: 4px; right: 4px; }
  html.touch .game-settings .touch-controls dl > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  html.touch .game-settings .panel-title { gap: 8px; padding-inline: 12px; }
}
/* A narrow phone (360 wide): a smaller heading keeps Settings, Feedback and Close on one row. */
@media (max-width: 380px) and (orientation: portrait) {
  html.touch .game-settings .panel-title { font-size: var(--t-m); letter-spacing: 1px; }
  html.touch .game-settings .panel-title :is(.set-feedback, [data-close]) { padding-inline: 12px; }
}
/* On its side the dialog is zoomed to 0.8 to 0.86: the tabs and Close are 56 px, so at least 44 on the glass. What
   each touch does is a grid of short cards, each name over its words, three across on a wide phone and two on a small
   one (mobile council round 2: a name far from its words read slowly, and at 568 wide the words were squeezed into a
   column five lines tall). Training and First-time tips stand side by side under them, so the whole pane fits a
   phone on its side, and the pane's foot fades over 56 px where it still scrolls, so a row cut at the panel's edge
   reads as more below (round 2, Opus 19: First-time tips was cut at the foot with no cue). */
@media (orientation: landscape) and (max-width: 1099.98px) {
  html.touch .game-settings .panel-title { padding-top: 8px; }
  html.touch .game-settings .tab { min-height: 56px; padding-inline: 18px; }
  html.touch .game-settings .panel-title :is(.set-feedback, [data-close]), html.touch .game-settings .setpane .btn { min-height: 56px; }
  html.touch .game-settings .choice span { padding-block: 16px; }
  html.touch .game-settings .touch-controls dl { grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 14px 32px; }
  html.touch .game-settings .touch-controls dl > div { grid-template-columns: minmax(0, 1fr); align-content: start; gap: 2px; }
  html.touch .game-settings .setpane { padding-bottom: 40px; mask-image: linear-gradient(#000 calc(100% - 56px), transparent); }
  html.touch .game-settings .setpane[data-pane="controls"] { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; column-gap: 32px; }
  html.touch .game-settings .setpane[data-pane="controls"] > .touch-controls { grid-column: 1 / -1; }
}
/* A small phone on its side: half the pane is too narrow for a row's words beside its control, so it stands under them. */
@media (orientation: landscape) and (max-width: 799.98px) {
  html.touch .game-settings .setpane[data-pane="controls"] > .setrow { grid-template-columns: minmax(0, 1fr); gap: 10px; }
}
