/*
 * Dual-thumb price range slider (products filter).
 * Two native <input type="range"> elements are stacked on top of a
 * shared track; each input is transparent and only its thumb is
 * interactive (pointer-events), which is what makes both handles
 * independently draggable without a JS-built slider widget.
 */

.price-range-slider {
  position: relative;
  height: 4px;
}

.price-range-track {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  border-radius: 9999px;
  background: #ECE6DF;
}

.price-range-fill {
  position: absolute;
  top: 0;
  height: 4px;
  border-radius: 9999px;
  background: var(--color-primary);
}

.price-range-slider input[type="range"] {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 4px;
  margin: 0;
  transform: translateY(-50%);
  background: transparent;
  pointer-events: none;
  -webkit-appearance: none;
  appearance: none;
}

.price-range-slider input[type="range"]::-webkit-slider-runnable-track {
  -webkit-appearance: none;
  height: 4px;
  background: transparent;
}

.price-range-slider input[type="range"]::-moz-range-track {
  height: 4px;
  background: transparent;
  border: none;
}

.price-range-slider input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--color-primary);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--color-primary);
  cursor: pointer;
  margin-top: -6px;
}

.price-range-slider input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--color-primary);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--color-primary);
  cursor: pointer;
}

/*
 * The min/max price number inputs (#priceMinInput / #priceMaxInput)
 * don't need the browser's built-in up/down stepper — typing or the
 * range thumbs below already cover that, and the stepper just adds
 * visual clutter to the filter.
 */
#priceMinInput,
#priceMaxInput {
  -moz-appearance: textfield;
  appearance: textfield;
}

#priceMinInput::-webkit-outer-spin-button,
#priceMinInput::-webkit-inner-spin-button,
#priceMaxInput::-webkit-outer-spin-button,
#priceMaxInput::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
