@import "../styles/variables.css";

/* =========================
   TOP BAR
========================= */
.topbar {
  background: var(--header-bg, #ff0000);
  color: #fff;
  font-size: 0.75rem;
  padding: 0.5rem 1rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  z-index: 1001;
}

/* =========================
   HEADER
========================= */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--header-bg, #ff0000);
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* =========================
   LOGO
========================= */
.header-left {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 90PX;
  width: auto;
}

/* =========================
   NAV (BASE)
========================= */
.nav {
  display: none;
  align-items: center;
  gap: 1.8rem;
}

.nav a {
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
}

/* =========================
   NAV ITEM + DROPDOWN
========================= */
.nav-item {
  position: relative;
}

.nav-item > span {
  color: #fff;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
}

/* SUBMENU DESKTOP */
.dropdown {
  display: none;
  position: absolute;
  top: 120%;
  left: 0;
  min-width: 200px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 20px 40px var(--header-bg, #ff0000);
  overflow: hidden;
  z-index: 3000;
}

.dropdown a {
  display: block;
  padding: 0.75rem 1rem;
  color: var(--header-bg, #ff0000);
  font-size: 0.9rem;
}

.dropdown a:hover {
  background: var(--header-bg, #ff0000);
}

/* =========================
   MENU BUTTON (MOBILE)
========================= */
.menu-btn {
  background: none;
  border: none;
  font-size: 1.9rem;
  color: #fff;
  cursor: pointer;
  z-index: 2000;
}

.nav-btn {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.2rem;
  font-weight: 500;
  cursor: pointer;
}

/* DROPDOWN MOBILE */
.dropdown.mobile {
  background: var(--header-bg, #ff0000);
  width: 100%;
  padding: 0.5rem 0;
}

.dropdown.mobile a {
  color: #fff;
  padding: 0.6rem 2rem;
  display: block;
}

/* =========================
   MOBILE
========================= */
@media (max-width: 1023px) {
  .nav {
    position: fixed;
    inset: 0;
    background: var(--header-bg, #ff0000);
    flex-direction: column;
    justify-content: center;
    gap: 1.4rem;
    display: none;
  }

  .nav.open {
    display: flex;
  }

  .nav a,
  .nav-item > span {
    font-size: 1.2rem;
  }

  .dropdown {
    position: static;
    display: block;
    background: transparent;
    box-shadow: none;
  }

  .dropdown a {
    color: #fff;
    padding-left: 1.6rem;
    font-size: 1rem;
  }
}

/* =========================
   DESKTOP (CENTRADO REAL)
========================= */
@media (min-width: 1024px) {
  .nav {
    display: flex;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }

  .menu-btn {
    display: none;
  }

  .nav-item:hover .dropdown {
    display: block;
  }
    .dropdown {
    position: absolute;
}

/* =========================
   LOGO RESPONSIVE
========================= */
@media (max-width: 480px) {
  .logo-img {
    height: 48px;
  }
}

@media (min-width: 1280px) {
  .logo-img {
    height: 110px;
  }
}
/* UNIFICAR ESTILO DE LINKS Y BOTONES */
.nav a,
.nav-btn {
  color: #e5e7eb;          /* blanco suave */
  font-size: 1.1rem;
  font-weight: 500;
  line-height: 1;
  background: none;
  border: none;
  padding: 0;
}

.nav a:hover,
.nav-btn:hover {
  color: #fff;
}

}