/* ── Base ─────────────────────────────────────────── */
html { scroll-behavior: smooth; }
body { font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

/* ── Form controls ────────────────────────────────── */
details > summary { user-select: none; }
input[type="number"]:focus, input[type="text"]:focus, select:focus { outline: 2px solid #1d4ed8; outline-offset: 2px; border-color: #1d4ed8; }
input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type=number] { -moz-appearance: textfield; }

/* ── Buttons ──────────────────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: #1d4ed8; color: #fff;
  padding: 0.875rem 2rem; border-radius: 0.875rem;
  font-weight: 600; font-size: 1rem; letter-spacing: -0.01em;
  transition: all 0.2s ease; white-space: nowrap;
}
.btn-primary:hover { background: #1e40af; transform: translateY(-1px); box-shadow: 0 6px 24px rgba(29,78,216,0.28); }

.btn-secondary {
  display: inline-flex; align-items: center; gap: 0.5rem;
  border: 1.5px solid #cbd5e1; color: #334155;
  padding: 0.875rem 2rem; border-radius: 0.875rem;
  font-weight: 600; font-size: 1rem; letter-spacing: -0.01em;
  transition: all 0.2s ease; white-space: nowrap;
}
.btn-secondary:hover { border-color: #1d4ed8; color: #1d4ed8; background: #eff6ff; }

.btn-nav {
  display: inline-flex; align-items: center; gap: 0.375rem;
  background: #1d4ed8; color: #fff;
  padding: 0.5rem 1.25rem; border-radius: 0.625rem;
  font-weight: 600; font-size: 0.875rem;
  transition: all 0.18s ease;
}
.btn-nav:hover { background: #1e40af; box-shadow: 0 4px 14px rgba(29,78,216,0.25); }

.btn-calc {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  background: #16a34a; color: #fff; width: 100%;
  padding: 0.875rem 2rem; border-radius: 0.75rem;
  font-weight: 600; font-size: 1rem;
  transition: all 0.2s ease; border: none; cursor: pointer;
}
.btn-calc:hover { background: #15803d; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(22,163,74,0.3); }

/* ── Cards ────────────────────────────────────────── */
.card-hover { transition: all 0.22s ease; }
.card-hover:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(0,0,0,0.09); }

/* ── Hero ─────────────────────────────────────────── */
.hero-section {
  background:
    radial-gradient(circle, rgba(147,197,253,0.3) 1.5px, transparent 1.5px),
    linear-gradient(170deg, #eff6ff 0%, #ffffff 60%);
  background-size: 30px 30px, 100% 100%;
  position: relative;
}
.hero-section::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #1d4ed8, #3b82f6, #16a34a);
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: #eff6ff; color: #1d4ed8;
  border: 1px solid #bfdbfe;
  padding: 0.375rem 1rem; border-radius: 9999px;
  font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.04em;
  text-transform: uppercase;
}
.hero-badge::before { content: '✦'; font-size: 0.625rem; }

/* ── Dark strip ───────────────────────────────────── */
.dark-strip { background: #0f172a; color: #fff; }
.stat-number { font-size: 2.75rem; font-weight: 800; line-height: 1; letter-spacing: -0.04em; color: #60a5fa; }
.stat-label { font-size: 0.9375rem; color: #94a3b8; margin-top: 0.375rem; }

/* ── Category icons ───────────────────────────────── */
.cat-icon {
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: #eff6ff; margin-bottom: 1.25rem; flex-shrink: 0;
}
.cat-icon svg { color: #1d4ed8; }

/* ── Pillar icons ─────────────────────────────────── */
.pillar-icon {
  width: 48px; height: 48px; border-radius: 12px;
  background: rgba(59,130,246,0.12);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
}
.pillar-icon svg { color: #3b82f6; }

/* ── CTA strip ────────────────────────────────────── */
.cta-strip { background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 50%, #2563eb 100%); }

/* ── Nav ──────────────────────────────────────────── */
.nav-link { font-size: 0.9375rem; font-weight: 500; color: #475569; transition: color 0.15s ease; position: relative; }
.nav-link:hover { color: #1d4ed8; }
.nav-link.active { color: #1d4ed8; font-weight: 600; }

/* ── Footer ───────────────────────────────────────── */
.footer-dark { background: #0f172a; }
.footer-link { color: #94a3b8; font-size: 0.875rem; transition: color 0.15s ease; display: block; }
.footer-link:hover { color: #60a5fa; }
.footer-heading { color: #f1f5f9; font-weight: 600; font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 1rem; }

/* ── Trust badge ──────────────────────────────────── */
.trust-badge {
  display: inline-flex; align-items: center; gap: 0.375rem;
  background: #f8fafc; border: 1px solid #e2e8f0;
  padding: 0.25rem 0.75rem; border-radius: 9999px;
  font-size: 0.75rem; color: #64748b;
}

/* ── Gradient text ────────────────────────────────── */
.text-gradient {
  background: linear-gradient(135deg, #1d4ed8, #16a34a);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Calculator result card ───────────────────────── */
.result-card { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 1rem; padding: 1.5rem; }
.result-value { font-size: 2rem; font-weight: 800; color: #1d4ed8; letter-spacing: -0.03em; }
.result-label { font-size: 0.875rem; color: #64748b; margin-top: 0.25rem; }
.result-positive { color: #16a34a; }
.result-negative { color: #dc2626; }

/* ── Section divider ──────────────────────────────── */
.section-divider { height: 1px; background: linear-gradient(90deg, transparent, #e2e8f0 30%, #e2e8f0 70%, transparent); margin: 0; }

/* ── Affiliate box ────────────────────────────────── */
.affiliate-box {
  background: linear-gradient(135deg, #eff6ff, #f0fdf4);
  border: 1px solid #bfdbfe; border-radius: 1rem;
  padding: 1.5rem; margin: 2rem 0;
}
.affiliate-box-title { font-size: 1rem; font-weight: 700; color: #1e293b; margin-bottom: 0.5rem; }
.affiliate-box-cta {
  display: inline-flex; align-items: center; gap: 0.375rem;
  background: #16a34a; color: #fff;
  padding: 0.625rem 1.5rem; border-radius: 0.625rem;
  font-weight: 600; font-size: 0.9375rem;
  transition: all 0.18s ease; margin-top: 1rem;
}
.affiliate-box-cta:hover { background: #15803d; }

/* ── Calculator hero (page headers on individual calc pages) ──── */
.calc-hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 40%, #1d4ed8 100%);
  position: relative; overflow: hidden;
}
.calc-hero::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, #60a5fa, #34d399, #a78bfa);
}
.calc-hero::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at 70% 50%, rgba(99,102,241,0.18) 0%, transparent 60%);
}

/* ── Category colour variants ─────────────────────── */
.cat-icon-green  { background: #f0fdf4; }
.cat-icon-green svg  { color: #16a34a; }
.cat-icon-red    { background: #fff1f2; }
.cat-icon-red svg    { color: #e11d48; }
.cat-icon-purple { background: #f5f3ff; }
.cat-icon-purple svg { color: #7c3aed; }
.cat-icon-amber  { background: #fffbeb; }
.cat-icon-amber svg  { color: #d97706; }
