/* =========================================
   Header 极简磨砂重构版
   ========================================= */
header {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.85), rgba(30, 64, 175, 0.85));
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.2);
  border-radius: 16px;
  color: white;
  padding: 16px 24px;
  position: relative;
  z-index: var(--z-nav);
  margin-bottom: 24px;
}

/* 闪光动画保留 */
header::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-radius: 16px;
  background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.15) 50%, transparent 70%);
  animation: shimmer 3s infinite;
  pointer-events: none;
}
@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* 深色模式保留 */
body.dark-theme header {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.85), rgba(15, 23, 42, 0.85));
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

/* 顶部行布局：标题左，按钮右 */
.header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  gap: 10px;
}

/* 移动端/平板操作区基础设定（防止在断点之间折行） */
.mobile-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

/* 缩小字号，保留渐变文字 */
.site-logo {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 0;
  display: inline-block;
  white-space: nowrap;
  flex-shrink: 0;
  background: linear-gradient(45deg, #fff, #e0e7ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-decoration: none;
  transition: opacity 0.2s;
}
.site-logo:hover { opacity: 0.9; }

/* 删掉废弃的 .logo p 样式 */

/* 恢复右侧三个按钮的磨砂圆形底座 */
.social-icons {
  display: flex;
  gap: 12px;
}

.social-icons a {
  color: white;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

/* 确保内部 SVG 图标大小合适 */
.social-icons a svg {
  width: 20px;
  height: 20px;
}

.social-icons a:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 移动端菜单按钮也保留一下基础设置，虽然目前是桌面端 */
.mobile-menu-toggle {
  display: none; /* 默认隐藏，由媒体查询唤醒 */
  width: 34px;
  height: 34px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  flex-shrink: 0;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.3s ease;
}
.mobile-menu-toggle:hover {
  background: rgba(255, 255, 255, 0.3);
}
.mobile-menu-toggle span {
  width: 18px;
  height: 2px;
  background: white;
  border-radius: 2px;
  display: block;
}


/* header.css —— 从 layout.css 拆出（原第 17-148 行）
   Header + 桌面导航
   拆分日期：2026-10-30 */

/* 桌面导航 */
.main-nav.desktop-nav ul {
  display: flex;
  gap: 2px;
  list-style: none;
  justify-content: center;
  flex-wrap: nowrap; /* 禁止换行 */
}

.main-nav .nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  border-radius: 20px;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 0.95rem;
}

.main-nav .nav-link:hover,
.main-nav .nav-link.active {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}
