/* =========================================================
   CompareHomez.com — design tokens
   Palette pulled from the brand mark: deep navy roofline + green roofline.
   Type: Space Grotesk (display, geometric, a little technical — fits
   a "compare/quote" tool) paired with Inter (body, quiet workhorse).
   Signature element: the 3-step "Compare → Quote → Hire" rail, which
   mirrors the tagline and is a genuine sequence, not decoration.
   ========================================================= */

:root {
  --navy-deep: #071A36;
  --navy: #0B2A52;
  --navy-soft: #1B3E6B;
  --green: #55AE22;
  --green-light: #8FD457;
  --green-pale: #EAF6E1;
  --bg: #F5F8FC;
  --paper: #FFFFFF;
  --ink: #101826;
  --ink-soft: #4B5A70;
  --line: #E1E7F0;
  --amber: #E8A93A;

  --font-display: "Space Grotesk", "Segoe UI", sans-serif;
  --font-body: "Inter", "Segoe UI", sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(7, 26, 54, 0.06), 0 1px 1px rgba(7, 26, 54, 0.04);
  --shadow-md: 0 8px 24px rgba(7, 26, 54, 0.10);
  --shadow-lg: 0 24px 60px rgba(7, 26, 54, 0.16);
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--navy-deep);
  line-height: 1.12;
  margin: 0 0 .5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.15rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
p  { margin: 0 0 1em; color: var(--ink-soft); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-display); font-size: .78rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; color: var(--green);
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 18px; height: 2px; background: var(--green); display: inline-block; }

section { padding: 64px 0; }
.section-tight { padding: 40px 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-display); font-weight: 600; font-size: .96rem;
  padding: 13px 26px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--green); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #4B9A1C; box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; border-color: rgba(255,255,255,.35); color: #fff; }
.btn-outline:hover { border-color: #fff; }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-deep); }
.btn-block { width: 100%; }
.btn-sm { padding: 9px 18px; font-size: .85rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 78px; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand img { height: 42px; width: auto; }
.main-nav { display: flex; align-items: center; gap: 28px; }
.main-nav a {
  font-size: .93rem; font-weight: 600; color: var(--navy);
  position: relative; padding: 6px 0;
}
.main-nav a:hover { color: var(--green); }
.header-cta { display: flex; align-items: center; gap: 14px; }
.header-phone { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--navy); font-size: .95rem; text-decoration: none; }
.header-phone:hover { color: var(--green); }
.header-phone svg { width: 18px; height: 18px; stroke: var(--green); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--navy); margin: 5px 0; }

/* Dropdown */
.has-dropdown { position: relative; }
.dropdown {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg); padding: 10px; display: grid; grid-template-columns: 1fr 1fr;
  gap: 2px; width: 460px; opacity: 0; visibility: hidden; translate: 0 8px;
  transition: all .15s ease; margin-top: 14px;
}
.has-dropdown:hover .dropdown { opacity: 1; visibility: visible; translate: 0 0; }
.dropdown a { padding: 9px 12px; border-radius: 8px; font-weight: 500; font-size: .88rem; color: var(--ink); }
.dropdown a:hover { background: var(--green-pale); color: var(--navy); }

