/*
 * Gäste-Webseite · Look A „wie in der App“ (Etappe 2, W1).
 * Farben und Maße folgen der App (AppColors, Weiches Weiß, Knopf 48,
 * dunkle Schrift auf Grün). Hell und dunkel.
 */
:root {
  color-scheme: light dark;
  --grund: #FFFFFF;
  --flaeche: #F4F5F6;
  --feld: #F1F3F4;
  --text: #252729;
  --neben: #5F666A;
  --leise: #8A9196;
  --linie: rgba(0, 0, 0, .07);
  --schatten: 0 2px 12px rgba(0, 0, 0, .10);
  --gruen: #22D982;
  --auf-gruen: #1E3B2E;
  --gruen-hell: #E6FAF1;
  --gruen-text: #107A4E;
  --orange: #FFBE6B;
  --auf-orange: #3B2A12;
  --orange-hell: #FFF1DD;
  --orange-text: #9A5A16;
  --dunkel: #2E3236;
  --auf-dunkel: #FFFFFF;
  --fehler: #B3261E;
  --karte-filter: none;
  /* Welt der Seite: body[data-welt] stellt um. */
  --akzent: var(--gruen);
  --auf-akzent: var(--auf-gruen);
  --akzent-hell: var(--gruen-hell);
  --akzent-text: var(--gruen-text);
}
@media (prefers-color-scheme: dark) {
  :root {
    --grund: #151618;
    --flaeche: #202124;
    --feld: #26282B;
    --text: #F2F2F3;
    --neben: #B4B9BC;
    --leise: #8A9196;
    --linie: rgba(255, 255, 255, .09);
    --schatten: 0 2px 12px rgba(0, 0, 0, .45);
    --gruen-hell: #173527;
    --gruen-text: #5BE3A0;
    --orange-hell: #382D20;
    --orange-text: #FFC985;
    --dunkel: #F2F2F3;
    --auf-dunkel: #151618;
    --fehler: #FF8A80;
    --karte-filter: brightness(.62) contrast(1.15) saturate(.7);
  }
}
body[data-welt="event"] {
  --akzent: var(--orange);
  --auf-akzent: var(--auf-orange);
  --akzent-hell: var(--orange-hell);
  --akzent-text: var(--orange-text);
}

html { font-size: 17px; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
/* iPhone: Textgröße aus den Systemeinstellungen (Dynamic Type). */
@supports (font: -apple-system-body) and (-webkit-touch-callout: none) {
  html { font: -apple-system-body; }
}
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--grund);
  color: var(--text);
  font-family: -apple-system, "SF Pro Text", "SF Pro", system-ui, "Segoe UI", Roboto, sans-serif;
  font-size: 1rem;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}
body.blatt-offen { overflow: hidden; }
h1, h2, p { margin: 0; }
a { color: inherit; }
button { font: inherit; color: inherit; }
img { display: block; }

.seite {
  max-width: 520px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}
.inhalt {
  flex: 1 0 auto;
  padding: 18px calc(20px + env(safe-area-inset-right)) 24px calc(20px + env(safe-area-inset-left));
}
@media (max-width: 359px) {
  .inhalt { padding-left: 16px; padding-right: 16px; }
}

/* ── Kopfbild: Flyer, Foto oder Karte (Max, 08.11.: Bild vor Karte) ── */
.kopfbild { position: relative; height: 236px; overflow: hidden; background: var(--flaeche); }
.kopfbild img.bild { width: 100%; height: 100%; object-fit: cover; }
/* Formate wie in der App: öffentlich 4:5 (Flyer), Treffen-Foto 3:2. */
.kopfbild.plakat { height: auto; aspect-ratio: 4 / 5; max-height: 72vh; }
.kopfbild.foto { height: auto; aspect-ratio: 3 / 2; }
.kopfbild.farbe { height: auto; aspect-ratio: 16 / 9; background: var(--orange-hell); }
.kopfbild.ohne-bild { height: 120px; aspect-ratio: auto; }
@media (min-width: 521px) {
  .kopfbild { border-radius: 0 0 24px 24px; }
}

