/* ----- Sección de Productos ----- */
.productos-menu {
  text-align: center;
  padding: 3rem 1rem;
}

.productos-menu h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #333;
}

.grid-productos {
  display: grid;
  grid-template-columns: repeat(5, 1fr); /* Escritorio: 5 columnas */
  gap: 15px;

  /* Nuevo: limitar ancho a 80% y centrar */
  width: 60%;
  margin: 0 auto;
}

.producto:hover {
  transform: scale(1.05);
}




.producto {
  position: relative; /* necesario para posicionar el overlay dentro */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  transition: transform 0.3s ease;
  cursor: pointer;
}

.producto img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}




.overlay {
  position: absolute;
  top: 0;      /* cubrir desde arriba */
  left: 0;
  width: 100%;
  height: 100%; /* cubrir toda la imagen */
  background: rgba(0, 0, 0, 0.5); 
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none; /* permite que el clic atraviese el overlay */
}

.producto:hover .overlay {
  opacity: 1;   
}




/* ----- Responsividad ----- */
@media (max-width: 1024px) {
  .grid-productos {
    grid-template-columns: repeat(3, 1fr);
    width: 90%; /* un poco más ancho en tablet */
  }
}

@media (max-width: 600px) {
  .grid-productos {
    grid-template-columns: repeat(2, 1fr);
    width: 95%; /* casi toda la pantalla en móvil */
  }

  .producto img {
    height: 150px;
  }
}
