/* Conteneur principal du carousel 2 */
.carousel-2-container {
    position: relative;
    width: 100%;
    max-width: 1920px; /* Largeur maximale du carousel */
    margin: 20px auto;
    overflow: hidden; /* Cache les éléments hors de la zone visible */
}

/* Conteneur des éléments du carousel 2 */
.carousel-2 {
    display: flex; /* Disposition horizontale */
    transition: transform 0.3s ease;
}

/* Chaque image */
.carousel-2-item {
    margin-right: 5px; /* Espacement entre les images */
    flex-shrink: 0; /* Empêche l'image de rétrécir */
}

/* Images du carousel 2 */
.carousel-2-item img {
    width: 100%; /* L'image prend toute la largeur disponible */
    max-width: 365px; /* Largeur maximale de l'image */
    height: 320px; /* Hauteur constante */
    object-fit: cover; /* Maintien du ratio et découpe l'image si nécessaire */
}

/* Flèches de navigation */
.arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px;
    font-size: 30px;
    cursor: pointer;
    z-index: 1;
}

/* Flèche précédente */
.prev {
    left: 10px;
}

/* Flèche suivante */
.next {
    right: 10px;
}

/* Désactiver les flèches quand on atteint le début ou la fin */
.arrow:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Responsivité */
@media screen and (max-width: 768px) {
    .carousel-2-container {
        width: 90%;
    }

    .carousel-2-item img {
        max-width: 300px;
        height: auto;
    }
}

@media screen and (max-width: 480px) {
    .carousel-2-container {
        width: 100%;
    }

    .carousel-2-item img {
        max-width: 250px;
    }

    .arrow {
        font-size: 24px;
        padding: 8px;
    }
}
