/* ==========================================================================
   USER ABSTRACTION & CITIZEN EDITORIAL RECEIPT
   ========================================================================== */
.user-only-ui {
  display: flex;
}

.admin-only-ui {
  display: flex;
}

.citizen-receipt-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: linear-gradient(145deg, #0f1626, #090e18);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 12px;
  padding: 22px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  position: relative;
  overflow: hidden;
  animation: receiptReveal 0.45s var(--ease-spring) both;
}

.citizen-receipt-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #10b981, #06b6d4, #3b82f6);
}

.receipt-header {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 14px;
}

.receipt-seal {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--accent-green);
  color: var(--accent-green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  font-weight: 800;
  flex-shrink: 0;
}

.receipt-meta {
  flex: 1;
}

.receipt-edition {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  color: var(--accent-cyan);
  margin-bottom: 4px;
}

.receipt-headline {
  font-family: var(--font-editorial);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-headline);
  line-height: 1.35;
  margin-bottom: 4px;
}

.receipt-byline {
  font-size: 0.74rem;
  color: var(--text-dim);
}

/* 3-TIER CLASSIFICATION TAG BADGE */
.citizen-tag-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px 16px;
}

.citizen-3tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: 0.9rem;
  padding: 8px 16px;
  border-radius: 6px;
  letter-spacing: 0.03em;
}

.citizen-3tier-badge.tag-real {
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid var(--accent-green);
  color: #34d399;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.25);
}

.citizen-3tier-badge.tag-likely-fake {
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid var(--accent-amber);
  color: #fbbf24;
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.25);
}

.citizen-3tier-badge.tag-fake {
  background: rgba(239, 68, 68, 0.18);
  border: 1px solid var(--accent-crimson);
  color: #f87171;
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.25);
}

.citizen-confidence-gauge {
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.citizen-confidence-gauge .gauge-label {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.citizen-confidence-gauge .gauge-value {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 800;
}

/* EXPLANATION BOX */
.citizen-explanation-box {
  background: var(--bg-surface);
  border-left: 3px solid var(--accent-cyan);
  border-radius: 0 8px 8px 0;
  padding: 14px 16px;
}

.citizen-explanation-box h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-headline);
  margin-bottom: 6px;
}

.citizen-explanation-box p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.citizen-checks-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.check-chip {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 0.72rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.check-chip .check-icon {
  color: var(--accent-green);
  font-weight: 900;
}

.citizen-receipt-actions {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}

/* ==========================================================================
   QUEUE ITEM META EXTENSIONS
   ========================================================================== */
.queue-meta-line {
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-top: 4px;
}


:root,
[data-theme="light"] {
  --bg-dark: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5f9;
  --bg-surface: #ffffff;
  --bg-input: #f8fafc;
  --bg-header-bar: #f1f5f9;

  --border-subtle: #e2e8f0;
  --border-focus: #0284c7;
  --border-newspaper: #cbd5e1;
  --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.05);
  --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.1);

  --text-main: #0f172a;
  --text-muted: #334155;
  --text-dim: #64748b;
  --text-newspaper: #1e293b;
  --text-headline: #0f172a;

  --accent-green: #16a34a;
  --accent-green-glow: rgba(22, 163, 74, 0.12);
  --accent-crimson: #dc2626;
  --accent-crimson-glow: rgba(220, 38, 38, 0.12);
  --accent-amber: #d97706;
  --accent-amber-glow: rgba(217, 119, 6, 0.12);
  --accent-cyan: #0284c7;
  --accent-cyan-glow: rgba(2, 132, 199, 0.12);
  --accent-purple: #7c3aed;
  --accent-purple-glow: rgba(124, 58, 237, 0.12);
  --accent-blue: #2563eb;

  --font-masthead: 'Algerian', 'Cinzel Decorative', 'Cinzel', 'Playfair Display', serif;
  --font-editorial: 'Newsreader', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

[data-theme="dark"] {
  --bg-dark: #070a11;
  --bg-card: #0d121f;
  --bg-card-hover: #131b2e;
  --bg-surface: #101726;
  --bg-input: #0a0f1a;
  --bg-header-bar: #04060a;

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(56, 189, 248, 0.4);
  --border-newspaper: #2a364f;
  --shadow-card: 0 4px 15px rgba(0, 0, 0, 0.35);
  --shadow-hover: 0 10px 30px rgba(0, 0, 0, 0.6);

  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --text-newspaper: #e2e8f0;
  --text-headline: #ffffff;

  --accent-green: #10b981;
  --accent-green-glow: rgba(16, 185, 129, 0.2);
  --accent-crimson: #ef4444;
  --accent-crimson-glow: rgba(239, 68, 68, 0.25);
  --accent-amber: #f59e0b;
  --accent-amber-glow: rgba(245, 158, 11, 0.2);
  --accent-cyan: #06b6d4;
  --accent-cyan-glow: rgba(6, 182, 212, 0.2);
  --accent-purple: #a855f7;
  --accent-purple-glow: rgba(168, 85, 247, 0.2);
  --accent-blue: #3b82f6;
}

[data-theme="paper"],
[data-theme="newsprint"] {
  --bg-dark: #f5eedc;
  /* Classic newsprint aged paper */
  --bg-card: #fdfaf2;
  /* Natural parchment broadsheet card */
  --bg-card-hover: #f7f0df;
  --bg-surface: #fdfaf2;
  --bg-input: #faf5e8;
  --bg-header-bar: #ede3cc;

  --border-subtle: #dcd0b8;
  --border-focus: #b45309;
  --border-newspaper: #c5b595;
  --shadow-card: 0 2px 10px rgba(78, 59, 29, 0.08);
  --shadow-hover: 0 8px 24px rgba(78, 59, 29, 0.15);

  --text-main: #1c150c;
  /* Deep printer's ink */
  --text-muted: #3d3121;
  --text-dim: #705e46;
  --text-newspaper: #241c10;
  --text-headline: #181109;

  --accent-green: #15803d;
  --accent-green-glow: rgba(21, 128, 61, 0.15);
  --accent-crimson: #b91c1c;
  --accent-crimson-glow: rgba(185, 28, 28, 0.15);
  --accent-amber: #b45309;
  --accent-amber-glow: rgba(180, 83, 9, 0.15);
  --accent-cyan: #0369a1;
  --accent-cyan-glow: rgba(3, 105, 161, 0.15);
  --accent-purple: #6b21a8;
  --accent-purple-glow: rgba(107, 33, 168, 0.15);
  --accent-blue: #1d4ed8;

  --font-masthead: 'Algerian', 'Cinzel Decorative', 'Cinzel', 'Playfair Display', serif;
  --font-editorial: 'Newsreader', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  max-width: 100%;
  overflow-x: hidden;
}

.layout-container {
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
  padding: 0 24px 60px;
  overflow-x: clip;
}

/* ==========================================================================
   TOP MARKET TICKER BAR (NEWSPAPER HEADER STRIP)
   ========================================================================== */
.market-ticker-bar {
  background: var(--bg-header-bar);
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  overflow: hidden;
  white-space: nowrap;
  padding: 6px 0;
}

.market-ticker-track {
  display: inline-block;
  padding-left: 100%;
  animation: tickerScroll 40s linear infinite;
}

.market-ticker-bar:hover .market-ticker-track {
  animation-play-state: paused;
}

@keyframes tickerScroll {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-100%);
  }
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 32px;
}

.ticker-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-green);
  display: inline-block;
}

:root {
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth: cubic-bezier(0.25, 0.8, 0.25, 1);
}

.live-pulse {
  animation: pulseBeacon 1.8s infinite var(--ease-spring);
}

@keyframes pulseBeacon {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
  }
  50% {
    opacity: 0.55;
    transform: scale(1.28);
    box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
  }
}

/* ==========================================================================
   GLOBAL MOTION & ANIMATION SYSTEM (REALISTIC NEWSPAPER PAGE TURN)
   ========================================================================== */
@keyframes tabEntrance {
  0% {
    opacity: 0;
    transform: perspective(1400px) rotateY(-3.5deg) translateY(18px) scale(0.985);
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.16));
    transform-origin: left center;
  }
  50% {
    transform: perspective(1400px) rotateY(1deg) translateY(-2px) scale(1.002);
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.08));
  }
  100% {
    opacity: 1;
    transform: perspective(1400px) rotateY(0deg) translateY(0) scale(1);
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.04));
  }
}

@keyframes paperPageTurnIn {
  0% {
    opacity: 0;
    transform: perspective(1400px) rotateY(-3.5deg) translateY(18px) scale(0.985);
    filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.16));
    transform-origin: left center;
  }
  50% {
    transform: perspective(1400px) rotateY(1deg) translateY(-2px) scale(1.002);
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.08));
  }
  100% {
    opacity: 1;
    transform: perspective(1400px) rotateY(0deg) translateY(0) scale(1);
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.04));
  }
}

@keyframes cardCascadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes modalBackdropFadeIn {
  0% {
    opacity: 0;
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
  }
  100% {
    opacity: 1;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
  }
}

@keyframes modalSpringIn {
  0% {
    opacity: 0;
    transform: scale(0.92) translateY(22px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes receiptReveal {
  0% {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes shardPurgeIntense {
  0% {
    transform: scale(1.02);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.5), inset 0 0 10px rgba(239, 68, 68, 0.25);
    filter: brightness(1);
  }
  100% {
    transform: scale(1.045);
    box-shadow: 0 0 30px rgba(239, 68, 68, 0.8), inset 0 0 20px rgba(239, 68, 68, 0.5);
    filter: brightness(1.25);
  }
}

@keyframes shardLaserSweep {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

@keyframes shardPurgedSuccess {
  0% {
    transform: scale(1.06);
    box-shadow: 0 0 35px rgba(16, 185, 129, 0.85);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 16px rgba(16, 185, 129, 0.35);
  }
}

@keyframes stepCardPulse {
  0% {
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.35);
    border-color: #f59e0b;
  }
  100% {
    box-shadow: 0 0 26px rgba(245, 158, 11, 0.7);
    border-color: #fbbf24;
  }
}

@keyframes checkPop {
  0% { transform: scale(0.5); }
  60% { transform: scale(1.28); }
  100% { transform: scale(1); }
}

@keyframes toastSpringIn {
  0% {
    opacity: 0;
    transform: translateX(120%) scale(0.9);
  }
  100% {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}

@keyframes toastSpringOut {
  0% {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateX(110%) scale(0.85);
  }
}

@keyframes toastProgressSweep {
  from { width: 100%; }
  to { width: 0%; }
}

@keyframes buttonShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

@keyframes badgeGlow {
  0%, 100% { box-shadow: 0 0 8px rgba(56, 189, 248, 0.3); }
  50% { box-shadow: 0 0 16px rgba(56, 189, 248, 0.6); }
}

/* ==========================================================================
   NEWSPAPER MASTHEAD
   ========================================================================== */
.newspaper-masthead {
  border-bottom: 2px solid var(--border-newspaper);
  padding: 20px 0 16px;
  margin-bottom: 16px;
  position: relative;
  z-index: 120;
}

.masthead-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 16px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
  margin-bottom: 16px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.masthead-date {
  font-family: var(--font-editorial);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--text-main);
}

.masthead-edition {
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  color: var(--accent-cyan);
}

.masthead-user-controls {
  display: flex;
  align-items: center;
  gap: 16px;
}

.role-pill-switch {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.04);
  padding: 3px 6px;
  border-radius: 20px;
  border: 1px solid var(--border-subtle);
}

.switch-label {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
  padding-left: 4px;
}

.role-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 4px;
}

.role-btn:hover {
  color: var(--text-headline);
}

.role-btn.active {
  background: rgba(56, 189, 248, 0.18);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
}

.auth-profile-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 5px 12px;
  cursor: pointer;
  color: var(--text-main);
  transition: all 0.2s;
}

.auth-profile-btn:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: var(--bg-card-hover);
}

.user-avatar {
  font-size: 0.85rem;
}

.user-name {
  font-size: 0.8rem;
  font-weight: 600;
}

.user-role-badge {
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 10px;
  letter-spacing: 0.04em;
}

.badge-green {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
}

.badge-crimson {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.badge-amber {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
}

.badge-cyan {
  background: rgba(6, 182, 212, 0.2);
  color: #06b6d4;
}

.badge-purple {
  background: rgba(168, 85, 247, 0.2);
  color: #a855f7;
}

.masthead-main {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  padding: 10px 0 14px;
  position: relative;
}

/* REALISTIC BROADSHEET MASTHEAD EARPIECES */
.masthead-ear {
  flex: 1;
  max-width: 210px;
  padding: 8px 12px;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--bg-surface);
  box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.03);
}

.ear-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-amber);
  margin-bottom: 2px;
}

.ear-headline {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-headline);
  margin-bottom: 2px;
  font-family: var(--font-sans);
}

.ear-quote {
  font-size: 0.65rem;
  font-style: italic;
  color: var(--text-dim);
  letter-spacing: 0.05em;
}

@media (max-width: 980px) {
  .masthead-ear {
    display: none;
  }
}

/* EMBOSSED SEALS: BRAIN & CLEANING BRUSH */
.masthead-seal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--text-headline);
  flex-shrink: 0;
}

