.products {
  background-color: #fff;
  padding: 4rem 2rem;
  text-align: center;
}

.products h2 {
  font-size: 2.5rem;
  color: #111;
  margin-bottom: 2rem;
}

#tables .product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  padding: 2 2rem;
  justify-items: center;
}

#tables .product-card {
  width: 100%;
  height: 35rem;
  max-width: 350px;
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  text-align: left;
  color: inherit;
  position: relative;
  background: linear-gradient(145deg, #fdfcfb, #f3f1ef, #e7e3df);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.05);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

#tables .product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

#tables .product-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  border-radius: 14px;
  transition: transform 0.5s ease;
}

#tables .product-card:hover img {
  transform: scale(1.05);
}

#tables .product-card h3 {
  font-size: 1.4rem;
  margin: 1rem 1rem 0.5rem;
  color: #111;
  font-weight: 600;
  letter-spacing: 0.5px;
}

#tables .product-card p {
  font-size: 0.95rem;
  color: #666;
  margin: 0 1rem 1rem;
  line-height: 1.5;
}

#tables .product-card span {
  display: block;
  font-weight: 600;
  color: #000;
  margin: 0 1rem 1.25rem;
  font-size: 1.1rem;
  border-top: 1px solid #eee;
  padding-top: 0.75rem;
}

#tables .product-card::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 4px;
  width: 0;
  background: linear-gradient(90deg, #111, #444);
  transition: width 0.4s ease;
}

#tables .product-card:hover::after {
  width: 100%;
}

#tables .product-card:link,
#tables .product-card:visited {
  text-decoration: none;
  color: inherit;
  display: block; 
}

#tables .product-card.dark {
  background: linear-gradient(145deg, #1e1e1e, #2c2c2c 40%, #444);
  color: #f5f5f5;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

#tables .product-card.dark h3,
#tables .product-card.dark p,
#tables .product-card.dark span {
  color: #f0f0f0;
}

#tables .product-card.dark span {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

#tables .product-card.dark::after {
  background: linear-gradient(90deg, #888, #ccc);
}

@media (max-width: 768px) {
  #tables .product-card {
    max-width: 100%;
  }
}