/* ═══════════════════════════════════════════════════════════
   FILOO – neues Design (Probe, Runde 2, 17.11.2026)
   Vorbild: die Lyricvideos "Routing Error" und "Signal Home":
   Nachtstadt in Cyan, goldenes Signal, Sterne, Magenta der Haare.

   Regeln aus F:\Webseiten Bibliothek (KEIN_KI_LOOK, STILFINDUNG 5/5a,
   SEITENAUFBAU), soweit sie ohne WordPress gelten:
   - kein unscharfer Leuchtschein, kein Milchglas, kein Verlaufstext:
     Leuchten nur aus SCHARFEN Linien und Flaechen und aus den Bildern
   - ein auffaelliger Effekt pro Seite: Sterne + Goldfunken im Kopf
   - nichts blendet von unten ein, nichts pulsiert dauernd
   - keine Deko-Nummern, kein "Etikett + Riesentitel + zwei Knoepfe"
   - jeder Reiter bekommt spaeter seine eigene Form
   ═══════════════════════════════════════════════════════════ */

:root {
    --nacht: #050811;
    --nacht-2: #0b1324;
    --flaeche: #0e1830;
    --linie: #1d2c4c;

    --cyan: #5ef0ff;
    --gold: #ffcf6e;
    --magenta: #ff4fa8;

    --text: #eef3ff;
    --text-leise: #9aa5c4;

    --schrift-titel: 'Orbitron', sans-serif;
    --schrift-text: 'Outfit', sans-serif;
    --schrift-mono: 'JetBrains Mono', monospace;

    /* Alte Namen - terminal.js und signal.js benutzen sie */
    --neon-cyan: var(--cyan);
    --neon-pink: var(--magenta);
    --neon-purple: #9d4edd;
    --text-muted: var(--text-leise);
    --font-mono: var(--schrift-mono);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    background: var(--nacht);
    color: var(--text);
    font-family: var(--schrift-text);
    font-size: 1.0625rem;
    line-height: 1.6;
    /* KEIN overflow-x: hidden hier - sonst klebt die Reiterleiste nicht.
       Randlose Bilder bekommen ihre Breite ueber den Aufbau (.inhalt ist
       voll breit, nur die Kinder sind begrenzt), nicht ueber 100vw. */
}

h1, h2, h3 {
    hyphens: auto;
    overflow-wrap: break-word;
}

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* Sichtbarer Fokus fuer die Tastatur */
:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
}

.sprung {
    position: absolute;
    left: 12px;
    top: -60px;
    z-index: 100;
    padding: 10px 14px;
    background: var(--cyan);
    color: #031018;
    font-family: var(--schrift-mono);
    text-decoration: none;
}
.sprung:focus { top: 12px; }

/* ═══ KOPF ═══ */
.hero {
    position: relative;
    /* nicht ganzer Bildschirm: die Reiter sind beim Oeffnen zu sehen */
    height: 68vh;
    height: 68svh;
    min-height: 440px;
    max-height: 720px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
}

.hero-bild {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: 70% 40%;
}

.sterne {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.hero-verlauf {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(5, 8, 17, 0.82) 0%, rgba(5, 8, 17, 0.35) 40%, rgba(5, 8, 17, 0) 62%),
        linear-gradient(180deg, rgba(5, 8, 17, 0) 50%, var(--nacht) 100%);
    pointer-events: none;
}

.hero-unten {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px 36px 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 32px;
}

/* Zeile aus dem Song, gesetzt wie im Lyricvideo */
.songzeile {
    font-family: var(--schrift-titel);
    font-weight: 600;
    font-size: clamp(0.85rem, 1.6vw, 1.05rem);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    line-height: 1.7;
    color: var(--text);
    border-left: 2px solid var(--cyan);
    padding-left: 14px;
    margin-bottom: 14px;
}

