body {
    margin: 0;
    background-color: #000000;
    color: #ffffff;
    font-family: 'Archivo Black', sans-serif;
    text-transform: uppercase;
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* --- BARRA SUPERIOR --- */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background-color: #000;
    z-index: 10;
    border-bottom: 2px solid #333;
}

.back-btn {
    text-decoration: none;
    color: white;
    font-size: 1rem;
    border: 2px solid white;
    padding: 5px 10px;
    transition: all 0.2s;
}

.back-btn:active {
    background-color: white;
    color: black;
}

.counter {
    font-size: 1.2rem;
    letter-spacing: 2px;
}

/* --- CONTENEDOR DEL CARROUSEL --- */
.carousel-container {
    flex-grow: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    padding-bottom: 10%;
    background-color: #111;
}

/* --- LAS DIAPOSITIVAS (SLIDES) --- */
.slide {
    display: none;
    width: 100%;
    height: 100%;
    position: relative;
    animation: fadeEffect 0.5s;
}

.slide.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.slide img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    box-shadow: 0 0 20px rgba(0,0,0,0.8);
}

.caption {
    position: absolute;
    bottom: 40px;
    left: 20px;
    background-color: white;
    color: black;
    padding: 5px 15px;
    font-size: 1.5rem;
    pointer-events: none;
}

/* --- BOTONES DE FLECHA --- */
.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 2rem;
    padding: 20px;
    cursor: pointer;
    user-select: none;
    transition: background 0.3s;
    z-index: 5;
}

.nav-arrow:active {
    background-color: white;
    color: black;
}

.prev { left: 0; }
.next { right: 0; }

@keyframes fadeEffect {
    from {opacity: 0.4} 
    to {opacity: 1}
}

/* --- RESPONSIVE ESCRITORIO --- */
@media (min-width: 768px) {
    .slide img {
        max-height: 85vh;
        max-width: 80%;
        cursor: zoom-in; /* Indica que la imagen es clickeable */
    }
    .nav-arrow {
        background-color: transparent;
        font-size: 4rem;
    }
    .nav-arrow:hover {
        color: #FF0000;
    }
}

/* ─────────────────────────────────────────
   LIGHTBOX — Solo visible en escritorio
───────────────────────────────────────── */
#lightbox {
    display: none; /* Oculto por defecto */
    position: fixed;
    inset: 0; /* top/right/bottom/left: 0 */
    background-color: rgba(0, 0, 0, 0.92);
    z-index: 100;
    justify-content: center;
    align-items: center;
    cursor: zoom-out;
}

#lightbox.active {
    display: none; /* En móvil nunca se muestra */
}

/* Solo en escritorio activamos el lightbox */
@media (min-width: 768px) {
    #lightbox.active {
        display: flex;
        animation: fadeEffect 0.3s;
    }
}

#lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    box-shadow: 0 0 60px rgba(0,0,0,0.9);
    cursor: default;
}

/* Botón cerrar */
#lightbox-close {
    position: fixed;
    top: 20px;
    right: 25px;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    font-family: 'Archivo Black', sans-serif;
    line-height: 1;
    transition: color 0.2s;
    z-index: 101;
}

#lightbox-close:hover {
    color: #FF0000;
}
