.plango-gastos-box {
    margin-top: 30px;
    padding: 24px;
    border: 1px solid #e1e1e1;
    border-radius: 12px;
    background: #ffffff;
}

.plango-gastos-box h3 {
    margin-top: 0;
}

.plango-gastos-box h4 {
    margin-top: 24px;
    margin-bottom: 12px;
}

/* =========================
   FORMULARIO
========================= */

#plango-form-gasto input,
#plango-form-gasto select {
    width: 100%;
    max-width: 420px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
}

#plango-form-gasto button,
.plango-eliminar-gasto {
    padding: 9px 14px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

#plango-form-gasto button:hover,
.plango-eliminar-gasto:hover {
    opacity: 0.9;
}

#plango-form-gasto button {
    background: #2271b1;
    color: white;
}

.plango-eliminar-gasto {
    background: #dc3545;
    color: white;
}

/* =========================
   MENSAJES
========================= */

#plango-gastos-mensaje p {
    margin-top: 10px;
    font-weight: bold;
}

/* =========================
   TABLAS
========================= */

.plango-tabla-contenedor {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.plango-tabla {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    margin-top: 10px;
}

.plango-tabla th,
.plango-tabla td {
    padding: 12px;
    border: 1px solid #ddd;
    text-align: left;
    vertical-align: middle;
}

.plango-tabla th {
    background: #f5f5f5;
    font-weight: 600;
}

.plango-tabla tbody tr:nth-child(even) {
    background: #fafafa;
}

/* =========================
   PARTICIPANTES
========================= */

.plango-gastos-box ul {
    padding-left: 20px;
}

.plango-gastos-box li {
    margin-bottom: 8px;
}

/* =========================
   MÓVIL
========================= */

@media (max-width: 768px) {

    .plango-gastos-box {
        padding: 16px;
    }

    .plango-tabla {
        min-width: 520px;
        font-size: 14px;
    }

    .plango-tabla th,
    .plango-tabla td {
        padding: 8px;
    }

    #plango-form-gasto input,
    #plango-form-gasto select {
        max-width: 100%;
    }

    #plango-form-gasto button,
    .plango-eliminar-gasto {
        width: 100%;
    }
}

/* =========================
   BOTÓN PAGAR
========================= */

.plango-pagar-gasto {
    padding: 9px 14px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
    background: #28a745 !important;
    color: white;
}

.plango-pagar-gasto:hover {
    background: #218838 !important;
}

/* =========================
   BOTÓN PAGAR
========================= */

.plango-pagar-gasto {
    padding: 9px 14px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: opacity 0.2s ease;
    background: #2271b1;
    color: white;
}

.plango-pagar-gasto:hover {
    opacity: 0.9;
}

#plango-pagos-mensaje p {
    margin-top: 10px;
    font-weight: bold;
}

/* =========================
   MODAL PAGO SIMULADO
========================= */

.plango-modal-pago {
    position: fixed;
    z-index: 99999;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.plango-modal-pago-contenido {
    background: #ffffff;
    width: 100%;
    max-width: 460px;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.25);
}

.plango-modal-pago-contenido h4 {
    margin-top: 0;
}

.plango-modal-resumen {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 8px;
    margin: 15px 0;
}

.plango-modal-resumen p {
    margin: 6px 0;
}

#plango-metodo-pago {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
}

.plango-modal-acciones {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

#plango-cancelar-pago,
#plango-confirmar-pago {
    padding: 9px 14px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

#plango-cancelar-pago {
    background: #6c757d;
    color: white;
}

#plango-confirmar-pago {
    background: #28a745;
    color: white;
}

#plango-confirmar-pago:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .plango-modal-pago-contenido {
        padding: 18px;
    }

    .plango-modal-acciones {
        flex-direction: column;
    }

    #plango-cancelar-pago,
    #plango-confirmar-pago {
        width: 100%;
    }
}

.plango-btn-guardar {
    background: #28a745 !important;
    color: white;
}

.plango-btn-guardar:hover {
    background: #218838 !important;
}