/* Design tokens: cool slate with the AutoTurret blue as the one accent. */
:root, .theme-dark {
  --bg: #0f1318; --bg2: #131820; --panel: #171d26; --panel2: #1e2631; --line: #283240; --line-strong: #3a4656;
  --text: #e6ebf1; --muted: #93a0b0; --accent: #6cc4ff; --on-accent: #04131f;
  --link: var(--accent); --focus: var(--accent); --console: #0b0f14;
  --accent2: color-mix(in srgb, var(--accent) 80%, #000); --accent-soft: color-mix(in srgb, var(--accent) 13%, transparent); --accent-line: color-mix(in srgb, var(--accent) 38%, transparent);
  --ok: #5fd38d; --warn: #f0a66b; --err: #ff7a85;
  --ok-bg: #11251b; --ok-line: #23573d; --warn-bg: #2a1e14; --warn-line: #5c4128; --warn-ink: #f3d2b4; --err-bg: #2a1519; --err-line: #5c2a31;
  --steam: #1b2838; --discord: #5865f2;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 15px/1.55 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--link); text-decoration: none; } a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.15; margin: 0; text-wrap: balance; font-weight: 700; }
h1, h2 { font-stretch: 112%; letter-spacing: -.01em; }
button, input, select, textarea { font: inherit; color: inherit; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); }
.num, .tnum { font-variant-numeric: tabular-nums; }

/* buttons: 6px radius for controls, 8px for panels, 12px for dialogs */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 16px; border-radius: 6px; border: 1px solid var(--line);
  background: var(--panel2); cursor: pointer; font-weight: 600; transition: background-color .12s, border-color .12s; white-space: nowrap; }
.btn:hover { border-color: var(--line-strong); text-decoration: none; background: color-mix(in srgb, var(--panel2) 85%, var(--text)); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--accent); border-color: transparent; color: var(--on-accent); }
.btn.primary:hover { background: color-mix(in srgb, var(--accent) 88%, #fff); }
.btn.steam { background: #171a21; border-color: #2a475e; color: #fff; }
.btn.steam:hover { background: #1b2838; }
.btn.discord { background: var(--discord); border-color: transparent; color: #fff; }
.btn.discord:hover { background: #4752c4; }
.btn.danger { background: var(--err-bg); border-color: var(--err-line); color: var(--err); }
.btn.danger:hover { background: color-mix(in srgb, var(--err-bg) 80%, var(--err)); }
.btn.sm { padding: 5px 10px; font-size: 13px; border-radius: 5px; }
.btn.lg { padding: 12px 20px; font-size: 16px; }
.btn svg { width: 20px; height: 20px; fill: currentColor; }

/* forms */
label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; font-weight: 600; }
input, select, textarea { width: 100%; background: var(--bg2); border: 1px solid var(--line); border-radius: 6px; padding: 9px 11px; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); }
.field { margin-bottom: 14px; }
.row { display: flex; gap: 12px; } .row > * { flex: 1; }

/* ---------- shared page chrome (nav, logo, footer) ---------- */
.nav { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); }
.nav-in { max-width: 1160px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 28px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 750; font-size: 18px; font-stretch: 115%; color: var(--text); letter-spacing: -.01em; }
.logo:hover { text-decoration: none; }
.logo-mark { width: 28px; height: 28px; border-radius: 5px; background: var(--accent); display: grid; place-items: center; color: var(--on-accent); }
.logo-mark svg { width: 22px; height: 22px; fill: currentColor; }
.logo-mark .eye { fill: var(--accent); }
.logo-mark .scan { fill: none; stroke: currentColor; stroke-width: 22; stroke-linecap: round; opacity: .55; }
.nav-links { display: flex; gap: 24px; margin-left: 8px; } .nav-links a { color: var(--muted); font-weight: 500; } .nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-right { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.cta { display: flex; gap: 10px; flex-wrap: wrap; }
.err-banner { background: var(--err-bg); border: 1px solid var(--err-line); color: var(--err); padding: 10px 14px; border-radius: 6px; margin-bottom: 18px; }

/* console text (homepage demo + dashboard share these colours) */
.term-body { padding: 14px 16px; font: 13px/1.65 var(--mono); }
.term-body .t-in { color: var(--accent); } .term-body .t-ok { color: var(--ok); } .term-body .t-dim { color: var(--muted); } .term-body .t-warn { color: var(--warn); }
.caret { display: inline-block; width: 8px; height: 15px; background: var(--text); vertical-align: -2px; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }

section.block { padding: 88px 0; }
section.block h2 { font-size: clamp(26px, 3vw, 34px); text-align: left; }
section.block .sub { color: var(--muted); margin: 12px 0 40px; max-width: 56ch; font-size: 17px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 20px; }
.card h3 { font-size: 16px; margin: 0 0 6px; } .card p { color: var(--muted); margin: 0; font-size: 14px; }
footer { padding: 28px 0 36px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--line); }

.modal-bg { position: fixed; inset: 0; background: rgba(5,6,8,.75); backdrop-filter: blur(4px); display: grid; place-items: center; z-index: 100; padding: 16px; }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 26px; width: 100%; max-width: 420px; max-height: 92vh; overflow: auto; }
.modal.wide { max-width: 560px; }
.modal h3 { font-size: 20px; margin-bottom: 4px; } .modal .sub { color: var(--muted); margin: 0 0 20px; font-size: 14px; }
.modal .stack { display: grid; gap: 10px; }
.modal .actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; margin-top: 18px; }

/* ---------- client app ---------- */
body.app { overflow: hidden; }
.shell { display: grid; grid-template-columns: 264px minmax(0, 1fr); height: 100vh; height: 100dvh; }
.user { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--panel2) center/cover; border: 1px solid var(--line); flex: none; }
.status { width: 9px; height: 9px; border-radius: 50%; background: var(--line-strong); flex: none; }
.status.online { background: var(--ok); } .status.connecting { background: var(--warn); } .status.error { background: var(--err); }
.badge { font-size: 11px; padding: 1px 7px; border-radius: 99px; background: var(--panel2); border: 1px solid var(--line); color: var(--muted); }
.main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.empty { margin: auto; text-align: center; padding: 30px; max-width: 420px; } .empty h2 { margin-bottom: 8px; } .empty p { color: var(--muted); margin-bottom: 18px; }
.pane { flex: 1; min-height: 0; display: none; flex-direction: column; } .pane.active { display: flex; }
.pane-pad { padding: 20px; overflow: auto; }

.console { flex: 1; min-height: 0; display: flex; flex-direction: column; background: var(--console); }
.c-tools { display: flex; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--bg2); align-items: center; }
.c-tools input[type=search] { max-width: 240px; padding: 5px 10px; font-size: 13px; }
.c-tools label.chk { display: flex; align-items: center; gap: 6px; margin: 0; cursor: pointer; font-weight: 500; } .c-tools input[type=checkbox] { width: auto; }
.c-out { flex: 1; overflow: auto; padding: 10px 14px; font: 13px/1.5 var(--mono); }
.ln { white-space: pre-wrap; word-break: break-word; } .ln .ts { color: var(--muted); margin-right: 8px; user-select: none; }
.ln.in { color: var(--accent); } .ln.in .who { color: var(--muted); } .ln.err { color: var(--err); } .ln.warn { color: var(--warn); } .ln.sys { color: var(--muted); font-style: italic; } .ln.chat { color: color-mix(in srgb, var(--accent) 55%, var(--text)); } .ln.out { color: var(--text); }
.c-in { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--line); background: var(--bg2); }
.c-in .prompt { color: var(--accent); font: 700 14px var(--mono); } .c-in input { font-family: var(--mono); background: var(--console); }
.macros { display: flex; gap: 6px; flex-wrap: wrap; padding: 8px 14px 0; background: var(--bg2); border-top: 1px solid var(--line); }
.macros:empty { display: none; }

table.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: 12px; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:hover td { background: rgba(255,255,255,.02); }
.tbl .act { text-align: right; white-space: nowrap; display: flex; gap: 6px; justify-content: flex-end; }
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; } .toolbar input { max-width: 280px; }
.section-title { font-size: 13px; color: var(--muted); margin: 24px 0 10px; font-weight: 700; }
.box { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px; }
.inline-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; } .inline-form .field { margin: 0; flex: 1; min-width: 140px; }
.invite-url { font-family: var(--mono); font-size: 12px; background: var(--bg2); padding: 6px 8px; border-radius: 6px; user-select: all; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 380px; }
.toast-host { position: fixed; bottom: 18px; right: 18px; display: grid; gap: 8px; z-index: 200; }
.toast { background: var(--panel2); border: 1px solid var(--line); padding: 10px 14px; border-radius: 8px; box-shadow: 0 8px 30px rgba(0,0,0,.4); max-width: 340px; } .toast.err { border-color: var(--err-line); color: var(--err); } .toast.ok { border-color: var(--ok-line); }
.player-name { display: flex; align-items: center; gap: 8px; }

@media (max-width: 860px) {
  .hero-grid, .grid3 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .shell { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); }
}

