/* =========================================
   Veranstaltungskalender Blankenhain
   Oeffentliches Frontend
   ========================================= */

:root {
    --primary: #4d7c0f;
    --primary-light: #65a30d;
    --primary-dark: #3a5e0a;
    --accent: #84cc16;
    --bg: #f7faf2;
    --card-bg: #fff;
    --text: #2b2b28;
    --text-light: #5c5c58;
    --border: #ddd;
    --radius: 10px;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
    --focus-ring: 3px solid #1d4ed8;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-light); }

/* Barrierefreiheit: sichtbarer Fokus-Indikator fuer Tastaturbedienung */
a:focus-visible,
button:focus-visible,
input:focus-visible,
.cal-day:focus-visible {
    outline: var(--focus-ring);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Nur fuer Screenreader sichtbar */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Skip-Link: erlaubt Tastaturnutzern, direkt zum Inhalt zu springen */
.skip-link {
    position: absolute;
    top: -3rem;
    left: 0.5rem;
    background: #fff;
    color: var(--primary-dark);
    padding: 0.6rem 1rem;
    border-radius: var(--radius);
    z-index: 2000;
    font-weight: 600;
    transition: top 0.2s;
}
.skip-link:focus {
    top: 0.5rem;
}

/* Header */
.site-header {
    background: var(--primary);
    color: #fff;
    padding: 1.5rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}
.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.site-header h1 { font-size: 1.5rem; font-weight: 700; }
.site-header h1 a { color: #fff; }
.site-logo {
    max-width: 340px;
    width: 100%;
    height: auto;
    border-radius: 8px;
    background: #fff;
    padding: 6px 10px;
}
.site-header .subtitle {
    font-size: 0.85rem;
    opacity: 0.8;
    font-weight: 400;
}
.header-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.header-nav a {
    color: rgba(255,255,255,0.95);
    font-size: 0.9rem;
    padding: 0.4rem 0.8rem;
    border: 1px solid rgba(255,255,255,0.4);
    border-radius: var(--radius);
    transition: all 0.2s;
    white-space: nowrap;
}
.header-nav a:hover {
    color: #fff;
    border-color: #fff;
    background: rgba(255,255,255,0.15);
}
.header-nav a.active {
    color: #fff;
    border-color: #fff;
    background: rgba(255,255,255,0.25);
}

/* Primaerer CTA-Button (Event einreichen) */
.header-nav a.nav-cta {
    background: #fff;
    color: var(--primary);
    font-weight: 600;
    border-color: #fff;
}
.header-nav a.nav-cta:hover {
    background: rgba(255,255,255,0.9);
    color: var(--primary-dark);
}

/* "Mehr"-Dropdown fuer sekundaere Links */
.nav-dropdown { position: relative; }
.nav-dropdown > summary {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    cursor: pointer;
    color: rgba(255,255,255,0.95);
    font-size: 0.9rem;
    padding: 0.4rem 0.8rem;
    border: 1px solid rgba(255,255,255,0.4);
    border-radius: var(--radius);
    white-space: nowrap;
    transition: all 0.2s;
    list-style: none;
}
.nav-dropdown > summary::-webkit-details-marker,
.nav-dropdown > summary::marker { display: none; content: ''; }
.nav-dropdown > summary:hover {
    color: #fff;
    border-color: #fff;
    background: rgba(255,255,255,0.15);
}
.nav-dropdown[open] > summary {
    color: #fff;
    border-color: #fff;
    background: rgba(255,255,255,0.15);
}
.nav-caret { font-size: 0.65em; transition: transform 0.2s; }
.nav-dropdown[open] .nav-caret { transform: rotate(180deg); }

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow-hover);
    padding: 0.4rem;
    min-width: 230px;
    z-index: 50;
}
.header-nav .nav-dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.6rem 0.7rem;
    border: none;
    border-radius: 6px;
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 400;
    text-align: left;
    white-space: nowrap;
    flex: none;
}
.header-nav .nav-dropdown-menu a:hover {
    background: var(--bg);
    color: var(--primary);
}

/* Container */
.container { max-width: 1100px; margin: 0 auto; padding: 0 1rem; }

