.site-header {
  --site-header-active-color: #4e8dff;
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  display: grid;
  grid-template-columns: minmax(140px, 1fr) auto minmax(140px, 1fr);
  align-items: center;
  gap: 18px;
  padding: 0 var(--layout-pad);
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(9, 9, 14, .70), rgba(9, 9, 14, .34));
  backdrop-filter: blur(18px) saturate(1.2);
}

html[data-theme="light"] .site-header {
  background: linear-gradient(180deg, rgb(243 213 255 / 65%), rgb(226 250 255 / 35%));
}

.brand {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  min-width: 0;
  text-decoration: none;
}

.brand-logo {
  width: auto;
  height: clamp(28px, 2.15vw, 38px);
  max-width: min(220px, 34vw);
  display: block;
  object-fit: contain;
  flex: 0 0 auto;
}

.brand-logo--light {
  display: none;
}

html[data-theme="light"] .brand-logo--dark {
  display: none;
}

html[data-theme="light"] .brand-logo--light {
  display: block;
}

.main-nav {
  justify-self: center;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 34px;
}

.main-nav__link {
  position: relative;
  height: 100%;
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  font-size: 15px;
  font-weight: 850;
  text-decoration: none;
  transition: color .18s ease;
}

.main-nav__link:hover,
.main-nav__link--active {
  color: var(--text);
}

.main-nav__link--active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 52px;
  height: 4px;
  border-radius: 999px 999px 0 0;
  background: var(--site-header-active-color);
  transform: translateX(-50%);
}

.header-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 20px;
}

.mobile-menu-button {
  width: 44px;
  height: 44px;
  display: none;
  place-items: center;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.profile-button {
  position: relative;
  width: 46px;
  height: 46px;
  padding: 0;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, .68);
  border-radius: 50%;
  background: rgba(255, 255, 255, .09);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .24);
}

.profile-button__avatar {
  width: 100%;
  height: 100%;
  display: block;
}

.profile-button__initials {
  position: absolute;
  inset: auto 0 4px;
  display: none;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  text-align: center;
}
