/* Funding Finder — interactive pick-and-choose on the homepage */
.finder { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.finder .wrap { padding-top: 88px; padding-bottom: 88px; }
.finder-head { text-align: center; max-width: 720px; margin: 0 auto; }
.finder-head h2 { font-family: var(--serif); font-size: var(--fs-h2); line-height: 1.1; font-weight: 600; color: var(--ink); margin-top: 10px; text-wrap: balance; }
.finder-head p { color: var(--body); font-size: 17px; margin-top: 14px; }

.finder-shell { display: grid; grid-template-columns: 1fr 300px; gap: 28px; margin-top: 44px; align-items: start; }
.finder-main { background: var(--white); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); padding: 36px 40px 32px; min-height: 520px; display: flex; flex-direction: column; }

.f-progress { display: flex; gap: 8px; }
.f-progress i { flex: 1; height: 6px; border-radius: 99px; background: var(--line); transition: background .3s; }
.f-progress i.on { background: var(--berry); }
.f-count { font-size: 13px; color: var(--muted); margin-top: 12px; }
.f-step h3 { font-family: var(--serif); font-size: var(--fs-h3); font-weight: 600; color: var(--ink); margin-top: 6px; }
.f-step .f-help { color: var(--body); font-size: 15px; margin-top: 6px; }
.f-step { animation: fIn .35s ease; }
@keyframes fIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 24px; }
.tile { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; text-align: left; background: var(--white); border: 1.5px solid var(--line); border-radius: 16px; padding: 18px 16px; font: 600 14.5px var(--sans); color: var(--ink); cursor: pointer; transition: border-color .15s, background .15s, transform .15s, box-shadow .15s; }
.tile:hover { border-color: var(--lilac); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(74,35,85,.08); }
.tile .t-ic { color: var(--berry); display: block; line-height: 0; }
.tile .t-ic svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.tile small { display: block; font-weight: 400; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.tile[aria-pressed="true"] { border-color: var(--aubergine); background: #F6F0F8; box-shadow: 0 0 0 3px rgba(74,35,85,.08); }
.tile[aria-pressed="true"] .t-ic { color: var(--aubergine); }
.tile[aria-pressed="true"]::after { content: "✓"; position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; border-radius: 50%; background: var(--berry); color: #fff; font-size: 12px; display: grid; place-items: center; }

.f-field { margin-top: 26px; }
.f-label { display: flex; justify-content: space-between; align-items: baseline; font-weight: 600; font-size: 15px; color: var(--ink); }
.f-label output { font-family: var(--serif); font-size: var(--fs-num); font-weight: 600; color: var(--aubergine); }
.range { width: 100%; margin-top: 14px; -webkit-appearance: none; appearance: none; height: 8px; border-radius: 99px; background: linear-gradient(90deg, var(--berry) var(--pct, 20%), var(--line) var(--pct, 20%)); outline: none; }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; border-radius: 50%; background: var(--white); border: 3px solid var(--berry); box-shadow: 0 4px 12px rgba(165,69,126,.35); cursor: grab; }
.range::-moz-range-thumb { width: 24px; height: 24px; border-radius: 50%; background: var(--white); border: 3px solid var(--berry); cursor: grab; }
.range-ends { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); margin-top: 8px; }
.seg { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.seg button { font: 600 14px var(--sans); color: var(--aubergine); background: var(--white); border: 1.5px solid var(--line); border-radius: 99px; padding: 10px 18px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--aubergine); border-color: var(--aubergine); color: var(--cream); }

.f-nav { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 28px; }
.f-nav .btn[disabled] { opacity: .45; }
.f-back { background: none; border: 0; font: 600 14.5px var(--sans); color: var(--muted); cursor: pointer; }
.f-back:hover { color: var(--aubergine); }

/* Results */
.result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 22px; }
.estimate { background: linear-gradient(160deg, var(--aubergine), var(--aubergine-deep)); color: var(--cream); border-radius: 20px; padding: 28px; position: relative; overflow: hidden; }
.estimate::after { content: ""; position: absolute; width: 240px; height: 240px; right: -90px; top: -110px; border-radius: 50%; background: radial-gradient(circle, rgba(165,69,126,.6), rgba(165,69,126,0) 70%); }
.estimate .k { font-family: var(--serif); font-style: italic; font-size: 17px; color: var(--lilac); }
.estimate .v { font-family: var(--serif); font-size: var(--fs-num-lg); font-weight: 600; color: #fff; line-height: 1.05; margin-top: 8px; position: relative; z-index: 1; }
.estimate .d { font-size: 12.5px; color: #CDBBD6; margin-top: 12px; line-height: 1.55; position: relative; z-index: 1; }
.estimate .need { margin-top: 20px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.15); position: relative; z-index: 1; }
.estimate .need .f-label { color: #fff; font-size: 14px; }
.estimate .need output { color: #fff; font-size: var(--fs-num); }
.estimate .range { background: linear-gradient(90deg, #E8A9CB var(--pct, 50%), rgba(255,255,255,.2) var(--pct, 50%)); }
.matches h4 { font-family: var(--serif); font-size: var(--fs-h4); color: var(--ink); }
.match-card { display: grid; grid-template-columns: 24px 1fr; gap: 14px; align-items: start; border: 1.5px solid var(--line); border-radius: 16px; padding: 14px 16px; margin-top: 12px; }
.match-card.top { border-color: var(--berry); background: #FBF3F8; }
.match-card .t-ic { color: var(--berry); line-height: 0; padding-top: 2px; }
.match-card.top .t-ic { color: var(--berry); }
.match-card .t-ic svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.match-card b { font-size: 15px; color: var(--ink); }
.match-card .why { font-size: 13px; color: var(--body); margin-top: 2px; line-height: 1.5; }
.match-card .pill { display: inline-block; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 14px; color: var(--berry); margin-left: 8px; }
.f-cta { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin-top: 26px; }
.f-note { font-size: 13px; color: var(--muted); margin-top: 14px; }
.f-warn { background: #FFF6E5; border: 1px solid #EBD9B4; color: #6B4E16; border-radius: 12px; padding: 12px 14px; font-size: 13.5px; margin-top: 14px; }

/* Summary sidebar */
.finder-side { position: sticky; top: 96px; background: var(--white); border: 1px solid var(--line); border-radius: 24px; padding: 26px 24px; }
.finder-side h4 { font-family: var(--serif); font-size: var(--fs-h4); color: var(--ink); }
.finder-side ul { list-style: none; margin-top: 14px; }
.finder-side li { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); color: var(--muted); }
.finder-side li:last-child { border-bottom: 0; }
.finder-side li b { color: var(--ink); text-align: right; font-weight: 600; }
.finder-side li b.empty { color: var(--lilac); font-weight: 500; }
.finder-side .side-trust { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--body); line-height: 1.6; }
.finder-side .side-trust div { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.finder-side .side-trust div::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--berry); flex: none; }

@media (max-width: 1080px) {
  .finder-shell { grid-template-columns: 1fr; }
  .finder-side { position: static; order: -1; }
  .tiles { grid-template-columns: repeat(3, 1fr); }
  .result-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .finder .wrap { padding-top: 56px; padding-bottom: 56px; }
  .finder-head h2 { font-size: 32px; }
  .finder-main { padding: 24px 18px 22px; min-height: 0; }
  .tiles { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .tile { padding: 14px 12px; font-size: 13.5px; }
  .f-step h3 { font-size: 23px; }
  .estimate .v { font-size: 42px; }
  .finder-side { display: none; }
}

/* ---------- Hero estimator (replaces the quick-match form) ---------- */
.est-card { padding: 30px 30px 26px; }
.est-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.est-top h2 { font-family: var(--serif); font-size: var(--fs-h4); font-weight: 600; color: var(--ink); }
.est-tag { font-family: var(--serif); font-style: italic; font-size: 15px; color: var(--berry); white-space: nowrap; }
.est-row { display: flex; justify-content: space-between; align-items: baseline; margin-top: 22px; font-size: 14.5px; font-weight: 600; color: var(--ink); }
.est-row output { font-family: var(--serif); font-size: var(--fs-num); font-weight: 600; color: var(--aubergine); }
.est-card .seg button { padding: 9px 14px; font-size: 13.5px; }
.est-result { margin-top: 22px; background: linear-gradient(160deg, var(--aubergine), var(--aubergine-deep)); border-radius: 16px; padding: 18px 20px; color: var(--cream); position: relative; overflow: hidden; }
.est-result::after { content: ""; position: absolute; width: 180px; height: 180px; right: -60px; top: -80px; border-radius: 50%; background: radial-gradient(circle, rgba(165,69,126,.6), rgba(165,69,126,0) 70%); }
.est-result span { font-size: 13px; color: var(--lilac); }
.est-result b { display: block; font-family: var(--serif); font-size: var(--fs-num-lg); font-weight: 600; line-height: 1.05; color: #fff; margin-top: 4px; position: relative; z-index: 1; }
.est-result small { display: block; font-size: 11.5px; color: #CDBBD6; margin-top: 6px; position: relative; z-index: 1; }
.est-card .btn { width: 100%; margin-top: 18px; }
.est-alt { display: block; text-align: center; margin-top: 12px; font-size: 13.5px; font-weight: 600; color: var(--muted); text-decoration: none; }
.est-alt:hover { color: var(--aubergine); }

/* Hero: service area line under the stats */
.hero-serving { margin-top: 28px; }

/* ---------- Program cards (solutions band) ---------- */
.prog-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 40px; }
.prog { position: relative; display: flex; flex-direction: column; text-decoration: none; color: var(--cream); background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: 22px; padding: 26px 22px 22px; transition: background .2s, transform .2s, border-color .2s; overflow: hidden; }
.prog:hover { background: rgba(255,255,255,.11); transform: translateY(-3px); border-color: rgba(255,255,255,.3); }
.prog.feature { background: linear-gradient(160deg, rgba(165,69,126,.55), rgba(165,69,126,.18)); border-color: rgba(232,169,203,.45); }
.prog-num { font-family: var(--serif); font-style: italic; color: #E7A6CB; font-size: 15px; }
.prog h3 { font-family: var(--serif); font-size: var(--fs-h4); font-weight: 600; color: #fff; margin-top: 10px; }
.prog p { font-size: 14px; line-height: 1.55; color: #D9CBE0; margin-top: 8px; }
.prog-meta { font-size: 12.5px; color: var(--lilac); margin-top: 16px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.14); }
.prog-meta b { color: #fff; font-weight: 600; }
.prog-go { margin-top: auto; padding-top: 16px; font-size: 14px; font-weight: 600; color: #fff; }

/* ---------- Footer disclosures ---------- */
.disclosures { grid-column: 1 / -1; text-align: left; padding-top: 22px; border-top: 1px solid var(--line); }
.disclosures h4 { font-family: var(--serif); font-size: 15px; color: var(--ink); }
.disclosures p { font-size: 12px; line-height: 1.6; color: var(--muted); margin-top: 8px; max-width: 980px; }

@media (max-width: 1080px) { .prog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .prog-grid { grid-template-columns: 1fr; } }