/* Suchleiste */
.search-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 0.75rem;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.1rem;
    margin-top: 1.5rem;
}
.search-field {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}
.search-field label {
    font-size: 0.78rem;
    color: var(--text-light);
    font-weight: 600;
}
.search-field-main { flex: 2 1 320px; }
.search-field-date input { width: 10.5rem; }
.search-bar input {
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text);
    background: #fff;
}
.search-field-main input { font-size: 1rem; }
.search-field { flex: 1 1 220px; }
.search-bar input:focus-visible {
    outline: var(--focus-ring);
    outline-offset: 1px;
}
.search-submit {
    padding: 0.65rem 1.4rem;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.search-submit:hover { background: var(--primary-light); }
.search-reset {
    font-size: 0.85rem;
    padding: 0.6rem 0.2rem;
    white-space: nowrap;
}
.search-result-info {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Kategorie-Tabs */
.category-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 1.4rem;
    padding: 1.3rem 0 0.9rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 0.5rem;
}
.category-filter a {
    --tab-color: var(--primary);
    padding: 0.3rem 0.1rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-light);
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
}
.category-filter a:hover {
    color: var(--text);
}
.category-filter a.active {
    color: var(--tab-color);
    border-bottom-color: var(--tab-color);
}

/* Highlight-Sektion: Termine dieser Woche */
.highlight-section {
    padding: 1.5rem 0 0.5rem;
}
.highlight-title {
    font-size: 1.15rem;
    color: var(--primary);
    margin-bottom: 0.8rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid var(--accent);
}
.highlight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
}
.highlight-card {
    display: flex;
    gap: 0.8rem;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 0.8rem;
    color: inherit;
    border-left: 4px solid var(--accent);
    transition: box-shadow 0.2s, border-color 0.2s;
}
.highlight-card:hover {
    box-shadow: var(--shadow-hover);
    border-left-color: var(--primary);
}
.highlight-img {
    width: 90px;
    height: 70px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
    background: #e5e5e0;
}
.highlight-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #3f6212 0%, var(--accent) 100%);
    color: rgba(255,255,255,0.3);
    font-size: 1.5rem;
}
.highlight-info {
    flex: 1;
    min-width: 0;
}
.highlight-date {
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 600;
}
.highlight-info h3 {
    font-size: 0.95rem;
    line-height: 1.3;
    margin: 0.15rem 0;
}
.highlight-location {
    font-size: 0.78rem;
    color: var(--text-light);
}

/* Trenner zwischen "Diese Woche" und der restlichen Terminliste */
.section-divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2rem 0;
}

/* Kartenstecknadel-Icon (Google-Maps-Pin-Stil) */
.pin-icon {
    width: 0.85em;
    height: 0.85em;
    vertical-align: -0.05em;
    fill: #ea4335;
    flex-shrink: 0;
}

/* KI-Kennzeichnung (Art. 50 EU-KI-Verordnung) */
.ai-badge-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: #8caf6e;
    cursor: help;
    white-space: nowrap;
}
.ai-notice {
    display: inline-block;
    background: #f4f8ee;
    border: 1px solid #dbe8c9;
    color: #7a9a5c;
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

/* Reservierungspflicht */
.reservation-badge-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: #fff;
    background: #7c3aed;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    white-space: nowrap;
}
.reservation-notice {
    display: inline-block;
    background: #dc2626;
    color: #fff;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.2rem 0.8rem;
    border-radius: 12px;
    margin-bottom: 1rem;
}

/* Ausverkauft */
.soldout-badge-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: #fff;
    background: #dc2626;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    white-space: nowrap;
}
.soldout-notice {
    display: inline-block;
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

/* Event-Liste (Karten im Stil einer horizontalen Terminliste) */
.events-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.5rem 0 3rem;
}

