/* Categorie: filterpaneel volgens het Figma-ontwerp (Categorie, node 2:726),
   plus de voorraadregel, de categoriebeschrijving en de prijs op de kaart. */

/* Eén filterpaneel. De kolom links (#brxe-dvogzn) is het paneel uit het ontwerp;
   de Bricks-filters erin (tweede prijsslider en een kleurenfilter) staan uit en
   het paneel van category-tools vult de kolom. Het oude paneel in de
   inhoudskolom (#brxe-wmscat) doet niet meer mee. */
body.woocommerce #brxe-hnypap,
body.woocommerce #brxe-nhhdws,
body.woocommerce #brxe-iicjgi,
body.woocommerce #brxe-ieazno,
body.woocommerce #brxe-wmscat {
  display: none !important;
}

/* De telling hoort in het paneel, niet als losse regel boven het grid. */
body.woocommerce .wms-cat-voorraad {
  display: none;
}

/* ---------------- paneel ---------------- */

.wms-cat-filters {
  width: 100%;
  font-size: 15px;
  color: #111827;
}

.wms-cat-filters__kop {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
  margin: 0 0 12px;
}

.wms-cat-filters__lijn {
  height: 1px;
  background: #e5e7eb;
  margin: 0 0 16px;
}

/* ---------------- prijs ---------------- */

.wms-prijs {
  margin: 0 0 4px;
}

.wms-prijs__label {
  font-size: 13px;
  font-weight: 500;
  color: #374151;
  margin: 0 0 18px;
}

.wms-prijs__slider {
  position: relative;
  height: 24px;
  margin: 0 0 14px;
}

.wms-prijs__track,
.wms-prijs__fill {
  position: absolute;
  top: 11px;
  height: 2px;
  border-radius: 2px;
}

.wms-prijs__track {
  left: 0;
  right: 0;
  background: #e5e7eb;
}

.wms-prijs__fill {
  background: #0f172a;
}

.wms-prijs__slider input[type="range"] {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 24px;
  margin: 0;
  background: none;
  -webkit-appearance: none;
  appearance: none;
  pointer-events: none;
}

.wms-prijs__slider input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  pointer-events: auto;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #d1d5db;
  box-shadow: 0 1px 3px rgba(15, 23, 42, .18);
  cursor: pointer;
}

.wms-prijs__slider input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #d1d5db;
  box-shadow: 0 1px 3px rgba(15, 23, 42, .18);
  cursor: pointer;
}

.wms-prijs__slider input[type="range"]::-webkit-slider-runnable-track {
  background: none;
  height: 24px;
}

.wms-prijs__slider input[type="range"]::-moz-range-track {
  background: none;
  height: 24px;
}

.wms-prijs__velden {
  display: flex;
  align-items: center;
  gap: 8px;
}

.wms-prijs__velden::before {
  content: "-";
  order: 1;
  color: #9ca3af;
  font-size: 14px;
}

.wms-prijs__veld {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  background: #f3f4f6;
  border-radius: 6px;
}

.wms-prijs__veld:first-of-type {
  order: 0;
}

.wms-prijs__veld:last-of-type {
  order: 2;
}

.wms-prijs__veldlabel {
  font-size: 11px;
  color: #6b7280;
  line-height: 1.2;
}

.wms-prijs__veldwaarde {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
  line-height: 1.3;
}

.wms-prijs__knop {
  width: 100%;
  height: 40px;
  margin-top: 12px;
  border: 0;
  border-radius: 8px;
  background: #0f172a;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

/* ---------------- kenmerken als accordeon ---------------- */

.wms-filtergroep {
  border-top: 1px solid #e5e7eb;
  padding: 0;
}

.wms-filtergroep__kop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  font-size: 16px;
  font-weight: 600;
  color: #111827;
  cursor: pointer;
  list-style: none;
}

.wms-filtergroep__kop::-webkit-details-marker {
  display: none;
}

.wms-filtergroep__pijl {
  width: 9px;
  height: 9px;
  border-right: 2px solid #6b7280;
  border-bottom: 2px solid #6b7280;
  transform: rotate(45deg);
  transition: transform .15s ease;
}

.wms-filtergroep[open] .wms-filtergroep__pijl {
  transform: rotate(-135deg);
}

.wms-filtergroep__lijst {
  list-style: none;
  margin: 0;
  padding: 0 0 14px;
}

.wms-filtergroep__lijst li {
  margin: 0 0 10px;
}

.wms-filteroptie {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #374151;
  font-size: 14px;
  text-decoration: none;
}

.wms-filteroptie__box {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  border: 1px solid #d1d5db;
  border-radius: 50%;
  background: #fff;
}

.wms-filteroptie__naam {
  flex: 1 1 auto;
}

