/* =========================================
   WISSENSDATENBANK & EVENTS (wissen.css)
   Zusammenführung von maitre-event & flair
   Goldstandard: Keine Transforms, striktes Raster
   ========================================= */

/* =========================================
   1. EVENT-NAVIGATION & HEADER-ELEMENTE
   ========================================= */
.event-logo-bar { 
    display: block; width: 100%; max-width: 926px; margin: 0 auto; 
}
.event-logo-bar img { 
    width: 100%; height: auto; display: block; 
}

.event-nav {
    display: flex; justify-content: space-between; align-items: center;
    width: 100%; max-width: 926px; margin: 10px auto; padding: 0;
}
.event-nav a {
    text-transform: uppercase; letter-spacing: 0.25em; font-size: 0.9rem;
    color: var(--accent-brown); text-decoration: none !important;
    transition: color 0.3s ease; cursor: pointer;
}
.event-nav a:hover, .event-nav a.active-event { 
    color: var(--accent-rot); 
}

/* =========================================
   2. EVENT-BLÖCKE (Ohne Transform/Wackeln!)
   ========================================= */
.event-block {
    display: block; text-align: center; text-decoration: none !important;
    color: inherit !important; margin-bottom: 40px; 
    transition: opacity 0.3s ease-in-out; 
}
.event-block:hover { 
    opacity: 0.8; 
}
.event-block:hover h2, .event-block:hover h3 { 
    color: var(--accent-rot) !important; 
}

.event-emblem { 
    height: 45px; width: auto; margin: 0 auto 15px auto; display: block; 
}

/* Spezifische Event-Typografie */
.subhead {
    font-size: 1.15rem; font-family: serif; font-style: italic;
    color: var(--accent-brown); margin-top: 0; margin-bottom: 0.5rem;
}
.event-meta {
    font-size: 0.9rem; letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--accent-brown); margin-top: 5px;
}
.event-sub { 
    font-size: 1rem; color: var(--accent-brown); font-style: italic;
    margin-top: 0; margin-bottom: 0; line-height: var(--grid-base);
}

/* =========================================
   3. DELIGHT-LISTEN (Mit Wappen-Bullet)
   ========================================= */
.delight-list {
    list-style: none; padding: 0; margin: 0 auto var(--grid-double) auto; max-width: 620px;
}
.delight-list li {
    position: relative; padding-left: 2.5rem; margin-bottom: var(--grid-half);
    text-align: left; line-height: 1.6;
}
.delight-list li::before {
    content: ""; position: absolute; left: 0; top: 0.2rem;
    width: 1.4rem; height: 1.4rem;
    background-image: url('../images/wappen.webp');
    background-size: contain; background-repeat: no-repeat;
}

/* =========================================
   4. SLOGANS & COMMUNITY-FLAIR
   ========================================= */
.slogan-block { text-align: center; padding: 20px 0; }
.slogan-block h1 { margin: 0; letter-spacing: 0.2em; }

.section-header-block { text-align: center; margin-top: 30px; margin-bottom: 40px; }
.section-header-block h1 { margin: 0 0 5px 0; letter-spacing: 0.2em; }
.section-header-block h5 { margin: 0 0 15px 0; font-weight: normal; font-style: italic; }

/* Linien-Spezialitäten für Flair */
.hr-flush { 
    margin: 0 !important; padding: 0 !important; border: none; 
    border-top: 1px solid var(--accent-brown); display: block; width: 100%; 
}
.hr-short { 
    width: 20%; margin: 40px auto; border: none; 
    border-top: 1px solid var(--accent-brown); 
}

.narrow-content-wrapper { max-width: 800px; margin: 0 auto 40px auto; padding: 0 20px; }

/* =========================================
   5. COMMUNITY LOGOS (Nebeneinander)
   ========================================= */
.community-block { margin-bottom: 50px; text-align: center; }
.logo-row {
    display: flex; justify-content: center; align-items: center;
    gap: 20px; flex-wrap: wrap; margin-bottom: 40px;
}
.social-hover-link { display: block; position: relative; width: 100px; height: 100px; line-height: 0; }
.social-img-standard { display: block; width: 100px; height: 100px; transition: opacity 0.3s ease; }
.social-img-hover {
    position: absolute; top: 0; left: 0; width: 100px; height: 100px;
    opacity: 0; transition: opacity 0.3s ease;
}
.social-hover-link:hover .social-img-hover { opacity: 1; }

