/* ==========================================================================
   RateProof — Minimalist Institutional Design System
   Linear / Vercel / Ramp / Stripe Precision Engineering Standard
   Pure monochrome obsidian palette, razor-thin borders, zero emojis.
   ========================================================================== */

:root {
  --bg: #000000;
  --bg-subtle: #08080a;
  --surface: #0c0c0e;
  --surface-raised: #121215;
  --surface-hover: #17171c;
  --surface-active: #1c1c22;
  
  --border: rgba(255, 255, 255, 0.08);
  --border-subtle: rgba(255, 255, 255, 0.04);
  --border-strong: rgba(255, 255, 255, 0.18);
  --border-focus: #ffffff;
  
  --text-primary: #f4f4f5;
  --text-secondary: #a1a1aa;
  --text-tertiary: #71717a;
  --text-dim: #52525b;
  
  --accent: #ffffff;
  --accent-inverse: #000000;
  --accent-blue: #38bdf8;
  --accent-blue-surface: rgba(56, 189, 248, 0.08);
  --accent-blue-border: rgba(56, 189, 248, 0.22);
  --cyan: #38bdf8;
  
  --emerald: #34d399;
  --emerald-surface: rgba(52, 211, 153, 0.08);
  --emerald-border: rgba(52, 211, 153, 0.22);
  
  --rose: #fb7185;
  --rose-surface: rgba(251, 113, 133, 0.08);
  --rose-border: rgba(251, 113, 133, 0.22);
  
  --amber: #fbbf24;
  --amber-surface: rgba(251, 191, 36, 0.08);
  --amber-border: rgba(251, 191, 36, 0.22);
  
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius: 8px;
  --radius-lg: 12px;
  
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Inter", sans-serif;
  --font-mono: "SF Mono", "Fira Code", Menlo, Monaco, Consolas, monospace;
}

[data-theme="light"] {
  --bg: #ffffff;
  --bg-subtle: #f8fafc;
  --surface: #ffffff;
  --surface-raised: #f1f5f9;
  --surface-hover: #e2e8f0;
  --surface-active: #cbd5e1;
  
  --border: rgba(0, 0, 0, 0.08);
  --border-subtle: rgba(0, 0, 0, 0.04);
  --border-strong: rgba(0, 0, 0, 0.2);
  --border-focus: #000000;
  
  --text-primary: #09090b;
  --text-secondary: #52525b;
  --text-tertiary: #71717a;
  --text-dim: #a1a1aa;
  
  --accent: #000000;
  --accent-inverse: #ffffff;
  --accent-blue: #0284c7;
  --accent-blue-surface: rgba(2, 132, 199, 0.06);
  --accent-blue-border: rgba(2, 132, 199, 0.2);
  --cyan: #0284c7;
  
  --emerald: #059669;
  --emerald-surface: rgba(5, 150, 105, 0.06);
  --emerald-border: rgba(5, 150, 105, 0.2);
  
  --rose: #e11d48;
  --rose-surface: rgba(225, 29, 72, 0.06);
  --rose-border: rgba(225, 29, 72, 0.2);
  
  --amber: #d97706;
  --amber-surface: rgba(217, 119, 6, 0.06);
  --amber-border: rgba(217, 119, 6, 0.2);
}

/* Reset & Global Setup */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
  background: var(--bg);
  overflow-x: hidden;
  max-width: 100vw;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-variant-numeric: tabular-nums;
  min-height: 100vh;
  letter-spacing: -0.011em;
  overflow-x: hidden;
  max-width: 100vw;
}

/* Scroll progress indicator */
#scrollProgress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  background: #ffffff;
  width: 0;
  z-index: 1000;
  transition: width 0.05s ease-out;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  line-height: 1.2;
}

h1 { font-size: 42px; font-weight: 600; letter-spacing: -0.04em; }
h2 { font-size: 24px; }
h3 { font-size: 16px; font-weight: 600; }
h4 { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); }

p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
}

a {
  color: var(--text-primary);
  text-decoration: none;
  transition: opacity 0.15s ease;
}

a:hover {
  opacity: 0.8;
}

/* Layout container */
.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px 64px;
}

