/* eIM Admin — Linear-inspired dark SaaS theme */
:root {
  --accent-rgb: 94, 106, 210;
  --accent2-rgb: 94, 106, 210;
  --neutral-950: #09090b;
  --neutral-900: #18181b;
  --neutral-850: #1c1c1f;
  --neutral-800: #27272a;
  --neutral-700: #3f3f46;
  --bg-deep: var(--neutral-950);
  --bg-panel: var(--neutral-900);
  --bg-card: var(--neutral-900);
  --surface-2: var(--neutral-850);
  --border: var(--neutral-800);
  --border-subtle: var(--neutral-800);
  --text: #fafafa;
  --text-muted: #a1a1aa;
  --muted: var(--text-muted);
  --accent: #5e6ad2;
  --accent-dim: rgba(var(--accent-rgb), 0.14);
  --accent-glow: rgba(var(--accent-rgb), 0.25);
  --danger: #f87171;
  --success: #4ade80;
  --warn: #fbbf24;
  --top-bar-bg: rgba(9, 9, 11, 0.92);
  --sidebar-bg: var(--neutral-950);
  --input-bg: var(--neutral-850);
  --btn-primary-start: var(--accent);
  --btn-primary-end: var(--accent);
  --btn-primary-fg: #ffffff;
  --radius: 8px;
  --radius-lg: 12px;
  --sidebar-w: 240px;
  --top-h: 52px;
  --font: "Inter", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.35);
  --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.45);
  --ring: 0 0 0 1px var(--neutral-800);
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }

body {
  font-family: var(--font);
  background: var(--bg-deep);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse 70% 45% at 50% -15%, rgba(var(--accent-rgb), 0.07), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

#app { position: relative; z-index: 1; min-height: 100%; }
.hidden { display: none !important; }

/* ——— Login ——— */
.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-card {
  width: min(420px, 100%);
  padding: 2rem;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--neutral-800);
  box-shadow: var(--ring), var(--shadow-xl);
}

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

.brand-logo-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: var(--radius);
  flex-shrink: 0;
}

.brand-logo-img.header-logo { width: 32px; height: 32px; }

.brand-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  border: 1px solid var(--neutral-800);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: var(--surface-2);
  color: var(--accent);
}

.login-card h1 {
  margin: 0;
  font-size: 1.375rem;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.login-card .tagline {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin: 0.25rem 0 1.5rem;
}

label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
}

input, select, textarea {
  font-family: var(--font);
  font-size: 0.875rem;
  color: var(--text);
  background: var(--input-bg);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius);
  padding: 0.5625rem 0.75rem;
  width: 100%;
  max-width: 100%;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}

input:hover, select:hover, textarea:hover {
  border-color: var(--neutral-700);
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

input:focus-visible, select:focus-visible, textarea:focus-visible,
button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--bg-deep), 0 0 0 4px rgba(var(--accent-rgb), 0.45);
}

textarea { font-family: var(--mono); font-size: 0.8125rem; line-height: 1.5; resize: vertical; }

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 520px) {
  .field-row { grid-template-columns: 1fr; }
}

.btn {
  font-family: var(--font);
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 0.5rem 0.875rem;
  min-height: 36px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease), transform 0.1s var(--ease), box-shadow 0.15s var(--ease);
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--accent);
  color: var(--btn-primary-fg);
  border-color: transparent;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  filter: brightness(1.08);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: var(--surface-2);
  color: var(--text);
  border-color: var(--neutral-800);
}

.btn-secondary:hover {
  background: var(--neutral-800);
  border-color: var(--neutral-700);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border-color: transparent;
}

.btn-ghost:hover { color: var(--text); background: var(--surface-2); }

.muted { color: var(--text-muted); font-size: 0.8125rem; }
code, .mono { font-family: var(--mono); font-size: 0.8em; }

