/* ==========================================================================
   Reverse Image Search — Clean Dual-Theme Stylesheet
   ========================================================================== */

:root,
html.light {
  /* Light Theme Variables */
  --bg-app: #f8fafc;
  --bg-card: #ffffff;
  --bg-panel: #f8fafc;
  --bg-subtle: #f1f5f9;
  --bg-hover: #e2e8f0;

  --border-subtle: #e2e8f0;
  --border-color: #e2e8f0;
  --border-focus: #3b82f6;
  --border-dashed: #cbd5e1;

  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-subtle: #eff6ff;
  --primary-gradient: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);

  --emerald-500: #10b981;
  --emerald-subtle: #ecfdf5;
  --emerald-text: #047857;
  --amber-500: #f59e0b;
  --amber-subtle: #fffbeb;
  --amber-text: #b45309;
  --rose-500: #f43f5e;
  --rose-subtle: #fff1f2;
  --rose-text: #be123c;
  --purple-500: #8b5cf6;
  --purple-subtle: #f5f3ff;
  --purple-text: #6d28d9;

  --text-primary: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --font-display: 'Outfit', 'Hind Siliguri', 'Noto Sans Bengali', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-sans: 'Inter', 'Hind Siliguri', 'Noto Sans Bengali', -apple-system, BlinkMacSystemFont, sans-serif;

  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-card: 0 4px 12px -2px rgba(15, 23, 42, 0.06), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
  --shadow-hover: 0 12px 24px -4px rgba(15, 23, 42, 0.09), 0 4px 8px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 20px 30px -6px rgba(15, 23, 42, 0.1);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  --transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --bg-header: rgba(255, 255, 255, 0.96);
}

/* ==========================================================================
   Dark Mode CSS Variables — Override all tokens for dark theme
   ========================================================================== */
html.dark {
  --bg-app: #020617;           /* slate-950 */
  --bg-card: #0f172a;          /* slate-900 */
  --bg-panel: #0f172a;         /* panels/cards */
  --bg-subtle: #1e293b;        /* slate-800 */
  --bg-hover: #334155;         /* slate-700 */
  --bg-header: rgba(15, 23, 42, 0.95);

  --border-subtle: #1e293b;    /* slate-800 */
  --border-color: #334155;     /* slate-700 */
  --border-focus: #38bdf8;     /* sky-400 */
  --border-dashed: #334155;    /* slate-700 */

  --primary: #38bdf8;          /* sky-400 — vibrant on dark */
  --primary-hover: #7dd3fc;    /* sky-300 */
  --primary-subtle: #0c4a6e;   /* sky-950 */
  --primary-gradient: linear-gradient(135deg, #0ea5e9 0%, #6366f1 100%);

  --emerald-500: #34d399;
  --emerald-subtle: #064e3b;
  --emerald-text: #6ee7b7;
  --amber-500: #fbbf24;
  --amber-subtle: #451a03;
  --amber-text: #fcd34d;
  --rose-500: #fb7185;
  --rose-subtle: #4c0519;
  --rose-text: #fda4af;
  --purple-500: #a78bfa;
  --purple-subtle: #2e1065;
  --purple-text: #c4b5fd;

  --text-primary: #f1f5f9;     /* slate-100 */
  --text-secondary: #cbd5e1;   /* slate-300 */
  --text-muted: #94a3b8;       /* slate-400 */

  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow-card: 0 4px 12px -2px rgba(0, 0, 0, 0.4), 0 2px 6px -1px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 12px 24px -4px rgba(0, 0, 0, 0.5), 0 4px 8px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 30px -6px rgba(0, 0, 0, 0.5);
}


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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-app);  /* responds to :root (light) or html.dark override */
  color: var(--text-secondary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "kern" 1, "liga" 1;
  text-rendering: optimizeLegibility;
}

/* ==========================================================================
   Header / Sticky Navigation Bar
   ========================================================================== */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-header);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  box-shadow: 0 1px 0 0 rgba(0,0,0,0.04);
}

/* Brand name in header */
.brand-name {
  color: var(--text-primary);
  font-family: var(--font-display);
  letter-spacing: -0.01em;
}

/* Brand subtitle in header */
.brand-sub {
  color: var(--text-muted);
}

/* Vertical separator line */
.header-sep {
  height: 20px;
  width: 1px;
  background: var(--border-subtle);
}

/* Engine status pill */
.header-status-pill {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
}

/* Status label text */
.status-label {
  color: var(--text-muted);
}


.header-container {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3);
}

.brand-text {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.brand-text h1 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.brand-text h1 span {
  color: var(--primary);
}

.brand-sub {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: 4px;
}

.badge {
  font-size: 0.7rem;
  font-weight: 600;
  background: var(--primary-subtle);
  color: var(--primary);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(37, 99, 235, 0.15);
}

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

.status-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--emerald-500);
  box-shadow: 0 0 6px var(--emerald-500);
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.85); }
}

.device-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.76rem;
}

.device-tag {
  color: var(--text-muted);
  font-weight: 500;
}

.device-name {
  color: var(--text-primary);
  font-weight: 600;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-md);
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
}

.btn-ghost:hover {
  background: var(--bg-subtle);
  border-color: var(--border-dashed);
  color: var(--text-primary);
}

/* ==========================================================================
   Main Layout & Search Card
   ========================================================================== */
.main-container {
  max-width: 1240px;
  margin: 0 auto 60px;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.search-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  padding: 32px;
  transition: background 0.2s, border-color 0.2s;
}

/* Feature pills */
.feature-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  padding: 4px 11px;
  border-radius: 20px;
  transition: var(--transition);
  letter-spacing: 0.01em;
}

.feature-pill:hover {
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.4);
  background: rgba(56, 189, 248, 0.07);
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.15);
}

@media (max-width: 768px) {
  .search-card {
    padding: 20px;
  }
}

.search-header {
  margin-bottom: 28px;
  text-align: left;
}

.search-header h1 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  color: #f1f5f9;  /* slate-100 — readable in dark mode */
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.search-header p {
  color: #94a3b8; /* slate-400 */
  font-size: 0.95rem;
  line-height: 1.55;
}

.search-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 28px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .search-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

/* ==========================================================================
   Dropzone & File Upload
   ========================================================================== */
.dropzone-wrapper {
  display: flex;
  flex-direction: column;
}

.dropzone {
  min-height: 110px;
  height: auto;
  border: 2px dashed var(--border-dashed);
  border-radius: var(--radius-lg);
  background: #fafbfc;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  cursor: pointer;
  padding: 10px 14px;
}

.dropzone:hover, .dropzone.dragover {
  border-color: var(--primary);
  background: #f0f7ff;
}

.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 3px;
}

.upload-icon-circle {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--primary-subtle);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2px;
}

.drop-title {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.drop-title span {
  color: var(--primary);
  text-decoration: underline;
}

.drop-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.drop-hint {
  font-size: 0.74rem;
  color: #94a3b8;
  margin-bottom: 14px;
}

.btn-sample {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.btn-sample:hover {
  background: var(--primary-subtle);
  border-color: var(--primary);
}

/* Image Preview Container */
.preview-container {
  width: 100%;
  height: 100%;
  min-height: 250px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.preview-container img {
  max-width: 100%;
  max-height: 260px;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.preview-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  padding: 10px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.preview-meta {
  font-size: 0.8rem;
  color: #ffffff;
  font-weight: 500;
  max-width: 70%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-remove {
  background: rgba(244, 63, 94, 0.2);
  color: #ff859b;
  border: 1px solid rgba(244, 63, 94, 0.4);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-remove:hover {
  background: var(--rose-500);
  color: #ffffff;
}

/* ==========================================================================
   Inputs & Search Action
   ========================================================================== */
.inputs-wrapper {
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: center;
}

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

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.field-label-row label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
}

.field-icon {
  font-size: 0.95rem;
}

.tag-optional {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 400;
  background: var(--bg-subtle);
  padding: 2px 6px;
  border-radius: 4px;
}

.form-control {
  background: #ffffff;
  border: 1px solid var(--border-dashed);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  line-height: 1.5;
  transition: var(--transition);
  width: 100%;
}

.form-control:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.form-control::placeholder {
  color: #94a3b8;
  font-size: 0.85rem;
}

textarea.form-control {
  resize: vertical;
  min-height: 64px;
}

.field-help {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
  background: transparent;
  padding: 2px 0 0 2px;
  border-left: none;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Primary Search Button - High Energy Cyber AI Gradient */
.btn-search {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, #06b6d4 0%, #2563eb 50%, #7c3aed 100%);
  color: #ffffff;
  font-family: 'Outfit', -apple-system, sans-serif;
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: 0.02em;
  padding: 15px 28px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(6, 182, 212, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  width: 100%;
  margin-top: 4px;
  position: relative;
  overflow: hidden;
}

.btn-search::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
  transition: left 0.6s ease;
}

.btn-search:hover:not(:disabled)::before {
  left: 100%;
}

.btn-search:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(6, 182, 212, 0.5), 0 0 20px rgba(124, 58, 237, 0.35);
  filter: brightness(1.06);
}

.btn-search:active:not(:disabled) {
  transform: translateY(0);
}

.btn-search:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
  filter: grayscale(0.5);
}


/* ==========================================================================
   Real-Time Pipeline Progress
   ========================================================================== */
.progress-box {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.progress-status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.progress-number {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.progress-track {
  width: 100%;
  height: 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--primary-gradient);
  border-radius: var(--radius-full);
  transition: width 0.35s ease;
}

.pipeline-steps {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
}

.step-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.step-node span {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.step-node label {
  font-size: 0.68rem;
  color: var(--text-muted);
  font-weight: 500;
}

.step-node.active span {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.step-node.active label {
  color: var(--primary);
  font-weight: 700;
}

.step-node.completed span {
  background: var(--emerald-500);
  border-color: var(--emerald-500);
  color: #ffffff;
}

/* ==========================================================================
   Results: Main Summary Card & Key Insights
   ========================================================================== */
.results-section {
  display: flex;
  flex-direction: column;
  gap: 28px;
  animation: fadeIn 0.4s ease;
}

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

.summary-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-left: 5px solid var(--primary);
  border-radius: var(--radius-xl);
  padding: 30px;
  box-shadow: var(--shadow-card);
}

.summary-top-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.status-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--primary-subtle);
  color: var(--primary);
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.status-badge.CONFIRMED, .status-badge.PROBABLE {
  background: var(--emerald-subtle);
  color: var(--emerald-text);
  border-color: rgba(16, 185, 129, 0.3);
}

.status-badge.SUSPICIOUS, .status-badge.HIGH {
  background: var(--rose-subtle);
  color: var(--rose-text);
  border-color: rgba(244, 63, 94, 0.3);
}

.summary-headline {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.summary-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

/* ==========================================================================
   Verdict Card — Fully dual-themed summary banner
   ========================================================================== */
.verdict-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(51, 65, 85, 0.8);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.verdict-card-border {
  border-bottom: 1px solid rgba(51, 65, 85, 0.6);
  padding-bottom: 16px;
}

.verdict-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.verdict-pill.verdict-confirmed {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.35);
}

.verdict-pill.verdict-suspicious {
  background: rgba(251, 113, 133, 0.12);
  color: #fb7185;
  border-color: rgba(251, 113, 133, 0.25);
}


.verdict-headline {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  color: #f1f5f9;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.verdict-summary {
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.7;
}

/* Stat values: accent tones for dark mode */
.stat-value-accent {
  color: #22d3ee;
}
.stat-value-purple {
  color: #a78bfa;
}

/* Light theme verdict overrides */
html.light .verdict-card {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 100%) !important;
  border: 1px solid #bfdbfe !important;
  backdrop-filter: none !important;
  box-shadow: 0 8px 30px rgba(37, 99, 235, 0.07) !important;
}

html.light .verdict-card-border {
  border-bottom: 1px solid #dbeafe !important;
}

html.light .verdict-pill {
  background: rgba(5, 150, 105, 0.1) !important;
  color: #059669 !important;
  border-color: rgba(5, 150, 105, 0.3) !important;
}

html.light .verdict-pill.verdict-confirmed {
  background: rgba(5, 150, 105, 0.12) !important;
  color: #047857 !important;
  border-color: rgba(5, 150, 105, 0.35) !important;
}

html.light .verdict-pill.verdict-suspicious {
  background: rgba(225, 29, 72, 0.08) !important;
  color: #be123c !important;
  border-color: rgba(225, 29, 72, 0.25) !important;
}


html.light .verdict-headline {
  color: #0f172a !important;
}

html.light .verdict-summary {
  color: #475569 !important;
}

html.light .stat-card {
  background: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
}

html.light .stat-value-accent {
  color: #0369a1 !important;
}

html.light .stat-value-purple {
  color: #6d28d9 !important;
}

html.light .stat-value {
  color: #0f172a !important;
}

html.light .stat-label {
  color: #64748b !important;
}



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

.stat-card {
  background: #f8fafc;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.stat-icon {
  font-size: 1.5rem;
}

.stat-content {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 500;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* ==========================================================================
   Results: Navigation Tabs with Smooth Horizontal Scroll & Controls
   ========================================================================== */
.tabs-nav-container {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-bottom: 24px;
}

.tab-scroll-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
  cursor: pointer;
  z-index: 2;
  transition: all 0.2s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.tab-scroll-btn:hover {
  background: #f8fafc;
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(1.08);
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.15);
}

.tab-scroll-btn:active {
  transform: scale(0.96);
}

.results-tabs {
  flex: 1;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 2px;
}

.results-tabs::-webkit-scrollbar {
  display: none;
}

.results-tabs::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 6px;
}

.results-tabs::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 6px;
}

.results-tabs::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--text-muted);
  padding: 12px 18px;
  font-size: 0.88rem;
  font-weight: 600;
  border: none;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  margin-bottom: -2px;
}

