/* =====================================================================
   JARAMA — feuille de style principale  (static/css/jarama.css)
   =====================================================================

     SOMMAIRE
     1.  Les polices ........... quels fichiers pour Inter et Poppins
     2.  Les couleurs .......... la palette Jarama, écrite une seule fois
     3.  Socle téléphone ....... réglages pour que le site se sente « appli »
     4.  Titres et textes ...... tailles et polices des titres, prix
     5.  Mise en page .......... la largeur et les marges de chaque page
     6.  Boutons ............... le bouton orange et ses variantes
     7.  Champs de formulaire .. les cases où l'on écrit
     8.  Messages .............. vert = succès, rouge = erreur…
     9.  En-tête ............... logo, cloche, voile pêche en haut
     10. Barre du bas .......... Accueil · Catégories · Panier · Compte
     11. Grand écran ........... adaptations pour ordinateur
     12. Survol ................ effets quand on passe la souris
     13. Page Catégories ....... la grille des catégories
     14. Page Compte ........... profil, liens, boutons du visiteur
     15. Accueil ............... recherche, bannières, ruban de catégories
     16. Cartes produits ....... la grille de produits utilisée partout
     17. Liste et boutique ..... puces, filtres, résultats, avis
     18. Fiche produit ......... photos, couleurs, tailles, barre d'achat
     19. Panier et commandes ... panier, total, statuts, suivi
     20. Validation et avis .... commander, confirmation, donner son avis
     21. Espace vendeur ........ tuiles, formulaires, photos
     22. Mes produits .......... la liste des produits du vendeur
     23. Gérer un produit ...... photos, tailles, masquer
     24. Commandes et livreur .. commandes reçues, livreur, reversements
     25. Comptes et notifs ..... connexion, inscription, notifications
   ===================================================================== */


/* =====================================================================
   1. LES POLICES
   Chaque bloc dit : « la police X, en épaisseur Y, c'est CE fichier ».
   ===================================================================== */

/* Inter normal : le texte courant */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-400.f55800950f01.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;   /* texte visible tout de suite, police appliquée ensuite */
}

/* Inter moyen : un peu plus marqué */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-500.fd895cdb4c0a.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* Inter demi-gras : prix et boutons */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-600.aa3cf1714e4f.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Poppins gras : titres et nom « jarama » */
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-700.de3d89660ac7.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}


/* =====================================================================
   2. LES COULEURS ET RÉGLAGES COMMUNS
   On les utilise partout avec var(--nom). Pour changer une couleur
   sur tout le site, on la change ICI, et nulle part ailleurs.
   ===================================================================== */
:root {
  --orange: #EA580C;      /* boutons, accents */
  --terre: #C2410C;       /* prix, liens */
  --peche: #FDEFE6;       /* fonds orange très doux */
  --creme: #FBF6EE;       /* fonds chauds */
  --nuit: #1C1410;        /* titres, icônes */
  --texte: #2A2420;       /* texte normal */
  --doux: #756D67;        /* texte secondaire */
  --gris: #F5F2EE;        /* fond des photos */
  --trait: #EFEAE4;       /* bordures fines */
  --ocre: #F5B700;        /* étoiles */
  --ombre-orange: 0 10px 24px -10px rgba(234, 88, 12, 0.55);
  --titres: "Poppins", system-ui, sans-serif;
  --corps: "Inter", system-ui, sans-serif;
  --rayon: 16px;          /* arrondi des boutons */
}


/* =====================================================================
   3. SOCLE TÉLÉPHONE
   Les petits réglages qui font qu'un site « se sent » comme une appli.
   ===================================================================== */

/* Une boîte de 100 px fait vraiment 100 px, bordure comprise */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-tap-highlight-color: transparent;  /* pas de flash gris au toucher */
  -webkit-text-size-adjust: 100%;            /* pas de texte grossi en paysage */
}

/* Le texte de base de tout le site */
body {
  margin: 0;
  font-family: var(--corps);
  font-size: 15px;
  line-height: 1.5;
  color: var(--texte);
  background: #FFFFFF;
  -webkit-font-smoothing: antialiased;
}

/* Une image ne déborde jamais de son cadre */
img {
  max-width: 100%;
  height: auto;
}

/* Les liens n'ont plus le bleu souligné du navigateur */
a {
  color: inherit;
  text-decoration: none;
}

/* Réaction immédiate au toucher (pas d'attente du double-tap) */
a,
button,
label,
input,
select,
textarea {
  touch-action: manipulation;
}

/* Un appui long sur un bouton ne sélectionne pas son texte */
button,
.bouton,
.rond,
.barre-bas a {
  user-select: none;
  -webkit-user-select: none;
}

/* Anneau orange quand on navigue au clavier (ordinateur) */
:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

/* Style commun de toutes les icônes (trait fin, couleur du texte) */
.ico {
  display: block;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}


/* =====================================================================
   4. TITRES ET TEXTES
   ===================================================================== */
h1,
h2,
h3 {
  margin: 0 0 0.5em;
  font-family: var(--titres);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;    /* lettres un peu resserrées = effet « premium » */
  color: var(--nuit);
}

h1 { font-size: 24px; }
h2 { font-size: 20px; }
h3 { font-size: 17px; }

p {
  margin: 0 0 1em;
}

/* Petit texte gris (dates, noms de boutique…) */
.petit {
  font-size: 13px;
  color: var(--doux);
}

/* Un prix : orange Terre, jamais coupé sur deux lignes */
.prix {
  font-weight: 600;
  color: var(--terre);
  white-space: nowrap;
}


/* =====================================================================
   5. MISE EN PAGE
   Le contenu de chaque page. En bas, on laisse la place pour la
   barre du bas + le trait de l'iPhone (safe-area).
   ===================================================================== */
.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 8px 20px calc(100px + env(safe-area-inset-bottom, 0px));
}


/* =====================================================================
   6. BOUTONS
   Utilisation : class="bouton"  ou  class="bouton bouton-clair bouton-large"
   ===================================================================== */

/* Le bouton principal : orange plein */
.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 22px;
  border: 0;
  border-radius: var(--rayon);
  background: var(--orange);
  color: #FFFFFF;
  font-family: var(--corps);
  font-size: 15px;
  font-weight: 600;
  box-shadow: var(--ombre-orange);
  cursor: pointer;
  transition: transform 120ms ease-out, background-color 120ms ease-out;
}

/* Le bouton « s'enfonce » sous le doigt */
.bouton:active {
  transform: scale(0.97);
}

/* Variante : bouton blanc, secondaire */
.bouton-clair {
  background: #FFFFFF;
  color: var(--nuit);
  border: 1px solid var(--trait);
  box-shadow: none;
}

/* Variante : bouton sur toute la largeur */
.bouton-large {
  width: 100%;
}


/* =====================================================================
   7. CHAMPS DE FORMULAIRE
   Tous les champs SAUF : cases à cocher, boutons radio (tes étoiles
   d'avis), champs cachés et envoi de photo.
   ===================================================================== */
