/* ═══════════════════════════════════════════════
   Ω Engine — Mobile-First, Auto-Pilot UI
   ═══════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@300;400;500;600;700&display=swap');

:root {
  --bg-0: #06060b;
  --bg-1: #0c0c14;
  --bg-2: #12121e;
  --bg-3: #1a1a2a;
  --bg-4: #222236;
  --border: #1c1c30;
  --border-2: #2a2a42;

  --text-1: #ededed;
  --text-2: #9898b4;
  --text-3: #5c5c78;

  --accent: #7c6cf6;
  --accent-2: #9d8fff;
  --accent-dim: rgba(124, 108, 246, 0.12);
  --accent-glow: rgba(124, 108, 246, 0.3);

  --green: #00d68f;
  --green-dim: rgba(0, 214, 143, 0.1);
  --green-2: rgba(0, 214, 143, 0.2);
  --red: #ff3d6a;
  --red-dim: rgba(255, 61, 106, 0.1);
  --red-2: rgba(255, 61, 106, 0.2);
  --yellow: #ffbe0b;
  --yellow-dim: rgba(255, 190, 11, 0.1);
  --blue: #3a86ff;

  --mono: 'JetBrains Mono', monospace;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius: 14px;
  --radius-sm: 8px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--sans);
  background: var(--bg-0);
  color: var(--text-1);
  min-height: 100vh;
  min-height: 100dvh;
  padding-bottom: env(safe-area-inset-bottom, 20px);
  overflow-x: hidden;
}

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

/* ═══ TOPBAR ═══ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(6, 6, 11, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-omega {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  border-radius: 50%;
  font-size: 1rem;
  font-weight: 800;
  color: white;
  box-shadow: 0 0 20px var(--accent-glow);
}

/* LIVE tag in header */
.live-tag {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 4px 12px;
  border-radius: 20px;
  background: var(--red-dim);
  color: var(--red);
  border: 1px solid rgba(255, 61, 106, 0.2);
  transition: all 0.3s var(--ease);
}

.live-tag.connected {
  background: var(--green-dim);
  color: var(--green);
  border-color: rgba(0, 214, 143, 0.3);
  animation: pulse 2s infinite;
  cursor: pointer;
}
.live-tag:hover {
  opacity: 0.85;
  transform: scale(1.05);
}


.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-clock {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--text-3);
  white-space: nowrap;
}

/* ═══ STATUS BAR ═══ */
.status-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 8px 16px;
  background: var(--bg-1);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-2);
}

.status-item {
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 2s infinite;
}

.status-dot.off { background: var(--red); animation: none; }
.status-dot.mock { background: var(--yellow); }

.clock {
  font-family: var(--mono);
  font-size: 0.72rem;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

@keyframes priceFlash {
  0% { color: var(--accent-2); text-shadow: 0 0 8px var(--accent-glow); }
  100% { color: inherit; text-shadow: none; }
}
.flash { animation: priceFlash 0.4s ease-out; }
.signal-price { transition: color 0.2s; }
.pred-cell-val { transition: color 0.2s; }

/* ═══ PILOT TOGGLE ═══ */
.pilot-section { padding: 16px; }

.pilot-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(145deg, var(--bg-2), var(--bg-1));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  position: relative;
}

.pilot-row.armed {
  border-color: var(--accent);
  box-shadow: 0 0 20px var(--accent-dim);
}

.pilot-title {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.pilot-desc {
  font-size: 0.72rem;
  color: var(--text-3);
  margin-top: 2px;
}

.pilot-left {
  flex: 1;
  min-width: 0;
}

.pilot-toggle-wrap {
  position: relative;
}

/* Toggle switch */
.pilot-toggle {
  position: relative;
  display: inline-block;
  width: 56px;
  height: 30px;
  cursor: pointer;
}

.pilot-toggle input { display: none; }

.pilot-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-4);
  border-radius: 30px;
  transition: 0.3s var(--ease);
}

.pilot-toggle input:checked + .pilot-slider {
  background: var(--accent);
  box-shadow: 0 0 14px var(--accent-dim);
}