/* =========================================
   6. BANNER & CROSSFADE-SLIDESHOWS
   ========================================= */
.event-banner-container, .flair-crossfade {
    display: block; position: relative; width: 100%;
    max-width: 926px; margin: 0 auto; overflow: hidden;
    background-color: var(--bg-base); line-height: 0;
}
.flair-crossfade { max-width: 100%; margin-bottom: 0; }

.event-banner-placeholder { display: block; width: 100%; height: auto; visibility: hidden; }

.event-slideshow-img, .flair-crossfade img {
    position: absolute; top: 0; left: 0; width: 100%; height: auto;
    opacity: 0; transition: opacity 1.2s ease-in-out; z-index: 1; display: block;
}
.event-slideshow-img.active { opacity: 1; z-index: 2; }

/* Der Fallback: Das erste Bild spannt den Container auf (bei flair) */
.flair-crossfade img:nth-child(1) { position: relative; opacity: 1; z-index: 1; }

/* =========================================
   7. MOBIL-WEICHE FÜR EVENTS & WISSEN
   ========================================= */
@media (max-width: 768px) {
    .event-nav {
        flex-direction: column; justify-content: center; gap: 15px; text-align: center;
    }
}

/* =========================================
   8. AGB & RECHTSTEXTE (Spezifische Formatierungen)
   ========================================= */

/* Box für das Widerrufsformular */
.agb-withdrawal-box {
    background-color: var(--bg-base); 
    border: 1px solid var(--accent-brown);
    padding: calc(var(--grid-base) * 1) 20px;
    margin: 0 auto calc(var(--grid-base) * 3) auto;
    max-width: 800px;
    text-align: left;
}

.agb-withdrawal-box h5 {
    text-align: center;
    margin-top: 0;
    margin-bottom: var(--grid-half);
}

.agb-withdrawal-box p {
    font-family: monospace;
    font-size: 0.95rem;
    line-height: var(--grid-base);
    color: var(--accent-brown);
    margin-top: 0; /* Verhindert künstlichen Abstand */
    margin-bottom: var(--grid-half);
}

/* Kontaktbox am Ende der AGB */
.agb-contact-box {
    background-color: var(--bg-base);
    border-top: 1px solid var(--accent-brown);
    border-bottom: 1px solid var(--accent-brown);
    padding: calc(var(--grid-base) * 1.5) 20px;
    margin: 0 auto calc(var(--grid-base) * 3) auto;
    max-width: 800px;
}

.agb-contact-flex {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
    margin-top: 0; /* Die Box schließt bündig ab */
}

.agb-contact-column {
    flex: 1;
    min-width: 250px;
    text-align: center;
}

.agb-contact-column p {
    margin: 0;
    line-height: var(--grid-base);
    color: var(--accent-brown);
}

/* =========================================
   9. LOGIN-MODAL & WARNHINWEISE (Für geschützte Tänze)
   ========================================= */
.login-error-msg {
    display: none;
    color: var(--accent-rot);
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1rem;
    margin-top: var(--grid-half);
    font-weight: bold;
    text-align: center;
}

.login-info-text {
    font-family: 'Libre Caslon Text', Georgia, serif;
    color: var(--accent-brown);
    font-size: 1.1rem;
    margin-top: calc(var(--grid-half) * 1.5);
    line-height: var(--grid-base);
    text-align: center;
}

.login-submit-btn {
    margin-top: calc(var(--grid-half) * 1.5);
    padding: 8px 30px;
    background-color: var(--accent-rot);
    color: var(--bg-base);
    border: none;
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    cursor: pointer;
    transition: opacity 0.3s ease;
    display: inline-block;
}

.login-submit-btn:hover {
    opacity: 0.8;
}

.warning-text {
    color: var(--accent-rot);
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    display: block;
    margin-bottom: 0.2rem;
}

/* Modal Overlay */
.modal-overlay {
    display: none; 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(0, 0, 0, 0.85); 
    z-index: 1000; 
    justify-content: center; 
    align-items: center; 
    opacity: 0; 
    transition: opacity 0.3s ease;
}

.modal-content { 
    position: relative; 
    max-width: 926px; 
    width: 100%; 
    text-align: center; 
    margin: 0 auto; 
}