input:where(:not([type="checkbox"], [type="radio"], [type="hidden"], [type="file"])),
select,
textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 16px;              /* ⚠️ 16 px minimum, sinon l'iPhone zoome */
  color: var(--texte);
  background: #FFFFFF;
  border: 1px solid #E4DCD4;
  border-radius: 14px;
  transition: border-color 150ms ease-out, box-shadow 150ms ease-out;
}

/* Le champ où l'on écrit : bordure orange + halo pêche */
input:where(:not([type="checkbox"], [type="radio"], [type="hidden"], [type="file"])):focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px var(--peche);
}

/* Cases à cocher et boutons radio en orange */
input[type="checkbox"],
input[type="radio"] {
  width: 20px;
  height: 20px;
  accent-color: var(--orange);
}


/* =====================================================================
   8. MESSAGES DJANGO (messages.success, messages.error…)
   Django donne lui-même le mot « success », « error », « warning ».
   ===================================================================== */
.messages {
  display: grid;
  gap: 8px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

/* Par défaut (information) : fond pêche, texte Terre */
.message {
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 500;
  background: var(--peche);
  color: var(--terre);
}

.message-success { background: #EAF7EE; color: #17643A; }   /* vert */
.message-error   { background: #FDECEC; color: #A32020; }   /* rouge */
.message-warning { background: #FFF6DB; color: #7A5600; }   /* jaune */


/* =====================================================================
   9. EN-TÊTE (logo à gauche, cloche à droite)
   ===================================================================== */

/* La bande du haut, avec le voile pêche qui fond vers le blanc */
.entete {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 20px 12px;
  background: linear-gradient(180deg, var(--peche) 0%, #FFFFFF 100%);
}

/* Logo + mot « jarama » */
.marque {
  display: flex;
  align-items: center;
  gap: 9px;
}

.marque img {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  box-shadow: var(--ombre-orange);
}

.marque span {
  font-family: var(--titres);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--nuit);
}

/* Le groupe à droite (cloche, lien « Se connecter ») */
.entete-droite {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Bouton rond blanc (la cloche, le retour…) */
.rond {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #FFFFFF;
  border: 1px solid var(--trait);
  color: var(--nuit);
}

/* Le point orange « il y a du nouveau » sur la cloche */
.rond .point {
  position: absolute;
  top: 10px;
  right: 11px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--orange);
  border: 2px solid #FFFFFF;
}

/* Lien « Se connecter » (visiteur non connecté) */
.lien-connexion {
  padding: 10px 4px;
  font-weight: 600;
  color: var(--terre);
}

/* Menu pour ordinateur : caché sur téléphone (voir section 11) */
.menu-ordi {
  display: none;
}


/* =====================================================================
   10. BARRE DE NAVIGATION DU BAS (téléphone)
   ===================================================================== */

/* La barre, collée en bas de l'écran */
.barre-bas {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: repeat(4, 1fr);    /* 4 boutons de même largeur */
  padding: 8px 4px calc(8px + env(safe-area-inset-bottom, 0px));
  background: #FFFFFF;
  border-top: 1px solid var(--trait);
}

/* Chaque bouton : icône au-dessus, mot en dessous */
.barre-bas a {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  min-height: 48px;
  font-size: 11px;
  color: var(--doux);
}

/* La capsule autour de l'icône */
.barre-bas .capsule {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 30px;
  border-radius: 15px;
  transition: transform 120ms ease-out, background-color 150ms ease-out;
}

/* La capsule rétrécit un peu sous le doigt */
.barre-bas a:active .capsule {
  transform: scale(0.92);
}

/* L'onglet de la page en cours */
.barre-bas a.actif {
  color: var(--nuit);
  font-weight: 600;
}

.barre-bas a.actif .capsule {
  background: var(--peche);
  color: var(--orange);
}

/* La pastille avec le nombre d'articles du panier */
.compteur {
  position: absolute;
  top: -2px;
  left: 50%;
  margin-left: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 9px;
  border: 2px solid #FFFFFF;
  background: var(--orange);
  color: #FFFFFF;
  font-size: 10px;
  font-weight: 600;
}


/* =====================================================================
   11. GRAND ÉCRAN (ordinateur, à partir de 900 px de large)
   La barre du bas disparaît, les liens passent dans l'en-tête.
   ===================================================================== */
@media (min-width: 900px) {
  .barre-bas {
    display: none;
  }

  .page {
    padding-bottom: 48px;
  }

  /* Le contenu de l'en-tête reste centré sur 1100 px */
  .entete {
    padding-left: max(20px, calc(50% - 530px));
    padding-right: max(20px, calc(50% - 530px));
  }

  .menu-ordi {
    display: flex;
    align-items: center;
    gap: 28px;
  }

  .menu-ordi a {
    font-weight: 500;
    color: var(--doux);
  }

  .menu-ordi a.actif {
    color: var(--nuit);
  }
}


/* =====================================================================
   12. SURVOL — seulement avec une vraie souris
   Sur téléphone, un survol resterait « collé » après le toucher.
   ===================================================================== */
@media (hover: hover) and (pointer: fine) {
  .bouton:hover { background: var(--terre); }
  .bouton-clair:hover { background: var(--gris); }
  .menu-ordi a:hover,
  .lien-connexion:hover { color: var(--orange); }
  .rond:hover { border-color: #E4DCD4; }
}

/* =====================================================================
   13. PAGE « CATÉGORIES »
   ===================================================================== */
.grille-categories {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));   /* 2 colonnes sur téléphone */
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.carte-categorie {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px;
  border-radius: 18px;
  background: var(--creme);
  border: 1px solid #F4E9DD;
  font-weight: 600;
  color: var(--nuit);
  transition: transform 120ms ease-out;
}

.carte-categorie:active {
  transform: scale(0.97);
}

/* Le petit carré blanc avec la lettre orange */
.carte-categorie .initiale {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: #FFFFFF;
  color: var(--orange);
  font-family: var(--titres);
  font-size: 18px;
  font-weight: 700;
}

@media (min-width: 600px) {
  .grille-categories { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 900px) {
  .grille-categories { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}


/* =====================================================================
   14. PAGE « COMPTE »
   ===================================================================== */

/* La carte avec le rond orange et le nom */
.carte-profil {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  padding: 16px;
  border-radius: 20px;
  background: var(--creme);
  border: 1px solid #F4E9DD;
}

.avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--orange);
  color: #FFFFFF;
}

/* La liste de liens (Mes commandes, Notifications…) */
.liste-liens {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
  background: #FFFFFF;
  border: 1px solid var(--trait);
  border-radius: 18px;
  overflow: hidden;
}

.liste-liens li + li {
  border-top: 1px solid var(--trait);    /* un trait entre deux lignes */
}

.liste-liens a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 16px;
  font-size: 15px;
  color: var(--texte);
}

.liste-liens a .ico {
  color: var(--orange);
}

.liste-liens .texte {
  flex: 1;                               /* le texte prend toute la place du milieu */
}

.liste-liens .ico.fleche {
  width: 18px;
  height: 18px;
  color: #B8AFA8;
}

/* Pastille orange (nombre de notifications) */
.badge {
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--orange);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 600;
}

/* Les deux boutons du visiteur */
.actions-visiteur {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

@media (hover: hover) and (pointer: fine) {
  .carte-categorie:hover { border-color: var(--orange); }
  .liste-liens a:hover { background: var(--gris); }
}

/* =====================================================================
   15. ACCUEIL : recherche, bannières, catégories
   ===================================================================== */

/* Texte invisible à l'écran, mais lu par les lecteurs d'écran */
.cache {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* --- La barre de recherche --- */
.recherche {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  margin: 4px 0 18px;
  padding: 0 16px;
  background: #FFFFFF;
  border: 1px solid #F1E4D8;
  border-radius: 16px;
  box-shadow: 0 6px 18px -12px rgba(194, 65, 12, 0.35);
}

.recherche:focus-within {
  border-color: var(--orange);        /* bordure orange quand on écrit */
}

.recherche .ico {
  width: 20px;
  height: 20px;
  color: var(--orange);
}

.recherche input[type="search"],
.recherche input[type="search"]:focus {
  flex: 1;
  min-height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

/* --- Le carrousel de bannières (glissé au doigt, sans JavaScript) --- */
.carrousel {
  display: flex;
  gap: 12px;
  margin: 0 -20px -8px;               /* va jusqu'aux bords de l'écran */
  padding: 0 20px 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;      /* s'arrête net sur chaque bannière */
  scroll-padding-inline: 20px;
  overscroll-behavior-x: contain;
  scrollbar-width: none;              /* cache la barre de défilement */
}

.carrousel::-webkit-scrollbar {
  display: none;
}

.banniere {
  flex: 0 0 86%;                      /* on voit le bord de la suivante */
  max-width: 420px;
  min-height: 156px;
  scroll-snap-align: start;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px;
  border-radius: 24px;
  background: var(--creme);
  color: var(--nuit);
  transition: transform 120ms ease-out;
}

.banniere:active {
  transform: scale(0.98);
}

.banniere .sur {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--doux);
}

.banniere h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.25;
}

.banniere h2 em {
  font-style: normal;
  color: var(--orange);
}

.banniere .lien {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  font-size: 13px;
  font-weight: 600;
}

.banniere .lien .ico {
  width: 16px;
  height: 16px;
}

/* Le carré blanc avec une grande icône */
.banniere-icone {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 76px;
  height: 76px;
  border-radius: 22px;
  background: #FFFFFF;
  color: var(--orange);
}

.banniere-icone .ico {
  width: 38px;
  height: 38px;
  stroke-width: 1.4;
}

/* Le logo penché de la 1re bannière */
.banniere-logo {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border: 3px solid #FFFFFF;
  border-radius: 20px;
  transform: rotate(-8deg);
  box-shadow: 0 12px 24px -10px rgba(124, 45, 18, 0.6);
}

/* Les 4 couleurs de bannières */
.banniere-orange {
  background: linear-gradient(135deg, #F39A55 0%, var(--orange) 70%);
  box-shadow: var(--ombre-orange);
}
.banniere-orange h2,
.banniere-orange .lien { color: #FFFFFF; }
.banniere-orange h2 em,
.banniere-orange .sur { color: #FFE4CC; }

.banniere-peche { background: var(--peche); }

.banniere-nuit { background: var(--nuit); }
.banniere-nuit h2,
.banniere-nuit .lien { color: #FFFFFF; }
.banniere-nuit h2 em { color: var(--ocre); }
.banniere-nuit .sur { color: #A89F98; }
.banniere-nuit .banniere-icone { background: #2E241F; color: var(--ocre); }

/* --- Titre de section avec « Voir tout » --- */
.titre-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 22px 0 12px;
}

.titre-section h2 {
  margin: 0;
  font-size: 18px;
}

.titre-section a {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 13px;
  font-weight: 500;
  color: var(--terre);
}

.titre-section a .ico {
  width: 16px;
  height: 16px;
}

/* --- Le ruban de catégories (glissé au doigt) --- */
.ruban-categories {
  display: flex;
  gap: 14px;
  margin: 0 -20px;
  padding: 0 20px;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scroll-padding-inline: 20px;
  scrollbar-width: none;
}

.ruban-categories::-webkit-scrollbar {
  display: none;
}

.ruban-categories li {
  flex: 0 0 68px;
  scroll-snap-align: start;
}

.ruban-categories a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  text-align: center;
  color: var(--texte);
}

/* La tuile : lettre noire + petit trait orange (fusion noir et orange) */
.tuile {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 22px;
  background: var(--creme);
  border: 1px solid #F4E9DD;
  font-family: var(--titres);
  font-size: 22px;
  font-weight: 700;
  color: var(--nuit);
  transition: transform 120ms ease-out;
}

.tuile::after {
  content: "";
  position: absolute;
  bottom: 12px;
  width: 14px;
  height: 3px;
  border-radius: 2px;
  background: var(--orange);
}

.ruban-categories a:active .tuile {
  transform: scale(0.95);
}


/* =====================================================================
   16. CARTES PRODUITS (_grille_produits.html, utilisé partout)
   ===================================================================== */
.grille-produits {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));   /* 2 par ligne */
  gap: 18px 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.carte-produit {
  display: block;
  color: var(--texte);
}

/* Le cadre gris clair de la photo */
.carte-produit .photo {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;                /* toujours carré */
  overflow: hidden;
  border-radius: 22px;
  background: var(--gris);
  transition: transform 120ms ease-out;
}

.carte-produit:active .photo {
  transform: scale(0.97);
}

/* La photo : le fond blanc se fond dans le gris */
.carte-produit .photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;                  /* la photo remplit tout le carré */
  transition: transform 200ms ease-out;
}

.sans-photo {
  font-size: 12px;
  color: var(--doux);
}

.carte-produit .nom {
  margin-top: 10px;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;            /* nom trop long → « … » */
}

.carte-produit .prix {
  display: block;
  margin-top: 2px;
  font-size: 15px;
}

.vendeur-carte {
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (min-width: 600px) {
  .grille-produits { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 900px) {
  .grille-produits {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px 20px;
  }
  .banniere { flex-basis: 420px; }
}

@media (hover: hover) and (pointer: fine) {
  .carte-produit:hover .photo img { transform: scale(1.04); }
  .banniere:hover { transform: translateY(-2px); }
}


/* =====================================================================
   17. LISTE, CATÉGORIE, BOUTIQUE
   ===================================================================== */

/* Lien « ‹ Retour » en haut de page */
.lien-retour {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 40px;
  font-size: 14px;
  font-weight: 500;
  color: var(--terre);
}

.lien-retour .ico {
  width: 16px;
  height: 16px;
  transform: rotate(180deg);          /* la flèche → devient ← */
}

.compteur-resultats {
  margin: 0 0 12px;
}

/* --- Puces de catégories (glissées au doigt) --- */
.puces {
  display: flex;
  gap: 8px;
  margin: 0 -20px 16px;
  padding: 0 20px;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.puces::-webkit-scrollbar {
  display: none;
}

.puces a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  background: #FFFFFF;
  border: 1px solid var(--trait);
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  color: var(--texte);
}

.puces a.actif {
  background: var(--nuit);
  border-color: var(--nuit);
  color: #FFFFFF;
}

/* --- Le tiroir « Filtres et tri » --- */
.filtres {
  margin-bottom: 16px;
  border: 1px solid var(--trait);
  border-radius: 16px;
  background: #FFFFFF;
}

.filtres summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
  padding: 0 16px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.filtres summary::-webkit-details-marker {
  display: none;
}

.filtres summary::after {
  content: "+";
  font-size: 20px;
  color: var(--orange);
}

.filtres[open] summary::after {
  content: "–";
}

.filtres-corps {
  display: grid;
  gap: 12px;
  padding: 0 16px 16px;
}

.filtres label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  color: var(--doux);
}

.deux-colonnes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.filtres-actions {
  display: flex;
  gap: 10px;
}

.filtres-actions .bouton {
  flex: 1;
}

/* Erreurs de formulaire de Django (en rouge) */
.errorlist {
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
  color: #A32020;
}

/* --- Message « aucun résultat » --- */
.etat-vide {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 8px;
  text-align: center;
}

.etat-vide-icone {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: var(--peche);
  color: var(--orange);
}

.etat-vide-icone .ico {
  width: 28px;
  height: 28px;
}

.etat-vide h2 {
  margin: 0 0 4px;
  font-size: 18px;
}

.etat-vide .puces {
  flex-wrap: wrap;
  justify-content: center;
  margin: 12px 0 16px;
  padding: 0;
  overflow: visible;
}

/* --- Page boutique --- */
.carte-boutique {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 4px 0 8px;
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--peche) 0%, var(--creme) 100%);
  border: 1px solid #F4E9DD;
}

.avatar-boutique {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 60px;
  height: 60px;
  border-radius: 18px;
  background: var(--orange);
  color: #FFFFFF;
  font-family: var(--titres);
  font-size: 26px;
  font-weight: 700;
  box-shadow: var(--ombre-orange);
}

.carte-boutique h1 {
  margin: 0 0 2px;
  font-size: 20px;
}

.carte-boutique .petit {
  margin: 0;
}

.note-boutique {
  margin-top: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--nuit);
}
/* Le texte prend la place du milieu, le bouton Partager reste à droite */
.carte-boutique > div {
  flex: 1;
  min-width: 0;
}

.carte-boutique .rond {
  flex-shrink: 0;
}

/* Sur la page boutique, inutile de répéter le nom du vendeur sous chaque produit */
.carte-boutique ~ .grille-produits .vendeur-carte {
  display: none;
}

/* --- Avis des clients : une carte par avis --- */
.liste-avis {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.avis-client {
  padding: 14px 16px;
  border-radius: 18px;
  background: var(--creme);
  border: 1px solid #F4E9DD;
}

.avis-entete {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.etoiles {
  font-size: 15px;
  letter-spacing: 1px;
  white-space: nowrap;
  color: #E4DCD4;                 /* étoile vide : gris clair */
}

.etoiles .pleine {
  color: var(--ocre);             /* étoile pleine : jaune ocre */
}

.avis-client .commentaire {
  margin: 6px 0 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--texte);
}

.avis-vide {
  padding: 16px;
  border-radius: 18px;
  background: var(--gris);
  text-align: center;
}

.note-resume {
  font-size: 13px;
  font-weight: 600;
  color: var(--nuit);
}

@media (hover: hover) and (pointer: fine) {
  .puces a:hover { border-color: var(--orange); }
  .lien-retour:hover { color: var(--orange); }
}

/* =====================================================================
   18. FICHE PRODUIT
   ===================================================================== */

/* Sécurité : un élément « hidden » reste toujours caché */
[hidden] {
  display: none !important;
}

.fiche {
  max-width: 640px;
  margin: 0 auto;
}

/* --- Les photos --- */
.galerie-bloc {
  margin-bottom: 18px;
}

.photo-cadre {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  max-height: 460px;
  overflow: hidden;
  border-radius: 28px;
  background: var(--gris);
}

.photo-grande {
  width: 100%;
  height: 100%;
  padding: 18px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.vignettes {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

.vignette {
  flex-shrink: 0;
  width: 62px;
  height: 62px;
  padding: 4px;
  border: 2px solid transparent;
  border-radius: 14px;
  background: var(--gris);
  object-fit: contain;
  cursor: pointer;
}

.vignette.choisie {
  border-color: var(--orange);
}

/* --- Nom, prix, garanties --- */
.fiche-categorie {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--orange);
}

.fiche-titre {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.fiche-titre h1 {
  margin: 4px 0 2px;
  font-size: 24px;
}

.fiche-prix {
  font-size: 22px;
}

.rond.copie {
  background: var(--peche);
  color: var(--orange);
}

.rassurance {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 4px;
  padding: 0;
  list-style: none;
}

.rassurance li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--peche);
  color: var(--terre);
  font-size: 12.5px;
  font-weight: 500;
}

.rassurance .ico {
  width: 16px;
  height: 16px;
}

.etiquette {
  margin: 20px 0 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--nuit);
}

/* --- Les couleurs (petite photo + nom) --- */
.couleurs {
  display: flex;
  gap: 10px;
  margin: 0 -20px;
  padding: 2px 20px;
  overflow-x: auto;
  scrollbar-width: none;
}

.choix-couleur {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  min-width: 70px;
  padding: 6px;
  border: 2px solid var(--trait);
  border-radius: 16px;
  background: #FFFFFF;
  font: 500 12px var(--corps);
  color: var(--texte);
  cursor: pointer;
  transition: border-color 150ms ease-out, transform 120ms ease-out;
}

.choix-couleur img {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: var(--gris);
  object-fit: contain;
  mix-blend-mode: multiply;
}

.choix-couleur.actif {
  border-color: var(--orange);
  color: var(--nuit);
  font-weight: 600;
}

.choix-couleur:active {
  transform: scale(0.96);
}

/* --- Les tailles (le rond radio est caché, on stylise l'étiquette) --- */
.tailles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.taille {
  position: relative;
}

.taille input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.taille span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--trait);
  border-radius: 14px;
  background: #FFFFFF;
  font-size: 14px;
  font-weight: 500;
  color: var(--nuit);
  transition: background-color 150ms ease-out, border-color 150ms ease-out;
}

.taille input:checked + span {
  border: 2px solid var(--orange);
  background: var(--peche);
  color: var(--terre);
  font-weight: 600;
}

.taille input:focus-visible + span {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

.taille input:disabled {
  cursor: not-allowed;
}

.taille input:disabled + span {
  border-color: var(--gris);
  background: var(--gris);
  color: #B5ADA6;
}

/* --- Carte du vendeur --- */
.carte-vendeur {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 14px;
  border: 1px solid var(--trait);
  border-radius: 18px;
  color: var(--texte);
}

.carte-vendeur .initiales {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--peche);
  color: var(--orange);
  font: 700 16px var(--titres);
}

.carte-vendeur .infos {
  flex: 1;
  min-width: 0;
}

.carte-vendeur .infos > * {
  display: block;
}

.carte-vendeur strong {
  color: var(--nuit);
}

.carte-vendeur .fleche {
  width: 18px;
  height: 18px;
  color: #B8AFA8;
}

/* --- Description --- */
.fiche-description h2 {
  margin: 24px 0 8px;
  font-size: 17px;
}

.fiche-description p {
  line-height: 1.65;
  color: #5F5852;
}

/* --- La barre d'achat collée en bas (remplace la barre de navigation) --- */
.barre-achat {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px));
  background: #FFFFFF;
  border-top: 1px solid var(--trait);
  box-shadow: 0 -10px 24px -18px rgba(28, 20, 16, 0.35);
}