.event-card {
    position: relative;
    background: var(--card-bg);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid transparent;
    transition: box-shadow 0.2s, border-color 0.2s, transform 0.15s;
}
.event-card:hover {
    box-shadow: var(--shadow-hover);
    border-color: var(--accent);
    transform: translateY(-1px);
}
.event-card a {
    color: inherit;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem;
}
.event-card-thumb {
    width: 130px;
    height: 96px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    background: #e5e5e0;
}
.event-card-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #3f6212 0%, var(--accent) 100%);
    color: rgba(255,255,255,0.35);
    font-size: 1.8rem;
}
.event-card-body {
    flex: 1;
    min-width: 0;
}
.event-card-badges {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.3rem;
}
.event-card-badges .category-badge {
    display: inline-block;
    padding: 0.15rem 0.6rem;
    border-radius: 10px;
    font-size: 0.7rem;
    color: #fff;
}
.event-card-body h3 {
    font-size: 1.05rem;
    line-height: 1.3;
    margin-bottom: 0.25rem;
}
.event-card-meta {
    font-size: 0.82rem;
    color: var(--text-light);
    margin-bottom: 0.3rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.15rem;
}
.event-card-desc {
    font-size: 0.85rem;
    color: var(--text-light);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.event-card-cta {
    flex-shrink: 0;
    align-self: center;
}
.cta-btn {
    display: inline-block;
    white-space: nowrap;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s;
}
.event-card:hover .cta-btn {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* Detail-Seite */
.event-detail {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin: 2rem 0;
    overflow: hidden;
}
.event-detail .hero-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
}
.event-detail .detail-body { padding: 2rem; }
.event-detail h1 { font-size: 1.8rem; margin-bottom: 0.5rem; }
.event-detail .meta {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}
.event-detail .meta span { display: flex; align-items: center; gap: 0.3rem; }
.event-detail .description {
    font-size: 1rem;
    line-height: 1.8;
}

/* Teilen-Leiste */
.share-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.3rem;
    border-bottom: 1px solid var(--border);
}
.share-label {
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 600;
    margin-right: 0.2rem;
}
.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 0.85rem;
    font-family: inherit;
    color: var(--text);
    background: #fff;
    cursor: pointer;
    transition: all 0.15s;
}
.share-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--bg);
}
.share-whatsapp:hover { border-color: #25d366; color: #1a9e4e; }
.share-facebook:hover { border-color: #1877f2; color: #1877f2; }
.share-btn svg { flex-shrink: 0; }
.calendar-actions {
    border-bottom: none;
    padding-bottom: 0.6rem;
    margin-bottom: 0.6rem;
}

/* Erinnerungs-Formular */
.reminder-box {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem 1.1rem;
    margin-bottom: 1.5rem;
}
.reminder-form label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.reminder-form-row {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.reminder-form-row input[type="email"] {
    flex: 1 1 220px;
    padding: 0.55rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.9rem;
    font-family: inherit;
}
.btn-sm-primary {
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    padding: 0.55rem 1.1rem;
    font-size: 0.9rem;
    font-family: inherit;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s;
}
.btn-sm-primary:hover { background: var(--primary-dark); }
.reminder-box .hint {
    color: var(--text-light);
    font-size: 0.78rem;
    margin-top: 0.5rem;
}

/* Merkliste (Favoriten) */
.fav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    color: #6b7280;
    padding: 0;
}
.fav-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    transition: all 0.15s;
}
.fav-btn.is-active { color: #f59e0b; }
.fav-btn.is-active svg { fill: #f59e0b; stroke: #f59e0b; }

.fav-btn-overlay {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
    justify-content: center;
    z-index: 2;
}
.fav-btn-overlay:hover { background: #fff; color: #f59e0b; }
.fav-btn-overlay .fav-label { display: none; }

.fav-btn-inline {
    padding: 0.4rem 0.8rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text);
    font-size: 0.85rem;
}
.fav-btn-inline.is-active { border-color: #f59e0b; color: #b45309; background: #fffbeb; }
.fav-btn-inline svg { width: 16px; height: 16px; }

.fav-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.2em;
    height: 1.2em;
    padding: 0 0.35em;
    margin-left: 0.35em;
    background: #f59e0b;
    color: #fff;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.2;
}

/* Merkliste-Seite */
.fav-list-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-light);
}
.fav-list-empty .icon { font-size: 2.5rem; margin-bottom: 1rem; }
.fav-list-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 0.9rem;
    margin-bottom: 0.8rem;
}
.fav-list-thumb {
    width: 90px;
    height: 68px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    background: #e5e5e0;
}
.fav-list-body { flex: 1; min-width: 0; }
.fav-list-body h3 { font-size: 1rem; margin-bottom: 0.2rem; }
.fav-list-meta { font-size: 0.82rem; color: var(--text-light); }
.fav-list-remove {
    flex-shrink: 0;
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.4rem 0.7rem;
    font-size: 0.8rem;
    color: var(--text-light);
    cursor: pointer;
    font-family: inherit;
}
.fav-list-remove:hover { border-color: #dc2626; color: #dc2626; }

/* Bildergalerie */
.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
    margin-top: 2rem;
}
.image-gallery img {
    width: 100%;
    border-radius: var(--radius);
    cursor: pointer;
    transition: opacity 0.2s;
    aspect-ratio: 4/3;
    object-fit: cover;
}
.image-gallery img:hover { opacity: 0.85; }
.gallery-item {
    display: block;
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
    width: 100%;
}
.gallery-item img { display: block; }

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.9);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.lightbox.active { display: flex; }
.lightbox img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
}
.lightbox .lb-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    background: none;
    border: none;
    line-height: 1;
}
.lightbox .lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    background: rgba(255,255,255,0.1);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
}
.lightbox .lb-prev { left: 1rem; }
.lightbox .lb-next { right: 1rem; }

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 0 3rem;
}
.pagination a, .pagination span {
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    font-size: 0.9rem;
}
.pagination a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination .current {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

/* Hauptlayout mit Sidebar */
.main-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
    align-items: start;
    padding-top: 0.5rem;
}
.main-content { min-width: 0; }

