/* FAIST Lohnfertigung – Anfragetool
   Formatierung 1:1 vom Kontaktformular auf faist.com (CF7 „cf7-two-columns"):
   Felder 1px #000 / radius 10px / padding 20px / Schrift clamp(1.25rem,1.5vw,1.5625rem) 400,
   Upload-Box mit Text + grauem Hinweis, roter Button radius 10px (Hover #c30018),
   Zustimmung mit großem Text und rotem Link. D-DIN Pro nur 400/500. */

.fla-funnel {
  --fla-red: #FF0827;
  --fla-red-hover: #c30018;
  --fla-black: #000000;
  --fla-grey: #6b6b6b;
  --fla-line: #000000;
  --fla-radius: 10px;
  --fla-gap: 30px;
  --fla-pad: 20px;
  --fla-fs: clamp(1.25rem, 1.5vw, 1.5625rem);
  --fla-lh: clamp(1.75rem, 2vw, 2.1875rem);
  --fla-fs-small: clamp(0.875rem, 0.9vw, 1rem);
  font-family: inherit;
  color: var(--fla-black);
  background: transparent;
  width: 100%;
  box-sizing: border-box;
}
.fla-funnel *, .fla-funnel *::before, .fla-funnel *::after { box-sizing: inherit; }

/* Themes/Elementor überschreiben das [hidden]-Attribut gern mit eigenen
   display-Regeln (z. B. button { display: inline-block }) — hart erzwingen. */
.fla-funnel [hidden] { display: none !important; }

/* Fortschritt */
.fla-progress {
  height: 3px;
  background: #ECECEC;
  border-radius: 2px;
  margin-bottom: clamp(24px, 4vw, 40px);
  overflow: hidden;
}
.fla-progress-bar {
  display: block;
  height: 100%;
  width: 20%;
  background: var(--fla-red);
  transition: width .35s ease;
}

/* Typografie (Kicker + Headline wie die Sektionen der Site) */
.fla-kicker {
  color: var(--fla-red);
  font-weight: 400;
  font-size: clamp(20px, 1.2vw + 14px, 25px);
  line-height: 1.4;
  margin: 0 0 8px;
}
.fla-title {
  font-size: clamp(28px, 2.4vw + 14px, 48px);
  line-height: 1.15;
  font-weight: 400;
  margin: 0 0 .35em;
  color: var(--fla-black);
}
.fla-sub {
  color: var(--fla-grey);
  font-size: var(--fla-fs);
  line-height: var(--fla-lh);
  margin: 0 0 var(--fla-gap);
}

/* Reihen + Felder */
.fla-row {
  display: flex;
  gap: var(--fla-gap);
  align-items: flex-start;
}
.fla-row > .fla-field { flex: 1 1 0; min-width: 0; }
.fla-field { position: relative; margin-bottom: var(--fla-gap); }
.fla-label {
  display: block;
  font-size: var(--fla-fs);
  font-weight: 400;
  margin-bottom: 12px;
}
.fla-funnel input[type="text"],
.fla-funnel input[type="email"],
.fla-funnel input[type="tel"],
.fla-funnel textarea {
  width: 100%;
  border: 1px solid var(--fla-line) !important;
  border-radius: var(--fla-radius);
  background: #fff;
  color: var(--fla-black);
  padding: var(--fla-pad);
  font-family: inherit;
  font-size: var(--fla-fs);
  font-weight: 400;
  line-height: var(--fla-lh);
  box-shadow: none !important;
  transition: background .15s ease;
}
.fla-funnel textarea { resize: none; min-height: 180px; line-height: normal; }
.fla-funnel input:focus,
.fla-funnel textarea:focus,
.fla-funnel input:focus-visible,
.fla-funnel textarea:focus-visible {
  outline: none;
  box-shadow: none !important;
  background: #fff;
}
.fla-funnel ::placeholder { color: rgba(0, 0, 0, .4); opacity: 1; }

