/* Farb-Swatches auf der PDP (mainJsColorswatches/initColorSwatchSlider in
   sections/product.liquid): Slider-Mechanik (Maus-Drag, natives Touch-Wischen,
   Pfeile) nach Vorbild von "Color Swatch Slider.dc.html", Groessen/Farben/
   Radius bleiben im eigenen Fitjeans-Stil. */
.color-swatch-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 16px;
}
.color-swatch-header__label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(0, 0, 0, 0.5);
}
.color-swatch-header__value {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
}

.color-swatch-container-new {
  position: relative;
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  padding-top: 8px;
  padding-bottom: 8px;
  overflow-x: auto;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  touch-action: pan-x;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.color-swatch-container-new::-webkit-scrollbar {
  display: none;
}
.color-swatch-container-new.is-dragging {
  cursor: grabbing;
  scroll-snap-type: none;
}
.color-swatch-new {
  position: relative;
  width: calc((100% - 6 * 8px) / 7);
  flex: 0 0 calc((100% - 6 * 8px) / 7);
  padding: 3px;
  scroll-snap-align: center;
  /* Feste Hoehe unabhaengig von Bild-Attributen/Anzahl Varianten: die img-Tags
     liefern kein width/height, ohne aspect-ratio haengt die Box-Hoehe vom Bild
     ab, das wiederum height:100% der Box erwartet (Zirkelbezug). Bei wenigen
     Swatches (z.B. 2) kollabierte das sichtbar auf einen winzigen Streifen. */
  aspect-ratio: 2 / 3;
}
.color-swatch-new.active {
  border: 1px solid #000;
  border-radius: 8px;
}
.color-swatch-link-new {
  width: 100%;
  height: 100%;
  display: block;
}
img.color-swatch-img-new {
  height: 100%;
  width: 100%;
  border-radius: 6px;
}

/* Preis-Block bekommt einen Positionierungskontext, damit die Pfeile oben
   rechts auf Hoehe der Preiszeile sitzen, unabhaengig von der Textlaenge
   des Preises (siehe initColorSwatchSlider in product.liquid). */
.product_price_block {
  position: relative;
}
.color-swatch-slider-arrows {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  gap: 6px;
}
.color-swatch-arrow {
  width: 32px;
  height: 32px;
  flex: none;
  padding: 0;
  border-radius: 10px;
  border: 1px solid #000;
  background: #fff;
  color: #000;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, opacity 0.15s ease;
}
.color-swatch-arrow:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
@media (hover: hover) {
  .color-swatch-arrow:not(:disabled):hover {
    background: #f4f2ee;
  }
}

@media (max-width: 750px) {
  .color-swatch-container-new {
    gap: 6px;
  }
  .color-swatch-new {
    width: calc((100% - 4 * 6px) / 5);
    flex-basis: calc((100% - 4 * 6px) / 5);
  }
}

/* .price_shipping (siehe product.liquid, verschiebt Bloecke per JS dorthin)
   ist selbst ein Flex-Container. Andere Kinder haben dort eine explizite
   .product__block { width:100%; } Regel, unsere Elemente nicht - dadurch
   schrumpften sie auf Inhaltsgroesse statt volle Breite zu nehmen, sobald
   das Verschieben bei DOMContentLoaded passiert (daher "kurz richtig, dann
   komprimiert": vor dem Verschieben ist die Breite noch korrekt). */
.price_shipping .color-swatch-header,
.price_shipping .color-swatch-container-new {
  width: 100%;
}