.masthead-seal.left-seal {
  color: var(--accent-cyan);
  border-color: rgba(6, 182, 212, 0.35);
}

.masthead-seal.left-seal:hover {
  transform: scale(1.08) rotate(-4deg);
  box-shadow: 0 8px 22px rgba(6, 182, 212, 0.28);
}

.masthead-seal.right-seal {
  color: var(--accent-amber);
  border-color: rgba(245, 158, 11, 0.35);
}

.masthead-seal.right-seal:hover {
  transform: scale(1.08) rotate(4deg);
  box-shadow: 0 8px 22px rgba(245, 158, 11, 0.28);
}

.masthead-icon-brain {
  transition: transform 0.3s ease;
}

.masthead-seal.left-seal:hover .masthead-icon-brain {
  transform: scale(1.06);
}

.masthead-icon-brush {
  transition: transform 0.3s ease;
}

.masthead-seal.right-seal:hover .masthead-icon-brush {
  transform: scale(1.06) rotate(-6deg);
}

/* ALGERIAN NEWSPAPER MASTHEAD TITLE */
.newspaper-title {
  font-family: 'Algerian', 'Cinzel Decorative', 'Cinzel', 'Playfair Display', Georgia, serif;
  font-size: 3.8rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-headline);
  text-align: center;
  line-height: 1.05;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
  margin: 0;
  padding: 0;
  transition: color 0.3s ease;
}

[data-theme="dark"] .newspaper-title {
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.9), 0 0 35px rgba(245, 158, 11, 0.18);
}

/* BROADSHEET OXFORD DOUBLE-RULE TAGLINE */
.masthead-tagline {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  font-size: 0.74rem;
  font-family: var(--font-mono);
  letter-spacing: 0.12em;
  color: var(--text-headline);
  text-align: center;
  padding: 8px 0;
  border-top: 3.5px double var(--border-subtle);
  border-bottom: 1.5px solid var(--border-subtle);
  margin-top: 8px;
}

/* ==========================================================================
   HEADLINES BREAKING NEWS WRAPPER
   ========================================================================== */
.breaking-news-wrapper {
  display: flex;
  align-items: stretch;
  background: linear-gradient(90deg, #b91c1c 0%, #7f1d1d 30%, #1e1115 100%);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 20px;
  box-shadow: 0 4px 15px rgba(185, 28, 28, 0.18);
}

.breaking-news-label {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #dc2626;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 10px 16px;
  white-space: nowrap;
  flex-shrink: 0;
}

.live-blink-circle {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
  animation: pulseBeacon 1s infinite;
}

.breaking-news-content {
  flex: 1;
  min-width: 180px;
  display: flex;
  align-items: center;
  overflow: hidden;
  white-space: nowrap;
  padding: 0 16px;
}

.breaking-actions-group {
  display: flex;
  align-items: stretch;
  flex-shrink: 0;
}

.breaking-news-marquee {
  display: inline-block;
  white-space: nowrap;
  padding-left: 20%;
  animation: breakingMarqueeScroll 35s linear infinite;
  font-size: 0.85rem;
  color: #fecaca;
}

.breaking-news-wrapper:hover .breaking-news-marquee {
  animation-play-state: paused;
}

@keyframes breakingMarqueeScroll {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-100%);
  }
}

.breaking-item {
  margin-right: 40px;
  cursor: pointer;
  transition: color 0.15s;
}

.breaking-item:hover {
  color: var(--text-headline);
  text-decoration: underline;
}

.live-sync-btn {
  background: rgba(0, 0, 0, 0.35);
  border: none;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 10px 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: background 0.2s;
}

.live-sync-btn:hover {
  background: rgba(0, 0, 0, 0.55);
}

@media (max-width: 960px) {
  .breaking-news-wrapper {
    flex-wrap: wrap;
  }
  .breaking-actions-group {
    width: 100%;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    justify-content: flex-end;
    flex-wrap: wrap;
  }
  .live-sync-btn {
    flex: 1;
    justify-content: center;
    padding: 8px 10px;
  }
}

/* ==========================================================================
   NAVIGATION TABS BAR
   ========================================================================== */
.newspaper-nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 8px 0;
  margin-bottom: 24px;
}

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.nav-tab {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 600;
  padding: 8px 13px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.nav-tab:hover {
  color: var(--text-headline);
  background: var(--bg-surface);
}

.nav-tab.active {
  color: var(--text-headline);
  background: var(--bg-card);
  border-color: var(--border-newspaper);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.nav-badge {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  padding: 1px 6px;
  border-radius: 10px;
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
}

.nav-meters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.meter-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 0.72rem;
  font-family: var(--font-mono);
  white-space: nowrap;
}

.meter-label {
  color: var(--text-dim);
}

/* ==========================================================================
   VIEWS ARCHITECTURE
   ========================================================================== */
.view-section {
  display: none;
}

.view-section.active {
  display: block;
  animation: paperPageTurnIn 0.48s cubic-bezier(0.16, 1, 0.3, 1) both;
  will-change: transform, opacity;
}

/* ==========================================================================
   TAB 1: FRONT PAGE NEWS WIRE
   ========================================================================== */
.category-filters-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 0;
  padding-bottom: 2px;
}

.filter-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 4px;
}

.cat-pill {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 16px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

.cat-pill:hover {
  color: var(--text-headline);
  border-color: var(--border-focus);
}

.cat-pill.active {
  background: #2563eb;
  color: #fff;
  border-color: #3b82f6;
}

/* NEWSPAPER LEAD HERO GRID */
.newspaper-grid-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  margin-bottom: 36px;
}

.featured-hero-article {
  min-width: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.4s var(--ease-spring), 
              box-shadow 0.4s var(--ease-spring), 
              border-color 0.25s ease;
  display: flex;
  flex-direction: column;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  animation: cardCascadeIn 0.48s var(--ease-spring) both;
  will-change: transform, box-shadow;
}

.featured-hero-article:hover {
  transform: translateY(-5px) translateZ(0);
  border-color: #38bdf8;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.65), 0 0 25px rgba(56, 189, 248, 0.2);
}

.hero-image-wrapper {
  position: relative;
  width: 100%;
  height: 340px;
  overflow: hidden;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s var(--ease-spring), filter 0.5s ease;
}

.featured-hero-article:hover .hero-image {
  transform: scale(1.04);
  filter: contrast(1.04) brightness(1.03);
}

.featured-hero-article:hover .hero-headline {
  color: #38bdf8;
  transition: color 0.2s ease;
}

.verification-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  gap: 6px;
}

.badge-verified {
  background: rgba(16, 185, 129, 0.85);
  color: #fff;
}

.badge-fake {
  background: rgba(239, 68, 68, 0.9);
  color: #fff;
}

.hero-category-tag {
  position: absolute;
  bottom: 14px;
  left: 14px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 4px;
}

.hero-content {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.hero-byline {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 10px;
}

.byline-source {
  font-weight: 700;
  color: var(--accent-cyan);
}

.byline-author {
  color: var(--text-muted);
}

.hero-headline {
  font-family: var(--font-editorial);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--text-headline);
  line-height: 1.25;
  margin-bottom: 12px;
}

.hero-excerpt {
  font-size: 0.92rem;
  color: var(--text-newspaper);
  line-height: 1.6;
  margin-bottom: 18px;
  flex: 1;
}

.hero-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  font-size: 0.8rem;
}

.read-more-link {
  color: #38bdf8;
  font-weight: 600;
}

.publish-time-stamp {
  font-family: var(--font-mono);
  color: var(--text-dim);
  font-size: 0.75rem;
}

/* TRENDING SIDEBAR */
.trending-wire-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.sidebar-header h3 {
  font-family: var(--font-editorial);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-headline);
}

.sidebar-tag {
  font-size: 0.68rem;
  font-family: var(--font-mono);
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-green);
  padding: 2px 8px;
  border-radius: 10px;
}

.trending-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex: 1;
}

.trending-item {
  display: flex;
  gap: 14px;
  cursor: pointer;
  padding: 8px 10px;
  border-radius: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: transform 0.28s var(--ease-spring), background-color 0.2s ease, border-color 0.2s ease;
}

.trending-item:hover {
  transform: translateX(6px);
  background: rgba(56, 189, 248, 0.06);
}

.trending-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.trending-rank {
  font-family: var(--font-masthead);
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--text-dim);
  line-height: 1;
  width: 24px;
}

.trending-content {
  flex: 1;
}

.trending-title {
  font-family: var(--font-editorial);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-headline);
  line-height: 1.35;
  margin-bottom: 4px;
}

.trending-item:hover .trending-title {
  color: #38bdf8;
}

.trending-meta {
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* SECTION DIVIDER */
.section-divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 30px 0 20px;
}

.section-divider-title {
  font-family: var(--font-editorial);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-headline);
  white-space: nowrap;
}

.section-divider-line {
  height: 1px;
  background: var(--border-subtle);
  flex: 1;
}

/* MAIN NEWS 3-COLUMN GRID */
.news-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.news-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
}

.news-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.card-thumb-wrapper {
  position: relative;
  width: 100%;
  height: 180px;
  overflow: hidden;
}

.card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.news-card:hover .card-thumb {
  transform: scale(1.03);
}

.card-stamp-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 10px;
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 800;
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1.8px solid currentColor;
  box-shadow: inset 0 0 0 1px currentColor, 0 2px 6px rgba(0, 0, 0, 0.25);
  transform: rotate(-3.5deg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 2;
  transition: transform 0.2s ease;
}

.card-stamp-badge:hover {
  transform: rotate(0deg) scale(1.05);
}

.card-body {
  padding: 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-meta {
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
}

.card-category {
  font-weight: 700;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.card-headline {
  font-family: var(--font-editorial);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-headline);
  line-height: 1.35;
  margin-bottom: 8px;
}

.card-excerpt {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 14px;
  flex: 1;
}

.card-footer {
  border-top: 1px solid var(--border-subtle);
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
}

.card-author {
  color: var(--text-dim);
}

.card-read-link {
  color: #38bdf8;
  font-weight: 600;
}

/* ==========================================================================
   TAB 2: SUBMIT NEWS & DUAL-TRACK AI SCAN
   ========================================================================== */
.ingest-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.ingest-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
}

.panel-header h2 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-headline);
}

.panel-tag {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 700;
}

.tag-blue {
  background: rgba(59, 130, 246, 0.2);
  color: #60a5fa;
}

.tag-cyan {
  background: rgba(6, 182, 212, 0.2);
  color: #22d3ee;
}

.tag-purple {
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
}

.tag-green {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.tag-amber {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
}

.tag-crimson {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

.tag-gray {
  background: rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
}

.panel-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* UPLOAD MODE TOGGLE */
.upload-mode-toggle {
  display: flex;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 4px;
  gap: 4px;
}

.mode-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.mode-btn.active {
  background: var(--bg-card);
  color: var(--text-headline);
  border: 1px solid var(--border-subtle);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

/* DOCUMENT DROP ZONE */
.document-drop-zone {
  border: 2px dashed rgba(56, 189, 248, 0.35);
  background: rgba(56, 189, 248, 0.03);
  border-radius: 10px;
  padding: 28px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.document-drop-zone.drag-active {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
}

.drop-icon {
  font-size: 2.2rem;
}

.drop-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-headline);
}

.drop-subtitle {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.parsed-file-badge {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 8px;
  padding: 10px 14px;
  width: 100%;
  max-width: 420px;
  margin-top: 10px;
}

.file-info-icon {
  font-size: 1.4rem;
}

.file-info-meta {
  flex: 1;
  text-align: left;
}

.file-info-meta strong {
  display: block;
  font-size: 0.85rem;
  color: var(--text-headline);
}

.file-info-meta span {
  font-size: 0.72rem;
  color: var(--accent-green);
}

.file-remove-btn {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.2rem;
  cursor: pointer;
}

.file-remove-btn:hover {
  color: #fff;
}

/* QUICK TEST SAMPLES */
.quick-samples {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.samples-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
}

.sample-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
}

.sample-btn:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}

.btn-sample-real {
  border-left: 3px solid var(--accent-green);
}

.btn-sample-mod {
  border-left: 3px solid var(--accent-amber);
}

.btn-sample-fake {
  border-left: 3px solid var(--accent-crimson);
}

/* FORM ELEMENTS */
.input-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-row {
  display: flex;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.form-group.flex-2 {
  flex: 2;
}

.form-group.flex-1 {
  flex: 1;
}

.form-group label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 10px 12px;
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.85rem;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--border-focus);
}

.form-group textarea {
  resize: vertical;
  line-height: 1.5;
}

.form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 6px;
  cursor: pointer;
  transition: transform 0.2s var(--ease-spring), 
              box-shadow 0.2s var(--ease-spring), 
              background-color 0.2s ease, 
              border-color 0.2s ease, 
              color 0.15s ease;
  border: none;
  font-size: 0.85rem;
  will-change: transform;
}

.btn:hover {
  transform: translateY(-1.5px);
}

.btn:active {
  transform: scale(0.96) !important;
}

.btn-primary {
  background: #2563eb;
  color: #fff;
}

