/* V5 · PAGE FICHES — modèle « Collection » (docs/design-system-v5/05_CONCEPTION_REFONTE.md, § D6 et § H).
   Les primitives viennent de modeles.css (.v5-grille, .v5-cellule…), primitives.css et controles.css : ce fichier ne règle que
   l'assemblage propre à Fiches (grille, inspecteur). Violet : sélection de photos, « Nouvelle fiche », « Publier ».
   Chargé avec media="(min-width:768px)" ; le contenu est produit par js/v5/pages/fiches.js et js/conseils-ia.js. */

/* ================================================================== grille : bord à bord */
.vt-fiches, .vt-fiches-principal{ display: block; }
#brouillons-list.v5-grille{ padding: 0; }
#brouillons-list.v5-grille > .v5-etat,
#brouillons-list.v5-grille > .fi-aucun{ grid-column: 1 / -1; }
.v5-cellule-legende{ pointer-events: none; }

/* ================================================================== inspecteur (élément déplacé dans le shell, qui lui laisse tout l'espace) */
#v5-inspecteur .v5-inspecteur-corps:has(> #fiches-inspecteur){ padding: 0; overflow: hidden; display: flex; }
#fiches-inspecteur{ flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; border: 0; background: none; }
#fiches-inspecteur[hidden]{ display: none; }
#fiches-inspecteur > .v5-inspecteur-cadre{ flex: 1; width: 100%; min-height: 0; }
#fiches-inspecteur .v5-inspecteur-pied{ flex-wrap: wrap; }

.v5-ins-photo{ display: grid; place-items: center; margin: 0 auto 8px; overflow: hidden; aspect-ratio: 4 / 5; border-radius: var(--v5-r-photo); background: var(--v5-surface-inset); }
.v5-ins-photo img{ width: 100%; height: 100%; object-fit: contain; display: block; }
.v5-ins-vignettes{ display: flex; gap: 4px; margin: 0 0 12px; }
.v5-ins-vign{ width: 44px; height: 44px; padding: 0; border: 0; overflow: hidden; border-radius: var(--v5-r-photo); background: var(--v5-surface-inset); cursor: default; }
.v5-ins-vign img{ width: 100%; height: 100%; object-fit: cover; display: block; }
.v5-ins-vign.actif{ outline: var(--v5-focus-l) solid var(--v5-photo-selection); outline-offset: -2px; }   /* photo choisie : seul usage violet de l'inspecteur avec « Publier » */
.v5-ins-vign:focus-visible{ outline: var(--v5-focus-l) solid var(--v5-focus); outline-offset: 1px; }

.v5-ins-champs{ display: flex; flex-direction: column; gap: 0; margin: 0 0 12px; padding: 0 12px; border-radius: var(--v5-r-groupe); background: var(--v5-fond-groupe);   /* 01/11 : remplissage de groupe (même fond que le panneau : cadre invisible en clair) */ box-shadow: inset 0 0 0 var(--v5-trait-fort) var(--v5-separateur); }   /* un groupe de lignes, comme « Informations » */
.v5-ins-champ{ display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 40px; box-sizing: border-box; padding: 6px 0; font-size: var(--v5-t-13); box-shadow: inset 0 calc(-1 * var(--v5-trait-fort)) 0 var(--v5-separateur); }
.v5-ins-champ:not(:has(~ .v5-ins-champ)){ box-shadow: none; }
.v5-ins-champ > span:first-child{ color: var(--v5-texte); }
.v5-ins-prix{ display: inline-flex; align-items: center; gap: 6px; color: var(--v5-texte-2); }
.v5-ins-prix input{ width: 84px; text-align: right; }
.v5-ins-liste{ max-width: 200px; }
.v5-ins-champs .vt-completer-date{ width: 100%; margin: 0 0 8px; }
.v5-ins-publier{ display: flex; width: auto; min-width: 120px; margin: 0 0 0 auto; }   /* action d'un formulaire : à droite, à la taille de son libellé (08_ECHELLE_DES_FORMES) */
.v5-ins-aide{ margin: 8px 0 0; font-size: var(--v5-t-12); line-height: 1.4; color: var(--v5-texte-2); }
.v5-ins-note{ display: flex; gap: 8px; margin: 12px 0; padding: 10px 12px; border-radius: var(--v5-r-sel); background: var(--v5-fond-groupe); font-size: var(--v5-t-12); }
.v5-ins-note .v5-point{ margin-top: 5px; }
.v5-ins-note b{ display: block; margin-bottom: 2px; font-size: var(--v5-t-13); font-weight: var(--v5-g-moyen); }
.v5-ins-note p{ margin: 2px 0 0; color: var(--v5-texte-2); overflow-wrap: anywhere; }

