/* ── Product Card Grid Component ──
   Neobrutalist product cards for browse/discovery grids.
   Design spec: design-system/docs/product-grid-mockup.html
   ── */

.product-section {
  padding: 48px 0;
}

/* Section Header */
.product-section .section-header {
  text-align: center;
  margin-bottom: 32px;
  /* Reset conflicting .section-header from style.css */
  font-family: inherit;
  font-size: inherit;
  text-transform: none;
  letter-spacing: normal;
}

.product-section .section-badge {
  display: inline-block;
  background: #ffe156;
  color: #1a1a1a;
  font-family: 'Bangers', cursive;
  font-size: 12px;
  letter-spacing: 0.1em;
  padding: 6px 16px;
  border: 2px solid #1a1a1a;
  border-radius: 100px;
  margin-bottom: 12px;
}

.product-section .section-title {
  font-family: 'Bangers', cursive;
  font-size: 32px;
  letter-spacing: 0.02em;
  color: var(--text, #1a1a1a);
  margin: 0;
}

/* Grid Layout */
.products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-width: 800px;
  margin: 0 auto;
}

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

/* Product Card */
.products-grid .product-card {
  background: #fefefe;
  border: 3px solid #1a1a1a;
  border-radius: 12px;
  box-shadow: 4px 4px 0 #1a1a1a;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  /* Reset any conflicting .product-card from style.css */
  margin: 0;
  padding: 0;
}

.products-grid .product-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 #1a1a1a;
}

.products-grid .product-card a {
  text-decoration: none;
  color: inherit;
  display: block;
}

/* Card Image */
.product-card-img {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #f5f5f5;
  border-bottom: 3px solid #1a1a1a;
  overflow: hidden;
}

.product-card-img picture {
  display: block;
  width: 100%;
  height: 100%;
}

.product-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Match Badge */
.match-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #2ed573;
  color: #fff;
  font-family: 'Bangers', cursive;
  font-size: 11px;
  padding: 4px 8px;
  border: 2px solid #1a1a1a;
  border-radius: 6px;
}

/* Card Body */
.product-card-body {
  padding: 12px;
}

.product-card-name {
  font-family: 'Bangers', cursive;
  font-size: 14px;
  letter-spacing: 0.02em;
  line-height: 1.2;
  margin: 0 0 4px;
  color: #1a1a1a;

  /* Clamp to 2 lines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card-dupes {
  font-size: 11px;
  color: var(--text-secondary, #888);
  margin-bottom: 8px;
}

.product-card-dupes span {
  font-weight: 600;
}

/* Price Row */
.product-card-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
}

.product-card-price .price-original {
  font-size: 12px;
  color: var(--text-muted, #aaa);
  text-decoration: line-through;
}

.product-card-price .price-sale {
  font-family: 'Bangers', cursive;
  font-size: 18px;
  color: #1a1a1a;
}

.price-save {
  font-size: 10px;
  font-weight: 600;
  color: #fff;
  background: #ff4757;
  padding: 2px 6px;
  border-radius: 4px;
}

/* ── Responsive ── */

@media (max-width: 599px) {
  .product-section .section-title {
    font-size: 26px;
  }

  .product-card-name {
    font-size: 13px;
  }

  .product-card-price .price-sale {
    font-size: 16px;
  }
}
