/* ============================================================
   Aipod Global Design System v2.0
   统一全局样式 / 响应式 / 设计规范
   ============================================================ */

/* ── 1. 设计变量 ── */
:root {
  --font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'SF Mono', Monaco, Inconsolata, 'Roboto Mono', Consolas, 'Courier New', monospace;
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface2: #f1f5f9;
  --surface3: #e2e8f0;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --text: #1e293b;
  --text-secondary: #64748b;
  --muted: #94a3b8;
  --accent: #0071e3;
  --accent2: #5856d6;
  --accent-hover: #005ac8;
  --accent-light: rgba(0,113,227,0.1);
  --success: #34c759;
  --success-light: rgba(52,199,89,0.1);
  --warning: #ff9500;
  --warning-light: rgba(255,149,0,0.1);
  --danger: #ff3b30;
  --danger-light: rgba(255,59,48,0.1);
  --gold: #ffd60a;
  --max-w: 1440px;
  --content-max: 1200px;
  --nav-h: 64px;
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.25rem;
  --sp-6: 1.5rem;
  --sp-8: 2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;
  --sp-16: 4rem;
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-xl: 16px;
  --r-full: 9999px;
  --t-fast: 0.15s ease;
  --t-normal: 0.25s ease;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
  --shadow-xl: 0 20px 25px rgba(0,0,0,0.15);
}

/* ── 2. 重置 & 基线 ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── 3. 全局容器 ── */
.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--sp-8);
}
.container--wide { max-width: var(--max-w); }
.container--narrow { max-width: 800px; }

.page-wrapper {
  padding: var(--sp-8) 0 var(--sp-16);
}
.section { margin-bottom: var(--sp-12); }
.section--lg { margin-bottom: var(--sp-16); }

/* ── 4. 页面顶部留白 ── */
body > nav ~ * { margin-top: 0; }
main { margin-top: var(--sp-6); }

/* ── 5. 导航栏 ── */
nav {
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 0;
}
nav .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: var(--nav-h);
  gap: var(--sp-4);
  flex-wrap: wrap;
}
.logo-area { display: flex; align-items: center; gap: var(--sp-3); text-decoration: none; flex-shrink: 0; }
.logo-icon { width: 36px; height: 36px; }
.logo-text {
  font-size: 1.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.3px;
}
.nav-links { display: flex; gap: var(--sp-1); list-style: none; flex-wrap: wrap; align-items: center; }
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.875rem;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-md);
  transition: all var(--t-fast);
  white-space: nowrap;
  font-weight: 500;
}
.nav-links a:hover, .nav-links a.active {
  color: var(--accent);
  background: var(--accent-light);
}
.nav-right {
  display: flex;
  gap: var(--sp-3);
  align-items: center;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* ── 6. 下拉菜单 ── */
.dropdown { position: relative; }
.dropdown-toggle { position: relative; padding-right: 1.5rem !important; }
.dropdown-toggle::after {
  content: '▼'; position: absolute; right: 0.4rem; top: 50%;
  transform: translateY(-50%); font-size: 0.65rem; color: var(--muted);
}
.dropdown-menu {
  position: absolute; top: calc(100% + 8px); left: 0;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow-lg);
  min-width: 180px; z-index: 1000;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: all var(--t-normal); pointer-events: none;
  padding: var(--sp-2);
}
.dropdown:hover .dropdown-menu,
.dropdown.open .dropdown-menu {
  opacity: 1; visibility: visible; transform: translateY(0); pointer-events: all;
}
.dropdown-menu li { list-style: none; }
.dropdown-menu a {
  display: block; padding: var(--sp-2) var(--sp-4);
  color: var(--text-secondary); text-decoration: none;
  border-radius: var(--r-sm); font-size: 0.875rem;
  transition: all var(--t-fast); font-weight: 500;
}
.dropdown-menu a:hover { background: var(--accent-light); color: var(--accent); }

/* ── 7. 英雄区 ── */
.hero {
  padding: var(--sp-16) 0;
  text-align: center;
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,113,227,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content { position: relative; z-index: 1; }
.hero-title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.5px;
  color: var(--text);
  margin-bottom: var(--sp-5);
}
.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto var(--sp-8);
  line-height: 1.7;
}
.hero-actions { display: flex; gap: var(--sp-4); justify-content: center; flex-wrap: wrap; margin-bottom: var(--sp-12); }
.hero-stats { display: flex; gap: var(--sp-10); justify-content: center; flex-wrap: wrap; margin-top: var(--sp-8); }
.hero-stat-num { font-size: 1.8rem; font-weight: 800; color: var(--accent); }
.hero-stat-label { font-size: 0.85rem; color: var(--muted); margin-top: 2px; }

