/* ── Reset ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; color: #1e293b; background: #f1f5f9; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }

/* ── Tokens ──────────────────────────────────────────────────────────────── */
:root {
  --primary:       #6366f1;
  --primary-dark:  #4f46e5;
  --primary-light: #eef2ff;
  --success:       #10b981;
  --danger:        #ef4444;
  --warning:       #f59e0b;
  --sidebar-bg:    #0f172a;
  --sidebar-hover: #1e293b;
  --text:          #1e293b;
  --muted:         #64748b;
  --border:        #e2e8f0;
  --bg:            #f1f5f9;
  --card:          #ffffff;
  --radius:        8px;
  --shadow:        0 1px 3px rgba(0,0,0,.10), 0 1px 2px rgba(0,0,0,.06);
  --shadow-lg:     0 10px 15px rgba(0,0,0,.08), 0 4px 6px rgba(0,0,0,.05);
}

/* ════════════════════════════════════════════════════════════════════════════
   LOGIN PAGE
════════════════════════════════════════════════════════════════════════════ */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
}

.login-card {
  background: var(--card);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 400px;
  padding: 40px;
}

.login-brand {
  text-align: center;
  margin-bottom: 32px;
}

.brand-logo {
  width: 56px;
  height: 56px;
  background: var(--primary);
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(99,102,241,.4);
}

.brand-logo-img {
  width: 180px;
  height: auto;
  margin-bottom: 10px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.login-brand h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
}

.login-brand p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}

/* ════════════════════════════════════════════════════════════════════════════
   FORM ELEMENTS
════════════════════════════════════════════════════════════════════════════ */
.form-group { margin-bottom: 18px; }

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
  font-size: 14px;
  transition: border-color .15s, box-shadow .15s;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
}

.input-wrap {
  position: relative;
}

.input-wrap input { padding-right: 40px; }

.toggle-pw {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  font-size: 16px;
  line-height: 1;
  padding: 2px;
}

.toggle-pw:hover { color: var(--text); }

/* ════════════════════════════════════════════════════════════════════════════
   BUTTONS
════════════════════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: var(--radius);
  border: 1.5px solid transparent;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, box-shadow .15s, opacity .15s;
  white-space: nowrap;
}

.btn:disabled { opacity: .55; cursor: not-allowed; }

.btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.btn-primary:hover:not(:disabled) { background: var(--primary-dark); border-color: var(--primary-dark); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover:not(:disabled) { background: var(--primary-light); }

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

.btn-danger {
  background: #fef2f2;
  color: var(--danger);
  border-color: #fecaca;
}
.btn-danger:hover:not(:disabled) { background: #fee2e2; }

.btn-success {
  background: var(--success);
  color: #fff;
  border-color: var(--success);
}

.btn-block { width: 100%; justify-content: center; padding: 11px; font-size: 15px; }

.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-icon { padding: 6px; min-width: 32px; justify-content: center; }

/* ════════════════════════════════════════════════════════════════════════════
   ALERT / TOAST
════════════════════════════════════════════════════════════════════════════ */
.alert {
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 16px;
  display: none;
}
.alert.show { display: flex; align-items: center; gap: 8px; }
.alert-error   { background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }
.alert-success { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
.alert-info    { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }

/* ════════════════════════════════════════════════════════════════════════════
   APP LAYOUT
════════════════════════════════════════════════════════════════════════════ */
.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ── Sidebar ─────────────────────────────────────────────────────────────── */
.sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 16px 18px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}

