/* Starcontrol Core Styles — shared across all pages */
:root {
  --bg: #0b1220;
  --panel: #111a2b;
  --line: #223250;
  --text: #e8eefc;
  --muted: #9fb1d1;
  --good: #35c46f;
  --warn: #f3b23d;
  --bad: #f05d5d;
  --brand: #4aa8ff;
  --viewed: #4aa8ff;
  --clicked: #35c46f;
  --scrolled: #7c8da6;
  --left: #f3b23d;
  --served: #6dd5ed;
  --stored: #b06ddd;
  --deleted: #f05d5d;
  --authenticated: #f4d07a;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { overflow-x: hidden; max-width: 100vw; }
body {
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(1200px 700px at 20% -20%, #1a2b49 0%, var(--bg) 60%);
  color: var(--text);
  min-height: 100vh;
}

/* --- Header / Nav --- */
header {
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 12, 23, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}
nav { display: flex; gap: 6px; }
nav a {
  padding: 6px 14px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  transition: all 0.15s;
}
nav a:hover { color: var(--text); background: rgba(255,255,255,0.05); }
nav a:focus-visible { outline: none; box-shadow: 0 0 0 2px rgba(74,168,255,0.4); }
nav a.active { color: var(--brand); background: rgba(74,168,255,0.1); }

/* --- Main Layout --- */
main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 16px 40px;
  display: grid;
  gap: 16px;
  overflow: hidden;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
}
.panel h2 {
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 12px;
}

/* --- Scrollbar --- */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
::-webkit-scrollbar-track { background: transparent; }

/* --- Status Colors --- */
.ok { color: var(--good); }
.warn { color: var(--warn); }
.bad { color: var(--bad); }
.up { color: var(--good); }
.down { color: var(--bad); }
.flat { color: var(--muted); }

/* --- Tab Bar --- */
#tab-bar:empty { display: none; }

/* --- Deprecation Banner --- */
.deprecation-banner {
  background: rgba(243, 178, 61, 0.1);
  border: 1px solid rgba(243, 178, 61, 0.3);
  border-radius: 8px;
  padding: 10px 16px;
  margin-bottom: 16px;
  font-size: 0.85rem;
  color: var(--warn);
}
.deprecation-banner a { color: var(--brand); font-weight: 600; text-decoration: none; }
.deprecation-banner a:hover { text-decoration: underline; }

/* --- Loading Placeholder --- */
.loading-placeholder {
  color: var(--muted);
  font-size: 0.85rem;
  animation: loadPulse 1.5s ease-in-out infinite;
}
.loading-placeholder.centered {
  text-align: center;
  padding: 24px 0;
}
@keyframes loadPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* --- Responsive --- */
@media (max-width: 768px) {
  header { flex-wrap: wrap; gap: 8px; }
  nav { flex-wrap: wrap; }
}
