/* --- ESTADO POR DEFECTO: OCULTO --- */
.cvii-popup-overlay {
    display: none;
    /* Oculto por defecto */
    position: fixed;
    /* Fijo respecto a la ventana del navegador */
    z-index: 10000;
    /* Muy alto para estar encima de todo (menú, chat, etc) */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    /* Fondo negro semitransparente */
    overflow: auto;
    /* Permite scroll si el formulario es muy largo */

    /* Flexbox para centrar el contenido perfectamente */
    align-items: center;
    justify-content: center;
}

/* Estilos de la caja blanca interna */
.cvii-popup-content {
    background-color: #fefefe;
    margin: 5% auto;
    /* Un poco de margen vertical */
    padding: 20px;
    border: 1px solid #888;
    width: 90%;
    /* Ancho responsivo */
    max-width: 600px;
    /* Ancho máximo para que no se vea gigante en PC */
    border-radius: 8px;
    /* Bordes redondeados */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    /* Sombra suave */
    position: relative;
    /* Necesario para posicionar el botón de cerrar */
}

/* Botón de cerrar (X) */
.close-popup-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 5px;
}

.close-popup-btn:hover,
.close-popup-btn:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

/* --- ESTILOS DEL PUPUP ACTIVO --- */
/* --- ESTADO VISIBLE --- */
.cvii-popup-overlay.active {
    display: flex !important;
    /* Usamos flex para activar el centrado definido arriba */
    animation: fadeIn 0.3s;
    /* Pequeña animación de entrada (opcional) */
}

/* Animación de desvanecimiento simple */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/** botones **/

/* --- ESTILO BASE DE LOS BOTONES --- */
.action-btn {
    display: inline-block;
    padding: 12px 35px;
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    border: none;
    border-radius: 50px;
    /* Botón píldora */
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 250px;
}

/* --- BOTÓN DE CERRAR (X) --- */
.close-popup-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 30px;
    color: #aaa;
    cursor: pointer;
    font-weight: bold;
    line-height: 1;
    z-index: 10;
}

.close-popup-btn:hover {
    color: #333;
}