/* Topbar Header */
.topbar {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

[data-theme="light"] .topbar {
  background: rgba(255, 255, 255, 0.85);
}

.topbar-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

[data-theme="light"] .logo {
  color: #0f172a;
}

.logo-mark {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: #0ea5e9;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  line-height: 1;
  font-family: var(--font-sans);
}

.logo-accent {
  color: #38bdf8;
}

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

.mobile-menu-btn {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
  border-radius: 6px;
  padding: 6px 10px;
  cursor: pointer;
  line-height: 1;
}

.mobile-menu-btn:hover {
  background: var(--surface-raised);
}

.nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

#appNav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav a {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color 0.15s ease;
}

.nav a:hover {
  color: var(--text-primary);
}

.topbar .nav .btn {
  border-radius: 9999px;
  font-size: 12.5px;
  padding: 6px 16px;
}

.topbar #launchBtn {
  background: #0ea5e9;
  color: #ffffff;
  border-color: #0ea5e9;
  font-weight: 600;
}

.topbar #launchBtn:hover {
  background: #0284c7;
  border-color: #0284c7;
}

@media (max-width: 980px) {
  .mobile-menu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .topbar-inner {
    position: relative;
  }
  .nav#landingNav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #0b0f17;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6);
    flex-direction: column;
    align-items: stretch;
    padding: 16px 24px;
    gap: 12px;
    z-index: 100;
  }
  [data-theme="light"] .nav#landingNav {
    background: #ffffff;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.12);
  }
  .nav#landingNav.mobile-open {
    display: flex;
  }
  .nav#landingNav a {
    padding: 8px 0;
    font-size: 14px;
    border-bottom: 1px solid var(--border-subtle);
  }
  .nav#landingNav .btn {
    width: 100%;
    text-align: center;
    margin-top: 4px;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--radius-sm);
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s ease;
  line-height: 1.3;
  user-select: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-inverse);
  border-color: var(--accent);
}

.btn-primary:hover {
  opacity: 0.92;
  transform: translateY(-0.5px);
}

.btn-outline {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
}

.btn-outline:hover {
  background: var(--surface-raised);
  border-color: var(--border-strong);
}

.btn-small {
  padding: 5px 10px;
  font-size: 12px;
  border-radius: var(--radius-xs);
}

.btn-danger {
  background: var(--rose-surface);
  color: var(--rose);
  border-color: var(--rose-border);
}

.btn-danger:hover {
  background: rgba(251, 113, 133, 0.15);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 500;
  border-radius: var(--radius-xs);
  line-height: 1.4;
  letter-spacing: 0.02em;
}

.badge-ok {
  background: var(--emerald-surface);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
}

.badge-flag {
  background: var(--rose-surface);
  color: var(--rose);
  border: 1px solid var(--rose-border);
}

.badge-warn {
  background: var(--amber-surface);
  color: var(--amber);
  border: 1px solid var(--amber-border);
}

.badge-grey {
  background: var(--surface-raised);
  color: var(--text-tertiary);
  border: 1px solid var(--border);
}

/* Cards & Grid Surfaces */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: border-color 0.15s ease;
}

.card.hoverable:hover {
  border-color: var(--border-strong);
}

.grid2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* Centered Hero Section (Image 2 Standard) */
.hero-centered {
  padding: 80px 24px 44px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle 800px at 50% 10%, rgba(14, 165, 233, 0.09) 0%, transparent 70%);
  border-bottom: 1px solid var(--border);
}

.hero-inner-centered {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(14, 165, 233, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.32);
  color: #38bdf8;
  border-radius: 9999px;
  padding: 6px 18px;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 24px;
}

.hero-title {
  font-size: 56px;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.035em;
  color: #ffffff;
  margin: 0 0 18px;
}

.hero-cyan {
  color: #38bdf8;
}

