/* =========================================================================
   Fotostand 3.0 – gemeinsamer Rahmen für Webseite, Portal und Backend
   Graphit #15171b · Anthrazit #242830 · Papier #f5f6f8 · Signalrot #c8192e
   ========================================================================= */
:root { --leiste: #15171b; --leiste-hell: #1f2228; --leiste-text: #b9bec8; --leiste-breite: 248px; --kopf-hoehe: 68px; }

[hidden] { display: none !important; }
body.app-seite { background: var(--hellgrau); }
.app { display: grid; grid-template-columns: var(--leiste-breite) minmax(0, 1fr); min-height: 100vh; }

/* ---------- Seitenleiste ---------- */
.app-leiste { position: sticky; top: 0; height: 100vh; overflow-y: auto; background: var(--leiste); color: var(--leiste-text);
  display: flex; flex-direction: column; gap: 1.4rem; padding: 1.25rem .85rem 1rem; z-index: 40; }
.app-marke { display: grid; gap: .35rem; padding: .2rem .6rem .4rem; text-decoration: none !important; }
.app-marke img { height: 44px; width: auto; }
.app-marke span { font-size: .72rem; font-weight: 700; color: #8a909b; letter-spacing: .02em; }
.leiste-nav { display: grid; gap: .15rem; }
.leiste-titel { margin: 1rem .75rem .35rem; font-size: .75rem; font-weight: 700; color: #6f7581; }
.leiste-punkt { display: flex; align-items: center; gap: .75rem; width: 100%; padding: .62rem .75rem; border-radius: 9px; border: 0; background: none;
  color: var(--leiste-text); font: inherit; font-weight: 600; font-size: .95rem; text-align: left; cursor: pointer; text-decoration: none !important; position: relative; }
.leiste-punkt .symbol { width: 20px; height: 20px; flex: none; opacity: .9; }
.leiste-punkt span:not(.zaehler) { flex: 1; }
.leiste-punkt:hover { background: var(--leiste-hell); color: #fff; }
.leiste-punkt[aria-current="page"] { background: linear-gradient(90deg, rgba(200, 25, 46, .22), rgba(200, 25, 46, .06)); color: #fff; }
.leiste-punkt[aria-current="page"]::before { content: ""; position: absolute; left: -.85rem; top: .45rem; bottom: .45rem; width: 3px; border-radius: 0 3px 3px 0; background: var(--rot); }
.leiste-punkt[aria-current="page"] .symbol { color: #ff5a6b; opacity: 1; }
.leiste-punkt .zaehler { background: var(--rot); color: #fff; font-size: .72rem; min-width: 1.4rem; text-align: center; padding: .05rem .4rem; border-radius: 999px; }
.leiste-punkt .zaehler[hidden] { display: none; }
.leiste-fuss { margin-top: auto; display: grid; gap: .15rem; border-top: 1px solid #2a2e36; padding-top: .9rem; }
.leiste-fuss form { margin: 0; }
.leiste-knopf { margin: .5rem .25rem 0; }

/* ---------- Kopfzeile ---------- */
.app-flaeche { display: flex; flex-direction: column; min-width: 0; }
.app-kopf { position: sticky; top: 0; z-index: 30; height: var(--kopf-hoehe); display: flex; align-items: center; gap: 1rem;
  padding: 0 clamp(1rem, 2.5vw, 2rem); background: rgba(21, 23, 27, .97); backdrop-filter: blur(8px); border-bottom: 1px solid #23262d; }
.app-menue-knopf { display: none; background: none; border: 0; color: #fff; padding: .4rem; border-radius: 8px; cursor: pointer; }
.app-menue-knopf .symbol { width: 26px; height: 26px; }
.app-kopf-suche { flex: 1; min-width: 0; max-width: 760px; }
.kopf-suchfeld { position: relative; margin: 0; }
.kopf-suchfeld .symbol { position: absolute; left: .9rem; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: #8a909b; pointer-events: none; }
.kopf-suchfeld input { width: 100%; height: 42px; border-radius: 10px; border: 1px solid #2c3038; background: #1f2228; color: #fff; padding: 0 1rem 0 2.6rem; font: inherit; font-size: .95rem; }
.kopf-suchfeld input::placeholder { color: #7d838e; }
.kopf-suchfeld input:focus { outline: none; border-color: var(--rot); background: #23262d; }
.app-kopf-rechts { display: flex; align-items: center; gap: .6rem; margin-left: auto; }
.knopf-dunkel-rahmen { background: transparent; color: #fff; border-color: #3a3f48; }
.knopf-dunkel-rahmen:hover { border-color: #6b7180; }
.kopf-person { display: flex; align-items: center; gap: .65rem; color: #fff; text-decoration: none !important; }
.kopf-initialen { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--rot); color: #fff; font-weight: 800; font-size: .85rem; }
.kopf-name { display: grid; font-weight: 700; font-size: .9rem; line-height: 1.2; }
.kopf-name small { color: #8a909b; font-weight: 600; font-size: .75rem; }

/* ---------- Inhalt ---------- */
.app-haupt { flex: 1; padding: clamp(1rem, 2.5vw, 2rem); width: 100%; max-width: 1480px; }
.app-haupt.randlos { padding: 0; max-width: none; }
.app-fuss { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1.5rem; padding: 1.1rem clamp(1rem, 2.5vw, 2rem);
  border-top: 1px solid var(--linie); font-size: .82rem; color: var(--text-leise); }
.app-fuss a { color: var(--text-leise); }
.app-fuss nav { display: flex; gap: 1.1rem; }
.meldung-info { background: #eef3fb; border-color: #c9d8f0; color: #1d3b6b; }

/* Alte Kopfzeilen werden im neuen Rahmen nicht mehr gebraucht */
.oeffentlich-haupt { padding: 0 !important; }
.portal-inhalt { padding: 0; max-width: none; }

/* ---------- Handy und Tablet ---------- */
@media (max-width: 1000px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .app-leiste { position: fixed; inset: 0 auto 0 0; width: 272px; transform: translateX(-100%); transition: transform .2s ease; }
  .app-leiste.offen { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .45); }
  .app-menue-knopf { display: inline-flex; }
  .kopf-name, .kopf-zugang { display: none; }
}
@media (max-width: 560px) {
  .app-kopf { gap: .5rem; }
  .kopf-suchfeld input { font-size: .9rem; }
  .app-kopf-rechts .knopf-dunkel-rahmen { padding: .4em .7em; }
}
@media (prefers-reduced-motion: reduce) { .app-leiste { transition: none; } }

/* =========================================================================
   Cockpit (Startseite) – für alle sichtbar, Inhalte nach der Anmeldung
   ========================================================================= */
.cockpit-kopf { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 1.25rem; }
.cockpit-kopf h1 { margin: 0 0 .25rem; font-size: clamp(1.5rem, 2.4vw, 2rem); }
.cockpit-kopf p { margin: 0; max-width: 60ch; }
.cockpit-filter { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .6rem; margin: 0; }
.cockpit-filter label { display: grid; gap: .2rem; font-size: .75rem; font-weight: 700; color: var(--text-leise); }
.cockpit-filter input, .cockpit-filter select { height: 40px; border: 1px solid var(--linie); border-radius: 9px; background: var(--weiss); padding: 0 .7rem; font: inherit; font-size: .9rem; color: var(--text); }
.cockpit-filter input[type="text"] { width: 150px; }
.cockpit-filter .knopf { height: 40px; display: inline-flex; align-items: center; gap: .4rem; }
.cockpit-filter .symbol { width: 16px; height: 16px; }

.cockpit-raster { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 1.25rem; margin-bottom: 1.5rem; }
.cockpit-raster.unten { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; }
.cockpit-karte { background: var(--weiss); border-radius: 14px; box-shadow: var(--schatten); padding: 1.2rem 1.25rem; margin: 0 0 1.25rem; }
.cockpit-seite .cockpit-karte:last-child, .cockpit-raster > .cockpit-karte { margin-bottom: 0; }
.cockpit-karte h2 { font-size: 1.05rem; margin: 0 0 .8rem; }
.karte-kopf { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .8rem; }
.karte-kopf h2 { margin: 0; }
.karte-kopf a, .cockpit-karte > a, .kalender-fuss a { display: inline-flex; align-items: center; gap: .25rem; font-weight: 700; font-size: .88rem; }
.karte-kopf .symbol, .cockpit-karte > a .symbol, .kalender-fuss .symbol { width: 15px; height: 15px; }

/* Bühne */
.cbuehne { position: relative; min-height: 440px; border-radius: 16px; overflow: hidden; background: #0d0f12; color: #fff; box-shadow: var(--schatten); }
.cbuehne-folie { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity .8s ease, visibility .8s; }
.cbuehne-folie.sichtbar { opacity: 1; visibility: visible; }
.cbuehne-folie img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cbuehne-folie::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(8, 9, 11, .88) 0%, rgba(8, 9, 11, .35) 45%, rgba(8, 9, 11, 0) 70%); pointer-events: none; }
.cbuehne-folie.leer { background: linear-gradient(135deg, #1b1e24, #2a1015); }
.cbuehne-text { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; padding: clamp(1.25rem, 3vw, 2.25rem); padding-bottom: 3.2rem; }
.cbuehne-text h2 { font-size: clamp(1.5rem, 3vw, 2.4rem); line-height: 1.15; margin: .5rem 0 .6rem; letter-spacing: -.02em; max-width: 24ch; color: #fff; }
.cbuehne-text p { color: rgba(255, 255, 255, .85); max-width: 60ch; }
.cbuehne-marke { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; background: var(--rot); padding: .25rem .55rem; border-radius: 5px; }
.cbuehne-daten { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; margin: 0 0 1.1rem; font-weight: 600; font-size: .95rem; }
.cbuehne-daten span { display: inline-flex; align-items: center; gap: .4rem; }
.cbuehne-daten .symbol { width: 17px; height: 17px; opacity: .85; }
.cbuehne-text .knopf { display: inline-flex; align-items: center; gap: .45rem; }
.cbuehne-text .knopf .symbol { width: 16px; height: 16px; }
.cbuehne-pfeil { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 42px; height: 42px; border-radius: 50%; border: 0;
  background: rgba(0, 0, 0, .45); color: #fff; display: grid; place-items: center; cursor: pointer; }
.cbuehne-pfeil:hover { background: rgba(0, 0, 0, .7); }
.cbuehne-pfeil .symbol { width: 20px; height: 20px; }
.cbuehne-pfeil.links { left: 1rem; }
.cbuehne-pfeil.rechts { right: 1rem; }
.cbuehne-punkte { position: absolute; z-index: 3; left: clamp(1.25rem, 3vw, 2.25rem); bottom: 1.2rem; display: flex; gap: .45rem; }
.cbuehne-punkte button { width: 9px; height: 9px; padding: 0; border-radius: 99px; border: 0; background: rgba(255, 255, 255, .45); cursor: pointer; transition: width .2s; }
.cbuehne-punkte button[aria-current="true"] { width: 26px; background: #fff; }

/* Kalender: nur Punkte */
.cockpit-blaettern { display: flex; align-items: center; gap: .4rem; font-size: .9rem; }
.cockpit-blaettern a { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; color: var(--text); }
.cockpit-blaettern a:hover { background: var(--hellgrau); text-decoration: none; }
.cockpit-blaettern .symbol { width: 15px; height: 15px; }
.mini-kalender { width: 100%; border-collapse: collapse; table-layout: fixed; text-align: center; font-size: .88rem; }
.mini-kalender th { font-size: .72rem; color: var(--text-leise); font-weight: 700; padding: .2rem 0 .45rem; }
.mini-kalender td { padding: 2px; height: 42px; vertical-align: top; }
.mini-kalender td > span, .mini-kalender td > a { display: grid; justify-items: center; gap: 2px; padding: .3rem 0; border-radius: 8px; color: var(--text); font-weight: 600; }
.mini-kalender td > a:hover { background: var(--hellgrau); text-decoration: none; }
.mini-kalender td.fremd > span { color: #b8bcc5; font-weight: 500; }
.mini-kalender td.heute > span, .mini-kalender td.heute > a { background: var(--anthrazit); color: #fff; }
.mini-kalender .punkte { display: flex; gap: 3px; height: 5px; }
.mini-kalender .punkte b { width: 5px; height: 5px; border-radius: 50%; background: var(--rot); }
.mini-kalender td.heute .punkte b { background: #ff6b7c; }
.kalender-fuss { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin: .8rem 0 0; padding-top: .8rem; border-top: 1px solid var(--linie); font-size: .85rem; color: var(--text-leise); }
.kalender-fuss > span .symbol { width: 15px; height: 15px; vertical-align: -2px; margin-right: .2rem; }

/* Aktuelle Bildstrecken */
.cockpit-strecken { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 1rem; }
.cockpit-strecke { display: grid; background: var(--weiss); border-radius: 12px; overflow: hidden; box-shadow: var(--schatten); color: var(--text); transition: transform .15s, box-shadow .15s; }
.cockpit-strecke:hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 6px 22px rgba(36, 40, 48, .12); }
.cockpit-strecke-bild { position: relative; aspect-ratio: 3 / 2; background: #d9dce2; overflow: hidden; }
.cockpit-strecke-bild img { width: 100%; height: 100%; object-fit: cover; display: block; }
.strecke-thema { position: absolute; left: .55rem; top: .55rem; background: rgba(21, 23, 27, .82); color: #fff; font-size: .7rem; font-weight: 700; padding: .2rem .5rem; border-radius: 5px; }
.strecke-schloss { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: .4rem; background: rgba(21, 23, 27, .55);
  color: #fff; font-weight: 700; font-size: .85rem; opacity: 0; transition: opacity .15s; }
.strecke-schloss .symbol { width: 16px; height: 16px; }
.cockpit-strecke:hover .strecke-schloss, .cockpit-strecke:focus-visible .strecke-schloss { opacity: 1; }
.cockpit-strecke-text { display: grid; gap: .2rem; padding: .7rem .8rem .8rem; }
.cockpit-strecke-text strong { font-size: .93rem; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cockpit-strecke-text span { font-size: .78rem; color: var(--text-leise); }

/* Seitenspalte */
.themen-liste, .meine-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.themen-liste a { display: flex; align-items: center; gap: .6rem; padding: .45rem .5rem; border-radius: 8px; color: var(--text); font-weight: 600; font-size: .92rem; }
.themen-liste a:hover { background: var(--hellgrau); text-decoration: none; }
.themen-liste .symbol { width: 17px; height: 17px; color: var(--text-leise); }
.themen-liste span { flex: 1; }
.themen-liste small { background: var(--hellgrau); color: var(--text-leise); font-weight: 700; font-size: .72rem; padding: .05rem .45rem; border-radius: 99px; }
.meine-liste a { display: flex; align-items: center; gap: .7rem; padding: .35rem; border-radius: 8px; color: var(--text); }
.meine-liste a:hover { background: var(--hellgrau); text-decoration: none; }
.meine-liste img, .meine-liste .ohne-bild { width: 64px; height: 44px; object-fit: cover; border-radius: 6px; background: #d9dce2; flex: none; }
.meine-liste span { display: grid; font-size: .86rem; line-height: 1.3; }
.meine-liste small { color: var(--text-leise); }
.schnell-chips { display: flex; flex-wrap: wrap; gap: .45rem; }
.schnell-chips a { padding: .35rem .75rem; border-radius: 99px; border: 1px solid var(--linie); color: var(--text); font-size: .85rem; font-weight: 600; background: var(--weiss); }
.schnell-chips a:hover { border-color: var(--rot); color: var(--rot); text-decoration: none; }
.zugang-hinweis { background: var(--anthrazit); color: #fff; }
.zugang-hinweis h2 { color: #fff; }
.zugang-hinweis p { color: rgba(255, 255, 255, .78); font-size: .9rem; }

/* Dezent darunter */
.cockpit-dezent { margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid var(--linie); }
.dezent-medien { text-align: center; margin-bottom: 2rem; }
.dezent-medien h2 { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--text-leise); margin-bottom: .7rem; }
.dezent-medien p { margin: 0 0 .4rem; }
.dezent-medien p span { display: inline-block; margin: .15rem .9rem; font-weight: 800; font-size: 1.02rem; color: #4a505c; }
.dezent-medien .leise { font-size: .85rem; }
.dezent-karten { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; }
.dezent-karten .cockpit-karte { margin: 0; }
.dezent-karten p { color: var(--text-leise); font-size: .92rem; }
.dezent-einblicke { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: .75rem; margin-top: 1.5rem; }
.dezent-einblicke figure { margin: 0; position: relative; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; background: #d9dce2; }
.dezent-einblicke img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dezent-einblicke figcaption { position: absolute; left: .6rem; bottom: .5rem; color: #fff; font-weight: 700; font-size: .82rem; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
.themen-zeile span { display: inline-block; margin: 0 .5rem .4rem 0; padding: .3rem .7rem; border-radius: 99px; background: var(--hellgrau); font-weight: 600; font-size: .9rem; }
.fakten-liste { display: flex; flex-wrap: wrap; gap: 1rem 2.5rem; margin: 0; }
.fakten-liste dt { font-size: .8rem; color: var(--text-leise); }
.fakten-liste dd { margin: 0; font-size: 1.5rem; font-weight: 800; }
.app-haupt > .textseite { margin-bottom: 1.25rem; }

@media (max-width: 1200px) {
  .cockpit-raster, .cockpit-raster.unten { grid-template-columns: minmax(0, 1fr) 300px; }
}
@media (max-width: 1000px) {
  .cockpit-raster, .cockpit-raster.unten { grid-template-columns: minmax(0, 1fr); }
  .dezent-karten { grid-template-columns: minmax(0, 1fr); }
  .cbuehne { min-height: 380px; }
}
@media (max-width: 560px) {
  .cockpit-filter { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  .cockpit-filter input, .cockpit-filter select, .cockpit-filter input[type="text"] { width: 100%; }
  .cockpit-filter .knopf { grid-column: 1 / -1; justify-content: center; }
  .cbuehne { min-height: 420px; }
  .cbuehne-pfeil { display: none; }
  .cockpit-strecken { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
}
@media (prefers-reduced-motion: reduce) { .cbuehne-folie, .cockpit-strecke { transition: none; } }
.app-haupt.ohne-abstand { padding: 0; max-width: none; }
.dezent-themen span { font-weight: 600 !important; font-size: .92rem !important; color: var(--text-leise) !important; margin: .15rem .6rem !important; }
.stimme-kurz { margin: 0 0 1rem; }
.stimme-kurz blockquote { margin: 0 0 .3rem; font-size: 1.05rem; font-style: italic; }
.stimme-kurz figcaption { font-size: .85rem; color: var(--text-leise); }
