/* ================================================================== *
 * anfrage-conversational.css – Anfragestrecke, Fassung A
 *
 * Nachbau der ursprünglichen Strecke: heller, blauer Grund mit weißem
 * Lichtkern in der Mitte, dunkelblaue Schrift, eine Frage nach der anderen.
 * Die vorherige und die nächste Frage bleiben blass sichtbar, unten liegt
 * die dunkle Fußleiste mit Fortschritt und Sprungtasten.
 *
 * Alle Maße, Farben und Schriftschnitte stammen aus der Quelle. Zwei
 * Ausnahmen, beide zugunsten der Lesbarkeit: der blasse Hinweis unter der
 * Einwilligung ist etwas kräftiger (Kontrast 4,5:1 statt 2,4:1) und
 * Eingabefelder bekommen beim Tastaturfokus eine sichtbare Unterstreichung.
 * ================================================================== */

/* ---- Schrift der Quelle: Lato, lokal ausgeliefert ----------------- */
@font-face {
  font-family: "Lato";
  src: url("/fonts/lato-300.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: optional;
}
@font-face {
  font-family: "Lato";
  src: url("/fonts/lato-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: optional;
}
@font-face {
  font-family: "Lato";
  src: url("/fonts/lato-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: optional;
}
/* Metrisch angeglichener Ersatz – greift nur, wenn Lato ausnahmsweise nicht
   rechtzeitig da ist, und hält das Layout dann trotzdem ruhig. */
@font-face {
  font-family: "Lato Fallback";
  src: local("Arial");
  size-adjust: 98%;
  ascent-override: 101%;
  descent-override: 22%;
}

.cf-page {
  /* Farbwerte der Quelle */
  --cf-text: #1a3d5c;
  --cf-muted: #3b5a76;
  --cf-accent: #448ccb;
  --cf-accent-hover: #357fc0;
  --cf-accent-active: #3072ac;
  --cf-error: #db4b5b;
  --cf-bg: #bcd6ec;
  --cf-footer-text: #e4eef7;
  --cf-line: rgba(26, 61, 92, 0.1);
  --cf-line-strong: rgba(26, 61, 92, 0.5);
  --cf-fill: rgba(26, 61, 92, 0.025);
  --cf-fill-hover: rgba(26, 61, 92, 0.05);

  font-family: "Lato", "Lato Fallback", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--cf-text);
  background-color: var(--cf-bg);
}

.cf {
  /* Abstand zwischen zwei Feldern – 75 px wie in der Quelle. */
  --cf-gap: 75px;
  height: 100svh;
  height: 100dvh;
  overflow: hidden;
  display: grid;
  grid-template-rows: 1fr auto;
  color: var(--cf-text);
  background-color: var(--cf-bg);
  background-image: radial-gradient(ellipse at center, #fff 0%, rgba(255, 255, 255, 0) 100%);
  word-break: break-word;
  hyphens: auto;
}

/* ---- Bühne ------------------------------------------------------- *
 * Die Felder liegen als Stapel untereinander. Das aktive Feld steht mit
 * seiner Oberkante im oberen Drittel der Bühne – genau wie in der Quelle,
 * die ihre Grundlinie bei Fensterhöhe/3 setzt (auf Geräten mit Touch bei
 * Fensterhöhe/5). Geblättert wird gesteuert: Mausrad, Wischgeste, Enter,
 * Pfeiltasten, Sprungtasten – oder mit einem Klick auf ein Nachbarfeld. */
.cf__main {
  position: relative;
  overflow-y: auto;
  overscroll-behavior: contain;
  /* Die Bildlaufleiste bleibt verborgen – geblättert wird Feld für Feld. */
  scrollbar-width: none;
}
.cf__main::-webkit-scrollbar {
  width: 0;
  height: 0;
}
@media (pointer: coarse) {
  .cf__main {
    scroll-snap-type: y proximity;
  }
  .cf-screen {
    scroll-snap-align: start;
  }
}
.cf-form {
  box-sizing: border-box;
  width: 100%;
  max-width: 880px;
  margin-inline: auto;
  padding-inline: 40px;
  /* Damit auch das letzte Feld die Grundlinie erreicht, bleibt unter dem
     Stapel Platz – gemessen aus Bühnenhöhe und Höhe des letzten Feldes.
     Oben übernimmt das der bildschirmfüllende Startbildschirm. */
  padding-bottom: var(--cf-pad-bottom, 75svh);
}
@media (min-width: 501px) and (max-width: 768px) {
  .cf-form {
    padding-inline: 60px;
  }
}

/* Ein Feld ist nur so hoch wie sein Inhalt; darunter liegen 75 px Abstand. */
.cf-screen {
  padding-bottom: var(--cf-gap);
  opacity: 0.2;
  transition: opacity 0.25s ease-in-out;
}
.cf-screen[hidden] {
  display: none;
}
.cf-screen.is-active {
  opacity: 1;
}
.cf-screen:not(.is-active) {
  cursor: pointer;
}
@media (prefers-reduced-motion: reduce) {
  .cf-screen {
    transition: none;
  }
}

/* ---- Startbildschirm --------------------------------------------- *
 * In der Quelle füllt er die ganze Höhe, Titel und Aufzählung stehen
 * linksbündig, die Schaltfläche darunter mittig. */
.cf-screen--intro {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: var(--cf-stage, 100svh);
  padding-bottom: 35px;
}
.cf-intro__title {
  margin: 0 0 14px;
  font-family: inherit;
  font-size: 50px;
  font-weight: 300;
  line-height: 1.2;
  color: var(--cf-text);
}
.cf-intro__list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 21px;
  font-weight: 400;
  color: var(--cf-text);
}
.cf-intro__list li {
  display: flex;
  align-items: baseline;
  gap: 0.4em;
}
.cf-intro__list li::before {
  content: "✓";
}
.cf-screen--intro .cf-actions {
  justify-content: center;
  margin-top: 48px;
}
@media (max-width: 500px) {
  .cf-intro__title {
    font-size: 30px;
  }
  .cf-intro__list {
    font-size: 16px;
  }
  .cf-screen--intro .cf-actions {
    margin-top: 30px;
  }
}

.cf-noscript {
  margin-top: 1.75rem;
  max-width: 34rem;
}
.cf-noscript a {
  color: var(--cf-accent);
}

/* ---- Frage-Bildschirme ------------------------------------------- *
 * Die laufende Nummer steht als „1." im linken Rand neben der Frage; auf
 * schmalen Geräten rückt sie vor den Text. */
.cf-screen__q {
  position: relative;
  margin: 0 0 11px;
  font-family: inherit;
  font-size: 23px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--cf-text);
}
.cf-screen__num {
  position: absolute;
  left: -36px;
  font-weight: 300;
}
.cf-req {
  color: var(--cf-error);
}
@media (max-width: 500px) {
  .cf-screen__num {
    position: static;
    margin-right: 5px;
  }
}

/* ---- Antwortmöglichkeiten ---------------------------------------- *
 * Eine Möglichkeit je Zeile, volle Breite – wie in der Quelle. */
.cf-options {
  display: block;
  margin: 0;
}
.cf-option {
  position: relative;
  display: block;
  min-height: 52px;
  margin-bottom: 15px;
  padding: 9px 9px 9px 50px;
  border: 1px solid var(--cf-line);
  border-radius: 4px;
  background-color: var(--cf-fill);
  color: var(--cf-text);
  font-size: 18px;
  line-height: 33px;
  cursor: pointer;
}
.cf-option input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  margin: 0;
  padding: 0;
}
/* Buchstaben-Kürzel links in der Antwort. */
.cf-option__key {
  position: absolute;
  top: 9px;
  left: 10px;
  display: block;
  width: 33px;
  height: 33px;
  border: 1px solid var(--cf-line-strong);
  border-radius: 3px;
  background-color: transparent;
  color: var(--cf-text);
  font-size: 16px;
  line-height: 30px;
  text-align: center;
  white-space: nowrap;
  transition: width 0.1s ease, left 0.1s ease;
}
.cf-option__key::before {
  content: "";
}
.cf-option__text {
  display: block;
}
.cf-option:has(input:checked) {
  border-color: var(--cf-line-strong);
}
.cf-option:has(input:checked) .cf-option__key {
  border-color: var(--cf-text);
  background-color: var(--cf-text);
  color: #fff;
}
.cf-option:has(input:focus-visible) {
  outline: 3px solid var(--cf-accent);
  outline-offset: 2px;
}
/* Am Zeigergerät wächst das Kürzel beim Überfahren zu „Key A" – wie in der
   Quelle, die dort die Tastenbelegung zeigt. */
