/* France 2030 AI Accent Overrides — Bleu de France (#002395) + Rouge (#ED2939) */
:root {
  --accent: #002395;
  --accent-dark: #001A6E;
  --accent-mid: #1A4FBF;
  --accent-light: #4D7FE0;
  --accent-pale: #E8EEF9;
  --accent2: #ED2939;
  --accent2-dark: #B91C2A;
  --accent2-light: #F45060;

  /* Section Accents — 10 Strategic Sectors */
  --section-nuclear: #ff6b35;
  --section-hydrogen: #00b4d8;
  --section-ev: #2ecc71;
  --section-semiconductors: #9b59b6;
  --section-ai: #e74c3c;
  --section-health: #1abc9c;
  --section-aviation: #3498db;
  --section-decarb: #f39c12;
  --section-space: #2c3e50;
  --section-deepsea: #0077b6;
  --section-food: #27ae60;
}

/* Navigation active state */
.nav__item--active {
  border-bottom-color: var(--accent);
  color: var(--accent);
}

/* Badges */
.nav__badge {
  background: var(--accent);
}

/* Primary buttons */
.btn--primary {
  background: var(--accent);
  border-color: var(--accent);
}
.btn--primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

/* Accent2 buttons */
.btn--accent2 {
  background: var(--accent2);
  color: #fff;
  border-color: var(--accent2);
}
.btn--accent2:hover {
  background: var(--accent2-dark);
  border-color: var(--accent2-dark);
}

/* Ticker positive/negative */
.ticker__change--up {
  color: #22C55E;
}
.ticker__change--down {
  color: var(--accent2);
}

/* Section tags */
.section-tag {
  background: var(--accent-pale);
  color: var(--accent-dark);
}

/* Sector-specific section tags */
.section-tag--nuclear { color: var(--section-nuclear); }
.section-tag--hydrogen { color: var(--section-hydrogen); }
.section-tag--ev, .section-tag--electric-vehicles { color: var(--section-ev); }
.section-tag--semiconductors { color: var(--section-semiconductors); }
.section-tag--ai, .section-tag--ai-quantum { color: var(--section-ai); }
.section-tag--health, .section-tag--health-biotech { color: var(--section-health); }
.section-tag--aviation, .section-tag--sustainable-aviation { color: var(--section-aviation); }
.section-tag--decarb, .section-tag--industrial-decarbonization { color: var(--section-decarb); }
.section-tag--space { color: var(--section-space); }
.section-tag--deepsea, .section-tag--deep-sea { color: var(--section-deepsea); }
.section-tag--food, .section-tag--food-agriculture { color: var(--section-food); }

/* Progress bars */
.progress-bar__fill--accent {
  background: var(--accent);
}

/* Badge accent */
.badge--accent {
  background: var(--accent);
  color: #fff;
}

/* L2 callout accent border */
.l2-callout {
  border-left-color: var(--accent2);
}

/* Subscribe CTA */
.subscribe-cta {
  border-top-color: var(--accent);
}

/* Premium overlay */
.premium-overlay__box {
  border-top: 4px solid var(--accent);
}

/* Deep header accent line */
.deep-header {
  border-bottom: 3px solid var(--accent);
}

/* Dashboard header */
.dash-header {
  border-bottom: 3px solid var(--accent);
}

/* Section index header */
.section-index-header__rule {
  background: var(--accent);
}

/* Sector-specific section rules */
.section-index-header__rule--nuclear { background: var(--section-nuclear); }
.section-index-header__rule--hydrogen { background: var(--section-hydrogen); }
.section-index-header__rule--ev { background: var(--section-ev); }
.section-index-header__rule--semiconductors { background: var(--section-semiconductors); }
.section-index-header__rule--ai { background: var(--section-ai); }
.section-index-header__rule--health { background: var(--section-health); }
.section-index-header__rule--aviation { background: var(--section-aviation); }
.section-index-header__rule--decarb { background: var(--section-decarb); }
.section-index-header__rule--space { background: var(--section-space); }
.section-index-header__rule--deepsea { background: var(--section-deepsea); }
.section-index-header__rule--food { background: var(--section-food); }
.section-index-header__rule--funding { background: var(--accent2); }
.section-index-header__rule--comparisons { background: var(--accent-mid); }