.pilot-knob {
  position: absolute;
  width: 24px;
  height: 24px;
  left: 3px;
  bottom: 3px;
  background: var(--text-3);
  border-radius: 50%;
  transition: 0.3s var(--ease);
  cursor: pointer;
  z-index: 2;
}

.pilot-knob:hover {
  box-shadow: 0 0 8px rgba(255,255,255,0.2);
}

.pilot-toggle input:checked + .pilot-slider .pilot-knob {
  transform: translateX(26px);
  background: white;
}


/* ═══ ACCOUNT SWITCHER ═══ */
.acct-switch {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 8px !important;
  transition: all 0.2s var(--ease);
}
.acct-switch:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
}
.acct-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.2s var(--ease);
  background: transparent;
  width: 100%;
  text-align: left;
}
.acct-card:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
}
.acct-card.active {
  border-color: rgba(0,214,143,0.4);
  background: rgba(0,214,143,0.06);
}

/* ═══ RISK MODE CARDS (in SL panel) ═══ */
.risk-card {
  opacity: 0.6;
  transition: all 0.2s var(--ease);
}

.risk-card:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

.risk-card.active[data-mode="reasoning"] {
  opacity: 1;
  border-color: rgba(0, 214, 143, 0.4) !important;
  background: rgba(0, 214, 143, 0.1) !important;
  box-shadow: 0 0 12px rgba(0, 214, 143, 0.12);
}

.risk-card.active[data-mode="risky"] {
  opacity: 1;
  border-color: rgba(255, 190, 11, 0.4) !important;
  background: rgba(255, 190, 11, 0.1) !important;
  box-shadow: 0 0 12px rgba(255, 190, 11, 0.12);
}

.risk-card.active[data-mode="madmax"] {
  opacity: 1;
  border-color: rgba(255, 61, 106, 0.4) !important;
  background: rgba(255, 61, 106, 0.1) !important;
  box-shadow: 0 0 12px rgba(255, 61, 106, 0.12);
  animation: madpulse 2s ease-in-out infinite;
}

@keyframes madpulse {
  0%, 100% { box-shadow: 0 0 12px rgba(255, 61, 106, 0.12); }
  50% { box-shadow: 0 0 20px rgba(255, 61, 106, 0.3); }
}

/* ═══ BOLT WALLET BUTTON ═══ */
.bolt-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  min-width: 34px;
  height: 34px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
  flex-shrink: 0;
  z-index: 5;
  font-size: 20px;
  line-height: 1;
  filter: saturate(1.2);
}

.bolt-btn:hover {
  transform: scale(1.2);
  filter: saturate(1.5) brightness(1.2);
}

.bolt-btn:active {
  transform: scale(0.9);
}

.bolt-btn.connected {
  color: #4ade80;
  border-color: rgba(74,222,128,0.35);
  background: linear-gradient(135deg, rgba(74,222,128,0.1), rgba(74,222,128,0.03));
}

.bolt-btn.connected:hover {
  border-color: #4ade80;
  box-shadow: 0 0 16px rgba(74,222,128,0.15);
}



/* Make toggle wrap flex so bolt + toggle sit side by side */
.pilot-left {
  flex: 1;
  min-width: 0;
}

.pilot-toggle-wrap {
  position: relative;
}

/* ═══ WALLET DROPDOWN ═══ */
.wallet-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 240px;
  max-height: 420px;
  overflow-y: auto;
  background: var(--bg-1);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  padding: 6px 0;
  z-index: 200;
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
  animation: dropIn 0.2s var(--ease);
}

.wallet-dropdown.open { display: block; }

@keyframes dropIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.wd-header {
  padding: 8px 14px 4px;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-3);
}

.wd-option {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 14px;
  background: none;
  border: none;
  color: var(--text-1);
  font-size: 0.82rem;
  font-weight: 500;
  font-family: var(--sans);
  cursor: pointer;
  transition: background 0.15s;
  text-align: left;
}

.wd-option:hover {
  background: var(--bg-3);
}

.wd-option.active {
  color: var(--accent-2);
  background: var(--accent-dim);
  border-left: 2px solid var(--accent);
}

.wd-icon {
  font-size: 1rem;
  width: 20px;
  text-align: center;
}