.titel {
    position: relative;
    font-family: var(--schrift-titel);
    font-weight: 900;
    font-size: clamp(4.2rem, 13vw, 10rem);
    letter-spacing: 0.1em;
    line-height: 0.9;
    color: #fff;
    /* Kein Leuchtschein: eine scharfe Cyan-Kante unten rechts, wie die
       doppelte Schrift im Lyricvideo-Titel */
    text-shadow: 3px 3px 0 rgba(94, 240, 255, 0.55);
    cursor: default;
    user-select: none;
}
/* Kleines Detail beim Drueberfahren: Glitch in Cyan und Magenta */
.titel::before,
.titel::after {
    content: attr(data-text);
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    text-shadow: none;
}
.titel::before { color: var(--cyan); }
.titel::after  { color: var(--magenta); }
.titel { transition: text-shadow 0.3s ease; }
.titel:hover {
    text-shadow: 3px 3px 0 rgba(94, 240, 255, 0.55), 0 0 22px rgba(94, 240, 255, 0.6), 0 0 60px rgba(94, 240, 255, 0.3);
}
.titel:hover::before {
    opacity: 0.85;
    animation: glitch-a 0.45s steps(2) infinite;
}
.titel:hover::after {
    opacity: 0.85;
    animation: glitch-b 0.45s steps(2) infinite;
}
@keyframes glitch-a {
    0%   { clip-path: inset(10% 0 70% 0); transform: translate(-6px, 0); }
    50%  { clip-path: inset(55% 0 20% 0); transform: translate(5px, 0); }
    100% { clip-path: inset(30% 0 45% 0); transform: translate(-3px, 0); }
}
@keyframes glitch-b {
    0%   { clip-path: inset(60% 0 10% 0); transform: translate(6px, 0); }
    50%  { clip-path: inset(15% 0 65% 0); transform: translate(-5px, 0); }
    100% { clip-path: inset(40% 0 35% 0); transform: translate(3px, 0); }
}

/* Die einzige Meldung im Kopf: was als Naechstes kommt */
.signal-meldung {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 230px;
    padding: 14px 18px 14px 16px;
    background: var(--nacht);
    border-left: 3px solid var(--gold);
    text-decoration: none;
    color: var(--text);
    transition: background 0.2s;
}
.signal-meldung:hover { background: var(--nacht-2); }
.meldung-kopf {
    font-family: var(--schrift-mono);
    font-size: 0.8rem;
    color: var(--gold);
}
.meldung-titel {
    font-family: var(--schrift-titel);
    font-weight: 800;
    font-size: 1.35rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.meldung-unter {
    font-size: 0.9rem;
    color: var(--text-leise);
}

/* ═══ REITER-LEISTE ═══ */
.reiter-leiste {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--nacht);
    border-bottom: 1px solid var(--linie);
}
.reiter-spur {
    position: relative;
    display: flex;
    gap: 4px;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 28px;
    overflow-x: auto;
    scrollbar-width: none;
}
.reiter-spur::-webkit-scrollbar { display: none; }

.reiter {
    flex: 0 0 auto;
    font-family: var(--schrift-titel);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--text-leise);
    padding: 18px 14px 16px 14px;
    transition: color 0.2s;
}
.reiter:hover { color: var(--text); }
.reiter.aktiv { color: var(--cyan); }

/* scharfer Strich, der zum aktiven Reiter gleitet */
.reiter-strich {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    width: 0;
    background: var(--cyan);
    transition: left 0.35s cubic-bezier(.6,.05,.25,1), width 0.35s cubic-bezier(.6,.05,.25,1);
}

/* ═══ INHALT ═══ */
.inhalt {
    padding: 56px 0 40px 0;
    min-height: 60vh;
}
/* alles im Reiter ist begrenzt - ausser randlosen Baendern */
.reiter-seite > * {
    width: min(1200px, calc(100% - 80px));
    margin-left: auto;
    margin-right: auto;
}
.reiter-seite > .randlos { width: 100%; }

/* Nur mit JavaScript werden Reiter versteckt; ohne JS steht alles
   untereinander und ist trotzdem lesbar */
.js .reiter-seite { display: none; }
.js .reiter-seite.aktiv { display: block; }
.reiter-seite + .reiter-seite { margin-top: 64px; }
.js .reiter-seite + .reiter-seite { margin-top: 0; }

.kopfzeile {
    display: flex;
    align-items: baseline;
    gap: 18px;
    margin-bottom: 30px;
}
.kopfzeile h2 {
    font-family: var(--schrift-titel);
    font-size: 1.6rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}
.kopf-linie {
    order: 2;
    flex: 1;
    height: 1px;
    background: var(--linie);
    align-self: center;
}
.kopf-fakt {
    order: 3;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    color: var(--text-leise);
}

