.site-header {
  background: rgba(3, 13, 30, 0.94);
  border-top: 1px solid rgba(255, 255, 255, 0.75);
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(18px);
}

.header-inner {
  min-height: 78px;
}

.brand {
  flex: 0 0 auto;
  gap: 12px;
  min-width: 360px;
  max-width: calc(100% - 62px);
}

.brand img {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  padding: 4px;
  border-radius: 50%;
  background: #fff;
  object-fit: contain;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18), 0 12px 30px rgba(22, 135, 245, 0.34);
}

.brand span {
  display: block;
  line-height: 1.05;
}

.brand strong {
  display: block;
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.brand small {
  display: block;
  margin-top: 5px;
  color: #aebed2;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
}

.menu-button {
  flex: 0 0 46px;
  margin-left: auto;
}

.menu-icon {
  display: grid;
  gap: 4px;
  width: 22px;
  margin: auto;
}

.menu-icon span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 99px;
  background: currentColor;
  transition: transform 180ms ease, opacity 180ms ease;
}

.menu-button[aria-expanded="true"] .menu-icon span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-button[aria-expanded="true"] .menu-icon span:nth-child(2) {
  opacity: 0;
}

.menu-button[aria-expanded="true"] .menu-icon span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

@media (max-width: 1200px) {
  .menu-button {
    display: block;
  }

  .primary-navigation {
    display: block;
    position: fixed;
    top: 80px;
    right: 0;
    left: auto;
    width: min(88vw, 390px);
    height: calc(100dvh - 80px);
    overflow: auto;
    padding: 20px 22px calc(30px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(180deg, #071a31, #0a2948);
    box-shadow: -24px 0 60px rgba(0, 0, 0, 0.3);
    visibility: hidden;
    transform: translateX(100%);
    transition: transform 220ms ease, visibility 220ms ease;
  }

  .primary-navigation.open {
    visibility: visible;
    transform: translateX(0);
  }

  .primary-navigation ul {
    display: grid;
  }

  .primary-navigation a {
    min-height: 52px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-size: 1rem;
  }
}

@media (max-width: 560px) {
  .header-inner {
    min-height: 72px;
  }

  .brand {
    min-width: 0;
    gap: 12px;
    max-width: calc(100% - 58px);
  }

  .brand img {
    width: 52px;
    height: 52px;
    flex-basis: 52px;
  }

  .brand strong {
    font-size: clamp(0.72rem, 3.1vw, 0.9rem);
    white-space: normal;
  }

  .brand small {
    display: block;
    margin-top: 5px;
    font-size: clamp(0.58rem, 2.35vw, 0.7rem);
    line-height: 1.2;
    white-space: normal;
  }

  .primary-navigation {
    top: 74px;
    width: 100%;
    height: calc(100dvh - 74px);
    box-shadow: none;
  }
}

@media (max-width: 390px) {
  .brand img {
    width: 50px;
    height: 50px;
    flex-basis: 50px;
  }

  .brand strong {
    font-size: 0.7rem;
  }

  .brand small {
    font-size: 0.56rem;
  }
}