/* ── 8. 卡片 ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--t-normal), transform var(--t-normal), border-color var(--t-normal);
}
.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border);
}
.card--flat:hover { box-shadow: var(--shadow-sm); transform: none; }
.card--elevated { box-shadow: var(--shadow-md); }
.card--clickable { cursor: pointer; }
.card--clickable:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

/* 卡片网格 */
.card-grid {
  display: grid;
  gap: var(--sp-6);
}
.card-grid--2 { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.card-grid--3 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.card-grid--4 { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

/* ── 9. 按钮 ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--r-md);
  border: 1.5px solid transparent;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  transition: all var(--t-fast);
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
  flex-shrink: 0;
  min-height: 44px;
  min-width: 44px;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); box-shadow: 0 4px 12px rgba(0,113,227,0.3); }
.btn-outline {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}
.btn-outline:hover { background: var(--accent-light); }
.btn-secondary {
  background: var(--surface2);
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { background: var(--surface3); border-color: var(--muted); }
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--surface2); color: var(--text); }
.btn-sm { padding: var(--sp-2) var(--sp-3); font-size: 0.8rem; border-radius: var(--r-sm); }
.btn-lg { padding: var(--sp-4) var(--sp-8); font-size: 1rem; border-radius: var(--r-lg); }
.btn-icon { width: 36px; height: 36px; padding: 0; border-radius: var(--r-md); }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-danger:hover { background: #e0352b; }
.btn-orange {
  background: var(--warning);
  color: #fff;
  border-color: var(--warning);
}
.btn-orange:hover { background: #e68600; box-shadow: 0 4px 12px rgba(255,149,0,0.35); }

/* ── 10. 表单 ── */
.form-group { margin-bottom: var(--sp-5); }
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: var(--sp-2);
}
.form-input, .form-select, textarea {
  width: 100%;
  padding: var(--sp-3) var(--sp-4);
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text);
  font-size: 0.9rem;
  font-family: var(--font);
  transition: all var(--t-fast);
  outline: none;
  line-height: 1.5;
}
.form-input:focus, .form-select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
  background: var(--surface);
}
.form-input::placeholder { color: var(--muted); }
textarea { resize: vertical; min-height: 100px; }
.form-hint { font-size: 0.8rem; color: var(--muted); margin-top: var(--sp-1); }
.form-error { font-size: 0.8rem; color: var(--danger); margin-top: var(--sp-1); }

/* ── 11. 标签 / Tag ── */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px var(--sp-3);
  border-radius: var(--r-full);
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  border: 1px solid transparent;
}
.tag-primary { background: var(--accent-light); color: var(--accent); border-color: rgba(0,113,227,0.15); }
.tag-success { background: var(--success-light); color: var(--success); border-color: rgba(52,199,89,0.15); }
.tag-warning { background: var(--warning-light); color: var(--warning); border-color: rgba(255,149,0,0.15); }
.tag-danger { background: var(--danger-light); color: var(--danger); border-color: rgba(255,59,48,0.15); }
.tag-muted { background: var(--surface2); color: var(--text-secondary); border-color: var(--border); }
.tag-outline { background: transparent; color: var(--muted); border-color: var(--border); }
.tag-lg { padding: var(--sp-2) var(--sp-4); font-size: 0.85rem; }

/* 分类标签 */
.cat-tag {
  display: inline-flex; align-items: center;
  padding: var(--sp-1) var(--sp-3);
  background: var(--surface2); color: var(--text-secondary);
  border-radius: var(--r-full); font-size: 0.8rem; font-weight: 500;
  border: 1px solid var(--border);
  cursor: pointer; transition: all var(--t-fast);
  white-space: nowrap;
}
.cat-tag:hover, .cat-tag.active {
  background: var(--accent-light); color: var(--accent);
  border-color: rgba(0,113,227,0.2);
}

