/*!
 * Offerte-funnel v1.0.0 — gedeeld FayLux-onderdeel (zie funnel.js).
 * Byte-voor-byte gelijk op alle sites. De huisstijl komt uit de --fn-*-tokens,
 * die offerte.html per site koppelt aan de CSS-variabelen van die site.
 * De waarden hieronder zijn alleen terugvalwaarden.
 */
.fn {
  --fn-font: inherit;
  --fn-font-head: inherit;
  --fn-text: #1a1a1a;
  --fn-muted: #5f6368;
  --fn-surface: #ffffff;
  --fn-surface-alt: #f6f6f4;
  --fn-border: #d9dcd8;
  --fn-accent: #1d7a2c;
  --fn-accent-soft: #eef6ee;
  --fn-on-accent: #ffffff;
  --fn-focus: #1a1a1a;
  --fn-error: #b42318;
  --fn-error-soft: #fef3f2;
  --fn-radius: 8px;
  --fn-radius-lg: 12px;
  --fn-head-transform: none;
  --fn-wa: #25d366;
  --fn-wa-text: #ffffff;
  --fn-scroll-offset: 100px;

  font-family: var(--fn-font);
  color: var(--fn-text);
  background: var(--fn-surface);
  border: 1px solid var(--fn-border);
  border-radius: var(--fn-radius-lg);
  padding: 20px 16px 18px;
  scroll-margin-top: var(--fn-scroll-offset);
  position: relative;
}
@media (min-width: 600px) { .fn { padding: 32px 36px 28px; } }