.tab-btn:hover {
  color: var(--text-primary);
  background: rgba(0, 0, 0, 0.02);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}

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

.tab-badge {
  font-size: 0.7rem;
  font-weight: 700;
  background: var(--bg-subtle);
  color: var(--text-muted);
  padding: 2px 7px;
  border-radius: var(--radius-full);
}

.tab-btn.active .tab-badge {
  background: var(--primary-subtle);
  color: var(--primary);
}

.tab-badge-verified {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #ffffff;
}

/* Tab Panels */
.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

.content-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 28px;
  box-shadow: var(--shadow-card);
}

.content-card.no-padding {
  padding: 0;
  overflow: hidden;
}

.content-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 22px;
  flex-wrap: wrap;
  gap: 12px;
}

.content-header h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.section-desc {
  font-size: 0.86rem;
  color: var(--text-muted);
}

.items-count-pill {
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--primary-subtle);
  color: var(--primary);
  padding: 4px 12px;
  border-radius: var(--radius-full);
}

/* ==========================================================================
   Tab 1: Visual Matching Photos Grid
   ========================================================================== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.candidate-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.candidate-card:hover {
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.candidate-thumbnail {
  width: 100%;
  height: 180px;
  background: #f1f5f9;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.candidate-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.candidate-card:hover .candidate-thumbnail img {
  transform: scale(1.04);
}

.candidate-rank-pill {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(15, 23, 42, 0.8);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.candidate-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.candidate-domain {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.candidate-title {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.candidate-scores {
  margin-top: auto;
  padding-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.82rem;
}

.score-badge {
  background: var(--emerald-subtle);
  color: var(--emerald-text);
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}

.candidate-link-btn {
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.82rem;
}

.candidate-link-btn:hover {
  text-decoration: underline;
}

/* ==========================================================================
   Tab 2: News Articles List
   ========================================================================== */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.news-card {
  display: flex;
  gap: 16px;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: var(--transition);
}

.news-card:hover {
  border-color: #93c5fd;
  box-shadow: var(--shadow-card);
}

.news-card-thumb {
  width: 120px;
  height: 85px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: #f1f5f9;
}

.news-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-card-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  flex: 1;
}

.news-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.news-publisher-name {
  font-weight: 600;
  color: var(--primary);
}

.news-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
}

.news-title a {
  color: var(--text-primary);
  text-decoration: none;
}

.news-title a:hover {
  color: var(--primary);
}

/* ==========================================================================
   Tab 3: Social Media Posts
   ========================================================================== */
.social-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.social-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  transition: var(--transition);
}

.social-card:hover {
  border-color: #93c5fd;
  box-shadow: var(--shadow-card);
}

.social-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.social-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
}

