﻿:root {
  --bg: #0b1220;
  --bg-soft: #111b2d;
  --panel: #16243a;
  --panel-soft: #1d2f4a;
  --text: #e7edf7;
  --text-soft: #9fb0c9;
  --border: #2b3d5a;
  --primary: #2dd4bf;
  --primary-soft: #1fa090;
  --danger: #f87171;
  --warning: #facc15;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: "Segoe UI", "Inter", sans-serif;
  background: radial-gradient(circle at 10% 10%, #12203a, var(--bg));
  color: var(--text);
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.admin-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

.sidebar {
  border-right: 1px solid var(--border);
  background: linear-gradient(180deg, #0f1a2c, #0b1220);
  padding: 24px 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.brand h1 {
  margin: 0;
  font-size: 18px;
}

.brand p {
  margin: 2px 0 0;
  color: var(--text-soft);
  font-size: 12px;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #34d399);
  color: #032620;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

.nav-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--text);
  background: transparent;
  margin-bottom: 8px;
}

.nav-menu a:hover {
  background: var(--panel-soft);
  text-decoration: none;
}

.content {
  padding: 22px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.topbar h2 {
  margin: 0;
  font-size: 20px;
}

.topbar-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.page-body {
  background: color-mix(in oklab, var(--panel) 92%, black);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
}

.auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 24px;
}

.auth-card h2 {
  margin-top: 0;
}

.text-muted {
  color: var(--text-soft);
}

.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.card {
  background: var(--panel-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
}

.card .label {
  color: var(--text-soft);
  font-size: 12px;
  margin-bottom: 6px;
}

.card .value {
  font-size: 22px;
  font-weight: 700;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  border-bottom: 1px solid var(--border);
  text-align: left;
  padding: 10px 8px;
  font-size: 14px;
  white-space: nowrap;
}

th {
  color: var(--text-soft);
  font-weight: 600;
}

input {
  width: 100%;
  background: #0c1526;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  margin-top: 6px;
}

select {
  width: 100%;
  background: #0c1526;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  margin-top: 6px;
}

.input-row {
  margin-bottom: 12px;
}

.btn {
  border: 0;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: 600;
  display: inline-block;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #22d3ee);
  color: #052421;
}

.btn-primary:hover {
  filter: brightness(1.05);
}

.btn-secondary {
  background: #26354d;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-danger {
  background: #4b1e26;
  color: #fecdd3;
  border: 1px solid #7f1d2f;
}

.badge {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--panel-soft);
  color: var(--text-soft);
  font-size: 12px;
}

.badge-ok {
  color: #86efac;
  border-color: #166534;
  background: #0f2d1c;
}

.badge-off {
  color: #fecaca;
  border-color: #7f1d1d;
  background: #321515;
}

.section-header {
  margin: 22px 0 12px;
  font-size: 15px;
  color: var(--text-soft);
}

.alert {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #14532d;
  background: #0f2d1c;
  color: #bbf7d0;
  margin-bottom: 14px;
}

.validation-summary-errors {
  color: #fca5a5;
  margin-top: 10px;
}

@media (max-width: 980px) {
  .admin-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .grid-two {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 14px;
  }
}