/* Subnav active states per sector */
.subnav__item--active-nuclear { border-bottom-color: var(--section-nuclear); }
.subnav__item--active-hydrogen { border-bottom-color: var(--section-hydrogen); }
.subnav__item--active-ev { border-bottom-color: var(--section-ev); }
.subnav__item--active-semiconductors { border-bottom-color: var(--section-semiconductors); }
.subnav__item--active-ai { border-bottom-color: var(--section-ai); }
.subnav__item--active-health { border-bottom-color: var(--section-health); }
.subnav__item--active-aviation { border-bottom-color: var(--section-aviation); }
.subnav__item--active-decarb { border-bottom-color: var(--section-decarb); }
.subnav__item--active-space { border-bottom-color: var(--section-space); }
.subnav__item--active-deepsea { border-bottom-color: var(--section-deepsea); }
.subnav__item--active-food { border-bottom-color: var(--section-food); }
.subnav__item--active-funding { border-bottom-color: var(--accent2); }

/* Featured deep dive border colors per sector */
.featured-deep--nuclear { border-left-color: var(--section-nuclear); }
.featured-deep--hydrogen { border-left-color: var(--section-hydrogen); }
.featured-deep--ev { border-left-color: var(--section-ev); }
.featured-deep--semiconductors { border-left-color: var(--section-semiconductors); }
.featured-deep--ai { border-left-color: var(--section-ai); }
.featured-deep--health { border-left-color: var(--section-health); }
.featured-deep--aviation { border-left-color: var(--section-aviation); }
.featured-deep--decarb { border-left-color: var(--section-decarb); }
.featured-deep--space { border-left-color: var(--section-space); }
.featured-deep--deepsea { border-left-color: var(--section-deepsea); }
.featured-deep--food { border-left-color: var(--section-food); }
.featured-deep--funding { border-left-color: var(--accent2); }

