/*
Theme Name:   Atcreative Divi 5 Child
Theme URI:    https://www.ludomemo.fr
Description:  Thème enfant Divi 5 pour LUDO MEMO. Contient les variables de charte, le chargement des polices et les éléments décoratifs/personnalisés non reproductibles directement dans le Divi Builder.
Author:       Arbonel Communication
Author URI:   https://www.atcreative.fr
Template:     Divi
Version:      1.3.8
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  atcreative-divi-5-child
*/

/* ==========================================================================
   LUDO MEMO — Variables de charte graphique
   Réutilisables dans le CSS personnalisé des modules Divi (Champ "CSS personnalisé")
   ========================================================================== */
:root {
    /* Violet */
    --lm-violet-dark:   #3D2982;
    --lm-violet-medium: #6B3BB5;
    --lm-violet-light:  #9C59E3;
    --lm-violet-lighter:#BA87F7;
    --lm-violet-pale:   #EDE0FC;

    /* Jaune */
    --lm-yellow:        #FFCF00;
    --lm-yellow-dark:   #FFB300;
    --lm-yellow-pale:   #FFF3C2;

    /* Neutres */
    --lm-black:  #1a1a1a;
    --lm-white:  #ffffff;
    --lm-gray:   #666666;

    /* Polices */
    --lm-font-title: 'Playfair Display', Georgia, serif;
    --lm-font-text:  'Nunito Sans', 'Segoe UI', sans-serif;

    /* Dégradés */
    --lm-gradient-violet: linear-gradient(135deg, #6B3BB5 0%, #9C59E3 100%);
}

/* ==========================================================================
   Échelle typographique globale (filet de sécurité — renforce les presets Divi)
   ========================================================================== */
body {
    font-family: var(--lm-font-text);
    color: var(--lm-black);
    font-size: 15px;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--lm-font-title);
    line-height: 1.2;
}

/* ==========================================================================
   Éléments décoratifs LUDO MEMO
   À activer en ajoutant la classe au module/section dans Divi
   (Réglages avancés > ID et classes CSS > Classe CSS)
   ========================================================================== */

/* --- Blobs flous décoratifs ---
   Usage : sur une Section, ajouter la classe "lm-has-blobs", puis insérer un
   module Code vide avec la classe "lm-blob lm-blob--yellow" (ou --violet).      */
.lm-has-blobs {
    position: relative;
    overflow: hidden;
}
.lm-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.18;
    z-index: 0;
    pointer-events: none;
}
.lm-blob--yellow      { background: var(--lm-yellow); }
.lm-blob--violet      { background: var(--lm-violet-light); }
.lm-blob--violet-dark { background: var(--lm-violet-dark); }

.lm-blob--animated {
    animation: lm-float 9s ease-in-out infinite;
}
.lm-blob--animated-slow {
    animation: lm-float 14s ease-in-out infinite;
}
@keyframes lm-float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%      { transform: translate(20px, -25px) scale(1.08); }
}

/* --- Filigrane (gros chiffre de section : 01, 02, 03) ---
   Usage : ajouter la classe "lm-watermark" + l'attribut data-num dans un module Code,
   ou utiliser directement un module Texte stylé.                                */
.lm-watermark {
    position: absolute;
    font-family: var(--lm-font-title);
    font-weight: 900;
    font-size: clamp(6rem, 14vw, 12rem);
    line-height: 1;
    color: var(--lm-violet-pale);
    opacity: 0.5;
    z-index: 0;
    pointer-events: none;
    user-select: none;
}

/* --- Cadre photo "polaroïd" (section Les Jeux) --- */
.lm-polaroid {
    background: #fff;
    padding: 1rem 1rem 2.5rem;
    border-radius: 6px;
    box-shadow: 0 20px 50px -12px rgba(61, 41, 130, 0.30);
    transform: rotate(-3deg);
    transition: transform 0.4s ease;
}
.lm-polaroid:hover { transform: rotate(0deg); }

