/* ============================================================
   PS BUECHBERG – MODERN LIGHT SWISS DESIGN
   ============================================================ */

:root {
    /* Colors – Light & Fresh */
    --bg-deep: #f5f5f0;
    --bg-primary: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #fafaf8;
    --bg-elevated: #f8f8f5;
    --bg-input: #f2f2ee;
    --bg-hero: #1a2332;

    --accent: #c0392b;
    --accent-hover: #e74c3c;
    --accent-soft: rgba(192, 57, 43, 0.08);
    --accent-glow: rgba(192, 57, 43, 0.15);
    --gold: #b8860b;
    --gold-soft: rgba(184, 134, 11, 0.08);
    --green: #27ae60;
    --green-soft: rgba(39, 174, 96, 0.08);

    --text-primary: #1a1a1a;
    --text-secondary: #555555;
    --text-muted: #999999;
    --text-on-dark: #f0ede8;

    --border: rgba(0, 0, 0, 0.08);
    --border-hover: rgba(0, 0, 0, 0.15);

    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow: 0 4px 16px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.05);

    --font-display: 'DM Serif Display', Georgia, serif;
    --font-body: 'Plus Jakarta Sans', system-ui, sans-serif;

    --header-h: 72px;
    --max-w: 1200px;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    background: var(--bg-deep);
    color: var(--text-primary);
    line-height: 1.65;
    font-weight: 400;
    font-size: 15px;
    min-height: 100vh;
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, textarea, select { font-family: inherit; font-size: inherit; }

.hidden { display: none !important; }

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.2; color: var(--text-primary); }
h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }

/* ============================================================
   HEADER
   ============================================================ */
#main-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-h);
    z-index: 1000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px) saturate(1.4);
    -webkit-backdrop-filter: blur(20px) saturate(1.4);
    border-bottom: 1px solid var(--border);
    transition: background 0.3s, box-shadow 0.3s;
}

#main-header.scrolled {
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 1px 20px rgba(0,0,0,0.06);
}

.header-inner {
    max-width: var(--max-w);
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 1.35rem;
    color: var(--text-primary);
    transition: opacity 0.2s;
}
.logo:hover { opacity: 0.7; }

.logo-icon-img {
    height: 38px;
    width: auto;
    object-fit: contain;
}

.logo-accent { color: var(--accent); }

#main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    padding: 8px 16px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: color 0.2s, background 0.2s;
    letter-spacing: 0.01em;
}
.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
    background: rgba(0,0,0,0.04);
}
.nav-link.active { color: var(--accent); }

/* Dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown::after { content: ''; position: absolute; left: 0; right: 0; top: 100%; height: 8px; }
.dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 6px;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all 0.2s;
    box-shadow: var(--shadow-lg);
}
.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.dropdown-menu a {
    display: block;
    padding: 8px 14px;
    font-size: 0.88rem;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    transition: all 0.15s;
}
.dropdown-menu a:hover {
    color: var(--text-primary);
    background: rgba(0,0,0,0.04);
}

/* Header Buttons */
.header-actions { display: flex; align-items: center; gap: 8px; }

.btn-login, .btn-admin {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    transition: all 0.2s;
}
.btn-login:hover, .btn-admin:hover {
    color: var(--text-primary);
    border-color: var(--border-hover);
    background: rgba(0,0,0,0.02);
}

.btn-admin {
    color: var(--accent);
    border-color: rgba(192,57,43,0.2);
}

.btn-logout {
    padding: 8px 14px;
    font-size: 0.82rem;
    color: var(--text-muted);
    transition: color 0.2s;
}
.btn-logout:hover { color: var(--accent); }

/* Hamburger */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 8px;
    z-index: 1001;
}
.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Mobile Nav */
.mobile-nav {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(30px);
    z-index: 999;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: calc(var(--header-h) + 20px) 24px 24px;
    overflow-y: auto;
    box-sizing: border-box;
}
.mobile-nav.open { display: flex; }
.mobile-nav-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: safe center;
    min-height: 0;
    overflow-y: auto;
    width: 100%;
}
.mobile-nav-links a {
    font-family: var(--font-display);
    font-size: 1.5rem;
    padding: 10px 24px;
    color: var(--text-secondary);
    transition: color 0.2s;
}
.mobile-nav-links a:hover { color: var(--accent); }
.mobile-nav-auth {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    width: 100%;
    max-width: 280px;
}
.mobile-nav-auth a,
.mobile-nav-auth button {
    font-family: var(--font-display);
    font-size: 1.1rem;
    padding: 12px 32px;
    border-radius: var(--radius);
    text-align: center;
    width: 100%;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    border: none;
    background: none;
}
.mobile-nav-auth .mobile-admin-btn {
    background: var(--accent);
    color: #fff;
    font-weight: 600;
}
.mobile-nav-auth .mobile-logout-btn {
    background: var(--bg-elevated);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    font-weight: 500;
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */
#app-content {
    min-height: calc(100vh - var(--header-h));
    padding-top: var(--header-h);
}