.hero-subtext {
  font-size: 16px;
  line-height: 1.6;
  color: #94a3b8;
  max-width: 720px;
  margin: 0 auto 32px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.btn-hero-primary {
  background: #0284c7;
  border: 1px solid #0284c7;
  color: #ffffff;
  border-radius: 9999px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-hero-primary:hover {
  background: #0369a1;
  border-color: #0369a1;
}

.btn-hero-outline {
  background: #090b10;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #f4f4f5;
  border-radius: 9999px;
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-hero-outline:hover {
  background: #141822;
  border-color: rgba(255, 255, 255, 0.3);
}

/* Interactive Freight Audit Engine Card (Image 2) */
.audit-calc-card {
  background: #080a0f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 32px;
  margin: 36px auto 56px;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.6);
}

.audit-calc-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.audit-calc-title {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin: 0 0 6px 0;
}

.audit-calc-subtitle {
  font-size: 13.5px;
  color: #94a3b8;
  margin: 0;
}

.audit-calc-card label {
  display: block;
  font-size: 12px;
  color: #94a3b8;
  margin-bottom: 6px;
  font-weight: 500;
}

.audit-calc-card input {
  background: #111520;
  border: 1px solid #232936;
  border-radius: 6px;
  padding: 10px 14px;
  font-size: 14px;
  color: #f4f4f5;
  font-family: var(--font-mono);
  transition: border-color 0.15s ease;
}

.audit-calc-card input:focus {
  border-color: #38bdf8;
}

[data-theme="light"] .hero-title { color: #0f172a; }
[data-theme="light"] .hero-cyan { color: #0284c7; }
[data-theme="light"] .hero-subtext { color: #475569; }
[data-theme="light"] .hero-pill { background: rgba(2, 132, 199, 0.1); border-color: rgba(2, 132, 199, 0.3); color: #0284c7; }
[data-theme="light"] .btn-hero-outline { background: #f8fafc; border-color: #cbd5e1; color: #0f172a; }
[data-theme="light"] .audit-calc-card { background: #ffffff; border-color: rgba(0, 0, 0, 0.08); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06); }
[data-theme="light"] .audit-calc-title { color: #0f172a; }
[data-theme="light"] .audit-calc-subtitle { color: #64748b; }
[data-theme="light"] .audit-calc-card label { color: #475569; }
[data-theme="light"] .audit-calc-card input { background: #f8fafc; border-color: #cbd5e1; color: #0f172a; }

/* Legacy Hero Compatibility */
.hero {
  padding: 80px 0 64px;
  border-bottom: 1px solid var(--border);
  background: radial-gradient(circle 700px at 50% 0px, rgba(255, 255, 255, 0.03), transparent);
}

.hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  margin-bottom: 20px;
}

.pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
}

.hero p {
  font-size: 16px;
  color: var(--text-secondary);
  margin: 16px 0 28px;
  max-width: 540px;
}

/* Hero Interactive 3D Cards */
.scene3d {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.scene3d-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
  transform-style: preserve-3d;
  transition: transform 0.2s ease-out;
}

.float-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  transition: border-color 0.15s ease;
}

.float-card:hover {
  border-color: var(--border-strong);
}

.float-card .label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  font-weight: 500;
  margin-bottom: 6px;
}

.float-card .big {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.float-card .sub {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.flag-amt { color: var(--rose) !important; }
.ok-amt { color: var(--emerald) !important; }

/* Sections */
.section {
  margin: 56px 0;
}

.section h2 {
  margin-bottom: 8px;
}

.section .lead {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 24px;
  max-width: 640px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.step-num {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--text-tertiary);
  margin-bottom: 10px;
}

/* Calculator */
.calc-result {
  margin-top: 16px;
  padding: 16px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13.5px;
}

.calc-result strong {
  color: var(--rose);
  font-size: 15px;
}

/* Pricing Grid */
.price-toggle {
  display: inline-flex;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 2px;
  gap: 2px;
}

.price-toggle button {
  border: 0;
  background: transparent;
  color: var(--text-secondary);
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 500;
  border-radius: var(--radius-xs);
  cursor: pointer;
  transition: all 0.15s ease;
}

.price-toggle button.active {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

/* FAQ Details */
.faq details {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  background: var(--surface);
  margin-bottom: 10px;
}

.faq summary {
  cursor: pointer;
  font-weight: 500;
  font-size: 14px;
  color: var(--text-primary);
  outline: none;
}

.faq p {
  margin-top: 10px;
  font-size: 13.5px;
}

/* Forms & Inputs */
form label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  margin: 12px 0 5px;
  font-weight: 500;
}

input, select, textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-raised);
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s ease;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--border-focus);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-row3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.search {
  max-width: 320px;
}

/* Tables */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

th {
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  font-weight: 500;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-raised);
}

td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
  vertical-align: middle;
}

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

tr:hover td {
  background: var(--surface-hover);
}

/* App View Layout */
#appView .wrap {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  column-gap: 24px;
  padding-top: 24px;
}

.app-header {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 16px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.tabs {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px;
  position: sticky;
  top: 72px;
}

.tab {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: transparent;
  color: var(--text-secondary);
  padding: 10px 14px;
  border-radius: var(--radius-xs);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
  width: 100%;
}

.tab svg {
  width: 16px;
  height: 16px;
  min-width: 16px;
  min-height: 16px;
  max-width: 16px;
  max-height: 16px;
  stroke-width: 1.8;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
}

.tab:hover {
  color: var(--text-primary);
  background: var(--surface-raised);
}

.tab.active {
  color: var(--text-primary);
  background: var(--surface-hover);
  border: 1px solid var(--border);
}

/* KPI Cards */
.kpi {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.kpi .card {
  padding: 16px;
}

.kpi b {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.03em;
  display: block;
  margin-bottom: 4px;
}

.kpi span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
}

.mini-kpi {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
}

.mini-kpi b {
  font-size: 20px;
  font-weight: 600;
  display: block;
  margin-top: 4px;
}

/* Status Cards & Notices */
.empty {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 36px 20px;
  text-align: center;
  color: var(--text-secondary);
}

.empty b {
  color: var(--text-primary);
  display: block;
  margin-bottom: 6px;
  font-size: 15px;
}

.dispute {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin: 12px 0;
}

.mono {
  font-family: var(--font-mono);
  font-size: 12px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  white-space: pre-wrap;
  word-break: break-word;
}

.progress {
  height: 4px;
  background: var(--surface-raised);
  border-radius: 999px;
  overflow: hidden;
  margin: 10px 0;
}

.progress i {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s ease;
}

.chip {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  border-radius: var(--radius-xs);
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip:hover {
  color: var(--text-primary);
  background: var(--surface-raised);
}

.chip.active {
  color: var(--text-primary);
  background: var(--surface-raised);
  border-color: var(--border-strong);
}

/* Toast Notifications */
#toasts {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 360px;
}

.toast {
  background: var(--surface-raised);
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.toast.error {
  border-color: var(--rose-border);
}

/* Command Palette Modal */
.link-btn {
  background: transparent;
  border: none;
  padding: 0;
  color: var(--text-secondary);
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition-fast);
}

.link-btn:hover {
  color: var(--text-primary);
}

.cmd-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 500;
  display: flex;
  justify-content: center;
  padding-top: 14vh;
}

.cmd-box {
  background: #0d1017;
  color: #f4f4f5;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius);
  width: min(540px, 92vw);
  max-height: 85vh;
  overflow-y: auto;
  padding: 18px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.85);
}

#checkoutModalBox {
  background: #0a0d14 !important;
  color: #f4f4f5 !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  border-radius: 12px !important;
}

.cmd-item {
  padding: 9px 12px;
  border-radius: var(--radius-xs);
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.1s ease;
}

.cmd-item:hover, .cmd-item.active {
  color: var(--text-primary);
  background: var(--surface-raised);
}

.cmd-hint {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 2px 5px;
  border-radius: 3px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  color: var(--text-tertiary);
}

/* Usage Meter & Quota Progress */
.usage-meter {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: var(--radius-xs);
  font-size: 12px;
}

.usage-bar-track {
  width: 90px;
  height: 6px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.usage-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s ease;
}

.usage-bar-fill.warning {
  background: #f59e0b;
}

.usage-bar-fill.danger {
  background: var(--rose);
}

/* Dispute Lifecycle Badges */
.badge-disputed {
  background: rgba(245, 158, 11, 0.12);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge-recovered {
  background: var(--emerald-dim);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
}

/* Carrier Leakage Scorecard */
.scorecard-rank {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-tertiary);
  width: 24px;
  display: inline-block;
}

.leakage-pill {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 11px;
  font-family: var(--font-mono);
  font-weight: 500;
  background: var(--rose-dim);
  color: var(--rose);
  border: 1px solid var(--rose-border);
}

/* Carrier Scorecard Intelligence Badges */
.grade-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: var(--radius-xs);
  letter-spacing: -0.02em;
}

.grade-a {
  background: var(--emerald-surface);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
}

.grade-b {
  background: var(--accent-blue-surface);
  color: var(--accent-blue);
  border: 1px solid var(--accent-blue-border);
}

.grade-c {
  background: var(--amber-surface);
  color: var(--amber);
  border: 1px solid var(--amber-border);
}

.grade-d, .grade-f {
  background: var(--rose-surface);
  color: var(--rose);
  border: 1px solid var(--rose-border);
}

.connector-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.15s ease;
}

.connector-card:hover {
  border-color: var(--border-strong);
}

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

.sync-log-feed {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-secondary);
  max-height: 180px;
  overflow-y: auto;
  line-height: 1.6;
}

