@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@600;700;800&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@500&display=swap');

:root {
  --navy: #1B2A4A;
  --navy-light: #2D4A7A;
  --emerald: #10B981;
  --emerald-hover: #059669;
  --emerald-light: #D1FAE5;
  --red: #EF4444;
  --red-light: #FEE2E2;
  --bg: #FAFAFA;
  --card-bg: #F3F4F6;
  --white: #FFFFFF;
  --text: #1F2937;
  --text-muted: #6B7280;
  --text-light: #9CA3AF;
  --border: #E5E7EB;
  --shadow: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.1);
  --radius: 12px;
  --radius-sm: 8px;
  --input-h: 48px;
  --max-w: 1200px;
  --transition: 0.2s ease;
}

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  line-height: 1.2;
  color: var(--navy);
}

h1 { font-size: 2.5rem; font-weight: 800; }
h2 { font-size: 1.75rem; font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 700; }
h4 { font-size: 1.1rem; font-weight: 600; }

a { color: var(--emerald); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--emerald-hover); }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }
@media (min-width: 768px) { .container { padding: 0 48px; } }

/* ── Header ── */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.header-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; height: 64px;
}
@media (min-width: 768px) { .header-inner { padding: 0 48px; } }
.logo {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800; font-size: 1.5rem;
  color: var(--navy); text-decoration: none;
}
.logo span { color: var(--emerald); }
.nav-links { display: flex; gap: 24px; list-style: none; }
.nav-links a {
  color: var(--text); font-weight: 500; font-size: 0.95rem;
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--emerald); }
.nav-links a.active { color: var(--emerald); font-weight: 600; }
.hamburger { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.hamburger svg { width: 24px; height: 24px; stroke: var(--navy); }
@media (max-width: 767px) {
  .nav-links {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; background: var(--white);
    border-bottom: 1px solid var(--border); box-shadow: var(--shadow-md);
    padding: 16px 24px; gap: 16px;
  }
  .nav-links.open { display: flex; }
  .hamburger { display: block; }
}

/* ── Tool Ticker (below header) ── */
.tool-ticker {
  background: var(--navy);
  overflow: hidden;
  white-space: nowrap;
  padding: 10px 0;
  position: relative;
}
.tool-ticker::before,
.tool-ticker::after {
  content: '';
  position: absolute; top: 0; bottom: 0; width: 80px; z-index: 2;
  pointer-events: none;
}
.tool-ticker::before {
  left: 0;
  background: linear-gradient(90deg, var(--navy) 0%, transparent 100%);
}
.tool-ticker::after {
  right: 0;
  background: linear-gradient(-90deg, var(--navy) 0%, transparent 100%);
}
.ticker-track {
  display: inline-flex;
  animation: tickerScroll 30s linear infinite;
}
.ticker-track:hover { animation-play-state: paused; }
.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 28px;
  color: rgba(255,255,255,0.85);
  font-size: 0.85rem;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  white-space: nowrap;
  transition: color 0.2s;
}
.ticker-item:hover { color: var(--emerald); }
.ticker-item svg {
  width: 16px; height: 16px;
  flex-shrink: 0;
  opacity: 0.7;
}
.ticker-sep {
  color: rgba(255,255,255,0.2);
  padding: 0 4px;
  font-size: 0.7rem;
}

@keyframes tickerScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── Breadcrumb ── */
.breadcrumb { padding: 16px 0; font-size: 0.875rem; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--emerald); }
.breadcrumb span { margin: 0 8px; }

/* ── Trust Badge ── */
.trust-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(16,185,129,0.12); color: var(--emerald-hover);
  padding: 8px 20px; border-radius: 100px;
  font-size: 0.85rem; font-weight: 600;
  margin-bottom: 20px;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(16,185,129,0.2);
  animation: badgeFade 0.6s ease 0.2s both;
}
.trust-badge svg { width: 16px; height: 16px; }

