/* ============================================
   RiskSorted — Design System v2 (brand-aligned)
   ============================================ */

:root {
  /* Palette — locked per brand brief, WCAG AA verified */
  --ink: #14213D;
  --ink-soft: #1F2D4D;
  --ink-muted: #5C6B85;
  --paper: #F4F1EB;
  --paper-warm: #ECE7DA;
  --rule: #DDD5C5;
  --green: #00B84A;
  --green-deep: #00802D;
  --white: #FFFFFF;

  /* Typography — single family, brief-compliant */
  --font-display: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-body: 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', monospace;

  --max: 1240px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}
.eyebrow::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--green);
  border-radius: 50%;
  display: inline-block;
}

/* Nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(244, 241, 235, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--rule);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px var(--gutter);
  max-width: var(--max);
  margin: 0 auto;
}
.brand-logo { display: block; height: 32px; width: auto; }

.nav-links { display: flex; gap: 32px; align-items: center; list-style: none; }
.nav-links a { font-size: 15px; color: var(--ink-soft); font-weight: 500; transition: color 0.2s var(--ease); }
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  background: var(--green);
  color: var(--ink);
  padding: 10px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 700;
  transition: all 0.25s var(--ease);
}
.nav-cta:hover { background: #00CD53; transform: translateY(-1px); box-shadow: 0 6px 16px -6px rgba(0, 184, 74, 0.5); }

@media (max-width: 760px) { .nav-links li:not(:last-child) { display: none; } }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 100px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.25s var(--ease);
  letter-spacing: -0.01em;
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--ink-soft); transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(20, 33, 61, 0.4); }
.btn-green { background: var(--green); color: var(--ink); font-weight: 700; }
.btn-green:hover { background: #00CD53; color: var(--ink); transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(0, 184, 74, 0.4); }
.btn-secondary { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--paper); }
.btn-arrow { width: 16px; height: 16px; transition: transform 0.25s var(--ease); }
.btn:hover .btn-arrow { transform: translateX(4px); }

/* Hero */
.hero { padding: clamp(60px, 10vw, 120px) 0 clamp(60px, 8vw, 100px); position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 60px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } }
.hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(40px, 6.5vw, 80px);
  line-height: 1;
  letter-spacing: -0.035em;
  margin: 24px 0 28px;
  color: var(--ink);
}
.hero h1 .accent {
  color: var(--green-deep);
  position: relative;
  display: inline-block;
}
.hero h1 .accent::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: 4px;
  height: 14px;
  background: var(--green);
  z-index: -1;
  opacity: 0.3;
}
.hero h1 em { font-style: normal; color: var(--ink-muted); font-weight: 500; }
.hero-sub { font-size: clamp(17px, 1.5vw, 19px); color: var(--ink-soft); max-width: 480px; margin-bottom: 40px; line-height: 1.55; font-weight: 400; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-secondary-cta { margin-top: 20px; font-size: 14px; color: var(--ink-muted); }
.hero-secondary-cta a { color: var(--green-deep); font-weight: 600; transition: color 0.2s var(--ease); }
.hero-secondary-cta a:hover { color: var(--ink); }

.section-local { background: var(--paper-warm); }
.local-pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-top: 16px; }
@media (max-width: 760px) { .local-pillars { grid-template-columns: 1fr; gap: 24px; } }
.local-pillar { background: var(--paper); padding: 32px 28px; border-radius: 16px; border: 1px solid var(--rule); }
.local-pillar-icon { width: 48px; height: 48px; color: var(--green-deep); margin-bottom: 20px; }
.local-pillar-icon svg { width: 100%; height: 100%; }
.local-pillar h3 { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; margin-bottom: 10px; color: var(--ink); }
.local-pillar p { font-size: 15px; color: var(--ink-soft); line-height: 1.55; }

.quote-card {
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 30px 60px -20px rgba(20, 33, 61, 0.18);
  position: relative;
}
.quote-card::before {
  content: 'INSTANT QUOTE';
  position: absolute;
  top: -10px; left: 24px;
  background: var(--ink); color: var(--paper);
  padding: 4px 12px; border-radius: 100px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.15em; font-weight: 500;
}
.quote-row { display: flex; justify-content: space-between; padding: 14px 0; border-bottom: 1px solid var(--rule); font-size: 15px; }
.quote-row:last-of-type { border-bottom: none; }
.quote-row span:first-child { color: var(--ink-muted); }
.quote-row span:last-child { font-weight: 600; }
.quote-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 18px; padding-top: 18px; border-top: 2px solid var(--ink); }
.quote-total span:first-child { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-muted); font-weight: 500; }
.quote-total .price { font-family: var(--font-display); font-size: 38px; font-weight: 800; letter-spacing: -0.03em; color: var(--ink); }
.quote-meta { display: flex; gap: 8px; margin-top: 16px; font-size: 12px; color: var(--ink-muted); align-items: center; }
.quote-meta .dot { width: 6px; height: 6px; background: var(--green); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.4; transform: scale(1.3); } }

