/* ===== PANIER ===== */
.connection-cart {
    max-width: 900px;
    margin: 20px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.connection-cart h2 {
    font-size: 20px;
    font-weight: 500;
    margin-bottom: 20px;
    color: #333;
}

/* Table avec bordures arrondies */
.cart-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

/* En-tête */
.cart-table thead tr {
    background-color: #e9ecef;
}

.cart-table th {
    text-align: left;
    padding: 12px 15px;
    font-weight: 500;
    color: #495057;
}

/* Coins arrondis de l'en-tête */
.cart-table thead tr th:first-child {
    border-top-left-radius: 8px;
}

.cart-table thead tr th:last-child {
    border-top-right-radius: 8px;
}

/* Lignes du corps - couleurs sur les td pour respecter les coins arrondis */
.cart-table tbody tr.white-row td {
    background-color: #ffffff;
}

.cart-table tbody tr.gray-row td {
    background-color: #f8f9fa;
}

/* Pas de hover sur les lignes du tableau */

.cart-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #e0e0e0;
}

/* Dernière ligne du body garde sa bordure */
.cart-table tbody tr:last-child td {
    border-bottom: 1px solid #e0e0e0;
}

/* Footer - alterne avec la dernière ligne d'offre, couleur sur th pour respecter les coins arrondis */
.cart-footer-row.gray-footer th {
    background-color: #f8f9fa; /* Dernière offre était blanche → total gris clair */
}

.cart-footer-row.white-footer th {
    background-color: #ffffff; /* Dernière offre était grise → total blanc */
}

.cart-footer-row th {
    padding: 12px 15px;
    font-weight: 500;
    color: #333;
    border-top: 1px solid #e0e0e0;
}

/* Coins arrondis du footer */
.cart-footer-row th:first-child {
    border-bottom-left-radius: 8px;
}

.cart-footer-row th:last-child {
    border-bottom-right-radius: 8px;
}

/* Colonnes */
.col-price {
    width: 80px;
    text-align: right;
    font-weight: 500;
    white-space: nowrap;
}

.col-action {
    width: 50px;
    text-align: center;
}

/* Titre de l'offre */
.offre-title {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.offre-text {
    line-height: 1.4;
}

.toggle-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    color: #6c757d;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.offre-title.active .toggle-icon {
    transform: rotate(180deg);
}

/* Détails de l'offre */
.offre-details {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px dashed #d0d0d0;
    font-size: 13px;
    color: #495057;
    line-height: 1.6;
}

.detail-reference {
    margin-bottom: 4px;
    color: #6c757d;
    font-size: 0.9em;
}

.details-list {
    display: inline;
}

.detail-item {
    display: inline;
}

.detail-label {
    color: #6c757d;
    font-weight: 400;
}

.detail-sep {
    color: #6c757d;
    margin: 0 3px;
}

/* Bouton retirer */
.cart-remove-item {
    background: none;
    border: none;
    color: #dc3545;
    cursor: pointer;
    padding: 5px 8px;
    font-size: 16px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.cart-remove-item:hover {
    opacity: 1;
}

/* Bouton vider */
.cart-clear {
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    padding: 5px 8px;
    font-size: 16px;
    transition: color 0.2s;
}

.cart-clear:hover {
    color: #dc3545;
}

/* Bouton Payer */
.cart-actions {
    text-align: right;
    margin-top: 15px;
}

.cart-checkout {
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 30px;
    font-weight: 500;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.2s;
    display: inline-block;
}

.cart-checkout:hover {
    background-color: #218838;
}

/* État vide */
.cart-empty {
    text-align: center;
    padding: 40px;
    background-color: #f9f9f9;
    border-radius: 8px;
    color: #6c757d;
}

/* ===== RESPONSIVE ===== */
@media screen and (max-width: 768px) {
    .cart-table th,
    .cart-table td {
        padding: 10px 8px;
        font-size: 0.9em;
    }
    
    .col-price {
        width: auto;
        white-space: nowrap;
    }
    
    .col-action {
        width: 36px;
    }
    
    .offre-title {
        flex-wrap: wrap;
    }
    
    .offre-details {
        font-size: 0.85em;
    }
    
    .cart-actions {
        text-align: center;
    }
    
    .cart-checkout {
        width: 100%;
    }
}

/* Footer */
.cart-footer-row.gray-footer {
    background-color: #e9ecef; /* Même gris que l'en-tête */
}

.cart-footer-row.white-footer {
    background-color: #ffffff;
}
.connection-invoices {
    max-width: 1000px;
    margin: 20px auto;
}

.invoices-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.invoices-table th,
.invoices-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.invoices-table th {
    background-color: #f5f5f5;
    font-weight: 600;
}

.invoices-table tr {
    background-color: #ffffff;
}


/* ===== FORMULAIRE DE PAIEMENT STRIPE ===== */
#payment-section {
    background-color: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

#payment-section h3 {
    font-size: 18px;
    font-weight: 500;
    margin: 0 0 15px 0;
    color: #333;
}

