/* ========================================
   SYSTÈME DE PANIER — L'as du goût
   ========================================
   Styles pour :
   - Bouton "+" sur les cartes produit
   - Icône panier dans la navbar (badge)
   - Modale produit améliorée (image + détails + commande)
   - Tiroir récapitulatif du panier (drawer depuis la droite)
   ======================================== */


/* ─────────────────────────────────────────
   IMAGE BOX — position relative nécessaire
   pour que le bouton "+" soit ancré dedans
   ───────────────────────────────────────── */
.carte-produit-image-box {
    position: relative;
}


/* ─────────────────────────────────────────
   BOUTON "+" SUR L'IMAGE PRODUIT
   ───────────────────────────────────────── */
.btn-plus-panier {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    background: var(--c-or-vif);
    color: var(--c-noir-profond);
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.55);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.2s;
    z-index: 5;
    line-height: 1;
}

.btn-plus-panier:hover {
    transform: scale(1.2) rotate(90deg);
    box-shadow: 0 6px 22px rgba(212, 175, 55, 0.8);
    background: #fff;
}


/* ─────────────────────────────────────────
   ICÔNE PANIER DANS LA NAVBAR
   ───────────────────────────────────────── */
.bouton-panier {
    background: transparent;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: var(--transition-fluide);
    color: var(--c-or-vif);
    position: relative;
    flex-shrink: 0;
    margin-right: 12px; /* même écart que drapeau→soleil/lune */
}

.bouton-panier:hover {
    background: rgba(212, 175, 55, 0.1);
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
}

/* Badge nombre d'articles */
#cart-badge {
    position: absolute;
    top: -7px;
    right: -7px;
    background: var(--c-or-vif);
    color: var(--c-noir-profond);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 0.62rem;
    font-weight: 700;
    display: none; /* shown by JS when count > 0 */
    align-items: center;
    justify-content: center;
    font-family: 'Montserrat', sans-serif;
    border: 2px solid var(--c-noir-profond);
    pointer-events: none;
}

@media (max-width: 900px) {
    .bouton-panier {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
}


/* ─────────────────────────────────────────
   OVERLAYS — z-index élevé pour passer
   au-dessus de la navbar (z:100) et des
   modales existantes (z:1000)
   ───────────────────────────────────────── */
.cart-product-overlay,
.cart-overview-overlay {
    position: fixed !important; /* Garantit qu'ils couvrent TOUT l'écran sur mobile */
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 1200;
}

/* Le Dual Pane s'anime à l'ouverture */
.cart-product-dual-pane {
    display: flex;
    gap: 20px;
    max-width: 860px;
    width: 95vw;
    margin: 0 auto;
    justify-content: center;
    align-items: stretch;
    transform: scale(0.85);
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.35s ease;
}
.cart-product-overlay.active .cart-product-dual-pane {
    transform: scale(1);
    opacity: 1;
}

/* Tiroir transformé en Modale Centrale */
.cart-overview-overlay.active {
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}


/* ─────────────────────────────────────────
   MODALE PRODUIT (DUAL PANE)
   Layout : [Pane Gauche | Pane Droite]
   ───────────────────────────────────────── */
.pane-window {
    background: #141414;
    border-radius: 20px;
    border: 1px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 35px 80px rgba(0, 0, 0, 0.7);
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Pane Gauche : Image + Détails */
.cart-pane-left {
    flex: 1;
    min-width: 380px;
    display: flex;
    flex-direction: column;
}

/* Pane Droite : Commande */
.cart-pane-right {
    width: 320px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

/* Variante consultation seule (Aix / pas de panier) : 1 seule fenêtre élégante et centrée */
.cart-product-dual-pane--single {
    max-width: 580px;
    width: 90vw;
}

.cart-product-dual-pane--single .cart-pane-left {
    min-width: 0;
    width: 100%;
    border-radius: 20px;
}

/* Bouton fermer dans le pane de droite (ou global) */
.cart-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: var(--c-texte-principal);
    font-size: 1.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: 0.3s;
}

.cart-modal-close:hover {
    background: rgba(212, 175, 55, 0.25);
    color: var(--c-or-vif);
    transform: rotate(90deg);
}

.cart-modal-close--left {
    display: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

/* Image du produit — proportions proches des cartes de la grille */
.cart-modal-image {
    background-size: cover;
    background-position: center;
    height: 300px;
    flex-shrink: 0;
    border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

/* En mode consultation (Asso di Gusto Aix), l'image a la même hauteur que la modale des autres pages (400px) */
.cart-product-dual-pane--single .cart-modal-image {
    height: 400px;
}

/* Bandeau Prix situé juste sous l'image pour les produits en consultation (ex: Asso di Gusto Aix) */
.cart-modal-prix-sous-img {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 28px;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.18), rgba(212, 175, 55, 0.05));
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    box-sizing: border-box;
}

.cart-prix-sous-img-label {
    text-transform: uppercase;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--c-texte-secondaire);
    font-family: 'Montserrat', sans-serif;
}

.cart-prix-sous-img-valeur {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--c-or-vif);
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.5px;
}

