
:root {
  --bg: #071018;
  --bg2: #0c1822;
  --card: rgba(14, 32, 44, 0.86);
  --line: rgba(86, 214, 184, 0.18);
  --mint: #3ee0b4;
  --mint2: #1aa888;
  --amber: #ffb020;
  --rose: #ff5c7a;
  --text: #e8f4ef;
  --muted: #8aa39a;
  --shadow: 0 18px 50px rgba(0,0,0,.35);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: "Outfit", system-ui, sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(62,224,180,.12), transparent 50%),
    radial-gradient(900px 500px at 110% 0%, rgba(255,176,32,.08), transparent 45%),
    linear-gradient(180deg, var(--bg), #04080c 70%);
}
body::before {
  content: "";
  position: fixed; inset: 0; pointer-events: none; opacity: .22;
  background-image: linear-gradient(rgba(62,224,180,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(62,224,180,.05) 1px, transparent 1px);
  background-size: 28px 28px;
}
a { color: var(--mint); text-decoration: none; }
.mono { font-family: "JetBrains Mono", ui-monospace, monospace; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 28px 22px 48px; position: relative; }

.topbar {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; margin-bottom: 22px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.mark {
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(145deg, var(--mint), #0e6b55);
  display: grid; place-items: center; font-weight: 800; color: #04221a;
  box-shadow: 0 0 24px rgba(62,224,180,.35);
}
.brand h1 { margin: 0; font-size: 20px; letter-spacing: .08em; }
.brand p { margin: 2px 0 0; color: var(--muted); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; }
.actions { display: flex; gap: 10px; align-items: center; }
.btn {
  border: 0; border-radius: 10px; padding: 10px 16px; cursor: pointer;
  font-weight: 650; font-family: inherit;
}
.btn-ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }
.btn-mint { background: linear-gradient(135deg, var(--mint), var(--mint2)); color: #04221a; }

.grid { display: grid; gap: 14px; }
.g4 { grid-template-columns: repeat(4, 1fr); }
.g2 { grid-template-columns: 1.2fr .8fr; }
.g3 { grid-template-columns: 1fr 1fr 1fr; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  padding: 16px 18px; box-shadow: var(--shadow); backdrop-filter: blur(10px);
}
.card h3 { margin: 0 0 12px; font-size: 13px; color: var(--muted); letter-spacing: .14em; text-transform: uppercase; }
.kpi { font-size: 28px; font-weight: 700; }
.kpi small { font-size: 13px; color: var(--muted); font-weight: 500; }
.bar { height: 8px; background: #10222b; border-radius: 99px; overflow: hidden; margin-top: 10px; }
.bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--mint2), var(--mint)); }
.pill { display: inline-flex; align-items: center; gap: 8px; border-radius: 99px; padding: 6px 12px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.calm { background: rgba(62,224,180,.15); color: var(--mint); }
.elevated { background: rgba(255,176,32,.16); color: var(--amber); }
.critical { background: rgba(255,92,122,.16); color: var(--rose); }
.ok { color: var(--mint); }
.bad { color: var(--rose); }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th { text-align: left; color: var(--muted); font-weight: 600; padding: 8px 6px; border-bottom: 1px solid var(--line); }
.table td { padding: 9px 6px; border-bottom: 1px solid rgba(255,255,255,.04); vertical-align: top; }
.log { font-size: 12px; line-height: 1.45; color: #cfe7de; max-height: 260px; overflow: auto; }
.foot { margin-top: 18px; color: var(--muted); font-size: 12px; }

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card {
  width: min(440px, 100%); background: var(--card); border: 1px solid var(--line);
  border-radius: 22px; padding: 32px; box-shadow: var(--shadow); position: relative;
}
.login-card h2 { margin: 14px 0 6px; }
.login-card p.sub { margin: 0 0 22px; color: var(--muted); }
label { display: block; font-size: 12px; color: var(--muted); margin: 12px 0 6px; letter-spacing: .08em; text-transform: uppercase; }
input[type=text], input[type=password] {
  width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: #08141c; color: var(--text); font: inherit;
}
.err { background: rgba(255,92,122,.12); color: var(--rose); padding: 10px 12px; border-radius: 10px; margin-bottom: 12px; font-size: 14px; }
@media (max-width: 980px) {
  .g4, .g2, .g3 { grid-template-columns: 1fr; }
}

.ip-row { display:flex; gap:10px; flex-wrap:wrap; align-items:center; margin-bottom:8px; }
.ip-input { flex:1; min-width:220px; padding:11px 14px; border-radius:12px; border:1px solid var(--line); background:#08141c; color:var(--text); font-size:14px; }
.btn-rose { background: linear-gradient(135deg, #ff6b86, #d13b58); color:#fff; }
.ip-msg { min-height: 18px; font-size:13px; color:var(--muted); margin: 4px 0 10px; }
.btn-tiny { padding: 5px 10px; font-size: 12px; border-radius: 8px; }
