:root { --site-nav-height: 70px; }

/* 官网首页和指南共用顶栏尺寸、按钮样式和移动端菜单。 */
.navbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--site-nav-height);
  line-height: normal;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(0,0,0,0.05);
  z-index: 1000;
  overflow: visible;
}

.navbar .inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 60px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 0;
  text-decoration: none;
  user-select: none;
}
.nav-logo-img {
  height: 32px;
  width: auto;
  display: block;
}

/* Nav links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 40px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-links a {
  font-size: 15px;
  color: #585F69;
  text-decoration: none;
  font-weight: 400;
  transition: color 0.2s;
}

.nav-links a:hover { color: #002448; }

.nav-links li.active a {
  color: #002448;
  font-weight: 500;
}

/* 汉堡按钮 & 用户图标默认桌面端隐藏 */
.mobile-nav-icons { display: none; }
.mobile-menu-btn { display: none; }
.mobile-nav-drawer { display: none; }
.mobile-user-btn { display: none; }

/* 移动端用户图标按钮 */
.mobile-user-btn {
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  flex-shrink: 0;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

/* Nav CTA button */
.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(25deg, #0175FF 0%, #01C4FF 100%);
  color: #fff;
  border: none;
  border-radius: 24px;
  padding: 10px 22px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.15s;
}

.nav-btn.visible { opacity: 1; pointer-events: auto; }
.nav-btn:hover { opacity: 0.9; transform: translateY(-1px); }

/* PC 导航右侧按钮组 */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* 登录/注册按钮 */
.nav-login-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  color: #000;
  border: none;
  padding: 9px 4px;
  font-size: 15px;
  font-weight: 400;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s;
  white-space: nowrap;
}
.nav-login-btn span { color: #000; }
.nav-login-btn:hover { opacity: 0.65; }

/* 平板宽度下压缩导航留白，让新增指南入口与下载按钮保持在同一行。 */
@media (768px < width < 1024px) {
  .navbar .inner { padding: 0 24px; }
  .nav-links { gap: 16px; }
}

@media (max-width: 768px) {
  /* Navbar */
  .nav-links { display: none; }
  .navbar .inner { padding: 0 20px; }
  .nav-btn { display: none; }
  .nav-login-btn { display: none; }
  .nav-actions { display: none; }

  /* 移动端启用汉堡 & 抽屉 & 用户图标 */
  .mobile-nav-icons {
    display: flex;
    align-items: center;
    gap: 4px;
  }
  .mobile-menu-btn { display: flex; }
  .mobile-nav-drawer { display: flex; }
  .mobile-user-btn { display: flex; }

  /* 移动端汉堡菜单 */
  .mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    cursor: pointer;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
  }
  .mobile-menu-btn span {
    display: block;
    width: 18px;
    height: 1.5px;
    background: #002448;
    border-radius: 2px;
    position: relative;
    transition: all 0.25s ease;
  }
  .mobile-menu-btn span::before,
  .mobile-menu-btn span::after {
    content: '';
    display: block;
    width: 18px;
    height: 1.5px;
    background: #002448;
    border-radius: 2px;
    position: absolute;
    left: 0;
    transition: all 0.25s ease;
  }
  .mobile-menu-btn span::before { top: -5px; }
  .mobile-menu-btn span::after  { top: 5px; }

  /* 打开状态：三条变 × */
  .mobile-menu-btn.open span { background: transparent; }
  .mobile-menu-btn.open span::before { top: 0; transform: rotate(45deg); }
  .mobile-menu-btn.open span::after  { top: 0; transform: rotate(-45deg); }

  /* 下拉面板 */
  .mobile-nav-drawer {
    position: fixed;
    top: var(--site-nav-height);
    left: 0; right: 0;
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    z-index: 999;
    display: flex;
    line-height: normal;
    flex-direction: column;
    padding: 8px 20px 20px;
    gap: 0;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.22s ease, opacity 0.22s ease;
  }
  .mobile-nav-drawer.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .mobile-nav-drawer a {
    font-size: 17px;
    font-weight: 400;
    color: #002448;
    text-decoration: none;
    padding: 14px 0;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    display: block;
    transition: color 0.15s;
  }
  .mobile-nav-drawer a:last-child { border-bottom: none; }
  .mobile-nav-drawer a.active { font-weight: 600; color: #0175FF; }
}