/* ============================================================
   HERO COMPACT – Slim banner header
   ============================================================ */
.hero-compact {
    background: linear-gradient(rgba(26,35,50,0.72), rgba(26,35,50,0.78)), url('/psbuechberg/img/psbuechberg_wiese.jpg') center 43%/cover no-repeat;
    padding: 48px 24px 44px;
    animation: fadeUp 0.5s ease-out;
}

.hero-compact-inner {
    max-width: var(--max-w);
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 20px;
}

.hero-compact-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.hero-compact-title {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3.5vw, 2.4rem);
    color: var(--text-on-dark);
    line-height: 1.2;
    margin-bottom: 4px;
}

.hero-compact-sub {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.5);
    letter-spacing: 0.02em;
}

.section-reports {
    padding-top: 48px;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: var(--radius);
    transition: all 0.25s;
    letter-spacing: 0.01em;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 2px 12px rgba(192,57,43,0.2);
}
.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(192,57,43,0.3);
}

.btn-outline {
    border: 1px solid var(--border-hover);
    color: var(--text-primary);
    background: transparent;
}
.btn-outline:hover {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.2);
}

.btn-sm {
    padding: 8px 18px;
    font-size: 0.82rem;
}

.btn-full { width: 100%; justify-content: center; }

.btn-danger { background: #c0392b; color: #fff; }
.btn-danger:hover { background: #e74c3c; }

.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: #d4a017; }

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
    padding: 80px 24px;
    max-width: var(--max-w);
    margin: 0 auto;
}

.section-header {
    margin-bottom: 48px;
}

.section-label {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--accent);
    margin-bottom: 12px;
}

.section-title {
    margin-bottom: 12px;
}

.section-desc {
    color: var(--text-secondary);
    max-width: 600px;
    font-size: 1rem;
}

.section-divider {
    width: 48px;
    height: 3px;
    background: var(--accent);
    margin-top: 16px;
    border-radius: 2px;
}

/* ============================================================
   REPORT CARDS (Blog Style)
   ============================================================ */
.reports-grid {
    display: grid;
    gap: 24px;
}

.report-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.35s;
    cursor: pointer;
    animation: fadeUp 0.5s ease-out both;
    box-shadow: var(--shadow-sm);
}
.report-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.report-card.featured {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.report-card-img {
    aspect-ratio: 16/9;
    background: var(--bg-elevated);
    overflow: hidden;
}
.report-card.featured .report-card-img {
    aspect-ratio: auto;
    min-height: 320px;
}
.report-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}
.report-card:hover .report-card-img img {
    transform: scale(1.04);
}

.report-card-img-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--text-muted);
    background: linear-gradient(135deg, #f0ede8 0%, #e8e4dd 100%);
}

.report-card-body {
    padding: 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.report-card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 0.82rem;
    color: var(--text-muted);
}

.report-tag {
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.report-tag-bericht {
    background: rgba(0,0,0,0.05);
    color: var(--text-secondary);
}
.report-tag-resultat {
    background: var(--gold-soft);
    color: var(--gold);
}

.report-card-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    margin-bottom: 10px;
    line-height: 1.3;
}
.report-card.featured .report-card-title {
    font-size: 1.8rem;
}

.report-card-excerpt {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.report-card-readmore {
    margin-top: 18px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent);
    transition: gap 0.2s;
}
.report-card:hover .report-card-readmore { gap: 10px; }

.report-card-edit {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 4;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(6px);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s, color 0.2s, background 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.report-card:hover .report-card-edit { opacity: 1; }
.report-card-edit:hover { background: var(--accent); color: #fff; }

.reports-small-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-top: 24px;
}

/* ============================================================
   SINGLE REPORT VIEW
   ============================================================ */
.report-single {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 24px;
}

.report-single-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
}
.report-single-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.88rem;
    transition: color 0.2s;
}
.report-single-back:hover { color: var(--accent); }

.report-single-img {
    width: 100%;
    aspect-ratio: 21/9;
    object-fit: cover;
    border-radius: var(--radius-lg);
    margin-bottom: 32px;
    box-shadow: var(--shadow);
}

.report-single-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.report-single h1 {
    margin-bottom: 28px;
    font-size: clamp(1.8rem, 4vw, 2.8rem);
}

.report-single-content {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-primary);
}
.report-single-content * {
    font-size: inherit !important;
    line-height: inherit !important;
    font-family: inherit !important;
}
.report-single-content p { margin-bottom: 16px; }
.report-single-content img {
    border-radius: var(--radius);
    margin: 24px 0;
}

/* Attachments */
.attachments {
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}
.attachments h3 { margin-bottom: 16px; }

.attachment-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 10px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.attachment-item:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-sm);
}

.attachment-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-soft);
    color: var(--accent);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 700;
}

