/* Layout grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px;
  padding: 15px;
  justify-content: center;
}

/* Card styling */
.product-card {
  width: 260px;
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.product-card img {
  width: 100%;              /* Fill the card width */
  height: 200px;            /* Fixed height */
  object-fit: cover;        /* Crop to fill space while maintaining aspect ratio */
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  display: block;
   padding-bottom: 12px;
}


.card-body {
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;    /* Reduced from 10px to tighten layout */
}

.card-body h3 {
  font-size: 18px;
  margin:0;
  color: #222;
  font-weight: bold;
  padding: 2px 0;
}

.card-body .category {
  font-size: 14px;
  color: #3b82f6;
  margin:0;
  padding: 2px 0;
}

.card-body .desc {
  font-size: 14px;
  color: #555;
  height: 20px;
  overflow: hidden;
  margin:0;
  padding: 2px 0;
}

.card-body .price {
  font-size: 16px;
  color: #1a7f37;
  font-weight: bold;
  padding: 2px 0;
}

.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.product-card {
  cursor: pointer;
}
