/* ================================================
   LIGHTBOX - Galeria de Fotos
   Arquivo separado para evitar conflito com style.css
   ================================================ */

/* Cursor pointer nas imagens da galeria */
.ag-galeria-grid img {
    cursor: pointer;
}

/* Overlay escuro de fundo */
.ag-lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.92);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    box-sizing: border-box;
    animation: ag-lb-fadein 0.25s ease;
}

.ag-lightbox-overlay.ag-lightbox-ativo {
    display: flex;
}

@keyframes ag-lb-fadein {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Wrapper central */
.ag-lightbox-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 1000px;
    width: 100%;
}

/* Imagem ampliada */
.ag-lightbox-img {
    display: block;
    max-width: 100%;
    max-height: 85vh;
    border-radius: 12px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6);
    object-fit: contain;
    animation: ag-lb-zoom 0.25s ease;
}

@keyframes ag-lb-zoom {
    from { transform: scale(0.93); opacity: 0; }
    to   { transform: scale(1);    opacity: 1; }
}

/* Botão Fechar (X) */
.ag-lightbox-fechar {
    position: fixed;
    top: 1rem;
    right: 1.2rem;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 2.5rem;
    line-height: 1;
    cursor: pointer;
    z-index: 10000;
    opacity: 0.85;
    transition: opacity 0.2s, transform 0.2s;
    padding: 0.2rem 0.5rem;
}

.ag-lightbox-fechar:hover {
    opacity: 1;
    transform: scale(1.15);
}

/* Botões de navegação (anterior / próximo) */
.ag-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(164, 0, 52, 0.75);
    border: none;
    color: #ffffff;
    font-size: 2rem;
    line-height: 1;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    z-index: 10000;
    flex-shrink: 0;
}

.ag-lightbox-nav:hover {
    background: rgba(164, 0, 52, 1);
    transform: translateY(-50%) scale(1.1);
}

.ag-lightbox-prev { left: -64px; }
.ag-lightbox-next { right: -64px; }

/* Contador (1 / 6) */
.ag-lightbox-contador {
    position: fixed;
    bottom: 1.2rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.95rem;
    font-family: system-ui, sans-serif;
    letter-spacing: 0.05em;
    z-index: 10000;
}

/* ---- Responsivo Mobile ---- */
@media (max-width: 600px) {
    .ag-lightbox-nav {
        width: 38px;
        height: 38px;
        font-size: 1.4rem;
    }

    .ag-lightbox-prev { left: -2px; }
    .ag-lightbox-next { right: -2px; }

    .ag-lightbox-img {
        max-height: 75vh;
        border-radius: 8px;
    }

    .ag-lightbox-fechar {
        font-size: 2rem;
        top: 0.5rem;
        right: 0.7rem;
    }
}