/* ── 12. 徽章 / Badge ── */
.badge {
  display: inline-flex; align-items: center;
  padding: 2px var(--sp-2);
  border-radius: var(--r-full);
  font-size: 0.7rem; font-weight: 700;
  background: var(--accent); color: #fff;
  letter-spacing: 0.3px;
}
.badge-outline { background: transparent; color: var(--accent); border: 1.5px solid var(--accent); }

/* ── 13. 列表项 ── */
.list-item {
  display: flex; align-items: center; gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--r-md);
  transition: all var(--t-fast);
}
.list-item:hover { border-color: var(--border); box-shadow: var(--shadow-sm); background: var(--surface); }

/* ── 14. 搜索栏 ── */
.search-bar {
  display: flex; gap: var(--sp-3);
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  padding: var(--sp-2) var(--sp-3);
  transition: all var(--t-fast);
}
.search-bar:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}
.search-bar input {
  flex: 1; border: none; outline: none;
  background: transparent; font-size: 0.9rem;
  color: var(--text); font-family: var(--font);
}
.search-bar input::placeholder { color: var(--muted); }
.search-bar .btn { flex-shrink: 0; }

/* ── 15. 筛选栏 ── */
.filter-bar {
  display: flex; gap: var(--sp-3);
  flex-wrap: wrap;
  align-items: center;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: var(--sp-6);
}
.filter-bar select {
  padding: var(--sp-2) var(--sp-4);
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  color: var(--text);
  font-family: var(--font);
  cursor: pointer;
  outline: none;
  transition: all var(--t-fast);
}
.filter-bar select:focus { border-color: var(--accent); }

/* ── 16. 分页 ── */
.pagination {
  display: flex; gap: var(--sp-2);
  justify-content: center;
  align-items: center;
  padding: var(--sp-8) 0 var(--sp-4);
  flex-wrap: wrap;
}
.pagination a, .pagination .page-num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px;
  padding: 0 var(--sp-3);
  border-radius: var(--r-md);
  font-size: 0.875rem; font-weight: 500;
  color: var(--text-secondary);
  background: var(--surface);
  border: 1.5px solid var(--border);
  text-decoration: none;
  transition: all var(--t-fast);
  cursor: pointer;
}
.pagination a:hover, .pagination .page-num:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
.pagination .page-num.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.pagination .page-num.disabled { opacity: 0.4; pointer-events: none; }

/* ── 17. 评分星级 ── */
.rating { display: flex; align-items: center; gap: 2px; }
.rating-star { color: var(--gold); font-size: 0.85rem; }
.rating-star.empty { color: var(--surface3); }
.rating-num { font-size: 0.8rem; color: var(--muted); margin-left: 4px; }

/* ── 18. 价格显示 ── */
.price { font-size: 1.1rem; font-weight: 800; color: var(--accent); }
.price-original { font-size: 0.85rem; color: var(--muted); text-decoration: line-through; margin-left: 4px; }
.price-free { font-size: 0.875rem; font-weight: 700; color: var(--success); }

/* ── 19. 数据统计 ── */
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat-num { font-size: 1.4rem; font-weight: 800; color: var(--text); }
.stat-label { font-size: 0.8rem; color: var(--muted); }
.stat-inline { display: flex; align-items: baseline; gap: 4px; }

/* ── 20. 进度条 ── */
.progress-bar {
  height: 6px; background: var(--surface2);
  border-radius: var(--r-full); overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  border-radius: var(--r-full);
  transition: width 0.4s ease;
}

/* ── 21. 分割线 ── */
.divider { border: none; border-top: 1px solid var(--border-light); margin: var(--sp-6) 0; }

/* ── 22. 模态框 ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000; padding: var(--sp-4);
}
.modal-content {
  background: var(--surface);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-xl);
  max-width: 560px; width: 100%;
  max-height: 90vh; overflow-y: auto;
}
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--sp-6);
  border-bottom: 1px solid var(--border-light);
}
.modal-title { font-size: 1.1rem; font-weight: 700; }
.modal-close {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--surface2); border: none;
  color: var(--muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; transition: all var(--t-fast);
}
.modal-close:hover { background: var(--danger-light); color: var(--danger); }
.modal-body { padding: var(--sp-6); }
.modal-footer {
  display: flex; gap: var(--sp-3); justify-content: flex-end;
  padding: var(--sp-5) var(--sp-6);
  border-top: 1px solid var(--border-light);
}

/* ── 23. 工具提示 ── */
.tooltip {
  position: relative;
}
.tooltip::after {
  content: attr(data-tip);
  position: absolute; bottom: calc(100% + 6px); left: 50%;
  transform: translateX(-50%);
  background: var(--text); color: #fff;
  padding: 4px var(--sp-3); border-radius: var(--r-sm);
  font-size: 0.75rem; white-space: nowrap;
  opacity: 0; visibility: hidden;
  transition: all var(--t-fast);
  pointer-events: none;
  z-index: 200;
}
.tooltip:hover::after { opacity: 1; visibility: visible; }

