/* ==========================================================================
   LowerHOAFees.com — design tokens
   ========================================================================== */
:root {
  --cream: #FBF6EE;
  --sand: #F1E6D4;
  --line: #EADFCF;
  --ink: #2B2622;
  --muted: #6A5F55;
  --faint: #9A8E82;
  --terracotta: #C8643A;
  --terracotta-hover: #B3552E;
  --terracotta-dark: #7A4A2E;
  --terracotta-light: #F6D9CB;
  --teal: #2A7F82;
  --teal-light: #D3ECEC;
  --dark-card: #2B2622;
  --dark-input: #3A332E;
  --dark-border: #4A423C;
  --dark-muted: #C9BFB3;
  --bar-fill: #D9C7AC;
  --white: #fff;

  --gutter: clamp(20px, 5vw, 64px);
  --rhythm: clamp(64px, 8vw, 96px);
  --rhythm-sm: clamp(40px, 5vw, 64px);
  --card-pad: clamp(22px, 3vw, 32px);

  --serif: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --sans: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

/* ==========================================================================
   Reset & base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
a:hover { opacity: .8; }

img { max-width: 100%; display: block; }

input, select, button, textarea { font: inherit; box-sizing: border-box; }

:where(a, button, input, select, summary):focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}

h1, h2, h3, p, ol, ul { margin: 0; }

.shell {
  max-width: 1280px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--cream);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: var(--cream);
  padding: 12px 20px;
  border-radius: 0 0 12px 0;
  font-size: 14px;
  font-weight: 700;
}
.skip-link:focus { left: 0; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   1. Sticky nav
   ========================================================================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--gutter);
  background: rgba(251, 246, 238, .92);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.brand { display: flex; align-items: center; gap: 12px; }
.brand:hover { opacity: 1; }
.brand__mark {
  width: 82px;
  height: auto;
  flex: none;
}
.brand__name { font: 400 22px/1.2 var(--serif); color: var(--ink); }

@media (max-width: 420px) {
  .brand__mark { width: 60px; }
  .brand__name { font-size: 19px; }
}

.nav-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 15px;
  font-weight: 600;
  color: var(--muted);
}

.nav__cta {
  margin-left: auto;
  background: var(--terracotta);
  color: var(--white);
  font-weight: 700;
  font-size: 14px;
  padding: 12px 20px;
  border-radius: 999px;
  transition: background .15s ease;
}
.nav__cta:hover { background: var(--terracotta-hover); opacity: 1; }

@media (max-width: 760px) {
  .nav-links { display: none !important; }
}

/* ==========================================================================
   2. Hero
   ========================================================================== */
.hero {
  padding: clamp(40px, 6vw, 80px) var(--gutter);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  min-height: 640px;
  margin-bottom: var(--rhythm-sm);
  /* JPEG fallback first; browsers that understand image-set take the WebP. */
  background:
    linear-gradient(90deg, #FBF6EE 0%, #FBF6EE 30%, rgba(251,246,238,.85) 52%, rgba(251,246,238,.35) 72%, rgba(251,246,238,.15) 100%),
    url('/fable/assets/hero-community.jpg') right center / cover no-repeat;
  background:
    linear-gradient(90deg, #FBF6EE 0%, #FBF6EE 30%, rgba(251,246,238,.85) 52%, rgba(251,246,238,.35) 72%, rgba(251,246,238,.15) 100%),
    image-set(
      url('/fable/assets/hero-community.webp') type('image/webp') 1x,
      url('/fable/assets/hero-community@2x.webp') type('image/webp') 2x,
      url('/fable/assets/hero-community.jpg') type('image/jpeg') 1x,
      url('/fable/assets/hero-community@2x.jpg') type('image/jpeg') 2x
    ) right center / cover no-repeat;
}

.hero__panel {
  background: rgba(251, 246, 238, .82);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-radius: 24px;
  padding: clamp(16px, 2.5vw, 28px);
  margin: calc(-1 * clamp(16px, 2.5vw, 28px));
}

.hero h1 {
  margin: 0 0 24px;
  font: 400 clamp(40px, 5vw, 66px)/1.05 var(--serif);
  letter-spacing: -.01em;
  text-wrap: pretty;
}

.hero__lede {
  margin: 0 0 28px;
  font-size: 19px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 520px;
  text-wrap: pretty;
}

.chips { display: flex; gap: 10px; flex-wrap: wrap; list-style: none; padding: 0; margin: 0; }
.chip {
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--sand);
  font-size: 13px;
  font-weight: 700;
  color: var(--terracotta-dark);
}

/* ==========================================================================
   Lead form card
   ========================================================================== */
.form-card {
  background: var(--white);
  border-radius: 24px;
  padding: clamp(22px, 3vw, 36px);
  box-shadow: 0 20px 60px rgba(122, 74, 46, .12);
}

.form-card h2 { margin: 0 0 6px; font: 400 28px/1.15 var(--serif); }
.form-card__sub { margin: 0 0 24px; font-size: 15px; color: var(--muted); line-height: 1.5; }

.field-stack { display: grid; gap: 14px; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: 14px; }

.field { display: grid; gap: 6px; font-size: 13px; font-weight: 700; color: var(--muted); }

.field input,
.field select {
  padding: 13px 16px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 400;
  background: var(--cream);
  color: var(--ink);
  width: 100%;
}
.field input::placeholder { color: var(--faint); }

.field input[aria-invalid="true"],
.field select[aria-invalid="true"] { border-color: var(--terracotta); }

.field__error {
  font-size: 12px;
  font-weight: 700;
  color: var(--terracotta);
  min-height: 0;
}
.field__error:empty { display: none; }

.btn-primary {
  margin-top: 6px;
  padding: 15px;
  border: 0;
  border-radius: 999px;
  background: var(--terracotta);
  color: var(--white);
  font: 700 16px var(--sans);
  cursor: pointer;
  transition: background .15s ease;
}
.btn-primary:hover:not(:disabled) { background: var(--terracotta-hover); }
.btn-primary:disabled { opacity: .6; cursor: progress; }

.fineprint { margin: 0; font-size: 12px; color: var(--faint); text-align: center; }

.form-error {
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: #FBEAE3;
  color: var(--terracotta-dark);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}

/* honeypot */
.hp {
  position: absolute !important;
  left: -9999px;
  opacity: 0;
  height: 0;
  width: 0;
  pointer-events: none;
}

/* Step 2 */
.thanks h2 { margin: 0 0 8px; font: 400 28px/1.15 var(--serif); color: var(--teal); }
.thanks__body { margin: 0 0 22px; font-size: 15px; line-height: 1.55; color: var(--muted); }
.thanks__body strong { color: var(--ink); }

.btn-teal {
  display: block;
  text-align: center;
  padding: 14px;
  border-radius: 999px;
  background: var(--teal);
  color: var(--white);
  font-weight: 700;
  font-size: 15px;
}

.details__label { margin: 24px 0 12px; font-size: 13px; font-weight: 700; color: var(--muted); }
.details__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: 12px; }
.details__grid input,
.details__grid select {
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  background: var(--cream);
  color: var(--ink);
  width: 100%;
}
.details__grid input::placeholder { color: var(--faint); }
.span-all { grid-column: 1 / -1; }

.btn-outline {
  grid-column: 1 / -1;
  padding: 12px;
  border: 1.5px solid var(--terracotta);
  border-radius: 999px;
  background: var(--white);
  color: var(--terracotta);
  font: 700 14px var(--sans);
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.btn-outline:hover:not(:disabled) { background: var(--terracotta); color: var(--white); }
.btn-outline:disabled { opacity: .6; cursor: progress; }

.received { margin: 20px 0 0; font-size: 14px; color: var(--teal); font-weight: 700; }

[hidden] { display: none !important; }

/* ==========================================================================
   3. Win/win band
   ========================================================================== */
.band {
  margin: 0 var(--gutter);
  padding: clamp(22px, 3vw, 32px) clamp(22px, 3vw, 36px);
  background: var(--teal);
  color: var(--white);
  border-radius: 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: clamp(12px, 2vw, 32px);
  align-items: center;
}
.band__head { margin: 0; font: 400 28px/1.2 var(--serif); }
.band__body { margin: 0; font-size: 15px; line-height: 1.55; color: var(--teal-light); }

/* ==========================================================================
   4. How it works
   ========================================================================== */
.how {
  padding: var(--rhythm) var(--gutter) var(--rhythm-sm);
  text-align: center;
}
.section-h2 { margin: 0 0 12px; font: 400 clamp(32px, 3.5vw, 44px)/1.1 var(--serif); }
.how__sub { margin: 0 auto clamp(32px, 4vw, 48px); font-size: 17px; color: var(--muted); max-width: 520px; }

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 20px;
  text-align: left;
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: step;
}
.step {
  padding: var(--card-pad);
  background: var(--white);
  border-radius: 20px;
}
.step__num {
  display: inline-grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--sand);
  color: var(--terracotta);
  font: 400 22px var(--serif);
  margin-bottom: 20px;
}
.step h3 { margin: 0 0 8px; font-size: 20px; font-weight: 700; }
.step p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ==========================================================================
   5. Why fees creep up
   ========================================================================== */