/* ── Hero ── */
.hero {
  padding: 60px 0 48px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -40%; left: -20%; right: -20%; bottom: -40%;
  background:
    radial-gradient(ellipse 600px 400px at 20% 50%, rgba(16,185,129,0.08) 0%, transparent 70%),
    radial-gradient(ellipse 500px 350px at 80% 30%, rgba(27,42,74,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 400px 300px at 60% 80%, rgba(16,185,129,0.05) 0%, transparent 70%);
  z-index: 0;
  animation: heroGlow 8s ease-in-out infinite alternate;
}
.hero-inner {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
}
@media (min-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr 320px;
    gap: 60px;
  }
}
.hero-left { text-align: left; }
@media (max-width: 1023px) {
  .hero-left { text-align: center; }
}
.hero-left > * { position: relative; z-index: 1; }
.hero h1 {
  margin-bottom: 20px;
  font-size: clamp(2rem, 5vw, 3.2rem);
  animation: heroTitle 0.7s ease 0.1s both;
}
.hero h1 .hero-highlight {
  background: linear-gradient(135deg, var(--emerald) 0%, #059669 50%, #10B981 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
}
.hero h1 .hero-highlight::after {
  content: '';
  position: absolute; bottom: 2px; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--emerald), #059669);
  border-radius: 2px;
  animation: underlineGrow 0.8s ease 0.8s both;
}
.hero .subtitle {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--text-muted);
  max-width: 640px; margin: 0 0 28px;
  line-height: 1.7;
  animation: heroSub 0.7s ease 0.3s both;
}
@media (max-width: 1023px) {
  .hero .subtitle { margin-left: auto; margin-right: auto; }
}

/* Hero stats row */
.hero-stats {
  display: flex; gap: 32px; flex-wrap: wrap;
  margin-top: 28px;
  animation: heroStats 0.7s ease 0.6s both;
}
@media (max-width: 1023px) {
  .hero-stats { justify-content: center; }
}
@media (max-width: 480px) {
  .hero-stats { gap: 20px; }
}
.hero-stat {
  text-align: center;
}
.hero-stat .stat-value {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800; font-size: 1.75rem;
  color: var(--navy);
  line-height: 1;
}
.hero-stat .stat-value .stat-num {
  display: inline-block;
}
.hero-stat .stat-label {
  font-size: 0.8rem; color: var(--text-muted);
  margin-top: 4px; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.hero-stat .stat-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--emerald);
  display: inline-block; margin-right: 6px;
  animation: dotPulse 2s ease-in-out infinite;
}

/* Hero floating shapes */
.hero-shapes {
  position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none;
}
.hero-shape {
  position: absolute; border-radius: 50%; opacity: 0;
  animation: shapeFloat 12s ease-in-out infinite;
}
.hero-shape:nth-child(1) {
  width: 80px; height: 80px; top: 10%; left: 5%;
  background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(16,185,129,0.02));
  animation-delay: 0s; animation-duration: 14s;
}
.hero-shape:nth-child(2) {
  width: 120px; height: 120px; top: 60%; right: 8%;
  background: linear-gradient(135deg, rgba(27,42,74,0.08), rgba(27,42,74,0.02));
  animation-delay: 2s; animation-duration: 16s;
}
.hero-shape:nth-child(3) {
  width: 50px; height: 50px; top: 20%; right: 15%;
  background: linear-gradient(135deg, rgba(16,185,129,0.12), rgba(16,185,129,0.03));
  animation-delay: 4s; animation-duration: 10s;
}
.hero-shape:nth-child(4) {
  width: 60px; height: 60px; bottom: 15%; left: 12%;
  background: linear-gradient(135deg, rgba(27,42,74,0.06), rgba(27,42,74,0.01));
  animation-delay: 1s; animation-duration: 13s;
}
.hero-shape:nth-child(5) {
  width: 40px; height: 40px; top: 40%; left: 25%;
  background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(16,185,129,0.02));
  animation-delay: 3s; animation-duration: 11s;
}

/* Hero CTA row */
.hero-cta {
  display: flex; gap: 12px; flex-wrap: wrap;
  animation: heroSub 0.7s ease 0.5s both;
}
@media (max-width: 1023px) {
  .hero-cta { justify-content: center; }
}

/* ── Tool Slider ── */
.hero-right {
  overflow: hidden;
  position: relative;
}

/* Mobile: horizontal slider below hero */
@media (max-width: 1023px) {
  .hero-right {
    margin: 32px -24px 0;
    padding: 0;
    mask-image: linear-gradient(90deg, transparent 0%, black 8%, black 92%, transparent 100%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, black 8%, black 92%, transparent 100%);
  }
  .hero-slider-track {
    flex-direction: row !important;
    gap: 12px;
    padding: 0 24px;
    animation: horizontalSlide 22s linear infinite;
    width: max-content;
  }
  .hero-slide {
    min-width: 220px;
    padding: 14px 16px;
  }
  .hero-slide:hover {
    transform: translateY(-3px);
  }
}

