/* 全站共享：窄屏头部导航。菜单内容与跳转逻辑由 site-navigation.js 统一生成。 */
@media (max-width: 1400px) {
  .nav { width: calc(100% - 32px); border-radius: 24px; }
  .nav-links {
    position: fixed;
    top: 108px;
    right: 16px;
    left: 16px;
    display: none;
    max-height: calc(100dvh - 138px);
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    overflow-y: auto;
    padding: 14px;
    border: 1px solid rgb(255 255 255 / 24%);
    border-radius: 22px;
    color: #fff;
    background: rgb(8 42 105 / 92%);
    box-shadow: 0 20px 50px rgb(4 29 76 / 24%);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
  }
  body.nav-open .nav-links { display: grid; }
  .nav-item { width: 100%; }
  .nav-link, .nav-link--static {
    min-height: 44px;
    justify-content: center;
    color: #fff;
    background: rgb(255 255 255 / 8%);
  }
  .nav-link:hover, .nav-link.active, .nav-link--static:hover, .nav-link--static.active {
    color: #fff;
    background: rgb(255 255 255 / 18%);
    transform: none;
  }
  .submenu {
    position: static;
    display: none;
    min-width: 0;
    margin-top: 8px;
    padding: 8px;
    border-color: rgb(255 255 255 / 14%);
    border-radius: 16px;
    color: #fff;
    visibility: visible;
    opacity: 1;
    background: rgb(255 255 255 / 8%);
    box-shadow: none;
    transform: none;
  }
  .nav-item.has-submenu:hover .submenu,
  .nav-item.has-submenu:focus-within .submenu,
  body.nav-open .submenu { display: grid; transform: none; }
  .submenu a, .submenu-static { color: rgb(255 255 255 / 84%); text-align: center; }
  .submenu a:hover, .submenu a:focus, .submenu a.active, .submenu-static:hover { color: #fff; background: rgb(255 255 255 / 12%); }
  .menu-toggle { display: inline-flex; }
}

@media (max-width: 760px) {
  .nav { top: 12px; width: calc(100% - 24px); min-height: 64px; gap: 8px; padding: 6px 12px; }
  .brand { min-width: 0 !important; max-width: calc(100% - 110px); flex: 1 1 0 !important; }
  .brand-logo { width: auto; max-width: 100%; height: 28px !important; }
  .nav-actions { gap: 8px; }
  .login { min-width: 52px; min-height: 42px; padding: 0 12px; font-size: 14px; }
  .menu-toggle { width: 42px; height: 42px; }
  .nav-links { top: 88px; right: 12px; left: 12px; grid-template-columns: 1fr; max-height: calc(100dvh - 104px); }
}
