/* Horizontal/Vertical--------------------------*/
#horizontal-section {
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    position: relative;
}

#horizontal-scroll {
    display: flex;
    height: 100%;
    width: max-content;
}

@media (hover: hover) {
    .spacer-slide {
        display: none !important;
        width: 0 !important;
        flex: 0 0 0 !important;
    }
}

@media (pointer: coarse) and (hover: none) {
    #horizontal-section {
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
    }

    #horizontal-scroll {
        display: flex;
        width: max-content; /* oder calc(3 * 100vw) wenn du willst */
        overflow-x: auto;
        scroll-snap-type: x mandatory;
    }

    .slide {
        flex: 0 0 100vw;
        scroll-snap-align: start;
    }

    .big-text-slide {
        flex: 0 0 100vw;
        position: relative;
    }

    .big-text {
        position: absolute;
        left: 0;
        transform: none;
        padding-left: 5vw;
        padding-right: 5vw;
        white-space: nowrap;
        font-size: 14vw;
    }

    .spacer-slide {
        flex: 0 0 100vw;
    }

    .video-slide {
        flex: 0 0 100vw;
    }

    .video-wrapper {
        width: 100vw;
        height: 100vh;
        display: flex;
        justify-content: center;
        align-items: center;
        overflow: hidden;
        position: relative;
    }
}

@media (pointer: coarse) and (hover: none) and (min-width: 768px) {
    html.scroll-lock,
    body.scroll-lock {
        overflow: hidden !important;
        height: 100vh;
        touch-action: pan-x; /* nur horizontales Scrollen erlauben */
    }
}

html.scroll-lock,
body.scroll-lock {
    position: fixed;
    overflow: hidden !important;
    width: 100vw;
    height: 100vh;
    touch-action: pan-x;
}

@media (pointer: coarse) and (hover: none) {
    html.scroll-lock-mobile,
    body.scroll-lock-mobile {
        position: fixed;
        overflow: hidden !important;
        width: 100vw;
        height: 100vh;
        touch-action: pan-x; /* horizontal okay */
    }
}

.slide {
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

    .slide.big-text-slide {
        width: auto; /* passt sich Inhalt an */
        min-width: calc(100vw + 40vw); /* z. B. extra Puffer, je nach Schriftbreite */
    }

    .slide.video-slide {
        width: 100vw;
        height: 100vh;
    }

.big-text {
    font-size: clamp(120px, 32vw, 620pt);
    font-weight: bold;
    white-space: nowrap;
    color: white;
    transform: translateX(0);
    padding: 0 10vw 0 2vw;
}

#vertical-section {
    min-height: auto;
    width: 100vw;
    padding: 2rem 2rem 0 2rem;
}

#vertical-lock-container.locked {
    display: none;
}

#vertical-lock-container {
    display: block;
}


/* Image row -------------------------------------*/
.image-row-wrapper {
    margin-top: 5rem;
    width: 100%;
    display: flex;
    justify-content: center;
}

.image-row {
    display: flex;
    gap: 45px;
    width: min(90vw, 1800px);
    box-sizing: border-box;
}

.image-box {
    flex: 1 1 calc((100% - 2 * 45px) / 3);
    min-width: 200px;
    height: auto;
    object-fit: cover;
    border-radius: 20px;
}

.middle-image {
    display: block;
    transform-origin: center center;
    transition: all 0.5s ease;
    z-index: 10;
}

.middle-image--fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    transform-origin: center center;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: 999;
    border-radius: 0;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.3);
}

.scroll-spacer {
    width: 100%;
    height: 0;
    transition: height 0.3s ease;
}

.image-row .image-box {
    cursor: zoom-in;
}

/* tile-section -----------------------------------------*/
.tile-section-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 20rem;
}

.tile-section {
    display: flex;
    justify-content: center;
}

    .tile-section .row {
        display: flex;
        flex-wrap: nowrap;
        gap: 40px;
        width: min(60vw, 1500px);
        min-width: 720px;
        margin: 0 auto;
        box-sizing: border-box;
    }

.container {
    flex: 1 1 calc((100% - 2 * 40px) / 3);
    min-width: 200px;
    max-width: none;
    height: auto;
    border: 3px solid white;
    border-radius: 10px;
    overflow: hidden;
    background: var(--theim-black);
    position: relative;
    margin: 0;
    opacity: 0;
    transform: translateY(100px);
}

.tile-section svg {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    overflow: visible;
}

.tile-svg text {
    fill: white;
    opacity: 1;
    font-size: 2rem;
}

text {
    font-family: 'Roobert', sans-serif;
    font-size: 60px;
    font-weight: 700;
    fill: white;
    opacity: 0;
}

.container object {
    display: block;
    width: 100%;
    height: auto;
}

.container--snap-start {
    scroll-snap-align: start;
}

.container--snap-end {
    scroll-snap-align: end;
}