/* ——— App shell ——— */
.app-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.top-bar {
  height: var(--top-h);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  border-bottom: 1px solid var(--neutral-800);
  background: var(--top-bar-bg);
  backdrop-filter: blur(12px);
}

.top-bar-left {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.top-bar-title {
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: -0.02em;
}

#brandHeaderAccent { color: var(--text-muted); font-weight: 500; }

.badge {
  font-family: var(--mono);
  font-size: 0.6875rem;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: var(--accent-dim);
  border: 1px solid rgba(var(--accent-rgb), 0.25);
  color: var(--accent);
}

.badge-role {
  background: var(--surface-2);
  border-color: var(--neutral-800);
  color: var(--text-muted);
}

.op-status {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  border: 1px solid transparent;
  text-transform: lowercase;
}
.op-status-created { color: var(--text-muted); background: var(--surface-2); border-color: var(--neutral-800); }
.op-status-staged { color: #fbbf24; background: rgba(251, 191, 36, 0.12); border-color: rgba(251, 191, 36, 0.25); }
.op-status-executing { color: #60a5fa; background: rgba(96, 165, 250, 0.12); border-color: rgba(96, 165, 250, 0.25); }
.op-status-executed { color: var(--success); background: rgba(74, 222, 128, 0.12); border-color: rgba(74, 222, 128, 0.25); }
.op-status-failed { color: var(--danger); background: rgba(248, 113, 113, 0.12); border-color: rgba(248, 113, 113, 0.25); }

.shell-body {
  display: flex;
  flex: 1;
  min-height: 0;
}

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  border-right: 1px solid var(--neutral-800);
  background: var(--sidebar-bg);
  padding: 0.75rem 0.625rem;
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.nav-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 0.75rem 0.625rem 0.375rem;
}

.nav-btn {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.625rem;
  min-height: 36px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font);
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), border-color 0.15s var(--ease);
}

.nav-btn:hover {
  background: var(--surface-2);
  color: var(--text);
}

.nav-btn.active {
  background: var(--accent-dim);
  border-color: rgba(var(--accent-rgb), 0.2);
  color: var(--text);
  box-shadow: inset 2px 0 0 var(--accent);
}

.nav-key {
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: none;
  flex-shrink: 0;
  color: inherit;
  opacity: 0.7;
}

.nav-key svg {
  width: 1rem;
  height: 1rem;
  display: block;
}

.nav-btn.active .nav-key {
  color: var(--accent);
  opacity: 1;
}

.content {
  flex: 1;
  overflow: auto;
  padding: 1.5rem 1.75rem 2.5rem;
  max-width: 1400px;
}

.view-panel { animation: fadeIn 0.2s var(--ease); }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.page-head { margin-bottom: 1.5rem; }

.page-head h2 {
  margin: 0 0 0.375rem;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.025em;
}

.page-head p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.875rem;
  max-width: 640px;
  line-height: 1.55;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.375rem;
  margin-bottom: 1rem;
  box-shadow: var(--ring);
  transition: box-shadow 0.2s var(--ease);
}

.card:hover {
  box-shadow: var(--ring), var(--shadow-sm);
}

.card h3 {
  margin: 0 0 0.875rem;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

@media (max-width: 960px) {
  .sidebar { display: none; }
  .mobile-nav {
    display: flex !important;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--neutral-800);
  }
  .grid-2 { grid-template-columns: 1fr; }
  .content { padding: 1rem 1rem 2rem; }
  .btn, .mobile-nav .nav-btn { min-height: 44px; }
}

@media (min-width: 961px) and (max-width: 1200px) {
  .content { padding: 1.25rem 1.25rem 2rem; }
}

.mobile-nav { display: none; }

.mobile-nav .nav-btn {
  width: auto;
  flex: 1 1 auto;
  min-width: calc(50% - 0.25rem);
  justify-content: center;
  box-shadow: none;
}