.social-platform-badge {
  font-weight: 700;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.platform-facebook { background: #e8f0fe; color: #1877f2; }
.platform-twitter, .platform-x { background: #f1f5f9; color: #0f172a; }
.platform-instagram { background: #fdf2f8; color: #db2777; }
.platform-youtube { background: #fef2f2; color: #dc2626; }
.platform-linkedin { background: #e0f2fe; color: #0284c7; }
.platform-tiktok { background: #f1f5f9; color: #000000; }

.face-verify-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-full);
}

.face-verify-badge.confirmed {
  background: var(--emerald-subtle);
  color: var(--emerald-text);
  border: 1px solid rgba(16, 185, 129, 0.35);
}

.face-verify-badge.probable {
  background: var(--primary-subtle);
  color: var(--primary);
  border: 1px solid rgba(37, 99, 235, 0.3);
}

.face-verify-badge.name {
  background: var(--bg-subtle);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.face-verify-badge.diff {
  background: var(--rose-subtle);
  color: var(--rose-text);
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.social-source-name {
  font-weight: 600;
  color: var(--text-secondary);
}

.social-content-row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-top: 4px;
}

.social-thumb-box {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-md);
  overflow: hidden;
  flex-shrink: 0;
  background: #f1f5f9;
  border: 1px solid var(--border-subtle);
}

.social-thumb-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.social-details {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.social-title {
  font-size: 0.95rem;
  font-weight: 600;
}

.social-title a {
  color: var(--text-primary);
  text-decoration: none;
}

.social-title a:hover {
  color: var(--primary);
}

.social-snippet {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.social-link-btn {
  color: var(--primary);
  font-size: 0.84rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  margin-top: 4px;
}

.social-link-btn:hover {
  text-decoration: underline;
}

/* ==========================================================================
   Tab 4: Google Web Results
   ========================================================================== */
.web-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.web-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: var(--transition);
}

.web-card:hover {
  border-color: #93c5fd;
  box-shadow: var(--shadow-card);
}

.web-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
}

.web-position-pill {
  background: var(--bg-subtle);
  color: var(--text-muted);
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}

.web-domain {
  color: var(--text-muted);
}

.web-title {
  font-size: 1rem;
  font-weight: 600;
}

.web-title a {
  color: var(--primary);
  text-decoration: none;
}

.web-title a:hover {
  text-decoration: underline;
}

.web-snippet {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ==========================================================================
   Tab 5: Timeline
   ========================================================================== */
.timeline-wrapper {
  position: relative;
  padding-left: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 10px;
}

.timeline-wrapper::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: #cbd5e1;
}

.timeline-event-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  position: relative;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.timeline-event-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-card);
}

.timeline-event-card::before {
  content: "";
  position: absolute;
  left: -29px;
  top: 20px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 2px #93c5fd;
}

.timeline-event-card.ground-zero::before {
  background: var(--emerald-500);
  box-shadow: 0 0 0 2px var(--emerald-500);
  width: 14px;
  height: 14px;
  left: -30px;
}

.event-date-badge {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.event-title {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.event-snippet {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.event-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
}

.event-domain {
  color: var(--text-muted);
  font-weight: 500;
}

.event-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.badge-gz {
  background: var(--emerald-subtle);
  color: var(--emerald-text);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-recycled {
  background: var(--rose-subtle);
  color: var(--rose-text);
  border: 1px solid rgba(244, 63, 94, 0.3);
}

/* ==========================================================================
   Tab 6: D3 Evidence Graph in Light Mode
   ========================================================================== */
.map-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
  background: #f8fafc;
  flex-wrap: wrap;
  gap: 12px;
}

.map-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-circle {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot-query { background: #2563eb; }
.dot-groundzero { background: #10b981; }
.dot-match { background: #0284c7; }
.dot-domain { background: #8b5cf6; }

.map-controls {
  display: flex;
  gap: 8px;
}

.btn-ctrl {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-ctrl:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
  border-color: var(--border-dashed);
}

.graph-viewport-container {
  width: 100%;
  height: 560px;
  position: relative;
  background-color: #fafbfc;
  background-image: radial-gradient(#cbd5e1 1px, transparent 1px);
  background-size: 20px 20px;
}

#evidenceGraphSvg {
  width: 100%;
  height: 100%;
  cursor: grab;
}

#evidenceGraphSvg:active {
  cursor: grabbing;
}

.link {
  stroke: #cbd5e1;
  stroke-width: 1.5px;
}

.link.highlighted {
  stroke: var(--primary);
  stroke-width: 2.5px;
}

.node {
  cursor: pointer;
}

.node circle {
  transition: stroke-width 0.15s ease, stroke 0.15s ease;
}

.node:hover circle {
  stroke: #2563eb;
  stroke-width: 4px;
}

.node-inspector-box {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 320px;
  max-height: calc(100% - 32px);
  overflow-y: auto;
  z-index: 10;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 18px;
}

.node-inspector-box h4 {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.btn-close-box {
  float: right;
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 3px 8px;
  font-size: 0.74rem;
  cursor: pointer;
  color: var(--text-muted);
}

.btn-close-box:hover {
  background: var(--rose-subtle);
  color: var(--rose-text);
}

.inspector-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.84rem;
}

.inspector-row {
  display: flex;
  flex-direction: column;
}

.inspector-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.inspector-value {
  color: var(--text-primary);
  font-weight: 500;
  word-break: break-word;
}

/* ==========================================================================
   Tab 7: Report & Export
   ========================================================================== */
.report-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  flex-wrap: wrap;
  gap: 12px;
}

.export-btn-group {
  display: flex;
  gap: 8px;
}

.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-download:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
}

.btn-download.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
}

.btn-download.primary:hover {
  background: var(--primary-hover);
}

.report-box {
  background: #f8fafc;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
  max-height: 520px;
  overflow-y: auto;
}

.report-box pre {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.85rem;
  color: var(--text-primary);
  white-space: pre-wrap;
  line-height: 1.6;
}

/* ==========================================================================
   History Drawer
   ========================================================================== */
/* ==========================================================================
   History Drawer & Rich Search History Cards
   ========================================================================== */
.history-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 430px;
  max-width: 92vw;
  height: 100vh;
  background: var(--bg-card);
  border-left: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s;
  padding: 0;
}

/* When .open is added, slide in from right */
.history-drawer.open {
  transform: translateX(0) !important;
}

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

.drawer-header h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.history-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 20px;
}

.history-item {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  gap: 12px;
  align-items: flex-start;
  box-shadow: var(--shadow-sm);
}

.history-item:hover {
  border-color: var(--primary);
  background: var(--bg-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.history-item-thumb-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  width: 68px;
}

.history-thumb-img {
  width: 68px;
  height: 68px;
  object-fit: cover;
  border-radius: 8px;
  border: 1.5px solid #e2e8f0;
  background: #f1f5f9;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.history-status-pill {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 4px;
  border-radius: 5px;
  text-align: center;
  width: 100%;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.history-status-pill.status-confirmed {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}

.history-status-pill.status-probable {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}

.history-status-pill.status-unverified {
  background: #f8fafc;
  color: #64748b;
  border: 1px solid #e2e8f0;
}

.history-status-pill.status-alert {
  background: #fff1f2;
  color: #e11d48;
  border: 1px solid #fecdd3;
}

.history-item-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.history-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.history-name-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 2px 8px;
  border-radius: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}

.history-file-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #334155;
  font-weight: 600;
  font-size: 0.82rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}

.history-date {
  font-size: 0.72rem;
  color: #94a3b8;
  white-space: nowrap;
}

.history-claim-box {
  font-size: 0.78rem;
  color: #475569;
  line-height: 1.35;
  background: #f8fafc;
  border-left: 2.5px solid var(--primary);
  padding: 4px 8px;
  border-radius: 0 6px 6px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.history-claim-box .claim-prefix {
  font-weight: 700;
  color: #1e293b;
}

.history-headline-box {
  font-size: 0.75rem;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-item-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 3px;
  padding-top: 5px;
  border-top: 1px dashed #e2e8f0;
  font-size: 0.72rem;
}

.history-inv-id {
  color: #94a3b8;
  font-family: ui-monospace, monospace;
}

.history-load-action {
  color: var(--primary);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.history-load-action:hover {
  text-decoration: underline;
}

.history-footer-left {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.history-delete-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: transparent;
  border: 1px solid transparent;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
}

.history-delete-btn:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.25);
  transform: scale(1.1);
}

.history-delete-btn:active {
  transform: scale(0.92);
}

/* History Drag & Drop and Move Reordering */
.history-item.dragging {
  opacity: 0.35 !important;
  transform: scale(0.98) !important;
  border: 2px dashed #0284c7 !important;
  box-shadow: 0 8px 24px rgba(2, 132, 199, 0.2) !important;
  cursor: grabbing !important;
}

.history-drag-handle {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  width: 18px;
  height: 38px;
  color: #94a3b8;
  border-radius: 4px;
  cursor: grab;
  flex-shrink: 0;
  opacity: 0.55;
  transition: opacity 0.2s ease, color 0.2s ease, transform 0.15s ease;
  padding: 2px;
}

.history-item:hover .history-drag-handle {
  opacity: 1;
  color: var(--primary);
}

.history-drag-handle:active {
  cursor: grabbing;
  transform: scale(1.15);
}

.history-move-buttons {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.history-move-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 19px;
  height: 19px;
  border-radius: 4px;
  font-size: 0.65rem;
  line-height: 1;
  font-weight: 700;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
}

.history-move-btn:hover {
  background: rgba(2, 132, 199, 0.12);
  color: var(--primary);
  border-color: var(--primary);
  transform: scale(1.12);
}

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

.history-item.deleting {
  opacity: 0 !important;
  transform: scale(0.92) translateX(24px) !important;
  max-height: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-width: 0 !important;
  pointer-events: none !important;
  transition: all 0.32s cubic-bezier(0.4, 0, 0.2, 1) !important;
  overflow: hidden !important;
}

/* History Load More */
.history-load-more-wrap {
  display: flex;
  justify-content: center;
  padding: 8px 0 14px 0;
}

.history-load-more-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  font-size: 0.76rem;
  font-weight: 600;
  border-radius: 10px;
  background: #f8fafc;
  color: #2563eb;
  border: 1px solid #e2e8f0;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.history-load-more-btn:hover:not(:disabled) {
  background: #eff6ff;
  border-color: #bfdbfe;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.12);
}

.history-load-more-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.load-more-arrow {
  display: inline-block;
  font-size: 0.85rem;
  transition: transform 0.2s ease;
}

.history-load-more-btn:hover:not(:disabled) .load-more-arrow {
  transform: translateY(2px);
}

.history-end-msg {
  font-size: 0.72rem;
  color: #64748b;
  font-weight: 500;
}

/* ==========================================================================
   Delete Confirmation Modal & Notification Toasts
   ========================================================================== */
.delete-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.delete-modal-overlay.hidden {
  display: none !important;
}

.delete-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.62);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: modalFadeIn 0.2s ease-out;
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.delete-modal-card {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 390px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.04);
  animation: modalPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalPopIn {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.delete-modal-icon-wrap {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #fef2f2;
  border: 1px solid #fee2e2;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ef4444;
  flex-shrink: 0;
}

.delete-modal-title {
  color: #0f172a;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.delete-modal-desc {
  color: #64748b;
  font-size: 0.78rem;
  line-height: 1.5;
}

.delete-target-preview {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 12px;
  margin-top: 10px;
  font-size: 0.75rem;
  color: #334155;
}

.delete-target-badge {
  background: #e2e8f0;
  color: #475569;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.delete-modal-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid #f1f5f9;
}

.btn-delete-cancel {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-weight: 600;
  font-size: 0.78rem;
  padding: 8px 14px;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-delete-cancel:hover {
  background: #e2e8f0;
  color: #1e293b;
}

.btn-delete-confirm {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  border: 1px solid #dc2626;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.78rem;
  padding: 8px 16px;
  border-radius: 9px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25);
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-delete-confirm:hover:not(:disabled) {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  box-shadow: 0 6px 16px rgba(239, 68, 68, 0.35);
  transform: translateY(-1px);
}

.btn-delete-confirm:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Notification Toasts */
.toast-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.2);
  pointer-events: auto;
  opacity: 0;
  transform: translateY(12px) scale(0.95);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-pill.toast-show {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.toast-pill.toast-success {
  background: #0f172a;
  color: #34d399;
  border: 1px solid #059669;
}

.toast-pill.toast-info {
  background: #0f172a;
  color: #38bdf8;
  border: 1px solid #0284c7;
}

/* ==========================================================================
   Connection Map Explainer & Friendly Guide
   ========================================================================== */
.connection-map-explainer {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 4px solid var(--primary);
  border-radius: 10px;
  padding: 16px 20px;
  margin: 16px 16px 12px 16px;
}

.explainer-header {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.explainer-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.explainer-header h4 {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.explainer-header p {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.explainer-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.exp-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.84rem;
  color: #334155;
  line-height: 1.45;
  background: #ffffff;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.exp-badge {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #ffffff;
  flex-shrink: 0;
}

.exp-badge.blue { background: #2563eb; }
.exp-badge.green { background: #16a34a; }
.exp-badge.amber { background: #d97706; }

.empty-graph-notice {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #ffffff;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  padding: 24px 30px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  max-width: 460px;
  z-index: 10;
}

.empty-graph-notice h4 {
  color: #166534;
  font-size: 1.08rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.empty-graph-notice p {
  color: #15803d;
  font-size: 0.88rem;
  line-height: 1.5;
}

/* ==========================================================================
   Executive Investigation Dossier (Human-Readable Certificate & Report)
   ========================================================================== */
.executive-dossier {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 28px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

.dossier-cert-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 2px solid #f1f5f9;
  padding-bottom: 20px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

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

.dossier-cert-icon {
  font-size: 2.4rem;
  line-height: 1;
}

.dossier-cert-title h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.dossier-cert-title span {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.dossier-meta-badges {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.dossier-id-badge {
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
  font-family: monospace;
}

.dossier-date-badge {
  font-size: 0.78rem;
  color: #64748b;
}

.dossier-verdict-card {
  background: #f0fdf4;
  border: 1.5px solid #86efac;
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 24px;
}

.dossier-verdict-card.public-match {
  background: #eff6ff;
  border-color: #93c5fd;
}

.verdict-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  flex-wrap: wrap;
  gap: 10px;
}

.verdict-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #166534;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
}

.verdict-status-pill.public {
  background: #1e40af;
}

.verdict-confidence-badge {
  font-size: 0.85rem;
  font-weight: 700;
  color: #15803d;
}

.verdict-confidence-badge.public {
  color: #1d4ed8;
}

.verdict-headline-text {
  font-size: 1.15rem;
  font-weight: 700;
  color: #166534;
  margin-bottom: 8px;
}

.verdict-headline-text.public {
  color: #1e3a8a;
}

.verdict-summary-text {
  font-size: 0.92rem;
  color: #334155;
  line-height: 1.6;
}

.dossier-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.dossier-grid-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px;
}

.dgc-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #1e293b;
}

.dgc-val {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 4px;
}

.dgc-desc {
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.45;
}

/* Executive Dossier - Person Intelligence Card & Narrative */
.dossier-person-intel-card {
  padding: 22px;
  border-radius: 16px;
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border-subtle, #e2e8f0);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  margin: 20px 0;
}

/* Quick Facts Table */
.dossier-quick-table-wrap {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid var(--border-subtle, #e2e8f0);
  margin-bottom: 16px;
  background: var(--bg-card, #ffffff);
}

.dossier-quick-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  text-align: left;
}

.dossier-quick-table tr {
  border-bottom: 1px solid var(--border-subtle, #f1f5f9);
}

.dossier-quick-table tr:last-child {
  border-bottom: none;
}

.dossier-quick-table td.label-col {
  padding: 10px 16px;
  width: 25%;
  min-width: 140px;
  font-weight: 600;
  color: var(--text-secondary, #64748b);
  background: var(--bg-subtle, #f8fafc);
  border-right: 1px solid var(--border-subtle, #e2e8f0);
  white-space: nowrap;
}

.dossier-quick-table td.val-col {
  padding: 10px 16px;
  font-weight: 500;
  color: var(--text-primary, #0f172a);
  background: var(--bg-card, #ffffff);
}

/* Structured Narrative Cards */
.dossier-bio-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dossier-bio-card {
  padding: 16px 18px;
  border-radius: 12px;
  background: var(--bg-subtle, #f8fafc);
  border: 1px solid var(--border-subtle, #e2e8f0);
  border-left: 4px solid var(--primary, #0284c7);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.dossier-bio-card .bio-card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary, #0284c7);
  margin-bottom: 8px;
}

.dossier-bio-card p {
  font-size: 0.88rem;
  line-height: 1.8;
  color: var(--text-secondary, #334155);
  margin: 0;
  text-align: justify;
}

.dossier-bio-card strong {
  color: var(--text-primary, #0f172a);
  font-weight: 700;
}

.dossier-section {
  border-top: 1px solid #f1f5f9;
  padding-top: 18px;
  margin-top: 18px;
}

.dossier-section h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 10px;
}

.dossier-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dossier-tag {
  background: #f1f5f9;
  color: #334155;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 6px;
}

/* Print Styling */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  .app-header, .search-card, .pipeline-card, .results-tabs, .tabs-nav-container, .export-btn-group, .history-drawer, .map-toolbar, .map-controls {
    display: none !important;
  }
  #reportTab {
    display: block !important;
  }
  .tab-pane:not(#reportTab) {
    display: none !important;
  }
  .executive-dossier {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }
}

/* ==========================================================================
   Tab: AI Person Intelligence Dossier & Cross-Check Styling
   ========================================================================== */
.intel-header-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(135deg, #1e1b4b 0%, #312e81 50%, #4338ca 100%);
  color: #ffffff;
  padding: 28px 32px;
  border-radius: var(--radius-lg, 12px);
  margin-bottom: 22px;
  box-shadow: 0 10px 25px -5px rgba(49, 46, 129, 0.35);
  flex-wrap: wrap;
  gap: 20px;
}

.intel-id-badge-col {
  flex: 1;
  min-width: 280px;
}

.intel-badge-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.intel-person-name {
  font-size: 1.85rem;
  font-weight: 800;
  margin: 0 0 10px 0;
  line-height: 1.25;
  color: #ffffff;
}

.intel-person-name span {
  color: #a5b4fc;
}

.intel-alias-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  flex-wrap: wrap;
}

.intel-label {
  color: #c7d2fe;
  font-weight: 600;
}

.intel-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.intel-tag-item {
  background: rgba(255, 255, 255, 0.12);
  color: #e0e7ff;
  padding: 2px 9px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-family: monospace;
}

.intel-score-col {
  display: flex;
  align-items: center;
  justify-content: center;
}

.intel-score-circle {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.18) 0%, rgba(255,255,255,0.06) 100%);
  border: 3px solid rgba(255, 255, 255, 0.35);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.intel-score-number {
  font-size: 1.95rem;
  font-weight: 900;
  color: #38bdf8;
  line-height: 1;
}

.intel-score-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #c7d2fe;
  margin-top: 4px;
  text-align: center;
}

/* Notice Banner */
.intel-notice-banner {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-left: 5px solid #4f46e5;
  padding: 14px 18px;
  border-radius: 8px;
  margin-bottom: 26px;
  font-size: 0.88rem;
  color: #334155;
  line-height: 1.5;
}

.intel-notice-banner .notice-icon {
  font-size: 1.3rem;
  line-height: 1;
}

/* Sections */
.intel-section {
  margin-bottom: 28px;
}

.intel-section-title h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 14px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Structured Key Table */
.intel-table-responsive {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  background: #ffffff;
}

.intel-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.intel-table th {
  background: #f1f5f9;
  color: #475569;
  font-weight: 700;
  padding: 13px 16px;
  border-bottom: 1px solid #cbd5e1;
  text-transform: uppercase;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
}

.intel-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #f1f5f9;
  color: #1e293b;
  vertical-align: middle;
}

.intel-table tr:hover td {
  background: #f8fafc;
}

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

.intel-cat-cell {
  font-weight: 600;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 8px;
}

.intel-info-cell {
  font-weight: 500;
}

.intel-info-cell.not-found {
  color: #94a3b8;
  font-style: italic;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
}

.status-verified {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.status-possible {
  background: #e0e7ff;
  color: #3730a3;
  border: 1px solid #a5b4fc;
}

.status-insufficient {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #cbd5e1;
}

/* Clean AI Research Summary Box */
.intel-summary-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 5px solid #4f46e5;
  border-radius: 12px;
  padding: 24px 28px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.04);
}

.intel-summary-paragraphs {
  margin-bottom: 18px;
}

.intel-summary-para.justified,
.intel-summary-para {
  font-size: 0.95rem;
  color: var(--text-secondary, #cbd5e1);
  line-height: 1.8;
  margin: 0 0 16px 0;
  font-weight: 400;
  text-align: justify;
  text-justify: inter-word;
}

.intel-summary-para.justified:last-child,
.intel-summary-para:last-child {
  margin-bottom: 0;
}

.intel-summary-para strong,
.intel-summary-paragraphs strong,
#piResearchSummaryContainer strong {
  color: var(--text-primary, #ffffff);
  font-weight: 700;
}

.intel-summary-footer {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

.verify-badge-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.verify-shield-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ecfdf5;
  color: #047857;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid #a7f3d0;
}

.verify-note-tag {
  font-size: 0.82rem;
  color: #64748b;
}

/* Reference Sources Section */
.intel-reference-section {
  width: 100%;
  padding-top: 10px;
  border-top: 1px dashed #e2e8f0;
}

.intel-ref-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: #334155;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.intel-reference-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ref-source-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #1e293b;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.ref-source-chip:hover {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(59, 130, 246, 0.18);
}

.ref-source-chip .ref-icon {
  font-size: 0.9rem;
}

.ref-source-chip .ref-verified-check {
  color: #10b981;
  font-weight: 800;
}

.ref-empty-hint {
  font-size: 0.84rem;
  color: #94a3b8;
  font-style: italic;
}

/* Language Switcher (বাংলা / English) */
.lang-switch-wrapper {
  display: inline-flex;
  align-items: center;
  position: relative;
}

.lang-toggle-bar {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 24px;
  padding: 3px 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: all 0.2s ease;
}

.lang-toggle-bar:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 6px rgba(59, 130, 246, 0.15);
}

.lang-globe-icon {
  font-size: 0.95rem;
  margin-right: 2px;
  display: inline-flex;
  align-items: center;
}

.lang-toggle-btn {
  background: transparent;
  border: none;
  color: #475569;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1.25;
}

.lang-toggle-btn:hover {
  color: #1e293b;
  background: #f1f5f9;
}

.lang-toggle-btn.active {
  background: #2563eb;
  color: #ffffff !important;
  font-weight: 700;
  box-shadow: 0 1px 4px rgba(37, 99, 235, 0.35);
}

.lang-toggle-sep {
  color: #cbd5e1;
  font-size: 0.75rem;
  user-select: none;
}

/* Hide top Google Translate banner if injected */
.goog-te-banner-frame.skiptranslate,
iframe.goog-te-banner-frame {
  display: none !important;
}

body {
  top: 0px !important;
}

.goog-tooltip, .goog-tooltip:hover {
  display: none !important;
}

.goog-text-highlight {
  background-color: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Verified Findings Grid */
.verified-findings-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.finding-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #10b981;
  padding: 16px 20px;
  border-radius: 8px;
  gap: 16px;
  flex-wrap: wrap;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

.finding-claim-col {
  flex: 1;
  min-width: 250px;
}

.finding-claim-text {
  font-size: 0.95rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0 0 8px 0;
  line-height: 1.45;
}

.finding-sources-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.finding-source-badge {
  font-size: 0.75rem;
  background: #f1f5f9;
  color: #334155;
  padding: 3px 9px;
  border-radius: 4px;
  font-weight: 600;
  border: 1px solid #e2e8f0;
}

/* Unknowns Minimal Footnote */
.intel-unknowns-card {
  margin-top: 24px;
  padding: 16px 20px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
}

.unknowns-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 8px;
}

.unknowns-list {
  margin: 0;
  padding-left: 20px;
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.5;
}

.unknowns-list li {
  margin-bottom: 4px;
}

/* Skills, Contacts & Portfolio Enhancements */
.intel-pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.intel-skill-tag {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
}

.intel-contact-link {
  color: #2563eb;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.intel-contact-link:hover {
  text-decoration: underline;
  color: #1d4ed8;
}

.intel-portfolios-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* ==========================================================================
   Reverse Image Search — Dual Theme Engine
   ========================================================================== */

/* ==========================================================================
   App Footer — Dark Mode (default)
   ========================================================================== */
.app-footer {
  margin-top: auto;
  border-top: 1px solid rgba(51, 65, 85, 0.7);
  background: rgba(2, 6, 23, 0.9);
  color: #64748b; /* slate-500 */
}

.footer-brand-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #94a3b8; /* slate-400 */
  font-weight: 500;
}

.footer-brand-text .font-bold {
  color: #cbd5e1; /* slate-300 */
}

.footer-sep {
  color: #475569;
}

.footer-dev-text {
  color: #64748b;
  font-weight: 500;
}

.footer-dev-link {
  color: #38bdf8; /* sky-400 */
  font-weight: 700;
  text-decoration: none;
  margin-left: 4px;
  transition: color 0.2s ease;
}

.footer-dev-link:hover {
  color: #7dd3fc; /* sky-300 */
  text-decoration: underline;
}

.footer-copy {
  color: #475569; /* slate-600 */
}

.footer-cleofan-link {
  color: #38bdf8;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-cleofan-link:hover {
  color: #7dd3fc;
  text-decoration: underline;
}

html.light .footer-cleofan-link {
  color: #0284c7;
}

html.light .footer-cleofan-link:hover {
  color: #0369a1;
}

/* ==========================================================================
   Theme Toggle Button — Dark Mode
   ========================================================================== */
.theme-toggle-btn {
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(71, 85, 105, 0.6);
  color: #cbd5e1;
  cursor: pointer;
}

.theme-toggle-btn:hover {
  background: rgba(51, 65, 85, 0.9);
  border-color: rgba(100, 116, 139, 0.8);
  color: #f1f5f9;
}

/* ==========================================================================
   Btn Ghost — Dark Mode
   ========================================================================== */
.btn-ghost {
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(71, 85, 105, 0.6);
  color: #94a3b8;
  cursor: pointer;
}

.btn-ghost:hover {
  background: rgba(51, 65, 85, 0.9);
  color: #e2e8f0;
  border-color: rgba(100, 116, 139, 0.8);
}

/* ==========================================================================
   Content Cards — Dark Mode
   ========================================================================== */
.content-card,
.summary-card {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(51, 65, 85, 0.8);
}

.content-card h3,
.summary-card h2 {
  color: #f1f5f9;
}

/* ==========================================================================
   Tabs — Dark Mode
   ========================================================================== */
.tabs-nav-container {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(51, 65, 85, 0.8);
}

.tab-btn {
  color: #64748b;
}

.tab-btn:hover {
  color: #cbd5e1;
}

.tab-btn.active {
  background: rgba(30, 41, 59, 0.9);
  color: #38bdf8;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Stat Cards — Dark Mode
   ========================================================================== */
.stat-card {
  background: rgba(2, 6, 23, 0.7);
  border-color: rgba(51, 65, 85, 0.6);
}

.stat-label {
  color: #64748b;
}

.stat-value {
  color: #f1f5f9;
}

/* ==========================================================================
   Forms — Dark Mode
   ========================================================================== */
.form-control {
  background: rgba(2, 6, 23, 0.8);
  border-color: rgba(71, 85, 105, 0.7);
  color: #f1f5f9;
}

.form-control:focus {
  border-color: #38bdf8;
  outline: none;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}

.form-control::placeholder {
  color: #475569;
}



/* ==========================================================================
   Dropzone Laser Scanning Beam
   ========================================================================== */
@keyframes laserScanAnimation {
  0% { top: 0%; opacity: 0; }
  15% { opacity: 0.9; }
  50% { opacity: 1; }
  85% { opacity: 0.9; }
  100% { top: 100%; opacity: 0; }
}

.dropzone.scanning .scanning-laser {
  opacity: 1 !important;
  animation: laserScanAnimation 2.2s ease-in-out infinite;
}

/* ==========================================================================
   CleoFan Logo Adaptive Filters
   ========================================================================== */
.cleofan-logo-img {
  transition: filter 0.3s ease;
}

html.light .cleofan-logo-img {
  /* Slightly darken for light backgrounds while keeping shape recognizable */
  filter: brightness(0.85) contrast(1.1) saturate(0.9);
}

html.dark .cleofan-logo-img,
:root .cleofan-logo-img {
  filter: drop-shadow(0 2px 8px rgba(56, 189, 248, 0.2));
}

/* ==========================================================================
   Corner Bracket Scanner Aesthetic (Dropzone)
   ========================================================================== */
.corner-bracket {
  position: absolute;
  width: 14px;
  height: 14px;
  pointer-events: none;
  transition: all 0.25s ease;
  border-color: rgba(56, 189, 248, 0.6);
  z-index: 5;
}

.dropzone:hover .corner-bracket {
  border-color: #38bdf8;
  width: 18px;
  height: 18px;
  filter: drop-shadow(0 0 5px rgba(56, 189, 248, 0.7));
}

.bracket-tl { top: -1px; left: -1px; border-top: 2px solid; border-left: 2px solid; border-top-left-radius: 10px; }
.bracket-tr { top: -1px; right: -1px; border-top: 2px solid; border-right: 2px solid; border-top-right-radius: 10px; }
.bracket-bl { bottom: -1px; left: -1px; border-bottom: 2px solid; border-left: 2px solid; border-bottom-left-radius: 10px; }
.bracket-br { bottom: -1px; right: -1px; border-bottom: 2px solid; border-right: 2px solid; border-bottom-right-radius: 10px; }

.scanner-grid-bg {
  background-image: radial-gradient(rgba(56, 189, 248, 0.1) 1px, transparent 1px);
  background-size: 22px 22px;
}

/* ==========================================================================
   LIGHT MODE — html.light overrides
   ========================================================================== */
html.light {
  color-scheme: light;
}

html.light body {
  background-color: #f8fafc;
  color: #334155;
}

/* ---- Header brand text fixes ---- */
/* App name and subtitle in header */
html.light .app-header span.font-bold,
html.light .app-header span[class*="text-slate-100"] {
  color: #0f172a !important;
}

html.light .app-header span[class*="text-slate-500"] {
  color: #64748b !important;
}

/* Separator line in header */
html.light .app-header div[class*="bg-slate-700"] {
  background-color: #cbd5e1 !important;
}

/* Engine status pill in header */
html.light .app-header div[class*="bg-slate-900"],
html.light .app-header div[class*="border-slate-800"] {
  background-color: #f1f5f9 !important;
  border-color: #e2e8f0 !important;
}

/* ---- Header ---- */
html.light .app-header {
  background: rgba(255, 255, 255, 0.96);
  border-bottom-color: #e2e8f0;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06);
}

/* Brand name */
html.light .brand-name {
  color: #0f172a;
}

/* Brand subtitle */
html.light .brand-sub {
  color: #94a3b8;
}

/* Header separator */
html.light .header-sep {
  background: #e2e8f0;
}

/* Engine status pill */
html.light .header-status-pill {
  background: #f1f5f9;
  border-color: #e2e8f0;
}

html.light .status-label {
  color: #64748b;
}

/* Feature pills */
html.light .feature-pill {
  color: #475569;
  background: #f1f5f9;
  border-color: #e2e8f0;
}

html.light .feature-pill:hover {
  color: #0f172a;
  background: #e2e8f0;
  border-color: #94a3b8;
}

/* Corner brackets in light mode */
html.light .corner-bracket {
  border-color: rgba(37, 99, 235, 0.4);
}

html.light .dropzone:hover .corner-bracket {
  border-color: #2563eb;
  filter: drop-shadow(0 0 4px rgba(37, 99, 235, 0.4));
}

/* OPTIONAL badge — override dark inline Tailwind classes */
html.light .form-group span[class*="bg-slate-800"] {
  background: #f1f5f9 !important;
  color: #64748b !important;
  border-color: #e2e8f0 !important;
}

/* Form helper text (emoji + tip text under inputs) */
html.light .form-group p {
  color: #64748b;
}


html.light .theme-toggle-btn {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) !important;
}

html.light .theme-toggle-btn:hover {
  background: #f1f5f9 !important;
}

html.light .btn-ghost {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

html.light .btn-ghost:hover {
  background: #f1f5f9 !important;
}

html.light .search-card,
html.light .content-card,
html.light .summary-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.05), 0 8px 10px -6px rgba(15, 23, 42, 0.02) !important;
}

html.light .search-card h1,
html.light .search-card h2,
html.light .summary-card h2,
html.light .content-card h1,
html.light .content-card h2,
html.light .content-card h3,
html.light .content-card h4,
html.light .content-card h5 {
  color: #0f172a !important;
}

/* Content card inner text in light mode */
html.light .content-card p,
html.light .content-card .tab-pane-subtitle {
  color: #64748b !important;
}

/* Tab pane card inner border separators */
html.light .content-card [class*="border-b"] {
  border-color: #e2e8f0 !important;
}

/* Items count pills in light mode */
html.light .items-count-pill {
  background: #eff6ff !important;
  color: #2563eb !important;
  border-color: #bfdbfe !important;
}



html.light .dropzone {
  background: #f8fafc !important;
  border-color: #cbd5e1 !important;
}

html.light .dropzone:hover {
  background: #f1f5f9 !important;
  border-color: #2563eb !important;
}

html.light .drop-title {
  color: #0f172a !important;
}

html.light .drop-subtitle,
html.light .drop-hint {
  color: #64748b !important;
}

html.light .drop-hint {
  background: #f1f5f9 !important;
  border-color: #e2e8f0 !important;
}

html.light .btn-sample {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

html.light .btn-sample:hover {
  background: #f1f5f9 !important;
  border-color: #94a3b8 !important;
}

html.light .form-group label {
  color: #334155 !important;
}

html.light .form-control {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
}

html.light .form-control::placeholder {
  color: #94a3b8 !important;
}

html.light .form-control:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15) !important;
}

html.light .stat-card {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

html.light .stat-label {
  color: #64748b !important;
}

html.light .stat-value {
  color: #0f172a !important;
}

html.light .tabs-nav-container {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}


html.light .tab-btn {
  color: #64748b !important;
}

html.light .tab-btn:hover {
  color: #0f172a !important;
  background: rgba(255, 255, 255, 0.6) !important;
}

html.light .tab-btn.active {
  background: #ffffff !important;
  color: #2563eb !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06) !important;
}

html.light .tab-badge {
  background: #e2e8f0 !important;
  color: #475569 !important;
}

html.light .tab-btn.active .tab-badge {
  background: #eff6ff !important;
  color: #2563eb !important;
}

html.light .connection-map-explainer {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

html.light .connection-map-explainer h4 {
  color: #0f172a !important;
}

html.light .connection-map-explainer span strong {
  color: #1e293b !important;
}

html.light .graph-viewport-container {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

html.light .node-inspector-box {
  background: rgba(255, 255, 255, 0.96) !important;
  border-color: #cbd5e1 !important;
  color: #1e293b !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1) !important;
}

/* ==========================================================================
   LIGHT MODE — Person Intelligence Tab (Subject Profile, Table, Synthesis)
   ========================================================================== */
html.light .person-intel-clean-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05) !important;
}

/* Header Banner */
html.light .intel-header-banner {
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%) !important;
  border: 1px solid #bfdbfe !important;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.04) !important;
}

html.light .intel-badge-title {
  color: #0284c7 !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em !important;
}

html.light #piPersonTitle,
html.light .intel-person-name {
  color: #0f172a !important;
  font-weight: 800 !important;
}

html.light #piPersonName,
html.light .intel-person-name span {
  color: #2563eb !important;
  font-weight: 800 !important;
}

html.light .intel-alias-row {
  color: #64748b !important;
}

html.light .intel-label {
  color: #475569 !important;
  font-weight: 600 !important;
}

html.light #piAliasesList {
  color: #1e293b !important;
}

html.light .intel-tag-item {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #1d4ed8 !important;
  font-weight: 600 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
}

/* Confidence Score Badge */
html.light .intel-score-circle {
  background: #ffffff !important;
  border: 2.5px solid #38bdf8 !important;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.16), inset 0 0 12px rgba(14, 165, 233, 0.05) !important;
}

html.light #piIdentityConfidenceVal,
html.light .intel-score-number {
  color: #0284c7 !important;
  font-weight: 900 !important;
}

html.light .intel-score-label {
  color: #64748b !important;
  font-weight: 700 !important;
}

/* Section Title */
html.light .intel-section-title h4 {
  color: #0f172a !important;
  font-weight: 700 !important;
}

/* Structured Key Table */
html.light .intel-table-responsive {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04) !important;
  overflow: hidden !important;
}

html.light .intel-table {
  background: #ffffff !important;
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

html.light .intel-table thead {
  background: #f8fafc !important;
}

html.light .intel-table th {
  background: #f8fafc !important;
  color: #475569 !important;
  font-weight: 700 !important;
  border-bottom: 1px solid #e2e8f0 !important;
  padding: 12px 16px !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.05em !important;
  text-transform: uppercase !important;
}

html.light #piKeyTableBody,
html.light .intel-table tbody {
  background: #ffffff !important;
  color: #1e293b !important;
}

html.light .intel-table tbody tr {
  background: #ffffff !important;
  border-bottom: 1px solid #f1f5f9 !important;
  border-color: #f1f5f9 !important;
  transition: background-color 0.15s ease !important;
}

html.light .intel-table tbody tr:hover td {
  background: #f8fafc !important;
}

html.light .intel-table td,
html.light .intel-table tbody td {
  background: #ffffff !important;
  color: #1e293b !important;
  border-bottom: 1px solid #f1f5f9 !important;
  padding: 13px 16px !important;
  vertical-align: middle !important;
}

html.light .intel-table tbody tr:last-child td {
  border-bottom: none !important;
}

html.light .intel-cat-cell {
  color: #334155 !important;
  font-weight: 600 !important;
}

html.light .intel-info-cell {
  color: #0f172a !important;
  font-weight: 500 !important;
}

html.light .intel-info-cell.not-found {
  color: #64748b !important;
  font-style: italic !important;
}

html.light .intel-table td strong {
  color: #0f172a !important;
  font-weight: 700 !important;
}

html.light .intel-contact-link {
  color: #2563eb !important;
  text-decoration: none !important;
  font-weight: 600 !important;
}

html.light .intel-contact-link:hover {
  color: #1d4ed8 !important;
  text-decoration: underline !important;
}

html.light .intel-skill-tag {
  background: #eff6ff !important;
  border: 1px solid #bfdbfe !important;
  color: #1d4ed8 !important;
  font-weight: 600 !important;
  padding: 3px 10px !important;
  border-radius: 6px !important;
}

/* Status Badges */
html.light .status-badge {
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.03em !important;
  border-radius: 9999px !important;
  padding: 4px 11px !important;
  text-transform: uppercase !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
}

html.light .status-verified {
  background: #ecfdf5 !important;
  color: #047857 !important;
  border: 1px solid #a7f3d0 !important;
}

html.light .status-possible {
  background: #eef2ff !important;
  color: #4338ca !important;
  border: 1px solid #c7d2fe !important;
}

html.light .status-insufficient {
  background: #f1f5f9 !important;
  color: #64748b !important;
  border: 1px solid #cbd5e1 !important;
}

/* AI Research & Multi-Model Synthesis */
html.light .intel-summary-box {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-left: 4px solid #2563eb !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04) !important;
  border-radius: 12px !important;
  padding: 22px 24px !important;
}

html.light #piResearchSummaryText,
html.light .intel-summary-para,
html.light .intel-summary-para.justified,
html.light #piResearchSummaryContainer p {
  color: #334155 !important;
  font-size: 0.92rem !important;
  line-height: 1.75 !important;
}

html.light .intel-summary-para strong,
html.light .intel-summary-para.justified strong,
html.light .intel-summary-paragraphs strong,
html.light #piResearchSummaryContainer strong {
  color: #0f172a !important;
  font-weight: 700 !important;
}

html.light .intel-summary-footer {
  border-top: 1px solid #f1f5f9 !important;
}

html.light .dossier-person-intel-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05) !important;
}

html.light .dossier-quick-table-wrap {
  border-color: #e2e8f0 !important;
  background: #ffffff !important;
}

html.light .dossier-quick-table tr {
  border-bottom-color: #f1f5f9 !important;
}

html.light .dossier-quick-table td.label-col {
  background: #f8fafc !important;
  color: #64748b !important;
  border-right-color: #e2e8f0 !important;
}

html.light .dossier-quick-table td.val-col {
  background: #ffffff !important;
  color: #0f172a !important;
}

html.light .dossier-bio-card {
  background: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
  border-left: 4px solid #0284c7 !important;
}

html.light .dossier-bio-card .bio-card-title {
  color: #0369a1 !important;
}

html.light .dossier-bio-card p {
  color: #334155 !important;
}

html.light .dossier-bio-card strong {
  color: #0f172a !important;
  font-weight: 700 !important;
}

html.light .verify-shield-tag {
  background: #ecfdf5 !important;
  color: #047857 !important;
  border: 1px solid #a7f3d0 !important;
  font-weight: 600 !important;
}

html.light .verify-note-tag {
  color: #64748b !important;
  font-size: 0.8rem !important;
}

html.light .intel-reference-section {
  border-top: 1px dashed #e2e8f0 !important;
}

html.light .intel-ref-title {
  color: #475569 !important;
  font-weight: 600 !important;
}

html.light .ref-source-chip {
  background: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  color: #1e293b !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
}

html.light .ref-source-chip:hover {
  background: #eff6ff !important;
  border-color: #3b82f6 !important;
  color: #1d4ed8 !important;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.12) !important;
}

html.light .ref-empty-hint {
  color: #94a3b8 !important;
}

/* Corroborated Public Facts */
html.light .finding-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-left: 4px solid #10b981 !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04) !important;
  border-radius: 10px !important;
}

html.light .finding-claim-text {
  color: #0f172a !important;
  font-weight: 600 !important;
}

html.light .finding-source-badge {
  background: #f1f5f9 !important;
  color: #475569 !important;
  border: 1px solid #e2e8f0 !important;
  font-weight: 600 !important;
}

/* Insufficient Evidence Notice */
html.light .intel-unknowns-card {
  background: #fffbeb !important;
  border: 1px solid #fef3c7 !important;
  border-radius: 10px !important;
}

html.light .unknowns-title {
  color: #b45309 !important;
  font-weight: 700 !important;
}

html.light .unknowns-list {
  color: #78350f !important;
}

html.light .unknowns-list li {
  color: #92400e !important;
}

/* ==========================================================================
   LIGHT MODE — Polished Components & History Overrides
   ========================================================================== */
html.light .history-drawer {
  background: #ffffff !important;
  border-left: 1px solid #e2e8f0 !important;
  box-shadow: -10px 0 30px rgba(15, 23, 42, 0.08) !important;
}

html.light .drawer-header {
  border-bottom: 1px solid #e2e8f0 !important;
}

html.light .drawer-header h3 {
  color: #0f172a !important;
}

html.light .history-drawer .btn-close-box {
  color: #64748b !important;
  background: transparent !important;
}

html.light .history-drawer .btn-close-box:hover {
  color: #0f172a !important;
  background: #f1f5f9 !important;
}

html.light .history-empty {
  color: #64748b !important;
}

html.light .history-item {
  background: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
  color: #0f172a !important;
}

html.light .history-item:hover {
  background: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08) !important;
}

html.light .history-thumb-img {
  border: 1.5px solid #e2e8f0 !important;
  background: #f1f5f9 !important;
}

html.light .history-name-pill {
  background: #eff6ff !important;
  color: #1d4ed8 !important;
  border: 1px solid #bfdbfe !important;
}

html.light .history-file-tag {
  color: #334155 !important;
}

html.light .history-date {
  color: #94a3b8 !important;
}

html.light .history-claim-box {
  background: #f1f5f9 !important;
  border-left: 2.5px solid #2563eb !important;
  color: #475569 !important;
}

html.light .history-claim-box .claim-prefix {
  color: #0f172a !important;
}

html.light .history-headline-box {
  color: #64748b !important;
}

html.light .history-item-footer {
  border-top: 1px dashed #e2e8f0 !important;
}

html.light .history-inv-id {
  color: #94a3b8 !important;
}

html.light .history-load-action {
  color: #2563eb !important;
}

html.light .history-status-pill.status-confirmed {
  background: #ecfdf5 !important;
  color: #059669 !important;
  border: 1px solid #a7f3d0 !important;
}

html.light .history-status-pill.status-probable {
  background: #eff6ff !important;
  color: #2563eb !important;
  border: 1px solid #bfdbfe !important;
}

html.light .history-status-pill.status-unverified {
  background: #f8fafc !important;
  color: #64748b !important;
  border: 1px solid #e2e8f0 !important;
}

html.light .history-status-pill.status-alert {
  background: #fff1f2 !important;
  color: #e11d48 !important;
  border: 1px solid #fecdd3 !important;
}

html.light .history-drag-handle {
  color: #94a3b8 !important;
}

html.light .history-item:hover .history-drag-handle {
  color: #2563eb !important;
}

html.light .history-move-btn {
  border-color: #e2e8f0 !important;
  color: #64748b !important;
  background: #ffffff !important;
}

html.light .history-move-btn:hover {
  background: #eff6ff !important;
  color: #2563eb !important;
  border-color: #bfdbfe !important;
}

html.light .history-item.dragging {
  border: 2px dashed #2563eb !important;
  background: #f0f7ff !important;
}

/* Light mode cards in loaded data */
html.light .candidate-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .candidate-thumbnail {
  background: #f1f5f9 !important;
}

html.light .candidate-title {
  color: #0f172a !important;
}

html.light .candidate-domain {
  color: #2563eb !important;
}

html.light .candidate-scores {
  color: #64748b !important;
}

html.light .score-badge {
  background: #eff6ff !important;
  color: #2563eb !important;
  border-color: #bfdbfe !important;
}

html.light .candidate-link-btn {
  background: #f1f5f9 !important;
  color: #2563eb !important;
  border: 1px solid #cbd5e1 !important;
}

html.light .news-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .news-card:hover {
  background: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08) !important;
}

html.light .news-card-thumb {
  background: #f1f5f9 !important;
}

html.light .news-title a {
  color: #0f172a !important;
}

html.light .news-publisher-name {
  color: #2563eb !important;
}

html.light .social-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .social-card:hover {
  background: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08) !important;
}