.fn[hidden], .fn [hidden] { display: none !important; }
/* Ruimte vasthouden tot funnel.js de stappen heeft gebouwd (geen layout shift) */
.fn:empty { min-height: 470px; }
@media (min-width: 600px) { .fn:empty { min-height: 450px; } }
.fn-sr {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ── Voortgang ── */
.fn-head { margin-bottom: 20px; }
.fn-steplabel {
  display: block; font-size: .85rem; font-weight: 600; color: var(--fn-muted);
  margin-bottom: 8px; letter-spacing: .02em;
}
.fn-bar {
  height: 6px; border-radius: 99px; background: var(--fn-surface-alt);
  overflow: hidden; border: 1px solid var(--fn-border);
}
.fn-bar-fill {
  display: block; height: 100%; width: 100%; background: var(--fn-accent);
  transform-origin: left center; transform: scaleX(0);
  transition: transform .35s ease;
}

/* ── Stap ── */
.fn-form { margin: 0; }
.fn-steps { min-height: 300px; }
@media (min-width: 600px) { .fn-steps { min-height: 280px; } }
.fn-step { border: 0; margin: 0; padding: 0; min-width: 0; }
/* Alleen een kleine verschuiving, geen opacity: de vraag is altijd leesbaar, ook als animaties stilstaan */
.fn.is-ready .fn-step { animation: fn-in .22s ease; }
@keyframes fn-in { from { transform: translateY(8px); } to { transform: none; } }
.fn-q {
  font-family: var(--fn-font-head); text-transform: var(--fn-head-transform);
  font-size: clamp(1.35rem, 1.1rem + 1.2vw, 1.85rem); line-height: 1.15;
  margin: 0 0 6px; color: var(--fn-text); outline: none;
}
.fn-intro { color: var(--fn-muted); margin: 0 0 16px; font-size: .95rem; }
.fn-q + .fn-options, .fn-q + .fn-field, .fn-q + .fn-notice { margin-top: 16px; }

/* ── Kaarten ── */
.fn-options { display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 520px) { .fn-options { grid-template-columns: 1fr 1fr; } }
.fn-opt {
  position: relative; display: flex; align-items: center; gap: 12px;
  min-height: 56px; padding: 14px 16px; cursor: pointer;
  background: var(--fn-surface); color: var(--fn-text);
  border: 1.5px solid var(--fn-border); border-radius: var(--fn-radius);
  transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.fn-opt:hover { border-color: var(--fn-accent); }
.fn-radio { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.fn-opt-mark {
  flex: none; width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--fn-border); background: var(--fn-surface);
  display: grid; place-items: center; transition: border-color .15s ease;
}
.fn-opt-mark::after {
  content: ''; width: 10px; height: 10px; border-radius: 50%;
  background: var(--fn-accent); transform: scale(0); transition: transform .15s ease;
}
.fn-opt-text { display: flex; flex-direction: column; gap: 2px; }
.fn-opt-title { font-weight: 600; font-size: 1rem; line-height: 1.3; }
.fn-opt-hint { font-size: .85rem; color: var(--fn-muted); }
.fn-radio:checked ~ .fn-opt-mark { border-color: var(--fn-accent); }
.fn-radio:checked ~ .fn-opt-mark::after { transform: scale(1); }
.fn-opt:has(.fn-radio:checked) { border-color: var(--fn-accent); background: var(--fn-accent-soft); }
.fn-opt:focus-within { outline: 3px solid var(--fn-focus); outline-offset: 2px; }

/* ── Velden ── */
.fn-field { margin: 0 0 16px; }
.fn-field label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: 6px; }
.fn-req { color: var(--fn-error); }
.fn-opt-label { font-weight: 400; color: var(--fn-muted); font-size: .88rem; }
.fn-field input, .fn-field textarea {
  display: block; width: 100%; min-height: 48px; padding: 12px 14px;
  font: inherit; font-size: 1rem; color: var(--fn-text); background: var(--fn-surface);
  border: 1.5px solid var(--fn-border); border-radius: var(--fn-radius);
  box-sizing: border-box; -webkit-appearance: none; appearance: none;
}
.fn-field textarea { min-height: 110px; resize: vertical; }
.fn-field input:focus, .fn-field textarea:focus {
  outline: none; border-color: var(--fn-accent);
  box-shadow: 0 0 0 3px var(--fn-accent-soft);
}
.fn-field input[aria-invalid="true"] { border-color: var(--fn-error); }
.fn-unit { position: relative; display: flex; align-items: center; max-width: 240px; }
.fn-unit input { padding-right: 84px; }
.fn-unit-label { position: absolute; right: 14px; color: var(--fn-muted); font-size: .95rem; pointer-events: none; }
.fn-hint { display: block; font-size: .85rem; color: var(--fn-muted); margin-top: 6px; }
.fn-unknown {
  display: inline-flex; align-items: center; min-height: 44px; padding: 10px 16px;
  font: inherit; font-weight: 600; color: var(--fn-text); cursor: pointer;
  background: var(--fn-surface-alt); border: 1.5px dashed var(--fn-border); border-radius: var(--fn-radius);
}
.fn-unknown:hover, .fn-unknown[aria-pressed="true"] { border-color: var(--fn-accent); border-style: solid; background: var(--fn-accent-soft); }
.fn-unknown:focus-visible { outline: 3px solid var(--fn-focus); outline-offset: 2px; }

/* ── Meldingen ── */
.fn-error {
  margin: 12px 0 0; padding: 10px 12px; font-size: .92rem; font-weight: 600;
  color: var(--fn-error); background: var(--fn-error-soft);
  border-left: 3px solid var(--fn-error); border-radius: var(--fn-radius);
}
.fn-error--field { display: block; margin-top: 6px; padding: 6px 10px; }
.fn-notice {
  margin: 0 0 16px; padding: 12px 14px; font-size: .95rem;
  background: var(--fn-surface-alt); border-left: 3px solid var(--fn-accent); border-radius: var(--fn-radius);
}

/* ── Upload ── */
.fn-upload { margin-top: 4px; }
.fn-drop {
  position: relative; border: 2px dashed var(--fn-border); border-radius: var(--fn-radius);
  background: var(--fn-surface-alt); transition: border-color .15s ease, background-color .15s ease;
}
.fn-drop.is-over, .fn-drop:hover { border-color: var(--fn-accent); background: var(--fn-accent-soft); }
.fn-file-input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.fn-drop:focus-within { outline: 3px solid var(--fn-focus); outline-offset: 2px; }
.fn-drop-label {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; min-height: 120px; padding: 18px; text-align: center; cursor: pointer;
}
.fn-drop-icon { width: 30px; height: 30px; color: var(--fn-accent); }
.fn-drop-icon svg { width: 100%; height: 100%; }
.fn-drop-title { font-weight: 600; }
.fn-drop-sub { font-size: .88rem; color: var(--fn-muted); }
.fn-files { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.fn-file {
  display: flex; align-items: center; gap: 12px; padding: 8px;
  border: 1px solid var(--fn-border); border-radius: var(--fn-radius); background: var(--fn-surface);
}
.fn-thumb {
  flex: none; width: 56px; height: 56px; object-fit: cover; border-radius: calc(var(--fn-radius) / 1.5);
  background: var(--fn-surface-alt);
}
.fn-thumb--icon { display: grid; place-items: center; align-content: center; color: var(--fn-muted); gap: 1px; }
.fn-thumb--icon svg { width: 24px; height: 24px; }
.fn-thumb--icon b { font-size: .65rem; letter-spacing: .04em; }
.fn-file-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fn-file-name { font-size: .92rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fn-file-size { font-size: .82rem; color: var(--fn-muted); }
.fn-file-rm {
  flex: none; width: 44px; height: 44px; display: grid; place-items: center;
  background: transparent; border: 0; border-radius: var(--fn-radius); color: var(--fn-muted); cursor: pointer;
}
.fn-file-rm svg { width: 18px; height: 18px; }
.fn-file-rm:hover { color: var(--fn-error); background: var(--fn-error-soft); }
.fn-file-rm:focus-visible { outline: 3px solid var(--fn-focus); outline-offset: 0; }

/* ── Navigatie ── */
.fn-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; }
.fn-back {
  min-height: 44px; padding: 10px 4px; font: inherit; font-weight: 600; color: var(--fn-muted);
  background: none; border: 0; cursor: pointer;
}
.fn-back:hover { color: var(--fn-text); }
.fn-back:focus-visible { outline: 3px solid var(--fn-focus); outline-offset: 2px; border-radius: 4px; }
.fn-back[hidden] { display: block !important; visibility: hidden; }
.fn-next { min-height: 48px; justify-content: center; margin-left: auto; }
.fn-next[disabled] { opacity: .7; cursor: progress; transform: none; }
.fn-form.is-last .fn-nav { flex-direction: column-reverse; align-items: stretch; }
.fn-form.is-last .fn-next { width: 100%; margin-left: 0; }
.fn-form.is-last .fn-back { align-self: flex-start; }
.fn-privacy { margin: 12px 0 0; font-size: .85rem; color: var(--fn-muted); }
.fn-privacy a { color: inherit; text-decoration: underline; }
.fn-form:not(.is-last) .fn-privacy { display: none; }

/* ── Bedankt ── */
.fn-done { text-align: center; padding: 12px 0 4px; outline: none; }
.fn-done-icon {
  width: 56px; height: 56px; margin: 0 auto 16px; border-radius: 50%;
  display: grid; place-items: center; background: var(--fn-accent-soft); color: var(--fn-accent);
}
.fn-done-icon svg { width: 28px; height: 28px; }
.fn-done-title {
  font-family: var(--fn-font-head); text-transform: var(--fn-head-transform);
  font-size: clamp(1.4rem, 1.15rem + 1.2vw, 1.9rem); line-height: 1.2; margin: 0 0 10px;
}
.fn-done-text { color: var(--fn-muted); margin: 0 auto 20px; max-width: 42ch; }
.fn-wa { min-height: 52px; justify-content: center; gap: 10px; width: 100%; max-width: 360px; }
.fn-wa:not([class*="btn"]) { display: inline-flex; align-items: center; background: var(--fn-wa); color: var(--fn-wa-text); border-radius: var(--fn-radius); font-weight: 700; text-decoration: none; }
.fn-done-call { margin: 16px 0 0; }
.fn-done-call a { color: var(--fn-text); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* ── Honeypot ── */
.fn-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ── Formulier zonder JavaScript (noscript) ── */
.fn-static fieldset { border: 0; padding: 0; margin: 0 0 22px; }
.fn-static legend { font-family: var(--fn-font-head); font-weight: 700; font-size: 1.1rem; margin-bottom: 10px; padding: 0; }
.fn-static .fn-opt { min-height: 48px; }
.fn-static .fn-radio { position: static; opacity: 1; width: 20px; height: 20px; pointer-events: auto; accent-color: var(--fn-accent); }
.fn-static input[type="file"] { min-height: 48px; padding: 10px; width: 100%; }
.fn-static .fn-next { width: 100%; }

@media (prefers-reduced-motion: reduce) {
  .fn-step { animation: none; }
  .fn-bar-fill, .fn-opt, .fn-opt-mark::after, .fn-drop { transition: none; }
}
