/* Familyday — Handy zuerst, grosse Schrift, keine externen Schriften.
   Farben aus dem Graffiti-Platzhalter; Task 8 passt sie ans gewählte Logo an. */
:root {
  --wand: #151515;          /* Startseite */
  --papier: #f5f6f3;        /* helle Seiten */
  --tinte: #1d2733;
  --grau: #5f6874;
  --rand: #5d6875;
  --rot: #e8192c;
  --blau: #1488e6;
  --gelb: #f7c600;
  --gruen: #48b82a;
  --plakat: "Avenir Next Condensed", "Roboto Condensed", "Arial Narrow", sans-serif-condensed, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }    /* sonst schlägt z. B. .knopf { display: flex } das hidden-Attribut */
html { font-size: 18px; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; line-height: 1.5;
       color: var(--tinte); background: var(--papier); }
main { max-width: 36rem; margin: 0 auto; padding: 1.25rem 1rem 3rem; }
@media (min-width: 700px) { main { padding: 2.5rem 2rem 4rem; } }
h1, h2, legend, .sticker, .kachel .name, .tipp { font-family: var(--plakat); font-weight: 800; }
h1 { font-size: 2.5rem; line-height: 1.05; margin: 0 0 .5rem; letter-spacing: -.01em; }
a { color: var(--tinte); text-decoration-color: var(--blau); text-decoration-thickness: 3px; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--blau); outline-offset: 3px; }
.leise { color: var(--grau); }

/* Knöpfe: harter Versatz-Schatten wie ein aufgeklebter Sticker; beim Antippen drückt er sich an die Wand */
.knopf { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 3.5rem;
         padding: .5rem 1.25rem; font: inherit; font-size: 1.2rem; font-weight: 700; text-decoration: none;
         color: #fff; background: var(--tinte); border: 3px solid var(--tinte); border-radius: 14px;
         box-shadow: 5px 5px 0 var(--rot); cursor: pointer; }