.barre-achat-prix {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.barre-achat-prix .prix {
  font-size: 17px;
}

.barre-achat .bouton {
  flex: 1;
}

/* Bouton grisé tant qu'aucune taille n'est choisie */
.bouton:disabled {
  background: #EBD9CC;
  color: #FFFFFF;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

@media (min-width: 900px) {
  .barre-achat {
    padding-left: max(20px, calc(50% - 320px));
    padding-right: max(20px, calc(50% - 320px));
  }
}

/* Le bouton panier de la barre d'achat, avec son compteur */
.panier-rond {
  flex-shrink: 0;
}

.panier-rond .compteur {
  top: -4px;
  left: auto;
  right: -4px;
  margin-left: 0;
}

/* =====================================================================
   19. PANIER ET COMMANDES
   ===================================================================== */

/* --- Les lignes du panier --- */
.lignes-panier {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.ligne-panier {
  display: flex;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--trait);
}

.ligne-panier:last-child {
  border-bottom: 0;
}

.vignette-panier {
  flex-shrink: 0;
  width: 84px;
  height: 84px;
  overflow: hidden;
  border-radius: 18px;
  background: var(--gris);
}

.vignette-panier img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ligne-panier .corps {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.ligne-panier .haut,
.ligne-panier .bas {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ligne-panier .haut {
  align-items: flex-start;
}

.ligne-panier .nom {
  font-weight: 600;
  color: var(--nuit);
}

.ligne-panier form {
  margin: 0;
}

/* Le compteur − 1 + */
.stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--trait);
  border-radius: 12px;
  background: #FFFFFF;
}

.stepper button {
  width: 38px;
  height: 38px;
  border: 0;
  background: none;
  font-size: 18px;
  font-weight: 600;
  color: var(--orange);
  cursor: pointer;
}

.stepper button:disabled {
  color: #CFC7C0;
  cursor: not-allowed;
}

.stepper span {
  min-width: 22px;
  text-align: center;
  font-weight: 600;
}

/* Le bouton poubelle */
.bouton-icone {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 12px;
  background: none;
  color: #B8AFA8;
  cursor: pointer;
}

.bouton-icone .ico {
  width: 20px;
  height: 20px;
}

/* --- La carte du total (panier et détail) --- */
.resume {
  padding: 18px;
  border-radius: 24px;
  background: var(--creme);
  border: 1px solid #F4E9DD;
}

.resume-ligne {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  color: var(--doux);
}

.resume-ligne b {
  font-weight: 500;
  color: var(--nuit);
}

.resume .note {
  margin: 0 0 8px;
  font-size: 12.5px;
  color: var(--doux);
}

.resume .total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-top: 4px;
  padding-top: 12px;
  border-top: 1px dashed #E8D9CA;
}

.resume .total span {
  font-family: var(--titres);
  font-size: 15px;
  font-weight: 700;
  color: var(--nuit);
}

.resume .total .prix {
  font-size: 21px;
  font-weight: 700;
}

.resume .bouton {
  width: 100%;
  margin-top: 16px;
}

.resume .rassure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 10px 0 0;
  font-size: 12.5px;
  color: var(--doux);
}