/* Desktop: vertical slider on right side */
@media (min-width: 1024px) {
  .hero-right {
    height: 420px;
    mask-image: linear-gradient(180deg, transparent 0%, black 10%, black 90%, transparent 100%);
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, black 10%, black 90%, transparent 100%);
  }
  .hero-slider-track {
    flex-direction: column;
    gap: 12px;
    animation: verticalSlide 25s linear infinite;
  }
  .hero-slide:hover {
    transform: translateX(-4px);
  }
}

.hero-slider-track {
  display: flex;
}
.hero-slider-track:hover {
  animation-play-state: paused;
}
.hero-slide {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  min-width: 280px;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
}
.hero-slide:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--emerald);
}
.hero-slide-icon {
  width: 40px; height: 40px;
  background: var(--emerald-light);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.hero-slide-icon svg {
  width: 20px; height: 20px;
  color: var(--emerald);
}
.hero-slide-text h4 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 2px;
  color: var(--navy);
}
.hero-slide-text p {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.3;
}

@keyframes verticalSlide {
  0% { transform: translateY(0); }
  100% { transform: translateY(-50%); }
}
@keyframes horizontalSlide {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Hero animations */
@keyframes heroTitle {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes heroSub {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes heroStats {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes badgeFade {
  from { opacity: 0; transform: translateY(-10px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes underlineGrow {
  from { transform: scaleX(0); transform-origin: left; }
  to { transform: scaleX(1); transform-origin: left; }
}
@keyframes heroGlow {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(20px, -10px) rotate(1deg); }
}
@keyframes shapeFloat {
  0% { opacity: 0; transform: translateY(20px) scale(0.8); }
  15% { opacity: 1; }
  50% { transform: translateY(-30px) scale(1.05) rotate(5deg); }
  85% { opacity: 1; }
  100% { opacity: 0; transform: translateY(20px) scale(0.8); }
}
@keyframes dotPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

/* ── Cards Grid ── */
.tool-category-heading {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700; font-size: 1.1rem;
  color: var(--navy);
  margin: 40px 0 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--card-bg);
  display: flex; align-items: center; gap: 10px;
}
.tool-category-heading:first-of-type { margin-top: 0; }
.tool-category-heading::before {
  content: '';
  width: 4px; height: 20px;
  background: var(--emerald);
  border-radius: 2px;
}
.tools-grid {
  display: grid; gap: 24px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .tools-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .tools-grid { grid-template-columns: repeat(3, 1fr); } }

.tool-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px 24px;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
  cursor: pointer;
  display: block; text-decoration: none; color: inherit;
  opacity: 0; transform: translateY(10px);
  animation: fadeUp 0.4s ease forwards;
}
.tool-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.tool-card .card-icon {
  width: 48px; height: 48px;
  background: var(--emerald-light); border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.tool-card .card-icon svg { width: 24px; height: 24px; color: var(--emerald); }
.tool-card h3 { margin-bottom: 8px; font-size: 1.15rem; }
.tool-card p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 16px; }
.tool-card .card-link {
  color: var(--emerald); font-weight: 600; font-size: 0.9rem;
  display: inline-flex; align-items: center; gap: 4px;
}

/* Stagger animation delays */
.tool-card:nth-child(1) { animation-delay: 0s; }
.tool-card:nth-child(2) { animation-delay: 0.1s; }
.tool-card:nth-child(3) { animation-delay: 0.2s; }
.tool-card:nth-child(4) { animation-delay: 0.3s; }
.tool-card:nth-child(5) { animation-delay: 0.4s; }
.tool-card:nth-child(6) { animation-delay: 0.5s; }
.tool-card:nth-child(7) { animation-delay: 0.6s; }

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

/* ── Benefit Cards ── */
.benefits-grid {
  display: grid; gap: 24px;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .benefits-grid { grid-template-columns: repeat(3, 1fr); } }
.benefit-card {
  text-align: center; padding: 32px 24px;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.benefit-card .benefit-icon {
  width: 56px; height: 56px; margin: 0 auto 16px;
  background: var(--emerald-light); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.benefit-card .benefit-icon svg { width: 28px; height: 28px; color: var(--emerald); }
.benefit-card h3 { margin-bottom: 8px; }
.benefit-card p { color: var(--text-muted); font-size: 0.9rem; }

/* ── How It Works ── */
.steps-grid {
  display: grid; gap: 32px;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .steps-grid { grid-template-columns: repeat(3, 1fr); } }
.step { text-align: center; }
.step .step-num {
  width: 48px; height: 48px; margin: 0 auto 16px;
  background: var(--navy); color: var(--white);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 1.2rem;
}
.step h3 { margin-bottom: 8px; }
.step p { color: var(--text-muted); font-size: 0.9rem; }

/* ── Tool Page Layout ── */
.tool-layout {
  display: grid; gap: 48px;
  grid-template-columns: 1fr;
  padding: 48px 0;
}
@media (min-width: 1024px) {
  .tool-layout { grid-template-columns: 1fr 1fr; }
}
.tool-layout.full-width { grid-template-columns: 1fr; }

/* ── Form Elements ── */
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; font-weight: 600; font-size: 0.9rem;
  margin-bottom: 6px; color: var(--navy);
}
.form-group .hint {
  font-size: 0.8rem; color: var(--text-muted); margin-top: 4px;
}
input[type="text"], input[type="number"], input[type="email"],
input[type="date"], input[type="tel"], textarea, select {
  width: 100%; height: var(--input-h); padding: 0 16px;
  border: 2px solid var(--border); border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif; font-size: 1rem;
  color: var(--text); background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  -webkit-appearance: none;
}
textarea { height: auto; min-height: 80px; padding: 12px 16px; resize: vertical; }
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%236B7280' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
  padding-right: 40px;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(27,42,74,0.15);
}
input[type="number"] { -moz-appearance: textfield; }
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; }
.input-prefix-wrap {
  position: relative;
}
.input-prefix-wrap .prefix {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  font-weight: 600; color: var(--text-muted); pointer-events: none;
}
.input-prefix-wrap input { padding-left: 36px; }

/* ── Toggle / Radio Group ── */
.toggle-group {
  display: flex; gap: 0; border: 2px solid var(--border);
  border-radius: var(--radius-sm); overflow: hidden;
}
.toggle-group label {
  flex: 1; text-align: center; padding: 12px 16px;
  font-weight: 500; font-size: 0.9rem; cursor: pointer;
  background: var(--white); color: var(--text-muted);
  transition: all var(--transition); border-right: 1px solid var(--border);
}
.toggle-group label:last-child { border-right: none; }
.toggle-group input[type="radio"] { display: none; }
.toggle-group input[type="radio"]:checked + label {
  background: var(--navy); color: var(--white);
}

/* ── Checkbox ── */
.checkbox-wrap {
  display: flex; align-items: center; gap: 10px; cursor: pointer;
  font-size: 0.9rem;
}
.checkbox-wrap input[type="checkbox"] {
  width: 20px; height: 20px; accent-color: var(--emerald);
}

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: var(--input-h); padding: 0 32px;
  border: none; border-radius: var(--radius-sm);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700; font-size: 1rem;
  cursor: pointer; transition: all var(--transition);
  text-decoration: none;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: var(--emerald); color: var(--white);
}
.btn-primary:hover { background: var(--emerald-hover); color: var(--white); }
.btn-secondary {
  background: var(--white); color: var(--navy);
  border: 2px solid var(--border);
}
.btn-secondary:hover { border-color: var(--navy); }
.btn-full { width: 100%; }
.btn-sm { height: 40px; padding: 0 20px; font-size: 0.875rem; }
.btn-group { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 16px; }

/* ── Results Card ── */
.results-card {
  background: var(--white); border-radius: var(--radius);
  padding: 32px; box-shadow: var(--shadow);
  opacity: 0; transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.results-card.visible {
  opacity: 1; transform: translateY(0);
}
.results-card h3 {
  font-size: 1.1rem; margin-bottom: 20px;
  padding-bottom: 12px; border-bottom: 2px solid var(--card-bg);
}
.result-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--card-bg);
}
.result-row:last-child { border-bottom: none; }
.result-row .label { color: var(--text-muted); font-size: 0.9rem; }
.result-row .value {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 500; font-size: 1rem; color: var(--navy);
}
.result-row.total {
  border-top: 2px solid var(--navy); margin-top: 8px; padding-top: 14px;
  border-bottom: none;
}
.result-row.total .label { font-weight: 700; color: var(--navy); font-size: 1rem; }
.result-row.total .value { font-weight: 700; font-size: 1.2rem; }
.result-row .value.positive { color: var(--emerald); }
.result-row .value.negative { color: var(--red); }

/* ── Comparison Table ── */
.comparison-table {
  width: 100%; border-collapse: collapse; margin: 16px 0;
  font-size: 0.9rem;
}
.comparison-table th, .comparison-table td {
  padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--border);
}
.comparison-table th {
  background: var(--navy); color: var(--white); font-weight: 600;
  font-family: 'Plus Jakarta Sans', sans-serif;
}
.comparison-table tr:nth-child(even) { background: var(--card-bg); }
.comparison-table td:last-child, .comparison-table th:last-child { text-align: right; }
.comparison-table .winner { background: var(--emerald-light); font-weight: 600; }