/* ─── Musik ─── */
.klein-zeile {
    font-family: var(--schrift-mono);
    font-size: 0.8rem;
    color: var(--cyan);
}
.gold { color: var(--gold) !important; }
.zitat { font-style: italic; color: #dfe6fa; }
.genre { font-family: var(--schrift-mono); font-size: 0.85rem; color: var(--text-leise); }

.haupt-video {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    background: var(--flaeche);
    border: 1px solid var(--linie);
    text-decoration: none;
    color: inherit;
    margin-bottom: 36px;
    transition: border-color 0.2s;
}
.haupt-video.bald:hover { border-color: var(--gold); }
.haupt-bild { position: relative; overflow: hidden; }
.haupt-bild img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}
.haupt-video:hover .haupt-bild img { transform: scale(1.04); }
.marke {
    position: absolute;
    top: 0; left: 0;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    padding: 7px 12px;
    background: var(--nacht);
    border-bottom: 2px solid var(--gold);
}
.haupt-text {
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    border-left: 3px solid var(--gold);
}
.haupt-text h3 {
    font-family: var(--schrift-titel);
    font-size: 2rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.link-zeile {
    margin-top: 10px;
    font-family: var(--schrift-mono);
    font-size: 0.9rem;
}

.video-raster {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px;
}
.video-karte {
    display: flex;
    flex-direction: column;
    gap: 6px;
    text-decoration: none;
    color: inherit;
}
.karte-bild {
    position: relative;
    overflow: hidden;
    margin-bottom: 8px;
    aspect-ratio: 16 / 9;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s;
}
.video-karte:hover .karte-bild { border-bottom-color: var(--cyan); }
.karte-bild img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}
.video-karte:hover .karte-bild img { transform: scale(1.05); }
.abspielen {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 2rem;
    color: #fff;
    background: rgba(5, 8, 17, 0.5);
    opacity: 0;
    transition: opacity 0.2s;
}
.video-karte:hover .abspielen,
.video-karte:focus-visible .abspielen { opacity: 1; }
.video-karte h3 {
    font-family: var(--schrift-titel);
    font-size: 1.05rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hinweis {
    margin-top: 32px;
    font-size: 0.9rem;
    color: var(--text-leise);
}

/* ─── Galerie: Bildwand ueber die ganze Breite ─── */
.galerie-kopf {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-family: var(--schrift-mono);
    font-size: 0.88rem;
    color: var(--cyan);
    border-top: 2px solid var(--cyan);
    padding-top: 10px;
    margin-bottom: 14px;
}
.galerie-kopf span + span { color: var(--text-leise); }
.galerie-kopf.gold { color: var(--gold); border-top-color: var(--gold); }
.reiter-seite > .galerie-kopf.gold { margin-top: 56px; }

.reiter-seite > .mosaik {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-auto-flow: dense;
    gap: 6px;
    padding: 0 6px;
}
.kachel {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: var(--flaeche);
}
.kachel.gross {
    grid-column: span 2;
    grid-row: span 2;
}
.mosaik.rechts .kachel.gross { grid-column: 4 / span 2; }
.kachel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease, filter 0.3s;
}
.kachel::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 2px solid transparent;
    transition: border-color 0.2s;
}
.kachel:hover img { transform: scale(1.05); }
.kachel:hover::after,
.kachel:focus-visible::after { border-color: var(--cyan); }
.mosaik.rechts .kachel:hover::after,
.mosaik.rechts .kachel:focus-visible::after { border-color: var(--gold); }

.reiter-seite > .galerie-bald {
    margin-top: 56px;
    padding-top: 10px;
    border-top: 2px dashed rgba(255, 207, 110, 0.5);
    font-family: var(--schrift-mono);
    font-size: 0.88rem;
    color: var(--gold);
}
[hidden] { display: none !important; }

/* Grossansicht */
.grossbild {
    margin: auto;
    padding: 0;
    border: 0;
    background: transparent;
    max-width: 100vw;
    max-height: 100vh;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}
.grossbild::backdrop { background: rgba(3, 5, 11, 0.94); }
.grossbild[open] {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.grossbild img {
    max-width: calc(100vw - 140px);
    max-height: calc(100vh - 110px);
    display: block;
    border: 1px solid var(--linie);
}
.grossbild-text {
    margin-top: 12px;
    font-family: var(--schrift-mono);
    font-size: 0.9rem;
    color: var(--text-leise);
}
.gb-knopf {
    position: absolute;
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    font-size: 1.8rem;
    color: var(--text);
    background: var(--nacht);
    border: 1px solid var(--linie);
    transition: border-color 0.2s, color 0.2s;
}
.gb-knopf:hover { border-color: var(--cyan); color: var(--cyan); }
.gb-zu { top: 16px; right: 16px; font-size: 1.1rem; }
.gb-zurueck { left: 16px; top: 50%; translate: 0 -50%; }
.gb-weiter { right: 16px; top: 50%; translate: 0 -50%; }

/* ─── Reference: ein Konstruktionsblatt ─── */
.blatt-titel {
    font-family: var(--schrift-titel);
    font-size: 0.85rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--cyan);
    border-top: 1px solid var(--linie);
    padding-top: 12px;
    margin: 56px auto 18px auto;
}
.reiter-seite > .blatt-titel:first-of-type { margin-top: 0; }

