/* ===================================== 
   YOUTUBE LIGHTBOX MODAL STYLES
   ===================================== */

/* Lightbox Overlay */
.youtube-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.youtube-lightbox.active {
    background-color: rgba(0, 0, 0, 0.95);
}

/* Lightbox Content Container */
.youtube-lightbox-content {
    position: relative;
    width: 90%;
    max-width: 1200px;
    cursor: default;
}

/* Video Container */
.youtube-lightbox-video {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    background-color: #000;
}

.youtube-lightbox-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Close Button */
.youtube-lightbox-close {
    position: absolute;
    top: -50px;
    right: -10px;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 40px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s ease;
    padding: 0;
    z-index: 10000;
}

.youtube-lightbox-close:hover {
    opacity: 1;
}

/* Mobile Anpassungen */
@media screen and (max-width: 768px) {
    .youtube-lightbox-content {
        width: 95%;
    }
    
    .youtube-lightbox-close {
        top: -40px;
        right: 0;
        font-size: 35px;
        width: 35px;
        height: 35px;
    }
}

/* ===================================== 
   YOUTUBE VIDEO POSITION FIX
   Diese Datei MUSS NACH main.css eingebunden werden!
   ===================================== */

/* FIX 1: Hero-Bereich - Video neben Text */
.s-hero .hero-video-container {
    position: relative !important;  /* Ãœberschreibt absolute */
    right: auto !important;         /* Entfernt right: 3rem */
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    padding-bottom: 0 !important;    /* Entfernt padding-bottom: 220px */
    background-color: transparent !important; /* Entfernt Magenta */
    margin-top: 0 !important;        /* Video ganz oben */
    padding-top: 0 !important;       /* Kein Padding oben */
}

/* Wrapper fÃ¼r Aspect Ratio 16:9 */
.s-hero .hero-video-container::before {
    content: "";
    display: block;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
}

.s-hero .hero-video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* FIX 2: About-Bereich - Video neben Text */
.s-about .hero-video-container {
    position: relative !important;  /* Ãœberschreibt absolute */
    right: auto !important;         /* Entfernt right: 3rem */
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    padding-bottom: 0 !important;
    background-color: transparent !important;
    margin-top: 0 !important;        /* Video ganz oben */
    padding-top: 0 !important;       /* Kein Padding oben */
}

/* About Section spezifisch - Video oben ausrichten */
.s-about .column.large-half:last-child {
    align-self: flex-start !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* Wrapper fÃ¼r Aspect Ratio 16:9 */
.s-about .hero-video-container::before {
    content: "";
    display: block;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
}

.s-about .hero-video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* FIX 3: Stelle sicher dass Flexbox funktioniert */
.hero-content__inner {
    display: flex !important;
    align-items: flex-start !important;  /* Videos oben ausrichten */
    gap: 3rem !important;
}

/* Text links - 60% Breite */
.hero-content__inner .column.large-half:first-child {
    flex: 0 0 60% !important;
}

/* Video rechts - 40% Breite */
.hero-content__inner .column.large-half:last-child {
    flex: 0 0 40% !important;
    align-self: flex-start !important;  /* Video ganz oben im Container */
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* About Content auch Flexbox */
.s-about .about-content {
    display: flex !important;
    align-items: flex-start !important;  /* Auch hier oben ausrichten statt center */
    gap: 3rem !important;
}

/* Hero Video und Buttons rechts */
.hero-right-section {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.hero-content__inner {
    display: flex;
    gap: 4rem;
    align-items: flex-start;
}

.hero-content__inner .large-7 {
    flex: 0 0 60%;
}

.hero-content__inner .large-5 {
    flex: 0 0 40%;
}

/* Video Container Anpassungen */
.hero-video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    background-color: #000;
    overflow: hidden;
    margin-bottom: 2rem;
}

.youtube-thumbnail-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.youtube-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.youtube-play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 48px;
    transition: transform 0.2s;
}

.youtube-thumbnail-wrapper:hover .youtube-play-button {
    transform: translate(-50%, -50%) scale(1.1);
}

/* Buttons unter dem Video */
.hero-right-section .hero-content__buttons {
    position: static;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
}

.hero-right-section .hero-content__buttons .bttn {
    width: 100%;
    margin: 0;
}

/* Responsive anpassen */
@media screen and (max-width: 1200px) {
    .hero-content__inner {
        flex-direction: column;
    }

    .hero-content__buttons .bttn {
        display: none;
    }

    .hero-video-container {  
        display: block!important;
    }
    
    .hero-content__inner .large-7,
    .hero-content__inner .large-5 {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    /* Original Buttons wieder anzeigen */
    .hero-content__buttons_more {
        display: block;
    }
}

.s-about .column.large-half:first-child {
    flex: 0 0 60% !important;
}

.s-about .column.large-half:last-child {
    flex: 0 0 40% !important;
}