.mobile-nav .nav-btn.active {
  box-shadow: none;
  border-color: rgba(var(--accent-rgb), 0.3);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

th, td {
  border-bottom: 1px solid var(--neutral-800);
  padding: 0.625rem 0.75rem;
  text-align: left;
  word-break: break-word;
}

th {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  font-weight: 600;
  background: var(--surface-2);
}

tbody tr {
  transition: background 0.12s var(--ease);
}

tbody tr:hover { background: rgba(var(--accent-rgb), 0.04); }

.table-wrap {
  overflow-x: auto;
  margin-top: 0.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--neutral-800);
}

.table-wrap table { margin: 0; }
.table-wrap th:first-child, .table-wrap td:first-child { padding-left: 1rem; }
.table-wrap th:last-child, .table-wrap td:last-child { padding-right: 1rem; }

.ops-actions {
  min-width: 11rem;
  white-space: nowrap;
  display: flex;
  flex-wrap: nowrap;
  gap: 0.35rem;
  align-items: center;
}
.ops-actions .btn { white-space: nowrap; flex-shrink: 0; }
.ops-ts { white-space: nowrap; font-size: 0.75rem; color: var(--text-muted); }
.ops-id-cell { white-space: nowrap; }

.op-expand-btn {
  padding: 0.1rem 0.4rem;
  font-family: var(--mono);
  font-size: 0.85rem;
  margin-right: 0.35rem;
  min-width: 1.5rem;
  line-height: 1.2;
}

.op-log-row td { padding: 0.35rem 1rem 0.75rem; background: var(--surface-2); }
.op-log-panel {
  background: var(--neutral-950);
  color: #d4d4d8;
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.45;
  max-height: 320px;
  overflow: auto;
  padding: 0.75rem;
  margin: 0;
  border-radius: var(--radius);
  border: 1px solid var(--neutral-800);
  white-space: pre-wrap;
  word-break: break-word;
}
.op-log-panel.loading { color: var(--text-muted); font-style: italic; }
.op-log-panel.error { color: var(--danger); }

.panel-euicc {
  margin-top: 0.5rem;
  padding: 1rem;
  border-radius: var(--radius);
  background: var(--surface-2);
  border: 1px solid var(--neutral-800);
}

.panel-euicc ul { margin: 0.5rem 0 0 1.1rem; padding: 0; }
.stack-gap > * + * { margin-top: 0.875rem; }

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.75rem;
}

.login-foot {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--neutral-800);
}

/* Support assistant */
.support-chat-root {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 9999;
  font-family: var(--font);
  max-width: calc(100vw - 2rem);
}

.support-fab {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--neutral-800);
  background: var(--accent);
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--ring), var(--shadow-md);
  transition: transform 0.15s var(--ease), filter 0.15s var(--ease);
}

.support-fab:hover { filter: brightness(1.08); transform: scale(1.04); }

.support-panel {
  position: absolute;
  bottom: 56px;
  right: 0;
  width: min(380px, calc(100vw - 2.5rem));
  max-height: min(560px, 70vh);
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-lg);
  border: 1px solid var(--neutral-800);
  background: var(--bg-card);
  box-shadow: var(--ring), var(--shadow-xl);
  overflow: hidden;
}

.support-panel.hidden { display: none !important; }

.support-head {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--neutral-800);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  background: var(--surface-2);
}

.support-head strong { font-size: 0.875rem; font-weight: 600; }

.support-messages {
  flex: 1;
  overflow-y: auto;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 220px;
  max-height: 380px;
}