/* ── 24. 页脚 ── */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: var(--sp-12) 0 var(--sp-8);
  margin-top: var(--sp-16);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--sp-8);
  margin-bottom: var(--sp-8);
}
.footer-brand .logo { display: flex; align-items: center; gap: var(--sp-3); margin-bottom: var(--sp-4); font-size: 1.1rem; font-weight: 700; }
.footer-brand p { color: var(--muted); font-size: 0.875rem; line-height: 1.7; }
.footer-col h4 { font-size: 0.875rem; font-weight: 700; margin-bottom: var(--sp-4); color: var(--text); text-transform: uppercase; letter-spacing: 0.5px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: var(--sp-2); }
.footer-col a { color: var(--muted); text-decoration: none; font-size: 0.875rem; transition: color var(--t-fast); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid var(--border-light); padding-top: var(--sp-6); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: var(--sp-4); color: var(--muted); font-size: 0.8rem; }

/* ── 25. 空状态 ── */
.empty-state {
  text-align: center; padding: var(--sp-16) var(--sp-8);
  color: var(--muted);
}
.empty-state-icon { font-size: 3rem; margin-bottom: var(--sp-4); opacity: 0.5; }
.empty-state h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: var(--sp-2); color: var(--text-secondary); }
.empty-state p { font-size: 0.9rem; max-width: 400px; margin: 0 auto var(--sp-6); }

/* ── 26. 加载动画 ── */
.skeleton {
  background: linear-gradient(90deg, var(--surface2) 25%, var(--surface3) 50%, var(--surface2) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--r-sm);
}
@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── 27. 滚动条美化 ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: var(--r-full); }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }

/* ── 28. 选中文字 ── */
::selection { background: var(--accent-light); color: var(--accent); }

/* ── 29. 标题层级 ── */
h1, h2, h3, h4, h5, h6 { color: var(--text); line-height: 1.3; font-weight: 700; }
h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); letter-spacing: -0.4px; }
h2 { font-size: clamp(1.3rem, 2.5vw, 1.7rem); letter-spacing: -0.3px; }
h3 { font-size: clamp(1.1rem, 2vw, 1.3rem); }
h4 { font-size: 1rem; }
p { color: var(--text-secondary); line-height: 1.7; }
a {
  color: var(--accent);
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
}

/* ── 30. 页面标题区 ── */
.page-header {
  padding: var(--sp-8) 0 var(--sp-6);
  border-bottom: 1px solid var(--border-light);
  margin-bottom: var(--sp-8);
}
.page-header h1 { margin-bottom: var(--sp-2); }
.page-header p { font-size: 0.95rem; }

/* ── 31. 工具栏 ── */
.toolbar {
  display: flex; gap: var(--sp-3);
  align-items: center;
  padding: var(--sp-4) 0;
  flex-wrap: wrap;
}
.toolbar-right { margin-left: auto; }

/* ── 32. 开关 ── */
.toggle {
  position: relative; display: inline-block;
  width: 44px; height: 24px;
}
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute; inset: 0;
  background: var(--border); border-radius: var(--r-full);
  cursor: pointer; transition: all var(--t-normal);
}
.toggle-slider::before {
  content: ''; position: absolute;
  width: 18px; height: 18px; left: 3px; bottom: 3px;
  background: white; border-radius: 50%;
  transition: all var(--t-normal);
}
.toggle input:checked + .toggle-slider { background: var(--accent); }
.toggle input:checked + .toggle-slider::before { transform: translateX(20px); }