@media (min-width: 769px) {
  .cf-option:hover {
    background-color: var(--cf-fill-hover);
  }
  .cf-option:not(:has(input:checked)):hover .cf-option__key {
    left: -24px;
    width: 67px;
    border-color: var(--cf-text);
    background-color: #d9e5f0;
  }
  .cf-option:not(:has(input:checked)):hover .cf-option__key::before {
    content: "Key\00a0";
  }
}
@media (prefers-reduced-motion: reduce) {
  .cf-option__key {
    transition: none;
  }
}
/* Auf Telefon und Tablet zeigt die Quelle statt des Buchstabens einen
   runden Auswahlpunkt – gefüllt, sobald die Antwort gewählt ist. */
@media (max-width: 768px) {
  .cf-option__key {
    border-radius: 50%;
    font-size: 0;
  }
  .cf-option:has(input:checked) .cf-option__key::before {
    content: "";
    display: block;
    width: 13px;
    height: 13px;
    margin: 9px auto;
    border-radius: 50%;
    background-color: #fff;
  }
  .cf-options--consent .cf-option__key {
    border-radius: 3px;
  }
  .cf-options--consent .cf-option:has(input:checked) .cf-option__key::before {
    content: "✓";
    width: auto;
    height: auto;
    margin: 0;
    background: none;
    font-size: 18px;
    line-height: 30px;
  }
}

