/* ════════════════════════════════════════════════════════════════
   Spark Intel - Premium Design System v2.1 (Dark / Light)
   ════════════════════════════════════════════════════════════════ */
/* ── Dark theme (default) ── */
:root {
  --navy-950: #000d1f;
  --navy-900: #00112A;
  --navy-800: #001940;
  --navy-700: #02376A;
  --navy-600: #095180;
  --navy-500: #187EB5;
  --accent-blue: #00ADD8;
  --accent-cyan: #35C2E0;
  --accent-indigo: #0094CA;
  --accent-teal: #6FCAC5;
  --accent-amber: #F79940;
  --accent-glow: rgba(0, 173, 216, 0.12);
  --amber-glow: rgba(247, 153, 64, 0.12);
  --teal-glow: rgba(111, 202, 197, 0.12);
  --text-primary: #f1f5f9;
  --text-secondary: #b4c4d6;
  --text-muted: #94adc8;
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.10);
  --glass-bg-strong: rgba(255, 255, 255, 0.07);
  --glass-border-strong: rgba(255, 255, 255, 0.12);
  /* Theme surface tokens (dark default) */
  --surface-body: #00112A;
  --surface-elevated: #001940;
  --surface-card: rgba(255, 255, 255, 0.035);
  --surface-card-hover: rgba(255, 255, 255, 0.08);
  --surface-input: #001940;
  --surface-nav: rgba(0, 17, 42, 0.65);
  --surface-mobile-menu: rgba(0, 13, 31, 0.98);
  --surface-footer: #00112A;
  --surface-pill: rgba(255, 255, 255, 0.04);
  --surface-pill-hover: rgba(0, 173, 216, 0.16);
  --surface-badge: rgba(255, 255, 255, 0.04);
  --surface-table-hover: rgba(0, 173, 216, 0.07);
  --surface-overlay: rgba(0, 17, 42, 0.85);
  --border-default: rgba(255, 255, 255, 0.07);
  --border-subtle: rgba(255, 255, 255, 0.04);
  --border-card: rgba(255, 255, 255, 0.07);
  --border-input: rgba(255, 255, 255, 0.10);
  --border-table: rgba(255, 255, 255, 0.08);
  --border-table-row: rgba(255, 255, 255, 0.03);
  --text-on-surface: #f1f5f9;
  --text-heading: #f1f5f9;
  --text-link: #82D2E7;
  --text-link-hover: #c0f0ff;
  --shadow-card: 0 16px 40px rgba(0, 0, 0, 0.25), 0 0 60px rgba(0, 173, 216, 0.10);
  --shadow-btn: 0 2px 8px rgba(0, 173, 216, 0.2), 0 8px 32px rgba(0, 173, 216, 0.1);
  --positive: #34d399;
  --negative: #f87171;
  --positive-bg: rgba(52, 211, 153, 0.10);
  --negative-bg: rgba(248, 113, 113, 0.10);
  --scrollbar-thumb: rgba(255, 255, 255, 0.15);
  --scrollbar-thumb-hover: rgba(255, 255, 255, 0.25);
  --divider: rgba(255, 255, 255, 0.1);
}
/* ── Light theme ── */
[data-theme="light"] {
  --navy-950: #f8fafc;
  --navy-900: #ffffff;
  --navy-800: #f1f5f9;
  --navy-700: #e2e8f0;
  --navy-600: #cbd5e1;
  --navy-500: #0284c7;
  --accent-blue: #0284c7;
  --accent-cyan: #0891b2;
  --accent-indigo: #0369a1;
  --accent-teal: #0d9488;
  --accent-amber: #d97706;
  --accent-glow: rgba(2, 132, 199, 0.08);
  --amber-glow: rgba(217, 119, 6, 0.08);
  --teal-glow: rgba(13, 148, 136, 0.08);
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --glass-bg: rgba(255, 255, 255, 0.70);
  --glass-border: rgba(0, 0, 0, 0.08);
  --glass-bg-strong: rgba(255, 255, 255, 0.85);
  --glass-border-strong: rgba(0, 0, 0, 0.10);
  --surface-body: #f8fafc;
  --surface-elevated: #ffffff;
  --surface-card: rgba(255, 255, 255, 0.80);
  --surface-card-hover: rgba(255, 255, 255, 0.95);
  --surface-input: #ffffff;
  --surface-nav: rgba(255, 255, 255, 0.80);
  --surface-mobile-menu: rgba(248, 250, 252, 0.98);
  --surface-footer: #f1f5f9;
  --surface-pill: rgba(0, 0, 0, 0.04);
  --surface-pill-hover: rgba(2, 132, 199, 0.10);
  --surface-badge: rgba(0, 0, 0, 0.04);
  --surface-table-hover: rgba(2, 132, 199, 0.06);
  --surface-overlay: rgba(241, 245, 249, 0.92);
  --border-default: rgba(0, 0, 0, 0.08);
  --border-subtle: rgba(0, 0, 0, 0.04);
  --border-card: rgba(0, 0, 0, 0.08);
  --border-input: rgba(0, 0, 0, 0.15);
  --border-table: rgba(0, 0, 0, 0.08);
  --border-table-row: rgba(0, 0, 0, 0.04);
  --text-on-surface: #0f172a;
  --text-heading: #0f172a;
  --text-link: #0369a1;
  --text-link-hover: #0284c7;
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.06), 0 1px 4px rgba(0, 0, 0, 0.04);
  --shadow-btn: 0 2px 8px rgba(2, 132, 199, 0.15), 0 4px 16px rgba(2, 132, 199, 0.08);
  --positive: #059669;
  --negative: #dc2626;
  --positive-bg: rgba(5, 150, 105, 0.08);
  --negative-bg: rgba(220, 38, 38, 0.08);
  --scrollbar-thumb: rgba(0, 0, 0, 0.15);
  --scrollbar-thumb-hover: rgba(0, 0, 0, 0.25);
  --divider: rgba(0, 0, 0, 0.08);
}
/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background-color: var(--surface-body);
  color: var(--text-primary);
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.theme-ready {
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.theme-ready {
}
/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0;
}
h1 { font-weight: 400; }
h2 { font-weight: 400; }
h3 { font-weight: 500; }
h4 { font-weight: 500; }
p  { line-height: 1.75; margin: 0; }
.gradient-text {
  background: linear-gradient(135deg, #82D2E7 0%, #00ADD8 42%, #6FCAC5 75%, #5AB8B3 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.gradient-text-warm {
  background: linear-gradient(135deg, #f1f5f9 0%, #cbd5e1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.gradient-text-amber {
  background: linear-gradient(135deg, #fcd34d 0%, #F79940 60%, #d4874a 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
/* ── Hero Background ── */
.hero-gradient {
  position: relative;
  overflow: hidden;
}
.hero-gradient::before {
  content: '';
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 160%;
  height: 120%;
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(0, 173, 216, 0.22), transparent 70%),
    radial-gradient(ellipse 50% 45% at 30% 15%, rgba(0, 148, 202, 0.14), transparent 60%),
    radial-gradient(ellipse 50% 45% at 70% 15%, rgba(53, 194, 224, 0.10), transparent 60%),
    radial-gradient(ellipse 80% 40% at 50% 90%, rgba(0, 25, 64, 0.60), transparent 70%),
    radial-gradient(ellipse 40% 35% at 85% 80%, rgba(247, 153, 64, 0.07), transparent 65%),
    radial-gradient(ellipse 35% 30% at 15% 85%, rgba(111, 202, 197, 0.06), transparent 60%);
  pointer-events: none;
  z-index: 0;
}
.hero-gradient::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to top, var(--navy-900), transparent);
  pointer-events: none;
  z-index: 0;
}
.hero-gradient > .fade-up, .hero-gradient > nav[aria-label], .hero-gradient > .hero-content {
  position: relative;
  z-index: 1;
}
/* Subtle grid mesh overlay for hero sections */
.hero-mesh {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black 20%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.orb-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.4;
  pointer-events: none;
  z-index: 0;
}
/* ── Navigation ── */
.nav-blur {
  background: var(--surface-nav);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  transition: background 0.3s ease;
}
.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 400;
  transition: color 0.25s ease;
  letter-spacing: -0.01em;
}
.nav-link:hover,
.nav-link.active {
  color: #e2e8f0;
}
.nav-link:hover {
  color: #82D2E7;
  text-shadow: 0 0 10px rgba(130, 210, 231, 0.2);
}
/* ── Buttons ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.75rem;
  background: linear-gradient(135deg, #00ADD8, #0094CA);
  color: #fff;
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 100px;
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: transform 0.2s ease, box-shadow 0.3s ease, filter 0.2s ease;
  box-shadow:
    0 0 0 1px rgba(0, 148, 202, 0.25),
    0 2px 8px rgba(0, 173, 216, 0.2),
    0 8px 32px rgba(0, 173, 216, 0.1);
}
.btn-primary:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow:
    0 0 0 1px rgba(0, 148, 202, 0.6),
    0 4px 24px rgba(0, 173, 216, 0.5),
    0 12px 48px rgba(0, 173, 216, 0.25),
    0 0 60px rgba(0, 173, 216, 0.15);
  filter: brightness(1.2);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.75rem;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.875rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 100px;
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(130, 210, 231, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25), 0 0 30px rgba(0, 173, 216, 0.08);
  color: #fff;
}
/* ── Glass Panels ── */
.glass-panel {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1.25rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: border-color 0.35s ease, background 0.35s ease, transform 0.35s cubic-bezier(.4,0,.2,1), box-shadow 0.35s ease;
}
.glass-panel:hover {
  border-color: rgba(0, 173, 216, 0.30);
  background: var(--surface-card-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}
.glass-panel-strong {
  background: var(--glass-bg-strong);
  border: 1px solid var(--glass-border-strong);
  border-radius: 1.5rem;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.glow-accent {
  box-shadow:
    0 0 80px rgba(0, 173, 216, 0.08),
    0 0 160px rgba(0, 148, 202, 0.04),
    0 24px 48px rgba(0, 0, 0, 0.15);
}
/* ── Dividers ── */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--divider), transparent);
}
/* ── Category Cards ── */
.category-card {
  background: var(--surface-card);
  border: 1px solid var(--border-card);
  border-radius: 1.25rem;
  padding: 2rem;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: block;
}
.category-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at 50% 0%, rgba(0, 173, 216, 0.08), transparent 60%);
  opacity: 0;
  transition: opacity 0.35s ease;
}
.category-card:hover {
  border-color: rgba(0, 173, 216, 0.35);
  background: var(--surface-card-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
}
.category-card:hover::before { opacity: 1; }
.sub-tag {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  background: rgba(0, 173, 216, 0.08);
  border: 1px solid rgba(0, 173, 216, 0.12);
  border-radius: 100px;
  color: #82D2E7;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background 0.2s ease, border-color 0.2s ease;
  text-decoration: none;
}
.sub-tag:hover {
  background: rgba(0, 173, 216, 0.22);
  border-color: rgba(0, 173, 216, 0.45);
  color: #c0f0ff;
  box-shadow: 0 0 12px rgba(0, 173, 216, 0.12);
}
/* ── Sections ── */
.section    { padding: 4.5rem 0; }
.section-sm { padding: 2.75rem 0; }
@media (min-width: 768px) {
  .section    { padding: 6.5rem 0; }
  .section-sm { padding: 4rem 0; }
}
/* ── Stats ── */
.stat-block  { text-align: center; padding: 1.5rem; }
.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
}
@media (min-width: 640px) {
  .stat-number { font-size: 3.5rem; }
}
/* ── Calculator Category Pill Nav ── */
.calc-pill-nav {
  position: sticky;
  top: 80px;
  z-index: 40;
  background: var(--surface-overlay);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid var(--border-subtle);
}
.calc-pill-nav-inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.calc-pill-nav-inner::-webkit-scrollbar { display: none; }
.calc-pill {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.875rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--surface-pill);
  border: 1px solid var(--border-default);
  text-decoration: none;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
  white-space: nowrap;
}
.calc-pill:hover {
  color: #c0f0ff;
  background: rgba(0, 173, 216, 0.16);
  border-color: rgba(0, 173, 216, 0.4);
  box-shadow: 0 0 10px rgba(0, 173, 216, 0.1);
}
.calc-pill.active {
  color: #35C2E0;
  background: rgba(0, 173, 216, 0.12);
  border-color: rgba(0, 173, 216, 0.35);
}
/* ── Scroll Down Indicator ── */
.scroll-indicator {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  color: rgba(148, 163, 184, 0.55);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  animation: bounce-down 2s ease-in-out infinite;
}
@keyframes bounce-down {
  0%, 100% { transform: translateY(0); opacity: 0.4; }
  50%       { transform: translateY(6px); opacity: 0.75; }
}
/* ── Report Cards ── */
.report-stat-card {
  background: var(--surface-card);
  border: 1px solid var(--border-card);
  border-radius: 1rem;
  padding: 1.25rem 1rem 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  min-height: 6.5rem;
  overflow: visible;
  transition: border-color 0.3s ease, background 0.3s ease;
}
.report-stat-card:hover {
  border-color: var(--border-default);
  background: var(--surface-card-hover);
}
.report-stat-card p:first-child {
  flex: 1;
  line-height: 1.4;
  margin-bottom: 0.5rem;
}
.report-stat-card p:last-child {
  line-height: 1.2;
  word-break: break-word;
  overflow-wrap: anywhere;
  padding-bottom: 2px;
}
/* ── Report Tables ── */
.report-table {
  border-collapse: collapse;
  border-spacing: 0;
}
.report-table thead th {
  padding: 0.75rem;
  font-weight: 500;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-align: right;
  border-bottom: 1px solid var(--border-table);
  white-space: nowrap;
}
.report-table thead th:first-child { text-align: left; }
.report-table tbody td {
  padding: 0.6rem 0.75rem;
  text-align: right;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-table-row);
  white-space: nowrap;
}
.report-table tbody td[class*="text-emerald"] { color: var(--positive); }
.report-table tbody td[class*="text-red"] { color: var(--negative); }
.report-table tbody td:first-child {
  text-align: left;
  color: var(--text-primary);
  font-weight: 400;
}
.report-table tbody tr:hover td {
  background: var(--surface-table-hover);
}
.report-table tbody tr:hover td:first-child {
  box-shadow: inset 2px 0 0 var(--accent-blue);
}
/* ── Table scroll wrappers ── */
.overflow-x-auto {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) transparent;
}
.overflow-x-auto::-webkit-scrollbar { height: 6px; }
.overflow-x-auto::-webkit-scrollbar-track { background: transparent; }
.overflow-x-auto::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 3px;
}
.overflow-x-auto::-webkit-scrollbar-thumb:hover {
  background: var(--scrollbar-thumb-hover);
}
/* ── FAQ ── */
.faq-item {
  border-bottom: 1px solid var(--border-subtle);
}
.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 1.25rem 0;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: color 0.2s ease;
  letter-spacing: -0.01em;
}
.faq-question:hover { color: #82D2E7; text-shadow: 0 0 8px rgba(130, 210, 231, 0.2); }
/* ── Breadcrumb hover ── */
.breadcrumb a:hover { color: #82D2E7 !important; text-shadow: 0 0 8px rgba(130, 210, 231, 0.25); }
/* ── Footer link hover ── */
footer a:hover { color: #82D2E7 !important; text-shadow: 0 0 8px rgba(130, 210, 231, 0.2); }
.faq-icon {
  flex-shrink: 0;
  width: 1.125rem;
  height: 1.125rem;
  color: var(--text-muted);
  transition: transform 0.3s ease, color 0.2s ease;
}
.faq-item.open .faq-icon {
  transform: rotate(45deg);
  color: var(--accent-blue);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease;
}
.faq-item.open .faq-answer {
  max-height: 500px;
  padding-bottom: 1.25rem;
}
/* ── Mobile Menu ── */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 40;
  background: var(--surface-mobile-menu);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  color: var(--text-primary);
  font-size: 1.5rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: -0.02em;
}
.hamburger span {
  display: block;
  width: 1.25rem;
  height: 1.5px;
  background: var(--text-secondary);
  transition: transform 0.3s ease, opacity 0.2s ease;
  border-radius: 2px;
}
.hamburger.active span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
/* ── Scroll Animations ── */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}
.stagger-children > .fade-up:nth-child(1) { transition-delay: 0s; }
.stagger-children > .fade-up:nth-child(2) { transition-delay: 0.1s; }
.stagger-children > .fade-up:nth-child(3) { transition-delay: 0.15s; }
.stagger-children > .fade-up:nth-child(4) { transition-delay: 0.2s; }
/* ── Keyframes ── */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}
@keyframes pulse-glow {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.6; }
}
.animate-float      { animation: float 6s ease-in-out infinite; }
.animate-pulse-glow { animation: pulse-glow 4s ease-in-out infinite; }
/* ── Decorative ── */
.line-accent {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-cyan));
  border-radius: 2px;
}
.line-accent-amber {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, rgba(247,153,64,0.7), rgba(252,211,77,0.5));
  border-radius: 2px;
}
.line-accent-teal {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-teal), #82D2E7);
  border-radius: 2px;
}
/* ── Amber Button ── */
.btn-amber {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.75rem;
  background: linear-gradient(135deg, rgba(247,153,64,0.88), rgba(217,110,16,0.82));
  color: #fff;
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 100px;
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: transform 0.2s ease, box-shadow 0.3s ease, filter 0.2s ease;
  box-shadow:
    0 0 0 1px rgba(247, 153, 64, 0.18),
    0 2px 8px rgba(247, 153, 64, 0.14),
    0 8px 32px rgba(247, 153, 64, 0.07);
}
.btn-amber:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow:
    0 0 0 1px rgba(247, 153, 64, 0.5),
    0 4px 24px rgba(247, 153, 64, 0.4),
    0 12px 48px rgba(247, 153, 64, 0.2),
    0 0 60px rgba(247, 153, 64, 0.1);
  filter: brightness(1.18);
}
/* ── Teal & Amber Tag Variants ── */
.sub-tag-teal {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  background: rgba(111, 202, 197, 0.08);
  border: 1px solid rgba(111, 202, 197, 0.2);
  border-radius: 100px;
  color: #6FCAC5;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.sub-tag-teal:hover {
  background: rgba(111, 202, 197, 0.2);
  border-color: rgba(111, 202, 197, 0.4);
  color: #8fd8d3;
}
.sub-tag-amber {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  background: rgba(247, 153, 64, 0.08);
  border: 1px solid rgba(247, 153, 64, 0.2);
  border-radius: 100px;
  color: #F79940;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.sub-tag-amber:hover {
  background: rgba(247, 153, 64, 0.2);
  border-color: rgba(247, 153, 64, 0.4);
  color: #f9b16e;
}
/* ── Amber glow accent ── */
.glow-accent-amber {
  box-shadow:
    0 0 80px rgba(247, 153, 64, 0.08),
    0 0 160px rgba(247, 153, 64, 0.04),
    0 24px 48px rgba(0, 0, 0, 0.15);
}
/* ── Focus States ── */
:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
  border-radius: 4px;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
}
/* ── Skip Link ── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--accent-blue);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  z-index: 100;
  text-decoration: none;
}
.skip-link:focus { top: 1rem; }
/* ── Footer ── */
footer a { transition: color 0.25s ease; }
/* ── Section anchor nav ── */
.section-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 1rem 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
}
.section-nav::-webkit-scrollbar { display: none; }
.section-nav a {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.4rem 1rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--surface-pill);
  border: 1px solid var(--border-default);
  text-decoration: none;
  transition: color 0.2s, background 0.2s, border-color 0.2s, box-shadow 0.2s;
  white-space: nowrap;
}
.section-nav a:hover {
  color: var(--text-link-hover);
  background: var(--surface-pill-hover);
  border-color: rgba(0, 173, 216, 0.4);
  box-shadow: 0 0 12px rgba(0, 173, 216, 0.1);
}
/* ════════════════════════════════════════════════════════════════
   Theme Toggle UI
   ════════════════════════════════════════════════════════════════ */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  border: 1px solid var(--border-default);
  border-radius: 0.5rem;
  background: var(--surface-pill);
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, transform 0.15s ease;
  flex-shrink: 0;
}
.theme-toggle:hover {
  color: var(--accent-blue);
  background: var(--surface-pill-hover);
  border-color: rgba(0, 173, 216, 0.4);
  transform: scale(1.08);
}
.theme-toggle svg {
  width: 1.125rem;
  height: 1.125rem;
  transition: transform 0.3s ease;
}
.theme-toggle:hover svg {
  transform: rotate(15deg);
}
/* Icon visibility per theme */
.theme-toggle .icon-sun  { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="light"] .theme-toggle .icon-sun  { display: block; }
[data-theme="light"] .theme-toggle .icon-moon { display: none; }

  /* Dark theme accessibility contrast override */
  .text-slate-500 {
    color: #7e8fa3 !important;
  }

  /* ════════════════════════════════════════════════════════════════
   Light Theme - Component Overrides
   ════════════════════════════════════════════════════════════════ */
