:root {
  --bg: #0f1419;
  --panel: #161b22;
  --panel-raised: #1c232c;
  --border: #262c36;
  --text: #e6edf3;
  --muted: #8b949e;
  --accent: #e3b341;
  --accent-dim: #8a6a24;
  --ok: #3fb950;
  --err: #f85149;
  --info: #58a6ff;
  --warning: #d29922;
  --sidebar-w: 220px;
  --sidebar-w-mini: 52px;
  --header-h: 44px;
  --radius: 8px;
  --radius-lg: 12px;
  --font-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Code", Consolas, monospace;
  --shadow: 0 1px 3px rgba(0,0,0,0.3);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.4);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 13px;
  line-height: 1.4;
  overflow-x: hidden;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

/* ── Layout ──────────────────────────────────────────── */
.layout { display: flex; min-height: 100vh; }

/* ── Header ──────────────────────────────────────────── */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 12px;
  z-index: 100;
  gap: 10px;
}
.header-toggle {
  background: none; border: none; color: var(--muted);
  cursor: pointer; padding: 6px; border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.header-toggle:hover { color: var(--text); background: var(--panel-raised); }
.header-brand {
  font-weight: 600; font-size: 13px; color: var(--text);
  display: flex; align-items: center; gap: 6px;
  white-space: nowrap;
}
.header-brand .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 6px var(--accent);
  flex-shrink: 0;
}
.header-spacer { flex: 1; }
.header-user {
  display: flex; align-items: center; gap: 8px;
  color: var(--muted); font-size: 12px;
}
.header-user a { color: var(--text); }
.header-user a:hover { text-decoration: none; color: var(--accent); }

/* ── Sidebar ─────────────────────────────────────────── */
.sidebar {
  position: fixed;
  top: var(--header-h);
  left: 0;
  bottom: 0;
  width: var(--sidebar-w);
  background: var(--panel);
  border-right: 1px solid var(--border);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 90;
  transition: width 0.2s ease;
  display: flex;
  flex-direction: column;
}
.sidebar.mini { width: var(--sidebar-w-mini); }
.sidebar.mini .sidebar-label { display: none; }
.sidebar.mini .sidebar-section-title { display: none; }
.sidebar-scroll { flex: 1; overflow-y: auto; padding: 6px 0; }
.sidebar-section { margin-bottom: 4px; }
.sidebar-section-title {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--muted); padding: 6px 14px 4px;
  white-space: nowrap; overflow: hidden;
}
.sidebar-item {
  display: flex; align-items: center;
  padding: 7px 12px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  cursor: pointer;
  border-left: 2px solid transparent;
  transition: background 0.1s, color 0.1s, border-color 0.1s;
  text-decoration: none !important;
}
.sidebar-item:hover { background: var(--panel-raised); color: var(--text); }
.sidebar-item.active { color: var(--accent); border-left-color: var(--accent); background: rgba(227,179,65,0.06); }
.sidebar-item.sub { padding-left: 32px; font-size: 11px; }
.sidebar.mini .sidebar-item { padding: 7px 16px; }
.sidebar.mini .sidebar-item.sub { padding: 7px 16px; }
.sidebar-icon {
  width: 20px; height: 20px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  margin-right: 8px;
}
.sidebar.mini .sidebar-icon { margin-right: 0; }
.sidebar-item svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sidebar-label { overflow: hidden; text-overflow: ellipsis; }
.sidebar-tooltip {
  display: none; position: fixed;
  background: var(--panel-raised); border: 1px solid var(--border);
  border-radius: 4px; padding: 4px 8px; font-size: 12px;
  color: var(--text); white-space: nowrap; z-index: 200;
  pointer-events: none; box-shadow: var(--shadow-lg);
}
.sidebar-tooltip.show { display: block; }

/* ── Mobile Sidebar ──────────────────────────────────── */
@media (max-width: 768px) {
  .main, .main.wide { margin-left: 0; }
  .sidebar { display: none; }
}

/* ── Main Content ────────────────────────────────────── */
.main {
  margin-left: var(--sidebar-w);
  margin-top: var(--header-h);
  flex: 1;
  padding: 16px 20px 60px;
  max-width: min(1200px, 100%);
  transition: margin-left 0.2s ease;
}
.main.wide { margin-left: var(--sidebar-w-mini); }

/* ── Content Styles ──────────────────────────────────── */
h1 { font-size: 22px; margin: 0 0 2px; font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: 15px; margin: 0 0 10px; color: var(--text); font-weight: 600; }
h3 { font-size: 13px; margin: 0 0 6px; color: var(--text); font-weight: 600; }
.subtitle { color: var(--muted); font-size: 12px; margin: 0 0 16px; }

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
}
.panel h2:first-child { margin-top: 0; }

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  gap: 8px;
}
.row:last-child { border-bottom: none; }
.row .meta { color: var(--muted); font-size: 11px; }