.login-bg { 
    width: 100%; 
    height: auto; 
    display: block; 
}

.login-form-container { 
    position: absolute; 
    bottom: 12%; 
    left: 0; 
    width: 100%; 
    text-align: center; 
}

.login-input { 
    background: transparent; 
    border: none; 
    border-bottom: 1px solid var(--accent-rot); 
    color: var(--accent-brown); 
    font-family: 'Libre Caslon Text', Georgia, serif; 
    font-size: 1.2rem; 
    text-align: center; 
    width: 300px; 
    padding: 5px; 
    outline: none; 
}

.close-modal { 
    position: absolute; 
    top: 20px; 
    right: 30px; 
    color: var(--accent-rot); 
    font-size: 2rem; 
    font-weight: bold; 
    cursor: pointer; 
    z-index: 10; 
    text-decoration: none; 
    transition: color 0.3s ease; 
}

.close-modal:hover { 
    color: var(--accent-brown); 
}

/* Modal Mobil-Weiche */
@media (max-width: 768px) {
    .modal-content { 
        display: flex; 
        flex-direction: column; 
        background-color: var(--bg-base); 
        border: 2px solid var(--accent-brown); 
    }
    .login-bg { 
        position: relative; 
        width: 100%; 
        height: auto; 
        object-fit: contain; 
        z-index: 1; 
    }
    .login-form-container { 
        position: relative; 
        padding: 10px 20px 30px 20px; 
        z-index: 2; 
        bottom: auto; 
    }
    .close-modal { 
        z-index: 10; 
        background-color: var(--bg-base); 
        color: var(--accent-rot); 
        border-radius: 50%; 
        width: 30px; 
        height: 30px; 
        line-height: 30px; 
        text-align: center; 
        top: 10px; 
        right: 10px; 
        box-shadow: 0 0 5px rgba(0,0,0,0.2); 
    }
}

/* =========================================
   9. SPEZIELLE ABSTANDS-KLASSEN & WARNUNGEN
   ========================================= */
/* Erzeugt den sauberen, dreizeiligen Abschluss-Abstand OHNE leere Spacer-Divs oder <br> */
.title-block-last hr {
    margin-bottom: calc(var(--grid-base) * 3);
}

.warning-text {
    display: block;
    color: var(--accent-rot);
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 0.85rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-top: 0;
    margin-bottom: 0;
}

/* =========================================
   10. LOGIN-MODAL (Passwort-Schutz)
   ========================================= */
.modal-overlay {
    display: none; 
    position: fixed; 
    top: 0; left: 0; width: 100%; height: 100%; 
    background-color: rgba(0, 0, 0, 0.85); 
    z-index: 1000; 
    justify-content: center; align-items: center; 
    opacity: 0; transition: opacity 0.3s ease;
}

.modal-content { 
    position: relative; max-width: 926px; width: 100%; 
    text-align: center; margin: 0 auto; 
}

.login-bg { width: 100%; height: auto; display: block; }

.login-form-container { 
    position: absolute; bottom: 12%; left: 0; 
    width: 100%; text-align: center; 
}

.login-input { 
    background: transparent; border: none; 
    border-bottom: 1px solid var(--accent-rot); 
    color: var(--accent-brown); 
    font-family: 'Libre Caslon Text', Georgia, serif; 
    font-size: 1.2rem; text-align: center; 
    width: 300px; padding: 5px; outline: none; 
}

.close-modal { 
    position: absolute; top: 20px; right: 30px; 
    color: var(--accent-rot); font-size: 2rem; 
    font-weight: bold; cursor: pointer; z-index: 10; 
    text-decoration: none; transition: color 0.3s ease; 
}
.close-modal:hover { color: var(--accent-brown); }

.login-error-msg {
    display: none; color: var(--accent-rot);
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1rem; font-weight: bold;
    margin-top: var(--grid-half); text-align: center;
}

.login-info-text {
    font-family: 'Libre Caslon Text', Georgia, serif;
    color: var(--accent-brown); font-size: 1.1rem;
    margin-top: var(--grid-base); line-height: 1.6;
    text-align: center;
}