.attachment-info { flex: 1; }
.attachment-name { font-weight: 600; font-size: 0.9rem; }
.attachment-size { font-size: 0.78rem; color: var(--text-muted); }

/* ============================================================
   EVENTS / TERMINE
   ============================================================ */
.events-timeline {
    position: relative;
    padding-left: 40px;
}
.events-timeline::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 0; bottom: 0;
    width: 2px;
    background: var(--border);
}

.event-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 20px;
    transition: all 0.25s;
    animation: fadeUp 0.5s ease-out both;
    box-shadow: var(--shadow-sm);
}
.event-card--next {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent), var(--shadow);
}
.event-card--next:hover {
    box-shadow: 0 0 0 1px var(--accent), var(--shadow-lg);
}
.event-next-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--accent);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 3px 10px;
    border-radius: 999px;
}
.event-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow);
}

.event-card::before {
    content: '';
    position: absolute;
    left: -32px;
    top: 28px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 4px var(--bg-deep), 0 0 12px var(--accent-glow);
}

.event-date-badge {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 14px;
    background: var(--accent-soft);
    border-radius: var(--radius-sm);
    margin-bottom: 14px;
    min-width: 60px;
}
.event-date-day {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    line-height: 1;
}
.event-date-month {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
}

.event-title {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.event-details {
    display: flex;
    gap: 10px 16px;
    flex-wrap: wrap;
    font-size: 0.85rem;
    color: var(--text-secondary);
    align-items: center;
}
.event-detail {
    display: flex;
    align-items: center;
    gap: 6px;
}

.event-category {
    display: inline-block;
    padding: 2px 8px;
    background: rgba(0,0,0,0.04);
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 10px;
}
.event-ics-btn {
    background: none;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 0.82rem;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--text-secondary);
    font-weight: 500;
}
.event-ics-btn:hover {
    background: rgba(37,99,235,0.08);
    border-color: var(--accent);
    color: var(--accent);
}

/* Month sections for Termine grouping */
.month-section {
    margin-bottom: 32px;
    animation: fadeUp 0.5s ease-out both;
}
.month-header {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent);
}
.month-header-name {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    text-transform: capitalize;
}
.month-header-year {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
}
/* Info box per month (dateless info entries) */
.month-info-box {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    background: linear-gradient(135deg, rgba(59,130,246,0.06) 0%, rgba(59,130,246,0.02) 100%);
    border: 1px solid rgba(59,130,246,0.18);
    border-left: 3px solid #3b82f6;
    border-radius: var(--radius);
    padding: 14px 18px;
    margin-bottom: 18px;
}
.month-info-icon {
    font-size: 1rem;
    font-weight: 700;
    color: #3b82f6;
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(59,130,246,0.1);
    border-radius: 50%;
    margin-top: 1px;
}
.month-info-items {
    flex: 1;
    min-width: 0;
}
.month-info-entry {
    font-size: 0.88rem;
    color: var(--text-primary);
    line-height: 1.5;
    padding: 3px 0;
}
.month-info-entry + .month-info-entry {
    border-top: 1px solid rgba(59,130,246,0.1);
    margin-top: 3px;
    padding-top: 6px;
}

/* ============================================================
   RESULTS PAGE
   ============================================================ */
.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
}

.result-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: all 0.3s;
    animation: fadeUp 0.5s ease-out both;
    box-shadow: var(--shadow-sm);
}
.result-card:hover {
    border-color: rgba(184,134,11,0.3);
    box-shadow: 0 4px 24px rgba(184,134,11,0.08);
}

.result-card-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 14px;
}

.result-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gold-soft);
    color: var(--gold);
    border-radius: var(--radius);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.result-card h3 {
    font-size: 1.1rem;
    margin-bottom: 4px;
}
.result-card-date {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.result-card-content {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.result-downloads {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.result-dl-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.2s;
}
.result-dl-btn:hover {
    background: rgba(0,0,0,0.05);
    color: var(--text-primary);
    border-color: var(--border-hover);
}

/* Collapsible result entries (report-linked Resultate page) */
.resultat-entry {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 16px;
    overflow: hidden;
    animation: fadeUp 0.5s ease-out both;
    box-shadow: var(--shadow-sm);
    transition: border-color 0.3s, box-shadow 0.3s;
}
.resultat-entry:hover {
    border-color: rgba(184,134,11,0.3);
    box-shadow: 0 4px 24px rgba(184,134,11,0.08);
}
.resultat-entry--open {
    border-color: rgba(184,134,11,0.3);
}
.resultat-entry-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px 24px;
    cursor: pointer;
    background: var(--bg-card);
    transition: background 0.2s;
}
.resultat-entry-header:hover {
    background: var(--bg-elevated);
}
.resultat-entry-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 4px;
}
.resultat-entry-arrow {
    font-size: 0.8rem;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 0.2s;
}
.resultat-entry-body {
    padding: 0 24px 24px;
    background: var(--bg-card);
}
@media (max-width: 600px) {
    .resultat-entry-header { padding: 16px; gap: 10px; }
    .resultat-entry-body { padding: 0 16px 16px; }
    .resultat-entry-title { font-size: 1rem; }
}