.badge {
  display: inline-block;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.4;
}
.badge.local { color: var(--ok); border-color: var(--ok); }
.badge.ssh { color: var(--accent); border-color: var(--accent); }
.badge.admin { color: var(--accent); border-color: var(--accent-dim); }
.badge.operator { color: var(--text); }
.badge.viewer { color: var(--muted); }

button, .btn {
  font-family: var(--font-ui);
  background: var(--accent);
  color: #1a1300;
  border: none;
  padding: 6px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  line-height: 1.3;
  transition: filter 0.15s, transform 0.1s;
}
button:hover, .btn:hover { filter: brightness(1.1); }
button:active, .btn:active { transform: scale(0.97); }
button.secondary, .btn.secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
button.danger, .btn.danger {
  background: transparent;
  color: var(--err);
  border: 1px solid var(--err);
}
button.danger:hover, .btn.danger:hover { background: rgba(248,81,73,0.1); }
button.primary, .btn.primary { background: var(--accent); }

input, select, textarea {
  font-family: var(--font-ui);
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 6px 10px;
  border-radius: var(--radius);
  font-size: 12px;
  width: 100%;
  transition: border-color 0.15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); }

label { display: block; font-size: 11px; color: var(--muted); margin: 8px 0 3px; }
label:first-child { margin-top: 0; }

form.inline { display: inline-flex; gap: 6px; align-items: center; }

.error-box {
  background: #2b1618;
  border: 1px solid var(--err);
  color: #ffb3ae;
  padding: 8px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  margin-bottom: 10px;
}
.info-box {
  background: #132b1a;
  border: 1px solid var(--ok);
  color: #a3f0b5;
  padding: 8px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  margin-bottom: 10px;
}
.warning-box {
  background: #2b2413;
  border: 1px solid var(--warning);
  color: #f0dfa3;
  padding: 8px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  margin-bottom: 10px;
}

.empty-state {
  text-align: center;
  color: var(--muted);
  padding: 32px 16px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
  font-size: 13px;
}

/* ── Dashboard Styles ────────────────────────────────── */
.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.server-status-dot {
  width: 8px; height: 8px; border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
}
.server-status-dot.online { background: var(--ok); box-shadow: 0 0 8px var(--ok); }
.server-status-dot.offline { background: var(--err); }
.server-status-dot.maintenance { background: var(--warning); }

.status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}
.status-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  text-align: center;
  transition: border-color 0.15s, transform 0.15s;
}
.status-card:hover { border-color: var(--accent-dim); transform: translateY(-1px); }
.status-card .status-icon {
  font-size: 22px; margin-bottom: 6px;
  display: flex; align-items: center; justify-content: center;
}
.status-card .status-value {
  font-size: 18px; font-weight: 700;
  font-family: var(--font-mono);
  line-height: 1.2;
}
.status-card .status-label {
  font-size: 10px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin-top: 4px;
}
.status-card .status-bar {
  height: 3px; border-radius: 2px;
  background: var(--border); margin-top: 8px; overflow: hidden;
}
.status-card .status-bar-fill {
  height: 100%; border-radius: 2px;
  transition: width 0.5s ease;
}
.status-card .status-bar-fill.green { background: var(--ok); }
.status-card .status-bar-fill.yellow { background: var(--warning); }
.status-card .status-bar-fill.red { background: var(--err); }

/* ── Quick Actions ───────────────────────────────────── */
.section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  padding: 0 4px;
}
.section-header .section-icon {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel-raised);
  border-radius: 6px;
  color: var(--accent);
}
.section-header .section-icon svg { width: 16px; height: 16px; }
.section-header h2 { margin: 0; }
.section-header .section-count {
  font-size: 11px; color: var(--muted);
  background: var(--panel-raised); padding: 1px 6px;
  border-radius: 999px;
}

.actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
  margin-bottom: 20px;
}
.action-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 14px 10px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s;
  color: var(--text) !important;
  text-decoration: none !important;
}
.action-card:hover {
  border-color: var(--accent-dim);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.action-card:active { transform: scale(0.97); }
.action-card .action-icon {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel-raised);
  border-radius: 8px;
  font-size: 18px;
}
.action-card .action-icon svg { width: 18px; height: 18px; stroke: currentColor; }
.action-card .action-title { font-weight: 600; font-size: 12px; line-height: 1.2; }
.action-card .action-desc { font-size: 10px; color: var(--muted); line-height: 1.3; }
.action-card.danger-action { border-color: transparent; }
.action-card.danger-action:hover { border-color: var(--err); }
.action-card.danger-action .action-icon { color: var(--err); }