.resume .rassure .ico {
  width: 16px;
  height: 16px;
  color: var(--terre);
}

/* --- Pastilles de statut --- */
.statut {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--gris);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  color: var(--doux);
}

.statut-en_attente { background: #FFF6DB; color: #7A5600; }   /* jaune */
.statut-confirmee  { background: var(--peche); color: var(--terre); }   /* orange */
.statut-livree     { background: #EAF7EE; color: #17643A; }   /* vert */
.statut-annulee    { background: var(--gris); color: #8C847E; }   /* gris */

/* --- La liste « Mes commandes » --- */
.liste-commandes {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.carte-commande {
  overflow: hidden;
  border: 1px solid var(--trait);
  border-radius: 18px;
  background: #FFFFFF;
}

.commande-lien {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  color: var(--texte);
}

.commande-infos {
  flex: 1;
  min-width: 0;
}

.commande-infos .numero,
.commande-infos .petit {
  display: block;
}

.commande-infos .numero {
  font-family: var(--titres);
  font-size: 16px;
  font-weight: 700;
  color: var(--nuit);
}

.commande-bas {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
}

.commande-lien .fleche {
  width: 18px;
  height: 18px;
  color: #B8AFA8;
}

.lien-avis {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 46px;
  border-top: 1px solid var(--trait);
  background: var(--creme);
  font-size: 14px;
  font-weight: 600;
  color: var(--terre);
}

/* --- Le suivi en 3 étapes (Reçue → Confirmée → Livrée) --- */
.suivi {
  display: flex;
  margin: 20px 0 12px;
  padding: 0;
  list-style: none;
}

.suivi li {
  position: relative;
  flex: 1;
  padding-top: 24px;
  text-align: center;
  font-size: 12px;
  color: var(--doux);
}

.suivi li::before {                 /* le rond */
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  z-index: 1;
  width: 16px;
  height: 16px;
  margin-left: -8px;
  border-radius: 50%;
  background: var(--trait);
}

.suivi li::after {                  /* le trait qui relie les ronds */
  content: "";
  position: absolute;
  top: 7px;
  left: -50%;
  width: 100%;
  height: 2px;
  background: var(--trait);
}

.suivi li:first-child::after {
  display: none;
}

.suivi li.fait {
  font-weight: 600;
  color: var(--nuit);
}

.suivi li.fait::before,
.suivi li.fait::after {
  background: var(--orange);
}

/* --- Le détail d'une commande --- */
.entete-commande {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.entete-commande h1 {
  margin: 0 0 2px;
}

.entete-commande .petit {
  margin: 0;
}

.bouton-avis {
  width: 100%;
  margin: 8px 0 4px;
}

.liste-articles {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.liste-articles li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--trait);
}

.liste-articles li.retire {
  color: var(--doux);
}

.avertissement {
  display: block;
  margin-top: 4px;
  font-size: 12.5px;
  color: #7A5600;
}

.form-annuler {
  margin-top: 20px;
}

.bouton-danger {
  background: #FFFFFF;
  color: #A32020;
  border: 1px solid #F3C9C9;
  box-shadow: none;
}

.centre {
  text-align: center;
}

@media (hover: hover) and (pointer: fine) {
  .bouton-icone:hover { color: #A32020; background: #FDECEC; }
  .carte-commande:hover { border-color: #E4DCD4; }
  .bouton-danger:hover { background: #FDECEC; }
}

/* =====================================================================
   20. VALIDATION, CONFIRMATION, AVIS
   ===================================================================== */

/* Carte blanche générique (articles, livraison, avis…) */
.carte-blanche {
  margin-bottom: 16px;
  padding: 18px;
  border: 1px solid var(--trait);
  border-radius: 20px;
  background: #FFFFFF;
}

.carte-blanche h2 {
  margin: 0 0 12px;
  font-size: 17px;
}

/* Un champ de formulaire avec son étiquette */
.champ {
  margin-bottom: 14px;
}

.champ label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--nuit);
}

/* Encadré pêche « Nous vous appellerons… » */
.appel {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 14px;
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--peche);
  font-size: 14px;
  color: var(--terre);
}

.appel .ico {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 1px;
}

.appel strong {
  color: var(--nuit);
}

/* Petite liste d'articles (validation, confirmation) */
.mini-articles {
  margin: 0;
  padding: 0;
  list-style: none;
}

.mini-articles li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--trait);
  font-size: 14px;
}

.mini-articles li:last-child {
  border-bottom: 0;
}

/* --- Page de confirmation --- */
.succes {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0 20px;
  text-align: center;
}

.succes-icone {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: #EAF7EE;
  color: #17643A;
}

.succes-icone .ico {
  width: 38px;
  height: 38px;
  stroke-width: 2.2;
}

.succes h1 {
  margin: 0 0 6px;
  font-size: 22px;
}

.succes .petit {
  margin: 0;
}

.numero-commande {
  display: inline-block;
  margin-top: 6px;
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--creme);
  font-family: var(--titres);
  font-size: 15px;
  font-weight: 700;
  color: var(--nuit);
}

.actions-fin {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

/* --- Page « Donner mon avis » --- */
.carte-avis-entete {
  display: flex;
  align-items: center;
  gap: 12px;
}

.carte-avis-entete h2 {
  margin: 0;
}

.avatar-rond {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--peche);
  font-family: var(--titres);
  font-size: 16px;
  font-weight: 700;
  color: var(--orange);
}

/* Les 5 choix d'étoiles, en pastilles */
.choix-note > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.choix-note label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--trait);
  border-radius: 14px;
  background: #FFFFFF;
  font-weight: 600;
  color: var(--nuit);
  cursor: pointer;
}

