.product-carousel {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  padding: 60px;
  position: relative;
  overflow: hidden;
}

/* Section header */
.section-intro {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  margin-bottom: 40px;
}

.section-intro-left,
.section-intro-right {
  flex: 1;
}

.section-intro-left {
  text-align: left;
}

.section-intro-right {
  text-align: right;
}

.section-intro h2 {
  font-size: 2rem;
}

.view-all {
  display: block;
  text-align: right;
  color: var(--secondary-color, #482b06);
  font-size: 1rem;
  text-decoration: none;
}

.view-all:hover {
  color: var(--secondary-color, #005a8c);
  text-decoration: underline;
}

/* Carousel core */
.carousel-wrapper {
  width: 100%;
  position: relative;
}

.carousel-track {
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  touch-action: pan-x;
  cursor: grab;

  /* ✅ scroll-snap hoort op de SCROLLCONTAINER */
  scroll-snap-type: x mandatory;

  /* ✅ compenseer de gap aan het eind, geen kunstmatige spacer nodig */
  scroll-padding-right: 20px;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-track.dragging {
  cursor: grabbing;
  user-select: none;
}

.product-items {
  display: flex;
  gap: 20px;
  padding-bottom: 10px;
  width: 100%;
  /* ❌ verwijderd: scroll-snap-type stond hier eerder fout */
}

/* ❌ verwijderd: extra spacer veroorzaakte witruimte voorbij laatste item */
/* .product-items::after { content: ''; flex: 0 0 20px; } */

/* Product item styling */
.product-item {
  width: 250px;
  flex: 0 0 auto;
  scroll-snap-align: start;
  text-align: left;
  user-select: none;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.product-item img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 15px;
}

.product-item h3 {
  font-size: 1.25rem;
  font-weight: bold;
  margin-bottom: 10px;
}

.product-item .label,
.product-item .short-description {
  font-size: 0.875rem;
  margin-bottom: 10px;
  color: #666;
}

.product-item .label {
  font-weight: 600;
}

.product-item .price {
  font-size: 1rem;
  color: #333;
  margin-bottom: 10px;
}

/* Link behavior */
.product-link-full {
  display: block;
  color: inherit;
  text-decoration: none;
}

.product-link-full:hover {
  text-decoration: underline;
}

/* Carousel navigation arrows */
.carousel-arrow {
  position: absolute;
  top: 50%;
  z-index: 10;
  height: 50px;
  width: 50px;
  margin: 0 60px;
  background-color: var(--primary-color, #f4b32d);
  color: var(--secondary-color, #ffffff);
  border-radius: 50%;
  cursor: pointer;
  transform: translateY(-50%);
}

.carousel-arrow-prev {
  left: 0;
}

.carousel-arrow-next {
  right: 0;
}

.carousel-arrow i {
  font-size: 1.5rem;
}

/* Prevent inner elements from intercepting drag */
.product-item img,
.product-item h3,
.product-item p {
  pointer-events: none;
}

/* Responsive */
@media (max-width: 768px) {
  .product-carousel {
    padding: 10px;
  }

  .section-intro {
    flex-direction: row;
    padding: 20px;
  }

  .section-intro-left {
    margin-left: 20px;
  }

  .section-intro-right {
    margin-right: 20px;
  }

  .section-intro-left,
  .section-intro-right {
    text-align: left;
    white-space: nowrap;
  }

  .section-intro h2 {
    font-size: 28px;
  }

  .view-all {
    font-size: 1rem;
  }

  .carousel-arrow {
    height: 32px;
    width: 32px;
    margin: 0 20px;
  }

  .product-items {
    gap: 10px;
  }

  .carousel-track {
    /* match de kleinere gap aan het eind */
    scroll-padding-right: 10px;
  }

  .product-item {
    width: 100%;
  }
}

@media (min-width: 768px) {
  .product-item {
    width: 22%;
  }
}