/* ============================================================
   BOARD / VORSTAND
   ============================================================ */
.board-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.board-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    transition: all 0.3s;
    animation: fadeUp 0.5s ease-out both;
    box-shadow: var(--shadow-sm);
}
.board-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border-hover);
}

.board-card-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    margin: 0 auto 20px;
    overflow: hidden;
    background: var(--bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid var(--bg-deep);
    box-shadow: var(--shadow-sm);
}
.board-card-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.board-card-avatar-placeholder {
    font-size: 2rem;
    color: var(--text-muted);
}

.board-card-name {
    font-family: var(--font-display);
    font-size: 1.15rem;
    margin-bottom: 4px;
}
.board-card-role {
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 14px;
}
.board-card-contact {
    font-size: 0.82rem;
    color: var(--text-muted);
}
.board-card-contact a { transition: color 0.2s; }
.board-card-contact a:hover { color: var(--accent); }

/* ============================================================
   ANFAHRT / MAP
   ============================================================ */
.map-container {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    height: 450px;
    margin-top: 32px;
    box-shadow: var(--shadow);
}
.map-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.address-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-top: 24px;
    box-shadow: var(--shadow-sm);
}

.address-card h3 { margin-bottom: 16px; }

.address-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.address-item-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    margin-bottom: 6px;
}

/* ============================================================
   KONTAKT
   ============================================================ */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.contact-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-sm);
}

.contact-item {
    display: flex;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}
.contact-item:last-child { border-bottom: none; }

.contact-icon-box {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-soft);
    color: var(--accent);
    border-radius: var(--radius);
    flex-shrink: 0;
    font-size: 1.1rem;
}

.contact-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 4px;
}

/* ============================================================
   ARCHIV
   ============================================================ */
.archive-years {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 40px;
}

.archive-year-btn {
    padding: 10px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.2s;
    box-shadow: var(--shadow-sm);
}
.archive-year-btn:hover, .archive-year-btn.active {
    background: var(--accent-soft);
    border-color: var(--accent);
    color: var(--accent);
}

.archive-reports {
    display: grid;
    gap: 12px;
}

.archive-item {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 20px;
    transition: all 0.2s;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    text-decoration: none;
    color: inherit;
    margin-bottom: 8px;
}
.archive-item:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow);
}
.archive-item-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 16px;
}
.archive-item-date {
    font-size: 0.82rem;
    color: var(--text-muted);
    white-space: nowrap;
    min-width: 90px;
}
.archive-item-title {
    font-weight: 600;
    flex: 1;
    min-width: 150px;
}
.archive-item-badges {
    font-size: 0.78rem;
    color: var(--text-muted);
    width: 100%;
}
.archive-item-btn {
    flex-shrink: 0;
    text-decoration: none;
    white-space: nowrap;
}
@media (max-width: 600px) {
    .archive-item { flex-wrap: wrap; gap: 8px; padding: 14px; }
    .archive-item-info { gap: 2px 12px; }
    .archive-item-btn { width: 100%; text-align: center; }
}

/* ============================================================
   INTERN (Internal Documents)
   ============================================================ */
.intern-docs-grid {
    display: grid;
    gap: 16px;
}

.intern-doc-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    transition: all 0.25s;
    box-shadow: var(--shadow-sm);
    animation: fadeUp 0.5s ease-out both;
}
.intern-doc-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow);
}

.intern-doc-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(59,130,246,0.06);
    border-radius: var(--radius);
}

.intern-doc-info {
    flex: 1;
    min-width: 180px;
}

.intern-doc-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    margin-bottom: 4px;
    line-height: 1.3;
}

.intern-doc-subtitle {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.intern-doc-meta {
    display: flex;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--text-muted);
}

.intern-doc-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    align-items: center;
}

