/* =========================================
   1. FARBEN, VARIABLEN & GRUNDEINSTELLUNGEN
   ========================================= */
:root {
    --color-green: #8dc63f;  /* Haupt-Grün */
    --color-dark: #202020;   /* Haupt-Dunkelgrau */
    --color-text: #64676B;   /* Text-Farbe */
    --color-bg-dark: #1a1a1a;/* Navigation Hintergrund */
}

/* Box-Sizing fixiert das Padding-Verhalten für alle Elemente */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: auto; /* Wir nutzen unser eigenes JavaScript-Scrolling */
}

/* =========================================
   2. TYPOGRAFIE & TEXT-FORMATIERUNG
   ========================================= */
body {
    overflow-x: hidden; /* Verhindert das seitliche Scrollen/Wackeln auf dem Handy */
    width: 100%;
    position: relative;
    margin: 0;
    padding: 0;
    font-family: 'Open Sans', sans-serif;
    font-size: 15px;
    line-height: 30px; 
    font-weight: 400;
    color: var(--color-text);
    background-color: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Überschriften Formate */
h1, h3 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-dark);
    margin: 0;
}

h2 {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-dark);
    margin: 0;
}

h4 {
    font-size: 4rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-dark);
    margin: 0;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* =========================================
   3. NAVIGATION (OBEN)
   ========================================= */
#main-nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    padding: 1.5rem 0;
}

.nav-inner {
    display: flex;
    justify-content: flex-end; 
    align-items: center;
}

.desktop-menu {
    display: none; /* Auf kleinen Bildschirmen unsichtbar */
}

.desktop-menu a {
    color: #d1d5db; 
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin: 0 1rem;
}

.desktop-menu a:hover {
    color: #fff;
}

.desktop-menu a.active {
    color: var(--color-green) !important;
}

.burger-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.875rem;
    cursor: pointer;
    transition: color 0.3s;
}

.burger-btn.dark-icon {
    color: var(--color-dark);
}

/* Mobiles Ausklapp-Menü */
#mobile-menu {
    background-color: var(--color-dark);
    width: 100%;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
    position: absolute;
    top: 100%;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

#mobile-menu.open {
    max-height: 500px;
}

#mobile-menu a {
    color: #d1d5db;
    padding: 0.5rem 0;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

@media (min-width: 768px) {
    .nav-inner {
        justify-content: center;
    }
    .burger-btn {
        display: none; /* Burger Button auf Desktop verstecken */
    }
    .desktop-menu {
        display: flex; /* Desktop Menü auf Desktop zeigen */
    }
    .nav-scrolled {
        background-color: #1a1a1a !important; /* Dunkler Balken beim Scrollen */
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        padding-top: 1rem !important;
        padding-bottom: 1rem !important;
    }
}

/* =========================================
   4. HERO SECTION (STARTBILDSCHIRM)
   ========================================= */
#home {
    min-height: 100vh; /* Nimmt die ganze Bildschirmhöhe ein */
    width: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-image: url('Bilder/Header/Bild02_V3.png');
    background-size: cover;
    background-position: center bottom;
    color: #fff;
    padding: 3rem 1rem 3rem 1rem;
}

.hero-logo-wrapper {
    margin-bottom: 1.5rem;
    transform: scale(0.75);
    transition: transform 0.5s;
}

.hero-logo-wrapper:hover {
    transform: scale(0.8); /* Leichter Zoom Effekt beim Hover */
}

#home h2 {
    font-size: 1.875rem; 
    font-weight: 700;
    margin: 0rem ;
    color: #fff;
}

.hero-subtitle {
    font-size: 1rem;
    font-weight: 300;
    margin-top: 1rem;
    color: #d1d5db;
}

.hero-footer {
    font-size: 0.75rem;
    margin-top: 2rem;
    color: #9ca3af;
}

/* Der wackelnde Pfeil, der nach unten zeigt */
.scroll-arrow {
    position: absolute;
    bottom: 2.5rem;
    font-size: 1.875rem;
    color: #fff;
    animation: bounce 2s infinite;
}

/* Keyframes erzeugen die Animation (das Springen) */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-10px);}
    60% {transform: translateY(-5px);}
}

@media (min-width: 768px) {
    .hero-logo-wrapper { transform: scale(0.7); }
    .hero-logo-wrapper:hover { transform: scale(0.75); }
    #home h2 { font-size: 5rem; line-height: 1; margin-bottom: 4rem;}
    .hero-subtitle { font-size: 1.25rem; }
}

/* =========================================
   5. LAYOUT & ABSCHNITTE (SECTIONS) ALLGEMEIN
   ========================================= */
section {
    padding: 4rem 1.5rem; /* Abstand auf dem Handy */
}

@media (min-width: 768px) {
    section { padding: 6rem 8rem; } /* Abstand Desktop */
}

@media (min-width: 1024px) {
    section { padding: 6rem 16rem; } /* Abstand große Bildschirme */
}

.content-wrapper {
    max-width: 56rem; /* Breite des Textes beschränken (ca. 900px) */
    margin: 0 auto;
}

.grid-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