.reiter-seite > .ansichten {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}
.kachel.ansicht {
    aspect-ratio: 848 / 1264;
    background: #d9d9de;
}
.kachel.ansicht img { object-fit: contain; }
.ansicht-name {
    position: absolute;
    left: 0;
    bottom: 0;
    padding: 6px 10px;
    font-family: var(--schrift-mono);
    font-size: 0.82rem;
    color: var(--text);
    background: var(--nacht);
    border-top: 2px solid var(--cyan);
}
.ansicht.konzept .ansicht-name { border-top-color: var(--magenta); right: 0; }

.reiter-seite > .details {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 36px;
}
.detail-gruppe { padding: 6px 0 22px 0; }
.detail-gruppe h3 {
    font-family: var(--schrift-titel);
    font-size: 1rem;
    letter-spacing: 0.06em;
    color: var(--magenta);
    margin-bottom: 6px;
}
.detail-gruppe dl {
    display: grid;
    grid-template-columns: 100px minmax(0, 1fr);
    column-gap: 14px;
}
.detail-gruppe dt,
.detail-gruppe dd {
    padding: 7px 0;
    border-bottom: 1px solid var(--linie);
}
.detail-gruppe dt {
    font-family: var(--schrift-mono);
    font-size: 0.8rem;
    line-height: 1.6;
    color: var(--text-leise);
}
.detail-gruppe dd { font-size: 0.95rem; line-height: 1.45; }

.reiter-seite > .farbband {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
}
.farbe { display: flex; flex-direction: column; gap: 3px; }
.farb-flaeche {
    height: 120px;
    background: var(--f);
    margin-bottom: 10px;
}
.farb-name {
    font-family: var(--schrift-titel);
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    padding: 0 10px;
}
.farb-hex {
    font-family: var(--schrift-mono);
    font-size: 0.82rem;
    color: var(--text-leise);
    padding: 0 10px;
}
.farb-zweck {
    font-size: 0.88rem;
    color: #c9d1e8;
    padding: 0 10px;
}

.reiter-seite > .story {
    width: min(820px, calc(100% - 80px));
    margin-left: max(40px, calc((100% - 1200px) / 2));
}
.story-zitat {
    font-size: clamp(1.2rem, 2.4vw, 1.55rem);
    font-weight: 300;
    line-height: 1.5;
    border-left: 3px solid var(--magenta);
    padding-left: 20px;
    margin-bottom: 16px;
}
.story p:not(.story-zitat) { line-height: 1.8; color: #dbe2f5; padding-left: 23px; }

/* ─── Statuszeile rechts in der Reiterleiste (wie auf der alten Seite) ─── */
.leisten-status {
    margin-left: auto;
    align-self: center;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    font-family: var(--schrift-mono);
    font-size: 0.75rem;
    color: var(--text);
    white-space: nowrap;
    background: rgba(94, 240, 255, 0.05);
    border: 1px dashed var(--cyan);
    border-radius: 4px;
}
.status-punkt {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 8px var(--cyan);
    animation: punkt-puls 1.5s infinite;
}
@keyframes punkt-puls {
    0%, 100% { opacity: 0.4; }
    50%      { opacity: 1; }
}
html:not(.js) #seite-anker { display: none; }

/* ─── Terminal ─── */
.reiter-seite > .terminal {
    width: min(1000px, calc(100% - 80px));
    border: 1px solid var(--linie);
    border-top: 2px solid var(--cyan);
    background: #03060d;
    font-family: var(--schrift-mono);
}
.terminal-kopf {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 16px;
    font-size: 0.75rem;
    color: var(--text-leise);
    border-bottom: 1px solid var(--linie);
}
.terminal-window {
    height: 440px;
    overflow-y: auto;
    padding: 16px;
    font-size: 0.9rem;
    line-height: 1.65;
    color: #d6e2f5;
    scrollbar-width: thin;
}
.terminal-row { white-space: pre-wrap; overflow-wrap: anywhere; }
.terminal-zeile {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-top: 1px solid var(--linie);
    cursor: text;
}
.terminal-prompt { color: var(--cyan); flex: 0 0 auto; font-size: 0.9rem; }
.terminal-input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: 0;
    outline: none;
    color: var(--text);
    font: inherit;
    font-size: 0.95rem;
    caret-color: var(--cyan);
}
.terminal-input::placeholder { color: #56607a; }
.terminal:focus-within { border-color: rgba(94, 240, 255, 0.45); }

/* ─── Musik-Player: kleiner Funkempfaenger ─── */
.empfaenger {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 60;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: var(--nacht);
    border: 1px solid rgba(255, 79, 168, 0.45);
    border-radius: 18px;
}
.emp-knopf {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--magenta);
    border-radius: 50%;
    color: var(--magenta);
    font-size: 0.95rem;
    transition: background 0.2s;
}
.emp-knopf:hover { background: rgba(255, 79, 168, 0.12); }
.emp-knopf.klein { width: 30px; height: 30px; border-color: var(--linie); color: var(--text-leise); font-size: 0.8rem; }
.emp-info { display: flex; flex-direction: column; min-width: 128px; line-height: 1.3; }
.emp-titel { font-family: var(--schrift-titel); font-size: 0.82rem; letter-spacing: 0.06em; text-transform: uppercase; }
.emp-unter { font-family: var(--schrift-mono); font-size: 0.72rem; color: var(--text-leise); }
.emp-wellen { display: flex; align-items: flex-end; gap: 3px; height: 20px; }
.emp-wellen i { width: 3px; height: 4px; background: var(--magenta); border-radius: 2px; }
.empfaenger.spielt .emp-wellen i { animation: welle 0.9s ease-in-out infinite alternate; }
.empfaenger.spielt .emp-wellen i:nth-child(2) { animation-delay: -0.3s; }
.empfaenger.spielt .emp-wellen i:nth-child(3) { animation-delay: -0.6s; }
.empfaenger.spielt .emp-wellen i:nth-child(4) { animation-delay: -0.15s; }
.empfaenger.spielt .emp-wellen i:nth-child(5) { animation-delay: -0.45s; }
@keyframes welle { from { height: 3px; } to { height: 20px; } }
.emp-laut { width: 80px; accent-color: var(--magenta); }
.empfaenger:focus-within { border-color: var(--magenta); }
.emp-mini {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 60;
    width: 46px;
    height: 46px;
    background: var(--nacht);
    border: 1px solid var(--magenta);
    border-radius: 50%;
    color: var(--magenta);
    font-size: 1.2rem;
}
/* Eingeklappt und Musik laeuft: das Notenzeichen wackelt */
.emp-mini.spielt { animation: wackeln 1.1s ease-in-out infinite; }
@keyframes wackeln {
    0%, 100% { transform: rotate(0deg) scale(1); }
    25%      { transform: rotate(-14deg) scale(1.08); }
    75%      { transform: rotate(14deg) scale(1.08); }
}
.empfaenger.zu { display: none; }

