[hidden] { display: none !important; }
:root {
  --bg: #f6f7f8;
  --panel: #fff;
  --ink: #1d2327;
  --muted: #66717a;
  --line: #e2e6e9;
  --accent: #1f6f5c;
  --accent-ink: #fff;
  --warn: #a15c00;
  --bad: #b3261e;
  --good: #1f6f3a;
  --radius: 8px;
  font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--accent); }
.top {
  display: flex; align-items: center; gap: 24px; padding: 10px 20px;
  background: #263238; color: #fff; position: sticky; top: 0; z-index: 5;
}
.top a { color: #cfd8dc; text-decoration: none; }
.top a.active, .top a:hover { color: #fff; }
.brand { font-weight: 700; color: #fff !important; letter-spacing: .02em; }
nav { display: flex; gap: 16px; flex-wrap: wrap; flex: 1; }
.who { font-size: 12px; color: #b0bec5; }
.link { background: none; border: 0; color: inherit; text-decoration: underline; cursor: pointer; padding: 0; font: inherit; }
main { max-width: 1280px; margin: 0 auto; padding: 20px; }
h1 { font-size: 20px; margin: 0 0 16px; }
h2 { font-size: 15px; margin: 24px 0 10px; }
.muted { color: var(--muted); }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; }
.grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.stat .label { color: var(--muted); font-size: 12px; }
.stat .value { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat.warn .value { color: var(--warn); }
.stat.bad .value { color: var(--bad); }
table { width: 100%; border-collapse: collapse; background: var(--panel); font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 7px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 12px; color: var(--muted); font-weight: 600; background: #fafbfb; position: sticky; top: 49px; }
td.num, th.num { text-align: right; }
tr.click { cursor: pointer; }
tr.click:hover td { background: #f3f7f6; }
.neg { color: var(--bad); font-weight: 600; }
.pill { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; background: #eceff1; }
.pill.live { background: #ffe0b2; color: #7a3d00; font-weight: 600; }
.pill.shadow { background: #e3f2fd; color: #0d47a1; }
.pill.ok { background: #e2f3e6; color: var(--good); }
.pill.bad { background: #fde7e6; color: var(--bad); }
form.inline, .toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: end; margin-bottom: 12px; }
label { display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: var(--muted); }
input, select, textarea {
  font: inherit; color: var(--ink); padding: 6px 8px; border: 1px solid #cfd6db; border-radius: 6px; background: #fff; min-width: 0;
}
textarea { width: 100%; min-height: 120px; font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
button, .button {
  font: inherit; padding: 6px 12px; border-radius: 6px; border: 1px solid var(--accent); background: var(--accent);
  color: var(--accent-ink); cursor: pointer; text-decoration: none; display: inline-block;
}
button.secondary { background: #fff; color: var(--accent); }
button.danger { background: var(--bad); border-color: var(--bad); }
button:disabled { opacity: .5; cursor: progress; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } nav { gap: 10px; } }
pre { background: #f4f6f7; padding: 10px; border-radius: 6px; overflow: auto; font-size: 12px; max-height: 360px; }
#toast {
  position: fixed; bottom: 20px; right: 20px; max-width: 420px; padding: 10px 14px; border-radius: 8px;
  background: #263238; color: #fff; opacity: 0; transition: opacity .2s; pointer-events: none;
}
#toast.show { opacity: 1; }
#toast.err { background: var(--bad); }
.login { max-width: 420px; margin: 60px auto; }
.right { text-align: right; }
.small { font-size: 12px; }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: 12px; word-break: break-all; }