/* --- Badge / eyebrow (sur-titre de section) --- */
.lm-eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--lm-violet-medium);
    margin-bottom: 0.75rem;
}

/* --- Pastille avatar témoignage (initiales sur fond dégradé) --- */
.lm-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--lm-font-title);
    font-weight: 700;
    color: #fff;
    background: var(--lm-gradient-violet);
    flex-shrink: 0;
}

/* ==========================================================================
   Header (Theme Builder)
   La mise en page (logo / menu / panier) est gérée NATIVEMENT dans Divi
   (en-tête à 3 colonnes). On ne garde ici que le soulignement de l'élément
   de menu ACTIF (comme le prototype) — aucune règle de structure imposée.
   ========================================================================== */
/* Élément de menu actif : barre violette sous le lien (0 → 100%), comme le prototype */
.et_pb_menu .et-menu > li > a { position: relative; }
.et_pb_menu .et-menu > li > a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -6px;
    width: 0;
    height: 3px;
    border-radius: 2px;
    background: var(--lm-violet-medium);
    transform: translateX(-50%);
    transition: width 0.25s ease;
}
.et_pb_menu .et-menu > li.current-menu-item > a::after,
.et_pb_menu .et-menu > li.current-menu-ancestor > a::after,
.et_pb_menu .et-menu > li.current_page_item > a::after,
.et_pb_menu .et-menu > li > a:hover::after {
    width: 100%;
}
.et_pb_menu .et-menu > li.current-menu-item > a,
.et_pb_menu .et-menu > li.current-menu-ancestor > a {
    color: var(--lm-violet-medium) !important;
}

/* ==========================================================================
   Bouton « Mon panier » (shortcode [ludomemo_cart]) — voir inc/cart-menu.php
   ========================================================================== */

.lm-cart {
    position: relative;
    display: inline-flex !important;   /* prioritaire sur le display:block du menu Divi */
    align-items: center;
    vertical-align: middle;
    gap: 0.5rem;
    padding: 0.6rem 1.4rem;
    line-height: 1;
    border-radius: 50px;
    font-family: var(--lm-font-text);
    font-size: 15px;
    font-weight: 700;
    color: var(--lm-violet-dark);
    background: var(--lm-yellow);               /* jaune plein comme le prototype */
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.lm-cart:hover {
    background: var(--lm-yellow-dark);
    color: var(--lm-violet-dark);
    transform: scale(1.05);
}

.lm-cart__icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.lm-cart__label { line-height: 1; }

/* Compteur = badge rond violet foncé dans le coin HAUT-DROIT (comme le prototype) */
.lm-cart__count {
    position: absolute;
    top: -5px;
    right: -5px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--lm-violet-dark);
    color: var(--lm-white);
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}

/* Panier vide : pas de pastille (comme le prototype, juste « Mon panier ») */
.lm-cart__count--empty,
.lm-cart--empty .lm-cart__count {
    display: none;
}

/* Sur mobile : masquer le libellé, garder icône + compteur */
@media (max-width: 980px) {
    .lm-cart { padding: 0.5rem 0.75rem; }
    .lm-cart__label { display: none; }
}

/* ==========================================================================
   Footer — largeurs de colonnes (Divi ne recalcule pas les fractions via REST,
   on reproduit la répartition du prototype : marque large + 3 colonnes liens)
   ========================================================================== */
