/**
* Block Name: custom_gallery
*/
body:has(* > section.custom_gallery) {
    overflow-y: hidden;
}

main:has(section.custom_gallery) {
    margin-top: 0;
}

section.custom_gallery {
    overflow: hidden;
    height: 100vh;
    min-height: 700px;
    padding: 100px 0;
}

/* CLOSE BUTTON */
section.custom_gallery .custom_gallery-close {
    position: fixed;
    top: 70px;
    right: 30px;
    z-index: 9999;
    width: 40px;
    height: 40px;
    background: #ffffffab;border-radius: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease-in-out, transform 200ms ease-in-out, box-shadow 200ms ease-in-out;
}

section.custom_gallery .custom_gallery-close.is-visible {
    opacity: 1;
    pointer-events: auto;
}

section.custom_gallery .custom_gallery-close:hover {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

section.custom_gallery .custom_gallery-close:hover svg path {
    fill: black;
}

section.custom_gallery .custom_gallery-close:hover svg circle {
    stroke: black;
}

section.custom_gallery .custom_gallery-close svg {
    display: block;
}

section.custom_gallery #btn_next_scroll {
    gap: 8px;
}

section.custom_gallery #btn_next_scroll:hover {
    cursor: pointer;
}

section.custom_gallery #btn_next_scroll svg {
    transition: transform 200ms ease-in;
}

section.custom_gallery #btn_next_scroll:hover svg,
section.custom_gallery .btn-primary:hover svg.internal,
section.custom_gallery .btn-primary:hover svg.external {
    transform: translateX(5px);

}

section.custom_gallery .btn-primary:hover svg.external {
    transform: translateX(3px) translateY(-2px);
}

section.custom_gallery .swiper-container {
    overflow: initial;
    height: 100%;
}

section.custom_gallery .swiper-slide .content {
    height: 100%;
    margin: 0 100px;
    width: 30vw;
    min-width: 300px;
}

section.custom_gallery .swiper-slide .thumb {
    height: 100%;
    width: 100%;
    min-width: 450px;
}

section.custom_gallery .facts {
    width: 45vw;
    min-width: 300px;
    max-width: 450px;
    margin-right: 100px;
}

section.custom_gallery .swiper-slide.layout-vier_bilder {
    min-width: 450px;
}

section.custom_gallery .swiper-slide.layout-vier_bilder {
    max-width: 100vw;
}

section.custom_gallery .swiper-slide.layout-vier_bilder .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 100px;
    height: 100%;
}

section.custom_gallery .swiper-slide.layout-vier_bilder .grid .grid-item {
    overflow: hidden;
}

section.custom_gallery .swiper-slide.layout-vier_bilder .grid .grid-item img {
    aspect-ratio: 3/2;
}

section.custom_gallery .teaser {
    height: 100%;
    width: 30vw;
    padding: 100px;
}

@media (min-width: 768px) {
    section.custom_gallery .swiper-wrapper.mousewheel {
        transition-duration: 0.4s !important;
    }

    section.custom_gallery .swiper-slide {
        width: auto;
    }
}

@media (max-width: 990px) {
    section.custom_gallery .js_mobile_detect {
        display: none;
    }

    section.custom_gallery {
        padding-bottom: 0;
        padding-top: 50px;
    }

    section.custom_gallery .btn-primary {
        margin-bottom: 50px;
    }

    section.custom_gallery h1 {
        margin-bottom: 0;
    }

    section.custom_gallery .swiper-slide {
        width: 100%;
        min-width: unset;
        max-width: unset;
        margin: 0;
        height: auto;
    }

    section.custom_gallery .swiper-slide>* {
        width: 100%;
        min-width: unset;
        max-width: unset;
        margin: 0;
    }

    section.custom_gallery .facts,
    section.custom_gallery .swiper-slide.layout-vier_bilder {
        margin-left: 0;
        margin-bottom: 50px;
        max-width: none;
        height: auto;
    }

    section.custom_gallery .swiper-slide.layout-vier_bilder .grid {
        display: flex;
        flex-direction: column;
        gap: 50px;
    }

    section.custom_gallery .swiper-slide .content {
        padding-top: 0;
        padding-bottom: 0;
        padding-left: 30px;
        padding-right: 30px;
        margin: 0;
        width: 100vw;
    }

    section.custom_gallery .facts {
        padding: 0 30px;
        margin-bottom: 0;
    }

    section.custom_gallery .teaser {
        padding: 30px;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 30px;
    }

    section.custom_gallery .teaser .btn-primary {
        margin-bottom: 0;
    }
}