.wd-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}

/* City label */
#city-label {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.68rem;
  color: var(--text-3);
  margin-right: 4px;
}

/* Stats grid */
.live-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.live-stats.two-col {
  grid-template-columns: repeat(2, 1fr);
}

/* Toggle Switch (kept for wallet section) */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 52px;
  height: 28px;
  flex-shrink: 0;
}

.toggle-switch.small { width: 42px; height: 24px; }

.toggle-switch input { display: none; }

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-4);
  border-radius: 28px;
  cursor: pointer;
  transition: 0.3s var(--ease);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  width: 22px;
  height: 22px;
  left: 3px;
  bottom: 3px;
  background: var(--text-3);
  border-radius: 50%;
  transition: 0.3s var(--ease);
}

.toggle-switch.small .toggle-slider::before {
  width: 18px;
  height: 18px;
}

input:checked + .toggle-slider {
  background: var(--green);
  box-shadow: 0 0 12px var(--green-dim);
}

input:checked + .toggle-slider::before {
  transform: translateX(24px);
  background: white;
}

.toggle-switch.small input:checked + .toggle-slider::before {
  transform: translateX(18px);
}

.stat-box {
  text-align: center;
  padding: 10px 4px;
  background: rgba(0,0,0,0.2);
  border-radius: var(--radius-sm);
}

.stat-box.stat-hero {
  padding: 18px 8px;
  background: linear-gradient(145deg, rgba(0,0,0,0.3), rgba(0,0,0,0.15));
  border: 1px solid var(--border);
}

.stat-value {
  font-family: var(--mono);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.stat-value.stat-big {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -1px;
}

.stat-label {
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-3);
  margin-top: 3px;
}

.stat-hero .stat-label {
  font-size: 0.7rem;
  margin-top: 6px;
}

/* Wallet dropdown icon images */
.wd-icon-img {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  object-fit: contain;
  flex-shrink: 0;
}

/* ═══ WALLET SECTION ═══ */
.wallet-section { padding: 0 16px 16px; }

.wallet-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-bottom: 10px;
}

.wallet-address {
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 500;
}

.wallet-balance {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--text-2);
  margin-top: 2px;
}

.wallet-chain {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 3px 10px;
  background: var(--accent-dim);
  color: var(--accent-2);
  border-radius: 20px;
}

.swap-settings {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 4px 0;
}

.swap-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  border-bottom: 1px solid rgba(28, 28, 48, 0.5);
}

.swap-row:last-child { border-bottom: none; }

.swap-label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-2);
}

.swap-input-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}

.swap-input {
  width: 80px;
  padding: 5px 8px;
  background: var(--bg-0);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-1);
  font-family: var(--mono);
  font-size: 0.82rem;
  text-align: right;
  outline: none;
}

.swap-input:focus { border-color: var(--accent); }

.swap-unit {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-3);
}

.swap-select {
  padding: 5px 8px;
  background: var(--bg-0);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-1);
  font-family: var(--sans);
  font-size: 0.78rem;
  outline: none;
}

.slippage-btns {
  display: flex;
  gap: 4px;
}

.slip-btn {
  padding: 4px 10px;
  font-size: 0.7rem;
  font-weight: 600;
  font-family: var(--mono);
  background: var(--bg-0);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-2);
  cursor: pointer;
  transition: all 0.15s;
}

.slip-btn:hover { border-color: var(--border-2); }
.slip-btn.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent-2);
}

/* ═══ SECTION LABELS ═══ */
.section-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-3);
  margin-bottom: 10px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 0;
  margin-bottom: 10px;
}

/* ═══ FILTER PILLS ═══ */
.filter-pills {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.pill {
  padding: 4px 10px;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text-3);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
  font-family: var(--sans);
}

.pill:hover { border-color: var(--border-2); color: var(--text-2); }
.pill.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

/* ═══ SIGNAL CARDS ═══ */
.signals-section { padding: 0 0 16px; }

.signal-list { padding: 0 16px; display: flex; flex-direction: column; gap: 6px; }

.signal-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s var(--ease);
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
}

