:root {
  --bg: #08090c;
  --bg-2: #0c0e13;
  --panel: #11141a;
  --panel-2: #151922;
  --line: #1e232d;
  --text: #eef1f6;
  --muted: #8b93a3;
  --dim: #626b7c;
  --red: #e2262c;
  --red-soft: rgba(226, 38, 44, 0.14);
  --orange: #ff6b35;
  --green: #22c55e;
  --amber: #f59e0b;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --radius: 16px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background:
    radial-gradient(1100px 620px at 78% -8%, rgba(226, 38, 44, 0.14), transparent 60%),
    radial-gradient(900px 520px at 8% 108%, rgba(139, 92, 246, 0.08), transparent 62%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

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

/* ---------- sidebar ---------- */
.sidebar {
  background: linear-gradient(180deg, #0b0d12, #090a0e);
  border-right: 1px solid var(--line);
  padding: 22px 16px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--red), var(--orange));
  color: #fff;
  box-shadow: 0 8px 22px rgba(226, 38, 44, 0.35);
}
.brand-mark svg { width: 22px; height: 22px; }
.brand-mark .inner { opacity: 0.75; }
.brand-text strong { display: block; font-size: 15px; letter-spacing: 0.1em; }
.brand-text small { color: var(--dim); font-size: 9px; letter-spacing: 0.22em; }

.nav { display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 13px;
  border: 1px solid transparent;
  border-radius: 11px;
  background: transparent;
  color: var(--muted);
  font: 500 13.5px/1 'Inter', sans-serif;
  cursor: pointer;
  transition: 0.16s ease;
}
.nav-item svg { width: 17px; height: 17px; }
.nav-item:hover { background: #14171f; color: var(--text); }
.nav-item.active {
  background: linear-gradient(90deg, rgba(226, 38, 44, 0.24), rgba(226, 38, 44, 0.05));
  border-color: rgba(226, 38, 44, 0.4);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--red);
}

.launch-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  padding: 13px;
  border-radius: 12px;
  border: 1px solid rgba(226, 38, 44, 0.55);
  background: rgba(226, 38, 44, 0.1);
  color: #ff8a80;
  font: 700 12px/1 'Inter', sans-serif;
  letter-spacing: 0.12em;
  cursor: pointer;
  transition: 0.18s ease;
}
.launch-btn:hover { background: rgba(226, 38, 44, 0.2); color: #fff; box-shadow: 0 0 24px rgba(226, 38, 44, 0.3); }
.launch-btn.solid {
  background: linear-gradient(135deg, var(--red), var(--orange));
  border-color: transparent;
  color: #fff;
  padding: 13px 24px;
  width: auto;
}

.system-card {
  margin-top: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
}
.card-eyebrow { margin: 0 0 8px; font-size: 9.5px; letter-spacing: 0.18em; color: var(--dim); }
.system-head { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted); margin-bottom: 12px; }
.meter + .meter { margin-top: 10px; }
.meter-top { display: flex; justify-content: space-between; font-size: 9.5px; letter-spacing: 0.14em; color: var(--dim); }
.meter-top b { color: var(--text); font-size: 11px; letter-spacing: 0; }
.meter canvas { width: 100%; height: 26px; display: block; }
.sidebar-foot { margin: 12px 0 0; font-size: 10px; color: var(--dim); text-align: center; }
.sidebar-foot span { color: var(--muted); }