.choix-note label:has(input:checked) {
  border: 2px solid var(--orange);
  background: var(--peche);
  color: var(--terre);
}

.carte-avis textarea {
  min-height: 110px;
  resize: vertical;
}

.carte-avis .bouton {
  width: 100%;
  margin-top: 8px;
}

/* =====================================================================
   21. ESPACE VENDEUR ET FORMULAIRES VENDEUR
   ===================================================================== */

/* Une colonne centrée, pas trop large sur ordinateur */
.colonne {
  max-width: 640px;
  margin: 0 auto;
}

/* Sur ordinateur, laisser la place à la barre collée en bas */
@media (min-width: 900px) {
  body:has(.barre-action, .barre-achat) .page {
    padding-bottom: 120px;
  }
}

/* --- Accueil de l'espace vendeur --- */
.carte-boutique h2 {
  margin: 0 0 2px;
  font-size: 20px;
}

.bouton-ajouter {
  margin: 16px 0;
}

.tuiles-vendeur {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tuile-vendeur {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  min-height: 124px;
  padding: 16px;
  border: 1px solid var(--trait);
  border-radius: 20px;
  background: #FFFFFF;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--nuit);
  transition: transform 120ms ease-out;
}

.tuile-vendeur:active {
  transform: scale(0.97);
}

.tuile-icone {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: var(--peche);
  color: var(--orange);
}

.tuile-icone .ico {
  width: 24px;
  height: 24px;
}

/* --- Les formulaires vendeur --- */
.numero-etape {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--orange);
  color: #FFFFFF;
  font-size: 14px;
  vertical-align: 2px;
}