/* la photothèque occupe toute la largeur du contenu : pas de marge de page (celle de .view, 8 / 40 / 48 px) tant que Fiches est ouverte */
#view-vinted[data-panel="fiches"]{ padding: 0; max-width: none; }
/* la page occupe toute la hauteur : le rectangle de sélection (lasso) peut partir du vide sous la grille, comme dans le Finder */
html.v5 #view-vinted[data-panel="fiches"] [data-vt-panel-body="fiches"]{ min-height: calc(100vh - var(--v5-barre-h)); position: relative; }
/* le rectangle de sélection (lasso, z-index 0) passe derrière les photos */
#brouillons-list.v5-grille .vt-fiche{ position: relative; z-index: 1; }
#fiches-attente:not([hidden]){ padding: 12px 16px 0; }
#fiches-inspecteur .sel-btn{ display: none; }   /* le bouton de menu V5 (js/v5/pages/fiches.js) remplace le déclencheur historique des listes */
@media (max-width: 1000px){ .v5-zoom .v5-curseur{ width: 72px; } }   /* barre d'outils étroite : le curseur de zoom raccourcit */
/* état « en cours » sur une photo : point blanc, pas violet. Le violet de la grille est réservé à la sélection (contour + coche) ; plusieurs fiches en cours ne doivent pas le diluer. */
#brouillons-list .v5-cellule-etat[data-etat="encours"]{ background: var(--v5-sur-photo); }

/* zoom des fiches (11/10) : la grille a un nombre de colonnes fixé par le zoom (js/v5/pages/fiches.js), au lieu de colonnes
   « autant qu'il en rentre » qui rendaient certains crans sans effet */
#brouillons-list.v5-grille{ grid-template-columns: repeat(var(--v5-colonnes, 6), minmax(0, 1fr)); }

/* 11/10 — inspecteur : la photo ne prend pas plus de 38 % de la hauteur de la fenêtre, pour que le prix, le compte et « Publier »
   restent visibles sans défiler sur un écran de portable */
.v5-ins-photo{ max-height: 38vh; }

/* 11/10 — vignettes trop petites pour la légende permanente (< 230 px) : au survol, au clavier et pour la fiche sélectionnée, le titre
   et l'état s'écrivent en clair sur la photo (le point de couleur seul ne dit ni quelle fiche, ni quel état). Le compteur de photos
   passe en haut, comme avec la légende permanente. */
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule:is(:hover, :focus-visible, [aria-selected="true"]) .v5-cellule-legende{ display: block; }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule:is(:hover, :focus-visible, [aria-selected="true"]) .v5-cellule-compte{ bottom: auto; top: 6px; left: 30px; }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende{ padding: 4px 6px; font-size: var(--v5-t-11); }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende b{ display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-weight: var(--v5-g-moyen); }

/* 12/10 — légende des petites vignettes (< 230 px, sans légende permanente), survol / focus / fiche sélectionnée : à 78 px de côté (inspecteur ouvert), la légende de 4 lignes (95 px) recouvrait toute la photo,
   le titre était tronqué en plein mot. Elle devient une bande de deux lignes au plus : le titre (une ligne, deux dès 130 px), puis l'état, le prix et le compte, coupés par une ellipse en fin de ligne
   (l'état, placé en premier, se lit toujours). Le compteur de photos reste en haut à gauche, à côté de la coche, comme avec la légende permanente. */
