/* ==========================================================================
   LOADBEAR AI STYLE SYSTEM (VANILLA CSS)
   ========================================================================== */

/* Design Tokens & Theme Variables */
:root {
  --bg-obsidian: #050608;
  --bg-carbon: rgba(14, 16, 22, 0.7);
  --bg-card: rgba(20, 24, 33, 0.5);
  --bg-glass: rgba(14, 16, 22, 0.4);
  --border-glass: rgba(255, 255, 255, 0.05);
  --border-glass-focus: rgba(144, 224, 239, 0.35);
  
  /* Loadbear GT/Gulf palette — carbon base, Gulf blue primary, Gulf orange attention */
  --accent-gold: #54b8e8;               /* Gulf blue (primary accent) */
  --accent-gold-rgb: 84, 184, 232;
  --accent-cyan: #54b8e8;               /* Gulf blue (alias referenced across the homepage) */
  --accent-orange: #f0682d;             /* Gulf orange (attention / CTA) */
  --gradient-primary: linear-gradient(135deg, #f0682d 0%, #ff8a54 100%); /* Gulf orange CTA */
  --accent-emerald: #46d36b;            /* status OK green (calmed from neon) */
  --accent-ruby: #ff3b30;
  
  /* Text Colors */
  --text-primary: #f2f5f9;
  --text-secondary: #909db2;
  --text-muted: #536279;
  
  /* Fonts */
  --font-ui: 'Outfit', sans-serif;
  --font-code: 'JetBrains Mono', monospace;
  
  /* Shadows and Glows */
  --glow-gold: 0 0 15px rgba(144, 224, 239, 0.25);
  --glow-orange: 0 0 15px rgba(0, 180, 216, 0.25);
  --glow-emerald: 0 0 15px rgba(0, 255, 170, 0.25);
  --shadow-main: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
  
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Elements */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-obsidian);
  color: var(--text-primary);
  font-family: var(--font-ui);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-gold);
  box-shadow: var(--glow-gold);
}

/* Ambient Background Glows */
.ambient-glow {
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(150px);
  opacity: 0.08;
  z-index: -1;
}

.glow-gold {
  background: radial-gradient(circle, var(--accent-gold) 0%, transparent 70%);
  top: -15%;
  right: -10%;
}

.glow-carbon {
  background: radial-gradient(circle, var(--accent-orange) 0%, transparent 70%);
  bottom: -15%;
  left: -10%;
}

/* Global Helpers */
.text-gold { color: var(--accent-gold) !important; }
.text-orange { color: var(--accent-orange) !important; }
.text-green { color: var(--accent-emerald) !important; }
.text-red { color: var(--accent-ruby) !important; }
.icon-gold { color: var(--accent-gold); width: 18px; height: 18px; }
.font-bold { font-weight: 600; }
.border-bottom { border-bottom: 1px solid var(--border-glass); }

/* Glassmorphism Panel */
.glass-panel {
  background: var(--bg-carbon);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  box-shadow: var(--shadow-main);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.glass-panel:hover {
  border-color: rgba(255, 255, 255, 0.08);
}

/* Layout Wrapper */
.console-wrapper {
  display: flex;
  flex-direction: column;
  height: 100vh;
  padding: 16px;
  gap: 16px;
}

/* Header Layout */
.console-header {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 16px 24px;
  gap: 16px;
  flex-shrink: 0;
}

.header-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-logo {
  height: 52px;
  width: auto;
  mix-blend-mode: lighten;
}

.brand-text h1 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  color: #ffffff;
  text-transform: uppercase;
}

.brand-sub {
  font-size: 0.58rem;
  letter-spacing: 3.5px;
  color: var(--text-secondary);
  font-weight: 700;
  display: block;
  margin-top: 1px;
  text-transform: uppercase;
}

/* Search Panel In Header */
.search-panel {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-grow: 1;
  max-width: 100%;
  background: rgba(0, 0, 0, 0.2);
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--border-glass);
  flex-wrap: wrap;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.input-group label {
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 600;
}

.input-group input, .input-group select {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  padding: 8px 12px;
  border-radius: 6px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  transition: all var(--transition-fast);
}

.input-group input:focus, .input-group select:focus {
  outline: none;
  border-color: var(--border-glass-focus);
  box-shadow: var(--glow-gold);
}

.global-stats {
  display: flex;
  gap: 20px;
  flex-shrink: 0;
}

.stat-box {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-label {
  font-size: 0.6rem;
  letter-spacing: 1px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 700;
}

.stat-value {
  font-size: 1.15rem;
  font-weight: 700;
  font-family: var(--font-code);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-gold);
  box-shadow: var(--glow-gold);
  display: inline-block;
  animation: pulse-slow 2s infinite;
}

