/* =========================================================================
   Feuerwehr Inselstadt Malchow – Homepage Stylesheet
   ========================================================================= */

:root {
    --fw-red:        #c1121f;
    --fw-red-dark:   #9a0e18;
    --fw-dark:       #1d1d1f;
    --fw-gray:       #6b7280;
    --fw-light:      #f4f5f7;
    --fw-border:     #e2e4e8;
    --fw-white:      #ffffff;
    --fw-success:    #2e7d32;
    --fw-success-bg: #e6f4ea;
    --fw-error:      #c62828;
    --fw-error-bg:   #fdecea;
    --fw-warn:       #b26a00;
    --fw-warn-bg:    #fff4e0;

    /* Einsatztypen */
    --op-brand:     #c1121f;   /* Brände: rot */
    --op-thl:       #ef6c00;   /* Technische Hilfe: orange */
    --op-gewaesser: #1565c0;   /* Gewässer: blau */
    --op-uebung:    #2e7d32;   /* Übungen: grün */

    --radius:    10px;
    --shadow:    0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
    --shadow-lg: 0 8px 24px rgba(0,0,0,.12);
    --maxw:      1140px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--fw-dark);
    background: var(--fw-light);
    line-height: 1.55;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a { color: var(--fw-red); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }

/* ── Topbar ───────────────────────────────────────────────────────────── */
.topbar {
    background: var(--fw-dark);
    color: #d6d6da;
    font-size: .82rem;
}
.topbar-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: .35rem 1.25rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}
.topbar a { color: #e8e8ec; margin-right: 1rem; }
.topbar a:last-child { margin-right: 0; }
.topbar a:hover { color: #fff; }

/* ── Banner / Header-Bild ─────────────────────────────────────────────── */
.site-banner {
    background-color: var(--fw-red);
    background-size: cover;
    background-position: center;
    position: relative;
}
.site-banner.no-image {
    background: linear-gradient(120deg, var(--fw-red), var(--fw-red-dark));
}
.banner-overlay {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 2.5rem 1.25rem;
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}
.site-banner { display: flex; }
.site-banner > .banner-overlay { width: 100%; }
.banner-brand {
    display: flex;
    align-items: center;
    gap: .9rem;
    color: #fff;
}
.banner-brand:hover { text-decoration: none; }
.banner-logo {
    height: 64px;
    width: auto;
    background: #fff;
    border-radius: 8px;
    padding: 4px;
}
.banner-text {
    display: flex;
    flex-direction: column;
    text-align: center;
}
.banner-name {
    color: #fff;
    font-weight: 800;
    font-size: 1.9rem;
    line-height: 1.1;
}
.banner-slogan {
    color: #fff;
    font-weight: 400;
    font-size: 1.05rem;
    line-height: 1.3;
    margin-top: .3rem;
    opacity: .92;
}

/* ── Navigation (Reiter) ──────────────────────────────────────────────── */
.site-nav {
    background: var(--fw-red);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}
.nav-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 1.25rem;
    display: flex;
    align-items: center;
}
.nav-toggle {
    display: none;
    background: transparent;
    color: #fff;
    border: 0;
    font-size: 1rem;
    font-weight: 600;
    padding: .8rem .2rem;
    cursor: pointer;
}
.nav-menu, .nav-sub { list-style: none; margin: 0; padding: 0; }
.nav-menu { display: flex; flex-wrap: wrap; }
.nav-menu > li { position: relative; }
.nav-menu > li > a {
    display: block;
    color: #fff;
    font-weight: 600;
    padding: .85rem 1.05rem;
    font-size: .96rem;
}
.nav-menu > li > a:hover { background: rgba(0,0,0,.16); text-decoration: none; }
.nav-menu .caret { font-size: .7rem; opacity: .85; }

/* Untermenüs (Dropdown) */
.nav-menu li.has-children > .nav-sub {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 210px;
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 110;
    padding: .3rem 0;
}
.nav-menu li.has-children:hover > .nav-sub { display: block; }
.nav-sub li { position: relative; }
.nav-sub a {
    display: block;
    color: var(--fw-dark);
    padding: .55rem 1.1rem;
    font-size: .92rem;
    font-weight: 500;
}
.nav-sub a:hover { background: var(--fw-light); text-decoration: none; color: var(--fw-red); }
/* Verschachtelte 3. Ebene klappt nach rechts auf */
.nav-sub li.has-children > .nav-sub {
    position: absolute;
    top: 0;
    left: 100%;
    min-width: 200px;
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    display: none;
    padding: .3rem 0;
}
.nav-sub li.has-children:hover > .nav-sub { display: block; }

/* ── Layout ───────────────────────────────────────────────────────────── */
.site-main {
    flex: 1;
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 1.75rem 1.25rem 3rem;
    overflow-wrap: break-word;
}
.page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
}
.page-head h1 { margin: 0; font-size: 1.7rem; }
.section-title {
    font-size: 1.35rem;
    margin: 2rem 0 1rem;
    padding-bottom: .4rem;
    border-bottom: 2px solid var(--fw-red);
    display: inline-block;
}