.intern-doc-edit {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 4;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,0.04);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s, color 0.2s, background 0.2s;
    font-size: 0.9rem;
}
.intern-doc-card:hover .intern-doc-edit { opacity: 1; }
.intern-doc-edit:hover { background: var(--accent); color: #fff; }

.intern-doc-viewer {
    width: 100%;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.intern-doc-viewer.open {
    max-height: 700px;
    margin-top: 12px;
}
.intern-doc-viewer iframe {
    width: 100%;
    height: 600px;
    border: none;
    border-top: 1px solid var(--border);
    border-radius: 0 0 var(--radius) var(--radius);
    display: block;
}

.intern-archive-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
}
.intern-archive-toggle:hover {
    background: var(--bg-elevated);
    border-color: var(--border-hover);
}
.intern-archive-arrow {
    font-size: 0.7rem;
    transition: transform 0.3s;
}
.intern-archive-toggle.open .intern-archive-arrow {
    transform: rotate(180deg);
}

@media (max-width: 600px) {
    .intern-doc-card { padding: 16px; gap: 12px; }
    .intern-doc-icon { width: 40px; height: 40px; font-size: 1.4rem; }
    .intern-doc-actions { width: 100%; }
    .intern-doc-viewer iframe { height: 400px; }
    .intern-doc-viewer.open { max-height: 500px; }
}

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.about-content {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 48px;
    align-items: start;
}

.about-text {
    font-size: 1.05rem;
    line-height: 1.85;
    color: var(--text-secondary);
}
.about-text p { margin-bottom: 16px; }

.about-sections {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.about-section-card {
    display: flex;
    gap: 24px;
    padding: 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s;
    animation: fadeUp 0.5s ease-out both;
}
.about-section-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.about-section-icon {
    font-size: 2.2rem;
    line-height: 1;
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.03);
    border-radius: var(--radius);
}

.about-section-content {
    flex: 1;
    min-width: 0;
}

.about-section-title {
    font-family: var(--font-display);
    font-size: 1.15rem;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.about-section-text {
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--text-secondary);
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}
.stat-number {
    font-family: var(--font-display);
    font-size: 2rem;
    color: var(--accent);
    margin-bottom: 4px;
}
.stat-label {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ============================================================
   MODAL
   ============================================================ */
.modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(8px);
}

.modal-content {
    position: relative;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px;
    max-width: 420px;
    width: 90%;
    box-shadow: var(--shadow-lg);
    animation: modalIn 0.3s ease-out;
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.95) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    transition: all 0.2s;
}
.modal-close:hover { color: var(--text-primary); background: rgba(0,0,0,0.05); }

.modal-content h2 {
    margin-bottom: 24px;
    font-size: 1.5rem;
}

/* ============================================================
   FORMS
   ============================================================ */
.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    transition: border-color 0.2s;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

.form-check {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
}
.form-check input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
}
.form-check label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.form-error {
    padding: 10px 14px;
    background: rgba(231,76,60,0.06);
    border: 1px solid rgba(231,76,60,0.2);
    border-radius: var(--radius-sm);
    color: #c0392b;
    font-size: 0.85rem;
    margin-bottom: 14px;
}

/* ============================================================
   ADMIN PANEL
   ============================================================ */
.admin-panel {
    position: fixed;
    inset: 0;
    z-index: 2000;
}

.admin-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.3);
    backdrop-filter: blur(6px);
}

.admin-content {
    position: absolute;
    right: 0; top: 0; bottom: 0;
    width: min(90vw, 700px);
    background: var(--bg-primary);
    border-left: 1px solid var(--border);
    box-shadow: -4px 0 40px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    animation: slideInRight 0.3s ease-out;
    overflow: hidden;
}

@keyframes slideInRight {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px;
    border-bottom: 1px solid var(--border);
}
.admin-header h2 { font-size: 1.3rem; }

.admin-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
    padding: 0 28px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-elevated);
}

.admin-tab {
    padding: 14px 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}
.admin-tab:hover { color: var(--text-secondary); }
.admin-tab.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
}

.admin-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px;
}

.admin-list-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 10px;
    transition: border-color 0.2s;
}
.admin-list-item--report {
    flex-wrap: wrap;
}
.admin-list-item--report .admin-list-actions {
    flex-shrink: 0;
}
.admin-list-item:hover { border-color: var(--border-hover); }

.admin-list-item-info { flex: 1; min-width: 0; }
.admin-list-item-title-row { display: flex; align-items: center; gap: 8px; justify-content: space-between; margin-bottom: 4px; }
.admin-list-item-title { font-weight: 600; font-size: 0.9rem; }
.admin-list-badge { display: inline-block; padding: 1px 8px; background: var(--accent-soft); color: var(--accent); font-size: 0.68rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; border-radius: 50px; white-space: nowrap; flex-shrink: 0; }
.admin-list-item-meta { font-size: 0.78rem; color: var(--text-muted); line-height: 1.5; }
.admin-list-item-sub { font-size: 0.78rem; color: var(--text-muted); }

.admin-list-actions {
    display: flex;
    gap: 6px;
}

.admin-btn-edit, .admin-btn-delete {
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 600;
    transition: all 0.2s;
}
.admin-btn-edit {
    color: var(--text-secondary);
    background: rgba(0,0,0,0.04);
}
.admin-btn-edit:hover { background: rgba(0,0,0,0.08); color: var(--text-primary); }
.admin-btn-delete { color: #e74c3c; background: rgba(231,76,60,0.06); }
.admin-btn-delete:hover { background: rgba(231,76,60,0.12); }

/* Admin year groups (collapsible) */
.admin-year-group {
    margin-bottom: 8px;
}
.admin-year-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
}
.admin-year-toggle:hover {
    background: var(--accent-soft);
    border-color: var(--accent);
}
.admin-year-toggle.open {
    border-radius: var(--radius) var(--radius) 0 0;
    border-bottom-color: transparent;
}
.admin-year-arrow {
    font-size: 0.72rem;
    color: var(--text-muted);
    width: 14px;
    text-align: center;
    transition: transform 0.2s;
}
.admin-year-content {
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 var(--radius) var(--radius);
    padding: 4px 0;
    margin-bottom: 4px;
}