/* ---------- overview ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; min-width: 0; }
.stat .k { font-size: 12px; color: var(--muted); font-weight: 600; }
.stat .v { font: 700 26px var(--sans); font-variant-numeric: tabular-nums; margin-top: 4px; font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.stat .v small { font-size: 13px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.chart-box { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px; }
.chart-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; flex-wrap: wrap; }
.chart-head h3 { font: 600 14px var(--sans); }
.seg { display: flex; border: 1px solid var(--line); border-radius: 7px; overflow: hidden; }
.seg button { background: none; border: 0; padding: 4px 10px; cursor: pointer; color: var(--muted); font: 600 12px var(--sans); font-variant-numeric: tabular-nums; }
.seg button.on { background: var(--panel2); color: var(--text); }
.chart-box svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart-box .gl { stroke: var(--line); stroke-width: 1; } .chart-box .tx { fill: var(--muted); font: 11px var(--sans); font-variant-numeric: tabular-nums; }
.chart-box .ln-s { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; } .chart-box .pt { fill: var(--accent); }
.c-sugg { position: relative; flex: 1; display: flex; }
.test-ok { background: var(--ok-bg); border: 1px solid var(--ok-line); color: var(--ok); padding: 10px 14px; border-radius: 8px; margin-bottom: 14px; }
.band h2 { font-family: var(--mono); }

/* ---------- players ---------- */
.pl-top { display: flex; align-items: flex-end; gap: 18px; flex-wrap: wrap; margin-bottom: 16px; }
.pl-count { font: 800 44px/1 var(--sans); font-variant-numeric: tabular-nums; font-variant-numeric: tabular-nums; }
.pl-count small { font: 500 14px var(--sans); color: var(--muted); letter-spacing: 0; margin-left: 8px; }
.pl-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.pill-s { font-size: 12px; padding: 3px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); }
.pl-tools { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.pl-tools input { width: 250px; } .pl-tools select { width: auto; }
.pl-card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.pl-row { display: grid; grid-template-columns: minmax(0, 1fr) 120px 100px 130px; gap: 16px; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.pl-row:last-child { border-bottom: 0; }
.pl-row:not(.pl-hd):hover { background: rgba(255,255,255,.025); }
.pl-hd { padding-block: 9px; background: var(--bg2); font-size: 11px; color: var(--muted); font-weight: 600; }
.pl-who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.pl-av { width: 36px; height: 36px; border-radius: 50%; flex: none; display: grid; place-items: center; font: 700 14px var(--sans); font-variant-numeric: tabular-nums; background: var(--accent-soft); color: var(--accent); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); }
.pl-nm { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; color: var(--text); }
a.pl-nm:hover { color: var(--accent); text-decoration: none; }
.pl-id { font: 12px var(--mono); color: var(--muted); background: none; border: 0; padding: 0; cursor: copy; text-align: left; }
.pl-id:hover { color: var(--text); }
.pl-info { min-width: 0; display: flex; flex-direction: column; }
.ping { display: inline-flex; align-items: center; gap: 8px; font: 500 13px var(--sans); font-variant-numeric: tabular-nums; font-variant-numeric: tabular-nums; }
.bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.bars i { width: 3px; background: var(--line); border-radius: 1px; } .bars i:nth-child(1) { height: 5px; } .bars i:nth-child(2) { height: 8px; } .bars i:nth-child(3) { height: 11px; } .bars i:nth-child(4) { height: 14px; }
.ping.good .bars i.on { background: var(--ok); } .ping.ok .bars i.on { background: var(--warn); } .ping.bad .bars i.on { background: var(--err); }
.pl-time { font: 13px var(--sans); font-variant-numeric: tabular-nums; color: var(--muted); font-variant-numeric: tabular-nums; }
.pl-act { display: flex; gap: 6px; justify-content: flex-end; }
.pl-empty { padding: 44px 16px; text-align: center; color: var(--muted); }
.pl-empty b { display: block; color: var(--text); font-size: 16px; margin-bottom: 4px; }
@media (max-width: 760px) { .pl-row { grid-template-columns: minmax(0, 1fr) auto; } .pl-row .ping, .pl-row .pl-time { display: none; } .pl-hd { display: none; } .pl-tools { margin-left: 0; width: 100%; } .pl-tools input { flex: 1; width: auto; min-width: 0; } }

/* ---------- ban / kick dialog ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chip { background: var(--bg2); border: 1px solid var(--line); color: var(--muted); border-radius: 99px; padding: 4px 12px; font-size: 13px; cursor: pointer; }
.chip:hover { color: var(--text); border-color: var(--line-strong); }
.chip.on { background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 45%, transparent); color: var(--accent); }
.dur-custom { display: flex; gap: 8px; margin-top: 8px; } .dur-custom input { width: 110px; } .dur-custom select { width: auto; }
.who-box { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; margin-bottom: 16px; }

/* ---------- bans ---------- */
.ban-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(150px, auto) auto; gap: 16px; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.ban-row:last-child { border-bottom: 0; } .ban-row .rs { color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.tag { font-size: 12px; padding: 2px 9px; border-radius: 99px; border: 1px solid var(--line); background: var(--bg2); color: var(--muted); white-space: nowrap; }
.tag.perm { color: var(--err); border-color: var(--err-line); background: var(--err-bg); } .tag.timed { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 35%, transparent); background: var(--accent-soft); }
@media (max-width: 760px) { .ban-row { grid-template-columns: 1fr auto; } .ban-row .rs { grid-column: 1 / -1; } }
.stat .sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.stats.second .stat { background: transparent; }
.rust-help { font-size: 12.5px; color: var(--muted); background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin-bottom: 14px; }
.rust-help code { font-family: var(--mono); color: var(--text); }
pre.cfg { background: var(--console); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; font: 13px/1.6 var(--mono); overflow-x: auto; margin: 14px 0 0; color: var(--text); }
pre.cfg .k { color: var(--accent); } pre.cfg .c { color: var(--muted); }

/* ---------- sidebar user ---------- */
.u-meta { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.u-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.u-prov { font-size: 12px; color: var(--muted); }
.icon-btn { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 8px; border: 1px solid transparent; background: none; color: var(--muted); cursor: pointer; flex: none; }
.icon-btn:hover { background: var(--panel2); color: var(--text); border-color: var(--line); }
.icon-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- overview v2 ---------- */
.ov { display: grid; gap: 16px; }
.ov-top { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 2fr); gap: 16px; }
.ov-card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; min-width: 0; }
.ov-k { font-size: 12px; color: var(--muted); font-weight: 600; }
.ov-big { font: 800 40px/1.1 var(--sans); font-variant-numeric: tabular-nums; margin-top: 6px; font-variant-numeric: tabular-nums; }
.ov-big small { font: 500 16px var(--sans); font-variant-numeric: tabular-nums; color: var(--muted); letter-spacing: 0; }
.cap { height: 6px; border-radius: 99px; background: var(--bg2); margin: 14px 0 10px; overflow: hidden; border: 1px solid var(--line); }
.cap > i { display: block; height: 100%; background: var(--accent); border-radius: 99px; transition: width .4s; }
.ov-sub { font-size: 13px; color: var(--muted); }
.kv-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kv { padding: 4px 16px 4px 0; min-width: 0; }
.kv + .kv { border-left: 1px solid var(--line); padding-left: 16px; }
.kv:nth-child(3n+1) { border-left: 0; padding-left: 0; }
.kv:nth-child(n+4) { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.kv .v { font: 700 20px var(--sans); font-variant-numeric: tabular-nums; margin-top: 4px; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.kv .s { font-size: 12px; color: var(--muted); margin-top: 1px; }
.status-pill { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; padding: 3px 10px 3px 8px; border-radius: 99px; border: 1px solid var(--line); background: var(--bg2); }
@media (max-width: 1000px) { .ov-top { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .kv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .kv:nth-child(3n+1) { border-left: 1px solid var(--line); padding-left: 16px; } .kv:nth-child(odd) { border-left: 0; padding-left: 0; } .kv:nth-child(n+3) { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); } }

/* ---------- linked servers + account ---------- */
.linked { border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); }
.linked-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; }
.linked-head b { font-size: 13px; } .linked-head .muted { font-size: 12px; }
.linked-list { border-top: 1px solid var(--line); max-height: 168px; overflow: auto; padding: 4px 0; }
.chk-row { display: flex; align-items: center; gap: 10px; padding: 7px 12px; margin: 0; cursor: pointer; font-weight: 500; color: var(--text); font-size: 14px; }
.chk-row:hover { background: var(--panel); }
.chk-row input { width: 16px; height: 16px; accent-color: var(--accent2); flex: none; }
.chk-row .r { margin-left: auto; font-size: 12px; color: var(--muted); }
.tag.net { color: #cbbcff; border-color: #3d3466; background: #1b1730; }
.tag.pend { color: var(--warn); border-color: var(--warn-line); background: var(--warn-bg); }
.tags { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.acct-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.acct-row:first-of-type { border-top: 0; } .acct-row > div { flex: 1; min-width: 0; } .acct-row p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.acct-id { display: flex; align-items: center; gap: 12px; padding: 12px; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; margin-bottom: 6px; }
.acct-id .avatar { width: 40px; height: 40px; }
.icon-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
@media (max-width: 560px) {
  .pane-pad { padding: 16px; }
  .pl-count { font-size: 36px; }
}
.avatar { display: grid; place-items: center; font: 700 13px var(--sans); font-variant-numeric: tabular-nums; color: var(--accent); background-color: var(--accent-soft); }
.toolbar { flex-wrap: wrap; }
.kv .v { font-size: 18px; }
@media (max-width: 560px) { .toolbar > .muted { display: none; } .toolbar > .btn { margin-left: auto; } }

/* ================= v5: features ================= */
.hint { font-size: 12px; color: var(--muted); margin-top: 5px; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--text); font-weight: 600; cursor: pointer; text-align: left; }
.linkish:hover { color: var(--accent); }
.danger-text { color: var(--err) !important; }
.ic { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.btn svg.ic, .icon-btn svg.ic { width: 15px; height: 15px; fill: none; }
.num { font-variant-numeric: tabular-nums; }
.clickable { cursor: pointer; }
.c-tools-r { margin-left: auto; display: flex; gap: 8px; }
.seg-lg button { padding: 6px 12px; font-size: 13px; }
.tag.on { color: var(--ok); border-color: var(--ok-line); background: var(--ok-bg); }
textarea { resize: vertical; min-height: 64px; font: inherit; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.form-grid { display: grid; gap: 2px; max-width: 680px; }

/* overview v3 */
.qa { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.qa-say { flex: 1 1 320px; display: flex; align-items: center; gap: 10px; min-width: 0; }
.qa-say .ic { color: var(--muted); margin-left: 4px; }
.qa-say input { background: var(--bg2); }
.qa-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.ov-split { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(280px, 1fr); gap: 16px; }
.chart-box, .feed-box { min-width: 0; }
.chart-head { gap: 10px; }
.chart-empty { padding: 60px 0; text-align: center; }
.chart-box .hv { stroke: var(--muted); stroke-dasharray: 3 3; }
.chart-box .tip-bg { fill: var(--panel2); stroke: var(--line); }
.chart-box .tip { fill: var(--text); font: 600 11px var(--sans); font-variant-numeric: tabular-nums; }
.chart-box .ln-s { stroke: var(--accent); } .chart-box .pt { fill: var(--accent); }
.feed-box { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px 16px 8px; display: flex; flex-direction: column; contain: size; min-height: 280px; } /* the chart sets the row height; the feed scrolls */
.feed-box h3 { font: 600 14px var(--sans); }
.live-dot { font-size: 11px; color: var(--ok); display: inline-flex; align-items: center; gap: 6px; font-weight: 700; }
.live-dot::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.feed { list-style: none; margin: 0; padding: 0; overflow: auto; flex: 1; }
.feed-item { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13.5px; }
.feed-item:first-child { border-top: 0; }
.feed-ic { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; background: var(--bg2); color: var(--muted); }
.feed-ic .ic { width: 13px; height: 13px; }
.feed-item.join .feed-ic { color: var(--ok); background: var(--ok-bg); } .feed-item.leave .feed-ic { color: var(--muted); }
.feed-item.kick .feed-ic, .feed-item.restart .feed-ic { color: var(--warn); background: var(--warn-bg); }
.feed-item.ban .feed-ic { color: var(--err); background: var(--err-bg); } .feed-item.unban .feed-ic { color: var(--ok); background: var(--ok-bg); }
.feed-item.task .feed-ic { color: var(--accent); background: var(--accent-soft); }
.feed-detail { font-size: 12px; color: var(--muted); margin-top: 1px; overflow-wrap: anywhere; }
.feed-t { font-size: 11.5px; color: var(--muted); white-space: nowrap; padding-top: 2px; }
.feed-empty { color: var(--muted); font-size: 13px; padding: 20px 4px; text-align: center; }
.feed.compact .feed-item { padding: 6px 0; }
@media (max-width: 1100px) { .ov-split { grid-template-columns: 1fr; } .feed-box { contain: none; height: 360px; } }

/* console + chat */
.c-tools { flex-wrap: wrap; }
.chat { flex: 1; min-height: 0; display: flex; flex-direction: column; background: var(--console); }
.chat-out { flex: 1; overflow: auto; padding: 12px 16px; display: flex; flex-direction: column; gap: 2px; }
.msg { display: flex; gap: 10px; align-items: baseline; padding: 5px 8px; border-radius: 6px; font-size: 14px; line-height: 1.45; }
.msg:hover { background: rgba(255,255,255,.03); }
.msg time { font: 12px var(--mono); color: var(--muted); flex: none; }
.msg .ch { font: 700 10px var(--sans); font-variant-numeric: tabular-nums; color: var(--ok); border: 1px solid var(--ok-line); border-radius: 4px; padding: 0 4px; flex: none; }
.msg-name { flex: none; color: var(--accent) !important; } .msg-name.server { color: var(--warn) !important; }
.msg-text { overflow-wrap: anywhere; min-width: 0; }
.msg.team .msg-text { color: color-mix(in srgb, var(--ok) 45%, var(--text)); }
.chat .c-in .prompt .ic { width: 17px; height: 17px; color: var(--muted); }

/* players: history table */
.hist-row { display: grid; grid-template-columns: minmax(0, 1.6fr) 120px 90px 110px 120px; gap: 14px; align-items: center; padding: 11px 16px; border-bottom: 1px solid var(--line); }
.hist-row:last-child { border-bottom: 0; }
.hist-row.clickable:hover, .pl-row.clickable:hover { background: rgba(255,255,255,.03); }
.hist-row:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.pl-top .seg { margin-bottom: 10px; width: fit-content; }
button.pl-nm { font-size: 15px; }
@media (max-width: 760px) { .hist-row { grid-template-columns: minmax(0, 1fr) auto; } .hist-row > :nth-child(n+3) { display: none; } }

/* drawer */
.drawer-bg { position: fixed; inset: 0; background: rgba(5,6,8,.55); z-index: 90; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(440px, 100vw); background: var(--panel); border-left: 1px solid var(--line); z-index: 91; display: flex; flex-direction: column; box-shadow: -20px 0 60px rgba(0,0,0,.5); animation: slideIn .18s ease-out; padding-bottom: env(safe-area-inset-bottom, 0px); }
@keyframes slideIn { from { transform: translateX(24px); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .drawer { animation: none; } }
.drawer-load { padding: 40px; color: var(--muted); text-align: center; }
.drawer-head { display: flex; gap: 14px; align-items: center; padding: 20px 20px 10px; }
.drawer-head h3 { font: 700 20px var(--sans); overflow-wrap: anywhere; }
.drawer-head .pl-info { flex: 1; min-width: 0; }
.pl-av.lg { width: 52px; height: 52px; font-size: 20px; }
.drawer-tags { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding: 0 20px 12px; }
.drawer-actions { display: flex; gap: 8px; flex-wrap: wrap; padding: 0 20px 16px; border-bottom: 1px solid var(--line); }
.drawer-body { overflow: auto; flex: 1; padding: 16px 20px 24px; display: grid; gap: 22px; align-content: start; }
.dstats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.dstat { background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 10px; min-width: 0; }
.dstat .v { font: 700 15px var(--sans); font-variant-numeric: tabular-nums; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dstat .ov-k { font-size: 10.5px; }
.dsec h4 { margin: 0 0 8px; font-size: 12px; color: var(--muted); }
.note-add { display: grid; gap: 8px; margin-bottom: 10px; } .note-add .btn { justify-self: end; }
.note { background: var(--bg2); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 8px; padding: 10px 12px; margin-top: 8px; }
.note p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.note-meta { font-size: 12px; color: var(--muted); margin-top: 6px; display: flex; gap: 10px; }
.dline { display: flex; gap: 10px; align-items: baseline; padding: 6px 0; border-top: 1px solid var(--line); font-size: 13.5px; flex-wrap: wrap; }
.dline:first-of-type { border-top: 0; }
.dline .muted { margin-left: auto; font-size: 12px; }
.chatline time { font: 11.5px var(--mono); color: var(--muted); }
.chatline .ch { font: 700 10px var(--sans); font-variant-numeric: tabular-nums; color: var(--ok); }
.chip.static { cursor: default; }

/* schedules */
.sched-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.sched { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.sched.off { opacity: .62; }
.sched-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.sched-when { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--accent); margin-top: 3px; font-weight: 600; }
.sched-cmd { display: block; font: 12.5px var(--mono); background: var(--console); border: 1px solid var(--line); border-radius: 6px; padding: 7px 10px; overflow-wrap: anywhere; color: var(--text); }
.sched-meta { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.sched-act { display: flex; gap: 6px; flex-wrap: wrap; }
.switch { position: relative; width: 38px; height: 22px; flex: none; margin: 0; cursor: pointer; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: var(--panel2); border: 1px solid var(--line); transition: .15s; }
.switch span::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--muted); transition: .15s; }
.switch input:checked + span { background: var(--accent-soft); border-color: var(--accent-line); }
.switch input:checked + span::after { transform: translateX(16px); background: var(--accent); }
.switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* plugins */
.plug-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 16px; align-items: center; padding: 11px 16px; border-bottom: 1px solid var(--line); }
.plug-row:last-child { border-bottom: 0; }
.plug-v { color: var(--muted); font: 500 12px var(--sans); font-variant-numeric: tabular-nums; }
pre.raw { margin: 0; padding: 16px; font: 12.5px/1.5 var(--mono); white-space: pre-wrap; color: var(--muted); }
@media (max-width: 640px) { .plug-row { grid-template-columns: minmax(0, 1fr) auto; } .plug-row > .muted { display: none; } }

/* manage */
.manage { display: grid; grid-template-columns: 200px minmax(0, 1fr); min-height: 0; height: 100%; }
.manage-content { padding: 20px 24px; overflow: auto; min-width: 0; }
.sub-head { margin-bottom: 16px; } .sub-head h3 { font-size: 18px; } .sub-head p { color: var(--muted); margin: 4px 0 0; font-size: 14px; max-width: 640px; }
.hdr-prev img { max-width: 100%; width: 320px; aspect-ratio: 2 / 1; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); margin: -4px 0 14px; display: block; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); padding: 4px 0; }
.member { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto auto; gap: 12px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.member:last-child { border-bottom: 0; }
.invite { display: flex; gap: 10px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.macro-row { display: flex; gap: 10px; align-items: center; margin-top: 10px; flex-wrap: wrap; }
@media (max-width: 760px) {
  .manage { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); }
  .manage-content { padding: 16px; }
}

/* accent swatches */
.swatches { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.swatch { display: inline-flex; align-items: center; gap: 7px; background: var(--bg2); border: 1px solid var(--line); border-radius: 99px; padding: 4px 11px 4px 5px; color: var(--muted); font-size: 13px; cursor: pointer; }
.swatch span { width: 18px; height: 18px; border-radius: 50%; background: var(--sw); }
.swatch:hover { color: var(--text); }
.swatch.on { color: var(--text); border-color: var(--sw); box-shadow: 0 0 0 1px var(--sw); }
.swatch:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pane > .manage { flex: 1; }

.feed-item.mute .feed-ic { color: var(--warn); background: var(--warn-bg); } .feed-item.unmute .feed-ic { color: var(--ok); background: var(--ok-bg); }

/* ================= homepage ================= */
body.lp { overflow-x: hidden; }
.lp .nav-links a { font-size: 15px; }


/* product shot: the real dashboard, dark, sitting on the hero's bottom edge */
.lp-shot { position: relative; margin-top: 56px; color: var(--text); }
.shot-win { background: var(--panel); border: 1px solid var(--line-strong); border-bottom: 0; border-radius: 10px 10px 0 0; overflow: hidden; box-shadow: 0 -1px 0 rgba(0,0,0,.04), 0 24px 60px -20px rgba(0,0,0,.55); }
.shot-top { display: flex; gap: 14px; align-items: center; padding: 12px 18px; background: var(--bg2); font-size: 14px; }
.shot-top b { font-size: 15px; }
.shot-on { display: inline-flex; align-items: center; gap: 6px; color: var(--ok); font-size: 13px; font-weight: 600; }
.shot-on::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); }
.shot-ip { margin-left: auto; font: 12.5px var(--mono); color: var(--muted); }
.shot-tabs { display: flex; gap: 22px; padding: 0 18px; background: var(--bg2); border-bottom: 1px solid var(--line); font-size: 13.5px; font-weight: 600; color: var(--muted); }
.shot-tabs span { padding: 9px 0; border-bottom: 2px solid transparent; }
.shot-tabs .on { color: var(--text); border-bottom-color: var(--accent); }
.shot-body { display: grid; grid-template-columns: minmax(0, 1fr) 280px; }
.shot-main { padding: 18px; display: grid; gap: 14px; min-width: 0; }
.shot-stats { display: grid; grid-template-columns: 1.4fr 1fr 1fr; border: 1px solid var(--line); border-radius: 8px; }
.shot-stats > div { padding: 12px 14px; min-width: 0; }
.shot-stats > div + div { border-left: 1px solid var(--line); }
.shot-stats span { display: block; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.shot-stats b { font: 700 26px var(--sans); font-variant-numeric: tabular-nums; } .shot-stats small { font-size: 14px; color: var(--muted); font-weight: 500; }
.shot-cap { display: block; height: 4px; border-radius: 2px; background: var(--panel2); margin-top: 8px; overflow: hidden; } .shot-cap i { display: block; height: 100%; background: var(--accent); }
.shot-console { background: var(--console); border: 1px solid var(--line); border-radius: 8px; height: 228px; overflow: hidden; }
.shot-side { border-left: 1px solid var(--line); padding: 16px 18px; font-size: 13.5px; min-width: 0; }
.shot-h { font-size: 12.5px; color: var(--muted); font-weight: 600; margin-bottom: 6px; }
.shot-h2 { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.shot-p { display: flex; gap: 10px; align-items: center; padding: 4px 0; }
.shot-p i { width: 22px; height: 22px; border-radius: 50%; background: var(--panel2); color: var(--muted); display: grid; place-items: center; font: 700 10.5px var(--sans); font-style: normal; }
.shot-p span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .shot-p em { font: 12px var(--sans); font-variant-numeric: tabular-nums; color: var(--muted); font-style: normal; }
.sf { padding: 3px 0 3px 10px; border-left: 2px solid var(--line); margin: 5px 0; }
.sf.join { border-color: var(--ok); } .sf.kick, .sf.mute { border-color: var(--warn); } .sf.ban { border-color: var(--err); } .sf.leave { color: var(--muted); }
.shot-discord { position: absolute; right: 312px; bottom: 28px; width: min(340px, 80%); background: #313338; color: #dbdee1; border-radius: 8px; padding: 12px 14px; box-shadow: 0 18px 40px rgba(0,0,0,.35); font-size: 13px; }
.dm-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.dm-av { width: 26px; height: 26px; border-radius: 50%; }
.dm-head b { color: #fff; } .dm-t { color: #949ba4; font-size: 11px; }
.dm-bot { background: #5865f2; color: #fff; font-size: 10px; font-weight: 700; border-radius: 4px; padding: 0 4px; }
.dm-embed { border-left: 4px solid #ff6b7a; background: #2b2d31; border-radius: 4px; padding: 8px 10px; display: grid; gap: 2px; }
.dm-embed b { color: #fff; } .dm-embed span { color: #b5bac1; font-size: 12.5px; }

.lp-chat { background: var(--console); color: var(--text); border-radius: 10px; padding: 14px 10px; display: grid; gap: 2px; box-shadow: 0 20px 50px -24px rgba(0,0,0,.55); }
.lp-mini { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 16px; display: grid; gap: 12px; box-shadow: 0 20px 50px -28px rgba(0,0,0,.55); }
.lp-mini-h { display: flex; gap: 12px; align-items: center; } .lp-mini-h > div { flex: 1; min-width: 0; display: flex; flex-direction: column; } .lp-mini-h small { font: 12px var(--mono); color: var(--muted); }
.lp-mini-g { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: 6px; } .lp-mini-g > div { padding: 8px 10px; } .lp-mini-g > div + div { border-left: 1px solid var(--line); }
.lp-mini-g span { display: block; font-size: 12px; color: var(--muted); } .lp-mini-g b { font: 700 15px var(--sans); font-variant-numeric: tabular-nums; }
.lp-note { border-left: 3px solid var(--accent); background: var(--bg2); border-radius: 4px; padding: 8px 10px; font-size: 13.5px; } .lp-note small { display: block; color: var(--muted); margin-top: 3px; }
.lp-mini-ban { margin-left: 48px; } .lp-mini-ban .chips { margin: 0; }
.lp-mini-row { display: flex; gap: 8px; align-items: center; font-size: 13.5px; } .lp-mini-row small { margin-left: auto; color: var(--muted); }
.chk-fake { width: 16px; height: 16px; border-radius: 3px; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; font-size: 11px; font-weight: 800; }
.discord-mock { background: #313338; color: #dbdee1; border-radius: 10px; padding: 18px; display: grid; gap: 10px; font-size: 14px; box-shadow: 0 20px 50px -24px rgba(0,0,0,.55); }
.dc-line { display: flex; gap: 12px; align-items: flex-start; } .dc-line b { color: #fff; }
.dc-av { width: 36px; height: 36px; border-radius: 50%; flex: none; }
.dc-t { color: #949ba4; font-size: 13px; }
.dc-embed { margin-top: 8px; border-left: 4px solid #ff6b7a; background: #2b2d31; border-radius: 4px; padding: 10px 12px; display: grid; gap: 3px; } .dc-embed b { color: #fff; } .dc-embed span { color: #b5bac1; font-size: 13px; } .dc-embed small { color: #949ba4; font-size: 11.5px; margin-top: 4px; }


pre.cfg { background: var(--console); color: var(--text); border-radius: 6px; padding: 12px 14px; font: 13px/1.6 var(--mono); overflow-x: auto; margin: 14px 0 0; border: 1px solid var(--line); }
pre.cfg .k { color: var(--accent); } pre.cfg .c { color: var(--muted); }

.lp-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px 20px; flex-wrap: wrap; }
.lp-foot .logo { font-size: 15px; }

@media (max-width: 960px) {
  .shot-discord { right: 12px; }
  .lp-mini-ban { margin-left: 0; }
}
@media (max-width: 700px) {
  .shot-body { grid-template-columns: 1fr; } .shot-side { display: none; }
  .shot-ip, .shot-tabs span:nth-child(n+4) { display: none; }
  .shot-stats { grid-template-columns: 1fr 1fr; } .shot-stats > div:last-child { display: none; }
  .shot-discord { position: relative; right: auto; bottom: auto; width: auto; margin: -40px 12px 0; }
}

/* discord alerts */
.alerts-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(260px, 1fr); gap: 20px; align-items: start; max-width: 1040px; }
.howto { margin: 0 0 14px; padding-left: 20px; color: var(--muted); font-size: 14px; display: grid; gap: 6px; } .howto b { color: var(--text); }
.dc-prev { background: #313338; color: #dbdee1; border-radius: 10px; padding: 14px; display: grid; gap: 8px; font-size: 13.5px; }
.dc-prev-head { display: flex; gap: 10px; align-items: center; } .dc-prev-head img { border-radius: 50%; } .dc-prev-head b { color: #fff; }
.dc-prev .dm-embed { margin-left: 50px; } .dc-prev .dm-embed small { color: #949ba4; font-size: 11.5px; margin-top: 4px; }
@media (max-width: 900px) { .alerts-grid { grid-template-columns: 1fr; } }

.dc-embed.kick, .dc-embed.mute { border-left-color: #f0a66b; }
img.dm-av, img.dc-av { border-radius: 50%; object-fit: cover; }
.discord-mock .dc-line > div { min-width: 0; flex: 1; }

/* public status page */
body.status-page { min-height: 100vh; }
.st-wrap { max-width: 980px; margin: 0 auto; padding: 40px 20px 30px; display: grid; gap: 16px; }
.st-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.st-head h1 { font-size: clamp(26px, 4vw, 38px); letter-spacing: -.01em; margin-top: 10px; }
.st-head p { margin: 6px 0 0; }
.st-brand { font-size: 15px; } .st-brand img { border-radius: 7px; }
.st-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 16px; }
.st-kv { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.st-kv .kv:nth-child(3) { border-left: 0; padding-left: 0; }
.st-kv .kv:nth-child(n+3) { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.st-kv .kv:nth-child(4) { border-left: 1px solid var(--line); padding-left: 16px; }
.st-row { grid-template-columns: minmax(0, 1fr) auto !important; }
.st-embed { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; display: grid; gap: 10px; justify-items: start; }
.st-embed h3 { font-size: 16px; } .st-embed p { margin: 0; font-size: 14px; }
.code-row { display: flex; gap: 8px; align-items: center; width: 100%; min-width: 0; }
.code-row code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; font: 12.5px var(--mono); background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.st-foot { text-align: center; color: var(--muted); font-size: 13px; padding-top: 10px; }
@media (max-width: 720px) { .st-grid { grid-template-columns: 1fr; } }

/* v7: flags, groups, steam, webhooks, auto-mod, public */
.small { font-size: 12.5px; }
p.small { margin: 0; }
.flag { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 1px 8px; border-radius: 99px; color: var(--fc); background: color-mix(in srgb, var(--fc) 14%, transparent); border: 1px solid color-mix(in srgb, var(--fc) 40%, transparent); margin-left: 6px; vertical-align: 1px; white-space: nowrap; }
.drawer-tags .flag { margin-left: 0; }
.flag-chip .fdot { width: 9px; height: 9px; border-radius: 50%; background: var(--fc); display: inline-block; margin-right: 6px; }
.flag-chip.on { color: var(--fc); border-color: color-mix(in srgb, var(--fc) 55%, transparent); background: color-mix(in srgb, var(--fc) 13%, transparent); }
.dstats.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dstat.bad { border-color: var(--err-line); } .dstat.bad .v { color: var(--err); }
.groups { display: grid; gap: 10px; }
.grp-head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.groups .chip { font-family: var(--mono); font-size: 12.5px; }
.groups .chip:disabled { opacity: .7; cursor: default; }
.grp-new { display: flex; gap: 8px; } .grp-new input { max-width: 220px; padding: 6px 10px; font-size: 13px; }
.grp-vanilla { display: grid; gap: 8px; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 4px; }
.grp-vanilla:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.grp-vanilla .seg { width: fit-content; } .seg button:disabled { cursor: not-allowed; opacity: .6; }
.chk-row.small { padding: 2px 0; font-size: 12.5px; color: var(--muted); }
.hooks { display: grid; gap: 14px; min-width: 0; }
.hook { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: grid; gap: 12px; }
.hook-new { border-style: dashed; } .hook-new h4 { margin: 0; font-size: 15px; }
.hook-head { display: flex; gap: 10px; align-items: center; } .hook-head input { max-width: 260px; font-weight: 600; }
.hook-ic { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; background: #5865f2; color: #fff; flex: none; }
.hook-url summary { cursor: pointer; color: var(--muted); font-size: 13px; } .hook-url input { margin-top: 8px; }
.ev-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 4px 16px; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 6px; }
.ev-group .ov-k { padding: 0 6px 2px; font-size: 10.5px; }
.ev-group .chk-row { padding: 5px 6px; }
.alerts-side { position: sticky; top: 0; }
.dc-chat { margin-left: 50px; display: grid; gap: 2px; font-size: 13.5px; } .dc-chat b { color: #fff; } .dc-chat code { font: 700 10px var(--sans); font-variant-numeric: tabular-nums; background: #2b2d31; border-radius: 3px; padding: 0 4px; color: #b5bac1; }
.rule-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto auto; gap: 14px; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.rule-row:last-child { border-bottom: 0; } .rule-row.off > :not(.switch) { opacity: .55; }
.try { display: flex; gap: 10px; align-items: center; background: var(--bg2); border: 1px dashed var(--line); border-radius: 8px; padding: 8px 10px; } .try input { max-width: 300px; padding: 6px 10px; }
.color-pick { display: flex; gap: 6px; padding-top: 6px; }
.cdot { width: 24px; height: 24px; border-radius: 50%; border: 2px solid transparent; background: var(--fc); cursor: pointer; }
.cdot.on { border-color: var(--text); box-shadow: 0 0 0 2px var(--bg); }
.cdot:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.slug { display: flex; align-items: center; gap: 6px; } .slug input { max-width: 260px; }
.feed-item.watch .feed-ic { color: #ffc857; background: var(--warn-bg); } .feed-item.trigger .feed-ic { color: var(--warn); background: var(--warn-bg); }
@media (max-width: 760px) { .rule-row { grid-template-columns: auto minmax(0, 1fr) auto; } .rule-row > .tag, .rule-row > .num { display: none; } .dstats.three { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* heat maps */
.heat { display: grid; gap: 8px; overflow-x: auto; }
.heat-grid { display: grid; grid-template-columns: 34px repeat(24, minmax(14px, 1fr)); gap: 3px; min-width: 420px; }
.hx { font: 11px var(--sans); color: var(--muted); text-align: left; }
.hy { font: 12px var(--sans); color: var(--muted); align-self: center; }
.hc { aspect-ratio: 1; border-radius: 3px; background: color-mix(in srgb, var(--accent) calc(var(--k) * 100%), var(--bg2)); border: 1px solid color-mix(in srgb, var(--line) 60%, transparent); min-height: 12px; }
.heat-grid .hc:hover { outline: 2px solid var(--text); outline-offset: -1px; }
.heat-legend { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--muted); }
.heat-legend .hc { width: 12px; min-height: 12px; }
.heat-empty { padding: 10px 0; }
#busy-box { min-width: 0; }
.drawer .heat-grid { grid-template-columns: 30px repeat(24, minmax(10px, 1fr)); gap: 2px; min-width: 360px; }
.drawer .hc { min-height: 10px; border-radius: 2px; }
/* alts + bans elsewhere */
.warn-box { background: var(--err-bg); border: 1px solid var(--err-line); border-radius: 10px; padding: 12px 14px; }
.warn-box h4 { color: var(--err) !important; }
.alt-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.alt-row:first-of-type { border-top: 0; }
.alt-bans { grid-column: 1 / -1; display: flex; gap: 6px; flex-wrap: wrap; }
/* auto-kick */
.ak-rules { display: grid; gap: 2px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); padding: 4px; margin-bottom: 14px; }
.ak-rule { display: flex; gap: 12px; align-items: flex-start; padding: 10px; border-radius: 8px; margin: 0; color: var(--text); font-weight: 400; cursor: pointer; }
.ak-rule:hover { background: var(--panel); }
.ak-rule input[type=checkbox] { width: 17px; height: 17px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.ak-rule.disabled { opacity: .55; cursor: default; }
.num-in { width: 82px !important; display: inline-block; padding: 3px 8px !important; margin: 0 2px; font: 600 13px var(--sans); font-variant-numeric: tabular-nums; }
.feed-item.autokick .feed-ic { color: var(--err); background: var(--err-bg); }

/* chat auto-moderation */
.chat-body { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) 290px; }
.chat-main { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.chatmod-panel { border-left: 1px solid var(--line); background: var(--bg2); padding: 14px; overflow: auto; display: grid; gap: 14px; align-content: start; }
.cmp-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cmp-filters { display: grid; gap: 2px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 4px 10px; }
.cmp-filters.off { opacity: .5; }
.cmp-filter { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.cmp-filter:first-child { border-top: 0; }
.cmp-stat { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--muted); }
.cmp-stat b { color: var(--text); font-family: var(--mono); }
.cmp-recent { display: grid; gap: 8px; }
.cmp-ev { border-left: 2px solid var(--warn); padding-left: 8px; font-size: 13px; }
.msg.flagged { background: color-mix(in srgb, var(--warn) 7%, transparent); }
.msg-flag { font-size: 11px; font-weight: 600; color: var(--warn); border: 1px solid var(--warn-line); background: var(--warn-bg); border-radius: 99px; padding: 0 8px; white-space: nowrap; margin-left: auto; flex: none; }
.chatline .msg-flag { margin-left: 0; }
@media (max-width: 1000px) { .chat-body { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) auto; } .chatmod-panel { border-left: 0; border-top: 1px solid var(--line); max-height: 220px; } }
.cm-wrap { max-width: 900px; }
.cm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.cm-card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 10px; align-content: start; }
.cm-card-h { display: flex; gap: 10px; align-items: center; margin: 0; color: var(--text); cursor: pointer; }
.cm-card-h input { width: 17px; height: 17px; accent-color: var(--accent); }
.cm-line { font-size: 13.5px; color: var(--muted); display: flex; align-items: center; flex-wrap: wrap; gap: 4px; }
.cm-line input:not(.num-in) { flex: 1; min-width: 160px; padding: 5px 8px; font-size: 13px; }
.act-sel { width: auto; padding: 4px 8px; font-size: 13px; }
.ladder { display: grid; gap: 8px; margin: 10px 0 14px; justify-items: start; }
.rung { display: flex; gap: 8px; align-items: center; }
.rung select { width: auto; padding: 5px 8px; font-size: 13px; }
.rung-n { width: 34px; height: 26px; border-radius: 6px; display: grid; place-items: center; font: 700 12px var(--sans); font-variant-numeric: tabular-nums; background: var(--accent-soft); color: var(--accent); }
.cm-strikes .muted.small { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
/* shared: notice + switch rows (were defined with the old bot settings) */
.notice { background: color-mix(in srgb, var(--warn) 10%, transparent); border: 1px solid color-mix(in srgb, var(--warn) 35%, transparent); color: var(--text); padding: 12px 14px; border-radius: 10px; margin-bottom: 16px; font-size: 14px; max-width: 900px; }
.switch-row { display: flex; gap: 14px; align-items: flex-start; margin: 0; cursor: pointer; color: var(--text); font-weight: 400; font-size: 14px; }
.switch-row .switch { margin-top: 2px; }
.switch-row b { font-size: 15px; }
/* chat messages wrap nicely on narrow screens */
.msg { flex-wrap: wrap; }
.msg-text { flex: 1 1 180px; }
@media (max-width: 640px) { .msg-flag { margin-left: 0; } }

/* ================= phones ================= */
.mobile-only { display: none; }
@media (max-width: 860px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: inline-flex; }
  /* one compact top bar: logo · server switcher · account */
  .icon-btn { width: 40px; height: 40px; }
  .c-tools::-webkit-scrollbar { display: none; }
  /* toolbars: one swipeable row instead of stacking */
  .c-tools { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 8px 10px; }
  .c-tools > * { flex: none; }
  .c-tools input[type=search] { width: 150px; }
  .c-tools-r { margin-left: 0; }
  /* chat: full height; auto-mod lives behind a button */
  .chat-body { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr); }
  .chatmod-panel { display: none; }
  .chatmod-sheet { display: grid; gap: 14px; }
  .c-in { padding: 8px 10px; padding-bottom: max(8px, env(safe-area-inset-bottom, 0px)); }
  /* no iOS zoom-on-focus: inputs at 16px */
  input, select, textarea { font-size: 16px; }
  .num-in, .act-sel, .rung select { font-size: 15px !important; }
  /* dialogs become bottom sheets with buttons always in reach */
  .modal-bg { align-items: end; padding: 0; }
  .modal { max-width: none !important; width: 100%; border-radius: 16px 16px 0 0; max-height: 92dvh; padding: 20px 16px 0; animation: sheetUp .2s ease-out; }
  .modal .actions { position: sticky; bottom: 0; background: var(--panel); margin: 16px -16px 0; padding: 12px 16px; padding-bottom: max(12px, env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); flex-wrap: wrap; }
  .modal .actions .btn { flex: 1; }
  .toast-host { top: max(10px, env(safe-area-inset-top, 0px)); bottom: auto; left: 10px; right: 10px; }
  .toast { max-width: none; }
  .drawer-head { padding-top: max(20px, env(safe-area-inset-top, 0px)); }
  .pane-pad { padding: 14px 12px; }
  .ov-big { font-size: 34px; }
  .qa-btns { width: 100%; } .qa-btns .btn { flex: 1; }
}
@keyframes sheetUp { from { transform: translateY(30px); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .modal { animation: none !important; } }
.sheet-list { display: grid; gap: 6px; }
.sheet-srv { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg2); color: var(--text); text-align: left; cursor: pointer; font: inherit; }
.sheet-srv.on { border-color: var(--accent-line); background: var(--accent-soft); }
.sheet-srv .info { display: flex; flex-direction: column; min-width: 0; }

/* ---------- email sign-in (login modal) ---------- */
.email-auth .or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; margin: 18px 0 14px; }
.email-auth .or::before, .email-auth .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.email-auth .field { margin-bottom: 12px; }
.ea-submit { width: 100%; margin-top: 4px; }
.ea-links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-top: 12px; }
.linkish { background: none; border: 0; padding: 0; color: var(--accent); cursor: pointer; font-size: 14px; }
.linkish:hover { text-decoration: underline; }
.ea-err { color: var(--err); font-size: 14px; margin: 0 0 10px; }
.ea-msg { background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: 8px; padding: 9px 12px; font-size: 14px; margin: 0 0 12px; }

.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 14px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; overflow-wrap: anywhere; }
.ok-t { color: var(--ok); } .warn-t { color: var(--warn); } .err-t { color: var(--err); }
.mono { font-family: var(--mono); font-size: 13px; }

/* auto-mod: hate speech categories */
.cm-cats { display: grid; gap: 4px; margin: 6px 0 2px; }
.cm-cat { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--text); margin: 0; cursor: pointer; }
.cm-cat input { width: auto; margin: 0; }
.cm-mute { display: inline-flex; align-items: center; gap: 6px; margin-left: 6px; }

/* beta notices */
.beta-tag { font: 700 10px var(--sans); font-variant-numeric: tabular-nums; color: var(--warn); border: 1px solid var(--warn-line); background: var(--warn-bg); border-radius: 99px; padding: 2px 7px; line-height: 1.4; flex: none; align-self: center; }
.nav-in > .beta-tag { margin-left: -18px; }
.beta-strip { background: var(--warn-bg); border-bottom: 1px solid var(--warn-line); color: var(--warn-ink); font-size: 13.5px; text-align: center; padding: 7px 16px; }
.beta-strip b { color: var(--warn); font: 700 11px var(--sans); font-variant-numeric: tabular-nums; margin-right: 6px; }
.ban-sync { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: -4px 0 12px; }
.ban-sync .linkish { font-size: 12.5px; }

/* Terms checkbox (sign-in box and dashboard prompt) */
.tos-check { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; font-weight: 400; color: var(--text); background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin: 0 0 14px; cursor: pointer; line-height: 1.45; }
.tos-check input { width: auto; margin-top: 3px; flex: none; }
.tos-check.shake { animation: tos-shake .35s; border-color: var(--warn); }
@keyframes tos-shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
/* (buttons stay full contrast before the Terms box is ticked; clicking them points at the box) */

/* legal pages */
body.legal-page { min-height: 100%; }
.legal { max-width: 820px; padding-top: 36px; padding-bottom: 72px; }
.legal h1 { font-size: clamp(28px, 4vw, 38px); letter-spacing: -.01em; margin-bottom: 6px; }
.legal h2 { font-size: 19px; margin: 34px 0 10px; font-family: var(--sans); font-weight: 600; letter-spacing: 0; }
.legal p, .legal li { color: var(--text); font-size: 15px; }
.legal ul, .legal ol { padding-left: 22px; display: grid; gap: 6px; }
.legal-meta { color: var(--muted) !important; font-size: 13px !important; margin: 0 0 24px; }
.legal .caps { font-size: 13px; }
.legal .callout { background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: 10px; padding: 12px 14px; }
.legal code { font-family: var(--mono); font-size: 13px; background: var(--bg2); border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; }
.legal-table { width: 100%; border-collapse: collapse; margin: 10px 0 6px; font-size: 14px; display: block; overflow-x: auto; }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.legal-table th { color: var(--muted); font-size: 12px; }
.legal-nav a[aria-current="page"] { color: var(--text); }
.legal-nav { flex-wrap: wrap; row-gap: 6px; }
.legal-foot, .lp-foot { flex-wrap: wrap; gap: 10px 20px; }
.foot-links, .legal-foot nav { display: flex; gap: 16px; flex-wrap: wrap; }
.foot-links a, .legal-foot nav a { color: var(--muted); } .foot-links a:hover, .legal-foot nav a:hover { color: var(--text); }
@media (max-width: 700px) { .legal-nav { display: flex; margin-left: 0; gap: 14px; font-size: 14px; } .legal-page .nav-in { flex-wrap: wrap; gap: 10px 16px; } }

/* Discord webhook: mention a role */
.hook-mention { border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; margin: 10px 0; background: var(--bg2); }
.hook-mention summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--text); }
.hook-mention[open] summary { margin-bottom: 10px; }
.hook-mention .field { margin-bottom: 10px; }
.hook-mention .chk-wrap { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); border: 1px solid var(--line); border-radius: 8px; padding: 4px 0; }

/* Settings: sign-in methods */
.signin-methods { display: block; }
.sims { display: grid; gap: 6px; margin-top: 10px; }
.sim { display: grid; grid-template-columns: 70px 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); font-size: 14px; }
.sim-p { font-weight: 600; }
.sim-who { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* VPN blocking */
.vpn-block { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); border: 1px solid var(--line); border-radius: 8px; padding: 4px 0; }
.vpn-block .flag-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; display: inline-block; }

.ban-prev { font-size: 13px; color: var(--muted); }
.ban-prev code { font-family: var(--mono); font-size: 12.5px; background: var(--bg2); border: 1px solid var(--line); border-radius: 4px; padding: 2px 6px; color: var(--text); }


/* Server config: preview of the in-game join message (Rust chat style) */
.rust-chat { display: flex; gap: 10px; align-items: flex-start; background: rgba(0,0,0,.55); border-radius: 6px; padding: 8px 12px; font: 600 15px/1.35 var(--sans); color: #fff; text-shadow: 0 1px 2px #000; max-width: 520px; }
.rust-chat .rc-ic img { width: 28px; height: 28px; border-radius: 4px; display: block; }
.rust-chat .rc-brand { color: #6cc4ff; }
.rust-chat .rc-extra { font-weight: 500; font-size: 14px; color: #e8e8e8; }

.plugin-banner { margin: 0 16px 10px; padding: 9px 12px; border: 1px solid var(--warn-line); background: var(--warn-bg); color: var(--warn-ink); border-radius: 8px; font-size: 13.5px; }
.plugin-banner b { color: var(--warn); }
.plugin-banner a, .plugin-banner .linkish { color: var(--accent); font-size: inherit; }
.plugin-done { margin-top: 8px; }

/* F7 reports */
.report-row { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: start; padding: 12px 14px; border-top: 1px solid var(--line); }
.report-row:first-child { border-top: 0; }
.report-row.done { opacity: .6; }
.rp-who { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px; }
.rp-subject { font-weight: 600; margin-top: 4px; }
.rp-msg { color: var(--muted); font-size: 14px; margin-top: 2px; white-space: pre-wrap; overflow-wrap: anywhere; }
.rp-act, .rp-seg { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.rep-badge { background: var(--err); color: #1a0306; border-color: transparent; }
@media (max-width: 700px) { .report-row { grid-template-columns: 1fr; } .rp-act { justify-content: flex-start; } }

/* Team: custom roles */
.role-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); }
.role-row:first-child { border-top: 0; }
.perm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; }
.perm-row { display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); margin: 0; cursor: pointer; font-weight: 400; color: var(--text); }
.perm-row input { width: auto; margin-top: 3px; flex: none; }
.perm-row b { display: block; font-size: 13.5px; } .perm-row small { color: var(--muted); font-size: 12px; line-height: 1.35; display: block; }

/* Public ban appeal page */
.appeal { max-width: 680px; padding-top: 40px; padding-bottom: 60px; }
.appeal-card { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 28px; display: grid; gap: 14px; }
.appeal-card h1 { font-size: clamp(24px, 4vw, 32px); }
.appeal-card .btn.steam { justify-self: start; }
.appeal-intro { color: var(--muted); margin: 0; }
.appeal-who { font-size: 14px; color: var(--muted); }
.appeal-ban { border: 1px solid var(--line); border-radius: 10px; padding: 16px; background: var(--bg2); display: grid; gap: 10px; }
.ab-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.appeal-form { display: grid; gap: 6px; } .appeal-form textarea, .appeal-form input { margin-bottom: 8px; } .appeal-form .btn { justify-self: start; }
.appeal-status { border-left: 3px solid var(--line); padding: 4px 0 4px 12px; display: grid; gap: 6px; }
.appeal-msg { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.appeal-reply { background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: 8px; padding: 8px 10px; font-size: 14px; white-space: pre-wrap; }
.appeal-none { text-align: center; padding: 20px; }
.appeal-foot { text-align: center; margin-top: 16px; }

.appeal-link { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.appeal-link code { font-family: var(--mono); font-size: 12.5px; background: var(--bg2); border: 1px solid var(--line); border-radius: 6px; padding: 5px 8px; overflow-wrap: anywhere; }

/* bot honeypot: off-screen, never seen by people */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Accessibility: a clear focus outline on everything you can Tab to */
:where(a, button, summary, [role="button"], [tabindex="0"]):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
tr[role="button"]:focus-visible { outline-offset: -2px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

/* Accessibility: links inside sentences are underlined, so they're not told apart by colour alone (WCAG 1.4.1) */
:where(p, li, dd, td, .legal, .appeal-foot, .hint, .muted, .st-foot) a:not(.btn) { text-decoration: underline; text-underline-offset: 2px; }

/* Skip link: hidden until it gets keyboard focus (first Tab on every page) */
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 1000; padding: 10px 14px; border-radius: 8px;
  background: var(--accent); color: var(--on-accent); font-weight: 600; text-decoration: none; }
.skip-link:focus { top: 12px; outline: 2px solid var(--text); outline-offset: 2px; }
main:focus { outline: none; }
[role=dialog]:focus { outline: none; }

/* Respect the system "reduce motion" setting everywhere */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ================= client area v2: a live control panel ================= */
body.app { background: var(--bg); }
.app .main { background: var(--bg); }

/* Panels: one lifted surface with a faint top highlight, used everywhere in the dashboard */
.app :where(.chart-box, .feed-box, .qa, .ov-hero, .ov-metrics, .pl-card, .box, .sched, .hook, .cm-card, .tbl-wrap, .linked) {
  background: linear-gradient(var(--panel), color-mix(in srgb, var(--panel) 92%, var(--bg)));
  border: 1px solid var(--line); border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.035), 0 1px 2px rgba(0,0,0,.25);
}
.chart-head h3, .feed-box h3 { font: 600 14.5px var(--sans); }

/* Sidebar: darker rail, servers as cards with a blue edge on the active one */

/* Live status dots: a slow ring on "online" so you can tell at a glance the connection is live */
.status.online { position: relative; }
.status.online::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--ok); opacity: 0; animation: livePing 2.4s ease-out infinite; }
@keyframes livePing { 0% { transform: scale(.5); opacity: .7; } 80%, 100% { transform: scale(1.4); opacity: 0; } }

/* Server header */
.sh-status { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--text); }
.sh-status .status { margin-right: 0 !important; }
.addr-chip { display: inline-flex; align-items: center; gap: 7px; padding: 3px 9px; border-radius: 6px; border: 1px solid var(--line); background: var(--panel); color: var(--muted); cursor: pointer; font-size: 12.5px; }
.addr-chip:hover { color: var(--text); border-color: var(--line-strong); }
.addr-chip .ic { width: 13px; height: 13px; }

/* Overview: summary card (big count, meter, sparkline), then a strip of numbers */
.ov { gap: 16px; }
.ov-hero { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(0, 1.5fr); gap: 28px; padding: 22px 24px; align-items: stretch; }
.ovh-status { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; min-width: 0; }
.ovh-host { color: var(--muted); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ovh-host::before { content: ''; display: inline-block; width: 1px; height: 12px; background: var(--line-strong); margin: 0 10px -1px 2px; }
.ovh-num { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 14px; }
.ovh-num b { font: 800 64px/1 var(--sans); font-stretch: 120%; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.ovh-num span { color: var(--muted); font-size: 15px; }
.meter { position: relative; height: 10px; border-radius: 3px; background: var(--bg2); border: 1px solid var(--line); overflow: hidden; margin-bottom: 12px; }
.meter > i { display: block; height: 100%; background: var(--accent); transition: width .4s; }
.meter::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 calc(10% - 2px), var(--bg) calc(10% - 2px) 10%); }
.ovh-spark { display: flex; flex-direction: column; min-width: 0; border-left: 1px solid var(--line); padding-left: 28px; }
.ovh-spark-h { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.ovh-spark-h span:last-child { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.spark { width: 100%; height: 100%; min-height: 96px; flex: 1; display: block; overflow: visible; }
.spark-l { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.spark .pt { fill: var(--accent); }
.spark-empty { margin: auto 0; }
.ag-top { stop-color: var(--accent); stop-opacity: .28; } .ag-bot { stop-color: var(--accent); stop-opacity: 0; }
.ov-metrics { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.ovm { padding: 14px 18px; min-width: 0; }
.ovm + .ovm { border-left: 1px solid var(--line); }
.ovm .v { font: 700 20px var(--sans); font-variant-numeric: tabular-nums; margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ovm .s { font-size: 12px; color: var(--muted); margin-top: 1px; }
.ovm.good .v { color: var(--ok); } .ovm.fair .v { color: var(--warn); } .ovm.poor .v { color: var(--err); }
.chart-box .ln-s { stroke-width: 2.25; stroke-linecap: round; }
.chart-box .gl { stroke-dasharray: 2 4; }
.qa { padding: 10px 12px; }
.feed-ic { border-radius: 50%; }
@media (max-width: 1100px) { .ov-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); } .ovm:nth-child(4) { border-left: 0; } .ovm:nth-child(n+4) { border-top: 1px solid var(--line); } }
@media (max-width: 760px) {
  .ov-hero { grid-template-columns: 1fr; gap: 18px; padding: 18px; }
  .ovh-spark { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 14px; }
  .ovh-num b { font-size: 52px; }
  .ov-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ovm:nth-child(odd) { border-left: 0; } .ovm:nth-child(4) { border-left: 1px solid var(--line); } .ovm:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (prefers-reduced-motion: reduce) { .status.online::after { display: none; } }
.ovh-main, .ovh-spark { min-width: 0; }
@media (max-width: 760px) { .ov-hero { grid-template-columns: minmax(0, 1fr); } }
/* phones: the beta notice drops onto its own line under the top bar instead of squeezing into it */
@media (max-width: 760px) { .ovm:last-child:nth-child(odd) { grid-column: 1 / -1; } }

/* ================= client area v3: one component system for every tab, Manage page and the admin panel ================= */
:where(body.app, body.adm) {
  --row-hover: color-mix(in srgb, var(--accent) 5%, transparent);
  --ring: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}

/* --- tab and page headings --- */
.app .pane-pad { padding: 24px 28px 40px; }
.toolbar { gap: 12px; margin-bottom: 16px; }
.toolbar > h3 { font-size: 20px; font-stretch: 115%; font-weight: 700; margin-right: 4px; }
.sub-head { margin-bottom: 22px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.sub-head h3 { font-size: 22px; font-stretch: 115%; }
.sub-head p { font-size: 14.5px; line-height: 1.55; max-width: 70ch; margin-top: 6px; }
.section-title { display: flex; align-items: center; gap: 12px; font-size: 13.5px; font-weight: 650; color: var(--text); margin: 28px 0 12px; }
.section-title::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* --- controls --- */
.btn { min-height: 36px; box-shadow: inset 0 1px 0 rgba(255,255,255,.04); }
.btn.sm { min-height: 30px; }
.btn.primary { background: linear-gradient(var(--accent), color-mix(in srgb, var(--accent) 88%, #000)); box-shadow: inset 0 1px 0 rgba(255,255,255,.25), 0 1px 2px rgba(0,0,0,.3); }
.btn.primary:hover { background: color-mix(in srgb, var(--accent) 90%, #fff); }
.btn.danger { box-shadow: none; }
:where(body.app, body.adm) :is(input:not([type=checkbox]):not([type=radio]), select, textarea) { background: var(--bg2); border-color: var(--line); border-radius: 7px; transition: border-color .12s, box-shadow .12s; }
:where(body.app, body.adm) :is(input, select, textarea):hover { border-color: var(--line-strong); }
:where(body.app, body.adm) :is(input, select, textarea):focus { border-color: var(--accent); box-shadow: var(--ring); }
:where(body.app, body.adm) :is(input[type=checkbox], input[type=radio]) { accent-color: var(--accent); }
label { font-weight: 600; }
.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg2); overflow: visible; }
.seg button { border-radius: 5px; padding: 5px 11px; font: 600 12.5px var(--sans); color: var(--muted); }
.seg button:hover { color: var(--text); }
.seg button.on { background: var(--panel2); color: var(--text); box-shadow: 0 1px 2px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.05); }
.rp-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg2); }
.rp-seg .btn { min-height: 28px; border-color: transparent; background: none; box-shadow: none; color: var(--muted); }
.rp-seg .btn.primary { background: var(--panel2); color: var(--text); box-shadow: 0 1px 2px rgba(0,0,0,.35); }
.switch span { background: var(--bg2); border-color: var(--line-strong); }
.switch input:checked + span { background: var(--accent); border-color: var(--accent); }
.switch input:checked + span::after { background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.4); }
.chip { border-radius: 7px; padding: 5px 12px; background: var(--bg2); }
.chip.on { background: var(--accent-soft); border-color: var(--accent-line); color: var(--text); box-shadow: inset 0 0 0 1px var(--accent-line); }

/* --- tags and badges: softer, squarer --- */
.tag { border-radius: 6px; font-weight: 600; padding: 2px 8px; font-size: 11.5px; }
.badge { border-radius: 6px; font-weight: 600; }

/* --- lists (players, bans, reports, plugins, team, rules, history) --- */
.app :is(.pl-row, .ban-row, .report-row, .plug-row, .member, .role-row, .rule-row, .hist-row, .alt-row) { transition: background-color .12s; }
.app :is(.pl-row:not(.pl-hd), .ban-row, .report-row, .plug-row, .member, .role-row, .rule-row, .hist-row):hover { background: var(--row-hover); }
.app :is(.ban-row, .report-row, .plug-row, .member, .role-row, .rule-row) { padding: 14px 18px; }
.pl-card { overflow: hidden; }
.pl-hd { background: color-mix(in srgb, var(--bg2) 70%, transparent); font-size: 12px; color: var(--muted); }
.pl-av { background: linear-gradient(145deg, color-mix(in srgb, var(--accent) 28%, var(--panel2)), color-mix(in srgb, var(--accent) 8%, var(--panel2))); color: var(--text); border-color: var(--accent-line); font-family: var(--sans); }
.pl-nm { font-size: 14.5px; }
.pl-id { font-size: 12px; }
.rp-subject { font-size: 15px; }
.report-row.done { opacity: .55; }
.pl-empty { padding: 56px 20px; }
.pl-empty b { font-size: 17px; font-stretch: 110%; margin-bottom: 6px; }
.empty h2 { font-stretch: 115%; }

/* --- console --- */
.console, .chat { background: var(--console); }
.c-tools { padding: 10px 16px; background: var(--bg); gap: 10px; }
.c-tools .seg { margin-right: 4px; }
.c-out { padding: 12px 0; font-size: 13px; line-height: 1.6; }
.c-out .ln { padding: 1px 18px; border-left: 2px solid transparent; }
.c-out .ln:hover { background: rgba(255,255,255,.025); }
.c-out .ln.err { border-left-color: var(--err); background: color-mix(in srgb, var(--err) 6%, transparent); }
.c-out .ln.warn { border-left-color: var(--warn); background: color-mix(in srgb, var(--warn) 5%, transparent); }
.c-out .ln.in { border-left-color: var(--accent-line); }
.c-in { padding: 12px 16px; background: var(--bg); gap: 10px; }
.c-in input { background: var(--console) !important; border-radius: 8px; padding: 11px 14px; }
.c-in .prompt { width: 30px; height: 30px; border-radius: 7px; display: grid; place-items: center; background: var(--accent-soft); flex: none; }
.macros { background: var(--bg); padding: 10px 16px 0; }

/* --- chat --- */
.chat-out { padding: 12px 14px; }
.msg { padding: 6px 10px; border-radius: 7px; }
.msg-name { font-weight: 650; }
.msg .ch { border-radius: 5px; font-family: var(--sans); font-size: 10.5px; padding: 1px 6px; }
.msg.flagged { background: color-mix(in srgb, var(--warn) 9%, transparent); box-shadow: inset 2px 0 0 var(--warn); }
.chatmod-panel { background: var(--bg); padding: 18px; }
.cmp-filters { background: var(--panel); border-radius: 10px; }

/* --- Manage: a proper settings layout --- */
.manage { grid-template-columns: 230px minmax(0, 1fr); }
.manage-content { padding: 28px 36px 48px; }
.manage-content > * { max-width: 1040px; }
.box { padding: 20px; }
.form-grid { gap: 6px; }
.hook, .cm-card, .sched { padding: 18px; }
.check-grid, .ev-groups, .ak-rules, .perm-row, .hook-mention, .tos-check { background: var(--bg2); }
.notice { border-radius: 10px; }
@media (max-width: 760px) { .manage-content { padding: 18px 16px 40px; } }

/* --- dialogs and the player panel --- */
.modal-bg { background: rgba(4,7,11,.72); backdrop-filter: blur(6px); }
.modal { padding: 24px 24px 0; border-radius: 14px; border-color: var(--line-strong); background: var(--panel); box-shadow: 0 30px 80px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.05); }
.modal h3 { font-size: 20px; font-stretch: 112%; }
.modal .actions { margin: 22px -24px 0; padding: 14px 24px; border-top: 1px solid var(--line); background: var(--bg2); border-radius: 0 0 14px 14px; position: sticky; bottom: 0; }
.who-box { background: var(--bg2); border-radius: 10px; }
.drawer { background: var(--panel); border-left-color: var(--line-strong); box-shadow: -30px 0 80px rgba(0,0,0,.55); }
.drawer-head { padding: 22px 22px 12px; }
.drawer-head h3 { font-stretch: 112%; font-size: 21px; }
.drawer-actions { padding: 0 22px 18px; }
.drawer-body { padding: 18px 22px 28px; }
.dstat { background: var(--bg2); border-radius: 9px; padding: 11px 12px; }
.dstat .v { font-family: var(--sans); font-size: 16px; }
.dsec h4 { font-size: 13px; font-weight: 650; color: var(--text); display: flex; align-items: center; gap: 10px; }
.dsec h4::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.note { border-radius: 8px; }
.toast { border-radius: 10px; border-left: 3px solid var(--line-strong); background: var(--panel2); box-shadow: 0 12px 40px rgba(0,0,0,.5); }
.toast.ok { border-left-color: var(--ok); } .toast.err { border-left-color: var(--err); }

/* --- sidebar footer --- */

.tbl th { background: var(--bg2); font-size: 12px; font-weight: 600; padding: 10px 14px; position: sticky; top: 0; }
.tbl td { padding: 11px 14px; }
.tbl tbody tr:hover td { background: var(--row-hover); }
.tbl tr:last-child td { border-bottom: 0; }
@media (max-width: 760px) {
  .manage { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
}
.ip-opt { display: grid; gap: 2px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); }
.ip-opt .chk-row { padding: 0; }
.ip-opt p { margin: 0 0 0 26px; }
.feed-item.group .feed-ic { color: #ab9dff; background: color-mix(in srgb, #ab9dff 14%, transparent); }

/* ================= Discord alerts ================= */
.hk-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.hk-list { display: grid; gap: 10px; margin-bottom: 10px; }
.hk-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 16px 18px; border: 1px solid var(--line); border-radius: 10px;
  background: linear-gradient(var(--panel), color-mix(in srgb, var(--panel) 92%, var(--bg))); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); }
.hk-row.bad { border-color: var(--err-line); }
.hk-ic { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: #5865f2; color: #fff; }
.hk-ic .ic { width: 18px; height: 18px; }
.hk-main { min-width: 0; display: grid; gap: 4px; }
.hk-name { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hk-name b { font-size: 15.5px; }
.hk-health { font-size: 12.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.hk-health::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--line-strong); }
.hk-health.ok { color: var(--ok); } .hk-health.ok::before { background: var(--ok); }
.hk-health.bad { color: var(--err); font-weight: 600; } .hk-health.bad::before { background: var(--err); }
.hk-sum { color: var(--muted); font-size: 14px; }
.hk-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.hk-err { margin: 6px 0 0; padding: 8px 10px; border-radius: 7px; background: var(--err-bg); border: 1px solid var(--err-line); color: var(--text); font-size: 13.5px; }
.hk-act { display: flex; gap: 8px; }

/* empty state: pick a starting point */
.hk-empty h4 { font-size: 17px; margin: 0 0 4px; }
.hk-presets-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-top: 16px; }
.hk-preset { display: grid; gap: 4px; text-align: left; padding: 16px 18px; border-radius: 10px; border: 1px solid var(--line); cursor: pointer; color: var(--text);
  background: linear-gradient(var(--panel), color-mix(in srgb, var(--panel) 92%, var(--bg))); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); transition: border-color .12s, background-color .12s; }
.hk-preset:hover { border-color: var(--accent-line); background: color-mix(in srgb, var(--accent) 6%, var(--panel)); }
.hk-preset b { font-size: 15px; } .hk-preset span { color: var(--muted); font-size: 13.5px; }
.hk-preset.blank { border-style: dashed; background: transparent; }

/* editor: steps on the left, live preview on the right */
.hk-edit { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; max-width: 1100px; }
.hk-form { display: grid; gap: 14px; min-width: 0; }
.hk-edit-head { display: flex; align-items: center; gap: 12px; }
.hk-edit-head h4 { margin: 0; font-size: 17px; }
.hk-unsaved { font-size: 12.5px; font-weight: 600; color: var(--warn); }
.hk-sec { padding: 18px 20px; border: 1px solid var(--line); border-radius: 10px; background: linear-gradient(var(--panel), color-mix(in srgb, var(--panel) 92%, var(--bg))); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); }
.hk-sec h4 { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font-size: 15px; }
.hk-sub { margin: -6px 0 12px 34px; }
.hk-n { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12.5px; font-weight: 700; background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent-line); flex: none; }
.hk-url { display: flex; gap: 6px; }
.hk-url input { flex: 1; min-width: 0; font-family: var(--mono); font-size: 13px; }
.hk-url-state.ok { color: var(--ok); } .hk-url-state.bad { color: var(--err); }
.hk-url-state.ok::before { content: '\2713  '; } .hk-url-state.bad::before { content: '\2715  '; }
.hk-howto { margin-top: 4px; font-size: 14px; }
.hk-howto summary { cursor: pointer; color: var(--accent); font-weight: 600; }
.hk-howto ol { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 4px; color: var(--muted); }
.hk-howto b { color: var(--text); }
.hk-presets { align-items: center; margin: 0 0 14px; }
.hk-groups { display: grid; gap: 14px; }
.hk-group { border: 0; padding: 0; margin: 0; min-width: 0; position: relative; }
.hk-group legend { padding: 0; font-weight: 650; font-size: 13.5px; display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.hk-count { font-size: 11.5px; font-weight: 600; color: var(--muted); padding: 1px 7px; border-radius: 6px; background: var(--bg2); border: 1px solid var(--line); }
.hk-count.on { color: var(--accent); border-color: var(--accent-line); background: var(--accent-soft); }
.hk-group-act { position: absolute; top: 0; right: 0; display: flex; gap: 12px; }
.hk-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; }
.hk-tile { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg2); cursor: pointer; margin: 0; font-weight: 400; color: var(--text); transition: border-color .12s, background-color .12s; }
.hk-tile:hover { border-color: var(--line-strong); }
.hk-tile:has(input:checked) { border-color: var(--accent-line); background: color-mix(in srgb, var(--accent) 8%, var(--bg2)); }
.hk-tile input { width: 16px; height: 16px; margin-top: 2px; flex: none; }
.hk-tile span { display: grid; gap: 1px; min-width: 0; }
.hk-tile b { font-size: 14px; } .hk-tile small { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.hk-sec select { max-width: 320px; }
.hk-pings { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 2px 12px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); }
.hk-ping-body { margin-top: 12px; }
.hk-ip p { margin: 4px 0 0 26px; }
.hk-foot { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; position: sticky; bottom: 0; padding: 14px 0 4px; background: linear-gradient(transparent, var(--bg) 30%); }
.hk-del { margin-left: auto; }
.hk-side { position: sticky; top: 0; display: grid; gap: 10px; }
.hk-preview { min-height: 140px; }
.hk-preview .dm-embed { margin-left: 50px; display: grid; gap: 2px; }
.hk-preview .dm-embed small { color: #949ba4; font-size: 11.5px; margin-top: 4px; }
.hk-mention { margin-left: 50px; color: #c9cdfb; background: rgba(88,101,242,.3); border-radius: 4px; padding: 0 4px; width: fit-content; font-weight: 600; }
.hk-more { margin: 4px 0 0 50px; color: #949ba4; font-size: 12.5px; }
@media (max-width: 1100px) { .hk-edit { grid-template-columns: minmax(0, 1fr); } .hk-side { position: static; } }
@media (max-width: 640px) {
  .hk-row { grid-template-columns: 34px minmax(0, 1fr); } .hk-act { grid-column: 1 / -1; } .hk-ic { width: 34px; height: 34px; }
  .hk-sub { margin-left: 0; } .hk-group-act { position: static; margin-bottom: 6px; } .hk-del { margin-left: 0; }
}
.hk-edit { grid-template-columns: minmax(0, 1fr) 300px; }
.hk-sec .field input:not([type=checkbox]) { max-width: 520px; }
.hk-url { max-width: 520px; }
.hk-tiles { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.hk-foot { background: var(--bg); border-top: 1px solid var(--line); padding: 12px 0; margin-top: 4px; z-index: 2; }
@media (max-width: 1250px) { .hk-edit { grid-template-columns: minmax(0, 1fr); } .hk-side { position: static; order: -1; } .hk-preview { max-height: 260px; overflow: auto; } }
.hk-head > div { flex: 1 1 420px; min-width: 0; }
.hk-head > .btn { flex: none; }
.feed-filters { display: flex; gap: 6px; margin-left: auto; margin-right: 10px; }
.chip.sm { padding: 2px 9px; font-size: 12px; border-radius: 6px; }
.feed-item.death .feed-ic { color: var(--err); background: var(--err-bg); }
.feed-item.team .feed-ic { color: var(--ok); background: var(--ok-bg); }
/* BetterChat titles: a coloured dot and edge in the title colour, readable text in any colour */
.bc-title { display: inline-flex; align-items: center; gap: 5px; margin-left: 6px; padding: 0 6px; border-radius: 4px; font-size: 11.5px; font-weight: 700; color: var(--text); background: var(--bg2); border: 1px solid color-mix(in srgb, var(--bc, var(--muted)) 55%, var(--line)); }
.bc-title::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--bc, var(--muted)); }
.bc-now { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; } .bc-now .bc-title:first-of-type { margin-left: 4px; }
.pl-nm-row { display: flex; align-items: center; gap: 2px; min-width: 0; }
.pl-nm-row .pl-nm { min-width: 0; }
.pl-nm-row .bc-title { flex: none; }

/* live Discord status message card */
.hk-status { display: grid; gap: 12px; margin: 18px 0 10px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 10px;
  background: linear-gradient(var(--panel), color-mix(in srgb, var(--panel) 92%, var(--bg))); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); max-width: 1100px; }
.hk-status-head { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 14px; align-items: start; }
.hk-status-head .hk-ic { background: var(--accent-soft); color: var(--accent); }
.hk-status-head p { margin: 2px 0 0; }
.hk-status .row { max-width: 760px; }
@media (max-width: 640px) { .hk-status .row { flex-direction: column; gap: 0; } }

/* timed groups */
.grp-left { margin-left: 6px; font-size: 11px; font-weight: 600; color: var(--warn); font-family: var(--sans); }
.tg-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 14px; align-items: center; }
@media (max-width: 640px) { .tg-row { grid-template-columns: minmax(0, 1fr) auto; } .tg-row .btn-row { grid-column: 1 / -1; } }

/* combat log */
.clog { display: grid; gap: 10px; justify-items: start; }
.clog > div { width: 100%; }
.clog-tbl { font-size: 12.5px; }
.clog-tbl td, .clog-tbl th { padding: 6px 8px; white-space: nowrap; }
.clog-tbl tr.out td:first-child { box-shadow: inset 2px 0 0 var(--accent); }
.clog-tbl tr.in td:first-child { box-shadow: inset 2px 0 0 var(--err); }

/* two-factor sign-in */
.mfa-gate { position: fixed; inset: 0; z-index: 300; display: grid; place-items: center; padding: 16px; background: var(--bg); }
.mfa-card { width: 100%; max-width: 380px; display: grid; gap: 10px; padding: 28px; border: 1px solid var(--line-strong); border-radius: 14px; background: var(--panel); box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.mfa-card h2 { font-size: 22px; font-stretch: 112%; }
.mfa-card .hk-ic { background: var(--accent-soft); color: var(--accent); }
.mfa-card input { font: 600 20px var(--mono); letter-spacing: .15em; text-align: center; }
.mfa-card .linkish { justify-self: center; }
.mfa-qr { width: 200px; height: 200px; margin: 4px auto 12px; padding: 8px; background: #fff; border-radius: 10px; }
.mfa-qr svg { width: 100%; height: 100%; display: block; }
.mfa-secret { font-family: var(--mono); font-size: 12.5px; background: var(--bg2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; overflow-wrap: anywhere; }
.mfa-codes { font: 600 16px/1.8 var(--mono); text-align: center; background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; padding: 12px; margin: 0; columns: 2; }
.mfa-row .btn-row { flex: none; }
.mfa-tag { margin-left: 8px; vertical-align: 1px; }
.mfa-req { margin: 12px 0 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); }
.mfa-banner { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }

/* analytics + staff activity */
.an-metrics { margin-bottom: 16px; }
.an-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; margin-top: 16px; }
.chart-box .bar-new { fill: var(--accent); } .chart-box .bar-ret { fill: color-mix(in srgb, var(--accent) 35%, var(--panel2)); }
.an-legend { display: flex; gap: 14px; font-size: 12.5px; color: var(--muted); }
.an-legend span::before { content: ''; display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.an-legend .k-new::before { background: var(--accent); } .an-legend .k-ret::before { background: color-mix(in srgb, var(--accent) 35%, var(--panel2)); }
.ret-bars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 12px; text-align: center; }
.ret { display: grid; gap: 4px; justify-items: center; }
.ret-bar { width: 38px; height: 110px; border-radius: 6px; background: var(--bg2); border: 1px solid var(--line); display: flex; align-items: flex-end; overflow: hidden; }
.ret-bar i { display: block; width: 100%; background: var(--accent); }
.an-top { margin: 0; padding-left: 22px; display: grid; gap: 6px; }
.an-top li { display: flex; justify-content: space-between; gap: 10px; }
.staff-tbl td.num, .staff-tbl th { text-align: right; } .staff-tbl th:first-child, .staff-tbl td:first-child, .staff-tbl th:last-child { text-align: left; }
.staff-tbl { overflow-x: auto; }
@media (max-width: 900px) { .an-split { grid-template-columns: 1fr; } }
.staff-tbl th, .staff-tbl td { white-space: nowrap; }
.plugin-banner a { text-decoration: underline; text-underline-offset: 2px; }
.an-note { margin: -4px 0 14px; max-width: 80ch; }

/* Expanded player profile */
.drawer { transition: width .18s ease-out; }
.drawer.wide { width: min(1120px, calc(100vw - 48px)); }
.drawer.wide .drawer-body { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
.drawer.wide .drawer-body > .dstats, .drawer.wide .drawer-body > .warn-box, .drawer.wide .dsec:has(.clog), .drawer.wide .dsec:has(.heat-grid), .drawer.wide .dsec:has(.ev) { grid-column: 1 / -1; }
.drawer.wide .heat-grid { min-width: 0; }
.drawer.wide .dstats:not(.three) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 760px) { .drawer-expand { display: none; } .drawer.wide { width: 100vw; } .drawer.wide .drawer-body { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .drawer { transition: none; } }
.drawer.wide .dsec:has(> .dstats) { grid-column: 1 / -1; }
.drawer.wide .dstats.three { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* Ban evidence */
.ev { display: grid; gap: 12px; }
.ev-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.ev-item { position: relative; display: grid; gap: 6px; min-width: 0; }
.ev-thumb { position: relative; display: grid; place-items: center; aspect-ratio: 16 / 10; width: 100%; overflow: hidden; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); padding: 0; cursor: zoom-in; color: var(--muted); }
.ev-thumb img, .ev-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.ev-thumb:hover, .ev-thumb:focus-visible { border-color: var(--accent); }
.ev-link { cursor: pointer; text-decoration: none; gap: 6px; font-size: 13px; padding: 8px; text-align: center; overflow-wrap: anywhere; }
.ev-link .ic { width: 22px; height: 22px; }
.ev-play { position: absolute; inset: 0; display: grid; place-items: center; font-size: 26px; color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,.7); pointer-events: none; }
.ev-meta { display: grid; font-size: 12px; line-height: 1.35; min-width: 0; }
.ev-meta > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ev-del { position: absolute; top: 6px; right: 6px; background: rgba(5,6,8,.75); border-radius: 6px; padding: 3px; }
.ev-del .ic { width: 14px; height: 14px; }
.ev-add { display: grid; gap: 8px; padding-top: 10px; border-top: 1px dashed var(--line); }
.ev-add-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ev-add-row input[type=url] { flex: 1 1 200px; min-width: 0; }
.ev-pick { display: grid; gap: 8px; }
.ev-view { display: grid; place-items: center; background: #000; border-radius: 8px; overflow: hidden; }
.ev-view img, .ev-view video { max-width: 100%; max-height: 70vh; display: block; }
.ban-row .btn-row { display: flex; gap: 6px; justify-content: flex-end; }
.ban-row .btn .ic { width: 14px; height: 14px; vertical-align: -2px; }
/* Triggers */
.tg-row.off { opacity: .6; }
.tg-row .pl-info { display: grid; gap: 2px; }
.tg-editor { display: grid; gap: 18px; padding: 18px; }
.tg-step { display: grid; gap: 10px; }
.tg-step h4 { margin: 0; font-size: 14px; }
.tg-cond, .tg-acts { display: grid; gap: 10px; }
.tg-inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.tg-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.tg-act { display: grid; gap: 6px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.tg-act-in input, .tg-act-in select { width: 100%; }
@media (max-width: 760px) { .tg-two { grid-template-columns: 1fr; } }
.tg-editor label.check { display: flex; align-items: center; gap: 10px; margin: 0; cursor: pointer; font-weight: 600; color: var(--text); font-size: 14px; }
.tg-editor label.check input { width: 16px; height: 16px; flex: none; accent-color: var(--accent2); margin: 0; }
.tg-act .hint { margin: 0 0 0 26px; }
.tg-act-in { margin-left: 26px; }
.tg-inline input[type=number] { flex: none; }

/* ---------- anti-cheat (Manage > Anti-cheat, player profile) ---------- */
.ok-text { color: var(--ok); }
/* player profile */
.ac-weight { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 14px; }
.ac-bar { position: relative; height: 8px; border-radius: 99px; background: var(--bg2); border: 1px solid var(--line); overflow: hidden; flex: 1; }
.ac-bar span { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 99px; }
.ac-bar.hot span { background: var(--err); }
.ac-score { margin-bottom: 4px; }
.ac-alert span:nth-child(2) { overflow-wrap: anywhere; }
.ac-savebar { position: sticky; bottom: 14px; z-index: 5; display: none; gap: 10px; align-items: center; padding: 10px 12px 10px 16px; margin-top: 14px;
  background: var(--panel2); border: 1px solid var(--accent-line); border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.45); }
.ac-savebar.show { display: flex; animation: ac-bar-in .18s ease-out; }
.ac-savebar span { margin-right: auto; font-weight: 600; color: var(--accent); }
@keyframes ac-bar-in { from { transform: translateY(10px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .ac-savebar.show { animation: none; } }

/* console: status strip */
.acx { container: acx / inline-size; }
.manage-content > .acx { max-width: none; } /* the console uses the full width */
.acx-rows { container: acxrows / inline-size; }
.acx-top { display: grid; grid-template-columns: minmax(210px, 1.3fr) repeat(3, minmax(100px, .8fr)) minmax(230px, 1.4fr); gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin-bottom: 12px; }
.acx-top > * { background: var(--panel); padding: 14px 16px; min-width: 0; }
.acx-power { display: flex; align-items: center; gap: 14px; border: 0; cursor: pointer; color: var(--text); text-align: left; font: inherit; transition: background-color .15s; }
.acx-power:hover { background: var(--panel2); }
.acx-power i { position: relative; width: 40px; height: 40px; flex: none; border-radius: 50%; border: 2px solid var(--line-strong); background: var(--bg2); transition: .2s; }
.acx-power i::before { content: ""; position: absolute; inset: 9px; border: 2px solid var(--muted); border-top-color: transparent; border-radius: 50%; }
.acx-power i::after { content: ""; position: absolute; left: 50%; top: 7px; width: 2px; height: 12px; margin-left: -1px; border-radius: 2px; background: var(--muted); }
.acx-power b { display: block; font-size: 17px; letter-spacing: .02em; }
.acx-power small { display: block; color: var(--muted); font-size: 12px; }
.acx-power.on i { border-color: var(--ok); background: var(--ok-bg); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 16%, transparent), 0 0 18px color-mix(in srgb, var(--ok) 35%, transparent); }
.acx-power.on i::before { border-color: var(--ok); border-top-color: transparent; } .acx-power.on i::after { background: var(--ok); }
.acx-power.on b { color: var(--ok); }
.acx-power:not(.on) b { color: var(--warn); }
.acx-stat { display: flex; flex-direction: column; justify-content: center; }
.acx-stat b { font: 700 24px/1.1 var(--mono); }
.acx-stat span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; margin-top: 3px; }
.acx-plugin { display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.acx-plugin-line { display: flex; gap: 10px; align-items: center; }
.acx-plugin-line small { display: block; font-size: 12px; }
.acx-plugin-btns { display: flex; gap: 6px; }
.acx-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--err); box-shadow: 0 0 0 3px var(--err-bg); }
.acx-dot.ok { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-bg); }
.acx-files { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 8px; margin-bottom: 12px; padding: 12px; border: 1px dashed var(--line-strong); border-radius: 10px; }
.acx-files[hidden] { display: none; }
.acx-files p { grid-column: 1 / -1; margin: 2px 0 0; }
.acx-file { display: flex; flex-direction: column; padding: 9px 11px; border-radius: 8px; background: var(--bg2); border: 1px solid var(--line); }
.acx-file:hover { border-color: var(--accent-line); text-decoration: none; }
.acx-file b { font-size: 13px; }

/* console: layout */
.acx-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 14px; align-items: start; }
.acx-main { min-width: 0; }
.acx-side { position: sticky; top: 14px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.acx-panel { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.acx-main > .acx-panel + .acx-panel { margin-top: 14px; }
.acx-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.acx-h h4 { margin: 0; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.acx-empty { margin: 4px 0; }

/* console: rules sentence */
.acx-sentence { margin: 0; font-size: 17px; line-height: 2.4; }
.acx-inline { display: inline-block; width: auto; padding: 1px 6px; margin: 0 2px; font: 700 16px var(--mono); color: var(--accent); background: var(--accent-soft);
  border: 0; border-bottom: 2px solid var(--accent-line); border-radius: 5px 5px 0 0; vertical-align: baseline; }
input.acx-inline { width: 4.2em; text-align: center; }
.acx-inline:hover, .acx-inline:focus { border-bottom-color: var(--accent); }
.acx-ban[hidden] { display: none; }
.acx-track { margin: 6px 0 2px; }
.acx-range { width: 100%; height: 22px; padding: 0; margin: 0; background: none; border: 0; accent-color: var(--accent); }
.acx-range:disabled { opacity: .35; }
.acx-ticks { display: flex; justify-content: space-between; gap: 8px; font-size: 11px; color: var(--muted); font-family: var(--mono); }
.acx-note { margin: 10px 0 0; padding: 9px 12px; font-size: 13.5px; color: var(--muted); background: var(--bg2); border-radius: 8px; }

/* console: detections */
.acx-filter { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.acx-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.acx-chip { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 99px; border: 1px solid var(--line); background: none; color: var(--muted); font: 600 13px var(--sans); cursor: pointer; }
.acx-chip span { font: 600 11px var(--mono); padding: 0 6px; border-radius: 99px; background: var(--bg2); }
.acx-chip:hover { color: var(--text); border-color: var(--line-strong); }
.acx-chip.on { color: var(--text); border-color: var(--accent-line); background: var(--accent-soft); }
.acx-search { width: 190px; padding: 6px 10px; font-size: 13px; }
.acx-group-h { margin: 14px 0 6px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.acx-group-h::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.acx-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.acx-row { display: flex; flex-direction: column; justify-content: space-between; gap: 14px; padding: 16px 16px 14px 18px; min-height: 132px;
  background: var(--bg2); border: 1px solid var(--line); border-left: 4px solid var(--line-strong); border-radius: 8px; transition: border-color .15s; }
.acx-row[data-tier=low] { border-left-color: var(--accent); }
.acx-row[data-tier=mid] { border-left-color: var(--warn); }
.acx-row[data-tier=hot] { border-left-color: var(--err); }
.acx-row.m-watch { border-left-style: dashed; }
.acx-row.m-off .acx-what { opacity: .5; }
.acx-name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.acx-count { font: 600 11px var(--mono); padding: 1px 7px; border-radius: 99px; color: var(--err); background: var(--err-bg); border: 1px solid var(--err-line); }
.acx-count[hidden] { display: none; }
.acx-seg { display: inline-flex; padding: 2px; gap: 2px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); }
.acx-seg-b { padding: 5px 11px; border: 0; border-radius: 6px; background: none; color: var(--muted); font: 600 12.5px var(--sans); cursor: pointer; }
.acx-seg-b:hover { color: var(--text); }
.acx-seg-b.on[data-m=off] { background: var(--panel2); color: var(--text); }
.acx-seg-b.on[data-m=watch] { background: var(--warn-bg); color: var(--warn); box-shadow: inset 0 0 0 1px var(--warn-line); }
.acx-seg-b.on[data-m=score] { background: var(--accent); color: var(--on-accent); }
.acx-weight { display: flex; align-items: center; gap: 8px; }
.acx-num { width: 56px; padding: 4px 6px; text-align: center; font: 600 13px var(--mono); }
.acx-num:disabled { opacity: .35; }
.acx-row-top { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; }
.acx-name b { font-size: 16px; }
.acx-what .small { margin-top: 3px; }
.acx-ctl { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.acx-ctl .acx-weight { flex: 1 1 200px; }
.acx-meta { flex: none; display: flex; flex-direction: column; align-items: flex-end; font-size: 11.5px; text-align: right; line-height: 1.2; min-width: 64px; }
.acx-meta b { font: 700 24px/1 var(--mono); }
.acx-meta .muted:only-child { margin-top: 4px; }
.acx-row[data-tier=hot] .acx-meta b { color: var(--err); }
.acx-row[data-tier=mid] .acx-meta b { color: var(--warn); }
.acx-legend { margin: 10px 0 0; }

/* console: watchlist + feed */
.acx-watch { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto 24px; gap: 4px 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.acx-watch:last-child { border-bottom: 0; }
.acx-rank { font: 600 12px var(--mono); color: var(--muted); }
.acx-who { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; }
.acx-x { width: 24px; height: 24px; border-radius: 6px; border: 1px solid var(--line); background: none; color: var(--muted); cursor: pointer; font-size: 14px; line-height: 1; }
.acx-x:hover { color: var(--text); border-color: var(--line-strong); }
.acx-meter { grid-column: 2 / 5; height: 5px; border-radius: 99px; background: var(--bg2); overflow: hidden; }
.acx-meter span { display: block; height: 100%; border-radius: 99px; background: var(--accent); }
.acx-watch.mid .acx-meter span { background: var(--warn); }
.acx-watch.hot .acx-meter span { background: var(--err); }
.acx-feed { position: relative; display: grid; grid-template-columns: 10px minmax(0, 1fr); gap: 0 10px; padding: 0 0 12px; font-size: 13.5px; }
.acx-feed::before { content: ""; position: absolute; left: 4px; top: 12px; bottom: 0; width: 2px; background: var(--line); }
.acx-feed:last-child::before { display: none; }
.acx-feed i { width: 10px; height: 10px; margin-top: 5px; border-radius: 50%; background: var(--line-strong); position: relative; }
.acx-feed.mid i { background: var(--warn); } .acx-feed.hot i { background: var(--err); box-shadow: 0 0 0 3px var(--err-bg); }
.acx-feed > div { overflow-wrap: anywhere; }
.acx-feed > span { grid-column: 2; }
.acx-test { margin-left: 6px; font: 600 10px var(--mono); padding: 0 5px; border-radius: 4px; border: 1px solid var(--line-strong); color: var(--muted); text-transform: uppercase; }

@container acx (max-width: 1000px) {
  .acx-layout { grid-template-columns: 1fr; }
  .acx-side { position: static; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
  .acx-top { grid-template-columns: repeat(3, 1fr); }
  .acx-power, .acx-plugin { grid-column: span 3; }
  .acx-plugin { flex-direction: row; align-items: center; justify-content: space-between; flex-wrap: wrap; }
}
@container acxrows (max-width: 700px) {
  .acx-grid { grid-template-columns: 1fr; }
  .acx-row { min-height: 0; }
}
@container acx (max-width: 640px) {
  .acx-search { width: 100%; }
  .acx-sentence { font-size: 15.5px; }
}
@container acx (max-width: 480px) {
  .acx-top { grid-template-columns: 1fr 1fr; } .acx-power, .acx-plugin { grid-column: span 2; } .acx-top > .acx-stat:nth-child(4) { grid-column: span 2; }
}


/* ---------- promo codes (Manage > Promo codes) ---------- */
.pr-banner { margin: 0 0 14px; }
.pr-settings, .pr-create { margin-bottom: 14px; }
.pr-cmd-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 20px; margin-top: 14px; }
.pr-cmd-wrap { display: flex; flex-direction: column; gap: 4px; margin: 0; font-size: 13px; font-weight: 600; color: var(--muted); }
.pr-slash { display: inline-flex; align-items: center; font: 700 16px var(--mono); color: var(--accent); background: var(--bg2); border: 1px solid var(--line); border-radius: 6px; padding-left: 10px; }
.pr-slash:focus-within { border-color: var(--accent); }
.pr-cmd { width: 150px; border: 0; background: none; padding: 8px 10px 8px 2px; font: 700 15px var(--mono); color: var(--accent); }
.pr-cmd:focus { outline: none; }
.pr-example-wrap { display: flex; flex-direction: column; gap: 4px; margin-right: auto; }
.pr-example { font: 600 14px var(--mono); padding: 8px 12px; border-radius: 6px; background: rgba(0,0,0,.45); color: #fff; border: 1px dashed var(--line-strong); }
.pr-create h4, .pr-cols h4 { margin: 0 0 12px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.pr-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 4px 16px; align-items: start; }
.pr-inline { display: flex; gap: 6px; } .pr-inline input { min-width: 0; } .pr-inline .btn { padding: 0 12px; font-size: 18px; }
.pr-custom { display: flex; gap: 6px; margin-top: 6px; } .pr-custom[hidden] { display: none; } .pr-custom input { width: 90px; }
.pr-form .chips { margin-top: 6px; } .pr-form .chip { padding: 2px 9px; font-size: 12px; }
.pr-create-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.pr-create-foot .muted { max-width: 560px; }
.pr-cols { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 14px; align-items: start; }
.pr-codes { display: grid; gap: 8px; }
.pr-code { display: grid; grid-template-columns: minmax(150px, 1.1fr) minmax(120px, 1fr) minmax(120px, 1fr) auto; gap: 12px 16px; align-items: center; padding: 12px 14px 12px 16px;
  background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--ok); border-radius: 10px; }
.pr-code.paused { border-left-color: var(--warn); } .pr-code.ended { border-left-color: var(--line-strong); }
.pr-code.paused .pr-code-name, .pr-code.ended .pr-code-name { color: var(--muted); }
.pr-code-main { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; }
.pr-code-name { border: 1px dashed var(--line-strong); background: var(--bg2); color: var(--text); font-size: 15px; font-weight: 700; letter-spacing: .06em; padding: 3px 9px; border-radius: 6px; cursor: copy; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.pr-code-name:hover { border-color: var(--accent); }
.pr-status { font: 600 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--ok); }
.pr-code.paused .pr-status { color: var(--warn); } .pr-code.ended .pr-status { color: var(--muted); }
.pr-code-what b { color: var(--accent); }
.pr-meter { height: 5px; margin: 4px 0 2px; border-radius: 99px; background: var(--bg2); overflow: hidden; max-width: 160px; }
.pr-meter span { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.pr-code-act { display: flex; gap: 6px; }
.pr-recent { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.pr-recent:last-child { border-bottom: 0; }
.pr-ago { margin-left: auto; }
@media (max-width: 1100px) { .pr-cols { grid-template-columns: 1fr; } }
@media (max-width: 700px) { .pr-code { grid-template-columns: 1fr 1fr; } .pr-code-act { grid-column: 1 / -1; } .pr-cmd-row .btn { width: 100%; } }
.pr-off { color: var(--warn); margin-top: 2px; } .pr-off:empty { display: none; }
.pr-label-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; } .pr-label-row label { margin-bottom: 6px; }
.pr-chips { max-height: 132px; overflow-y: auto; }

/* player profile: reset */
.ac-reset { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.reset-opts { display: grid; gap: 8px; margin: 4px 0 6px; }
.reset-opt { display: flex; gap: 12px; align-items: flex-start; margin: 0; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); cursor: pointer; font-weight: 400; }
.reset-opt:hover { border-color: var(--line-strong); }
.reset-opt:has(input:checked) { border-color: var(--accent-line); background: var(--accent-soft); }
.reset-opt input { width: 17px; height: 17px; margin-top: 2px; flex: none; accent-color: var(--accent); }

/* anti-cheat: demos */
.acx-demo-tools { display: flex; align-items: center; gap: 10px; }
.acx-rec { margin: 0; gap: 8px; font-size: 13px; font-weight: 600; }
.acx-demo-status { margin: -4px 0 10px; }
.acx-demo-list { display: grid; gap: 6px; }
.acx-demo { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto; grid-template-areas: "who meta act" "why why act"; gap: 2px 14px; align-items: center;
  padding: 10px 12px; background: var(--bg2); border: 1px solid var(--line); border-radius: 8px; }
.acx-demo-who { grid-area: who; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; min-width: 0; }
.acx-demo-why { grid-area: why; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acx-demo-meta { grid-area: meta; color: var(--muted); }
.acx-demo-act, .acx-demo-prog, .acx-demo > .btn { grid-area: act; justify-self: end; }
.acx-demo-act { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.acx-demo-prog { min-width: 130px; } .acx-demo-prog .acx-meter { margin-top: 4px; }
.acx-demo-empty { padding: 12px 14px; border: 1px dashed var(--line-strong); border-radius: 8px; } .acx-demo-empty p { margin: 4px 0 0; }
.acx-demo-help { margin: 10px 0 0; }
@container acx (max-width: 640px) { .acx-demo { grid-template-columns: 1fr; grid-template-areas: "who" "meta" "why" "act"; } .acx-demo-act, .acx-demo-prog, .acx-demo > .btn { justify-self: start; margin-top: 6px; } }

/* anti-cheat: protection (anti-ESP) */
.acx-esp-main { align-items: flex-start; margin: 0; }
.acx-esp-main .muted { max-width: 720px; }
.acx-esp-old { margin: 12px 0 0; }
.acx-esp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 22px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); transition: opacity .15s; }
.acx-esp.off .acx-esp-grid { opacity: .4; pointer-events: none; }
.acx-esp-label { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 13.5px; font-weight: 600; }
.acx-esp-label b { color: var(--accent); font-size: 13px; }
.acx-esp-field .muted { margin-top: 2px; }
@container acx (max-width: 640px) { .acx-esp-grid { grid-template-columns: 1fr; } }

/* ---- Trust score (player profile) ---- */
.trust.t-trusted { --tc: var(--ok); }
.trust.t-medium  { --tc: #c9b14e; }
.trust.t-guarded { --tc: var(--warn); }
.trust.t-low     { --tc: var(--err); }
.trust .trust-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.trust-badge { display: inline-flex; align-items: baseline; gap: 6px; }
.trust-badge b { font-size: 22px; line-height: 1; color: var(--tc); }
.trust-badge span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.trust-bar { height: 8px; border-radius: 5px; overflow: hidden; margin: 8px 0 10px; background: color-mix(in srgb, var(--tc) 16%, transparent); }
.trust-bar span { display: block; height: 100%; background: var(--tc); border-radius: 5px; }
.trust-factors { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
.trust-factors li { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; }
.trust-factors li > span { color: var(--muted); }
.trust-factors li.up b { color: var(--ok); }
.trust-factors li.down b { color: var(--err); }

/* ---- Anti-cheat reviews ---- */
.acx-reviews .acx-badge { display: inline-flex; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 4px;
  border-radius: 9px; background: var(--err); color: #fff; font-size: 11px; font-weight: 700; align-items: center; justify-content: center; }
.acx-reviews .acx-badge[hidden] { display: none; }
.acx-review { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; margin-bottom: 8px;
  background: color-mix(in srgb, var(--err) 6%, var(--panel)); }
.acx-review-top { display: flex; align-items: center; gap: 8px; }
.acx-review-top .acx-who { font-weight: 600; margin-right: auto; text-align: left; }
.acx-review-why { margin: 5px 0 0; }
.acx-review-chips { display: flex; flex-wrap: wrap; gap: 4px; margin: 7px 0 0; }
.acx-review .acx-chip { font-size: 11px; padding: 1px 6px; border-radius: 4px;
  background: color-mix(in srgb, var(--warn) 16%, transparent); color: var(--warn-ink, #f0d3a8); }
.acx-review-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 9px; }
.acx-review-btns { display: flex; gap: 6px; }
