/*
Theme Name: hellochild
Author: vahatra
Template: hello-elementor
Version: 1.0.0
*/

/* ====== Grille style maçonnerie ====== */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* 4 colonnes sur PC */
  gap: 20px;
  align-items: start;
}

/* ====== Responsive : 2 colonnes sur mobile ====== */
@media (max-width: 768px) {
  .woocommerce ul.products {
    grid-template-columns: repeat(2, 1fr); /* 2 colonnes sur mobile */
  }
}

/* ====== Bloc catégorie ====== */
.woocommerce ul.products li.product-category {
  position: relative;
border-radius: 0 30px 30px 30px;
  overflow: hidden;
  background: #f9f9f9;
}

/* ====== Image de la catégorie ====== */
.woocommerce ul.products li.product-category img {
  width: 100%;
  height: auto;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}

/* Zoom 8% sur l'image uniquement */
.woocommerce ul.products li.product-category:hover img {
  transform: scale(1.08);
}

/* ====== Nom de la catégorie ====== */
.woocommerce ul.products li.product-category .woocommerce-loop-category__title {
  position: absolute;
  bottom: 15px;
  left: 15px;
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  text-transform: uppercase;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  margin: 0;
  z-index: 2;
}

/* ====== Overlay léger pour lisibilité ====== */
.woocommerce ul.products li.product-category::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 60%, rgba(0, 0, 0, 0.35) 100%);
  transition: opacity 0.3s ease;
  opacity: 1;
  z-index: 1;
}

.woocommerce ul.products li.product-category:hover::after {
  opacity: 0.9;
}

/* ====== Lien cliquable ====== */
.woocommerce ul.products li.product-category a {
  display: block;
  line-height: 0;
}
