﻿/* Overlay del modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}
    /* Mostrar el overlay cuando tenga .open */
    .modal-overlay.open {
        display: flex;
        align-items: center;
        justify-content: center;
    }

/* Contenedor del contenido */
.modal-content {
    background: var(--color-surface);
    border-radius: var(--radius-base);
    padding: var(--spacing-lg);
    max-width: 600px;
    width: 90%;
    max-height: 70vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Cuerpo donde va la tarjeta */
.modal-body {
    width: 100%;
}
    /* Wrapper centrado dentro del modal */
    .modal-body .modal-card {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: var(--spacing-md);
        width: 100%;
    }
        /* Ajuste de la tarjeta clonada */
        .modal-body .modal-card article.card {
            width: 100%;
            margin: 0;
            transform: none !important;
        }

    /* Imagen dentro del modal */
    .modal-body img {
        display: block;
        max-width: 300px;
        width: 100%;
        height: auto;
        margin: 0 auto var(--spacing-md);
    }

    /* Datos de texto */
    .modal-body h4,
    .modal-body .age,
    .modal-body .party-name {
        margin: var(--spacing-sm) 0;
    }

    /* Botones de feedback centrados */
    .modal-body .modal-card .feedback-buttons {
        margin-top: var(--spacing-lg);
        display: flex;
        gap: var(--spacing-md);
        justify-content: center;
    }

/* Botón de cerrar (×) */
.modal-close {
    position: absolute;
    top: var(--spacing-sm);
    left: 50%;
    transform: translateX(-50%);
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-text);
    opacity: 1;
    transition: color 0.2s ease, opacity 0.2s ease;
}

    .modal-close:hover {
        color: var(--color-primary);
        opacity: 1 !important;
    }

/* Pie del modal */
.modal-footer {
    text-align: center;
    margin-top: var(--spacing-lg);
}

    .modal-footer .btn {
        padding: var(--spacing-sm) var(--spacing-lg);
    }

/* Responsive: reducir imagen en móviles */
@media (max-width: 576px) {
    .modal-body img {
        max-width: 200px;
    }
}

/* Sombras por partido, que aplicarán también dentro del modal */
#union-por-la-patria .card {
    border: 3px solid #3777B8;
    box-shadow: 0 4px 12px rgba(55, 119, 184, 0.3);
}

#juntos-por-el-cambio .card {
    border: 3px solid #FFD700;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
}

#la-libertad-avanza .card {
    border: 3px solid #5A2C81;
    box-shadow: 0 4px 12px rgba(90, 44, 129, 0.3);
}

#voto-en-blanco .card {
    border: 3px solid #000000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
