/* --- Sansation: Signaturschrift der ganzen Seite ----------------------------
 * Fuenf echte Schnitte, selbst gehostet in fonts/ (OFL-sansation.txt).
 * Kein Weg zu einem Drittanbieter. Die Marken von BRAWONE und TOMS • TOWN
 * in der Fusszeile behalten ihre eigenen Schriften aus dem publishmanager.
 * ------------------------------------------------------------------------- */
@font-face {
    font-family: 'Sansation'; src: url('../fonts/Sansation-Light.woff2') format('woff2');
    font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
    font-family: 'Sansation'; src: url('../fonts/Sansation-Regular.woff2') format('woff2');
    font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
    font-family: 'Sansation'; src: url('../fonts/Sansation-Italic.woff2') format('woff2');
    font-weight: 400; font-style: italic; font-display: swap;
}
@font-face {
    font-family: 'Sansation'; src: url('../fonts/Sansation-Bold.woff2') format('woff2');
    font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
    font-family: 'Sansation'; src: url('../fonts/Sansation-BoldItalic.woff2') format('woff2');
    font-weight: 700; font-style: italic; font-display: swap;
}

    /* --- UbuntuSans als zweite Stufe --------------------------------------------
     * Ubuntu Sans deckt vor allem die 214 kyrillischen Zeichen ab, die
     * Sansation nicht hat. Gerade im Kontaktformular
     * ist das relevant: dort koennen Besucher in jeder Sprache schreiben.
     * Auch ein Variable Font, deshalb EIN Block fuer wght 100-800.
     * Die Breitenachse wdth wurde beim Erzeugen der Datei auf 100
     * festgelegt; die Condensed-Schnitte werden nicht verwendet und
     * wuerden sonst 1050 statt 194 KB kosten.
     * Ubuntu Sans steht unter der Ubuntu Font Licence, nicht unter OFL.
     * ------------------------------------------------------------- */
    @font-face {
        font-family: 'UbuntuSans'; src: url('../fonts/ubuntu-var.woff2') format('woff2');
        font-weight: 100 800; font-style: normal; font-display: swap;
    }
    @font-face {
        font-family: 'UbuntuSans'; src: url('../fonts/ubuntu-var-italic.woff2') format('woff2');
        font-weight: 100 800; font-style: italic; font-display: swap;
    }

html {
    margin: 0; padding: 0; height: 100%; width: 100%;
    background-color: #050505;
}
body {
    margin: 0; padding: 0; height: 100%; width: 100%;
    /* Transparent: Der Body-Hintergrund wuerde die Glas-Ebene (#glasHintergrund,
     * z -2) und die schwarze Innenflaeche (body::before, z -1) ueberdecken,
     * weil er in der Malreihenfolge NACH den negativen Ebenen liegt. */
    background: transparent;
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
    color: white; overflow: hidden;
}

/* --- Liquid Glass: unscharfe Vollbild-Kopie des Fotos als Untergrund ---
 * Das Bild liegt hinter allem und scheint NUR ausserhalb der blauen
 * Linie (.rahmen) durch: body::before deckt die Innenflaeche schwarz ab.
 * #glasHintergrund setzt das JS beim Bildwechsel; body ist transparent,
 * damit die Ebene durchscheint. */
#glasHintergrund {
    position: fixed;
    inset: -10%;
    z-index: -2;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: blur(40px) saturate(1.3);
    pointer-events: none;
}
/* Innenflaeche deckend schwarz: Glas nur im 10px-Rand ausserhalb der Linie.
 * Radius 24px = derselbe Wert wie .rahmen und der Fotorahmen innen. */
body::before {
    content: '';
    position: fixed;
    inset: calc(10px + var(--fam)) 10px 10px;
    z-index: -1;
    background: #050505;
    border-radius: 24px;
}

/* --- HEADER --- */
/* 12px Abstand zur blauen Linie: Die Leiste sitzt mittig in ihrem Feld
 * zwischen Linie und Fotokarte (die Karte rutscht per JS ebenfalls 12px
 * unter die Leiste -> oben und unten gleich viel Luft).
 * Radius 13 schmiegt sich an die Innenkante des Rahmens an. */
#main-header {
    position: fixed; top: calc(23px + var(--fam)); left: 11px; right: 11px; width: auto;
    background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px); text-align: center; pointer-events: auto;
    border-radius: 13px 13px 0 0; z-index: 10002;
}

.header-group {
    display: inline-block;
    width: max-content;
    max-width: 90vw;
    padding: clamp(12px, 2.5vh, 24px) 0;
}

.header-content {
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
    font-weight: 200; letter-spacing: 5px; text-transform: uppercase;
    font-size: clamp(1rem, 2.6vw, 1.35rem); margin-bottom: 12px; white-space: nowrap;
}

/* Seitentitel ist eine h1: Browser-Abstand oben entfernen, sonst wie bisher */
h1.header-content { margin-top: 0; }

.header-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.header-line {
    width: 100%; height: 1px; min-height: 1px; flex-shrink: 0;
    background: rgba(255, 255, 255, 0.4);
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* --- FOOTER --- */
#main-footer {
    position: fixed; bottom: 23px; left: 11px; right: 11px; width: auto;
    background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px); z-index: 10001; pointer-events: auto;
    border-radius: 0 0 13px 13px;
}

.footer-inner {
    padding: clamp(10px, 2vh, 16px) 0 20px 0;
    max-width: 1200px; margin: 0 auto;
    display: flex; flex-direction: column; align-items: center;
}

#description {
    font-weight: 200; font-size: clamp(0.95rem, 2.4vw, 1.1rem); letter-spacing: 1px;
    margin-bottom: 12px; padding: 0 40px; text-align: center;
    min-height: 1.5em;
}

/* Zaehler der Serie ("5 / 32"): ruhig, kleinere Stufe. Abstand kommt
 * aus der Fusszeile (flex-gap), kein eigener. */
.serie-nr {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85em;
    letter-spacing: 1px;
    white-space: nowrap;
    margin-left: 0;
}

.reload-link {
    color: rgba(255, 255, 255, 0.4);    text-decoration: none;
    font-size: inherit;
    font-weight: 200;
    letter-spacing: 1px;
    margin-left: 1em;
    transition: color 0.3s ease, outline-color 0.3s ease;
    white-space: nowrap;
}

.reload-link i {
    font-size: 0.8em;
    vertical-align: middle;
}

.reload-link:hover {
    color: #ffffff;
}

.footer-line {
    width: 60%; height: 1px; min-height: 1px; flex-shrink: 0;
    background: rgba(255, 255, 255, 0.15); margin-bottom: 20px;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.footer-bottom {
    width: 100%;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

#copyright {
    font-size: 0.82rem; font-weight: 400; letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.4); text-transform: uppercase;
}

.copyright-link {
    color: inherit;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.copyright-link:hover {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.button-row {
    display: flex; gap: 30px; justify-content: center;
}

.url-button {
    color: rgba(255, 255, 255, 0.4); text-decoration: none;
    font-size: 0.82rem; font-weight: 400; text-transform: uppercase;
    letter-spacing: 1.5px; display: flex; align-items: center;
    transition: all 0.3s ease; padding: 5px 0; cursor: pointer;
}

.url-button .icon {
    color: rgba(255, 255, 255, 0.4);
    margin: 0 5px;
}

/* Eigene Icons (statt Font Awesome): 1em gross, Grundlinien-buendig. */
.icon {
    width: 1em;
    height: 1em;
    vertical-align: -0.125em;
}

.url-button:hover {
    color: #ffffff; transform: translateY(-3px);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* --- Accessibility: sichtbarer Tastatur-Fokus --- */
a:focus-visible,
button:focus-visible,
#mobile-next:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.9);
    outline-offset: 3px;
    border-radius: 2px;
}

/* --- LAYOUT --- */
#main-wrapper { height: 100vh; display: flex; flex-direction: column; pointer-events: none; }

#camera-cursor {
    /* Entwurf: Folge-Cursor (Icon + Label) aus – Klick-Funktion und
     * Blitz-Effekt bleiben unveraendert erhalten. */
    display: none !important;
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-50%, -50%);
    display: none;
    opacity: 0;
    align-items: center;
    gap: 12px;
    transition: opacity 0.3s ease;
}

.cursor-label {
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
    font-size: 0.8rem;
    font-weight: 200;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.7);
    white-space: nowrap;
    background: rgba(0, 0, 0, 0.2);
    padding: 4px 8px;
    border-radius: 4px;
}

#camera-cursor i {
    color: rgba(255, 255, 255, 0.5);
    font-size: 2rem;
    filter: drop-shadow(0 0 5px rgba(0,0,0,0.3));
}

.flash-active-icon i {
    color: #fff !important;
    text-shadow: 0 0 15px #fff;
}

#camera-cursor.is-active {
    display: flex;
}

#camera-cursor.is-visible {
    opacity: 1;
}

/* Ohne Hover kein Kamera-Cursor (Sicherheitsnetz zum JS-Guard). */
@media (hover: none) {
    #camera-cursor { display: none !important; }
}

body.is-loading::after {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 2px solid rgba(255,255,255,0.1);
    border-top-color: rgba(255,255,255,0.6);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    z-index: 9999;
    pointer-events: none;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#screen-flash {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    z-index: 5;
    opacity: 0;
    background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
                rgba(255, 255, 255, 0.8) 0%,
                rgba(255, 255, 255, 0) 70%);
    mix-blend-mode: screen;
}

.flash-active {
    animation: pro-flash 1.2s ease-out forwards;
}

@keyframes pro-flash {
    0% { opacity: 0; }
    5% { opacity: 1; }
    100% { opacity: 0; }
}

.cursor-hidden { opacity: 0 !important; }