/* ---- Eingabefelder ------------------------------------------------ *
 * Ohne seitliche Polsterung: Das Eingegebene steht damit genau unter dem
 * ersten Buchstaben der Frage, so wie in der Quelle. */
.cf-input input {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  height: 66px;
  padding: 10px 0;
  border: none;
  border-bottom: 1px solid rgba(26, 61, 92, 0.1);
  border-radius: 0;
  background-color: transparent;
  color: var(--cf-text);
  font-family: inherit;
  font-size: 30px;
  font-weight: 400;
  line-height: normal;
}
.cf-input input::placeholder {
  color: var(--cf-text);
  opacity: 0.35;
}
.cf-input input:focus {
  outline: none;
  border-bottom: 2px solid var(--cf-accent);
  padding-bottom: 9px;
}
.cf-screen--error .cf-input input {
  border-bottom-color: var(--cf-error);
}
@media (max-width: 500px) {
  .cf-input input {
    font-size: 24px;
  }
}
.cf-error {
  display: block;
  margin: 10px 0 17px;
  color: var(--cf-error);
  font-weight: 400;
  line-height: 1.3;
}

/* ---- Einwilligung -------------------------------------------------- */
.cf-consent-text {
  margin: 30px 0 0;
  color: var(--cf-text);
}
.cf-consent-text a {
  color: var(--cf-accent);
}

/* ---- Schaltflächen und Tastatur-Hinweise -------------------------- *
 * Schaltflächen tragen in der Quelle nur der Startbildschirm und der
 * Absende-Bildschirm; Eingabefelder haben keine. */
.cf-actions {
  display: flex;
  align-items: center;
  margin-top: 48px;
}
/* Auf schmalen Geräten rückt der Knopf näher an das Feld – wie in der Quelle. */
@media (max-width: 500px) {
  .cf-actions {
    margin-top: 30px;
  }
}
.cf-btn {
  padding: 12px 31px;
  border: 0;
  border-radius: 3px;
  background-color: var(--cf-accent);
  box-shadow: 0 3px 10px 0 rgba(0, 0, 0, 0.15);
  color: #fff;
  font-family: inherit;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.5;
  cursor: pointer;
}
/* Der Startknopf trägt als einziger den Pfeil der Angebots-Schaltflächen. Er
   läuft im Textfluss mit, damit er auf schmalen Geräten hinter dem letzten
   Wort steht und nicht am Rand hängen bleibt. */
.cf-btn--start {
  display: inline-block;
  text-align: center;
}
.cf-btn--start svg {
  display: inline-block;
  width: 1.1em;
  height: 1.1em;
  margin-left: 0.4em;
  vertical-align: -0.15em;
}
@media (max-width: 500px) {
  .cf-btn--start {
    padding: 12px 20px;
  }
}
.cf-btn:hover,
.cf-btn:focus {
  background-color: var(--cf-accent-hover);
  box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.15);
}
.cf-btn:active {
  background-color: var(--cf-accent-active);
  box-shadow: none;
}
.cf-btn:disabled {
  box-shadow: none;
  opacity: 0.5;
  cursor: progress;
}
.cf-btn:focus-visible {
  outline: 3px solid var(--cf-text);
  outline-offset: 2px;
}
/* Hinweis neben dem Startknopf – in der Quelle in voller Textfarbe. */
.cf-hint {
  margin: 0;
  margin-inline-start: 30px;
  color: var(--cf-text);
  font-size: 18px;
}
.cf-hint strong {
  color: var(--cf-text);
  font-weight: 700;
}
@media (max-width: 500px) {
  .cf-hint {
    display: none;
  }
}
/* Der Hinweis unter der Einwilligung steht als eigene Zeile unter dem Feld –
   und nur am aktiven Feld, wie in der Quelle. */
