/* ============================================================
   QualifyHomes.com — Warm & Hopeful design system
   Hand-built, no framework. Bricolage Grotesque (display) +
   Hanken Grotesk (body/UI). Self-hosted woff2, latin subset.
   ============================================================ */

/* ---------- Fonts ---------- */
@font-face { font-family: 'Bricolage Grotesque'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/bricolage-grotesque-600.woff2) format('woff2'); }
@font-face { font-family: 'Bricolage Grotesque'; font-style: normal; font-weight: 700; font-display: swap; src: url(/fonts/bricolage-grotesque-700.woff2) format('woff2'); }
@font-face { font-family: 'Bricolage Grotesque'; font-style: normal; font-weight: 800; font-display: swap; src: url(/fonts/bricolage-grotesque-800.woff2) format('woff2'); }
@font-face { font-family: 'Hanken Grotesk'; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/hanken-grotesk-400.woff2) format('woff2'); }
@font-face { font-family: 'Hanken Grotesk'; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/hanken-grotesk-500.woff2) format('woff2'); }
@font-face { font-family: 'Hanken Grotesk'; font-style: normal; font-weight: 600; font-display: swap; src: url(/fonts/hanken-grotesk-600.woff2) format('woff2'); }
@font-face { font-family: 'Hanken Grotesk'; font-style: normal; font-weight: 700; font-display: swap; src: url(/fonts/hanken-grotesk-700.woff2) format('woff2'); }

/* ---------- Tokens ---------- */
:root {
  --paper:      #FBF7EF;   /* warm cream page */
  --paper-2:    #F4ECDD;   /* deeper sand, alternating sections */
  --paper-3:    #EFE5D2;
  --card:       #FFFFFF;
  --ink:        #25221C;   /* warm near-black */
  --ink-soft:   #57503F;
  --ink-faint:  #8C8470;

  --green:      #1F8A6B;   /* homestead green — primary action */
  --green-deep: #14654E;
  --green-dark: #0F4D3B;
  --green-tint: #E6F1EB;
  --green-tint-2:#D3E7DC;

  --amber:      #E0913B;   /* warm secondary / highlight */
  --amber-soft: #F7E2C4;
  --clay:       #C75D43;   /* warm accent for small marks */

  --line:       #E8DEC9;
  --line-soft:  #F0E8D8;

  --display: 'Bricolage Grotesque', 'Hanken Grotesk', system-ui, sans-serif;
  --sans:    'Hanken Grotesk', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;

  --radius:    20px;
  --radius-sm: 13px;
  --radius-pill: 999px;

  --shadow:     0 22px 50px -26px rgba(37,34,28,0.30), 0 2px 6px -2px rgba(37,34,28,0.06);
  --shadow-sm:  0 10px 28px -18px rgba(37,34,28,0.28);
  --shadow-green: 0 16px 34px -16px rgba(31,138,107,0.55);

  --maxw: 1140px;
  --pad: 40px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green-deep); text-decoration: none; }
a:hover { color: var(--green-dark); }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; line-height: 1.08; color: var(--ink); margin: 0 0 .5em; letter-spacing: -0.015em; }
p { margin: 0 0 1.1em; }
ul { margin: 0 0 1.1em; padding-left: 1.2em; }
strong { font-weight: 700; }
::selection { background: var(--green-tint-2); }

/* ---------- Layout ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad); }
.wrap-narrow { max-width: 760px; }
section { padding: 92px 0; }
.section-tint { background: var(--paper-2); }
.eyebrow {
  font-family: var(--sans); font-weight: 700; font-size: 13px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--green-deep); margin: 0 0 14px;
  display: inline-flex; align-items: center; gap: 8px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--amber); border-radius: 2px; }
.section-head { max-width: 680px; margin-bottom: 52px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow::before { display: none; }
h2 { font-size: clamp(30px, 4vw, 46px); }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--ink-soft); line-height: 1.6; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,247,239,0.86);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 74px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-family: var(--display); font-weight: 800; font-size: 21px; color: var(--ink); letter-spacing: -0.02em; }
.brand:hover { color: var(--ink); }
/* "Qualify" and "Homes" are separate flex items; the 11px flex gap reads as a
   word space. Pull "Homes" back so the wordmark tightens to a near-single word. */
