/* ════════════════════════════════════════════════════════════════
   ANALYSE — mehrstufiges Quiz
   Erbt Farben, Schrift und Knoepfe aus styles.css.
   ════════════════════════════════════════════════════════════════ */

.quizseite { min-height: 100svh; display: flex; flex-direction: column; }

/* Nur fuer Screenreader. Traegt die Seitenueberschrift, ohne sie zu
   zeigen: sichtbar waere sie hier ein zweiter Titel neben der Frage. */
.nur-vorlesen {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

.qkopf {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px;
  padding: 22px calc(var(--gutter) + var(--sicher-r)) 22px calc(var(--gutter) + var(--sicher-l));
}
.qkopf__schritt {
  margin: 0;
  font-size: 12px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--ink-mute);
  font-variant-numeric: tabular-nums;
}

/* Der Balken sitzt ueber der ganzen Breite. Er startet nicht bei null:
   ein bereits begonnener Fortschritt wird deutlich haeufiger zu Ende
   gebracht als einer, der bei null anfaengt. */
.qbalken {
  height: 2px;
  background: rgba(255, 255, 255, .1);
  overflow: hidden;
}
/* Ueber transform statt width: laeuft im Kompositor und erzeugt kein
   Neuberechnen des Layouts in jedem Bild. */
.qbalken__fuell {
  display: block; height: 100%; width: 100%;
  background: var(--paper);
  transform: scaleX(.12);
  transform-origin: left;
  transition: transform .55s var(--ease);
}

.quiz {
  flex: 1;
  display: flex; align-items: center;
  padding: clamp(36px, 7vh, 80px) calc(var(--gutter) + var(--sicher-r))
           calc(clamp(48px, 9vh, 100px) + var(--sicher-u)) calc(var(--gutter) + var(--sicher-l));
}
.quiz__form { width: 100%; max-width: 660px; margin: 0 auto; }

/* Eine Frage je Bild. Weniger auf einmal heisst weniger Aufwand pro
   Entscheidung und deutlich weniger Abbrueche. */
.frage {
  border: 0; margin: 0; padding: 0;
  display: none;
}
.frage.is-aktiv { display: block; animation: frageAn .45s var(--ease) both; }
@keyframes frageAn {
  from { opacity: 0; transform: translateY(14px); filter: blur(6px); }
  to   { opacity: 1; transform: none; filter: none; }
}

.frage__titel {
  padding: 0;
  font-size: clamp(23px, 3vw, 34px);
  font-weight: 700; line-height: 1.16; letter-spacing: -.03em;
  color: var(--ink);
  text-wrap: balance;
}
.frage__hilfe {
  margin: 12px 0 0;
  font-size: clamp(14px, 1.05vw, 15.5px);
  line-height: 1.55; color: var(--ink-mute);
}

.wahl { margin-top: clamp(26px, 3.4vw, 38px); display: flex; flex-direction: column; gap: 10px; }
.wahl__opt {
  display: flex; align-items: center; gap: 14px;
  width: 100%; padding: 17px 18px;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(255,255,255,.045), rgba(255,255,255,.012));
  color: var(--ink-dim);
  font-size: clamp(14.5px, 1.1vw, 16px);
  line-height: 1.35;
  cursor: pointer;
  transition: border-color .2s var(--ease), background-color .2s var(--ease), color .2s var(--ease);
}
.wahl__opt:hover { border-color: rgba(255,255,255,.3); color: var(--ink); }

/* Die Zifferntaste zeigt, dass die Tastatur geht. Das beschleunigt
   geuebte Nutzer und wirkt wie ein Spiel statt wie ein Formular. */
.wahl__taste {
  flex: none;
  display: grid; place-items: center;
  width: 24px; height: 24px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,.14);
  font-size: 11px; font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--ink-mute);
  transition: border-color .2s var(--ease), color .2s var(--ease), background-color .2s var(--ease);
}
.wahl__opt.is-gewaehlt {
  border-color: rgba(255,255,255,.42);
  background: linear-gradient(160deg, rgba(255,255,255,.12), rgba(255,255,255,.03));
  color: var(--ink);
}
.wahl__opt.is-gewaehlt .wahl__taste {
  border-color: transparent;
  background: var(--paper);
  color: var(--on-paper);
}