#brouillons-list.v5-grille .v5-cellule{ container-type: inline-size; }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende{ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende br{ display: none; }
#brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende b{ white-space: normal; }
@container (max-width: 130px){
  #brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende{ padding: 3px 5px; font-size: var(--v5-t-11); line-height: 14px; }
  #brouillons-list.v5-grille:not([data-legende]) .v5-cellule-legende b{ display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

/* ================================================================== 17/10 — « Fiche à compléter » (#brouillon-auto-modal), Lucas : « améliore ça »
   Façon Claude / Cursor : en-tête court, photos plus grandes avec des repères discrets (★ ou numéro, « IA »), outils au survol seulement,
   deux boutons compacts, une ligne d'aide, champs au même gabarit, pied fixe (Supprimer à gauche, Annuler / Enregistrer à droite). */
html.v5 #brouillon-auto-modal .vt-ba-feuille:not(#_){ width: min(560px, calc(100vw - 48px)); max-width: none; max-height: min(86vh, 820px); padding: 22px 22px 0; }
html.v5 #brouillon-auto-modal .detail-name{ font-size: var(--v5-t-17); font-weight: var(--v5-g-fort); }
html.v5 #brouillon-auto-modal .vt-ba-intro{ margin: 2px 0 0; font-size: var(--v5-t-13); color: var(--v5-texte-2); }
/* photos */
html.v5 #brouillon-auto-modal .vt-ba-photos:not(#_){ display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; margin: 16px 0 10px; }
html.v5 #brouillon-auto-modal .vt-ba-vignette{ position: relative; aspect-ratio: 1; border-radius: var(--v5-r-sel); overflow: hidden; background: var(--v5-fond-groupe); touch-action: none; user-select: none; cursor: grab; box-shadow: inset 0 0 0 var(--v5-trait-fort) var(--v5-separateur); }
html.v5 #brouillon-auto-modal .vt-ba-vignette.principale{ outline: 2px solid var(--v5-texte); outline-offset: -2px; }
html.v5 #brouillon-auto-modal .vt-ba-vignette img, html.v5 #brouillon-auto-modal .vt-ba-vide{ display: block; width: 100%; height: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
/* 19/10 (Lucas) : plus de numéro, de mention « IA » ni d'étoile sur les vignettes ; au survol, un voile sombre qui se pose doucement et
   un bouton « Modifier » (icône + mot) qui monte en place, « Refaire » en petit cercle à côté. Le glisser pour changer l'ordre reste partout ailleurs. */
html.v5 #brouillon-auto-modal .vt-ba-vignette::after{ content: ""; position: absolute; inset: 0; background: var(--v5-voile); opacity: 0; transition: opacity var(--v5-duree) var(--v5-courbe); pointer-events: none; }
html.v5 #brouillon-auto-modal .vt-ba-vignette:is(:hover, :focus-within)::after{ opacity: 1; }
html.v5 #brouillon-auto-modal .vt-ba-outils{ position: absolute; z-index: 1; left: 8px; right: 8px; bottom: 8px; display: flex; justify-content: center; align-items: center; gap: 6px; opacity: 0; transform: translateY(6px); transition: opacity var(--v5-duree) var(--v5-courbe), transform var(--v5-duree) var(--v5-courbe); }
html.v5 #brouillon-auto-modal .vt-ba-vignette:is(:hover, :focus-within) .vt-ba-outils{ opacity: 1; transform: none; }
/* 19/10 (Lucas, modèle en image) : petits carrés arrondis avec un liseré, crayon seul ; au survol, le carré s'éclaircit, son liseré
   s'affirme et il grossit un peu, d'un mouvement doux */
html.v5 #brouillon-auto-modal .vt-ba-outils > button:not(#_):not(#_){ display: grid; place-items: center; width: 34px; height: 34px; min-width: 0; margin: 0; padding: 0; border: 0; border-radius: 10px; background: var(--v5-photo-btn); color: var(--v5-sur-photo); box-shadow: inset 0 0 0 1px var(--v5-photo-btn-bord), var(--v5-ombre-bulle); backdrop-filter: blur(8px); cursor: pointer; transition: background-color var(--v5-duree) var(--v5-courbe), box-shadow var(--v5-duree) var(--v5-courbe), scale var(--v5-duree) var(--v5-courbe); }
html.v5 #brouillon-auto-modal .vt-ba-outils svg{ width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
html.v5 #brouillon-auto-modal .vt-ba-outils > button:not(#_):not(#_):hover{ background: var(--v5-photo-btn-survol); box-shadow: inset 0 0 0 1px var(--v5-photo-btn-bord-survol), var(--v5-ombre-bulle); scale: 1.08; }
html.v5 #brouillon-auto-modal .vt-ba-outils > button:not(#_):not(#_):active{ scale: .96; }
/* boutons et aide */
html.v5 #brouillon-auto-modal .vt-ba-actions:not(#_){ gap: 8px; margin: 0 0 16px; }
html.v5 #brouillon-auto-modal .vt-ba-actions > button:not(#_):not(#_){ width: auto; height: var(--v5-ctrl-h); padding: 0 12px; font-size: var(--v5-t-12); }
html.v5 #brouillon-auto-modal .vt-ba-aide:not(#_){ flex: 1 1 100%; margin: 2px 0 0; font-size: var(--v5-t-12); line-height: 16px; color: var(--v5-texte-3); }
/* champs : libellé au-dessus, même hauteur partout */
html.v5 #brouillon-auto-modal .field:not(#_){ display: block; margin: 0 0 12px; }
html.v5 #brouillon-auto-modal .field > .lbl:not(#_){ display: block; margin: 0 0 5px; font-size: var(--v5-t-12); font-weight: var(--v5-g-moyen); color: var(--v5-texte-2); }
html.v5 #brouillon-auto-modal .vt-ba-desc:not(#_){ min-height: 120px; padding: 8px 10px; border: 0; border-radius: var(--v5-r-champ); background: var(--v5-surface-inset); box-shadow: inset 0 0 0 var(--v5-trait-fort) var(--v5-separateur); color: var(--v5-texte); font-size: var(--v5-t-13); line-height: 1.45; }
html.v5 #brouillon-auto-modal .vt-ba-desc:focus-visible{ outline: none; box-shadow: inset 0 0 0 var(--v5-focus-l) var(--v5-violet); }
/* pied fixe en bas de la feuille */
html.v5 #brouillon-auto-modal .vt-ba-pied:not(#_){ position: sticky; bottom: 0; z-index: 1; display: flex; align-items: center; gap: 8px; margin: 16px -22px 0; padding: 12px 22px; background: var(--v5-fond); box-shadow: inset 0 var(--v5-trait-fort) 0 var(--v5-separateur); }
html.v5 #brouillon-auto-modal .vt-ba-pied > button:not(#_):not(#_){ flex: 0 0 auto; width: auto; height: var(--v5-ctrl-l); padding: 0 16px; }
html.v5 #brouillon-auto-modal .vt-ba-pied #brouillon-auto-supprimer:not(#_):not(#_){ margin-right: auto; padding: 0 10px; border: 0; background: none; box-shadow: none; color: var(--v5-rouge); }
html.v5 #brouillon-auto-modal .vt-ba-pied #brouillon-auto-supprimer:not(#_):not(#_):hover{ background: var(--v5-survol); }

/* ================================================================== fenêtre « Date de publication » (vtChangerDate, js/conseils-ia.js)
   24/10 (Lucas : « des trucs qui se superposent ») : la fenêtre n'avait pas de mise en page à elle : sous-titre remonté sous le titre
   (marge négative de .vt-modifier-aide), blocs collés. Colonne espacée comme les autres fenêtres de Fiches. */
html.v5 #date-fiche-modal .vt-modifier-sheet{ display: flex; flex-direction: column; gap: 14px; width: calc(100vw - 48px); max-width: 480px; }
html.v5 #date-fiche-modal .vt-modifier-aide{ margin: -8px 0 0; padding-right: 24px; }
html.v5 #date-fiche-modal .detail-name{ padding-right: 28px; }
html.v5 #date-fiche-modal .rel-pied{ display: flex; align-items: center; gap: 8px; justify-content: flex-end; }
html.v5 #date-fiche-modal .rel-pied .status-line{ margin-right: auto; }
html.v5 #date-fiche-modal .pub-quand{ display: grid; grid-template-columns: max-content repeat(3, minmax(0, 1fr)); gap: 6px; }
html.v5 #date-fiche-modal .pub-quand .pub-choix{ width: 100%; min-width: 0; padding: 0 10px; white-space: nowrap; }

/* ================================================================== 25/10 : gamme « Notion » choisie par Lucas (comme Aujourd'hui) :
   la photothèque devient une galerie de cartes posées sur la page — marges, espace entre les cartes, photo arrondie, titre et
   « état · prix · compte » écrits SOUS la photo (plus de bandeau sur l'image). Composants, points d'état et violet inchangés. */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list.v5-grille{ gap: 18px 14px; padding: 20px 24px 48px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule{ aspect-ratio: auto; overflow: visible; background: none; border-radius: var(--v5-r-sel); }
/* la photo : carré arrondi ; le fond gris est posé dessous (pseudo-élément) pour rester visible si l'image ne charge pas */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule::before{ content: ""; position: absolute; top: 0; left: 0; width: 100%; aspect-ratio: 1; border-radius: var(--v5-r-sel); background: var(--v5-surface-inset); }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule > img{ position: relative; aspect-ratio: 1; height: auto; border-radius: var(--v5-r-sel); }
/* sélection et focus : contour sur la photo, pas sur la carte entière */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule[aria-selected="true"]{ outline: none; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule[aria-selected="true"] > img{ outline: var(--v5-focus-l) solid var(--v5-photo-selection); outline-offset: -3px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule:focus-visible{ outline-offset: 3px; }
/* compteur de photos en haut, à côté de la coche du mode sélection */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-compte{ top: 6px; bottom: auto; left: 30px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule:not([aria-selected="true"]) .v5-cellule-compte{ left: 6px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list.v5-grille[data-selection] .v5-cellule-compte{ left: 30px; }
/* légende sous la photo, toujours visible : titre sur une ligne, puis état · prix · compte en gris */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende{
  position: static; display: block; padding: 8px 2px 0; background: none; color: var(--v5-texte-2);
  font-size: var(--v5-t-12); line-height: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende br{ display: none; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--v5-t-13); line-height: 18px; font-weight: var(--v5-g-moyen); color: var(--v5-texte); }
/* image absente (hors réseau) : le symbole photo se centre sur la photo, pas sur la carte */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule:has(> img[data-absente])::after{
  inset: 0 auto auto 0; width: 100%; height: auto; aspect-ratio: 1; margin: 0;
  -webkit-mask-size: 22px; mask-size: 22px; -webkit-mask-position: center; mask-position: center; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
/* toutes petites cartes (inspecteur ouvert, zoom au minimum) : le compteur de photos chevauchait le point d'état et la ligne
   « état · prix » n'était plus lisible : on garde la photo, le point et le titre seul */
@container (max-width: 80px){
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-compte{ display: none; }
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende{ height: 24px; padding-top: 6px; }
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ font-size: var(--v5-t-12); }
}

/* 25/10 (Lucas : le point et le nombre posés sur la photo, « c'est pas la meilleure manière ») : la photo reste nue.
   L'état se lit sous la photo, point + mot (« ● À publier · 9 € · compte ») ; le nombre de photos passe en petit, gris, avec une icône,
   au bout de la ligne du titre. */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende{ padding-left: 15px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ margin-left: -13px; padding-right: 34px; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-etat{ top: auto; right: auto; left: 2px; bottom: 4px; box-shadow: none; }
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-compte,
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list.v5-grille[data-selection] .v5-cellule-compte,
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule:not([aria-selected="true"]) .v5-cellule-compte{
  top: calc(100cqw + 9px); bottom: auto; left: auto; right: 0; display: inline-flex; align-items: center; gap: 3px; padding: 0;
  background: none; color: var(--v5-texte-3); font: var(--v5-g-normal) var(--v5-t-12)/16px var(--v5-police);
}
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-compte::before{
  content: ""; width: 12px; height: 12px; background-color: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='8' y='8' width='13' height='13' rx='2.5'/%3E%3Cpath d='M16 4H6a2 2 0 0 0-2 2v10'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='8' y='8' width='13' height='13' rx='2.5'/%3E%3Cpath d='M16 4H6a2 2 0 0 0-2 2v10'/%3E%3C/svg%3E") center / contain no-repeat;
}
@container (max-width: 80px){
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ padding-right: 0; }
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-etat{ bottom: 5px; }
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ margin-left: 0; }
}
/* « en cours » : le point blanc était fait pour la photo ; sous la photo, il serait invisible en thème clair */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-etat[data-etat="encours"]{ background: var(--v5-texte-2); }
/* petites cartes : pas la place pour le nombre de photos à côté du titre */
@container (max-width: 120px){
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-compte,
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list.v5-grille[data-selection] .v5-cellule-compte,
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule:not([aria-selected="true"]) .v5-cellule-compte{ display: none; }
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ padding-right: 0; }
}

/* 25/10 (Lucas) : deux dispositions au choix dans la barre — « Galerie » (cartes avec titre, état, nombre de photos : règles ci-dessus)
   et « Mosaïque » (photos collées, comme avant : règles d'origine du fichier, état et nombre posés sur la photo). Le choix est sur
   <html data-fiches-dispo>, posé par js/v5/pages/fiches.js et gardé dans le navigateur. */

/* 26/10 : fiche sans aucune photo (ni enregistrée, ni sur son annonce Vinted) : jamais un carré noir, le symbole photo discret
   (le même que pour une image qui ne charge pas) */
html.v5 #brouillons-list .v5-cellule[data-sans-photo]::after{
  content: ""; position: absolute; inset: 0 auto auto 0; width: 100%; aspect-ratio: 1; background-color: var(--v5-texte-3);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.6'/%3E%3Cpath d='M21 16l-5-5-8 8'/%3E%3C/svg%3E") center / 22px no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.6'/%3E%3Cpath d='M21 16l-5-5-8 8'/%3E%3C/svg%3E") center / 22px no-repeat;
}
html.v5[data-fiches-dispo="mosaique"] #brouillons-list .v5-cellule[data-sans-photo]::after{ height: 100%; }
/* sans image, la légende garde sa place sous le carré de la photo (galerie) */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule[data-sans-photo] .v5-cellule-legende{ margin-top: 100cqw; }

/* 31/10 : petites cartes (panneau de détail ouvert, zoom serré) — le titre coupé à 12 lettres ne disait plus rien : il passe sur deux lignes,
   et le nom du compte s'efface pour laisser « état · prix » entiers */
@container (max-width: 190px){
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; white-space: normal; overflow-wrap: anywhere; min-height: 36px; }   /* deux lignes réservées : le point d'état reste sur la ligne « état · prix » */
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-nom-compte{ display: none; }
}
/* 31/10 : « À publier · 9 € · compte » — l'espacement de mots resserré de la police collait les points aux mots en 12 px */
html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende{ word-spacing: normal; }

/* 01/11 : cartes minuscules (≤ 48 px : panneau ouvert, zoom serré, fenêtre de 820 px) — il restait 13 px pour le titre, réduit à une lettre coupée
   (« H », « J ») : seul le point d'état reste sous la photo */
@container (max-width: 48px){
  html.v5:not([data-fiches-dispo="mosaique"]) #view-vinted #brouillons-list .v5-cellule-legende b{ visibility: hidden; }
}

/* 01/11 : Mosaïque — les photos restent collées, mais la grille garde les marges de la Galerie : elle allait d'un bord à l'autre de la
   zone (16 px à gauche et 24 px à droite au-delà du filet des onglets) et touchait ce filet sans aucun écart */
html.v5[data-fiches-dispo="mosaique"] #view-vinted #brouillons-list.v5-grille{ padding: 12px 24px 48px; }