/* Trust & Security Callouts */
.trust-banner {
  background: var(--surface-raised);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 16px 0;
}

.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  padding: 4px 9px;
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--text-secondary);
  letter-spacing: -0.01em;
}

.trust-badge-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 6px var(--emerald-dim);
}

/* Multi-Column Enterprise Footer */
.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 13px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr 1.2fr;
  gap: 36px;
  margin-bottom: 36px;
  text-align: left;
}

.footer-col h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin: 0 0 14px 0;
  font-weight: 600;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  line-height: 2;
}

.footer-col a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s ease;
  cursor: pointer;
}

.footer-col a:hover {
  color: var(--text-primary);
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--text-tertiary);
}

/* Utilities */
.hidden { display: none !important; }
.muted { color: var(--text-secondary); }
.small { font-size: 12px; }
.text-right { text-align: right; }

@media (max-width: 900px) {
  html, body {
    overflow-x: hidden;
    max-width: 100vw;
  }
  .topbar-inner {
    padding: 10px 16px;
  }
  #appNav {
    gap: 6px;
  }
  #appNav .btn {
    padding: 4px 10px;
    font-size: 11px;
  }
  .hero-inner, .grid3, .grid2, .kpi, .form-row, .form-row3, .steps {
    grid-template-columns: 1fr;
  }
  #appView .wrap { grid-template-columns: 1fr; }
  .tabs { position: static; flex-direction: row; overflow-x: auto; max-width: 100%; margin-bottom: 16px; -webkit-overflow-scrolling: touch; }
  .usage-meter { width: 100%; justify-content: space-between; margin-top: 8px; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .before-after-grid, .security-badge-grid { grid-template-columns: 1fr; }
  .floating-roi-banner {
    bottom: 12px;
    right: 12px;
    left: 12px;
    width: auto;
    max-width: calc(100vw - 24px);
    max-height: 180px;
    overflow: hidden;
    padding: 10px 36px 10px 14px;
    gap: 10px;
    flex-wrap: wrap;
    border-radius: 12px;
  }
  .floating-roi-banner.visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .floating-roi-banner .roi-icon-container {
    display: none;
  }
  .roi-slider-group {
    min-width: 140px;
    flex: 1;
  }
  .slider-tick .tick-desc {
    display: none;
  }
  .tick-50 {
    left: 0;
  }
  .tick-300 {
    left: 14%;
    transform: translateX(-50%);
  }
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
  opacity: 0.001 !important;
}