.sidebar-logo {
  width: 34px; height: 34px;
  background: var(--primary);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.sidebar-brand-text { flex: 1; min-width: 0; }
.sidebar-brand-text strong { display: block; color: #f1f5f9; font-size: 14px; }
.sidebar-brand-text span   { display: block; color: #64748b; font-size: 11px; }

.sidebar-nav {
  flex: 1;
  padding: 12px 8px;
}

.nav-section-title {
  font-size: 10px;
  font-weight: 700;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 12px 8px 6px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 7px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, color .15s;
  margin-bottom: 2px;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

.nav-item:hover { background: var(--sidebar-hover); color: #f1f5f9; }
.nav-item.active { background: rgba(99,102,241,.2); color: #a5b4fc; }

.nav-icon { font-size: 15px; width: 18px; text-align: center; }

.sidebar-footer {
  padding: 12px 8px;
  border-top: 1px solid rgba(255,255,255,.07);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 7px;
  background: rgba(255,255,255,.05);
}

.user-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

.user-info { flex: 1; min-width: 0; }
.user-info strong { display: block; color: #e2e8f0; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-info span   { display: block; color: #64748b; font-size: 11px; }

.btn-logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: none;
  color: #64748b;
  cursor: pointer;
  transition: color .15s, background .15s;
}
.btn-logout:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}
.btn-logout:focus-visible {
  outline: 2px solid #ef4444;
  outline-offset: 2px;
}

/* ── Main content ────────────────────────────────────────────────────────── */
.main-wrap {
  flex: 1;
  margin-left: 220px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  background: var(--card);
  border-bottom: 1px solid var(--border);
  padding: 0 28px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.topbar-subtitle {
  font-size: 12px;
  color: var(--muted);
  margin-top: 1px;
}

.content         { padding: 28px; flex: 1; }
.content.no-pad  { padding: 0; display: flex; flex-direction: column; overflow: hidden; }

/* ════════════════════════════════════════════════════════════════════════════
   CARDS
════════════════════════════════════════════════════════════════════════════ */
.card {
  background: var(--card);
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.card-subtitle {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.card-body { padding: 24px; }

/* ════════════════════════════════════════════════════════════════════════════
   TABS
════════════════════════════════════════════════════════════════════════════ */
.tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--border);
  margin-bottom: 24px;
}

.tab-btn {
  padding: 10px 20px;
  border: none;
  background: none;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color .15s;
  display: flex;
  align-items: center;
  gap: 7px;
}

.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ════════════════════════════════════════════════════════════════════════════
   TABLE
════════════════════════════════════════════════════════════════════════════ */
.table-wrap { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

thead th {
  text-align: left;
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
}

tbody tr { border-bottom: 1px solid var(--border); }
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: #f8fafc; }

tbody td {
  padding: 12px 16px;
  color: var(--text);
  vertical-align: middle;
}

.table-actions { display: flex; gap: 6px; justify-content: flex-end; }

.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--muted);
}

.empty-state .empty-icon { font-size: 36px; margin-bottom: 12px; }
.empty-state p { font-size: 14px; font-weight: 500; margin-bottom: 4px; color: var(--text); }
.empty-state span { font-size: 13px; }

/* ════════════════════════════════════════════════════════════════════════════
   BADGES
════════════════════════════════════════════════════════════════════════════ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}

.badge-admin   { background: #ede9fe; color: #6d28d9; }
.badge-viewer  { background: #f0fdf4; color: #15803d; }
.badge-dev     { background: #fef3c7; color: #92400e; }
.badge-prod    { background: #dcfce7; color: #15803d; }
.badge-default { background: #e0f2fe; color: #0369a1; }

/* ════════════════════════════════════════════════════════════════════════════
   ENV SELECTOR
════════════════════════════════════════════════════════════════════════════ */
.env-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  max-width: 560px;
}

.env-card {
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s, background .2s;
  background: var(--card);
  position: relative;
  text-align: center;
}

.env-card:hover { border-color: var(--primary); background: var(--primary-light); }

.env-card.selected {
  border-color: var(--primary);
  background: var(--primary-light);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
}

.env-card .env-check {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px; height: 20px;
  background: var(--primary);
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 11px;
}

.env-card.selected .env-check { display: flex; }

.env-icon  { margin-bottom: 12px; color: var(--primary); display: flex; align-items: center; justify-content: center; }
.env-label { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.env-url   { font-size: 11px; color: var(--muted); font-family: monospace; }

.env-status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding: 12px 16px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  max-width: 560px;
}

.env-status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--success);
  flex-shrink: 0;
}

.env-status p  { font-size: 13px; font-weight: 600; color: #15803d; }
.env-status span { font-size: 12px; color: #166534; font-family: monospace; }

/* ════════════════════════════════════════════════════════════════════════════
   PASSWORD REVEAL
════════════════════════════════════════════════════════════════════════════ */
.pw-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: monospace;
  font-size: 15px;
  letter-spacing: .04em;
  color: var(--muted);
}

.pw-cell .btn-reveal {
  font-size: 14px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  padding: 2px 4px;
  border-radius: 4px;
}

.pw-cell .btn-reveal:hover { color: var(--primary); background: var(--primary-light); }

/* ════════════════════════════════════════════════════════════════════════════
   MODAL
════════════════════════════════════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--card);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 440px;
  transform: translateY(-12px);
  transition: transform .2s;
}

.modal-overlay.open .modal { transform: translateY(0); }

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 { font-size: 16px; font-weight: 700; }

.modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
  padding: 2px 6px;
  border-radius: 4px;
}
.modal-close:hover { background: var(--bg); color: var(--text); }

.modal-body   { padding: 20px 24px; }
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 24px 20px;
  border-top: 1px solid var(--border);
}

/* ════════════════════════════════════════════════════════════════════════════
   STATS ROW (dashboard)
════════════════════════════════════════════════════════════════════════════ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: var(--shadow);
}

.stat-label { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.stat-value { font-size: 28px; font-weight: 800; color: var(--text); margin: 4px 0; }
.stat-sub   { font-size: 12px; color: var(--muted); }

.dash-charts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.dash-chart-card { margin-bottom: 0; }
.dash-chart-body { padding-top: 0; }
.dash-line-chart {
  width: 100%;
  min-height: 180px;
}
.dash-chart-svg {
  width: 100%;
  height: auto;
  display: block;
}
.dash-chart-grid {
  stroke: var(--border);
  stroke-width: 1;
}
.dash-chart-axis {
  fill: var(--muted);
  font-size: 10px;
}
.dash-chart-missing {
  fill: var(--muted);
  font-size: 9px;
}
.dash-chart-empty {
  padding: 48px 16px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

/* ════════════════════════════════════════════════════════════════════════════
   SPINNER
════════════════════════════════════════════════════════════════════════════ */
.spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .6s linear infinite;
  display: inline-block;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ════════════════════════════════════════════════════════════════════════════
   TOAST NOTIFICATION
════════════════════════════════════════════════════════════════════════════ */
#toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 12px 18px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  z-index: 2000;
  transform: translateY(60px);
  opacity: 0;
  transition: transform .25s, opacity .25s;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 320px;
}

#toast.show {
  transform: translateY(0);
  opacity: 1;
}

#toast.toast-success { background: #0f172a; color: #d1fae5; }
#toast.toast-error   { background: #0f172a; color: #fecaca; }
#toast.toast-info    { background: #0f172a; color: #bfdbfe; }


/* ════════════════════════════════════════════════════════════════════════════
   LIVE TEST RUNNER  (light theme)
════════════════════════════════════════════════════════════════════════════ */

/* Suite select */
.lt-runner-header {
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}
.lt-runner-intro {
  flex: 1;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}
.lt-runner-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}
.lt-runner-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 180px;
}
.lt-runner-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.2;
  min-height: 13px;
}
.lt-bulk-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.lt-bulk-actions[hidden] {
  display: none !important;
}
.lt-runner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-end;
}
.lt-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 108px;
  width: 108px;
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.lt-suite-select {
  background: #fff;
  color: var(--text);
  border: 1.5px solid var(--border);
  border-radius: 6px;
  padding: 7px 12px;
  font-size: 13px;
  cursor: pointer;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  box-sizing: border-box;
}
.lt-runner-controls .lt-suite-select,
.lt-runner-controls > .btn,
.lt-runner-controls .lt-bulk-actions .btn {
  height: 36px;
  min-height: 36px;
  padding-top: 0;
  padding-bottom: 0;
  line-height: 1.2;
}
.lt-runner-controls > .btn,
.lt-runner-controls .lt-bulk-actions .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 14px;
  padding-right: 14px;
}
.lt-runner-controls .lt-bulk-actions .btn-sm {
  padding-left: 12px;
  padding-right: 12px;
  font-size: 12px;
}
.lt-suite-select:hover,
.lt-suite-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.12);
}