/* ─────────── Kontaktfelder ─────────── */
.feld { margin-top: 20px; }
.feld label {
  display: block; margin-bottom: 8px;
  font-size: 13px; font-weight: 700; letter-spacing: -.01em;
  color: var(--ink-dim);
}
.feld__opt { font-weight: 400; color: var(--ink-mute); }
.feld input {
  width: 100%; height: 52px; padding: 0 16px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 11px;
  background: rgba(255,255,255,.03);
  color: var(--ink);
  font: inherit; font-size: 16px;   /* 16px verhindert das Zoomen auf iOS */
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
.feld input::placeholder { color: rgba(255,255,255,.3); }
/* Nur bei Tastaturbedienung ein Ring, beim Klicken nicht. Der reine
   Randwechsel war als Fokusanzeige zu schwach. */
.feld input:focus { border-color: rgba(255,255,255,.45); background: rgba(255,255,255,.05); }
.feld input:focus-visible { outline: 2px solid var(--paper); outline-offset: 3px; }
.feld input.is-fehler { border-color: var(--warnung-rand); }
/* Begruendung genau dort, wo die Hemmung entsteht. Eine genannte
   Begruendung erhoeht die Bereitschaft messbar, auch wenn sie
   selbstverstaendlich klingt. */
.feld__hinweis { margin: 8px 0 0; font-size: 12.5px; color: var(--ink-mute); }

.zustimmung {
  display: flex; align-items: flex-start; gap: 11px;
  margin-top: 26px;
  font-size: 13px; line-height: 1.5; color: var(--ink-mute);
  cursor: pointer;
}
.zustimmung input { flex: none; width: 18px; height: 18px; margin-top: 1px; accent-color: var(--paper); }
.zustimmung a { color: var(--ink-dim); border-bottom: 1px solid rgba(255,255,255,.28); }
.zustimmung a:hover { color: var(--ink); }

.frage__fehler {
  margin: 18px 0 0;
  font-size: 13.5px; line-height: 1.5; color: var(--warnung);
}

.verdeckt { display: none; }

.qsteuer {
  margin-top: clamp(28px, 4vw, 40px);
  display: flex; align-items: center; gap: 22px;
}
.qzurueck {
  border: 0; background: none; padding: 8px 0;
  font-size: 14px; color: var(--ink-mute);
  cursor: pointer;
  transition: color .2s var(--ease);
}
.qzurueck:hover { color: var(--ink); }
/* Bei Einfachauswahl springt die Seite von selbst weiter, der Knopf
   waere dann nur ein zusaetzlicher Klick. */
.qweiter[hidden] { display: none; }

/* ─────────── Abschluss ─────────── */
.fertig {
  width: 100%; max-width: 560px; margin: 0 auto;
  text-align: center;
  animation: frageAn .6s var(--ease) both;
}
.fertig__marke {
  margin: 0 auto 26px;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(207, 212, 221, .38);
  background: linear-gradient(150deg, rgba(255,255,255,.13), rgba(255,255,255,.02));
  color: var(--silber);
}
.fertig__marke svg { width: 20px; height: 20px; }
.fertig__titel {
  margin: 0;
  font-size: clamp(28px, 3.4vw, 42px);
  font-weight: 700; letter-spacing: -.03em; line-height: 1.1;
}
.fertig__text {
  margin: 16px auto 32px;
  max-width: 42ch;
  font-size: clamp(14.5px, 1.05vw, 16px);
  line-height: 1.6; color: var(--ink-mute);
}

@media (max-width: 560px) {
  .wahl__opt { padding: 15px 15px; }
  .qkopf { padding: 18px var(--gutter); }
}

@media (prefers-reduced-motion: reduce) {
  .frage.is-aktiv, .fertig { animation: none; }
  .qbalken__fuell { transition: none; }
  .wahl__opt, .feld input { transition: none; }
}

/* Honigtopf. Nicht display:none, das ueberspringen manche Bots
   absichtlich. Stattdessen aus dem Bild geschoben. */
.honig {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  overflow: hidden;
}