/* Leistungs-Karten: Feld-Optik der Site, 3 pro Reihe wie das Kontakt-Layout */
.fla-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--fla-gap);
}
.fla-card {
  display: flex;
  align-items: center;
  gap: 15px;
  border: 1px solid var(--fla-line);
  border-radius: var(--fla-radius);
  background: #fff;
  padding: var(--fla-pad);
  cursor: pointer;
  font-size: var(--fla-fs);
  font-weight: 400;
  line-height: 1.3;
  transition: background .15s ease, border-color .15s ease;
  user-select: none;
}
.fla-card:hover { background: #fafafa; }
.fla-card input {
  appearance: none;
  -webkit-appearance: none;
  width: 26px;
  height: 26px;
  min-width: 26px;
  border: 1px solid var(--fla-line);
  border-radius: 6px;
  margin: 0;
  display: inline-grid;
  place-content: center;
  cursor: pointer;
  background: #fff;
  transition: border-color .15s ease, background .15s ease;
}
.fla-card input::before {
  content: "";
  width: 13px;
  height: 13px;
  transform: scale(0);
  background: #fff;
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
  transition: transform .12s ease;
}
.fla-card input:checked { background: var(--fla-red); border-color: var(--fla-red); }
.fla-card input:checked::before { transform: scale(1); }
.fla-card:has(input:checked) { border-color: var(--fla-red); background: rgba(255, 8, 39, .04); }
.fla-card input:focus-visible { outline: 2px solid var(--fla-red); outline-offset: 2px; }

/* Umfang-Auswahl: wie Felder, aktiv schwarz */
.fla-pills { display: flex; flex-wrap: wrap; gap: 15px; }
.fla-pill { cursor: pointer; position: relative; }
.fla-pill input { position: absolute; opacity: 0; pointer-events: none; }
.fla-pill span {
  display: inline-block;
  border: 1px solid var(--fla-line);
  border-radius: var(--fla-radius);
  background: #fff;
  padding: 15px 22px;
  font-size: var(--fla-fs);
  font-weight: 400;
  line-height: 1.2;
  transition: background .15s ease, color .15s ease;
}
.fla-pill:hover span { background: #fafafa; }
.fla-pill input:checked + span { background: var(--fla-black); color: #fff; }
.fla-pill input:focus-visible + span { outline: 2px solid var(--fla-red); outline-offset: 2px; }

/* Upload-Box – exakt wie .cf7-file der Site */
.fla-drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 180px;
  padding: var(--fla-pad);
  text-align: center;
  border: 1px solid var(--fla-line);
  border-radius: var(--fla-radius);
  background: #fff;
  cursor: pointer;
  transition: background .15s ease;
}
.fla-drop:hover, .fla-drop:focus-within, .fla-drop.is-drag { background: #fafafa; }
.fla-drop.is-drag { border-color: var(--fla-red); }
.fla-drop input { display: none; }
.fla-drop-text { color: var(--fla-black); font-size: var(--fla-fs); font-weight: 400; line-height: normal; pointer-events: none; }
.fla-drop-hint { color: var(--fla-grey); font-size: var(--fla-fs-small); font-weight: 400; line-height: normal; pointer-events: none; }
.fla-filelist { list-style: none; margin: 15px 0 0; padding: 0; }
.fla-filelist li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  border: 1px solid var(--fla-line);
  border-radius: var(--fla-radius);
  background: #fff;
  padding: 12px var(--fla-pad);
  margin-bottom: 10px;
  font-size: var(--fla-fs-small);
  overflow-wrap: anywhere;
}
.fla-file-remove {
  border: 0;
  background: none;
  color: var(--fla-red);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
  flex-shrink: 0;
}

/* Zustimmung – wie .wpcf7-list-item der Site */
.fla-consent { margin-top: 0; }
.fla-consent label {
  display: flex;
  gap: 15px;
  align-items: flex-start;
  font-size: var(--fla-fs);
  font-weight: 400;
  line-height: normal;
  color: var(--fla-black);
  cursor: pointer;
}
.fla-consent input {
  width: 24px;
  height: 24px;
  min-width: 24px;
  margin: 2px 0 0;
  accent-color: var(--fla-red);
  cursor: pointer;
}
.fla-consent a { color: var(--fla-red); text-decoration: none; }
.fla-consent a:hover { text-decoration: underline; }
.fla-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Fehlermeldungen – wie .wpcf7-not-valid-tip */
.fla-error {
  color: var(--fla-red);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.2;
  margin: 6px 0 0 2px;
}
.fla-submit-error { margin-top: 0; }

/* Navigation – Buttons wie .cf7-red-button */
.fla-nav {
  display: flex;
  justify-content: space-between;
  gap: var(--fla-gap);
  margin-top: var(--fla-gap);
}
.fla-btn {
  border: 1px solid var(--fla-black);
  border-radius: var(--fla-radius);
  background: #fff;
  color: var(--fla-black);
  font-family: inherit;
  font-size: var(--fla-fs);
  font-weight: 500;
  line-height: 1.2;
  padding: 15px 50px;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.fla-btn-next {
  margin-left: auto;
  background: var(--fla-red);
  border-color: var(--fla-red);
  color: #fff;
}
.fla-btn-next:hover { background: var(--fla-red-hover); border-color: var(--fla-red-hover); }
.fla-btn-back:hover { background: var(--fla-black); color: #fff; }
.fla-btn:disabled { opacity: .55; cursor: default; }
.fla-btn:focus-visible { outline: 2px solid var(--fla-red); outline-offset: 2px; }

/* ---------- Responsive (Breakpoints wie das Kontaktformular) ---------- */
@media (max-width: 1024px) {
  .fla-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
  .fla-funnel { --fla-gap: 15px; --fla-pad: 15px; }
  .fla-row { flex-direction: column; gap: 0; }
  .fla-cards { grid-template-columns: 1fr; }
  .fla-funnel textarea { min-height: 150px; }
  .fla-drop { min-height: 140px; }
  .fla-pill span { padding: 12px 18px; }
  /* Wie der Site-Button: volle Breite; Absenden/Weiter oben, Zurück darunter */
  .fla-nav { flex-direction: column-reverse; gap: 15px; }
  .fla-btn { width: 100%; padding: 15px 10px; text-align: center; }
  .fla-btn-next { margin-left: 0; }
}