.trust-strip { margin-top: 80px; padding-top: 36px; border-top: 1px solid var(--rule); display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
@media (max-width: 760px) { .trust-strip { grid-template-columns: repeat(2, 1fr); gap: 24px; } }
.trust-item .num { font-family: var(--font-display); font-size: 36px; font-weight: 800; letter-spacing: -0.03em; display: block; margin-bottom: 4px; color: var(--ink); }
.trust-item .label { font-size: 13px; color: var(--ink-muted); line-height: 1.4; }

/* Sections */
.section { padding: clamp(70px, 10vw, 130px) 0; }
.section-dark { background: var(--ink); color: var(--paper); }
.section-dark .eyebrow { color: var(--paper); opacity: 0.6; }
.section-head { max-width: 720px; margin-bottom: 60px; }
.section-head h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(32px, 4.2vw, 52px);
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 16px 0 20px;
  color: var(--ink);
}
.section-dark .section-head h2 { color: var(--paper); }
.section-head p { font-size: 18px; color: var(--ink-muted); line-height: 1.55; max-width: 580px; }
.section-dark .section-head p { color: var(--paper); opacity: 0.7; }

/* Service cards */
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: 18px; overflow: hidden; }
@media (max-width: 900px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .services-grid { grid-template-columns: 1fr; } }
.service-card { background: var(--paper); padding: 32px 28px; display: flex; flex-direction: column; transition: background 0.3s var(--ease); position: relative; min-height: 240px; }
.service-card:hover { background: var(--white); }
.service-card .badge { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.12em; color: var(--green-deep); margin-bottom: 16px; display: flex; align-items: center; gap: 6px; font-weight: 500; text-transform: uppercase; }
.service-card .badge::before { content: ''; width: 6px; height: 6px; background: var(--green); border-radius: 50%; }
.service-card h3 { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; margin-bottom: 8px; color: var(--ink); }
.service-card .price-from { font-size: 14px; color: var(--ink-muted); margin-bottom: 16px; }
.service-card .price-from b { color: var(--ink); font-weight: 700; }
.service-card .desc { font-size: 14px; color: var(--ink-soft); line-height: 1.5; margin-bottom: 20px; flex: 1; }
.service-card .link { font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; color: var(--ink); }
.service-card .link::after { content: '→'; transition: transform 0.2s var(--ease); }
.service-card:hover .link::after { transform: translateX(4px); }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; position: relative; }
@media (max-width: 900px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.step .step-num { font-family: var(--font-mono); font-size: 12px; color: var(--green); letter-spacing: 0.12em; margin-bottom: 16px; display: block; font-weight: 500; }
.step h3 { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; margin-bottom: 10px; line-height: 1.15; color: var(--paper); }
.step p { font-size: 14px; color: var(--paper); opacity: 0.65; line-height: 1.55; }
.step-icon { width: 44px; height: 44px; border: 1.5px solid var(--paper); border-radius: 10px; display: grid; place-items: center; margin-bottom: 20px; opacity: 0.5; }

/* Differentiator */
.diff-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--rule); border-radius: 18px; overflow: hidden; }
@media (max-width: 760px) { .diff-grid { grid-template-columns: 1fr; } }
.diff-side { padding: 40px; }
.diff-side.bad { background: var(--paper-warm); }
.diff-side.good { background: var(--ink); color: var(--paper); }
.diff-side .diff-title { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.15em; text-transform: uppercase; margin-bottom: 24px; display: flex; align-items: center; gap: 8px; font-weight: 500; }
.diff-side.bad .diff-title { color: var(--ink-muted); }
.diff-side.good .diff-title { color: var(--green); }
.diff-side ul { list-style: none; }
.diff-side li { padding: 14px 0; font-size: 16px; display: flex; gap: 12px; align-items: flex-start; line-height: 1.5; }
.diff-side.bad li { color: var(--ink-muted); border-bottom: 1px solid var(--rule); }
.diff-side.good li { color: var(--paper); border-bottom: 1px solid rgba(244, 241, 235, 0.1); }
.diff-side li:last-child { border-bottom: none; }
.diff-mark { flex-shrink: 0; width: 18px; height: 18px; display: grid; place-items: center; margin-top: 2px; }