/* ─── Lore: Ausweis quer oben, darunter Kapitel mit Leiste (Idee B) ─── */
.reiter-seite > .ausweis {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr) 260px;
    gap: 32px;
    padding: 22px;
    background: var(--flaeche);
    border: 1px solid var(--linie);
    border-top: 3px solid var(--magenta);
    margin-bottom: 56px;
}
.ausweis-foto {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border: 1px solid var(--linie);
}
.ausweis-name {
    font-family: var(--schrift-titel);
    font-weight: 900;
    font-size: 2.4rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    line-height: 1;
}
.ausweis-art {
    margin: 8px 0 14px 0;
    color: var(--text-leise);
}
.ausweis-daten {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    column-gap: 16px;
}
.ausweis-daten dt,
.ausweis-daten dd {
    padding: 8px 0;
    border-top: 1px solid var(--linie);
}
.ausweis-daten dt {
    font-family: var(--schrift-mono);
    font-size: 0.8rem;
    line-height: 1.6;
    color: var(--text-leise);
}
.ausweis-daten dd { font-size: 0.98rem; line-height: 1.45; }
.ausweis-status {
    border-left: 1px solid var(--linie);
    padding-left: 24px;
}
.akte-kopf {
    font-family: var(--schrift-titel);
    font-size: 0.78rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--cyan);
    margin: 0 0 8px 0;
}
.akte-kopf.magenta { color: var(--magenta); }

.foto-rahmen { position: relative; overflow: hidden; }
.scanner {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, transparent, var(--cyan), transparent);
    box-shadow: 0 0 10px var(--cyan);
    opacity: 0.8;
    animation: scannen 4s linear infinite;
    pointer-events: none;
}
@keyframes scannen {
    0%, 100% { top: 0%; }
    50%      { top: calc(100% - 3px); }
}

/* simulierter System-Status */
.status-wert {
    --farbe: var(--cyan);
    display: grid;
    grid-template-columns: 1fr auto;
    row-gap: 6px;
    font-size: 0.92rem;
    padding: 8px 0;
}
.status-wert.magenta { --farbe: var(--magenta); }
.status-zahl {
    font-family: var(--schrift-mono);
    color: var(--farbe);
}
.status-balken {
    grid-column: 1 / -1;
    height: 5px;
    background: var(--linie);
}
.status-balken i {
    display: block;
    height: 100%;
    background: var(--farbe);
    transition: width 0.8s ease;
}