html.light .social-thumb-box {
  background: #f1f5f9 !important;
  border-color: #e2e8f0 !important;
}

html.light .social-details h4 a {
  color: #0f172a !important;
}

html.light .web-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .web-card:hover {
  background: #ffffff !important;
  border-color: #2563eb !important;
}

html.light .web-title a {
  color: #2563eb !important;
}

html.light .web-position-pill {
  background: #f1f5f9 !important;
  color: #64748b !important;
  border: 1px solid #e2e8f0 !important;
}

html.light .timeline-wrapper::before {
  background: #cbd5e1 !important;
}

html.light .timeline-event-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .event-title {
  color: #0f172a !important;
}

html.light .event-snippet {
  color: #64748b !important;
}


html.light .executive-dossier {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  color: #334155 !important;
}

html.light .dossier-cert-header {
  border-bottom-color: #e2e8f0 !important;
}

html.light .dossier-cert-title h3 {
  color: #0f172a !important;
}

html.light .dossier-cert-title span {
  color: #64748b !important;
}

html.light .dossier-grid-card {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

html.light .dgc-header {
  color: #0f172a !important;
}

html.light .dossier-section {
  border-top-color: #e2e8f0 !important;
}

html.light .dossier-section h4 {
  color: #0f172a !important;
}

html.light .dossier-tag {
  background: #f1f5f9 !important;
  color: #334155 !important;
  border: 1px solid #e2e8f0 !important;
}

html.light .app-footer {
  background: #ffffff !important;
  border-top-color: #e2e8f0 !important;
}

html.light .app-footer span,
html.light .app-footer a {
  color: #64748b !important;
}

html.light .app-footer a:hover {
  color: #2563eb !important;
}

/* ==========================================================================
   CleoFan Logo Theme Adaptive Filters
   ========================================================================== */
.cleofan-logo-img {
  transition: filter 0.3s ease;
}

html.light .cleofan-logo-img {
  /* Inverts light text to sharp dark slate while preserving blue crest */
  filter: brightness(0.12) contrast(1.2);
}

html.dark .cleofan-logo-img {
  filter: drop-shadow(0 2px 10px rgba(6, 182, 212, 0.25));
}

/* ==========================================================================
   Cyber Scanner & Radar Bracket Aesthetics
   ========================================================================== */
.corner-bracket {
  position: absolute;
  width: 14px;
  height: 14px;
  pointer-events: none;
  transition: all 0.25s ease;
  border-color: rgba(6, 182, 212, 0.7);
  z-index: 5;
}

.dropzone:hover .corner-bracket {
  border-color: #00f0ff;
  width: 18px;
  height: 18px;
  filter: drop-shadow(0 0 6px rgba(0, 240, 255, 0.8));
}

.bracket-tl { top: -1px; left: -1px; border-top: 2.5px solid; border-left: 2.5px solid; border-top-left-radius: 14px; }
.bracket-tr { top: -1px; right: -1px; border-top: 2.5px solid; border-right: 2.5px solid; border-top-right-radius: 14px; }
.bracket-bl { bottom: -1px; left: -1px; border-bottom: 2.5px solid; border-left: 2.5px solid; border-bottom-left-radius: 14px; }
.bracket-br { bottom: -1px; right: -1px; border-bottom: 2.5px solid; border-right: 2.5px solid; border-bottom-right-radius: 14px; }

.scanner-grid-bg {
  background-image: radial-gradient(rgba(6, 182, 212, 0.12) 1.2px, transparent 1.2px);
  background-size: 20px 20px;
}

html.light .scanner-grid-bg {
  background-image: radial-gradient(rgba(37, 99, 235, 0.1) 1.2px, transparent 1.2px);
}

/* Polished Light Mode Hero Card */
html.light .search-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.06), 0 4px 12px -2px rgba(15, 23, 42, 0.04) !important;
}

