/* Header styles for RGO */

.uec-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: linear-gradient(135deg, rgba(5, 6, 10, 0.96), rgba(5, 6, 10, 0.92));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

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

.uec-header__branding {
  display: flex;
  align-items: center;
  min-width: 0;
}

.uec-header__logo-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
}

.uec-header__logo-mark {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 0, #f5c75a, #7b1430 55%, #05060a 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-glow-gold);
  position: relative;
  overflow: hidden;
}

.uec-header__logo-chip {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 3px solid rgba(247, 247, 251, 0.85);
  box-shadow: 0 0 0 2px rgba(5, 6, 10, 0.85);
}

.uec-header__logo-text {
  display: flex;
  flex-direction: column;
}

.uec-header__logo-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.uec-header__logo-subtitle {
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
}

/* Navigation */

.uec-header__nav {
  display: flex;
  align-items: center;
}

.uec-header__nav-list {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.uec-header__nav-link {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
  padding: 0.35rem 0.25rem;
  position: relative;
}

.uec-header__nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, #f5c75a, #1f4bff);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform var(--transition-normal);
}

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

.uec-header__nav-link:hover::after,
.uec-header__nav-link:focus-visible::after {
  transform: scaleX(1);
}

.uec-header__nav-item--cta .uec-header__nav-link--cta {
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, #f5c75a, #ffd66b);
  color: #1b1304;
  font-weight: 600;
  box-shadow: var(--shadow-soft);
}

.uec-header__nav-item--cta .uec-header__nav-link--cta::after {
  display: none;
}

.uec-header__nav-item--cta .uec-header__nav-link--cta:hover {
  box-shadow: var(--shadow-strong);
}

/* Mobile toggle */

.uec-header__toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.18);
  align-items: center;
  justify-content: center;
  gap: 3px;
  background-color: rgba(5, 6, 10, 0.9);
}

.uec-header__toggle-bar {
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--color-text);
  transition: transform var(--transition-normal), opacity var(--transition-normal), background-color var(--transition-normal);
}

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

.uec-header__toggle--open .uec-header__toggle-bar:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

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

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

/* Mobile layout */

@media (max-width: 768px) {
  .uec-header__inner {
    gap: var(--space-4);
  }

  .uec-header__toggle {
    display: inline-flex;
    flex-direction: column;
  }

  .uec-header__nav {
    position: fixed;
    inset: 64px 0 auto 0;
    background: radial-gradient(circle at top, rgba(245, 199, 90, 0.08), transparent 55%), rgba(5, 6, 10, 0.98);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transform-origin: top;
    transform: scaleY(0.9);
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-normal), transform var(--transition-normal);
  }

  .uec-header__nav-list {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
    padding: var(--space-4) var(--space-4) var(--space-5);
  }

  .uec-header__nav-link {
    padding: 0.5rem 0;
    font-size: var(--font-size-base);
  }

  .uec-header__nav--open {
    opacity: 1;
    transform: scaleY(1);
    pointer-events: auto;
  }
}

@media (max-width: 480px) {
  .uec-header__logo-title {
    font-size: 0.9rem;
  }

  .uec-header__logo-subtitle {
    display: none;
  }
}
