.product-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

/* Product card/cell styles */
.product-cell {
  width: 325px;
  height: 375px;
  box-sizing: border-box;
  padding: 10px;
  text-align: center;
  border: 1px solid #E8D2D2;
  border-radius: 5px;
  overflow: hidden; /* Prevent image from spilling outside */
  position: relative;
}

.product-cell img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain; /* Keeps aspect ratio while fitting */
  display: block;
  margin: 0 auto;

}


/* Responsive: Stack vertically on small screens */
@media screen and (max-width: 768px) {
  .product-grid {
    flex-direction: column;
    align-items: center;
  }

  .product-cell {
    width: 90%; /* Full width but with some margin on sides */
    height: auto; /* Let it grow as per content */
  }
}



/* desktop media queries */

@media screen and (min-width: 1920px) {
  .product-cell {
    width: 242px;
    height: 242px;
  }
}

/* Laptop Media Queries    */

@media screen and (max-width: 1440px) {
  .product-cell {
    width: 230px;
  }
}

@media screen and (max-width: 1280px) {
  .product-cell {
    width: 220px;
  }
}

@media screen and (max-width: 1149px) {
  .product-cell {
    width: 210px;
  }
}

@media screen and (max-width: 1081px) {
  .product-cell {
    width: 200px;
  }
}

@media screen and (max-width: 1024px) {
  .product-cell {
    width: 190px;
  }
}

/* Tablet Media Queries */

@media screen and (max-width: 1024px) {
  .product-grid {
    flex-wrap: wrap;
    justify-content: center;
  }
  .product-cell {
    width: 45%;
    height: auto;
  }
}

@media screen and (max-width: 834px) {
  .product-cell {
    width: 48%;
    height: auto;
  }
}

/*  Mobile Phone Media Queries */

@media screen and (max-width: 768px) {
  .product-grid {
    flex-direction: column;
    align-items: center;
  }

  .product-cell {
    width: 90%;
    height: auto;
  }
}

@media screen and (max-width: 600px) {
  .product-cell {
    width: 95%;
  }
}

/* small phones */
@media screen and (max-width: 480px) {
  .product-cell {
    width: 95%;
  }
}

@media screen and (max-width: 375px) {
  .product-cell {
    width: 100%;
  }
}

@media screen and (max-width: 320px) {
  .product-cell {
    width: 100%;
    padding: 8px;
  }
}

