/* =========================================================================
   BODEZIA — CONFIRMATION DU TRANSFERT
   -------------------------------------------------------------------------
   Réécriture complète. Tous les sélecteurs de l'ancien fichier sont
   conservés, et les doublons de fin de fichier sont fusionnés dans leur
   règle d'origine : .money-confirm-section, .money-confirm-item et
   .money-confirm-actions y étaient déclarés deux fois.

   Ce qui change
     - Les labels passent de 9,9px à 12px et deviennent lisibles
     - Le total à payer se détache enfin des autres montants
     - Gris conformes AA : #98a2a8, #99a2a8, #7d878d et #9aa3a8 sortent
     - Bascule à 991,98px comme le reste du projet

   L'en-tête de page vient de motif-origin-money.css (.flow-main), cette
   page portant la classe. Les tokens viennent de flow.css.
   ========================================================================= */

#money-confirm-flow {
    min-width: 0;
}


/* =========================================================================
   SECTION
   ========================================================================= */

#money-confirm-flow .money-confirm-section {
    padding: 20px 22px;

    border-bottom: 1px solid var(--flow-c-border, #e6e9ee);
}

#money-confirm-flow .money-confirm-section:last-of-type {
    border-bottom: 0;
}

#money-confirm-flow .money-confirm-section-header {
    display: flex;
    align-items: center;

    gap: 12px;

    margin-bottom: 16px;
}

#money-confirm-flow .money-confirm-section-header > div {
    min-width: 0;
}


/* Lien « Modifier » : sur un écran de vérification, il faut pouvoir
   corriger sans passer par le bouton retour du navigateur. */

#money-confirm-flow .money-confirm-edit {
    display: inline-flex;
    align-items: center;

    flex: 0 0 auto;

    gap: 7px;

    min-height: 38px;

    margin-left: auto;
    padding: 8px 16px;

    color: var(--flow-c-accent, #7441d4);

    background: var(--flow-c-accent-soft, #f3eefd);

    border-radius: 999px;

    font-size: var(--flow-fs-small, 0.8125rem);
    font-weight: 600;

    white-space: nowrap;
    text-decoration: none;

    transition: background-color 0.15s ease;
}

#money-confirm-flow .money-confirm-edit:hover,
#money-confirm-flow .money-confirm-edit:focus {
    color: var(--flow-c-accent-dark, #6533c1);

    background: #e9dffb;
}

#money-confirm-flow .money-confirm-edit:focus-visible {
    outline: 2px solid var(--flow-c-accent, #7441d4);
    outline-offset: 2px;
}

#money-confirm-flow .money-confirm-section-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 auto;

    width: 40px;
    height: 40px;

    color: var(--flow-c-accent, #7441d4);

    background: var(--flow-c-accent-soft, #f3eefd);

    border-radius: 10px;

    font-size: 1rem;
}

#money-confirm-flow .money-confirm-section-header h2 {
    margin: 0;

    color: var(--flow-c-heading, #2b3034);

    font-size: var(--flow-fs-section, 1.0625rem);
    font-weight: 600;

    line-height: 1.35;
}

#money-confirm-flow .money-confirm-section-header p {
    margin: 2px 0 0;

    color: var(--flow-c-body, #5c6670);

    font-size: var(--flow-fs-label, 0.875rem);
    line-height: 1.4;
}


/* Ces deux classes n'avaient aucune règle dans l'ancien fichier : elles
   sont présentes dans le HTML et servent de points d'accroche. On les
   déclare explicitement pour qu'un futur ajustement ait où se poser. */

#money-confirm-flow .money-confirm-card {
    overflow: hidden;
}

#money-confirm-flow .money-confirm-summary-section {
    background: #fff;
}


/* =========================================================================
   GRILLE D'INFORMATIONS
   ========================================================================= */

#money-confirm-flow .money-confirm-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 12px;
}

#money-confirm-flow .money-confirm-item {
    min-width: 0;

    padding: 14px 16px;

    background: var(--flow-c-surface, #f9fafc);

    border: 1px solid var(--flow-c-border, #e6e9ee);
    border-radius: 12px;
}

#money-confirm-flow .money-confirm-item-wide {
    grid-column: 1 / -1;
}

/* 9,9px en #98a2a8 (2,57:1) : le plus petit texte du projet, dans la
   couleur la moins lisible, sur l'écran de vérification avant paiement. */
#money-confirm-flow .money-confirm-label {
    display: block;

    margin-bottom: 5px;

    color: var(--flow-c-body, #5c6670);

    font-size: 0.75rem;   /* 12px */
    font-weight: 600;

    letter-spacing: 0.05em;

    text-transform: uppercase;
}

#money-confirm-flow .money-confirm-item strong {
    display: block;

    color: var(--flow-c-heading, #2b3034);

    font-size: var(--flow-fs-body, 0.9375rem);
    font-weight: 600;

    line-height: 1.4;

    overflow-wrap: anywhere;
}

