/* ==========================================================================
   Lenor Macaire — côté acheteur (accueil, catalogue, fiche produit, panier, commande, compte)
   ========================================================================== */

body.boutique { padding-bottom: var(--lm-barre-h); }
@media (min-width: 992px) { body.boutique { padding-bottom: 0; } }

/* ----------------------------------------------------------------- Bandeau du haut */
.bandeau-info { background: var(--lm-encre); color: #D2D2D7; font-size: 0.8rem; }
.bandeau-info .lm-conteneur { display: flex; justify-content: space-between; align-items: center; min-height: 32px; gap: 12px; }
.bandeau-info a { color: #fff; }
.bandeau-info a:hover { color: var(--lm-orange); }

/* ----------------------------------------------------------------- En-tête */
.entete { background: #fff; border-bottom: 1px solid var(--lm-filet); position: sticky; top: 0; z-index: 1030; }
.entete-ligne { display: flex; align-items: center; gap: 12px; min-height: var(--lm-entete-h); }
.recherche { position: relative; flex: 1; }
.recherche input { width: 100%; height: 42px; border: 1px solid #D2D2D7; border-radius: var(--lm-rayon); padding: 0 48px 0 14px; font-size: 15px; background: var(--lm-fond); }
.recherche input:focus { outline: none; border-color: var(--lm-encre); background: #fff; }
.recherche button { position: absolute; right: 4px; top: 4px; bottom: 4px; width: 40px; border: 0; border-radius: 4px; background: var(--lm-orange); color: #fff; }
.suggestions { position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); box-shadow: 0 10px 30px rgba(0,0,0,.08); z-index: 1040; max-height: 70vh; overflow-y: auto; }
.suggestions a { display: flex; gap: 10px; align-items: center; padding: 8px 12px; color: var(--lm-encre); border-bottom: 1px solid var(--lm-filet); }
.suggestions a:last-child { border-bottom: 0; }
.suggestions a:hover { background: var(--lm-fond); }
.suggestions .titre-groupe { padding: 8px 12px 4px; font-size: 0.75rem; text-transform: uppercase; color: var(--lm-gris); letter-spacing: .04em; }
.entete-actions { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.entete-action { position: relative; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 8px; color: var(--lm-encre); border-radius: var(--lm-rayon); font-size: 0.72rem; }
.entete-action .bi { font-size: 1.3rem; line-height: 1; }
.entete-action:hover { background: var(--lm-fond); color: var(--lm-encre); }
.pastille-compte { position: absolute; top: 2px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--lm-orange); color: #fff; font-size: 0.7rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.pastille-compte:empty, .pastille-compte[data-nombre="0"] { display: none; }
.entete-recherche-mobile { padding: 0 0 10px; }
@media (min-width: 992px) { .entete-recherche-mobile { display: none; } }

/* Menu des rayons */
.rayons { background: #fff; border-bottom: 1px solid var(--lm-filet); }
.rayons .lm-conteneur { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.rayons .lm-conteneur::-webkit-scrollbar { display: none; }
.rayons a { padding: 10px 12px; white-space: nowrap; color: var(--lm-texte); font-weight: 500; font-size: 0.92rem; border-bottom: 2px solid transparent; }
.rayons a:hover, .rayons a.actif { color: var(--lm-encre); border-bottom-color: var(--lm-orange); }
.rayons a.rayon-flash { color: var(--lm-rouge); }

/* Barre d'onglets en bas (téléphone) */
.barre-bas { position: fixed; left: 0; right: 0; bottom: 0; height: var(--lm-barre-h); background: #fff; border-top: 1px solid var(--lm-filet); display: flex; z-index: 1030; padding-bottom: env(safe-area-inset-bottom); }
.barre-bas a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--lm-gris); font-size: 0.7rem; font-weight: 500; position: relative; }
.barre-bas a .bi { font-size: 1.3rem; line-height: 1; }
.barre-bas a.actif { color: var(--lm-orange); }
.barre-bas .pastille-compte { top: 6px; right: calc(50% - 22px); }
@media (min-width: 992px) { .barre-bas { display: none; } }

/* ----------------------------------------------------------------- Accueil */
.accueil-tete { background: #fff; border-bottom: 1px solid var(--lm-filet); }
.accueil-tete .grille { display: grid; gap: 16px; padding: 20px 0; }
.accroche h1 { font-size: 1.7rem; line-height: 1.15; margin-bottom: 10px; }
.accroche h1 em { font-style: normal; color: var(--lm-orange); }
.accroche p { color: var(--lm-gris); margin-bottom: 16px; }
.accroche .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.accroche-chiffres { display: flex; gap: 24px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--lm-filet); }
.accroche-chiffres div { font-size: 0.8rem; color: var(--lm-gris); }
.accroche-chiffres strong { display: block; font-size: 1.25rem; color: var(--lm-encre); font-weight: 700; }
.carrousel-diapo { border-radius: var(--lm-rayon); overflow: hidden; background: var(--lm-fond); aspect-ratio: 16 / 9; }
.carrousel-diapo img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 992px) {
    .accueil-tete .grille { grid-template-columns: 5fr 6fr; align-items: center; padding: 32px 0; gap: 40px; }
    .accroche h1 { font-size: 2.4rem; }
}
.atouts { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--lm-filet); border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); overflow: hidden; }
.atouts > div { background: #fff; padding: 12px; display: flex; gap: 10px; align-items: flex-start; font-size: 0.85rem; }
.atouts .bi { font-size: 1.25rem; color: var(--lm-encre); }
.atouts strong { display: block; color: var(--lm-encre); font-size: 0.9rem; }
@media (min-width: 992px) { .atouts { grid-template-columns: repeat(4, 1fr); } }

/* Grille de catégories */
.grille-rayons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rayon-carte { background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); padding: 12px 8px; text-align: center; color: var(--lm-encre); display: flex; flex-direction: column; align-items: center; gap: 6px; }
.rayon-carte:hover { border-color: var(--lm-encre); color: var(--lm-encre); }
.rayon-carte .rayon-visuel { width: 52px; height: 52px; border-radius: 50%; overflow: hidden; background: var(--lm-fond); display: flex; align-items: center; justify-content: center; }
.rayon-carte .rayon-visuel img { width: 100%; height: 100%; object-fit: cover; }
.rayon-carte .rayon-visuel .bi { font-size: 1.4rem; color: var(--lm-encre); }
.rayon-carte .rayon-nom { font-size: 0.82rem; font-weight: 500; line-height: 1.2; }
.rayon-carte .rayon-nb { font-size: 0.72rem; color: var(--lm-gris); }
@media (min-width: 768px) { .grille-rayons { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 992px) { .grille-rayons { grid-template-columns: repeat(8, 1fr); } }

/* Bandeau vente flash */
.flash { background: var(--lm-encre); color: #fff; border-radius: var(--lm-rayon); padding: 14px 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.flash h2 { color: #fff; margin: 0; font-size: 1.15rem; display: flex; align-items: center; gap: 8px; }
.flash h2 .bi { color: var(--lm-orange); }
.compte-a-rebours { display: flex; gap: 4px; font-variant-numeric: tabular-nums; }
.compte-a-rebours span { background: #fff; color: var(--lm-encre); border-radius: 4px; padding: 2px 6px; font-weight: 700; min-width: 32px; text-align: center; }
.flash a { color: #fff; }

/* ----------------------------------------------------------------- Cartes produit */
.grille-produits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (min-width: 576px) { .grille-produits { gap: 12px; } }
@media (min-width: 768px) { .grille-produits { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 992px) { .grille-produits { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .grille-produits.cinq { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.defilant { display: grid; grid-auto-flow: column; grid-auto-columns: 46%; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px; scrollbar-width: thin; }
.defilant > * { scroll-snap-align: start; }
@media (min-width: 768px) { .defilant { grid-auto-columns: 31%; gap: 12px; } }
@media (min-width: 992px) { .defilant { grid-auto-columns: 19%; } }

.carte-produit { background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); overflow: hidden; display: flex; flex-direction: column; position: relative; min-width: 0; }
.carte-produit:hover { border-color: #C7C7CC; }
.carte-produit .cp-visuel { display: block; aspect-ratio: 1 / 1; background: var(--lm-fond); position: relative; overflow: hidden; }
.carte-produit .cp-visuel img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.carte-produit:hover .cp-visuel img { transform: scale(1.03); }
.carte-produit .cp-badges { position: absolute; top: 8px; left: 8px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.badge-lm { display: inline-block; font-size: 0.7rem; font-weight: 700; padding: 2px 6px; border-radius: 4px; background: #fff; color: var(--lm-encre); border: 1px solid var(--lm-filet); }
.badge-lm.gros { background: var(--lm-encre); color: #fff; border-color: var(--lm-encre); }
.badge-lm.flash { background: var(--lm-orange); color: #fff; border-color: var(--lm-orange); }
.badge-lm.epuise { background: #fff; color: var(--lm-rouge); }
.carte-produit .cp-favori { position: absolute; top: 6px; right: 6px; width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.92); border: 0; color: var(--lm-encre); display: flex; align-items: center; justify-content: center; }
.carte-produit .cp-favori.actif { color: var(--lm-rouge); }
.carte-produit .cp-corps { padding: 10px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.carte-produit .cp-boutique { font-size: 0.75rem; color: var(--lm-gris); }
.carte-produit .cp-nom { font-size: 0.9rem; color: var(--lm-encre); font-weight: 500; line-height: 1.3; min-height: 2.6em; }
.carte-produit .cp-nom:hover { color: var(--lm-orange); }
.carte-produit .cp-prix { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 6px; margin-top: auto; }
.carte-produit .cp-prix strong { font-size: 1.05rem; color: var(--lm-encre); font-weight: 700; }
.carte-produit .cp-prix s { font-size: 0.8rem; color: var(--lm-gris); }
.carte-produit .cp-gros { font-size: 0.75rem; color: var(--lm-gris); }
.carte-produit .cp-action { margin-top: 6px; }
.carte-produit .cp-action .btn { width: 100%; padding: 0.4rem; font-size: 0.85rem; }

/* ----------------------------------------------------------------- Catalogue */
.catalogue { display: grid; gap: 16px; }
@media (min-width: 992px) { .catalogue { grid-template-columns: 250px 1fr; align-items: start; } }
.panneau-filtres { background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); }
.panneau-filtres .groupe { padding: 14px 16px; border-bottom: 1px solid var(--lm-filet); }
.panneau-filtres .groupe:last-child { border-bottom: 0; }
.panneau-filtres h3 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: .04em; color: var(--lm-gris); margin-bottom: 8px; }
.panneau-filtres .lien-filtre { display: flex; justify-content: space-between; padding: 4px 0; color: var(--lm-texte); font-size: 0.92rem; }
.panneau-filtres .lien-filtre.actif { color: var(--lm-encre); font-weight: 600; }
.barre-catalogue { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.barre-catalogue .form-select { width: auto; padding: 0.4rem 2rem 0.4rem 0.7rem; font-size: 0.9rem; }
.filtres-actifs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.filtres-actifs a { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border: 1px solid var(--lm-filet); border-radius: 4px; background: #fff; font-size: 0.82rem; color: var(--lm-encre); }

/* ----------------------------------------------------------------- Fiche produit */
.fiche { display: grid; gap: 16px; }
@media (min-width: 992px) { .fiche { grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; } }
.galerie-principale { aspect-ratio: 1 / 1; background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); overflow: hidden; }
.galerie-principale img { width: 100%; height: 100%; object-fit: contain; }
.galerie-vignettes { display: flex; gap: 8px; margin-top: 8px; overflow-x: auto; }
.galerie-vignettes button { width: 64px; height: 64px; flex-shrink: 0; padding: 0; border: 1px solid var(--lm-filet); border-radius: 4px; overflow: hidden; background: #fff; }
.galerie-vignettes button.actif { border-color: var(--lm-encre); box-shadow: inset 0 0 0 1px var(--lm-encre); }
.galerie-vignettes img { width: 100%; height: 100%; object-fit: cover; }
.fiche-titre { font-size: 1.35rem; margin-bottom: 6px; }
@media (min-width: 992px) { .fiche-titre { font-size: 1.7rem; } }
.fiche-prix { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: 12px 0; }
.fiche-prix .prix { font-size: 1.8rem; font-weight: 700; color: var(--lm-encre); font-variant-numeric: tabular-nums; }
.fiche-prix s { color: var(--lm-gris); }
.paliers { border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); overflow: hidden; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); }
.paliers > div { padding: 10px 12px; border-right: 1px solid var(--lm-filet); background: #fff; }
.paliers > div:last-child { border-right: 0; }
.paliers > div.actif { background: var(--lm-orange-pale); }
.paliers .qte { font-size: 0.78rem; color: var(--lm-gris); }
.paliers .val { font-weight: 700; color: var(--lm-encre); }
.fiche-options .option { margin-bottom: 14px; }
.fiche-options .option-titre { font-weight: 600; color: var(--lm-encre); margin-bottom: 6px; font-size: 0.92rem; }
.fiche-options .option-titre span { font-weight: 400; color: var(--lm-gris); }
.fiche-achat { display: flex; gap: 8px; align-items: stretch; margin-top: 12px; }
.fiche-achat .btn { flex: 1; }
.barre-achat-mobile { position: fixed; left: 0; right: 0; bottom: var(--lm-barre-h); background: #fff; border-top: 1px solid var(--lm-filet); padding: 10px 16px; display: flex; gap: 10px; align-items: center; z-index: 1020; }
.barre-achat-mobile .prix { font-weight: 700; color: var(--lm-encre); font-size: 1.1rem; white-space: nowrap; }
.barre-achat-mobile .btn { flex: 1; }
@media (min-width: 992px) { .barre-achat-mobile { display: none; } }
body.avec-barre-achat { padding-bottom: calc(var(--lm-barre-h) + 64px); }
@media (min-width: 992px) { body.avec-barre-achat { padding-bottom: 0; } }
.vendeur-carte { display: flex; gap: 12px; align-items: center; padding: 14px 16px; }
.description-produit { line-height: 1.7; }
.description-produit img { height: auto; }
.garanties { list-style: none; padding: 0; margin: 12px 0 0; font-size: 0.88rem; color: var(--lm-gris); }
.garanties li { display: flex; gap: 8px; padding: 4px 0; }
.etoiles { color: #E8A317; letter-spacing: 1px; }

/* ----------------------------------------------------------------- Panier et commande */
.panier { display: grid; gap: 16px; }
@media (min-width: 992px) { .panier { grid-template-columns: 1fr 360px; align-items: start; } .panier .recap { position: sticky; top: calc(var(--lm-entete-h) + 16px); } }
.ligne-panier { display: grid; grid-template-columns: 72px 1fr; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--lm-filet); }
.ligne-panier:last-child { border-bottom: 0; }
.ligne-panier .vignette { width: 72px; height: 72px; }
.ligne-panier .lp-nom { font-weight: 500; color: var(--lm-encre); line-height: 1.3; }
.ligne-panier .lp-variante { font-size: 0.85rem; color: var(--lm-gris); }
.ligne-panier .lp-bas { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.ligne-panier .lp-total { font-weight: 700; color: var(--lm-encre); }
.ligne-panier .lp-info { font-size: 0.8rem; color: var(--lm-vert); }
.recap .ligne-recap { display: flex; justify-content: space-between; padding: 6px 0; }
.recap .ligne-recap.total-general { border-top: 1px solid var(--lm-encre); margin-top: 6px; padding-top: 12px; font-size: 1.15rem; font-weight: 700; color: var(--lm-encre); }
.etapes { display: flex; gap: 6px; font-size: 0.82rem; color: var(--lm-gris); margin-bottom: 8px; }
.etapes span.actif { color: var(--lm-encre); font-weight: 600; }
.etapes span + span::before { content: '›'; margin-right: 6px; color: var(--lm-gris-clair); }

/* ----------------------------------------------------------------- Boutiques */
.carte-boutique { background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); padding: 14px; display: flex; gap: 12px; align-items: center; color: inherit; }
.carte-boutique:hover { border-color: var(--lm-encre); color: inherit; }
.carte-boutique .logo-boutique { width: 56px; height: 56px; border-radius: 6px; object-fit: cover; flex-shrink: 0; border: 1px solid var(--lm-filet); }
.carte-boutique .monogramme { width: 56px; height: 56px; font-size: 1.1rem; }
.boutique-tete { background: #fff; border-bottom: 1px solid var(--lm-filet); }
.boutique-banniere { height: 120px; background: var(--lm-encre) center/cover no-repeat; }
@media (min-width: 768px) { .boutique-banniere { height: 200px; } }
.boutique-identite { display: flex; gap: 14px; align-items: flex-end; margin-top: -32px; padding-bottom: 14px; }
.boutique-identite .logo-boutique, .boutique-identite .monogramme { width: 80px; height: 80px; border: 3px solid #fff; border-radius: 8px; object-fit: cover; background: #fff; font-size: 1.5rem; }
.badge-certifie { display: inline-flex; align-items: center; gap: 4px; font-size: 0.75rem; font-weight: 600; color: var(--lm-vert); }

/* ----------------------------------------------------------------- Pied de page */
.pied { background: var(--lm-encre); color: #A1A1A6; margin-top: 32px; font-size: 0.9rem; }
.pied h3 { color: #fff; font-size: 0.95rem; margin-bottom: 10px; }
.pied a { color: #D2D2D7; }
.pied a:hover { color: #fff; }
.pied ul { list-style: none; padding: 0; margin: 0; }
.pied li { padding: 3px 0; }
.pied-bas { border-top: 1px solid #3A3A3C; padding: 14px 0; font-size: 0.8rem; }

/* Pages de contenu (à propos, aide, conditions) */
.contenu-page { background: #fff; border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); padding: 20px; line-height: 1.75; }
.contenu-page h2 { font-size: 1.15rem; margin-top: 1.5rem; }
.contenu-page h2:first-child { margin-top: 0; }
@media (min-width: 768px) { .contenu-page { padding: 32px 40px; } }

/* Authentification */
.auth { max-width: 440px; margin: 24px auto; }
.auth.large { max-width: 720px; }
.auth .bloc-corps { padding: 24px 20px; }
@media (min-width: 768px) { .auth .bloc-corps { padding: 32px; } }
.offre { border: 1px solid var(--lm-filet); border-radius: var(--lm-rayon); padding: 14px; background: #fff; height: 100%; }
.choix input:checked + label .offre { border-color: var(--lm-encre); }
