/* ==========================================================================
   Univers LP Business — Page boutique : fil d'Ariane, sidebar filtres, grille, pagination
   ========================================================================== */

/* ---- Fil d'Ariane ---- */
.breadcrumb {
  padding-block: var(--space-md);
  font-size: 0.85rem;
  color: var(--color-ink-soft);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.breadcrumb a {
  color: var(--color-ink-soft);
  transition: color var(--duration-fast) var(--ease-standard);
}

.breadcrumb a:hover {
  color: var(--color-violet-medium);
}

.breadcrumb li:not(:last-child)::after {
  content: '/';
  margin-left: 0.4rem;
  color: var(--color-grey-300);
}

.breadcrumb li[aria-current] {
  color: var(--color-violet-deep-1);
  font-weight: 700;
}

/* ---- Layout boutique ---- */
.shop-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--space-xl);
  align-items: start;
  padding-bottom: var(--space-2xl);
}

.shop-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
}

.shop-header h1 {
  font-size: 1.7rem;
}

.shop-header__count {
  color: var(--color-ink-soft);
  font-size: 0.9rem;
}

/* ---- Sidebar filtres ---- */
.filters-sidebar {
  position: sticky;
  top: calc(var(--header-height) + var(--space-md));
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  box-shadow: var(--shadow-rest);
}

.filter-group {
  padding-block: var(--space-md);
  border-bottom: 1px solid var(--color-grey-200);
}

.filter-group:first-child {
  padding-top: 0;
}

.filter-group:last-child {
  border-bottom: none;
}

.filter-group__title {
  font-family: var(--font-title);
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-violet-deep-1);
  margin-bottom: var(--space-sm);
}

.filter-option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0;
  font-size: 0.9rem;
  color: var(--color-ink-soft);
  cursor: pointer;
}

.filter-option input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--color-magenta-1);
  cursor: pointer;
  flex-shrink: 0;
}

.filter-subgroup {
  margin-top: 0.3rem;
  margin-bottom: 0.6rem;
}

.filter-subgroup__label {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--color-ink-soft);
  margin: 0.5rem 0 0.2rem;
}

.price-range {
  position: relative;
  height: 34px;
  margin-top: var(--space-xs);
}

.price-range input[type="range"] {
  position: absolute;
  width: 100%;
  top: 12px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: none;
  pointer-events: none;
}

.price-range input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  pointer-events: auto;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-magenta-1);
  border: 3px solid var(--color-white);
  box-shadow: 0 1px 4px rgba(43, 15, 73, 0.35);
  cursor: pointer;
  margin-top: -10px;
}

.price-range input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-magenta-1);
  border: 3px solid var(--color-white);
  cursor: pointer;
}

.price-range input[type="range"]::-webkit-slider-runnable-track {
  height: 3px;
  background: transparent;
}

.price-range__track {
  position: absolute;
  top: 15px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--color-grey-200);
  border-radius: 999px;
}

.price-range__fill {
  position: absolute;
  top: 15px;
  height: 3px;
  background: var(--gradient-brand);
  border-radius: 999px;
}

.price-range__values {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-violet-deep-1);
  margin-top: var(--space-xs);
}

.filters-reset {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-magenta-1);
}

.filters-reset:hover {
  text-decoration: underline;
}

.filters-toggle-mobile,
.filters-sidebar__close {
  display: none;
}

@media (max-width: 900px) {
  .shop-layout {
    grid-template-columns: 1fr;
  }

  .filters-toggle-mobile {
    display: inline-flex;
    margin-bottom: var(--space-sm);
  }

  .filters-sidebar__close {
    display: flex;
  }

  .filters-sidebar {
    position: fixed;
    inset: 0 15% 0 0;
    z-index: 300;
    border-radius: 0;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform var(--duration-section) var(--ease-standard);
  }

  .filters-sidebar.is-open {
    transform: translateX(0);
  }
}

/* ---- Message état vide ---- */
.shop-empty {
  text-align: center;
  padding: var(--space-2xl) var(--space-md);
  color: var(--color-ink-soft);
}

/* ---- Pagination / Charger plus ---- */
.load-more {
  display: flex;
  justify-content: center;
  margin-top: var(--space-lg);
}

/* Cartes produit « style place de marché » (inspiré d'Alibaba) : photo carrée en tête, nom sur 2 lignes, prix en gras,
   « En stock » discret, petit bouton rond « panier » en bas à droite. Pas de catégorie ni de gros bouton. */
.product-card { border: 1px solid var(--color-grey-200); border-radius: 10px; box-shadow: none; background: #fff; }
.product-card:hover, .product-card:focus-within { transform: none; box-shadow: 0 6px 18px rgba(15, 30, 80, 0.12); border-color: var(--color-grey-300); }
.product-card__media { aspect-ratio: 1 / 1; background: #f5f5f5; }
.product-card:hover .product-card__media-img, .product-card:focus-within .product-card__media-img { transform: none; }
.product-card__body { gap: 0.2rem; padding: 0.6rem 0.7rem 0.75rem; position: static; }
.product-card__category { display: none; }
.product-card__name {
  font-size: 0.88rem; font-weight: 500; line-height: 1.3; color: #222;
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: calc(2 * 1.3em);
}
.product-card__price-row { padding-right: 2.6rem; margin-top: 0.15rem; }
.product-card__price { font-family: var(--font-body); font-size: 1.2rem; font-weight: 800; color: #111; }
.product-card__price-old { font-size: 0.78rem; }
.product-card__stock { display: block; padding-right: 2.6rem; font-size: 0.74rem; color: #777; }
.product-card__add {
  position: absolute; right: 0.6rem; bottom: 0.6rem; margin: 0; width: 34px; height: 34px; min-width: 0; padding: 0;
  border-radius: 50%; font-size: 0; line-height: 0; overflow: hidden;
  background-color: var(--color-orange-primary); background-repeat: no-repeat; background-position: center; background-size: 18px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='9' cy='20' r='1.4'/><circle cx='18' cy='20' r='1.4'/><path d='M2 3h3l2.7 12.4a2 2 0 0 0 2 1.6h8.1a2 2 0 0 0 2-1.5L21.5 8H6'/></svg>");
}
.product-card__add.is-added { background-color: #1e8449; }
.product-card__add[disabled] { background-image: none; background-color: var(--color-grey-300); }
@media (min-width: 721px) {
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
}
/* Mobile : la bulle « Votre panier est ici » reçoit un `top` en ligne (JS) ET `bottom` (mobile.css) → elle s'étirait sur tout l'écran. */
@media (max-width: 720px) {
  .cart-hint { top: auto !important; height: auto !important; }
  .cart-hint::before { display: none; }
}
@media (max-width: 720px) {
  .product-card__price { font-size: 1rem; white-space: nowrap; }
  .product-card__price-row, .product-card__stock { padding-right: 0; }
  .product-card__stock { padding-right: 2.4rem; }
}

/* Cartes encore plus courtes : nom sur UNE ligne (les noms longs sont coupés par « … », le nom complet est sur la fiche),
   « En stock » masqué (seuls « Rupture » et « Précommande » restent visibles), corps resserré. */
.product-card__body { padding: 0.5rem 0.65rem 0.6rem; gap: 0.1rem; }
.product-card__name { -webkit-line-clamp: 1; line-clamp: 1; min-height: 0; font-size: 0.86rem; line-height: 1.35; }
.product-card__stock:not(.product-card__stock--out):not(.product-card__stock--preorder) { display: none; }
.product-card__price-row { margin-top: 0; padding-right: 2.4rem; }
.product-card__add { bottom: 0.45rem; width: 32px; height: 32px; }