.why {
  padding: var(--rhythm-sm) var(--gutter) var(--rhythm);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}
.why__body { margin: 0 0 16px; font-size: 17px; line-height: 1.6; color: var(--muted); }
.why__body:last-child { margin-bottom: 0; }
.why .section-h2 { margin-bottom: 20px; }

.breakdown {
  background: var(--white);
  border-radius: 20px;
  padding: var(--card-pad);
}
.breakdown h3 { margin: 0 0 4px; font: 400 22px/1.2 var(--serif); }
.breakdown__note { margin: 0 0 22px; font-size: 13px; color: var(--faint); }

.bars { display: grid; gap: 12px; font-size: 15px; }
.bar-row {
  display: grid;
  grid-template-columns: minmax(110px, 150px) 1fr auto;
  gap: 12px;
  align-items: center;
}
.bar-track {
  height: 12px;
  background: var(--sand);
  border-radius: 6px;
  overflow: hidden;
}
.bar-fill { display: block; height: 100%; background: var(--bar-fill); }
.bar-tag { font-size: 12px; color: var(--faint); }

.bar-row--focus .bar-label { font-weight: 700; color: var(--terracotta); }
.bar-row--focus .bar-fill { background: var(--terracotta); }
.bar-row--focus .bar-tag { color: var(--terracotta); font-weight: 700; }