/* Primary Button */
.btn {
  font-family: var(--font-ui);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.82rem;
  padding: 9px 16px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-orange) 100%);
  color: var(--bg-obsidian);
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.1);
}

.btn-glow {
  box-shadow: 0 0 10px rgba(255, 183, 0, 0.3);
}

.btn-glow:hover {
  box-shadow: 0 0 18px rgba(255, 183, 0, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border-color: var(--border-glass);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
}

.btn-block {
  width: 100%;
}

.btn-icon {
  width: 15px;
  height: 15px;
}

/* Console Panels Grid Layout */
.console-grid {
  display: grid;
  grid-template-columns: 360px 1fr 1fr;
  gap: 16px;
  flex-grow: 1;
  min-height: 0;
}

.console-panel {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

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

.header-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-title h2 {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Badges */
.badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid transparent;
}

.badge-gold {
  background: rgba(255, 183, 0, 0.12);
  color: var(--accent-gold);
  border-color: rgba(255, 183, 0, 0.25);
}

.badge-neutral {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  border-color: var(--border-glass);
}

.badge-green {
  background: rgba(0, 255, 170, 0.12);
  color: var(--accent-emerald);
  border-color: rgba(0, 255, 170, 0.25);
}

.badge-red {
  background: rgba(255, 59, 48, 0.12);
  color: var(--accent-ruby);
  border-color: rgba(255, 59, 48, 0.25);
}

/* PANEL 1: Prospect Targets Container */
.leads-container {
  flex-grow: 1;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lead-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-glass);
  padding: 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.lead-card:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 183, 0, 0.25);
  transform: translateY(-1px);
}

.lead-card.active {
  background: rgba(255, 183, 0, 0.04);
  border-color: var(--accent-gold);
  box-shadow: inset 0 0 10px rgba(255, 183, 0, 0.05);
}

.lead-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.lead-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
}

.lead-card-website {
  font-size: 0.72rem;
  color: var(--text-secondary);
  font-family: var(--font-code);
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

.lead-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.7rem;
  margin-top: 4px;
  color: var(--text-muted);
}

/* PANEL 2: Technical Diagnostics Viewport */
.diagnostics-container {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.diag-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.diag-title {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.diag-meta-link {
  font-size: 0.72rem;
  font-family: var(--font-code);
  color: var(--accent-gold);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.diag-meta-link:hover {
  text-decoration: underline;
}

.diag-gauge-wrapper {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-glass);
  padding: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.diag-gauge-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.diag-gauge-label {
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.diag-gauge-value {
  font-size: 1.8rem;
  font-weight: 800;
  font-family: var(--font-code);
}

/* Linear progress speed bar */
.speed-bar-wrapper {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.speed-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.speed-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}

.speed-fill {
  height: 100%;
  width: 0%;
  transition: width 1s ease-out;
  border-radius: 3px;
}

.speed-fill.fast {
  background: linear-gradient(90deg, var(--accent-gold) 0%, var(--accent-emerald) 100%);
  box-shadow: 0 0 8px var(--accent-emerald);
}

.speed-fill.slow {
  background: linear-gradient(90deg, var(--accent-orange) 0%, var(--accent-ruby) 100%);
  box-shadow: 0 0 8px var(--accent-ruby);
}

/* Checked Checklist Item Grid */
.audit-check-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.audit-check-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.02);
  padding: 10px 14px;
  border-radius: 6px;
}

.check-label-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
}

.check-icon {
  width: 15px;
  height: 15px;
}

.check-val {
  font-size: 0.75rem;
  font-weight: 700;
  font-family: var(--font-code);
}

.diag-action-bar {
  margin-top: auto;
  padding-top: 16px;
}

/* PANEL 3: Outbound Copywriter View */
.writer-container {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.writer-subject-wrapper {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-glass);
  padding: 10px 14px;
  border-radius: 6px;
}

.writer-subject-label {
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.writer-subject-input {
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 600;
  width: 100%;
}

.writer-subject-input:focus {
  outline: none;
}

.writer-body-wrapper {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-glass);
  padding: 14px;
  border-radius: 6px;
  min-height: 250px;
}

.writer-body-textarea {
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-code);
  font-size: 0.78rem;
  line-height: 1.45;
  width: 100%;
  height: 100%;
  resize: none;
  flex-grow: 1;
}

.writer-body-textarea:focus {
  outline: none;
}

.writer-actions {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

/* Bottom status telemetry log feed */
.console-terminal {
  height: 160px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-color: rgba(255, 183, 0, 0.15);
}

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

.terminal-title {
  font-family: var(--font-code);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-secondary);
}