.btn-primary:hover {
  background: #1d4ed8;
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

.btn-secondary {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-headline);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.btn-amber {
  background: #d97706;
  color: #fff;
}

.btn-amber:hover {
  background: #b45309;
  box-shadow: 0 6px 18px rgba(217, 119, 6, 0.45);
}

.btn-crimson {
  background: #dc2626;
  color: #fff;
}

.btn-crimson:hover {
  background: #b91c1c;
  box-shadow: 0 6px 18px rgba(220, 38, 38, 0.45);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.78rem;
}

.btn-xs {
  padding: 4px 8px;
  font-size: 0.7rem;
}

.btn-block {
  width: 100%;
}

.cache-bypass-label {
  font-size: 0.78rem;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

/* SCAN VERDICT DISPLAY */
.result-display {
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: receiptReveal 0.45s var(--ease-spring) both;
}

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px 16px;
}

.verdict-banner {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.verdict-badge {
  font-size: 0.95rem;
  font-weight: 900;
  letter-spacing: 0.05em;
}

.verdict-action {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.latency-indicator {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.latency-val {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 800;
}

.latency-badge {
  font-size: 0.65rem;
  font-family: var(--font-mono);
  color: var(--accent-green);
}

/* PROBABILITY PROGRESS BARS */
.probability-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.prob-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.prob-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.progress-track {
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s ease;
}

.fill-fake {
  background: linear-gradient(90deg, #f87171, #ef4444);
}

.fill-real {
  background: linear-gradient(90deg, #34d399, #10b981);
}

/* DUAL TRACK CARDS */
.tracks-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.track-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.track-title {
  display: flex;
  align-items: center;
  gap: 6px;
}

.track-title h3 {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-headline);
}

.track-tag {
  font-size: 0.65rem;
  font-family: var(--font-mono);
  font-weight: 800;
  padding: 2px 4px;
  border-radius: 3px;
}

.track-stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  font-family: var(--font-mono);
}

.track-details {
  font-size: 0.72rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border-subtle);
  padding-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* XAI BOX */
.xai-box {
  background: rgba(10, 14, 23, 0.85);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 14px;
}

.xai-header {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text-headline);
  margin-bottom: 8px;
}

.xai-list {
  list-style: none;
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.xai-list li::before {
  content: "•";
  color: var(--accent-cyan);
  display: inline-block;
  width: 1em;
}

.submission-notice {
  padding: 12px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 700;
}

.notice-published {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.notice-pending {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.notice-blocked {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #f87171;
}

.scan-placeholder {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-dim);
}

.placeholder-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.scan-placeholder h3 {
  color: var(--text-headline);
  font-size: 1.1rem;
  margin-bottom: 6px;
}

/* ==========================================================================
   TAB 3: MY SUBMISSIONS (CITIZEN JOURNALIST VIEW)
   ========================================================================== */
.submissions-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-newspaper);
  padding-bottom: 14px;
  margin-bottom: 24px;
}

.submissions-header h2 {
  font-family: var(--font-editorial);
  font-size: 1.6rem;
  color: var(--text-headline);
}

.section-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.submissions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.submission-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.submission-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.submission-title {
  font-family: var(--font-editorial);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-headline);
}

.submission-body {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.submission-card-footer {
  border-top: 1px solid var(--border-subtle);
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
}

/* ==========================================================================
   TAB 4: ADMIN EDITORIAL & 3-FAMILY UNLEARNING
   ========================================================================== */
.admin-top-banner {
  background: linear-gradient(90deg, rgba(239, 68, 68, 0.15) 0%, rgba(13, 18, 31, 0.9) 100%);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 10px;
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.admin-badge {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--accent-crimson);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.admin-top-banner h2 {
  font-family: var(--font-editorial);
  font-size: 1.5rem;
  color: var(--text-headline);
}

.admin-quick-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.stat-mini {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.stat-mini-val {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 800;
}

.stat-mini-label {
  font-size: 0.7rem;
  color: var(--text-dim);
}

.admin-split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
  gap: 24px;
  align-items: start;
}

.admin-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

.admin-card {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 10px;
}

.card-header h3 {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-headline);
}

.header-crimson {
  border-bottom-color: rgba(239, 68, 68, 0.3);
}

.header-amber {
  border-bottom-color: rgba(245, 158, 11, 0.3);
}

.header-green {
  border-bottom-color: rgba(16, 185, 129, 0.3);
}

.card-caption {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.queue-items-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 480px;
  overflow-y: auto;
}

.queue-item-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.queue-item-card:hover {
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateX(2px);
}

.queue-item-card.selected {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.08);
}

.queue-item-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.queue-item-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-headline);
  line-height: 1.35;
}

.queue-actions-row {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

/* UNLEARNING WORKBENCH */
.target-inspector {
  background: rgba(10, 14, 23, 0.85);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.target-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.target-id {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--accent-crimson);
}

.target-headline {
  font-family: var(--font-editorial);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-headline);
}

.target-excerpt {
  font-size: 0.82rem;
  color: var(--text-newspaper);
  line-height: 1.45;
}

.unlearning-selector-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.selector-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.selector-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
}

.algorithm-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
  gap: 12px;
}

.algo-card-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 14px;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.algo-card-btn:hover {
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.algo-card-btn.active {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.08);
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.15);
}

.algo-family-tag {
  font-size: 0.65rem;
  font-family: var(--font-mono);
  font-weight: 800;
  display: inline-block;
}

.algo-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-headline);
}

.algo-family {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.algo-complexity {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
}

.algo-desc {
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-top: 2px;
}

/* BENCHMARK RESULTS TABLE */
.benchmark-results-box {
  background: rgba(10, 14, 23, 0.9);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 16px;
  overflow-x: auto;
}

.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.results-header h4 {
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--text-headline);
}

.benchmark-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.benchmark-table th {
  text-align: left;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-weight: 700;
  border-bottom: 1px solid var(--border-subtle);
}

.benchmark-table td {
  padding: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-main);
}

.benchmark-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* 6-STEP PURGE STEPPER */
.purge-stepper-box {
  background: rgba(10, 14, 23, 0.75);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 16px;
}

.stepper-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.stepper-header h4 {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-headline);
}

.stepper-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: transform 0.28s var(--ease-spring), 
              border-color 0.25s ease, 
              background-color 0.25s ease, 
              box-shadow 0.25s ease;
}

.step-card.step-active {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
  transform: scale(1.025);
  animation: stepCardPulse 1.2s infinite alternate ease-in-out;
}

.step-card.step-complete {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.25);
  transform: scale(1);
}

.step-badge {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  transition: all 0.3s var(--ease-spring);
}

.step-card.step-complete .step-badge {
  background: #10b981;
  color: #fff;
  animation: checkPop 0.45s var(--ease-spring);
}

.step-info {
  flex: 1;
}

.step-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-headline);
}

.step-desc {
  font-size: 0.68rem;
  color: var(--text-dim);
}

.step-time {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--accent-green);
}

/* PERSISTENT UNLEARNING AUDIT LEDGER */
.ledger-box {
  background: rgba(10, 14, 23, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 16px;
}

.ledger-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.ledger-header h4 {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-headline);
}

.ledger-table-wrapper {
  max-height: 220px;
  overflow-x: auto;
  overflow-y: auto;
}

.ledger-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75rem;
}

.ledger-table th {
  text-align: left;
  padding: 6px 8px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--border-subtle);
}

.ledger-table td {
  padding: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* ==========================================================================
   TAB 5: WEBSOCKET AUDIT TERMINAL
   ========================================================================== */
.audit-terminal-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 12px;
  padding: 24px;
}

.terminal-window {
  background: #05080f;
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 16px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: #e2e8f0;
  height: 480px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.terminal-line {
  line-height: 1.4;
  word-break: break-all;
}

.term-time {
  color: var(--text-dim);
  margin-right: 8px;
}

.term-ev {
  color: var(--accent-cyan);
  font-weight: 700;
  margin-right: 6px;
}

/* ==========================================================================
   MODAL WINDOWS (ARTICLE READER & AUTH)
   ========================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(4, 8, 16, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: modalBackdropFadeIn 0.32s var(--ease-spring) forwards;
}

.article-modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 14px;
  width: 100%;
  max-width: 820px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: 0 25px 65px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.08);
  animation: modalSpringIn 0.38s var(--ease-spring) forwards;
  transform-origin: center center;
}

.modal-close-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-headline);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  background: var(--bg-card-hover);
}

.modal-meta-row {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 8px;
}

.modal-category {
  color: var(--accent-cyan);
  font-weight: 700;
  text-transform: uppercase;
}

.modal-title {
  font-family: var(--font-editorial);
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--text-headline);
  line-height: 1.2;
  margin-bottom: 12px;
}

.modal-author-row {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.modal-image-wrapper {
  width: 100%;
  height: 320px;
  border-radius: 8px;
  overflow: hidden;
}

.modal-banner-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-body-content {
  font-family: var(--font-editorial);
  font-size: 1.05rem;
  line-height: 1.7;
  color: #e2e8f0;
}

.fact-certificate-box {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 10px;
  padding: 20px;
  margin-top: 10px;
}

.cert-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.cert-seal {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent-green);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  font-weight: 900;
}

.cert-header h3 {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-headline);
  letter-spacing: 0.04em;
}

.cert-subtext {
  font-size: 0.72rem;
  font-family: var(--font-mono);
  color: var(--accent-green);
}

.cert-meters-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}

.cert-meter {
  background: rgba(0, 0, 0, 0.4);
  border-radius: 6px;
  padding: 10px;
  text-align: center;
}

.cert-meter-name {
  display: block;
  font-size: 0.68rem;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.cert-meter-val {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 800;
}

.cert-rationale {
  font-size: 0.78rem;
  color: var(--text-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 10px;
  font-style: italic;
}

/* AUTH MODAL */
.auth-modal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-radius: 14px;
  width: 100%;
  max-width: 440px;
  padding: 32px;
  position: relative;
  box-shadow: 0 25px 65px rgba(0, 0, 0, 0.85);
  animation: modalSpringIn 0.38s var(--ease-spring) forwards;
  transform-origin: center center;
}

.editorial-edit-modal-card {
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 25px 65px rgba(0, 0, 0, 0.85);
  animation: modalSpringIn 0.38s var(--ease-spring) forwards;
  transform-origin: center center;
}

.auth-header {
  text-align: center;
  margin-bottom: 20px;
}

.auth-header h2 {
  font-family: var(--font-editorial);
  font-size: 1.5rem;
  color: var(--text-headline);
  margin-bottom: 4px;
}

.auth-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.auth-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 20px;
}

.auth-tab-btn {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 10px;
  cursor: pointer;
}

.auth-tab-btn.active {
  color: #38bdf8;
  border-bottom-color: #38bdf8;
}

.demo-login-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 20px;
}

.demo-title {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.demo-buttons {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.demo-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 8px 12px;
  color: var(--text-headline);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
}

.demo-btn:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.25);
}

.demo-journalist {
  border-left: 3px solid var(--accent-green);
}

.demo-admin {
  border-left: 3px solid var(--accent-amber);
}

/* RESPONSIVE BREAKPOINTS */
@media (max-width: 1024px) {
  .newspaper-grid-layout {
    grid-template-columns: 1fr;
  }

  .news-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ingest-wrapper {
    grid-template-columns: 1fr;
  }

  .admin-split-grid {
    grid-template-columns: 1fr;
  }

  .algorithm-cards-grid {
    grid-template-columns: 1fr;
  }

  .cert-meters-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .news-cards-grid {
    grid-template-columns: 1fr;
  }

  .stepper-grid {
    grid-template-columns: 1fr;
  }

  .masthead-meta-row {
    flex-direction: column;
    gap: 8px;
  }

  .newspaper-title {
    font-size: 2.2rem;
  }

  .nav-meters {
    display: none;
  }
}

.accent-green {
  color: var(--accent-green);
}

.accent-crimson {
  color: var(--accent-crimson);
}

.accent-amber {
  color: var(--accent-amber);
}

.accent-cyan {
  color: var(--accent-cyan);
}

.accent-purple {
  color: var(--accent-purple);
}

/* ==========================================================================
   ENHANCED FEATURES: SEARCH, HEATMAP, SHARDS, PROBE & TOASTS
   ========================================================================== */

/* LIVE SEARCH BAR */
.nav-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 4px 12px;
  margin: 0;
  flex: 1 1 220px;
  min-width: 180px;
  max-width: 320px;
}

.search-icon {
  font-size: 0.8rem;
  color: var(--text-dim);
}

.nav-search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 0.8rem;
  width: 100%;
}

.nav-search-box input::placeholder {
  color: var(--text-dim);
}

/* LINGUISTIC DECEPTION HEATMAP */
.heatmap-panel {
  background: rgba(10, 14, 23, 0.9);
  border: 1px solid rgba(168, 85, 247, 0.35);
  border-radius: 8px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.heatmap-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.heatmap-title {
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text-headline);
}

.arousal-indicator {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--accent-purple);
}

.heatmap-text-container {
  background: #060911;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 12px;
  font-family: var(--font-editorial);
  font-size: 0.95rem;
  line-height: 1.6;
  color: #e2e8f0;
  max-height: 180px;
  overflow-y: auto;
}