.support-msg {
  padding: 0.5625rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.8125rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.support-msg-user {
  align-self: flex-end;
  background: var(--accent-dim);
  border: 1px solid rgba(var(--accent-rgb), 0.25);
  max-width: 92%;
}

.support-msg-bot {
  align-self: flex-start;
  background: var(--surface-2);
  border: 1px solid var(--neutral-800);
  max-width: 100%;
}

.support-msg-sys {
  align-self: center;
  font-size: 0.72rem;
  color: var(--text-muted);
  background: transparent;
  border: none;
}

.support-foot {
  padding: 0.625rem;
  border-top: 1px solid var(--neutral-800);
  display: flex;
  gap: 0.5rem;
  background: var(--surface-2);
}

.support-foot input { flex: 1; margin: 0; }

#loginErr, #forgotErr, #resetErr, #forcePwErr { color: var(--danger); margin-top: 0.75rem; font-size: 0.875rem; }
#opErr, #userErr, #iccInventoryErr, #euiccsImportErr, #euiccConfigErr {
  color: var(--danger);
  margin-top: 0.5rem;
  font-size: 0.8125rem;
}

.login-links { margin-top: 0.5rem; }
.login-links button { font-size: 0.8125rem; }

.manual-md { max-height: min(70vh, 720px); overflow: auto; padding: 0.25rem 0.5rem; font-size: 0.875rem; line-height: 1.55; }
.manual-md h1, .manual-md h2, .manual-md h3 { margin: 1.1em 0 0.45em; font-weight: 600; letter-spacing: -0.02em; }
.manual-md h1 { font-size: 1.35rem; }
.manual-md h2 { font-size: 1.1rem; border-bottom: 1px solid var(--neutral-800); padding-bottom: 0.25rem; }
.manual-md code { font-family: var(--mono); font-size: 0.84em; background: var(--surface-2); padding: 0.1em 0.35em; border-radius: 4px; }
.manual-md pre { background: var(--neutral-950); border: 1px solid var(--neutral-800); border-radius: var(--radius); padding: 0.75rem; overflow: auto; }
.manual-md pre code { background: none; padding: 0; }
.manual-md .mermaid {
  margin: 1rem 0;
  padding: 0.75rem;
  overflow-x: auto;
  background: var(--surface-2);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius);
  text-align: center;
}
.manual-md .mermaid svg { max-width: 100%; height: auto; }
.manual-md table { border-collapse: collapse; width: 100%; font-size: 0.85rem; margin: 0.75rem 0; }
.manual-md th, .manual-md td { border: 1px solid var(--neutral-800); padding: 0.35rem 0.5rem; text-align: left; }

.manual-tabs {
  display: flex;
  gap: 0.375rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.manual-tab.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-dim);
}

#apiPasswordGate {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(9, 9, 11, 0.88);
  backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center; padding: 24px;
}
#apiPasswordGate .login-card { max-width: 420px; width: 100%; }

html.vendor-wl-locked #navWlBtn,
html.vendor-wl-locked #viewBranding {
  display: none !important;
}

/* KPI & charts */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius-lg);
  padding: 1rem 1.125rem;
  box-shadow: var(--ring);
  transition: box-shadow 0.15s var(--ease);
}

.kpi-card:hover { box-shadow: var(--ring), var(--shadow-sm); }

.kpi-value {
  font-size: 1.625rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
}

.kpi-label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-top: 0.375rem;
}

.kpi-sub {
  font-size: 0.6875rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.chart-card {
  background: var(--bg-card);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius-lg);
  padding: 1rem;
  min-height: 280px;
  box-shadow: var(--ring);
}

.chart-card h4 {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.qos-map {
  height: 360px;
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--neutral-800);
  background: var(--surface-2);
  z-index: 0;
}

.qos-map-wrap { min-width: 0; }
.qos-map-marker { background: transparent; border: none; }

.qos-reports-wrap {
  margin-top: 0;
  overflow-x: auto;
}

.qos-reports-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
}

.qos-reports-table th,
.qos-reports-table td {
  white-space: nowrap;
  vertical-align: middle;
  padding: 0.65rem 0.85rem;
}

.qos-reports-table th {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--neutral-800);
}

.qos-reports-table td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.qos-eid {
  font-family: var(--mono);
  font-size: 0.78rem;
  max-width: 14rem;
  overflow: hidden;
  text-overflow: ellipsis;
}