/* Kapitel-Leiste links, bleibt beim Lesen stehen */
.reiter-seite > .lore-layout {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 48px;
    align-items: start;
}
.kapitel-leiste {
    position: sticky;
    top: 86px;
    display: flex;
    flex-direction: column;
    border-left: 1px solid var(--linie);
}
.kapitel-leiste a {
    display: grid;
    grid-template-columns: 30px 1fr;
    gap: 10px;
    align-items: start;
    padding: 9px 0 9px 14px;
    margin-left: -1px;
    border-left: 2px solid transparent;
    color: var(--text-leise);
    text-decoration: none;
    font-size: 0.92rem;
    line-height: 1.35;
    transition: color 0.2s, border-color 0.2s;
}
.kapitel-leiste span {
    font-family: var(--schrift-titel);
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--magenta);
}
.kapitel-leiste em { font-style: normal; }
.kapitel-leiste a:hover { color: var(--text); }
.kapitel-leiste a.aktiv {
    color: var(--text);
    border-left-color: var(--magenta);
}

/* Kapitel */
/* Kapitel-Kaesten wie auf der alten Seite: pinke Eck-Winkel, Rand
   leuchtet bei Maus darueber */
.kapitel {
    position: relative;
    margin-bottom: 48px;
    scroll-margin-top: 80px;
    padding: 34px 36px;
    background: rgba(14, 22, 42, 0.55);
    border: 1px solid var(--linie);
    border-radius: 8px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.kapitel::before,
.kapitel::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    pointer-events: none;
    transition: width 0.3s ease, height 0.3s ease;
}
.kapitel::before {
    top: -1px; left: -1px;
    border-top-color: var(--magenta);
    border-left-color: var(--magenta);
    border-top-left-radius: 8px;
}
.kapitel::after {
    bottom: -1px; right: -1px;
    border-bottom-color: var(--magenta);
    border-right-color: var(--magenta);
    border-bottom-right-radius: 8px;
}
.kapitel:hover {
    border-color: rgba(255, 79, 168, 0.55);
    box-shadow: 0 0 0 1px rgba(255, 79, 168, 0.25), 0 12px 40px rgba(255, 79, 168, 0.12);
}
.kapitel:hover::before,
.kapitel:hover::after { width: 34px; height: 34px; }
.kapitel-nr {
    font-family: var(--schrift-mono);
    font-size: 0.9rem;
    color: var(--magenta);
    margin-bottom: 6px;
}
.kapitel h3 {
    font-family: var(--schrift-titel);
    font-size: clamp(1.4rem, 3vw, 2.1rem);
    letter-spacing: 0.05em;
    line-height: 1.25;
    margin-bottom: 26px;
}
.kapitel h4 {
    font-family: var(--schrift-titel);
    font-size: 0.95rem;
    letter-spacing: 0.08em;
    color: var(--cyan);
    margin: 30px 0 8px 0;
}
.kapitel p {
    line-height: 1.8;
    color: #dbe2f5;
}
.kapitel p + p { margin-top: 1em; }
/* alle Kapitelbilder gleich: volle Spaltenbreite, 16:9 */
.kapitel-bild { margin: 32px 0; }
.kapitel-bild img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border: 1px solid var(--linie);
}

/* Filoos Zitate: gross, mit Magenta-Linie */
.filoo-zitat {
    margin: 40px 0 0 0;
    padding-left: 22px;
    border-left: 3px solid var(--magenta);
}
.filoo-zitat p {
    font-size: clamp(1.15rem, 2.2vw, 1.4rem);
    line-height: 1.55;
    font-weight: 300;
    color: var(--text);
}
.filoo-zitat cite {
    display: block;
    margin-top: 12px;
    font-style: normal;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    color: var(--magenta);
}

/* ─── Logbuch: schmale Lesespalte, Eintraege an einer Linie ─── */
.reiter-seite > .logbuch { width: min(760px, calc(100% - 80px)); }
.log-quelle {
    display: inline-block;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    color: var(--cyan);
    text-decoration: none;
    margin-bottom: 26px;
    padding-left: 92px;
}
a.log-quelle:hover { text-decoration: underline; }

.log-liste {
    list-style: none;
    position: relative;
}
/* die durchgehende Linie, an der die Eintraege haengen */
.log-liste::before {
    content: "";
    position: absolute;
    left: 70px;
    top: 6px;
    bottom: 6px;
    width: 1px;
    background: var(--linie);
}

.log-eintrag {
    --farbe: var(--cyan);
    position: relative;
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr);
    column-gap: 22px;
    padding-bottom: 34px;
}
.log-eintrag.gold { --farbe: var(--gold); }
/* Markierung auf der Linie */
.log-eintrag::before {
    content: "";
    position: absolute;
    left: 66px;
    top: 9px;
    width: 9px;
    height: 9px;
    background: var(--farbe);
}