.token-cue {
  padding: 2px 4px;
  border-radius: 3px;
  font-weight: 700;
  cursor: help;
  transition: all 0.2s;
}

.cue-urgency_manipulation,
.cue-urgency {
  background: rgba(239, 68, 68, 0.35);
  color: #fca5a5;
  border-bottom: 2px solid #ef4444;
}

.cue-sensationalism {
  background: rgba(245, 158, 11, 0.35);
  color: #fde68a;
  border-bottom: 2px solid #f59e0b;
}

.cue-conspiratorial_framing,
.cue-conspiratorial {
  background: rgba(168, 85, 247, 0.35);
  color: #e9d5ff;
  border-bottom: 2px solid #a855f7;
}

.cue-exclamation_amplification,
.cue-punctuation {
  background: rgba(6, 182, 212, 0.35);
  color: #a5f3fc;
  border-bottom: 2px solid #06b6d4;
}

.cue-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.7rem;
  color: var(--text-dim);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 8px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

/* SISA 5-SHARD PARTITION ARCHITECTURE VISUALIZER */
.shards-visualizer-box {
  background: rgba(10, 14, 23, 0.85);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.shards-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.shards-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-headline);
}

.shards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.shards-grid > * {
  min-width: 0;
}

.shard-node-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: transform 0.3s var(--ease-spring), 
              border-color 0.25s ease, 
              background-color 0.25s ease, 
              box-shadow 0.25s ease;
  position: relative;
  overflow: hidden;
}

.shard-node-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}

.shard-node-card.shard-purging {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.18);
  animation: shardPurgeIntense 0.35s infinite alternate ease-in-out;
}

.shard-node-card.shard-purging::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(239, 68, 68, 0.6), transparent);
  animation: shardLaserSweep 0.75s infinite linear;
  pointer-events: none;
}

.shard-node-card.shard-purged {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.16);
  animation: shardPurgedSuccess 0.6s var(--ease-spring) forwards;
}

.shard-node-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 4px;
}

.shard-name {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--text-headline);
}

.shard-status-tag {
  font-size: 0.62rem;
  font-family: var(--font-mono);
  font-weight: 800;
}

.shard-stat-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-dim);
}

.shard-stat-line code {
  font-size: 0.65rem;
  color: var(--accent-cyan);
}

/* RESIDUAL MEMORY PROBE TESTER */
.probe-tester-box {
  background: rgba(10, 14, 23, 0.85);
  border: 1px solid rgba(6, 182, 212, 0.35);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.probe-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.probe-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-headline);
}

.probe-input-row {
  display: flex;
  gap: 10px;
}

.probe-input-row input {
  flex: 1;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 8px 12px;
  color: var(--text-main);
  font-size: 0.82rem;
}

.probe-result-card {
  background: rgba(6, 182, 212, 0.06);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: fadeIn 0.2s ease-in;
}

.probe-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  text-align: center;
}

.probe-metric {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 6px;
  padding: 6px;
}

.probe-metric .metric-label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-dim);
  margin-bottom: 2px;
}

.probe-guarantee-text {
  font-size: 0.72rem;
  color: var(--text-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 6px;
  font-style: italic;
}

/* MODAL ACTION BAR */
.modal-action-bar {
  display: flex;
  gap: 10px;
  margin-top: 8px;
  flex-wrap: wrap;
}

/* FLOATING TOAST NOTIFICATIONS */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 2000;
  pointer-events: none;
}

.toast-message {
  pointer-events: auto;
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 14px 18px;
  font-size: 0.85rem;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.65), 0 0 1px rgba(255, 255, 255, 0.2);
  animation: toastSpringIn 0.38s var(--ease-spring) forwards;
  min-width: 300px;
  max-width: 440px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s var(--ease-spring);
}

.toast-message.toast-dismissing {
  animation: toastSpringOut 0.35s var(--ease-spring) forwards !important;
}

.toast-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  font-size: 1rem;
}

.toast-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 100%;
  background: var(--accent-cyan);
  animation: toastProgressSweep 3.8s linear forwards;
}

.toast-success {
  border-left: 4px solid var(--accent-green);
}
.toast-success .toast-progress-bar {
  background: var(--accent-green);
}

.toast-alert, .toast-error {
  border-left: 4px solid var(--accent-crimson);
}
.toast-alert .toast-progress-bar, .toast-error .toast-progress-bar {
  background: var(--accent-crimson);
}

.toast-info {
  border-left: 4px solid var(--accent-cyan);
}

.toast-warning {
  border-left: 4px solid var(--accent-amber);
}
.toast-warning .toast-progress-bar {
  background: var(--accent-amber);
}

/* ==========================================================================
   MASTHEAD AUTHENTICATION & PROFILE CONTROLS
   ========================================================================== */
.auth-actions-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-auth-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.nav-auth-btn.btn-signin {
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.35);
}

.nav-auth-btn.btn-signin:hover {
  background: rgba(56, 189, 248, 0.22);
  transform: translateY(-1px);
}

.nav-auth-btn.btn-register {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #fff;
  border: none;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.nav-auth-btn.btn-register:hover {
  opacity: 0.92;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

/* ==========================================================================
   CONSOLIDATED PROFILE & READER SETTINGS DRAWER
   ========================================================================== */
.profile-settings-wrapper {
  position: relative;
  display: inline-block;
  z-index: 100;
}

.profile-settings-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 24px;
  padding: 5px 14px 5px 8px;
  cursor: pointer;
  color: var(--text-headline);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.profile-settings-btn:hover {
  background: var(--bg-card);
  border-color: var(--accent-blue);
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.15);
  transform: translateY(-1px);
}

.user-avatar-mini {
  font-size: 1.1rem;
  line-height: 1;
}

.user-name-label {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--text-headline);
}

.settings-gear-icon {
  font-size: 0.85rem;
  opacity: 0.7;
  transition: transform 0.3s ease;
}

.profile-settings-btn:hover .settings-gear-icon {
  transform: rotate(45deg);
  opacity: 1;
}

/* BROADSHEET PROFILE DRAWER DROPDOWN */
.profile-settings-drawer {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 320px;
  background: var(--bg-card);
  border: 1.5px solid var(--border-newspaper);
  border-radius: 10px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35), 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 16px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: profileDrawerSlide 0.25s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes profileDrawerSlide {
  0% {
    opacity: 0;
    transform: translateY(-8px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.drawer-user-card {
  display: flex;
  align-items: center;
  gap: 12px;
}

.drawer-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.drawer-user-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.drawer-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-headline);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.drawer-email {
  font-size: 0.72rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.drawer-role-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.drawer-role-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
}

.drawer-role-badge {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0.04em;
}

.drawer-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 2px 0;
}

.drawer-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drawer-section-title {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dim);
}

.drawer-mode-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.drawer-mode-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  position: relative;
}

.drawer-mode-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-blue);
  transform: translateX(2px);
}

.drawer-mode-btn.active {
  background: rgba(2, 132, 199, 0.08);
  border-color: var(--accent-blue);
}

.mode-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.mode-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.mode-info strong {
  font-size: 0.8rem;
  color: var(--text-headline);
}

.mode-info small {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.mode-check {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent-blue);
  opacity: 0;
}

.drawer-mode-btn.active .mode-check {
  opacity: 1;
}

.drawer-lang-grid {
  display: flex;
  gap: 6px;
}

.drawer-lang-btn {
  flex: 1;
  padding: 6px 4px;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s ease;
}

.drawer-lang-btn:hover {
  border-color: var(--accent-blue);
  background: var(--bg-card-hover);
}

.drawer-lang-btn.active {
  background: var(--accent-blue);
  color: #fff;
  border-color: var(--accent-blue);
}

.drawer-actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 4px;
}

/* REALISTIC BROADSHEET SCROLLING PAGE-TURN TRANSITIONS */
.newspaper-dispatch-card,
.featured-hero-article,
.trending-item,
.submission-card {
  opacity: 1;
  transform: perspective(1400px) rotateX(0deg) translateY(0) scale(1);
  transition: box-shadow 0.35s ease,
              border-color 0.25s ease,
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.newspaper-dispatch-card:hover,
.submission-card:hover {
  transform: perspective(1400px) rotateX(1deg) translateY(-4px) scale(1.008);
}

.newspaper-dispatch-card.paper-scrolled-in,
.featured-hero-article.paper-scrolled-in,
.trending-item.paper-scrolled-in,
.submission-card.paper-scrolled-in {
  opacity: 1;
  transform: perspective(1400px) rotateX(0deg) translateY(0) scale(1);
}

.user-profile-widget {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-logout {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
  border-radius: 16px;
  padding: 5px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.btn-logout:hover {
  background: rgba(239, 68, 68, 0.25);
  color: #fff;
}

/* ==========================================================================
   ANIME NEWS ANCHOR BROADCAST DESK
   ========================================================================== */
.anime-anchor-broadcast-card {
  display: flex;
  align-items: center;
  gap: 24px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(30, 41, 59, 0.85) 100%);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 12px;
  padding: 18px 24px;
  margin-bottom: 24px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}

.anime-anchor-broadcast-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ef4444, #f59e0b, #10b981, #06b6d4, #8b5cf6);
}

.anchor-avatar-box {
  position: relative;
  flex-shrink: 0;
  width: 140px;
  height: 140px;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid rgba(56, 189, 248, 0.5);
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.25);
}

.anchor-portrait {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.live-stream-badge {
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(239, 68, 68, 0.9);
  color: #fff;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  backdrop-filter: blur(4px);
}

.pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
  animation: pulseBlink 1.2s infinite;
}

@keyframes pulseBlink {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.3;
    transform: scale(0.8);
  }
}

.anchor-briefing-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.anchor-identity {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.anchor-name-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.anchor-name {
  font-family: var(--font-headline);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-headline);
  letter-spacing: -0.01em;
}

.anchor-badge {
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
  padding: 2px 8px;
  border-radius: 12px;
}

.anchor-studio-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent-cyan);
}

.anchor-channel-status {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.status-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  margin-right: 4px;
}

.anchor-dialogue {
  font-family: var(--font-body);
  font-size: 0.88rem;
  line-height: 1.5;
  color: #e2e8f0;
  background: rgba(0, 0, 0, 0.25);
  border-left: 3px solid var(--accent-cyan);
  padding: 8px 14px;
  border-radius: 0 8px 8px 0;
}

.anchor-actions-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 2px;
}

/* ==========================================================================
   FILTER CONTROLS ROW & LANGUAGE PILLS
   ========================================================================== */
.filter-controls-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.language-filters-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.lang-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.74rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lang-pill:hover {
  background: var(--bg-card-hover);
  color: var(--text-headline);
  border-color: var(--border-focus);
}

.lang-pill.active {
  background: rgba(245, 158, 11, 0.18);
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.45);
}

/* ==========================================================================
   RECOMMENDED BEST MODEL BANNER & METRICS TABLE
   ========================================================================== */
.recommended-model-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12) 0%, rgba(16, 185, 129, 0.08) 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: 10px;
  padding: 14px 20px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.rec-banner-badge {
  font-size: 0.68rem;
  font-weight: 800;
  background: #f59e0b;
  color: #0f172a;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.rec-banner-content {
  flex: 1;
  min-width: 260px;
}

.rec-banner-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-headline);
  margin-bottom: 3px;
}

.rec-banner-desc {
  font-size: 0.78rem;
  color: #cbd5e1;
  line-height: 1.4;
}

.btn-rec-action {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #0f172a;
  font-weight: 800;
  border: none;
  padding: 8px 18px;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
  white-space: nowrap;
}

.btn-rec-action:hover {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  transform: translateY(-1px);
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.benchmark-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.benchmark-table th {
  background: rgba(15, 23, 42, 0.8);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.benchmark-table td {
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: middle;
}

.row-recommended {
  background: rgba(245, 158, 11, 0.06);
  border-left: 3px solid #f59e0b;
}

.rec-star-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 800;
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
  padding: 1px 6px;
  border-radius: 8px;
  margin-left: 6px;
  vertical-align: middle;
}

.metric-pair {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

.m-before {
  color: var(--text-dim);
}

.m-after {
  color: #38bdf8;
  font-weight: 700;
}

/* ==========================================================================
   AUTHENTIC BROADSHEET NEWSPAPER ARTICLE STYLING
   ========================================================================== */
.newspaper-dispatch-card {
  background: var(--bg-card);
  border: 1px solid var(--border-newspaper);
  border-top: 3px double var(--border-newspaper);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.35s var(--ease-spring), 
              box-shadow 0.35s var(--ease-spring), 
              border-color 0.25s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.35);
  animation: cardCascadeIn 0.42s var(--ease-spring) both;
  will-change: transform, box-shadow;
}

.newspaper-dispatch-card:hover {
  transform: translateY(-6px) translateZ(0);
  border-color: rgba(56, 189, 248, 0.65);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.55), 0 0 20px rgba(56, 189, 248, 0.2);
}

.newspaper-dispatch-card .card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-spring), filter 0.5s ease;
}

