/* Anmeldeseite (/login) aller drei Portale. Nur Farbtokens aus app.css, Abstände im 4-px-Raster, kein Verlauf, keine Glasfläche, kein Schatten.
   Aufbau: links die Anmeldung (eine Hauptaktion), rechts die Zusagen zu den Daten, darunter der erste Weg in drei Schritten mit dem Platz für das Video.
   Szene „Horizont“ (partials/szene-horizont.ejs, css/szene-horizont.css) steht über der Anmeldung: ab 900 px Kopf der linken Spalte, darunter oben über die volle Breite.
   Bewegung: nur Farbwechsel beim Überfahren, bei „reduzierte Bewegung“ ohne Übergang; die Szene bewegt sich nach ihren eigenen Regeln. */

.an {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  grid-template-areas: "start erst" "nach erst" "weg zusagen" "demo demo";
  column-gap: 96px;
  align-items: start;
  max-width: 1120px;
  margin: 0 auto;
  padding-top: 40px;
}
.an-start { grid-area: start; min-width: 0; }
.an-start > .hz { margin-bottom: 32px; }
.an-zusagen { grid-area: zusagen; min-width: 0; }
.an-erst { grid-area: erst; min-width: 0; }
.an-nach { grid-area: nach; min-width: 0; }
.an-weg { grid-area: weg; min-width: 0; }
.an .demo-access { grid-area: demo; margin-top: 64px; }
.an .role-grid .btn { min-height: 44px; }

/* ---------- Anmeldung ---------- */
.an-portal { margin: 0 0 8px; color: var(--brand); font: 600 16px/1.4 var(--sans); overflow-wrap: anywhere; }
.an h1 { font-size: clamp(2.25rem, 4.4vw, 3.5rem); line-height: 1.05; letter-spacing: -0.035em; }
.an-nutzen { margin: 20px 0 0; max-width: 34ch; font-size: 1.25rem; line-height: 1.5; color: var(--ink); text-wrap: pretty; overflow-wrap: anywhere; }

.an-haupt { margin-top: 36px; max-width: 440px; }
.an-ms { display: flex; width: 100%; min-height: 56px; justify-content: center; font-size: 17px; border-radius: 8px; }
.an-ms:focus-visible, .an-go:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.an-ms[aria-busy="true"] { background: var(--brand-dark); cursor: progress; }
.an-konto { margin: 12px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
/* Kurzfassung der Zusagen mit Sprung zum Abschnitt (die Zusagen stehen unter Anmeldung und Video) */
.an-kurz { display: block; margin: 4px 0 0; font-size: 14px; }
.an-kurz a { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink); font-weight: 600; text-underline-offset: 4px; }
.an-kurz a:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.an-zusagen:focus { outline: none; }

.an-pruefen { margin-top: 36px; padding-top: 28px; max-width: 440px; border-top: 1px solid var(--rule); }
.an-pruefen h2 { margin: 0; font-size: 1.05rem; line-height: 1.35; }
.an-hinweis { margin: 6px 0 16px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.an-label { display: block; margin: 0 0 6px; font-weight: 600; font-size: 14px; }
.an-zeile { display: flex; flex-wrap: wrap; gap: 8px; }
.an-feld { flex: 1 1 14rem; min-width: 0; min-height: 48px; padding: 8px 12px; border: 1px solid var(--control); border-radius: 8px; background: var(--surface); color: var(--ink); font: 400 16px var(--sans); }
.an-feld::placeholder { color: var(--muted); opacity: 1; }
.an-feld:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; border-color: var(--brand); }
.an-go { min-height: 48px; min-width: 96px; justify-content: center; padding-inline: 20px; border-radius: 8px; background: var(--surface); }
.an-go[aria-busy="true"] { cursor: progress; color: var(--muted); border-color: var(--control); }
.an-status { margin: 8px 0 0; min-height: 0; color: var(--muted); font-size: 14px; }
.an-status:empty { display: none; }

.an-hilfe { display: flex; flex-wrap: wrap; gap: 0 24px; margin: 20px 0 0; font-size: 15px; }
.an-hilfe a { display: inline-flex; align-items: center; min-height: 44px; color: var(--link); text-underline-offset: 4px; }
.an-hilfe a:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.an-aus { margin: 32px 0 0; max-width: 46ch; padding: 16px 20px; border: 1px solid var(--warn); border-radius: 8px; background: var(--surface); }

/* ---------- Zusagen ---------- */
.an-zusagen { margin-top: 72px; }
.an-z-flaeche { padding: 32px 32px 20px; background: var(--surface); border: 1px solid var(--hairline); border-radius: 12px; }
.an-zusagen h2 { margin: 0 0 8px; font-size: 1.05rem; line-height: 1.35; }
.an-zusagen dl { margin: 0; }
.an-zusagen dl > div { padding: 16px 0; border-top: 1px solid var(--hairline); }
.an-zusagen dl > div:first-child { border-top: 0; }
.an-zusagen dt { font-weight: 700; font-size: 16px; line-height: 1.35; }
.an-zusagen dd { margin: 4px 0 0; color: var(--muted); font-size: 14px; line-height: 1.55; text-wrap: pretty; overflow-wrap: anywhere; }
.an-zusagen dd a { display: flex; align-items: center; width: fit-content; min-height: 44px; margin-bottom: -10px; color: var(--link); text-underline-offset: 3px; }
.an-zusagen .begl-buehne { max-width: none; margin-top: 8px; background: none; border: 0; }
.an-zusagen .begl-buehne .tr { width: 64px; height: 75px; }
.an-zusagen .begl-gruss { font-size: 14px; line-height: 1.5; }