.wms-filteroptie__aantal {
  color: #9ca3af;
  font-variant-numeric: tabular-nums;
}

.wms-filteroptie:hover .wms-filteroptie__box {
  border-color: #0f172a;
}

.wms-filteroptie.is-aan .wms-filteroptie__box {
  border-color: #0f172a;
  background: #0f172a;
  box-shadow: inset 0 0 0 3px #fff;
}

.wms-filteroptie.is-aan .wms-filteroptie__naam {
  font-weight: 600;
  color: #111827;
}

/* ---------------- voorraadschakelaar ---------------- */

.wms-voorraadschakelaar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0 0;
  text-decoration: none;
  color: #374151;
  font-size: 13px;
  line-height: 1.35;
}

.wms-voorraadschakelaar__switch {
  flex: 0 0 auto;
  position: relative;
  width: 36px;
  height: 24px;
  border-radius: 999px;
  background: #e5e7eb;
  transition: background .15s ease;
}

.wms-voorraadschakelaar__switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .25);
  transition: left .15s ease;
}

.wms-voorraadschakelaar.is-aan .wms-voorraadschakelaar__switch {
  background: #16a34a;
}

.wms-voorraadschakelaar.is-aan .wms-voorraadschakelaar__switch::after {
  left: 15px;
}

.wms-cat-filters__reset {
  display: inline-block;
  margin-top: 12px;
  font-size: 13px;
  color: #6b7280;
  text-decoration: underline;
}

/* ---------------- voorraadregel boven het grid ---------------- */

.wms-cat-voorraad {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #15803d;
  margin: 0 0 12px;
}

.wms-cat-voorraad span {
  color: #6b7280;
}

.wms-cat-voorraad__stip {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #15803d;
  display: inline-block;
}

/* ---------------- categoriebeschrijving ---------------- */

.wms-cat-beschrijving {
  margin: 32px 0 0;
  font-size: 15px;
  color: #374151;
}

.wms-cat-beschrijving__tekst {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.wms-cat-beschrijving.is-open .wms-cat-beschrijving__tekst {
  -webkit-line-clamp: unset;
  display: block;
}

.wms-cat-beschrijving__knop {
  margin-top: 8px;
  padding: 0;
  border: 0;
  background: none;
  color: #111827;
  font-size: 15px;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

.wms-cat-beschrijving.is-open .wms-cat-beschrijving__knop {
  display: none;
}

/* ---------------- prijs op de productkaart ---------------- */

.wms-kaart-prijs {
  margin: 6px 0 0;
}

.wms-kaart-prijs .price,
.wms-kaart-prijs .woocommerce-Price-amount {
  font-size: 16px;
  font-weight: 600;
  color: #111827;
  text-decoration: none;
}

.wms-kaart-prijs del {
  font-size: 14px;
  font-weight: 400;
  color: #9ca3af;
  margin-right: 6px;
}

.wms-kaart-prijs ins {
  text-decoration: none;
}

/* Op mobiel en tablet staat het paneel gewoon boven het grid; de Bricks-drawer
   met zijn "Filters"-knop is niet meer nodig en was na het uitzetten van de
   Bricks-filters leeg. */
@media (max-width: 991px) {
  body.woocommerce #brxe-wqjgik {
    display: block !important;
    position: static !important;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    transform: none !important;
    background: none !important;
    padding: 0 !important;
  }

  body.woocommerce #brxe-gtwstc,
  body.woocommerce #brxe-agnblc {
    display: none !important;
  }

  body.woocommerce #brxe-dvogzn {
    width: 100% !important;
    margin: 0 0 24px;
  }

  .wms-prijs__slider {
    margin-bottom: 16px;
  }
}

/* Het paneel is een <details>: op desktop altijd open met de titel als kop, op
   mobiel dichtgeklapt zodat het een compacte Filters-balk is. */
.wms-cat-filters > summary.wms-cat-filters__kop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  list-style: none;
  cursor: default;
}

.wms-cat-filters > summary.wms-cat-filters__kop::-webkit-details-marker {
  display: none;
}

.wms-cat-filters > summary.wms-cat-filters__kop::after {
  content: "";
  display: none;
  width: 9px;
  height: 9px;
  border-right: 2px solid #6b7280;
  border-bottom: 2px solid #6b7280;
  transform: rotate(45deg);
}

@media (max-width: 991px) {
  .wms-cat-filters > summary.wms-cat-filters__kop {
    cursor: pointer;
    margin-bottom: 0;
  }

  .wms-cat-filters > summary.wms-cat-filters__kop::after {
    display: block;
  }

  .wms-cat-filters[open] > summary.wms-cat-filters__kop {
    margin-bottom: 12px;
  }

  .wms-cat-filters[open] > summary.wms-cat-filters__kop::after {
    transform: rotate(-135deg);
  }
}
