/**
 * Estilos para componentes de compensación de pago
 */

/* Contenedor principal de compensación */
.botones-compensacion-container {
    /*  margin: 40px 0; */

    padding: 0px 0px 30px 0px;
}


/* Información de compensación */
.compensacion-info {
    margin-bottom: 30px;
    text-align: center;
}

.compensacion-info p {
    font-size: 18px;
    color: #333;
    margin-bottom: 10px;
}

#monto-total-compensacion {
    font-size: 20px;
    color: #1B77BB;
    font-weight: bold;
    margin-bottom: 20px;
}

/* Grid de proyectos */
.proyectos-compensacion {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(234px, 1fr));
    gap: 12px;
    margin-top: 30px;
}

/* Tarjetas de proyecto seleccionables */
.proyecto-card-selectable {
    width: min-content;
    min-height: 124px;
    border: 2px solid #20347D;
    border-radius: 24px;
    padding: 16px;
    text-align: center;
    background: #fff;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    display: flex;
    flex-direction: column;
}

.proyecto-card-selectable:hover {
    border-color: #72B9E7;
    box-shadow: 0 4px 8px rgba(27, 119, 187, 0.2);
    -webkit-transform: translateY(-2px);
    transform: translateY(-2px);
}

.proyecto-card-selectable.proyecto-selected {
    border-color: #1B77BB;
    background: #f0f8ff;
    box-shadow: 0 4px 12px rgba(27, 119, 187, 0.3);
}

.proyecto-card-selectable.proyecto-selected::before {
    content: "✓";
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    background: #1B77BB;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
}

/* Radio button oculto */
.proyecto-card-selectable input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

/* Contenido de la tarjeta */
.proyecto-card-content {
    display: flex;
    flex-direction: column;
    flex: 1;

}

.proyecto-card-content h3 {
    color: #1B77BB;
    font-size: 18px;
    margin-bottom: 8px;
}

.proyecto-card-content h5 {
    font-size: 16px;
    font-weight: 700;
    font-style: bold;
    line-height: 22px;
    color: #20347D;
    font-family: 'Montserrat', sans-serif;
}

.proyecto-card-content p {
    color: #20347D;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 0;
    line-height: 1.4;
    flex: 1;
}

/* Mensaje de compensación */
#mensaje-compensacion {
    margin-top: 20px;
    display: none;
}

/* Wrapper del botón de compensación */
.boton-compensacion-wrapper {
    text-align: center;
    margin-top: 30px;
}

/* Botón de compensación */
.btn-compensacion-submit {
    background: #20347D;
    color: #fff;
    border: none;
    padding: 15px 40px;
    border-radius: 6px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 250px;
}

.btn-compensacion-submit:hover:not(:disabled) {
    background: #1B77BB;
    -webkit-transform: translateY(-2px);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(27, 119, 187, 0.3);
}

.btn-compensacion-submit:active:not(:disabled) {
    -webkit-transform: translateY(0);
    transform: translateY(0);
}

.btn-compensacion-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #ccc;
}

/* Mensaje de selección de proyecto */
.mensaje-seleccion-proyecto {
    margin-top: 10px;
    color: #d63638;
    font-size: 14px;
    display: block;
    transition: opacity 0.3s ease;
}

/* Contenedor de imagen del proyecto */
.proyecto-imagen-container {
    text-align: center;
    width: 202px;
    height: 148px;
}

/* Icono de imagen pequeño */
.proyecto-imagen-icono {
    width: 100%;
    height: 100%;
    -webkit-object-fit: cover;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-transition: all 0.3s ease;
}

.proyecto-imagen-icono:hover {
    -webkit-transform: scale(1.0);
    transform: scale(1.0);
    border-color: #1B77BB;
    box-shadow: 0 4px 8px rgba(27, 119, 187, 0.3);
}

/* Modal para imagen grande */
.proyecto-imagen-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.proyecto-imagen-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.proyecto-imagen-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    max-width: 90%;
    max-height: 90vh;
    z-index: 10001;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

.proyecto-imagen-modal-close {
    position: absolute;
    top: 11px;
    right: 15px;
    background: #20347D;
    color: #fff;
    border: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    -webkit-transition: all 0.3s ease;
    z-index: 10002;
}

.proyecto-imagen-modal-close:hover {
    background: #1B77BB;
    -webkit-transform: rotate(90deg);
    transform: rotate(90deg);
}

.proyecto-imagen-modal-titulo {
    color: #20347D;
    padding-bottom: 12px;
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
    width: 100%;
}

.proyecto-imagen-modal-imagen {
    max-width: 100%;
    max-height: 70vh;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    -webkit-object-fit: contain;
    object-fit: contain;
}

/* Responsive para modal */
@media (max-width: 768px) {
    .proyecto-imagen-modal-content {
        padding: 20px;
        max-width: 95%;
    }

    .proyecto-imagen-modal-titulo {
        font-size: 18px;
        margin-bottom: 15px;
    }

    .proyecto-imagen-modal-imagen {
        max-height: 60vh;
    }

    .proyectos-compensacion {
        display: flex;
        align-items: center;
        flex-direction: column;
    }
}