/* CTA Block */
.cta-block { background: var(--ink); color: var(--paper); border-radius: 24px; padding: clamp(40px, 6vw, 80px); text-align: center; position: relative; overflow: hidden; }
.cta-block::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 30% 30%, rgba(0, 184, 74, 0.18), transparent 60%); pointer-events: none; }
.cta-block h2 { font-family: var(--font-display); font-weight: 800; font-size: clamp(30px, 3.8vw, 46px); letter-spacing: -0.03em; line-height: 1.1; margin-bottom: 20px; position: relative; color: var(--paper); }
.cta-block p { font-size: 18px; color: var(--paper); opacity: 0.8; margin-bottom: 32px; max-width: 520px; margin-left: auto; margin-right: auto; position: relative; }
.cta-block .btn-primary { background: var(--green); color: var(--ink); position: relative; font-weight: 700; }
.cta-block .btn-primary:hover { background: #00CD53; color: var(--ink); }

/* Footer */
.footer { background: var(--ink); color: var(--paper); padding: 80px 0 40px; }
.footer-top { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 60px; border-bottom: 1px solid rgba(244, 241, 235, 0.1); }
@media (max-width: 760px) { .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; } }
.footer-logo { display: block; height: 36px; width: auto; margin-bottom: 16px; }
.footer-tag { font-size: 14px; color: var(--paper); opacity: 0.6; max-width: 280px; line-height: 1.5; }
.footer h4 { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 18px; color: var(--paper); font-weight: 500; }
.footer ul { list-style: none; }
.footer li { margin-bottom: 10px; }
.footer li a { font-size: 14px; color: var(--paper); opacity: 0.7; transition: opacity 0.2s var(--ease); }
.footer li a:hover { opacity: 1; }
.footer-bottom { display: flex; justify-content: space-between; padding-top: 32px; font-size: 13px; color: var(--paper); opacity: 0.5; flex-wrap: wrap; gap: 16px; }

/* Page-level */
.page-hero { padding: clamp(80px, 12vw, 140px) 0 clamp(40px, 6vw, 80px); }
.page-hero h1 { font-family: var(--font-display); font-weight: 800; font-size: clamp(36px, 5.5vw, 68px); letter-spacing: -0.035em; line-height: 1; margin: 16px 0 24px; max-width: 900px; color: var(--ink); }
.page-hero p { font-size: clamp(17px, 1.5vw, 20px); color: var(--ink-muted); max-width: 640px; line-height: 1.55; }
.page-hero p.page-direct-answer { font-size: clamp(18px, 1.6vw, 21px); color: var(--ink); font-weight: 500; max-width: 720px; line-height: 1.5; margin-bottom: 18px; padding-left: 18px; border-left: 3px solid var(--green); }

.reviewer-block { background: var(--paper-warm); border-radius: 12px; padding: 20px 24px; margin: 32px 0 16px; }
.reviewer-block p { margin-bottom: 0; font-size: 14px; color: var(--ink-soft); line-height: 1.5; }
.reviewer-block strong { color: var(--ink); display: block; margin-bottom: 6px; font-size: 13px; }

.legal-disclaimer { font-size: 12px; color: var(--ink-muted); font-style: normal; line-height: 1.5; padding-top: 16px; border-top: 1px solid var(--rule); margin-top: 12px; }

.prose { max-width: 720px; margin: 0 auto; font-size: 17px; line-height: 1.7; }
.prose p { margin-bottom: 22px; color: var(--ink-soft); }
.prose h2 { font-family: var(--font-display); font-weight: 800; font-size: 30px; letter-spacing: -0.025em; margin: 48px 0 18px; color: var(--ink); line-height: 1.15; }
.prose h3 { font-family: var(--font-display); font-weight: 700; font-size: 22px; margin: 32px 0 12px; color: var(--ink); letter-spacing: -0.02em; }
.prose ul { margin: 18px 0 22px 24px; color: var(--ink-soft); }
.prose li { margin-bottom: 10px; }
.prose strong { color: var(--ink); font-weight: 700; }

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--rule); padding: 24px 0; }
.faq-item summary { font-family: var(--font-display); font-weight: 700; font-size: 18px; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 20px; letter-spacing: -0.015em; color: var(--ink); }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-family: var(--font-display); font-size: 28px; font-weight: 400; color: var(--ink-muted); transition: transform 0.25s var(--ease); flex-shrink: 0; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-answer { margin-top: 14px; color: var(--ink-soft); line-height: 1.6; font-size: 16px; }

/* Spec */
.spec-table { width: 100%; border-collapse: collapse; margin: 24px 0; background: var(--white); border-radius: 12px; overflow: hidden; border: 1px solid var(--rule); }
.spec-table tr { border-bottom: 1px solid var(--rule); }
.spec-table tr:last-child { border-bottom: none; }
.spec-table td { padding: 16px 20px; font-size: 15px; color: var(--ink-soft); }
.spec-table td:first-child { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-muted); width: 40%; font-weight: 500; }

.next-cta { background: var(--paper-warm); border-radius: 16px; padding: 32px; margin: 40px 0; text-align: center; }
.next-cta h3 { font-family: var(--font-display); font-weight: 700; font-size: 24px; margin-bottom: 8px; letter-spacing: -0.02em; color: var(--ink); }
.next-cta p { color: var(--ink-muted); margin-bottom: 20px; }

/* Form */
.form { display: grid; gap: 20px; max-width: 560px; margin: 40px auto 0; }
.form label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-muted); margin-bottom: 6px; display: block; font-weight: 500; }
.form input, .form textarea, .form select { width: 100%; padding: 14px 18px; border: 1px solid var(--rule); border-radius: 10px; font-family: inherit; font-size: 16px; background: var(--white); color: var(--ink); transition: border-color 0.2s var(--ease); }
.form input:focus, .form textarea:focus, .form select:focus { outline: none; border-color: var(--ink); }
.form textarea { min-height: 120px; resize: vertical; }
