/* ===== Product grid ===== */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
}
@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
}
@media (min-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
  }
}

.product-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  text-decoration: none;
  color: inherit;
}

.product-card-imgwrap {
  position: relative;
  aspect-ratio: 3 / 4;
  background: var(--bg-soft);
  overflow: hidden;
}
.product-card-img {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--text-quiet);
  letter-spacing: 0.1em;
  background:
    linear-gradient(135deg, #f0f0f0 25%, transparent 25%),
    linear-gradient(225deg, #f0f0f0 25%, transparent 25%),
    linear-gradient(45deg, #f0f0f0 25%, transparent 25%),
    linear-gradient(315deg, #f0f0f0 25%, #f6f6f6 25%);
  background-size: 14px 14px;
  background-position: 7px 0, 7px 0, 0 0, 0 0;
  user-select: none;
}
.product-card-img-real {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* "+" agora é direct child de .product-card (depois de imgwrap, antes de info).
   Pra manter visual de overlay na bottom-right da imagem, usamos align-self
   + margin-top negativo que puxa o botão pra dentro da área da imagem. */
.product-add-btn {
  align-self: flex-end;
  margin-right: 8px;
  margin-top: -34px;
  margin-bottom: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--text);
  font-weight: 300;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  transition: transform var(--t-fast), background var(--t-fast);
  line-height: 1;
  position: relative;   /* fica acima de imgwrap mesmo com margin negativo */
  z-index: 2;
}
.product-add-btn:hover {
  background: #fff;
  transform: scale(1.08);
}
.product-add-btn:active { transform: scale(0.95); }

@media (min-width: 1024px) {
  .product-add-btn {
    width: 30px;
    height: 30px;
    margin-right: 10px;
    margin-top: -38px;
  }
}

.product-card-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
  padding: 0 4px;
}
.product-card-name {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text);
  line-height: 1.3;
}
@media (min-width: 1024px) {
  .product-card-name { font-size: 14px; }
}
.product-card-price {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-top: 2px;
}
.product-card-swatches {
  display: flex;
  gap: 4px;
  margin-top: 4px;
}
.product-swatch {
  width: 12px;
  height: 12px;
  border-radius: 2px;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: transform var(--t-fast);
}
.product-swatch:hover { transform: scale(1.15); }
