/**
 * Gallery Mad - Styles
 * SOLO estilos para vídeos y lightbox. No tocar imágenes.
 */

/* El contenedor de vídeo dentro de la galería */
.gmad-has-video .e-gallery-image {
    position: relative !important;
    overflow: hidden;
}

/* El vídeo llena el contenedor igual que background-image */
.gmad-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

/* Overlay y contenido por encima del vídeo */
.gmad-has-video .elementor-gallery-item__overlay { z-index: 2; }
.gmad-has-video .elementor-gallery-item__content { z-index: 3; }

/* Cursor pointer en ítems de vídeo */
.e-gallery-item.gmad-has-video { cursor: pointer; }

/* ── LIGHTBOX ───────────────────────────────────────────────────────────── */
.gmad-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
}
.gmad-lightbox--open { display: flex; }

.gmad-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.92);
    cursor: pointer;
}
.gmad-lightbox__inner {
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.gmad-lightbox__video {
    max-width: 90vw;
    max-height: 85vh;
    width: auto;
    height: auto;
    border-radius: 6px;
    background: #000;
}
.gmad-lightbox__close {
    position: fixed;
    top: 20px;
    right: 24px;
    background: rgba(255,255,255,0.15);
    border: none;
    color: #fff;
    font-size: 28px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    z-index: 2;
    line-height: 1;
}
.gmad-lightbox__close:hover { background: rgba(255,255,255,0.3); }
body.gmad-lightbox-open { overflow: hidden; }