.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--dim); display: inline-block; }
.dot.ok, .dot.green { background: var(--green); box-shadow: 0 0 10px rgba(34, 197, 94, 0.6); }
.dot.red { background: var(--red); box-shadow: 0 0 10px rgba(226, 38, 44, 0.6); }
.dot.amber { background: var(--amber); }
.dot.blue { background: var(--blue); }
.dot.grey { background: #4b5563; }
.pulse { animation: pulse 1.5s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

/* ---------- main ---------- */
.main { padding: 24px 26px 34px; display: flex; flex-direction: column; gap: 18px; min-width: 0; }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.topbar h1 { font-size: 25px; letter-spacing: 0.02em; }
.topbar p { margin: 5px 0 0; color: var(--muted); font-size: 13px; }
.topbar-right { display: flex; align-items: center; gap: 12px; }

.pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.pill.small { letter-spacing: 0.06em; text-transform: uppercase; }
.pill.danger { border-color: rgba(226, 38, 44, 0.45); color: #ff8a80; }

.icon-btn {
  position: relative;
  width: 38px; height: 38px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  display: grid; place-items: center;
  cursor: pointer;
}
.icon-btn:hover { color: var(--text); }
.badge {
  position: absolute; top: -6px; right: -6px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 10px; font-weight: 700;
  display: grid; place-items: center;
}

.user-chip {
  display: flex; align-items: center; gap: 9px;
  padding: 6px 12px 6px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
}
.avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, var(--red), var(--orange));
  display: grid; place-items: center;
  font-size: 10.5px; font-weight: 700; color: #fff;
}
.user-chip strong { display: block; font-size: 12px; }
.user-chip small { color: var(--dim); font-size: 10px; }

.view { display: none; flex-direction: column; gap: 18px; }
.view.active { display: flex; }

/* ---------- stat cards ---------- */
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr) 1.05fr; gap: 14px; }
.stat-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
}
.stat-card strong { display: block; font-size: 26px; margin: 12px 0 3px; letter-spacing: -0.02em; }
.stat-card p { margin: 0; color: var(--muted); font-size: 12px; }
.stat-icon {
  width: 38px; height: 38px; border-radius: 11px;
  display: grid; place-items: center;
  background: var(--red-soft); color: var(--red);
  font-size: 15px;
}
.stat-icon.green { background: rgba(34, 197, 94, 0.14); color: var(--green); }
.stat-icon.purple { background: rgba(139, 92, 246, 0.16); color: var(--purple); }
.stat-icon.amber { background: rgba(245, 158, 11, 0.15); color: var(--amber); }
.stat-icon.slate { background: #1b2029; color: var(--muted); }
.delta { display: inline-block; margin-top: 9px; font-size: 11px; color: var(--green); }
.delta.warn { color: var(--amber); }
.delta.down { color: var(--red); }
.date-card strong { font-size: 18px; }

/* ---------- panels ---------- */
.board { display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: 14px; align-items: start; }
.board-2 { grid-template-columns: 1.55fr 1fr; }

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 17px;
  min-width: 0;
}
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 15px; }
.panel-head h2 { font-size: 11px; letter-spacing: 0.16em; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.panel-link {
  margin-top: 14px;
  width: 100%;
  background: none;
  border: none;
  color: var(--red);
  font: 600 10.5px/1 'Inter', sans-serif;
  letter-spacing: 0.14em;
  cursor: pointer;
  text-align: center;
}
.panel-link.inline { width: auto; margin: 0; color: var(--dim); }
.panel-link:hover { color: var(--orange); }
.empty { color: var(--dim); font-size: 12.5px; margin: 0; }

.activity-list { display: flex; flex-direction: column; gap: 15px; }
.activity-row { display: grid; gap: 7px; }
.activity-top { display: flex; align-items: center; justify-content: space-between; font-size: 13px; }
.activity-top span { display: flex; align-items: center; gap: 8px; }
.activity-top b { font-variant-numeric: tabular-nums; }
.activity-sub { display: flex; justify-content: space-between; font-size: 11px; color: var(--dim); }
.activity-sub em { font-style: normal; color: var(--red); }

.bar { height: 7px; border-radius: 999px; background: #1c212b; overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--red), var(--orange)); transition: width 0.5s ease; }
.bar.green span { background: linear-gradient(90deg, #16a34a, var(--green)); }
.bar.indeterminate span {
  width: 34% !important;
  background: linear-gradient(90deg, transparent, var(--red), var(--orange), transparent);
  animation: sweep 1.5s ease-in-out infinite;
}
@keyframes sweep { 0% { margin-left: -34%; } 100% { margin-left: 100%; } }
.phase-line {
  margin: 0 0 14px;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--orange);
  text-transform: uppercase;
}

/* queue donut */
.queue { display: flex; align-items: center; gap: 16px; }
.donut {
  position: relative;
  width: 128px; height: 128px; border-radius: 50%;
  background: conic-gradient(#2a2f3a 0deg 360deg);
  flex-shrink: 0;
}
.donut-hole {
  position: absolute; inset: 17px;
  border-radius: 50%;
  background: var(--panel);
  display: grid; place-content: center; text-align: center;
}
.donut-hole strong { font-size: 24px; }
.donut-hole small { font-size: 8.5px; letter-spacing: 0.18em; color: var(--dim); }
.legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; flex: 1; }
.legend li { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.legend b { margin-left: auto; color: var(--text); font-variant-numeric: tabular-nums; }

/* active scraper */
.active-panel {
  background: linear-gradient(160deg, rgba(226, 38, 44, 0.16), rgba(17, 20, 26, 0.98) 55%);
  border-color: rgba(226, 38, 44, 0.4);
}
.live-tag {
  font-size: 9.5px; letter-spacing: 0.16em; color: var(--red);
  border: 1px solid rgba(226, 38, 44, 0.45);
  border-radius: 999px; padding: 4px 9px;
}
#activeHost { font-size: 17px; line-height: 1.35; margin: 0 0 6px; word-break: break-word; }
.huge { margin: 0 0 10px; font-size: 40px; font-weight: 700; letter-spacing: -0.03em; }
.bar-caption { margin: 9px 0 15px; font-size: 11.5px; color: var(--muted); }
.metric-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 16px; }
.metric {
  background: rgba(9, 11, 15, 0.65);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  text-align: center;
}
.metric span { font-size: 12px; color: var(--orange); }
.metric b { display: block; font-size: 15px; margin: 3px 0 1px; }
.metric small { font-size: 9.5px; color: var(--dim); }
.current-item { margin: 0 0 4px; font-size: 12.5px; word-break: break-all; }
.current-sub { margin: 0; font-size: 11px; color: var(--dim); }
.active-actions { display: flex; gap: 9px; margin-top: 15px; }

.ghost-btn {
  padding: 10px 14px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  font: 500 12px/1 'Inter', sans-serif;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: 0.16s ease;
}
.ghost-btn:hover:not(:disabled) { border-color: rgba(226, 38, 44, 0.5); color: #fff; }
.ghost-btn:disabled { opacity: 0.45; cursor: not-allowed; }

/* velocity + feed */
#velocityChart { width: 100%; height: 190px; display: block; }
.mini-select {
  background: var(--panel-2);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 9px;
  padding: 6px 9px;
  font-size: 11px;
}
.feed { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; max-height: 260px; overflow-y: auto; }
.feed li { display: flex; align-items: flex-start; gap: 10px; font-size: 12.5px; }
.feed li.empty { color: var(--dim); }
.feed .ficon {
  width: 26px; height: 26px; border-radius: 8px;
  display: grid; place-items: center;
  font-size: 11px;
  background: #1b2029; color: var(--muted);
  flex-shrink: 0;
}
.feed .ficon.red { background: var(--red-soft); color: var(--red); }
.feed .ficon.green { background: rgba(34, 197, 94, 0.15); color: var(--green); }
.feed .ficon.amber { background: rgba(245, 158, 11, 0.15); color: var(--amber); }
.feed .ftext { flex: 1; min-width: 0; }
.feed .ftext p { margin: 0; overflow-wrap: anywhere; }
.feed .fago { color: var(--dim); font-size: 10.5px; white-space: nowrap; }

/* strip */
.strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.strip-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 15px;
  display: flex; align-items: center; gap: 12px;
}
.strip-item b { font-size: 20px; }
.strip-item small { display: block; font-size: 9.5px; letter-spacing: 0.13em; color: var(--dim); }
.strip-item small i { display: block; font-style: normal; letter-spacing: 0; font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.strip-item.highlight { border-color: rgba(226, 38, 44, 0.45); background: linear-gradient(140deg, rgba(226, 38, 44, 0.16), var(--panel)); }

/* fleet, jobs, sources, exports */
.fleet { display: flex; flex-direction: column; gap: 11px; }
.fleet-row {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2);
}
.fleet-row small { display: block; color: var(--dim); font-size: 11.5px; margin-top: 4px; }
.tag { font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 5px 10px; }
.tag.live { color: var(--red); border-color: rgba(226, 38, 44, 0.5); }

.job-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; margin: 0 0 16px; }
.job-grid dt { font-size: 9.5px; letter-spacing: 0.14em; color: var(--dim); }
.job-grid dd { margin: 5px 0 0; font-size: 13px; word-break: break-all; }
.job-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.log {
  margin: 0;
  background: #07080b;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  font: 12px/1.6 'JetBrains Mono', monospace;
  color: #b6bdc9;
  max-height: 420px;
  overflow: auto;
  white-space: pre-wrap;
}

.field { display: block; margin-bottom: 13px; }
.field > span, .field-label { display: block; font-size: 9.5px; letter-spacing: 0.15em; color: var(--dim); margin-bottom: 7px; }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 11px 12px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: #0a0c10;
  color: var(--text);
  font: 13px/1.4 'Inter', sans-serif;
  resize: vertical;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: rgba(226, 38, 44, 0.6); }
.source-category-field { max-width: 520px; margin-bottom: 18px; }
.alert-actions a.launch-btn { display: inline-flex; text-decoration: none; }
.hint { color: var(--dim); font-size: 11.5px; margin: 10px 0 0; }
.error { color: #ff8a80; font-size: 12px; margin: 10px 0 0; }

.access-row { display: flex; justify-content: space-between; gap: 12px; margin: 0 0 11px; font-size: 12.5px; }
.access-row span { color: var(--dim); letter-spacing: 0.12em; font-size: 10px; }
.access-row a { color: var(--red); text-decoration: none; word-break: break-all; }

.export-list { display: flex; flex-direction: column; gap: 10px; }
.export-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2);
  font-size: 12.5px;
}
.export-row small { display: block; color: var(--dim); margin-top: 3px; font-size: 11px; }

