/* doc-project | commande/v1/assets/css/components/chips.css | Définit les styles des chips, du bloc dryrun, de la recherche et de la modal "none fits" pour l’interface de commande. | Expose: aucun | Dépend de: aucun | Impacte: UI | Tables: aucune */
.dryrun{
  display:block;
  margin: 0 0 10px;
  padding: 10px 12px;
  border-radius: 14px;
  /* Dans le panier, le bloc est dans une card (fond clair) => texte blanc illisible.
     On bascule vers une variante "surface claire" (cohérente avec .chip / .search). */
  border: 1px dashed rgba(0,0,0,.18);
  background: rgba(255,255,255,.86);
  color: var(--text);
  box-shadow: var(--shadow);
}
.dryrun__row{
  display:flex;
  gap: 10px;
  align-items:center;
  flex-wrap:wrap;
}
.dryrun__label{
  font-weight: 950;
  font-size: 14px;
  white-space: nowrap;
}
.dryrun__value{
  font-weight: 800;
  font-size: 13px;
  opacity: .98;
  white-space: nowrap;
}
.dryrun__range{
  flex: 1 1 220px;
  min-width: 180px;
}

.chips{
  display:flex;
  gap: 8px;
  flex-wrap: wrap;
}
.chips--scroll{
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
  padding-bottom: 2px; /* évite de couper l'ombre/border */
  scroll-snap-type: x mandatory;
}
.chips--scroll::-webkit-scrollbar{ display:none; }
.chips--scroll .chip{
  flex: 0 0 auto;
  scroll-snap-align: start;
}
.chip{
  border: 1px solid rgba(0,0,0,.12);
  background: rgba(255,255,255,.72);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}
.chip--ok{
  border-color: rgba(27,127,42,.35);
  background: rgba(27,127,42,.12);
}
.chip--warn{
  border-color: rgba(255,136,0,.45);
  background: rgba(255,136,0,.16);
}
.chip--slot{
  position: relative;
  padding-top: 10px;
  padding-bottom: 16px; /* espace pour badge bas */
  padding-right: 16px;  /* espace visuel badge haut droite */
}
.chip--nonefits{
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 10px auto 0;
  text-align: center;
  border-color: rgba(255,0,0,.55);
  background: #d40000;
  color: #fff;
}
.chip__label{
  display: block;
}
.chip__badge{
  position: absolute;
  z-index: 2;
  min-width: 18px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 950;
  line-height: 18px;
  border: 1px solid rgba(0,0,0,.14);
  background: rgba(255,255,255,.92);
  color: #111;
  pointer-events: none;
}
.chip__badge--tr{
  top: -7px;
  right: -7px;
}
.chip__badge--bc{
  bottom: -7px;
  left: 50%;
  transform: translateX(-50%);
}
.chip.is-active{
  background: #111;
  color: #fff;
  border-color: #111;
}
.chip.is-active .chip__badge{
  background: rgba(0,0,0,.42);
  border-color: rgba(255,255,255,.18);
  color: #fff;
}
.chip--nonefits:hover{
  filter: brightness(.95);
}
.chip--nonefits:active{
  filter: brightness(.9);
}
.chip[disabled]{
  opacity: .55;
  cursor: not-allowed;
}
.chip[disabled] .chip__badge{
  opacity: .7;
}

.nonefitsModal{
  position: fixed;
  inset: 0;
  z-index: 9999;
}
.nonefitsModal__backdrop{
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.55);
}
.nonefitsModal__panel{
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(520px, calc(100vw - 32px));
  background: rgba(255,255,255,.98);
  border: 1px solid rgba(0,0,0,.14);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 14px 14px 16px;
  color: var(--text);
}
.nonefitsModal__close{
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,.12);
  background: rgba(255,255,255,.92);
  cursor: pointer;
  font-size: 20px;
  font-weight: 900;
  line-height: 32px;
}
.nonefitsModal__title{
  font-weight: 950;
  font-size: 16px;
  padding-right: 42px; /* évite le chevauchement avec la croix */
  margin: 2px 0 8px;
}
.nonefitsModal__text{
  font-weight: 750;
  font-size: 14px;
  line-height: 1.35;
  opacity: .96;
  margin: 0 0 12px;
}
.nonefitsModal__call{
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto;
  text-align: center;
  text-decoration: none;
}

.search{
  display:flex;
  gap: 8px;
  align-items:center;
  background: rgba(255,255,255,.92);
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: var(--shadow);
}
.search__icon{ opacity:.7; }
.search__input{
  border:0;
  outline: none;
  flex: 1 1 auto;
  min-width: 0;
  background: transparent;
  font-weight: 700;
}

/* Micro-optimisation mobile: input plus dense (sans perdre le "tap target") */
@media (max-width: 380px){
  .chip{
    padding: 7px 10px;
    font-size: 13px;
  }
  .search{
    padding: 9px 10px;
  }
}