.brand span:not(.brand-mark) { margin-left: -8px; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 9px;
  background: var(--green); color: #fff; display: grid; place-items: center;
  box-shadow: var(--shadow-green);
}
.brand-mark svg { width: 18px; height: 18px; }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { color: var(--ink-soft); font-weight: 600; font-size: 15.5px; }
.nav-links a:hover { color: var(--green-deep); }
.nav-cta { margin-left: 6px; }
/* CTA button in nav must stay white — beat the .nav-links a color rules */
.nav-links a.nav-cta, .nav-links a.nav-cta:hover { color: #fff; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--ink); }
.nav-toggle svg { width: 26px; height: 26px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--sans); font-weight: 700; font-size: 16px; line-height: 1;
  padding: 16px 28px; border-radius: var(--radius-pill); border: 0; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
  text-align: center; white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--green); color: #fff; box-shadow: var(--shadow-green); }
.btn-primary:hover { background: var(--green-deep); color: #fff; transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { background: var(--card); color: var(--ink); border-color: var(--ink-faint); transform: translateY(-2px); }
.btn-lg { padding: 19px 34px; font-size: 17.5px; }
.btn-block { display: flex; width: 100%; }

/* ---------- Hero ---------- */
.hero { padding: 64px 0 80px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 60px; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 9px; background: var(--green-tint);
  color: var(--green-dark); font-weight: 700; font-size: 14px; padding: 8px 15px;
  border-radius: var(--radius-pill); margin-bottom: 22px; border: 1px solid var(--green-tint-2);
}
.hero-badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.hero h1 { font-size: clamp(38px, 5.4vw, 62px); font-weight: 800; margin-bottom: 22px; }
.hero h1 .hl { color: var(--green-deep); position: relative; white-space: nowrap; }
.hero h1 .hl::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 12px;
  background: var(--amber-soft); z-index: -1; border-radius: 4px;
}
.hero .lead { margin-bottom: 32px; max-width: 520px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-note { font-size: 14.5px; color: var(--ink-faint); margin: 18px 0 0; display: flex; align-items: center; gap: 8px; }
.hero-note svg { width: 17px; height: 17px; color: var(--green); flex: none; }

/* Hero visual card */
.hero-visual { position: relative; }
.hero-photo {
  border-radius: 26px; overflow: hidden; box-shadow: var(--shadow);
  aspect-ratio: 4 / 4.4; background: var(--paper-3);
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-float {
  position: absolute; left: -26px; bottom: 34px; background: var(--card);
  border-radius: var(--radius-sm); padding: 16px 18px; box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 13px; border: 1px solid var(--line-soft);
}
.hero-float .ico { width: 40px; height: 40px; border-radius: 11px; background: var(--green-tint); color: var(--green-deep); display: grid; place-items: center; flex: none; }
.hero-float .ico svg { width: 22px; height: 22px; }
.hero-float strong { display: block; font-family: var(--display); font-size: 17px; }
.hero-float span { font-size: 13.5px; color: var(--ink-faint); }

/* decorative blobs */
.blob { position: absolute; border-radius: 50%; filter: blur(8px); opacity: .5; z-index: 0; pointer-events: none; }

/* ---------- Stats strip ---------- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.stat { text-align: center; padding: 8px; }
.stat .num { font-family: var(--display); font-weight: 800; font-size: clamp(34px, 4.6vw, 52px); color: var(--green-deep); line-height: 1; letter-spacing: -0.02em; }
.stat .label { font-weight: 600; color: var(--ink-soft); margin-top: 10px; font-size: 15.5px; }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.step {
  background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: 34px 30px 30px; box-shadow: var(--shadow-sm); position: relative;
}
.step-num {
  font-family: var(--display); font-weight: 800; font-size: 15px; color: #fff;
  width: 38px; height: 38px; border-radius: 11px; background: var(--green);
  display: grid; place-items: center; margin-bottom: 20px;
}
.step h3 { font-size: 22px; margin-bottom: 10px; }
.step p { margin: 0; color: var(--ink-soft); font-size: 16.5px; }

/* ---------- Benefits ---------- */
.benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.benefit {
  background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: 28px 26px; box-shadow: var(--shadow-sm);
}
.benefit .ico { width: 46px; height: 46px; border-radius: 13px; background: var(--green-tint); color: var(--green-deep); display: grid; place-items: center; margin-bottom: 16px; }
.benefit .ico svg { width: 24px; height: 24px; }
.benefit h3 { font-size: 19px; margin-bottom: 7px; }
.benefit p { margin: 0; color: var(--ink-soft); font-size: 16px; }

/* ---------- Who it's for ---------- */
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.checklist li { display: flex; gap: 13px; align-items: flex-start; font-size: 17.5px; color: var(--ink-soft); }
.checklist .tick { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--green-tint); color: var(--green-deep); display: grid; place-items: center; margin-top: 2px; }
.checklist .tick svg { width: 15px; height: 15px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.media-card { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 1/0.82; background: var(--paper-3); }
.media-card img { width:100%; height:100%; object-fit: cover; }

/* ---------- Testimonial ---------- */
.quote-card {
  background: var(--green-dark); color: #F3EFE6; border-radius: 26px;
  padding: 56px clamp(28px, 5vw, 64px); position: relative; overflow: hidden;
}
.quote-card .mark { font-family: var(--display); font-size: 120px; line-height: .6; color: rgba(255,255,255,.14); position: absolute; top: 28px; right: 40px; }
.quote-card blockquote { margin: 0; font-family: var(--display); font-weight: 600; font-size: clamp(20px, 2.5vw, 27px); line-height: 1.4; letter-spacing: -0.01em; position: relative; }
.quote-card .byline { margin-top: 26px; display: flex; align-items: center; gap: 14px; }
.quote-card .avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--amber); color: var(--green-dark); display: grid; place-items: center; font-family: var(--display); font-weight: 800; font-size: 19px; }
.quote-card .who strong { display: block; color: #fff; font-size: 16px; }
.quote-card .who span { color: rgba(243,239,230,.7); font-size: 14px; }

/* ---------- FAQ accordion ---------- */
.faq-list { display: grid; gap: 14px; max-width: 820px; margin: 0 auto; }
.faq-item { background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); overflow: hidden; }
.faq-item > summary {
  list-style: none; cursor: pointer; padding: 22px 26px; font-family: var(--display);
  font-weight: 700; font-size: 18.5px; color: var(--ink); display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary .chev { flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--green-tint); color: var(--green-deep); display: grid; place-items: center; transition: transform .2s ease; }