/* Sidebar */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: sticky;
    top: 1rem;
    align-self: start;
}

/* Kartenvorverkauf-Box */
.presale-box {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    border-top: 3px solid #e67e22;
}
.presale-title {
    font-size: 0.95rem;
    color: #e67e22;
    margin-bottom: 0.7rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid var(--border);
}
.presale-item {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
    color: inherit;
    transition: background 0.15s;
}
.presale-item:last-child { border-bottom: none; }
.presale-item:hover { background: #fef9f2; }
.presale-event-name {
    display: block;
    font-weight: 600;
    font-size: 0.85rem;
    line-height: 1.3;
    color: var(--text);
}
.presale-meta {
    display: block;
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 0.1rem;
}
.presale-date {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    color: #e67e22;
    margin-top: 0.2rem;
    padding: 0.1rem 0.4rem;
    background: #fef3e2;
    border-radius: 4px;
}

/* Reservierungs-Box (gleiche Struktur wie VVK-Box, roter Akzent) */
.reservation-box {
    border-top-color: #dc2626;
    margin-top: 1rem;
}
.reservation-box .presale-title { color: #dc2626; }
.reservation-box .presale-item:hover { background: #fef2f2; }

/* Kalender-Widget */
.calendar-widget {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1rem;
}
.calendar-widget .cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    padding: 0 0.2rem;
}
.calendar-widget .cal-header h3 {
    font-size: 0.95rem;
    color: var(--text);
}
.calendar-widget .cal-nav {
    background: none;
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    padding: 0.2rem 0.5rem;
    font-size: 0.85rem;
    color: var(--text);
    transition: all 0.2s;
}
.calendar-widget .cal-nav:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}
.calendar-widget table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}
.calendar-widget th {
    font-size: 0.7rem;
    color: var(--text-light);
    font-weight: 600;
    padding: 0.3rem;
    text-align: center;
    text-transform: uppercase;
}
.calendar-widget td {
    text-align: center;
    padding: 0;
}
.calendar-widget .cal-day {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin: 1px auto;
    border-radius: 50%;
    font-size: 0.85rem;
    color: var(--text);
    text-decoration: none;
    transition: all 0.15s;
}
.calendar-widget .cal-day.today {
    font-weight: 700;
    border: 2px solid var(--primary);
}
.calendar-widget .cal-day.has-event {
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    cursor: pointer;
}
.calendar-widget .cal-day.has-event:hover,
.calendar-widget .cal-day.has-event:focus-visible {
    background: var(--primary);
    color: #fff;
    transform: scale(1.15);
}
.calendar-widget .cal-day.other-month {
    color: var(--border);
}
.calendar-widget .cal-day.other-month.has-event {
    background: #d4eaad;
    color: #4d7c0f;
}

/* Keine Termine */
.no-events {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--text-light);
}
.no-events .icon { font-size: 3rem; margin-bottom: 1rem; }