.aide {
  margin: 6px 0 0;
}

.champ textarea {
  min-height: 110px;
  resize: vertical;
}

/* Les 4 tuiles photo */
.tuiles-photos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 8px;
}

.tuile-photo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 2px dashed #E4D6C8;
  border-radius: 18px;
  background: var(--creme);
  cursor: pointer;
  transition: border-color 150ms ease-out, transform 120ms ease-out;
}

.tuile-photo:active {
  transform: scale(0.97);
}

.tuile-photo.principale {
  border-color: var(--orange);
}

/* Le vrai bouton « choisir un fichier » : invisible, mais il couvre toute la tuile */
.tuile-photo input[type="file"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.tuile-photo:focus-within {
  outline: 2px solid var(--orange);
  outline-offset: 2px;
}

/* Le dessin et l'aperçu laissent passer le toucher jusqu'au bouton caché */
.tuile-photo-vide,
.apercu {
  pointer-events: none;
}

.tuile-photo-vide {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 8px;
  text-align: center;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--doux);
}

.tuile-photo-vide .ico {
  width: 30px;
  height: 30px;
  color: var(--orange);
}

.apercu {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tuile-photo.remplie {
  border-style: solid;
  border-color: var(--orange);
}

/* Les cases des tailles */
.cases-tailles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 10px 0 6px;
}

.cases-tailles input {
  text-align: center;
  font-weight: 600;
}

/* La barre d'action collée en bas (un seul gros bouton) */
.barre-action {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  padding: 12px 20px calc(12px + env(safe-area-inset-bottom, 0px));
  background: #FFFFFF;
  border-top: 1px solid var(--trait);
  box-shadow: 0 -10px 24px -18px rgba(28, 20, 16, 0.35);
}

.barre-action .bouton {
  width: 100%;
}

