/* ================================
   VARIABLES Y RESET
================================= */
:root {
  --primary-color: #2c3e50;
  --secondary-color: #3498db;
  --accent-color: #e74c3c;
  --text-light: #ffffff;
  --text-dark: #333333;
  --header-height: 68px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}


body {
  font-family: 'Source Sans Pro', Arial, sans-serif;
  background-color: #f4f5f5;
  color: var(--text-dark);
}

/* ================================
   HEADER Y NAVEGACIÓN
================================= */
.main-header {
  background-color: #f4f5f5;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  height: var(--header-height);
  position: relative;
  z-index: 1000;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}

.logo img {
  height: 40px;
  width: auto;
}

/* Botón menú móvil */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

.menu-icon {
  display: block;
  width: 25px;
  height: 2px;
  background: #00386c;
  position: relative;
}
.menu-icon::before,
.menu-icon::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  background: #00386c;
  transition: var(--transition);
}
.menu-icon::before {
  top: -8px;
}
.menu-icon::after {
  bottom: -8px;
}

/* Navegación */
.header-navigation {
  display: flex;
  align-items: center;
  gap: 30px;
}

.main-nav {
  margin-left: 20px;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 20px;
}

.nav-link {
  text-decoration: none;
  text-transform: uppercase;
  color: #00386C;
  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  transition: var(--transition);
}

.nav-link:hover {
  background-color: var(--primary-color); /* Azul marino */
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  min-width: 200px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  opacity: 0;
  visibility: hidden;
  list-style: none;
  transition: var(--transition);
  z-index: 999;
}

.dropdown:hover .dropdown-menu,
.dropdown.active .dropdown-menu,
.dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
}

.dropdown-menu li a {
  display: block;
  padding: 12px 15px;
  text-decoration: none;
  color: var(--text-dark);
  font-size: 0.9rem;
  transition: var(--transition);
  text-transform: uppercase;
}

.dropdown-menu li a:hover {
  background-color: #B5020B;
  color: white;
}

/* Acceso rápido */
.quick-access {
  display: flex;
  gap: 10px;
}

.cta-button {
  background: var(--accent-color);
  color: white;
  font-size: 14px;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 4px;
  transition: var(--transition);
}

.cta-button:hover {
  background: #c0392b;
  transform: translateY(-2px);
}

/* ================================
   HERO BOX
================================= */
.hero-box {
  background: var(--secondary-color);
  color: white;
  text-align: center;
  padding: 60px 20px;
}
.hero-box h1 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}
.hero-box p {
  max-width: 800px;
  margin: 0 auto;
  text-align: justify;
  text-align-last: center;
}

/* ================================
   GALERÍA DE VÁLVULAS
================================= */
.galeria-valvulas {
  padding: 40px 5%;
  background-color: #ffffff;
  text-align: center;
}
.galeria-valvulas h2 {
  font-size: 2rem;
  margin-bottom: 30px;
  color: var(--primary-color);
}
.galeria-valvulas h2 a {
  text-decoration: none;
  color: var(--primary-color);
  transition: color 0.3s;
}


.grid-valvulas {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px;
  justify-items: center;
}
.valvula {
  background: #f9f9f9;
  border-radius: 6px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  padding: 10px;
  transition: transform 0.3s;
  max-width: 180px;
}
.valvula:hover {
  transform: translateY(-5px);
}
.valvula img {
  width: 100%;
  height: auto;
  object-fit: contain;
}
.valvula p {
  margin-top: 10px;
  font-weight: bold;
  font-size: 0.9rem;
}
.valvula a {
  text-decoration: none;
  color: inherit;
  display: block;
  text-align: center;
}
.valvula a:hover {
  color: var(--secondary-color);
}

.ver-productos {
  display: inline-block;
  margin-top: 20px;
  font-size: 1.5rem;
  font-weight: bold;
  text-decoration: none;
  color: var(--primary-color);
}
.ver-productos:hover {
  color: var(--secondary-color);
}

/* ================================
   INFORMACIÓN
================================= */
.info-section {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 40px 5%;
  background: white;
}
.info-text {
  flex: 1;
  min-width: 300px;
  max-width: 1000px;
}
.info-text h2 {
  text-align: center;
  color: var(--primary-color);
  margin-bottom: 20px;
}
.info-text p {
  text-align: justify;
  margin-bottom: 15px;
}

/* ================================
   FOOTER
================================= */
.footer {
  background: var(--primary-color);
  color: white;
  padding: 20px 5%;
  text-align: center;
}
.footer-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

/* ================================
   RESPONSIVE
================================= */
@media (max-width: 1024px) {
  .header-navigation {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: var(--primary-color);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 30px;
    transform: translateX(-100%);
    transition: var(--transition);
  }

  .header-navigation.active {
    transform: translateX(0);
  }

  .header-navigation.active .nav-link {
  color: white;
}

.header-navigation.active .nav-link:hover {
  background-color: white;
  color: var(--primary-color);
}

  .header-navigation.active .dropdown-menu li a {
  color: white;
}

.header-navigation.active .dropdown-menu li a:hover {
  background-color: var(--accent-color); /* rojo */
  color: white;
}



  .nav-menu {
    flex-direction: column;
    width: 100%;
    align-items: center;
  }

  .nav-menu > li {
    width: 100%;
    text-align: center;
  }

  .dropdown-menu {
    position: static;
    background: #34495e;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    display: none;
  }

  .dropdown.active .dropdown-menu {
    display: block;
  }

  .dropdown-menu a {
    color: white;
    text-align: center;
  }

  .quick-access {
    flex-direction: column;
    align-items: center;
    margin-top: 20px;
  }

  .mobile-menu-btn {
    display: block;
  }
}

@media (max-width: 600px) {
  .hero-box h1 {
    font-size: 1.8rem;
  }

  .slide {
    width: 120px;
    height: 180px;
  }

  .slide img {
    width: 90px;
    height: 130px;
  }

  .footer-content {
    flex-direction: column;
    gap: 10px;
  }
}