.login-submit-btn {
    margin-top: var(--grid-base); padding: 8px 30px;
    background-color: var(--accent-rot); color: var(--bg-base);
    border: none; font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1.1rem; text-transform: uppercase;
    letter-spacing: 0.15em; cursor: pointer;
    transition: opacity 0.3s ease; display: inline-block;
}
.login-submit-btn:hover { opacity: 0.8; }

/* Modal Mobil-Weiche */
@media (max-width: 768px) {
    .modal-content { 
        display: flex; flex-direction: column; 
        background-color: var(--bg-base); 
        border: 2px solid var(--accent-brown); 
    }
    .login-bg { position: relative; width: 100%; height: auto; object-fit: contain; z-index: 1; }
    .login-form-container { position: relative; padding: 10px 20px 30px 20px; z-index: 2; bottom: auto; }
    .close-modal { 
        background-color: var(--bg-base); border-radius: 50%; 
        width: 30px; height: 30px; line-height: 30px; 
        top: 10px; right: 10px; box-shadow: 0 0 5px rgba(0,0,0,0.2); 
    }
}

/* =========================================
   11. SPEZIAL-WAPPEN FÜR KALENDER/KURSE
   ========================================= */
.cal-emblem {
    height: 30px;
    width: auto;
    /* Oben 1,5 Rasterzeilen Abstand, unten eine halbe Rasterzeile */
    margin: calc(var(--grid-base) * 1.5) auto var(--grid-half) auto;
    display: block;
}

/* =========================================
   12. KALENDER-LISTEN ABSCHLUSS
   ========================================= */
/* Erzeugt den sauberen, dreizeiligen Abschluss-Abstand OHNE leere Spacer-Divs oder <br> */
.calendar-section-last {
    margin-bottom: calc(var(--grid-base) * 3);
}

/* =========================================
   TEXT-AUSRICHTUNG FÜR WISSENSTEXTE (FLAIR)
   ========================================= */
.text-justify {
    text-align: justify !important;
    hyphens: auto;
}

/* =========================================
   LISTEN MIT ET-ZEICHEN (BON TON GALANTE)
   ========================================= */
.et-list {
    list-style: none;
    padding: 0;
    max-width: 620px;
    margin: 0 auto var(--grid-half) auto;
}

.et-list-last {
    list-style: none;
    padding: 0;
    max-width: 620px;
    margin: 0 auto calc(var(--grid-base) * 3) auto;
}

.et-list li, .et-list-last li {
    position: relative;
    padding-left: 2.8rem;
    margin-bottom: var(--grid-half);
    text-align: justify;
    line-height: var(--grid-base);
    display: block;
    hyphens: auto;
}

/* =========================================
   LISTEN MIT ET-ZEICHEN (BON TON GALANTE)
   ========================================= */
.et-list li::before, .et-list-last li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.1rem;
    width: 1.8rem;
    height: 1.8rem;
    background-image: url('../images/et.webp'); /* <-- Pfad prüfen! Wenn das Bild nicht im /images Ordner über /css liegt, anpassen! */
    background-size: contain;
    background-repeat: no-repeat;
}

/* =========================================
   SIGNATUR-TEXT FÜR ABSCHLÜSSE
   ========================================= */
.signature-text {
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1.2rem;
    font-style: italic;
    color: var(--accent-brown);
}

/* =========================================
   12. MENÜ & SPEISEFOLGE
   ========================================= */
.menu-course {
    text-align: center;
    margin-bottom: var(--grid-base);
}

.menu-course p {
    font-family: 'Libre Caslon Text', Georgia, serif;
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--accent-brown);
    margin-bottom: var(--grid-half);
}

.menu-course p:last-child {
    margin-bottom: 0;
}

.menu-divider-img {
    display: block;
    /* Margin: Oben (vergrößert) | Rechts & Links (zentriert) | Unten (verringert) */
    margin: calc(var(--grid-base) * 2) auto calc(var(--grid-base) * 0.3) auto;
    width: 45px;
    height: auto;
}

/* =========================================
   14. WAPPEN & EMBLEME (ZENTRIERT)
   ========================================= */
.emblem-wrapper {
    max-width: 200px;
    margin: 0 auto var(--grid-base) auto;
    display: block;
    line-height: 0;
    position: relative; /* Assuréiert d'Stabilitéit */
}

/* Zéngt d'Biller an de Link sech exakt un d'Breet unzepassen */
.emblem-wrapper .logo-link {
    width: 100%;
    display: block;
}

