:root {
  --bg: #0a0a0c;
  --panel: #141418;
  --line: rgba(255,255,255,.10);
  --text: #f5f5f5;
  --muted: #a1a1aa;
  --accent: #e10600;
  --accent-2: #ff3b30;
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #fb7185;
  --radius: 16px;
  --font: "Manrope", system-ui, sans-serif;
  --display: "Syne", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(900px 420px at 8% -10%, rgba(225,6,0,.18), transparent 55%),
    radial-gradient(700px 360px at 100% 0%, rgba(255,59,48,.08), transparent 50%),
    linear-gradient(165deg, #050506, #0a0a0c 45%, #121214);
}
a { color: var(--accent-2); text-decoration: none; }
.shell { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.sidebar {
  padding: 28px 18px;
  border-right: 1px solid var(--line);
  background: rgba(8,8,10,.86);
  backdrop-filter: blur(10px);
}
.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.brand-logo {
  width: 48px; height: 48px; border-radius: 50%;
  object-fit: cover; display: block;
  box-shadow: 0 0 0 2px rgba(225,6,0,.35);
}
.brand strong { display: block; font-family: var(--display); font-size: 1.15rem; }
.brand span { color: var(--muted); font-size: .8rem; }
.nav a {
  display: block; padding: 11px 14px; border-radius: 12px;
  color: var(--muted); margin-bottom: 4px;
}
.nav a:hover, .nav a.active { background: rgba(225,6,0,.16); color: #fff; }
.content { padding: 28px; }
.topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; }
h1, h2 { font-family: var(--display); margin: 0 0 8px; }
.muted { color: var(--muted); }
.grid { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: 1fr 1fr; }
@media (max-width: 980px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .grid-4, .grid-2 { grid-template-columns: 1fr; }
}
.card {
  background: rgba(20,20,24,.92);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}
.stat-value { font-size: 1.8rem; font-weight: 700; font-family: var(--display); }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 12px; padding: 10px 16px; cursor: pointer;
  background: var(--accent); color: #fff; font-weight: 600;
}
.btn.secondary { background: rgba(148,163,184,.15); color: var(--text); }
.btn.danger { background: rgba(251,113,133,.2); color: #fecdd3; }
input, select, textarea {
  width: 100%; padding: 11px 12px; border-radius: 12px;
  border: 1px solid var(--line); background: #0b0b0e; color: var(--text);
}
label { display: block; font-size: .85rem; color: var(--muted); margin: 10px 0 6px; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); font-size: .92rem; }
.badge {
  display: inline-block; padding: 3px 8px; border-radius: 999px; font-size: .75rem;
  background: rgba(148,163,184,.15); color: var(--muted);
}
.badge.ok { background: rgba(52,211,153,.15); color: var(--ok); }
.badge.warn { background: rgba(251,191,36,.15); color: var(--warn); }
.badge.danger { background: rgba(251,113,133,.15); color: var(--danger); }
.alert {
  padding: 12px 14px; border-radius: 12px; margin-bottom: 16px;
  border: 1px solid var(--line);
}
.alert.ok { background: rgba(52,211,153,.1); }
.alert.error { background: rgba(251,113,133,.1); }
.login-page {
  min-height: 100vh; display: grid; place-items: center; padding: 24px;
}
.login-card { width: min(420px, 100%); }
.login-hero {
  display: flex; flex-direction: column; align-items: center; gap: 12px; margin-bottom: 18px;
}
.login-hero img {
  width: 120px; height: 120px; border-radius: 50%; object-fit: cover;
  box-shadow: 0 12px 40px rgba(225,6,0,.25);
}
.form-actions { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.switch { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