/* Masthead subscribe button */
.masthead__subscribe {
  background: var(--accent);
  color: #fff;
  padding: 2px 10px;
  border-radius: 3px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Entity badge */
.badge--entity {
  background: var(--accent-pale);
  color: var(--accent-dark);
}

/* Status badges */
.badge--on-track { background: #DCFCE7; color: #166534; }
.badge--at-risk { background: #FEF9C3; color: #854D0E; }
.badge--off-track { background: var(--accent-pale); color: var(--accent-dark); }
.badge--funded { background: #DCFCE7; color: #166534; }
.badge--pending { background: #FEF9C3; color: #854D0E; }
.badge--announced { background: var(--accent-pale); color: var(--accent-dark); }

/* Link hover accent */
a:hover {
  color: var(--accent);
}

/* Cookie accept button */
.cookie-accept {
  background: var(--accent);
  color: #fff;
}

/* Comparison table highlight */
.comparison-table th.highlight {
  background: rgba(0,35,149,0.06);
  color: var(--accent);
}
.comparison-table td.highlight {
  background: rgba(0,35,149,0.04);
}

/* Table row hover */
.content-body tr:hover td,
.deep-body__main tr:hover td,
.container-article tr:hover td {
  background: rgba(0,35,149,0.02);
}

/* GCC table leader color */
.gcc-table .leader { color: var(--accent); font-weight: 700; }
.gcc-table .highlight-col { background: rgba(0,35,149,0.04); }

/* --- LIVE DATA INDICATORS --- */

/* Live data value styling */
.live-data {
  font-variant-numeric: tabular-nums;
}

/* Live: green pulsing dot */
.live-data.live::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4CAF50;
  margin-left: 4px;
  vertical-align: middle;
  animation: liveDataPulse 2s infinite;
}

/* Stale: amber dot (API failed, showing fallback) */
.live-data.stale::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #FF9800;
  margin-left: 4px;
  vertical-align: middle;
}

@keyframes liveDataPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* Live change indicator in ticker */
.ticker__change-live {
  font-size: 0.85em;
  margin-left: 2px;
}

/* --- DATA FRESHNESS INDICATORS --- */

/* Data point container */
.data-point {
  position: relative;
}

/* Timestamp styling */
.data-timestamp {
  font-size: 10px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* Fresh: updated today */
[data-fresh="true"] .data-timestamp {
  color: #4CAF50;
}

/* Recent: updated this week */
[data-fresh="recent"] .data-timestamp {
  color: var(--ink-40, #999);
}

/* Stale: > 7 days */
[data-fresh="stale"] .data-timestamp {
  color: #FF9800;
}
[data-fresh="stale"] .data-value {
  opacity: 0.7;
}

/* Live indicator dot (standalone) */
.live-indicator {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4CAF50;
  margin-right: 3px;
  vertical-align: middle;
  animation: liveDataPulse 2s infinite;
}

/* ── QA FIX: Utility Classes ── */
.section-divider { border-top: 1px solid var(--salmon-border); padding-top: 16px; }
.section-divider--mt { border-top: 1px solid var(--salmon-border); padding-top: 16px; margin-top: 16px; }
.lead-text { text-align: center; font-family: var(--font-body); font-size: 0.92rem; color: var(--ink-60); margin-bottom: 20px; max-width: 680px; margin-left: auto; margin-right: auto; }
.table-scroll { max-height: 600px; overflow-y: auto; border: 1px solid var(--salmon-border); }
.table-scroll table { margin: 0; }
.table-sticky-header { position: sticky; top: 0; background: var(--salmon); z-index: 10; }
.button-group { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.section-footer { text-align: center; margin-top: 16px; }
.grid-5-col { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; }
.grid-3-col { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.text-muted { color: var(--ink-40); }
.link-accent { font-weight: 600; color: var(--accent); }
.link-accent:hover { text-decoration: underline; }
.desc-text { font-size: 0.88rem; color: var(--ink-60); line-height: 1.5; }
.entity-desc { font-family: var(--font-body); font-size: 0.82rem; color: var(--ink-60); }

/* ── QA FIX: Missing Section Tag Variants ── */
.section-tag--comparisons { color: var(--accent-mid); }
.section-tag--compare { color: var(--accent-mid); }
.section-tag--analysis { color: var(--accent-dark); }
.section-tag--ranking, .section-tag--rankings { color: var(--accent2); }
.section-tag--data { color: var(--accent-mid); }
.section-tag--dashboard { color: var(--accent2); }
.section-tag--timeline, .section-tag--timelines { color: var(--section-space); }
.section-tag--map, .section-tag--maps { color: var(--accent-mid); }
.section-tag--guides { color: var(--accent-dark); }
.section-tag--glossary { color: var(--accent-mid); }
.section-tag--actors { color: var(--accent-dark); }
.section-tag--news { color: var(--accent2); }
.section-tag--funding { color: var(--accent2); }
.section-tag--about { color: var(--ink-60); }
.section-tag--tags { color: var(--ink-60); }

/* ── QA FIX: Table Improvements ── */
.gcc-table tbody tr:nth-child(odd) { background: rgba(0,35,149,0.015); }
.gcc-table th { border-bottom: 2px solid var(--ink-30, #B0A090); }

/* ── QA FIX: Hover & Interaction States ── */
.stream-item { transition: background 0.15s ease; }
.stream-item:hover { background: rgba(0,0,0,0.015); }
.top-stories__item { transition: background 0.15s ease; }
.top-stories__item:hover { background: rgba(0,0,0,0.015); }
.sidebar-indicator { transition: background 0.15s ease; }
.sidebar-indicator:hover { background: rgba(0,0,0,0.02); }
.network-link { transition: background 0.15s ease; }
.network-link:hover { background: rgba(0,0,0,0.02); }
.btn { transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.1s ease; }
.btn:active { transform: scale(0.98); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.badge { transition: background 0.15s ease; }

/* ── QA FIX: Responsive Grid ── */
@media (max-width: 1024px) {
  .grid-5-col { grid-template-columns: repeat(3, 1fr); }
  .grid-3-col { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-5-col { grid-template-columns: repeat(2, 1fr); }
  .grid-3-col { grid-template-columns: 1fr; }
}

/* ── Glossary A-Z Navigation ── */
.az-nav { display: flex; flex-wrap: wrap; gap: 6px; margin: 24px 0; }
.az-nav__link { display: inline-block; padding: 4px 10px; font-weight: 600; font-size: 13px; font-family: var(--font-mono, monospace); text-decoration: none; border-radius: 2px; transition: background 0.15s ease, color 0.15s ease; }
.az-nav__link--active { background: var(--accent-pale); color: var(--accent-dark); cursor: pointer; }
.az-nav__link--active:hover { background: var(--accent); color: #fff; }
.az-nav__link--disabled { background: transparent; color: var(--ink-20, #ccc); cursor: default; }
.glossary-letter-group { margin-top: 32px; }
.glossary-letter-group__heading { border-bottom: 2px solid var(--accent); padding-bottom: 6px; font-size: 1.5rem; color: var(--accent-dark); margin-bottom: 12px; }
.glossary-count { margin-top: 40px; text-align: center; font-size: 0.85rem; color: var(--ink-40); font-style: italic; }
