.header {
  flex: 0 0 auto;
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #E8ECF2;
}
.header__inner {
  max-width: var(--shell);
  margin: 0 auto;
  padding: 14px var(--gutter);
  min-height: var(--header-min);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 26px;
}
.header__logo {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 0 1 auto;
  min-width: 0;
  color: inherit;
}
.header__logo img {
  height: 68px;
  width: auto;
  display: block;
  object-fit: contain;
  aspect-ratio: 81 / 100;
}
.header__logo-text {
  max-width: 18.125rem;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.15;
  color: var(--ink);
}
.nav {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 26px;
  min-width: 0;
  font-size: 1rem;
  font-weight: 500;
}
.nav a {
  color: var(--ink);
  transition: color .15s;
}
.nav a:hover { color: var(--brand); }
@media (min-width: 1201px) and (max-width: 1460px) {
  .nav { gap: 10px 16px; font-size: 0.9375rem; }
  .header__logo-text { font-size: 0.8438rem; }
}

.nav a[aria-current="page"] { color: var(--brand); font-weight: 600; }
.header__tools {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}
.icon-btn {
  width: 46px;
  height: 46px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: transform .15s, background .15s;
}
.icon-btn:hover { background: #EEF3FB; transform: translateY(-1px); }
.icon-btn img { width: 40px; height: 40px; border-radius: 10px; object-fit: cover; }
.burger {
  display: none;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid var(--line-3);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}
.burger span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform .2s, opacity .2s;
}
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
@media (max-width: 1200px) {
  .burger { display: flex; }
  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    margin: 0;
    padding: 12px var(--gutter) 20px;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    background: var(--surface);
    border-bottom: 1px solid var(--line-2);
    box-shadow: 0 18px 32px rgba(20, 33, 61, .12);
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .18s, transform .18s, visibility .18s;
    z-index: 90;
  }
  .nav[data-open="true"] {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav a {
    padding: 13px 12px;
    border-radius: 9px;
    font-size: 1rem;
  }
  .nav a:hover { background: #F2F5FA; }
  .header__logo img { height: 56px; }
  .header__logo-text { font-size: 0.8438rem; max-width: 15rem; }
  .header__tools { margin-left: auto; }
}

@media (max-width: 600px) {
  .header__inner { padding: 10px var(--gutter); gap: 10px; flex-wrap: nowrap; }
  .header__logo { gap: 8px; }
  .header__logo img { height: 54px; }
  .header__logo-text { font-size: 0.5938rem; max-width: 9.375rem; }
  .header__tools { gap: 4px; }
  .icon-btn,
  .burger { width: 40px; height: 40px; }
  .icon-btn img { width: 32px; height: 32px; }
}

@media (max-width: 400px) {
  .header__logo-text { display: none; }
  .header__logo img { height: 60px; }
}

@media print {
  .header,
  .burger { display: none !important; }
}