.faq-item[open] > summary .chev { transform: rotate(45deg); }
.faq-item .faq-body { padding: 0 26px 24px; color: var(--ink-soft); font-size: 16.5px; }
.faq-item .faq-body p:last-child { margin-bottom: 0; }

/* ---------- Form ---------- */
.form-card {
  background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: clamp(28px, 4vw, 44px); box-shadow: var(--shadow);
}
.signup-form .field { margin-bottom: 16px; }
.signup-form label { display: block; font-weight: 600; font-size: 14.5px; margin-bottom: 7px; color: var(--ink); }
.signup-form input, .signup-form select {
  width: 100%; font-family: var(--sans); font-size: 16.5px; color: var(--ink);
  padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 13px; background: var(--paper);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.signup-form input:focus, .signup-form select:focus { outline: 0; border-color: var(--green); box-shadow: 0 0 0 4px var(--green-tint); background: #fff; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-fine { font-size: 13px; color: var(--ink-faint); margin: 14px 0 0; text-align: center; }
.placeholder-flag {
  background: var(--amber-soft); border: 1px dashed var(--amber); color: #8a5a17;
  font-size: 13px; font-weight: 600; padding: 9px 13px; border-radius: 10px; margin-bottom: 18px;
}

/* ---------- CTA band ---------- */
.cta-band { background: var(--green-dark); color: #F3EFE6; border-radius: 28px; padding: clamp(40px, 6vw, 72px); text-align: center; position: relative; overflow: hidden; }
.cta-band h2 { color: #fff; }
.cta-band .lead { color: rgba(243,239,230,.82); margin-bottom: 30px; max-width: 600px; margin-left: auto; margin-right: auto; }
.cta-band .btn-primary { background: var(--amber); color: var(--green-dark); box-shadow: 0 16px 34px -16px rgba(224,145,59,.7); }
.cta-band .btn-primary:hover { background: #f0a24c; color: var(--green-dark); }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #CFC8B8; padding: 64px 0 34px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; margin-bottom: 44px; }
.site-footer .brand { color: #fff; margin-bottom: 14px; }
.site-footer p { color: #A9A192; font-size: 15.5px; max-width: 340px; }
.footer-col h4 { color: #fff; font-family: var(--sans); font-size: 14px; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px; }
.footer-col a { display: block; color: #CFC8B8; margin-bottom: 11px; font-size: 15.5px; }
.footer-col a:hover { color: #fff; }
.footer-legal { border-top: 1px solid rgba(255,255,255,.1); padding-top: 26px; font-size: 13px; color: #8C8470; line-height: 1.6; }
.footer-legal .row { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 12px; }

/* ---------- Article / blog ---------- */
.post-hero { padding: 56px 0 30px; }
.post-meta { font-size: 14.5px; color: var(--ink-faint); font-weight: 600; margin-bottom: 14px; }
.post-meta a { color: var(--green-deep); }
.post-title { font-size: clamp(30px, 4.5vw, 50px); font-weight: 800; max-width: 16ch; }
.article { font-size: 18.5px; line-height: 1.75; color: var(--ink-soft); }
.article h2 { font-size: clamp(25px, 3vw, 33px); margin: 1.6em 0 .5em; color: var(--ink); }
.article h3 { font-size: 21px; margin: 1.4em 0 .4em; color: var(--ink); }
.article p, .article ul, .article ol { margin-bottom: 1.15em; }
.article ul li, .article ol li { margin-bottom: .5em; }
.article strong { color: var(--ink); }
.article a { text-decoration: underline; text-underline-offset: 2px; }
.article blockquote { margin: 1.6em 0; padding: 4px 0 4px 24px; border-left: 4px solid var(--green); font-family: var(--display); font-size: 22px; color: var(--ink); font-weight: 600; }
.callout { background: var(--green-tint); border: 1px solid var(--green-tint-2); border-radius: var(--radius-sm); padding: 22px 26px; margin: 1.8em 0; }
.callout p:last-child { margin-bottom: 0; }
.back-link { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; font-size: 15px; color: var(--ink-soft); }
.back-link:hover { color: var(--green-deep); }

/* blog index cards */
.post-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.post-card { background: var(--card); border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 30px 28px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; transition: transform .15s ease, box-shadow .2s ease; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.post-card .tag { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--green-deep); margin-bottom: 12px; }
.post-card h3 { font-size: 22px; margin-bottom: 10px; color: var(--ink); }
.post-card p { color: var(--ink-soft); font-size: 16px; margin-bottom: 18px; flex: 1; }
.post-card .more { font-weight: 700; color: var(--green-deep); font-size: 15px; display: inline-flex; align-items: center; gap: 6px; }

/* ---------- Misc ---------- */
.center { text-align: center; }
/* Centered headings: center the eyebrow (no leading dash) and the lead block */
.center .eyebrow { justify-content: center; }
.center .eyebrow::before { display: none; }
.center .lead { margin-left: auto; margin-right: auto; }
.mt-l { margin-top: 40px; }
.disclaimer-note { font-size: 13px; color: var(--ink-faint); max-width: 760px; margin: 36px auto 0; text-align: center; line-height: 1.6; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  :root { --pad: 26px; }
  section { padding: 68px 0; }
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero-visual { max-width: 460px; }
  .split { grid-template-columns: 1fr; gap: 36px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  body { font-size: 17px; }
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column; align-items: stretch; gap: 6px;
    position: absolute; top: 74px; left: 0; right: 0; background: var(--paper);
    padding: 16px var(--pad) 24px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-sm);
  }
  .nav-links.open a { padding: 10px 0; font-size: 17px; }
  .nav-links.open .nav-cta { margin: 8px 0 0; }
  .nav-toggle { display: inline-flex; }
  .steps, .benefits { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; gap: 30px; }
  .form-row { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-float { left: 0; }
}