.admin-form {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 24px;
}
.admin-form h3 {
    margin-bottom: 18px;
    font-size: 1.1rem;
}

.admin-form-actions {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}

/* File upload area */
.upload-area {
    border: 2px dashed var(--border-hover);
    border-radius: var(--radius);
    padding: 28px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 14px;
}
.upload-area:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}
.upload-area-text {
    color: var(--text-muted);
    font-size: 0.88rem;
}
.upload-area-text strong {
    color: var(--accent);
}
.upload-area input[type="file"] { display: none; }

.upload-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}
.upload-preview-item {
    position: relative;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    font-size: 0.82rem;
    display: flex;
    align-items: center;
    gap: 8px;
}
.upload-preview-remove {
    color: var(--accent);
    font-weight: 700;
    cursor: pointer;
}

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
#toast-container {
    position: fixed;
    top: 90px;
    right: 24px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 14px 20px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.88rem;
    box-shadow: var(--shadow-lg);
    animation: toastIn 0.3s ease-out;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 360px;
}
.toast-success { border-left: 3px solid var(--green); }
.toast-error { border-left: 3px solid #e74c3c; }

@keyframes toastIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ============================================================
   FOOTER
   ============================================================ */
#main-footer {
    background: #1a2332;
    color: rgba(255,255,255,0.7);
    padding: 60px 24px 32px;
}

.footer-inner {
    max-width: var(--max-w);
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 48px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: #fff;
    margin-bottom: 14px;
}
.footer-logo-img {
    height: 34px;
    width: auto;
    object-fit: contain;
}

.footer-desc {
    color: rgba(255,255,255,0.45);
    font-size: 0.88rem;
    line-height: 1.6;
}

.footer-col h4 {
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.5);
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    padding: 4px 0;
    font-size: 0.88rem;
    color: rgba(255,255,255,0.5);
    transition: color 0.2s;
}
.footer-col a:hover { color: #fff; }

.footer-col p {
    font-size: 0.88rem;
    color: rgba(255,255,255,0.45);
    line-height: 1.6;
}

.footer-bottom {
    padding-top: 24px;
    border-top: 1px solid rgba(255,255,255,0.08);
    text-align: center;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.3);
}

/* ============================================================
   LOADING
   ============================================================ */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
}

.loading-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

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

.empty-state {
    text-align: center;
    padding: 60px 24px;
    color: var(--text-muted);
}
.empty-state-icon {
    font-size: 3rem;
    margin-bottom: 16px;
    opacity: 0.4;
}
.empty-state p {
    font-size: 0.95rem;
}

/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
    #main-nav { display: none; }
    .hamburger { display: flex; }
    .btn-login, .btn-admin, .btn-logout { display: none !important; }

    .hero { min-height: 60vh; }

    .report-card.featured { grid-template-columns: 1fr; }
    .report-card.featured .report-card-img {
        min-height: 200px;
        aspect-ratio: 16/9;
    }
    .reports-small-grid { grid-template-columns: 1fr; }

    .about-content { grid-template-columns: 1fr; }
    .about-section-card { padding: 24px; gap: 16px; }
    .about-section-icon { width: 44px; height: 44px; font-size: 1.6rem; }
    .about-stats {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .stat-card {
        display: flex;
        align-items: center;
        gap: 16px;
        text-align: left;
        padding: 18px 22px;
    }
    .stat-number { margin-bottom: 0; font-size: 1.5rem; }
    .stat-label { font-size: 0.82rem; }
    .contact-grid { grid-template-columns: 1fr; }
    .gemeinde-content { grid-template-columns: 1fr !important; }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .admin-content { width: 100vw; }
    .results-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    :root { --header-h: 60px; }
    body { font-size: 14px; }
    .section { padding: 48px 16px; }
    .hero-actions { flex-direction: column; align-items: center; }
    .footer-grid { grid-template-columns: 1fr; gap: 24px; }
    .events-timeline { padding-left: 28px; }
    .event-card::before { left: -20px; }
    .month-info-box { padding: 10px 14px; }
    .month-header { margin-bottom: 12px; }
    .board-grid { grid-template-columns: 1fr; }
    .admin-body { padding: 16px; }
    .admin-tabs { padding: 0 16px; }
    .admin-tab { padding: 10px 14px; font-size: 0.8rem; }
    .pdf-attachment-header { gap: 6px; padding: 10px 12px; }
    .pdf-attachment-name, .pdf-attachment-name-input { flex: 1 1 100%; min-width: 0; font-size: 0.82rem; }
    .pdf-attachment-actions { flex: 1 1 100%; margin-top: 4px; }
    .pdf-attachment-size { order: -1; }
    .pdf-btn { padding: 6px 14px; font-size: 0.8rem; flex: 1; justify-content: center; }
    .map-container { height: 300px; }
}

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: #aaa; }

