/* /anfrage – distraction-free inquiry funnel */
.funnel-body { background: var(--surface); min-height: 100vh; display: flex; flex-direction: column; }
.funnel-header { background: #fff; border-bottom: 1px solid var(--border); }
.funnel-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 1rem; }
.funnel-header__trust { display: flex; align-items: center; gap: 1.1rem; font-size: .88rem; font-weight: 700; color: var(--navy); }
.funnel-header__trust > span { display: inline-flex; align-items: center; gap: .4rem; }
.funnel-header__trust .icon { color: var(--brand); }
.funnel-header__rating { gap: .5rem !important; }
.funnel-header__phone { display: inline-flex; align-items: center; gap: .4rem; color: var(--ink); text-decoration: none; }
.funnel-main { flex: 1; padding: clamp(1.25rem, 4vw, 2.75rem) 0 3rem; }
.funnel { max-width: calc(820px + var(--gutter) * 2); }
.funnel-intro { text-align: center; margin-bottom: 1.4rem; }
.funnel-intro__title { font-size: clamp(1.45rem, 1.1rem + 1.5vw, 2rem); margin-bottom: .35rem; }
.funnel-intro__lead { color: var(--muted); margin: 0; }
.funnel-card { background: #fff; border-radius: 22px; box-shadow: 0 30px 60px -30px rgba(23, 53, 77, .28), 0 2px 6px rgba(16, 42, 64, .05); border: 1px solid var(--border); overflow: hidden; }
.funnel-progress { padding: 1.3rem clamp(1.2rem, 4vw, 2.4rem) 0; }
.funnel-progress__meta { display: flex; justify-content: space-between; font-size: .84rem; font-weight: 700; color: var(--muted); margin-bottom: .5rem; }
.funnel-progress__meta [data-step-name] { color: var(--brand-700); }
.funnel-progress__bar { height: 8px; border-radius: 99px; background: var(--ice); overflow: hidden; }
.funnel-progress__bar span { display: block; height: 100%; width: 20%; border-radius: 99px; background: var(--brand-600); transition: width .5s var(--ease); }
.funnel-steps { display: grid; grid-template-columns: repeat(5, 1fr); list-style: none; margin: .55rem 0 0; padding: 0; font-size: .74rem; color: var(--muted-2); font-weight: 600; }
.funnel-steps li { text-align: center; }
.funnel-steps li.is-done { color: var(--brand); }
.funnel-steps li.is-current { color: var(--ink); font-weight: 800; }
.funnel-form { padding: 1.6rem clamp(1.2rem, 4vw, 2.4rem) 1.8rem; }
.fstep { animation: fstepIn .35s var(--ease); }
@keyframes fstepIn { from { opacity: 0; transform: translateX(14px); } to { opacity: 1; transform: none; } }
.fstep__title { font-size: clamp(1.2rem, 1rem + .9vw, 1.55rem); margin-bottom: 1.2rem; outline: none; }
.fstep__eyebrow { display: inline-flex; align-items: center; gap: .4rem; margin: 0 0 .5rem; padding: .25rem .7rem; border-radius: 99px; background: var(--ice); color: var(--navy); font-weight: 700; font-size: .84rem; }
.fstep__eyebrow svg { width: 18px; height: 18px; }
.fstep__lead { margin-top: -.6rem; color: var(--muted); }

/* Category cards */
.fcats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.fcats--more { margin-top: 12px; }
.fcat { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .55rem; min-height: 124px; padding: 1rem .6rem; border: 1.5px solid var(--border-2); border-radius: 14px; background: #fff; color: var(--ink); font-weight: 700; font-size: .95rem; text-align: center; line-height: 1.25; transition: border-color .15s, background-color .15s, transform .15s, box-shadow .15s; }
.fcat:hover { border-color: var(--brand); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.fcat__icon { color: var(--navy); }
.fcat__icon .icon { width: 36px; height: 36px; stroke-width: 1.4; }
.fcat__check { position: absolute; top: 8px; right: 8px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--brand); color: #fff; opacity: 0; transform: scale(.6); transition: all .2s var(--ease); }
.fcat__check .icon { width: 14px; height: 14px; stroke-width: 3; }
.fcat.is-selected { border-color: var(--brand); background: var(--ice); box-shadow: 0 0 0 3px rgba(36, 117, 168, .12); }
.fcat.is-selected .fcat__icon { color: var(--brand); }
.fcat.is-selected .fcat__check { opacity: 1; transform: none; }
.fmore { display: inline-flex; align-items: center; gap: .35rem; margin-top: 1rem; padding: .4rem 0; background: none; border: 0; color: var(--brand-700); font-weight: 700; }
.fmore[aria-expanded="true"] .icon { transform: rotate(180deg); }

/* Option buttons */
.fq { margin-bottom: 1.5rem; }
.fq__label { display: block; font-weight: 750; color: var(--ink); margin: 0 0 .7rem; }
.fopts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); gap: 10px; }
.fopts--2 { grid-template-columns: repeat(2, 1fr); }
.fopt { display: flex; align-items: center; gap: .7rem; min-width: 0; hyphens: auto; overflow-wrap: break-word; min-height: 56px; padding: .75rem 1rem; border: 1.5px solid var(--border-2); border-radius: 12px; background: #fff; text-align: left; font-weight: 650; color: var(--ink); transition: border-color .15s, background-color .15s; }
.fopt:hover { border-color: var(--brand); }
.fopt__dot { flex: none; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--border-2); position: relative; transition: border-color .15s; }
.fopt.is-selected { border-color: var(--brand); background: var(--ice); }
.fopt.is-selected .fopt__dot { border-color: var(--brand); }
.fopt.is-selected .fopt__dot::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--brand); }

.fgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.fgrid--plz { grid-template-columns: .8fr 1.2fr; }
.input--lg { min-height: 56px; font-size: 1.05rem; }
.input.is-invalid { border-color: var(--danger); }
.fhint { display: flex; align-items: center; gap: .4rem; margin-top: .9rem; color: var(--brand-700); font-weight: 700; }
.ferror { display: flex; align-items: center; gap: .35rem; margin: .5rem 0 0; color: var(--danger); font-size: .88rem; font-weight: 600; }
.ferror--box { display: block; padding: .8rem 1rem; border-radius: 10px; background: #fff3f1; }
.ferror--box .btn { margin-top: .6rem; }
.fsummary { display: flex; flex-wrap: wrap; gap: .45rem; list-style: none; margin: -.4rem 0 1.3rem; padding: 0; }
.fsummary li { padding: .3rem .7rem; border-radius: 99px; background: var(--surface); font-size: .84rem; font-weight: 600; color: var(--ink-2); }
.linkish { display: inline-flex; align-items: center; gap: .25rem; background: none; border: 0; padding: 0; color: var(--brand-700); font-weight: 700; font-size: .84rem; }
.finfo { display: grid; grid-template-columns: auto 1fr; gap: .7rem; margin: 1.4rem 0 1rem; padding: 1rem 1.1rem; border-radius: 12px; background: var(--ice); color: var(--navy); font-size: .88rem; }
.finfo p { margin: 0; }
.finfo .icon { color: var(--brand); margin-top: .15rem; }
.fconsent { font-size: .88rem; }

.fnav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1.6rem; padding-top: 1.4rem; border-top: 1px solid var(--border); }
.fnav__next, .fnav__submit { margin-left: auto; min-width: 200px; }
.fnav__submit.is-loading { opacity: .8; cursor: progress; }
.btn[disabled] { opacity: .4; }

.funnel-trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; list-style: none; margin: 1.6rem 0 0; padding: 0; }
.funnel-trust li { display: flex; gap: .6rem; align-items: flex-start; font-size: .82rem; color: var(--muted); }
.funnel-trust .icon { color: var(--brand); flex: none; }
.funnel-trust strong { display: block; color: var(--ink); font-size: .9rem; }
.funnel-thanks { padding: clamp(1.8rem, 5vw, 3rem); text-align: center; }
.funnel-thanks .timeline { max-width: 560px; margin: 0 auto 1.5rem; }
.funnel-ref { font-size: 1.15rem; margin: .5rem 0; }
.funnel-ref strong { white-space: nowrap; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--ice); color: var(--navy); padding: .15rem .55rem; border-radius: 8px; letter-spacing: .04em; }
.funnel-more { margin-top: 2.5rem; }
.funnel-footer { padding: 1.4rem 0 2rem; font-size: .82rem; color: var(--muted); text-align: center; }
.funnel-footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1.2rem; margin-bottom: .4rem; }
.funnel-footer a { color: var(--muted); }