.status-indicator {
  font-family: var(--font-code);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--accent-gold);
  background: rgba(255, 183, 0, 0.05);
  padding: 2px 8px;
  border-radius: 3px;
  border: 1px solid rgba(255, 183, 0, 0.15);
}

.terminal-body {
  flex-grow: 1;
  background: rgba(0, 0, 0, 0.5);
  padding: 12px 16px;
  overflow-y: auto;
  font-family: var(--font-code);
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.85);
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-shadow: 0 0 3px rgba(255, 183, 0, 0.1);
}

.log-line {
  line-height: 1.4;
  word-break: break-all;
}

/* Empty State / Spinner */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
  color: var(--text-secondary);
  gap: 12px;
  padding: 24px;
}

.empty-icon {
  width: 40px;
  height: 40px;
  color: var(--text-muted);
}

.spinner {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(255, 183, 0, 0.1);
  border-top-color: var(--accent-gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-bottom: 8px;
}

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

@keyframes pulse-slow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.95); }
}

/* Responsive Grid Adjustments */
@media (max-width: 1100px) {
  .header-top-row {
    flex-wrap: wrap;
    gap: 16px;
  }
  .console-navigation {
    margin-left: auto;
    margin-right: 0;
  }
  .console-grid {
    grid-template-columns: 280px 1fr;
    grid-template-rows: auto auto;
  }
  .panel-writer {
    grid-column: span 2;
    height: 400px;
  }
}

@media (max-width: 850px) {
  .console-wrapper {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
  }
  .header-top-row {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
  }
  .header-brand {
    justify-content: center;
  }
  .console-navigation {
    margin: 0 auto;
    width: 100%;
    justify-content: center;
  }
  .global-stats {
    justify-content: center;
    margin-top: 4px;
  }
  .search-panel {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .search-panel .btn {
    width: 100%;
  }
  .console-grid {
    grid-template-columns: 1fr;
  }
  .panel-leads, .panel-diagnostics, .panel-writer, .panel-pipeline {
    grid-column: span 1 !important;
    height: 500px;
  }
}

/* Height-based responsiveness to prevent cutoff in short viewports */
@media (max-height: 850px) {
  .console-wrapper {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
  }
  .console-grid {
    min-height: 650px;
    height: auto;
  }
  .console-panel {
    height: 650px;
  }
}

/* ==========================================================================
   NAVIGATION & PIPELINE LAYOUT STYLES
   ========================================================================== */

.console-navigation {
  display: flex;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-glass);
  padding: 4px;
  border-radius: 8px;
  gap: 4px;
  margin-left: 20px;
  margin-right: auto;
}

.nav-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition-fast);
}

.nav-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.03);
}

.nav-btn.active {
  color: var(--bg-obsidian);
  background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-orange) 100%);
  box-shadow: var(--glow-gold);
}

.hidden {
  display: none !important;
}

/* Pipeline Table Styling */
.pipeline-container {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
}

.pipeline-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-ui);
  text-align: left;
}

.pipeline-table th {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 1px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-glass);
}

.pipeline-table td {
  font-size: 0.82rem;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
  vertical-align: middle;
}

.pipeline-table tbody tr {
  cursor: pointer;
  transition: all var(--transition-fast);
}

.pipeline-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.015);
}

.pipeline-table tbody tr.active {
  background: rgba(144, 224, 239, 0.03);
  border-left: 2px solid var(--accent-gold);
}

.pipeline-company-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pipeline-company-name {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.88rem;
}

.pipeline-company-domain {
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-family: var(--font-code);
}

.pipeline-action-btns {
  display: flex;
  gap: 8px;
}

.pipeline-action-btns .btn-icon-only {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
  padding: 6px;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.pipeline-action-btns .btn-icon-only:hover {
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.15);
}

.pipeline-action-btns .btn-icon-only.btn-pay-sync:hover {
  color: var(--accent-gold);
  border-color: var(--border-glass-focus);
  box-shadow: var(--glow-gold);
}

.pipeline-action-btns .btn-icon-only.btn-delete:hover {
  color: var(--accent-ruby);
  border-color: rgba(255, 59, 48, 0.3);
}

.pipeline-pay-link {
  font-family: var(--font-code);
  font-size: 0.7rem;
  color: var(--accent-gold);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  background: rgba(144, 224, 239, 0.04);
  border: 1px solid rgba(144, 224, 239, 0.15);
  border-radius: 4px;
  transition: all var(--transition-fast);
}

.pipeline-pay-link:hover {
  background: rgba(144, 224, 239, 0.08);
  border-color: var(--accent-gold);
  text-decoration: none;
  box-shadow: var(--glow-gold);
}

