/* Variables del sistema anterior */
:root {
    --primary-color: #1a428a;
    --primary-hover: #123166;
    --accent-color: #e32219;
    --bg-light: #f8fafc;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
}

/* --- ESTILOS DEL MODAL --- */

/* Fondo oscuro translúcido */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.6); /* Backdrop oscuro moderno */
    backdrop-filter: blur(4px); /* Efecto de desenfoque de fondo */
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Ventana del Modal */
.modal-container {
    background: #ffffff;
    width: 100%;
    max-width: 650px;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    position: relative;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Encabezado del Modal */
.modal-header {
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0;
}

/* Botón de cerrar (X) */
.modal-close-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 28px;
    font-weight: 300;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, transform 0.2s;
}

.modal-close-btn:hover {
    color: #ffffff;
    transform: scale(1.1);
}

/* Cuerpo del contenido */
.modal-body {
    padding: 28px 24px;
    max-height: 75vh;
    overflow-y: auto;
}

/* Lista de requisitos optimizada */
.modal-req-list {
    list-style: none;
    padding: 0;
    margin: 0 0 30px 0;
}

.modal-req-item {
    position: relative;
    padding-left: 28px;
    margin-bottom: 16px;
    font-size: 14.5px;
    color: #334155;
    line-height: 1.5;
}

.modal-req-item:last-child {
    margin-bottom: 0;
}

/* Icono de viñeta azul moderno */
.modal-req-item::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 6px;
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
}

/* Sección de Aviso Importante */
.modal-alert-box {
    background-color: #fff1f2; /* Rojo/Rosa muy tenue */
    border: 1px solid #ffe4e6;
    border-radius: 12px;
    padding: 20px;
}

.modal-alert-box h4 {
    color: var(--accent-color);
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-alert-box p {
    font-size: 14px;
    color: #9f1239;
    font-weight: 600;
    padding-left: 2px;
}

/* Ajuste responsivo */
@media (max-width: 680px) {
    .modal-container {
        width: 90%;
        margin: 20px;
    }

    .modal-body {
        padding: 20px;
    }
}

/* Sección de pie de página del modal */
.modal-footer {
    padding: 10px 15px;
    background-color: #f8fafc; /* Fondo ligeramente gris para separarlo del contenido */
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end; /* Alinea los elementos a la derecha */
    gap: 5px; /* Espacio horizontal entre los botones */
}

/* Base para los botones del modal */
.btn-modal {
    font-family: inherit;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

/* Botón Principal (Entendido / Aceptar) */
.btn-modal-primary {
    background-color: var(--primary-color);
    color: #ffffff;
}

.btn-modal-primary:hover {
    background-color: var(--primary-hover);
}

/* Botón Secundario o de Texto (Cancelar / Cerrar) */
.btn-modal-text {
    background-color: transparent;
    color: var(--text-muted);
}

.btn-modal-text:hover {
    background-color: #f1f5f9;
    color: var(--text-main);
}