/* Détails produit */
.cart-modal-details {
    padding: 30px 35px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}

.cart-modal-nom {
    color: var(--c-texte-principal);
    font-size: 1.7rem;
    margin: 0;
    font-family: 'Playfair Display', serif;
}

.cart-modal-description {
    color: var(--c-texte-secondaire);
    line-height: 1.8;
    font-size: 0.95rem;
}

.cart-modal-allergenes-bloc {
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px dashed rgba(255, 255, 255, 0.12);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cart-modal-allergenes {
    font-size: 0.85rem;
    color: var(--c-texte-principal);
    margin: 0;
    line-height: 1.5;
}

.cart-modal-allergenes-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.78rem;
    color: var(--c-texte-secondaire);
    line-height: 1.5;
    background: rgba(212, 175, 55, 0.06);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 8px;
    padding: 8px 12px;
    margin: 0;
}

.cart-modal-allergenes-note svg {
    color: var(--c-or-vif);
    flex-shrink: 0;
    margin-top: 2px;
}

.cart-note-link {
    color: var(--c-or-vif);
    text-decoration: underline;
    font-weight: 500;
    transition: color 0.2s ease;
}

.cart-note-link:hover {
    color: var(--c-or-doux);
}

/* Boîte prix unitaire */
.cart-modal-prix-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.12), rgba(212, 175, 55, 0.03));
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    width: 100%;
    box-sizing: border-box;
    box-shadow: inset 0 2px 10px rgba(255, 255, 255, 0.04), 0 4px 15px rgba(0, 0, 0, 0.2);
}

.cart-prix-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--c-texte-secondaire);
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
}

.cart-prix-valeur {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--c-or-vif);
    font-family: 'Montserrat', sans-serif;
}

/* En-tête du pane droit */
.cart-order-header {
    padding: 28px 22px 20px;
    text-align: center;
    flex-shrink: 0;
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.07) 0%, transparent 100%);
    border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

.cart-order-header h3 {
    color: var(--c-or-vif);
    font-size: 1.1rem;
    font-family: 'Playfair Display', serif;
    margin: 0 0 12px;
    letter-spacing: 0.5px;
}

.cart-order-separator {
    width: 48px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--c-or-vif), transparent);
    margin: 0 auto;
}

/* Colonne 2 : Panneau de commande (Pane Droite) */
.cart-modal-order-panel {
    padding: 30px 22px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    gap: 20px;
    text-align: center;
    justify-content: center;
    
    /* Ajout d'élégance supplémentaire (ombres + bordures pour structurer) */
    background: radial-gradient(circle at center, rgba(212, 175, 55, 0.05) 0%, transparent 60%);
    border-radius: 12px;
}

/* Actions (bouton ajouter) — ancré en bas */
.cart-order-actions {
    padding: 16px 22px 24px;
    flex-shrink: 0;
    border-top: 1px solid rgba(212, 175, 55, 0.12);
}

.cart-panel-subtitle {
    font-size: 0.72rem;
    color: var(--c-texte-secondaire);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin: 0;
}

/* Contrôleur de quantité */
.cart-qty-control {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(10, 10, 10, 0.6);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 40px;
    padding: 8px 18px;
    box-shadow: inset 0 4px 10px rgba(0, 0, 0, 0.7);
}

