/* Contenedor principal */
.container {
    position: relative;
    margin-top: 195px;
    width: 100%;
    max-width: 1920px;
    height: 700px;
}

/* Video */
video {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 1s ease;
    z-index: 1;
}

/* Contenedor de imágenes */
.imagenes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    transition: opacity 1s ease;
}

/* Carrusel de imágenes */
.carousel-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s ease, visibility 0s linear 1s;
    z-index: 15;
}

.carousel-item.visible {
    opacity: 1;
    visibility: visible;
    transition: opacity 1s ease, visibility 0s linear 0s;
}

/* Imagen dentro del carrusel */
.carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* BOTÓN "VER MÁS" */
.carousel-button {
    position: absolute;
    bottom: 50px; /* Posición desde la parte inferior del carrusel */
    left: 50%;
    transform: translateX(-50%); /* Centrar horizontalmente */
    padding: 15px 30px;
    background-color: #787878;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    z-index: 100; /* El botón debe estar por encima de todo */
    transition: background-color 0.3s ease, transform 0.3s ease;
    pointer-events: auto;
}

.carousel-button:hover {
    background-color: #f90042;
}

/* CONTROLES DE CARRUSEL (FLECHAS) */
.carousel-controls {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 50;
    transform: translateY(-50%);
}

.carousel-prev, .carousel-next {
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 36px;
    border: none;
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 30;
    transition: background-color 0.3s ease;
}

.carousel-prev:hover, .carousel-next:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.carousel-prev {
    left: 5%;
}

.carousel-next {
    right: 5%;
}

/* RESPONSIVIDAD */
@media (max-width: 1920px) {
    .container {
        width: 100%;
        height: calc(100vw * (700 / 1920));
    }

    .carousel-button {
        font-size: 16px; /* Ajustar tamaño del texto en el botón */
        padding: 12px 24px; /* Botón más compacto */
    }

    .carousel-prev, .carousel-next {
        font-size: 30px;
        padding: 8px;
    }
}

@media (max-width: 768px) {
    .container {
        height: 300px;
    }

    .carousel-button {
        font-size: 14px;
        padding: 10px 20px;
        bottom: 20px; /* Ajustar posición para pantallas pequeñas */
    }

    .carousel-prev, .carousel-next {
        font-size: 24px;
        padding: 6px;
    }
}