.signal-card:hover { border-color: var(--border-2); background: var(--bg-3); }

.signal-card:active { transform: scale(0.99); }

.signal-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  overflow: hidden;
}

.signal-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex-shrink: 0;
  object-fit: contain;
}

.signal-icon-fallback {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 50%;
  background: var(--bg-4);
  color: var(--text-2);
  font-weight: 700;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.signal-card.expanded {
  border-color: var(--accent);
  box-shadow: 0 0 20px var(--accent-dim);
}

.signal-name {
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.signal-class {
  font-size: 0.58rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-3);
  margin-top: 1px;
}

.signal-price {
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
  flex-shrink: 0;
}

.signal-change {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 6px;
  text-align: center;
  white-space: nowrap;
  flex-shrink: 0;
}

.signal-change.up { color: var(--green); background: var(--green-dim); }
.signal-change.down { color: var(--red); background: var(--red-dim); }
.signal-change.flat { color: var(--text-3); background: rgba(92,92,120,0.1); }

/* Expanded detail */
.signal-detail {
  display: none;
  grid-column: 1 / -1;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  margin-top: 8px;
}

.signal-card.expanded .signal-detail { display: block; }

.pred-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 6px;
}

.pred-cell {
  text-align: center;
  padding: 8px 4px;
  background: rgba(0,0,0,0.25);
  border-radius: 6px;
}

.pred-cell-label {
  font-size: 0.58rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-3);
  margin-bottom: 3px;
}

.pred-cell-val {
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 600;
}

.pred-cell-delta {
  font-family: var(--mono);
  font-size: 0.62rem;
  margin-top: 2px;
}

.pred-cell-delta.up { color: var(--green); }
.pred-cell-delta.down { color: var(--red); }

.pred-cell-conf {
  font-size: 0.5rem;
  font-weight: 600;
  color: var(--text-3);
  margin-top: 1px;
  opacity: 0.7;
}

.signal-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.sig-action-btn {
  flex: 1;
  padding: 9px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: var(--sans);
  transition: all 0.15s;
}

.sig-action-btn.swap-buy {
  background: linear-gradient(135deg, #00b074, #00d68f);
  color: white;
}

.sig-action-btn.swap-sell {
  background: linear-gradient(135deg, #d43f5a, #ff3d6a);
  color: white;
}

.sig-action-btn:active { transform: scale(0.97); }

/* ═══ LOG ═══ */
.log-section { padding: 0 0 16px; }

.log-badge {
  font-family: var(--mono);
  font-size: 0.62rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  background: var(--accent-dim);
  color: var(--accent-2);
}

.log-list { padding: 0 16px; }

.log-empty {
  text-align: center;
  padding: 24px;
  font-size: 0.78rem;
  color: var(--text-3);
}

.log-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(28, 28, 48, 0.4);
  font-size: 0.78rem;
  animation: slideIn 0.3s var(--ease);
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.log-time {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--text-3);
  min-width: 56px;
}

.log-side-tag {
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 4px;
}

.log-side-tag.long { color: var(--green); background: var(--green-dim); }
.log-side-tag.short { color: var(--red); background: var(--red-dim); }
.log-side-tag.swap { color: var(--blue); background: rgba(58,134,255,0.1); }
.log-side-tag.close { color: var(--yellow); background: var(--yellow-dim); }

.log-asset { font-weight: 600; }

.log-info {
  flex: 1;
  text-align: right;
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--text-2);
}

.log-status-dot {
  font-size: 0.58rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 20px;
}

.log-status-dot.sim { background: var(--yellow-dim); color: var(--yellow); }
.log-status-dot.done { background: var(--green-dim); color: var(--green); }

/* ═══ VENUES ═══ */
.venues-section { padding: 0 16px 16px; }

.section-collapse {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 12px 0;
  background: none;
  border: none;
  color: var(--text-3);
  cursor: pointer;
  font-family: var(--sans);
}

.collapse-arrow {
  font-size: 1rem;
  transition: transform 0.2s;
}

.collapse-arrow.open { transform: rotate(180deg); }

.venue-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.venue-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 500;
}

.venue-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
}