/* Die Karte: MapLibre mit dem Stil der App (webseite/karte/). */
.karte { position: absolute; inset: 0; overflow: hidden; background: var(--flaeche); }
.karte.antippbar { cursor: pointer; }
/* Spezifischer als .maplibregl-map (dort position: relative → Höhe 0). */
.karte > .karte-flaeche, .karte > .karte-flaeche.maplibregl-map { position: absolute; inset: 0; }
.karte-flaeche.karte-ohne {
  background: radial-gradient(circle at 50% 50%, var(--gruen-hell) 0%, var(--flaeche) 70%);
}
.karte .maplibregl-ctrl-attrib { font-size: .62rem; }
/* Erst zeigen, wenn er als kleines „i“ zugeklappt ist (kein Aufblitzen). */
.karte .maplibregl-ctrl-attrib:not(.zu) { visibility: hidden; }
.karte-mitte {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  pointer-events: none;
}
.mitte-spalte { display: flex; flex-direction: column; align-items: center; gap: 8px; }
/* Gesichter auf der Karte wie im Treffen-Blatt der App: 48 pt, überlappend. */
.karte-mitte .stapel .kopf { width: 48px; height: 48px; margin-left: -14px; font-size: 1rem; box-shadow: var(--schatten); }
.karte-mitte .stapel .kopf:first-child { margin-left: 0; }
.pille {
  display: inline-flex; align-items: center; gap: 7px;
  min-height: 34px; padding: 6px 14px;
  border-radius: 999px; background: var(--dunkel); color: var(--auf-dunkel);
  font-weight: 700; font-size: .85rem; box-shadow: var(--schatten);
  max-width: 78vw; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pille i { width: 9px; height: 9px; border-radius: 50%; background: var(--gruen); display: inline-block; flex: none; }
.pille-ort { color: #7CC4F2; display: inline-flex; flex: none; }
.pille-ort svg circle { fill: var(--dunkel); }

/* ── Gesichter ─────────────────────────────────────────────────── */
.kopf {
  flex: none; width: 28px; height: 28px; border-radius: 50%;
  object-fit: cover; background: var(--akzent-hell); color: var(--akzent-text);
  display: inline-grid; place-items: center; font-weight: 800; font-size: .72rem;
  overflow: hidden;
}
.kopf.m { width: 44px; height: 44px; font-size: .95rem; }
.stapel { display: flex; }
.stapel .kopf { width: 40px; height: 40px; border: 3px solid var(--grund); margin-left: -12px; font-size: .85rem; }
.stapel .kopf:first-child { margin-left: 0; }

/* ── Text ──────────────────────────────────────────────────────── */
.wer { display: flex; align-items: center; gap: 9px; color: var(--neben); font-weight: 600; font-size: .92rem; margin-bottom: 8px; }
.wer b { color: var(--text); }
h1 {
  font-size: 1.62rem; line-height: 1.14; font-weight: 800; letter-spacing: -.02em;
  overflow-wrap: anywhere;
  -webkit-hyphens: auto; hyphens: auto;
}
.unterzeile { color: var(--neben); font-weight: 600; margin-top: 4px; }
.etikett {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--akzent-text); margin-bottom: 8px;
}
.notiz { color: var(--neben); font-weight: 500; margin-top: 14px; white-space: pre-line; overflow-wrap: anywhere; }

/* ── Zeilen ────────────────────────────────────────────────────── */
.zeilen { margin-top: 14px; }
.zeile { display: flex; align-items: center; gap: 14px; padding: 12px 0; font-weight: 600; min-height: 48px; }
.zeile + .zeile { border-top: 1px solid var(--linie); }
.zeile > svg { flex: none; color: var(--text); }
.zeile .text { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.zeile small { display: block; font-size: .8rem; color: var(--neben); font-weight: 500; margin-top: 2px; }
.zeile-link { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
.zeile-link .pfeil { margin-left: auto; color: var(--leise); display: inline-flex; flex: none; }
.zeile-link:focus-visible { outline: 3px solid var(--akzent-text); outline-offset: 2px; border-radius: 8px; }
.zeile .tun {
  margin-left: auto; flex: none;
  display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px;
  border-radius: 999px; background: var(--flaeche);
  font-weight: 700; font-size: .85rem; text-decoration: none; white-space: nowrap;
}

/* ── Hinweis-Karten ────────────────────────────────────────────── */
.hinweis {
  display: flex; gap: 12px; align-items: flex-start;
  margin-top: 16px; padding: 14px 16px; border-radius: 18px;
  background: var(--flaeche); font-weight: 600;
}
.hinweis svg { flex: none; margin-top: 1px; }
.hinweis small { display: block; color: var(--neben); font-weight: 500; margin-top: 2px; }
.hinweis.gruen { background: var(--gruen-hell); color: var(--gruen-text); }
.hinweis.gruen small { color: var(--gruen-text); opacity: .85; }
.hinweis .textknopf { display: block; }
.textknopf {
  background: none; border: 0; padding: 0; margin-top: 6px;
  font-weight: 700; text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
  min-height: 32px;
}

/* ── App-Karte ─────────────────────────────────────────────────── */
.app-karte {
  display: flex; gap: 12px; align-items: center;
  margin-top: 18px; padding: 14px; border-radius: 18px; background: var(--flaeche);
}
.app-karte .ic { width: 44px; height: 44px; border-radius: 11px; background: var(--text); display: grid; place-items: center; flex: none; }
.app-karte .ic i { width: 16px; height: 16px; border-radius: 50%; background: var(--gruen); }
.app-karte b { display: block; font-size: .92rem; }
.app-karte span { font-size: .8rem; color: var(--neben); }
.app-karte a {
  margin-left: auto; flex: none; min-height: 36px; padding: 0 16px; border-radius: 999px;
  background: var(--text); color: var(--grund); display: inline-flex; align-items: center;
  font-weight: 700; font-size: .85rem; text-decoration: none;
}

/* ── Knöpfe und Fuß ────────────────────────────────────────────── */
.fuss {
  position: sticky; bottom: 0; z-index: 4;
  display: flex; gap: 10px;
  padding: 10px calc(16px + env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) calc(16px + env(safe-area-inset-left));
  background: var(--grund); border-top: 1px solid var(--linie);
}
.knopf {
  flex: 1; min-height: 48px; padding: 0 18px; border: 0; border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 700; font-size: 1rem; cursor: pointer; text-decoration: none; text-align: center;
  -webkit-tap-highlight-color: transparent;
}
.knopf.haupt { background: var(--akzent); color: var(--auf-akzent); flex: 1.6; }
.knopf.grau { background: var(--feld); color: var(--text); }
.knopf.dunkel { background: var(--dunkel); color: var(--auf-dunkel); }
.knopf.voll { width: 100%; flex: none; }
.knopf[disabled] { opacity: .55; cursor: default; }
.knopf:focus-visible, .textknopf:focus-visible, .tun:focus-visible, .feld:focus-visible { outline: 3px solid var(--akzent-text); outline-offset: 2px; }
.kreisel {
  width: 18px; height: 18px; border-radius: 50%;
  border: 2.5px solid currentColor; border-right-color: transparent;
  animation: dreh .8s linear infinite;
}
@keyframes dreh { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .kreisel { animation-duration: 2.4s; } }

.unten-text { padding: 18px 20px 28px; text-align: center; font-size: .78rem; color: var(--leise); }
.unten-text a { color: var(--neben); }

/* ── Ganzseitige Hinweise ──────────────────────────────────────── */
.mitte-seite { flex: 1 0 auto; display: flex; flex-direction: column; justify-content: center; padding: 32px 24px; text-align: center; gap: 10px; }
.mitte-seite .rund {
  width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 6px;
  display: grid; place-items: center; background: var(--flaeche); color: var(--neben);
}
.mitte-seite .rund.gruen { background: var(--gruen-hell); color: var(--gruen-text); }
.mitte-seite p { color: var(--neben); }
.mitte-seite .knopf { margin-top: 12px; flex: none; }

/* ── Dabei-Kopf ────────────────────────────────────────────────── */
.dabei-kopf { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.dabei-kopf .haken { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--akzent); color: var(--auf-akzent); flex: none; }
.dabei-kopf b { font-size: 1.1rem; }

/* ── Skelett ───────────────────────────────────────────────────── */
.skelett { background: var(--flaeche); border-radius: 10px; }
.skelett.titel { height: 30px; width: 70%; margin: 8px 0 18px; }
.skelett.zeile-s { height: 18px; width: 55%; margin: 16px 0; }

/* ── Blatt von unten ───────────────────────────────────────────── */
.schleier {
  position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0, .34);
  display: flex; align-items: flex-end; justify-content: center;
  animation: einblenden .18s ease-out;
}
.blatt {
  width: 100%; max-width: 520px; max-height: 92dvh; overflow-y: auto;
  background: var(--grund); border-radius: 28px 28px 0 0;
  padding: 10px calc(20px + env(safe-area-inset-right)) calc(22px + env(safe-area-inset-bottom)) calc(20px + env(safe-area-inset-left));
  animation: hoch .24s cubic-bezier(.2, .8, .2, 1);
}
@keyframes einblenden { from { opacity: 0; } }
@keyframes hoch { from { transform: translateY(40px); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .schleier, .blatt { animation: none; } }
.griff { width: 40px; height: 5px; border-radius: 999px; background: var(--feld); margin: 0 auto 16px; }
.blatt h2 { font-size: 1.3rem; font-weight: 800; letter-spacing: -.01em; }
.blatt .satz { color: var(--neben); margin: 6px 0 16px; }
.feld {
  width: 100%; min-height: 54px; border: 0; border-radius: 14px; background: var(--feld);
  padding: 0 16px; font-size: 1.05rem; color: var(--text); font-weight: 600;
  display: flex; align-items: center;
}
input.feld { -webkit-appearance: none; appearance: none; }
input.feld::placeholder { color: var(--leise); font-weight: 500; }
.feld.code { justify-content: center; text-align: center; font-size: 1.6rem; letter-spacing: .5em; padding-left: calc(16px + .5em); font-variant-numeric: tabular-nums; }
label.beschriftung { display: block; font-size: .8rem; font-weight: 700; color: var(--neben); margin: 0 0 6px 4px; }
.blatt .knopf { margin-top: 14px; }
.klein { font-size: .8rem; color: var(--neben); line-height: 1.4; margin-top: 12px; }
.klein a { color: var(--text); }
.meldung { color: var(--fehler); font-weight: 600; font-size: .88rem; margin-top: 10px; min-height: 0; }
.blatt-zeile { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 14px; }

/* ── Demo-Liste ────────────────────────────────────────────────── */
.demo-liste { columns: 2; padding-left: 20px; }
.demo-liste li { margin: 6px 0; }

/* ── Gästeliste (0174) ─────────────────────────────────────────────── */
.gratis {
  display: inline-flex; align-items: center; margin: 4px 0 2px; padding: 4px 11px;
  border-radius: 999px; background: var(--orange-hell); color: var(--orange-text);
  font-weight: 800; font-size: .8rem;
}
.gast-code { text-align: center; }
.gast-code .zeilen, .gast-code .hinweis, .gast-code .app-karte { text-align: left; }
.gast-code .unterzeile { margin-bottom: 4px; }
.qr-feld {
  width: min(260px, 74vw); aspect-ratio: 1; margin: 14px auto 12px; padding: 10px;
  background: #FFFFFF; border-radius: 22px; border: 1px solid var(--linie);
  display: grid; place-items: center;
}
.qr-feld svg { width: 100%; height: 100%; display: block; }
.code-satz { font-weight: 700; margin: 0 0 4px; }
.drin { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 18px 0 8px; }
.drin .haken {
  width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center;
  background: var(--akzent); color: var(--auf-akzent);
}
.drin p { font-weight: 700; }
.mitte-text { text-align: center; margin-top: 16px; }
.mitte-text .textknopf { display: inline; padding: 0; font-size: inherit; }