/* Smooth transition for all themed elements */
[data-theme="light"] *,
[data-theme="light"] *::before,
[data-theme="light"] *::after {
  transition-property: background-color, border-color, color, box-shadow, opacity;
  transition-duration: 0.3s;
  transition-timing-function: ease;
}
/* ── Gradient text adjustments for light mode ── */
[data-theme="light"] .gradient-text {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 42%, #0d9488 75%, #0f766e 100%);
  -webkit-background-clip: text;
  background-clip: text;
}
[data-theme="light"] .gradient-text-warm {
  background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
  -webkit-background-clip: text;
  background-clip: text;
}
[data-theme="light"] .gradient-text-amber {
  background: linear-gradient(135deg, #b45309 0%, #d97706 60%, #92400e 100%);
  -webkit-background-clip: text;
  background-clip: text;
}
/* ── Hero section ── */
[data-theme="light"] .hero-gradient::before {
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(2, 132, 199, 0.10), transparent 70%),
    radial-gradient(ellipse 50% 45% at 30% 15%, rgba(3, 105, 161, 0.06), transparent 60%),
    radial-gradient(ellipse 50% 45% at 70% 15%, rgba(8, 145, 178, 0.05), transparent 60%),
    radial-gradient(ellipse 80% 40% at 50% 90%, rgba(241, 245, 249, 0.60), transparent 70%),
    radial-gradient(ellipse 40% 35% at 85% 80%, rgba(217, 119, 6, 0.04), transparent 65%),
    radial-gradient(ellipse 35% 30% at 15% 85%, rgba(13, 148, 136, 0.03), transparent 60%);
}
[data-theme="light"] .hero-gradient::after {
  background: linear-gradient(to top, var(--surface-body), transparent);
}
[data-theme="light"] .hero-mesh {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.03) 1px, transparent 1px);
}
[data-theme="light"] .orb-glow {
  opacity: 0.25;
}
/* ── Navigation ── */
[data-theme="light"] .nav-link {
  color: var(--text-muted);
}
[data-theme="light"] .nav-link:hover,
[data-theme="light"] .nav-link.active {
  color: var(--text-primary);
  text-shadow: none;
}
[data-theme="light"] .nav-link:hover {
  color: var(--accent-blue);
  text-shadow: none;
}
[data-theme="light"] .hamburger span {
  background: var(--text-secondary);
}
/* ── Buttons ── */
[data-theme="light"] .btn-primary {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #fff;
  box-shadow:
    0 0 0 1px rgba(3, 105, 161, 0.15),
    0 2px 8px rgba(2, 132, 199, 0.15),
    0 4px 16px rgba(2, 132, 199, 0.08);
}
[data-theme="light"] .btn-primary:hover {
  box-shadow:
    0 0 0 1px rgba(3, 105, 161, 0.4),
    0 4px 24px rgba(2, 132, 199, 0.3),
    0 8px 32px rgba(2, 132, 199, 0.15);
}
[data-theme="light"] .btn-secondary {
  background: rgba(0, 0, 0, 0.03);
  color: var(--text-primary);
  border-color: var(--border-default);
}
[data-theme="light"] .btn-secondary:hover {
  background: rgba(0, 0, 0, 0.06);
  border-color: var(--accent-blue);
  color: var(--text-primary);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}