/* modal */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(4, 5, 8, 0.72);
  backdrop-filter: blur(5px);
  display: grid; place-items: center;
  padding: 20px;
  z-index: 50;
}
.modal {
  width: min(470px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  background: linear-gradient(165deg, #171b23, #0f1218);
  border: 1px solid #262c37;
  border-radius: 18px;
  padding: 21px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 17px; }
.modal-head h2 { font-size: 12.5px; letter-spacing: 0.14em; display: flex; align-items: center; gap: 8px; }
.close { background: none; border: none; color: var(--muted); font-size: 22px; cursor: pointer; line-height: 1; }
.radio-row { display: flex; gap: 16px; margin-bottom: 14px; flex-wrap: wrap; }
.radio { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--muted); cursor: pointer; }
.radio input { accent-color: var(--red); }
.radio input:checked + span { color: var(--text); }
.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.sitemap-tools { display: flex; gap: 9px; align-items: center; margin-bottom: 10px; }
.sitemap-tools input[type="file"] { flex: 1; min-width: 0; font-size: 11.5px; color: var(--muted); }
.sitemap-tools input[type="file"]::file-selector-button {
  margin-right: 9px;
  padding: 8px 11px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  font: 500 11.5px/1 'Inter', sans-serif;
  cursor: pointer;
}
#categorySearch { margin-bottom: 8px; }
#categorySelect optgroup { background: #0a0c10; color: var(--dim); font-size: 11px; letter-spacing: 0.1em; }
#categorySelect option { color: var(--text); }
.remote { margin-bottom: 12px; }
.remote summary { cursor: pointer; font-size: 11.5px; color: var(--red); list-style: none; }
.remote summary::-webkit-details-marker { display: none; }
.remote summary::before { content: "▸ "; }
.remote[open] summary::before { content: "▾ "; }
.remote textarea {
  width: 100%;
  margin: 9px 0;
  padding: 10px 12px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: #0a0c10;
  color: var(--text);
  font: 12.5px/1.4 'Inter', sans-serif;
  resize: vertical;
}
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 17px; }
.bolt { filter: drop-shadow(0 0 6px rgba(255, 107, 53, 0.7)); }