.venue-dot.live { background: var(--green); }
.venue-dot.sandbox { background: var(--yellow); }
.venue-dot.off { background: var(--text-3); }

/* ═══ FOOTER ═══ */
.footer {
  text-align: center;
  padding: 20px;
  font-size: 0.72rem;
  color: var(--text-3);
  font-family: var(--mono);
}

/* ═══ DESKTOP ENHANCEMENTS ═══ */
@media (min-width: 768px) {
  body { max-width: 560px; margin: 0 auto; }

  .autopilot-stats { gap: 14px; }
  .pred-row { gap: 8px; }
}

@media (min-width: 1024px) {
  body { max-width: 480px; }
}



.pilot-controls {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
/* ═══ STOP-LOSS BUTTON ═══ */
.sl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  min-width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
  flex-shrink: 0;
  z-index: 10;
  position: relative;
}
.sl-btn:hover { transform: scale(1.15); }
.sl-btn:active { transform: scale(0.9); }

.sl-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--text-3, #555);
  border: 2px solid rgba(255,255,255,0.15);
  transition: all 0.3s ease;
  display: block;
  pointer-events: none;
}
.sl-dot.active {
  background: #4ade80;
  border-color: rgba(74,222,128,0.4);
  box-shadow: 0 0 10px rgba(74,222,128,0.3);
}

/* ═══ STOP-LOSS OVERLAY + PANEL ═══ */
.sl-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 9998;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}
.sl-overlay.active { display: flex; }

.sl-panel {
  background: var(--bg-1, #0a0a0f);
  border: 1px solid var(--border-2, rgba(255,255,255,0.08));
  border-radius: 16px;
  width: 320px;
  max-width: 92%;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.sl-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border, rgba(255,255,255,0.06));
}
.sl-title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.3px;
}
.sl-close {
  background: none;
  border: none;
  color: var(--text-3, #666);
  font-size: 20px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}
.sl-close:hover { color: #ef4444; }

.sl-body {
  padding: 20px;
}

.sl-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}
.sl-label {
  font-size: 13px;
  color: var(--text-2, #aaa);
}

/* Toggle switch */
.sl-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}
.sl-switch input { display: none; }
.sl-switch-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-4, #333);
  border-radius: 24px;
  cursor: pointer;
  transition: 0.25s;
}
.sl-switch-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: 0.25s;
}
.sl-switch input:checked + .sl-switch-slider {
  background: #4ade80;
}
.sl-switch input:checked + .sl-switch-slider::before {
  transform: translateX(20px);
}

.sl-divider {
  height: 1px;
  background: var(--border, rgba(255,255,255,0.06));
  margin: 16px 0;
}

.sl-main-label {
  font-size: 12px;
  color: var(--text-3, #888);
  margin-bottom: 12px;
  letter-spacing: 0.3px;
}

.sl-slider-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sl-range {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  background: var(--bg-4, #333);
  border-radius: 3px;
  outline: none;
}
.sl-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  background: #ef4444;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid rgba(255,255,255,0.15);
  box-shadow: 0 0 8px rgba(239,68,68,0.3);
}

.sl-value {
  font-size: 18px;
  font-weight: 800;
  color: #ef4444;
  min-width: 42px;
  text-align: right;
  font-family: 'JetBrains Mono', monospace;
}

.sl-hint {
  font-size: 11px;
  color: var(--text-3, #666);
  margin-top: 12px;
  line-height: 1.6;
}

.sl-info-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 12px;
}
.sl-info-label { color: var(--text-3, #888); }
.sl-info-val { color: var(--text-1, #e2e8f0); font-weight: 600; }

.sl-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border, rgba(255,255,255,0.06));
}

.sl-save-btn {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, rgba(74,222,128,0.15), rgba(74,222,128,0.06));
  border: 1px solid rgba(74,222,128,0.3);
  border-radius: 10px;
  color: #4ade80;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.5px;
}
.sl-save-btn:hover {
  background: linear-gradient(135deg, rgba(74,222,128,0.25), rgba(74,222,128,0.1));
  border-color: #4ade80;
  box-shadow: 0 0 16px rgba(74,222,128,0.15);
}