/* Event einreichen: Formularseite */
.submit-page {
    max-width: 720px;
    margin: 1.5rem auto 3rem;
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 2rem;
}
.submit-page h1 { font-size: 1.5rem; margin-bottom: 0.6rem; }
.submit-intro {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* FAQ / Hilfe-Seite */
.faq-page { max-width: 780px; }
.faq-section-title {
    font-size: 1.05rem;
    color: var(--primary, #4d7c0f);
    margin: 1.8rem 0 0.7rem;
    padding-bottom: 0.3rem;
    border-bottom: 1px solid var(--border);
}
.faq-section-title:first-of-type { margin-top: 0.5rem; }
.faq-item {
    background: #fafafa;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 0.6rem;
    padding: 0.2rem 0;
}
.faq-item summary {
    cursor: pointer;
    padding: 0.7rem 1rem;
    font-weight: 600;
    font-size: 0.95rem;
    list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before {
    content: '+';
    display: inline-block;
    width: 1.1em;
    color: var(--primary, #4d7c0f);
    font-weight: 700;
}
.faq-item[open] summary::before { content: '\2212'; }
.faq-item[open] summary { border-bottom: 1px solid var(--border); }
.faq-answer {
    padding: 0.8rem 1rem 0.9rem 2.3rem;
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}
.faq-answer p { margin: 0; }
.faq-answer p + p { margin-top: 0.6rem; }
.submit-form .form-group { margin-bottom: 1.1rem; }
.submit-form label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
    color: var(--text);
}
.submit-form input[type="text"],
.submit-form input[type="email"],
.submit-form input[type="date"],
.submit-form input[type="file"],
.submit-form textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text);
    background: #fff;
}
.submit-form textarea { min-height: 110px; resize: vertical; }
.submit-form input:focus-visible,
.submit-form textarea:focus-visible {
    outline: var(--focus-ring);
    outline-offset: 1px;
}
.submit-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.submit-form .hint {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 0.3rem;
}
/* Honeypot-Feld: fuer Menschen unsichtbar, aber fuer Screenreader/Bots vorhanden */
.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Flash-Meldungen */
.flash {
    padding: 0.9rem 1.1rem;
    border-radius: var(--radius);
    font-size: 0.9rem;
    margin-bottom: 1.2rem;
}
.flash-success { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.flash-error { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }

@media (max-width: 600px) {
    .submit-page { padding: 1.3rem; }
    .submit-form .form-row { grid-template-columns: 1fr; }
}

/* Back-Link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin: 1.5rem 0 0;
    font-size: 0.9rem;
}

/* Footer */
.site-footer {
    background: var(--primary);
    color: rgba(255,255,255,0.7);
    padding: 1.5rem 0;
    text-align: center;
    font-size: 0.85rem;
    margin-top: 2rem;
}
.site-footer a {
    color: rgba(255,255,255,0.9);
    text-decoration: underline;
}
.site-footer a:hover {
    color: #fff;
}

/* Responsive */
@media (max-width: 900px) {
    .main-layout {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: static;
        order: -1;
    }
    .search-field-date input { width: 100%; }
}
@media (max-width: 600px) {
    .event-card a { flex-direction: column; align-items: stretch; }
    .event-card-thumb, .event-card-placeholder { width: 100%; height: 150px; }
    .event-card-cta { align-self: flex-end; }
    .event-detail .detail-body { padding: 1.2rem; }
    .event-detail h1 { font-size: 1.4rem; }
    .image-gallery { grid-template-columns: repeat(2, 1fr); }
    .site-header h1 { font-size: 1.2rem; }
    .site-logo { max-width: 260px; padding: 6px 8px; }
    .site-header .container { justify-content: center; text-align: center; }
    .header-nav { justify-content: center; width: 100%; }
    .header-nav a { flex: 1 1 auto; text-align: center; }
    .nav-dropdown { flex: 1 1 auto; }
    .nav-dropdown-menu {
        position: static;
        width: 100%;
        box-shadow: none;
        border: 1px solid rgba(255,255,255,0.4);
        margin-top: 0.4rem;
    }
    .search-bar { flex-direction: column; align-items: stretch; padding: 0.85rem; }
    .search-field { flex: 1 1 auto; width: 100%; }
    .search-field-date input { width: 100%; }
    .search-submit { width: 100%; }
    .search-reset { text-align: center; padding: 0.4rem 0; }
    .category-filter {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.7rem;
    }
    .category-filter a { flex-shrink: 0; }
    .calendar-widget .cal-day { width: 30px; height: 30px; font-size: 0.8rem; }
    .pagination a, .pagination span { padding: 0.45rem 0.75rem; font-size: 0.85rem; }
}

@media (max-width: 420px) {
    .container { padding: 0 0.75rem; }
    .highlight-grid { grid-template-columns: 1fr; }
}
