.csins { --csins-bord: color-mix(in srgb, currentColor 14%, transparent);
    margin: 2em 0 2.5em; clear: both;
    border: 1px solid var(--csins-bord);
    border-radius: var(--csins-rayon, 14px);
    padding: 1.4em 1.5em; }
.csins__titre { font-size: 1.15em; font-weight: 700; margin: 0 0 1.1em; line-height: 1.3; }

/* Rangée de vignettes et bloc du total côte à côte tant qu'il y a la
   place ; l'un sous l'autre dès que c'est serré, sans point de rupture
   fixe — c'est la largeur réelle du conteneur qui décide, pas celle de
   l'écran, car le bloc peut vivre dans une colonne étroite. */
.csins__corps { display: flex; flex-wrap: wrap; gap: 1.6em 2.2em;
    align-items: center; justify-content: flex-start; }

/* La rangée ne se replie jamais : un « + » renvoyé en fin de ligne se
   retrouve orphelin, séparateur sans rien à séparer. Ce sont les
   vignettes qui rétrécissent, toutes ensemble, jusqu'à leur plancher. */
.csins__rangee { display: flex; align-items: center; gap: .7em; flex-wrap: nowrap;
    list-style: none; margin: 0; padding: 0; flex: 0 1 auto; min-width: 0; }
/* max-width borne la contribution intrinsèque : sans elle, l'image en
   width:100% fait remonter sa largeur naturelle — 600 px pour une photo
   de pièce — et la rangée réclame toute la largeur, chassant le total
   sur la ligne suivante alors qu'il y avait la place. */
.csins__vignette { margin: 0; flex: 0 1 92px; min-width: 44px; max-width: 92px; }
/* color:inherit avant tout : --csins-bord se résout en currentColor à
   l'endroit où il sert, et dans un <a> ce serait la couleur des liens du
   thème — un liseré bleu autour de chaque vignette. */
.csins__vignette a { color: inherit; display: block; border: 1px solid var(--csins-bord);
    border-radius: max(4px, calc(var(--csins-rayon, 14px) * .45));
    overflow: hidden; background: #fff;
    transition: border-color .15s ease, transform .15s ease; }
.csins__vignette a:hover, .csins__vignette a:focus-visible {
    border-color: var(--csins-accent, currentColor); transform: translateY(-2px); }
.csins__vignette img { display: block; width: 100%; height: auto; aspect-ratio: 1;
    object-fit: contain; margin: 0; padding: 6px; box-sizing: border-box; }
.csins__plus { margin: 0; flex: 0 0 auto; font-size: 1.6em; font-weight: 400;
    opacity: .3; line-height: 1; user-select: none; }

/* Le total colle aux vignettes plutôt que d'être repoussé au bord : entre
   les deux, un vide de plusieurs centimètres cassait la lecture « ces
   articles font ce prix ». */
.csins__total { flex: 0 1 auto; text-align: left; min-width: 200px; }
.csins__total-prix { margin: 0 0 .5em; line-height: 1.3; }
.csins__total-libelle { display: block; font-size: .85em; opacity: .7; }
.csins__total-somme { font-size: 1.35em; font-weight: 700;
    color: var(--csins-accent, inherit); }

.csins__ajouter-tout { box-sizing: border-box !important; display: inline-block !important;
    width: 100%; border: 0; cursor: pointer; text-align: center; text-decoration: none;
    background: var(--csins-accent, #1d2327); color: #fff;
    font-family: inherit !important; font-size: .92em !important; font-weight: 600 !important;
    line-height: 1.3 !important; padding: .7em 1.2em !important; min-height: 0 !important;
    text-transform: none !important; letter-spacing: normal !important;
    border-radius: max(4px, calc(var(--csins-rayon, 14px) * .5));
    transition: opacity .15s ease, transform .12s ease; }
.csins__ajouter-tout:hover { opacity: .88; }
.csins__ajouter-tout:active { transform: scale(.98); }
.csins__ajouter-tout[disabled] { opacity: .5; cursor: default; transform: none; }
.csins__note { margin: .5em 0 0; font-size: .82em; line-height: 1.35;
    opacity: .75; min-height: 1.2em; }

/* La liste à cocher, sous la rangée : un trait la sépare des vignettes
   sans ajouter de cadre — le bloc en a déjà un. */
.csins__choix { list-style: none; margin: 1.3em 0 0; padding: 1.2em 0 0;
    border-top: 1px solid var(--csins-bord); display: grid; gap: .7em; }
.csins__choix-item { margin: 0; }
.csins__case { display: flex; align-items: flex-start; gap: .6em; cursor: pointer; }
.csins__case--sans { cursor: default; padding-left: 1.75em; }
.csins__coche { flex: 0 0 auto; margin: .15em 0 0; width: 1.05em; height: 1.05em;
    accent-color: var(--csins-accent, #1d2327); cursor: pointer; }
.csins__etiquette { font-size: .92em; line-height: 1.45; }
.csins__cet-article { font-weight: 700; margin-right: .3em; }
.csins__etiquette a { color: inherit; text-decoration: none;
    border-bottom: 1px solid transparent; transition: border-color .15s ease; }
.csins__etiquette a:hover { border-bottom-color: currentColor; }
.csins__prix { margin-left: .5em; font-weight: 700; white-space: nowrap; }
.csins__options { margin-left: .5em; font-size: .88em; opacity: .65; font-style: italic; }
.csins__case:has(.csins__coche:not(:checked)) .csins__etiquette { opacity: .5; }

@media (prefers-reduced-motion: reduce) {
    .csins__vignette a, .csins__ajouter-tout { transition: none; }
}