html.light .search-card h1 {
  color: #0f172a !important;
}

html.light .search-card p {
  color: #475569 !important;
}

html.light .dropzone {
  background: #f8fafc !important;
  border-color: #cbd5e1 !important;
}

html.light .dropzone:hover {
  background: #f1f5f9 !important;
  border-color: #2563eb !important;
}

html.light .drop-title {
  color: #0f172a !important;
}

html.light .drop-subtitle {
  color: #64748b !important;
}

html.light .drop-hint {
  background: #ffffff !important;
  color: #64748b !important;
  border-color: #e2e8f0 !important;
}

html.light .upload-icon-circle {
  background: #eff6ff !important;
  border-color: #bfdbfe !important;
  color: #2563eb !important;
}

html.light .btn-sample {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

html.light .btn-sample:hover {
  background: #f8fafc !important;
  border-color: #2563eb !important;
  color: #2563eb !important;
}

/* ==========================================================================
   DARK MODE — Full UI, Results Data & History System Overrides (html.dark)
   ========================================================================== */
html.dark {
  color-scheme: dark;
}

html.dark body {
  background-color: #020617 !important;
  color: #cbd5e1 !important;
}

/* Header in Dark Mode */
html.dark .app-header {
  background: rgba(15, 23, 42, 0.95) !important;
  border-bottom: 1px solid #1e293b !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4) !important;
}

html.dark .brand-name {
  color: #f1f5f9 !important;
}

html.dark .brand-sub {
  color: #94a3b8 !important;
}

html.dark .header-sep {
  background: #1e293b !important;
}

html.dark .header-status-pill {
  background: #0f172a !important;
  border-color: #1e293b !important;
}

html.dark .status-label {
  color: #94a3b8 !important;
}

html.dark .feature-pill {
  color: #94a3b8 !important;
  background: #0f172a !important;
  border-color: #1e293b !important;
}

html.dark .feature-pill:hover {
  color: #f1f5f9 !important;
  background: #1e293b !important;
  border-color: #38bdf8 !important;
}

html.dark .theme-toggle-btn {
  background: #0f172a !important;
  border-color: #334155 !important;
  color: #f1f5f9 !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4) !important;
}

html.dark .theme-toggle-btn:hover {
  background: #1e293b !important;
  border-color: #38bdf8 !important;
}

html.dark .btn-ghost {
  background: #0f172a !important;
  border-color: #334155 !important;
  color: #cbd5e1 !important;
}

html.dark .btn-ghost:hover {
  background: #1e293b !important;
  border-color: #38bdf8 !important;
  color: #ffffff !important;
}

/* Hero Search Card in Dark Mode */
html.dark .search-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.6) !important;
}