::selection {
    background: var(--accent);
    color: #fff;
}

/* ============================================================
   SLIDESHOW / IMAGE GALLERY
   ============================================================ */
.slideshow {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--bg-deep);
}
.slideshow-track {
    display: flex;
    transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}
.slideshow-slide {
    min-width: 100%;
    position: relative;
    overflow: hidden;
}
.slideshow-slide img {
    width: 100%;
    display: block;
    object-fit: cover;
}
.slideshow--detail .slideshow-slide img {
    max-height: 520px;
    object-fit: contain;
    background: var(--bg-deep);
}
.slideshow--card .slideshow-slide img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-radius: var(--radius);
}
.slideshow--card {
    box-shadow: 0 2px 12px rgba(0,0,0,0.10), 0 0 0 1px rgba(0,0,0,0.04);
    border-radius: var(--radius);
}
.slideshow-prev,
.slideshow-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(6px);
    border: none;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s, background 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.slideshow:hover .slideshow-prev,
.slideshow:hover .slideshow-next { opacity: 1; }
.slideshow-prev:hover,
.slideshow-next:hover { background: #fff; }
.slideshow-prev { left: 10px; }
.slideshow-next { right: 10px; }
.slideshow-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 7px;
    z-index: 3;
}
.slideshow-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    border: none;
    cursor: pointer;
    transition: background 0.25s, transform 0.2s;
    padding: 0;
}
.slideshow-dot.active {
    background: #fff;
    transform: scale(1.25);
    box-shadow: 0 0 4px rgba(0,0,0,0.3);
}
.slideshow-counter {
    position: absolute;
    top: 10px;
    right: 12px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    font-size: 0.72rem;
    padding: 3px 10px;
    border-radius: 20px;
    z-index: 3;
    letter-spacing: 0.04em;
}

/* ============================================================
   PDF VIEWER (collapsible)
   ============================================================ */
.pdf-attachment {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 12px;
}
.pdf-attachment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--bg-elevated);
    cursor: pointer;
    transition: background 0.2s;
    flex-wrap: wrap;
}
.pdf-attachment-header:hover { background: var(--bg-input); }
.pdf-attachment-name {
    flex: 1;
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--text-primary);
}
.pdf-attachment-name-input {
    flex: 1;
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--text-primary);
    background: transparent;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    padding: 4px 8px;
    transition: border-color 0.2s, background 0.2s;
}
.pdf-attachment-name-input:hover {
    border-color: var(--border);
    background: var(--bg-primary);
}
.pdf-attachment-name-input:focus {
    outline: none;
    border-color: var(--accent);
    background: var(--bg-primary);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
.pdf-attachment-size {
    font-size: 0.78rem;
    color: var(--text-muted);
}
.pdf-attachment-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}
.pdf-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}
.pdf-btn--view {
    background: var(--accent-soft);
    color: var(--accent);
}
.pdf-btn--view:hover { background: var(--accent-glow); }
.pdf-btn--view.active {
    background: var(--accent);
    color: #fff;
}
.pdf-btn--download {
    background: var(--bg-input);
    color: var(--text-secondary);
}
.pdf-btn--download:hover {
    background: var(--border-hover);
    color: var(--text-primary);
}
.pdf-frame-wrapper {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.pdf-frame-wrapper.open {
    max-height: 700px;
}
.pdf-frame-wrapper iframe {
    width: 100%;
    height: 600px;
    border: none;
    border-top: 1px solid var(--border);
    display: block;
}

/* ============================================================
   GALLERY GRID (5-per-view with scroll)
   ============================================================ */
.gallery-grid {
    position: relative;
    margin-top: 32px;
}
.gallery-grid-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.gallery-grid-count {
    font-weight: 400;
    color: var(--text-muted);
    font-size: 0.78rem;
}
.gallery-grid-track {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
}
.gallery-grid-track::-webkit-scrollbar { height: 6px; }
.gallery-grid-track::-webkit-scrollbar-track { background: var(--bg-deep); border-radius: 3px; }
.gallery-grid-track::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }
.gallery-grid-track::-webkit-scrollbar-thumb:hover { background: #aaa; }
.gallery-grid-item {
    flex: 0 0 calc((100% - 40px) / 5);
    scroll-snap-align: start;
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
    position: relative;
    background: var(--bg-deep);
    aspect-ratio: 4/3;
    box-shadow: 0 2px 10px rgba(0,0,0,0.10), 0 0 0 1px rgba(0,0,0,0.04);
    transition: transform 0.2s, box-shadow 0.2s;
}
.gallery-grid-item:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.18), 0 0 0 1px rgba(0,0,0,0.06);
}
.gallery-grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}
.gallery-grid-item:hover img {
    transform: scale(1.05);
}
.gallery-grid-more {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 0.02em;
    backdrop-filter: blur(2px);
}
.gallery-grid-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(6px);
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    opacity: 0;
    transition: opacity 0.25s;
}
.gallery-grid:hover .gallery-grid-nav { opacity: 1; }
.gallery-grid-nav:hover { background: #fff; }
.gallery-grid-nav--prev { left: -12px; }
.gallery-grid-nav--next { right: -12px; }

/* Lightbox overlay */
.lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0,0,0,0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
    animation: lbFadeIn 0.2s ease;
    -webkit-user-select: none;
    user-select: none;
}
@keyframes lbFadeIn { from { opacity: 0 } to { opacity: 1 } }
.lightbox-img-container {
    position: relative;
    max-width: min(92vw, calc(100vw - 120px));
    max-height: 88vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lightbox-overlay img,
.lightbox-img-container img {
    max-width: min(92vw, calc(100vw - 120px));
    max-height: 88vh;
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.4);
    cursor: default;
}
.lightbox-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    font-size: 1.6rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    backdrop-filter: blur(8px);
}
.lightbox-close:hover { background: rgba(255,255,255,0.3); }
.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(8px);
    border: none;
    color: #fff;
    font-size: 2.2rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: background 0.2s;
}
.lightbox-arrow:hover { background: rgba(255,255,255,0.25); }
.lightbox-arrow--left { left: 16px; }
.lightbox-arrow--right { right: 16px; }
.lightbox-counter {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.7);
    font-size: 0.82rem;
    background: rgba(0,0,0,0.4);
    padding: 4px 12px;
    border-radius: 20px;
    backdrop-filter: blur(4px);
}
@media (max-width: 600px) {
    .lightbox-arrow { width: 36px; height: 36px; font-size: 1.6rem; }
    .lightbox-arrow--left { left: 8px; }
    .lightbox-arrow--right { right: 8px; }
    .lightbox-overlay img, .lightbox-img-container img { max-width: 96vw; max-height: 85vh; }
    .lightbox-img-container { max-width: 96vw; max-height: 85vh; }
}

