/* ============================= */
/* CARROUSEL                     */
/* ============================= */

.carousel {
    position: relative;
    width: 70%;
    max-width: 100%;
    margin: 0 auto;
}

/* Zone des photos */

.carousel-viewport {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 10px 10px 0 0;
}

.carousel-images {
    display: flex;
    width: 100%;
    max-width: 100%;
}

.carousel-slide {
    position: relative;
    flex: 0 0 100%;
    width: 100%;
    min-width: 0;
    max-width: 100%;
}

.carousel-slide img {
    display: block;
    width: 100%;
    height: clamp(300px, 35vw, 650px);
    object-fit: contain;
    background-color: white;
}

/* ============================= */
/* FLECHES DE NAVIGATION         */
/* ============================= */

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;

    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: white;

    font-size: 25px;
    padding: 12px;

    cursor: pointer;
    border-radius: 5px;
}

.carousel-btn.prev {
    left: 10px;
}

.carousel-btn.next {
    right: 10px;
}

/* ============================= */
/* LEGENDE SOUS LA PHOTO         */
/* ============================= */

.carousel-caption {
    position: relative;
    display: block;

    width: 100%;
    min-height: 20px;
    box-sizing: border-box;

    padding: 5px;

    color: #333;
    background: #f0f0f0;
    border-radius: 0 0 10px 10px;
    text-align: center;
}

/* ============================= */
/* POINTS DE NAVIGATION          */
/* ============================= */

.carousel-dots {
    position: relative;

    width: 100%;

    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;

    padding: 5px 0;

    background: #f0f0f0;

}

.carousel-dots button {
    width: 12px;
    height: 12px;

    padding: 0;
    border: none;
    border-radius: 50%;

    background: #999;
    opacity: 0.5;

    cursor: pointer;
}

.carousel-dots button.active {
    opacity: 1;
    background: #333;
}

/* ============================= */
/* MOBILE ET TABLETTE            */
/* ============================= */

@media screen and (max-width: 768px) {

    .carousel {
        width: 100%;
    }

    .carousel-slide img {
        height: clamp(200px, 55vw, 400px);
    }

    .carousel-caption {
        font-size: 14px;
    }

}