/* ── Save Banner ── */
.save-banner {
  background: var(--emerald-light); color: var(--emerald-hover);
  padding: 16px 24px; border-radius: var(--radius-sm);
  font-weight: 700; text-align: center; margin: 16px 0;
  font-size: 1rem;
}

/* ── Info Section ── */
.info-section { padding: 48px 0; }
.info-section h2 { margin-bottom: 24px; }
.info-section h3 { margin: 32px 0 12px; }
.info-section p { margin-bottom: 16px; color: var(--text); }
.info-section ul, .info-section ol {
  margin: 0 0 16px 24px; color: var(--text);
}
.info-section li { margin-bottom: 8px; }

/* ── Data Table ── */
.data-table {
  width: 100%; border-collapse: collapse; margin: 16px 0;
  font-size: 0.9rem; border-radius: var(--radius-sm); overflow: hidden;
  box-shadow: var(--shadow);
}
.data-table th, .data-table td {
  padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--border);
}
.data-table th {
  background: var(--navy); color: var(--white); font-weight: 600;
}
.data-table tr:nth-child(even) { background: var(--card-bg); }

/* ── Chart (CSS Bar) ── */
.bar-chart { display: flex; gap: 24px; align-items: flex-end; height: 200px; padding: 16px 0; }
.bar-chart .bar-wrap { flex: 1; text-align: center; }
.bar-chart .bar {
  width: 100%; border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  transition: height 0.5s ease;
  min-height: 4px;
}
.bar-chart .bar.old { background: var(--navy); }
.bar-chart .bar.new { background: var(--emerald); }
.bar-chart .bar-label { margin-top: 8px; font-size: 0.8rem; color: var(--text-muted); }
.bar-chart .bar-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem; font-weight: 500; margin-bottom: 4px;
}