@keyframes totalValuePulse {
  0% { transform: scale(1.03); filter: brightness(1.2); }
  100% { transform: scale(1); filter: brightness(1); }
}

.calc-value-pulse {
  animation: totalValuePulse 0.25s ease-out;
}

/* ============================================================
   1. Interactive Audit Engine Micro-Animations & Glows
   ============================================================ */
.calc-highlight-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  border-radius: var(--radius-md);
  padding: 20px 24px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.calc-highlight-box.has-variance {
  background: rgba(244, 63, 94, 0.05);
  border: 1px solid rgba(244, 63, 94, 0.32);
  box-shadow: 0 0 30px rgba(244, 63, 94, 0.12), inset 0 0 15px rgba(244, 63, 94, 0.04);
}

.calc-highlight-box.zero-variance {
  background: rgba(16, 185, 129, 0.05);
  border: 1px solid rgba(16, 185, 129, 0.32);
  box-shadow: 0 0 30px rgba(16, 185, 129, 0.12), inset 0 0 15px rgba(16, 185, 129, 0.04);
}

.calc-overcharge-number {
  font-size: 32px;
  font-weight: 800;
  font-family: var(--font-mono);
  letter-spacing: -0.03em;
  line-height: 1.1;
  transition: color 0.25s ease, text-shadow 0.25s ease;
}

.calc-overcharge-number.glow-rose {
  color: var(--rose);
  text-shadow: 0 0 18px rgba(244, 63, 94, 0.45);
}