/* ============================================================
   RICH TEXT EDITOR
   ============================================================ */
.rte-wrap {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color 0.2s;
}
.rte-wrap:focus-within { border-color: var(--accent); }
.rte-toolbar {
    display: flex;
    align-items: center;
    gap: 1px;
    padding: 4px 6px;
    background: #f5f6f8;
    border-bottom: 1px solid var(--border);
}
.rte-toolbar .rte-sep {
    width: 1px;
    height: 20px;
    background: var(--border);
    margin: 0 4px;
    flex-shrink: 0;
}
.rte-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 5px;
    background: transparent;
    color: #444;
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 600;
    transition: background 0.15s, color 0.15s;
    flex-shrink: 0;
    position: relative;
}
.rte-btn:hover { background: #e8e9ec; color: #111; }
.rte-btn.active { background: var(--accent); color: #fff; }
.rte-btn svg { width: 16px; height: 16px; fill: currentColor; }

/* Color picker: hidden input behind a styled button */
.rte-color-label {
    cursor: pointer;
    gap: 0;
    font-weight: 700;
    font-size: 0.9rem;
    flex-direction: column;
    line-height: 1;
    padding-top: 3px;
}
.rte-color-dot {
    display: block;
    width: 16px;
    height: 3px;
    border-radius: 1px;
    background: #000;
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
}
.rte-color-input {
    position: absolute;
    width: 0;
    height: 0;
    padding: 0;
    border: none;
    opacity: 0;
    pointer-events: none;
}

/* Editor body */
.rte-body {
    min-height: 180px;
    max-height: 500px;
    overflow-y: auto;
    padding: 14px 16px;
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--text-primary);
    background: var(--bg);
    outline: none;
}
.rte-body:empty::before {
    content: attr(data-placeholder);
    color: var(--text-muted);
    pointer-events: none;
}
.rte-body ul, .rte-body ol { padding-left: 24px; margin: 8px 0; }
.rte-body li { margin-bottom: 4px; }
.rte-body a { color: var(--accent); text-decoration: underline; }

/* Public content: ensure lists and links render properly */
.report-single-content ul, .report-single-content ol { padding-left: 24px; margin: 12px 0; }
.report-single-content li { margin-bottom: 6px; }
.report-single-content a { color: var(--accent); text-decoration: underline; }

@media (max-width: 768px) {
    .slideshow-prev, .slideshow-next { width: 32px; height: 32px; font-size: 0.9rem; opacity: 0.8; }
    .slideshow--detail .slideshow-slide img { max-height: 320px; }
    .pdf-frame-wrapper iframe { height: 400px; }
    .pdf-frame-wrapper.open { max-height: 500px; }
    .gallery-grid-item { flex: 0 0 calc((100% - 20px) / 3); }
    .gallery-grid-nav { display: none; }
}
