/* 独立技术页与制造页复用统一官网导航排版、国际化标识与阻尼下拉动效 */
:root {
  --header-height: 72px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}
body { padding-top: var(--header-height); }
body.menu-open { overflow: hidden; }
.skip {
  position: fixed; top: 12px; left: 12px; z-index: 30; padding: 10px 16px;
  border-radius: 8px; background: #fff; box-shadow: 0 12px 32px rgba(8, 21, 38, 0.12);
  transform: translateY(-160%); transition: transform .2s var(--ease-out);
}
.skip:focus { transform: translateY(0); }

.header {
  --ink: #0d1b2e;
  --muted: #4e5e73;
  --blue: #164cc5;
  --blue-hover: #103b9c;
  --blue-soft: #e8effc;
  --line: #d6dfe9;
  --gutter: clamp(20px, 5.2vw, 84px);
  position: fixed; z-index: 20; inset: 0 0 auto; color: var(--ink);
  background: rgba(248, 250, 252, 0.92);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(18, 38, 68, 0.08);
  font-family: Inter, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans JP", "Malgun Gothic", sans-serif;
  line-height: 1.55;
  transition: background-color .22s ease, box-shadow .22s ease;
}
.header.is-scrolled { background: rgba(255, 255, 255, 0.96); box-shadow: 0 4px 20px rgba(8, 21, 38, 0.05); }
.header a { color: inherit; text-decoration: none; }
.header a, .header button { -webkit-tap-highlight-color: transparent; }
.header a[aria-current="page"] { color: var(--blue); font-weight: 650; }
.header :focus-visible { outline: 2px solid #4c8eff; outline-offset: 3px; }
.header-inner {
  min-height: var(--header-height); padding-inline: clamp(16px, 2.4vw, 40px);
  display: grid; grid-template-columns: minmax(max-content, 1fr) auto minmax(max-content, 1fr);
  align-items: center; gap: 16px; position: relative;
}
.header-brand { display: inline-flex; align-items: center; gap: 10px; justify-self: start; }
.header-brand .brand-zh { display: block; width: clamp(128px, 10.6vw, 162px); height: auto; }
.header-brand .brand-intl { display: none; align-items: center; gap: 9px; }
.header-brand .brand-intl img { display: block; width: 34px; height: auto; }
.header-brand .brand-intl-text { font-size: 1.12rem; font-weight: 800; letter-spacing: 0.07em; color: var(--ink); line-height: 1; }
html:not([lang^="zh"]) .header-brand .brand-zh { display: none; }
html:not([lang^="zh"]) .header-brand .brand-intl { display: inline-flex; }

.nav { display: flex; align-items: center; gap: clamp(4px, 0.85vw, 14px); }
.nav-group { position: relative; }
.nav-item {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 7px;
  min-height: 40px; padding: 7px 11px; font-size: .9rem; font-weight: 560;
  white-space: nowrap; color: inherit; background: none; border: 0; border-radius: 8px;
  transition: color .16s ease, background-color .16s ease;
}
.nav-item:hover, .nav-item[aria-expanded="true"] { color: var(--blue); background: rgba(22, 76, 197, 0.07); }
.chevron {
  display: block; width: 6px; height: 6px; border: solid currentColor;
  border-width: 0 1.5px 1.5px 0; transform: translateY(-2px) rotate(45deg);
  transition: transform .2s var(--ease-out);
}
.nav-item[aria-expanded="true"] .chevron { transform: translateY(1px) rotate(225deg); }

.flyout {
  position: absolute; z-index: 5; top: calc(100% + 6px); left: 0; min-width: 248px; padding: 7px;
  background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 12px 32px rgba(8, 21, 38, 0.12);
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(6px) scale(0.985); transform-origin: top left;
  transition: opacity .18s var(--ease-out), transform .18s var(--ease-out), visibility 0s .18s;
}
.flyout::before { content: ""; position: absolute; inset: -10px 0 auto 0; height: 10px; }
.flyout-end { left: auto; right: 0; min-width: 184px; transform-origin: top right; }
.nav-group.is-open .flyout,
.nav-item[aria-expanded="true"] + .flyout {
  opacity: 1; visibility: visible; pointer-events: auto;
  transform: translateY(0) scale(1); transition-delay: 0s;
}
.flyout a {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px; border-radius: 8px; font-size: .89rem; font-weight: 500;
  white-space: nowrap; transition: background-color .14s ease, color .14s ease;
}
.flyout a small { color: var(--muted); font-size: .78rem; }
.flyout a:hover, .flyout a:focus-visible { background: var(--blue-soft); color: var(--blue); }

.header .header-cta {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 38px; padding: 7px 16px; border-radius: 999px;
  background: var(--blue); color: #fff; font-size: .85rem; font-weight: 640; white-space: nowrap;
  transition: background-color .18s ease;
}
.header .header-cta:hover { background: var(--blue-hover); }
.nav-mobile-cta { display: none; }
.mobile-trigger { display: none; }

@media (max-width: 1080px) {
  :root { --header-height: 64px; }
  .header-inner { grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
  .header-brand .brand-zh { width: clamp(112px, 26vw, 138px); }
  .header .header-cta { display: none; }
  .mobile-trigger {
    display: inline-flex; align-items: center; gap: 7px; min-height: 42px; padding: 6px 10px;
    color: inherit; font-size: .88rem; font-weight: 640; background: none; border: 1px solid var(--line); border-radius: 999px;
  }
  .menu-icon { width: 14px; height: 10px; position: relative; }
  .menu-icon::before, .menu-icon::after {
    content: ""; position: absolute; left: 0; top: 1.5px; width: 14px; height: 1.5px;
    background: currentColor; transition: transform .18s var(--ease-out);
  }
  .menu-icon::after { top: 7px; }
  .mobile-trigger[aria-expanded="true"] .menu-icon::before { transform: translateY(2.75px) rotate(45deg); }
  .mobile-trigger[aria-expanded="true"] .menu-icon::after { transform: translateY(-2.75px) rotate(-45deg); }
  .header.is-open { background: #fff; }
  .nav {
    position: absolute; z-index: 10; top: 100%; inset-inline: 0; width: 100%;
    display: none; overflow-y: auto; overscroll-behavior: contain;
    max-height: calc(100dvh - var(--header-height)); padding: 8px var(--gutter) 28px;
    background: #fff; color: var(--ink); border-top: 1px solid var(--line);
    box-shadow: 0 16px 32px rgba(8, 21, 38, 0.14);
  }
  .header.is-open .nav { display: block; }
  .nav-item {
    display: flex; width: 100%; min-height: 52px; padding-inline: 4px;
    border-bottom: 1px solid var(--line); border-radius: 0; font-size: 1rem; text-align: left;
  }
  .nav-item:hover, .nav-item[aria-expanded="true"] { background: transparent; color: var(--blue); }
  .flyout {
    position: static; width: 100%; padding: 6px 0 10px; background: none; border: 0;
    border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none;
    display: none; opacity: 1; visibility: visible; pointer-events: auto; transform: none;
  }
  .flyout::before { display: none; }
  .nav-group.is-open .flyout, .nav-item[aria-expanded="true"] + .flyout { display: block; }
  .flyout a { font-size: .94rem; padding: 10px 12px; white-space: normal; }
  .nav-mobile-cta {
    display: flex; align-items: center; justify-content: center; width: 100%; min-height: 46px;
    margin-top: 18px; border-radius: 999px; background: var(--blue); color: #fff !important; font-weight: 650;
  }
}

@media (prefers-reduced-motion: reduce) {
  .header *, .header *::before, .header *::after { transition-duration: .001ms !important; }
}