@media (min-width: 768px) {
    .grid-layout {
        grid-template-columns: 1fr 3fr; /* Text-Layout: Links 1/4, Rechts 3/4 */
    }
}

/* Der grüne Strich unter den Titeln links */
.sidebar-title {
    color: var(--color-dark);
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-bottom: 2px solid var(--color-green);
    display: inline-block;
    padding-bottom: 5px;
    margin-bottom: 2rem;
}

.logo-placeholder {
    width: 100%;
    max-width: 200px;
    height: auto;
    margin-top: 1rem;
}

.section-heading {
    font-size: 1.5rem;
    margin-bottom: 1.5rem; 
    color: var(--color-dark);
}

.section-heading-sm {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--color-dark);
}

.text-block {
    margin-bottom: 2rem; 
}

.text-bold-small {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 2rem;
}

hr {
    border: 0;
    border-top: 1px solid #f3f4f6;
    margin: 0;
}

.separator {
    border-top: 1px solid #e5e7eb; /* Feine Trennlinie in den Sektionen */
    margin: 3rem 0;
}

/* =========================================
   6. NACHT AM WESTRING (DARK SECTION)
   ========================================= */
#nacht-am-westring {
    background-color: var(--color-dark);
    color: #fff;
}

.naw-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.naw-text-content {
    text-align: left;
    flex-grow: 1;
}

/* Erzwingt weiße Farbe für Texte in der dunklen Section */
.naw-text-content h3, 
.naw-text-content p, 
.naw-text-content div {
    color: #fff; 
}

@media (min-width: 768px) {
    .naw-container {
        flex-direction: row;
        align-items: flex-start;
    }
}

/* =========================================
   7. AUSBILDUNGSBERUFE
   ========================================= */
.table {
    width: 100%;
    padding: 0.5rem;
}

/* =========================================
   8. MEDIA / GALERIE
   ========================================= */
#media {
    background-color: #f3f4f6;
}

.media-title {
    text-align: center;
    font-size: 1.125rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #9ca3af;
    letter-spacing: 0.1em;
    margin-bottom: 3rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* 2 Spalten auf dem Handy */
    gap: 1rem;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(4, 1fr); /* 4 Spalten auf dem Desktop */
    }
}

.gallery-item {
    aspect-ratio: 1 / 1; /* Macht Bilder immer exakt quadratisch */
    background-color: #d1d5db;
    overflow: hidden;
    position: relative;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s; /* Sanfter Zoom */
}

.gallery-item:hover img.zoomable {
    transform: scale(1.1); /* Zoomt das Bild beim drüberfahren */
}

/* Zentrierter Video Block unten */
.center-video-container {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.center-video {
    width: 50%;
    aspect-ratio: 1/1;
    background-color: #d1d5db;
    position: relative;
    overflow: hidden;
}

@media (min-width: 768px) {
    .center-video { width: 25%; } /* Auf Desktop kleiner */
}

/* =========================================
   9. FOOTER & KONTAKT
   ========================================= */
footer {
    background-color: var(--color-dark);
    color: #fff;
    padding: 2rem 0;
    position: relative;
    text-align: center;
}

/* Pfeil-Button nach ganz oben */
.scroll-top-btn {
    position: absolute;
    top: -1.25rem; /* Sitzt halb auf dem Rand */
    left: 50%;
    transform: translateX(-50%);
    background-color: #4b5563;
    border-radius: 9999px;
    padding: 0.5rem;
    cursor: pointer;
    transition: background-color 0.3s;
    display: block;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scroll-top-btn:hover {
    background-color: #6b7280;
}

.footer-links a {
    font-size: 0.75rem;
    color: #6b7280;
    margin: 0 0.5rem;
}

.footer-links a:hover {
    color: #fff;
}

.footer-copy {
    font-size: 0.625rem;
    color: #4b5563;
    margin-top: 0.5rem;
}

.contact-link {
    color: var(--color-green);
    display: block;
}

.contact-link:hover { text-decoration: underline; }

.social-icons {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    font-size: 1.5rem;
    color: var(--color-green);
}

/* =========================================
   10. VIDEO HIGHLIGHT (BREAKOUT)
   ========================================= */
.video-highlight-wrapper {
    max-width: 70rem; /* Bricht aus dem normalen 56rem Layout aus, wird also breiter! */
    margin: 0 auto;
}

.video-highlight-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center; /* Zentriert Text und Video vertikal auf eine Höhe */
}

@media (min-width: 768px) {
    .video-highlight-grid {
        grid-template-columns: 2fr 3fr; /* Text bekommt 2 Teile, Video 3 Teile */
        gap: 5rem; 
    }
}

.video-player-container {
    width: 100%;
    background-color: #000;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15); /* Gibt dem Video einen eleganten Schatten */
    overflow: hidden;
    border-radius: 8px; /* Leicht abgerundete Ecken */
}

@media (min-width: 1024px) {
    .video-player-container {
        width: 110%; /* Macht das Video auf dem Desktop absichtlich breiter (Breakout-Effekt) */
    }
}

.video-player-container video {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    display: block;
    object-fit: contain;
    background-color: #000;
}

/* =========================================
   11. KACHELN FÜR DIE VIDEOS (MEDIA TAB)
   ========================================= */
.yt-kachel, .local-kachel {
    aspect-ratio: 1 / 1;
    background-color: #d1d5db;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.yt-kachel img, .local-kachel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-in-out;
}

/* Das Vorschaubild zoomt leicht heran, wenn man hovert */
.yt-kachel:hover img, .local-kachel:hover img {
    transform: scale(1.1);
}

/* Das Play-Symbol, das über der Kachel liegt */
.yt-play-overlay, .local-play-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    
    /* GANZ WICHTIG: Komplett Transparent, dunkelt das Bild nicht mehr pauschal ab! */
    background-color: rgba(0, 0, 0, 0); 
    transition: background-color 0.3s ease;
}