.log-nr {
    font-family: var(--schrift-titel);
    font-weight: 900;
    font-size: 2.1rem;
    line-height: 1;
    color: var(--farbe);
    text-align: right;
    padding-right: 14px;
}
.log-text p {
    font-family: var(--schrift-mono);
    font-size: 0.98rem;
    line-height: 1.75;
    color: var(--text);
}

/* Bildpause ueber die ganze Fensterbreite */
.log-band {
    position: relative;
    margin: 30px 0 56px 0;
}
.log-band img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 1;
    object-fit: cover;
    object-position: 50% 42%;
}
.log-band figcaption {
    position: absolute;
    left: 50%;
    bottom: 0;
    translate: -50% 50%;
    font-family: var(--schrift-mono);
    font-size: 0.95rem;
    color: var(--text);
    background: var(--nacht);
    border: 1px solid var(--cyan);
    padding: 8px 18px;
    white-space: nowrap;
}

.log-schluss {
    font-family: var(--schrift-mono);
    color: var(--text-leise);
    padding-left: 92px;
    margin-top: 4px;
}
.log-offen {
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    color: var(--text-leise);
    padding-left: 92px;
    margin-top: 40px;
}
.log-cursor {
    color: var(--cyan);
    animation: blinken 1.1s steps(1) infinite;
}
@keyframes blinken { 50% { opacity: 0; } }

.platzhalter {
    padding: 50px 24px;
    text-align: center;
    font-family: var(--schrift-mono);
    font-size: 0.9rem;
    color: var(--text-leise);
    border: 1px dashed var(--linie);
}