/* Badge de sécurité */
.stripe-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: #e9ecef;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    color: #495057;
    margin-bottom: 15px;
}

.stripe-badge svg {
    color: #28a745;
}

/* Conteneur de la carte */
.stripe-card-element {
    background-color: white;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 12px 15px;
    margin-bottom: 15px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.stripe-card-element:focus-within {
    border-color: #2a6496;
    box-shadow: 0 0 0 3px rgba(42, 100, 150, 0.1);
}

/* Messages d'erreur */
.stripe-card-errors {
    color: #dc3545;
    font-size: 14px;
    margin: 10px 0;
    min-height: 20px;
}

/* Boutons de paiement */
.stripe-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 15px;
}

.stripe-actions .button {
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.stripe-actions .button-primary {
    background-color: #28a745;
    color: white;
}

.stripe-actions .button-primary:hover {
    background-color: #218838;
}

.stripe-actions .button-primary:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
}

.stripe-actions .button:not(.button-primary) {
    background-color: white;
    border: 1px solid #e0e0e0;
    color: #495057;
}

.stripe-actions .button:not(.button-primary):hover {
    background-color: #f8f9fa;
}

/* Animation de chargement */
.button .spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin-right: 5px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive */
@media screen and (max-width: 768px) {
    #payment-section {
        padding: 15px;
    }
    
    .stripe-actions {
        flex-direction: column;
    }
    
    .stripe-actions .button {
        width: 100%;
        text-align: center;
    }
}
/* ===== PAGE PAIEMENT RÉUSSI ===== */
.paiement-reussi {
    max-width: 600px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.paiement-reussi-header {
    text-align: center;
    margin-bottom: 30px;
}

.paiement-reussi-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background-color: #d4edda;
    border-radius: 50%;
    color: #28a745;
    margin-bottom: 20px;
}

.paiement-echec-icon {
    background-color: #f8d7da;
    color: #dc3545;
}

.paiement-reussi h2 {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 0 0 10px 0;
}

.paiement-reussi-subtitle {
    color: #6c757d;
    font-size: 15px;
    margin: 0;
}

/* Tableau récap */
.paiement-reussi-recap {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
}

.paiement-reussi-recap h3 {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0 0 15px 0;
}

.recap-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.recap-table tr {
    border-bottom: 1px solid #f0f0f0;
}

.recap-table tr:last-child {
    border-bottom: none;
}

.recap-table td {
    padding: 10px 15px;
    font-size: 14px;
}

.recap-label {
    color: #6c757d;
    width: 50%;
    text-align: left;
}

.recap-value {
    font-weight: 500;
    color: #333;
    text-align: center;
}

.recap-total .recap-label,
.recap-total .recap-value {
    font-weight: 600;
    font-size: 15px;
    color: #333;
    padding-top: 15px;
}

/* Boutons */
.recap-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

.recap-btn {
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s;
}

.recap-btn-primary {
    background-color: #28a745;
    color: white;
}

.recap-btn-primary:hover {
    background-color: #218838;
    color: white;
}

.recap-btn-secondary {
    background-color: white;
    color: #495057;
    border: 1px solid #e0e0e0;
}

.recap-btn-secondary:hover {
    background-color: #f8f9fa;
    color: #495057;
}

@media screen and (max-width: 768px) {
    .recap-actions {
        flex-direction: column;
    }

    .recap-btn {
        text-align: center;
    }
}