/* ── Product Card ─────────────────────────────────────────── */
.product-card {
  position: relative;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
  user-select: none;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 32px rgba(0,0,0,0.5);
}

/* Link wrapper */
.pc-link {
  display: block;
  text-decoration: none;
  color: inherit;
}
.pc-title-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

/* Image wrapper */
.pc-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #f0f0f0;
  flex-shrink: 0;
}

/* Product image slides — stacked, only active is visible */
.pc-img-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  z-index: 1;
  pointer-events: none;
}
.pc-img-slide.active {
  opacity: 1;
  z-index: 2;
  pointer-events: auto;
}
.product-card:hover .pc-img-slide.active { transform: scale(1.04); transition: transform 0.35s ease; }

/* Slide-in/out keyframes */
@keyframes pcInRight  { from { transform: translateX(100%); opacity: 1; } to { transform: translateX(0); opacity: 1; } }
@keyframes pcInLeft   { from { transform: translateX(-100%); opacity: 1; } to { transform: translateX(0); opacity: 1; } }
@keyframes pcOutLeft  { from { transform: translateX(0); opacity: 1; } to { transform: translateX(-100%); opacity: 0; } }
@keyframes pcOutRight { from { transform: translateX(0); opacity: 1; } to { transform: translateX(100%); opacity: 0; } }

.pc-img-slide.pc-in-right  { animation: pcInRight  0.42s cubic-bezier(0.25,0.46,0.45,0.94) forwards; }
.pc-img-slide.pc-in-left   { animation: pcInLeft   0.42s cubic-bezier(0.25,0.46,0.45,0.94) forwards; }
.pc-img-slide.pc-out-left  { animation: pcOutLeft  0.42s cubic-bezier(0.25,0.46,0.45,0.94) forwards; }
.pc-img-slide.pc-out-right { animation: pcOutRight 0.42s cubic-bezier(0.25,0.46,0.45,0.94) forwards; }


/* SAVE badge — top left, red pill */
.pc-save {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #e8192c;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 4px;
  letter-spacing: 0.05em;
  z-index: 3;
  pointer-events: none;
  line-height: 1;
}

/* Wishlist — top right, white circle */
.pc-wishlist {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  font-size: 15px;
  color: #333;
  transition: color 0.15s ease, background 0.15s ease;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  pointer-events: all;
}
.pc-wishlist:hover { color: #e8192c; background: #fff; }
.pc-wishlist.active { color: #e8192c; }

/* ADD TO CART — slides up from bottom on hover */
.pc-atc {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: #111;
  color: #fff;
  border: none;
  padding: 14px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transform: translateY(101%);
  transition: transform 0.25s ease;
  font-family: inherit;
  z-index: 4;
  text-align: center;
  pointer-events: none;
}
.product-card:hover .pc-atc {
  transform: translateY(0);
  pointer-events: all;
}

/* Info section below image */
.pc-info {
  padding: 10px 8px 12px;
  background: #fff;
  flex: 1;
}

/* Title */
.pc-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #111;
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

/* Prices */
.pc-prices {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.pc-compare {
  font-size: 12px;
  color: #999;
  text-decoration: line-through;
  font-weight: 400;
}
.pc-price {
  font-size: 13px;
  font-weight: 700;
  color: #111;
}

/* Touch devices — always show ATC */
@media (hover: none) {
  .pc-atc {
    transform: translateY(0);
    pointer-events: all;
  }
}

/* Slider cards width */
.products-slider-track .product-card {
  flex-shrink: 0;
  width: 240px;
  scroll-snap-align: start;
}
@media (min-width: 768px)  { .products-slider-track .product-card { width: 280px; } }
@media (min-width: 1024px) { .products-slider-track .product-card { width: 300px; } }

.products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (min-width: 768px) {
  .products-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
  .products-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ── Product card image slider arrows ─────────────────────────────────────── */
.pc-img-prev,
.pc-img-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: #111;
  cursor: pointer;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.2s ease, background 0.15s ease, transform 0.15s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
  pointer-events: all;
}
.pc-img-prev { left: 8px; }
.pc-img-next { right: 8px; }
.product-card:hover .pc-img-prev,
.product-card:hover .pc-img-next {
  opacity: 1;
}
.pc-img-prev:hover { background: #fff; transform: translateY(-50%) scale(1.1); }
.pc-img-next:hover { background: #fff; transform: translateY(-50%) scale(1.1); }

/* ── Image dots ────────────────────────────────────────────────────────────── */
.pc-img-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 5px;
  z-index: 5;
  pointer-events: none;
}
.pc-img-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.45);
  transition: background 0.2s, transform 0.2s;
}
.pc-img-dot.active {
  background: #fff;
  transform: scale(1.35);
}