#money-confirm-flow .money-confirm-country {
    display: flex;
    align-items: center;

    gap: 8px;
}


/* =========================================================================
   RÉSUMÉ FINANCIER
   ========================================================================= */

#money-confirm-flow .money-confirm-summary {
    background: #fff;

    border: 1px solid var(--flow-c-border, #e6e9ee);
    border-radius: 12px;

    overflow: hidden;
}

#money-confirm-flow .money-confirm-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 24px;

    min-height: 50px;

    padding: 11px 16px;

    border-bottom: 1px solid var(--flow-c-border, #e6e9ee);
}

#money-confirm-flow .money-confirm-summary-row:last-child {
    border-bottom: 0;
}

#money-confirm-flow .money-confirm-summary-row > span {
    color: var(--flow-c-body, #5c6670);

    font-size: var(--flow-fs-body, 0.9375rem);
}

#money-confirm-flow .money-confirm-summary-row strong {
    color: var(--flow-c-heading, #2b3034);

    font-size: var(--flow-fs-body, 0.9375rem);
    font-weight: 600;

    text-align: right;

    /* Une valeur monétaire ne se coupe pas entre le nombre et la devise */
    white-space: nowrap;
}


/* Total : même traitement que sur send-money.php, où il fait 20px.
   Ici il était à 14,7px face à 13,1px pour les autres lignes. */

#money-confirm-flow .money-confirm-total {
    min-height: 62px;

    background: rgba(116, 65, 212, 0.05);

    border-top: 1px solid var(--flow-c-border, #e6e9ee);
}

#money-confirm-flow .money-confirm-total > span {
    color: var(--flow-c-heading, #2b3034);

    font-size: var(--flow-fs-body, 0.9375rem);
    font-weight: 600;
}

#money-confirm-flow .money-confirm-total strong {
    color: var(--flow-c-accent, #7441d4);

    font-size: var(--flow-fs-total, 1.25rem);
    font-weight: 700;

    letter-spacing: -0.01em;
}


/* =========================================================================
   ACTION
   ========================================================================= */

#money-confirm-flow .money-confirm-actions {
    display: flex;
    justify-content: flex-end;

    padding-top: 20px;
}

#money-confirm-flow .money-confirm-pay-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 210px;
    min-height: 50px;

    padding: 12px 28px;

    border-radius: 999px;

    font-size: var(--flow-fs-body, 0.9375rem);
    font-weight: 600;

    text-decoration: none;
}


/* =========================================================================
   OFFRE
   ========================================================================= */

#money-confirm-flow .money-confirm-offer {
    padding: 12px 22px;

    color: var(--flow-c-body, #5c6670);

    background: var(--flow-c-surface, #f9fafc);

    border-top: 1px solid var(--flow-c-border, #e6e9ee);

    font-size: var(--flow-fs-small, 0.8125rem);
    line-height: 1.4;
}


/* =========================================================================
   MOBILE  (< 576px)
   La grille tient sur deux colonnes jusqu'à 576px : au-dessus, la
   colonne principale occupe déjà toute la largeur depuis 992px.
   ========================================================================= */

@media (max-width: 575.98px) {

    #money-confirm-flow .money-confirm-section {
        padding: 16px;
    }

    #money-confirm-flow .money-confirm-section-header {
        margin-bottom: 13px;
    }

    /* La pastille prenait 155px des 360 disponibles et écrasait le
       sous-titre sur trois lignes. Sous 576px elle se réduit à son
       icône, avec une cible de 40px et le libellé conservé pour les
       lecteurs d'écran via aria-label. */

    #money-confirm-flow .money-confirm-edit {
        justify-content: center;

        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;

        padding: 0;

        border-radius: 50%;

        font-size: 0.875rem;
    }

    #money-confirm-flow .money-confirm-edit-text {
        position: absolute;

        width: 1px;
        height: 1px;

        overflow: hidden;

        clip-path: inset(50%);
        white-space: nowrap;
    }

    #money-confirm-flow .money-confirm-section-icon {
        width: 36px;
        height: 36px;

        border-radius: 9px;

        font-size: 0.9rem;
    }

    #money-confirm-flow .money-confirm-grid {
        grid-template-columns: 1fr;

        gap: 10px;
    }

    #money-confirm-flow .money-confirm-item-wide {
        grid-column: auto;
    }

    #money-confirm-flow .money-confirm-item {
        padding: 12px 14px;
    }

    #money-confirm-flow .money-confirm-summary-row {
        gap: 12px;

        padding: 10px 14px;
    }

    #money-confirm-flow .money-confirm-actions {
        justify-content: stretch;

        padding-top: 16px;
    }

    /* Même bouton que sur les autres écrans du tunnel */
    #money-confirm-flow .money-confirm-pay-btn {
        width: 100%;
        min-width: 0;
        min-height: 52px;
    }

    #money-confirm-flow .money-confirm-offer {
        padding: 12px 16px;
    }
}