/* ---------- Erster Weg ---------- */
.an-weg { margin-top: 72px; }
.an-weg h2 { margin: 0 0 28px; font-size: clamp(1.4rem, 2.2vw, 1.75rem); letter-spacing: -0.02em; }
.an-weg .vp-sprung { margin-top: 4px; }
.an-weg .vp-sprung-knopf { margin-left: -4px; }
.an-schritte { margin: 0; padding: 0; list-style: none; counter-reset: an-schritt; }
.an-schritte li { position: relative; padding: 0 0 24px 64px; counter-increment: an-schritt; }
.an-schritte li + li { padding-top: 24px; border-top: 1px solid var(--hairline); }
.an-schritte li::before {
  content: counter(an-schritt);
  position: absolute; left: 0; top: 0;
  width: 40px; height: 40px; display: grid; place-items: center;
  border: 2px solid var(--brand); border-radius: 50%;
  color: var(--brand); font: 700 17px/1 var(--sans);
}
.an-schritte li + li::before { top: 24px; }
.an-schritte h3 { margin: 0; padding-top: 8px; font-size: 1.05rem; line-height: 1.35; }
.an-schritte p { margin: 6px 0 0; color: var(--muted); font-size: 15px; line-height: 1.55; max-width: 56ch; overflow-wrap: anywhere; }

/* ---------- Zum ersten Mal hier: Video neben der Anmeldung (ab 900 px), darunter auf schmalen Bildschirmen ---------- */
.an-erst { margin-top: 8px; }
.an-erst h2 { margin: 0 0 8px; font-size: 1.25rem; line-height: 1.3; letter-spacing: -0.01em; }
.an-erst-satz { margin: 0 0 16px; max-width: 52ch; color: var(--muted); font-size: 15px; line-height: 1.55; overflow-wrap: anywhere; }
.an-video { min-width: 0; }
/* Umschalter der beiden Videos (nur mit Skript sichtbar): zwei gleich breite Knöpfe, der gewählte ist gefüllt */
.an-wahl:not([hidden]) { display: flex; gap: 0; margin: 0 0 16px; max-width: 520px; border: 1px solid var(--control); border-radius: 8px; overflow: hidden; background: var(--surface); }
.an-tab { flex: 1 1 0; min-width: 0; min-height: 44px; padding: 8px 12px; border: 0; background: transparent; color: var(--ink); font: 600 15px/1.3 var(--sans); cursor: pointer; }
.an-tab + .an-tab { border-left: 1px solid var(--control); }
.an-tab[aria-pressed="true"] { background: var(--brand); color: #fff; }
.an-tab:focus-visible { outline: 3px solid var(--focus); outline-offset: -3px; }
.an-tafel + .an-tafel { margin-top: 32px; }
.an-tafel[hidden] { display: none; }
.an-tafel:focus { outline: none; }
.an-admin a { font-weight: 400; }
.an-video .vp { margin: 0; max-width: none; }
.an-video .vp-text { font-size: 13.5px; }
.an-video .vp-kapitel { margin-top: 8px; }

.an-zusagen a:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* ---------- Bewegung: nur Rückmeldung, ohne Übergang bei „reduzierte Bewegung“ ---------- */
@media (prefers-reduced-motion: no-preference) {
  .an-feld { transition: border-color .15s var(--ease-out); }
}
@media (prefers-reduced-motion: reduce) {
  .an .btn { transition: none; }
}

/* ---------- Breiten ---------- */
@media (max-width: 1100px) {
  .an { column-gap: 56px; }
}
@media (max-width: 900px) {
  .an { grid-template-columns: minmax(0, 1fr); grid-template-areas: "start" "erst" "nach" "zusagen" "weg" "demo"; padding-top: 24px; }
  .an-zusagen { margin-top: 48px; max-width: 560px; }
  .an-haupt, .an-pruefen { max-width: 560px; }

  .an-weg { margin-top: 56px; }
  .an-erst { margin-top: 28px; max-width: 560px; }
}
@media (max-width: 640px) {
  .an { padding-top: 24px; }
  .an-start > .hz { margin-bottom: 20px; }
  .an h1 { font-size: 2.25rem; }
  .an-nutzen { margin-top: 12px; font-size: 1.1rem; }
  .an-haupt { margin-top: 24px; }
  .an-pruefen { margin-top: 28px; padding-top: 24px; }
  .an-erst h2 { margin-bottom: 6px; }
  .an-erst-satz { margin-bottom: 8px; font-size: 14.5px; }
  .an-go { flex: 1 1 100%; }
  /* Schmal: der Umschalter ist der Einstieg für die Administration (der Link darüber entfällt), damit das ganze Videobild im ersten Bildschirm bleibt. */
  .an-admin { display: none; }
  .an-erst h2 { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
  .an-wahl:not([hidden]) { margin-bottom: 8px; }
  .an-tab { padding: 6px 8px; font-size: 14px; }
  .an-z-flaeche { padding: 24px 20px 12px; }
  .an-schritte li { padding-left: 56px; }
}
@media (max-width: 599px) {
  /* Szene randlos direkt unter der Kopfzeile (Handy-Zuschnitt) */
  .an-start > .hz { margin: -24px -20px 20px; }
  .an-start > .hz .hz-bild { border-radius: 0; }
  .an-start > .hz .begl-gruss { margin-inline: 20px; }
}
