:root { --bg:#0f1419; --card:#18202a; --line:#26323f; --text:#e6edf3; --muted:#8b98a5; --ok:#3fb950; --warn:#d29922; --bad:#f85149; --info:#58a6ff; }
* { box-sizing: border-box; }
body { margin:0; background:var(--bg); color:var(--text); font:14px/1.45 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; }
.hidden { display:none !important; }
header { display:flex; align-items:center; gap:16px; padding:10px 20px; background:var(--card); border-bottom:1px solid var(--line); position:sticky; top:0; z-index:5; flex-wrap:wrap; }
nav { display:flex; gap:4px; flex-wrap:wrap; }
nav button { background:none; border:0; color:var(--muted); padding:6px 12px; border-radius:6px; cursor:pointer; font:inherit; }
nav button.active, nav button:hover { background:var(--line); color:var(--text); }
.spacer { flex:1; }
main { padding:20px; max-width:1400px; margin:0 auto; }
h2 { margin:0 0 12px; font-size:18px; }
h3 { margin:0 0 10px; font-size:14px; color:var(--muted); font-weight:600; text-transform:uppercase; letter-spacing:.04em; }
.grid { display:grid; gap:14px; margin-bottom:14px; }
.g4 { grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); }
.g2 { grid-template-columns:repeat(auto-fit,minmax(420px,1fr)); }
.card { background:var(--card); border:1px solid var(--line); border-radius:10px; padding:14px 16px; overflow:hidden; }
.kpi .v { font-size:26px; font-weight:600; }
.kpi .s { color:var(--muted); font-size:12px; }
.muted { color:var(--muted); }
.bar { height:6px; background:var(--line); border-radius:3px; margin-top:6px; }
.bar > i { display:block; height:100%; border-radius:3px; background:var(--ok); }
.bar > i.warn { background:var(--warn); } .bar > i.bad { background:var(--bad); }
table { width:100%; border-collapse:collapse; }
th, td { text-align:left; padding:6px 8px; border-bottom:1px solid var(--line); vertical-align:top; }
th { color:var(--muted); font-weight:600; font-size:12px; }
td.num, th.num { text-align:right; font-variant-numeric:tabular-nums; }
.scroll { overflow-x:auto; }
.pill { display:inline-block; padding:1px 8px; border-radius:10px; font-size:12px; background:var(--line); }
.pill.ok, .pill.normal { background:#12341c; color:var(--ok); } .pill.warn, .pill.warning, .pill.busy { background:#3b2e0c; color:var(--warn); }
.pill.bad, .pill.error, .pill.critical, .pill.congested { background:#41161a; color:var(--bad); } .pill.info { background:#10304f; color:var(--info); }
.toolbar { display:flex; gap:8px; flex-wrap:wrap; align-items:center; margin-bottom:14px; }
input, select, button { font:inherit; color:var(--text); background:#0d1218; border:1px solid var(--line); border-radius:6px; padding:6px 10px; }
button { cursor:pointer; background:#1f6feb; border-color:#1f6feb; color:#fff; }
button.ghost { background:none; border-color:var(--line); color:var(--text); }
button.danger { background:var(--bad); border-color:var(--bad); }
button:disabled { opacity:.5; cursor:default; }
.chart { position:relative; height:240px; }
.login { min-height:100vh; display:grid; place-items:center; }
.login-card { width:340px; display:grid; gap:12px; }
.login-card label { display:grid; gap:4px; color:var(--muted); }
.error { color:var(--bad); margin:0; min-height:1em; }
.msg { color:var(--info); }
pre { margin:6px 0 0; padding:8px; background:#0d1218; border-radius:6px; white-space:pre-wrap; word-break:break-word; max-height:260px; overflow:auto; font-size:12px; }
.msgcell { max-width:640px; word-break:break-word; }
.alertrow { display:flex; gap:10px; align-items:baseline; padding:6px 0; border-bottom:1px solid var(--line); }
.form { display:grid; grid-template-columns:repeat(auto-fit,minmax(180px,1fr)); gap:12px; }
.form label { display:grid; gap:4px; color:var(--muted); }
.notice { padding:10px 14px; border:1px solid var(--warn); border-radius:8px; color:var(--warn); margin-bottom:14px; }