[data-theme="light"] .btn-amber {
  background: linear-gradient(135deg, #d97706, #b45309);
  box-shadow:
    0 0 0 1px rgba(217, 119, 6, 0.15),
    0 2px 8px rgba(217, 119, 6, 0.12),
    0 4px 16px rgba(217, 119, 6, 0.06);
}
[data-theme="light"] .btn-amber:hover {
  box-shadow:
    0 0 0 1px rgba(217, 119, 6, 0.4),
    0 4px 24px rgba(217, 119, 6, 0.25),
    0 8px 32px rgba(217, 119, 6, 0.12);
}
/* ── Glass panels ── */
[data-theme="light"] .glass-panel {
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
[data-theme="light"] .glass-panel:hover {
  border-color: rgba(2, 132, 199, 0.25);
  box-shadow: var(--shadow-card);
}
[data-theme="light"] .glass-panel-strong {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
/* ── Glow accents muted for light mode ── */
[data-theme="light"] .glow-accent {
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.04),
    0 4px 16px rgba(2, 132, 199, 0.06);
}
[data-theme="light"] .glow-accent-amber {
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.04),
    0 4px 16px rgba(217, 119, 6, 0.06);
}
/* ── Category card ── */
[data-theme="light"] .category-card::before {
  background: radial-gradient(circle at 50% 0%, rgba(2, 132, 199, 0.05), transparent 60%);
}
[data-theme="light"] .category-card:hover {
  border-color: rgba(2, 132, 199, 0.25);
}
/* ── Sub tags ── */
[data-theme="light"] .sub-tag {
  background: rgba(2, 132, 199, 0.06);
  border-color: rgba(2, 132, 199, 0.12);
  color: #0369a1;
}
[data-theme="light"] .sub-tag:hover {
  background: rgba(2, 132, 199, 0.14);
  border-color: rgba(2, 132, 199, 0.3);
  color: #0284c7;
  box-shadow: 0 0 8px rgba(2, 132, 199, 0.08);
}
[data-theme="light"] .sub-tag-teal {
  background: rgba(13, 148, 136, 0.06);
  border-color: rgba(13, 148, 136, 0.15);
  color: #0f766e;
}
[data-theme="light"] .sub-tag-teal:hover {
  background: rgba(13, 148, 136, 0.12);
  border-color: rgba(13, 148, 136, 0.3);
  color: #0d9488;
}
[data-theme="light"] .sub-tag-amber {
  background: rgba(217, 119, 6, 0.06);
  border-color: rgba(217, 119, 6, 0.15);
  color: #92400e;
}
[data-theme="light"] .sub-tag-amber:hover {
  background: rgba(217, 119, 6, 0.12);
  border-color: rgba(217, 119, 6, 0.3);
  color: #b45309;
}
/* ── Calc pills & Section nav - hover ── */
[data-theme="light"] .calc-pill:hover {
  color: #0284c7;
  background: var(--surface-pill-hover);
  border-color: rgba(2, 132, 199, 0.3);
  box-shadow: 0 0 6px rgba(2, 132, 199, 0.06);
}
[data-theme="light"] .calc-pill.active {
  color: #0284c7;
  background: rgba(2, 132, 199, 0.08);
  border-color: rgba(2, 132, 199, 0.25);
}
[data-theme="light"] .section-nav a:hover {
  color: #0284c7;
  background: var(--surface-pill-hover);
  border-color: rgba(2, 132, 199, 0.3);
  box-shadow: 0 0 6px rgba(2, 132, 199, 0.06);
}
/* ── Report table ── */
[data-theme="light"] .report-table tbody tr:hover td:first-child {
  box-shadow: inset 2px 0 0 var(--accent-blue);
}
/* ── FAQ ── */
[data-theme="light"] .faq-question:hover {
  color: var(--accent-blue);
  text-shadow: none;
}
/* ── Breadcrumbs & Footer ── */
[data-theme="light"] .breadcrumb a:hover {
  color: var(--accent-blue) !important;
  text-shadow: none;
}
[data-theme="light"] footer a:hover {
  color: var(--accent-blue) !important;
  text-shadow: none;
}
/* ── Line accents ── */
[data-theme="light"] .line-accent {
  background: linear-gradient(90deg, #0284c7, #0891b2);
}
[data-theme="light"] .line-accent-amber {
  background: linear-gradient(90deg, rgba(217,119,6,0.6), rgba(180,83,9,0.4));
}
[data-theme="light"] .line-accent-teal {
  background: linear-gradient(90deg, #0d9488, #0891b2);
}
/* ── Mobile menu ── */
[data-theme="light"] .mobile-menu a {
  color: var(--text-primary);
}
/* ════════════════════════════════════════════════════════════════
   Light Theme - Tailwind Utility Class Overrides
   Overriding classes used in HTML with [data-theme="light"]
   ════════════════════════════════════════════════════════════════ */
/* Body-level background and text */
[data-theme="light"].bg-navy-900,
[data-theme="light"] .bg-navy-900 {
  background-color: var(--surface-body) !important;
}
[data-theme="light"].text-slate-100,
[data-theme="light"] .text-slate-100,
[data-theme="light"].text-slate-200,
[data-theme="light"] .text-slate-200 {
  color: var(--text-primary) !important;
}
/* Border utilities */
[data-theme="light"] .border-white\/\[0\.04\],
[data-theme="light"] .border-white\/\[0\.06\] {
  border-color: var(--border-subtle) !important;
}
[data-theme="light"] .border-white\/5,
[data-theme="light"] .border-white\/10 {
  border-color: var(--border-default) !important;
}
/* Text color utilities */
[data-theme="light"] .text-slate-400 {
  color: var(--text-secondary) !important;
}
[data-theme="light"] .text-slate-500 {
  color: var(--text-muted) !important;
}
[data-theme="light"] .text-slate-300 {
  color: var(--text-primary) !important;
}
[data-theme="light"] .text-white {
  color: var(--text-heading) !important;
}
/* Keep buttons white on accent backgrounds */
[data-theme="light"] .btn-primary .text-white,
[data-theme="light"] .btn-primary,
[data-theme="light"] .btn-amber,
[data-theme="light"] .btn-amber .text-white {
  color: #fff !important;
}
/* Background surface overrides */
[data-theme="light"] .bg-navy-800 {
  background-color: var(--surface-elevated) !important;
}
[data-theme="light"] .bg-navy-950 {
  background-color: var(--surface-body) !important;
}
[data-theme="light"] .bg-white\/\[0\.02\],
[data-theme="light"] .bg-white\/\[0\.03\],
[data-theme="light"] .bg-white\/\[0\.04\] {
  background-color: var(--surface-pill) !important;
}
/* Ring utilities */
[data-theme="light"] .ring-white\/\[0\.06\] {
  --tw-ring-color: var(--border-default) !important;
}
/* Variance colors */
[data-theme="light"] .text-emerald-400 {
  color: var(--positive) !important;
}
[data-theme="light"] .text-red-400 {
  color: var(--negative) !important;
}
/* Blue accent text */
[data-theme="light"] .text-blue-400,
[data-theme="light"] .text-blue-300 {
  color: var(--accent-blue) !important;
}
/* Amber and teal accent text */
[data-theme="light"] .text-amber-400 {
  color: var(--accent-amber) !important;
}
[data-theme="light"] .text-teal-400 {
  color: var(--accent-teal) !important;
}
/* Badge backgrounds */
[data-theme="light"] .bg-red-500\/10 {
  background-color: var(--negative-bg) !important;
}
[data-theme="light"] .bg-emerald-500\/10,
[data-theme="light"] .bg-green-500\/10 {
  background-color: var(--positive-bg) !important;
}
[data-theme="light"] .bg-accent-blue\/10,
[data-theme="light"] .bg-blue-500\/10 {
  background-color: rgba(2, 132, 199, 0.08) !important;
}
/* Badge border colors */
[data-theme="light"] .border-red-500\/20 {
  border-color: rgba(220, 38, 38, 0.20) !important;
}
[data-theme="light"] .border-blue-500\/20 {
  border-color: rgba(2, 132, 199, 0.20) !important;
}
[data-theme="light"] .border-blue-500\/30 {
  border-color: rgba(2, 132, 199, 0.30) !important;
}
/* Hover background for interactive cards */
[data-theme="light"] .hover\:bg-blue-500\/\[0\.04\]:hover {
  background-color: rgba(2, 132, 199, 0.06) !important;
}
[data-theme="light"] .hover\:border-blue-500\/30:hover {
  border-color: rgba(2, 132, 199, 0.25) !important;
}
/* Group hover text */
[data-theme="light"] .group:hover .group-hover\:text-white {
  color: var(--accent-blue) !important;
}
/* Focus ring overrides */
[data-theme="light"] .focus\:border-blue-500\/50:focus {
  border-color: rgba(2, 132, 199, 0.50) !important;
}
[data-theme="light"] .focus\:ring-blue-500\/30:focus {
  --tw-ring-color: rgba(2, 132, 199, 0.30) !important;
}
/* Calculator input overrides */
[data-theme="light"] input.bg-navy-800,
[data-theme="light"] select.bg-navy-800,
[data-theme="light"] textarea.bg-navy-800 {
  background-color: var(--surface-input) !important;
  color: var(--text-primary) !important;
  border-color: var(--border-input) !important;
}
[data-theme="light"] .placeholder-slate-500::placeholder {
  color: var(--text-muted) !important;
}
/* Logo - keep readable */
[data-theme="light"] header img[alt*="Intel"] {
  filter: brightness(0) saturate(100%) invert(8%) sepia(50%) saturate(4000%) hue-rotate(200deg) brightness(95%);
}
/* Scroll indicator */
[data-theme="light"] .scroll-indicator {
  color: rgba(100, 116, 139, 0.5);
}
/* Skip link remains high-contrast */
[data-theme="light"] .skip-link {
  background: var(--accent-blue);
  color: #fff;
}
/* ── Report page spacing adjustments ── */
.hero-gradient > nav[aria-label="Breadcrumb"] {
  padding-bottom: 1.75rem;
}
.hero-gradient:not(.hero-compact) {
  padding-top: 8rem;
}
@media (min-width: 768px) {
  .hero-gradient:not(.hero-compact) {
    padding-top: 11rem;
  }
}

/* Dynamic category cards */
.category-expandable {
  cursor: pointer;
  transition: border-color 0.3s ease;
}
.category-expandable.is-open {
  border-color: rgba(59, 130, 246, 0.2);
}
.category-expandable .category-chevron {
  transition: transform 0.3s ease;
}
.category-expandable.is-open .category-chevron {
  transform: rotate(180deg);
}
.category-dropdown {
  overflow: hidden;
  transition: max-height 0.4s ease, opacity 0.3s ease;
}
.category-link-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 0.875rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.875rem;
  color: var(--slate-200, #e2e8f0);
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s;
}
.category-link-item:hover {
  background: rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.15);
  color: #fff;
}
.category-view-all {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--accent-blue, #3b82f6);
  text-decoration: none;
  transition: gap 0.2s;
}
.category-view-all:hover {
  gap: 0.5rem;
}
.if-tab, .uk-year-tab, .la-quarter-tab {
  padding: 0.375rem 0.875rem;
  border-radius: 0.375rem;
  font-size: 0.8125rem;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--slate-400, #94a3b8);
  cursor: pointer;
  transition: all 0.2s;
}
.if-tab:hover, .uk-year-tab:hover, .la-quarter-tab:hover {
  background: rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.15);
  color: #fff;
}
.if-tab.active, .uk-year-tab.active, .la-quarter-tab.active {
  background: rgba(59, 130, 246, 0.15);
  border-color: rgba(59, 130, 246, 0.3);
  color: #fff;
}
.category-select {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--slate-200, #e2e8f0);
  font-size: 0.875rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.5rem center;
  background-size: 1.25rem;
}
.category-select:focus {
  outline: none;
  border-color: rgba(59, 130, 246, 0.4);
}
.category-select option {
  background: #0a1929;
  color: #e2e8f0;
}
[data-theme="light"] .category-link-item {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.06);
  color: #1e293b;
}
[data-theme="light"] .category-link-item:hover {
  background: rgba(59, 130, 246, 0.06);
  border-color: rgba(59, 130, 246, 0.15);
  color: #0f172a;
}
[data-theme="light"] .if-tab, [data-theme="light"] .uk-year-tab, [data-theme="light"] .la-quarter-tab {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.08);
  color: #475569;
}
[data-theme="light"] .if-tab:hover, [data-theme="light"] .uk-year-tab:hover, [data-theme="light"] .la-quarter-tab:hover {
  background: rgba(59, 130, 246, 0.06);
  color: #1e293b;
}
[data-theme="light"] .if-tab.active, [data-theme="light"] .uk-year-tab.active, [data-theme="light"] .la-quarter-tab.active {
  background: rgba(59, 130, 246, 0.1);
  border-color: rgba(59, 130, 246, 0.25);
  color: #1e40af;
}
[data-theme="light"] .category-select {
  background-color: #fff;
  border-color: rgba(0, 0, 0, 0.1);
  color: #1e293b;
}
[data-theme="light"] .category-select option {
  background: #fff;
  color: #1e293b;
}