/* --- Reduced Motion: Animationen aus --- */
@media (prefers-reduced-motion: reduce) {
    body.is-loading::after,
    .flash-active {
        animation: none !important;
    }
    #screen-flash { opacity: 0 !important; }
    .copyright-link:hover,
    .url-button:hover,
    .reload-link,
    #mobile-next {
        transform: none !important;
    }
    * { transition-duration: 0.01s !important; }
}

@media (max-width: 768px) {
    .header-group { padding: 30px 0; }
    /* Leisten mobil gestapelt und mittig (ID-Selektor: steht weiter
     * oben als die Basis-Regeln und muss trotzdem gewinnen). */
    #main-header .header-zeile, #main-footer .fuss-zeile {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
        gap: 0.3rem;
        padding-top: 0.6rem;
        padding-bottom: 0.6rem;
        max-width: none;
    }
    .header-zeile .kopf-seite:first-child,
    .header-zeile .kopf-seite:last-child,
    .fuss-zeile #copyright { justify-self: center; text-align: center; }
    #main-footer .fuss-rechts { justify-self: center; }
    .header-content { font-size: 1.05rem; white-space: nowrap; }
    .button-row { gap: 6px; flex-wrap: wrap; }
    #description { font-size: 0.95rem; margin-bottom: 10px; padding: 0 20px; }
    /* Mobil schlanker Fuss: weniger Luft, keine Zierlinie. */
    .footer-inner { padding: 10px 0 14px 0; }
    .footer-line { display: none; }
    .footer-bottom { gap: 6px 12px; }
    /* Beschreibung und Zufalls-Button je eigene Zeile mit Luft. */
    .reload-link { display: block; margin: 10px 0 0 0; }
    /* Copyright + beide Buttons: exakt gleiche Zeilen, gleiche Luecken. */
    #copyright, .url-button { font-size: 0.8rem; line-height: 1.4; margin: 0; padding: 3px 14px; }
    .footer-bottom { gap: 0; }
    .button-row { gap: 0; }
}
/* Sehr schmal (iPhone SE): Kopfzeile muss einzeilig bleiben. */
@media (max-width: 480px) {
    .header-content { font-size: 0.82rem; letter-spacing: 3px; }

    .mobile-next {
        display: flex;
        position: fixed;
        bottom: 16px;
        right: 16px;
        z-index: 2000;
        align-items: center;
        gap: 8px;
        padding: 12px 20px;
        border: 1px solid rgba(255, 255, 255, 0.35);
        border-radius: 24px;
        background: rgba(0, 0, 0, 0.55);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        color: white;
        font-family: 'Sansation', 'UbuntuSans', sans-serif;
        font-weight: 400;
        text-transform: uppercase;
        letter-spacing: 1px;
        font-size: 0.75rem;
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .mobile-next:active {
        transform: scale(0.95);
        background: rgba(255, 255, 255, 0.2);
    }
}

.mobile-next {
    display: none;
    border: none;
}

/* --- Firefox: Sansation ------------------------------------------------------
 * Sansation zuerst und damit auf jedem System dieselbe Datei.
 * Der Block bleibt, weil Firefox die Schrift etwas fetter zeichnet,
 * deshalb feste Gewichte, damit alle Browser gleich wirken.
 * font-synthesis-weight: none verhindert erfundenes Fett: Die vier Schnitte
 * Light/Regular/Bold/Italic liegen echt vor, es wird nichts nachgebaut.
 * Andere Browser ignorieren diesen Block.
 * ------------------------------------------------------------------------- */
@supports (-moz-appearance: none) {
    /* Die Familienleiste (und die Marken darin) behalten ihre eigenen Schriften,
     * sonst ist sie in Firefox nur hier anders breit als auf den anderen Seiten. */
    html, body, body *:not(.familie):not(.familie *) {
        font-family: 'Sansation', 'UbuntuSans', sans-serif !important;
        font-synthesis-weight: none !important;
        font-weight: 300 !important;
        -moz-osx-font-smoothing: auto !important;
    }
    h1, h2, h3, strong, b, .header-content, .footer-inner { font-weight: 700 !important; }
}

/* --- Blaettern ueber die Seitenflaechen (wie tomstown.ch) -------------------
 * Ganze Hoehe klickbar, Text senkrecht am Aussenrand. Verlauf (zurueck)
 * geht durch die besuchten Bilder, vorwaerts wuerfelt neu. Hover in
 * Wand-Blau. Nur Desktop mit Maus. */
.seite {
    position: fixed;
    top: 0;
    bottom: 0;
    width: 4.5rem;
    padding: 0;
    border: 0;
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    cursor: pointer;
    z-index: 1500;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.4);
    -webkit-tap-highlight-color: transparent;
    transition: color 0.2s, background-color 0.25s;
}
.seite:hover { color: #fff; }
.seite:hover span { text-shadow: none; }
/* Hover: Registerlasche in Wand-Blau, haengt am Fotorahmen (runde Ecken
 * aussen, weiche Kehle zum Rahmen). 9-Slice, damit die Rundungen bei jeder
 * Hoehe gleich bleiben. Der Rahmen liegt 13px innerhalb der Flaeche. */
.seite::before {
    content: '';
    position: absolute;
    top: 30%;
    bottom: 30%;
    width: 30px;
    border-style: solid;
    border-color: transparent;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}
.seite-rechts::before {
    left: -14px;
    border-width: 40px 40px 40px 0;
    border-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2070%20120'%20width='70'%20height='120'%3E%3Cg%3E%3Cpath%20d='M0.5,0%20A16,16%200%200%200%2016.5,16%20L47.5,16%20A22,22%200%200%201%2069.5,38%20L69.5,82%20A22,22%200%200%201%2047.5,104%20L16.5,104%20A16,16%200%200%200%200.5,120%20L0,120%20L0,0%20Z'%20fill='rgba(91,124,255,0.24)'/%3E%3Cpath%20d='M0.5,0%20A16,16%200%200%200%2016.5,16%20L47.5,16%20A22,22%200%200%201%2069.5,38%20L69.5,82%20A22,22%200%200%201%2047.5,104%20L16.5,104%20A16,16%200%200%200%200.5,120'%20fill='none'%20stroke='%235b7cff'%20stroke-width='1'/%3E%3C/g%3E%3C/svg%3E") 40 40 40 0 fill / 40px 40px 40px 0 stretch;
}
.seite-links::before {
    right: -14px;
    border-width: 40px 0 40px 40px;
    border-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2070%20120'%20width='70'%20height='120'%3E%3Cg%20transform='translate(70%200)%20scale(-1%201)'%3E%3Cpath%20d='M0.5,0%20A16,16%200%200%200%2016.5,16%20L47.5,16%20A22,22%200%200%201%2069.5,38%20L69.5,82%20A22,22%200%200%201%2047.5,104%20L16.5,104%20A16,16%200%200%200%200.5,120%20L0,120%20L0,0%20Z'%20fill='rgba(91,124,255,0.24)'/%3E%3Cpath%20d='M0.5,0%20A16,16%200%200%200%2016.5,16%20L47.5,16%20A22,22%200%200%201%2069.5,38%20L69.5,82%20A22,22%200%200%201%2047.5,104%20L16.5,104%20A16,16%200%200%200%200.5,120'%20fill='none'%20stroke='%235b7cff'%20stroke-width='1'/%3E%3C/g%3E%3C/svg%3E") 40 0 40 40 fill / 40px 0 40px 40px stretch;
}
.seite:hover::before { opacity: 1; }
/* Pfeiltasten: gleicher Look wie Maus-Hover (Klasse per JS). */
.seite.taste-hover { color: #fff; }
.seite.taste-hover span { text-shadow: none; }
.seite.taste-hover::before { opacity: 1; }
.seite span { position: relative; }
.seite span {
    writing-mode: vertical-rl;
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    white-space: nowrap;
}
/* Text naeher am Fotorand: links nach innen (rechts), rechts nach innen (links). */
/* Ohne Hover: Text mittig zwischen Fotorahmen und Kartenrand.
 * Mit Hover gleitet er 7.5px zum Foto und sitzt mittig in der Lasche. */
.seite-links { justify-content: flex-end; padding-right: 23.5px; }
.seite-rechts { justify-content: flex-start; padding-left: 23.5px; }
.seite span { transition: translate 0.25s ease; }
.seite-links:hover span, .seite-links.taste-hover span { translate: 7.5px 0; }
.seite-rechts:hover span, .seite-rechts.taste-hover span { translate: -7.5px 0; }
@media (hover: none) { .seite span { translate: none !important; } }
.seite-links span { transform: rotate(180deg); }
.seite:focus-visible { outline: 2px solid #5b7cff; outline-offset: -4px; }
.seite:disabled { opacity: 0; pointer-events: none; }
#seiteZurueck { left: 11px; }
#seiteWeiter { right: 11px; }
@media (hover: none) {
    /* Mobil: schmalere Zonen, immer dezent sichtbar (kein Hover). */
    .seite { width: 3rem; }
    .seite span { font-size: 0.62rem; }
}
/* Seitenzonen: Pfeil + kurzes Wort statt langem Satz, besser lesbar. */
.seite { color: rgba(255, 255, 255, 0.55); }
.seite .seite-inhalt { writing-mode: horizontal-tb; transform: none; display: flex; flex-direction: column; align-items: center; gap: 12px; font-size: inherit; letter-spacing: 0; text-transform: none; }
.seite .seite-pfeil { width: 26px; height: 26px; flex: none; }
.seite .seite-wort { writing-mode: vertical-rl; font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase; translate: none !important; }
.seite-links .seite-wort { transform: rotate(180deg); }
.seite .seite-inhalt .seite-wort { transition: none; }
@media (hover: none) { .seite .seite-pfeil { width: 22px; height: 22px; } .seite .seite-wort { display: none; } }
/* Ein Satz zur Entstehung des Fotos (aus der Verwaltung), unter dem Titel. */
/* contain: Die Notiz macht die Fussmitte nicht breiter (sonst wird links
 * das Copyright gequetscht); sie bricht innerhalb von Titel + Anfragen um. */
.foto-notiz { flex-basis: 100%; contain: inline-size; margin: 0.1rem 0 0; font-size: 0.8rem; line-height: 1.45; color: inherit; opacity: 0.68; text-align: center; text-wrap: balance; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.foto-notiz[hidden] { display: none; }

/* --- Kopf- und Fusszeile: drei Zonen, gleiche Hoehe -----------------------
 * Links / Mitte / Rechts. Linien entfallen ersatzlos. */
.leiste {
    /* Gemeinsame Hoehe von Kopf und Fuss, so dass das Band zwischen
     * blauer Linie und Fotokarte OBEN/UNTEN genauso breit ist wie
     * LINKS/RECHTS:
     *   links/rechts: Karte 96px vom Rand, Linie innen bei 11px  -> 85px
     *   oben/unten:   12px Luft + H + 12px Luft = 85px           -> H = 61px
     * (Die Karte wird per JS 12px von der Leiste weggesetzt.)
     * Kein vertikaler Padding mehr in den Einzelzeilen – das Raster
     * zentriert den Inhalt. */
    min-height: 61px;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}
.header-zeile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    width: 100%;
    max-width: calc(100% - 2 * (4.5rem + 24px));
    margin: 0 auto;
    /* Kein vertikaler Padding: .leiste gibt die Hoehe vor, das Raster
     * zentriert den Titel. */
    padding: 0 2.5rem;
    box-sizing: border-box;
}
.kopf-seite {
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
    /* Gleich wie #copyright unten links (0.82rem / 1.5px), damit
     * Kopf-Seitenlinks und Fuss-Text optisch dieselbe Groesse haben. */
    font-size: 0.82rem;
    font-weight: 400;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.3s ease;
}
.kopf-seite:hover { color: #ffffff; transform: translateY(-3px); text-shadow: 0 0 10px rgba(255, 255, 255, 0.5); }
.header-zeile .header-link:hover { color: #ffffff; text-shadow: 0 0 12px rgba(255, 255, 255, 0.9), 0 0 30px rgba(255, 255, 255, 0.45); }
.header-zeile .header-content {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0;
}
.header-zeile .kopf-seite:first-child { justify-self: start; }
.header-zeile .kopf-seite:last-child { justify-self: end; text-align: right; }
.fuss-zeile {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    width: 100%;
    max-width: calc(100% - 2 * (4.5rem + 24px));
    margin: 0 auto;
    /* Wie die Kopfzeile: keine vertikale Polsterung, Raster zentriert. */
    padding: 0 2.5rem;
    box-sizing: border-box;
}
.fuss-zeile #copyright { justify-self: start; }
.fuss-zeile #description { margin-bottom: 0; padding: 0; text-align: center; }
.fuss-rechts {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.zufall-knopf {
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.75);
    font: inherit;
    /* Gleich wie #copyright und .kopf-seite (0.82rem / 1.5px). */
    font-size: 0.82rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 0.45rem 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
}
.zufall-knopf:hover { color: #ffffff; border-color: rgba(255, 255, 255, 0.8); text-shadow: 0 0 10px rgba(255, 255, 255, 0.5); }
/* Diashow-Knopf: rund, Icon mittig, gleiches Hover-Verhalten. */
.dia-knopf {
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.75);
    width: 2.1rem;
    height: 2.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}
.dia-knopf:hover { color: #ffffff; border-color: rgba(255, 255, 255, 0.8); }
.dia-knopf .icon { width: 1rem; height: 1rem; }
/* Tempo-Pillen: nur im Play-Modus sichtbar, aktive weiss mit Schwarz.
 * min-width setzt JS = Breite des Zufall-Knopfs, damit beim Start/Stop
 * der Diashow nichts in der Fusszeile springt. */
.dia-tempo { display: inline-flex; gap: 0.35rem; justify-content: center; }
.dia-tempo[hidden] { display: none; }
.dia-tempo button {
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.75);
    font: inherit;
    font-size: 0.72rem;
    letter-spacing: 1px;
    padding: 0.4rem 0.7rem;
    cursor: pointer;
    transition: all 0.3s ease;
}
.dia-tempo button:hover { color: #ffffff; border-color: rgba(255, 255, 255, 0.8); }
.dia-tempo button.ist-an { background: #ffffff; border-color: #ffffff; color: #000000; }

/* --- Fotorahmen: Apple-Karte mit runden Ecken zwischen den Leisten ------ */
#fotoRahmen {
    position: fixed;
    left: calc(4.5rem + 24px);
    right: calc(4.5rem + 24px);
    border-radius: 24px;
    overflow: hidden;
    z-index: 0;
    /* Milchig wie die Leisten statt Schwarz + feine Kante als Karte. */
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    border: 1px solid #5b7cff;
}
#fotoBild {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
@media (hover: none) {
    /* Mobil: Zonen sind 3rem schmal. */
    #fotoRahmen { left: calc(3rem + 8px); right: calc(3rem + 8px); border-radius: 18px; }
}

/* --- Akzent-Linien oben und unten (wie tomstown.ch) ----------------- */
:root { --accent: #5b7cff; }

.safari-fix,
.safari-fix-bottom {
    position: fixed;
    left: 0;
    width: 100%;
    height: 1px;
    min-height: 1px;
    background: var(--accent);
    z-index: 10003;
    pointer-events: none;
    transform: translateZ(0);
    backface-visibility: hidden;
}
/* Schwebender Rahmen: eingerueckt mit runden Ecken statt Kantenlinien.
 * Radius 24px = derselbe Wert wie der Fotorahmen (#fotoRahmen) innen. */
.rahmen {
    position: fixed;
    inset: calc(10px + var(--fam)) 10px 10px;
    border: 1px solid var(--accent);
    border-radius: 24px;
    z-index: 10003;
    pointer-events: none;
    transform: translateZ(0);
}

/* --- BRAWone-Logo neben dem Copyright (Fusszeile links) ---------------------
 * Gleiches Grau wie das Copyright; beim Darueberfahren weiss, die Punkte
 * leuchten im Blau von tombrawand.ch (#5b7cff, frueher #5b7cff).
 * Logo-Grundlage: brawone-mark/brawone-mark.css */
#copyright { display: flex; align-items: center; flex-wrap: wrap; gap: 0 .55em; }
#copyright .bwm-sep { color: rgba(255, 255, 255, 0.25); }
#copyright .bw-mark {
    --bwm-ink: rgba(255, 255, 255, 0.4);
    --bwm-ink-hover: #ffffff;
    --bwm-dot-rest: rgba(255, 255, 255, 0.28);
    --bwm-accent: #5b7cff;
    --bwm-bg: #050505;
    font-size: 1.05em;
}
#copyright .bw-mark:hover { filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.35)); }
/* Firefox-Block oben setzt fuer alle Elemente Sansation/300 mit !important:
 * das Logo braucht seine eigene Schrift und Gewichte. */
#copyright .bw-mark, #copyright .bw-mark * { font-family: "BW Inter", "Inter", system-ui, sans-serif !important; }
#copyright .bw-mark .bw-braw { font-weight: 800 !important; }
#copyright .bw-mark .bw-ne { font-weight: 500 !important; }
/* Toms Town neben BRAWONE: gleich grau, beim Darueberfahren hell, der Mond im Blau der Seite */
#copyright .tt-mark, .recht-fuss .tt-mark {
    --ttm-ink: rgba(255, 255, 255, 0.4);
    --ttm-ink-hover: #ffffff;
    --ttm-mond-rest: rgba(255, 255, 255, 0.28);
    --ttm-accent: #c873ec;
    --ttm-bg: #050505;
    font-size: .98em;
    text-decoration: none;
}
.recht-fuss .tt-mark { --ttm-ink: rgba(255, 255, 255, 0.55); }
#copyright .tt-mark:hover { filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.35)); }
#copyright .tt-mark, #copyright .tt-mark *, .recht-fuss .tt-mark, .recht-fuss .tt-mark * { font-family: "TT MuseoModerno", system-ui, sans-serif !important; font-weight: 700 !important; }
#copyright .mark-sep, .recht-fuss .mark-sep { color: rgba(255, 255, 255, 0.25); }
#copyright .bw-mark, #copyright .tt-mark { font-size: 1.1em; }
html.licht-an #copyright .tt-mark, html.licht-an .recht-fuss .tt-mark { --ttm-ink: rgba(31, 29, 26, 0.7); --ttm-ink-hover: #1f1d1a; --ttm-mond-rest: rgba(31, 29, 26, 0.28); --ttm-bg: #efece6; }
html.licht-an #copyright .mark-sep, html.licht-an .recht-fuss .mark-sep { color: rgba(31, 29, 26, 0.55); }
/* Die eigene Marke FOTOTOM: Sansation, Linse im «o», Signaturblau. */
#copyright .ft-mark, .recht-fuss .ft-mark {
    --ftm-ink: rgba(255, 255, 255, 0.4);
    --ftm-ink-hover: #ffffff;
    --ftm-bg: #050505;
    font-size: 1.1em;
    text-decoration: none;
}
.recht-fuss .ft-mark { --ftm-ink: rgba(255, 255, 255, 0.55); font-size: 1.05em; }
#copyright .ft-mark:hover { filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.35)); }
#copyright .ft-mark, #copyright .ft-mark *, .recht-fuss .ft-mark, .recht-fuss .ft-mark * { font-family: 'Sansation', 'UbuntuSans', sans-serif !important; }
html.licht-an #copyright .ft-mark, html.licht-an .recht-fuss .ft-mark { --ftm-ink: rgba(31, 29, 26, 0.62); --ftm-ink-hover: #1f1d1a; --ftm-bg: #efece6; }
@media (max-width: 768px) {
    #copyright { justify-content: center; gap: .35em .55em; }
    #copyright .bwm-sep { display: none; }
}

/* Kopfzeile ohne Seitenlinks: Titel bleibt in der mittleren Spalte. */
@media (min-width: 769px) {
    .header-zeile .header-content { grid-column: 2; }
}

/* =====================================================================
 * Ergaenzungen Oktober 2026: Uebersicht, Filter, Impressum, Anfrage,
 * Wisch-Hinweis. Farben wie bisher: Grau 0.4/0.55, Akzent #5b7cff.
 * ===================================================================== */

/* Kopfzeile: «Alle Bilder» links, «Impressum» rechts. Knoepfe sehen aus
 * wie die frueheren Kopf-Links, heben sich aber beim Hover nicht an. */
.kopf-knopf {
    background: none;
    border: 0;
    padding: 0.4rem 0;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5em;
}
.kopf-knopf:hover { transform: none; }
.kopf-knopf .icon { width: 0.95em; height: 0.95em; vertical-align: 0; }
@media (min-width: 769px) {
    .header-zeile #alleKnopf { grid-column: 1; grid-row: 1; justify-self: start; }
    .header-zeile #rechtKnopf { grid-column: 3; grid-row: 1; justify-self: end; }
}
@media (max-width: 768px) {
    /* Handy: Titel oben ueber die volle Breite, darunter die zwei Knoepfe. */
    #main-header .header-zeile {
        grid-template-columns: 1fr 1fr;
        column-gap: 1.6rem;
        row-gap: 0.1rem;
    }
    .header-zeile .header-content { grid-column: 1 / -1; grid-row: 1; }
    .header-zeile #alleKnopf { grid-column: 1; grid-row: 2; justify-self: end; }
    .header-zeile #rechtKnopf { grid-column: 2; grid-row: 2; justify-self: start; }
    .kopf-knopf { font-size: 0.72rem; padding: 0.2rem 0; }
}

/* Fussmitte: Bildtext + «Anfrage» auf einer Linie. */
.fuss-mitte {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.2rem 0.9rem;
    min-width: 0;
}
.anfrage-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    font-size: 0.72rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    white-space: nowrap;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}
.anfrage-link:hover { color: #ffffff; text-shadow: 0 0 10px rgba(255, 255, 255, 0.5); }
.anfrage-link:hover .icon { color: var(--accent); }
@media (max-width: 768px) {
    .fuss-mitte { gap: 0.1rem 0.7rem; }
    .fuss-zeile .fuss-mitte #description { padding: 0; margin: 0; }
}

/* --- Dialoge (Uebersicht, Impressum) ------------------------------------
 * Liegen in der Top-Layer-Ebene ueber allem. Gleicher Rahmen wie die
 * Seite: 10px Abstand, Radius 24px, blaue Linie, milchig dunkel. */
dialog.ebene {
    position: fixed;
    inset: 10px;
    width: auto;
    height: auto;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--accent);
    border-radius: 24px;
    background: rgba(5, 5, 5, 0.88);
    -webkit-backdrop-filter: blur(22px);
    backdrop-filter: blur(22px);
    color: #fff;
    overflow: auto;
    overscroll-behavior: contain;
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
}
dialog.ebene[open] { display: flex; flex-direction: column; }
dialog.ebene::backdrop { background: rgba(0, 0, 0, 0.45); }
.ebene-kopf {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 1rem 1.4rem;
    background: rgba(5, 5, 5, 0.82);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.ebene-kopf h2, .ebene-marke {
    margin: 0;
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 4px;
    text-transform: uppercase;
}
.ebene-marke { color: rgba(255, 255, 255, 0.55); }
.ebene-zu {
    margin-left: auto;
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.8);
    width: 2.3rem;
    height: 2.3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}
.ebene-zu:hover { color: #fff; border-color: rgba(255, 255, 255, 0.85); }
.ebene-zu .icon { width: 1.1rem; height: 1.1rem; }

/* Filter-Pillen wie die Tempo-Pillen der Diashow. */
.filter { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.filter button {
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.75);
    font: inherit;
    font-size: 0.75rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 0.42rem 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}
.filter button:hover { color: #fff; border-color: rgba(255, 255, 255, 0.8); }
.filter button[aria-pressed="true"] { background: #fff; border-color: #fff; color: #000; }
.filter .anz { opacity: 0.55; margin-left: 0.2em; }

/* Raster der Vorschaubilder. */
.raster {
    list-style: none;
    margin: 0;
    padding: 1.2rem 1.4rem 1.6rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 1rem;
}
.kachel {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.kachel-bild {
    display: block;
    aspect-ratio: 3 / 2;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05) center / cover no-repeat;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
    filter: saturate(0.92);
    -webkit-touch-callout: none;
}
.kachel-text {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.78rem;
    letter-spacing: 0.5px;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.55);
    transition: color 0.25s ease;
}
.kachel:hover .kachel-bild,
.kachel:focus-visible .kachel-bild { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); filter: none; }
.kachel:hover .kachel-text { color: #fff; }
.kachel.ist-akt .kachel-bild { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); filter: none; }
.kachel.ist-akt .kachel-text { color: #fff; }
.kachel:focus-visible { outline: none; }
@media (max-width: 600px) {
    .raster { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.8rem; padding: 1rem; }
    .kachel-text { font-size: 0.7rem; }
    .ebene-kopf { padding: 0.8rem 1rem; }
    .ebene-kopf .filter { order: 3; width: 100%; gap: 0.3rem; flex-wrap: nowrap; }
    .filter button { font-size: 0.66rem; letter-spacing: 1px; padding: 0.4rem 0.6rem; }
}

/* Impressum: ruhiger Lesetext. */
.recht {
    max-width: 44rem;
    margin: 0 auto;
    padding: 1.6rem 1.6rem 2.4rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.82);
}
.recht h2 {
    font-family: 'Sansation', 'UbuntuSans', sans-serif;
    font-size: 1.05rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: #fff;
    margin: 1.8rem 0 0.6rem;
}
.recht section:first-child h2 { margin-top: 0.4rem; }
.recht h3 { font-size: 0.95rem; color: #fff; margin: 1.3rem 0 0.3rem; }
.recht p, .recht ul { margin: 0 0 0.8rem; }
.recht address { font-style: normal; }
.recht a { color: #fff; text-decoration-color: var(--accent); text-underline-offset: 3px; }
.recht a:hover { color: var(--accent); }

/* Wisch-Hinweis (nur Touch, einmalig). */
.wisch-hinweis {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 1600;
    padding: 0.6rem 1.1rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 0.75rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.85);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
    white-space: nowrap;
}
.wisch-hinweis.ist-an { opacity: 1; }
.wisch-hinweis::before { content: '← '; }
.wisch-hinweis::after { content: ' →'; }

/* Firefox-Block oben erzwingt Sansation fuer alles: Dialog-Titel behalten
 * die fette Kopfschrift wie die Kopfzeile. */
@supports (-moz-appearance: none) {
    .ebene-kopf h2, .ebene-marke, .recht h2, .recht h3 { font-weight: 700 !important; }
}

/* Akzentfarbe (helles Blau) fuer Hover der neuen Knoepfe/Links und den
 * aktiven Filter. */
.kopf-knopf:hover, .kopf-knopf:focus-visible { color: var(--accent); text-shadow: 0 0 10px rgba(91, 124, 255, 0.55); }
.anfrage-link:hover, .anfrage-link:focus-visible { color: var(--accent); text-shadow: 0 0 10px rgba(91, 124, 255, 0.55); }
.filter button:hover { color: var(--accent); border-color: var(--accent); }
.filter button[aria-pressed="true"],
.filter button[aria-pressed="true"]:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.filter button[aria-pressed="true"] .anz { opacity: 0.8; }
.ebene-zu:hover { color: var(--accent); border-color: var(--accent); }

/* --- Kopfzeile rechts: Kontakt + Impressum --------------------------- */
.kopf-rechts { display: flex; align-items: center; gap: 1.4rem; justify-self: end; }
@media (min-width: 769px) {
    .header-zeile .kopf-rechts { grid-column: 3; grid-row: 1; }
}
@media (max-width: 768px) {
    .header-zeile .kopf-rechts { grid-column: 2; grid-row: 2; justify-self: start; gap: 1.6rem; }
}
button.anfrage-link { background: none; border: 0; padding: 0.2rem 0; font-family: inherit; cursor: pointer; }

/* --- Kontaktformular (Dialog) ----------------------------------------- */
.kontakt-inhalt { max-width: 40rem; }
.k-intro { color: rgba(255, 255, 255, 0.7); margin-bottom: 1.2rem; }
.k-bild {
    display: flex; align-items: center; gap: 0.9rem;
    padding: 0.6rem; margin: 0 0 1.2rem;
    border: 1px solid rgba(91, 124, 255, 0.55); border-radius: 14px;
    background: rgba(91, 124, 255, 0.08);
}
.k-bild[hidden] { display: none; }
.k-bild-vorschau {
    flex: 0 0 auto; width: 84px; aspect-ratio: 3 / 2; border-radius: 9px;
    background: rgba(255, 255, 255, 0.06) center / cover no-repeat;
}
.k-bild-text { display: flex; flex-direction: column; min-width: 0; font-size: 0.9rem; color: #fff; }
.k-bild-l { font-size: 0.68rem; letter-spacing: 1.5px; text-transform: uppercase; color: var(--accent); }
.k-bild-weg {
    margin-left: auto; flex: 0 0 auto; width: 2rem; height: 2rem; border-radius: 999px;
    background: none; border: 1px solid rgba(255, 255, 255, 0.3); color: rgba(255, 255, 255, 0.75);
    font-size: 1.1rem; line-height: 1; cursor: pointer; transition: all 0.3s ease;
}
.k-bild-weg:hover { color: var(--accent); border-color: var(--accent); }
.k-form { display: grid; grid-template-columns: 1fr 1fr; gap: 0.9rem 1rem; }
.k-voll { grid-column: 1 / -1; }
.k-feld { display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; }
.k-feld label .k-frei { text-transform: none; letter-spacing: 0; opacity: .7; margin-left: .4em; }
.k-feld label { font-size: 0.7rem; letter-spacing: 1.5px; text-transform: uppercase; color: rgba(255, 255, 255, 0.55); }
.k-feld input, .k-feld select, .k-feld textarea {
    font: inherit; font-size: 0.95rem; color: #fff;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 10px;
    padding: 0.65rem 0.8rem; width: 100%; box-sizing: border-box;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.k-feld select { appearance: none; -webkit-appearance: none; padding-right: 2rem;
    background-image: linear-gradient(45deg, transparent 50%, rgba(255,255,255,.6) 50%), linear-gradient(135deg, rgba(255,255,255,.6) 50%, transparent 50%);
    background-position: calc(100% - 16px) 55%, calc(100% - 11px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
.k-feld select option { background: #111; color: #fff; }
.k-feld textarea { resize: vertical; min-height: 8rem; }
.k-feld input:focus, .k-feld select:focus, .k-feld textarea:focus {
    outline: none; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent);
}
.k-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.k-ts:empty { display: none; }
.k-ts { min-height: 65px; }
.k-ende { display: flex; align-items: center; flex-wrap: wrap; gap: 0.6rem 1rem; }
.k-senden {
    font: inherit; font-size: 0.82rem; letter-spacing: 1.5px; text-transform: uppercase;
    color: #fff; background: var(--accent); border: 1px solid var(--accent); border-radius: 999px;
    padding: 0.6rem 1.3rem; cursor: pointer; transition: all 0.3s ease;
}
.k-senden:hover { background: #fff; border-color: #fff; color: #000; }
.k-senden:disabled { opacity: 0.55; cursor: wait; }
.k-note { margin: 0; font-size: 0.88rem; color: rgba(255, 255, 255, 0.75); }
.k-note.gut { color: #8fd19e; }
.k-note.fehler { color: #ff9b9b; }
.k-klein { margin-top: 1.2rem; font-size: 0.78rem; color: rgba(255, 255, 255, 0.45); }
@media (max-width: 600px) {
    .k-form { grid-template-columns: 1fr; }
}

/* Kontaktfoto unten im Kontakt-Dialog: Comic im tombrawand-Blau,
 * gleiche Karte wie das Foto (runde Ecken, blaue Linie). */
.k-foto { margin: 1.8rem auto 0; max-width: 300px; }
.k-foto img {
    display: block; width: 100%; height: auto;
    border-radius: 18px; border: 1px solid var(--accent);
    box-shadow: 0 0 0 4px rgba(91, 124, 255, 0.12), 0 14px 40px rgba(0, 0, 0, 0.5);
    -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none;
}
@media (max-width: 600px) { .k-foto { max-width: 240px; } }

/* Kontakt: Formular links (schmaler), Foto rechts. Handy: Foto darunter. */
.kontakt-inhalt { max-width: 52rem; }
.k-layout { display: grid; grid-template-columns: minmax(0, 27rem) 260px; gap: 2.4rem; align-items: start; justify-content: center; }
.k-layout .k-foto { margin: 1.4rem 0 0; max-width: none; }
.k-feld textarea { min-height: 6rem; }
.recht .k-klein { margin-top: 1.8rem; }
.recht .k-note:empty { display: none; }
.k-ende { margin-top: 0.3rem; }
@media (max-width: 860px) {
    .k-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
    .k-layout .k-foto { margin: 1.8rem auto 0; max-width: 260px; }
}
@media (max-width: 600px) { .k-layout .k-foto { max-width: 220px; } }

/* Dialog-Kopf: Punkt in «tombrawand.ch» als Logo (wie Favicon). */
.ebene-marke { display: inline-flex; align-items: center; }
.marke-punkt { width: 0.95em; height: 0.95em; margin: 0 0.3em 0 0.02em; flex: 0 0 auto; }

/* Kopfzeile: Logo-Punkt statt «•» zwischen Tom Brawand und Fotografie. */
.header-link { display: inline-flex; align-items: center; }
.kopf-punkt { width: 0.9em; height: 0.9em; margin: 0 0.42em 0 0.19em; flex: 0 0 auto; transition: filter 0.3s ease; }
.header-link:hover .kopf-punkt { filter: drop-shadow(0 0 6px rgba(91, 124, 255, 0.8)); }
/* Uebersicht: Marke links, Titel daneben etwas leiser. */
.ebene-kopf .ebene-titel { color: #fff; padding-left: 0.9rem; border-left: 1px solid rgba(255, 255, 255, 0.18); }
@media (max-width: 600px) {
    .ebene-kopf .ebene-titel { display: none; }
}

/* Hover auf «Tom Brawand ◉ Fotografie»: Logo wie ein Kameraverschluss –
 * der weisse Punkt schliesst sich kurz (Blende), der Ring zieht nach und
 * leuchtet. viewBox ist 2px groesser, damit der Ring beim Wachsen nicht
 * abgeschnitten wird; Groesse dafuer leicht angepasst. */
.kopf-punkt { width: 1.01em; height: 1.01em; overflow: visible; }
.kopf-punkt .kp-punkt, .kopf-punkt .kp-ring { transform-box: fill-box; transform-origin: center; }
.header-link:hover .kp-punkt, .header-link:focus-visible .kp-punkt { animation: kp-blende 0.9s cubic-bezier(.5, 0, .3, 1) both; }
.header-link:hover .kp-ring, .header-link:focus-visible .kp-ring { animation: kp-ring 0.9s cubic-bezier(.5, 0, .3, 1) both; }
@keyframes kp-blende {
    0%   { transform: scale(1); }
    22%  { transform: scale(0.2); }
    40%  { transform: scale(0.2); }
    70%  { transform: scale(1.12); }
    100% { transform: scale(1); }
}
@keyframes kp-ring {
    0%   { transform: scale(1);    stroke-width: 6; }
    22%  { transform: scale(0.86); stroke-width: 8; }
    40%  { transform: scale(0.86); stroke-width: 8; }
    70%  { transform: scale(1.1);  stroke-width: 5; }
    100% { transform: scale(1);    stroke-width: 6; }
}
@media (prefers-reduced-motion: reduce) {
    .header-link:hover .kp-punkt, .header-link:hover .kp-ring,
    .header-link:focus-visible .kp-punkt, .header-link:focus-visible .kp-ring { animation: none; }
}

/* Trennpunkt zwischen Kontakt und Impressum. */
.kopf-rechts { gap: 0.8rem; }
.kopf-trenner { color: rgba(255, 255, 255, 0.3); font-size: 0.82rem; line-height: 1; }
@media (max-width: 768px) { .header-zeile .kopf-rechts { gap: 0.8rem; } .kopf-trenner { font-size: 0.72rem; } }

/* =====================================================================
 * Handy: schlanke Fusszeile + Vollbild per Tippen (Oktober 2026)
 * ===================================================================== */

/* Copyright und BRAWone stehen am Handy im Impressum statt im Fuss. */
.recht-fuss {
    margin-top: 2.2rem;
    padding-top: 1.1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.6rem;
    font-size: 0.78rem; letter-spacing: 1.5px; text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
}
.recht-fuss .bwm-sep { color: rgba(255, 255, 255, 0.25); }
.recht-fuss-label { text-transform: none; letter-spacing: 0.5px; }
.recht-fuss .bw-mark {
    --bwm-ink: rgba(255, 255, 255, 0.55);
    --bwm-ink-hover: #ffffff;
    --bwm-dot-rest: rgba(255, 255, 255, 0.28);
    --bwm-accent: #5b7cff;
    --bwm-bg: #050505;
    font-size: 1.05em;
    text-decoration: none;
}
.recht-fuss .bw-mark, .recht-fuss .bw-mark * { font-family: "BW Inter", "Inter", system-ui, sans-serif !important; }
.recht-fuss .bw-mark .bw-braw { font-weight: 800 !important; }
.recht-fuss .bw-mark .bw-ne { font-weight: 500 !important; }

@media (max-width: 768px) {
    /* Fuss: nur noch, was zum Bild gehoert – Bildtext + Anfrage, darunter
     * Diashow, Zaehler, Zufall. */
    #main-footer #copyright { display: none; }
    #main-footer .fuss-zeile { gap: 0.35rem; padding-top: 0.55rem; padding-bottom: 0.55rem; }
    .fuss-mitte { flex-wrap: nowrap; gap: 0.55rem; max-width: 100%; align-items: center; }
    /* Bildtext darf zweizeilig werden, «Anfrage» ist nur noch der Brief. */
    .fuss-mitte #description {
        min-width: 0; text-align: center; line-height: 1.3;
        display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    }
    .fuss-mitte .anfrage-link { flex: 0 0 auto; height: 2rem; padding: 0 0.7rem; justify-content: center; border: 1px solid rgba(255, 255, 255, 0.3); border-radius: 999px; }
    .fuss-mitte .anfrage-link span { font-size: 0.62rem; letter-spacing: 1px; }
    .fuss-mitte { flex-wrap: wrap; }
    .fuss-mitte #description { flex: 1 1 0; }
    .fuss-mitte .foto-notiz { font-size: 0.74rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .fuss-mitte .foto-notiz[hidden] { display: none; }
    .fuss-mitte .anfrage-link .icon { width: 0.95rem; height: 0.95rem; }
}

/* Vollbild: Kopf, Fuss und Seitenzonen gleiten weg, das Foto waechst. */
#main-header, #main-footer, .seite, #fotoRahmen {
    transition-property: transform, opacity, top, bottom, left, right;
    transition-duration: 0.35s;
    transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}
body.ist-vollbild #main-header { transform: translateY(calc(-100% - 30px)); opacity: 0; pointer-events: none; }
body.ist-vollbild #main-footer { transform: translateY(calc(100% + 30px)); opacity: 0; pointer-events: none; }
body.ist-vollbild .seite { opacity: 0; pointer-events: none; }
body.ist-vollbild #fotoRahmen { left: 22px; right: 22px; }
body.ist-vollbild #fotoBild { background-size: contain; }
.voll-hinweis {
    position: fixed; left: 50%; bottom: 40px; transform: translateX(-50%);
    z-index: 1600; padding: 0.55rem 1rem; border-radius: 999px;
    background: rgba(0, 0, 0, 0.6); border: 1px solid rgba(255, 255, 255, 0.3);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    font-size: 0.72rem; letter-spacing: 1.5px; text-transform: uppercase; white-space: nowrap;
    color: rgba(255, 255, 255, 0.85); pointer-events: none;
    opacity: 0; transition: opacity 0.4s ease;
}
.voll-hinweis.ist-an { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
    #main-header, #main-footer, .seite, #fotoRahmen { transition-duration: 0.01s; }
}

/* =====================================================================
 * Lichtschalter: «Licht aus» = dunkel (Standard), «Licht an» = hell.
 * Die Wahl merkt sich der Browser (localStorage).
 * ===================================================================== */
.kopf-links { display: flex; align-items: center; gap: 0.8rem; justify-self: start; min-width: 0; }
@media (min-width: 769px) {
    .header-zeile .kopf-links { grid-column: 1; grid-row: 1; }
}
@media (max-width: 768px) {
    .header-zeile .kopf-links { grid-column: 1; grid-row: 2; justify-self: end; gap: 0.8rem; }
    /* Am Handy ist die Zeile knapp: nur die Gluehbirne, ohne Text. */
    .licht-knopf .licht-text { display: none; }
    /* Etwas weniger Rand, damit Alle Bilder, Licht, Kontakt und Impressum
     * auch auf schmalen Handys in eine Zeile passen. */
    #main-header .header-zeile { padding-left: 1rem; padding-right: 1rem; column-gap: 1.1rem; grid-template-columns: auto auto; justify-content: center; }
    .licht-knopf .licht-icon { width: 1.25em; height: 1.25em; }
}
/* Icon zeigt wie die Beschriftung, was ein Klick bewirkt:
 * dunkel = leuchtende Birne (anmachen), hell = Birne aus (ausmachen). */
.licht-icon .strahlen { opacity: 1; transition: opacity .3s ease; }
.licht-icon .birne { fill: currentColor; fill-opacity: .25; transition: fill-opacity .3s ease; }
.licht-an .licht-icon .strahlen { opacity: 0; }
.licht-an .licht-icon .birne { fill-opacity: 0; }

/* Sehr schmale Handys: «Alle Bilder» nur als Symbol. */
@media (max-width: 369px) {
    #alleKnopf .alle-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    #alleKnopf .icon { width: 1.15em; height: 1.15em; }
}

/* Licht an: eigenes helles Farbschema (warmes Papierweiss, fast schwarze
 * Schrift). Automatisch aus den dunklen Farben abgeleitet: Schwarz wird
 * Papier, Weiss wird Tinte, Grautoene dazwischen, graue Schrift etwas
 * kraeftiger. Akzentblau und Fotos bleiben unveraendert. Kein Filter -
 * sieht in allen Browsern gleich aus. */
html.licht-an { color-scheme: light; }
html.licht-an { background-color: #efece6; }
html.licht-an body { background: transparent; color: #1f1d1a; }
html.licht-an body::before { background: #efece6; }
html.licht-an #main-header { background: rgba(243, 240, 234, 0.6); }
html.licht-an .header-link { color: inherit; }
html.licht-an .header-line { background: rgba(31, 29, 26, 0.4); }
html.licht-an #main-footer { background: rgba(243, 240, 234, 0.6); }
html.licht-an .serie-nr { color: rgba(31, 29, 26, 0.7); }
html.licht-an .reload-link { color: rgba(31, 29, 26, 0.7); }
html.licht-an .reload-link:hover { color: #1f1d1a; }
html.licht-an .footer-line { background: rgba(31, 29, 26, 0.15); }
html.licht-an #copyright { color: rgba(31, 29, 26, 0.7); }
html.licht-an .copyright-link { color: inherit; }
html.licht-an .copyright-link:hover { color: #1f1d1a; text-shadow: none; }
html.licht-an .url-button { color: rgba(31, 29, 26, 0.7); }
html.licht-an .url-button .icon { color: rgba(31, 29, 26, 0.7); }
html.licht-an .url-button:hover { color: #1f1d1a; text-shadow: none; }
html.licht-an a:focus-visible, html.licht-an button:focus-visible, html.licht-an #mobile-next:focus-visible { outline: 2px solid rgba(31, 29, 26, 0.9); }
html.licht-an .cursor-label { color: rgba(31, 29, 26, 1); background: rgba(243, 240, 234, 0.2); }
html.licht-an #camera-cursor i { color: rgba(31, 29, 26, 0.8); }
html.licht-an .flash-active-icon i { color: #1f1d1a !important; text-shadow: none; }
html.licht-an body.is-loading::after { border: 2px solid rgba(31, 29, 26, 0.1); border-top-color: rgba(31, 29, 26, 0.6); }
/* Blitz bleibt auch bei Licht an weiss: Er liegt ueber dem Foto, nicht
 * ueber dem Papierhintergrund (dunkler Blitz waere mit «screen» unsichtbar). */
html.licht-an #screen-flash { background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
                rgba(255, 255, 255, 0.8) 0%,
                rgba(255, 255, 255, 0) 70%); }
@media (max-width: 480px) { html.licht-an .mobile-next { border: 1px solid rgba(31, 29, 26, 0.35); background: rgba(243, 240, 234, 0.55); color: #1f1d1a; } }
@media (max-width: 480px) { html.licht-an .mobile-next:active { background: rgba(31, 29, 26, 0.2); } }
html.licht-an .mobile-next { border: none; }
html.licht-an .seite { border: 0; background: rgba(243, 240, 234, 0.6); color: rgba(31, 29, 26, 0.7); }
html.licht-an .seite:hover { color: #1f1d1a; }
html.licht-an .seite:hover span { text-shadow: none; }
html.licht-an .seite.taste-hover { color: #1f1d1a; }
html.licht-an .seite.taste-hover span { text-shadow: none; }
html.licht-an .seite:focus-visible { outline: 2px solid #5b7cff; }
html.licht-an .kopf-seite { color: rgba(31, 29, 26, 0.85); }
html.licht-an .kopf-seite:hover { color: #1f1d1a; text-shadow: none; }
html.licht-an .header-zeile .header-link:hover { color: #1f1d1a; text-shadow: none; }
html.licht-an .zufall-knopf { background: none; border: 1px solid rgba(31, 29, 26, 0.35); color: rgba(31, 29, 26, 1); }
html.licht-an .zufall-knopf:hover { color: #1f1d1a; border-color: rgba(31, 29, 26, 0.8); text-shadow: none; }
html.licht-an .dia-knopf { background: none; border: 1px solid rgba(31, 29, 26, 0.35); color: rgba(31, 29, 26, 1); }
html.licht-an .dia-knopf:hover { color: #1f1d1a; border-color: rgba(31, 29, 26, 0.8); }
html.licht-an .dia-tempo button { background: none; border: 1px solid rgba(31, 29, 26, 0.35); color: rgba(31, 29, 26, 1); }
html.licht-an .dia-tempo button:hover { color: #1f1d1a; border-color: rgba(31, 29, 26, 0.8); }
html.licht-an .dia-tempo button.ist-an { background: #1f1d1a; border-color: #1f1d1a; color: #f3f0ea; }
html.licht-an #fotoRahmen { background: rgba(243, 240, 234, 0.6); border: 1px solid #5b7cff; }
html.licht-an .safari-fix, html.licht-an .safari-fix-bottom { background: var(--accent); }
html.licht-an .rahmen { border: 1px solid var(--accent); }
html.licht-an #copyright .bwm-sep { color: rgba(31, 29, 26, 0.55); }
html.licht-an #copyright .bw-mark { --bwm-ink: rgba(31, 29, 26, 0.7); --bwm-ink-hover: #1f1d1a; --bwm-dot-rest: rgba(31, 29, 26, 0.28); --bwm-bg: #efece6; }
html.licht-an .kopf-knopf { background: none; border: 0; }
html.licht-an .anfrage-link { color: rgba(31, 29, 26, 0.7); }
html.licht-an .anfrage-link:hover { color: #1f1d1a; text-shadow: none; }
html.licht-an .anfrage-link:hover .icon { color: var(--accent); }
html.licht-an dialog.ebene { border: 1px solid var(--accent); background: rgba(239, 236, 230, 0.88); color: #1f1d1a; }
html.licht-an dialog.ebene::backdrop { background: rgba(243, 240, 234, 0.45); }
html.licht-an .ebene-kopf { background: rgba(239, 236, 230, 0.82); border-bottom: 1px solid rgba(31, 29, 26, 0.08); }
html.licht-an .ebene-marke { color: rgba(31, 29, 26, 0.85); }
html.licht-an .ebene-zu { background: none; border: 1px solid rgba(31, 29, 26, 0.35); color: rgba(31, 29, 26, 1); }
html.licht-an .ebene-zu:hover { color: #1f1d1a; border-color: rgba(31, 29, 26, 0.85); }
html.licht-an .filter button { background: none; border: 1px solid rgba(31, 29, 26, 0.35); color: rgba(31, 29, 26, 1); }
html.licht-an .filter button:hover { color: #1f1d1a; border-color: rgba(31, 29, 26, 0.8); }
html.licht-an .filter button[aria-pressed="true"] { background: #1f1d1a; border-color: #1f1d1a; color: #f3f0ea; }
html.licht-an .kachel { border: 0; background: none; color: inherit; }
html.licht-an .kachel-bild { background: rgba(31, 29, 26, 0.05) center / cover no-repeat; border: 1px solid rgba(31, 29, 26, 0.1); }
html.licht-an .kachel-text { color: rgba(31, 29, 26, 0.85); }
html.licht-an .kachel:hover .kachel-bild, html.licht-an .kachel:focus-visible .kachel-bild { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
html.licht-an .kachel:hover .kachel-text { color: #1f1d1a; }
html.licht-an .kachel.ist-akt .kachel-bild { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
html.licht-an .kachel.ist-akt .kachel-text { color: #1f1d1a; }
html.licht-an .kachel:focus-visible { outline: none; }
html.licht-an .recht { color: rgba(31, 29, 26, 1); }
html.licht-an .recht h2 { color: #1f1d1a; }
html.licht-an .recht h3 { color: #1f1d1a; }
html.licht-an .recht a { color: #1f1d1a; text-decoration-color: var(--accent); }
html.licht-an .recht a:hover { color: var(--accent); }
html.licht-an .wisch-hinweis { background: rgba(243, 240, 234, 0.6); border: 1px solid rgba(31, 29, 26, 0.3); color: rgba(31, 29, 26, 1); }
html.licht-an .kopf-knopf:hover, html.licht-an .kopf-knopf:focus-visible { color: var(--accent); text-shadow: 0 0 10px rgba(91, 124, 255, 0.55); }
html.licht-an .anfrage-link:hover, html.licht-an .anfrage-link:focus-visible { color: var(--accent); text-shadow: 0 0 10px rgba(91, 124, 255, 0.55); }
html.licht-an .filter button:hover { color: var(--accent); border-color: var(--accent); }
html.licht-an .filter button[aria-pressed="true"], html.licht-an .filter button[aria-pressed="true"]:hover { background: var(--accent); border-color: var(--accent); color: #1f1d1a; }
html.licht-an .ebene-zu:hover { color: var(--accent); border-color: var(--accent); }
html.licht-an button.anfrage-link { background: none; border: 0; }
html.licht-an .k-intro { color: rgba(31, 29, 26, 1); }
html.licht-an .k-bild { border: 1px solid rgba(91, 124, 255, 0.55); background: rgba(91, 124, 255, 0.08); }
html.licht-an .k-bild-vorschau { background: rgba(31, 29, 26, 0.06) center / cover no-repeat; }
html.licht-an .k-bild-text { color: #1f1d1a; }
html.licht-an .k-bild-l { color: var(--accent); }
html.licht-an .k-bild-weg { background: none; border: 1px solid rgba(31, 29, 26, 0.3); color: rgba(31, 29, 26, 1); }
html.licht-an .k-bild-weg:hover { color: var(--accent); border-color: var(--accent); }
html.licht-an .k-feld label { color: rgba(31, 29, 26, 0.85); }
html.licht-an .k-feld input, html.licht-an .k-feld select, html.licht-an .k-feld textarea { color: #1f1d1a; background: rgba(31, 29, 26, 0.05); border: 1px solid rgba(31, 29, 26, 0.2); }
html.licht-an .k-feld select option { background: #e5e2dc; color: #1f1d1a; }
html.licht-an .k-feld input:focus, html.licht-an .k-feld select:focus, html.licht-an .k-feld textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
html.licht-an .k-senden { color: #1f1d1a; background: var(--accent); border: 1px solid var(--accent); }
html.licht-an .k-senden:hover { background: #1f1d1a; border-color: #1f1d1a; color: #f3f0ea; }
html.licht-an .k-note { color: rgba(31, 29, 26, 1); }
html.licht-an .k-note.gut { color: #8fd19e; }
html.licht-an .k-note.fehler { color: #ff9b9b; }
html.licht-an .k-klein { color: rgba(31, 29, 26, 0.75); }
html.licht-an .k-foto img { border: 1px solid var(--accent); box-shadow: none; }
html.licht-an .ebene-kopf .ebene-titel { color: #1f1d1a; border-left: 1px solid rgba(31, 29, 26, 0.18); }
html.licht-an .kopf-trenner { color: rgba(31, 29, 26, 0.6); }
html.licht-an .recht-fuss { border-top: 1px solid rgba(31, 29, 26, 0.12); color: rgba(31, 29, 26, 0.75); }
html.licht-an .recht-fuss .bwm-sep { color: rgba(31, 29, 26, 0.55); }
html.licht-an .recht-fuss .bw-mark { --bwm-ink: rgba(31, 29, 26, 0.85); --bwm-ink-hover: #1f1d1a; --bwm-dot-rest: rgba(31, 29, 26, 0.28); --bwm-bg: #efece6; }
@media (max-width: 768px) { html.licht-an .fuss-mitte .anfrage-link { border: 1px solid rgba(31, 29, 26, 0.3); } }
html.licht-an .voll-hinweis { background: rgba(243, 240, 234, 0.6); border: 1px solid rgba(31, 29, 26, 0.3); color: rgba(31, 29, 26, 1); }
html.licht-an .kp-punkt, html.licht-an .marke-punkt circle[fill="#fff"] { fill: #1f1d1a; }
html.licht-an dialog.ebene::backdrop { background: rgba(243, 240, 234, 0.55); }
html.licht-an body::before { background: #f3f0ea; }
/* Text auf Akzentblau bleibt weiss. */
html.licht-an .filter button[aria-pressed="true"], html.licht-an .filter button[aria-pressed="true"]:hover,
html.licht-an .k-senden, html.licht-an .k-form button[type="submit"] { color: #fff; }
/* Bei Licht an kein Leuchten: auch der blaue Schein beim Darueberfahren
 * wirkt auf hellem Grund wie ein unscharfer Schatten. */
html.licht-an body *, html.licht-an dialog * { text-shadow: none !important; }

/* Fensterkopf (Alle Bilder, Kontakt, Impressum): Schliessen links, Logo
 * in der Mitte. In der Uebersicht darunter Titel und Filter, ebenfalls
 * mittig. */
.ebene-kopf { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; row-gap: 0.8rem; }
.ebene-kopf .ebene-zu { grid-column: 1; grid-row: 1; justify-self: start; margin: 0; }
.ebene-kopf .ebene-marke { grid-column: 2; grid-row: 1; justify-self: center; }
.ebene-unter { grid-column: 1 / -1; grid-row: 2; display: flex; justify-content: center; align-items: center; gap: 1rem; flex-wrap: wrap; min-width: 0; }
.ebene-kopf .ebene-titel { border-left: 0; padding-left: 0; }
@media (max-width: 600px) {
    .ebene-unter .filter { flex-wrap: wrap; justify-content: center; }
}

/* Licht an: Bildtext in der Uebersicht ruhig grau, beim Darueberfahren
 * und beim aktuellen Bild klar schwarz. */
html.licht-an .kachel-text { color: rgba(31, 29, 26, 0.6); }
html.licht-an .kachel:hover .kachel-text,
html.licht-an .kachel:focus-visible .kachel-text,
html.licht-an .kachel.ist-akt .kachel-text { color: #000; }
html.licht-an .ebene-kopf .ebene-titel { border-left: 0; }

/* Schliessen-Knopf etwas weg von der runden Fensterecke. */
dialog.ebene .ebene-kopf { padding: 1.4rem 2.4rem; }
@media (max-width: 600px) { dialog.ebene .ebene-kopf { padding: 1.2rem 1.5rem; } }
/* Impressum-Schluss: © links, «ein Projekt von BRAWone» rechtsbuendig. */
.recht-fuss .bwm-sep { display: none; }
.recht-fuss .recht-fuss-label { margin-left: auto; }

/* Absicherung: Aeltere Fassungen kehrten die Seite per Filter um. Haelt ein
 * Browser davon noch etwas im Speicher, wuerde das Papierweiss wieder dunkel.
 * Bei Licht an darum alle Umkehr-Filter auf Seite, Teilen und Fenstern aus. */
html.licht-an,
html.licht-an body > :not(#glasHintergrund),
html.licht-an dialog[open],
html.licht-an dialog[open] > *,
html.licht-an #fotoBild,
html.licht-an .kachel-bild,
html.licht-an #kBildVorschau,
html.licht-an .k-foto img { filter: none !important; }

/* «ein Projekt von» in Grossbuchstaben wie das Copyright daneben. */
.recht-fuss .recht-fuss-label { text-transform: uppercase; letter-spacing: 1.5px; }

/* Laptop: Der Titel in der Mitte ist breit. Damit der Lichtschalter nicht
 * unter den Titel rutscht, zeigt er hier nur die Gluehbirne
 * (Tooltip und Screenreader-Text bleiben). */
@media (min-width: 1200px) and (max-width: 1399px) {
    .licht-knopf .licht-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    .licht-knopf .licht-icon { width: 1.15em; height: 1.15em; }
}
/* Tablet: zweizeilig wie am Handy, Titel oben, Knoepfe darunter. */
@media (min-width: 769px) and (max-width: 1199px) {
    #main-header .header-zeile { grid-template-columns: auto auto; justify-content: center; column-gap: 2.4rem; row-gap: 0.3rem; }
    .header-zeile .header-content { grid-column: 1 / -1; grid-row: 1; justify-self: center; }
    .header-zeile .kopf-links { grid-column: 1; grid-row: 2; justify-self: end; }
    .header-zeile .kopf-rechts { grid-column: 2; grid-row: 2; justify-self: start; }
    .kopf-knopf { font-size: 0.8rem; padding: 0.2rem 0; }
}
/* Schmale Handys: Knopfzeile etwas enger, damit nichts am Rand klebt. */
@media (max-width: 414px) {
    #main-header .header-zeile { column-gap: 0.7rem; }
    .header-zeile .kopf-links, .header-zeile .kopf-rechts { gap: 0.55rem; }
}

/* Kontakt: Betreff als Pills (echte Radios), 2 x 2 und gleich breit wie die Felder. */
.k-label { font-size: 0.7rem; letter-spacing: 1.5px; text-transform: uppercase; color: rgba(255, 255, 255, 0.55); }
.k-pills { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.k-pill { display: flex; position: relative; min-width: 0; }
.k-pill input { position: absolute; width: 1px; height: 1px; opacity: 0; margin: 0; pointer-events: none; }
.k-pill span {
    flex: 1; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer;
    font-size: 0.85rem; letter-spacing: 0.3px; text-transform: none; color: rgba(255, 255, 255, 0.7);
    padding: 0.6rem 0.6rem; border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 999px;
    background: rgba(255, 255, 255, 0.05); transition: color .2s ease, border-color .2s ease, background .2s ease;
}
.k-pill:hover span { color: #fff; border-color: var(--accent); }
.k-pill input:checked + span { background: var(--accent); border-color: var(--accent); color: #fff; }
.k-pill input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 3px; }
@media (max-width: 480px) { .k-pills { grid-template-columns: 1fr; } }
html.licht-an .k-label { color: rgba(31, 29, 26, 0.7); }
html.licht-an .k-pill span { color: rgba(31, 29, 26, 0.75); background: rgba(31, 29, 26, 0.05); border-color: rgba(31, 29, 26, 0.2); }
html.licht-an .k-pill:hover span { color: #1f1d1a; border-color: var(--accent); }
html.licht-an .k-pill input:checked + span { background: var(--accent); border-color: var(--accent); color: #fff; }

/* Kontaktfoto: oben buendig mit dem Formular (Zeile «Name»), unten etwa
 * auf Hoehe der Betreff-Pills, rechts buendig mit dem Inhalt. Rahmen sitzt
 * an der Karte, damit das Bild beim Hover darin zoomen kann. */
.k-layout { grid-template-columns: minmax(0, 27rem) 270px; }
.k-layout .k-foto {
    margin: 0; position: relative; overflow: hidden;
    border-radius: 18px; border: 1px solid var(--accent);
    box-shadow: 0 0 0 4px rgba(91, 124, 255, 0.12), 0 14px 40px rgba(0, 0, 0, 0.5);
    transition: box-shadow .3s ease, transform .3s ease;
}
.k-layout .k-foto img {
    border: 0; border-radius: 0; box-shadow: none;
    transition: transform .6s cubic-bezier(0.22, 1, 0.36, 1), filter .4s ease;
}
/* Blauer Punkt oben rechts wie ein Kamera-Signal */
.k-layout .k-foto::after {
    content: ""; position: absolute; top: 12px; right: 12px; width: 11px; height: 11px;
    border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.85);
    transform: scale(0); transition: transform .3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.k-layout .k-foto:hover { box-shadow: 0 0 0 6px rgba(91, 124, 255, 0.22), 0 18px 46px rgba(0, 0, 0, 0.55); transform: translateY(-3px); }
.k-layout .k-foto:hover img { transform: scale(1.05) rotate(-0.6deg); }
.k-layout .k-foto:hover::after { transform: scale(1); }
/* Handy/Tablet: eine Spalte – Formular in voller Breite, Foto darunter.
 * (Die Zwei-Spalten-Regel oben gilt sonst auch auf dem Handy und quetscht das Formular.) */
@media (max-width: 860px) {
    .k-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
    .k-layout .k-foto { margin: 1.8rem auto 0; max-width: 260px; }
}
@media (max-width: 600px) { .k-layout .k-foto { max-width: 220px; } }
@media (prefers-reduced-motion: reduce) {
    .k-layout .k-foto, .k-layout .k-foto img, .k-layout .k-foto::after { transition: none; }
    .k-layout .k-foto:hover, .k-layout .k-foto:hover img { transform: none; }
}
html.licht-an .k-layout .k-foto { box-shadow: 0 0 0 4px rgba(91, 124, 255, 0.12); }
html.licht-an .k-layout .k-foto:hover { box-shadow: 0 0 0 6px rgba(91, 124, 255, 0.22); }
html.licht-an .k-layout .k-foto img { border: 0; }

/* --- Familienleiste: Absprung zu den eigenen Seiten ------------------------
 * Desktop und Handy (dort seitlich wischbar). Sitzt im Glasrand ueber der blauen Linie; Linie,
 * Innenflaeche und Kopfleiste ruecken dafuer um --fam nach unten (die
 * Fotokarte folgt per JS der Kopfleiste). Im Vollbild faellt sie weg. */
:root { --fam: 27.8px; }
.familie {
    display: flex; justify-content: center; align-items: center;
    position: fixed; top: 0; left: 0; right: 0; height: calc(8px + var(--fam));
    z-index: 10004;
    font-size: 0.72rem; letter-spacing: .5px; text-transform: none;
}
.familie ul { list-style: none; margin: 0; padding: 0 30px; display: flex; justify-content: safe center; gap: 22px; max-width: 100%; overflow-x: auto; scrollbar-width: none; white-space: nowrap; }
.familie ul::-webkit-scrollbar { display: none; }
.familie-trenn { flex: none; width: 1px; align-self: stretch; margin: 1px 0; background: rgba(255, 255, 255, 0.35); }
.familie a {
    display: inline-flex; align-items: center; gap: 7px;
    color: rgba(255, 255, 255, 0.62); text-decoration: none;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.75); transition: color 0.2s;
}
.familie a:hover, .familie a:focus-visible { color: #ffffff; outline: none; }
.familie a[aria-current="page"] { color: #ffffff; }
/* Punkt vor der aktuellen Seite kommt aus der Familienleiste, hier nur das Leuchten */
.familie a[aria-current="page"]::before { box-shadow: 0 0 6px rgba(91, 124, 255, 0.8); }
body.ist-vollbild { --fam: 0px; }
body.ist-vollbild .familie { display: none; }
@media (prefers-reduced-motion: reduce) { .familie a { transition: none; } }
@media (max-width: 700px) {
    .familie { font-size: 0.64rem; letter-spacing: .4px; }
    .familie ul { justify-content: flex-start; gap: 18px; padding: 0 18px; }
}

.familie{--fb-bg:#111111;--fb-accent:#5b7cff;--fb-neu-bg:#a3b4ff}   /* «neu»-Pille: helleres Blau, damit die dunkle Schrift lesbar ist */

/* Familienleiste: Wort vor der zweiten Gruppe; leichter dunkler Verlauf,
   damit die Schrift auch auf sehr hellen Fotos lesbar bleibt. */
.familie-label { display: flex; align-items: center; flex: none; font-size: .9em; color: rgba(255,255,255,.5); text-shadow: 0 1px 4px rgba(0,0,0,.75); pointer-events: none; }
.familie { background: linear-gradient(to bottom, rgba(0,0,0,.42), rgba(0,0,0,.12) 70%, rgba(0,0,0,0)); }

/* Tooltip der Familienleiste im Stil der Seite (Farben ueber --ft-*) */
:root{--ft-bg:rgba(8,8,12,.94);--ft-fg:#fff;--ft-mute:rgba(255,255,255,.7);--ft-line:rgba(91,124,255,.55);--ft-akzent:#5b7cff;--ft-font:'Sansation','UbuntuSans',sans-serif;--ft-radius:13px;--ft-ls:.02em}

/* Farbfilter in der Uebersicht (js/script.js: FARBEN): gleiche Hoehe, Schrift
   und Abstaende wie die Kategorie-Knoepfe, mit feinem Trennstrich davor */
.farben { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; margin: 0; padding-left: 0.9rem;
  border-left: 1px solid rgba(255, 255, 255, 0.18); }
.farben[hidden] { display: none; }
.farben button { display: inline-flex; align-items: center; gap: 0.45rem; box-sizing: border-box;
  padding: 0.42rem 0.85rem 0.42rem 0.45rem; border: 1px solid transparent; border-radius: 999px; background: none;
  color: rgba(255, 255, 255, 0.75); font: inherit; font-size: 0.75rem; line-height: inherit; letter-spacing: 1.5px; text-transform: uppercase;
  cursor: pointer; transition: border-color .3s ease, color .3s ease; }
.farben button:hover { color: var(--accent, #5b7cff); border-color: var(--accent, #5b7cff); }
.farben button[aria-pressed="true"] { color: #fff; border-color: var(--accent, #5b7cff); background: rgba(91, 124, 255, 0.14); }
.farben button:focus-visible { outline: 2px solid var(--accent, #5b7cff); outline-offset: 2px; }
.farbe-punkt { width: 1em; height: 1em; border-radius: 50%; flex: none; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45); }
@media (max-width: 600px) {
  .farben { padding-left: 0; border-left: 0; order: 99; width: 100%; justify-content: center; }
  .farben .farbe-name { display: none; }
  .farben button { padding: 0.32rem; }
  .farbe-punkt { width: 1.45rem; height: 1.45rem; }
}
html.licht-an .farben { border-left-color: rgba(31, 29, 26, 0.18); }
html.licht-an .farben button { color: rgba(31, 29, 26, 0.75); }
html.licht-an .farben button:hover { color: var(--accent, #5b7cff); border-color: var(--accent, #5b7cff); }
html.licht-an .farben button[aria-pressed="true"] { color: #1f1d1a; border-color: var(--accent, #5b7cff); background: rgba(91, 124, 255, 0.12); }
html.licht-an .farbe-punkt { box-shadow: inset 0 0 0 1px rgba(31, 29, 26, 0.3); }