.calc-overcharge-number.glow-emerald {
  color: var(--emerald);
  text-shadow: 0 0 18px rgba(16, 185, 129, 0.45);
}

.calc-indicator-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 4px;
}

.calc-indicator-pill.pill-rose {
  background: rgba(244, 63, 94, 0.12);
  color: var(--rose);
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.calc-indicator-pill.pill-emerald {
  background: rgba(16, 185, 129, 0.12);
  color: var(--emerald);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* ============================================================
   2. Drag-and-Drop Mock PDF Ingestion Zone
   ============================================================ */
.pdf-dropzone {
  border: 2px dashed rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-md);
  background: rgba(14, 165, 233, 0.02);
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}

.pdf-dropzone:hover, .pdf-dropzone.dragover {
  border-color: var(--cyan);
  background: rgba(14, 165, 233, 0.07);
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.15);
  transform: translateY(-1px);
}

.dropzone-file-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.001;
  cursor: pointer;
  z-index: 2;
  display: block;
  pointer-events: auto;
}

.pdf-dropzone-actions {
  position: relative;
  z-index: 10;
  pointer-events: auto;
}

.pdf-dropzone-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 10px;
  border-radius: 10px;
  background: rgba(56, 189, 248, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
}

.pdf-dropzone-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}

.pdf-dropzone-sub {
  font-size: 13px;
  color: var(--text-secondary);
}

.pdf-dropzone-badge {
  display: inline-block;
  margin-top: 8px;
  font-size: 11px;
  padding: 2px 10px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.pdf-dropzone-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}

@keyframes inputGlowFlash {
  0% {
    border-color: var(--cyan);
    box-shadow: 0 0 15px rgba(56, 189, 248, 0.5);
    background-color: rgba(56, 189, 248, 0.08);
  }
  100% {
    border-color: var(--border);
    box-shadow: none;
    background-color: transparent;
  }
}

.input-flash {
  animation: inputGlowFlash 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.dropzone-error-banner {
  transition: all 0.25s ease;
}

.calc-carrier-meta {
  transition: all 0.25s ease;
}

/* Contingency & ROI Volume Slider Ticks */
.slider-ticks-row {
  position: relative;
  height: 20px;
  margin-top: 8px;
  font-size: 10px;
  color: var(--text-tertiary);
  user-select: none;
}

.slider-tick {
  position: absolute;
  cursor: pointer;
  white-space: nowrap;
  padding: 2px 4px;
  border-radius: 4px;
  transition: color 0.15s ease, background 0.15s ease;
}

.slider-tick:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.slider-tick .tick-desc {
  display: none;
}

.tick-50 {
  left: 0;
  transform: none;
}

.tick-300 {
  left: 10.2%;
  transform: translateX(-50%);
}

.tick-1500 {
  left: 59.2%;
  transform: translateX(-50%);
}

.tick-2500 {
  right: 0;
  transform: none;
}

/* ============================================================
   3. Floating ROI / Savings Calculator Banner
   ============================================================ */
.floating-roi-banner {
  position: fixed;
  bottom: 24px;
  right: 24px;
  left: auto;
  transform: translateY(120px);
  width: auto;
  max-width: 680px;
  background: rgba(10, 13, 20, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(56, 189, 248, 0.35);
  /* Wrap so the Claim button drops to a visible second row instead of being
     clipped when the row's minimum widths exceed the 680px cap (Audit #8
     P1-3: Claim below the fold at 1919px). 240px fits two wrapped rows. */
  flex-wrap: wrap;
  max-height: 240px;
  overflow: hidden;
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 30px rgba(56, 189, 248, 0.12);
  padding: 12px 36px 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  z-index: 400;
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
  pointer-events: none;
}

.floating-roi-banner:not(.visible) {
  display: none !important;
}

.floating-roi-banner.visible {
  display: flex !important;
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* The banner must never cover the public calculator's inputs while #calc is
   on screen (Audit #8 P1-3: clicks on Detention Hourly Rate timed out under
   the banner). Toggled by an IntersectionObserver in app.js; !important so
   it wins over the inline display:flex the scroll handler sets. */
.floating-roi-banner.roi-hidden-by-calc {
  display: none !important;
}

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

.btn-spinner {
  display: inline-block;
  width: 12px;
  height: 12px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-right: 6px;
  vertical-align: middle;
}

.roi-close-btn {
  position: absolute;
  top: 8px;
  right: 12px;
  background: transparent;
  border: none;
  color: var(--text-tertiary);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color 0.15s ease;
  z-index: 10;
}

.roi-close-btn:hover {
  color: var(--text-primary);
}

[data-theme="light"] .roi-close-btn {
  color: #64748b;
}

[data-theme="light"] .roi-close-btn:hover {
  color: #0f172a;
}

.roi-slider-group {
  flex: 1;
  min-width: 220px;
}

.roi-slider-labels {
  display: flex;
  justify-content: space-between;
  /* The two labels must wrap as whole units: without wrap the estimate note
     runs onto the same line as a wrapped load count at 600px
     ("1,500Estimate based on $88/load…") — Audit #8 P2-1. */
  flex-wrap: wrap;
  gap: 2px 12px;
  font-size: 11px;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.roi-slider-labels span:first-child {
  white-space: nowrap;
}

.roi-slider {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: var(--surface-raised);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  accent-color: var(--cyan);
  cursor: pointer;
  touch-action: pan-x;
}

.roi-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--cyan);
  cursor: pointer;
  border: 2px solid #ffffff;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
}

.roi-slider::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--cyan);
  cursor: pointer;
  border: 2px solid #ffffff;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
}

