/* global/visor/estilos_visor.css */

/* El fondo oscuro cristalino */
.visor-modal-overlay {
    display: none; /* Oculto por defecto */
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.85); 
    z-index: 9999; /* Por encima de TODA la página */
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px); 
}

/* Clase que se activa con JS para mostrarlo con animación */
.visor-modal-overlay.activo {
    display: flex; 
    animation: aparecerModal 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.visor-modal-contenedor {
    background-color: #f2f2f2;
    width: 90%;
    max-width: 1100px;
    height: 85vh;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
}

.visor-modal-cabecera {
    background-color: #000;
    color: #fff;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.visor-modal-cabecera h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 20px;
}

.visor-btn-cerrar {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.visor-btn-cerrar:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.visor-modal-cuerpo {
    flex-grow: 1;
    width: 100%;
    background-color: #e5e5e5;
}

.visor-modal-cuerpo iframe {
    width: 100%;
    height: 100%;
    border: none;
}

@keyframes aparecerModal {
    from { opacity: 0; transform: scale(0.95) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Ajustes para Móviles: ¡Pantalla Completa! */
@media (max-width: 768px) {
    .visor-modal-contenedor {
        width: 100%;
        height: 100%;
        border-radius: 0;
    }
    .visor-modal-cabecera h3 {
        font-size: 15px;
    }
}