.cf-hint--field {
  margin: 12px 0 0;
  color: var(--cf-muted);
  font-size: 16px;
}
.cf-screen:not(.is-active) .cf-hint--field {
  visibility: hidden;
}
@media (max-width: 500px) {
  .cf-hint--field {
    display: block;
  }
}

/* ---- Absende-Bildschirm ------------------------------------------- */
.cf-screen--submit .cf-actions {
  margin-top: 30px;
}
.cf-alert {
  margin-top: 17px;
  padding: 15px 20px;
  border: 1px solid rgba(219, 75, 91, 0.35);
  border-radius: 4px;
  background-color: rgba(219, 75, 91, 0.06);
  color: var(--cf-error);
  line-height: 1.4;
}

/* ---- Fußleiste: Fortschritt, Rechtslinks, Sprungtasten ------------ */
.cf__footer {
  z-index: 2;
  box-sizing: border-box;
  height: 60px;
  overflow: hidden;
  background-color: var(--cf-text);
  color: var(--cf-footer-text);
  font-size: 13px;
  transition: height 0.25s ease-in-out;
}
/* Auf dem Startbildschirm ist die Leiste eingefahren – wie in der Quelle. */
.cf.is-start .cf__footer {
  height: 0;
}
@media (prefers-reduced-motion: reduce) {
  .cf__footer {
    transition: none;
  }
}
.cf__footer-wrap {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 0 15px;
  max-width: 830px;
  margin-inline: auto;
  padding: 15px;
}
.cf-progress__status {
  margin: 0 0 8px;
  line-height: 1;
  opacity: 0.75;
}
.cf-progress__track {
  position: relative;
  width: 237px;
  max-width: 100%;
  height: 10px;
  border-radius: 10px;
  background-color: rgba(0, 0, 0, 0.251);
}
.cf-progress__bar {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  border-radius: 10px;
  background-color: var(--cf-accent);
  transition: width 0.35s ease;
}
@media (max-width: 500px) {
  .cf-progress__track {
    width: 140px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cf-progress__bar {
    transition: none;
  }
}
.cf__footer-right {
  display: flex;
  align-items: center;
  opacity: 0.75;
}
/* Pflichtangabe der deutschen Anbieterkennzeichnung – die Quelle führte
   Impressum und Datenschutz nur im Einwilligungstext, hier stehen sie
   zusätzlich dauerhaft erreichbar in der Leiste. */
.cf-footer__links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0 15px;
  opacity: 0.75;
}
.cf-footer__links a {
  color: inherit;
  text-decoration: none;
}
.cf-footer__links a:hover {
  text-decoration: underline;
}
.cf-footer__links a:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}
.cf-nav {
  display: flex;
  justify-content: space-between;
  width: 77px;
  margin-left: 20px;
}
.cf-nav__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 31px;
  height: 31px;
  padding: 0;
  border: 2px solid #fff;
  border-radius: 50%;
  background: none;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
}
.cf-nav__btn:disabled {
  opacity: 0.45;
  cursor: default;
}
.cf-nav__btn:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}
.cf-nav__btn svg {
  width: 1em;
  height: 1em;
}
.cf-nav__btn--up svg {
  transform: rotate(180deg);
}
@media (max-width: 768px) {
  .cf-nav {
    width: 96px;
    margin-top: -5px;
    margin-left: 15px;
  }
  .cf-nav__btn {
    width: 41px;
    height: 41px;
    font-size: 26px;
  }
}
/* Auf schmalen Geräten reicht die Zeile nicht für Fortschritt, Rechtslinks und
   Sprungtasten – die Links rücken dann in eine eigene Zeile darunter. */
@media (max-width: 600px) {
  .cf__footer {
    height: auto;
  }
  .cf__footer-wrap {
    align-items: center;
    gap: 8px 12px;
    padding: 12px 15px;
  }
  /* Fortschritt und Sprungtasten in einer Zeile, die Rechtslinks darunter. */
  .cf__footer-right {
    display: contents;
  }
  .cf-progress {
    order: 1;
  }
  .cf-nav {
    order: 2;
    margin-top: 0;
    opacity: 0.75;
  }
  .cf-footer__links {
    order: 3;
    width: 100%;
    font-size: 12px;
  }
}

/* ---- Spamfalle ---------------------------------------------------- */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.cf-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