/* ── Breadcrumb ───────────────────────────────────────────────────────── */
.breadcrumb { font-size: .9rem; color: var(--fw-gray); margin-bottom: 1rem; }
.breadcrumb a { color: var(--fw-gray); }
.breadcrumb span { margin: 0 .35rem; }

/* ── Hero / Begrüßung (Startseite) ────────────────────────────────────── */
.welcome {
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-left: 5px solid var(--fw-red);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.75rem;
}
.welcome h1 { margin-top: 0; font-size: 1.6rem; }
.welcome p { margin-bottom: 0; color: #333; }

/* ── Statistik-Kacheln ────────────────────────────────────────────────── */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}
.stat-tile {
    background: var(--fw-red);
    color: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.4rem 1rem;
    text-align: center;
}
.stat-tile.alt { background: var(--fw-dark); }
.stat-number { font-size: 2.3rem; font-weight: 800; line-height: 1; }
.stat-label { font-size: .9rem; opacity: .92; margin-top: .35rem; }

/* ── Modulare Startseite (Bausteine) ──────────────────────────────────── */
.home-blocks {
    display: flex;
    flex-wrap: wrap;
    gap: 1.75rem 1.5rem;          /* Zeilenabstand / Spaltenabstand */
    align-items: flex-start;
}
.home-block { flex: 1 1 100%; min-width: 0; }
.home-block.block-half { flex: 1 1 calc(50% - 0.75rem); }
/* Eigene Außenabstände der Bausteininhalte entfallen – der Abstand kommt vom gap */
.home-block > section { margin: 0; }
.home-block .welcome,
.home-block .stat-grid,
.home-block .op-list,
.home-block .grid { margin-bottom: 0; }
.home-block .page-head { margin-bottom: 1rem; }
.home-block .section-title { margin-top: 0; }

.home-image-wrap { width: 100%; }
.home-image { width: 100%; height: auto; border-radius: var(--radius); display: block; }

@media (max-width: 820px) {
    .home-block.block-half { flex: 1 1 100%; }
}