.inline-icon {
  width: 14px;
  height: 14px;
  vertical-align: middle;
}

/* ==========================================================================
   OPERATIONAL DASHBOARD STYLING
   ========================================================================== */
.panel-dashboard {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.dash-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all var(--transition-fast);
}

.dash-card:hover {
  border-color: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}

.dash-card-title {
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--text-secondary);
  font-weight: 700;
  text-transform: uppercase;
}

.dash-card-value {
  font-size: 2.2rem;
  font-weight: 800;
  font-family: var(--font-ui);
  line-height: 1;
}

.dash-card-sub {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.dashboard-controls-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 10px;
}

@media (max-width: 900px) {
  .dashboard-controls-grid {
    grid-template-columns: 1fr;
  }
}

.control-panel, .logs-panel {
  display: flex;
  flex-direction: column;
  min-height: 400px;
}

.control-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex-grow: 1;
}

.campaign-toggle-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.interval-select-wrapper {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-grow: 1;
}

.interval-select-wrapper label {
  font-size: 0.6rem;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
}

.interval-select-wrapper select {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  padding: 8px 12px;
  border-radius: 6px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  outline: none;
}

.targets-manager-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-top: 1px solid var(--border-glass);
  padding-top: 16px;
}

.targets-manager-wrapper h4 {
  font-size: 0.75rem;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
}

.add-target-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.add-target-form select {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  padding: 8px 12px;
  border-radius: 6px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  outline: none;
}

.console-input {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  padding: 8px 12px;
  border-radius: 6px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  flex: 1;
  min-width: 150px;
}

.console-input:focus {
  outline: none;
  border-color: var(--border-glass-focus);
}

.targets-list-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-height: 180px;
  overflow-y: auto;
  padding: 4px;
}

.target-badge {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-glass);
  padding: 6px 12px;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
}

.target-badge .niche-label {
  color: var(--text-primary);
  font-weight: 600;
}

.target-badge .region-label {
  color: var(--text-secondary);
}

.target-badge .remove-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-weight: bold;
  font-size: 0.8rem;
  padding: 0;
  display: flex;
  align-items: center;
  transition: color var(--transition-fast);
}

.target-badge .remove-btn:hover {
  color: var(--accent-ruby);
}

.logs-body {
  flex-grow: 1;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 0 0 12px 12px;
  font-family: var(--font-code);
  font-size: 0.75rem;
  padding: 16px;
  overflow-y: auto;
  max-height: 380px;
}

.logs-body .log-line {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 4px;
}

.logs-body .log-line.error {
  color: var(--accent-ruby);
}

/* ==========================================================================
   HEURISTICS TREND ANALYZER CARD & TABLE STYLES
   ========================================================================== */
.dashboard-trends-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.trends-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.trends-insights-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.insight-card {
  background: rgba(144, 224, 239, 0.03);
  border: 1px solid rgba(144, 224, 239, 0.15);
  border-radius: 8px;
  padding: 12px 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.8rem;
  line-height: 1.5;
}

.insight-card.positive {
  background: rgba(0, 255, 170, 0.03);
  border-color: rgba(0, 255, 170, 0.15);
}

.insight-card.warning {
  background: rgba(255, 183, 0, 0.03);
  border-color: rgba(255, 183, 0, 0.15);
}

.insight-card.opportunity {
  background: rgba(144, 224, 239, 0.03);
  border-color: rgba(144, 224, 239, 0.15);
}

.insight-card-icon {
  margin-top: 2px;
  flex-shrink: 0;
  width: 16px;
  height: 16px;
}

.insight-card-content {
  flex-grow: 1;
}

.insight-card-content strong {
  display: block;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.insight-card-content p {
  margin: 0;
  color: var(--text-secondary);
}

.trends-tables-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 900px) {
  .trends-tables-grid {
    grid-template-columns: 1fr;
  }
}

.trends-table-box {
  padding: 16px;
  background: rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.trends-table-title {
  font-size: 0.75rem;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
}

.trends-mini-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75rem;
}

.trends-mini-table th, .trends-mini-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-glass);
}

.trends-mini-table th {
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.65rem;
  letter-spacing: 0.5px;
}

.trends-mini-table tr:last-child td {
  border-bottom: none;
}

/* Review Queue Panel Styles */
.border-right {
  border-right: 1px solid var(--border-glass);
}

@media (max-width: 950px) {
  .review-split-container {
    grid-template-columns: 1fr !important;
    height: auto !important;
    min-height: 0;
  }
  .review-left-pane {
    border-right: none !important;
    border-bottom: 1px solid var(--border-glass);
    height: 300px !important;
  }
  .review-right-pane {
    height: auto !important;
  }
}




