/* ============================================================
   paygw_fedapay — Styles modal Moodle 5.x / Theme Moove
   Couleur principale : #4a7fb5 (bleu Moove)
   ============================================================ */

/* --- Header bleu Moove --- */
.modal .modal-header[data-region="header"] {
    background: #4a7fb5;
    border-radius: 12px 12px 0 0;
    border-bottom: none;
    padding: 14px 20px;
}

.modal .modal-header[data-region="header"] .modal-title {
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal .modal-header[data-region="header"] .modal-title::before {
    content: "F";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: white;
    color: #4a7fb5;
    font-weight: 800;
    font-size: 17px;
    border-radius: 7px;
    flex-shrink: 0;
}

.modal .modal-header[data-region="header"] .btn-close {
    filter: brightness(0) invert(1);
    opacity: 0.85;
}

/* --- Corps du modal --- */
.modal .modal-body[data-region="body"] {
    padding: 0;
    background: #f8f9fa;
}

/* --- Bloc gateway FedaPay --- */
.modal .modal-body .form-check.fedapay {
    margin: 16px 16px 0;
    padding: 0;
}

/* --- Label (carte cliquable) --- */
.modal .modal-body .form-check.fedapay label.form-check-label {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px !important;
    margin: 0 !important;
    border-radius: 10px !important;
    border: 1.5px solid #4a7fb5 !important;
    background: rgba(74, 127, 181, 0.05) !important;
    cursor: pointer;
    transition: box-shadow 0.15s;
    width: 100%;
}

.modal .modal-body .form-check.fedapay label.form-check-label:hover {
    box-shadow: 0 3px 10px rgba(74, 127, 181, 0.2);
}

/* --- Icone F dans la carte --- */
.modal .modal-body .form-check.fedapay label.form-check-label::before {
    content: "F";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    min-width: 42px;
    background: #4a7fb5;
    color: white;
    font-weight: 800;
    font-size: 20px;
    border-radius: 10px;
}

/* --- Titre FedaPay --- */
.modal .modal-body .form-check.fedapay label .h3 {
    font-size: 15px !important;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 3px !important;
}

/* --- Description --- */
.modal .modal-body .form-check.fedapay label .content {
    font-size: 12px;
    color: #666;
    margin: 0 !important;
}

/* --- Cacher l'image icone --- */
.modal .modal-body .form-check.fedapay label img.icon {
    display: none;
}

/* --- Cacher le radio button --- */
.modal .modal-body .form-check.fedapay .form-check-input {
    display: none;
}

/* --- Zone cout --- */
.modal .modal-body .core_payment_fee_breakdown {
    margin: 12px 16px 16px;
    padding: 11px 14px;
    background: #eaf1f8;
    border: 1px solid #b3cce0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #2e5f8a;
}

.modal .modal-body .core_payment_fee_breakdown::before {
    content: "💰 ";
}

/* --- Footer --- */
.modal .modal-footer[data-region="footer"] {
    padding: 14px 20px;
    background: white;
    border-top: 1px solid #e8e8e8;
    border-radius: 0 0 12px 12px;
    gap: 10px;
}

/* --- Bouton Continuer --- */
.modal .modal-footer .btn-primary[data-action="proceed"] {
    background: #4a7fb5 !important;
    border-color: #4a7fb5 !important;
    color: white !important;
    padding: 10px 28px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    transition: background 0.15s;
}

.modal .modal-footer .btn-primary[data-action="proceed"]:hover {
    background: #3a6a9a !important;
    border-color: #3a6a9a !important;
}

/* --- Bouton Annuler --- */
.modal .modal-footer .btn-secondary[data-action="cancel"] {
    background: #f0f0f0 !important;
    border-color: #ddd !important;
    color: #555 !important;
    padding: 10px 22px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
}

.modal .modal-footer .btn-secondary[data-action="cancel"]:hover {
    background: #e2e2e2 !important;
}