@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700;800&display=swap');

/* Pantalla de carga */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeOut 1.5s forwards;
  /* Se oculta en 3 segundos */
}

body {
  font-family: 'Poppins', sans-serif;
}


.container {
  max-width: 1200px;
  margin: 0 auto;
}

.header {
  min-height: 10vh;
  display: flex;
  align-items: center;
}

.menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 1000;
  backdrop-filter: blur(2px);
  /* opcional efecto difuminado */
  ;
}

.logo img {
  height: 60px;
  transition: transform 0.3s ease;
}

.menu .navbar ul li {
  position: relative;
  float: left;
}

.menu .navbar ul li a {
  font-size: 18px;
  padding: 20px;
  color: #6c8d43;
  display: block;
  font-weight: 600;
}

#menu {
  display: none;
}

.menu-icon {
  width: 50px;
  height: auto;
}


.menu label {
  cursor: pointer;
  display: none;
}

/* Estilo general del menú */
.navbar {
  display: flex;
  gap: 20px;
}

.navbar li {
  position: relative;
}

/* Link principal */
.navbar a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  padding: 10px 15px;
  display: block;
}

/* Pantallas chicas */
@media(max-width: 991px) {
  .menu label {
    display: block;
    /* El ícono del menú aparece */
  }

  .navbar {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    display: none;
    flex-direction: column;
  }

  #menu:checked~.navbar {
    display: flex;
    /* Muestra el menú al hacer click en el ícono */
  }

  .navbar ul {
    width: 100%;
    flex-direction: column;
  }

  .navbar li {
    width: 100%;
  }

  .navbar li a {
    padding: 15px;
    display: block;
    color: #6c8d43;
  }
}

/* Pantallas muy chicas (celulares pequeños) */
@media (max-width: 500px) {
  .producto {
    padding: 15px;
  }

  .producto h3 {
    font-size: 18px;
  }

  button {
    padding: 8px 16px;
    font-size: 13px;
  }
}


/* Estilo del desplegable oculto */
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  /* justo debajo del botón */
  left: 0;
  background: #ffffff;
  /* color de fondo */
  border: 1px solid #6c8d43;
  z-index: 1000;
  max-height: 250px;
  /* puedes ajustar según tu diseño */
  overflow-y: auto;
}


/* Poner las opciones en columna */
.dropdown-menu li {
  width: 100%;
}

.dropdown-menu li a {
  padding: 10px 15px;
  color: #fff;
  display: block;
  text-align: left;
}

.dropdown-menu li a:hover {
  background: #d7e2c9;
  color: #333;
}

/* Mostrar el menú al pasar mouse */
.dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-menu::-webkit-scrollbar {
  width: 8px;
}

.dropdown-menu::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

.dropdown-menu::-webkit-scrollbar-thumb:hover {
  background: #999;
}


.header-txt {
  text-align: justify;
}

.header-txt h1 {
  font-size: 2.8rem;
  /* tamaño de la fuente */
  line-height: 1.2;
  font-weight: 700;
  text-align: center;
  color: #6c8d43;
  margin-bottom: 1rem;
}

.header-txt p {
  font-size: 1.1rem;
  font-weight: 300;
  color: #ffffff;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 1.5rem;

}

.header-txt h2 {
  font-size: 20px;
  font-weight: 700;
  color: #86a75c;
  margin-bottom: 1rem;
  text-align: justify;
}

/* Logo con animación */
.preloader-logo {
  width: 150px;
  height: auto;
  animation: pulse 1.5s infinite;
}

/* Animación de "latido" */
@keyframes pulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }

  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Desaparecer pantalla */
@keyframes fadeOut {
  0% {
    opacity: 1;
    visibility: visible;
  }

  80% {
    opacity: 0.3;
  }

  100% {
    opacity: 0;
    visibility: hidden;
  }
}



* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  text-decoration: none;
  list-style: none;

}


body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #f9f9f9;
}

/* --- Catálogo adaptativo --- */
.catalogo {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  /* Modifica la cantidad de productos por fila */
  gap: 20px;
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Producto */
.producto {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 20px;
  text-align: center;
  transition: transform 0.2s;
}

.producto img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.producto:hover {
  transform: translateY(-5px);
}


.producto h3 {
  margin: 15px 0 10px;
  font-size: 20px;
  color: #555;
}


.producto p {
  margin: 5px 0;
  font-size: 14px;
  color: #555;
}


button {
  margin-top: 15px;
  padding: 10px 20px;
  background: #6c8d43;
  border: none;
  color: #fff;
  font-size: 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}


button:hover {
  background: #86a75c;
}



/* Footer */
footer {
  padding: 18px 0;
  text-align: center;
  border-top: 1px solid #eee;
  background: #fff;
  color: #6c8d43;
}


/* Responsive */
@media (max-width: 900px) {
  .producto-detalle {
    grid-template-columns: 1fr;
  }
}