/* login */
.login-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.login-card {
  display: flex;
  flex-direction: column;
  width: min(380px, 100%);
  background: linear-gradient(165deg, #171b23, #0f1218);
  border: 1px solid #262c37;
  border-radius: 18px;
  padding: 32px 28px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
.login-top { text-align: center; margin-bottom: 24px; }
.login-mark { width: 52px; height: 52px; margin: 0 auto 16px; }
.login-mark svg { width: 30px; height: 30px; }
.login-card h1 { font-size: 20px; letter-spacing: 0.16em; }
.login-sub { margin: 6px 0 0; font-size: 9.5px; letter-spacing: 0.24em; color: var(--dim); }
.login-note { font-size: 12px; color: var(--muted); margin: 0 0 20px; line-height: 1.55; text-align: center; }
.login-error { margin: 0 0 14px; text-align: center; }
.login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  padding: 14px 18px;
  margin-top: 4px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--red), var(--orange));
  color: #fff;
  font: 700 12px/1 'Inter', sans-serif;
  letter-spacing: 0.12em;
  cursor: pointer;
  transition: 0.18s ease;
}
.login-btn:hover { box-shadow: 0 0 26px rgba(226, 38, 44, 0.4); }
.login-foot { margin: 20px 0 0; font-size: 10.5px; color: var(--dim); line-height: 1.6; text-align: center; }
.login-foot strong { color: var(--muted); font-weight: 600; }