.cart-qty-modal {
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.2);
    color: var(--c-or-vif);
    font-size: 1.35rem;
    font-weight: 500;
    cursor: pointer;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    line-height: 1;
}

.cart-qty-modal:hover { 
    transform: scale(1.1);
    background: var(--c-or-vif);
    color: var(--c-noir-profond);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.4);
}

/* Input de quantité éditable (remplace l'ancien span) */
.cart-qty-input {
    background: transparent;
    border: none;
    color: var(--c-blanc);
    font-size: 1.2rem;
    font-weight: 700;
    width: 46px;
    text-align: center;
    font-family: 'Montserrat', sans-serif;
    appearance: textfield;       /* Standard */
    -moz-appearance: textfield; /* Firefox : masque les flèches */
    outline: none;
    padding: 2px 0;
}

/* Chrome/Safari : masque les flèches natives de l'input number */
.cart-qty-input::-webkit-inner-spin-button,
.cart-qty-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Ligne de total */
.cart-total-ligne {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 18px 22px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.08) 0%, rgba(10, 10, 10, 0.6) 100%);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3), inset 0 2px 10px rgba(212, 175, 55, 0.08);
}

.cart-total-ligne > span:first-child {
    font-size: 0.72rem;
    color: var(--c-texte-secondaire);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
}

.cart-total-valeur {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--c-or-vif);
    font-family: 'Montserrat', sans-serif;
}

/* Bouton ajouter au panier (Amélioration Premium - Thème Fenêtre Translucide) */
.btn-add-to-cart {
    margin-top: 0;
    padding: 16px 20px;
    font-size: 0.95rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    width: 100%;
    text-align: center;
    border-radius: 50px; /* Style pilule */
    background: rgba(25, 25, 25, 0.7); /* Thème fond sombre de la modale */
    color: var(--c-or-vif); /* Texte or */
    border: 1px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4), inset 0 2px 5px rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.35s ease;
}

.btn-add-to-cart:hover:not(.added) {
    background: rgba(212, 175, 55, 0.15); /* Légère lueur or au survol */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), inset 0 2px 8px rgba(212, 175, 55, 0.25);
    transform: translateY(-3px) scale(1.02);
    border-color: rgba(212, 175, 55, 0.6);
    color: #fff;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.6);
}

/* État "Ajouté !" */
.btn-add-to-cart.added {
    background: linear-gradient(135deg, #3d8b5c, #2a6b44) !important;
    border-color: #3d8b5c !important;
    box-shadow: 0 4px 18px rgba(61, 139, 92, 0.45) !important;
    transform: scale(1.02);
}

@keyframes cartCheckDraw {
    from { stroke-dashoffset: 24; opacity: 0; }
    to   { stroke-dashoffset: 0;  opacity: 1; }
}


/* ─────────────────────────────────────────
   MODALE PANIER (Cart Modal Centrée)
   ───────────────────────────────────────── */
.cart-overview-panel {
    width: min(800px, 95vw);
    max-height: 85vh;
    background: #141414;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.85),
                inset 0 1px 1px rgba(255, 255, 255, 0.05);
    animation: fadeInScaleCart 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@keyframes fadeInScaleCart {
    from { opacity: 0; transform: scale(0.9); }
    to   { opacity: 1; transform: scale(1); }
}

/* En-tête du tiroir */
.cart-overview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 22px 28px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.15);
    background: transparent;
    flex-shrink: 0;
    gap: 12px;
}

.cart-overview-header h2 {
    color: var(--c-or-vif);
    font-size: 1.3rem;
    margin: 0;
}

.cart-header-controls {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

/* Boîte total général (en haut à droite) */
.cart-grand-total-box {
    display: flex;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15), rgba(212, 175, 55, 0.05));
    border: 1px solid rgba(212, 175, 55, 0.4);
    padding: 8px 18px;
    border-radius: 30px;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.1);
}

.cart-total-label {
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1px;
    color: var(--c-or-doux);
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
}

.cart-grand-total-box strong {
    color: var(--c-or-vif);
    font-size: 1.25rem;
    font-family: 'Montserrat', sans-serif;
    margin-left: 0;
}

