:root {
  color-scheme: light;
  --bg:#f4f7fb; --surface:#fff; --surface-soft:#f8fafc; --text:#111b35; --muted:#667085;
  --border:#dfe5ee; --accent:#1266f1; --accent-dark:#0b52ca; --green:#159447; --amber:#d88900; --red:#d92d3f;
  --shadow:0 14px 42px rgba(23,42,75,.08); --radius:12px;
  font-family:Inter,"SF Pro Text","PingFang SC","Microsoft YaHei",system-ui,sans-serif;
}
*{box-sizing:border-box} body{margin:0;color:var(--text);background:var(--bg);font-size:14px;line-height:1.5}
button,input,select{font:inherit} button{cursor:pointer} button:disabled{cursor:not-allowed;opacity:.5}
:focus-visible{outline:3px solid rgba(18,102,241,.25);outline-offset:2px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.topbar{height:72px;padding:0 4vw;background:var(--surface);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between}
.brand{display:flex;align-items:center;gap:11px;color:var(--text);font-size:20px;font-weight:760;text-decoration:none;letter-spacing:-.02em}
.brand-mark{width:42px;height:42px;border-radius:11px;display:grid;place-items:center;background:var(--accent);color:#fff;font-weight:800;box-shadow:0 7px 18px rgba(18,102,241,.22)}.brand-mark.small{width:32px;height:32px;border-radius:8px;font-size:13px}
.button{border:1px solid var(--border);border-radius:8px;padding:9px 17px;background:#fff;color:var(--text);font-weight:650;min-height:40px;transition:.15s ease}.button:hover{border-color:#b7c2d2;background:#fbfcfe}.button.primary{color:#fff;background:var(--accent);border-color:var(--accent)}.button.primary:hover{background:var(--accent-dark)}.button.secondary{color:var(--accent);border-color:#72a5f7}.button.quiet{background:transparent}.button.full{width:100%;margin-top:5px}
.workspace{width:min(1460px,94vw);margin:26px auto 50px}.status-grid{display:grid;grid-template-columns:repeat(4,1fr);background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);box-shadow:var(--shadow);overflow:hidden}
.status-item{padding:22px 24px;min-height:126px;border-right:1px solid var(--border);display:flex;flex-direction:column;justify-content:center}.status-item:last-child{border-right:0}.status-label{color:var(--muted);font-size:13px;margin-bottom:7px}.status-item strong{font-size:20px;line-height:1.25;letter-spacing:-.02em}.status-item small{margin-top:7px;color:var(--muted)}.healthy{color:var(--green)!important}.unhealthy{color:var(--red)!important}
.operations{margin-top:18px;padding:16px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);display:flex;align-items:center;gap:32px}.operation-buttons{display:flex;gap:10px;flex:0 0 auto}.task-panel{flex:1}.task-copy{display:flex;justify-content:space-between;color:var(--muted);font-size:13px;margin-bottom:7px}.task-copy strong{color:var(--text)}progress{width:100%;height:7px;border:0;border-radius:10px;overflow:hidden}progress::-webkit-progress-bar{background:#e9edf3}progress::-webkit-progress-value{background:var(--accent);border-radius:10px}
.subscription-settings{margin-top:18px;padding:19px 22px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);display:grid;grid-template-columns:minmax(220px,1fr) minmax(420px,2fr);align-items:end;gap:28px}.settings-copy h2{margin:0 0 3px;font-size:17px}.settings-copy p{margin:0;color:var(--muted);font-size:13px}.subscription-form label{display:block;margin-bottom:6px;color:var(--muted);font-size:12px;font-weight:700}.subscription-control{display:flex;gap:9px}.subscription-control input{min-width:0;flex:1;height:40px;border:1px solid var(--border);border-radius:8px;padding:0 12px;color:var(--text);background:#fff}.subscription-control input:focus{border-color:var(--accent)}
.node-panel{margin-top:18px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);box-shadow:var(--shadow);overflow:hidden}.panel-heading{padding:20px 22px 16px;display:flex;align-items:flex-end;justify-content:space-between;gap:20px}.panel-heading h1{font-size:18px;margin:0 0 2px}.panel-heading p{margin:0;color:var(--muted);font-size:13px}.filters{display:flex;gap:9px}.filters input,.filters select{height:40px;border:1px solid var(--border);border-radius:8px;background:#fff;color:var(--text);padding:0 12px}.filters input{width:260px}.filters select{min-width:130px}
.table-wrap{border-top:1px solid var(--border)}table{width:100%;border-collapse:collapse}th,td{text-align:left;padding:14px 18px;border-bottom:1px solid #edf0f4;vertical-align:middle}th{color:#4a5568;font-size:12px;font-weight:700;background:#fafbfd;text-transform:none}tbody tr:hover{background:#f8fbff}tbody tr.current{background:#f3f8ff}.node-name{font-weight:680;color:#1c2b4a}.node-sub{display:block;color:var(--muted);font-size:12px;margin-top:2px}.current-tag{display:inline-block;margin-left:7px;padding:2px 6px;border-radius:5px;color:#fff;background:var(--accent);font-size:10px;vertical-align:2px}.latency{font-variant-numeric:tabular-nums;font-weight:700}.latency.good{color:var(--green)}.latency.mid{color:var(--amber)}.latency.bad{color:var(--red)}.state{display:inline-flex;align-items:center;gap:7px}.state::before{content:"";width:7px;height:7px;border-radius:50%;background:#98a2b3}.state.reachable{color:var(--green)}.state.reachable::before{background:var(--green)}.state.failed{color:var(--red)}.state.failed::before{background:var(--red)}.sort{border:0;background:transparent;color:inherit;font-weight:inherit;padding:0}.empty-state{text-align:center;color:var(--muted);padding:50px}.mobile-nodes{display:none}
dialog{border:0;padding:0;background:transparent}dialog::backdrop{background:rgba(17,27,53,.38);backdrop-filter:blur(2px)}.dialog-card{width:min(460px,90vw);padding:27px;background:#fff;border-radius:13px;box-shadow:0 28px 80px rgba(15,23,42,.24);position:relative}.dialog-card h2{margin:0 0 8px;font-size:20px}.dialog-card p{margin:0;color:var(--muted)}.dialog-close{position:absolute;right:15px;top:13px;border:0;background:transparent;font-size:24px;color:var(--muted)}.target-node{margin:20px 0;padding:15px;background:var(--surface-soft);border:1px solid var(--border);border-radius:9px;display:flex;flex-direction:column}.target-node span{margin-top:4px;color:var(--muted)}.dialog-actions{display:flex;justify-content:flex-end;gap:9px}.toast{position:fixed;right:24px;bottom:24px;max-width:380px;padding:13px 17px;border-radius:9px;background:#18233d;color:#fff;box-shadow:var(--shadow);z-index:20}
.login-page{min-height:100vh;display:grid;place-items:center;background:var(--bg)}.login-shell{width:min(410px,92vw)}.login-card{background:#fff;border:1px solid var(--border);border-radius:15px;padding:38px;box-shadow:0 24px 70px rgba(23,42,75,.12)}.login-card .brand-mark{margin:0 auto}.login-card h1{text-align:center;margin:15px 0 27px;font-size:25px}.login-card label{display:block;font-weight:650;margin:14px 0 6px}.login-card input{width:100%;height:44px;border:1px solid var(--border);border-radius:8px;padding:0 12px}.login-card input:focus{border-color:var(--accent)}.form-error{min-height:21px;margin:8px 0 1px;color:var(--red);font-size:13px}.security-note{text-align:center;color:var(--muted);font-size:12px;margin:19px 0 0}
@media (max-width:900px){.status-grid{grid-template-columns:repeat(2,1fr)}.status-item:nth-child(2){border-right:0}.status-item:nth-child(-n+2){border-bottom:1px solid var(--border)}.subscription-settings{grid-template-columns:1fr;gap:14px}.panel-heading{align-items:stretch;flex-direction:column}.filters{display:grid;grid-template-columns:1fr 1fr}.filters .search{grid-column:1/-1}.filters input,.filters select{width:100%}.table-wrap table{display:none}.mobile-nodes{display:grid;gap:10px;padding:12px}.mobile-node{border:1px solid var(--border);border-radius:9px;padding:14px;display:grid;grid-template-columns:1fr auto;gap:9px;background:#fff}.mobile-node.current{border-color:#8ab5fa;background:#f7faff}.mobile-node .meta{color:var(--muted);font-size:12px}.mobile-node .mobile-actions{grid-column:1/-1;display:flex;justify-content:space-between;align-items:center}}
@media (max-width:560px){.topbar{height:62px;padding:0 16px}.brand{font-size:18px}.workspace{width:calc(100% - 24px);margin:14px auto 30px}.status-grid{box-shadow:none}.status-item{padding:16px;min-height:102px}.status-item strong{font-size:16px}.operations{align-items:stretch;flex-direction:column;gap:14px}.operation-buttons{display:grid;grid-template-columns:1fr 1fr}.subscription-settings{padding:16px}.subscription-control{align-items:stretch;flex-direction:column}.panel-heading{padding:17px 15px 12px}.filters{grid-template-columns:1fr}.filters .search{grid-column:auto}.login-card{padding:29px 23px}.toast{left:12px;right:12px;bottom:12px}}
@media (prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