/* alert popup */
.alert-modal {
  width: min(430px, 100%);
  background: linear-gradient(165deg, #1d1216, #0f1218);
  border: 1px solid rgba(226, 38, 44, 0.5);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  text-align: center;
}
.alert-icon {
  width: 52px; height: 52px; margin: 0 auto 15px;
  border-radius: 15px;
  display: grid; place-items: center;
  font-size: 24px;
  background: var(--red-soft); color: var(--red);
}
.alert-modal h2 { font-size: 16px; letter-spacing: 0.04em; margin-bottom: 9px; }
.alert-modal p { margin: 0 0 8px; font-size: 13px; color: var(--muted); line-height: 1.6; }
.alert-detail { font-family: 'JetBrains Mono', monospace; font-size: 11.5px; color: var(--dim); word-break: break-word; }
.alert-actions { display: flex; gap: 10px; justify-content: center; margin-top: 20px; }

.logout-btn {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  border-radius: 11px;
  padding: 9px 12px;
  font: 500 11.5px/1 'Inter', sans-serif;
  cursor: pointer;
}
.logout-btn:hover { color: var(--text); border-color: rgba(226, 38, 44, 0.5); }

.toast {
  position: fixed; right: 20px; bottom: 20px;
  background: var(--panel);
  border: 1px solid rgba(226, 38, 44, 0.45);
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 12.5px;
  z-index: 60;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5);
}

@media (max-width: 1360px) {
  .stat-row { grid-template-columns: repeat(3, 1fr); }
  .board { grid-template-columns: 1fr 1fr; }
  .active-panel { grid-column: span 2; }
  .strip { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar {
    position: static; height: auto;
    flex-direction: row; flex-wrap: wrap; align-items: center;
    gap: 12px;
  }
  .nav { flex-direction: row; flex-wrap: wrap; flex: 1; }
  .launch-btn { width: auto; }
  .system-card, .sidebar-foot { display: none; }
  .board, .board-2 { grid-template-columns: 1fr; }
  .active-panel { grid-column: auto; }
}

@media (max-width: 720px) {
  .main { padding: 16px; }
  .stat-row, .strip { grid-template-columns: 1fr 1fr; }
  .job-grid { grid-template-columns: 1fr 1fr; }
  .user-chip div, .topbar p { display: none; }
  .queue { flex-direction: column; }
}