.disabled-btn {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: rgba(255, 255, 255, 0.3) !important;
    cursor: default !important;
    box-shadow: none !important;
}

/* Bouton fermer le tiroir */
.cart-overview-close {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--c-texte-secondaire);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    flex-shrink: 0;
}

.cart-overview-close:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--c-or-vif);
    transform: rotate(90deg);
}

/* Corps scrollable */
.cart-overview-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(212, 175, 55, 0.3) transparent;
}

.cart-overview-body::-webkit-scrollbar { width: 4px; }
.cart-overview-body::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 55, 0.3);
    border-radius: 2px;
}

/* Bloc par catégorie */
.cart-categorie-bloc {
    margin-bottom: 20px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(212, 175, 55, 0.08);
    border-radius: 14px;
    padding: 14px;
}

/* En-tête de catégorie : titre + bouton poubelle */
.cart-categorie-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.cart-categorie-header .cart-categorie-titre {
    margin: 0;
    padding-bottom: 0;
    border-bottom: none;
    flex: 1;
}

.cart-categorie-titre {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--c-or-vif);
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
}

/* Liste des articles */
.cart-articles-liste {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Article individuel */
.cart-article {
    display: grid;
    grid-template-columns: 52px 1fr 112px 64px 24px;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    padding: 11px 14px;
    transition: border-color 0.3s;
}

.cart-article:hover {
    border-color: rgba(212, 175, 55, 0.2);
}

.cart-article-image {
    width: 52px;
    height: 52px;
    border-radius: 7px;
    background-size: cover;
    background-position: center;
    background-color: var(--c-fond-principal);
}

.cart-article-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.cart-article-nom {
    color: var(--c-texte-principal);
    font-weight: 600;
    font-size: 0.88rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-article-prix-unit {
    color: var(--c-texte-secondaire);
    font-size: 0.76rem;
}

/* Contrôles +/- dans le tiroir */
.cart-article-controles {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 20px;
    padding: 5px 11px;
}

.cart-qty-btn {
    background: none;
    border: none;
    color: var(--c-or-vif);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
    line-height: 1;
}

.cart-qty-btn:hover { transform: scale(1.4); }

.cart-qty-count {
    color: var(--c-texte-principal);
    font-weight: 700;
    min-width: 18px;
    text-align: center;
    font-size: 0.88rem;
}

.cart-qty-edit {
    background: none;
    border: none;
    color: var(--c-texte-principal);
    font-weight: 700;
    font-size: 0.88rem;
    width: 36px;
    text-align: center;
    padding: 0;
    outline: none;
    -moz-appearance: textfield;
    cursor: text;
}

.cart-qty-edit::-webkit-outer-spin-button,
.cart-qty-edit::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.cart-qty-edit:focus {
    color: var(--c-or-vif);
}

.cart-article-total {
    color: var(--c-or-vif);
    font-weight: 700;
    font-size: 0.88rem;
    min-width: 56px;
    text-align: right;
    font-family: 'Montserrat', sans-serif;
}

/* Bouton supprimer */
.cart-article-suppr {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.22);
    font-size: 1.05rem;
    cursor: pointer;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s;
}

.cart-article-suppr:hover {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.12);
}

/* Boutons Vider le panier */
.cart-clear-btn {
    background: transparent;
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: rgba(231, 76, 60, 0.8);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.25s;
    padding: 0;
    flex-shrink: 0;
}