/* ── Karten / Grid ────────────────────────────────────────────────────── */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
}
.card {
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: transform .12s ease, box-shadow .12s ease;
    display: flex;
    flex-direction: column;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.card-thumb {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    background: #e9eaee;
}
.card-thumb.placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.6rem;
    color: #b9bcc4;
}
.card-body { padding: 1.1rem 1.2rem; flex: 1; display: flex; flex-direction: column; }
.card-title { font-weight: 700; font-size: 1.1rem; margin: 0 0 .35rem; }
.card-title a { color: var(--fw-dark); }
.card-title a:hover { color: var(--fw-red); text-decoration: none; }
.card-meta { font-size: .8rem; color: var(--fw-gray); margin-bottom: .5rem; }
.card-excerpt { color: #444; font-size: .92rem; margin: 0 0 .8rem; }
/* Auf der Fahrzeugkarte direkt angezeigte technische Felder */
.card-specs { margin: 0 0 .7rem; font-size: .82rem; color: var(--fw-gray); }
.card-specs > div { display: flex; flex-wrap: wrap; gap: .3rem; padding: .05rem 0; }
.card-specs dt { font-weight: 600; margin: 0; }
.card-specs dt::after { content: ":"; }
.card-specs dd { margin: 0; }
.card-foot { margin-top: auto; }

/* ── Personenkarten (Mitglieder / Wehrführung) ────────────────────────── */
/* Spaltenanzahl per --person-cols steuerbar (Shortcode-Attribut „spalten"),
   Standard 4. Auf schmaleren Geräten greifen die Media-Queries unten. */
.people-grid {
    display: grid;
    grid-template-columns: repeat(var(--person-cols, 4), minmax(0, 1fr));
    gap: 1rem;
}
@media (max-width: 900px) { .people-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 680px) { .people-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 440px) { .people-grid { grid-template-columns: 1fr; } }

.person-card {
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1rem 1.1rem 1.1rem;
    display: flex;
    flex-direction: column;
}
.person-photo {
    position: relative;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    overflow: hidden;
    background: #eef1f6;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: .7rem;
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.person-photo-placeholder { width: 64%; height: 64%; fill: #aab6c6; }
.person-name {
    font-size: 1.02rem;
    font-weight: 700;
    margin: 0 0 .15rem;
    color: var(--fw-dark);
    line-height: 1.25;
}
.person-role {
    color: var(--fw-gray);
    font-size: .85rem;
    margin-bottom: .3rem;
}
.person-fields {
    margin: .35rem 0 0;
    font-size: .82rem;
    color: var(--fw-gray);
    width: 100%;
}
.person-fields > div {
    display: flex;
    flex-wrap: wrap;
    gap: .3rem;
    padding: .08rem 0;
}
.person-fields dt { font-weight: 600; margin: 0; }
.person-fields dt::after { content: ":"; }
.person-fields dd { margin: 0; }

/* ── Einsatzliste ─────────────────────────────────────────────────────── */
.op-list { display: flex; flex-direction: column; gap: .7rem; }
.op-item {
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-left: 5px solid var(--fw-gray);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: .9rem 1.1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.op-item.type-brand     { border-left-color: var(--op-brand); }
.op-item.type-thl       { border-left-color: var(--op-thl); }
.op-item.type-gewaesser { border-left-color: var(--op-gewaesser); }
.op-item.type-uebung    { border-left-color: var(--op-uebung); }
.op-date {
    font-weight: 700;
    font-size: .9rem;
    color: var(--fw-dark);
    min-width: 116px;
}
.op-date small { display: block; font-weight: 400; color: var(--fw-gray); }
.op-main { flex: 1; min-width: 180px; }
.op-main .op-title { font-weight: 600; }
.op-main .op-title a { color: var(--fw-dark); }
.op-main .op-title a:hover { color: var(--fw-red); }
.op-loc { font-size: .85rem; color: var(--fw-gray); }
.op-no {
    display: inline-block;
    font-size: .72rem;
    font-weight: 700;
    color: var(--fw-red);
    background: #fde7e9;
    border-radius: 4px;
    padding: 0 .35rem;
    margin-bottom: .15rem;
}
.op-keyword { font-size: .82rem; font-weight: 600; color: var(--fw-gray); }
.op-flags { display: inline-flex; gap: .3rem; margin-left: .4rem; vertical-align: middle; }
.op-flag { font-size: .82rem; opacity: .65; cursor: default; }

/* Einsatz-Statistik je Typ (zugleich Typ-Filter) */
.op-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: .6rem;
    margin-bottom: 1.5rem;
}
.op-stat {
    display: block;
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-top: 4px solid var(--fw-gray);
    border-radius: var(--radius);
    padding: .75rem .8rem;
    text-align: center;
    color: var(--fw-dark);
    transition: box-shadow .12s ease, transform .12s ease;
}
.op-stat:hover { text-decoration: none; box-shadow: var(--shadow); transform: translateY(-1px); }
.op-stat-num { font-size: 1.7rem; font-weight: 800; line-height: 1; }
.op-stat-label { font-size: .8rem; color: var(--fw-gray); margin-top: .25rem; }
.op-stat.active { box-shadow: inset 0 0 0 2px var(--fw-red); background: #fff7f7; }
.op-stat.all { border-top-color: var(--fw-dark); }
.op-stat.type-brand     { border-top-color: var(--op-brand); }
.op-stat.type-thl       { border-top-color: var(--op-thl); }
.op-stat.type-gewaesser { border-top-color: var(--op-gewaesser); }
.op-stat.type-uebung    { border-top-color: var(--op-uebung); }

/* Typ-Badge */
.op-badge {
    display: inline-block;
    padding: .2rem .6rem;
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
}
.op-badge.type-brand     { background: var(--op-brand); }
.op-badge.type-thl       { background: var(--op-thl); }
.op-badge.type-gewaesser { background: var(--op-gewaesser); }
.op-badge.type-uebung    { background: var(--op-uebung); }

/* Filterleiste */
.filterbar {
    display: flex;
    gap: .5rem;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
    align-items: center;
}
.filterbar .chip {
    padding: .4rem .9rem;
    border-radius: 999px;
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    font-size: .88rem;
    font-weight: 600;
    color: var(--fw-gray);
}
.filterbar .chip:hover { text-decoration: none; border-color: var(--fw-red); color: var(--fw-red); }
.filterbar .chip.active { background: var(--fw-red); color: #fff; border-color: var(--fw-red); }

/* ── Panels / Inhalt ──────────────────────────────────────────────────── */
.panel {
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.panel h2 { margin-top: 0; }
.content-body { font-size: 1rem; }
.content-body img { max-width: 100%; height: auto; border-radius: 8px; }
.content-body h2, .content-body h3 { margin-top: 1.4rem; }
.article-image {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: var(--radius);
    margin-bottom: 1.25rem;
}
.article-meta { color: var(--fw-gray); font-size: .9rem; margin-bottom: 1rem; }

/* ── Medien-Galerie ───────────────────────────────────────────────────── */
.media-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: .75rem;
    margin: 1.25rem 0;
}
.media-gallery img { width: 100%; height: 160px; object-fit: cover; border-radius: 8px; cursor: pointer; }
.media-gallery figure { margin: 0; }
.media-gallery figcaption { font-size: .82rem; color: var(--fw-gray); margin-top: .35rem; text-align: center; line-height: 1.3; }

/* ── Datei-Downloads ──────────────────────────────────────────────────── */
.download-list { display: flex; flex-direction: column; gap: .5rem; margin: 1.25rem 0; }
.download-item {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .7rem .9rem;
    background: var(--fw-white);
    border: 1px solid var(--fw-border);
    border-radius: var(--radius);
    color: var(--fw-dark);
    transition: box-shadow .12s ease, border-color .12s ease;
}
.download-item:hover { text-decoration: none; box-shadow: var(--shadow); border-color: var(--fw-red); }
.download-ext {
    flex: 0 0 auto;
    font-size: .72rem;
    font-weight: 700;
    color: #fff;
    background: var(--fw-red);
    border-radius: 5px;
    padding: .3rem .5rem;
    min-width: 2.8rem;
    text-align: center;
}
.download-name { flex: 1; font-weight: 600; word-break: break-word; }
.download-size { flex: 0 0 auto; font-size: .82rem; color: var(--fw-gray); }

/* ── Datentabellen / technische Daten ─────────────────────────────────── */
table.data, table.specs {
    width: 100%;
    border-collapse: collapse;
    background: var(--fw-white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}
table.data th, table.data td, table.specs th, table.specs td {
    text-align: left;
    padding: .7rem .9rem;
    border-bottom: 1px solid var(--fw-border);
    font-size: .92rem;
}
table.data th { background: var(--fw-light); font-weight: 600; }
table.data tr:last-child td, table.specs tr:last-child td { border-bottom: 0; }
table.data tr:hover td { background: #fafafa; }
table.specs th { width: 40%; background: var(--fw-light); font-weight: 600; }

/* ── Formulare ────────────────────────────────────────────────────────── */
form .field { margin-bottom: 1.1rem; }
form label { display: block; font-weight: 600; margin-bottom: .35rem; font-size: .92rem; }
form .hint { color: var(--fw-gray); font-size: .82rem; font-weight: 400; margin-top: .25rem; }
input[type=text], input[type=email], input[type=password], input[type=number],
input[type=url], input[type=date], input[type=datetime-local], input[type=search],
select, textarea {
    width: 100%;
    padding: .6rem .7rem;
    border: 1px solid var(--fw-border);
    border-radius: 8px;
    font-size: .95rem;
    font-family: inherit;
    background: #fff;
}
textarea { min-height: 140px; resize: vertical; }
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--fw-red);
    box-shadow: 0 0 0 3px rgba(193,18,31,.12);
}
.form-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.form-row > .field { flex: 1; min-width: 200px; }
.checkbox-row { display: flex; align-items: center; gap: .5rem; }
.checkbox-row input { width: auto; }
.checkbox-list {
    display: flex; flex-direction: column; gap: .5rem;
    border: 1px solid var(--fw-border); border-radius: 8px; padding: .75rem;
}
.checkbox-list label { font-weight: 500; display: flex; align-items: flex-start; gap: .5rem; margin: 0; }
.checkbox-list input { width: auto; margin-top: .2rem; }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ── Buttons ──────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: var(--fw-red);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: .6rem 1.1rem;
    font-size: .95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .12s ease;
}
.btn:hover { background: var(--fw-red-dark); text-decoration: none; color: #fff; }
.btn-secondary { background: #e8e8eb; color: var(--fw-dark); }
.btn-secondary:hover { background: #dcdce0; color: var(--fw-dark); }
.btn-danger { background: var(--fw-error); }
.btn-danger:hover { background: #a31515; }
.btn-sm { padding: .35rem .7rem; font-size: .82rem; }
.btn-group { display: flex; gap: .5rem; flex-wrap: wrap; }
.btn-block { width: 100%; justify-content: center; }

/* ── Flash-Nachrichten ────────────────────────────────────────────────── */
.flash {
    padding: .8rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: .92rem;
    border: 1px solid transparent;
}
.flash-success { background: var(--fw-success-bg); color: var(--fw-success); border-color: #bfe3c6; }
.flash-error   { background: var(--fw-error-bg);   color: var(--fw-error);   border-color: #f5c6c0; }
.flash-warning { background: var(--fw-warn-bg);    color: var(--fw-warn);    border-color: #f3dca6; }

/* ── Badges ───────────────────────────────────────────────────────────── */
.badge {
    display: inline-block;
    padding: .15rem .55rem;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 600;
    background: var(--fw-light);
    color: var(--fw-gray);
}
.badge-admin { background: #fde7e9; color: var(--fw-red); }
.badge-on    { background: var(--fw-success-bg); color: var(--fw-success); }
.badge-off   { background: #eee; color: var(--fw-gray); }

/* ── Login / Auth ─────────────────────────────────────────────────────── */
.auth-wrap { max-width: 400px; margin: 4rem auto; }
.auth-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
}
.auth-card h1 { text-align: center; margin-top: 0; font-size: 1.4rem; }
.auth-logo { text-align: center; font-size: 2.5rem; margin-bottom: .5rem; }

/* ── Footer ───────────────────────────────────────────────────────────── */
.site-footer {
    background: var(--fw-dark);
    color: #cfcfd4;
    font-size: .9rem;
    margin-top: auto;
}
.footer-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 2rem 1.25rem 1.25rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}
.footer-col strong { color: #fff; display: block; margin-bottom: .5rem; }
.footer-col a { color: #fff; display: inline-block; margin-bottom: .3rem; }
.footer-text { margin: .2rem 0; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,.12);
    text-align: center;
    padding: .9rem 1.25rem;
    font-size: .82rem;
    color: #9a9aa2;
}
.footer-bottom a { color: #fff; }
.footer-sep { opacity: .4; }

/* ── Hilfsklassen ─────────────────────────────────────────────────────── */
.muted { color: var(--fw-gray); }
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.empty-state { text-align: center; color: var(--fw-gray); padding: 3rem 1rem; }
.empty-state .big { font-size: 2.5rem; display: block; margin-bottom: .5rem; }

/* ── Lightbox ─────────────────────────────────────────────────────────── */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 92%; max-height: 92%; border-radius: 8px; }

/* ── Mobile / Responsive ──────────────────────────────────────────────── */
@media (max-width: 820px) {
    .banner-name { font-size: 1.4rem; }
    .banner-overlay { min-height: 110px; padding: 1.75rem 1.25rem; }

    /* Navigation als ausklappbares Menü */
    .site-nav { position: static; }
    .nav-inner { flex-direction: column; align-items: stretch; padding: 0; }
    .nav-toggle { display: block; padding: .9rem 1.25rem; text-align: left; }
    .nav-menu { display: none; flex-direction: column; }
    .nav-menu.open { display: flex; }
    .nav-menu > li > a { padding: .8rem 1.25rem; border-top: 1px solid rgba(255,255,255,.12); }

    /* Untermenüs inline statt als Dropdown */
    .nav-menu li.has-children > .nav-sub,
    .nav-sub li.has-children > .nav-sub {
        position: static;
        display: none;
        box-shadow: none;
        border: 0;
        border-radius: 0;
        background: rgba(0,0,0,.18);
        padding: 0;
    }
    .nav-menu li.open > .nav-sub { display: block; }
    .nav-sub a { color: #fff; padding-left: 2.4rem; }
    .nav-sub a:hover { background: rgba(0,0,0,.25); color: #fff; }
    .nav-menu li.has-children:hover > .nav-sub { display: none; } /* Hover deaktivieren */
    .nav-menu li.open.has-children > .nav-sub { display: block; }

    .site-main { padding: 1.1rem .9rem 2.5rem; }
    .page-head h1 { font-size: 1.4rem; }
    .panel { padding: 1.1rem; }

    /* Feste zweispaltige Layouts (z. B. Kontakt: Adresse + Formular) stapeln */
    .site-main .grid[style*="grid-template-columns"] { grid-template-columns: 1fr !important; }

    /* iOS-Zoom verhindern */
    input[type=text], input[type=email], input[type=password], input[type=number],
    input[type=url], input[type=date], input[type=datetime-local], input[type=search],
    select, textarea { font-size: 16px; }

    .form-row { flex-direction: column; gap: 0; }
    .form-row > .field { width: 100%; min-width: 0; }

    /* Breite Tabellen horizontal scrollbar machen, statt das Layout zu sprengen */
    table.data,
    .content-body table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
    table.specs { white-space: normal; }

    /* Einsatzliste klar gegliedert: Datum oben links, Typ oben rechts,
       Titel/Stichwort/Ort darunter über die volle Breite. */
    .op-item {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-areas:
            "date badge"
            "main main";
        gap: .35rem .6rem;
        align-items: start;
    }
    .op-date  { grid-area: date; min-width: 0; }
    .op-badge { grid-area: badge; justify-self: end; }
    .op-main  { grid-area: main; min-width: 0; }

    .footer-inner { text-align: center; }

    .auth-wrap { margin: 1.5rem auto; }
    .auth-card { padding: 1.5rem; }
}

/* Echte Smartphone-Breiten */
@media (max-width: 480px) {
    .topbar-inner { padding: .35rem .9rem; font-size: .76rem; }
    .topbar a { margin-right: .7rem; }

    /* Logo über den Namen stapeln, Schrift weiter verkleinern */
    .banner-overlay { min-height: 88px; padding: 1.3rem 1rem; }
    .banner-brand { flex-direction: column; gap: .55rem; }
    .banner-logo { height: 52px; }
    .banner-name { font-size: 1.2rem; }
    .banner-slogan { font-size: .9rem; }

    .site-main { padding: 1rem .8rem 2.25rem; }
    .page-head h1 { font-size: 1.25rem; }
    .section-title { font-size: 1.12rem; }
    .welcome { padding: 1.15rem 1.2rem; }
    .welcome h1 { font-size: 1.3rem; }
    .panel { padding: 1rem; }

    .stat-number { font-size: 2rem; }
    .op-stat-num { font-size: 1.45rem; }
    .media-gallery img { height: 210px; }

    /* Aktionsbuttons als gut tippbare, volle Breite */
    .btn-group .btn { flex: 1 1 auto; justify-content: center; }
}