@media (min-width: 981px) {
  /* Gap explicite + largeurs qui, AVEC les 3 gaps, totalisent 100% pile.
     (35 + 16 + 16 + 21 = 88%) + (3 × 4% = 12%) = 100% → aucun débordement. */
  .et_pb_row_0_tb_footer { column-gap: 4% !important; }
  .et_pb_row_0_tb_footer > .et_pb_column { margin: 0 !important; }
  .et_pb_row_0_tb_footer > .et_pb_column:nth-child(1) { flex: 0 0 35% !important; max-width: 35% !important; }
  .et_pb_row_0_tb_footer > .et_pb_column:nth-child(2),
  .et_pb_row_0_tb_footer > .et_pb_column:nth-child(3) { flex: 0 0 16% !important; max-width: 16% !important; }
  .et_pb_row_0_tb_footer > .et_pb_column:nth-child(4) { flex: 0 0 21% !important; max-width: 21% !important; }
}
/* Logo du footer : taille raisonnable (sinon rendu pleine largeur de colonne) */
.et_pb_row_0_tb_footer .et_pb_image img {
  max-width: 150px !important;
  width: auto !important;
  height: auto !important;
}
/* Footer : texte et liens CLAIRS sur fond violet foncé (le lien global violet était illisible) */
[class*="_tb_footer"] .et_pb_text,
[class*="_tb_footer"] .et_pb_text p,
[class*="_tb_footer"] .et_pb_text li,
[class*="_tb_footer"] .et_pb_text a {
  color: rgba(255, 255, 255, 0.82) !important;
}
[class*="_tb_footer"] .et_pb_text a:hover { color: #ffffff !important; }
/* on garde les titres de colonnes en jaune */
[class*="_tb_footer"] h4 { color: var(--lm-yellow) !important; }

/* ==========================================================================
   Responsive — empilement des colonnes sur mobile/tablette
   (les colonnes générées ne portent pas toujours les variantes mobiles Divi)
   ========================================================================== */
/* Tablette : les grilles de 3-4 colonnes passent en 2 colonnes */
@media (max-width: 980px) {
  .et_pb_row:not(.et_pb_row_0_tb_header),
  .et_pb_row_inner {
    flex-wrap: wrap !important;
  }
  .et_pb_row:not(.et_pb_row_0_tb_header) > .et_pb_column,
  .et_pb_row_inner > .et_pb_column_inner {
    margin-bottom: 24px;
  }
}
/* Mobile : tout s'empile en pleine largeur (sauf le header) */
@media (max-width: 767px) {
  /* les lignes flex doivent pouvoir passer à la ligne pour empiler les colonnes */
  .et_pb_row:not(.et_pb_row_0_tb_header),
  .et_pb_row_inner {
    flex-wrap: wrap !important;
  }
  .et_pb_row:not(.et_pb_row_0_tb_header) > .et_pb_column,
  .et_pb_row_inner > .et_pb_column_inner {
    width: 100% !important;
    max-width: 100% !important;
    flex: 0 0 100% !important;
    margin-left: 0 !important;
  }
  /* les vignettes de galerie produit restent en ligne (4 colonnes) */
  .et_pb_row_inner.et-thumbs > .et_pb_column_inner { width: 23% !important; flex: 0 0 23% !important; }
}
/* (Le header est géré nativement par le template Divi 3 colonnes — pas de verrou CSS ici.) */

/* ==========================================================================
   WooCommerce — aux couleurs LUDO MEMO (pages panier / commande / compte /
   connexion : générées par WooCommerce, donc stylées en CSS thème enfant)
   ========================================================================== */
/* Boutons WooCommerce → violet, pilule */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.woocommerce #place_order,
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button,
.woocommerce-MyAccount-content .button {
    background: var(--lm-violet-medium) !important;
    color: #fff !important;
    border: none !important;
    border-radius: 50px !important;
    font-family: var(--lm-font-text) !important;
    font-weight: 700 !important;
    padding: 13px 30px !important;
    text-transform: none !important;
    transition: background 0.2s ease, transform 0.2s ease;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce #place_order:hover,
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button:hover {
    background: var(--lm-violet-dark) !important;
    transform: translateY(-1px);
}

/* Supprimer l'icône flèche Divi (::after) injectée sur les boutons WooCommerce
   et le décalage du texte au survol qui va avec. */
.woocommerce a.button::after,
.woocommerce button.button::after,
.woocommerce input.button::after,
.woocommerce a.button.alt::after,
.woocommerce button.button.alt::after,
.woocommerce input.button.alt::after,
.woocommerce button.single_add_to_cart_button.button::after,
.woocommerce #respond input#submit::after,
.woocommerce #respond input#submit.alt::after,
.woocommerce #place_order::after,
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button::after,
.woocommerce-page a.button::after,
.woocommerce-page button.button::after,
.woocommerce-page input.button::after {
    display: none !important;
    content: none !important;
    margin: 0 !important;
    opacity: 0 !important;
}

/* Liens WooCommerce */
.woocommerce a:not(.button) { color: var(--lm-violet-medium); }

/* Champs de formulaire (panier, commande, compte, connexion) */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce-account input.input-text,
.woocommerce .select2-container .select2-selection {
    border: 1px solid var(--lm-gray-medium) !important;
    border-radius: 8px !important;
    padding: 12px 14px !important;
    background: #fff !important;
}

/* Tableaux (panier, commande) */
.woocommerce table.shop_table {
    border: 1px solid var(--lm-gray-medium);
    border-radius: 14px;
    overflow: hidden;
    border-collapse: separate;
}
.woocommerce table.shop_table thead th {
    background: var(--lm-violet-pale);
    color: var(--lm-violet-dark);
    font-family: var(--lm-font-text);
    font-weight: 700;
}
.woocommerce .cart_totals h2,
.woocommerce-checkout #order_review_heading,
.woocommerce-billing-fields h3,
.woocommerce #payment .place-order { color: var(--lm-violet-dark); }

/* Encadrés totaux / récap commande */
.woocommerce-checkout #order_review,
.woocommerce .cart_totals {
    background: #faf8ff;
    border: 1px solid var(--lm-violet-pale);
    border-radius: 14px;
    padding: 20px;
}

/* Messages / notices WooCommerce → accent violet */
.woocommerce-message, .woocommerce-info, .woocommerce-noreviews, .woocommerce-error {
    border-top-color: var(--lm-violet-medium) !important;
    background: #faf8ff;
}
.woocommerce-message::before, .woocommerce-info::before { color: var(--lm-violet-medium) !important; }

/* MON COMPTE : navigation latérale en onglets stylés */
.woocommerce-account .woocommerce-MyAccount-navigation ul { list-style: none !important; margin: 0; padding: 0; }
.woocommerce-account .woocommerce-MyAccount-navigation li { margin: 0 0 8px; list-style: none !important; }
.woocommerce-account .woocommerce-MyAccount-navigation li::before { display: none !important; content: none !important; }
.woocommerce-account .woocommerce-MyAccount-navigation li a {
    display: block;
    padding: 11px 18px;
    border-radius: 10px;
    background: #f4f1fb;
    color: var(--lm-violet-dark);
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}
.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a,
.woocommerce-account .woocommerce-MyAccount-navigation li a:hover {
    background: var(--lm-gradient-violet);
    color: #fff;
}

/* CONNEXION / INSCRIPTION : encadrés */
.woocommerce-account .u-columns { display: flex; gap: 30px; flex-wrap: wrap; }
.woocommerce-account .u-columns > div { flex: 1 1 320px; }
.woocommerce form.login,
.woocommerce form.register,
.woocommerce form.checkout_coupon,
.woocommerce form.lost_reset_password {
    border: 1px solid var(--lm-gray-medium);
    border-radius: 14px;
    padding: 26px;
    box-shadow: 0 8px 25px -5px rgba(61,41,130,0.10);
}

/* WooCommerce Blocks (Cart Block / Checkout Block Gutenberg) → boutons violets */
.wc-block-components-button:not(.is-link),
.wp-block-woocommerce-cart .wc-block-cart__submit-button,
.wc-block-cart__submit-button,
.wc-block-components-checkout-place-order-button,
.wc-block-components-totals-coupon__button {
    background: var(--lm-violet-medium) !important;
    color: #fff !important;
    border-radius: 50px !important;
    font-weight: 700 !important;
}
.wc-block-components-button:not(.is-link):hover,
.wc-block-cart__submit-button:hover,
.wc-block-components-checkout-place-order-button:hover {
    background: var(--lm-violet-dark) !important;
}
.wc-block-components-product-price, .wc-block-components-totals-item__value { color: var(--lm-violet-dark); }
.wc-block-cart__totals-title, .wc-block-checkout__main h2 { color: var(--lm-violet-dark) !important; }
/* liens du bloc (codes promo, etc.) */
.wc-block-components-button.is-link { color: var(--lm-violet-medium) !important; }

/* --- Page Panier (Cart Block) : cartes à la charte, comme le prototype --- */
/* Slot woocommerce-services cassé (erreur JS « ...reading 'notices' ») → masqué */
.wc-block-components-order-meta { display: none !important; }

/* Carte « article(s) » (tableau de gauche) */
.wp-block-woocommerce-cart .wc-block-cart-items {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(45, 27, 105, 0.08);
    overflow: hidden;
}
.wp-block-woocommerce-cart .wc-block-cart-items td,
.wp-block-woocommerce-cart .wc-block-cart-items th { border-color: #efedf6 !important; }

/* Carte « Résumé de commande » UNIFIÉE (colonne de droite) — comme le prototype */
.wp-block-woocommerce-cart .wc-block-cart__sidebar {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(45, 27, 105, 0.08);
    padding: 26px 28px !important;
}
/* Les sous-blocs de totaux ne sont plus des cartes individuelles */
.wp-block-woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-wrapper {
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    padding: 0 !important;
}
/* Wrapper devenu vide (slot order-meta masqué) → ne pas réserver d'espace */
.wp-block-woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-wrapper:empty,
.wp-block-woocommerce-cart .wc-block-cart__sidebar .wc-block-components-totals-wrapper.slot-wrapper { display: none; }
.wc-block-cart__totals-title {
    border-bottom: 2px solid var(--lm-violet-pale, #efe9fb);
    padding-bottom: 12px;
    display: block;
}
.wc-block-components-totals-item__value,
.wc-block-components-totals-footer-item .wc-block-components-totals-item__value {
    color: var(--lm-violet-dark) !important;
    font-weight: 700;
}

/* Mention « Paiement 100% sécurisé » sous le bouton Valider (comme le prototype) */
.wc-block-cart__submit::after {
    content: "🔒 Paiement 100% sécurisé";
    display: block;
    text-align: center;
    font-size: 13px;
    color: #6b6b80;
    margin-top: 14px;
}

/* Réassurance panier (modules Blurb Divi) : icônes dans cercles pastel alternés (prototype) */
.woocommerce-cart .et_pb_blurb .et_pb_main_blurb_image { margin-bottom: 16px; }
.woocommerce-cart .et_pb_blurb .et_pb_main_blurb_image .et-pb-icon {
  width: 76px !important;
  height: 76px !important;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #EDE0FC; /* violet pâle (cols impaires) */
}
.woocommerce-cart .et_pb_column:nth-of-type(2n) .et_pb_blurb .et_pb_main_blurb_image .et-pb-icon {
  background: #FFF1C2; /* jaune pâle (cols paires) */
}

/* Tableau panier (cart classique Divi) en carte blanche arrondie + entête doux */
.woocommerce-cart table.shop_table {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(45, 27, 105, 0.08);
  overflow: hidden;
  border: none !important;
}
.woocommerce-cart table.shop_table thead th {
  background: var(--lm-violet-pale);
  color: var(--lm-violet-dark);
}
/* Bouton « Appliquer » du code promo en JAUNE (comme le prototype) */
.woocommerce-cart .coupon button[name="apply_coupon"],
.woocommerce-cart button[name="apply_coupon"],
.woocommerce-cart input[name="apply_coupon"] {
  background: var(--lm-yellow) !important;
  color: var(--lm-violet-dark) !important;
}
.woocommerce-cart .coupon button[name="apply_coupon"]:hover,
.woocommerce-cart button[name="apply_coupon"]:hover {
  background: #f5c400 !important;
}

/* ---- UX panier : boutons homogènes & soignés (fini les gros boutons) ---- */
/* Taille commune raisonnable pour TOUS les boutons du panier */
.woocommerce-cart .checkout-button,
.woocommerce-cart button[name="apply_coupon"],
.woocommerce-cart button[name="update_cart"] {
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  padding: 12px 24px !important;
  border-radius: 50px !important;
  min-height: 0 !important;
  letter-spacing: 0 !important;
  width: auto;
}
/* « Valider la commande » : pleine largeur de la carte, bien centré */
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button {
  display: block;
  width: 100%;
  text-align: center;
  padding: 15px 24px !important;
  font-size: 15px !important;
}
/* Rangée d'actions : champ code promo + Appliquer + Mettre à jour CÔTE À CÔTE.
   NB : on garde le <td> en cellule de tableau (pas display:flex, sinon le
   colspan casse la largeur du tableau) ; on aligne en INLINE. */
.woocommerce-cart td.actions {
  text-align: left;
  padding: 18px 12px !important;
  white-space: nowrap;
}
.woocommerce-cart td.actions .coupon {
  display: inline-flex !important;
  align-items: center;
  gap: 10px;
  float: none !important;
  margin: 0 10px 0 0 !important;
  vertical-align: middle;
}
.woocommerce-cart td.actions .coupon input#coupon_code {
  width: 180px;
  border: 2px solid #e7e3f2 !important;
  border-radius: 10px !important;
  padding: 11px 16px !important;
  margin: 0 !important;
}
.woocommerce-cart td.actions button[name="apply_coupon"] { white-space: nowrap; }
/* « Mettre à jour » : secondaire discret (contour), poussé à droite */
.woocommerce-cart td.actions button[name="update_cart"] {
  background: #fff !important;
  color: var(--lm-violet-medium) !important;
  border: 2px solid var(--lm-violet-medium) !important;
  font-size: 13px !important;
  padding: 9px 18px !important;
  float: none !important;
  white-space: nowrap;
  display: inline-block;
  vertical-align: middle;
}
.woocommerce-cart td.actions button[name="update_cart"]:hover {
  background: var(--lm-violet-medium) !important;
  color: #fff !important;
}
.woocommerce-cart td.actions button[name="update_cart"]:disabled { opacity: .4; }

/* Tableau : largeur AUTO (fini le fixed qui casse les mots), cellules aérées */
.woocommerce-cart table.shop_table { table-layout: auto !important; }
.woocommerce-cart table.shop_table td,
.woocommerce-cart table.shop_table th { padding: 16px 12px !important; vertical-align: middle; }
/* Colonnes étroites pour supprimer + miniature, libellés verbeux masqués */
.woocommerce-cart table.shop_table th.product-remove,
.woocommerce-cart table.shop_table td.product-remove { width: 34px; padding-left: 6px !important; padding-right: 6px !important; }
.woocommerce-cart table.shop_table th.product-thumbnail,
.woocommerce-cart table.shop_table td.product-thumbnail { width: 92px !important; }
.woocommerce-cart table.shop_table th.product-remove,
.woocommerce-cart table.shop_table th.product-thumbnail { font-size: 0 !important; }
/* Prix / sous-total ne se coupent pas */
.woocommerce-cart table.shop_table td.product-price,
.woocommerce-cart table.shop_table td.product-subtotal,
.woocommerce-cart table.shop_table th.product-price,
.woocommerce-cart table.shop_table th.product-subtotal { white-space: nowrap; }
.woocommerce-cart table.shop_table td.product-name { min-width: 170px; word-break: normal; overflow-wrap: normal; }
.woocommerce-cart table.shop_table td.product-name a {
  font-weight: 700;
  color: var(--lm-violet-dark) !important;
  font-size: 15px;
}
.woocommerce-cart table.shop_table td.product-name a:hover { color: var(--lm-violet-medium) !important; }
/* Image produit : forcée visible (une règle tierce la réduisait à 8px) */
.woocommerce-cart table.shop_table td.product-thumbnail img,
.woocommerce-cart td.product-thumbnail a img,
.woocommerce-cart .product-thumbnail img {
  width: 72px !important;
  min-width: 72px !important;
  height: 72px !important;
  max-width: none !important;
  object-fit: cover;
  border-radius: 10px !important;
  display: inline-block !important;
}
/* Champ quantité propre */
.woocommerce-cart .quantity input.qty {
  border: 2px solid #e7e3f2 !important;
  border-radius: 8px !important;
  padding: 8px 6px !important;
  height: auto;
}
/* Bouton « supprimer » (croix) : petit et discret */
.woocommerce-cart td.product-remove { width: 30px !important; }
.woocommerce-cart td.product-remove a.remove {
  color: var(--lm-violet-medium) !important;
  font-size: 15px !important;
  width: 22px !important;
  height: 22px !important;
  line-height: 22px !important;
  display: inline-block;
  text-align: center;
}
.woocommerce-cart td.product-remove a.remove:hover { background: transparent !important; color: #d63333 !important; }

/* Panier mobile : on libère le nowrap et on empile proprement (pas de scroll) */
@media (max-width: 767px) {
  .woocommerce-cart .et_pb_wc_cart_products,
  .woocommerce-cart .woocommerce { overflow-x: hidden; }
  .woocommerce-cart table.shop_table { width: 100% !important; max-width: 100% !important; }
  /* annuler tous les nowrap hérités du desktop sur mobile */
  .woocommerce-cart table.shop_table td,
  .woocommerce-cart table.shop_table th { white-space: normal !important; padding: 10px 8px !important; }
  .woocommerce-cart td.actions { white-space: normal !important; text-align: center; }
  .woocommerce-cart td.actions .coupon { display: flex !important; width: 100%; margin: 0 0 10px !important; }
  .woocommerce-cart td.actions .coupon input#coupon_code { flex: 1 1 auto; width: auto; min-width: 0; }
  .woocommerce-cart td.actions button[name="apply_coupon"] { flex: 0 0 auto; }
  .woocommerce-cart td.actions button[name="update_cart"] { width: 100%; }
  .woocommerce-cart table.shop_table td.product-name { min-width: 0 !important; }
  .woocommerce-cart table.shop_table td.product-thumbnail { width: 60px !important; }
  .woocommerce-cart table.shop_table td.product-thumbnail img,
  .woocommerce-cart .product-thumbnail img { width: 50px !important; min-width: 50px !important; height: 50px !important; }
}

/* Extras de la page Panier (lien « Continuer » + réassurance) — comme le prototype */
.lm-cart-extras { max-width: 1080px; margin: 8px auto 0; padding: 0 16px; }
.lm-cart-continue { margin: 0 0 40px; }
.lm-cart-continue a { color: var(--lm-violet-medium) !important; font-weight: 700; text-decoration: none; }
.lm-cart-continue a:hover { color: var(--lm-violet-dark) !important; }
.lm-cart-reassurance {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    justify-content: space-between;
    border-top: 1px solid #efedf6;
    padding-top: 32px;
    margin-bottom: 8px;
}
.lm-reassure { flex: 1 1 220px; text-align: center; }
.lm-reassure-ico { font-size: 30px; display: block; margin-bottom: 8px; }
.lm-reassure h4 { font-family: 'Playfair Display', Georgia, serif; font-size: 17px; color: var(--lm-violet-dark); margin: 0 0 4px; }
.lm-reassure p { font-size: 14px; color: #6b6b80; margin: 0; }

/* Fiche produit : pleine largeur (retirer la sidebar de widgets par défaut) */
.single-product #sidebar { display: none !important; }
.single-product #left-area { width: 100% !important; padding-right: 0 !important; }
.single-product #content-area .container,
.archive.woocommerce #content-area .container { max-width: 1200px; }
/* ==========================================================================
   Galerie produit : image principale à hauteur maîtrisée + vignette active violette
   ========================================================================== */
.single-product .woocommerce-product-gallery__image a { cursor: pointer; }

/* Image principale : quelle que soit l'image affichée, hauteur plafonnée, sans déformation */
.single-product .woocommerce-product-gallery__wrapper { text-align: center; }
.single-product .woocommerce-product-gallery__image img,
.single-product .woocommerce-product-gallery__image img.wp-post-image {
  max-height: 460px !important;
  width: 100% !important;
  height: auto !important;
  object-fit: contain;
  border-radius: 14px;
  margin: 0 auto;
}
/* Le zoom (loupe) doit suivre la même contrainte */
.single-product .woocommerce-product-gallery__image img.zoomImg { object-fit: contain; }

/* Vignettes : la vignette ACTIVE est entourée d'une bordure violette */
.single-product .flex-control-thumbs li img {
  border: 2px solid transparent;
  border-radius: 10px;
  opacity: .6;
  box-sizing: border-box;
  cursor: pointer;
  transition: opacity .2s ease, border-color .2s ease;
}
.single-product .flex-control-thumbs li img:hover { opacity: 1; }
.single-product .flex-control-thumbs li img.flex-active,
.single-product .flex-control-thumbs li.flex-active img {
  border-color: var(--lm-violet-medium, #6B3BB5);
  opacity: 1;
}

/* Sélecteur de quantité « − [n] + » (boutons injectés par inc/qty-stepper.php) */
.single-product .quantity.lm-qty-ready {
  display: inline-flex !important;
  flex-direction: row !important;   /* annule un éventuel flex-direction:column de Divi */
  flex-wrap: nowrap !important;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: auto !important;
  max-width: none !important;
  background: #efedf5;
  border-radius: 14px;
  padding: 5px;
}
/* Les 3 éléments restent sur une ligne, à leur taille (pas de pleine largeur) */
.single-product .quantity.lm-qty-ready > .lm-qty-btn,
.single-product .quantity.lm-qty-ready > input.qty {
  flex: 0 0 auto !important;
  margin: 0 !important;
  float: none !important;
}
.single-product .quantity .lm-qty-btn {
  width: 42px;
  height: 42px;
  border: none;
  background: transparent;
  color: var(--lm-violet-dark, #3D2982);
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease;
}
.single-product .quantity .lm-qty-btn:hover { background: rgba(107, 59, 181, .12); }
.single-product .quantity.lm-qty-ready input.qty {
  width: 56px;
  height: 42px;
  text-align: center;
  border: none !important;
  background: #fff !important;
  border-radius: 10px !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .08);
  font-size: 16px;
  font-weight: 700;
  color: #1a1a1a;
  padding: 0 !important;
  -moz-appearance: textfield;
}
.single-product .quantity.lm-qty-ready input.qty::-webkit-outer-spin-button,
.single-product .quantity.lm-qty-ready input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* ==========================================================================
   Échelle typographique COHÉRENTE inter-pages (évite les décalages de titres)
   - Titres de section H2 : 32px uniforme partout
   - Titres de page H1 : 38px (sauf le hero de l'accueil, plus grand)
   - Les pastilles « eyebrow » sont des H3 → non impactées
   ========================================================================== */
.et_pb_heading h2,
.et_pb_text h2 {
  font-size: 32px !important;
  line-height: 1.25 !important;
}
body:not(.home) .et_pb_heading h1 {
  font-size: 38px !important;
  line-height: 1.18 !important;
}
@media (max-width: 980px) {
  .et_pb_heading h2,
  .et_pb_text h2 { font-size: 26px !important; }
}
@media (max-width: 767px) {
  .et_pb_heading h2,
  .et_pb_text h2 { font-size: 22px !important; }
  body:not(.home) .et_pb_heading h1 { font-size: 28px !important; }
}

/* ==========================================================================
   Ajustements généraux
   ========================================================================== */
html { scroll-behavior: smooth; }

/* Liens panier / header : transition douce */
.lm-navbar a { transition: color 0.2s ease; }
