/* ====== ESTILOS DE LAS CARDS ====== */
.product-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
  text-align: center;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.product-card:hover {
  transform: scale(1.03);
}

/* ===== CONTENEDOR DE IMÁGENES ===== */
.image-container {
  position: relative;
  min-height: 220px;
  width: 100%;
  overflow: hidden;
}

/* ambas imágenes superpuestas */
.image-container img {
  position: absolute;            /* 🔑 CLAVE */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

/* imagen principal */
.main-img {
  opacity: 1;
  z-index: 1;
}

/* imagen secundaria */
.hover-img {
  opacity: 0;
  z-index: 2;
}

/* efecto swap */
.product-card.has-hover:hover .main-img {
  opacity: 0;
}

.product-card.has-hover:hover .hover-img {
  opacity: 1;
}

/* leve zoom */
.product-card:hover .image-container img {
  transform: scale(1.05);
}

/* ===== OVERLAY ===== */
.overlay {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(0,0,0,0.6);
  color: white;
  padding: 8px;
  font-weight: bold;
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 3;
}

.product-card:hover .overlay {
  opacity: 1;
}

/* ===== NOMBRE ===== */
.product-card h5 {
  margin-top: 10px;
  font-size: 16px;
  font-weight: 600;
  color: #333;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

/* ====== RESPONSIVE ====== */
@media (max-width: 768px) {
  .image-container {
    min-height: 180px;
  }
  .product-card h5 {
    font-size: 14px;
  }
}

@media (max-width: 576px) {
  .image-container {
    min-height: 150px;
  }
  .product-card h5 {
    font-size: 13px;
  }
}
/* Quitar azul y subrayado */
.producto-link {
  text-decoration: none;
  color: inherit;
}

.producto-link:hover {
  text-decoration: none;
  color: inherit;
}
.paginacion {
  text-align: center;
  margin-top: 20px;
}

.btn-pagina {
  display: inline-block;
  padding: 8px 14px;
  margin: 4px;
  border-radius: 6px;
  background: #f1f1f1;
  color: #333;
  text-decoration: none;
  font-weight: 600;
  transition: 0.2s;
}

.btn-pagina:hover {
  background: #ddd;
}

.btn-pagina.activa {
  background: #000;
  color: #fff;
}