/* ---------- Hero ---------- */
.hero {
  background: radial-gradient(ellipse 900px 500px at 15% -10%, rgba(85,174,34,.16), transparent 60%),
              linear-gradient(180deg, var(--navy-deep) 0%, var(--navy) 100%);
  color: #fff; padding: 84px 0 0; position: relative; overflow: hidden;
}
.hero .container { position: relative; z-index: 2; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; padding-bottom: 56px; }
.hero h1 { color: #fff; }
.hero h1 span { color: var(--green-light); }
.hero-sub { color: #C6D3E6; font-size: 1.1rem; max-width: 46ch; }
.hero-stats { display: flex; gap: 32px; margin-top: 32px; }
.hero-stats div strong { display: block; font-family: var(--font-display); font-size: 1.7rem; color: #fff; }
.hero-stats div span { font-size: .82rem; color: #9FB2CC; }

.search-card {
  background: #fff; border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-lg);
  color: var(--ink);
}
.search-card h3 { margin-bottom: 4px; }
.search-card .sub { font-size: .85rem; color: var(--ink-soft); margin-bottom: 16px; }
.search-form { display: flex; flex-direction: column; gap: 12px; }
.field label { display: block; font-size: .78rem; font-weight: 700; color: var(--navy); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .04em; }
.field select, .field input {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: .95rem; background: #fbfcfe;
}
.field select:focus, .field input:focus { outline: none; border-color: var(--green); background: #fff; }
.search-trust { display: flex; align-items: center; gap: 8px; font-size: .78rem; color: var(--ink-soft); margin-top: 10px; }
.search-trust svg { width: 16px; height: 16px; stroke: var(--green); flex-shrink: 0; }

.hero-strip {
  border-top: 1px solid rgba(255,255,255,.12); padding: 20px 0;
  display: flex; gap: 40px; align-items: center; flex-wrap: wrap;
  font-size: .82rem; color: #9FB2CC; font-weight: 600; letter-spacing: .02em;
}
.hero-strip span { color: #fff; }

/* ---------- Process rail (signature element) ---------- */
.process { background: var(--paper); }
.process-rail { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: 40px; position: relative; }
.process-rail::before {
  content: ""; position: absolute; top: 34px; left: 12%; right: 12%; height: 2px;
  background: repeating-linear-gradient(90deg, var(--line) 0 10px, transparent 10px 18px);
  z-index: 0;
}
.process-step { position: relative; z-index: 1; padding: 0 24px; text-align: left; }
.process-num {
  width: 68px; height: 68px; border-radius: 50%; background: var(--navy); color: #fff;
  display: flex; align-items: center; justify-content: center; font-family: var(--font-display);
  font-size: 1.5rem; font-weight: 700; margin-bottom: 20px; box-shadow: var(--shadow-md);
}
.process-step:nth-child(2) .process-num { background: var(--green); }
.process-step:nth-child(3) .process-num { background: var(--amber); }
.process-step p { font-size: .95rem; }

/* ---------- Category grid ---------- */
.cat-section { background: var(--bg); }
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 40px; }
.cat-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: transparent; }
.cat-icon {
  width: 48px; height: 48px; border-radius: 12px; background: var(--green-pale); color: var(--navy);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.cat-icon svg { width: 26px; height: 26px; }
.cat-card h3 { margin-bottom: 6px; }
.cat-card p { font-size: .87rem; margin-bottom: 12px; }
.cat-card .cat-link { font-size: .85rem; font-weight: 700; color: var(--green); display: inline-flex; align-items: center; gap: 6px; }
.cat-card .cat-link svg { width: 14px; height: 14px; stroke: var(--green); transition: translate .15s ease; }
.cat-card:hover .cat-link svg { translate: 3px 0; }

/* ---------- Trust / why ---------- */
.trust-band { background: var(--navy-deep); color: #fff; }
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-top: 40px; }
.trust-item svg { width: 30px; height: 30px; stroke: var(--green-light); margin-bottom: 14px; }
.trust-item h3 { color: #fff; }
.trust-item p { color: #A9B9D0; }

/* ---------- Comparison keyword band ---------- */
.compare-band { background: var(--paper); }
.compare-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 32px; }
.compare-pill {
  border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 20px;
  display: flex; align-items: flex-start; gap: 12px; background: var(--bg);
}
.compare-pill svg { width: 20px; height: 20px; stroke: var(--green); flex-shrink: 0; margin-top: 2px; }
.compare-pill strong { display: block; font-family: var(--font-display); font-size: .96rem; color: var(--navy); margin-bottom: 3px; }
.compare-pill span { font-size: .85rem; color: var(--ink-soft); }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--green) 0%, #3F8C17 100%);
  color: #fff; text-align: center; border-radius: var(--radius); padding: 56px 32px; margin: 0 24px;
}
.cta-band h2 { color: #fff; margin-bottom: 10px; }
.cta-band p { color: rgba(255,255,255,.9); max-width: 50ch; margin: 0 auto 26px; }
.cta-band .btn-primary { background: #fff; color: var(--navy); }
.cta-band .btn-primary:hover { background: #F0F4FA; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: #A9B9D0; padding: 64px 0 24px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 32px; }
.footer-brand img { height: 36px; margin-bottom: 14px; }
.footer-brand p { font-size: .86rem; color: #8296B4; max-width: 32ch; }
.footer-col h4 { color: #fff; font-size: .82rem; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 16px; }
.footer-col a { display: block; font-size: .87rem; color: #A9B9D0; padding: 5px 0; }
.footer-col a:hover { color: var(--green-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08); margin-top: 44px; padding-top: 24px;
  display: flex; justify-content: space-between; align-items: center; font-size: .8rem; color: #6D80A0; flex-wrap: wrap; gap: 12px;
}
.footer-keywords { padding-top: 18px; font-size: .78rem; color: #5A6D8C; line-height: 1.9; }
.footer-keywords a { color: #7A8CAA; margin-right: 4px; }
.footer-keywords a:hover { color: var(--green-light); }

/* ---------- Category page ---------- */
.page-hero { background: var(--navy); color: #fff; padding: 52px 0; }
.breadcrumb { font-size: .82rem; color: #9FB2CC; margin-bottom: 16px; }
.breadcrumb a { color: #C6D3E6; } .breadcrumb a:hover { color: #fff; }
.page-hero h1 { color: #fff; max-width: 24ch; }
.page-hero .hero-sub { color: #C6D3E6; }

.layout-2col { display: grid; grid-template-columns: 1fr 340px; gap: 44px; align-items: start; }
.service-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 24px 0 36px; }
.service-list li {
  display: flex; align-items: center; gap: 10px; background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 12px 14px; font-size: .9rem; font-weight: 600; color: var(--navy);
}
.service-list svg { width: 16px; height: 16px; stroke: var(--green); flex-shrink: 0; }

.faq-item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq-item h3 { margin-bottom: 8px; font-size: 1.02rem; }
.faq-item p { margin: 0; }

.sidebar-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow-sm); position: sticky; top: 100px;
}
.sidebar-card h3 { margin-bottom: 4px; }
.sidebar-card .sub { font-size: .85rem; color: var(--ink-soft); margin-bottom: 16px; }

.other-cats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.other-cats a {
  font-size: .82rem; font-weight: 600; color: var(--navy); background: var(--bg);
  border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px;
}
.other-cats a:hover { border-color: var(--green); color: var(--green); }

/* ---------- Form pages ---------- */
.form-page { padding: 60px 0 90px; }
.form-shell { max-width: 640px; margin: 0 auto; background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 40px; box-shadow: var(--shadow-md); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.form-shell .field { margin-bottom: 14px; }
.form-note { font-size: .8rem; color: var(--ink-soft); margin-top: 14px; text-align: center; }

.alert-success {
  background: var(--green-pale); border: 1px solid #C7E7AE; color: #2C5A0F;
  border-radius: var(--radius-sm); padding: 16px 20px; font-weight: 600; margin-bottom: 20px;
}
.alert-error {
  background: #FDECEC; border: 1px solid #F5C2C2; color: #8A2A2A;
  border-radius: var(--radius-sm); padding: 16px 20px; font-weight: 600; margin-bottom: 20px;
}

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.section-head { max-width: 620px; margin-bottom: 8px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .layout-2col { grid-template-columns: 1fr; }
  .sidebar-card { position: static; }
  .trust-grid { grid-template-columns: 1fr; }
  .process-rail { grid-template-columns: 1fr; gap: 28px; }
  .process-rail::before { display: none; }
}
@media (max-width: 720px) {
  .main-nav, .header-phone { display: none; }
  .nav-toggle { display: block; }
  .cat-grid { grid-template-columns: 1fr; }
  .service-list { grid-template-columns: 1fr; }
  .compare-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-wrap: wrap; row-gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}