/* ── Donut Chart ── */
.donut-wrap { display: flex; align-items: center; gap: 32px; margin: 24px 0; }
.donut-legend { display: flex; flex-direction: column; gap: 12px; }
.donut-legend .legend-item { display: flex; align-items: center; gap: 8px; font-size: 0.9rem; }
.donut-legend .legend-dot { width: 12px; height: 12px; border-radius: 50%; }

/* ── Ad Slot Placeholder ── */
.ad-slot {
  background: var(--card-bg); border: 2px dashed var(--border);
  border-radius: var(--radius-sm); padding: 32px; text-align: center;
  color: var(--text-light); font-size: 0.85rem; margin: 32px 0;
  min-height: 90px; display: flex; align-items: center; justify-content: center;
}

/* ── Disclaimer ── */
.disclaimer {
  background: var(--card-bg); border-radius: var(--radius-sm);
  padding: 20px 24px; margin: 32px 0;
  font-size: 0.85rem; color: var(--text-muted);
  border-left: 4px solid var(--navy);
}

/* ── Footer ── */
.site-footer {
  background: var(--navy); color: rgba(255,255,255,0.8);
  padding: 64px 0 0; margin-top: 64px;
}
.footer-grid {
  display: grid; gap: 40px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-col h4 {
  color: var(--white); margin-bottom: 16px; font-size: 1rem;
}
.footer-col p { font-size: 0.9rem; margin-bottom: 12px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
  color: rgba(255,255,255,0.7); font-size: 0.9rem;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--emerald); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 24px 0; margin-top: 40px;
  text-align: center; font-size: 0.85rem; color: rgba(255,255,255,0.5);
}

/* ── Section spacing ── */
.section { padding: 48px 0; }
.section-title { text-align: center; margin-bottom: 40px; }
.section-title h2 { margin-bottom: 12px; }
.section-title p { color: var(--text-muted); max-width: 600px; margin: 0 auto; }

