/* Header styles for Lintrixx Sales Academy */

.lx-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background-color: rgba(245, 247, 251, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--gray-200);
}

.lx-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-3);
  padding-bottom: var(--space-3);
}

/* Brand */
.lx-header__brand {
  display: flex;
  align-items: center;
}

.lx-header__logo-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
}

.lx-header__logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: radial-gradient(circle at 0 0, #60a5fa, #1d4ed8);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: #ffffff;
  box-shadow: var(--shadow-md);
}

.lx-header__logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.lx-header__logo-title {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.1rem;
}

.lx-header__logo-subtitle {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

/* Navigation */
.lx-header__nav {
  display: flex;
  align-items: center;
}

.lx-header__nav-list {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lx-header__nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-text-muted);
  padding-block: 0.25rem;
}

.lx-header__nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, #60a5fa, #1d4ed8);
  transition: width var(--transition-normal);
}

.lx-header__nav-link:hover,
.lx-header__nav-link:focus-visible {
  color: var(--color-text);
}

.lx-header__nav-link:hover::after,
.lx-header__nav-link:focus-visible::after {
  width: 100%;
}

.lx-header__nav-item--highlight .lx-header__nav-link {
  padding-inline: 0;
}

.lx-header__cta {
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  background-color: var(--color-primary);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.lx-header__cta::after {
  display: none;
}

.lx-header__cta:hover,
.lx-header__cta:focus-visible {
  background-color: var(--color-primary-dark);
  color: #ffffff;
}

/* Mobile toggle */
.lx-header__toggle {
  display: none;
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--gray-200);
  align-items: center;
  justify-content: center;
  padding: 0;
  background-color: #ffffff;
  cursor: pointer;
}

.lx-header__toggle:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.lx-header__toggle-bar {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--gray-700);
  transition: transform var(--transition-normal), opacity var(--transition-normal), translate var(--transition-normal);
}

.lx-header__toggle-bar + .lx-header__toggle-bar {
  margin-top: 4px;
}

/* Open state animation */
.lx-header__toggle--open .lx-header__toggle-bar:nth-child(1) {
  transform: translateY(14px) rotate(45deg);
}

.lx-header__toggle--open .lx-header__toggle-bar:nth-child(2) {
  opacity: 0;
}

.lx-header__toggle--open .lx-header__toggle-bar:nth-child(3) {
  transform: translateY(-14px) rotate(-45deg);
}

/* Responsive behavior */
@media (max-width: 768px) {
  .lx-header__toggle {
    display: inline-flex;
    flex-direction: column;
  }

  .lx-header__nav {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    background-color: rgba(245, 247, 251, 0.98);
    border-bottom: 1px solid var(--gray-200);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-6px);
    transition:
      max-height var(--transition-slow),
      opacity var(--transition-normal),
      transform var(--transition-normal);
  }

  .lx-header__nav--open {
    max-height: 360px;
    opacity: 1;
    transform: translateY(0);
  }

  .lx-header__nav-list {
    flex-direction: column;
    align-items: flex-start;
    padding: 0.75rem 1.25rem 1.25rem;
    gap: 0.35rem;
  }

  .lx-header__nav-item--highlight {
    margin-top: 0.4rem;
  }

  .lx-header__cta {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .lx-header__logo-subtitle {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lx-header,
  .lx-header__nav,
  .lx-header__toggle-bar {
    transition: none !important;
  }
}