.mega-menu-wrapper { position: relative; }
.mega-dropdown {
  position: fixed;
  top: 4.5rem;
  left: 0;
  right: 0;
  z-index: 49;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  pointer-events: none;
  padding-top: 0.5rem;
}
.mega-dropdown::before {
  content: '';
  position: absolute;
  top: -1rem;
  left: 0;
  right: 0;
  height: 1.5rem;
}
.mega-dropdown.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.mega-inner {
  max-width: 80rem;
  margin: 0 auto;
  display: flex;
  background: var(--bg-secondary, #0d1f38);
  border: 1px solid rgba(255,255,255,0.06);
  border-top: none;
  border-radius: 0 0 0.75rem 0.75rem;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
  min-height: 340px;
  max-height: calc(100vh - 5.5rem);
  overflow: hidden;
}
.mega-left {
  width: 220px;
  min-width: 220px;
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 0.5rem 0;
  display: flex;
  flex-direction: column;
}
.mega-left-item {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  transition: all 0.15s;
  border-left: 2px solid transparent;
}
.mega-left-item:hover,
.mega-left-item.is-active {
  color: #fff;
  background: rgba(59,130,246,0.06);
  border-left-color: rgba(59,130,246,0.5);
}
.mega-left-sub {
  display: flex;
  flex-direction: column;
  padding-left: 1rem;
}
.mega-type-item {
  display: flex;
  align-items: center;
  padding: 0.375rem 1.25rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--slate-500, #64748b);
  text-decoration: none;
  transition: all 0.15s;
  border-left: 2px solid transparent;
  letter-spacing: 0.01em;
}
.mega-type-item:hover {
  color: var(--slate-300, #cbd5e1);
  background: rgba(255,255,255,0.02);
}
.mega-type-item.is-active {
  color: #60a5fa;
  background: rgba(59,130,246,0.06);
  border-left-color: rgba(59,130,246,0.5);
  font-weight: 600;
}
.mega-ref-footer {
  margin-top: auto;
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 0.75rem 1.25rem;
}
.mega-ref-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate-500, #64748b);
  margin-bottom: 0.5rem;
}
.mega-ref-link {
  display: block;
  font-size: 0.75rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  padding: 0.2rem 0;
  transition: color 0.15s;
}
.mega-ref-link:hover { color: #fff; }
[data-theme="light"] .mega-ref-footer { border-top-color: rgba(0,0,0,0.06); }
[data-theme="light"] .mega-ref-label { color: #94a3b8; }
[data-theme="light"] .mega-ref-link { color: #64748b; }
[data-theme="light"] .mega-ref-link:hover { color: #1e293b; }
.mega-year-item {
  display: flex;
  align-items: center;
  padding: 0.4rem 1.25rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  transition: all 0.15s;
  border-left: 2px solid transparent;
}
.mega-year-item:hover,
.mega-year-item.is-active {
  color: #fff;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}
.mega-right {
  flex: 1;
  padding: 1.25rem 1.5rem;
  overflow-y: auto;
}
.mega-panel { display: none; }
.mega-panel.is-active { display: block; }
.mega-panel-date {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: rgba(247,153,64,0.7);
  margin-bottom: 1rem;
}
.mega-panel-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.mega-col-heading {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--slate-300, #cbd5e1);
  margin-bottom: 0.625rem;
}
.mega-col-heading a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s;
}
.mega-col-heading a:hover { color: #fff; }
.mega-col-heading--disabled {
  color: var(--slate-500, #64748b);
}
.mega-col-desc {
  font-size: 0.8125rem;
  color: var(--slate-500, #64748b);
  margin-bottom: 0.5rem;
  line-height: 1.4;
}
.mega-col-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.mega-col-list li { margin-bottom: 0.125rem; }
.mega-col-list a {
  display: block;
  padding: 0.25rem 0;
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  transition: color 0.15s;
}
.mega-col-list a:hover { color: #fff; }
.mega-col-list--disabled span {
  display: block;
  padding: 0.25rem 0;
  font-size: 0.8125rem;
  color: var(--slate-600, #475569);
  cursor: default;
}
.mega-view-all {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(59,130,246,0.7);
  text-decoration: none;
  transition: color 0.15s;
}
.mega-view-all:hover { color: rgba(59,130,246,1); }
.mega-lender-az-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding-bottom: 0.75rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.mega-az-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  border-radius: 0.375rem;
  transition: color 0.15s, background 0.15s;
}
.mega-az-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
}
.mega-az-btn.is-active {
  color: #fff;
  background: rgba(59,130,246,0.15);
}
.mega-lender-results {
  overflow-y: auto;
  max-height: 320px;
}
.mega-lender-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.125rem 1.25rem;
}
.mega-az-viewall {
  display: inline-flex;
  align-items: center;
  padding: 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(59,130,246,0.7);
  text-decoration: none;
  transition: color 0.15s;
  white-space: nowrap;
}
.mega-az-viewall:hover { color: rgba(59,130,246,1); }
.mega-lender-link {
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  padding: 0.25rem 0;
  transition: color 0.15s;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mega-lender-link:hover { color: #fff; }

/* ── Lender Directory Cards ── */
.lender-dir-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.75rem;
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.lender-dir-card:hover {
  border-color: rgba(59,130,246,0.3);
  background: var(--surface-card-hover);
  transform: translateY(-1px);
}
.lender-dir-info {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
  min-width: 0;
}
.lender-dir-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--slate-300, #cbd5e1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.group:hover .lender-dir-name { color: #fff; }
.lender-dir-cohort {
  font-size: 0.75rem;
  color: var(--slate-600, #475569);
  line-height: 1.3;
}
.lender-dir-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  margin-left: 0.75rem;
}
.lender-dir-quarters {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--slate-600, #475569);
}
.lender-dir-arrow {
  width: 0.875rem;
  height: 0.875rem;
  color: var(--slate-700, #334155);
  transition: color 0.2s, transform 0.2s;
}
.group:hover .lender-dir-arrow {
  color: rgba(59,130,246,0.7);
  transform: translateX(2px);
}

[data-theme="light"] .lender-dir-card {
  background: rgba(0,0,0,0.02);
  border-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .lender-dir-card:hover {
  border-color: rgba(59,130,246,0.25);
  background: rgba(0,0,0,0.03);
}
[data-theme="light"] .lender-dir-name { color: #334155; }
[data-theme="light"] .group:hover .lender-dir-name { color: #0f172a; }
[data-theme="light"] .lender-dir-cohort { color: #94a3b8; }
[data-theme="light"] .lender-dir-quarters { color: #94a3b8; }
[data-theme="light"] .lender-dir-arrow { color: #cbd5e1; }

.rp-quarter-tabs {
  display: flex;
  gap: 0.25rem;
  background: rgba(255,255,255,0.03);
  border-radius: 0.5rem;
  padding: 0.25rem;
  border: 1px solid rgba(255,255,255,0.06);
}
.rp-quarter-tab {
  flex: 1;
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--slate-500, #64748b);
  background: transparent;
  border: none;
  border-radius: 0.375rem;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
}
.rp-quarter-tab:hover { color: var(--slate-300, #cbd5e1); }
.rp-quarter-tab.is-active {
  background: rgba(59,130,246,0.12);
  color: #60a5fa;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.rp-cohort-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 0.875rem;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 0.5rem;
  text-decoration: none;
  transition: all 0.15s;
}
.rp-cohort-card:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(59,130,246,0.2);
  transform: translateY(-1px);
}
.rp-cohort-name {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--slate-300, #cbd5e1);
}
.rp-cohort-card:hover .rp-cohort-name { color: #fff; }
.rp-cohort-card:hover svg { color: rgba(59,130,246,0.7) !important; }

[data-theme="light"] .rp-quarter-tabs {
  background: rgba(0,0,0,0.02);
  border-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .rp-quarter-tab { color: #94a3b8; }
[data-theme="light"] .rp-quarter-tab:hover { color: #475569; }
[data-theme="light"] .rp-quarter-tab.is-active {
  background: rgba(59,130,246,0.1);
  color: #2563eb;
}
[data-theme="light"] .rp-cohort-card {
  background: rgba(0,0,0,0.02);
  border-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .rp-cohort-card:hover {
  background: rgba(0,0,0,0.04);
  border-color: rgba(59,130,246,0.25);
}
[data-theme="light"] .rp-cohort-name { color: #334155; }
[data-theme="light"] .rp-cohort-card:hover .rp-cohort-name { color: #0f172a; }

.rp-section {
  margin-bottom: 1.25rem;
}
.rp-section-heading {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(148,163,184,0.6);
  margin-bottom: 0.75rem;
}
.rp-breakdown-panel {
  padding: 1rem 1.125rem;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 0.625rem;
}
.rp-breakdown-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
.rp-breakdown-link {
  display: block;
  padding: 0.3125rem 0.5rem;
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  border-radius: 0.25rem;
  transition: background 0.12s, color 0.12s;
}
.rp-breakdown-link:hover {
  background: rgba(255,255,255,0.04);
  color: #fff;
}
[data-theme="light"] .rp-breakdown-panel {
  background: rgba(0,0,0,0.015);
  border-color: rgba(0,0,0,0.07);
}
[data-theme="light"] .rp-section-heading {
  color: rgba(71,85,105,0.7);
}
[data-theme="light"] .rp-breakdown-link {
  color: #475569;
}
[data-theme="light"] .rp-breakdown-link:hover {
  background: rgba(0,0,0,0.04);
  color: #0f172a;
}

.rp-type-tabs {
  display: flex;
  gap: 0;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 0.5rem;
  padding: 3px;
  width: fit-content;
}
.rp-period-btn {
  display: block;
  width: 100%;
  padding: 5px 10px;
  font-size: 0.8125rem;
  color: rgba(148,163,184,0.7);
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 4px;
  text-align: left;
  transition: background 0.12s, color 0.12s;
}
.rp-period-btn:hover:not(.is-disabled) {
  background: rgba(255,255,255,0.04);
  color: #e2e8f0;
}
.rp-period-btn.is-active {
  background: rgba(59,130,246,0.12);
  color: #60a5fa;
  font-weight: 500;
}
.rp-period-btn.is-disabled {
  color: rgba(148,163,184,0.4);
  cursor: default;
}
[data-theme="light"] .rp-type-tabs {
  background: rgba(0,0,0,0.02);
  border-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .rp-period-btn { color: #94a3b8; }
[data-theme="light"] .rp-period-btn:hover:not(.is-disabled) { background: rgba(0,0,0,0.04); color: #334155; }
[data-theme="light"] .rp-period-btn.is-active { background: rgba(59,130,246,0.1); color: #2563eb; }
[data-theme="light"] .rp-period-btn.is-disabled { color: rgba(148,163,184,0.35); }

/* ── Research Page Navigator ── */
.research-nav-page {
  display: flex;
  gap: 0;
  min-height: 480px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 1rem;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(255,255,255,0.025) 0%, rgba(59,130,246,0.015) 100%);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px -8px rgba(0,0,0,0.3), 0 0 0 1px rgba(255,255,255,0.03) inset;
}
.research-nav-sidebar {
  width: 240px;
  min-width: 240px;
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 1.25rem 0;
  display: flex;
  flex-direction: column;
  background: rgba(0,0,0,0.12);
}
.research-nav-tab {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  width: 100%;
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--slate-400, #94a3b8);
  background: none;
  border: none;
  border-left: 3px solid transparent;
  cursor: pointer;
  text-align: left;
  transition: color 0.15s, background 0.15s, border-left-color 0.15s;
}
.research-nav-tab:hover {
  color: #fff;
  background: rgba(255,255,255,0.03);
}
.research-nav-tab.is-active {
  color: #fff;
  background: rgba(59,130,246,0.06);
  border-left-color: rgba(59,130,246,0.5);
}
.research-nav-ref {
  display: block;
  padding: 0.375rem 1.25rem;
  font-size: 0.8125rem;
  color: var(--slate-500, #64748b);
  text-decoration: none;
  transition: color 0.15s;
}
.research-nav-ref:hover { color: var(--slate-300, #cbd5e1); }

.research-nav-content {
  flex: 1;
  min-width: 0;
  padding: 2rem 2.5rem;
}
.research-nav-panel {
  display: none;
}
.research-nav-panel.is-active {
  display: block;
}
.research-panel-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.research-uk-grid {
  display: flex;
  gap: 0;
}
.research-uk-years {
  min-width: 100px;
  padding-right: 1.25rem;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.research-year-btn {
  display: block;
  width: 100%;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--slate-400, #94a3b8);
  background: none;
  border: none;
  border-left: 2px solid transparent;
  cursor: pointer;
  text-align: left;
  transition: color 0.15s, background 0.15s, border-left-color 0.15s;
}
.research-year-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.03);
}
.research-year-btn.is-active {
  color: #fff;
  background: rgba(59,130,246,0.06);
  border-left-color: rgba(59,130,246,0.5);
}

.research-uk-months {
  min-width: 120px;
  padding: 0 1.25rem;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.research-month-group {
  display: none;
}
.research-month-group.is-active {
  display: block;
}
.research-month-btn {
  display: block;
  width: 100%;
  padding: 0.3125rem 0.5rem;
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  background: none;
  border: none;
  border-left: 2px solid transparent;
  cursor: pointer;
  text-align: left;
  transition: color 0.15s, background 0.15s, border-left-color 0.15s;
}
.research-month-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.03);
}
.research-month-btn.is-active {
  color: #fff;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}

.research-uk-detail {
  flex: 1;
  padding-left: 1.5rem;
  min-width: 0;
}

.research-cohort-link {
  display: block;
  padding: 0.25rem 0;
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  transition: color 0.15s;
}
.research-cohort-link:hover { color: #fff; }
.research-cohort-link--disabled {
  color: var(--slate-600, #475569) !important;
  cursor: default;
}
.research-cohort-link--disabled:hover { color: var(--slate-600, #475569) !important; }

.research-lender-grid {
  display: flex;
  gap: 1.5rem;
}
.research-lender-letters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  align-content: flex-start;
  min-width: 180px;
  max-width: 180px;
}
.research-az-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--slate-400, #94a3b8);
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 0.5rem;
  cursor: pointer;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}
.research-az-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.1);
}
.research-az-btn.is-active {
  color: #fff;
  background: rgba(59,130,246,0.12);
  border-color: rgba(59,130,246,0.3);
}
.research-lender-list {
  flex: 1;
  min-width: 0;
}

@media (max-width: 768px) {
  .research-nav-page {
    flex-direction: column;
  }
  .research-nav-sidebar {
    width: 100%;
    min-width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding: 0.75rem;
    gap: 0.25rem;
  }
  .research-nav-tab {
    padding: 0.5rem 0.75rem;
    border-left: none;
    border-bottom: 2px solid transparent;
    font-size: 0.8125rem;
  }
  .research-nav-tab.is-active {
    border-bottom-color: rgba(59,130,246,0.5);
    border-left-color: transparent;
  }
  .research-nav-sidebar .mt-6 { display: none; }
  .research-nav-content {
    padding: 1.5rem;
  }
  .research-uk-grid {
    flex-direction: column;
    gap: 1rem;
  }
  .research-uk-years {
    border-right: none;
    padding-right: 0;
    display: flex;
    gap: 0.5rem;
    min-width: auto;
  }
  .research-uk-months {
    border-right: none;
    padding: 0;
  }
  .research-month-group.is-active {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
  }
  .research-uk-detail {
    padding-left: 0;
  }
  .research-lender-grid {
    flex-direction: column;
  }
  .research-lender-letters {
    min-width: auto;
    max-width: none;
  }
}

[data-theme="light"] .research-nav-page {
  border-color: rgba(0,0,0,0.08);
  background: linear-gradient(135deg, rgba(255,255,255,0.9) 0%, rgba(241,245,249,0.95) 100%);
  box-shadow: 0 8px 32px -8px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.06);
}
[data-theme="light"] .research-nav-sidebar { border-right-color: rgba(0,0,0,0.06); background: rgba(0,0,0,0.02); }
[data-theme="light"] .research-nav-tab { color: #475569; }
[data-theme="light"] .research-nav-tab:hover { color: #0f172a; background: rgba(0,0,0,0.02); }
[data-theme="light"] .research-nav-tab.is-active {
  color: #0f172a;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}
[data-theme="light"] .research-nav-ref { color: #94a3b8; }
[data-theme="light"] .research-nav-ref:hover { color: #475569; }
[data-theme="light"] .research-panel-header { border-bottom-color: rgba(0,0,0,0.06); }
[data-theme="light"] .research-uk-years { border-right-color: rgba(0,0,0,0.06); }
[data-theme="light"] .research-uk-months { border-right-color: rgba(0,0,0,0.06); }
[data-theme="light"] .research-year-btn { color: #475569; }
[data-theme="light"] .research-year-btn:hover { color: #0f172a; }
[data-theme="light"] .research-year-btn.is-active { color: #0f172a; background: rgba(59,130,246,0.04); border-left-color: rgba(59,130,246,0.4); }
[data-theme="light"] .research-month-btn { color: #475569; }
[data-theme="light"] .research-month-btn:hover { color: #0f172a; }
[data-theme="light"] .research-month-btn.is-active { color: #0f172a; background: rgba(59,130,246,0.04); border-left-color: rgba(59,130,246,0.4); }
[data-theme="light"] .research-cohort-link { color: #475569; }
[data-theme="light"] .research-cohort-link:hover { color: #0f172a; }
[data-theme="light"] .research-cohort-link--disabled { color: #94a3b8 !important; }
[data-theme="light"] .research-az-btn { color: #475569; background: rgba(0,0,0,0.03); border-color: rgba(0,0,0,0.08); }
[data-theme="light"] .research-az-btn:hover { color: #0f172a; background: rgba(0,0,0,0.05); }
[data-theme="light"] .research-az-btn.is-active { color: #0f172a; background: rgba(59,130,246,0.08); border-color: rgba(59,130,246,0.2); }

.mega-uk-cascade {
  display: flex;
  height: 100%;
  gap: 0;
}
.mega-uk-months {
  min-width: 130px;
  border-right: 1px solid rgba(255,255,255,0.06);
  overflow-y: auto;
}
.mega-month-list {
  display: none;
  flex-direction: column;
  padding: 0.375rem 0;
}
.mega-month-list.is-active {
  display: flex;
}
.mega-month-item {
  display: flex;
  align-items: center;
  padding: 0.3125rem 0.75rem;
  font-size: 0.8125rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
  transition: color 0.15s, background 0.15s;
  border-left: 2px solid transparent;
  white-space: nowrap;
}
.mega-month-item:hover {
  color: #fff;
  background: rgba(255,255,255,0.03);
}
.mega-month-item.is-active {
  color: #fff;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}
.mega-month-item.is-disabled {
  color: rgba(148,163,184,0.4);
  cursor: default;
  pointer-events: none;
}
[data-theme="light"] .mega-month-item.is-disabled {
  color: #cbd5e1;
}
.mega-uk-placeholder {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.mega-uk-detail {
  flex: 1;
  padding-left: 1.25rem;
  min-width: 0;
}
.mega-uk-detail .mega-panel-date {
  margin-bottom: 0.75rem;
}
.mega-uk-detail .mega-panel-cols {
  gap: 1.25rem;
}

[data-theme="light"] .mega-uk-months {
  border-right-color: rgba(0,0,0,0.06);
}
[data-theme="light"] .mega-month-item { color: #475569; }
[data-theme="light"] .mega-month-item:hover { color: #0f172a; background: rgba(0,0,0,0.02); }
[data-theme="light"] .mega-month-item.is-active {
  color: #0f172a;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}

.mobile-research-toggle {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 0.75rem 0;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}
.mobile-research-toggle.is-open svg { transform: rotate(180deg); }
.mobile-research-content { padding-left: 1rem; }
.mobile-research-link {
  display: block;
  padding: 0.5rem 0;
  font-size: 0.9375rem;
  color: var(--slate-400, #94a3b8);
  text-decoration: none;
}
.mobile-research-link:hover { color: #fff; }

[data-theme="light"] .mega-inner {
  background: #fff;
  border-color: rgba(0,0,0,0.08);
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.15);
}
[data-theme="light"] .mega-left { border-right-color: rgba(0,0,0,0.06); }
[data-theme="light"] .mega-left-item { color: #475569; }
[data-theme="light"] .mega-left-item:hover,
[data-theme="light"] .mega-left-item.is-active {
  color: #0f172a;
  background: rgba(59,130,246,0.04);
  border-left-color: rgba(59,130,246,0.4);
}
[data-theme="light"] .mega-type-item { color: #64748b; }
[data-theme="light"] .mega-type-item:hover { color: #334155; background: rgba(0,0,0,0.02); }
[data-theme="light"] .mega-type-item.is-active {
  color: #2563eb;
  background: rgba(59,130,246,0.06);
  border-left-color: rgba(59,130,246,0.5);
}
[data-theme="light"] .mega-year-item { color: #475569; }
[data-theme="light"] .mega-year-item:hover,
[data-theme="light"] .mega-year-item.is-active {
  color: #0f172a;
  background: rgba(59,130,246,0.03);
  border-left-color: rgba(59,130,246,0.3);
}
[data-theme="light"] .mega-col-heading { color: #1e293b; }
[data-theme="light"] .mega-col-heading--disabled { color: #94a3b8; }
[data-theme="light"] .mega-col-list a { color: #475569; }
[data-theme="light"] .mega-col-list a:hover { color: #0f172a; }
[data-theme="light"] .mega-col-list--disabled span { color: #94a3b8; }
[data-theme="light"] .mega-letter-heading { color: #1e293b; border-bottom-color: rgba(0,0,0,0.06); }
[data-theme="light"] .mega-lender-az-bar { border-bottom-color: rgba(0,0,0,0.06); }
[data-theme="light"] .mega-az-btn { color: #475569; }
[data-theme="light"] .mega-az-btn:hover { color: #0f172a; background: rgba(0,0,0,0.04); }
[data-theme="light"] .mega-az-btn.is-active {
  color: #0f172a;
  background: rgba(59,130,246,0.08);
}
[data-theme="light"] .mega-lender-link { color: #475569; }
[data-theme="light"] .mega-lender-link:hover { color: #0f172a; }
[data-theme="light"] .mega-panel-date { color: rgba(180,100,20,0.8); }

/* Back to top button */
.back-to-top {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease, background 0.2s ease, color 0.2s ease;
  z-index: 50;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.back-to-top:hover {
  background: rgba(255,255,255,0.1);
  color: #e2e8f0;
  border-color: rgba(255,255,255,0.18);
}
.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
[data-theme="light"] .back-to-top {
  background: rgba(0,0,0,0.05);
  border-color: rgba(0,0,0,0.1);
  color: #64748b;
}
[data-theme="light"] .back-to-top:hover {
  background: rgba(0,0,0,0.09);
  color: #1e293b;
}

/* Mega dropdown: desktop only */
@media (max-width: 767px) {
  .mega-menu-wrapper { pointer-events: none; }
  .mega-dropdown { display: none !important; }
}

/* Tables: force natural min-width on mobile so overflow-x scroll works */
@media (max-width: 767px) {
  .overflow-x-auto table {
    min-width: max-content;
    width: auto;
  }
}