/* Erst beim drüberfahren (Hover) wird das Bild leicht abgedunkelt, um Fokus auf Play zu legen */
.yt-kachel:hover .yt-play-overlay, .local-kachel:hover .local-play-overlay {
    background-color: rgba(0, 0, 0, 0.4);
}

/* Das Icon selbst (Der weiße Pfeil/Kreis) */
.yt-play-overlay i, .local-play-overlay i {
    color: #ffffff;
    font-size: 3rem;
    opacity: 0.9;
    transition: transform 0.3s ease;
    
    /* Schlagschatten eingefügt: Falls das Hintergrundbild extrem hell/weiß ist, bleibt der Button trotzdem erkennbar! */
    text-shadow: 0 4px 8px rgba(0,0,0,0.6);
}

.yt-kachel:hover .yt-play-overlay i, .local-kachel:hover .local-play-overlay i {
    transform: scale(1.15); /* Icon wird beim Hover minimal größer */
}

/* =========================================
   12. LIGHTBOX MODALS (POP-UP FENSTER FÜR VIDEOS)
   ========================================= */
/* Der abgedunkelte Hintergrund hinter dem Pop-Up */
.yt-lightbox, .local-lightbox {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.85); /* 85% Schwarz */
    z-index: 9999; /* Garantiert, dass es GANZ OBEN über allem anderen liegt */
}

.yt-lightbox-wrapper, .local-lightbox-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    padding: 1rem;
    box-sizing: border-box;
}

/* Die Box, in der das Video/Der Text im Pop-up ist */
.yt-modal-container, .local-modal-container {
    width: 100%;
    max-width: 56rem; 
    background-color: #111111;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: relative;
    display: flex;
    flex-direction: column;
}

.local-modal-container video {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    display: block;
    object-fit: contain;
    background-color: #000000;
}

/* Datenschutz-Schirm für YouTube */
.yt-consent-view {
    width: 100%;
    min-height: 350px; 
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
    overflow: hidden;
    background-color: #000000;
}

@media (min-width: 768px) {
    .yt-consent-view {
        aspect-ratio: 16 / 9;
        min-height: auto;
    }
}

.yt-consent-thumb {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.4;
}

.yt-consent-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.yt-icon-youtube {
    color: #dc2626; 
    font-size: 3rem;
    margin-bottom: 1rem;
}

.yt-consent-title {
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    margin-top: 0;
}

.yt-consent-text {
    color: #d1d5db; 
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    max-width: 32rem;
    line-height: 1.6;
}

.yt-btn-group {
    display: flex;
    gap: 1rem;
    flex-direction: row;
}

@media (max-width: 640px) {
    .yt-btn-group { flex-direction: column; width: 100%; }
}

.yt-btn {
    padding: 0.75rem 1.5rem;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.yt-btn-cancel { background-color: #374151; }
.yt-btn-cancel:hover { background-color: #4b5563; }
.yt-btn-accept { background-color: #8dc63f; }
.yt-btn-accept:hover { background-color: #7ab030; }

.yt-player-view {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.yt-iframe-container {
    aspect-ratio: 16 / 9;
    width: 100%;
    position: relative;
    background-color: #000000;
}

.yt-iframe-container iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
}

.yt-bottom-bar {
    background-color: #111111;
    width: 100%;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    border-top: 1px solid #1f2937;
    box-sizing: border-box;
}

.yt-bar-link, .yt-bar-btn {
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: color 0.3s ease;
}

@media (max-width: 768px) {
    .yt-bar-link, .yt-bar-btn { font-size: 0.625rem; }
}

.yt-bar-link:hover { color: #8dc63f; }
.yt-bar-btn:hover { color: #9ca3af; }

/* Der kleine 'X' Button oben rechts, um Popups zu schließen */
.yt-btn-close-top, .local-btn-close-top {
    position: absolute;
    color: #ffffff;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 50;
    transition: color 0.3s ease;
    padding: 0.5rem;
}

.yt-btn-close-top {
    top: 1rem;
    right: 1rem;
}

.local-btn-close-top {
    top: -2.5rem;
    right: 0;
}

@media (min-width: 768px) {
    .local-btn-close-top {
        right: -2.5rem;
    }
}

.yt-btn-close-top:hover, .local-btn-close-top:hover { color: #9ca3af; }
.yt-btn-close-top i { font-size: 1.5rem; }
.local-btn-close-top i { font-size: 2rem; }