@media (min-width: 600px) {
  .tuiles-photos { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cases-tailles { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (min-width: 900px) {
  .tuiles-vendeur { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .barre-action {
    padding-left: max(20px, calc(50% - 320px));
    padding-right: max(20px, calc(50% - 320px));
  }
}

@media (hover: hover) and (pointer: fine) {
  .tuile-vendeur:hover,
  .tuile-photo:hover { border-color: var(--orange); }
}

/* =====================================================================
   22. MES PRODUITS (vendeur)
   ===================================================================== */
.liste-produits-vendeur {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ligne-produit-vendeur {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px;
  border: 1px solid var(--trait);
  border-radius: 20px;
  background: #FFFFFF;
  color: var(--texte);
  transition: transform 120ms ease-out;
}

.ligne-produit-vendeur:active {
  transform: scale(0.98);
}

.ligne-produit-vendeur .infos {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}

.ligne-produit-vendeur .nom {
  max-width: 100%;
  font-weight: 600;
  color: var(--nuit);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ligne-produit-vendeur .fleche {
  width: 18px;
  height: 18px;
  color: #B8AFA8;
}

/* Un produit masqué : sa photo pâlit */
.ligne-produit-vendeur.masque .vignette-panier {
  opacity: 0.5;
}

/* Pastilles « En ligne » (vert) et « Masqué » (gris) */
.statut-en-ligne { background: #EAF7EE; color: #17643A; }
.statut-masque   { background: var(--gris); color: #8C847E; }

@media (min-width: 900px) {
  .liste-produits-vendeur { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (hover: hover) and (pointer: fine) {
  .ligne-produit-vendeur:hover { border-color: var(--orange); }
}

/* =====================================================================
   23. GÉRER UN PRODUIT (vendeur)
   ===================================================================== */

/* --- L'en-tête : photo, nom, prix, statut --- */
.entete-produit {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 4px 0 14px;
}

.entete-produit .vignette-panier {
  width: 96px;
  height: 96px;
}

.entete-produit .infos {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  min-width: 0;
}

.entete-produit h1 {
  margin: 0;
  font-size: 21px;
}

.entete-produit .prix {
  font-size: 17px;
}

/* Bandeau jaune quand le produit est masqué */
.alerte-masque {
  margin-bottom: 14px;
  padding: 14px;
  border-radius: 18px;
  background: #FFF6DB;
  color: #7A5600;
}

.alerte-masque p {
  margin: 0 0 10px;
  font-weight: 500;
}

/* Les deux boutons « Modifier » et « Voir la fiche » */
.actions-produit {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 6px;
}

.actions-produit .bouton {
  min-height: 48px;
  padding: 0 12px;
  font-size: 14px;
}

.carte-blanche h3 {
  margin: 0 0 4px;
  font-size: 17px;
}

/* --- Les photos d'une couleur --- */
.grille-photos {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.photo-vendeur {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 14px;
  background: var(--gris);
}

.photo-vendeur img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-vendeur form,
.ajout-photo {
  margin: 0;
}

/* La petite poubelle rouge sur chaque photo */
.bouton-retirer {
  position: absolute;
  top: 4px;
  right: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #A32020;
  box-shadow: 0 2px 6px rgba(28, 20, 16, 0.2);
  cursor: pointer;
}

.bouton-retirer .ico {
  width: 16px;
  height: 16px;
}

/* La tuile « + Ajouter » reprend le style des tuiles photo (section 21) */
.ajout-photo .tuile-photo {
  border-radius: 14px;
}

.ajout-photo .tuile-photo-vide .ico {
  width: 24px;
  height: 24px;
}

.tuile-photo.envoi {
  border-style: solid;
  border-color: var(--orange);
}

/* --- Les tailles : une pastille par taille --- */
.pastilles-tailles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 12px;
}

.pastilles-tailles form {
  margin: 0;
}

.pastille-taille {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 56px;
  padding: 6px 12px;
  border: 1.5px solid #BFE5CB;
  border-radius: 14px;
  background: #EAF7EE;                /* vert : disponible */
  color: #17643A;
  font-family: inherit;
  cursor: pointer;
  transition: transform 120ms ease-out;
}

.pastille-taille:active {
  transform: scale(0.95);
}

.taille-nom {
  font-size: 16px;
  font-weight: 700;
  color: var(--nuit);
}

.taille-etat {
  font-size: 11px;
  font-weight: 600;
}

.pastille-taille.epuisee {               /* gris barré : épuisé */
  border-color: var(--trait);
  background: var(--gris);
  color: #8C847E;
}

.pastille-taille.epuisee .taille-nom {
  color: #A39B95;
  text-decoration: line-through;
}

/* Ajouter une taille : la case et le bouton sur la même ligne */
.ajout-taille {
  display: flex;
  gap: 8px;
}

.ajout-taille input {
  flex: 1;
  min-width: 0;
}

.ajout-taille .bouton {
  min-height: 50px;
  padding: 0 18px;
  box-shadow: none;
}

.zone-masquer {
  margin-top: 24px;
}

@media (hover: hover) and (pointer: fine) {
  .pastille-taille:hover { border-color: var(--orange); }
  .bouton-retirer:hover { background: #FDECEC; }
}

/* =====================================================================
   24. COMMANDES REÇUES, TABLEAU LIVREUR, REVERSEMENTS
   ===================================================================== */

/* --- Carte commune (une commande ou un article) --- */
.carte-suivi {
  margin-bottom: 12px;
  padding: 16px;
  border: 1px solid var(--trait);
  border-radius: 20px;
  background: #FFFFFF;
}

.carte-suivi-entete {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.carte-suivi-entete .numero {
  display: block;
  font-family: var(--titres);
  font-size: 16px;
  font-weight: 700;
  color: var(--nuit);
}

.carte-suivi form {
  margin: 0;
}

/* --- L'article (page vendeur) --- */
.article-vendeur {
  display: flex;
  align-items: center;
  gap: 12px;
}

.article-vendeur .vignette-panier {
  width: 64px;
  height: 64px;
  border-radius: 14px;
}

.article-vendeur strong {
  color: var(--nuit);
}

/* Plusieurs articles dans une même commande : un trait entre eux */
.article-bloc + .article-bloc {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--trait);
}

/* Commission offerte pendant le lancement : en vert */
.montants .offerte {
  color: #17643A;
}

/* --- Le bloc des montants --- */
.montants {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--creme);
}

.montants .resume-ligne {
  margin-bottom: 4px;
  font-size: 13.5px;
}

.montants .petit {
  margin: 2px 0 0;
}

.montant-fort {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed #E8D9CA;
  font-weight: 600;
  color: var(--nuit);
}

.montants > .montant-fort:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.montant-fort .prix {
  font-size: 19px;
  font-weight: 700;
}

/* --- Les bandeaux d'état --- */
.etat-ligne {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 13.5px;
  font-weight: 500;
}

.etat-paye    { background: #EAF7EE; color: #17643A; }   /* vert */
.etat-attente { background: #FFF6DB; color: #7A5600; }   /* jaune */
.etat-gris    { background: var(--gris); color: #6F6862; }
.etat-rouge   { background: #FDECEC; color: #A32020; }

/* --- Petits boutons --- */
.bouton-petit {
  min-height: 42px;
  padding: 0 14px;
  font-size: 13.5px;
  box-shadow: none;
}

.bouton-vert {
  background: #1F8A4C;
  box-shadow: none;
}

.form-signaler {
  margin-top: 12px;
}

/* --- La carte « Mes gains » --- */
.carte-gains {
  margin: 4px 0 14px;
  padding: 18px;
  border-radius: 24px;
  background: linear-gradient(135deg, #F39A55 0%, var(--orange) 70%);
  color: #FFFFFF;
  box-shadow: var(--ombre-orange);
}

.carte-gains p {
  margin: 0;
}

.gains-titre {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #FFE4CC;
}

.gains-montant {
  margin: 4px 0 2px !important;
  font-family: var(--titres);
  font-size: 30px;
  font-weight: 700;
  line-height: 1.15;
}

.gains-detail {
  font-size: 12.5px;
  color: #FFE4CC;
}

.gains-tuiles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.gains-tuiles div {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
}

.gains-tuiles span {
  display: block;
  font-size: 12px;
  color: #FFE4CC;
}

.gains-tuiles strong {
  display: block;
  font-size: 16px;
  white-space: nowrap;
}

/* --- Les chiffres du jour (livreur, reversements) --- */
.chiffres-livreur {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.chiffre {
  margin: 0;
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--gris);
  font-size: 13.5px;
  color: var(--doux);
}

.chiffre strong {
  display: block;
  font-size: 18px;
  color: var(--nuit);
  white-space: nowrap;
}

.chiffre-large {
  margin-bottom: 14px;
  background: var(--creme);
}

.chiffre-large strong {
  font-size: 24px;
  color: var(--terre);
}

/* --- Un quartier (titre) --- */
.titre-quartier {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 22px 0 10px;
  font-size: 16px;
}

.titre-quartier .ico {
  width: 18px;
  height: 18px;
  color: var(--orange);
}

/* --- Le client et ses boutons Appeler / WhatsApp --- */
.contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--trait);
}

.contact .infos {
  min-width: 0;
}

.contact .infos strong,
.contact .infos span {
  display: block;
}

.contact-boutons {
  display: flex;
  flex-shrink: 0;
  gap: 8px;
}

.rond-action {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--peche);
  color: var(--orange);
}

.rond-action .ico {
  width: 20px;
  height: 20px;
}

.rond-action.vert {
  background: #EAF7EE;
  color: #17643A;
}

/* --- Un article dans une livraison --- */
.article-livreur {
  padding: 10px 0;
  border-top: 1px dashed var(--trait);
}

.article-livreur .haut,
.article-livreur .vendeur-ligne {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.article-livreur .vendeur-ligne {
  margin-top: 4px;
}

.lien-discret {
  margin-top: 4px;
  padding: 6px 0;
  border: 0;
  background: none;
  font: 600 13px var(--corps);
  color: #A32020;
  cursor: pointer;
}

/* --- Les boutons d'une livraison --- */
.actions-commande {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 8px;
  margin-top: 12px !important;
}

.actions-commande .bouton {
  min-height: 48px;
  padding: 0 10px;
  font-size: 14px;
}

/* --- Reversements --- */
.alerte-recuperer {
  margin-bottom: 14px;
  padding: 14px;
  border-radius: 18px;
  background: #FFF6DB;
  color: #7A5600;
}

.alerte-recuperer h2 {
  margin: 0 0 8px;
  font-size: 15px;
  color: #7A5600;
}

.alerte-recuperer ul {
  margin: 0 0 8px;
  padding-left: 18px;
  font-size: 13.5px;
}

.entete-vendeur {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.entete-vendeur .infos {
  flex: 1;
  min-width: 0;
}

.entete-vendeur .infos strong,
.entete-vendeur .infos span {
  display: block;
}

.entete-vendeur .infos strong {
  color: var(--nuit);
}

.entete-vendeur .prix {
  font-size: 18px;
  font-weight: 700;
}

.ligne-reversement {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 0;
  border-top: 1px dashed var(--trait);
}

.ligne-reversement .infos {
  min-width: 0;
}

.ligne-reversement .infos > span {
  display: block;
}

@media (hover: hover) and (pointer: fine) {
  .bouton-vert:hover { background: #17643A; }
  .rond-action:hover { filter: brightness(0.96); }
}

/* =====================================================================
   25. COMPTES (connexion, inscription, devenir vendeur) ET NOTIFICATIONS
   ===================================================================== */

/* --- Pages connexion / inscription / devenir vendeur --- */
.auth {
  max-width: 440px;
  margin: 8px auto 0;
}

.auth-logo {
  display: block;
  width: 56px;
  height: 56px;
  margin: 4px 0 14px;
  border-radius: 16px;
  box-shadow: var(--ombre-orange);
}

.auth h1 {
  margin-bottom: 4px;
}

.auth > .petit {
  margin: 0 0 16px;
}

.auth form .bouton {
  width: 100%;
  margin-top: 4px;
}

.auth-bas {
  margin-top: 16px;
  text-align: center;
  font-size: 14px;
}

.auth-bas a {
  font-weight: 600;
  color: var(--terre);
}

/* --- Case à cocher avec son texte --- */
.case {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--texte);
  cursor: pointer;
}

.case input {
  flex-shrink: 0;
  margin: 1px 0 0;
}

/* --- Erreur générale d'un formulaire (ex. : mauvais mot de passe) --- */
.errorlist.nonfield {
  margin: 0 0 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: #FDECEC;
  font-weight: 500;
}

.aide ul {
  margin: 4px 0 0;
  padding-left: 18px;
}

/* --- Les avantages (devenir vendeur) --- */
.avantages {
  display: grid;
  gap: 10px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.avantages li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--creme);
  font-weight: 500;
  color: var(--nuit);
}

.avantages .tuile-icone {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: #FFFFFF;
}

.avantages .tuile-icone .ico {
  width: 20px;
  height: 20px;
}

/* --- Mes notifications --- */
.entete-notifs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.entete-notifs h1,
.entete-notifs form {
  margin: 0;
}

.bouton-lien {
  padding: 8px 0;
  border: 0;
  background: none;
  font: 600 13.5px var(--corps);
  color: var(--terre);
  cursor: pointer;
  white-space: nowrap;
}

.carte-push {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 0;
  padding: 16px;
  border-radius: 20px;
  background: var(--peche);
}

.carte-push p {
  margin: 0;
  font-size: 14px;
  color: var(--terre);
}

/* Si le téléphone ne sait pas recevoir de notifications, la carte se cache */
.carte-push:has(#activer-push[hidden]) {
  display: none;
}

#etat-push:empty {
  display: none;
}

.liste-notifs {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.liste-notifs form {
  margin: 0;
}

/* Une notification = un grand bouton */
.notif {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  padding: 14px;
  border: 1px solid var(--trait);
  border-radius: 18px;
  background: #FFFFFF;
  font: inherit;
  text-align: left;
  color: var(--texte);
  cursor: pointer;
}

.notif.non-lue {
  border-color: #F4E9DD;
  background: var(--creme);
}

.notif-icone {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gris);
  color: var(--doux);
}

.notif.non-lue .notif-icone {
  background: var(--peche);
  color: var(--orange);
}

.notif-icone .ico {
  width: 20px;
  height: 20px;
}

.notif-texte {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.notif-texte strong {
  color: var(--nuit);
}

.point-notif {
  flex-shrink: 0;
  width: 9px;
  height: 9px;
  margin-top: 6px;
  border-radius: 50%;
  background: var(--orange);
}

@media (hover: hover) and (pointer: fine) {
  .notif:hover { border-color: var(--orange); }
  .auth-bas a:hover,
  .bouton-lien:hover { color: var(--orange); }
}