@media (max-width: 760px) {
  body:not(.auth-page):not(.dashboard-page) header {
    height: auto;
  }
  header .wrap.nav {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas: "brand actions" "sections sections";
    align-items: center;
    min-height: 0;
    height: auto;
    gap: 0 8px;
    padding-top: 5px;
  }
  header .nav > .brand {
    grid-area: brand;
    gap: 5px;
    font-size: 16px;
  }
  header .nav > .brand svg {
    width: 28px;
  }
  body:not(.dashboard-page):not(.auth-page) header .nav-actions {
    grid-area: actions;
    justify-content: flex-end;
    gap: 6px;
    white-space: nowrap;
  }
  body:not(.dashboard-page):not(.auth-page) header .nav-actions a,
  body:not(.dashboard-page):not(.auth-page) header .language-switch select {
    font-size: 14px !important;
  }
  header .nav-actions .login {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
  }
  body:not(.dashboard-page):not(.auth-page) header .nav-actions .small {
    padding: 7px 10px;
  }
  header .nav-actions .small span,
  header .nav-actions .language-switch > span {
    display: none;
  }
  header .nav nav {
    grid-area: sections;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    overflow-x: auto;
    white-space: nowrap;
    scrollbar-width: none;
  }
  body:not(.dashboard-page):not(.auth-page) header .nav nav a {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    font-size: 14px !important;
  }
}
@media (max-width: 370px) {
  header .nav > .brand span { display: none; }
}
@media (max-width: 760px) {
  .summit-metrics .metrics-refined { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .summit-metrics .metrics-refined > *,
  .summit-metrics .metrics-client-link > span { min-width: 0; white-space: normal; }
  .summit-metrics .metrics-refined strong,
  .summit-metrics .metrics-client-link small { white-space: normal; overflow-wrap: anywhere; }
}
@media (min-width: 371px) and (max-width: 400px) {
  html[lang^="en"] header .nav > .brand span { font-size: 14px; }
}
@media (min-width: 371px) and (max-width: 400px) {
  html[lang^="en"] body:not(.auth-page):not(.dashboard-page) header .nav-actions { gap: 4px; }
  html[lang^="en"] header .nav > .brand svg { width: 24px; }
}