/* ── Inline link list ── */
.related-links {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px;
}
.related-links a {
  background: var(--card-bg); padding: 6px 14px;
  border-radius: 100px; font-size: 0.85rem; font-weight: 500;
  color: var(--navy); transition: all var(--transition);
}
.related-links a:hover { background: var(--emerald-light); color: var(--emerald-hover); }

/* ── Amortization Table ── */
.amort-table-wrap {
  max-height: 400px; overflow-y: auto; border-radius: var(--radius-sm);
  box-shadow: var(--shadow); margin: 16px 0;
}
.amort-table {
  width: 100%; border-collapse: collapse; font-size: 0.85rem;
  font-family: 'JetBrains Mono', monospace;
}
.amort-table th {
  position: sticky; top: 0; z-index: 2;
  background: var(--navy); color: var(--white); padding: 10px 12px;
  text-align: right; font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 600; font-size: 0.8rem;
}
.amort-table th:first-child { text-align: center; }
.amort-table td { padding: 8px 12px; text-align: right; border-bottom: 1px solid var(--border); }
.amort-table td:first-child { text-align: center; color: var(--text-muted); }
.amort-table tr:nth-child(even) { background: var(--card-bg); }

/* ── Invoice Preview ── */
.invoice-preview {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 48px; margin: 24px 0;
  box-shadow: var(--shadow-md); font-size: 0.9rem;
}
.invoice-preview table { width: 100%; border-collapse: collapse; margin: 24px 0; }
.invoice-preview th {
  background: var(--navy); color: var(--white); padding: 10px 12px;
  text-align: left; font-size: 0.85rem;
}
.invoice-preview td { padding: 10px 12px; border-bottom: 1px solid var(--border); }
.invoice-preview .invoice-header {
  display: flex; justify-content: space-between; align-items: flex-start;
  margin-bottom: 32px; flex-wrap: wrap; gap: 16px;
}
.invoice-preview .invoice-total-box {
  background: var(--card-bg); border-radius: var(--radius-sm);
  padding: 20px; margin-top: 24px;
}
.invoice-preview .invoice-total-row {
  display: flex; justify-content: space-between; padding: 6px 0;
}
.invoice-preview .invoice-total-row.grand {
  border-top: 2px solid var(--navy); margin-top: 8px; padding-top: 12px;
  font-weight: 700; font-size: 1.1rem;
}

/* ── Balance Sheet Layout ── */
.bs-columns {
  display: grid; gap: 32px; grid-template-columns: 1fr;
}
@media (min-width: 768px) { .bs-columns { grid-template-columns: 1fr 1fr; } }
.bs-side h3 { margin-bottom: 16px; padding-bottom: 8px; border-bottom: 2px solid var(--navy); }
.bs-balance-status {
  text-align: center; padding: 16px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 1rem; margin: 24px 0;
}
.bs-balance-status.balanced { background: var(--emerald-light); color: var(--emerald-hover); }
.bs-balance-status.unbalanced { background: var(--red-light); color: var(--red); }

/* ── Responsive helpers ── */
.hide-mobile { display: none; }
@media (min-width: 768px) { .hide-mobile { display: block; } }
.show-mobile { display: block; }
@media (min-width: 768px) { .show-mobile { display: none; } }

/* ── Print styles ── */
@media print {
  .site-header, .site-footer, .breadcrumb, .btn, .trust-badge,
  .disclaimer, .ad-slot, .related-links { display: none !important; }
  body { background: white; }
  .results-card, .invoice-preview { box-shadow: none; border: 1px solid #ccc; }
}

/* ── Updated tag ── */
.updated-tag {
  font-size: 0.8rem; color: var(--text-light); margin-top: 8px;
}

/* ── Modal ── */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,0.5); align-items: center; justify-content: center;
  padding: 24px;
}
.modal-overlay.active { display: flex; }
.modal-content {
  background: var(--white); border-radius: var(--radius);
  max-width: 800px; width: 100%; max-height: 90vh; overflow-y: auto;
  padding: 32px; position: relative;
}
.modal-close {
  position: absolute; top: 16px; right: 16px;
  background: none; border: none; cursor: pointer; padding: 8px;
}
.modal-close svg { width: 24px; height: 24px; stroke: var(--text-muted); }
