/* ============================================================
   DLX 统一顶栏 · 全站共用
   左 logo / 中导航 / 右气泡目录按钮
   ============================================================ */
/* 顶栏高度 + 全站统一左右边距（覆盖各页 CSS 里的 --pad，
   让 logo 与每页正文左缘严格对齐，8 个页面观感一致） */
:root{--sh-h:76px;--pad:clamp(20px,4.4vw,64px);}

.sh{
  position:fixed;
  top:0;left:0;right:0;
  height:var(--sh-h);
  z-index:90;
  display:grid;
  grid-template-columns:1fr auto 1fr;
  align-items:center;
  padding:0 var(--pad);
  /* 与当前页面底色一致，避免内页白底上出现一层浅灰“卡片” */
  background:var(--paper,#FCFCFC);
  -webkit-backdrop-filter:blur(10px);
  backdrop-filter:blur(10px);
}

/* ---------- logo ---------- */
.sh-logo{
  display:inline-flex;
  align-items:center;
  gap:11px;
  justify-self:start;
  text-decoration:none;
  color:var(--ink,#0B0B0B);
}
/* 官方 logo（DLX驭韶® 横排字标，矢量 SVG，来自 驭韶LOGO文件.ai） */
.sh-logo img{
  display:block;
  height:32px;width:auto;
}

/* ---------- 中导航 ---------- */
.sh-nav{
  display:flex;
  align-items:center;
  justify-self:center;
  gap:clamp(18px,2.6vw,40px);
  /* 覆盖 style.css 的全局 nav{border-bottom}，避免整条导航下方出现细线 */
  border-bottom:0;
}
.sh-nav a{
  position:relative;
  display:inline-flex;
  align-items:baseline;
  gap:8px;
  padding:4px 0;
  text-decoration:none;
  color:var(--ink,#0B0B0B);
  font-size:15.5px;
  letter-spacing:.08em;
  white-space:nowrap;
  transition:opacity .3s ease;
}
.sh-nav a i{
  font-style:normal;
  font-family:var(--mono,"Space Mono",monospace);
  font-size:11.5px;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:#A5A5A1;
  transition:color .3s ease;
}
.sh-nav a::after{
  content:"";
  position:absolute;
  left:0;bottom:0;
  height:1px;width:0;
  background:currentColor;
  transition:width .4s cubic-bezier(.2,.8,.2,1);
}
.sh-nav a:hover::after,
.sh-nav a[aria-current]::after{width:100%;}
.sh-nav a:hover i{color:#6E6E6B;}
.sh-nav a[aria-current]{font-weight:500;}
.sh-nav a[aria-current] i{color:#6E6E6B;}

/* ---------- 右侧气泡 ---------- */
.bub{
  position:relative;
  justify-self:end;
  display:flex;
  justify-content:flex-end;
}

.bub-toggle{
  width:44px;height:44px;
  border-radius:50%;
  border:1px solid rgba(11,11,11,.24);
  background:#fff;
  box-shadow:0 8px 20px -10px rgba(0,0,0,.45);
  display:grid;
  place-items:center;
  padding:0;
  cursor:pointer;
  transition:background .4s cubic-bezier(.34,1.56,.64,1),
             border-color .4s ease,
             transform .55s cubic-bezier(.34,1.56,.64,1);
}
@media (hover:hover) and (pointer:fine){
  .bub-toggle:hover{transform:scale(1.07);}
  .bub-toggle:hover .bub-ic i:last-child{width:16px;}
}
.bub.on .bub-toggle{
  background:#0B0B0B;
  border-color:#0B0B0B;
}

.bub-ic{position:relative;width:16px;height:12px;display:block;}
.bub-ic i{
  position:absolute;left:0;
  width:16px;height:1.5px;border-radius:2px;
  background:#0B0B0B;
  transition:transform .4s cubic-bezier(.34,1.56,.64,1),
             width .4s cubic-bezier(.34,1.56,.64,1),
             background .3s ease;
}
.bub-ic i:first-child{top:3px;}
.bub-ic i:last-child{top:9px;width:10px;}
.bub.on .bub-ic i{background:#fff;}
.bub.on .bub-ic i:first-child{transform:translateY(3px) rotate(45deg);}
.bub.on .bub-ic i:last-child{width:16px;transform:translateY(-3px) rotate(-45deg);}

/* ---------- 下拉气泡列表 ---------- */
.bub-list{
  position:absolute;
  top:calc(100% + 15px);
  right:0;
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:9px;
  padding:22px 18px 18px;
  border-radius:28px;
  background:rgba(252,252,252,.965);
  -webkit-backdrop-filter:blur(22px) saturate(1.1);
  backdrop-filter:blur(22px) saturate(1.1);
  border:1px solid rgba(11,11,11,.07);
  box-shadow:0 34px 80px -44px rgba(0,0,0,.7),0 2px 10px -6px rgba(0,0,0,.25);
  pointer-events:none;
  visibility:hidden;
  transition:visibility 0s linear .32s;
}
.bub.on .bub-list{
  visibility:visible;
  pointer-events:auto;
  transition:visibility 0s linear 0s;
}

.bub-hd{
  font-family:var(--mono,"Space Mono",monospace);
  font-size:9px;
  letter-spacing:.24em;
  text-transform:uppercase;
  color:#9A9A96;
  padding-right:8px;
  margin-bottom:6px;
  opacity:0;
  transform:translateY(-4px);
  transition:opacity .3s ease,transform .4s cubic-bezier(.34,1.56,.64,1);
}
.bub.on .bub-hd{opacity:1;transform:translateY(0);}

.bub-pill{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  width:292px;
  height:58px;
  padding:0 22px;
  border-radius:999px;
  background:#FCFCFC;
  border:1px solid rgba(11,11,11,.12);
  box-shadow:0 2px 8px -6px rgba(0,0,0,.6);
  color:#0B0B0B;
  text-decoration:none;
  white-space:nowrap;
  transform-origin:100% 0;
  transform:translateY(-8px) scale(.72) rotate(0deg);
  opacity:0;
  transition:transform .42s cubic-bezier(.34,1.56,.64,1),
             opacity .24s ease,
             background .3s ease,
             color .3s ease,
             border-color .3s ease;
}
.bub.on .bub-pill{
  transform:translateY(0) scale(1) rotate(var(--rot,0deg));
  opacity:1;
  transition-delay:calc(var(--i,0) * 55ms + 40ms);
}

.bub-l{display:inline-flex;align-items:baseline;gap:11px;}
.bub-n{
  font-family:var(--mono,"Space Mono",monospace);
  font-size:10px;
  letter-spacing:.1em;
  color:#9A9A96;
  line-height:1;
  transition:color .3s ease;
}
.bub-t{font-size:17px;font-weight:400;letter-spacing:.06em;line-height:1;}
.bub-e{
  font-family:var(--mono,"Space Mono",monospace);
  font-size:9.5px;
  letter-spacing:.15em;
  text-transform:uppercase;
  color:#A5A5A1;
  line-height:1;
  transition:color .3s ease;
}
.bub-pill[aria-current] .bub-t{font-weight:500;}
.bub-pill[aria-current] .bub-n{color:#0B0B0B;}

@media (hover:hover) and (pointer:fine){
  .bub.on .bub-pill:hover{
    background:#0B0B0B;
    border-color:#0B0B0B;
    color:#fff;
    transform:translate(-6px,0) scale(1.03) rotate(0deg);
    transition-delay:0s;
  }
  .bub.on .bub-pill:hover .bub-n,
  .bub.on .bub-pill:hover .bub-e{color:rgba(255,255,255,.5);}
}

/* ---------- 内页补偿顶栏高度 ---------- */
.sh-pad{padding-top:var(--sh-h);}

/* ---------- 中窄屏 ---------- */
@media (max-width:1180px){
  .sh{--sh-h:70px;}
  .sh-logo img{height:28px;}
  .sh-nav{gap:clamp(14px,2vw,26px);}
  .sh-nav a{font-size:14px;}
  .sh-nav a i{font-size:10.5px;}
}

@media (max-width:900px){
  .sh{--sh-h:64px;grid-template-columns:auto 1fr;}
  .sh-logo img{height:26px;}
  .sh-nav{display:none;}
  .bub{justify-self:end;}
  .bub-toggle{width:38px;height:38px;}
  .bub-ic{width:15px;}
  .bub-ic i{width:15px;}
  .bub-ic i:last-child{width:9px;}
  .bub.on .bub-ic i:last-child{width:15px;}
  .bub-list{top:calc(100% + 12px);padding:18px 14px 14px;border-radius:24px;}
  .bub-pill{width:min(78vw,296px);height:54px;padding:0 18px;}
  .bub-t{font-size:16px;}
  .bub-n{font-size:9.5px;}
  .bub-e{font-size:9px;}
  .sh-pad{padding-top:64px;}
}

@media (max-width:420px){
  .sh-logo img{height:22px;}
  .bub-pill{width:min(80vw,296px);height:56px;}
  .bub-t{font-size:16.5px;}
}

/* ---------- 降低动效 ---------- */
@media (prefers-reduced-motion:reduce){
  .bub-pill,.bub-toggle,.bub-ic i,.bub-hd{transition-duration:.01s;}
  .bub.on .bub-pill{transition-delay:0s;}
  .sh-nav a::after{transition:none;}
}

/* ---------- 键盘焦点 ---------- */
.sh-logo:focus-visible,
.sh-nav a:focus-visible,
.bub-toggle:focus-visible,
.bub-pill:focus-visible{
  outline:1px solid #0B0B0B;
  outline-offset:4px;
}
.bub.on .bub-toggle:focus-visible{outline-color:#fff;}