.newspaper-dispatch-card:hover .card-thumb {
  transform: scale(1.055);
  filter: contrast(1.05) brightness(1.03);
}

.newspaper-dispatch-card:hover .broadsheet-headline {
  color: #38bdf8;
  transition: color 0.2s ease;
}

.newspaper-dispatch-card .card-read-link {
  transition: transform 0.22s var(--ease-spring), color 0.2s ease;
  display: inline-block;
}

.newspaper-dispatch-card:hover .card-read-link {
  transform: translateX(4px);
  color: #38bdf8;
}

.dispatch-header-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 12px;
  background: rgba(15, 23, 42, 0.85);
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.65rem;
}

.dispatch-kicker {
  font-weight: 800;
  color: var(--accent-cyan);
  letter-spacing: 0.08em;
}

.dispatch-vol {
  color: var(--text-dim);
  font-size: 0.62rem;
}

.newspaper-dateline-row {
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-bottom: 6px;
  font-family: var(--font-mono);
}

.newspaper-location {
  font-weight: 800;
  color: var(--accent-amber);
  letter-spacing: 0.04em;
}

.newspaper-date {
  color: var(--text-dim);
}

.broadsheet-headline {
  font-family: var(--font-editorial);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-headline);
  margin-bottom: 8px;
}

.newspaper-card-rule {
  height: 1px;
  background: var(--border-subtle);
  margin: 12px 0 10px;
}

/* ==========================================================================
   BROADSHEET MODAL SPREAD & TYPOGRAPHY
   ========================================================================== */
@keyframes broadsheetModalUnfold {
  0% {
    opacity: 0;
    transform: perspective(1600px) rotateY(-8deg) scale(0.93) translateY(24px);
  }
  60% {
    transform: perspective(1600px) rotateY(1.5deg) scale(1.008) translateY(-3px);
  }
  100% {
    opacity: 1;
    transform: perspective(1600px) rotateY(0deg) scale(1) translateY(0);
  }
}

.broadsheet-modal-card {
  max-width: 960px;
  background: var(--bg-card);
  border: 2px solid var(--border-newspaper);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
  position: relative;
  animation: broadsheetModalUnfold 0.42s cubic-bezier(0.16, 1, 0.3, 1) both;
  overflow: hidden;
}

/* Authentic physical newspaper center crease spine shadow */
.broadsheet-modal-card::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 36px;
  transform: translateX(-50%);
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.04) 42%,
    rgba(0, 0, 0, 0.10) 50%,
    rgba(255, 255, 255, 0.04) 52%,
    rgba(0, 0, 0, 0) 100%
  );
  pointer-events: none;
  z-index: 5;
}

/* Authentic physical dog-ear folded corner */
.broadsheet-modal-card::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, transparent 50%, rgba(0, 0, 0, 0.18) 50%, rgba(230, 220, 200, 0.95) 55%);
  border-bottom-left-radius: 4px;
  box-shadow: -2px 2px 5px rgba(0, 0, 0, 0.2);
  pointer-events: none;
  z-index: 6;
}

.broadsheet-paper-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 14px;
  background: var(--bg-card-hover);
  border-bottom: 2px solid var(--border-newspaper);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  text-transform: uppercase;
  position: relative;
  z-index: 2;
}

.paper-header-left {
  font-weight: 800;
  color: var(--accent-cyan);
}

.paper-header-center {
  font-style: italic;
  color: var(--text-muted);
}

.paper-header-right {
  color: var(--accent-amber);
}

.broadsheet-body-content {
  font-family: var(--font-editorial);
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text-newspaper);
  margin: 18px 0;
  text-align: justify;
  position: relative;
  z-index: 2;
}

@media (min-width: 768px) {
  .broadsheet-body-content {
    columns: 2;
    column-gap: 36px;
    column-rule: 1px solid var(--border-subtle);
  }
  .broadsheet-pull-quote,
  .broadsheet-printer-slug {
    column-span: all;
  }
}

.newspaper-lead-para {
  margin-bottom: 14px;
}

.newspaper-drop-cap {
  float: left;
  font-family: var(--font-masthead);
  font-size: 3.4rem;
  line-height: 0.8;
  font-weight: 900;
  color: var(--accent-cyan);
  padding: 4px 8px 0 0;
  margin-right: 4px;
  text-shadow: 0 2px 8px rgba(6, 182, 212, 0.3);
}

.newspaper-body-para {
  margin-bottom: 12px;
  text-indent: 1.5em;
}

.broadsheet-pull-quote {
  border-left: 3px solid var(--accent-amber);
  border-right: 3px solid var(--accent-amber);
  background: rgba(245, 158, 11, 0.05);
  margin: 18px 10px;
  padding: 12px 20px;
  font-size: 1.15rem;
  font-style: italic;
  color: #fef3c7;
  text-align: center;
  border-radius: 4px;
}

.broadsheet-printer-slug {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  border-top: 1px dashed var(--border-subtle);
  padding-top: 12px;
  margin-top: 20px;
  text-align: center;
  letter-spacing: 0.04em;
}

.citizen-cert-box {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(6, 182, 212, 0.05) 100%);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.admin-cert-box {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.08) 0%, rgba(239, 68, 68, 0.05) 100%);
  border: 1px solid rgba(168, 85, 247, 0.3);
}


/* ==========================================================================
   SMRITI SHUDDHI BRANDING & MULTILINGUAL / AUDIO STYLING
   ========================================================================== */
.newspaper-title-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.devanagari-masthead-title {
  font-family: var(--font-masthead), serif;
  font-size: 1.4rem;
  letter-spacing: 0.18em;
  color: var(--accent-amber);
  margin-top: -6px;
  font-weight: 700;
  text-shadow: 0 0 16px rgba(245, 158, 11, 0.4);
}

.lang-switch-group {
  display: inline-flex;
  align-items: center;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 2px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.lang-ui-btn {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lang-ui-btn:hover {
  color: var(--text-headline);
}

.lang-ui-btn.active {
  background: linear-gradient(135deg, var(--accent-cyan) 0%, #0284c7 100%);
  color: #000;
  font-weight: 800;
  box-shadow: 0 2px 8px rgba(6, 182, 212, 0.4);
}

/* INTERACTIVE MULTILINGUAL AUDIO PLAYER CONSOLE */
.audio-player-console {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(30, 41, 59, 0.9) 100%);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 8px;
  padding: 12px 16px;
  margin: 14px 0 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.audio-console-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.audio-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: #94a3b8;
}

.audio-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #64748b;
  display: inline-block;
  transition: background 0.3s ease;
}

.audio-status-dot.speaking {
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulseDot 1s infinite alternate;
}

.audio-lang-indicator {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.2);
  padding: 2px 8px;
  border-radius: 12px;
}

.audio-speed-group {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.speed-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
}

.speed-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.speed-btn:hover {
  border-color: var(--accent-cyan);
  color: var(--text-headline);
}

.speed-btn.active {
  background: var(--accent-cyan);
  color: #0f172a;
  border-color: var(--accent-cyan);
  font-weight: 800;
}

.audio-console-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.audio-btn-cluster {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-audio-play {
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  color: #ffffff;
  border: none;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 7px 16px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 10px rgba(14, 165, 233, 0.4);
  transition: all 0.2s ease;
}

.btn-audio-play:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(14, 165, 233, 0.6);
}

.btn-audio-play.speaking {
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
  box-shadow: 0 2px 10px rgba(217, 119, 6, 0.4);
}

.btn-audio-stop {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.btn-audio-stop:hover {
  background: rgba(239, 68, 68, 0.3);
  color: #ffffff;
}

/* ANIMATED EQUALIZER BARS */
.audio-equalizer-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  height: 22px;
  padding: 0 6px;
}

.eq-bar {
  width: 3px;
  height: 4px;
  background: var(--accent-cyan);
  border-radius: 1px;
  transition: height 0.15s ease;
}

.audio-equalizer-bars.active .eq-bar:nth-child(1) {
  animation: eqBounce 0.4s infinite ease-in-out alternate;
}