@media (max-width: 600px) {
  .status-grid { grid-template-columns: repeat(2, 1fr); }
  .actions-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-header { flex-direction: column; align-items: flex-start; }
}

/* ── Cat-egory Button Groups ─────────────────────────── */
.category-group {
  margin-bottom: 24px;
}
.category-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  padding: 8px 12px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  user-select: none;
  transition: background 0.1s;
}
.category-header:hover { background: var(--panel-raised); }
.category-header .cat-icon { font-size: 18px; }
.category-header .cat-title { font-weight: 600; font-size: 13px; flex: 1; }
.category-header .cat-count { font-size: 11px; color: var(--muted); }

/* ── File Manager ────────────────────────────────────── */
.fm-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 12px;
  min-height: 400px;
}
.fm-tree {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px;
  overflow-y: auto;
  max-height: 550px;
}
.fm-tree-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 6px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 11.5px;
  color: var(--muted);
  transition: background 0.1s, color 0.1s;
  text-decoration: none !important;
}
.fm-tree-item:hover { background: var(--panel-raised); color: var(--text); }
.fm-tree-item.active { background: rgba(227,179,65,0.1); color: var(--accent); }
.fm-tree-item .fm-tree-icon { width: 14px; text-align: center; flex-shrink: 0; }
.fm-tree-item .fm-tree-spacer { width: 14px; flex-shrink: 0; }
.fm-tree-item.indent-1 { padding-left: 20px; }
.fm-tree-item.indent-2 { padding-left: 34px; }
.fm-tree-item.indent-3 { padding-left: 48px; }

