/* --- Modal --- */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
}

.modal-content {
    background-color: var(--modal-bg);
    margin: 5% auto; /* Reducido para pantallas pequeñas, responsive.css lo ajusta */
    padding: var(--spacing-xl);
    border: none;
    border-radius: var(--border-radius-md);
    width: 90%;
    max-width: 650px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2), 0 5px 10px rgba(0, 0, 0, 0.1);
    position: relative;
    animation: modalFadeIn 0.3s ease-out;
    color: var(--modal-text);
}

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

.modal-close {
    color: var(--text-muted-color);
    position: absolute;
    top: var(--spacing-md);
    right: var(--spacing-md);
    font-size: 2rem;
    font-weight: bold;
    line-height: 1;
    transition: color 0.2s ease;
}

.modal-close:hover,
.modal-close:focus {
    color: var(--secondary-color);
    text-decoration: none;
    cursor: pointer;
}