.cart-clear-btn:hover {
    background: #e74c3c;
    border-color: #e74c3c;
    color: white;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

.cart-clear-cat {
    width: 28px;
    height: 28px;
    margin-bottom: -3px;
}

/* Sous-total par catégorie */
.cart-sous-total-cat {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.82rem;
    color: var(--c-texte-secondaire);
}

.cart-sous-total-cat strong {
    color: var(--c-texte-principal);
    font-size: 0.95rem;
    font-family: 'Montserrat', sans-serif;
}

/* Panier vide */
.cart-vide {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 70px 20px;
    text-align: center;
    color: var(--c-texte-secondaire);
}

.cart-vide-icon {
    font-size: 3.5rem;
    opacity: 0.35;
    color: var(--c-or-vif);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-vide p {
    font-size: 1.1rem;
    color: var(--c-texte-principal);
    margin: 0;
}

.cart-vide span {
    font-size: 0.85rem;
}

/* Pied du tiroir */
.cart-overview-footer {
    padding: 20px 28px;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    background: var(--c-noir-profond);
    flex-shrink: 0;
    display: flex; /* En force flex pour bien centrer vert. et horiz. */
    align-items: center;
    justify-content: center;
}

/* ── Bouton "Finaliser mon devis" — effet shimmer doré ── */
.cart-overview-footer .bouton-envoyer {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0; /* Tue le margin-top: 10px du .bouton-envoyer global */
    width: 100%;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    /* Shimmer via ::before */
}

.cart-overview-footer .bouton-envoyer::before {
    content: '';
    position: absolute;
    top: 0;
    left: -80%;
    width: 55%;
    height: 100%;
    background: linear-gradient(
        120deg,
        transparent 0%,
        rgba(255, 255, 255, 0.28) 50%,
        transparent 100%
    );
    transform: skewX(18deg);
    transition: left 0.55s ease;
    pointer-events: none;
    z-index: 0;
}

.cart-overview-footer .bouton-envoyer > * {
    position: relative;
    z-index: 1;
}

.cart-overview-footer .bouton-envoyer:hover::before {
    left: 130%;
}

.cart-overview-footer .bouton-envoyer:hover {
    background-color: var(--c-or-vif);
    color: var(--c-noir-profond);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(212, 175, 55, 0.40);
}

.cart-overview-footer .bouton-envoyer:active {
    transform: translateY(0);
    box-shadow: 0 4px 14px rgba(212, 175, 55, 0.25);
}


/* ─────────────────────────────────────────
   RESPONSIVE MOBILE
   ───────────────────────────────────────── */
@media (max-width: 768px) {
    /* Modale produit : empilement vertical */
    .cart-product-dual-pane {
        flex-direction: column;
        max-height: 92vh;
        max-height: 92dvh; /* Dynamic viewport height (iOS fix) */
        overflow-y: auto;
        overflow-x: hidden;
        justify-content: flex-start;
        align-items: stretch;
        width: 95vw;
        border-radius: 16px;
        -webkit-overflow-scrolling: touch;
    }

    .cart-pane-left, .cart-pane-right {
        width: 100%;
        min-width: unset;
        flex: none;
    }

    .cart-modal-image {
        min-height: 200px;
        max-height: 220px;
    }

    .cart-modal-details {
        padding: 20px 16px;
    }

    .cart-order-header {
        padding: 18px 16px 14px;
    }

    .cart-modal-order-panel {
        padding: 14px 16px 10px;
    }

    .cart-order-actions {
        padding: 12px 16px 18px;
    }

    /* Panier récapitulatif: presque plein écran */
    .cart-overview-panel {
        width: 95vw;
        max-height: 88vh;
        max-height: 88dvh;
    }

    .cart-overview-header {
        padding: 16px 20px;
    }

    .cart-overview-body {
        padding: 18px 16px;
    }

    /* Article : layout 2 colonnes */
    .cart-article {
        grid-template-columns: 48px 1fr auto;
        grid-template-rows: auto auto;
        gap: 8px;
    }

    .cart-article-image {
        grid-row: 1 / 3;
    }

    .cart-article-controles {
        grid-column: 3;
        grid-row: 1;
    }

    .cart-article-total {
        grid-column: 2;
        grid-row: 2;
        text-align: left;
    }

    .cart-article-suppr {
        grid-column: 3;
        grid-row: 2;
    }
}

/* ── Unités des prestations (heures / km) dans la modale produit ──
   Même habillage que le contrôle Quantité. Deux unités demandées :
   côte à côte (50/50) ; une seule : elle occupe la ligne, centrée. */
.cart-unites-grid {
  display: flex;
  gap: 12px;
  width: 100%;
}
.cart-unite-cell {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.cart-unite-control {
  width: 100%;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 12px;
}
.cart-unite-control .cart-qty-modal {
  width: 30px;
  height: 30px;
  font-size: 1.15rem;
  flex-shrink: 0;
}
.cart-unite-control .cart-qty-input {
  width: 100%;
  min-width: 0;
  font-size: 1.1rem;
}