html.dark .search-card h1 {
  color: #f1f5f9 !important;
}

html.dark .search-card p {
  color: #94a3b8 !important;
}

html.dark .dropzone {
  background: #070d1d !important;
  border-color: #334155 !important;
}

html.dark .dropzone:hover,
html.dark .dropzone.dragover {
  background: #0b1736 !important;
  border-color: #38bdf8 !important;
}

html.dark .drop-title {
  color: #f1f5f9 !important;
}

html.dark .drop-subtitle {
  color: #94a3b8 !important;
}

html.dark .drop-hint {
  background: #0f172a !important;
  color: #94a3b8 !important;
  border-color: #1e293b !important;
}

html.dark .upload-icon-circle {
  background: rgba(56, 189, 248, 0.12) !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
  color: #38bdf8 !important;
}

html.dark .btn-sample {
  background: #0f172a !important;
  border-color: #334155 !important;
  color: #cbd5e1 !important;
}

html.dark .btn-sample:hover {
  background: #1e293b !important;
  border-color: #38bdf8 !important;
  color: #38bdf8 !important;
}

html.dark .preview-container {
  background: transparent !important;
}

html.dark #previewImage {
  border: 1.5px solid #334155 !important;
  background: #020617 !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6) !important;
}

html.dark .preview-meta {
  color: #cbd5e1 !important;
}

html.dark .form-group label {
  color: #cbd5e1 !important;
}

html.dark .form-group p {
  color: #94a3b8 !important;
}

html.dark .form-control {
  background: #020617 !important;
  border-color: #334155 !important;
  color: #f1f5f9 !important;
}

html.dark .form-control::placeholder {
  color: #64748b !important;
}

html.dark .form-control:focus {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.25) !important;
}

/* Executive Summary & Verdict Banner in Dark Mode */
html.dark .summary-card {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(20, 30, 50, 0.9) 100%) !important;
  border: 1px solid rgba(51, 65, 85, 0.7) !important;
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
  backdrop-filter: blur(16px) !important;
}

html.dark #verdictHeadline {
  color: #ffffff !important;
}

html.dark #verdictSummary {
  color: #cbd5e1 !important;
}

html.dark .stat-card {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.85), rgba(30, 41, 59, 0.7)) !important;
  border: 1px solid rgba(51, 65, 85, 0.7) !important;
  border-radius: 14px !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3) !important;
  backdrop-filter: blur(12px) !important;
  transition: all 0.25s ease !important;
}

html.dark .stat-card:hover {
  border-color: rgba(56, 189, 248, 0.5) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 12px rgba(56, 189, 248, 0.15) !important;
}

html.dark .stat-label {
  color: #94a3b8 !important;
}

html.dark .stat-value {
  color: #f8fafc !important;
}

/* Tabs Navigation in Dark Mode */
html.dark .tabs-nav-container {
  background: rgba(15, 23, 42, 0.88) !important;
  border: 1px solid rgba(51, 65, 85, 0.6) !important;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
  backdrop-filter: blur(16px) !important;
}

html.dark .results-tabs {
  border-bottom: none !important;
}

html.dark .tab-btn {
  background: rgba(15, 23, 42, 0.6) !important;
  border: 1px solid rgba(51, 65, 85, 0.5) !important;
  color: #94a3b8 !important;
  border-radius: 12px !important;
  transition: all 0.2s ease !important;
}

html.dark .tab-btn:hover {
  color: #f8fafc !important;
  background: rgba(30, 41, 59, 0.9) !important;
  border-color: rgba(100, 116, 139, 0.75) !important;
}

