/* Carousel Styles */
.carousel-block {
    position: relative;
    width: 100%;
    margin: 0 auto 64px auto;
    overflow: hidden;

    border-radius: 18px;
    min-height: 350px !important;
    max-width: 1300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-frame-link {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

.carousel-frame {
    display: flex;
    flex-direction: row;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

.carousel-frame-col1 {
    flex: 0 0 38%; /* Golden cut: ~38% */
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
}
.carousel-frame-image {
    max-height:100%;
    border-radius: 12px;

    object-fit: contain;

}

.carousel-frame-col2 {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 0 24px;
}
.carousel-frame-headline {
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    text-align: center;
    margin-bottom: 18px;
    animation: bigheadlineFadeIn 2.2s ease-in forwards;
}
.carousel-frame-byline {
    font-size: 1.2rem;
    color: #bbb;
    text-align: center;
}

/* Fade transitions */
.carousel-fade-in {
    animation: carouselFadeIn 0.6s;
}
.carousel-fade-out {
    animation: carouselFadeOut 0.6s;
}
@keyframes carouselFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes carouselFadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* Height logic for desktop */
@media (min-width: 992px) {
    .carousel-block {
        height: min(calc(50vh - 30px), 700px);
        min-height: 320px;
    }
}

/* Mobile layout: image on top, text below */
@media (max-width: 992px) {
    .carousel-block {
        width:100%;
        height: calc(80vh - 40px);
        min-height: 220px;
        max-height: 1000px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .carousel-frame {
        flex-direction: column;
        height: 100%;
        min-height: 320px;
        align-items: center;
        justify-content: center;
        padding-top:50px;
        padding-bottom:100px;
    }
    .carousel-frame-col1 {
        width: 100%;
        height: 70%; /* Golden cut: ~62% of height */
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .carousel-frame-image {
        height: 100%;

        margin: 0 auto;
        display: block;
    }
    .carousel-frame-col2 {
        width: 100%;

        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 24px 12px;
    }
    .carousel-frame-headline {
        font-size: 2rem;
        margin-bottom: 10px;
        animation: bigheadlineFadeIn 2.2s ease-in forwards;
    }
    .carousel-frame-byline {
        font-size: 1.5rem;
    }



}
