/* ============================================
   AVISO-EMERGENTE.CSS - VERSIÓN SIMPLE
   ============================================ */

/* MODAL PRINCIPAL */
.aviso-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    z-index: 9999;
    display: none; /* Se mostrará con JavaScript */
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease-out;
    backdrop-filter: blur(5px);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* CONTENEDOR SIMPLE CON MARCO BLANCO */
.aviso-contenedor {
    background: white;
    border-radius: 10px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.3),
        0 0 30px rgba(0, 80, 115, 0.2);
    overflow: hidden;
    animation: slideUp 0.4s ease-out;
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    border: 15px solid white; /* Marco blanco */
}

@keyframes slideUp {
    from { 
        transform: translateY(30px) scale(0.95);
        opacity: 0;
    }
    to { 
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* BOTÓN CERRAR (X) */
.aviso-cerrar {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid white;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    font-size: 24px;
    font-weight: 300;
    padding: 0;
    line-height: 1;
}

.aviso-cerrar:hover {
    background: #CC0000; /* Rojo al hover */
    transform: scale(1.1);
    border-color: #CC0000;
}

.aviso-cerrar:active {
    transform: scale(0.95);
}

/* CONTENEDOR DE LA IMAGEN */
.aviso-imagen-contenedor {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    max-width: 100%;
    max-height: calc(90vh - 70px); /* Ajusta según el botón "No mostrar hoy" */
}

/* IMAGEN RESPONSIVA */
.aviso-imagen {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain; /* Mantiene proporciones */
}

/* ENLACE PARA LA IMAGEN (si es clickeable) */
.aviso-enlace {
    display: block;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.aviso-enlace:hover {
    opacity: 0.95;
}

/* BOTÓN "NO MOSTRAR HOY" */
.aviso-opciones {
    padding: 15px;
    text-align: center;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

.btn-no-mostrar {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Times New Roman', Times, serif;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

.btn-no-mostrar:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
    .aviso-contenedor {
        max-width: 95%;
        border-width: 10px; /* Marco más delgado en móviles */
    }
    
    .aviso-cerrar {
        width: 35px;
        height: 35px;
        top: 10px;
        right: 10px;
        font-size: 20px;
    }
    
    .btn-no-mostrar {
        padding: 8px 20px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .aviso-contenedor {
        max-width: 98%;
        border-width: 8px;
        border-radius: 8px;
    }
    
    .aviso-cerrar {
        width: 30px;
        height: 30px;
        font-size: 18px;
    }
    
    .aviso-imagen-contenedor {
        max-height: calc(90vh - 60px);
    }
}

/* EFECTO PARA IMAGENES VERTICALES/HORIZONTALES */
@media (orientation: portrait) {
    .aviso-imagen {
        max-height: 70vh;
        max-width: 100%;
    }
}

@media (orientation: landscape) {
    .aviso-imagen {
        max-height: 80vh;
        max-width: 100%;
    }
}