/* ========== Root Variables (Mobile-first) ========== */
:root {
  --card-gap: 8px;
  --border-color: #e0e0e0;
}

/* ========== Product Card Grid Layout ========== */
.product-card-grid,
.product-listing-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* Mobile: 2 per row */
  gap: var(--card-gap);
  padding: 8px;
  justify-content: center;
  align-items: flex-start;
}

/* ========== Product Card ========== */
.product-card {
  background: #fff;
  width: 100%;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
  font-family: sans-serif;
  position: relative;
}

/* ========== Image Container ========== */
.product-card-image-container {
  width: 100%;
  aspect-ratio: 3/4;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f8f8f8;
}

.product-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ========== Product Info ========== */
.product-card-info {
  padding: 6px 8px;
  font-size: 13px;
}

.product-card-info .product-title {
  font-weight: 500;
  color: #222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-card-info .product-price {
  margin-top: 4px;
  font-weight: bold;
  color: #2e7d32;
}

.product-card-info .product-discount {
  font-size: 12px;
  color: #ff5722;
  margin-left: 6px;
}

.product-card-info .product-rating {
  margin-top: 4px;
  font-size: 12px;
  color: #666;
}

/* ========== Wishlist Button (No Background on Mobile) ========== */
.product-card .wishlist-button,
.product-card .wishlist-icon,
.product-card .wishlist-heart {
  position: absolute;
  top: 6px;
  right: 6px;
  background: transparent !important;  /* Removed background */
  box-shadow: none !important;         /* Removed box shadow */
  padding: 0 !important;
  width: auto !important;
  height: auto !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  z-index: 5;
  cursor: pointer;
}

/* ========== Tablet View (≥600px) ========== */
@media (min-width: 600px) {
  .product-card-grid,
  .product-listing-container {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 10px;
  }

  .product-card-info {
    font-size: 14px;
  }
}

/* ========== Desktop View (≥768px) ========== */
@media (min-width: 768px) {
  .product-card-grid,
  .product-listing-container {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    padding: 12px;
  }

  .product-card-info {
    font-size: 15px;
  }

  .product-card .wishlist-button {
    font-size: 18px;
  }
}
