/* =========================================================
   AI 工具导航 · 设计系统
   纯静态 / 零依赖 / 浅色+暗黑双模式 / 响应式
   ========================================================= */

/* ---------- Design Tokens ---------- */
:root {
  --bg: #f5f7fa;
  --bg-elev: #ffffff;
  --bg-soft: #eef2f7;
  --text: #1a2230;
  --text-soft: #5a6577;
  --text-mute: #8b95a5;
  --border: #e3e8ef;
  --primary: #185fa5;
  --primary-soft: #e6f1fb;
  --primary-strong: #0c447c;
  --danger: #c0392b;
  --star: #f4b400;
  --shadow: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-hover: 0 10px 28px rgba(16, 24, 40, .10);
  --radius: 14px;
  --radius-sm: 10px;
  --maxw: 1180px;
  --header-h: 64px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", Roboto, Helvetica, Arial, sans-serif;
}

[data-theme="dark"] {
  --bg: #0e1117;
  --bg-elev: #161b22;
  --bg-soft: #1c232c;
  --text: #e6edf3;
  --text-soft: #aab4c0;
  --text-mute: #7d8694;
  --border: #232b35;
  --primary: #4a9fe0;
  --primary-soft: #14283b;
  --primary-strong: #6cb4ee;
  --danger: #e06b5e;
  --star: #f4c542;
  --shadow: 0 1px 3px rgba(0, 0, 0, .4);
  --shadow-hover: 0 10px 28px rgba(0, 0, 0, .55);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  transition: background .25s ease, color .25s ease;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; font-weight: 600; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: color-mix(in srgb, var(--bg-elev) 88%, transparent);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  height: 100%; display: flex; align-items: center; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; color: var(--text); }
.brand .logo {
  width: 32px; height: 32px; border-radius: 9px;
  background: linear-gradient(135deg, var(--primary), #7f77dd);
  display: grid; place-items: center; color: #fff; font-size: 17px;
}
.brand small { display: block; font-size: 11px; font-weight: 400; color: var(--text-mute); }
.header-nav { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.header-nav a {
  padding: 8px 12px; border-radius: 8px; font-size: 14px; color: var(--text-soft);
  transition: background .15s, color .15s;
}
.header-nav a:hover { background: var(--bg-soft); color: var(--text); }
.theme-toggle {
  width: 38px; height: 38px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text); display: grid; place-items: center; font-size: 16px;
  transition: background .15s, transform .15s;
}
.theme-toggle:hover { background: var(--bg-soft); transform: translateY(-1px); }

/* ---------- World Clock ---------- */
.clock-bar {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.clock-bar .container {
  display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 10px 0;
  font-size: 13px; color: var(--text-soft);
  max-width: none;
}
.clock-item { display: inline-flex; align-items: baseline; gap: 6px; }
.clock-item b { color: var(--text); font-variant-numeric: tabular-nums; font-weight: 600; }
.clock-item .city { color: var(--text-mute); }

/* ---------- Search / Hero ---------- */
.hero-search {
  position: relative;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 45%, #ec4899 100%);
  color: #fff;
  padding: 0 0 50px;
  overflow: hidden;
}
.hero-search::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 15% 85%, rgba(99,102,241,.55) 0%, transparent 40%),
              radial-gradient(circle at 85% 15%, rgba(236,72,153,.45) 0%, transparent 38%),
              radial-gradient(circle at 50% 50%, rgba(255,255,255,.08) 0%, transparent 55%);
  pointer-events: none;
}
.hero-search .container { position: relative; z-index: 1; max-width: var(--maxw); text-align: center; }