.audio-equalizer-bars.active .eq-bar:nth-child(2) {
  animation: eqBounce 0.6s infinite ease-in-out alternate 0.1s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(3) {
  animation: eqBounce 0.35s infinite ease-in-out alternate 0.2s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(4) {
  animation: eqBounce 0.5s infinite ease-in-out alternate 0.15s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(5) {
  animation: eqBounce 0.45s infinite ease-in-out alternate 0.05s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(6) {
  animation: eqBounce 0.55s infinite ease-in-out alternate 0.25s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(7) {
  animation: eqBounce 0.38s infinite ease-in-out alternate 0.18s;
}

.audio-equalizer-bars.active .eq-bar:nth-child(8) {
  animation: eqBounce 0.48s infinite ease-in-out alternate 0.08s;
}

@keyframes eqBounce {
  0% {
    height: 4px;
    background: #0284c7;
  }

  50% {
    height: 18px;
    background: #06b6d4;
  }

  100% {
    height: 8px;
    background: #10b981;
  }
}

.modal-utility-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dispatch-audio-listen-btn {
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  color: var(--accent-cyan);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: transform 0.22s var(--ease-spring), 
              background-color 0.2s ease, 
              color 0.2s ease, 
              box-shadow 0.22s var(--ease-spring);
}

.dispatch-audio-listen-btn:hover {
  background: var(--accent-cyan);
  color: #0f172a;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.4);
}

.dispatch-audio-listen-btn:active {
  transform: scale(0.95) !important;
}


/* ==========================================================================
   THEME TOGGLE BUTTON GROUP
   ========================================================================== */
.theme-switch-group {
  display: inline-flex;
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 2px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.theme-ui-btn {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.theme-ui-btn:hover {
  color: var(--text-main);
}

.theme-ui-btn.active {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  font-weight: 800;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.35);
}

[data-theme="dark"] .theme-ui-btn.active {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(2, 132, 199, 0.35);
}

/* ==========================================================================
   LIGHT MODE COMPREHENSIVE STYLING (ZERO WHITE-ON-LIGHT ISSUES)
   ========================================================================== */
[data-theme="light"] {
  --bg-dark: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5f9;
  --bg-surface: #ffffff;
  --bg-input: #f8fafc;
  --bg-header-bar: #f1f5f9;

  --border-subtle: #cbd5e1;
  --border-focus: #0284c7;
  --border-newspaper: #94a3b8;
  --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.06);
  --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.1);

  --text-main: #0f172a;
  --text-muted: #334155;
  --text-dim: #64748b;
  --text-newspaper: #1e293b;
  --text-headline: #0f172a;

  --accent-green: #16a34a;
  --accent-crimson: #dc2626;
  --accent-amber: #d97706;
  --accent-cyan: #0284c7;
}

[data-theme="light"] body {
  background-color: #f8fafc;
  color: #0f172a;
}

[data-theme="light"] .layout-container {
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .newspaper-dispatch-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-top: 3px double #94a3b8;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .newspaper-dispatch-card:hover {
  border-color: #0284c7;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .dispatch-header-line {
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  color: #0f172a;
}

[data-theme="light"] .card-headline,
[data-theme="light"] .broadsheet-headline {
  color: #0f172a;
}

[data-theme="light"] .card-excerpt {
  color: #334155;
}

[data-theme="light"] .featured-hero-article {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-top: 4px double #0f172a;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .hero-title {
  color: #0f172a !important;
}

[data-theme="light"] .hero-excerpt {
  color: #1e293b;
}

[data-theme="light"] .hero-excerpt::first-letter {
  color: #dc2626;
}

[data-theme="light"] .trending-wire-sidebar {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-top: 4px double #0f172a;
}

[data-theme="light"] .sidebar-header h3 {
  color: #0f172a;
}

[data-theme="light"] .trending-title {
  color: #0f172a;
}

[data-theme="light"] .nav-tab {
  color: #334155;
}

[data-theme="light"] .nav-tab:hover {
  color: #0f172a;
  background: #f1f5f9;
}

[data-theme="light"] .nav-tab.active {
  color: #0f172a;
  background: #ffffff;
  border-color: #0284c7;
  border-bottom: 3px solid #0284c7;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .btn-secondary {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .btn-secondary:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  color: #0f172a;
}

/* Light Mode Admin Workbench */
[data-theme="light"] .admin-panel-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .admin-top-banner {
  background: linear-gradient(135deg, #ffffff 0%, #f1f5f9 100%);
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .admin-top-banner h2 {
  color: #0f172a;
}

[data-theme="light"] .admin-top-banner p {
  color: #475569;
}

[data-theme="light"] .queue-item-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .queue-item-card:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
}

[data-theme="light"] .queue-item-card.selected {
  border-color: #ef4444;
  background: #fef2f2;
}

[data-theme="light"] .queue-item-title {
  color: #0f172a;
}

[data-theme="light"] .queue-item-meta {
  color: #64748b;
}

[data-theme="light"] .target-inspector {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .target-headline {
  color: #0f172a;
}

[data-theme="light"] .target-excerpt {
  color: #334155;
}

[data-theme="light"] .algo-card-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .algo-card-btn:hover {
  border-color: #0284c7;
  background: #f8fafc;
}

[data-theme="light"] .algo-card-btn.active {
  border-color: #16a34a;
  background: #f0fdf4;
  box-shadow: 0 4px 15px rgba(22, 163, 74, 0.12);
}

[data-theme="light"] .algo-name {
  color: #0f172a;
}

[data-theme="light"] .algo-family {
  color: #475569;
}

[data-theme="light"] .algo-desc {
  color: #64748b;
}

[data-theme="light"] .benchmark-results-box {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .results-header h4 {
  color: #0f172a;
}

[data-theme="light"] .benchmark-table {
  background: #ffffff;
}

[data-theme="light"] .benchmark-table th {
  background: #f1f5f9;
  color: #0f172a;
  border-bottom: 2px solid #cbd5e1;
}

[data-theme="light"] .benchmark-table td {
  border-bottom: 1px solid #e2e8f0;
  color: #0f172a;
}

[data-theme="light"] .benchmark-table tr:hover td {
  background: #f8fafc;
}

[data-theme="light"] .recommended-model-banner {
  background: linear-gradient(135deg, #f0fdf4 0%, #e0f2fe 100%);
  border: 1px solid #86efac;
}

[data-theme="light"] .rec-banner-title {
  color: #0f172a;
}

[data-theme="light"] .rec-banner-desc {
  color: #334155;
}

[data-theme="light"] .purge-stepper-box {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .stepper-header h4 {
  color: #0f172a;
}

[data-theme="light"] .step-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

[data-theme="light"] .step-card.step-active {
  border-color: #0284c7;
  background: #f0f9ff;
}

[data-theme="light"] .step-card.step-complete {
  border-color: #16a34a;
  background: #f0fdf4;
}

[data-theme="light"] .step-title {
  color: #0f172a;
}

[data-theme="light"] .step-desc {
  color: #64748b;
}

[data-theme="light"] .ledger-box,
[data-theme="light"] .unlearning-ledger-box {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .ledger-header h4 {
  color: #0f172a;
}

[data-theme="light"] .ledger-table th {
  background: #f1f5f9;
  color: #0f172a;
  border-bottom: 2px solid #cbd5e1;
}

[data-theme="light"] .ledger-table td {
  border-bottom: 1px solid #e2e8f0;
  color: #0f172a;
}

[data-theme="light"] .probe-tester-box,
[data-theme="light"] .model-probe-box {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .probe-title {
  color: #0f172a;
}

[data-theme="light"] .probe-sub {
  color: #64748b;
}

[data-theme="light"] .probe-input-row input {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .probe-result-card {
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  color: #0f172a;
}

[data-theme="light"] .shards-visualizer-box,
[data-theme="light"] .shards-distribution-box {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .shards-title {
  color: #0f172a;
}

[data-theme="light"] .shard-node-card,
[data-theme="light"] .shard-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

[data-theme="light"] .shard-name {
  color: #0f172a;
}

[data-theme="light"] .heatmap-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .heatmap-title {
  color: #0f172a;
}

[data-theme="light"] .upload-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .panel-header h2 {
  color: #0f172a;
}

[data-theme="light"] .dropzone-container {
  background: #f8fafc;
  border: 2px dashed #cbd5e1;
}

[data-theme="light"] .drop-title {
  color: #0f172a;
}

[data-theme="light"] .drop-sub,
[data-theme="light"] .drop-hint {
  color: #64748b;
}

[data-theme="light"] .file-info-card {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .file-info-meta strong {
  color: #0f172a;
}

[data-theme="light"] .sample-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
}

[data-theme="light"] .sample-btn:hover {
  background: #f1f5f9;
  color: #0f172a;
}

[data-theme="light"] .dual-track-container {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .track-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

[data-theme="light"] .track-title h3 {
  color: #0f172a;
}

[data-theme="light"] .xai-analysis-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .xai-header {
  color: #0f172a;
}

[data-theme="light"] .submissions-header h2 {
  color: #0f172a;
}

[data-theme="light"] .submission-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .submission-title {
  color: #0f172a;
}

[data-theme="light"] .modal-card {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #cbd5e1;
}

[data-theme="light"] .modal-title {
  color: #0f172a;
}

[data-theme="light"] .modal-close-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .audio-player-console {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid rgba(2, 132, 199, 0.3);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .speed-btn {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #334155;
}

[data-theme="light"] .speed-btn.active {
  background: #0284c7;
  color: #ffffff;
}

[data-theme="light"] .auth-modal-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .auth-header h2 {
  color: #0f172a;
}

[data-theme="light"] .auth-sub {
  color: #64748b;
}

[data-theme="light"] .auth-tabs {
  background: #f1f5f9;
}

[data-theme="light"] .auth-tab-btn.active {
  background: #ffffff;
  color: #0f172a;
}

[data-theme="light"] .demo-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

[data-theme="light"] .demo-btn:hover {
  background: #f1f5f9;
}


/* ==========================================================================
   AUTHENTIC VINTAGE BROADSHEET NEWSPAPER READING MODE (NO CENTER LINE)
   ========================================================================== */
[data-theme="paper"],
[data-theme="newsprint"] {
  --bg-dark: #f4ecdc;
  --bg-card: #fbf6ec;
  --bg-card-hover: #f5eedc;
  --bg-surface: #fbf6ec;
  --bg-input: #f5eedc;
  --bg-header-bar: #ede3cb;

  --border-subtle: #d6c7ab;
  --border-focus: #7d1515;
  --border-newspaper: #c4b393;
  --shadow-card: 0 4px 15px rgba(58, 43, 23, 0.1);
  --shadow-hover: 0 10px 28px rgba(58, 43, 23, 0.18);

  --text-main: #140d07;
  --text-muted: #3a2e20;
  --text-dim: #6b5840;
  --text-newspaper: #1c140a;
  --text-headline: #110903;

  --accent-green: #15803d;
  --accent-green-glow: rgba(21, 128, 61, 0.18);
  --accent-crimson: #7d1515;
  --accent-crimson-glow: rgba(125, 21, 21, 0.2);
  --accent-amber: #9a3412;
  --accent-amber-glow: rgba(154, 52, 18, 0.18);
  --accent-cyan: #075985;
  --accent-cyan-glow: rgba(7, 89, 133, 0.18);
  --accent-purple: #581c87;
  --accent-purple-glow: rgba(88, 28, 135, 0.18);
  --accent-blue: #1e3a8a;

  --font-masthead: 'Algerian', 'Cinzel Decorative', 'Cinzel', 'Playfair Display', Georgia, serif;
  --font-editorial: 'Newsreader', Georgia, 'Times New Roman', serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

/* 1. Real-Life Unbleached Newsprint Texture (NO STRIPES, NO LINE) */
[data-theme="paper"] body {
  background-color: #f4ecdc;
  background-image:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 500 500' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='newsprintGrain'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.18  0 0 0 0 0.14  0 0 0 0 0.09  0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23newsprintGrain)'/%3E%3C/svg%3E"),
    radial-gradient(ellipse at 50% 15%, #faf5ea 0%, #eee4ce 70%, #decfae 100%);
  background-attachment: fixed;
  color: #140d07;
  font-family: 'Newsreader', Georgia, 'Times New Roman', serif;
}

/* 2. Physical Printed Broadsheet Paper Container (Vertical center line completely removed) */
[data-theme="paper"] .layout-container {
  background-color: #faf5e8;
  background-image:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='sheetGrain'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.18  0 0 0 0 0.13  0 0 0 0 0.08  0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23sheetGrain)'/%3E%3C/svg%3E");
  border: 1px solid #c9b99a;
  border-top: 5px double #1c140a;
  border-bottom: 5px double #1c140a;
  box-shadow:
    0 12px 35px rgba(50, 36, 18, 0.18),
    0 0 0 1px #cebea0,
    0 0 0 5px #ebe0cd,
    0 25px 60px rgba(45, 32, 16, 0.2);
  margin-top: 14px;
  margin-bottom: 50px;
  padding: 24px 36px 60px;
  position: relative;
}

/* Eliminate the vertical dividing fold line artifact completely */
[data-theme="paper"] .layout-container::before {
  display: none !important;
  content: none !important;
}

/* 3. Authentic Broadsheet Masthead with Ink Printing Aesthetic */
[data-theme="paper"] .newspaper-masthead {
  border-top: 2px solid #1c140a;
  border-bottom: 4px double #1c140a;
  padding: 18px 0 14px;
  background: transparent;
}

[data-theme="paper"] .masthead-meta-row {
  border-bottom: 1px solid #1c140a;
  padding-bottom: 8px;
  font-family: 'Cinzel', 'Newsreader', Georgia, serif;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: #1c140a;
  font-weight: 700;
  text-transform: uppercase;
}

[data-theme="paper"] .newspaper-title {
  font-family: 'Algerian', 'Cinzel Decorative', 'Cinzel', 'Playfair Display', Georgia, serif;
  font-weight: 900;
  color: #110903;
  letter-spacing: 0.08em;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.25);
}

[data-theme="paper"] .devanagari-masthead-title {
  color: #7d1515;
  font-weight: 800;
  letter-spacing: 0.06em;
}

[data-theme="paper"] .masthead-tagline {
  border-top: 1px solid #1c140a;
  border-bottom: 1px solid #1c140a;
  padding: 5px 0;
  font-family: 'Newsreader', Georgia, serif;
  font-style: italic;
  color: #2e2316;
  letter-spacing: 0.05em;
  font-size: 0.88rem;
}

[data-theme="paper"] .masthead-seal {
  background: #faf5e8;
  border: 2px double #1c140a;
  color: #7d1515;
  box-shadow: 0 0 0 1px #1c140a;
}

[data-theme="paper"] .masthead-seal span,
[data-theme="paper"] .masthead-seal svg {
  color: #7d1515;
}

/* 4. Top Market Ticker Bar in Broadsheet Mode */
[data-theme="paper"] .market-ticker-bar {
  background: #ede2cb;
  border-bottom: 1px solid #1c140a;
  color: #1c140a;
  font-family: 'JetBrains Mono', 'Newsreader', monospace;
  font-size: 0.74rem;
  font-weight: 700;
}

/* 5. Authentic Breaking News Banner (Telegraph Bulletin Edition) */
[data-theme="paper"] .breaking-news-wrapper {
  background: #6e1313;
  border-top: 2px solid #1c140a;
  border-bottom: 2px solid #1c140a;
  color: #ffffff;
  box-shadow: inset 0 0 15px rgba(0, 0, 0, 0.35);
}

[data-theme="paper"] .breaking-news-label {
  background: #480b0b;
  color: #fce8e8;
  border-right: 1px solid rgba(255, 255, 255, 0.25);
  font-family: 'Cinzel', serif;
  letter-spacing: 0.08em;
}

[data-theme="paper"] .breaking-item {
  color: #ffffff;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 0.88rem;
}

[data-theme="paper"] .live-sync-btn {
  background: #480b0b;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
}

[data-theme="paper"] .live-sync-btn:hover {
  background: #330707;
}

/* 6. Broadsheet Navigation Bar & Section Tabs */
[data-theme="paper"] .newspaper-nav-bar {
  border-top: 1px solid #1c140a;
  border-bottom: 2px solid #1c140a;
  background: #ece1c8;
}

[data-theme="paper"] .nav-tab {
  font-family: 'Cinzel', 'Newsreader', Georgia, serif;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #2b1f13;
  border-bottom: 3px solid transparent;
}

[data-theme="paper"] .nav-tab:hover {
  background: #dfd2b5;
  color: #110903;
}

[data-theme="paper"] .nav-tab.active {
  color: #110903;
  background: #faf5e8;
  border-color: #7d1515;
  border-bottom: 3px solid #7d1515;
}

/* 7. Lead Hero Article (Classic Broadsheet Front Page Lead Story) */
[data-theme="paper"] .featured-hero-article {
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
  box-shadow: 0 2px 10px rgba(60, 45, 25, 0.08);
  border-radius: 2px;
}

[data-theme="paper"] .featured-hero-article:hover {
  border-color: #7d1515;
  box-shadow: 0 6px 20px rgba(60, 45, 25, 0.16);
}

[data-theme="paper"] .hero-title {
  font-family: 'Newsreader', 'Playfair Display', Georgia, serif !important;
  font-weight: 800;
  font-size: 1.95rem;
  line-height: 1.2;
  color: #110903 !important;
}

[data-theme="paper"] .hero-excerpt {
  font-family: 'Newsreader', Georgia, serif;
  font-size: 1.05rem;
  line-height: 1.62;
  color: #1e150b;
  text-align: justify;
}

[data-theme="paper"] .hero-excerpt::first-letter {
  font-family: 'Cinzel', 'Playfair Display', Georgia, serif;
  font-size: 3.5rem;
  float: left;
  line-height: 0.8;
  margin: 4px 10px 0 0;
  color: #7d1515;
  font-weight: 800;
}

/* 8. Trending Wire Sidebar (Broadsheet Second Column) */
[data-theme="paper"] .trending-wire-sidebar {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
  border-radius: 2px;
  box-shadow: 0 2px 10px rgba(60, 45, 25, 0.08);
}

[data-theme="paper"] .sidebar-header {
  border-bottom: 2px solid #1c140a;
}

[data-theme="paper"] .sidebar-header h3 {
  font-family: 'Cinzel', 'Newsreader', Georgia, serif;
  font-weight: 800;
  color: #110903;
  letter-spacing: 0.04em;
}

[data-theme="paper"] .trending-item {
  border-bottom: 1px dashed #c4b494;
  padding-bottom: 12px;
}

[data-theme="paper"] .trending-rank {
  font-family: 'Cinzel', serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: #7d1515;
}

[data-theme="paper"] .trending-title {
  font-family: 'Newsreader', Georgia, serif;
  font-weight: 700;
  font-size: 0.98rem;
  color: #140d07;
}

/* 9. Authentic Newspaper Broadsheet Article Cards */
[data-theme="paper"] .newspaper-dispatch-card {
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid #c9ba9c;
  border-top: 4px double #1c140a;
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(78, 59, 29, 0.07);
}

[data-theme="paper"] .newspaper-dispatch-card:hover {
  border-color: #7d1515;
  box-shadow: 0 6px 18px rgba(78, 59, 29, 0.15);
  transform: translateY(-2px);
}

[data-theme="paper"] .dispatch-header-line {
  background: #ece1c8;
  border-bottom: 1px solid #c9ba9c;
  font-family: 'Cinzel', serif;
  font-size: 0.68rem;
  color: #1c140a;
  font-weight: 700;
}

[data-theme="paper"] .dispatch-kicker {
  color: #7d1515;
  font-weight: 800;
}

[data-theme="paper"] .broadsheet-headline {
  font-family: 'Newsreader', Georgia, serif;
  font-weight: 800;
  font-size: 1.2rem;
  line-height: 1.3;
  color: #110903;
}

[data-theme="paper"] .card-excerpt {
  font-family: 'Newsreader', Georgia, serif;
  color: #241a0e;
  font-size: 0.9rem;
  line-height: 1.55;
  text-align: justify;
}

[data-theme="paper"] .newspaper-dateline-row {
  border-top: 1px dotted #c4b494;
  border-bottom: 1px dotted #c4b494;
  padding: 4px 0;
  margin-bottom: 8px;
  font-family: 'Cinzel', serif;
  font-size: 0.68rem;
  color: #443422;
  font-weight: 700;
}

[data-theme="paper"] .newspaper-location {
  color: #7d1515;
  font-weight: 800;
}

[data-theme="paper"] .card-meta-line {
  border-top: 1px solid #c9ba9c;
  padding-top: 8px;
  font-family: 'Newsreader', Georgia, serif;
  color: #4a3b2b;
}

[data-theme="paper"] .newspaper-card-rule {
  background: #c4b494;
  height: 1px;
}

/* 10. Authentic Newsprint Offset Print Photo Effect */
[data-theme="paper"] .dispatch-image-box img,
[data-theme="paper"] .hero-image,
[data-theme="paper"] .modal-hero-photo {
  filter: sepia(0.22) contrast(1.15) brightness(0.96) grayscale(0.2);
  border: 1px solid #1c140a;
}

/* 11. Modal Reader (Authentic Broadsheet Extra Dispatch Edition) */
[data-theme="paper"] .broadsheet-modal-card {
  background-color: #faf5e8;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='modalGrain'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.18  0 0 0 0 0.13  0 0 0 0 0.08  0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23modalGrain)'/%3E%3C/svg%3E");
  border: 2px solid #1c140a;
  box-shadow: 0 25px 70px rgba(45, 30, 15, 0.45);
}

[data-theme="paper"] .broadsheet-modal-card::before {
  background: linear-gradient(
    to right,
    rgba(28, 20, 10, 0) 0%,
    rgba(28, 20, 10, 0.06) 42%,
    rgba(28, 20, 10, 0.14) 50%,
    rgba(255, 250, 240, 0.25) 52%,
    rgba(28, 20, 10, 0) 100%
  );
}

[data-theme="paper"] .broadsheet-modal-card::after {
  background: linear-gradient(135deg, transparent 50%, rgba(28, 20, 10, 0.25) 50%, #ded0b0 55%);
}

[data-theme="paper"] .broadsheet-paper-header {
  background: #ede2cb;
  border-bottom: 2px solid #1c140a;
  color: #1c140a;
  font-family: 'Cinzel', serif;
  font-weight: 700;
}

[data-theme="paper"] .broadsheet-body-content {
  color: #140d07;
  font-family: 'Newsreader', Georgia, serif;
}

[data-theme="paper"] .newspaper-lead-para::first-letter,
[data-theme="paper"] .newspaper-drop-cap {
  color: #7d1515;
  font-family: 'Cinzel', Georgia, serif;
  font-size: 3.5rem;
  font-weight: 800;
  float: left;
  line-height: 0.8;
  margin-right: 10px;
}

[data-theme="paper"] .broadsheet-pull-quote {
  background: rgba(125, 21, 21, 0.06);
  color: #5c1010;
  border-left: 3px solid #7d1515;
  border-right: 3px solid #7d1515;
  font-family: 'Newsreader', Georgia, serif;
  font-style: italic;
}

[data-theme="paper"] .broadsheet-printer-slug {
  border-top: 1px double #1c140a;
  color: #574632;
  font-family: 'Cinzel', serif;
}

/* 12. Admin Unlearning Workbench in Paper Mode (The Typesetter Press Desk) */
[data-theme="paper"] .admin-panel-card {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
  box-shadow: 0 3px 12px rgba(60, 45, 25, 0.08);
}

[data-theme="paper"] .admin-top-banner {
  background: #efe5ce;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .admin-top-banner h2 {
  font-family: 'Cinzel', Georgia, serif;
  color: #110903;
  font-weight: 800;
}

[data-theme="paper"] .admin-top-banner p {
  color: #3d3021;
}

[data-theme="paper"] .queue-item-card {
  background: #ffffff;
  border: 1px solid #c9ba9c;
  border-left: 4px solid #7d1515;
}

[data-theme="paper"] .queue-item-card:hover {
  background: #fdfbf7;
  border-color: #1c140a;
}

[data-theme="paper"] .queue-item-card.selected {
  background: #fdf5f5;
  border-color: #7d1515;
}

[data-theme="paper"] .queue-item-title {
  font-family: 'Newsreader', Georgia, serif;
  font-weight: 800;
  color: #110903;
  font-size: 0.95rem;
}

[data-theme="paper"] .queue-item-meta {
  color: #574632;
  font-family: 'Cinzel', monospace;
}

[data-theme="paper"] .target-inspector {
  background: #fdfaf2;
  border: 2px solid #7d1515;
}

[data-theme="paper"] .target-headline {
  font-family: 'Newsreader', Georgia, serif;
  font-weight: 800;
  color: #110903;
  font-size: 1.25rem;
}

[data-theme="paper"] .target-excerpt {
  color: #241a0e;
  font-family: 'Newsreader', Georgia, serif;
}

[data-theme="paper"] .algo-card-btn {
  background: #ffffff;
  border: 1px solid #c4b494;
  border-top: 2px solid #1c140a;
}

[data-theme="paper"] .algo-card-btn:hover {
  background: #f7f0e0;
  border-color: #1c140a;
}

[data-theme="paper"] .algo-card-btn.active {
  background: #f0fdf4;
  border: 2px solid #15803d;
  box-shadow: 0 4px 15px rgba(21, 128, 61, 0.15);
}

[data-theme="paper"] .algo-name {
  font-family: 'Cinzel', Georgia, serif;
  font-weight: 800;
  color: #110903;
}

[data-theme="paper"] .algo-family {
  color: #3d3021;
}

[data-theme="paper"] .algo-desc {
  color: #574632;
}

[data-theme="paper"] .benchmark-results-box {
  background: #faf5e8;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .results-header h4 {
  font-family: 'Cinzel', Georgia, serif;
  color: #110903;
  font-weight: 800;
}

[data-theme="paper"] .benchmark-table {
  background: #ffffff;
  border: 1px solid #c4b494;
}

[data-theme="paper"] .benchmark-table th {
  background: #ede2cb;
  color: #110903;
  font-family: 'Cinzel', serif;
  font-weight: 800;
  border-bottom: 2px solid #1c140a;
}

[data-theme="paper"] .benchmark-table td {
  border-bottom: 1px solid #dcd0b8;
  color: #140d07;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 0.82rem;
}

[data-theme="paper"] .benchmark-table tr:hover td {
  background: #fcf9f2;
}

[data-theme="paper"] .recommended-model-banner {
  background: #fbf8ee;
  border: 1px solid #b45309;
}

[data-theme="paper"] .rec-banner-title {
  color: #110903;
  font-family: 'Cinzel', serif;
}

[data-theme="paper"] .rec-banner-desc {
  color: #2e2316;
}

[data-theme="paper"] .purge-stepper-box {
  background: #faf5e8;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .stepper-header h4 {
  font-family: 'Cinzel', serif;
  color: #110903;
  font-weight: 800;
}

[data-theme="paper"] .step-card {
  background: #ffffff;
  border: 1px solid #c9ba9c;
}

[data-theme="paper"] .step-card.step-complete {
  background: #f0fdf4;
  border-color: #15803d;
}

[data-theme="paper"] .step-title {
  font-family: 'Cinzel', Georgia, serif;
  font-weight: 800;
  color: #110903;
}

[data-theme="paper"] .step-desc {
  color: #4a3b2a;
}

[data-theme="paper"] .ledger-box,
[data-theme="paper"] .unlearning-ledger-box {
  background: #faf5e8;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .ledger-header h4 {
  font-family: 'Cinzel', serif;
  color: #110903;
  font-weight: 800;
}

[data-theme="paper"] .ledger-table th {
  background: #ede2cb;
  color: #110903;
  border-bottom: 2px solid #1c140a;
  font-family: 'Cinzel', serif;
}

[data-theme="paper"] .ledger-table td {
  background: #ffffff;
  color: #140d07;
  border-bottom: 1px solid #dcd0b8;
  font-family: 'Newsreader', Georgia, serif;
}

[data-theme="paper"] .probe-tester-box,
[data-theme="paper"] .model-probe-box {
  background: #faf5e8;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .shards-visualizer-box,
[data-theme="paper"] .shards-distribution-box {
  background: #faf5e8;
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .shards-title {
  color: #1c140a;
}

[data-theme="paper"] .shard-node-card,
[data-theme="paper"] .shard-card {
  background: #ffffff;
  border: 1px solid #c4b494;
}

[data-theme="paper"] .probe-title {
  font-family: 'Cinzel', serif;
  color: #110903;
  font-weight: 800;
}

[data-theme="paper"] .probe-input-row input {
  background: #ffffff;
  border: 1px solid #c4b494;
  color: #140d07;
  font-family: 'Newsreader', Georgia, serif;
  font-size: 0.95rem;
}

[data-theme="paper"] .probe-result-card {
  background: #f0fdf4;
  border: 1px solid #86efac;
  color: #110903;
}

[data-theme="paper"] .upload-card,
[data-theme="paper"] .submissions-container,
[data-theme="paper"] .dual-track-container,
[data-theme="paper"] .xai-analysis-card {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid #c4b494;
  border-top: 4px double #1c140a;
}

[data-theme="paper"] .panel-header h2,
[data-theme="paper"] .submissions-header h2,
[data-theme="paper"] .track-title h3,
[data-theme="paper"] .xai-header {
  color: #110903;
  font-family: 'Cinzel', serif;
}

[data-theme="paper"] .dropzone-container {
  background: #f7f0e0;
  border: 2px dashed #c4b494;
}

[data-theme="paper"] .drop-title {
  color: #110903;
  font-family: 'Cinzel', serif;
}

[data-theme="paper"] .drop-sub,
[data-theme="paper"] .drop-hint {
  color: #574632;
}

[data-theme="paper"] .sample-btn {
  background: #faf5e8;
  border: 1px solid #c4b494;
  color: #2e2316;
}

[data-theme="paper"] .sample-btn:hover {
  background: #ede2cb;
  color: #110903;
}

[data-theme="paper"] .btn-secondary {
  background: #faf5e8;
  border: 1px solid #b8a682;
  color: #140d07;
}

[data-theme="paper"] .btn-secondary:hover {
  background: #ede3cc;
  border-color: #1c140a;
}

[data-theme="paper"] .theme-ui-btn.active {
  background: #7d1515;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(125, 21, 21, 0.4);
}

[data-theme="paper"] .audio-player-console {
  background: #faf5e8;
  border: 1px solid #b8a682;
  box-shadow: 0 4px 16px rgba(78, 59, 29, 0.08);
}

[data-theme="paper"] .auth-modal-card {
  background: #faf5e8;
  border: 2px solid #1c140a;
  color: #140d07;
}

[data-theme="paper"] .auth-tab-btn.active {
  background: #faf5e8;
  color: #7d1515;
  border-bottom: 2px solid #7d1515;
}

[data-theme="paper"] .demo-btn {
  background: #faf5e8;
  border: 1px solid #b8a682;
  color: #140d07;
}

[data-theme="paper"] .demo-btn:hover {
  background: #ede3cc;
}

/* ==========================================================================
   MULTI-MODEL UNLEARNING ACTIVE & EXECUTED HIGHLIGHT BADGES
   ========================================================================== */
.row-executed {
  background: rgba(16, 185, 129, 0.12) !important;
  border-left: 4px solid #10b981 !important;
  font-weight: 700;
}

[data-theme="light"] .row-executed {
  background: #f0fdf4 !important;
  border-left: 4px solid #16a34a !important;
}

[data-theme="paper"] .row-executed {
  background: #edfbf0 !important;
  border-left: 4px solid #15803d !important;
}

.row-recommended {
  background: rgba(245, 158, 11, 0.08) !important;
}

[data-theme="light"] .row-recommended {
  background: #fffbeb !important;
}

[data-theme="paper"] .row-recommended {
  background: #fefce8 !important;
}


/* ==========================================================================
   REAL-TIME NEWS READER AUDIO ANCHOR (BROADSHEET TTS)
   ========================================================================== */
.news-reader-anchor-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  width: 92%;
  max-width: 940px;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.28);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  z-index: 99999;
  animation: anchorSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

[data-theme="paper"] .news-reader-anchor-bar {
  background: #fbf7ee;
  border: 1px solid #c9b99a;
  box-shadow: 0 16px 40px rgba(50, 40, 25, 0.22);
}

@keyframes anchorSlideUp {
  from {
    opacity: 0;
    transform: translate(-50%, 40px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

.anchor-profile {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

.anchor-avatar-pulse {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-purple, #8b5cf6), var(--accent-cyan, #06b6d4));
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.anchor-avatar-pulse .anchor-icon {
  font-size: 1.35rem;
  z-index: 2;
}

.audio-waves {
  position: absolute;
  bottom: -4px;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
}

.audio-waves .wave-bar {
  width: 3px;
  height: 4px;
  background: #ffffff;
  border-radius: 2px;
  opacity: 0.85;
}

.speaking .audio-waves .wave-bar:nth-child(1) { animation: soundWaveBounce 0.6s infinite ease-in-out alternate; }
.speaking .audio-waves .wave-bar:nth-child(2) { animation: soundWaveBounce 0.8s infinite ease-in-out alternate 0.15s; }
.speaking .audio-waves .wave-bar:nth-child(3) { animation: soundWaveBounce 0.5s infinite ease-in-out alternate 0.3s; }
.speaking .audio-waves .wave-bar:nth-child(4) { animation: soundWaveBounce 0.7s infinite ease-in-out alternate 0.2s; }
.speaking .audio-waves .wave-bar:nth-child(5) { animation: soundWaveBounce 0.9s infinite ease-in-out alternate 0.4s; }

@keyframes soundWaveBounce {
  0% { height: 3px; }
  100% { height: 14px; }
}

.anchor-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.anchor-label {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-purple, #8b5cf6);
}

.anchor-headline {
  font-family: var(--font-headline, Georgia, serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 480px;
}

.anchor-byline {
  font-size: 0.74rem;
  color: var(--text-dim);
}

.anchor-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.anchor-ctrl-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.anchor-ctrl-btn:hover {
  background: var(--accent-blue);
  color: #ffffff;
  transform: scale(1.08);
}

.anchor-rate-selector {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.76rem;
  color: var(--text-muted);
}

.anchor-rate-selector select {
  padding: 4px 6px;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  font-size: 0.76rem;
  cursor: pointer;
}

.anchor-close-btn {
  background: transparent;
  border: none;
  font-size: 1.1rem;
  color: var(--text-dim);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.anchor-close-btn:hover {
  color: var(--accent-crimson, #ef4444);
  background: rgba(239, 68, 68, 0.1);
}

/* LISTEN ANCHOR BUTTON ON NEWS CARDS */
.btn-listen-anchor {
  background: rgba(139, 92, 246, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.25);
  color: var(--accent-purple, #8b5cf6);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.18s ease;
}

.btn-listen-anchor:hover {
  background: var(--accent-purple, #8b5cf6);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

/* ADMIN AI COPILOT STYLES */
.copilot-card {
  position: relative;
  overflow: hidden;
}

.copilot-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #8b5cf6, #06b6d4, #10b981);
}

.copilot-chips-row button {
  transition: all 0.16s ease;
}

.copilot-chips-row button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

/* DATABASE TELEMETRY GRID */
.telemetry-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: all 0.2s ease;
}

.telemetry-stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent-blue);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.telemetry-stat-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-dim);
}

.telemetry-stat-value {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

.telemetry-stat-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ==========================================================================
   PROMINENT FRONT-PAGE NEWS WIRE SEARCH BAR & QUICK TOPIC CHIPS
   ========================================================================== */
.wire-search-bar-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 20px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: all 0.2s ease;
}

.wire-search-bar-wrap:focus-within {
  border-color: var(--accent-blue);
  box-shadow: 0 6px 24px rgba(2, 132, 199, 0.12);
}

.wire-search-input-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 8px 14px;
  transition: all 0.2s ease;
}

.wire-search-input-group:focus-within {
  border-color: var(--accent-blue);
  background: var(--bg-card);
}

.wire-search-icon {
  font-size: 1.15rem;
  color: var(--text-dim);
  user-select: none;
}

.wire-search-input {
  flex: 1 1 200px;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 0.95rem;
  font-family: var(--font-sans);
}

.wire-search-input::placeholder {
  color: var(--text-dim);
}

.btn-clear-search {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 1rem;
  cursor: pointer;
  padding: 2px 8px;
  border-radius: 4px;
  transition: all 0.15s ease;
}

.btn-clear-search:hover {
  color: var(--accent-crimson);
  background: rgba(239, 68, 68, 0.1);
}

.wire-search-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.search-badge {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-blue);
  background: rgba(2, 132, 199, 0.08);
  border: 1px solid rgba(2, 132, 199, 0.2);
  border-radius: 20px;
  padding: 3px 10px;
}

.wire-search-quick-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 4px;
  border-top: 1px dashed var(--border-subtle);
}

.quick-tag-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-right: 4px;
}

.quick-topic-tag {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 4px 10px;
  font-size: 0.76rem;
  color: var(--text-headline);
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.quick-topic-tag:hover {
  background: var(--accent-blue);
  color: #ffffff;
  border-color: var(--accent-blue);
  transform: translateY(-1px);
}

.modal-xai-breakdown-box {
  background: rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 10px 14px;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-main);
}

/* ==========================================================================
   MOBILE & SMALL VIEWPORT UX (COMFORTABLE TOUCH UI + ZERO OVERFLOW)
   ========================================================================== */
@media (max-width: 640px) {
  .layout-container {
    padding: 0 12px 48px;
  }

  .newspaper-masthead {
    padding: 10px 0;
    margin-bottom: 10px;
  }

  .masthead-meta-row {
    align-items: center;
    text-align: center;
    gap: 6px;
    padding-bottom: 8px;
    margin-bottom: 8px;
  }

  .masthead-date {
    font-size: 0.78rem;
  }

  .masthead-edition {
    display: none;
  }

  .masthead-user-controls {
    width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
  }

  .role-pill-switch {
    flex-wrap: wrap;
    justify-content: center;
  }

  .profile-settings-wrapper {
    position: static;
  }

  .profile-settings-drawer {
    position: fixed;
    top: 64px;
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    max-height: calc(100vh - 84px);
    overflow-y: auto;
    z-index: 2500;
  }

  .masthead-main {
    gap: 8px;
    padding: 4px 0 6px;
  }

  .masthead-seal {
    width: 34px;
    height: 34px;
  }

  .masthead-seal svg {
    width: 18px;
    height: 18px;
  }

  .newspaper-title {
    font-size: clamp(1.3rem, 6.2vw, 1.95rem);
    line-height: 1.15;
  }

  .devanagari-masthead-title {
    font-size: clamp(1rem, 4.8vw, 1.45rem);
  }

  .masthead-tagline {
    font-size: 0.62rem;
    letter-spacing: 0.04em;
    line-height: 1.35;
    text-align: center;
  }

  .breaking-news-wrapper {
    flex-direction: column;
    margin-bottom: 12px;
  }

  .breaking-news-label {
    justify-content: center;
    padding: 6px 12px;
    font-size: 0.72rem;
  }

  .breaking-news-content {
    min-width: 0;
    width: 100%;
    padding: 6px 12px;
  }

  .breaking-actions-group {
    width: 100%;
  }

  .live-sync-btn {
    flex: 1 1 33%;
    min-width: 0;
    padding: 8px 6px;
    font-size: 0.72rem;
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    white-space: normal;
    text-align: center;
  }

  .newspaper-nav-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-bottom: 14px;
    padding: 8px 0;
  }

  .nav-links {
    width: 100%;
    flex-wrap: wrap;
    gap: 6px;
  }

  .nav-tab {
    flex: 1 1 auto;
    justify-content: center;
    padding: 7px 10px;
    font-size: 0.78rem;
    min-height: 38px;
    border-radius: 18px;
    white-space: nowrap;
  }

  .nav-search-box {
    width: 100%;
    max-width: none;
    min-width: 0;
    padding: 6px 12px;
  }

  .anime-anchor-broadcast-card {
    padding: 12px 14px;
    margin-bottom: 14px;
  }

  .anchor-dialogue {
    font-size: 0.84rem;
    line-height: 1.5;
  }

  .anchor-actions-bar .btn {
    flex: 1 1 auto;
    min-height: 38px;
  }

  .wire-search-bar-wrap {
    padding: 12px;
    margin-bottom: 14px;
  }

  .wire-search-input-group {
    padding: 8px 10px;
  }

  .wire-search-quick-tags {
    flex-wrap: wrap;
    gap: 6px;
  }

  .quick-topic-tag {
    flex: 0 1 auto;
    white-space: nowrap;
    padding: 5px 10px;
  }

  .filter-controls-row {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin-bottom: 14px;
    padding-bottom: 10px;
  }

  .category-filters-bar,
  .language-filters-bar {
    width: 100%;
    flex-wrap: wrap;
    gap: 6px;
  }

  .cat-pill,
  .lang-pill {
    flex: 0 1 auto;
    font-size: 0.74rem;
    padding: 5px 10px;
    min-height: 32px;
    white-space: nowrap;
  }

  .hero-image-wrapper {
    height: 195px;
  }

  .hero-content {
    padding: 14px;
  }

  .hero-headline {
    font-size: 1.25rem;
    line-height: 1.3;
  }

  .hero-excerpt,
  .card-excerpt {
    font-size: 0.88rem;
    line-height: 1.55;
  }

  .hero-footer,
  .card-footer,
  .submission-card-footer,
  .dispatch-header-line {
    flex-wrap: wrap;
    gap: 8px;
  }

  .card-body {
    padding: 14px;
  }

  .card-thumb-wrapper {
    height: 165px;
  }

  .trending-wire-sidebar,
  .ingest-panel,
  .admin-card,
  .admin-top-banner {
    padding: 14px;
  }

  .upload-mode-toggle {
    flex-direction: column;
    gap: 6px;
  }

  .mode-btn {
    min-height: 40px;
  }

  .quick-samples {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }

  .sample-btn {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .form-row {
    flex-direction: column;
    gap: 12px;
  }

  .form-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .form-actions .btn {
    width: 100%;
    min-height: 44px;
  }

  .admin-quick-stats {
    width: 100%;
    justify-content: space-between;
  }

  .stat-mini {
    align-items: flex-start;
  }

  .section-divider-title {
    white-space: normal;
    font-size: 1.05rem;
  }

  .submissions-grid,
  .citizen-checks-row {
    grid-template-columns: 1fr;
  }

  .cert-meters-row,
  .probe-metric-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .recommended-model-banner {
    padding: 12px;
    gap: 12px;
  }

  .rec-banner-content {
    min-width: 0;
    width: 100%;
  }

  .modal-backdrop {
    padding: 10px;
    align-items: flex-start;
    overflow-y: auto;
  }

  .article-modal-card,
  .broadsheet-modal-card,
  .auth-modal-card,
  .editorial-edit-modal-card {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 92vh;
    overflow-y: auto;
    padding: 16px;
    margin: 4px auto;
    border-radius: 12px;
  }

  .modal-close-btn {
    top: 10px;
    right: 10px;
    width: 34px;
    height: 34px;
    z-index: 20;
  }

  .broadsheet-modal-card::before {
    display: none;
  }

  .broadsheet-body-content {
    font-size: 0.96rem;
    line-height: 1.65;
    text-align: left;
  }

  .broadsheet-paper-header {
    flex-wrap: wrap;
    gap: 4px;
    justify-content: center;
    text-align: center;
    padding-right: 36px;
  }

  .news-reader-anchor-bar {
    bottom: 10px;
    width: calc(100% - 20px);
    padding: 10px 12px;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    border-radius: 12px;
  }

  .anchor-headline {
    max-width: 100%;
    font-size: 0.85rem;
  }

  .anchor-controls {
    width: 100%;
    justify-content: space-between;
  }

  .toast-container {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .toast-message {
    min-width: 0;
    width: 100%;
    max-width: 100%;
    padding: 12px 14px;
  }

  input[type="text"],
  input[type="email"],
  input[type="password"],
  input[type="url"],
  textarea,
  select {
    font-size: 16px;
  }
}

