.header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: all var(--transition);
}

.header.scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
}

.header-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  text-decoration: none;
}

.logo h1 {
  font-size: 1.5rem;
  background: var(--highlight-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-family: 'Space Grotesk', sans-serif;
}

/* Hamburger Menu */
.mobile-menu-button {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}

.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: all var(--transition);
}

.hamburger.active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.nav-list {
  display: flex;
  list-style: none;
  gap: 2.5rem;
  align-items: center;
  margin: 0;
  padding: 0;
}

.nav-list li {
  position: relative;
}

.nav-list a {
  color: var(--text-dark);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all var(--transition);
  padding: 0.5rem 0;
  position: relative;
}

.nav-list a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--highlight-gradient);
  transition: width var(--transition);
  border-radius: 2px;
}

.nav-list a:hover,
.nav-list a.active {
  color: var(--highlight-color);
}

.nav-list a:hover::after,
.nav-list a.active::after {
  width: 100%;
}

/* Nav CTA Button */
.nav-cta {
  background: var(--primary-gradient);
  color: white !important;
  padding: 0.6rem 1.5rem !important;
  border-radius: 100px;
  font-weight: 600 !important;
  transition: all var(--transition-smooth) !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.nav-cta::after {
  display: none !important;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  color: white !important;
}

/* Dropdown */
.dropdown {
  position: relative;
}

.dropdown-toggle {
  background: none;
  border: none;
  color: var(--text-dark);
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  font-family: inherit;
  padding: 0.5rem 0;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dropdown-toggle svg {
  transition: transform var(--transition);
}

.dropdown:hover .dropdown-toggle svg,
.dropdown-toggle.active svg {
  transform: rotate(180deg);
}

.dropdown-toggle:hover,
.dropdown-toggle.active {
  color: var(--highlight-color);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: white;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.12);
  border-radius: var(--radius-lg);
  padding: 0.75rem 0;
  min-width: 260px;
  list-style: none;
  margin-top: 0.5rem;
  z-index: 1001;
  border: 1px solid rgba(0, 0, 0, 0.06);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition);
}

.dropdown:hover .dropdown-menu,
.dropdown-menu.open {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-menu li {
  padding: 0;
}

.dropdown-menu a {
  display: block;
  padding: 0.75rem 1.5rem;
  color: var(--text-dark);
  transition: all var(--transition);
  font-size: 0.9rem;
  font-weight: 500;
}

.dropdown-menu a::after {
  display: none;
}

.dropdown-menu a:hover {
  background: var(--bg-light);
  color: var(--highlight-color);
  padding-left: 1.75rem;
}

@media (max-width: 900px) {
  .header-container {
    padding: 1rem 1.5rem;
  }

  .mobile-menu-button {
    display: block;
  }

  .nav {
    display: none;
  }

  .nav.mobile-open {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.12);
    padding: 1.5rem 0;
    border-bottom-left-radius: var(--radius-lg);
    border-bottom-right-radius: var(--radius-lg);
  }

  .nav-list {
    flex-direction: column;
    gap: 0;
  }

  .nav-list li {
    width: 100%;
  }

  .nav-list a {
    display: block;
    padding: 1rem 2rem;
  }

  .nav-list a::after {
    display: none;
  }

  .nav-cta {
    margin: 1rem 2rem;
    display: block;
    text-align: center;
    width: calc(100% - 4rem);
    padding: 1rem 2rem !important;
  }

  .dropdown-toggle {
    width: 100%;
    text-align: left;
    padding: 1rem 2rem;
    justify-content: space-between;
  }

  /* Override desktop hover behavior on mobile */
  .dropdown:hover .dropdown-menu {
    opacity: 0;
    visibility: hidden;
    max-height: 0;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    margin-top: 0;
    padding-left: 1.5rem;
    background: var(--bg-light);
    transform: none !important;
    opacity: 0;
    visibility: hidden;
    max-height: 0;
    overflow: hidden;
    border-radius: 0;
    border: none;
    transition: all var(--transition);
    min-width: auto;
    left: 0;
  }

  .dropdown:hover .dropdown-menu.open,
  .dropdown-menu.open {
    opacity: 1;
    visibility: visible;
    max-height: 500px;
    padding: 0.5rem 0 0.5rem 1rem;
  }

  .dropdown-menu a {
    padding: 0.75rem 1.5rem;
  }

  .dropdown-menu a:hover {
    padding-left: 2rem;
  }
}
