:root {
  --brand: #015eab;
  --bg: #f4f7fb;
  --card: #ffffff;
  --text: #1b1f23;
  --muted: #6a727d;
  --danger: #b42318;
  --ok: #067647;
}

body {
  margin: 0;
  font-family: Segoe UI, Arial, sans-serif;
  background:
    radial-gradient(1200px 700px at 10% 5%, rgba(255,255,255,0.18), transparent 58%),
    linear-gradient(140deg, #005CAE 0%, #0b4f93 55%, #073f79 100%);
  background-repeat: no-repeat;
  background-size: cover;
  background-attachment: fixed;
  color: var(--text);
}

.wrap { max-width: 1120px; margin: 28px auto; padding: 0 14px; }
.wrap-login { min-height: calc(100vh - 56px); display: flex; align-items: center; justify-content: center; }
.card { background: rgba(255,255,255,0.97); border-radius: 12px; box-shadow: 0 12px 32px rgba(4, 21, 40, 0.22); padding: 16px; margin-bottom: 14px; }
h1, h2 { margin: 0 0 10px 0; color: var(--brand); }
h1 { font-size: 23px; }
h2 { font-size: 18px; }
.muted { color: var(--muted); }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
input, select { width: 100%; max-width: 320px; padding: 9px 11px; border: 1px solid #d0d8e2; border-radius: 8px; font-size: 14px; }
button { border: none; border-radius: 8px; padding: 9px 11px; font-weight: 600; cursor: pointer; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-ghost { background: #eef4fb; color: var(--brand); }
.btn-danger { background: #ffe4e8; color: var(--danger); }
.btn-ok { background: #d1fadf; color: #067647; }
.msg { margin-top: 10px; min-height: 18px; }
.msg.err { color: var(--danger); }
.msg.ok { color: var(--ok); }
table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 13px; }
th, td { text-align: left; padding: 8px 7px; border-bottom: 1px solid #edf1f6; vertical-align: top; }
th { color: #425466; font-weight: 700; }
.table-wrap { width: 100%; overflow-x: auto; }
.table-wrap table { min-width: 760px; }
.hidden { display: none; }
.pill { display:inline-block; border-radius:999px; padding:2px 8px; font-size:12px; font-weight:700; }
.pill.on { background:#d1fadf; color:#067647; }
.pill.off { background:#fde2e2; color:#b42318; }
.grid2 { display:grid; grid-template-columns:1fr 1fr; gap: 12px; }
.nav-link { color: var(--brand); font-weight: 600; text-decoration: none; }
.header-brand { text-align: center; width: 100%; }
.header-actions { justify-content: flex-end; margin-top: 8px; }
@media (max-width: 900px) { .grid2 { grid-template-columns: 1fr; } }
