* {
  box-sizing: border-box;
}

body {
  font-family: "Open Sans", Verdana, sans-serif;
  background: linear-gradient(to right, #f6d1b8 55%, #d99b77 106%);
  margin: 0;
}

main {
  padding: 32px;
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* 5 cards per row */
  gap: 20px;
}
/* Responsive */

@media (max-width: 1024px) {
  main {
    grid-template-columns: repeat(3, 1fr); /* Tablet 3 per row */
  }
}

@media (max-width: 768px) {
  main {
    grid-template-columns: 1fr; /* Mobile 1 per row */
  }
}

.card {
  border-radius: 12px;
  width: 100%;
  min-height: 300px; /* smaller height */
  box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.15);
  overflow: hidden;

  transition: transform 0.3s ease;
}

.card:hover {
  transform: scale(1.03);
}

.info {
  background-color: #ffeeeb;
  padding: 12px 14px 14px; /* less padding */
}

.title {
  margin: 0;
  font-size: 16px; /* smaller title */
  font-weight: bold;
  color: rgba(0, 0, 0, 0.87);
}

.description {
  margin: 6px 0;
  font-size: 13px;
  line-height: 1.3;
  color: #555;
}

.price {
  margin: 8px 0;
  font-size: 15px;
  font-weight: bold;
  color: #1c5b72;
}

/* Image button instead of normal button */
.btn-img {
  display: block;
  margin: 8px 0;
  cursor: pointer;
  width: 90px; /* smaller */
  transition: transform 0.3s ease;
}

.btn-img:hover {
  transform: scale(1.1);
}

/* Popup Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: #fff;
  padding: 15px;
  border-radius: 12px;
  max-width: 500px;
  width: 90%;
  text-align: center;
  position: relative;
}

.modal-content img {
  max-width: 100%;
  border-radius: 6px;
  margin-bottom: 8px;
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
}
.product-img {
  width: 100%;
  height: 200px;
  object-fit: cover; /* crop nicely */
  display: block;
}

a.my-btn,
a.my-btn:visited {
  background: linear-gradient(to right, #f6d1b8 55%, #d99b77 106%);
  display: inline-block;

  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #000000; /* <-- stays white even after visited */
  text-decoration: none; /* <-- removes underline */
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  width: 150px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

a.my-btn:hover {
  opacity: 0.9;
}