.breakdown__foot { margin: 22px 0 0; font-size: 14px; color: var(--muted); line-height: 1.5; }

/* ==========================================================================
   6. Savings calculator
   ========================================================================== */
.calc {
  margin: 0 var(--gutter);
  padding: clamp(24px, 4vw, 56px);
  background: var(--dark-card);
  color: var(--cream);
  border-radius: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
}
.calc h2 { margin: 0 0 14px; font: 400 clamp(30px, 3.2vw, 40px)/1.1 var(--serif); }
.calc__sub { margin: 0 0 28px; font-size: 16px; line-height: 1.55; color: var(--dark-muted); }
.calc__inputs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); gap: 16px; }
.calc__inputs .field { color: var(--dark-muted); }
.calc__inputs input {
  padding: 13px 16px;
  border: 1.5px solid var(--dark-border);
  border-radius: 12px;
  font-size: 17px;
  background: var(--dark-input);
  color: var(--cream);
}

.calc__result {
  background: var(--cream);
  color: var(--ink);
  border-radius: 20px;
  padding: clamp(22px, 3vw, 36px);
}
.calc__label { margin: 0 0 6px; font-size: 13px; font-weight: 700; color: var(--muted); }
.calc__range {
  margin: 0 0 24px;
  font: 400 clamp(34px, 4vw, 50px)/1 var(--serif);
  color: var(--teal);
}
.calc__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr));
  gap: 16px;
  padding-top: 22px;
  border-top: 1.5px solid var(--line);
}
.calc__stat-label { margin: 0 0 2px; font-size: 12px; color: var(--faint); }
.calc__stat-value { margin: 0; font-size: 22px; font-weight: 700; }