.knopf:active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--rot); }
.knopf:disabled { opacity: .7; cursor: progress; }
.knopf-hell { color: var(--tinte); background: #fff; box-shadow: 5px 5px 0 var(--blau); }
.knopf-hell:active { box-shadow: 2px 2px 0 var(--blau); }

/* ---------- Startseite ---------- */
body.dunkel { background: var(--wand); color: #eef0ea; }
body.dunkel main { max-width: 64rem; padding: 0 1rem; }
.buehne { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; align-items: center;
          justify-content: center; gap: 1.25rem; padding: 2rem 0; text-align: center; }
/* Seitenverhältnis aus den width/height-Attributen (echte Masse des Logos). Die Höhe ist begrenzt, damit der
   Hinweis darunter auch im Querformat sichtbar bleibt (9.5rem = Hinweis + Abstände); contain verzerrt nie. */
.logo { display: block; width: 100%; height: auto; margin: 0 auto; object-fit: contain;
        max-height: 70vh; max-height: min(70svh, calc(100svh - 9.5rem)); }
.eintreten { display: block; width: 100%; color: inherit; text-decoration: none; border-radius: 18px; }
.eintreten:focus-visible { outline: 4px solid var(--gelb); outline-offset: 6px; }
.tipp { display: inline-block; margin-top: 1.25rem; padding: .35rem 1rem .5rem; font-size: 1.5rem; color: #eef0ea;
        border-bottom: 4px solid var(--gelb); }
.tipp-ohne-link { max-width: 24rem; margin: 0; font-family: inherit; font-weight: 400; font-size: 1.2rem;
                  border: 0; color: #d9ddd5; }
@media (prefers-reduced-motion: no-preference) {
  /* «aufsprayen»: das Logo erscheint aus einer wachsenden Sprühwolke von links */
  .logo { animation: aufsprayen 1.3s cubic-bezier(.25, .7, .2, 1) both; }
  .tipp { animation: auftauchen .4s 1.1s ease-out both; }
  .eintreten .logo { transition: transform .2s ease-out; }
  .tritt-ein .logo { transform: scale(1.03); }
}
@keyframes aufsprayen {
  0%   { clip-path: circle(0% at 10% 45%); filter: blur(12px) saturate(.3); opacity: .5; }
  60%  { filter: blur(3px) saturate(.9); opacity: 1; }
  100% { clip-path: circle(120% at 10% 45%); filter: none; opacity: 1; }
}
@keyframes auftauchen { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Bestätigen ---------- */
.gruss { font-size: 2.6rem; }
.unterzeile { font-size: 1.25rem; margin: 0 0 1.5rem; }
.fehlerbox { margin: 0 0 1.5rem; padding: .75rem 1rem; background: #fdeae4; border: 3px solid var(--rot);
             border-radius: 12px; }
.fehlerbox p { margin: 0; font-weight: 700; }
.fehlerbox ul { margin: .25rem 0 0; padding-left: 1.25rem; }
.feld { margin-bottom: 1.25rem; }
.feld label { display: block; margin-bottom: .3rem; font-weight: 700; font-size: 1.1rem; }
.feld input { display: block; width: 100%; min-height: 3.5rem; padding: .5rem .9rem; font: inherit; font-size: 1.15rem;
              color: var(--tinte); background: #fff; border: 3px solid var(--rand); border-radius: 12px; }
.feld input:focus { border-color: var(--blau); outline: 3px solid var(--blau); outline-offset: 1px; }
.feld input[aria-invalid="true"] { border-color: var(--rot); }
.fehler { margin: .35rem 0 0; color: #a3300f; font-weight: 700; }
.hinweis { margin: 0; color: var(--grau); }
/* Trennlinie in den vier Spray-Farben */
.strich { height: 6px; margin: 2rem 0; border: 0; border-radius: 3px;
          background: linear-gradient(90deg, var(--rot) 0 25%, var(--gelb) 25% 50%, var(--gruen) 50% 75%, var(--blau) 75%); }
.wahl { margin: 0 0 2rem; padding: 0; border: 0; min-width: 0; }
.wahl legend { padding: 0; margin-bottom: .9rem; font-size: 1.7rem; line-height: 1.15; }
.option { display: flex; align-items: center; gap: .9rem; min-height: 4rem; margin-bottom: .9rem; padding: .6rem 1rem;
          font-size: 1.2rem; font-weight: 700; background: #fff; border: 3px solid var(--rand); border-radius: 14px;
          cursor: pointer; }
.option input { flex: none; width: 1.6rem; height: 1.6rem; margin: 0; accent-color: var(--tinte); }
.option:has(input:focus-visible) { outline: 3px solid var(--blau); outline-offset: 3px; }
.option-dabei:has(input:checked) { background: #e8f6df; border-color: var(--tinte); box-shadow: 5px 5px 0 var(--gruen); }
.option-nicht:has(input:checked) { background: #fde6de; border-color: var(--tinte); box-shadow: 5px 5px 0 var(--rot); }

/* ---------- Infoseite ---------- */
.kopf { margin-bottom: 2rem; }
.kopf h1 { font-size: 2.9rem; }
.datum { margin: 0; font-size: 1.25rem; font-weight: 700; }
.sticker { display: inline-block; margin: 1rem 0 0; padding: .3rem 1rem .4rem; font-size: 1.7rem; line-height: 1.2;
           background: var(--gelb); border: 3px solid var(--tinte); border-radius: 8px; box-shadow: 4px 4px 0 var(--rot);
           transform: rotate(-2.5deg); transform-origin: left center; }
.sticker[hidden] { display: none; }
.kacheln { display: grid; gap: 1.1rem; }
.kachel { --k: var(--blau); background: #fff; border: 3px solid var(--tinte); border-radius: 16px;
          box-shadow: 5px 5px 0 var(--k); }
.farbe-rot { --k: var(--rot); }
.farbe-blau { --k: var(--blau); }
.farbe-gruen { --k: var(--gruen); }
.farbe-gelb { --k: var(--gelb); }
.kachel summary, .kachel .zeile { display: flex; align-items: center; gap: .9rem; min-height: 4.5rem; padding: .6rem 1rem; }
.kachel summary { cursor: pointer; list-style: none; border-radius: 13px; }
.kachel summary::-webkit-details-marker { display: none; }
.kachel summary::after { content: ""; flex: none; width: .8rem; height: .8rem; margin: 0 .3rem 0 auto;
                         border-right: 3px solid var(--tinte); border-bottom: 3px solid var(--tinte);
                         transform: rotate(45deg) translateY(-3px); transition: transform .15s; }
.kachel[open] summary::after { transform: rotate(-135deg) translate(-3px, 0); }
.kachel[open] summary { border-bottom: 3px dashed var(--k); border-radius: 13px 13px 0 0; }
.marke { flex: none; width: 2.75rem; height: 2.75rem; padding: .45rem; border-radius: 50%; background: var(--k);
         fill: none; stroke: var(--tinte); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.kachel .name { font-size: 1.5rem; line-height: 1.15; }
.kachel .inhalt { padding: .5rem 1.1rem 1.1rem; font-size: 1.1rem; }
.kachel .inhalt > :first-child { margin-top: .5rem; }
.kachel .inhalt .knopf { margin-top: .5rem; }
.ort-name { font-weight: 700; margin-bottom: 0; }
.namen { margin: .5rem 0 1rem; padding: 0; list-style: none; columns: 2 10rem; column-gap: 1.5rem; }
.namen li { padding: .2rem 0; break-inside: avoid; }
.absagen { margin: .5rem 0 0; color: var(--grau); font-size: 1rem; }
.absagen span { font-weight: 700; }
.kachel-aus { border: 3px dashed #a6adb5; box-shadow: none; background: transparent; color: var(--grau); }
.kachel-aus .marke { background: #dfe2dc; stroke: var(--grau); }
.kachel-aus small { display: block; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
                    font-weight: 400; font-size: 1rem; }
.meine { display: grid; gap: 1rem; margin-top: 2.75rem; }
.meine p { margin: 0; font-size: 1.1rem; }
.nicht-ich summary { display: inline-flex; align-items: center; min-height: 3rem; color: var(--grau); cursor: pointer;
                     text-decoration: underline; text-underline-offset: 3px; list-style: none; }
.nicht-ich summary::-webkit-details-marker { display: none; }
.nicht-ich p { color: var(--grau); }

/* ---------- Verwaltung (Silvio): schlicht, auch am Handy bedienbar ---------- */
body.admin main { max-width: 64rem; }
body.admin h1 { font-size: 2.2rem; }
.admin h2 { font-size: 1.5rem; margin: 0 0 .75rem; }
.admin-nav { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem .5rem; margin: 0 0 1.5rem;
             padding-bottom: .75rem; border-bottom: 3px solid var(--tinte); }
.admin-nav a, .nav-knopf { display: inline-flex; align-items: center; min-height: 3rem; padding: 0 .9rem;
                           font: inherit; font-weight: 700; color: var(--tinte); background: none; border: 0;
                           border-radius: 10px; cursor: pointer; text-decoration: none; }
.admin-nav a[aria-current="page"] { background: var(--tinte); color: #fff; }
.admin-nav form { margin: 0 0 0 auto; }
.nav-knopf { text-decoration: underline; text-decoration-color: var(--rot); text-decoration-thickness: 3px; }
.admin textarea, .admin .feld input[type=file] { display: block; width: 100%; padding: .6rem .9rem; font: inherit;
  font-size: 1.1rem; color: var(--tinte); background: #fff; border: 3px solid var(--rand); border-radius: 12px; }
.admin textarea:focus { border-color: var(--blau); outline: 3px solid var(--blau); outline-offset: 1px; }
.admin .feld input[readonly] { background: #eceee8; }
.admin .formular .knopf, .admin .formular .option { margin-bottom: 1rem; }
.knopf-klein { display: inline-flex; width: auto; min-height: 3rem; padding: .3rem 1rem; font-size: 1rem;
               box-shadow: 3px 3px 0 var(--rot); }
.knopf-klein.knopf-hell { box-shadow: 3px 3px 0 var(--blau); }
.knopf-gefahr { background: #a3300f; border-color: #a3300f; box-shadow: 3px 3px 0 var(--tinte); }
.knopfreihe, .aktion { display: flex; flex-wrap: wrap; gap: .75rem; margin: 0 0 1rem; }
/* Mailmodus über jeder Verwaltungsseite: Probebetrieb auffällig, Echtversand dezent */
.modus { margin: -1rem 0 1.5rem; padding: .4rem .9rem; font-weight: 700; border-radius: 10px; }
.modus-probe { background: var(--gelb); border: 3px solid var(--tinte); }
.modus-echt { padding: 0; color: var(--grau); font-weight: 400; font-size: 1rem; }
.infobox { margin: 0 0 1.5rem; padding: .75rem 1rem; background: #e8f6df; border: 3px solid var(--gruen);
           border-radius: 12px; }
.infobox p { margin: 0; font-weight: 700; }
.infobox ul { margin: .25rem 0 0; padding-left: 1.25rem; }
.zaehler { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin: 1rem 0 1.5rem; }
.zaehler > div { padding: .6rem; text-align: center; background: #fff; border: 3px solid var(--tinte);
                 border-radius: 14px; }
.zaehler-dabei { box-shadow: 4px 4px 0 var(--gruen); }
.zaehler-nicht { box-shadow: 4px 4px 0 var(--rot); }
.zaehler-offen { box-shadow: 4px 4px 0 var(--gelb); }
.zaehler .zahl { display: block; font-family: var(--plakat); font-size: 2.4rem; font-weight: 800; line-height: 1.1; }
.zaehler .etikett { font-weight: 700; }
/* nur dieser Container scrollt waagrecht, nicht die ganze Seite */
.tabelle-scroll { overflow-x: auto; margin: 0 0 1.5rem; border: 3px solid var(--tinte); border-radius: 12px; background: #fff; }
/* Passt bei 1280 px ohne Scrollen; auf dem Handy scrollt nur der Container (min-width) */
.tabelle { width: 100%; min-width: 50rem; border-collapse: collapse; font-size: .9rem; }
.tabelle th, .tabelle td { padding: .45rem .45rem; text-align: left; vertical-align: middle; border-bottom: 1px solid #d5d9d0; }
.tabelle th { background: #eceee8; white-space: nowrap; }
.tabelle .name-zelle { font-weight: 700; }
.tabelle .telefon, .tabelle .einzeilig, .tabelle .aktionen { white-space: nowrap; }
.tabelle .email { min-width: 11rem; overflow-wrap: anywhere; }
.aktionen-reihe { display: flex; gap: .35rem; }
.knopf-mini { display: inline-flex; width: auto; min-height: 2.6rem; padding: .2rem .7rem; font-size: .9rem;
              border-width: 2px; border-radius: 10px; box-shadow: 2px 2px 0 var(--blau); }
.antwort { display: inline-block; padding: .1rem .6rem; font-weight: 700; border-radius: 999px; border: 2px solid var(--tinte); }
.antwort-dabei { background: #e8f6df; }
.antwort-nicht { background: #fde6de; }
.antwort-offen { background: #fbf0c4; }
.liste { margin: 0 0 1rem; padding: 0; list-style: none; display: grid; gap: .75rem; }
.liste .knopf { justify-content: space-between; gap: 1rem; text-align: left; }
.liste .marken { color: var(--grau); font-weight: 400; font-size: 1rem; }
.vorschau { margin-top: .75rem; padding: .5rem 1rem; background: #fff; border: 3px dashed var(--blau); border-radius: 12px; }
.vorschau h2 { font-size: 1.1rem; color: var(--grau); }
code { padding: .1rem .3rem; background: #eceee8; border-radius: 6px; }

/* Mail-Vorschau */
.vorschau { margin: 0 0 1.5rem; padding: .75rem 1rem; white-space: pre-wrap; font: inherit; background: #fff;
            border: 3px solid var(--tinte); border-radius: 12px; }

/* ---------- Fotos ---------- */
.kachel-link { display: block; color: inherit; text-decoration: none; }
.kachel-link .zeile::after { content: ""; flex: none; width: .8rem; height: .8rem; margin: 0 .5rem 0 auto;
                             border-right: 3px solid var(--tinte); border-bottom: 3px solid var(--tinte);
                             transform: rotate(-45deg); }
.kachel-link:active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--k); }
.kachel-link small { display: block; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
                     font-weight: 400; font-size: 1rem; }
body.galerie main { max-width: 64rem; }
.zurueck { margin: 0 0 .75rem; }
.zurueck a { display: inline-flex; align-items: center; min-height: 3rem; font-weight: 700; }
.reiter { display: flex; flex-wrap: wrap; gap: .6rem; margin: 0 0 1.5rem; }
.reiter a { display: inline-flex; align-items: center; justify-content: center; min-width: 5rem; min-height: 3rem;
            padding: 0 1rem; font-family: var(--plakat); font-size: 1.3rem; font-weight: 800; text-decoration: none;
            background: #fff; border: 3px solid var(--tinte); border-radius: 12px; }
.reiter a[aria-current="page"] { color: #fff; background: var(--tinte); box-shadow: 4px 4px 0 var(--gelb); }
.hochladen { margin: 0 0 2rem; padding: 1rem 1.1rem 1.25rem; background: #fff; border: 3px solid var(--tinte);
             border-radius: 16px; box-shadow: 5px 5px 0 var(--gruen); }
.hochladen h2 { margin: 0 0 .75rem; font-size: 1.6rem; }
.hochladen form { display: grid; gap: .75rem; }
.hochladen .hinweis { margin-top: .9rem; }
.knopf-gross { gap: .6rem; min-height: 4.5rem; font-size: 1.4rem; }
.knopf-marke { flex: none; width: 1.8rem; height: 1.8rem; fill: none; stroke: currentColor; stroke-width: 2.2;
               stroke-linecap: round; stroke-linejoin: round; }
.waehlen.gesperrt { opacity: .6; pointer-events: none; }
.hochladen form:has(.datei-feld:focus-visible) .waehlen { outline: 3px solid var(--blau); outline-offset: 3px; }
.feld-titel { font-size: 1.1rem; font-weight: 700; }
.datei-feld { min-height: 3.5rem; font: inherit; font-size: 1.1rem; }
.unsichtbar { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
              clip-path: inset(50%); white-space: nowrap; border: 0; }
.upload-stand { margin-top: 1.25rem; }
.stand-text { margin: 0 0 .5rem; font-size: 1.2rem; font-weight: 700; }
.upload-stand progress { width: 100%; height: 1.25rem; accent-color: var(--gruen); }
.fehlgeschlagen { margin: .75rem 0; padding-left: 1.25rem; color: #a3300f; font-weight: 700; overflow-wrap: anywhere; }
.fehlgeschlagen:empty { display: none; }
.raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr)); gap: 1rem .75rem;
          margin: 0 0 2rem; padding: 0; list-style: none; }
.raster-foto a { display: block; overflow: hidden; background: #dfe2dc; border: 3px solid var(--tinte); border-radius: 12px; }
.raster-foto img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.raster-foto form { margin: 0; }
.von { margin: .3rem 0 0; font-size: 1rem; color: var(--grau); overflow-wrap: anywhere; }
.knopf-text { min-height: 3rem; padding: 0 .2rem; font: inherit; font-size: 1rem; font-weight: 700; color: #a3300f;
              background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.raster-admin .knopf { margin-top: .4rem; }

/* Lightbox: Foto gross auf dunklem Grund, Knöpfe gross genug für den Daumen */
html.lightbox-offen, html.lightbox-offen body { overflow: hidden; }
.lightbox { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center;
            padding: 4.5rem 0 7.5rem; color: #fff; background: #111; touch-action: pan-y pinch-zoom; }
.lightbox :focus-visible { outline-color: var(--gelb); }
.lb-bild { max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; -webkit-user-select: none; }
.lb-knopf { position: absolute; display: flex; align-items: center; justify-content: center; width: 3.5rem;
            height: 3.5rem; padding: 0; color: #fff; background: rgba(0, 0, 0, .55);
            border: 2px solid rgba(255, 255, 255, .75); border-radius: 50%; cursor: pointer; }
.lb-knopf svg { width: 1.8rem; height: 1.8rem; fill: none; stroke: currentColor; stroke-width: 2.5;
                stroke-linecap: round; stroke-linejoin: round; }
.lb-zu { top: .75rem; right: .75rem; }
.lb-zurueck, .lb-weiter { top: 50%; transform: translateY(-50%); }
.lb-zurueck { left: .5rem; }
.lb-weiter { right: .5rem; }
.lb-leiste { position: absolute; right: 0; bottom: 0; left: 0; display: flex; flex-wrap: wrap; align-items: center;
             justify-content: space-between; gap: .5rem 1rem;
             padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom)); background: rgba(0, 0, 0, .7); }
.lb-text { margin: 0; font-size: 1.1rem; font-weight: 700; }
.lb-zaehler { font-weight: 400; color: #cfd3cc; }
.lb-aktionen { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Logo-Auswahl in der Verwaltung (Layout; Farben folgen nach der Wahl des Logos) */
.varianten { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); gap: .75rem; margin-bottom: 1rem; }
.variante { display: block; padding: .5rem; border: 3px solid transparent; border-radius: 12px; background: #151515; color: #fff; }
.variante:has(input:checked) { border-color: var(--blau); }
.variante img { display: block; width: 100%; height: auto; }
.variante input { width: 1.5rem; height: 1.5rem; vertical-align: middle; margin-right: .5rem; }