.roi-metric-display {
  text-align: right;
  min-width: 180px;
  /* Keep the right-aligned header clear of the absolute Dismiss × in the
     banner's top-right corner (Audit #8 P1-3: × printed over "LEAKAGE"). */
  padding-right: 30px;
}

.roi-metric-value {
  font-size: 22px;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--emerald);
  letter-spacing: -0.02em;
  line-height: 1;
  text-shadow: 0 0 12px rgba(16, 185, 129, 0.35);
}

/* ============================================================
   4. Enterprise Trust & Security Badge Grid Refinement
   ============================================================ */
.security-badge-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 24px;
}

.security-badge-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.security-badge-card:hover {
  border-color: rgba(56, 189, 248, 0.4);
  transform: translateY(-2px);
}

.security-badge-card-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: rgba(56, 189, 248, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  margin-bottom: 12px;
}

.security-badge-card h4 {
  margin: 0 0 6px 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.security-badge-card p {
  margin: 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-secondary);
}

/* ============================================================
   5. Visual "Before & After" Dispute Comparison Card
   ============================================================ */
.before-after-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 24px;
}

.before-card {
  background: #0d1017;
  border: 1px solid rgba(244, 63, 94, 0.3);
  border-radius: var(--radius-md);
  padding: 24px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.before-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.35);
  color: var(--rose);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
}

.after-card {
  background: #091319;
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-md);
  padding: 24px;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 25px rgba(16, 185, 129, 0.08);
}

.after-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: var(--emerald);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 16px;
}

.bill-paper-preview {
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 6px;
  padding: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
}

.bill-row-danger {
  background: rgba(244, 63, 94, 0.15);
  border-left: 3px solid var(--rose);
  padding: 3px 8px;
  margin: 6px 0;
  color: #ffccd5;
}

.bill-row-clean {
  background: rgba(16, 185, 129, 0.1);
  border-left: 3px solid var(--emerald);
  padding: 3px 8px;
  margin: 6px 0;
  color: #bbf7d0;
}

/* ============================================================
   Feature Icons & Interactive Visual Primitives
   ============================================================ */
.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: rgba(56, 189, 248, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  margin-bottom: 16px;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
  stroke: var(--cyan);
}

.roi-icon-container {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(56, 189, 248, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan);
  flex-shrink: 0;
}

/* ============================================================
   Comprehensive Light Theme Overrides
   ============================================================ */
[data-theme="light"] .feature-icon {
  background: rgba(2, 132, 199, 0.1);
  color: #0284c7;
}

[data-theme="light"] .feature-icon svg {
  stroke: #0284c7;
}

/* 1. Floating ROI / AP Savings Calculator Banner */
[data-theme="light"] .floating-roi-banner {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(14, 165, 233, 0.35);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.12), 0 0 25px rgba(14, 165, 233, 0.15);
}

[data-theme="light"] .floating-roi-banner .roi-icon-container {
  background: rgba(2, 132, 199, 0.1);
  color: #0284c7;
}