/* ── 33. 标签页 ── */
.tabs { display: flex; gap: var(--sp-1); border-bottom: 2px solid var(--border-light); margin-bottom: var(--sp-6); }
.tab-btn {
  padding: var(--sp-3) var(--sp-5);
  font-size: 0.9rem; font-weight: 600;
  color: var(--muted); background: none; border: none;
  cursor: pointer; position: relative;
  transition: all var(--t-fast);
  font-family: var(--font);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
}
.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }

/* ── 34. 通知徽章 ── */
.notif-btn {
  position: relative; width: 36px; height: 36px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: var(--r-md); cursor: pointer; font-size: 1rem;
  text-decoration: none; transition: all var(--t-fast);
  color: var(--muted);
}
.notif-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
.notif-dot {
  position: absolute; top: -4px; right: -4px;
  width: 10px; height: 10px; background: var(--danger);
  border-radius: 50%; border: 2px solid var(--surface);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.8; }
}

/* ── 35. 辅助工具 ── */
.text-accent { color: var(--accent); }
.text-muted { color: var(--muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.font-bold { font-weight: 700; }
.font-mono { font-family: var(--font-mono); }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: var(--sp-2); }
.gap-3 { gap: var(--sp-3); }
.gap-4 { gap: var(--sp-4); }
.gap-6 { gap: var(--sp-6); }
.gap-8 { gap: var(--sp-8); }
.flex-1 { flex: 1; }
.flex-wrap { flex-wrap: wrap; }
.w-full { width: 100%; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ── 36. 响应式滚动容器 ── */
.scroll-container {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.scroll-container::-webkit-scrollbar {
  height: 6px;
}

.scroll-container::-webkit-scrollbar-track {
  background: transparent;
}

.scroll-container::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: var(--r-full);
}

.scroll-container::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}

/* 表格响应式 */
table {
  width: 100%;
  border-collapse: collapse;
}

.table-container {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: var(--sp-4) 0;
}

/* 卡片列表响应式 */
.card-list {
  display: flex;
  gap: var(--sp-4);
  overflow-x: auto;
  padding: var(--sp-2) 0;
  -webkit-overflow-scrolling: touch;
}

.card-list .card {
  flex: 0 0 280px;
  min-width: 280px;
}

/* ── 36. 间距辅助 ── */
.mt-2 { margin-top: var(--sp-2); }
.mt-4 { margin-top: var(--sp-4); }
.mt-6 { margin-top: var(--sp-6); }
.mt-8 { margin-top: var(--sp-8); }
.mb-2 { margin-bottom: var(--sp-2); }
.mb-4 { margin-bottom: var(--sp-4); }
.mb-6 { margin-bottom: var(--sp-6); }
.mb-8 { margin-bottom: var(--sp-8); }
.p-4 { padding: var(--sp-4); }
.p-6 { padding: var(--sp-6); }
.px-4 { padding-left: var(--sp-4); padding-right: var(--sp-4); }
.py-2 { padding-top: var(--sp-2); padding-bottom: var(--sp-2); }
.py-4 { padding-top: var(--sp-4); padding-bottom: var(--sp-4); }

/* ── 37. 响应式断点 ── */
@media (max-width: 1024px) {
  .container { padding: 0 var(--sp-6); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--sp-6); }
  .card-grid--3 { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
}
@media (max-width: 768px) {
  
  .container { padding: 0 var(--sp-4); }
  .nav-links { display: none; }
  .nav-right .lang-switch,
  .nav-right .theme-switch { display: none; }
  .hero { padding: var(--sp-10) 0; }
  .hero-stats { gap: var(--sp-6); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--sp-6); }
  .card-grid--2,
  .card-grid--3,
  .card-grid--4 { grid-template-columns: 1fr; }
  .page-header { padding: var(--sp-6) 0 var(--sp-4); }
  .modal-content { border-radius: var(--r-lg); }
  .hero-actions { flex-direction: column; align-items: center; }
  .filter-bar { gap: var(--sp-2); }
}
@media (max-width: 480px) {
  
  .container { padding: 0 var(--sp-4); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .card { padding: var(--sp-4); }
  .btn-lg { width: 100%; justify-content: center; }
  .search-bar { flex-wrap: wrap; }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .filter-bar select { width: 100%; }
  .pagination { gap: var(--sp-1); }
  .pagination a, .pagination .page-num { min-width: 32px; height: 32px; font-size: 0.8rem; }
  .page-header h1 { font-size: 1.4rem; }
}