/* ═══ ANIMATIONEN (Niclas, 17.11.: gern mehr davon) ═══ */
/* Reiterwechsel: Inhalt gleitet sanft herein, Linie zieht sich auf */
.js .reiter-seite.aktiv { animation: reiter-rein 0.45s ease-out; }
@keyframes reiter-rein {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: none; }
}
.reiter-seite.aktiv .kopf-linie {
    transform-origin: left;
    animation: linie-ziehen 0.9s 0.15s cubic-bezier(.6,.05,.25,1) both;
}
@keyframes linie-ziehen { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* Beim Scrollen nacheinander erscheinen. Nur mit JS; seite.js zeigt
   nach spaetestens 2,5 s alles (Notausgang) */
.js .erscheint {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.6s ease, transform 0.6s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    transition-delay: var(--verzoegerung, 0s);
}
.js .erscheint.sichtbar { opacity: 1; transform: none; }
.js .erscheint.sichtbar:hover { transition-delay: 0s; }

/* Logbuch: Markierung leuchtet bei Maus darueber */
.log-eintrag::before { transition: box-shadow 0.3s, transform 0.3s; }
.log-eintrag:hover::before {
    box-shadow: 0 0 12px var(--farbe);
    transform: scale(1.4);
}
.log-nr { transition: text-shadow 0.3s; }
.log-eintrag:hover .log-nr { text-shadow: 0 0 14px var(--farbe); }

/* Farbband: Farbe hebt sich und leuchtet in ihrer Farbe */
.farb-flaeche { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.farbe:hover .farb-flaeche {
    transform: translateY(-6px);
    box-shadow: 0 10px 30px color-mix(in srgb, var(--f) 45%, transparent);
}

/* Detail-Gruppen: Ueberschrift leuchtet */
.detail-gruppe h3 { transition: text-shadow 0.3s; }
.detail-gruppe:hover h3 { text-shadow: 0 0 12px var(--magenta); }

/* Signal-Meldung im Kopf: goldener Rand atmet leicht */
.signal-meldung { animation: gold-atmen 3.5s ease-in-out infinite; }
@keyframes gold-atmen {
    0%, 100% { box-shadow: -3px 0 0 0 transparent; }
    50%      { box-shadow: -6px 0 18px -4px rgba(255, 207, 110, 0.55); }
}

/* ═══ DATENSCHUTZ-SEITE ═══ */
.rechtstext {
    width: min(760px, calc(100% - 40px));
    margin: 48px auto 0 auto;
    line-height: 1.75;
}
.rechtstext h1 {
    font-family: var(--schrift-titel);
    font-size: clamp(1.4rem, 5vw, 1.9rem);
    letter-spacing: 0.1em;
    margin: 18px 0 26px 0;
}
.rechtstext h2 {
    font-family: var(--schrift-titel);
    font-size: 0.95rem;
    letter-spacing: 0.1em;
    color: var(--cyan);
    margin: 32px 0 8px 0;
}
.rechtstext p, .rechtstext li { color: #dbe2f5; }
.rechtstext ul { margin: 8px 0 8px 22px; }
.rechtstext a { color: var(--cyan); }
.rechtstext .zurueck {
    display: inline-block;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    text-decoration: none;
    margin-top: 10px;
}

/* ═══ FUSS ═══ */
.fuss {
    max-width: 1280px;
    margin: 40px auto 0 auto;
    padding: 24px 40px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    font-family: var(--schrift-mono);
    font-size: 0.85rem;
    color: var(--text-leise);
    border-top: 1px solid var(--linie);
}
.fuss a { color: var(--text-leise); }
.fuss a:hover { color: var(--cyan); }

/* ═══ SCHMALE ODER FAST QUADRATISCHE FENSTER ═══
   Text untereinander, Filoo bleibt oben sichtbar */
@media (max-width: 820px), (max-aspect-ratio: 5/4) {
    .hero { height: 78svh; max-height: none; }
    .hero-bild { background-position: 62% 30% !important; }
    .hero-verlauf {
        background:
            linear-gradient(180deg, rgba(5, 8, 17, 0) 0%, rgba(5, 8, 17, 0.1) 40%, rgba(5, 8, 17, 0.85) 68%, var(--nacht) 100%);
    }
    .hero-unten {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
        padding: 0 20px 24px 20px;
    }
    .signal-meldung { min-width: 0; }
}

@media (max-width: 820px) {
    .reiter-spur { padding: 0 8px; }
    .reiter { padding: 16px 12px 14px 12px; font-size: 0.75rem; }
    .haupt-video { grid-template-columns: minmax(0, 1fr); }
    .haupt-text { padding: 22px; border-left: 0; border-top: 3px solid var(--gold); }
    .video-raster { grid-template-columns: minmax(0, 1fr); }
    .inhalt { padding: 40px 0; }
    .reiter-seite > *,
    .reiter-seite > .logbuch { width: calc(100% - 40px); }
    .reiter-seite > .randlos { width: 100%; }
    .fuss { padding: 24px 20px; }
    .kopf-fakt { display: none; }

    .log-liste::before { left: 44px; }
    .log-eintrag { grid-template-columns: 44px minmax(0, 1fr); column-gap: 16px; }
    .log-eintrag::before { left: 40px; }
    .log-nr { font-size: 1.3rem; padding-right: 10px; }
    .log-text p { font-size: 0.95rem; }
    .log-quelle, .log-schluss, .log-offen { padding-left: 60px; }
    .log-band img { aspect-ratio: 4 / 3; }

    .reiter-seite > .ausweis { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 16px; }
    .ausweis-foto { max-width: 220px; }
    .ausweis-daten { grid-template-columns: 110px minmax(0, 1fr); }
    .ausweis-status { border-left: 0; padding-left: 0; }
    .reiter-seite > .lore-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
    .kapitel-leiste { display: none; }
    .kapitel { padding: 24px 18px; }
    .leisten-status { display: none; }
    /* Handy: Player unten als eigene Leiste, die Seite bekommt Platz */
    .empfaenger { left: 0; right: 0; bottom: 0; gap: 10px; padding: 8px 12px; border-radius: 18px 18px 0 0; border-bottom: 0; }
    .emp-info { flex: 1; min-width: 0; }
    .emp-laut, .emp-wellen { display: none; }
    body { padding-bottom: 64px; }
    body.player-zu { padding-bottom: 0; }
    .emp-mini { right: 12px; bottom: 12px; }
    .reiter-seite > .terminal { width: calc(100% - 40px); }
    .terminal-window { height: 360px; font-size: 0.85rem; }
    .reiter-seite > .ansichten { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
    .reiter-seite > .details { grid-template-columns: minmax(0, 1fr); }
    .reiter-seite > .farbband { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 22px; }
    .farb-flaeche { height: 70px; }
    .reiter-seite > .story { width: calc(100% - 40px); margin-left: 20px; }
    .reiter-seite > .mosaik { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 0 4px; }
    .kachel.gross, .mosaik.rechts .kachel.gross { grid-column: auto; grid-row: auto; }
    .grossbild img { max-width: 100vw; max-height: calc(100vh - 140px); border-left: 0; border-right: 0; }
    .gb-zurueck, .gb-weiter { top: auto; bottom: 16px; translate: none; }
}

@media (min-width: 821px) and (max-width: 1100px) {
    .reiter-seite > .mosaik { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .reiter-seite > .details { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .reiter-seite > .farbband { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 22px; }
    .mosaik.rechts .kachel.gross { grid-column: 2 / span 2; }
    .reiter-seite > .ausweis { grid-template-columns: 190px minmax(0, 1fr); }
    .ausweis-status { grid-column: 1 / -1; border-left: 0; padding-left: 0; border-top: 1px solid var(--linie); padding-top: 14px; }
    .reiter-seite > .lore-layout { grid-template-columns: 170px minmax(0, 1fr); gap: 32px; }
}

/* "Bewegung reduzieren" im System: ruhige Seite */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
}