@media (max-width: 720px) {
  .hide-sm { display: none; }
  .funnel-steps { display: none; }
  .fcats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .fcat { min-height: 104px; font-size: .9rem; }
  .fopts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .fopt { min-height: 52px; padding: .6rem .7rem; gap: .5rem; font-size: .92rem; }
  .fopts--2, .fopts--long { grid-template-columns: 1fr; }
  .fgrid, .fgrid--plz { grid-template-columns: 1fr; }
  .funnel-trust { grid-template-columns: 1fr 1fr; }
  .fnav { position: sticky; bottom: 0; background: #fff; margin: 1.4rem calc(-1 * clamp(1.2rem, 4vw, 2.4rem)) -1.8rem; padding: .9rem clamp(1.2rem, 4vw, 2.4rem) calc(.9rem + env(safe-area-inset-bottom)); box-shadow: 0 -8px 20px -14px rgba(0, 0, 0, .25); }
  .fnav__next, .fnav__submit { min-width: 0; flex: 1; white-space: normal; line-height: 1.2; padding-inline: 1rem; }
  .fnav__back { padding-inline: .7rem; flex: none; }
  .fnav__back .hide-sm { display: none; }
  .funnel-intro { margin-bottom: 1rem; }
  .funnel-intro__title { font-size: 1.3rem; }
  .funnel-intro__lead { font-size: .9rem; }
  .funnel-advanced .funnel-intro { display: none; }
  .funnel-main { padding-top: 1rem; }
  .funnel-ref { font-size: 1rem; }
  .funnel-card { border-radius: 18px; overflow: visible; }
}

/* Phase 2 polish */
.funnel-body { background: radial-gradient(1100px 520px at 50% -8%, var(--ice) 0%, rgba(235, 244, 250, 0) 62%), var(--surface); }
.funnel-card { position: relative; }
.funnel-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--navy), var(--brand-600)); }
.fopt:hover, .fcat:hover { background: #f8fbfd; }
.fopt.is-selected, .fcat.is-selected { box-shadow: 0 0 0 3px rgba(36, 117, 168, .12); }
.fopt:active, .fcat:active { transform: scale(.985); }
.chip span { transition: border-color .15s, background-color .15s, color .15s; }
.chip:hover span { border-color: var(--brand); }
.input--lg:focus { background: #fff; }
.fstep__title { letter-spacing: -.02em; }

/* MeisterMatch identity – funnel (Phase 5): same tokens as the website, calmer surfaces */
.funnel-card { border-radius: 16px; }
.fcat, .fopt { border-radius: 10px; }
.fcat__icon { color: var(--navy); }
.fcat:hover, .fopt:hover { border-color: var(--brand); }
.fcat.is-selected, .fopt.is-selected { border-color: var(--brand-600); background: var(--ice); box-shadow: 0 0 0 3px rgba(36, 117, 168, .14); }
.fcat.is-selected .fcat__icon { color: var(--brand-700); }
.fcat__check { background: var(--brand-600); }
.fopt.is-selected .fopt__dot { border-color: var(--brand-600); }
.fopt.is-selected .fopt__dot::after { background: var(--brand-600); }
.fstep__eyebrow { background: var(--ice); color: var(--navy); }
.funnel-steps li.is-done { color: var(--brand-700); }
.funnel-ref strong { background: var(--ice); color: var(--navy); }
.fopt__dot { border-color: var(--control); }

/* Narrow phones: long service names (Komplettsanierung, Elektroinstallation) hyphenate inside the card */
.fcat { overflow-wrap: anywhere; hyphens: auto; }