/* ── Instance bar ────────────────────────────────────────────────────────── */
.lt-instance-bar {
  display: flex;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  min-height: 44px;
  align-items: stretch;
}
.lt-instance-bar:empty::after {
  content: 'No test instances — choose a scenario and click ▶ Start';
  color: var(--muted);
  font-size: 12px;
  padding: 12px 20px;
  align-self: center;
}
.lt-inst-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  cursor: pointer;
  border-right: 1px solid var(--border);
  white-space: nowrap;
  transition: background .12s;
  position: relative;
  min-width: 0;
  flex-shrink: 0;
}
.lt-inst-tab:hover  { background: var(--primary-light); }
.lt-inst-tab.active {
  background: var(--primary-light);
  border-bottom: 2px solid var(--primary);
  margin-bottom: -1px;
}
.lt-inst-tab.lt-inst-tab-running:not(.active) {
  background: #f8fbff;
}
.lt-inst-tab.lt-inst-tab-running.active {
  background: #eff6ff;
}
.lt-inst-suite {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  max-width: 90px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lt-inst-env {
  font-size: 10px;
  padding: 2px 6px;
  line-height: 1.2;
  flex-shrink: 0;
}
.lt-inst-badge {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 600;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
}
.lt-ib-running { background: #dbeafe; color: #1d4ed8; }
.lt-ib-paused  { background: #fef9c3; color: #854d0e; }
.lt-ib-pass    { background: #dcfce7; color: #15803d; }
.lt-ib-warn    { background: #ffedd5; color: #c2410c; }
.lt-ib-fail    { background: #fee2e2; color: #b91c1c; }
.lt-ib-idle    { background: #f1f5f9; color: #64748b; }

.lt-inst-actions { display: flex; gap: 4px; margin-left: 4px; }

.lt-ia-btn {
  width: 22px; height: 22px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .12s;
  flex-shrink: 0;
}
.lt-ia-btn:disabled { opacity: .4; cursor: not-allowed; }
.lt-ia-pause { background: #fef9c3; color: #854d0e; }
.lt-ia-pause:hover:not(:disabled) { background: #f59e0b; color: #fff; }
.lt-ia-pause.is-paused { background: #dbeafe; color: #1d4ed8; }
.lt-ia-pause.is-paused:hover:not(:disabled) { background: #3b82f6; color: #fff; }
.lt-ia-stop  { background: #fee2e2; color: #b91c1c; }
.lt-ia-stop:hover:not(:disabled)   { background: #ef4444; color: #fff; }
.lt-ia-remove { background: #f1f5f9; color: #64748b; }
.lt-ia-remove:hover:not(:disabled) { background: #e2e8f0; color: var(--text); }

/* ── Progress bar ────────────────────────────────────────────────────────── */
.lt-progress-wrap { height: 3px; background: var(--border); }
.lt-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--success));
  transition: width .4s ease;
}

/* ── Detail header ───────────────────────────────────────────────────────── */
.lt-detail-header {
  padding: 10px 20px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  min-height: 44px;
}
.lt-detail-header.lt-empty { color: var(--muted); font-size: 13px; }

.lt-status-badge {
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 99px;
  font-weight: 600;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
}
.lt-s-running   { background: #dbeafe; color: #1d4ed8; }
.lt-s-failed    { background: #fee2e2; color: #b91c1c; }
.lt-s-done-pass { background: #dcfce7; color: #15803d; }
.lt-s-done-warn { background: #ffedd5; color: #c2410c; }
.lt-s-done-fail { background: #fee2e2; color: #b91c1c; }
.lt-s-idle      { background: #f1f5f9; color: #64748b; }
.lt-s-paused    { background: #fef9c3; color: #854d0e; }

.lt-failure-banner {
  margin: 0 20px 12px;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #991b1b;
  font-size: 13px;
  line-height: 1.45;
}
.lt-failure-banner strong { display: block; margin-bottom: 4px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }
.lt-failure-reason { margin: 0; white-space: pre-wrap; word-break: break-word; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }

/* ── Shared status-dot mixin ─────────────────────────────────────────────────
   All status badges get a 7×7 colored dot before their text label.
   Color map (consistent across all badge families):
     pass/completed  → #16a34a (green)
     fail/incomplete → #dc2626 (red)
     stop/paused     → #d97706 (amber)
     running         → #2563eb (blue)
     idle/pending    → #94a3b8 (slate)
────────────────────────────────────────────────────────────────────────── */
.lt-s-done-pass::before, .lt-s-done-warn::before, .lt-s-done-fail::before, .lt-s-failed::before, .lt-s-running::before,
.lt-s-paused::before, .lt-s-idle::before,
.lt-ib-pass::before, .lt-ib-warn::before, .lt-ib-fail::before,
.lt-ib-running::before, .lt-ib-paused::before, .lt-ib-idle::before,
.lt-hb-pass::before, .lt-hb-warn::before, .lt-hb-fail::before, .lt-hb-stop::before, .lt-hb-timeout::before {
  content: '';
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 5px;
  vertical-align: middle;
  flex-shrink: 0;
}
.lt-s-done-pass::before, .lt-ib-pass::before,  .lt-hb-pass::before  { background: #16a34a; }
.lt-s-done-warn::before, .lt-ib-warn::before,  .lt-hb-warn::before  { background: #ea580c; }
.lt-s-done-fail::before, .lt-s-failed::before, .lt-ib-fail::before,  .lt-hb-fail::before  { background: #dc2626; }
.lt-s-running::before,   .lt-ib-running::before {
  width: 10px;
  height: 10px;
  border: 2px solid #93c5fd;
  border-top-color: #1d4ed8;
  background: transparent;
  animation: lt-spin .75s linear infinite;
}
.lt-s-paused::before,    .lt-ib-paused::before, .lt-hb-stop::before { background: #d97706; }
.lt-s-timeout::before,   .lt-hb-timeout::before  { background: #be123c; }
.lt-s-idle::before,      .lt-ib-idle::before                        { background: #94a3b8; }

/* ── Counters ────────────────────────────────────────────────────────────── */
.lt-counters { display: flex; gap: 8px; flex-wrap: wrap; margin-left: 2px; }
.lt-counter {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5px 10px;
  border-radius: 8px;
  min-width: 46px;
}
.lt-num { font-size: 17px; font-weight: 800; line-height: 1; }
.lt-lbl { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; margin-top: 2px; opacity: .8; }

.lt-c-total { background: #f1f5f9; color: var(--text); }
.lt-c-pass  { background: #dcfce7; color: #15803d; }
.lt-c-fail  { background: #fee2e2; color: #b91c1c; }
.lt-c-skip  { background: #fef9c3; color: #854d0e; }
.lt-c-run   { background: #dbeafe; color: #1d4ed8; }
.lt-c-pend  { background: #f8fafc; color: #94a3b8; border: 1px solid var(--border); }

#lt-elapsed {
  margin-left: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  white-space: nowrap;
}
.lt-start-label    { font-size: 11px; color: var(--muted); }
.lt-duration-label { font-size: 12px; font-weight: 600; color: var(--muted); }

/* ── Filter bar ──────────────────────────────────────────────────────────── */
.lt-filter-bar {
  padding: 7px 16px;
  display: flex;
  gap: 7px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.lt-filter-btn {
  padding: 3px 11px;
  border-radius: 99px;
  font-size: 12px;
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: all .15s;
}
.lt-filter-btn.active              { background: var(--primary); color: #fff; border-color: var(--primary); }
.lt-filter-btn:hover:not(.active)  { background: var(--bg); color: var(--text); border-color: #cbd5e1; }

/* ── Empty message ───────────────────────────────────────────────────────── */
.lt-empty-msg { color: var(--muted); font-size: 13px; }

/* ── Test list loading (Playwright bootstrap) ────────────────────────────── */
.lt-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 48px 24px;
  min-height: 160px;
}
.lt-loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e2e8f0;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: lt-spin .75s linear infinite;
}
.lt-loading-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.lt-loading-sub {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}
@keyframes lt-spin {
  to { transform: rotate(360deg); }
}

/* ── Test list & rows ────────────────────────────────────────────────────── */
#lt-test-list {
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--card);
  min-height: 80px;
}

.lt-test-row { border-radius: 8px; overflow: hidden; border: 1px solid transparent; }
.lt-test-row.passed   { border-color: #86efac; }
.lt-test-row.failed   { border-color: #fca5a5; }
.lt-test-row.skipped  { border-color: #fde68a; }
.lt-test-row.timedOut { border-color: #fca5a5; }
.lt-test-row.running  { border-color: #93c5fd; }
.lt-test-row.pending  { border-color: var(--border); opacity: .6; }

.lt-test-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 13px;
  font-size: 13px;
  cursor: pointer;
  user-select: none;
  transition: filter .12s;
}
.lt-test-item:hover { filter: brightness(.97); }

.lt-test-row.passed   .lt-test-item { background: #f0fdf4; }
.lt-test-row.failed   .lt-test-item { background: #fef2f2; }
.lt-test-row.skipped  .lt-test-item { background: #fffbeb; }
.lt-test-row.timedOut .lt-test-item { background: #fef2f2; }
.lt-test-row.running  .lt-test-item { background: #eff6ff; animation: lt-pulse 1.5s ease-in-out infinite; }
.lt-test-row.pending  .lt-test-item { background: #f8fafc; }

@keyframes lt-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .65; } }

.lt-icon       { flex-shrink: 0; display: flex; align-items: center; justify-content: center; line-height: 1; }
.lt-test-info  { flex: 1; min-width: 0; }
.lt-test-title { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.lt-test-suite { font-size: 11px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lt-test-meta  { display: flex; align-items: center; gap: 6px; margin-top: 3px; flex-wrap: wrap; }
.lt-test-dur   { font-size: 11px; color: var(--muted); }

.lt-retry-badge { font-size: 10px; background: #fef9c3; color: #854d0e; padding: 1px 6px; border-radius: 4px; }
.lt-has-shot    { font-size: 10px; color: #1d4ed8; padding: 1px 5px; border-radius: 4px; background: #dbeafe; }
.lt-has-log     { font-size: 10px; color: #7c3aed; padding: 1px 5px; border-radius: 4px; background: #ede9fe; }

.lt-expand-arrow {
  font-size: 10px;
  color: var(--muted);
  flex-shrink: 0;
  margin-top: 3px;
  transition: transform .2s;
}
.lt-test-row.expanded .lt-expand-arrow { transform: rotate(180deg); }

.lt-test-detail { display: none; padding: 10px 13px; border-top: 1px solid rgba(0,0,0,.06); }
.lt-test-row.passed   .lt-test-detail { background: #f0fdf4; }
.lt-test-row.failed   .lt-test-detail { background: #fef2f2; }
.lt-test-row.skipped  .lt-test-detail { background: #fffbeb; }
.lt-test-row.timedOut .lt-test-detail { background: #fef2f2; }
.lt-test-row.running  .lt-test-detail { background: #eff6ff; }
.lt-test-row.pending  .lt-test-detail { background: #f8fafc; }
.lt-test-detail.open  { display: block; }

.lt-detail-section            { margin-bottom: 12px; }
.lt-detail-section:last-child { margin-bottom: 0; }
.lt-detail-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  margin-bottom: 6px;
}
.lt-full-error {
  font-size: 12px;
  color: #b91c1c;
  background: #fef2f2;
  border: 1px solid #fecaca;
  padding: 9px 11px;
  border-radius: 6px;
  white-space: pre-wrap;
  word-break: break-all;
  max-height: 180px;
  overflow-y: auto;
  line-height: 1.5;
}
.lt-stdout-log {
  font-size: 12px;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 9px 11px;
  border-radius: 6px;
  white-space: pre-wrap;
  word-break: break-all;
  max-height: 160px;
  overflow-y: auto;
  line-height: 1.5;
  font-family: monospace;
}

/* Screenshots */
.lt-screenshots { display: flex; flex-wrap: wrap; gap: 8px; }
.lt-thumb-wrap {
  position: relative;
  cursor: pointer;
  border-radius: 6px;
  overflow: hidden;
  border: 2px solid var(--border);
  transition: border-color .15s;
}
.lt-thumb-wrap:hover { border-color: var(--primary); }
.lt-thumb-wrap img { display: block; height: 110px; width: auto; max-width: 200px; object-fit: cover; }
.lt-thumb-wrap img.lt-img-loading { opacity: 0.45; }
.lt-thumb-wrap img.lt-img-failed { opacity: 0.3; outline: 2px dashed #fca5a5; }
.lt-thumb-label {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: rgba(0,0,0,.55);
  font-size: 10px;
  padding: 2px 5px;
  color: #fff;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Lightbox (keep dark — image viewer) ─────────────────────────────────── */
#lt-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.92);
  z-index: 1100;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
}
#lt-lightbox.open { display: flex; }
#lt-lightbox img  { max-width: 92vw; max-height: 85vh; border-radius: 8px; box-shadow: 0 0 40px rgba(0,0,0,.8); }
#lt-lightbox img[hidden] { display: none; }
.lt-lightbox-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(255,255,255,.25);
  border-top-color: #fff;
  border-radius: 50%;
  animation: lt-spin .75s linear infinite;
}
.lt-lightbox-error {
  max-width: 420px;
  margin: 0;
  padding: 12px 16px;
  border-radius: 8px;
  background: rgba(239,68,68,.15);
  color: #fecaca;
  font-size: 13px;
  text-align: center;
}
#lt-lightbox-close {
  position: absolute;
  top: 14px; right: 18px;
  font-size: 24px; color: #fff;
  cursor: pointer; background: none; border: none; line-height: 1;
}
#lt-lightbox-close:hover { opacity: .7; }
#lt-lightbox-label { font-size: 12px; color: #a0aec0; }

/* Environment indicator on Live Tests / History */
.view-env-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
}
.view-env-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}
.view-env-url {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  color: var(--text);
}

/* ── History view ────────────────────────────────────────────────────────── */
.lt-history-view {
  flex: 1;
  display: flex;
  overflow: hidden;
  min-height: 0;
}
#lt-history-runs {
  width: 320px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  overflow-y: auto;
  background: var(--bg);
}
#lt-history-detail {
  flex: 1;
  overflow-y: auto;
  background: var(--card);
}
.lt-history-placeholder {
  padding: 48px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.lt-hist-run {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .12s;
}
.lt-hist-run:hover  { background: var(--card); }
.lt-hist-run.active {
  background: var(--primary-light);
  border-left: 3px solid var(--primary);
  padding-left: 11px;
}

.lt-hist-run-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}
.lt-hist-run-title {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
}
.lt-hist-run-suite {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  text-transform: capitalize;
}
.lt-hist-run-title .badge {
  font-size: 10px;
  padding: 1px 6px;
}
.lt-hist-run-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.lt-hist-run-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 700;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.lt-hb-pass  { background: #dcfce7; color: #15803d; }
.lt-hb-warn  { background: #ffedd5; color: #c2410c; }
.lt-hb-fail  { background: #fee2e2; color: #b91c1c; }
.lt-hb-stop  { background: #fef9c3; color: #854d0e; font-weight: 600; }
.lt-hb-timeout { background: #fff1f2; color: #be123c; font-weight: 600; }
.lt-s-timeout { background: #fff1f2; color: #be123c; }

.lt-hist-run-meta {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
  line-height: 1.4;
}
.lt-hist-run-meta-sep {
  margin: 0 4px;
  opacity: .5;
}

.lt-hist-run-stats {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.lt-hist-stat {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--card);
  border: 1px solid var(--border);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.lt-hist-stat strong {
  font-weight: 700;
  margin-right: 2px;
}
.lt-hist-stat-pass strong { color: #16a34a; }
.lt-hist-stat-fail strong { color: #dc2626; }
.lt-hist-stat-skip strong { color: #d97706; }
.lt-hist-stat-total {
  margin-left: auto;
  border: none;
  background: transparent;
  padding: 2px 0;
  font-size: 10px;
}

/* Legacy count pills (dashboard table) */
.lt-hist-run-env {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.lt-hist-run-env .view-env-url { font-size: 10px; }
.lt-hist-run-counts { display: flex; gap: 8px; font-size: 11px; flex-wrap: wrap; }
.lt-hc       { padding: 1px 6px; border-radius: 4px; display: inline-flex; align-items: center; }
.lt-hc-pass  { background: #dcfce7; color: #15803d; }
.lt-hc-fail  { background: #fee2e2; color: #b91c1c; }
.lt-hc-skip  { background: #fef9c3; color: #854d0e; }
.lt-hc-total { background: #f1f5f9; color: #64748b; }
.lt-hc-pass::before, .lt-hc-fail::before, .lt-hc-skip::before {
  content: '';
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  margin-right: 4px;
  flex-shrink: 0;
}
.lt-hc-pass::before { background: #16a34a; }
.lt-hc-fail::before { background: #dc2626; }
.lt-hc-skip::before { background: #d97706; }

/* History header + per-run delete */
.lt-hist-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  color: var(--muted);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 1;
}
.lt-hist-delete {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  font-size: 16px;
  line-height: 1;
  padding: 0 2px;
  border-radius: 3px;
  opacity: 0;
  transition: opacity .15s, color .15s;
  flex-shrink: 0;
}
.lt-hist-run:hover .lt-hist-delete,
.lt-hist-run.active .lt-hist-delete { opacity: 1; }
.lt-hist-delete:hover { color: #ef4444; }

/* ════════════════════════════════════════════════════════════════════════════
   TEST SCENARIOS
════════════════════════════════════════════════════════════════════════════ */
.scenarios-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.scenarios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
}
.scenarios-file {
  border-top: 1px solid var(--border);
  padding: 12px 24px;
}
.scenarios-file:first-child { border-top: none; }
.scenarios-file-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
  font-family: monospace;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.scenarios-tests      { display: flex; flex-direction: column; gap: 2px; }

/* Base row */
.scenario-test-row {
  display: flex;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12.5px;
  align-items: center;
  cursor: pointer;
  transition: background .12s;
}
.scenario-test-row:hover { background: var(--bg); }
.scenario-test-row:hover .scenario-test-chevron { opacity: 1; }

/* Number column */
.scenario-test-num { color: var(--muted); font-size: 11px; flex-shrink: 0; font-family: monospace; min-width: 18px; }

/* Name */
.scenario-test-name { color: var(--text); line-height: 1.4; flex: 1; min-width: 0; }

/* Chevron hint */
.scenario-test-chevron { color: var(--muted); font-size: 15px; opacity: 0; flex-shrink: 0; transition: opacity .1s; margin-left: 4px; }

.scenario-priority {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid transparent;
}
.scenario-priority-high {
  background: #fef2f2;
  color: #b91c1c;
  border-color: #fecaca;
}
.scenario-priority-mid {
  background: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}
.scenario-priority-low {
  background: #f0fdf4;
  color: #15803d;
  border-color: #bbf7d0;
}
.scenario-priority-select {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 2px 22px 2px 7px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  appearance: none;
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 10px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath fill='%2364748b' d='M2 3.5 5 6.5 8 3.5'/%3E%3C/svg%3E");
}
.scenario-priority-select:disabled {
  opacity: .7;
  cursor: wait;
}
.scenario-priority-select-high {
  background-color: #fef2f2;
  color: #b91c1c;
  border-color: #fecaca;
}
.scenario-priority-select-mid {
  background-color: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}
.scenario-priority-select-low {
  background-color: #f0fdf4;
  color: #15803d;
  border-color: #bbf7d0;
}
.scd-priority .scenario-priority-select {
  font-size: 11px;
  padding: 3px 24px 3px 9px;
}
.scenario-priority-stat-high .stat-value { color: #b91c1c; }
.scenario-priority-stat-mid .stat-value { color: #b45309; }
.scenario-priority-stat-low .stat-value { color: #15803d; }

.lt-test-meta .scenario-priority,
.lt-hist-run-meta .scenario-priority {
  font-size: 9px;
  padding: 1px 6px;
}

/* ── Scenario Detail modal — criteria list ───────────────────────────────── */
.scd-criteria { display: flex; flex-direction: column; gap: 6px; }
.scd-criteria-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  padding: 7px 10px;
}
.scd-criteria-icon { color: #16a34a; font-size: 13px; flex-shrink: 0; margin-top: 1px; font-weight: 700; }
.scd-criteria-text {
  font-size: 13px;
  color: #166534;
  line-height: 1.5;
}

/* ── Scheduler ─────────────────────────────────────────────────────────────── */
.sched-next-run { font-variant-numeric: tabular-nums; color: #475569; font-size: 13px; }

/* Toggle switch */
.sched-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.sched-toggle input[type="checkbox"] { display: none; }
.sched-toggle-track {
  position: relative;
  width: 34px; height: 18px;
  background: #cbd5e1;
  border-radius: 9px;
  transition: background 0.2s;
  flex-shrink: 0;
}
.sched-toggle-track::after {
  content: '';
  position: absolute;
  top: 2px; left: 2px;
  width: 14px; height: 14px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,.15);
  transition: left 0.2s;
}
.sched-toggle input:checked + .sched-toggle-track { background: #16a34a; }
.sched-toggle input:checked + .sched-toggle-track::after { left: 18px; }
.sched-toggle-lbl { font-size: 12px; color: #64748b; }