/* ==========================================================================
   7. Proof
   ========================================================================== */
.proof {
  padding: var(--rhythm) var(--gutter);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.proof__cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 20px;
}
.stat-card { padding: 28px; background: var(--white); border-radius: 20px; }
.stat-card__label { margin: 0 0 6px; font-size: 13px; font-weight: 700; color: var(--faint); }
.stat-card__was { margin: 0 0 4px; font-size: 15px; color: var(--faint); text-decoration: line-through; }
.stat-card__now { margin: 0; font: 400 40px/1 var(--serif); color: var(--teal); }
.stat-card__note { margin: 10px 0 0; font-size: 13px; color: var(--muted); }

.stat-card--wide {
  grid-column: 1 / -1;
  padding: 28px;
  background: var(--terracotta);
  color: var(--white);
  border-radius: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.stat-card--wide .stat-card__label { margin: 0 0 4px; color: var(--terracotta-light); }
.stat-card--wide .stat-card__now { margin: 0; font: 400 40px/1 var(--serif); color: var(--white); }
.stat-card--wide .stat-card__aside {
  margin: 0;
  font-size: 14px;
  max-width: 220px;
  line-height: 1.5;
  color: var(--terracotta-light);
}

.eyebrow {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--terracotta);
}
.proof__copy .section-h2 { margin-bottom: 20px; }
.proof__copy p:last-child { font-size: 17px; line-height: 1.6; color: var(--muted); }

/* ==========================================================================
   8. Checklist
   ========================================================================== */
.checklist {
  margin: 0 var(--gutter);
  padding: clamp(24px, 4vw, 56px);
  background: var(--white);
  border-radius: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: clamp(24px, 4vw, 56px);
}
.checklist h2 { margin: 0 0 16px; font: 400 clamp(28px, 3vw, 36px)/1.1 var(--serif); }
.checklist__intro { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }
.checklist ol {
  margin: 0; padding: 0;
  list-style: none;
  display: grid;
  gap: 14px;
  font-size: 15px;
  line-height: 1.5;
}
.checklist li { display: flex; gap: 14px; }
.checklist li::before {
  content: "";
  flex: none;
  width: 24px; height: 24px;
  border: 2px solid var(--teal);
  border-radius: 50%;
}

/* ==========================================================================
   9. FAQ
   ========================================================================== */
.faq {
  padding: var(--rhythm) var(--gutter);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: clamp(24px, 4vw, 56px);
}
.faq .section-h2 { margin: 0; }
.faq__item { padding: 24px 0; border-top: 1.5px solid var(--line); }
.faq__item:last-child { border-bottom: 1.5px solid var(--line); }
.faq__item h3 { margin: 0 0 8px; font-size: 18px; font-weight: 700; }
.faq__item p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ==========================================================================
   10. Partner CTA
   ========================================================================== */
.partner {
  margin: 0 var(--gutter) var(--rhythm);
  padding: clamp(24px, 4vw, 48px) clamp(24px, 4vw, 56px);
  background: var(--sand);
  border-radius: 28px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.partner h2 { margin: 0 0 8px; font: 400 clamp(24px, 2.6vw, 30px)/1.15 var(--serif); max-width: 640px; }
.partner__sub { margin: 0; font-size: 15px; color: var(--muted); }
.partner__cta {
  flex: none;
  background: var(--ink);
  color: var(--cream);
  font-weight: 700;
  font-size: 14px;
  padding: 14px 22px;
  border-radius: 999px;
}

/* ==========================================================================
   11. Footer
   ========================================================================== */
.footer {
  padding: 32px var(--gutter);
  border-top: 1.5px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
}
.footer__left { display: flex; gap: 24px; flex-wrap: wrap; align-items: center; }
.footer__logo { width: 124px; height: auto; flex: none; }
.footer a:hover { opacity: .8; }
