:root {
  --navy: #10243e;
  --blue: #1d4f91;
  --green: #168a5b;
  --orange: #f27a1a;
  --ink: #1b2638;
  --muted: #5f6b7a;
  --line: #dfe6ee;
  --soft: #f4f7fb;
  --softer: #f9fbfd;
  --white: #fff;
  --shadow: 0 18px 50px rgba(16, 36, 62, 0.11);
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--white); line-height: 1.6; }
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; }
code { background: #eef3f8; border: 1px solid var(--line); border-radius: 6px; padding: 0.1rem 0.35rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem clamp(1rem, 4vw, 3rem);
  background: rgba(255,255,255,0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand { display: inline-flex; align-items: center; gap: 0.7rem; min-width: max-content; }
.brand strong { display: block; color: var(--navy); font-size: 1.05rem; letter-spacing: 0; }
.brand small { display: block; color: var(--muted); font-size: 0.76rem; margin-top: -0.15rem; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--navy);
  color: #fff;
  font-weight: 800;
  font-size: 0.8rem;
}

.site-nav { display: flex; align-items: center; gap: 0.25rem; flex-wrap: wrap; justify-content: flex-end; }
.site-nav a { color: #31445d; font-size: 0.93rem; padding: 0.48rem 0.62rem; border-radius: 6px; }
.site-nav a:hover { background: var(--soft); color: var(--navy); }
.site-nav .nav-cta { background: var(--green); color: #fff; font-weight: 750; }
.nav-toggle { display: none; border: 1px solid var(--line); background: #fff; border-radius: 6px; padding: 0.55rem 0.8rem; color: var(--navy); font-weight: 750; }

.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.55fr);
  align-items: center;
  gap: clamp(1.5rem, 5vw, 4rem);
  padding: clamp(3rem, 7vw, 6rem) clamp(1rem, 5vw, 5rem);
  background:
    linear-gradient(120deg, rgba(16,36,62,0.92), rgba(29,79,145,0.82)),
    url("https://images.unsplash.com/photo-1600585154340-be6161a56a0c?auto=format&fit=crop&w=1800&q=80") center/cover;
  color: #fff;
}

.home-hero h1, .page-hero h1, .article-hero h1 {
  margin: 0;
  color: inherit;
  line-height: 1.03;
  font-size: clamp(2.4rem, 6vw, 5.2rem);
  letter-spacing: 0;
}

.home-hero p { max-width: 760px; font-size: 1.18rem; color: rgba(255,255,255,0.88); }
.eyebrow { margin: 0 0 0.65rem; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 850; font-size: 0.76rem; color: var(--green); }
.home-hero .eyebrow { color: #83e0bb; }

.search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.65rem;
  width: min(760px, 100%);
  margin-top: 1.6rem;
  padding: 0.55rem;
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}
.search-box input, input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.82rem 0.9rem;
  font: inherit;
  color: var(--ink);
  background: #fff;
}
.search-box input { border: 0; min-width: 0; }
.search-results { display: grid; gap: 0.5rem; margin-top: 1rem; max-width: 760px; }
.search-results a { padding: 0.75rem 0.9rem; border-radius: 6px; background: rgba(255,255,255,0.14); border: 1px solid rgba(255,255,255,0.22); }

.hero-estimator, .range-card, .sticky-card, .calculator-card, .quote-panel, .author-box, .affiliate-box {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.hero-estimator { color: var(--ink); padding: 1.4rem; }
.hero-estimator span, .range-card span, .result-grid span, .calc-card span, .category-card span { color: var(--muted); font-size: 0.82rem; font-weight: 750; text-transform: uppercase; letter-spacing: 0.05em; }
.hero-estimator strong { display: block; color: var(--navy); font-size: 1.7rem; }
.hero-estimator p { color: var(--green); font-size: 2rem; font-weight: 850; margin: 0.4rem 0; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.75rem 1.05rem;
  border: 0;
  border-radius: 6px;
  font-weight: 800;
  cursor: pointer;
}
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: #0f724a; }
.btn-secondary { background: #eef5ff; color: var(--blue); border: 1px solid #cfe0f4; }

.section, .content-shell { padding: clamp(2.6rem, 6vw, 5rem) clamp(1rem, 5vw, 5rem); }
.section.alt { background: var(--soft); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.3rem; }
.section-head h2, .trust-band h2, .quote-panel h2, .email-capture h2, article h2 {
  margin: 0;
  color: var(--navy);
  line-height: 1.15;
  font-size: clamp(1.55rem, 3vw, 2.55rem);
  letter-spacing: 0;
}
.section-head p { color: var(--muted); max-width: 720px; }
.section-head a { color: var(--blue); font-weight: 800; }

.card-grid, .category-grid, .guide-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}
.card-grid.small { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.calc-card, .category-card, .guide-grid a {
  display: grid;
  gap: 0.55rem;
  min-height: 150px;
  padding: 1.1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}
.calc-card:hover, .category-card:hover, .guide-grid a:hover { transform: translateY(-2px); border-color: #b9c8d9; box-shadow: 0 14px 35px rgba(16,36,62,0.09); }
.calc-card strong, .category-card strong, .guide-grid strong { color: var(--navy); font-size: 1.05rem; line-height: 1.25; }
.calc-card small, .category-card small, .guide-grid span { color: var(--muted); }

.trust-band {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 2rem;
  align-items: center;
  padding: clamp(2.6rem, 6vw, 5rem) clamp(1rem, 5vw, 5rem);
  background: var(--navy);
  color: #fff;
}
.trust-band h2 { color: #fff; }
.trust-band p { color: rgba(255,255,255,0.78); }
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; }
.trust-grid div { padding: 1rem; border: 1px solid rgba(255,255,255,0.18); border-radius: var(--radius); background: rgba(255,255,255,0.08); }
.trust-grid strong { display: block; font-size: 2rem; }
.trust-grid span { color: rgba(255,255,255,0.76); }

.quote-panel {
  display: grid;
  grid-template-columns: 0.65fr 1fr;
  gap: 1.5rem;
  margin: clamp(2.6rem, 6vw, 5rem) clamp(1rem, 5vw, 5rem);
  padding: clamp(1.2rem, 3vw, 2rem);
}
.lead-form, .cost-calculator {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}
label { display: grid; gap: 0.35rem; color: #31445d; font-weight: 720; font-size: 0.92rem; }
label span { color: var(--muted); font-size: 0.8rem; }
.full { grid-column: 1 / -1; }
.check { display: flex; align-items: start; gap: 0.55rem; font-weight: 600; color: var(--muted); }
.check input { width: auto; margin-top: 0.3rem; }
.honeypot { position: absolute; left: -9999px; opacity: 0; }
.form-status { color: var(--green); font-weight: 750; margin: 0; }

.email-capture {
  display: grid;
  grid-template-columns: 1fr 0.7fr;
  gap: 1rem;
  align-items: center;
  padding: clamp(2rem, 5vw, 4rem) clamp(1rem, 5vw, 5rem);
  background: #eaf5ef;
}
.email-capture form { display: grid; grid-template-columns: 1fr auto; gap: 0.75rem; }

.page-hero, .article-hero {
  padding: clamp(2.4rem, 6vw, 5rem) clamp(1rem, 5vw, 5rem);
  background: linear-gradient(180deg, #f8fbfe, #fff);
  border-bottom: 1px solid var(--line);
}
.page-hero { max-width: none; }
.page-hero h1, .article-hero h1 { color: var(--navy); }
.page-hero p, .lede { max-width: 820px; color: var(--muted); font-size: 1.12rem; }
.breadcrumbs { color: var(--muted); font-size: 0.9rem; margin-bottom: 1rem; }
.breadcrumbs a { color: var(--blue); font-weight: 750; }
.hero-split { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 2rem; align-items: center; }
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1.2rem; }
.range-card { padding: 1.3rem; }
.range-card strong { display: block; color: var(--green); font-size: 2rem; line-height: 1.1; margin: 0.4rem 0; }
.range-card small { color: var(--muted); }

.content-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 1.5rem;
  align-items: start;
}
.article-body { display: grid; gap: 1.65rem; min-width: 0; }
.article-body section:not(.calculator-card):not(.quote-panel):not(.affiliate-box):not(.author-box):not(.disclaimer) { scroll-margin-top: 96px; }
article h3 { margin: 1.1rem 0 0.25rem; color: var(--navy); font-size: 1.15rem; }
article p { color: #34455c; }

.calculator-card { padding: clamp(1rem, 3vw, 1.5rem); display: grid; gap: 1rem; }
.result-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}
.result-grid div, .breakdown-grid p {
  margin: 0;
  padding: 0.9rem;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.result-grid strong { display: block; color: var(--navy); font-size: 1.35rem; line-height: 1.2; overflow-wrap: anywhere; }
.breakdown-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; }

.toc {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0.8rem;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.toc strong { color: var(--navy); margin-right: 0.25rem; }
.toc a { color: var(--blue); font-weight: 750; }

table { width: 100%; border-collapse: collapse; margin: 1rem 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: table; }
caption { text-align: left; font-weight: 850; color: var(--navy); padding: 0.7rem 0; }
th, td { text-align: left; padding: 0.85rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: #eef3f8; color: var(--navy); }
tr:last-child td { border-bottom: 0; }

.checklist { padding: 0; list-style: none; display: grid; gap: 0.55rem; }
.checklist li { padding-left: 1.5rem; position: relative; }
.checklist li:before { content: ""; position: absolute; left: 0; top: 0.58rem; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }

.faq details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.8rem 1rem;
  background: #fff;
  margin-bottom: 0.65rem;
}
.faq summary { cursor: pointer; color: var(--navy); font-weight: 850; }

.ad-slot {
  display: grid;
  place-items: center;
  min-height: 110px;
  border: 1px dashed #b6c4d3;
  border-radius: var(--radius);
  background: #f7f9fb;
  color: #758295;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.sidebar { display: grid; gap: 1rem; position: sticky; top: 92px; }
.sticky-card { padding: 1rem; }
.sticky-card h3 { color: var(--navy); margin: 0 0 0.4rem; }

.affiliate-box, .author-box, .disclaimer { padding: 1rem; }
.affiliate-box { background: #fff9f3; border-color: #f2d4b8; }
.disclaimer { background: #f6f8fb; border: 1px solid var(--line); border-radius: var(--radius); }
.pill-row { display: flex; gap: 0.55rem; flex-wrap: wrap; }
.pill-row a { background: #eef3f8; border: 1px solid var(--line); border-radius: 999px; padding: 0.48rem 0.75rem; color: var(--blue); font-weight: 750; }

.directory-group {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 1rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--line);
}
.directory-group h2 { color: var(--navy); margin-top: 0; }
.directory-group p { color: var(--muted); }

.prose { max-width: 920px; }
.prose h2 { color: var(--navy); margin-top: 0; }
.contact-form { max-width: 760px; }

.site-footer {
  padding: clamp(2rem, 5vw, 4rem) clamp(1rem, 5vw, 5rem);
  background: #0d1f35;
  color: rgba(255,255,255,0.78);
}
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 1.5rem; }
.footer-brand strong { color: #fff; }
.site-footer h3 { color: #fff; margin: 0 0 0.6rem; }
.site-footer a { display: block; color: rgba(255,255,255,0.82); margin: 0.35rem 0; }
.site-footer .footer-button {
  display: inline-flex;
  margin-top: 0.55rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 6px;
  color: #fff;
  font-weight: 800;
}
.contact-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1.25rem; }
.fine-print { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1rem; margin-top: 1.5rem; font-size: 0.86rem; }

@media (max-width: 1100px) {
  .card-grid, .category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-header { align-items: flex-start; }
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; left: 1rem; right: 1rem; top: 66px; padding: 0.85rem; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); justify-content: flex-start; }
  .site-nav.open { display: flex; }
}

@media (max-width: 880px) {
  .home-hero, .hero-split, .trust-band, .quote-panel, .email-capture, .content-shell, .directory-group { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .card-grid, .card-grid.small, .category-grid, .guide-grid, .result-grid, .breakdown-grid, .lead-form, .cost-calculator, .footer-grid, .trust-grid { grid-template-columns: 1fr 1fr; }
  .range-card { max-width: 560px; }
}

@media (max-width: 620px) {
  .site-header { min-height: 64px; padding: 0.7rem 1rem; }
  .brand small { display: none; }
  .home-hero h1, .page-hero h1, .article-hero h1 { font-size: 2.35rem; }
  .search-box, .email-capture form, .card-grid, .card-grid.small, .category-grid, .guide-grid, .result-grid, .breakdown-grid, .lead-form, .cost-calculator, .footer-grid, .trust-grid { grid-template-columns: 1fr; }
  .section-head { align-items: start; flex-direction: column; }
  table { display: block; overflow-x: auto; white-space: nowrap; }
  .quote-panel { margin-left: 1rem; margin-right: 1rem; }
}