html.dark .tab-btn.active {
  background: linear-gradient(135deg, #0ea5e9 0%, #3b82f6 50%, #6366f1 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
}

html.dark .tab-badge {
  background: rgba(30, 41, 59, 0.9) !important;
  border: 1px solid rgba(71, 85, 105, 0.55) !important;
  color: #7dd3fc !important;
}

html.dark .tab-btn.active .tab-badge {
  background: rgba(255, 255, 255, 0.25) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  color: #ffffff !important;
}

html.dark .tab-badge.tab-badge-verified {
  background: rgba(16, 185, 129, 0.2) !important;
  border-color: rgba(16, 185, 129, 0.45) !important;
  color: #34d399 !important;
}

html.dark .tab-scroll-btn {
  background: rgba(30, 41, 59, 0.9) !important;
  border: 1px solid rgba(71, 85, 105, 0.7) !important;
  color: #94a3b8 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4) !important;
}

html.dark .tab-scroll-btn:hover {
  background: rgba(51, 65, 85, 1) !important;
  border-color: #38bdf8 !important;
  color: #38bdf8 !important;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.3) !important;
  transform: scale(1.08) !important;
}

/* Content Container Cards in Dark Mode */
html.dark .content-card {
  background: rgba(15, 23, 42, 0.8) !important;
  border: 1px solid #1e293b !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
}

html.dark .content-card h3 {
  color: #f1f5f9 !important;
}

html.dark .content-card p {
  color: #94a3b8 !important;
}

html.dark .items-count-pill {
  background: #020617 !important;
  color: #38bdf8 !important;
  border: 1px solid #1e293b !important;
}

/* Visual Matches Candidate Cards in Dark Mode */
html.dark .candidate-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .candidate-card:hover {
  border-color: #38bdf8 !important;
  background: #131d35 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .candidate-thumbnail {
  background: #020617 !important;
}

html.dark .candidate-domain {
  color: #38bdf8 !important;
}

html.dark .candidate-title {
  color: #f1f5f9 !important;
}

html.dark .candidate-scores {
  color: #94a3b8 !important;
}

html.dark .score-badge {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}

html.dark .candidate-link-btn {
  background: #1e293b !important;
  color: #38bdf8 !important;
  border: 1px solid #334155 !important;
}

html.dark .candidate-link-btn:hover {
  background: #334155 !important;
  color: #7dd3fc !important;
}

/* News Cards in Dark Mode */
html.dark .news-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .news-card:hover {
  border-color: #38bdf8 !important;
  background: #131d35 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .news-card-thumb {
  background: #020617 !important;
}

html.dark .news-publisher-name {
  color: #38bdf8 !important;
}

html.dark .news-authors {
  color: #94a3b8 !important;
}

html.dark .news-date {
  color: #64748b !important;
}

html.dark .news-title a {
  color: #f1f5f9 !important;
}

html.dark .news-title a:hover {
  color: #38bdf8 !important;
}

/* Social Cards in Dark Mode */
html.dark .social-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .social-card:hover {
  border-color: #38bdf8 !important;
  background: #131d35 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .social-thumb-box {
  background: #020617 !important;
  border: 1px solid #1e293b !important;
}

html.dark .social-source-name {
  color: #cbd5e1 !important;
}

html.dark .social-details h4 a {
  color: #f1f5f9 !important;
}

html.dark .social-details h4 a:hover {
  color: #38bdf8 !important;
}

html.dark .social-details p {
  color: #94a3b8 !important;
}

html.dark .social-post-date {
  color: #64748b !important;
}

html.dark .platform-twitter,
html.dark .platform-x {
  background: #1e293b !important;
  color: #f1f5f9 !important;
}

html.dark .platform-tiktok {
  background: #1e293b !important;
  color: #f1f5f9 !important;
}

/* Web Results Cards in Dark Mode */
html.dark .web-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .web-card:hover {
  border-color: #38bdf8 !important;
  background: #131d35 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .web-position-pill {
  background: #1e293b !important;
  color: #94a3b8 !important;
  border: 1px solid #334155 !important;
}

html.dark .web-domain {
  color: #94a3b8 !important;
}

html.dark .web-title a {
  color: #38bdf8 !important;
}

html.dark .web-title a:hover {
  color: #7dd3fc !important;
}

html.dark .web-snippet {
  color: #cbd5e1 !important;
}

/* Timeline Cards in Dark Mode */
html.dark .timeline-wrapper::before {
  background: #334155 !important;
}

html.dark .timeline-event-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .timeline-event-card:hover {
  border-color: #38bdf8 !important;
  background: #131d35 !important;
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.5) !important;
}

html.dark .timeline-event-card::before {
  background: #38bdf8 !important;
  border: 2px solid #0f172a !important;
  box-shadow: 0 0 0 2px #1e293b !important;
}

html.dark .timeline-event-card.ground-zero::before {
  background: #34d399 !important;
  box-shadow: 0 0 0 2px #064e3b !important;
}

html.dark .event-date-badge {
  color: #38bdf8 !important;
}

html.dark .event-title {
  color: #f1f5f9 !important;
}

html.dark .event-snippet {
  color: #cbd5e1 !important;
}

html.dark .event-domain {
  color: #94a3b8 !important;
}

/* Evidence Graph in Dark Mode */
html.dark #graphContainer {
  background: #020617 !important;
}

html.dark .graph-sidebar {
  background: #0f172a !important;
  border-color: #1e293b !important;
  color: #cbd5e1 !important;
}

html.dark .graph-sidebar h4 {
  color: #f1f5f9 !important;
}

html.dark .graph-legend {
  background: rgba(15, 23, 42, 0.95) !important;
  border-color: #1e293b !important;
  color: #cbd5e1 !important;
}

html.dark .connection-map-explainer {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .connection-map-explainer h4 {
  color: #f1f5f9 !important;
}

html.dark .connection-map-explainer span strong {
  color: #f1f5f9 !important;
}

/* Person Intelligence in Dark Mode */
html.dark .person-intel-clean-card {
  background: rgba(15, 23, 42, 0.8) !important;
  border: 1px solid #1e293b !important;
}

html.dark .intel-header-banner {
  background: linear-gradient(135deg, #020617 0%, #0f172a 100%) !important;
  border: 1px solid #1e293b !important;
}

html.dark .intel-badge-title {
  color: #38bdf8 !important;
}

html.dark #piPersonTitle {
  color: #ffffff !important;
}

html.dark #piPersonName {
  color: #38bdf8 !important;
}

html.dark .intel-label {
  color: #94a3b8 !important;
}

html.dark #piAliasesList {
  color: #cbd5e1 !important;
}

html.dark .intel-tag-item {
  background: #1e293b !important;
  border: 1px solid #334155 !important;
  color: #7dd3fc !important;
}

html.dark .intel-score-circle {
  background: rgba(8, 145, 178, 0.15) !important;
  border-color: rgba(56, 189, 248, 0.4) !important;
}

html.dark #piIdentityConfidenceVal {
  color: #38bdf8 !important;
}

html.dark .intel-score-label {
  color: #94a3b8 !important;
}

html.dark .intel-section-title h4 {
  color: #f1f5f9 !important;
}

html.dark .intel-table-responsive {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
}

html.dark .intel-table th {
  background: #020617 !important;
  color: #94a3b8 !important;
  border-bottom: 1px solid #1e293b !important;
}

html.dark .intel-table td {
  background: #0f172a !important;
  color: #cbd5e1 !important;
  border-bottom: 1px solid #1e293b !important;
}

html.dark .intel-table tr:hover td {
  background: #1e293b !important;
}

html.dark .intel-cat-cell {
  color: #f1f5f9 !important;
}

html.dark .intel-info-cell {
  color: #cbd5e1 !important;
}

html.dark .intel-summary-box {
  background: #020617 !important;
  border: 1px solid #1e293b !important;
  border-left: 4px solid #38bdf8 !important;
}

html.dark #piResearchSummaryText,
html.dark .intel-summary-para,
html.dark .intel-summary-para.justified,
html.dark #piResearchSummaryContainer p {
  color: #cbd5e1 !important;
  font-size: 0.95rem !important;
  line-height: 1.8 !important;
}

html.dark .intel-summary-para strong,
html.dark .intel-summary-para.justified strong,
html.dark .intel-summary-paragraphs strong,
html.dark #piResearchSummaryContainer strong {
  color: #ffffff !important;
  font-weight: 700 !important;
}

html.dark .intel-summary-footer {
  border-top-color: #1e293b !important;
}

html.dark .dossier-person-intel-card {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(2, 6, 23, 0.98) 100%) !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5) !important;
}

html.dark .dossier-quick-table-wrap {
  border-color: #1e293b !important;
  background: rgba(2, 6, 23, 0.85) !important;
}

html.dark .dossier-quick-table tr {
  border-bottom-color: #1e293b !important;
}

html.dark .dossier-quick-table td.label-col {
  background: rgba(15, 23, 42, 0.9) !important;
  color: #94a3b8 !important;
  border-right-color: #1e293b !important;
}

html.dark .dossier-quick-table td.val-col {
  background: rgba(2, 6, 23, 0.85) !important;
  color: #f1f5f9 !important;
}

html.dark .dossier-bio-card {
  background: rgba(2, 6, 23, 0.8) !important;
  border: 1px solid #1e293b !important;
  border-left: 4px solid #38bdf8 !important;
}

html.dark .dossier-bio-card .bio-card-title {
  color: #38bdf8 !important;
}

html.dark .dossier-bio-card p {
  color: #cbd5e1 !important;
}

html.dark .dossier-bio-card strong {
  color: #ffffff !important;
  font-weight: 700 !important;
}

html.dark .ref-source-chip {
  background: #0f172a !important;
  border: 1px solid #334155 !important;
  color: #e2e8f0 !important;
}

html.dark .ref-source-chip:hover {
  background: #1e293b !important;
  border-color: #38bdf8 !important;
  color: #38bdf8 !important;
}

html.dark .verify-note-tag {
  color: #94a3b8 !important;
}

html.dark .intel-ref-title {
  color: #94a3b8 !important;
}

html.dark .ref-empty-hint {
  color: #64748b !important;
}

html.dark .ref-tag {
  background: #1e293b !important;
  border: 1px solid #334155 !important;
  color: #38bdf8 !important;
}

html.dark .finding-card {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
  border-left: 4px solid #10b981 !important;
}

html.dark .finding-claim-text {
  color: #f1f5f9 !important;
}

html.dark .finding-source-badge {
  background: #1e293b !important;
  color: #94a3b8 !important;
  border: 1px solid #334155 !important;
}

html.dark .intel-unknowns-card {
  background: rgba(245, 158, 11, 0.08) !important;
  border: 1px solid rgba(245, 158, 11, 0.25) !important;
}

html.dark .unknowns-title {
  color: #fbbf24 !important;
}

html.dark .unknowns-list {
  color: #94a3b8 !important;
}

/* Executive Dossier in Dark Mode */
html.dark .executive-dossier {
  background: #0f172a !important;
  border: 1px solid #1e293b !important;
  color: #cbd5e1 !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4) !important;
}

html.dark .dossier-cert-header {
  border-bottom: 2px solid #1e293b !important;
}

html.dark .dossier-cert-title h3 {
  color: #f1f5f9 !important;
}

html.dark .dossier-cert-title span {
  color: #94a3b8 !important;
}

html.dark .dossier-id-badge {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}

html.dark .dossier-date-badge {
  color: #94a3b8 !important;
}

html.dark .dossier-verdict-card {
  background: rgba(6, 78, 59, 0.3) !important;
  border: 1.5px solid rgba(52, 211, 153, 0.35) !important;
}

html.dark .dossier-verdict-card.public-match {
  background: rgba(12, 74, 110, 0.3) !important;
  border: 1.5px solid rgba(56, 189, 248, 0.35) !important;
}

html.dark .verdict-headline-text {
  color: #34d399 !important;
}

html.dark .verdict-headline-text.public {
  color: #7dd3fc !important;
}

html.dark .verdict-summary-text {
  color: #cbd5e1 !important;
}

html.dark .dossier-grid-card {
  background: #020617 !important;
  border: 1px solid #1e293b !important;
}

html.dark .dgc-header {
  color: #f1f5f9 !important;
}

html.dark .dgc-val {
  color: #38bdf8 !important;
}

html.dark .dgc-desc {
  color: #94a3b8 !important;
}

html.dark .dossier-section {
  border-top: 1px solid #1e293b !important;
}

html.dark .dossier-section h4 {
  color: #f1f5f9 !important;
}

html.dark .dossier-tag {
  background: #1e293b !important;
  color: #cbd5e1 !important;
  border: 1px solid #334155 !important;
}

html.dark #rawReportContent,
html.dark #markdownReportContent {
  background: #020617 !important;
  color: #cbd5e1 !important;
  border: 1px solid #1e293b !important;
}

/* History Drawer in Dark Mode */
html.dark .history-drawer {
  background: rgba(15, 23, 42, 0.98) !important;
  border-left: 1px solid #1e293b !important;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.6) !important;
}

html.dark .drawer-header {
  border-bottom: 1px solid #1e293b !important;
}

html.dark .drawer-header h3 {
  color: #f1f5f9 !important;
}

html.dark .history-drawer .btn-close-box {
  color: #94a3b8 !important;
  background: transparent !important;
}

html.dark .history-drawer .btn-close-box:hover {
  color: #ffffff !important;
  background: #1e293b !important;
}

html.dark .history-empty {
  color: #64748b !important;
}

html.dark .history-item {
  background: #131d35 !important;
  border: 1px solid #1e293b !important;
  color: #cbd5e1 !important;
}

html.dark .history-item:hover {
  background: #1e293b !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.12) !important;
}

html.dark .history-thumb-img {
  border: 1.5px solid #334155 !important;
  background: #020617 !important;
}

html.dark .history-name-pill {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.35) !important;
}

html.dark .history-file-tag {
  color: #e2e8f0 !important;
}

html.dark .history-date {
  color: #64748b !important;
}

html.dark .history-claim-box {
  background: #0b1329 !important;
  border-left: 2.5px solid #38bdf8 !important;
  color: #94a3b8 !important;
}

html.dark .history-claim-box .claim-prefix {
  color: #f1f5f9 !important;
}

html.dark .history-headline-box {
  color: #94a3b8 !important;
}

html.dark .history-item-footer {
  border-top: 1px dashed #1e293b !important;
}

html.dark .history-inv-id {
  color: #64748b !important;
}

html.dark .history-load-action {
  color: #38bdf8 !important;
}

html.dark .history-status-pill.status-confirmed {
  background: rgba(16, 185, 129, 0.15) !important;
  color: #34d399 !important;
  border: 1px solid rgba(16, 185, 129, 0.35) !important;
}