.qos-plmn-cell {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  white-space: normal;
  min-width: 7rem;
}

.qos-plmn-cell .qos-plmn {
  font-family: var(--mono);
  font-size: 0.85rem;
}

.qos-plmn-cell .qos-mno {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.qos-signal {
  font-family: var(--mono);
  font-size: 0.78rem;
  line-height: 1.35;
  white-space: normal;
  min-width: 11rem;
}

.qos-signal span {
  display: inline-block;
  margin-right: 0.65rem;
  color: var(--text-muted);
}

.qos-signal strong {
  color: var(--text);
  font-weight: 600;
}

.qos-score {
  font-family: var(--mono);
  font-weight: 600;
}

.qos-score-good { color: #3d9a6a; }
.qos-score-mid { color: #e6b84a; }
.qos-score-bad { color: #ff6b8a; }

.qos-survey {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  white-space: normal;
  min-width: 12rem;
  max-width: 22rem;
}

.qos-survey-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.55rem;
  font-size: 0.78rem;
  line-height: 1.3;
}

.qos-survey-row .qos-plmn {
  font-family: var(--mono);
  font-size: 0.8rem;
}

.qos-survey-row .qos-mno {
  color: var(--text-muted);
  font-size: 0.72rem;
}

.qos-badge {
  display: inline-block;
  font-size: 0.65rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  border: 1px solid var(--neutral-700);
  color: var(--text-muted);
}

.qos-badge-current {
  border-color: rgba(61, 154, 106, 0.55);
  color: #3d9a6a;
}

.qos-badge-available {
  border-color: rgba(230, 184, 74, 0.45);
  color: #e6b84a;
}

.qos-badge-forbidden {
  border-color: rgba(255, 107, 138, 0.45);
  color: #ff6b8a;
}

.qos-survey-rf {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

.qos-loc {
  font-size: 0.78rem;
  white-space: nowrap;
}

.leaflet-container { font-family: var(--font); background: var(--neutral-900); }
.leaflet-popup-content-wrapper {
  background: var(--bg-panel);
  color: var(--text);
  border: 1px solid var(--neutral-800);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}
.leaflet-popup-tip { background: var(--bg-panel); }

.chart-card canvas { max-height: 240px; }

.progress-bar {
  height: 4px;
  background: var(--neutral-800);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 0.25rem;
  min-width: 80px;
}

.progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 99px;
  transition: width 0.4s var(--ease);
}

.campaign-status {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--muted);
  border: 1px solid var(--neutral-800);
}

.campaign-status-succeeded, .campaign-status-completed, .campaign-status-executed {
  background: rgba(74, 222, 128, 0.1);
  border-color: rgba(74, 222, 128, 0.25);
  color: var(--success);
}

.campaign-status-failed {
  background: rgba(248, 113, 113, 0.1);
  border-color: rgba(248, 113, 113, 0.25);
  color: var(--danger);
}

.campaign-status-running, .campaign-status-staged, .campaign-status-created {
  background: var(--accent-dim);
  border-color: rgba(var(--accent-rgb), 0.25);
  color: var(--accent);
}

.campaign-status-pending, .campaign-status-draft {
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.25);
  color: var(--warn);
}

.preset-pills { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.preset-pills select { min-width: 140px; }

.campaign-detail-panel {
  margin-top: 1rem;
  border-top: 1px solid var(--neutral-800);
  padding-top: 1rem;
}

#reportCustomRange:not(.hidden) {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.hero-demo-banner {
  background: var(--accent-dim);
  border: 1px solid rgba(var(--accent-rgb), 0.25);
  border-radius: var(--radius-lg);
  padding: 1rem 1.25rem;
  margin-bottom: 1.25rem;
}

.hero-demo-banner h3 {
  margin: 0 0 0.35rem;
  font-size: 0.9375rem;
  font-weight: 600;
}

.hero-demo-banner p {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--muted);
  line-height: 1.5;
}