.tile-nav-dots {
    display: none;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.tile-dot {
    all: unset;
    width: 12px;
    height: 12px;
    aspect-ratio: 1;
    display: inline-block;
    border-radius: 50%;
    border: 2px solid white;
    background-color: transparent;
    cursor: pointer;
    transition: background-color 0.2s ease;
    flex-shrink: 0;
}

    .tile-dot.active,
    .tile-dot:hover {
        background-color: white;
    }

/* White Line -----------------------------------------*/
.white-line-wrapper {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
    position: relative;
    height: auto;
    min-height: 200px; /* Optionaler Startwert */
    display: flex;
    justify-content: center;
    align-items: center; /* Zentriert vertikal */
    flex-direction: column;
    overflow: visible;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-top: 2rem;
}

.white-line-bg {
    position: absolute;
    top: 0;
    left: 0;
    height: 2px;
    width: 100%;
    background: white;
    z-index: 0;
    transform-origin: top center;
    transform: scaleY(0);
}

.white-section-content {
    position: relative;
    transform: none;
    top: auto;
    left: auto;
    max-width: 75ch;
    padding: 0 2rem;
    color: black;
    text-align: left;
}

.white-headline {
    font-size: clamp(2rem, 3.2vw, 3.2rem);
    font-weight: bold;
    margin-bottom: 1.5rem;
    opacity: 0;
}

.white-subcontent {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

    .white-subcontent p {
        margin-bottom: 1.5rem;
        color: black;
    }

.white-arrow {
    display: inline-block;
    cursor: pointer;
    font-size: 3.5rem;
    text-decoration: none;
    color: var(--theim-red);
    transition: transform 0.2s ease;
}

    .white-arrow:hover {
        transform: translateX(8px);
    }

.white-line-trigger-anchor {
    height: 1px;
    margin-top: 10vh;
}

/* Video -----------------------------------------*/
.video-wrapper {
    position: relative;
    width: 100vw;
    height: 100vh;
}

    .video-wrapper video {
        width: 100%;
        height: 100%;
        opacity: 0;
        transition: opacity 0.5s ease;
        object-fit: cover;
        display: block;
    }

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

.play-button-custom {
    background: none;
    border: none;
    cursor: pointer;
    color: white;
    transition: transform 0.2s ease;
}

    .play-button-custom:hover {
        transform: scale(1.1);
        color: var(--theim-red);
    }

    .play-button-custom svg {
        width: 130px;
        height: 130px;
    }

/* Breakpoint 0: mittlere Desktops */
@media (max-width: 1400px) {
    .tile-section .row {
        gap: 40px;
        width: min(70vw, 1500px);
    }
    .tile-section-wrapper {
        margin-top: 17rem;
    }
}


/* Breakpoint 1: kleinere Desktops / große Tablets (≤1200px) */
@media (max-width: 1200px) {
    #vertical-section {
        padding-top: 1rem;
    }

    .big-text {
        padding: 0 10vw 0 15vw;
    }

    .play-button-custom svg {
        width: 110px;
        height: 110px;
    }

    .image-row {
        display: flex;
        gap: 25px;
        width: min(90vw, 1800px);
        box-sizing: border-box;
    }

    .tile-section-wrapper {
        margin-top: 15rem;
    }

    .tile-section .row {
        gap: 25px;
    }
}

@media (min-width: 992px) and (max-width: 1366px) {
    .slide.big-text-slide {
        min-width: 100vw;
    }
}

/* Breakpoint 2: Tablets quer (≤992px) */
@media (max-width: 992px) {
    #vertical-section {
        padding-top: 0;
    }

    .tile-section .row {
        width: min(80vw, 900px);
    }

    .white-arrow {
        font-size: 3rem;
    }

    .white-subcontent p {
        margin-bottom: 0.5rem;
    }
}


/* Breakpoint 3: Tablets hoch / große Smartphones (≤768px) */
@media (max-width: 768px) {

    .play-button-custom svg {
        width: 100px;
        height: 100px;
    }

    .image-row {
        flex-direction: column;
        width: 70vw;
        align-items: center;
    }

    .image-box {
        width: 90%;
        flex: none;
        min-width: unset;
        border-radius: 15px;
    }

    .tile-section-wrapper {
        width: 100vw;
        max-width: 100vw;
        margin-left: calc(-50vw + 50%);
        overflow: visible;
        margin-top: 10rem;
    }

    .tile-section {
        width: 100vw;
        max-width: 100vw;
        margin-left: calc(-50vw + 50%);
        overflow: visible;
    }

        .tile-section .row {
            display: flex;
            flex-wrap: nowrap;
            overflow-x: auto;
            overflow-y: hidden;
            -webkit-overflow-scrolling: touch;
            scroll-snap-type: x mandatory;
            scroll-padding-inline: 1.5rem;
            gap: 1.5rem;
            padding: 0;
            box-sizing: border-box;
            scrollbar-width: none;
            width: max-content;
            scroll-behavior: smooth;
        }

    .spacer-tile {
        flex: 0 0 1.5rem;
        scroll-snap-align: center;
        pointer-events: none;
    }

    .tile-section .row::before,
    .tile-section .row::after {
        content: '';
        display: block;
        flex: 0 0 1.5rem;
    }

    .container {
        flex: 0 0 40vw;
        width: 40vw;
        scroll-snap-align: none;
        background: none;
    }

    .tile-section .row::-webkit-scrollbar {
        display: none; /* Safari + Chrome */
    }

    .tile-nav-dots {
        display: flex;
        justify-content: center;
        gap: 1rem;
        margin-top: 1.5rem;
    }
}

/* Breakpoint 4: Smartphones (≤576px) */
@media (max-width: 576px) {

    .play-button-custom svg {
        width: 90px;
        height: 90px;
    }

    .image-row {
        width: 100vw;
    }

    .image-box {
        width: 100%;
        border-radius: 10px;
    }

    .tile-section .row {
        scroll-padding: 5rem;
        padding: 0 5rem;
    }
}

/* Breakpoint 5: sehr schmale Smartphones */
@media (max-width: 420px) {

    .play-button-custom svg {
        width: 80px;
        height: 80px;
    }

    .image-row-wrapper {
        width: 100vw;
        margin-left: calc(-1 * (100vw - 100%) / 2);
        display: flex;
        justify-content: center;
    }

    .image-row {
        width: auto;
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    .image-box {
        width: 85vw;
        max-width: 500px;
    }
}

@media (pointer: coarse) and (hover: none) {
    .container {
        border: none !important;
        border-radius: 0 !important;
        background: none;
    }
    .tile-section .container {
        opacity: 1 !important;
        transform: none !important;
    }
}