html.dark .history-status-pill.status-probable {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.35) !important;
}

html.dark .history-status-pill.status-unverified {
  background: rgba(148, 163, 184, 0.12) !important;
  color: #94a3b8 !important;
  border: 1px solid rgba(148, 163, 184, 0.25) !important;
}

html.dark .history-status-pill.status-alert {
  background: rgba(244, 63, 94, 0.15) !important;
  color: #fb7185 !important;
  border: 1px solid rgba(244, 63, 94, 0.35) !important;
}

html.dark .history-drag-handle {
  color: #64748b !important;
}

html.dark .history-item:hover .history-drag-handle {
  color: #38bdf8 !important;
}

html.dark .history-move-btn {
  border-color: #334155 !important;
  color: #94a3b8 !important;
  background: #0f172a !important;
}

html.dark .history-move-btn:hover {
  background: #1e293b !important;
  color: #38bdf8 !important;
  border-color: #38bdf8 !important;
}

html.dark .history-item.dragging {
  border: 2px dashed #38bdf8 !important;
  background: #0f172a !important;
}

/* Footer in Dark Mode */
html.dark .app-footer {
  background: #020617 !important;
  border-top: 1px solid #1e293b !important;
}

html.dark .app-footer span,
html.dark .app-footer a {
  color: #94a3b8 !important;
}

html.dark .app-footer a:hover {
  color: #38bdf8 !important;
}

/* Dark Mode overrides for Delete Modal, History Delete Btn & Load More */
html.dark .delete-modal-backdrop {
  background: rgba(3, 7, 18, 0.75) !important;
}

html.dark .delete-modal-card {
  background: #111827 !important;
  border-color: #1f2937 !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.06) !important;
}

html.dark .delete-modal-icon-wrap {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: rgba(239, 68, 68, 0.3) !important;
  color: #f87171 !important;
}

html.dark .delete-modal-title {
  color: #f8fafc !important;
}

html.dark .delete-modal-desc {
  color: #94a3b8 !important;
}

html.dark .delete-target-preview {
  background: #1e293b !important;
  border-color: #334155 !important;
  color: #e2e8f0 !important;
}

html.dark .delete-target-badge {
  background: #334155 !important;
  color: #cbd5e1 !important;
}

html.dark .delete-modal-actions {
  border-top-color: #1f2937 !important;
}

html.dark .btn-delete-cancel {
  background: #1f2937 !important;
  border-color: #374151 !important;
  color: #94a3b8 !important;
}

html.dark .btn-delete-cancel:hover {
  background: #374151 !important;
  color: #f1f5f9 !important;
}

html.dark .history-delete-btn {
  color: #64748b !important;
}

html.dark .history-delete-btn:hover {
  background: rgba(239, 68, 68, 0.18) !important;
  color: #f87171 !important;
  border-color: rgba(239, 68, 68, 0.35) !important;
}

html.dark .history-load-more-btn {
  background: #1e293b !important;
  border-color: #334155 !important;
  color: #38bdf8 !important;
}

html.dark .history-load-more-btn:hover:not(:disabled) {
  background: #334155 !important;
  border-color: #0284c7 !important;
}

html.dark .history-end-msg {
  color: #94a3b8 !important;
}

html.dark .toast-pill.toast-success {
  background: #1e293b !important;
  color: #34d399 !important;
  border-color: #059669 !important;
}

html.dark .toast-pill.toast-info {
  background: #1e293b !important;
  color: #38bdf8 !important;
  border-color: #0284c7 !important;
}

/* ==========================================================================
   Smart Camera Sticky Viewfinder Layout (Google Lens / Yandex Visual Style)
   ========================================================================== */
.sticky-camera-container {
  position: sticky;
  top: 1.5rem;
  z-index: 30;
  max-height: calc(100vh - 3rem);
}

.smart-camera-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.viewfinder-frame {
  position: relative;
  background: rgba(2, 6, 23, 0.85);
  box-shadow: inset 0 0 24px rgba(0, 0, 0, 0.8);
}

.corner-bracket {
  position: absolute;
  width: 18px;
  height: 18px;
  border-color: #ffffff;
  pointer-events: none;
  z-index: 20;
}

.corner-bracket.top-left {
  top: 10px;
  left: 10px;
  border-top: 2.5px solid #ffffff;
  border-left: 2.5px solid #ffffff;
  border-top-left-radius: 4px;
}

.corner-bracket.top-right {
  top: 10px;
  right: 10px;
  border-top: 2.5px solid #ffffff;
  border-right: 2.5px solid #ffffff;
  border-top-right-radius: 4px;
}

.corner-bracket.bottom-left {
  bottom: 10px;
  left: 10px;
  border-bottom: 2.5px solid #ffffff;
  border-left: 2.5px solid #ffffff;
  border-bottom-left-radius: 4px;
}

.corner-bracket.bottom-right {
  bottom: 10px;
  right: 10px;
  border-bottom: 2.5px solid #ffffff;
  border-right: 2.5px solid #ffffff;
  border-bottom-right-radius: 4px;
}

html.light .viewfinder-frame {
  background: #0f172a;
}

/* ==========================================================================
   Welcome Overview Card (Right Column Standby State) — Dual-Theme Styling
   ========================================================================== */
.welcome-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  transition: all 0.25s ease;
}

.welcome-title {
  color: var(--text-primary);
}

.welcome-subtitle {
  color: var(--text-secondary);
}

.welcome-badge {
  background: var(--bg-subtle);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.welcome-feature-card {
  background: var(--bg-panel);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.welcome-feature-card:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: 0 8px 20px -4px rgba(37, 99, 235, 0.08);
}

.welcome-feature-title {
  color: var(--text-primary);
}

.welcome-feature-desc {
  color: var(--text-muted);
}

.welcome-steps-section {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
}

.welcome-steps-heading {
  color: var(--text-muted);
}

.welcome-step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  transition: all 0.15s ease;
}

.welcome-step-card strong {
  color: var(--text-primary);
}

.welcome-step-card .step-num {
  background: var(--primary-subtle);
  color: var(--primary);
  border: 1px solid rgba(37, 99, 235, 0.2);
}

.welcome-banner-tip {
  background: var(--primary-subtle);
  border: 1px solid rgba(37, 99, 235, 0.2);
  color: var(--primary);
}

/* Light Mode Overrides for Welcome Card & Left Card Typography */
html.light .welcome-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.05), 0 8px 10px -6px rgba(15, 23, 42, 0.02) !important;
}

html.light .welcome-title {
  color: #0f172a !important;
}

html.light .welcome-subtitle {
  color: #475569 !important;
}

html.light .welcome-badge {
  background: #f1f5f9 !important;
  color: #475569 !important;
  border-color: #e2e8f0 !important;
}

html.light .welcome-feature-card {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03) !important;
}

html.light .welcome-feature-card:hover {
  background: #ffffff !important;
  border-color: #93c5fd !important;
  box-shadow: 0 10px 24px -4px rgba(37, 99, 235, 0.09) !important;
}

html.light .welcome-feature-title {
  color: #0f172a !important;
}

html.light .welcome-feature-desc {
  color: #64748b !important;
}

html.light .welcome-steps-section {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

html.light .welcome-steps-heading {
  color: #64748b !important;
}

html.light .welcome-step-card {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
}

html.light .welcome-step-card strong {
  color: #0f172a !important;
}

html.light .welcome-step-card p {
  color: #64748b !important;
}

html.light .welcome-step-card .step-num {
  background: #eff6ff !important;
  color: #2563eb !important;
  border-color: #bfdbfe !important;
}

html.light .welcome-banner-tip {
  background: #eff6ff !important;
  border-color: #bfdbfe !important;
  color: #1e40af !important;
}

html.light .welcome-banner-tip strong {
  color: #1d4ed8 !important;
}

html.light .search-title-primary {
  color: #0f172a !important;
}

html.light .search-desc {
  color: #64748b !important;
}

/* Dark Mode Overrides for Welcome Card */
html.dark .welcome-card {
  background: rgba(15, 23, 42, 0.65) !important;
  border-color: rgba(30, 41, 59, 0.8) !important;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4) !important;
}

html.dark .welcome-title {
  color: #f8fafc !important;
}

html.dark .welcome-subtitle {
  color: #94a3b8 !important;
}

html.dark .welcome-badge {
  background: rgba(30, 41, 59, 0.8) !important;
  color: #94a3b8 !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

html.dark .welcome-feature-card {
  background: rgba(2, 6, 23, 0.55) !important;
  border-color: rgba(30, 41, 59, 0.8) !important;
}

html.dark .welcome-feature-card:hover {
  background: rgba(15, 23, 42, 0.8) !important;
  border-color: rgba(56, 189, 248, 0.35) !important;
}

html.dark .welcome-feature-title {
  color: #f1f5f9 !important;
}

html.dark .welcome-feature-desc {
  color: #94a3b8 !important;
}

html.dark .welcome-steps-section {
  background: rgba(2, 6, 23, 0.4) !important;
  border-color: rgba(30, 41, 59, 0.6) !important;
}

html.dark .welcome-steps-heading {
  color: #94a3b8 !important;
}

html.dark .welcome-step-card {
  background: rgba(15, 23, 42, 0.7) !important;
  border-color: rgba(30, 41, 59, 0.8) !important;
}

html.dark .welcome-step-card strong {
  color: #f1f5f9 !important;
}

html.dark .welcome-step-card p {
  color: #94a3b8 !important;
}

html.dark .welcome-step-card .step-num {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #38bdf8 !important;
  border-color: rgba(56, 189, 248, 0.3) !important;
}

html.dark .welcome-banner-tip {
  background: rgba(8, 47, 73, 0.35) !important;
  border-color: rgba(14, 165, 233, 0.25) !important;
  color: #7dd3fc !important;
}

html.dark .welcome-banner-tip strong {
  color: #38bdf8 !important;
}

html.dark .search-title-primary {
  color: #f8fafc !important;
}

/* ==========================================================================
   Verified Facebook Profile Hero Card (SerpApi facebook_profile)
   ========================================================================== */
.fb-hero-card {
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.3s ease;
  margin-bottom: 20px;
}

html.dark .fb-hero-card {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.9));
  border: 1px solid rgba(59, 130, 246, 0.35);
  box-shadow: 0 10px 30px -10px rgba(37, 99, 235, 0.25);
}

html.light .fb-hero-card {
  background: linear-gradient(135deg, #ffffff, #f0f7ff);
  border: 1px solid #bfdbfe;
  box-shadow: 0 10px 30px -10px rgba(37, 99, 235, 0.12);
}

.fb-hero-cover {
  width: 100%;
  height: 120px;
  object-fit: cover;
  background: linear-gradient(90deg, #1877f2, #0d5bb5);
}

.fb-hero-body {
  padding: 16px 20px 20px 20px;
  position: relative;
}

.fb-hero-avatar-row {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  margin-top: -46px;
  margin-bottom: 12px;
}

.fb-hero-avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  border: 3.5px solid #ffffff;
  object-fit: cover;
  background: #1877f2;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  flex-shrink: 0;
}

html.dark .fb-hero-avatar {
  border-color: #0f172a;
}

.fb-verified-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 0.72rem;
  font-weight: 700;
  background: #1877f2;
  color: #ffffff;
}

.fb-hero-name {
  font-size: 1.25rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 6px;
}

html.dark .fb-hero-name {
  color: #f8fafc;
}

html.light .fb-hero-name {
  color: #0f172a;
}

.fb-stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.78rem;
  margin-top: 6px;
}

html.dark .fb-stats-row {
  color: #94a3b8;
}

html.light .fb-stats-row {
  color: #475569;
}

.fb-stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 6px;
}

html.dark .fb-stat-pill {
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(51, 65, 85, 0.8);
}

html.light .fb-stat-pill {
  background: #e0f2fe;
  border: 1px solid #bae6fd;
  color: #0369a1;
}

.fb-hero-intro {
  margin-top: 10px;
  font-size: 0.82rem;
  line-height: 1.5;
}

html.dark .fb-hero-intro {
  color: #cbd5e1;
}

html.light .fb-hero-intro {
  color: #334155;
}

.fb-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(148, 163, 184, 0.15);
  font-size: 0.75rem;
}

html.dark .fb-meta-grid {
  color: #94a3b8;
}

html.light .fb-meta-grid {
  color: #64748b;
}

.fb-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  background: #1877f2;
  color: #ffffff !important;
  text-decoration: none;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(24, 119, 242, 0.3);
}

.fb-link-btn:hover {
  background: #0d65d9;
  transform: translateY(-1px);
}