.fm-main {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.fm-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding: 8px 12px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.fm-toolbar .btn { font-size: 11px; padding: 4px 8px; }
.fm-path {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  padding: 0 4px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.fm-table th {
  text-align: left;
  padding: 6px 10px;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  font-weight: 500;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: var(--panel-raised);
  cursor: pointer;
  user-select: none;
}
.fm-table td {
  padding: 5px 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.fm-table tr:last-child td { border-bottom: none; }
.fm-table tr:hover td { background: var(--panel-raised); }
.fm-table tr.selected td { background: rgba(227,179,65,0.08); }
.fm-table .fm-name {
  display: flex; align-items: center; gap: 8px;
  cursor: pointer; color: var(--text) !important; text-decoration: none !important;
}
.fm-table .fm-name:hover { color: var(--accent) !important; }
.fm-table .fm-name-icon { font-size: 14px; width: 18px; text-align: center; flex-shrink: 0; }
.fm-context-menu {
  position: fixed;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 0;
  box-shadow: var(--shadow-lg);
  z-index: 500;
  min-width: 160px;
  display: none;
}
.fm-context-menu.show { display: block; }
.fm-context-menu .ctx-item {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px; font-size: 12px;
  color: var(--text); cursor: pointer;
  transition: background 0.1s;
}
.fm-context-menu .ctx-item:hover { background: var(--panel); }
.fm-context-menu .ctx-item.ctx-danger { color: var(--err); }
.fm-context-menu .ctx-divider { height: 1px; background: var(--border); margin: 4px 0; }

@media (max-width: 768px) {
  .fm-layout { grid-template-columns: 1fr; }
  .fm-tree { display: none; }
}

/* ── Console Terminal ────────────────────────────────── */
.terminal-wrapper {
  background: #05070a;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 14px;
}
.terminal-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
}
.terminal-dot { width: 10px; height: 10px; border-radius: 50%; }
.terminal-dot.red { background: #ff5f57; }
.terminal-dot.yellow { background: #febc2e; }
.terminal-dot.green { background: #28c840; }
.terminal-title { color: var(--muted); font-size: 11px; margin-left: 8px; flex: 1; }
.terminal-header-actions { display: flex; gap: 4px; }
.terminal-header-actions .btn { font-size: 10px; padding: 3px 7px; }

.terminal-screen {
  padding: 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  color: #c9d1d9;
  max-height: 420px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-word;
}
.terminal-screen:empty::before {
  content: 'Running command…';
  color: var(--muted);
  font-style: italic;
}
.terminal-status {
  padding: 6px 14px;
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.terminal-status.running { color: var(--accent); }
.terminal-status.ok { color: var(--ok); }
.terminal-status.failed { color: var(--err); }
.terminal-status .spinner {
  width: 12px; height: 12px;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.terminal-input-area {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 12px 14px;
  background: var(--panel);
  border-top: 1px solid var(--border);
}
.terminal-input-area .terminal-prompt {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ok);
  flex-shrink: 0;
}
.terminal-input-area input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 4px 0;
  outline: none;
}
.terminal-input-area input:focus { border-color: transparent; }

.terminal-predefined {
  margin-bottom: 14px;
}
.terminal-predefined summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  user-select: none;
  padding: 4px 0;
}
.terminal-predefined summary:hover { color: var(--text); }
.terminal-commands-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
}
.terminal-commands-grid .cmd-btn {
  font-size: 10.5px;
  padding: 3px 8px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s;
  font-family: var(--font-mono);
}
.terminal-commands-grid .cmd-btn:hover { border-color: var(--accent); color: var(--accent); }
.terminal-commands-grid .cmd-btn.fav::after { content: ' ★'; color: var(--accent); }

.terminal-fullscreen .terminal-screen { max-height: calc(100vh - 200px); }
.terminal-fullscreen .terminal-wrapper {
  position: fixed;
  inset: 0;
  z-index: 300;
  border-radius: 0;
  display: flex;
  flex-direction: column;
}
.terminal-fullscreen .terminal-screen { flex: 1; }

/* ── Toast / Notifications ───────────────────────────── */
.toast-container {
  position: fixed;
  top: 56px;
  right: 16px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 360px;
}
.toast {
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 12px;
  color: var(--text);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 8px;
  animation: toast-in 0.3s ease;
  border: 1px solid var(--border);
}
.toast.success { border-color: var(--ok); background: #132b1a; }
.toast.error { border-color: var(--err); background: #2b1618; }
.toast.info { border-color: var(--info); background: #13243b; }
.toast.warning { border-color: var(--warning); background: #2b2413; }
.toast .toast-close {
  margin-left: auto;
  cursor: pointer;
  opacity: 0.5;
  background: none;
  border: none;
  color: var(--text);
  padding: 0;
  font-size: 14px;
}
.toast .toast-close:hover { opacity: 1; }
.toast.out { animation: toast-out 0.3s ease forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: translateX(0); } }
@keyframes toast-out { from { opacity: 1; transform: translateX(0); } to { opacity: 0; transform: translateX(40px); } }

/* ── Confirm Dialog ──────────────────────────────────── */
.dialog-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 500;
  align-items: center;
  justify-content: center;
}
.dialog-overlay.show { display: flex; }
.dialog-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  max-width: 420px;
  width: 90%;
  box-shadow: var(--shadow-lg);
}
.dialog-box h3 { margin: 0 0 8px; }
.dialog-box p { color: var(--muted); font-size: 12px; margin: 0 0 16px; line-height: 1.5; }
.dialog-actions { display: flex; gap: 8px; justify-content: flex-end; }

/* ── Grid Helpers ────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.grid-5 { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
@media (max-width: 900px) { .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .grid-2, .grid-3, .grid-4, .grid-5 { grid-template-columns: 1fr; } }

.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.flex-wrap { display: flex; gap: 6px; flex-wrap: wrap; }

nav.service-nav { display: flex; gap: 4px; margin-bottom: 12px; flex-wrap: wrap; }
nav.service-nav .btn, nav.service-nav a.btn { font-size: 11px; padding: 3px 8px; border-radius: 4px; }

.stat-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
}
.stat-card .stat-value { font-size: 20px; font-weight: 700; font-family: var(--font-mono); }
.stat-card .stat-label { font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; margin-top: 2px; }

.danger-zone { border-color: var(--err); }
.danger-zone h2 { color: var(--err); }

/* ── Loading shimmer ─────────────────────────────────── */
@keyframes shimmer {
  0% { background-position: -200px 0; }
  100% { background-position: calc(200px + 100%) 0; }
}
.loading {
  background: linear-gradient(90deg, var(--panel) 25%, var(--panel-raised) 50%, var(--panel) 75%);
  background-size: 200px 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius);
  min-height: 60px;
}

/* ── Table (standard) ────────────────────────────────── */
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th, td { text-align: left; padding: 6px 10px; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-weight: 500; font-size: 10px; text-transform: uppercase; letter-spacing: 0.03em; }
td.mono, .mono { font-family: var(--font-mono); font-size: 11.5px; }

/* ── Login ──────────────────────────────────────────── */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}
.login-box {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 100%;
  max-width: 360px;
}
.login-box h1 { text-align: center; margin-bottom: 20px; font-size: 20px; }
.login-box .dot {
  display: inline-block;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 8px var(--accent);
  margin-right: 6px;
}
