/* ============================================================
   GALERIA-GALAXIA.CSS - CLEAN COMPONENT ARCHITECTURE
   ============================================================ */

.c7-gallery-wrapper {
    display: block !important;
    width: 100%;
    clear: both;
}

.c7-stack-gallery-zone {
    width: 100%;
    padding: 40px 0 100px 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.c7-stack-instruction-tag {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.1rem;
    letter-spacing: 3px;
    color: #11dbdb;
    margin-bottom: 30px;
    text-transform: uppercase;
}

/* CONTENEDOR DE LA PILA */
.c7-stack-container {
    position: relative !important;
    width: 100%;
    max-width: 850px;
    height: 500px;
    cursor: pointer;
    perspective: 1200px;
    z-index: 5;
}

/* CAPAS BASE */
.c7-stack-layer {
    position: absolute !important;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: #05070a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.8);
    transition: transform 0.45s cubic-bezier(0.165, 0.84, 0.44, 1), 
                filter 0.3s ease, 
                opacity 0.4s ease;
             
}

.c7-stack-layer img {
    width: 100%; height: 100%;
    object-fit: cover;
    pointer-events: none;
}

/* TEXTOS META DEL COMPONENTE */
.c7-stack-meta {
    position: absolute;
    bottom: 0; left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.95));
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
}

.c7-stack-meta strong {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.2rem;
    color: #fff;
    letter-spacing: 1px;
}

/* CONFIGURACIÓN TRIDIMENSIONAL SÓLIDA */
.c7-layer-front {
    transform: translate3d(0, 0, 0) scale(1);
    z-index: 3;
    opacity: 1;
    filter: grayscale(0%);
}

.c7-layer-mid {
    transform: translate3d(0, -20px, -40px) scale(0.95);
    z-index: 2;
    opacity: 0.8;
    filter: grayscale(100%) brightness(0.4);
}

.c7-layer-back {
    transform: translate3d(0, -40px, -80px) scale(0.90);
    z-index: 1;
    opacity: 0.4;
    filter: grayscale(100%) brightness(0.2);
}

.c7-layer-hidden {
    transform: translate3d(0, -40px, -80px) scale(0.90);
    z-index: 0;
    opacity: 0;
    pointer-events: none;
}

/* RETROALIMENTACIÓN VISUAL AL HACER CLIC (FEEDBACK MECÁNICO) */
.c7-stack-container:active .c7-layer-front {
    /* Se hunde ligeramente y se oscurece un poco en el instante del clic */
    transform: translate3d(0, 0, 0) scale(0.98);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.9);
    filter: brightness(0.9);
    transition: transform 0.05s ease, filter 0.05s ease, box-shadow 0.05s ease;
}

/* Opcional: Si extrañas el borde azul de enfoque clásico para confirmar la selección */
.c7-stack-container:focus {
    outline: 2px solid #11dbdb;
    outline-offset: 5px;
}


/* ANIMACIONES DE SALIDA (VOLAR) */
.c7-layer-dismissed-right {
    transform: translate3d(120%, 0, 30px) rotate(5deg) !important;
    opacity: 0 !important;
    z-index: 40 !important;
    
}

.c7-layer-dismissed-left {
    transform: translate3d(-120%, 0, 30px) rotate(-5deg) !important;
    opacity: 0 !important;
    z-index: 40 !important;
    
}

/* CELULARES */
@media (max-width: 768px) {
    .c7-stack-gallery-zone {
        padding: 18px 20px 80px;
        align-items: center;
        background:
            linear-gradient(180deg, transparent, rgba(85, 247, 255, 0.05) 46%, transparent 100%);
    }

    .c7-stack-instruction-tag {
        align-self: flex-start;
        max-width: 22rem;
        margin-bottom: 24px;
        padding-left: 12px;
        border-left: 2px solid #11dbdb;
        font-size: 1rem;
        line-height: 1.45;
        letter-spacing: 3px;
    }

    .c7-stack-container {
        width: 100%;
        height: clamp(260px, 64vw, 330px);
    }

    .c7-stack-layer {
        box-shadow: 0 22px 55px rgba(0, 0, 0, 0.86);
    }

    .c7-stack-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
        padding: 54px 18px 18px;
        background: linear-gradient(transparent, rgba(0, 0, 0, 0.92) 48%, rgba(0, 0, 0, 0.98));
    }

    .c7-stack-meta strong {
        font-size: 1.05rem;
    }

    .c7-layer-mid { transform: translate3d(0, -10px, -20px) scale(0.97); }
    .c7-layer-back { transform: translate3d(0, -20px, -40px) scale(0.94); }
}