/* 顶部通栏导航栏：吸顶固定在最顶端（脱离 hero-search 的 overflow:hidden，sticky 生效） */
.site-topbar {
  position: sticky; top: 0; z-index: 70;
  border-bottom: 1px solid rgba(124, 58, 237, .12);
  background: rgba(255, 247, 255, .92);
  backdrop-filter: saturate(160%) blur(10px);
  box-shadow: 0 4px 20px rgba(79, 70, 229, .10);
}
[data-theme="dark"] .site-topbar {
  background: rgba(23, 20, 48, .82);
  border-bottom-color: rgba(255,255,255,.08);
  box-shadow: 0 4px 20px rgba(0,0,0,.25);
}
.topbar-inner {
  display: flex; align-items: center; gap: 22px;
  height: 68px;
}
.topbar-brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 18px; color: #4c1d95; white-space: nowrap;
}
[data-theme="dark"] .topbar-brand { color: #e9d5ff; }
.topbar-brand .logo {
  width: 34px; height: 34px; border-radius: 9px;
  background: linear-gradient(135deg, #7c3aed, #4f46e5); display: grid; place-items: center; font-size: 18px;
  color: #fff;
}
.top-nav {
  display: flex; align-items: center; gap: 4px; margin-left: 6px; flex: 1; min-width: 0; overflow-x: auto;
  scrollbar-width: none;
}
.top-nav::-webkit-scrollbar { display: none; }
.top-nav a {
  padding: 8px 14px; border-radius: 8px; font-size: 15px; color: #5b21b6;
  white-space: nowrap; transition: background .15s, color .15s;
}
[data-theme="dark"] .top-nav a { color: rgba(255,255,255,.82); }
.top-nav a:hover { background: rgba(124, 58, 237, .10); color: #4c1d95; }
[data-theme="dark"] .top-nav a:hover { background: rgba(255,255,255,.12); color: #fff; }
.topbar-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.tb-btn {
  border: none; cursor: pointer; font-size: 14px; border-radius: 9px;
  background: rgba(124, 58, 237, .10); color: #5b21b6; transition: background .15s, transform .15s;
}
[data-theme="dark"] .tb-btn { background: rgba(255,255,255,.10); color: #fff; }
.tb-btn.icon { width: 38px; height: 38px; font-size: 16px; display: grid; place-items: center; }
.tb-btn.icon:hover { background: rgba(124, 58, 237, .18); color: #4c1d95; }
[data-theme="dark"] .tb-btn.icon:hover { background: rgba(255,255,255,.20); color: #fff; }

/* 语言切换 */
.lang-switch { position: relative; }
.lang-current {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: 9px; border: 1px solid rgba(124, 58, 237, .22);
  background: rgba(124, 58, 237, .08); color: #5b21b6; font-size: 14px; cursor: pointer; white-space: nowrap;
}
[data-theme="dark"] .lang-current { border-color: rgba(255,255,255,.18); background: rgba(255,255,255,.08); color: #fff; }
.lang-current:hover { background: rgba(124, 58, 237, .14); }
[data-theme="dark"] .lang-current:hover { background: rgba(255,255,255,.14); }
.lang-menu {
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 160px;
  background: var(--bg-elev); color: var(--text); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: var(--shadow-hover); padding: 6px; display: none; z-index: 80;
}
.lang-menu.open { display: block; }
.lang-menu button {
  display: block; width: 100%; text-align: left; padding: 9px 12px; border: none; background: transparent;
  color: var(--text); font-size: 14px; border-radius: 8px; cursor: pointer; white-space: nowrap;
}
.lang-menu button:hover { background: var(--bg-soft); color: var(--primary); }
.lang-menu button.active { background: var(--primary-soft); color: var(--primary); font-weight: 600; }

/* Hero 内容区 */
.hero-content { padding: 32px 0 0; }
.hero-title { font-size: 32px; font-weight: 700; margin: 0 0 6px; letter-spacing: .5px; }
.hero-subtitle { font-size: 15px; color: rgba(255,255,255,.85); margin: 0 0 22px; }

/* 白色搜索卡片 */
.hero-card {
  max-width: 820px; margin: 0 auto;
  background: #fff; border-radius: 18px;
  box-shadow: 0 20px 50px rgba(0,0,0,.18);
  padding: 18px 22px 16px;
  text-align: center;
  border: 1px solid #e5e7eb;
}
[data-theme="dark"] .hero-card { background: #1a1730; border-color: rgba(255,255,255,.12); }

/* Tabs（在白色卡片内：默认灰字、激活红色，居中） */
.hero-tabs {
  display: inline-flex; gap: 6px; flex-wrap: wrap;
  margin-bottom: 12px; justify-content: center;
}
.hero-tab {
  padding: 5px 12px; border-radius: 7px; border: 1px solid transparent;
  background: transparent; color: #6b7280;
  font-size: 14px; cursor: pointer; transition: all .15s;
}
.hero-tab:hover { background: #f3f4f6; color: #374151; }
.hero-tab.active { background: #fef2f2; color: #ef4444; border-color: #fecaca; font-weight: 600; }
[data-theme="dark"] .hero-tab { color: #a1a1aa; }
[data-theme="dark"] .hero-tab:hover { background: rgba(255,255,255,.08); color: #fff; }
[data-theme="dark"] .hero-tab.active { background: rgba(239,68,68,.15); color: #f87171; border-color: rgba(239,68,68,.35); }

/* Input（卡片内：透明背景，底部细线分隔） */
.hero-input-wrap {
  position: relative; max-width: 100%; margin: 0 auto;
  background: transparent; border-radius: 12px;
  display: flex; align-items: center; gap: 10px;
  padding: 6px 0;
}
.hero-input {
  flex: 1; border: none; outline: none; padding: 10px 12px;
  font-size: 15px; color: #1f2937; background: transparent;
  text-align: center;
}
[data-theme="dark"] .hero-input { color: #e4e4e7; }
.hero-input::placeholder { color: #9ca3af; text-align: center; }
.hero-search-btn {
  flex: 0 0 46px; width: 46px; height: 40px; border-radius: 10px;
  border: none; background: #ef4444; color: #fff; font-size: 18px;
  display: grid; place-items: center; transition: transform .15s, background .15s;
  box-shadow: 0 4px 12px rgba(239,68,68,.35);
}
.hero-search-btn:hover { background: #dc2626; transform: scale(1.04); }

/* Keywords（卡片内：深色文字，浅灰胶囊，居中） */
.hero-keywords {
  margin-top: 10px; font-size: 13px; color: #6b7280;
  display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap;
  padding-top: 10px; border-top: 1px solid #f3f4f6;
}
[data-theme="dark"] .hero-keywords { color: #a1a1aa; border-top-color: rgba(255,255,255,.08); }
.hero-keywords span { color: #9ca3af; }
.hero-keywords a {
  color: #4b5563; padding: 3px 10px; border-radius: 999px;
  background: #f3f4f6; transition: background .15s, color .15s;
}
.hero-keywords a:hover { background: #e5e7eb; color: #111827; }
[data-theme="dark"] .hero-keywords a { color: #d4d4d8; background: rgba(255,255,255,.08); }
[data-theme="dark"] .hero-keywords a:hover { background: rgba(255,255,255,.14); color: #fff; }

/* legacy */
.search-meta { margin-top: 12px; font-size: 13px; color: var(--text-mute); }

/* ---------- Section ---------- */
.section { padding: 26px 0; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-head h2 { font-size: 19px; }
.section-head .sub { font-size: 13px; color: var(--text-mute); }

/* ---------- Category chips ---------- */
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; }
.chip {
  padding: 7px 14px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text-soft); font-size: 13px;
  transition: all .15s;
}
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.chip .count { opacity: .65; margin-left: 4px; font-size: 11px; }

/* ---------- Card Grid ---------- */
.grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(248px, 1fr));
}
.card, .tool-card {
  position: relative; display: flex; gap: 14px; padding: 16px;
  background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card:hover, .tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: color-mix(in srgb, var(--primary) 40%, var(--border)); }
.card-icon, .tc-icon, .hot-card .hc-icon {
  flex: 0 0 46px; width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center; font-size: 22px;
  background: var(--primary-soft); color: var(--primary-strong);
}
.card-body, .tc-body { min-width: 0; flex: 1; }
.card-title, .tc-name { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 6px; line-height: 1.35; word-break: break-all; }
.card-title a, .tc-name { color: var(--text); }
.card-title a:hover, .tool-card:hover .tc-name { color: var(--primary); }
.card-desc, .tc-desc {
  font-size: 13px; color: var(--text-soft); margin-top: 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-tags, .tc-tags { margin-top: 9px; display: flex; flex-wrap: wrap; gap: 6px; }
.tag, .tc-tag { font-size: 11px; color: var(--text-mute); background: var(--bg-soft); padding: 2px 8px; border-radius: 6px; }
.fav-btn {
  position: absolute; top: 12px; right: 12px; width: 30px; height: 30px;
  border-radius: 8px; border: 1px solid var(--border); background: var(--bg-elev);
  color: var(--text-mute); font-size: 15px; line-height: 1; display: grid; place-items: center;
  transition: all .15s;
}
.fav-btn:hover { color: var(--star); border-color: var(--star); }
.fav-btn.on { color: var(--star); border-color: var(--star); background: color-mix(in srgb, var(--star) 12%, var(--bg-elev)); }

/* ---------- Detail page ---------- */
.detail-hero { padding: 40px 0 10px; }
.detail-card {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); margin-top: 16px;
}
.detail-card .card-icon { width: 64px; height: 64px; font-size: 30px; flex: none; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 11px 20px; border-radius: 10px;
  background: var(--primary); color: #fff; font-size: 14px; font-weight: 500;
  border: 1px solid var(--primary); transition: opacity .15s, transform .15s;
}
.btn:hover { opacity: .92; transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn.ghost:hover { background: var(--bg-soft); }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: 13px; color: var(--text-mute); padding: 18px 0 0; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { margin: 0 6px; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 56px; border-top: 1px solid var(--border); background: var(--bg-soft);
  padding: 36px 0 28px; font-size: 14px; color: var(--text-soft);
}
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 28px; }
.footer-grid h4 { font-size: 14px; color: var(--text); margin-bottom: 12px; }
.footer-grid a { display: block; padding: 4px 0; color: var(--text-soft); }
.footer-grid a:hover { color: var(--primary); }
.footer-bottom {
  margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 13px; color: var(--text-mute);
}

/* ---------- Empty state ---------- */
.empty { text-align: center; padding: 60px 0; color: var(--text-mute); }
.empty .big { font-size: 40px; margin-bottom: 10px; }

/* ---------- Prose (about/privacy) ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: 20px; margin: 28px 0 10px; }
.prose p, .prose li { color: var(--text-soft); }
.prose ul { padding-left: 20px; list-style: disc; }
.prose li { margin: 6px 0; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 30px; transform: translateX(-50%) translateY(20px);
  background: var(--text); color: var(--bg-elev); padding: 10px 18px; border-radius: 10px;
  font-size: 14px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 100;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 首页三栏布局（左侧导航 + 右侧内容包裹） ---------- */
.page-root { display: block; }
/* 通栏 Hero 之下的主体行：左侧栏 + 右侧内容 */
.body-row { display: flex; align-items: flex-start; min-height: 100vh; }

/* 左侧固定导航栏：吸顶时避开顶部通栏（68px），钉在通栏正下方 */
.left-sidebar {
  position: sticky; top: 68px; z-index: 45;
  flex: 0 0 230px; width: 230px; align-self: flex-start;
  height: calc(100vh - 68px); overflow-y: auto;
  background: var(--bg-elev); border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  padding: 18px 14px 14px;
}

/* 右侧内容包裹：世界时钟 + 热门通栏 + 下栏（主栏 + 右侧栏） */
.main-right-wrap {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column;
  padding: 0 20px;
}

/* 无左侧边栏页面：主内容向左扩展至原来侧边栏位置 */
.body-row.no-leftnav { display: flex; }
.body-row.no-leftnav .main-right-wrap { flex: 1; width: 100%; }

/* 下栏：主内容 + 右侧信息栏 */
.sub-body {
  display: flex; align-items: flex-start; gap: 24px;
}
.left-brand {
  display: flex; align-items: center; gap: 10px; padding: 0 4px 16px;
  border-bottom: 1px solid var(--border); margin-bottom: 14px;
}
.left-brand .logo {
  width: 38px; height: 38px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), #7f77dd);
  display: grid; place-items: center; color: #fff; font-size: 20px;
}
.left-brand strong { display: block; font-size: 15px; color: var(--text); }
.left-brand small { display: block; font-size: 11px; color: var(--text-mute); }

.search-sidebar { position: relative; margin-bottom: 12px; }
.search-sidebar input {
  width: 100%; padding: 10px 10px 10px 34px; font-size: 14px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--bg-soft);
  color: var(--text);
}
.search-sidebar input:focus { outline: none; border-color: var(--primary); }
.search-sidebar .icon-search {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  color: var(--text-mute); font-size: 15px;
}

.left-nav { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; }
.left-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px; border-radius: 10px; font-size: 14px;
  color: var(--text-soft); transition: all .15s;
}
.left-nav a:hover { background: var(--bg-soft); color: var(--text); }
.left-nav a.active { background: var(--primary-soft); color: var(--primary); font-weight: 500; }
.left-nav .nav-icon { width: 22px; text-align: center; }

.left-bottom {
  margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--border);
  display: flex; align-items: center; gap: 8px;
}
.left-bottom a { font-size: 13px; color: var(--text-mute); }
.left-bottom a:hover { color: var(--primary); }

.left-toggle {
  display: none; position: fixed; left: 14px; bottom: 18px; z-index: 70;
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text); box-shadow: var(--shadow-hover);
}

/* 右侧主区域 */
.right-pane { flex: 1; min-width: 0; }

/* 移动端顶部条 */
.mobile-bar {
  display: none; align-items: center; gap: 10px;
  height: 56px; padding: 0 16px;
  background: var(--bg-elev); border-bottom: 1px solid var(--border);
}
.mobile-menu-btn {
  width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--bg-soft); color: var(--text);
}
.mobile-brand { flex: 1; font-weight: 600; font-size: 15px; }

/* 主内容栏 */
.main-area {
  padding-top: 22px; padding-bottom: 10px;
}

/* 右侧信息栏：吸顶时避开顶部通栏（68px）+ 留白 */
.right-sidebar {
  position: sticky; top: 82px;
  width: 300px; flex-shrink: 0;
  display: flex; flex-direction: column; gap: 18px;
}

/* 主栏：热门 AI 工具横卡网格（截图红框同款） */
.hot-main { padding-top: 22px; margin-bottom: 28px; }
.hot-main .section-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px; gap: 12px; flex-wrap: wrap;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.hot-main .section-head h2 { font-size: 18px; }

/* 截图同款点分隔标签页 */
.dot-tabs { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.dot-tabs .dot {
  color: var(--text-mute); font-size: 12px; padding: 0 2px; user-select: none;
}
.dot-tabs .tab {
  padding: 4px 10px; border-radius: 6px; border: none;
  background: transparent; color: var(--text-soft); font-size: 13px; cursor: pointer;
  transition: all .15s; white-space: nowrap;
}
.dot-tabs .tab:hover { color: var(--primary); background: var(--bg-soft); }
.dot-tabs .tab.active { color: var(--primary); background: var(--bg-soft); font-weight: 600; }

/* 6 列横卡网格 */
.hot-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}
.hot-card {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 12px; background: var(--bg-elev);
  border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform .15s, border-color .15s, box-shadow .15s;
}
.hot-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--primary) 40%, var(--border));
  box-shadow: var(--shadow-hover);
}
.hot-card .card-icon, .hot-card .hc-icon {
  flex: 0 0 42px; width: 42px; height: 42px;
  border-radius: 10px; font-size: 20px;
}
.hot-card .hc-body { min-width: 0; flex: 1; }
.hot-card .hc-title, .hot-card .hc-name {
  font-size: 14px; font-weight: 600; color: var(--text);
  line-height: 1.35; word-break: break-all;
}
.hot-card .hc-title a, .hot-card .hc-name { color: var(--text); }
.hot-card .hc-title a:hover, .hot-card:hover .hc-name { color: var(--primary); }
.hot-card .hc-desc {
  font-size: 12px; color: var(--text-soft); margin-top: 3px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* 加载更多 */
.load-more-wrap { text-align: center; margin-top: 18px; }
.btn-load-more {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 22px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--bg-elev); color: var(--text-soft); font-size: 13px; cursor: pointer;
  transition: all .15s;
}
.btn-load-more:hover { border-color: var(--primary); color: var(--primary); background: var(--bg-soft); }
.btn-load-more:disabled { opacity: .55; cursor: default; }
.btn-load-more::after { content: "›"; font-size: 14px; }

/* 右侧栏：AI 工具导航（全部分类） */
.nav-cat-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.nav-cat-list a {
  display: flex; align-items: center; gap: 6px; font-size: 13px;
  padding: 8px 10px; border: 1px solid var(--border); border-radius: 9px;
  color: var(--text-soft); background: var(--bg-soft); transition: all .15s;
}
.nav-cat-list a:hover { border-color: var(--primary); color: var(--primary); }
.nav-cat-list a .n { margin-left: auto; font-size: 11px; color: var(--text-mute); }

/* 站点资料卡 */
.profile-card .profile-head { display: flex; align-items: center; gap: 12px; }
.profile-head .logo {
  width: 48px; height: 48px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #7f77dd);
  display: grid; place-items: center; color: #fff; font-size: 24px;
}
.profile-head h3 { font-size: 15px; margin: 0; }
.profile-head p { font-size: 12px; color: var(--text-mute); margin: 2px 0 0; }
.stats-row {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  text-align: center; margin-top: 14px; padding-top: 14px;
  border-top: 1px solid var(--border);
}
.stats-row b { display: block; font-size: 18px; color: var(--primary); line-height: 1.1; }
.stats-row span { display: block; font-size: 11px; color: var(--text-mute); margin-top: 3px; }

/* 板块（每个分类一块） */
.board { margin-bottom: 28px; scroll-margin-top: 14px; }
.board-head {
  display: flex; align-items: baseline; gap: 10px;
  padding-bottom: 11px; margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.board-head .bi { font-size: 20px; line-height: 1; }
.board-head h2 { font-size: 18px; }
.board-head .en {
  font-size: 11px; letter-spacing: .6px; text-transform: uppercase;
  color: var(--text-mute); font-weight: 500;
}
.board-head .cnt { font-size: 12px; color: var(--text-mute); }
.board-head .more {
  margin-left: auto; font-size: 13px; color: var(--primary); white-space: nowrap;
}
.board-head .more:hover { text-decoration: underline; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 10px; flex-wrap: wrap; }
.section-head h2 { font-size: 18px; }
.section-head .more { font-size: 13px; color: var(--primary); }

/* 右侧栏小组件 */
.side-widget {
  background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow);
}
.side-widget h3 {
  font-size: 14px; margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
}
.side-widget h3::before {
  content: ""; width: 3px; height: 14px; border-radius: 2px;
  background: var(--primary); display: inline-block;
}
.cat-list { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-list a {
  font-size: 13px; padding: 6px 11px; border: 1px solid var(--border);
  border-radius: 8px; color: var(--text-soft); background: var(--bg-soft);
  transition: all .15s;
}
.cat-list a:hover { border-color: var(--primary); color: var(--primary); }
.rank-list { display: flex; flex-direction: column; }
.rank-item {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 2px; border-bottom: 1px dashed var(--border);
}
.rank-item:last-child { border-bottom: none; }
.rank-no {
  flex: 0 0 22px; height: 22px; border-radius: 6px;
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
  background: var(--bg-soft); color: var(--text-mute);
}
.rank-item:nth-child(1) .rank-no { background: var(--star); color: #fff; }
.rank-item:nth-child(2) .rank-no { background: #9aa7b5; color: #fff; }
.rank-item:nth-child(3) .rank-no { background: #c08457; color: #fff; }
.rank-name {
  font-size: 13px; color: var(--text); flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rank-name:hover { color: var(--primary); }
.rank-name .rk-cat { display: block; font-size: 11px; color: var(--text-mute); }
.friend-links { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.friend-links a { font-size: 13px; color: var(--text-soft); }
.friend-links a:hover { color: var(--primary); }

/* 右侧栏：热点资讯 / 学习教程 */
.post-list { display: flex; flex-direction: column; gap: 10px; }
.post-item {
  display: flex; flex-direction: column; gap: 4px; padding: 10px 12px;
  border-radius: 10px; background: var(--bg-soft); transition: background .15s;
}
.post-item:hover { background: var(--primary-soft); }
.post-title {
  font-size: 13px; color: var(--text); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; text-overflow: ellipsis;
}
.post-item:hover .post-title { color: var(--primary); }
.post-date { font-size: 11px; color: var(--text-mute); }

/* 标签云 */
.tag-cloud-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; gap: 10px;
}
.tag-cloud-head h3 { margin-bottom: 0; }
.refresh-tags {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--bg-soft); color: var(--text-soft); font-size: 14px; cursor: pointer;
  display: grid; place-items: center; transition: all .2s;
}
.refresh-tags:hover { background: var(--primary-soft); color: var(--primary); transform: rotate(180deg); }
.tag-cloud {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}
.tag-item {
  font-size: 13px; padding: 7px 11px; border-radius: 20px; border: 1px solid transparent;
  transition: transform .12s, filter .12s; line-height: 1;
}
.tag-item:hover { transform: translateY(-1px); filter: brightness(0.98); }
.tag-item span { opacity: .75; font-size: 11px; margin-left: 2px; }

/* ---------- Responsive ---------- */
@media (max-width: 1140px) {
  .hot-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 1060px) {
  .sub-body { flex-direction: column; }
  .right-sidebar { position: static; width: 100%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .right-sidebar .profile-card { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .left-sidebar {
    position: fixed; top: 0; left: 0; z-index: 90;
    transform: translateX(-100%);
    box-shadow: 4px 0 24px rgba(0,0,0,.12);
    transition: transform .25s ease;
  }
  .left-sidebar.open { transform: translateX(0); }
  .left-toggle { display: grid; place-items: center; }
  .body-row { display: block; }
  .body-row.no-leftnav { display: block; }
  .main-right-wrap { padding: 0 16px; }
  .body-row.no-leftnav .main-right-wrap { padding: 0 16px; }
  .right-pane { margin-left: 0; }
  .mobile-bar { display: flex; position: sticky; top: 58px; z-index: 56; }
  .clock-bar { position: sticky; top: 58px; z-index: 50; }
  .sub-body { flex-direction: column; gap: 18px; }
  .right-sidebar { position: static; width: 100%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .right-sidebar .profile-card { grid-column: 1 / -1; }
  .hot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .header-nav a:not(.always) { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .clock-bar .container { gap: 6px 14px; font-size: 12px; justify-content: center; }
  .right-sidebar { grid-template-columns: 1fr; }
  .hot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .hot-card { padding: 9px 10px; }
  .hot-card .card-icon { flex: 0 0 36px; width: 36px; height: 36px; font-size: 17px; }
  .section-head { gap: 8px; }
  .topbar-inner { height: 58px; gap: 10px; }
  .topbar-brand span:last-child { display: none; }
  .top-nav a { padding: 7px 10px; font-size: 13px; }
  .tb-btn.member { display: none; }
  .hero-content { padding-top: 30px; }
  .hero-search { padding-bottom: 40px; }
  .lang-current { padding: 7px 10px; font-size: 13px; }
}
@media (max-width: 460px) {
  .grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hot-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   栏目页（测评 / 资讯 / 教程）内容列表
   ========================================================= */
.page-layout {
  display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start;
}
.page-content { min-width: 0; }
.page-head { margin-bottom: 18px; }
.page-head h1 { font-size: 24px; margin: 0 0 6px; }
.page-head p { color: var(--text-soft); font-size: 14px; margin: 0; }

/* 顶部 Tab */
.page-tabs {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px;
}
.page-tab {
  padding: 7px 16px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text-soft); font-size: 14px; cursor: pointer;
  transition: all .15s;
}
.page-tab:hover { border-color: var(--primary); color: var(--primary); }
.page-tab.active { background: #ef4444; border-color: #ef4444; color: #fff; font-weight: 600; }

/* 文章卡片网格 */
.post-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px;
}
/* 文章卡片（栏目页 / 相关文章，由 g_postCard 生成 .article-card） */
.article-card {
  display: flex; gap: 14px; padding: 14px;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s;
  animation: fadeUp .35s ease both;
}
.article-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.ac-cover {
  flex: 0 0 120px; height: 90px; border-radius: 10px;
  display: grid; place-items: center; font-size: 36px; text-decoration: none;
  background: var(--bg-soft); color: var(--primary);
  transition: transform .18s; overflow: hidden;
}
.ac-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article-card:hover .ac-cover { transform: scale(1.02); }
.ac-body { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.ac-title { font-size: 15px; font-weight: 600; line-height: 1.4; margin: 0 0 6px; }
.ac-title a { color: var(--text); }
.ac-title a:hover { color: var(--primary); }
.ac-summary {
  font-size: 13px; color: var(--text-soft); line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; margin-bottom: 8px; flex: 1;
}
.ac-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.pc-tag {
  font-size: 11px; padding: 2px 8px; border-radius: 5px;
  background: var(--bg-soft); color: var(--text-mute);
}
.ac-meta {
  display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--text-mute);
}
.ac-meta span:first-child { margin-right: auto; }

/* 栏目页右侧栏 */
.page-sidebar { position: sticky; top: 82px; display: flex; flex-direction: column; gap: 18px; }
.page-profile-card {
  padding: 18px; border-radius: var(--radius);
  background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 55%, #ec4899 100%);
  color: #fff;
}
.pp-head { display: flex; align-items: center; gap: 12px; }
.pp-logo {
  width: 46px; height: 46px; border-radius: 12px;
  background: rgba(255,255,255,.18); display: grid; place-items: center; font-size: 24px;
}
.page-profile-card h4 { font-size: 16px; margin: 0 0 2px; }
.page-profile-card p { font-size: 12px; margin: 0; opacity: .85; }

/* 统计网格 */
.stat-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 14px !important;
}
.stat-grid > div {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 12px 6px; border-radius: 10px; background: var(--bg-soft); text-align: center;
}
.stat-grid b { font-size: 20px; color: var(--text); }
.stat-grid span { font-size: 11px; color: var(--text-mute); margin-top: 2px; }

/* 热门网址 */
.hot-links { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.hot-links a {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px;
  border-radius: 8px; background: var(--bg-soft); color: var(--text-soft);
  font-size: 13px; transition: all .15s;
}
.hot-links a:hover { background: var(--primary-soft); color: var(--primary); }
.hl-icon { font-size: 16px; }

/* 栏目页响应式 */
@media (max-width: 1060px) {
  .page-layout { grid-template-columns: 1fr; }
  .page-sidebar { position: static; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .page-sidebar .side-widget { margin: 0; }
  .page-sidebar .page-profile-card { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .post-grid { grid-template-columns: 1fr; }
  .ac-cover { flex: 0 0 100px; height: 80px; font-size: 28px; }
  .page-sidebar { grid-template-columns: 1fr; }
}

/* ---------- 文章详情页（由 g_pagePost 生成） ---------- */
.article-detail { min-width: 0; }
.ap-title { font-size: 26px; line-height: 1.3; margin: 4px 0 12px; word-break: break-word; }
.ap-meta {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center;
  font-size: 13px; color: var(--text-mute); margin-bottom: 18px;
  padding-bottom: 14px; border-bottom: 1px solid var(--border);
}
.ap-cover { margin: 6px 0 22px; border-radius: 14px; overflow: hidden; }
.ap-cover-img { width: 100%; max-height: 440px; object-fit: cover; display: block; }
.ap-cover-emoji {
  height: 200px; display: grid; place-items: center; font-size: 84px;
  background: linear-gradient(135deg, rgba(124,58,237,.12), rgba(236,72,153,.12));
  border-radius: 14px;
}
.ap-content { max-width: 860px; font-size: 15px; line-height: 1.85; }
.ap-content img { max-width: 100%; border-radius: 10px; margin: 14px 0; }
.ap-content h2 { font-size: 21px; margin: 30px 0 12px; }
.ap-content h3 { font-size: 18px; margin: 24px 0 10px; }
.ap-content p { margin: 12px 0; color: var(--text-soft); }
.ap-content ul, .ap-content ol { padding-left: 22px; margin: 12px 0; color: var(--text-soft); }
.ap-content li { margin: 6px 0; }
.ap-content a { color: var(--primary); text-decoration: underline; }
.ap-content pre, .ap-content code {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 8px; padding: 2px 6px; font-size: 13px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.ap-content pre { padding: 14px; overflow-x: auto; line-height: 1.6; }
.ap-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 10px; }
.ap-tags .tag-pill { font-size: 13px; }
.ap-share {
  margin-top: 14px; padding: 12px 14px; border-radius: 10px;
  background: var(--bg-soft); font-size: 13px; color: var(--text-soft);
}
.ap-share code {
  background: var(--bg-elev); padding: 2px 8px; border-radius: 6px;
  border: 1px solid var(--border); color: var(--primary); margin-left: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.related { margin-top: 6px; }

/* ---------- 站点详情页（site-{id}.html） ---------- */
.site-detail { min-width: 0; }
.sd-hero {
  display: flex; gap: 22px; padding: 22px; border-radius: 16px;
  background: var(--bg-elev); border: 1px solid var(--border); margin-bottom: 22px;
}
.sd-hero-icon {
  flex: 0 0 90px; width: 90px; height: 90px; border-radius: 18px;
  display: grid; place-items: center; font-size: 48px;
  background: linear-gradient(135deg, rgba(124,58,237,.12), rgba(236,72,153,.12));
}
.sd-hero-body { flex: 1; min-width: 0; }
.sd-title { font-size: 28px; line-height: 1.25; margin: 0 0 10px; word-break: break-word; }
.sd-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px;
  font-size: 13px; color: var(--text-mute); margin-bottom: 10px;
}
.sd-updated { color: var(--text-soft); }
.sd-headline { font-size: 16px; color: var(--text-soft); margin: 10px 0 12px; }
.sd-info { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-bottom: 12px; font-size: 13px; }
.sd-label { color: var(--text-mute); }
.sd-value { color: var(--text); font-weight: 500; }
.sd-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.sdp-tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 5px 12px; border-radius: 20px; font-size: 13px;
  background: var(--bg-soft); color: var(--primary); border: 1px solid var(--border);
}
.sd-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.sd-actions .btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 22px;
  border-radius: 10px; font-size: 14px; font-weight: 600; text-decoration: none;
  transition: transform .15s, box-shadow .15s;
}
.sd-actions .btn-primary {
  background: linear-gradient(135deg, var(--primary), #ec4899);
  color: #fff; box-shadow: 0 6px 18px rgba(124,58,237,.25);
}
.sd-actions .btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(124,58,237,.32); }
.sd-actions .btn-outline {
  background: var(--bg-elev); color: var(--primary); border: 1px solid var(--primary);
}
.sd-actions .btn-outline:hover { background: var(--primary-soft); }

.sd-section { margin-bottom: 24px; }
.sd-section-title {
  font-size: 18px; font-weight: 600; margin: 0 0 14px;
  display: flex; align-items: center; gap: 8px;
}
.sd-section-title::before {
  content: ""; width: 5px; height: 18px; border-radius: 3px;
  background: linear-gradient(180deg, var(--primary), #ec4899);
}
.sd-modules, .sd-content {
  background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px; font-size: 15px; line-height: 1.8;
}
.sd-modules p, .sd-content p { margin: 10px 0; color: var(--text-soft); }
.sd-modules img, .sd-content img { max-width: 100%; border-radius: 10px; margin: 12px 0; }
.sd-modules a, .sd-content a { color: var(--primary); text-decoration: underline; }
.sd-modules h2, .sd-content h2 { font-size: 20px; margin: 22px 0 10px; }
.sd-modules h3, .sd-content h3 { font-size: 17px; margin: 18px 0 8px; }
.sd-modules ul, .sd-content ul, .sd-modules ol, .sd-content ol { padding-left: 22px; margin: 12px 0; color: var(--text-soft); }
.sd-modules li, .sd-content li { margin: 6px 0; }
.sd-modules pre, .sd-content pre, .sd-modules code, .sd-content code {
  background: var(--bg-soft); border: 1px solid var(--border); border-radius: 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px;
}
.sd-modules code, .sd-content code { padding: 2px 6px; }
.sd-modules pre, .sd-content pre { padding: 14px; overflow-x: auto; }

.rel-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px;
}
.rel-tool-card {
  display: flex; align-items: flex-start; gap: 12px; padding: 14px;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: 12px;
  text-decoration: none; transition: transform .15s, box-shadow .15s;
}
.rel-tool-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(60,40,120,.08); border-color: var(--primary-soft); }
.rtc-icon {
  flex: 0 0 44px; width: 44px; height: 44px; border-radius: 10px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, rgba(124,58,237,.1), rgba(236,72,153,.1));
}
.rtc-body { flex: 1; min-width: 0; }
.rtc-name { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rtc-desc { font-size: 12px; color: var(--text-soft); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rtc-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.rtc-tag { font-size: 11px; padding: 2px 7px; border-radius: 5px; background: var(--bg-soft); color: var(--text-mute); }

@media (max-width: 720px) {
  .sd-hero { flex-direction: column; align-items: flex-start; }
  .sd-hero-icon { flex: 0 0 70px; width: 70px; height: 70px; font-size: 36px; }
  .sd-title { font-size: 22px; }
  .rel-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- 广告位（后台「广告管理」粘贴任意联盟代码，生成器原样输出） ---------- */
.ad-slot { margin: 18px 0; }
.ad-slot:empty { display: none; }
.ad-top { margin: 0 0 18px; }
.ad-inline { margin: 20px 0; }
.ad-footer { margin: 22px 0 0; }
.ad-sidebar_top, .ad-sidebar_bot { margin: 0 0 4px; }
.ad-slot ins, .ad-slot iframe, .ad-slot img, .ad-slot > div { max-width: 100%; }

/* =========================================================
   响应式增强（Mobile / Tablet / Desktop 自适应）
   ========================================================= */

/* 宽屏微调 */
@media (max-width: 1400px) {
  .hot-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 1200px) {
  .hot-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .grid { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
}

/* 平板横屏 / 小桌面 */
@media (max-width: 1060px) {
  .sub-body { flex-direction: column; }
  .right-sidebar { position: static; width: 100%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .right-sidebar .profile-card { grid-column: 1 / -1; }
  .page-layout { grid-template-columns: 1fr; }
  .page-sidebar { position: static; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .page-sidebar .side-widget { margin: 0; }
  .page-sidebar .page-profile-card { grid-column: 1 / -1; }
}

/* 平板竖屏：隐藏左侧边栏，显示移动端菜单 */
@media (max-width: 860px) {
  .left-sidebar {
    position: fixed; top: 0; left: 0;
    transform: translateX(-100%);
    box-shadow: 4px 0 24px rgba(0,0,0,.12);
    transition: transform .25s ease;
    z-index: 100;
  }
  .left-sidebar.open { transform: translateX(0); }
  .left-toggle { display: grid; place-items: center; }
  .body-row { display: block; }
  .main-right-wrap { padding: 0 14px; }
  .right-pane { margin-left: 0; }
  .mobile-bar { display: flex; position: sticky; top: 58px; z-index: 56; }
  .clock-bar { position: sticky; top: 58px; z-index: 50; }
  .sub-body { flex-direction: column; gap: 18px; }
  .right-sidebar { position: static; width: 100%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .right-sidebar .profile-card { grid-column: 1 / -1; }
  .hot-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .container { padding: 0 14px; }
  .site-footer { padding: 28px 0; }
  .page-main { padding-top: 14px !important; }
  .page-content .breadcrumb { padding-top: 8px; }
}

/* 移动端 */
@media (max-width: 720px) {
  .topbar-inner { height: 58px; gap: 10px; }
  .topbar-brand span:last-child { display: none; }
  .top-nav a { padding: 7px 10px; font-size: 13px; }
  .tb-btn.member { display: none; }
  .hero-content { padding-top: 26px; }
  .hero-search { padding-bottom: 36px; }
  .hero-title { font-size: 26px; }
  .hero-card { padding: 14px 16px 14px; }
  .lang-current { padding: 7px 10px; font-size: 13px; }
  .hot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .clock-bar .container { gap: 6px 14px; font-size: 12px; justify-content: center; }
  .right-sidebar { grid-template-columns: 1fr; }
  .page-sidebar { grid-template-columns: 1fr; }
  .hot-card { padding: 9px 10px; }
  .hot-card .card-icon, .hot-card .hc-icon { flex: 0 0 36px; width: 36px; height: 36px; font-size: 17px; }
  .section-head { gap: 8px; }
  .board-head { flex-wrap: wrap; gap: 6px 10px; }
  .board-head .more { margin-left: 0; }
  .article-card { gap: 12px; padding: 12px; }
  .ac-cover { flex: 0 0 96px; height: 72px; font-size: 28px; }
  .ap-title { font-size: 22px; }
  .ap-meta { gap: 10px 14px; }
  .ap-cover-emoji { height: 160px; font-size: 64px; }
  .ap-content { font-size: 15px; }
}

/* 小屏手机 */
@media (max-width: 480px) {
  .container { padding: 0 12px; }
  .main-right-wrap { padding: 0 12px; }
  .hot-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .grid { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: 1fr; }
  .hero-tabs { gap: 4px; }
  .hero-tab { padding: 4px 9px; font-size: 13px; }
  .hero-keywords a { padding: 2px 8px; font-size: 12px; }
  .article-card { flex-direction: column; gap: 10px; }
  .ac-cover { flex: none; width: 100%; height: 140px; }
  .page-tabs { gap: 6px; }
  .page-tab { padding: 6px 12px; font-size: 13px; }
  .left-sidebar { width: 260px; flex: 0 0 260px; }
}

/* 左侧边栏遮罩：仅在移动端通过 JS 给 body 添加 .sidebar-open 时显示 */
body.sidebar-open::before {
  content: "";
  position: fixed; inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 99;
  pointer-events: auto;
}

/* 左侧边栏内部关闭按钮（移动端可见） */
.left-close {
  display: none;
  position: absolute; top: 12px; right: 12px;
  width: 32px; height: 32px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--bg-soft);
  color: var(--text); font-size: 18px; line-height: 1;
  align-items: center; justify-content: center;
}
@media (max-width: 860px) {
  .left-close { display: flex; }
}

/* =========================================================
   AGENT / SKILL 专题页（agents.html）
   参考 Skill 详情页布局：大标题-英文副标题-Tagline-
   为什么值得看-项目说明预览框-步骤-同类推荐
   ========================================================= */
.skill-page { display: flex; flex-direction: column; gap: 28px; }

/* SKILL 列表页：卡片网格 */
.skill-list-head { padding-bottom: 8px; }
.skill-list-head h1 {
  font-size: 34px; line-height: 1.15; margin: 10px 0 8px;
  color: var(--text);
}
.skill-list-desc {
  font-size: 15px; color: var(--text-soft); line-height: 1.7;
  margin: 0; max-width: 760px;
}
.skill-search { margin: 22px 0 4px; }
.skill-search-inner {
  position: relative; display: flex; align-items: center;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: var(--shadow);
  padding: 4px 6px 4px 4px;
  transition: border-color .15s, box-shadow .15s;
}
.skill-search-inner:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(124,58,237,.10), var(--shadow);
}
.skill-search-icon {
  flex: 0 0 auto; display: grid; place-items: center;
  width: 38px; height: 38px; font-size: 16px; line-height: 1;
  color: var(--text-mute); pointer-events: none;
}
.skill-search input {
  flex: 1; min-width: 0; padding: 12px 16px 12px 6px;
  font-size: 15px; line-height: 1.4;
  color: var(--text); background: transparent;
  border: none; outline: none;
}
.skill-search input::placeholder { color: var(--text-mute); opacity: .85; }
.skill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 18px;
}
.skill-card {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px;
  text-decoration: none; color: inherit;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.skill-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary-soft);
}
.skill-card-head {
  display: flex; align-items: center; gap: 12px;
}
.skill-card-icon {
  flex: 0 0 44px; width: 44px; height: 44px; border-radius: 10px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, rgba(124,58,237,.1), rgba(236,72,153,.1));
}
.skill-card-title {
  font-size: 16px; font-weight: 700; color: var(--text);
  line-height: 1.35;
}
.skill-card-en {
  font-size: 12px; color: var(--text-mute);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.skill-card-tagline {
  font-size: 14px; color: var(--text-soft); line-height: 1.65;
  flex: 1; min-height: 0;
}
.skill-card-badges {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.skc-badge {
  font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px;
  background: rgba(124,58,237,.08); color: #7c3aed;
  border: 1px solid rgba(124,58,237,.15);
}
[data-theme="dark"] .skc-badge { background: rgba(167,139,250,.12); color: #c4b5fd; border-color: rgba(167,139,250,.25); }
.skill-card-foot {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 2px; font-size: 13px; font-weight: 600; color: var(--primary);
}

/* Skill 榜单（热榜下载 / 新榜推荐） */
.skill-rank-section {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px 26px 28px;
  margin: 22px 0 28px;
}
.skill-rank-header {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  margin-bottom: 18px;
}
.skill-rank-title {
  font-size: 22px; font-weight: 800; color: var(--text);
  margin: 0 0 4px; line-height: 1.3;
}
.skill-rank-subtitle {
  font-size: 14px; color: var(--text-soft); margin: 0;
}
.skill-rank-more {
  font-size: 13px; font-weight: 600; color: var(--text-mute);
  text-decoration: none; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 4px;
  transition: color .15s;
}
.skill-rank-more:hover { color: var(--primary); }
.rank-tabs {
  display: flex; gap: 8px; margin-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.rank-tab {
  background: transparent; border: none; border-bottom: 2px solid transparent;
  padding: 10px 14px 12px; font-size: 14px; font-weight: 600; color: var(--text-mute);
  cursor: pointer; transition: color .15s, border-color .15s;
}
.rank-tab:hover { color: var(--text); }
.rank-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.rank-panels { position: relative; }
.rank-panel { display: none; }
.rank-panel.active { display: block; }
.rank-layout {
  display: grid; grid-template-columns: 280px 1fr; gap: 22px;
}
.rank-hero-card {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column;
  background: linear-gradient(135deg, #1f1c2c 0%, #4a3f6b 100%);
  border-radius: 16px; padding: 22px;
  color: #fff; text-decoration: none; min-height: 320px;
  box-shadow: 0 10px 30px rgba(0,0,0,.18);
  transition: transform .15s, box-shadow .15s;
}
.rank-hero-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 36px rgba(0,0,0,.24);
}
.rank-hero-badge {
  align-self: flex-start;
  font-size: 12px; font-weight: 700; letter-spacing: .4px;
  padding: 5px 10px; border-radius: 999px;
  background: rgba(255,255,255,.15); color: #fff;
  backdrop-filter: blur(4px);
  margin-bottom: 18px;
}
.rank-hero-icon {
  width: 64px; height: 64px; border-radius: 16px;
  display: grid; place-items: center; font-size: 32px;
  background: rgba(255,255,255,.18); margin-bottom: 16px;
}
.rank-hero-card h3 {
  font-size: 20px; font-weight: 800; margin: 0 0 10px; line-height: 1.25;
}
.rank-hero-desc {
  font-size: 13px; line-height: 1.7; color: rgba(255,255,255,.78);
  margin: 0 0 auto; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden;
}
.rank-hero-meta {
  display: flex; flex-wrap: wrap; gap: 8px 12px; margin-top: 18px;
  font-size: 12px; color: rgba(255,255,255,.7);
}
.rank-hero-meta span { display: inline-flex; align-items: center; gap: 4px; }
.rank-list {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
}
.rank-item {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 12px; padding: 12px 14px;
  text-decoration: none; color: inherit;
  transition: background .15s, border-color .15s, transform .15s;
}
.rank-item:hover {
  background: rgba(124,58,237,.06); border-color: var(--primary-soft);
  transform: translateY(-2px);
}
.rank-num {
  flex: 0 0 24px; font-size: 14px; font-weight: 800; color: var(--text-mute);
  font-variant-numeric: tabular-nums;
}
.rank-icon {
  flex: 0 0 40px; width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center; font-size: 18px;
  background: linear-gradient(135deg, rgba(124,58,237,.1), rgba(236,72,153,.1));
}
.rank-info { flex: 1; min-width: 0; }
.rank-name {
  font-size: 14px; font-weight: 700; color: var(--text);
  margin-bottom: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rank-meta {
  font-size: 12px; color: var(--text-soft);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.rank-dl {
  flex: 0 0 auto; font-size: 12px; font-weight: 600; color: var(--text-mute);
  white-space: nowrap; display: inline-flex; align-items: center; gap: 3px;
}

/* Skill 分类导航（横向扁平胶囊） */
.skill-cat-nav {
  margin: 26px 0 18px;
}
.skill-cat-nav-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  margin-bottom: 14px;
}
.skill-cat-nav-title {
  font-size: 20px; font-weight: 800; color: var(--text);
  margin: 0 0 4px; line-height: 1.3;
}
.skill-cat-nav-subtitle {
  font-size: 14px; color: var(--text-soft); margin: 0;
}
.skill-cat-nav-scroll {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding: 4px 2px 14px;
}
.skill-cat-chip {
  flex: 0 0 calc(16.666% - 9px);
  display: inline-flex; align-items: center; justify-content: flex-start;
  gap: 8px;
  min-width: 120px; max-width: 180px;
  padding: 9px 16px 9px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  transition: background .15s, border-color .15s, color .15s, transform .15s, box-shadow .15s;
  box-shadow: 0 1px 2px rgba(16,24,40,.04);
}
.skill-cat-chip:hover {
  background: var(--bg-soft);
  border-color: var(--primary-soft);
  color: var(--primary-strong);
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(16,24,40,.06);
}
.skill-cat-chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(124,58,237,.22);
}
.skill-cat-chip .skc-icon { font-size: 18px; line-height: 1; }
.skill-cat-chip .skc-label { font-size: 14px; font-weight: 600; white-space: nowrap; }
.skill-cat-chip .skc-count {
  font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
  background: rgba(124,58,237,.08); color: #7c3aed;
}
.skill-cat-chip.active .skc-count { background: rgba(255,255,255,.22); color: #fff; }
.skill-cat-chip.skill-cat-more .skc-arrow {
  font-size: 16px; font-weight: 700; color: var(--text-mute); margin-left: 2px;
}
.skill-cat-chip.skill-cat-more:hover .skc-arrow { color: var(--primary-strong); }

/* 场景分类下拉筛选 */
.skill-scene-filter {
  margin: 0 0 22px;
}
.skill-scene-select-wrap {
  position: relative;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px 9px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: 0 1px 2px rgba(16,24,40,.04);
  cursor: pointer;
}
.skill-scene-select-wrap:hover {
  border-color: var(--primary-soft);
}
.skill-scene-icon { font-size: 16px; line-height: 1; }
.skill-scene-select {
  appearance: none; -webkit-appearance: none;
  background: transparent; border: none;
  font-size: 14px; font-weight: 600; color: var(--text);
  cursor: pointer;
  padding-right: 18px;
  min-width: 120px;
}
.skill-scene-select:focus { outline: none; }
.skill-scene-caret {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  font-size: 18px; line-height: 1; color: var(--text-mute); pointer-events: none;
}

/* Skill 全部分类页面 */
.skill-cat-page { padding-bottom: 40px; }
.skill-cat-page h1 { font-size: 32px; margin: 12px 0 8px; }
.skill-cat-page-desc {
  font-size: 15px; color: var(--text-soft); margin: 0 0 24px; max-width: 680px;
}
.skill-cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.skill-cat-large {
  display: flex; align-items: center; gap: 14px;
  padding: 18px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  color: var(--text); text-decoration: none;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  box-shadow: 0 1px 2px rgba(16,24,40,.04);
}
.skill-cat-large:hover {
  transform: translateY(-2px);
  border-color: var(--primary-soft);
  box-shadow: var(--shadow-hover);
}
.skill-cat-large .skcl-icon {
  flex: 0 0 44px; width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, rgba(124,58,237,.1), rgba(236,72,153,.1));
}
.skill-cat-large .skcl-body { flex: 1; min-width: 0; }
.skill-cat-large .skcl-name {
  font-size: 15px; font-weight: 700; color: var(--text);
  margin-bottom: 3px;
}
.skill-cat-large .skcl-count { font-size: 12px; color: var(--text-soft); }
.skill-cat-large .skcl-arrow {
  font-size: 18px; font-weight: 700; color: var(--text-mute);
}

/* 全部 Skill 列表页 */
.skill-list-page { padding-bottom: 40px; }
.skill-list-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 20px;
  margin-bottom: 18px;
}
.skill-list-head h1 { font-size: 32px; margin: 0 0 6px; }
.skill-list-desc {
  font-size: 15px; color: var(--text-soft); margin: 0; max-width: 680px;
}
.skill-list-count {
  font-size: 13px; color: var(--text-soft); margin: -8px 0 14px;
}
.skill-list-tabs {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-bottom: 18px;
}
.skl-tab {
  display: inline-flex; align-items: center;
  padding: 7px 14px; border-radius: 999px;
  font-size: 13px; font-weight: 600; text-decoration: none;
  background: var(--bg); border: 1px solid var(--border); color: var(--text-soft);
  transition: background .15s, border-color .15s, color .15s;
}
.skl-tab:hover { background: var(--bg-soft); color: var(--text); }
.skl-tab.active {
  background: var(--primary); border-color: var(--primary); color: #fff;
}
.skill-list-pagination {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--border);
}
.skl-page-numbers { display: flex; gap: 6px; }
.skl-page-link {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 32px; height: 32px; padding: 0 10px;
  border-radius: 8px;
  font-size: 13px; font-weight: 600; text-decoration: none;
  background: var(--bg); border: 1px solid var(--border); color: var(--text);
  transition: background .15s, border-color .15s, color .15s;
}
.skl-page-link:hover { background: var(--bg-soft); border-color: var(--primary-soft); color: var(--primary); }
.skl-page-link.active {
  background: var(--primary); border-color: var(--primary); color: #fff;
}
.skl-page-link.disabled {
  opacity: .5; cursor: not-allowed; color: var(--text-mute);
}

/* 单个 Skill 详情区块 */
.skill-detail {
  background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 28px 30px 24px; scroll-margin-top: 18px;
}

/* 顶部标题区 */
.skill-hero { margin-bottom: 22px; }
.skill-hero .breadcrumb { margin-bottom: 10px; }
.skill-hero h1 { font-size: 32px; line-height: 1.2; margin: 0 0 4px; }
.skill-en {
  font-size: 13px; color: var(--text-mute); letter-spacing: .4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  margin-bottom: 10px;
}
.skill-tagline {
  font-size: 16px; color: var(--text-soft); line-height: 1.6;
  margin: 0 0 18px; max-width: 760px;
}

/* Skill 详情页作者/统计/操作区 */
.skill-meta-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
  padding: 14px 0; border-top: 1px solid var(--border);
}
.skill-author {
  display: flex; align-items: center; gap: 10px;
}
.skill-author-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; font-size: 18px;
  background: var(--bg-soft); border: 1px solid var(--border);
}
.skill-author-name { font-size: 14px; font-weight: 700; color: var(--text); }
.skill-version { font-size: 12px; color: var(--text-soft); margin-top: 2px; }
.skill-stats {
  display: flex; align-items: center; gap: 18px;
}
.skill-stat { text-align: center; }
.skill-stat b { display: block; font-size: 16px; font-weight: 800; color: var(--text); }
.skill-stat span { font-size: 11px; color: var(--text-soft); }
.skill-actions {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding-bottom: 4px;
}
.skill-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 18px; border-radius: 999px;
  font-size: 14px; font-weight: 700; text-decoration: none;
  cursor: pointer; transition: transform .15s, box-shadow .15s, opacity .15s;
  border: none;
}
.skill-btn:hover { transform: translateY(-1px); }
.skill-btn-primary {
  background: var(--primary); color: #fff;
  box-shadow: 0 4px 12px rgba(124,58,237,.22);
}
.skill-btn-primary:hover { box-shadow: 0 6px 16px rgba(124,58,237,.3); }
.skill-btn-secondary {
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border);
}
.skill-btn-secondary:hover { border-color: var(--primary-soft); color: var(--primary-strong); }
.skill-btn-ghost {
  background: transparent; color: var(--text-soft);
  border: 1px solid var(--border);
}
.skill-btn-ghost:hover { color: var(--text); border-color: var(--text-mute); }

/* 优缺点与适合人群 */
.skill-pros, .skill-cons, .skill-audience {
  display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 20px;
  padding-top: 22px; margin-top: 22px; border-top: 1px solid var(--border);
}
.sk-pros-body ul, .sk-cons-body ul, .sk-audience-body ul { padding-left: 18px; margin: 8px 0; }
.sk-pros-body li, .sk-cons-body li, .sk-audience-body li { margin: 6px 0; font-size: 15px; line-height: 1.7; }
.sk-pros-body li::marker { color: #22c55e; }
.sk-cons-body li::marker { color: #ef4444; }
.sk-audience-body li::marker { color: var(--primary); }

/* 通用两栏区块（为什么值得看 / 项目说明 / 步骤） */
.skill-why, .skill-preview, .skill-steps, .skill-related {
  display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 20px;
  padding-top: 22px; margin-top: 22px; border-top: 1px solid var(--border);
}
.sk-section-label {
  font-size: 14px; font-weight: 600; color: var(--text);
  line-height: 1.4;
}
.sk-section-body { font-size: 15px; line-height: 1.85; color: var(--text-soft); }
.sk-section-body p { margin: 0 0 12px; }
.sk-section-body p:last-child { margin-bottom: 0; }
.sk-section-body b, .sk-section-body strong { color: var(--text); }

/* 项目说明预览卡（模拟浏览器窗口） */
.sk-preview-card {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 12px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(16,24,40,.04);
}
.sk-preview-head {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 12px; background: var(--bg-soft); border-bottom: 1px solid var(--border);
}
.sk-preview-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: #e5e7eb;
}
.sk-preview-dot:nth-child(1) { background: #ef4444; }
.sk-preview-dot:nth-child(2) { background: #f59e0b; }
.sk-preview-dot:nth-child(3) { background: #22c55e; }
[data-theme="dark"] .sk-preview-dot { opacity: .85; }
.sk-preview-body { padding: 18px 20px; font-size: 15px; line-height: 1.8; color: var(--text-soft); }
.sk-preview-body ul, .sk-preview-body ol { padding-left: 20px; margin: 10px 0; }
.sk-preview-body li { margin: 6px 0; }
.sk-preview-foot {
  display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; justify-content: space-between;
  padding: 12px 18px; background: var(--bg-elev); border-top: 1px solid var(--border);
}
.sk-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.sk-badge {
  font-size: 11px; font-weight: 600; padding: 4px 10px; border-radius: 999px;
  background: rgba(124,58,237,.08); color: #7c3aed; border: 1px solid rgba(124,58,237,.15);
}
[data-theme="dark"] .sk-badge { background: rgba(167,139,250,.12); color: #c4b5fd; border-color: rgba(167,139,250,.25); }
.sk-links { display: flex; flex-wrap: wrap; gap: 10px; }
.sk-link {
  font-size: 13px; color: var(--primary); font-weight: 500;
}
.sk-link:hover { text-decoration: underline; }

/* 步骤列表 */
.sk-step-list { margin: 0; padding: 0; list-style: none; counter-reset: step; }
.sk-step-list li {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 14px 0; border-bottom: 1px dashed var(--border);
}
.sk-step-list li:last-child { border-bottom: none; }
.sk-step-list li::before {
  counter-increment: step; content: counter(step);
  flex: 0 0 28px; width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center; font-size: 13px; font-weight: 700;
  background: var(--primary); color: #fff;
}
.sk-step-list li b {
  display: block; font-size: 14px; color: var(--text); margin-bottom: 3px;
}
.sk-step-list li span { font-size: 14px; color: var(--text-soft); line-height: 1.6; }

/* 同类工具推荐 */
.sk-rel-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px;
}
.sk-rel-card {
  display: flex; gap: 12px; padding: 14px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 12px;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.sk-rel-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); border-color: var(--primary-soft); }
.sk-rel-icon {
  flex: 0 0 44px; width: 44px; height: 44px; border-radius: 10px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, rgba(124,58,237,.1), rgba(236,72,153,.1));
}
.sk-rel-body { flex: 1; min-width: 0; }
.sk-rel-name { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sk-rel-desc { font-size: 12px; color: var(--text-soft); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Skill 页响应式 */
@media (max-width: 860px) {
  .skill-list-head h1 { font-size: 28px; }
  .skill-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .skill-card { padding: 16px; }
  .skill-detail { padding: 20px; }
  .skill-hero h1 { font-size: 26px; }
  .skill-why, .skill-preview, .skill-steps, .skill-related,
  .skill-pros, .skill-cons, .skill-audience { grid-template-columns: 1fr; gap: 12px; }
  .sk-section-label { font-size: 16px; border-bottom: none; }
  .sk-preview-foot { flex-direction: column; align-items: flex-start; }
  .sk-rel-grid { grid-template-columns: repeat(2, 1fr); }
  .sk-step-list li { padding: 12px 0; }
  .skill-meta-bar { flex-direction: column; align-items: flex-start; gap: 12px; }
  .skill-actions { width: 100%; }
  .skill-btn { flex: 1; justify-content: center; }
  .skill-rank-section { padding: 18px 18px 22px; }
  .skill-rank-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  .rank-layout { grid-template-columns: 1fr; }
  .rank-hero-card { min-height: 240px; }
  .rank-list { grid-template-columns: 1fr; }
  .skill-cat-nav-scroll { gap: 10px; }
  .skill-cat-chip { padding: 9px 14px 9px 12px; }
  .skill-cat-nav-title { font-size: 18px; }
  .skill-cat-page h1 { font-size: 26px; }
  .skill-cat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}
@media (max-width: 560px) {
  .skill-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .skill-detail { padding: 18px 16px; border-radius: 12px; }
  .skill-hero h1 { font-size: 22px; }
  .skill-tagline { font-size: 14px; }
  .sk-rel-grid { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------------------
   线性图标（Lucide 风格内联 SVG）
   尺寸由父级 font-size 控制（容器已用 grid 居中），无需逐处设宽高
   --------------------------------------------------------------- */
.line-icon { width: 1em; height: 1em; flex: none; vertical-align: -0.15em; }
/* 文章默认封面：线性文件图标放大并弱化，避免过于抢眼 */
.ap-cover-emoji .line-icon { width: 72px; height: 72px; color: var(--primary); opacity: .42; }
.ac-cover .line-icon { width: 44px; height: 44px; color: var(--primary); opacity: .5; }
/* 板块标题里的线性图标与文字对齐 */
.cat-icon .line-icon, .board-head h2 .line-icon, .sd-section-title .line-icon,
.skill-cat-nav-title .line-icon { vertical-align: -0.18em; margin-right: 2px; }