[data-theme="light"] .floating-roi-banner .roi-slider {
  background: #e2e8f0;
}

[data-theme="light"] .floating-roi-banner .roi-slider-labels {
  color: #64748b;
}

[data-theme="light"] .floating-roi-banner .roi-metric-value {
  color: #059669;
  text-shadow: 0 0 12px rgba(5, 150, 105, 0.2);
}

[data-theme="light"] .floating-roi-banner #roiClaimBtn {
  background: #0ea5e9;
  color: #ffffff;
  border-color: #0ea5e9;
}

[data-theme="light"] .floating-roi-banner #roiClaimBtn:hover {
  background: #0284c7;
  border-color: #0284c7;
}

/* 2. PDF Ingestion Dropzone & Extracted Metadata Badge */
[data-theme="light"] .pdf-dropzone {
  border-color: rgba(14, 165, 233, 0.35);
  background: rgba(14, 165, 233, 0.02);
}

[data-theme="light"] .pdf-dropzone:hover,
[data-theme="light"] .pdf-dropzone.dragover {
  border-color: #0284c7;
  background: rgba(14, 165, 233, 0.06);
  box-shadow: 0 0 25px rgba(14, 165, 233, 0.12);
}

[data-theme="light"] .pdf-dropzone-icon {
  background: rgba(2, 132, 199, 0.1);
  color: #0284c7;
}

[data-theme="light"] .pdf-dropzone-badge {
  background: #f1f5f9;
  border-color: #e2e8f0;
  color: #475569;
}

[data-theme="light"] .calc-carrier-meta {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.08);
}

/* 3. Interactive Engine Calculation Highlighting */
[data-theme="light"] .calc-highlight-box.has-variance {
  background: #fff1f2;
  border-color: rgba(244, 63, 94, 0.35);
  box-shadow: 0 4px 20px rgba(244, 63, 94, 0.08);
}

[data-theme="light"] .calc-highlight-box.zero-variance {
  background: #f0fdf4;
  border-color: rgba(16, 185, 129, 0.35);
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.08);
}

[data-theme="light"] .calc-overcharge-number.glow-rose {
  color: #e11d48;
  text-shadow: 0 0 14px rgba(225, 29, 72, 0.25);
}

[data-theme="light"] .calc-overcharge-number.glow-emerald {
  color: #059669;
  text-shadow: 0 0 14px rgba(5, 150, 105, 0.25);
}

/* 4. Before & After Dispute Comparison Cards */
[data-theme="light"] .before-card {
  background: #fff5f5;
  border-color: rgba(244, 63, 94, 0.3);
  box-shadow: 0 10px 30px rgba(244, 63, 94, 0.06);
}

[data-theme="light"] .after-card {
  background: #f0fdf4;
  border-color: rgba(16, 185, 129, 0.3);
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.06);
}

[data-theme="light"] .bill-paper-preview {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.12);
  color: #0f172a;
}

[data-theme="light"] .bill-row-danger {
  background: rgba(244, 63, 94, 0.1);
  color: #be123c;
}

[data-theme="light"] .bill-row-clean {
  background: rgba(16, 185, 129, 0.1);
  color: #047857;
}

/* 5. Enterprise Security Badges & Cards */
[data-theme="light"] .security-badge-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .security-badge-card-icon {
  background: rgba(2, 132, 199, 0.1);
  color: #0284c7;
}

[data-theme="light"] .card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .card.hoverable:hover {
  border-color: rgba(14, 165, 233, 0.4);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .faq details {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .price-toggle {
  background: #f1f5f9;
  border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .price-toggle button.active {
  background: #ffffff;
  color: #0f172a;
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .footer {
  background: #f8fafc;
  border-top-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .cmd-modal {
  background: rgba(15, 23, 42, 0.55);
}

[data-theme="light"] .cmd-box {
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid rgba(0, 0, 0, 0.15) !important;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.15) !important;
}

[data-theme="light"] .cmd-box h1,
[data-theme="light"] .cmd-box h2,
[data-theme="light"] .cmd-box h3,
[data-theme="light"] .cmd-box h4 {
  color: #0f172a !important;
}

[data-theme="light"] .cmd-box p,
[data-theme="light"] .cmd-box span,
[data-theme="light"] .cmd-box li {
  color: #334155;
}

[data-theme="light"] .cmd-box strong {
  color: #0f172a;
}


