.navbar {
  background-color: var(--color-bg);
  box-shadow: 0 2px 10px var(--color-border);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.navbar__mobile {
  display: none;
  background-color: var(--color-bg);
  box-shadow: 0 2px 10px var(--color-border);
  position: fixed;
  bottom: 0;
  z-index: 1000;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.navbar__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.navbar__brand {
  display: flex;
}

.navbar__img {
  width: 142px;
  height: auto;
}

.navbar__menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 20px;
  align-items: center;
}

.dropdown__link {
  color: var(--color-txt);
  text-decoration: none;
  padding: 10px 15px;
  display: block;
  border-radius: 5px;
  transition: all 0.3s ease;
  font-weight: 500;
}

.navbar__item{
    position: relative;
}

.dropdown__menu {
  display: none;
  list-style: none;
  position: absolute;
  background-color: var(--color-bg-dd);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  top: 100%;
  left: 0;
  min-width: 180px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  z-index: 10;
}

.dropup__menu {
  display: none;
  list-style: none;
  position: absolute;
  background-color: var(--color-bg-dd);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  bottom: 100%;
  min-width: 180px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  z-index: 10;
}

.left {
  left: 0;
}

.right {
  right: 0;
}

.dropdown__link {
  padding: 10px 16px;
}

.dropdown:hover .dropdown__menu, .dropdown:hover .dropup__menu {
  display: block;
}

.dropdown:hover > .dropdown__link {
  background-color: #6B5CFF; 
  color: white;
  font-weight: bold;
  border-radius: 6px;
}

.theme-toggle {
  font-size: 20px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
}

.dropdown__link:hover,
.dropdown__link:active {
  background-color: var(--color-secondary);
  color: #fff;
}

.theme-toggle {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-secondary);
  margin-left: 1rem;
}

.navbar__toggle {
  display: none;
}

.language-switcher {
  display: flex;
  gap: 10px;
}

.lang-option {
  background-color: transparent;
  border: 1px solid var(--color-border);
  padding: 6px 12px;
  border-radius: 4px;
  color: var(--color-txt);
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Hover solo si NO está activo */
.lang-option:not(.active):hover {
  background-color: var(--color-secondary);
  color: #fff;
}

/* Estilo del idioma activo */
.lang-option.active {
  background-color: var(--color-secondary);
  color: #fff;
  cursor: default; 
}


@media (min-width: 601px) and (max-width: 1024px) {
  .navbar__toggle {
    display: block;
    font-size: 28px;
    background: none;
    border: none;
    color: var(--color-txt);
    cursor: pointer;
    z-index: 1001;
  }

  .mobile__menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background-color: var(--color-bg);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
    padding: 10px 0;
  }

  .navbar__menu.active {
    display: flex;
  }

  .dropdown__menu {
    display: none;
    background-color: var(--color-bg-dd);
    margin: 5px 0;
    border-radius: 6px;
    padding: 5px 0;
  }

  .dropdown.open .dropdown__menu {
    display: block;
  }
}

@media (max-width: 600px) {
  .navbar {
    display: none;
  }
  .navbar__mobile {
    display: block;
  }
  .navbar__menu {
    display: flex;
    justify-content: space-between;
    height: 70px;
    width: 100vw;
  }
  .navbar__container {
    padding: 3px;
    margin: 0;
  }
  .navbar__item {
    width: 30%;
    padding: 0 7px;
  }
  .navbar__logo {
    max-width: 142px;
  }
  .navbar__img{
    width: 100%;
  }
  .dropdown__link {
    padding: 5px 7px;
    text-align: start;
  }
}
