/* ══════════════════════════════════════════════
   ATYC · LIGHTBOX (componente genérico, sitewide)
   Cualquier elemento con [data-lightbox-src] lo abre.
   Requiere el markup de #at-lightbox (en footer.php)
   y el script lightbox.js. 
   
   Agregar 3 atributos a un elemento clicable:

   data-lightbox-src="url de la foto completa"
   data-lightbox-alt="texto alternativo"
   data-lightbox-caption="descripción opcional"
   ══════════════════════════════════════════════ */

[data-lightbox-src] {
    cursor: zoom-in;
}

.at-lightbox {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(11, 9, 7, 0.94);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.at-lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.at-lightbox-img {
    max-width: 88vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.at-lightbox-caption {
    position: absolute;
    bottom: 2.25rem;
    left: 0;
    right: 0;
    text-align: center;
    font-family: "Jost", sans-serif;
    font-size: 13px;
    color: rgba(245, 239, 227, 0.85);
    padding: 0 4rem;
}

.at-lightbox-close,
.at-lightbox-prev,
.at-lightbox-next {
    position: absolute;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #f5efe3;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 250ms ease;
}

.at-lightbox-close:hover,
.at-lightbox-prev:hover,
.at-lightbox-next:hover {
    background: rgba(255, 255, 255, 0.18);
}

.at-lightbox-close { top: 1.5rem; right: 1.5rem; }
.at-lightbox-prev { left: 1.5rem; top: 50%; transform: translateY(-50%); }
.at-lightbox-next { right: 1.5rem; top: 50%; transform: translateY(-50%); }

body.at-lightbox-active {
    overflow: hidden;
}

@media (max-width: 640px) {
    .at-lightbox-prev, .at-lightbox-next {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }
    .at-lightbox-close {
        width: 38px;
        height: 38px;
        top: 1rem;
        right: 1rem;
    }
    .at-lightbox-caption {
        padding: 0 3.5rem;
        font-size: 12px;
    }
}