/* web/play-panels.css
   The play page's side panels, arranged by web/dock.js and started by
   web/play-panels.js: AB's sidebars, a near-black column either side of the
   text, each panel under a title in its own colour. */

/* The Colour in Settings' Panels (web/swatches.js) sets --panel on the page. The side
   columns take it, and so do the input line, the dropdowns, the menus and
   Settings' fields, each field and edge drawn a little lighter than it. The
   panels' text keeps these greys on every shade; a title keeps its own colour. */
:root {
  --rail-bg: var(--panel);
  --cell: color-mix(in srgb, var(--panel), #fff 5%);
  --cell-edge: color-mix(in srgb, var(--panel), #fff 15%);
  --line: color-mix(in srgb, var(--panel), #fff 9%);
  --pn-text: #ccc;
  --pn-soft: #aaa;
  --pn-label: #888;
  --pn-faint: #777;
  --pn-empty: #666;
  --pn-quiet: #555;
  --pn-blank: #444;
  --pn-dash: #4f5462;
  --pn-hush: #7d8396;
  --pn-head: #8a90a2;
  --pn-hair: #2c303c;
  --rd-track: #2a2e3a;
  --rd-h: 1.25em;
  --rd-line: 1.3em;
  --pn-row: 1.7em;
}

/* The text and the prompt, between the columns. web/play-panels.js pads this
   by each column's width, so a column never covers a line. */
#centre {
  flex: 1; min-height: 0; position: relative;
  display: flex; flex-direction: column;
}

/* Each column runs the full height beside the text, and scrolls on its own, up and
   down only: what is wider than the column is clipped, never scrolled to, so every
   panel is made to fit the narrowest one. */
.rail {
  position: absolute; top: 0; bottom: 0; z-index: 5; box-sizing: border-box;
  overflow-x: hidden; overflow-y: auto; background: var(--rail-bg);
  display: flex; flex-direction: column;
  font-family: var(--mono);
}
.rail.empty { display: none; }
/* AB's thin dark scrollbar, not the browser's white one. Its room is kept whether
   or not the column needs it, so a panel growing past the foot never narrows the
   column and re-wraps every panel in it. */
.rail { scrollbar-width: thin; scrollbar-color: #333 transparent; scrollbar-gutter: stable; }
#rail-left  { border-right: 2px solid #333; }
#rail-right { border-left: 2px solid #333; }
/* The column's edge, dragged by any pointer to widen it (web/dock.js). Invisible
   until hovered or held; with touch controls it shows a grip (web/hud/touch.css). */
.railgrip {
  position: absolute; top: 0; bottom: 0; width: 7px; z-index: 6;
  cursor: col-resize; background: transparent; touch-action: none;
}
.railgrip:hover, .railgrip.drag { background: var(--accent); opacity: .55; }
.railgrip.empty { display: none; }
/* At the login screen web/play-panels.js puts the columns away whole. */
#centre.away .rail, #centre.away .railgrip { display: none; }

/* While the Stage is open (web/hud/stage.js) both columns tuck away: they fade, then
   leave the page, and the text slides over to share the width with the Stage, all in
   its time (web/hud/stage.css). Coming back, they return and fade in. */
#centre .rail {
  transition: transform var(--stage-ms) var(--stage-ease), opacity calc(var(--stage-ms) * .6) ease;
}
#centre .railgrip { transition: opacity calc(var(--stage-ms) * .6) ease; }
#centre.tucking .rail, #centre.tucking .railgrip { pointer-events: none; }
#centre.tucking .railgrip { opacity: 0; }
#centre.tucking #rail-left { transform: translateX(-100%); }
#centre.tucking #rail-right { transform: translateX(100%); }
#centre.tucked .rail, #centre.tucked .railgrip { display: none; }
#centre.sliding { transition: padding var(--stage-ms) var(--stage-ease); }
/* Only the game window, and its tabs over it, make room for the Stage
   (web/play-panels.js), so the input line and the bar under it run the full width,
   under the Stage and the window. A phone places the Stage in the grid instead. */
:root:not([data-phone]) #centre > :is(#screen, #wintabs) {
  margin-left: var(--beside-left, 0px); margin-right: var(--beside-right, 0px);
}
#centre.sliding > :is(#screen, #wintabs) { transition: margin var(--stage-ms) var(--stage-ease); }

/* A column folds (web/play-panels.js) from its button in the header, which shows
   the window with that side filled while the column is out and hollow while it is
   folded. A folded column leaves nothing at its side; the button brings it back. */
#centre.shut-left #rail-left, #centre.shut-left #grip-left,
#centre.shut-right #rail-right, #centre.shut-right #grip-right { display: none; }
.colfold { padding: 3px 7px; font-size: 12px; color: var(--dim); }
.colfold[hidden] { display: none; }
.colfold:hover, .colfold[aria-pressed="true"] { color: var(--ink); }
.colfold svg {
  width: 18px; height: 14px; vertical-align: middle;
  fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round;
}
.colfold[aria-pressed="true"] .side { fill: currentColor; }

/* A panel: its title row, then its body. AB's panels were separated by a
   hairline and titled in bold, each in a colour of its own. */
/* A panel's text is its own size from its gear (web/panel-settings.js), else
   the header's Panel size (web/play-panels.js), else the game text's Size;
   everything inside scales from it. */
/* Each panel's colour is --tc (below): its title, the rule under it, and what in
   web/hud/panel_style.css says so. */
.dkpanel {
  flex: none; border-bottom: 1px solid #222; --tc: var(--pn-text);
  font-size: var(--panel-size, var(--panel-base, var(--mono-size)));
}
/* The title, its drawn icon before it, and a faint rule in its colour under it,
   gone while the panel is folded. */
.dkhead {
  display: flex; align-items: center; gap: 2px;
  margin: 0 6px 6px 4px; padding: 8px 0 6px;
  border-bottom: 1px solid color-mix(in srgb, var(--tc) 28%, transparent);
  user-select: none; -webkit-user-select: none;
}
.dkpanel.shut .dkhead { margin-bottom: 0; border-bottom-color: transparent; }
.dkhead .dkname {
  display: inline-flex; align-items: center; gap: .5em; flex: 0 1 auto; min-width: 0;
  background: none; border: none; padding: 0; margin: 0; border-radius: 0;
  font-family: inherit; line-height: inherit; text-align: left; cursor: pointer;
  font-size: 1em; font-weight: 700; letter-spacing: .03em; color: var(--tc);
}
/* The icon and the name's words are never a click's target, so the dock always finds
   the name. On a bar too narrow for everything the name is cut short, so the controls
   stay inside the column. */
.dkicon { display: inline-flex; flex: none; pointer-events: none; }
.dktitle { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; pointer-events: none; }
.dkicon svg { width: 1.15em; height: 1.15em; display: block; }
/* A count is a pill at the far right, after the controls, so it never moves
   when they show. On a narrow bar it is cut short before the name is. */
.dkbadge {
  order: 2; flex: 0 10000 auto; min-width: 0; max-width: 45%; margin-left: 6px; padding: 0 .55em;
  border: 1px solid #343949; border-radius: 9px; background: #262a36; color: #b8bdcc;
  font-size: .79em; font-weight: 600; line-height: 1.55; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
/* A panel's own control (web/dock.js) sits at the far right with the badge, after
   the controls that come and go, and always shows: the panel uses it folded too. */
.dkcontrol { order: 2; flex: none; display: inline-flex; align-items: center; margin-left: 6px; }
.dkhead .grow { flex: 1; }
/* The page styles every button for the header; these are small and quiet. */
.dkhead .dk {
  background: none; border: none; color: var(--pn-quiet);
  padding: 2px 3px; font-size: 10px; line-height: 1; border-radius: 3px;
}
.dkhead .dk:hover { color: var(--ink); background: #222; }
/* A move the panel cannot make takes no room, which keeps a narrow column's title to
   one line with its count whole. */
.dkhead .dk:disabled { display: none; }
.dkhead .dk.t { font-size: 12px; color: var(--pn-label); }
.dkhead .dk.x { font-size: 14px; }
.dkhead .dk.x:hover { color: #ff8f8f; }
.dkhead .dk.set { font-size: 15px; color: var(--pn-label); }
/* With touch controls, one ⋯ holds them all (web/hud/touch.css). */
.dkhead .dkmore { display: none; }
/* At rest a title bar shows only the panel's name and badge. Its controls keep
   their space, and come back while the pointer is over the panel or keyboard focus
   is in it -- :focus-visible, so a click that leaves focus on a button does not
   hold them on after the pointer has gone. */
.dkhead .dk { opacity: 0; transition: opacity .15s; }
.dkpanel:hover .dkhead .dk, .dkpanel:has(:focus-visible) .dkhead .dk { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .dkhead .dk { transition: none; } }
.dkbody { padding: 2px 12px 10px; }
.dkpanel.shut .dkbody, .dkpanel.shut .dkset { display: none; }

/* A panel set to sit at the Bottom (web/panel-settings.js): the first of them
   takes the free space above it, so the ones below never move as it grows. */
.dkpanel.foot { margin-top: auto; border-top: 1px solid #222; }

/* The strip the gear opens, under the title, its settings wrapping as the
   column narrows. A fixed size, so the control that sets the panel's size does
   not move while you use it. */
.dkset {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; padding: 2px 12px 8px;
  font-size: 12px; color: var(--pn-label);
}
.dkset[hidden] { display: none; }
/* A setting's label keeps to one line, and its select shrinks to the column
   rather than widening it: a long option, such as "Only when affected", would
   otherwise give the whole column a sideways scrollbar. */
.dkset label { display: flex; align-items: center; gap: 6px; min-width: 0; max-width: 100%; }
.dkset label > span { flex: none; white-space: nowrap; }
.dkset select {
  flex: 0 1 auto; min-width: 0; max-width: 100%;
  background: var(--cell); color: var(--ink);
  border: 1px solid var(--cell-edge); border-radius: 6px;
  padding: 2px 6px; font-size: 12px; font-family: inherit;
}

/* ---- each panel's colour, --tc, AB's for its title ---------------------- */
.dkpanel[data-panel="equipment"] { --tc: #ffaa66; }
.dkpanel[data-panel="inventory"] { --tc: #aaccaa; }
.dkpanel[data-panel="resonance"] { --tc: #c9a6ff; }
.dkpanel[data-panel="link"], .dkpanel[data-panel="linkfight"], .rq-pop[data-panel="link"] { --tc: #8fb3ff; }
.dkpanel[data-panel="chat"] { --tc: #8fc1ff; }
.dkpanel[data-panel="guild"], .rq-pop[data-panel="guild"] { --tc: #f27d72; }
.dkpanel[data-panel="travel"] { --tc: #f2b25c; }
.dkpanel[data-panel="player"] { --tc: #7fd18e; }
.dkpanel[data-panel="target"] { --tc: #ff8844; }
.dkpanel[data-panel="pair"] { --tc: #ff9944; }
.dkpanel[data-panel="story"] { --tc: #f0b0c8; }
.dkpanel[data-panel="character"] { --tc: #aaddff; }
.dkpanel[data-panel="loadout"] { --tc: #cc99ff; }
.dkpanel[data-panel="builds"] { --tc: #e39bd0; }
.dkpanel[data-panel="quests"], .dkpanel[data-panel="main_quest"] { --tc: #e8c87a; }
.dkpanel[data-panel="sky"] { --tc: #e0c890; }
.dkpanel[data-panel="gambits"] { --tc: #e6a03c; }
.dkpanel[data-panel="meter"] { --tc: #9fcf7a; }
.dkpanel[data-panel="admin"], .dkpanel[data-panel="server"] { --tc: #9fd3a8; }

/* ---- time & weather (web/hud/sky.js) ------------------------------------ */
.sky-hour { margin-bottom: .2em; }
.sky-clock { font-size: 1.3em; font-weight: 700; color: #fff; margin-right: .5em; }
.sky-phase { color: var(--pn-label); }
.sky-date { color: var(--pn-text); }
.sky-season { color: var(--pn-label); }
.sky-weather { color: var(--pn-soft); }
.sky-weather.indoors { color: var(--pn-empty); }

/* ---- the character (web/hud/character.js) ------------------------------- */
.cs-name { font-weight: 700; color: #fff; margin-bottom: .2em; }
.cs-levels { margin-bottom: .6em; }
.cs-levels .cs-value { margin: 0 1.2em 0 .4em; }
.cs-label { color: var(--pn-label); }
.cs-value { color: var(--pn-text); }
/* AB's stat grid: as many columns as fit, so a larger text size drops to one. */
.cs-stats {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(8.5em, 1fr));
  gap: 0 1.2em; margin-bottom: .6em;
}
.cs-stat { display: flex; justify-content: space-between; }
/* Defenses: a name, then Flat, % and Total, each figure under its heading. */
.cs-def {
  display: grid; grid-template-columns: minmax(0, 1fr) repeat(3, max-content);
  gap: 0 .9em; margin-bottom: .6em; font-variant-numeric: tabular-nums;
}
.cs-def .cs-value { text-align: right; }
.cs-def .cs-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-def .cs-head { color: var(--pn-text); font-weight: 600; }
.cs-dh { align-self: end; text-align: right; font-size: .78em; color: var(--pn-label); text-transform: uppercase; letter-spacing: .05em; }
.pn-label.cs-skill { color: #cc99ff; }

/* ---- the inventory (web/hud/inventory.js) ------------------------------- */
.inv-item { color: var(--pn-soft); padding-left: .4em; column-gap: .4em; flex-wrap: wrap; }
.inv-item.held { padding-left: 1.5em; }
.inv-qty  { color: #556688; }
.inv-hint { color: var(--pn-faint); }

/* ---- the quest tracker (web/hud/quests.js) ------------------------------ */
.qt-entry { margin-bottom: .7em; }
.qt-entry:last-child { margin-bottom: .2em; }
.qt-name { font-weight: 700; color: var(--pn-text); margin-bottom: .15em; }
.qt-objective { color: var(--pn-soft); padding-left: .4em; }
/* AB's bar under a counted step, in the inventory's count colour. */
.qt-entry > .rd { margin: .25em 0 0 .4em; --rd-label-w: 0; }
.qt-entry > .rd .fill { background: #556688; }

/* ---- the Link panel (web/hud/link_panel.js): a block per member --------- */
.lk-list > .sp { padding: .4em 0 .35em; border-top: 1px solid #222; }
.lk-list > .sp:first-child { border-top: none; padding-top: 0; }
.lk-list > .sp.lk-companion { padding-left: 1.1em; }
.lk .sp-who .lk-marks {
  flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis;
  font-size: .8em; color: #f5d061;
}
.lk-list > .sp.lk-down .sp-bars { opacity: .45; }
.lk .lk-on:empty { display: none; }

/* ---- the Travel panel (web/hud/travel_panel.js) ------------------------- */
.tv-acts { display: flex; gap: .5em; margin-top: .3em; }
.tv-acts[hidden], .tv-ask[hidden], .tv-note[hidden], .tv-cd[hidden] { display: none; }
.tv-col { flex: 1 1 0; display: grid; gap: 3px; align-content: start; min-width: 0; }
.tv .tv-act { width: 100%; }
.tv .tv-act.glow:not(:disabled) { border-color: var(--tc); animation: tv-glow 2.4s ease-in-out infinite; }
@keyframes tv-glow {
  0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--tc) 18%, transparent); }
  50% { box-shadow: 0 0 0 5px color-mix(in srgb, var(--tc) 18%, transparent); }
}
@media (prefers-reduced-motion: reduce) {
  .tv .tv-act.glow:not(:disabled) { animation: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--tc) 18%, transparent); }
}
/* Recall's countdown, a slim track in the panel's colour. */
.tv-cd { height: 6px; border-radius: 3px; background: var(--rd-track); overflow: hidden; margin: .1em 0 .4em; }
.tv-cd i { display: block; height: 100%; border-radius: 3px; background: var(--tc); transition: width .9s linear; }
.tv-note { margin-top: .35em; font-size: .88em; color: var(--pn-label); }
.tv-ask { margin-top: .15em; border: 1px solid #3a3f4b; border-radius: 6px; padding: .5em; background: #15171c; }
.tv-question { font-size: .92em; color: var(--pn-text); }
.tv-row { display: flex; gap: .5em; margin-top: .45em; }
@media (prefers-reduced-motion: reduce) { .tv-cd i { transition: none; } }

/* ---- skills (web/hud/skills_panel.js) ----------------------------------- */
.sk-skill { gap: .45em; }
.sk-name { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--pn-text); }
.sk-rank { flex: none; width: 1.8em; text-align: right; color: var(--pn-text); font-weight: 600; }
.sk-rank.empty { color: var(--pn-dash); font-weight: 400; }
.sk-said { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sk-kind { flex: none; color: var(--pn-label); font-size: .9em; }
/* One small size for every button; one you can afford in the action meaning's gold. */
.sk .sk-act { flex: none; width: 4.6em; padding: .05em 0; font-size: .82em; border-radius: 10px; }
.sk .sk-act:not(.can):disabled { border-color: #2e3240; }
.sk .sk-act.can, .sk .sk-act.can:hover { border-color: var(--can); color: var(--can); }
.sk .sk-act.can:hover { background: color-mix(in srgb, var(--can) 12%, transparent); }
.sk-ask { margin-bottom: .5em; border: 1px solid #3a3f4b; border-radius: 6px; padding: .5em; background: #15171c; }
.sk-ask[hidden], .sk-note[hidden] { display: none; }
.sk-question { font-size: .92em; color: var(--pn-text); }
.sk-row { display: flex; gap: .5em; margin-top: .45em; }
.sk-note { margin-top: .35em; font-size: .88em; color: var(--pn-label); }

/* ---- the help box the panels share (web/hud/help_tip.js) ---------------- */
[aria-describedby="help-tip"] { cursor: help; }
[aria-describedby="help-tip"]:focus-visible { outline: 1px solid #7fb2ff; outline-offset: 1px; }
/* A tooltip on something that is not help -- an item, an effect, a stat -- draws it as it was,
   and with Settings, Tooltips, Show tooltips Off nothing is marked as having one. */
.tip-quiet[aria-describedby="help-tip"] { cursor: inherit; text-decoration: none; }
:root[data-tips="off"] [aria-describedby="help-tip"] { cursor: inherit; text-decoration: none; }
.help-tip { position: fixed; z-index: 50; padding: .55em .7em; border: 1px solid #3a3f4b; border-radius: 6px;
  background: var(--tip-bg, #12141a); color: var(--pn-text); font-family: var(--mono); font-size: 13px; line-height: 1.45; white-space: pre-wrap;
  max-height: calc(100vh - 16px); overflow: hidden; pointer-events: none; box-shadow: 0 6px 18px rgba(0, 0, 0, .5); }
.help-tip[hidden] { display: none; }
.help-tip .tip-again { margin-top: 1.45em; }

/* ---- the Resonance panel (web/hud/resonance_panel.js) ------------------- */
.rs .rs-rate { margin-top: .2em; }
.rs .rs-rate[hidden] { display: none; }
.rs-facts:not(:empty), .rs-list:not(:empty) { margin-top: .4em; padding-top: .35em; border-top: 1px solid #222; }
/* A line per Echo: its name, then a bar of its own drawn by the panel's Bars. */
.rs-echo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 9em); gap: .6em; align-items: center; }
.rs-echo .rs-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--pn-text); }
.rs-echo .rs-mark { color: #f5d061; }
.rs-echo .rd { --rd-label-w: 0; --rd-value-w: 3.5ch; }
.rs-echo .fill { background: #b98cff; }
.rs .rd.rs-flash { animation: rs-flash 1.4s ease-out 1; }
@keyframes rs-flash {
  0% { box-shadow: 0 0 0 0 rgba(245, 208, 97, 0); }
  20% { box-shadow: 0 0 0 3px rgba(245, 208, 97, .6); }
  100% { box-shadow: 0 0 0 0 rgba(245, 208, 97, 0); }
}
@media (prefers-reduced-motion: reduce) { .rs .rd.rs-flash { animation: none; } }

/* ---- the Link fight panel (web/link-fight.js): their lines, each keeping the
   look it had in your window; and the Chat panel (web/hud/chat_panel.js) ------ */
.lf-feed, .chat-feed {
  max-height: 22em; overflow-y: auto; white-space: pre-wrap; word-break: break-word;
  line-height: 1.4; color: var(--pn-text);
}
.lf-feed .k-gap { margin-top: .5em; }
.chat-feed .line {
  padding-left: var(--hang, 0); text-indent: calc(-1 * var(--hang, 0)); min-height: 1.4em;
}

/* ---- the Player and Target panels (web/hud/status_panel.js) ------------- */
.sp-who {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0 .6em;
  margin-bottom: .2em;
}
.sp-name { font-weight: 700; color: #ddd; min-width: 0; overflow-wrap: anywhere; }
.dkpanel[data-panel="target"] .sp-name { color: var(--tc); }
.sp-note { flex: 0 1 auto; min-width: 0; font-size: .8em; color: var(--pn-label); }
/* With no target, everything under the title is dimmed. */
.sp.none > * { opacity: .45; }
.sp-bars { display: grid; gap: .2em; }
.sp-pools { display: flex; gap: .2em; min-width: 0; }
.sp-pools > .rd { flex: 1 1 0; }
.sp-pools:empty, .sp-line:empty { display: none; }
.sp-line { display: flex; justify-content: space-between; gap: .6em; }
.sp-line .rd-label { color: var(--pn-label); }
.sp-line .rd-value { color: var(--pn-text); font-weight: 700; }
.sp-info {
  min-height: 1.3em; font-size: .85em; color: var(--pn-soft);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sp-info .who { color: var(--pn-text); font-weight: 600; }
/* A slot holds its place empty: the dashed outline of a bar, or with Slim or
   Numbers a line's height (web/hud/panel_style.css draws the bars). */
.sp-slot:empty { box-sizing: border-box; height: var(--rd-h); border: 1px dashed var(--pn-hair); border-radius: 4px; }
[data-bars="slim"] .sp-slot:empty, [data-bars="numbers"] .sp-slot:empty { border: none; height: var(--rd-line); }
[data-bars="slim"] .sp-pools, [data-bars="numbers"] .sp-pools { flex-direction: column; }

/* ---- a strip of effects (web/hud/strips.js) ----------------------------- */
.fxs {
  margin: .3em 0; border: 1px solid #262626; border-radius: 4px; background: #0b0b0b;
}
.fxs.buffs { border-left: 3px solid #2288cc; }
.fxs.debuffs { border-left: 3px solid #cc2222; }
.fxs-head {
  all: unset; box-sizing: border-box; display: flex; width: 100%; cursor: pointer;
  justify-content: space-between; align-items: center; gap: .6em; padding: .1em .55em;
  font-size: .78em; letter-spacing: .08em; text-transform: uppercase; color: var(--pn-label);
}
/* The heading is one button: what is inside it is never the click's target,
   so the dock always finds the fold. */
.fxs-head > * { pointer-events: none; }
.fxs-head:hover { color: var(--ink); }
.fxs-head:focus-visible { outline: 2px solid #8fd3ff; outline-offset: 1px; }
/* The marker every panel heading folds behind (web/hud/heading_folds.js). */
.fxs-name::before { content: "\25BE"; display: inline-block; width: 1em; font-size: 1.25em; line-height: 1; letter-spacing: 0; }
.fxs.shut .fxs-name::before { content: "\25B8"; }
.fxs.none .fxs-name::before { content: ""; }
.fxs-count { color: var(--pn-text); font-weight: 700; letter-spacing: 0; text-transform: none; font-size: 1.1em; }
.fxs.none .fxs-head { cursor: default; color: var(--pn-quiet); }
.fxs.none .fxs-count { color: var(--pn-quiet); font-weight: 400; }
.fxs-body { padding: .2em .4em .35em; }
.fxs.as-tags .fxs-body { display: flex; flex-wrap: wrap; gap: 3px; }
.fxs .fxs-body:empty { display: none; }
/* The panel's Effects show setting. Bare: no heading and no box, only the
   kind's coloured edge, and nothing at all when empty, as with Only when there
   are some. One row hides both strips for the row under the bars. */
.fxs.show-row, .fxs.none.show-bare, .fxs.none.show-some { display: none; }
.fxs.show-bare { border-top: 0; border-right: 0; border-bottom: 0; border-radius: 0; background: none; }
.fxs.show-bare .fxs-head { display: none; }
.fxs.show-bare .fxs-body { padding: .15em 0 .15em .45em; }
/* One row: buffs, a thin divider, then every other effect, all wrapping
   together; as a list, the divider is a hairline between the two. */
.fxr { margin: .3em 0; }
.fxr.none { display: none; }
.fxr-part { display: contents; }
.fxr.as-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 3px; }
.fxr.as-tags .fxr-divider { width: 1px; height: 1.3em; margin: 0 3px; background: #444; }
.fxr.as-list .fxr-part { display: block; }
.fxr.as-list .fxr-divider { display: block; height: 1px; margin: .2em 0; background: #333; }
.fxr .fxr-divider[hidden] { display: none; }
/* A tag as on the bar, sized with the panel. One with a colour of its own is
   dark, edged and lettered in it, as web/hud/effects.js sets them. */
.fxs .chip, .fxr .chip {
  display: inline-flex; align-items: center; height: 1.55em; padding: 0 .55em;
  background: rgb(80, 80, 80); border: 1px solid #555; border-radius: 4px;
  font-family: "Exo 2", sans-serif; font-size: .82em; color: #ccc; white-space: nowrap;
}
.fxs .chip.effect.lit, .fxr .chip.effect.lit { font-weight: 600; }
/* A list: the name in the effect's colour on the left, its time on the right. */
.fx-row { display: flex; justify-content: space-between; gap: .6em; white-space: nowrap; font-size: .92em; }
.fx-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--pn-soft); }
.fx-time { flex: none; color: var(--pn-label); }

/* ---- Player & Target side by side (web/hud/side_by_side.js) ------------- */
/* A label column, then yours, then your target's, every row straight across.
   Each value is a panel bar, drawn by the panel's Bars; health, the pools and
   the gauge carry no label of their own, the row naming them. */
.sbs {
  display: grid; grid-template-columns: max-content minmax(0, 1fr) minmax(0, 1fr);
  gap: .2em .8em; align-items: center; --rd-label-w: 0; --rd-value-w: 0;
}
.sbs-row { display: contents; }
.sbs-row.sbs-top > * { align-self: start; }
.sbs-label {
  font-size: .78em; letter-spacing: .06em; text-transform: uppercase;
  color: var(--pn-faint); white-space: nowrap;
}
.sbs-cell { min-width: 0; }
.sbs-name { display: block; font-weight: 700; color: #ddd; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sbs-name.it { color: #ff8844; }
.sbs-name.it.none { color: var(--pn-empty); font-weight: 400; }
.sbs-density { text-align: right; font-weight: 700; color: var(--pn-text); }
.sbs-aim { font-weight: 700; color: var(--pn-text); }
.sbs-fx .fx-row { font-size: .92em; }
.sbs-fx:empty::before { content: "\2014"; color: var(--pn-dash); }
.sbs.untargeted .sbs-row > :nth-child(3) .sbs-fx:empty::before { content: none; }

/* ---- the Admin panel (web/hud/admin_panel.js), for admins ---------------- */
.ad-hint { margin: .1em 0 .4em; font-size: .85em; color: var(--pn-label); }
.ad-names { display: flex; flex-wrap: wrap; gap: .2em .9em; margin: 0 0 .5em; padding: 0; list-style: none; }
.ad-name { color: var(--pn-text); }

/* ---- the Panels menu in the header, drawn by web/menu.js ----------------- */
.menuwrap { position: relative; display: inline-block; }
.menuwrap[hidden] { display: none; }
.menuwrap > button { padding: 3px 10px; font-size: 12px; }
.menuwrap > button.on { border-color: var(--accent); }
.menu {
  display: none; position: absolute; top: calc(100% + 6px); right: 0; z-index: 30;
  background: var(--panel); border: 1px solid var(--cell-edge); border-radius: 8px;
  padding: 5px; min-width: 190px; box-shadow: 0 10px 28px rgba(0, 0, 0, .55);
  max-height: calc(100vh - 60px); overflow-y: auto;
}
.menu.open { display: block; }
.mi {
  display: block; width: 100%; text-align: left; background: none; border: none;
  padding: 5px 8px; font-size: 13px; color: var(--ink); border-radius: 5px;
  white-space: nowrap;
}
.mi:hover { background: var(--cell); }
.misep { height: 1px; background: var(--line); margin: 5px 2px; }
/* A group's heading in the Panels menu (web/dock.js). */
.mhead {
  padding: 3px 8px 2px; font-size: 11px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--pn-label);
}
.mhead ~ .mhead { margin-top: 6px; }

/* New lines (web/hud/new_lines.js): a small pill over the foot of the game text,
   centred, while you read back and lines arrive below. Placed by its script. */
#newlines {
  position: absolute; z-index: 5; transform: translateX(-50%);
  padding: 4px 14px; border-radius: 999px; white-space: nowrap;
  font-size: 12px; font-weight: 600; color: var(--ink);
  background: var(--cell); border: 1px solid var(--accent);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .55);
}
#newlines[hidden] { display: none; }
#newlines:hover { background: var(--cell-edge); }
#newlines:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
