/*
Theme Name: Jay Theme
Theme URI: https://blog.jmfqy.top/
Author: Jay's 折腾笔记
Author URI: https://blog.jmfqy.top/
Description: 轻量、移动端优先的 WordPress 博客主题。卡片式文章流、抽屉导航、深色模式、点赞/阅读量，全部手写无重型框架。
Version: 2.0.14
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Disclaimer: 本主题仅供合法用途。用户使用本主题从事任何违法违规行为，责任自负，与主题作者无关。使用本主题即表示同意遵守当地法律法规。
Text Domain: jay-theme
Tags: blog, mobile-first, responsive, dark-mode, customizer
*/

/* ============ 基础重置 ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; font-size: 16px; line-height: 1.7; color: var(--text); background: var(--bg); transition: background .3s, color .3s; -webkit-font-smoothing: antialiased; padding-bottom: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-decoration: none; }
a:hover { color: var(--link-hover); }
ul, ol { list-style: none; }

/* ============ CSS 变量（浅色默认） ============ */
:root {
  --bg: #fafafa;
  --card: #ffffff;
  --text: #171717;
  --text-2: #525252;
  --text-3: #595959;
  --link: #2563eb;
  --link-hover: #1d4ed8;
  --primary: #2563eb;
  --primary-text: #ffffff;
  --border: #e5e7eb;
  --header-bg: rgba(255, 255, 255, .88);
  --shadow: none;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow-md: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow-lg: 0 1px 2px rgba(0, 0, 0, .05);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --code-bg: #f3f4f6;
  --hl-k: #d73a49;
  --hl-s: #032f62;
  --hl-c: #6a737d;
  --hl-n: #005cc5;
  --hl-f: #6f42c1;
  --hl-v: #e36209;
  --muted: #595959;
  --border-strong: #d4d4d4;
  --hover-bg: rgba(0, 0, 0, .03);
  --success: var(--success);
  --danger: var(--danger);
  --warning: var(--warning);
}
[data-theme="dark"] {
  --bg: #0a0a0a;
  --card: #111113;
  --text: #ededed;
  --text-2: #a1a1aa;
  --text-3: #9aa3b2;
  --link: #60a5fa;
  --link-hover: #93c5fd;
  --primary: #3b82f6;
  --border: #232326;
  --header-bg: rgba(10, 10, 10, .85);
  --shadow: none;
  --shadow-sm: none;
  --shadow-md: none;
  --shadow-lg: none;
  --code-bg: #171717;
  --hl-k: #ff7b72;
  --hl-s: #a5d6ff;
  --hl-c: #8b949e;
  --hl-n: #79c0ff;
  --hl-f: #d2a8ff;
  --hl-v: #ffa657;
  --muted: #9aa3b2;
  --border-strong: #3f3f46;
  --hover-bg: rgba(255, 255, 255, .04);
}

/* 深色模式 */


/* ============ 布局容器 ============ */
.container { max-width: 1080px; margin: 0 auto; padding: 0 14px; }
.main { padding: 14px 0 40px; min-height: 60vh; }.site-header { position: sticky; top: 0; z-index: 100; background: var(--header-bg); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
.header-inner {
  max-width: 1080px; margin: 0 auto; padding: 0 14px;
  height: 56px; display: flex; align-items: center; gap: 12px;
}.site-logo { font-size: 18px; font-weight: 700; color: var(--text); white-space: nowrap; letter-spacing: -0.02em; }
.site-logo img { height: 32px; width: auto; }
.site-logo .custom-logo-link { display: inline-flex; align-items: center; }
/* 汉堡菜单按钮（仅移动端显示） */
.hamburger {
  width: 36px; height: 36px; border: none; background: transparent;
  color: var(--text); font-size: 20px; cursor: pointer;
  display: none; align-items: center; justify-content: center; flex-shrink: 0;
  border-radius: var(--radius-sm);
}
.hamburger:hover { background: var(--bg); }
@media (max-width: 767px) { .hamburger { display: inline-flex; } }
.header-search { flex: 1; position: relative; }
.header-search input {
  width: 100%; height: 36px; border: 1px solid var(--border);
  border-radius: 18px; padding: 0 36px 0 14px;
  background: var(--bg); color: var(--text); font-size: 14px; outline: none;
}
.header-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 15%, transparent); }
.header-search button {
  position: absolute; right: 4px; top: 4px; width: 28px; height: 28px;
  border: none; border-radius: 50%; background: transparent;
  color: var(--text-2); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.header-search button:hover { color: var(--primary); }
.theme-toggle {
  width: 36px; height: 36px; border: 1px solid var(--border); border-radius: 50%;
  background: var(--card); color: var(--text); cursor: pointer;
  display: flex; align-items: center; justify-content: center; font-size: 17px;
  flex-shrink: 0;
}
.theme-toggle:hover { border-color: var(--primary); }

/* ============ 文章卡片流 ============ */
.post-list { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.post-card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
  display: flex; gap: 12px; padding: 14px;
  align-items: stretch;
  transition: transform .2s, box-shadow .2s;
}
@media (hover: hover) {
  .post-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.12); }
}
.post-card:active { transform: scale(.99); }
.post-card-content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.post-card-title { font-size: 16px; font-weight: 700; line-height: 1.5; margin-bottom: 6px; }
.post-card-title a { color: var(--text); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; /* v2.0.13: 标题改单行省略，彻底告别两行错位（杰哥建议） */ }
.post-card-title a:hover { color: var(--primary); }
.post-card-excerpt {
  font-size: 13px; color: var(--text-2); line-height: 1.6;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; /* v2.0.14: 摘要恢复两行截断（v2.0.13 误伤） */
  margin-bottom: 8px; flex: 1;
}
.post-card-meta { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--text-3); }
.post-card-meta span { display: inline-flex; align-items: center; gap: 3px; }
.post-card-meta svg { flex-shrink: 0; }
.post-card-meta .cat-tag {
  background: var(--primary); color: var(--primary-text);
  padding: 1px 8px; border-radius: 10px; font-size: 11px;
}
/* v2.0.3: 缩略图改方形（截图样式）——左图右文卡片，缩略图 1:1 正方形；
   智能默认图 SVG 本身尺寸无关（slice 裁剪 + 相对定位），方形只需盒子 1:1；
   真实特色图由 object-fit: cover 裁成方形，无需重生成缩略图。 */
.post-card-thumb { width: 120px; height: 120px; flex-shrink: 0; border-radius: var(--radius-sm); overflow: hidden; background: var(--bg); align-self: center; }
@media (max-width: 767px) {
  .post-card-thumb { width: 96px; height: 96px; }
}
.post-card-thumb img { width: 100%; height: 100%; object-fit: cover; }

/* 智能默认图（关键词 + 渐变 SVG，深浅色通用） */
.smart-thumb { display: block; width: 100%; height: 100%; }
.smart-thumb svg { width: 100%; height: 100%; display: block; }
.smart-thumb text {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

/* 大图模式（首篇或置顶） */
.post-card.featured { flex-direction: column; padding: 0; }
.post-card.featured .post-card-thumb { width: 100%; height: 180px; border-radius: 0; }
.post-card.featured .post-card-content { padding: 14px; }
.post-card.featured .post-card-title { font-size: 18px; }

/* ============ 分页 ============ */
.pagination { display: flex; justify-content: center; gap: 8px; margin: 24px 0; flex-wrap: wrap; }
.pagination a, .pagination span {
  min-width: 36px; height: 36px; padding: 0 10px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); background: var(--card); color: var(--text-2);
  font-size: 14px; box-shadow: var(--shadow);
}
.pagination a:hover { background: var(--primary); color: var(--primary-text); }
.pagination .current { background: var(--primary); color: var(--primary-text); font-weight: 600; }

/* ============ 文章页 ============ */
.reading-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: var(--primary); z-index: 200; transition: width .1s;
}
.single-article {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 20px 16px; margin-top: 14px;
}
.single-title { font-size: 24px; font-weight: 700; line-height: 1.4; margin-bottom: 12px; letter-spacing: 0.01em; }
.single-meta { display: flex; flex-wrap: wrap; gap: 8px 14px; font-size: 13px; color: var(--text-3); margin-bottom: 18px; padding-bottom: 18px; border-bottom: 1px solid var(--border); align-items: center; }
.single-meta span { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.single-meta svg { flex-shrink: 0; color: var(--text-3); }
.single-content { font-size: 17px; line-height: 1.8; word-wrap: break-word; }
.single-content p { margin: 1.2em 0; }
.single-content h2, .single-content h3, .single-content h4 { margin: 1.8em 0 .8em; line-height: 1.5; font-weight: 700; }
.single-content h2 { font-size: 22px; padding-bottom: 10px; border-bottom: 1px solid var(--border); position: relative; }
.single-content h2::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 48px; height: 3px; background: var(--primary); border-radius: 2px; }
.single-content h3 { font-size: 19px; padding-left: 12px; border-left: 3px solid var(--primary); }
.single-content h4 { font-size: 18px; }
/* v1.3.3: 加粗与链接视觉区分——strong 深色加粗，链接蓝色 + hover 下划线 */
.single-content strong, .single-content b { color: var(--text); font-weight: 700; }
.single-content a { color: var(--link); }
.single-content a:hover { color: var(--link-hover); text-decoration: underline; }
.single-content ul, .single-content ol { margin: 1em 0; padding-left: 1.6em; }
.single-content ul { list-style: disc; }
.single-content ol { list-style: decimal; }
.single-content li { margin: .4em 0; }
.single-content blockquote {
  margin: 1.4em 0; padding: 16px 20px 16px 52px; border-left: 3px solid var(--primary);
  background: var(--bg); border-radius: 0 12px 12px 0; color: var(--text-2);
  position: relative; font-size: 15px; line-height: 1.75;
}
.single-content blockquote::before {
  content: "\201C"; position: absolute; left: 14px; top: 8px;
  font-size: 42px; line-height: 1; color: var(--primary); opacity: .35;
  font-family: Georgia, serif;
}
.single-content blockquote p { margin: .5em 0; }
.single-content blockquote p:first-child { margin-top: 0; }
.single-content blockquote p:last-child { margin-bottom: 0; }
.single-content code {
  background: var(--code-bg); padding: 2px 6px; border-radius: 4px;
  font-family: "SF Mono", Consolas, monospace; font-size: .88em;
}
.single-content pre {
  background: var(--code-bg); padding: 14px; border-radius: var(--radius-sm);
  overflow-x: auto; margin: 1.2em 0; -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  /* v2.0.2: 显式锁定空白保留——防止任何外部样式把 pre 的 white-space 改成 normal 导致空格/换行丢失（命令粘连）。 */
  white-space: pre; word-break: normal; overflow-wrap: normal;
}
.single-content pre code { background: none; padding: 0; }

/* Mac 风格代码块：顶栏 + 圆点 + 语言 + 复制 */
.code-block { margin: 1.2em 0; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: var(--code-bg); }
.code-block pre { margin: 0; border: none; border-radius: 0; background: transparent; }.code-head { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid var(--border); background: var(--bg); }
.code-dots { display: flex; gap: 6px; flex-shrink: 0; }
.code-dots i { width: 11px; height: 11px; border-radius: 50%; display: block; }
.code-dots i:nth-child(1) { background: #ff5f57; }
.code-dots i:nth-child(2) { background: #febc2e; }
.code-dots i:nth-child(3) { background: #28c840; }
.code-lang { font-size: 12px; color: var(--text-3); text-transform: uppercase; letter-spacing: .06em; font-family: "SF Mono", Consolas, monospace; }
.code-copy { margin-left: auto; font-size: 12px; padding: 4px 12px; border: 1px solid var(--border); border-radius: 6px; background: transparent; color: var(--text-2); cursor: pointer; transition: all .2s; flex-shrink: 0; }
.code-copy:hover { color: var(--primary); border-color: var(--primary); }
.single-content img { border-radius: var(--radius-sm); margin: 1em auto; }
.single-content table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: 14px; display: block; overflow-x: auto; border-radius: 10px; border: 1px solid var(--border); }
.single-content th, .single-content td { border: 1px solid var(--border); padding: 10px 14px; text-align: left; }
.single-content th { background: var(--primary); color: #fff; font-weight: 600; border-color: var(--primary); }
.single-content th:first-child { border-top-left-radius: 9px; }
.single-content th:last-child { border-top-right-radius: 9px; }
.single-content tr:nth-child(even) td { background: var(--bg); }
.single-content tr:hover td { background: rgba(127,127,127,.08); }
.single-content hr { border: none; margin: 2em auto; height: 1px; max-width: 240px; background: linear-gradient(90deg, transparent, var(--primary), transparent); opacity: .5; }
.single-tags { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 8px; }
.single-tags a { font-size: 13px; padding: 5px 14px; border: 1px solid var(--border); border-radius: var(--radius-lg); color: var(--text-2); background: var(--bg); transition: all .2s; text-decoration: none; }
.single-tags a:hover { border-color: var(--primary); color: var(--primary); background: rgba(127,127,127,.06); }.toc-box { background: var(--bg); border-radius: 10px; padding: 14px 16px; margin: 0 0 18px; font-size: 14px; border: 1px solid var(--border); }
.toc-toggle { display: block; background: none; border: none; padding: 0; margin: 0 0 8px; cursor: default; color: var(--text); }
.toc-toggle svg { display: none; }
.toc-box > strong, .toc-toggle strong { display: block; font-size: 15px; }
.toc-list { padding-left: 0; }
.toc-box li { margin: 4px 0; }
.toc-box li.toc-h3 { padding-left: 1em; }
.toc-box li.toc-h4 { padding-left: 2em; }
.toc-box a { color: var(--text-2); }
.toc-box a:hover, .toc-box a.active { color: var(--primary); }
/* 目录折叠（手机端 + PC 端文内目录） */
.toc-toggle {
  display: flex; align-items: center; gap: 6px; width: 100%;
  background: none; border: none; padding: 0; margin-bottom: 8px;
  font-size: 15px; cursor: pointer; color: var(--text);
}
.toc-toggle svg { display: block; transition: transform .2s; flex-shrink: 0; }
.toc-box.toc-collapsed .toc-toggle svg { transform: rotate(-90deg); }
.toc-box.toc-collapsed .toc-toggle { margin-bottom: 0; }
.toc-box.toc-collapsed .toc-list { display: none; }
/* 侧边栏目录始终展开，不可折叠 */
.single-sidebar .toc-box.toc-collapsed .toc-list { display: block; }
.single-sidebar .toc-toggle { cursor: default; }
.single-sidebar .toc-toggle svg { display: none; }

/* 相关文章 - v1.3.3 优化视觉层次 */
.related-posts { margin: 32px 0 8px; }
.related-posts > h2 { font-size: 18px; font-weight: 700; margin-bottom: 14px; }
/* v1.6.0: 相关/随机推荐改为 4 列网格卡片（手机 2 列），缩略图+标题 */
.related-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.related-list .post-card { flex-direction: column; padding: 0; gap: 0; }
.related-list .post-card-thumb { width: 100%; height: 110px; border-radius: 0; align-self: auto; }
.related-list .post-card-content { padding: 10px 12px 12px; }
.related-list .post-card-title { font-size: 14px; margin-bottom: 6px; }
.related-list .post-card-title a { /* 继承 .post-card-title a 单行省略 */ }
.related-list .post-card-excerpt { display: none; }
.related-list .post-card-meta { font-size: 11px; gap: 8px; }
@media (max-width: 640px) {
  .related-list { grid-template-columns: repeat(2, 1fr); }
  .related-list .post-card-thumb { height: 90px; }
}

/* ============ 归档/分类页头 ============ */
.archive-header {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px; margin-top: 14px; margin-bottom: 4px;
}
.archive-header h1 { font-size: 20px; font-weight: 800; }
.archive-header p { font-size: 13px; color: var(--text-2); margin-top: 6px; }

/* v1.2.3: 分类封面（渐变背景 + 大字分类名） */
.cat-cover {
  position: relative; overflow: hidden;
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 36px 28px; margin-bottom: 16px; color: #fff;
  /* v2.0.0: 渐变封面 + 白字（archive.php 内联 linear-gradient） */
}
.cat-cover::after {
  content: ''; position: absolute; right: -50px; top: -50px;
  width: 180px; height: 180px; border-radius: 50%;
  background: rgba(255,255,255,.10); pointer-events: none;
}
.cat-cover h1 { font-size: 28px; font-weight: 800; color: #fff; }
.cat-cover p { font-size: 14px; color: #fff; opacity: .85; margin-top: 8px; max-width: 640px; }
.cat-cover .cat-count {
  display: inline-block; margin-top: 12px; font-size: 12px;
  background: rgba(255,255,255,.12); color: #fff;
  padding: 4px 14px; border-radius: 20px;
}
@media (max-width: 640px) {
  .cat-cover { padding: 26px 20px; }
  .cat-cover h1 { font-size: 22px; }
}.search-header { margin: 14px 0 4px; font-size: 14px; color: var(--text-2); }
.search-header strong { color: var(--primary); }

/* ============ 404 ============ */
.error-404 { text-align: center; padding: 56px 20px; background: var(--card); border-radius: var(--radius); margin-top: 14px; min-height: 55vh; display: flex; flex-direction: column; align-items: center; justify-content: center; }
/* v1.6.0：大数字渐变 + 搜索框 + 热门推荐 */
.e404-num { font-size: 120px; font-weight: 900; line-height: 1; letter-spacing: .04em;
  background: linear-gradient(135deg, var(--primary), var(--text));
  background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--primary) 45%, var(--text)));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.e404-title { margin: 14px 0 0; font-size: 22px; font-weight: 700; color: var(--text); }
.e404-desc { color: var(--text-2); margin: 10px 0 22px; font-size: 14px; line-height: 1.8; }
.e404-search { width: 100%; max-width: 420px; margin-bottom: 30px; }
.e404-search .search-form { display: flex; gap: 8px; }
.e404-search .search-form label { flex: 1; min-width: 0; }
.e404-search .search-form .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.e404-search .search-field { width: 100%; padding: 11px 16px; font-size: 14px; color: var(--text);
  background: var(--bg); border: 1px solid var(--border); border-radius: 10px; outline: none; }
.e404-search .search-field:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.e404-search .search-submit { flex-shrink: 0; padding: 0 20px; font-size: 14px; font-weight: 600;
  background: var(--primary); color: var(--primary-text); border: none; border-radius: 10px; cursor: pointer; }
.e404-search .search-submit:hover { opacity: .9; }.e404-popular { width: 100%; max-width: 560px; margin-bottom: 28px; text-align: left; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; }.e404-popular-title { margin: 0 0 8px; font-size: 15px; font-weight: 700; color: var(--text); text-align: left; }
.e404-popular-list { margin: 0; padding: 0; list-style: none; }
.e404-actions { margin-bottom: 6px; }
.btn {
  display: inline-block; padding: 10px 24px; border-radius: var(--radius-sm);
  background: var(--primary); color: var(--primary-text); font-size: 15px; font-weight: 600;
  transition: opacity .2s, transform .15s;
}
.btn:hover { color: var(--primary-text); opacity: .92; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

/* ============ 页脚 ============ */
.site-footer { margin-top: 30px; border-top: 1px solid var(--border); background: var(--card); }
.footer-inner { max-width: 1080px; margin: 0 auto; padding: 22px 14px; text-align: center; font-size: 13px; color: var(--text-3); }
.footer-inner p { margin: 4px 0; }
.footer-inner a { color: var(--text-2); }
.footer-inner a:hover { color: var(--primary); }
.theme-credit { font-size: 12px; }
/* v1.3.3: 页脚友情链接 / 统计 / 备案号 */
.footer-links { font-size: 13px; margin: 8px 0; }
.footer-links-label { margin-right: 4px; }
.footer-links a { margin: 0 8px 0 0; text-decoration: none; }
.footer-icp { font-size: 13px; margin: 4px 0; }
.footer-icp a { text-decoration: none; }
.site-uptime { font-size: 12px; color: var(--text-2); }
.site-uptime span { font-weight: 700; color: var(--primary); }

/* 右下角浮动按钮组 */
.float-btns {
  position: fixed; right: 16px; bottom: 24px; z-index: 150;
  display: flex; flex-direction: column; gap: 10px;
}.float-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--border); background: var(--card); color: var(--text-2); cursor: pointer; box-shadow: var(--shadow); display: flex; align-items: center; justify-content: center; transition: transform .15s ease, color .15s ease, border-color .15s ease; }
.float-btn:hover { color: var(--primary); border-color: var(--primary); transform: translateY(-2px); }
.float-btn:active { transform: scale(.94); }
/* 回到顶部：滚动超过一屏才显示 */
.back-to-top { display: none; }
.back-to-top.show { display: flex; }.breadcrumb { font-size: 13px; color: var(--text-3); margin: 14px 0 0; display: flex; align-items: center; flex-wrap: wrap; row-gap: 4px; }
.breadcrumb a { color: var(--text-2); }
.breadcrumb a:hover { color: var(--primary); text-decoration: underline; }
.breadcrumb .breadcrumb-sep { margin: 0 8px; color: var(--text-3); display: inline-flex; opacity: .65; }
.breadcrumb .current { color: var(--text-3); }

/* ============ 抽屉导航（移动端） ============ */
.drawer-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.45);
  z-index: 290; opacity: 1; transition: opacity .25s;
}.drawer { position: fixed; top: 0; left: 0; bottom: 0; width: min(300px, 84vw); background: var(--card); z-index: 300; transform: translateX(-102%); transition: transform .28s ease, visibility 0s .28s; visibility: hidden; display: flex; flex-direction: column; box-shadow: none; border-right: 1px solid var(--border); }
.drawer.open { transform: translateX(0); visibility: visible; transition: transform .28s ease; }
body.drawer-open { overflow: hidden; }
.drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--border);
}
.drawer-title { font-weight: 800; font-size: 16px; color: var(--text); }
.drawer-close {
  width: 32px; height: 32px; border: none; border-radius: var(--radius-sm);
  background: transparent; color: var(--text-2); font-size: 16px; cursor: pointer;
}
.drawer-close:hover { background: var(--bg); color: var(--text); }
/* v2.0.6: 工具行（主题切换在顶部，样式复用 drawer-link，行与下方用分隔线区分） */
.drawer-tools { padding: 10px 16px; border-bottom: 1px solid var(--border); }
.drawer-tools .drawer-link { width: 100%; }
.drawer-search { display: flex; gap: 8px; padding: 14px 16px 6px; }
.drawer-search input {
  flex: 1; height: 36px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0 12px; background: var(--bg); color: var(--text); font-size: 14px; outline: none;
  min-width: 0;
}
.drawer-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 15%, transparent); }
.drawer-search button {
  height: 36px; padding: 0 14px; border: none; border-radius: var(--radius-sm);
  background: var(--primary); color: var(--primary-text); font-size: 14px; cursor: pointer;
  flex-shrink: 0;
}
.drawer-nav { flex: 1; overflow-y: auto; padding: 10px 8px 20px; -webkit-overflow-scrolling: touch; }.drawer-group-title { font-size: 11px; color: var(--text-3); padding: 16px 12px 6px; font-weight: 700; /* v2.0.2: 同上，中文分组标题删字距 + uppercase */
  color: var(--text-3); }
.drawer-link {
  display: flex; align-items: center; gap: 8px;
  padding: 10px; border-radius: var(--radius-sm); font-size: 15px; color: var(--text);
}
.drawer-link:hover { background: var(--bg); color: var(--primary); }
.drawer-link svg { flex-shrink: 0; }
.drawer-link .count { margin-left: auto; font-size: 12px; color: var(--text-3); }

/* ============ 首页双栏布局（PC 端侧边栏） ============ */
/* ============ v1.6.0: 博客首屏定位 ============ */
/* v2.0.3: 视觉隐藏（保留 h1 供 SEO/无障碍，页面上看不到） */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
@media (max-width: 767px) {
}

/* ============ v1.6.0: 推广卡缩小 ============ */
.theme-promo-card { background: linear-gradient(135deg, var(--primary, #1a2a4a), var(--primary, #2d5aa0)); background: linear-gradient(135deg, color-mix(in srgb, var(--primary, #2563eb) 65%, #0f172a), var(--primary, #2563eb)); border-radius: 10px; margin-bottom: 16px; color: #fff; }
.theme-promo-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; flex-wrap: wrap; }
.theme-promo-text h2 { font-size: 16px; margin-bottom: 4px; color: #fff; }
.theme-promo-text h2.promo-title { display: flex; align-items: center; gap: 8px; }
.theme-promo-text h2.promo-title svg { flex-shrink: 0; }
.theme-promo-text p { font-size: 14px; opacity: .85; margin: 0; }
.theme-promo-btn { background: #fff; color: var(--primary, #1a2a4a) !important; padding: 10px 24px; border-radius: var(--radius-sm); font-weight: bold; text-decoration: none; white-space: nowrap; transition: background .2s, transform .15s; }
.theme-promo-btn:hover { background: #f0f0f0; text-decoration: none; transform: translateY(-1px); }
/* ============ v1.3.3: 推广卡片手机端紧凑布局（一行式，省垂直空间） ============ */
@media (max-width: 767px) {
  .theme-promo-card { border-radius: 10px; margin-bottom: 14px; }
  .theme-promo-inner { flex-wrap: nowrap; padding: 12px 14px; gap: 10px; align-items: center; }
  .theme-promo-text { min-width: 0; flex: 1; }
  .theme-promo-text h2 { font-size: 15px; margin-bottom: 2px; }
  .theme-promo-text h2.promo-title svg { width: 18px; height: 18px; }
  .theme-promo-text p { font-size: 12px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; /* v2.0.14: 摘要恢复两行截断（v2.0.13 误伤） */ }
  .theme-promo-btn { flex-shrink: 0; padding: 8px 14px; font-size: 13px; border-radius: 20px; }
}
.home-layout { display: block; }
.home-main { min-width: 0; }
.home-sidebar { display: none; }
/* v1.3.3: 侧栏左右/隐藏（PC 端） */
.home-layout.no-sidebar .home-sidebar { display: none !important; }
@media (min-width: 768px) {
  .home-layout { display: flex; gap: 20px; align-items: flex-start; }
  .home-layout.sidebar-left { flex-direction: row-reverse; }
  .home-main { flex: 1; min-width: 0; }
  .home-sidebar { display: block; width: 280px; flex-shrink: 0; margin-top: 14px; position: sticky; top: 76px; }
}
.widget {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px; margin-bottom: 16px;
}
.widget-title { font-size: 15px; font-weight: 700; margin-bottom: 12px; padding-left: 10px; border-left: 3px solid var(--primary); }
.popular-list li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--border); font-size: 14px; }
.popular-list li:last-child { border-bottom: none; }
.popular-list .rank {
  width: 22px; height: 22px; flex-shrink: 0; border-radius: 6px;
  background: var(--bg); color: var(--text-2); font-size: 12px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.popular-list .rank-1 { background: var(--danger); color: #fff; }
.popular-list .rank-2 { background: var(--warning); color: #fff; }
.popular-list .rank-3 { background: #10b981; color: #fff; }
.popular-list a { flex: 1; min-width: 0; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.popular-list a:hover { color: var(--primary); }
.popular-list .views { flex-shrink: 0; font-size: 12px; color: var(--text-3); }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud a {
  font-size: 13px; padding: 4px 12px; border: 1px solid var(--border);
  border-radius: 14px; color: var(--text-2);
}
.tag-cloud a:hover { border-color: var(--primary); color: var(--primary); }
.tag-cloud a span { color: var(--text-3); font-size: 11px; }

/* ============ 文章点赞 ============ */
.single-actions { margin: 22px 0 6px; text-align: center; }
.like-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 26px; border-radius: 24px; font-size: 15px; font-weight: 600;
  border: 1px solid var(--border); background: transparent; color: var(--text-2);
  cursor: pointer; transition: all .2s;
}
.like-btn:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.like-btn.liked, .like-btn:disabled { border-color: var(--primary); background: var(--primary); color: var(--primary-text); opacity: .9; cursor: default; }
.like-btn .like-count { font-variant-numeric: tabular-nums; }
.like-btn svg, .fav-btn svg { flex-shrink: 0; }
.like-btn:hover:not(:disabled) svg { transform: scale(1.12); }
.like-btn svg { transition: transform .15s; }

/* ============ v1.9.0: 评论点赞 ============ */
.comment .reply { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.jay-comment-like {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px; font-size: 12px; line-height: 1.6;
  border: 1px solid var(--border); background: transparent; color: var(--text-3);
  cursor: pointer; transition: all .2s;
}
.jay-comment-like:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.jay-comment-like.liked { border-color: var(--primary); background: var(--primary); color: var(--primary-text); }
.jay-comment-like:disabled { opacity: .6; cursor: default; }
.jay-comment-like .like-count { font-variant-numeric: tabular-nums; }
.jay-comment-like svg { flex-shrink: 0; }

/* ============ 评论区 - v1.3.3 美化 ============ */
.comments-area {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 20px 16px; margin-top: 20px;
}
.comments-title { font-size: 17px; font-weight: 700; margin-bottom: 16px; }
.comment-list { padding: 0; margin: 0; list-style: none; }
.comment-list .comment { margin-bottom: 16px; }
/* v1.9.0 楼中楼：层级缩进 + 左侧竖线区分，PC 24px 缩进 */
.comment-list .children {
  margin: 12px 0 0 24px; padding-left: 16px;
  border-left: 3px solid var(--border); 
  border-left: 3px solid color-mix(in srgb, var(--primary) 35%, var(--border));
  list-style: none;
}
/* 二级以上加深竖线，层级更清晰 */
.comment-list .children .children {
  border-left-color: #2563eb; 
  border-left-color: color-mix(in srgb, var(--primary) 55%, var(--border));
}
[data-theme="dark"] .comment-list .children {
  border-left-color: var(--border); 
  border-left-color: color-mix(in srgb, var(--primary) 45%, var(--border));
}
.comment-body { background: var(--bg); border-radius: 10px; padding: 14px 16px; transition: box-shadow .2s; }
.comment-body:hover { box-shadow: 0 2px 8px rgba(0,0,0,.06); }
.comment-author { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.comment-author img { border-radius: 50%; border: 2px solid var(--border); width: 40px; height: 40px; object-fit: cover; }
.comment-author .fn { font-style: normal; font-weight: 700; font-size: 14px; color: var(--text); }
.comment-author .says { display: none; }
/* 博主标识 */
.comment.bypostauthor > .comment-body .comment-author .fn::after {
  content: "博主"; font-size: 11px; font-weight: 600; color: var(--primary-text);
  background: var(--primary); border-radius: 10px; padding: 1px 8px; margin-left: 6px;
  vertical-align: 1px;
}
.comment-meta { font-size: 12px; color: var(--text-3); margin-bottom: 8px; padding-left: 50px; }
.comment-meta a { color: var(--text-3); text-decoration: none; }
.comment-meta a:hover { color: var(--primary); }
.comment-content { font-size: 14px; color: var(--text); line-height: 1.75; word-wrap: break-word; }
.comment-content p { margin: .5em 0; }
.comment-content a { color: var(--link); }
.reply { margin-top: 8px; padding-left: 50px; font-size: 13px; }.comment-reply-link { display: inline-block; padding: 5px 16px; border: 1px solid var(--border); border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--text); text-decoration: none; background: transparent; transition: all .2s; }
.comment-reply-link:hover { border-color: var(--primary); color: #fff; background: var(--primary); }
.comment-reply-link:active { transform: scale(.96); }
/* v1.9.0 楼中楼手机端：缩进收紧不挤，按钮保持可点 */
@media (max-width: 767px) {
  .comment-list .children { margin: 10px 0 0 12px; padding-left: 10px; }
  .comment-body { padding: 12px; border-radius: 8px; }
  .comment-author img { width: 32px; height: 32px; }
  .comment-meta, .reply { padding-left: 42px; }
  .comment-reply-link { padding: 6px 18px; font-size: 13px; }
}
/* 评论表单 */
.comment-respond { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--border); }
.comment-reply-title { font-size: 16px; font-weight: 700; margin-bottom: 14px; }
.comment-reply-title small { margin-left: 8px; font-size: 13px; font-weight: 400; }
.comment-form label { display: block; font-size: 13px; color: var(--text-2); margin-bottom: 6px; font-weight: 500; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
  width: 100%; border: 1px solid var(--border); border-radius: 10px;
  padding: 11px 14px; font-size: 14px; background: var(--bg); color: var(--text);
  outline: none; margin-bottom: 12px; font-family: inherit; transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.comment-form input:focus, .comment-form textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); 
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 15%, transparent);
}
.comment-form textarea { min-height: 110px; resize: vertical; line-height: 1.6; }
.comment-form .form-submit { margin: 8px 0 0; }
.comment-form input[type="submit"] {
  padding: 11px 36px; border: none; border-radius: 24px; cursor: pointer;
  background: var(--primary); color: var(--primary-text); font-size: 15px; font-weight: 600;
  transition: transform .2s, box-shadow .2s, opacity .2s;
}
.comment-form input[type="submit"]:hover { opacity: 1; transform: translateY(-1px); box-shadow: 0 4px 14px rgba(37,99,235,.35); }
.comment-form input[type="submit"]:active { transform: translateY(0); }
.comment-form .required { color: var(--danger); }
.comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-2); margin-bottom: 12px; }
.comment-form-cookies-consent input { width: auto; margin: 0; }
/* 桌面端三列表单 */
@media (min-width: 768px) {
  .comment-form .comment-form-author, .comment-form .comment-form-email, .comment-form .comment-form-url { margin-bottom: 0; }
  .comment-form-author + .comment-form-email + .comment-form-url { display: contents; }
}
.no-comments { color: var(--text-3); font-size: 14px; margin: 10px 0; }
.no-comments-tip { text-align: center; color: var(--text-3); font-size: 14px; padding: 24px 0 8px; margin: 0; }
.no-comments-tip::before { content: "💬"; display: block; font-size: 28px; margin-bottom: 8px; }
.comment-navigation { display: flex; justify-content: space-between; margin: 12px 0; font-size: 14px; }
@media (min-width: 768px) { .comments-area { padding: 28px 32px; } }

/* ============ 顶部通知栏 ============ */
.notice-bar {
  background: var(--primary); color: #fff;
  display: flex; align-items: center;
  font-size: 13px; overflow: hidden; position: relative; z-index: 120;
}
.notice-track {
  /* v2.0.3: 轨道宽度 = 内容宽度（6 份文案），translateX(-50%) 恰好 = 3 份文案，无缝循环；
     之前 flex:1 把轨道拉满整栏，-50% 不等于一份文案宽，滚动会跳变/滑出屏后空栏。 */
  flex: none; width: max-content; display: flex; white-space: nowrap; overflow: hidden;
  animation: notice-scroll 20s linear infinite;
}
.notice-track span { padding: 8px 40px 8px 0; flex-shrink: 0; }
@keyframes notice-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.notice-close {
  position: absolute; right: 0; top: 50%; transform: translateY(-50%); z-index: 1;
  border: none; background: var(--primary); color: #fff;
  font-size: 14px; cursor: pointer; padding: 12px 14px; opacity: .8;
}
.notice-close:hover { opacity: 1; }
/* v2.0.2: 公告统一一行滚动；悬停暂停，方便读完 */
.notice-bar:hover .notice-track { animation-play-state: paused; }
/* v2.0.2: /tag/ 标签索引页 */
.tag-index { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-index-item { display: inline-flex; align-items: center; gap: 4px; background: var(--card); border: 1px solid var(--border); border-radius: 999px; padding: 8px 14px; font-size: 14px; color: var(--text); }
.tag-index-item:hover { border-color: var(--primary); color: var(--primary); }
.tag-index-item span { color: var(--text-3); font-size: 12px; }

/* ============ 热门搜索关键词 ============ */
.hot-keys {
  position: absolute; top: 42px; left: 0; right: 0;
  background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: var(--shadow); padding: 10px 12px; display: none; z-index: 110;
}
.header-search:focus-within .hot-keys { display: block; }
.hot-keys-label { font-size: 12px; color: var(--text-3); margin-right: 4px; }
.hot-keys button {
  font-size: 13px; margin: 3px 4px 3px 0; padding: 4px 12px;
  border: 1px solid var(--border); border-radius: 14px;
  background: var(--bg); color: var(--text-2); cursor: pointer;
}
.hot-keys button:hover { border-color: var(--primary); color: var(--primary); }
.drawer-hotkeys { padding: 4px 16px 10px; font-size: 13px; }
.drawer-hotkeys .hot-keys-label { display: block; font-size: 12px; color: var(--text-3); margin-bottom: 6px; }
.drawer-hotkeys button {
  font-size: 13px; margin: 0 6px 6px 0; padding: 4px 12px;
  border: 1px solid var(--border); border-radius: 14px;
  background: var(--bg); color: var(--text-2); cursor: pointer;
}
.drawer-hotkeys button:hover { border-color: var(--primary); color: var(--primary); }

/* ============ 代码高亮 ============ */
.tok-k { color: var(--hl-k); }
.tok-s { color: var(--hl-s); }
.tok-c { color: var(--hl-c); font-style: italic; }
.tok-n { color: var(--hl-n); }
.tok-f { color: var(--hl-f); }
.tok-v { color: var(--hl-v); }


pre.hl-light {
  --hl-k: #d73a49; --hl-s: #032f62; --hl-c: #6a737d;
  --hl-n: #005cc5; --hl-f: #6f42c1; --hl-v: #e36209;
}
pre.hl-dark {
  --hl-k: #ff7b72; --hl-s: #a5d6ff; --hl-c: #8b949e;
  --hl-n: #79c0ff; --hl-f: #d2a8ff; --hl-v: #ffa657;
}
pre.jay-hl { position: relative; padding-top: 30px; }
pre.jay-hl::before {
  content: attr(data-lang);
  position: absolute; top: 8px; right: 12px;
  font-size: 11px; color: var(--text-3); text-transform: uppercase; letter-spacing: 1px;
}

/* ============ 图片灯箱 ============ */
.lightbox {
  position: fixed; inset: 0; z-index: 400;
  background: rgba(0,0,0,.9);
  display: flex; align-items: center; justify-content: center;
}
.lightbox[hidden] { display: none; }
.lb-img { max-width: 92vw; max-height: 86vh; border-radius: var(--radius-sm); object-fit: contain; }
.lb-close, .lb-prev, .lb-next {
  position: absolute; border: none; border-radius: 50%; cursor: pointer;
  background: rgba(255,255,255,.15); color: #fff; font-size: 20px;
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
}
.lb-close:hover, .lb-prev:hover, .lb-next:hover { background: rgba(255,255,255,.3); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lb-count {
  position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%);
  color: #fff; font-size: 13px; opacity: .8;
}

/* ============ 收藏按钮 ============ */
.fav-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 26px; border-radius: 24px; font-size: 15px; font-weight: 600;
  border: 1px solid var(--border); background: transparent; color: var(--text-2);
  cursor: pointer; transition: all .2s; margin-left: 10px;
}
.fav-btn:hover { border-color: var(--warning); color: var(--warning); }
.fav-btn.faved { border-color: var(--warning); background: var(--warning); color: #fff; }
.fav-count { font-size: 13px; opacity: .85; font-weight: 600; }

/* ============ 友情链接页 ============ */
.links-page {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 24px 18px; margin-top: 14px;
}
.links-title { font-size: 22px; font-weight: 800; margin-bottom: 16px; }
.links-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px;
  margin-bottom: 20px;
}
.link-card {
  display: flex; flex-direction: column; gap: 4px;
  border: 1px solid var(--border); border-radius: 10px; padding: 14px;
  transition: border-color .2s, transform .2s;
}
.link-card:hover { border-color: var(--primary); transform: translateY(-2px); }
.link-name { font-weight: 700; font-size: 15px; color: var(--text); }
.link-desc { font-size: 13px; color: var(--text-2); }
.link-url { font-size: 12px; color: var(--text-3); }
.links-empty { color: var(--text-3); font-size: 14px; margin-bottom: 16px; }
.links-content { margin-top: 8px; }
@media (min-width: 768px) { .links-page { padding: 32px 36px; } }

/* ============ PC 端增强（≥768px） ============ */
@media (min-width: 768px) {
  .post-list { gap: 14px; }
  .post-card { padding: 18px; }
  .post-card-thumb { width: 200px; height: 134px; }
  .post-card-title { font-size: 18px; }
  .post-card.featured .post-card-thumb { height: 280px; }
  .single-article { padding: 32px 36px; }
  .single-title { font-size: 32px; }
  .single-meta { flex-wrap: nowrap; }
  /* PC 端双栏：内容 + 侧边目录 */
  .single-layout { display: flex; gap: 20px; align-items: flex-start; }
  .single-layout .single-article { flex: 1; min-width: 0; margin-top: 14px; }
  .single-sidebar { width: 260px; flex-shrink: 0; position: sticky; top: 76px; margin-top: 14px; }
  .single-sidebar .toc-box { margin-bottom: 0; }
  .toc-box { max-height: 60vh; overflow-y: auto; }
}

/* ============ 移动端底部 TAB 导航 ============ */
.tab-bar { display: none; }
@media (max-width: 767px) {
  .tab-bar {
    display: flex;
    position: fixed; left: 12px; right: 12px;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    z-index: 160;
    background: var(--card); /* 不支持 color-mix 的兜底 */
    background: color-mix(in srgb, var(--card) 88%, transparent);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
    border: 1px solid var(--border); border-radius: 22px;
    box-shadow: 0 6px 22px rgba(0,0,0,.14);
    padding: 8px 6px 6px;
  }
  .tab-item {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 4px 0 6px; border: none; background: transparent; border-radius: 14px;
    color: var(--text-3); font-size: 11px; cursor: pointer; font-family: inherit;
    position: relative; transition: color .2s;
  }
  .tab-item:hover { color: var(--text-2); }
  .tab-item:active { transform: scale(.96); }
  .tab-icon {
    display: inline-flex; align-items: center; justify-content: center;
    line-height: 1; padding: 5px 12px; border-radius: 14px;
    transition: background .25s, transform .2s, color .2s;
  }
  .tab-icon svg { display: block; transition: transform .2s; }
  /* v1.3.3: 激活态——图标胶囊高亮 + 顶部悬浮小圆点 */
  .tab-item.active { color: var(--primary); font-weight: 700; }
  .tab-item.active .tab-icon {
    background: rgba(37, 99, 235, 0.13); 
    background: color-mix(in srgb, var(--primary) 13%, transparent);
    color: var(--primary);
  }
  .tab-item.active .tab-icon svg { transform: scale(1.12); }
  .tab-item.active::before {
    content: ""; position: absolute; top: -5px; left: 50%;
    width: 4px; height: 4px; border-radius: 50%;
    background: var(--primary); transform: translateX(-50%);
  }
  /* 底部留白，避免内容被 TAB 栏遮挡 */
  body { padding-bottom: 92px; }
  .float-btns { bottom: 104px; right: 14px; }
}

/* 移动端隐藏 PC 目录（文章内目录已显示） */
@media (max-width: 767px) {
  .single-sidebar { display: none; }
}

/* ============ v1.1.0: P0 可访问性修复 ============ */

/* P0-8: Skip link */
.skip-link {
  position: absolute; top: -100px; left: 8px; z-index: 9999;
  background: var(--primary); color: #fff; padding: 8px 16px;
  border-radius: 0 0 8px 8px; text-decoration: none; font-size: 14px;
  transition: top .2s;
}
.skip-link:focus { top: 0; color: #fff; }

/* P0-18: 键盘可见焦点 */
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

/* P0-17: 减少动态效果 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important; transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* P0-19: 次要文字对比度 (浅色 #9ca3af -> #6b7280, 深色 #6b7280 -> #8a94a6) */
/* 已在 :root 和 [data-theme="dark"] 中直接修改变量值 */

/* ============ v1.1.0: BEAUTIFY 美化 ============ */

/* B-2: 文章卡片紧凑化 */
.post-card { padding: 12px; }
.post-card-title { font-size: 15px; line-height: 1.45; letter-spacing: 0.01em; }
.post-card-excerpt { line-height: 1.55; }
.post-card-meta { font-size: 11px; gap: 8px; line-height: 1.4; }
@media (min-width: 768px) {
  .post-card { padding: 16px; }
}

/* B-4: 字体优化 */
.single-title { font-weight: 700; letter-spacing: 0.01em; }
.single-content { line-height: 1.8; }
button, .btn, .theme-promo-btn { letter-spacing: 0.05em; }

/* B-5: 点赞爱心实心/空心区分 */
.like-btn svg { transition: fill .2s; }
.like-btn.liked svg { fill: var(--primary); stroke: var(--primary); }
.meta-views { color: var(--text-3); }

/* B-7: 分类标签圆角统一 */
.cat-tag { border-radius: var(--radius); }

/* B-9: Logo 深色模式适配 (CSS filter 反白) */
[data-theme="dark"] .site-logo img { filter: brightness(0) invert(1); }

/* ============ v1.1.0: DESIGN 设计建议 ============ */

/* D-1: PC 端顶部横栏导航（v1.3.3: 改为 wp_nav_menu + 二级下拉） */
.pc-nav { display: none; align-items: center; margin-left: 8px; }
.pc-menu { display: flex; align-items: center; gap: 4px; margin: 0; padding: 0; list-style: none; }
.pc-menu > li { position: relative; }
.pc-menu a {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 8px 12px; border-radius: var(--radius-sm); color: var(--text-2);
  font-size: 14px; text-decoration: none; white-space: nowrap;
  transition: color .18s ease, background .18s ease;
}
.pc-menu > li > a:hover { color: var(--primary); background: var(--bg); }
.pc-menu > li > a.active,
.pc-menu .current-menu-item > a,
.pc-menu .current-menu-ancestor > a { color: var(--primary); font-weight: 600; }
.menu-caret { display: inline-flex; margin-left: -6px; color: var(--text-3); transition: transform .2s ease, color .18s ease; }
.menu-item-has-children:hover .menu-caret,
.menu-item-has-children.sub-open .menu-caret { transform: rotate(180deg); color: var(--primary); }
@media (min-width: 768px) { .pc-nav { display: flex; } }

/* D-5: 卡片悬停微动效 (仅 hover 设备) */
@media (hover: hover) {
  .post-card { transition: transform .2s ease, box-shadow .2s ease; }
  .post-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.12); }
  .post-card-thumb img { transition: transform .3s ease; }
  .post-card:hover .post-card-thumb img { transform: scale(1.03); }
}

/* D-6: 首页轻量 Hero (站点介绍条) */
.site-hero {
  background: var(--card); border-radius: var(--radius);
  padding: 16px 20px; margin-bottom: 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  box-shadow: var(--shadow);
}
.site-hero-text { font-size: 14px; color: var(--text-2); }
.site-hero-stats { display: flex; gap: 16px; font-size: 13px; color: var(--text-3); white-space: nowrap; }
.site-hero-stats strong { color: var(--primary); font-size: 16px; }

/* D-2: 搜索图标展开式 (PC) */
@media (min-width: 768px) {
  .header-search { max-width: 200px; transition: max-width .25s ease; }
  .header-search:focus-within { max-width: 320px; }
}

/* 深色模式精细调色 (D-3, 学 Blocksy 非简单反色) */


/* 上一篇/下一篇导航卡片 */
.post-nav {
  display: flex; gap: 12px; margin: 24px 0;
}
.post-nav-card {
  flex: 1; min-width: 0; display: block; padding: 14px 16px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius); text-decoration: none;
  transition: border-color .2s, transform .2s;
}
.post-nav-card:hover { border-color: var(--primary); }
.post-nav-card.post-nav-next { text-align: right; }
.post-nav-label { display: block; font-size: 12px; color: var(--text-3); margin-bottom: 4px; }
.post-nav-title {
  display: block; font-size: 14px; font-weight: 600; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.post-nav-card:hover .post-nav-title { color: var(--primary); }
@media (max-width: 767px) { .post-nav { flex-direction: column; } }

/* 分享按钮 */
.share-box { display: flex; align-items: center; gap: 8px; margin: 20px 0; flex-wrap: wrap; }
.share-label { font-size: 14px; color: var(--text-3); }.share-btn { display: inline-flex; align-items: center; gap: 4px; padding: 6px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); color: var(--text-2); font-size: 13px; cursor: pointer; }
.share-btn:hover { border-color: var(--primary); color: var(--primary); }

/* v1.3.3: 分享弹窗（替代一排按钮） */
.share-menu-wrap { position: relative; }
.share-popup {
  position: absolute; left: 0; bottom: calc(100% + 8px);
  min-width: 148px; padding: 6px; z-index: 80;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 10px 28px rgba(0,0,0,.14);
}
.share-popup[hidden] { display: none; }
.share-item {
  display: block; width: 100%; text-align: left; white-space: nowrap;
  padding: 9px 14px; border: 0; border-radius: var(--radius-sm); background: none;
  font-size: 14px; color: var(--text); cursor: pointer;
}
.share-item:hover { background: rgba(37, 99, 235, 0.1);  background: color-mix(in srgb, var(--primary) 10%, transparent); color: var(--primary); }
/* 微信扫码弹窗 */
.share-qr-overlay {
  position: fixed; inset: 0; z-index: 300; display: flex;
  align-items: center; justify-content: center; background: rgba(0,0,0,.55);
}
.share-qr-overlay[hidden] { display: none; }
.share-qr-card {
  background: var(--card); border-radius: var(--radius-lg); padding: 24px 28px; text-align: center;
  box-shadow: var(--shadow-lg);
}
.share-qr-title { font-size: 15px; color: var(--text); margin: 0 0 14px; }
.share-qr-card canvas { display: block; margin: 0 auto; border-radius: var(--radius-sm); }
.share-qr-close {
  margin-top: 16px; padding: 8px 28px; border: 1px solid var(--border); border-radius: 20px;
  background: var(--card); font-size: 14px; color: var(--text-2); cursor: pointer;
}
.share-qr-close:hover { border-color: var(--primary); color: var(--primary); }

/* v1.3.3: 作者卡片 */
.author-card {
  display: flex; gap: 16px; align-items: flex-start;
  margin: 24px 0; padding: 20px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.author-avatar img { border-radius: 50%; border: 3px solid rgba(37, 99, 235, 0.25);  border: 3px solid color-mix(in srgb, var(--primary) 25%, transparent); display: block; }
.author-info { flex: 1; min-width: 0; }
.author-name { font-size: 17px; font-weight: 700; margin-bottom: 6px; }
.author-bio { font-size: 14px; color: var(--text-2); line-height: 1.7; margin: 0 0 8px; }
.author-meta { font-size: 13px; color: var(--text-3); }

/* 归档页 */
.archive-page { max-width: 800px; margin: 0 auto; }
.archive-title { font-size: 24px; margin-bottom: 8px; }
.archive-stats { color: var(--text-3); font-size: 14px; margin-bottom: 24px; }
.archive-month { font-size: 18px; margin: 24px 0 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.archive-month .count { font-size: 14px; color: var(--text-3); font-weight: 400; }
.archive-list li { display: flex; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--border); font-size: 14px; }
.archive-date { color: var(--text-3); flex-shrink: 0; }
.archive-list a { color: var(--text); }
.archive-list a:hover { color: var(--primary); }

/* 搜索实时建议 */
.search-suggest {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 200;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); margin-top: 4px; overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,.12);
}
.search-suggest a {
  display: flex; justify-content: space-between; gap: 8px;
  padding: 10px 14px; font-size: 14px; color: var(--text);
  text-decoration: none; border-bottom: 1px solid var(--border);
}
.search-suggest a:last-child { border-bottom: none; }
.search-suggest a:hover { background: var(--bg); }
.ss-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-date { color: var(--text-3); font-size: 12px; flex-shrink: 0; }
.ss-limit { display: block; padding: 12px 14px; font-size: 13px; color: var(--text-2); text-align: center; }
.header-search, .drawer-search { position: relative; }

/* 打赏 */
.donate-box { text-align: center; margin: 24px 0; }
.donate-btn {
  padding: 10px 32px; border: none; border-radius: 24px;
  background: var(--primary); color: #fff; font-size: 15px; cursor: pointer;
}
.donate-qrcode { display: flex; gap: 20px; justify-content: center; margin-top: 16px; }
.donate-qrcode img { width: 160px; height: 160px; border-radius: var(--radius-sm); }
.donate-qrcode p { font-size: 13px; color: var(--text-3); margin-top: 4px; }

/* 分类加密 */
.encrypt-lock {
  max-width: 400px; margin: 60px auto; text-align: center;
  background: var(--card); padding: 32px; border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.encrypt-lock h2 { margin-bottom: 8px; }
.encrypt-lock p { color: var(--text-3); font-size: 14px; margin-bottom: 16px; }
#cat-pwd-form { display: flex; gap: 8px; }
#cat-pwd-input {
  flex: 1; height: 40px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0 12px; background: var(--bg); color: var(--text);
}
#cat-pwd-form button {
  padding: 0 20px; border: none; border-radius: var(--radius-sm);
  background: var(--primary); color: #fff; cursor: pointer;
}
.pwd-error { color: #dc2626 !important; margin-top: 8px !important; }

/* 用户中心 */
.user-auth { max-width: 400px; margin: 40px auto; background: var(--card); padding: 32px; border-radius: var(--radius); box-shadow: var(--shadow); }
.auth-tabs { display: flex; gap: 8px; margin-bottom: 20px; }.auth-tab { flex: 1; padding: 10px; border: none; background: var(--bg); border-radius: 8px; cursor: pointer; font-size: 15px; }
.auth-tab.active { background: var(--primary); color: #fff; }
.auth-form input { width: 100%; height: 42px; margin-bottom: 12px; padding: 0 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); color: var(--text); }
.auth-form button { width: 100%; height: 42px; border: none; border-radius: var(--radius-sm); background: var(--primary); color: #fff; font-size: 15px; cursor: pointer; }
.auth-error { color: #dc2626; font-size: 13px; margin-top: 8px; }
.user-center { max-width: 800px; margin: 0 auto; }
/* v1.3.0: 用户中心美化 - 渐变封面 */
.uc-cover { position: relative; border-radius: var(--radius); overflow: hidden; margin-bottom: 16px; box-shadow: var(--shadow); }
.uc-cover-bg { height: 140px; background: linear-gradient(135deg, var(--primary), #8b5cf6 60%, #ec4899); position: relative; }
.uc-cover-bg::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.25), transparent 50%); }.uc-profile { display: flex; align-items: center; gap: 16px; background: var(--card); padding: 0 20px 20px; margin-top: -32px; position: relative; }
.uc-avatar { position: relative; margin-top: -8px; }
.uc-avatar img { border-radius: 50%; border: 4px solid var(--card); box-shadow: 0 4px 16px rgba(0,0,0,.15); width: 88px; height: 88px; }
.uc-info { flex: 1; min-width: 0; }
.uc-info h2 { margin: 4px 0; font-size: 20px; }
.uc-meta { color: var(--text-3); font-size: 13px; margin: 0; }
.uc-bio { color: var(--text-2); font-size: 14px; margin: 6px 0 0; }
.uc-footer { text-align: center; padding: 24px 0 8px; }
.uc-logout-link { font-size: 13px; color: var(--text-3); text-decoration: none; }
.uc-logout-link:hover { color: var(--text-2); text-decoration: underline; }
.uc-stats { display: flex; background: var(--card); border-top: 1px solid var(--border); }
.uc-stat { flex: 1; text-align: center; padding: 14px 8px; }
.uc-stat + .uc-stat { border-left: 1px solid var(--border); }
.uc-stat strong { display: block; font-size: 22px; color: var(--primary); }
.uc-stat span { font-size: 12px; color: var(--text-3); }.uc-tabs { display: flex; gap: 0; margin-bottom: 0; overflow-x: auto; border-bottom: 1px solid var(--border); scrollbar-width: none; }
.uc-tab { position: relative; }
.uc-dot { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; line-height: 18px; text-align: center; background: var(--danger); color: #fff; font-size: 11px; font-style: normal; border-radius: 9px; padding: 0 5px; }
.uc-panel { background: var(--card); border-radius: var(--radius); padding: 8px 0; box-shadow: var(--shadow); }
.uc-item { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--border); }
.uc-item:last-child { border-bottom: none; }
.uc-item a { flex: 1; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uc-item a:hover { color: var(--primary); }
.uc-item-date { font-size: 12px; color: var(--text-3); flex-shrink: 0; }
.uc-notice { flex-wrap: wrap; }
.uc-notice-text { width: 100%; font-size: 13px; color: var(--text-2); margin-bottom: 4px; }
.uc-empty { text-align: center; color: var(--text-3); padding: 40px 20px; margin: 0; }
.uc-empty a { color: var(--primary); text-decoration: none; }
.uc-empty a:hover { text-decoration: underline; }
.uc-form { padding: 20px; }
.uc-form label { display: block; margin-bottom: 16px; font-size: 14px; color: var(--text-2); }
.uc-form input, .uc-form textarea { display: block; width: 100%; margin-top: 6px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); color: var(--text); font-size: 14px; box-sizing: border-box; }
.uc-form input:focus, .uc-form textarea:focus { outline: none; border-color: var(--primary); }
.uc-form-tip { font-size: 13px; color: var(--text-3); margin-top: 12px; }
.uc-header { display: flex; align-items: center; gap: 16px; background: var(--card); padding: 20px; border-radius: var(--radius); margin-bottom: 16px; }
.uc-header img { border-radius: 50%; }
.uc-header h2 { margin: 0 0 4px; }
.uc-header p { color: var(--text-3); font-size: 13px; margin: 0; }
.uc-header .btn { margin-left: auto; }
.uc-tab { padding: 8px 16px; border: 1px solid var(--border); background: var(--card); border-radius: var(--radius-sm); cursor: pointer; }
.uc-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.uc-panel { background: var(--card); border-radius: var(--radius); padding: 20px; }
.uc-item { padding: 10px 0; border-bottom: 1px solid var(--border); }
.uc-item:last-child { border-bottom: none; }
.uc-empty { color: var(--text-3); text-align: center; padding: 20px; }
#profile-form label { display: block; margin-bottom: 12px; font-size: 14px; }
#profile-form input, #profile-form textarea { width: 100%; margin-top: 4px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); color: var(--text); }
#profile-form button { padding: 10px 24px; border: none; border-radius: var(--radius-sm); background: var(--primary); color: #fff; cursor: pointer; }

/* ===== 分享海报弹窗 v1.2.2 ===== */
.jay-poster-overlay {
  position: fixed; inset: 0; z-index: 99990;
  background: rgba(2, 6, 23, 0.72);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; box-sizing: border-box;
  animation: jayPosterIn 0.22s ease-out;
}
@keyframes jayPosterIn {
  from { opacity: 0; } to { opacity: 1; }
}.jay-poster-modal { background: var(--card); border-radius: 20px; width: 380px; max-width: 100%; max-height: 92dvh; overflow-y: auto; box-shadow: 0 24px 80px rgba(0, 0, 0, 0.4); border: 1px solid var(--border); }
.jay-poster-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; font-size: 17px; font-weight: 700;
  color: var(--text, #1e293b);
  border-bottom: 1px solid var(--border, #e2e8f0);
  position: sticky; top: 0; background: inherit; z-index: 1;
}
.jay-poster-close {
  border: none; background: var(--bg-2, #f1f5f9); color: var(--text-2, #64748b);
  width: 34px; height: 34px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.jay-poster-close:hover { background: var(--bg-3, #e2e8f0); color: var(--text, #1e293b); }
.jay-poster-canvas-wrap { padding: 20px; display: flex; justify-content: center; }
.jay-poster-canvas {
  width: 100%; max-width: 320px; height: auto;
  border-radius: var(--radius); box-shadow: 0 8px 30px rgba(0, 0, 0, 0.18);
}
.jay-poster-actions { padding: 0 20px; }
.jay-poster-dl {
  width: 100%; height: 48px; border: none; border-radius: var(--radius);
  background: var(--primary, #2563eb); color: #fff;
  font-size: 16px; font-weight: 700; cursor: pointer;
}
.jay-poster-dl:hover { filter: brightness(1.07); }
.jay-poster-dl:disabled { opacity: 0.6; cursor: wait; }
.jay-poster-tip {
  text-align: center; color: var(--text-3, #94a3b8);
  font-size: 13px; padding: 12px 20px 20px; margin: 0;
}
@media (prefers-reduced-motion: reduce) {
  .jay-poster-overlay { animation: none; }
}

/* ============ v1.2.5: 页眉用户入口 ============ */
.user-entry { position: relative; flex-shrink: 0; }
.user-login-link {
  display: inline-flex; align-items: center; gap: 6px;
  height: 36px; padding: 0 14px; border: 1px solid var(--border);
  border-radius: 18px; background: var(--card); color: var(--text);
  font-size: 13px; text-decoration: none; white-space: nowrap;
}
.user-login-link:hover { border-color: var(--primary); color: var(--primary); }.user-avatar-btn { width: 36px; height: 36px; padding: 0; border: 1px solid var(--border); border-radius: 50%; background: var(--card); cursor: pointer; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; }
.user-avatar-btn:hover { border-color: var(--primary); }
.user-avatar-btn img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.user-dropdown {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 200;
  min-width: 180px; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: 0 8px 28px rgba(0,0,0,.14);
  padding: 8px; overflow: hidden;
}
.user-dropdown[hidden] { display: none; }
.user-dropdown-head {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px 12px; border-bottom: 1px solid var(--border);
  margin-bottom: 6px; font-weight: 600; font-size: 14px;
}
.user-dropdown-head img { width: 36px; height: 36px; border-radius: 50%; }
.user-dropdown a {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 10px; border-radius: var(--radius-sm); color: var(--text);
  font-size: 13px; text-decoration: none;
}
.user-dropdown a:hover { background: var(--bg); color: var(--primary); }
@media (max-width: 767px) {
  .user-login-text { display: none; }
  .user-login-link { padding: 0; width: 36px; height: 36px; border-radius: 50%; justify-content: center; }
}

/* ============ v1.2.5: 打赏二维码 hidden 修复 ============ */
/* 原 .donate-qrcode {display:flex} 会覆盖 hidden 属性，导致二维码常显 */
.donate-qrcode[hidden] { display: none; }
.donate-share-btn svg { vertical-align: -3px; margin-right: 2px; }
.donate-empty { color: var(--text-3); font-size: 13px; }
/* 旧版独立打赏框样式保留兼容 */
.donate-box { text-align: center; margin: 24px 0; }
.donate-btn {
  padding: 10px 32px; border: none; border-radius: 24px;
  background: var(--primary); color: #fff; font-size: 15px; cursor: pointer;
}

/* ============ v1.2.5: 移动端双列布局 ============ */
@media (max-width: 767px) {
  .post-list.cols-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .post-list.cols-2 .post-card { flex-direction: column; padding: 10px; gap: 8px; }
  .post-list.cols-2 .post-card-thumb { width: 100%; height: 108px; }
  .post-list.cols-2 .post-card-title { font-size: 13px; line-height: 1.4; }
  .post-list.cols-2 .post-card-excerpt { display: none; }
  .post-list.cols-2 .post-card-meta { font-size: 10px; gap: 6px; flex-wrap: wrap; }
  .post-list.cols-2 .post-card-meta .meta-views { display: none; }
  .post-list.cols-2 .post-card-meta .cat-tag { font-size: 10px; padding: 1px 6px; }
}

/* ============ v1.3.3: 首页杂志风布局（旧 4 列规则已废弃，见下方第一屏重构） ============ */
.mag-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .15s, box-shadow .15s;
}
.mag-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.mag-card-thumb { display: block; aspect-ratio: 1/1; /* v2.0.5: 精选小卡缩略图改方形（与截图同款） */ overflow: hidden; background: var(--bg); }
.mag-card-thumb img, .mag-card-thumb svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.mag-card-thumb .smart-thumb { display: block; width: 100%; height: 100%; }
.mag-card-title { font-size: 13px; font-weight: 600; line-height: 1.45; margin: 0; padding: 8px 10px 2px; }
.mag-card-title a {
  color: var(--text); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; /* v2.0.13: 标题改单行省略，彻底告别两行错位（杰哥建议） */
}
.mag-card-title a:hover { color: var(--primary); }
.mag-card-meta {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: var(--text-3); padding: 4px 10px 10px;
}
.mag-card-meta .meta-views { display: inline-flex; align-items: center; gap: 3px; }
@media (max-width: 767px) {
  .mag-card-title { font-size: 12px; }
}

/* ============ v1.2.5: 无缩略图卡片 ============ */
.post-card.no-thumb .post-card-content { padding-left: 2px; }.jay-login-read { margin: 28px 0; padding: 26px 24px; text-align: center; background: var(--card); border: 1px solid var(--border); border-radius: 12px; }
.jay-login-read-title { margin: 0 0 8px; font-size: 19px; font-weight: 700; color: var(--text); }
.jay-login-read-desc { margin: 0 0 18px; font-size: 14px; color: var(--text-2); }
.jay-login-read-btns { margin: 0; }
.jay-btn { display: inline-block; padding: 10px 26px; border-radius: 999px; font-size: 15px; font-weight: 600; text-decoration: none; border: 1px solid var(--border); color: var(--text); background: var(--card); transition: transform .15s ease, box-shadow .15s ease; }
.jay-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(2,6,23,.12); text-decoration: none; }
.jay-btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.jay-btn-primary:hover { color: #fff; }.jay-download-box { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 24px 0; padding: 16px 18px; border: 1px dashed var(--border); border-radius: 10px; background: var(--card); }
.jay-download-name { font-weight: 600; }
.jay-download-price { color: #b32d2e; font-weight: 700; }
.jay-download-btn { display: inline-block; padding: 8px 20px; border-radius: 999px; background: var(--primary); color: #fff; text-decoration: none; font-size: 14px; }

/* ========== v1.3.1: 页脚菜单 ========== */
.footer-nav { margin: 10px 0 4px; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; justify-content: center; }
.footer-nav a { color: var(--muted); font-size: 13px; text-decoration: none; }
.footer-nav a:hover { color: var(--primary); }

/* ========== v1.3.1: 小工具通用样式 ========== */
.home-sidebar .widget, .single-sidebar .widget { margin-bottom: 22px; }
.home-sidebar .widget ul, .single-sidebar .widget ul { list-style: none; margin: 0; padding: 0; }
.home-sidebar .widget li, .single-sidebar .widget li { padding: 7px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.home-sidebar .widget li:last-child, .single-sidebar .widget li:last-child { border-bottom: 0; }
.home-sidebar .widget a, .single-sidebar .widget a { color: var(--text); text-decoration: none; }
.home-sidebar .widget a:hover, .single-sidebar .widget a:hover { color: var(--primary); }
.home-sidebar .widget select, .single-sidebar .widget select { max-width: 100%; }
/* v1.3.3: 小工具 - 带缩略图热门文章 */
.widget-posts { list-style: none; margin: 0; padding: 0; }
.widget-posts li { padding: 8px 0; border-bottom: 1px dashed var(--border); }
.widget-posts li:last-child { border-bottom: 0; }
.widget-post-link { display: flex; gap: 10px; align-items: center; color: var(--text); text-decoration: none; }.widget-post-thumb { width: 56px; height: 56px; flex-shrink: 0; border-radius: 6px; overflow: hidden; background: var(--bg); }
.widget-post-thumb img, .widget-post-thumb svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.widget-post-text { min-width: 0; flex: 1; }
.widget-post-title { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; /* v2.0.13: 标题改单行省略，彻底告别两行错位（杰哥建议） */ font-size: 13.5px; line-height: 1.5; width: 100%; /* v2.0.10: span 行内元素同上 */ }
.widget-post-link:hover .widget-post-title { color: var(--primary); }
.widget-post-meta { display: block; margin-top: 4px; font-size: 12px; color: var(--text-3); }
/* v1.3.3: 小工具 - 站点统计 */
.widget-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; }.widget-stat { background: var(--bg); border-radius: 8px; padding: 12px 4px; }
.widget-stat b { display: block; font-size: 19px; font-weight: 800; color: var(--primary); line-height: 1.3; }
.widget-stat span { font-size: 12px; color: var(--text-3); }

/* ========== v1.3.1: 弹窗登录/注册 ========== */
.jay-auth-modal { position: fixed; inset: 0; z-index: 9999; background: rgba(10, 15, 30, 0.55); backdrop-filter: blur(4px); display: flex; align-items: center; justify-content: center; padding: 20px; }
.jay-auth-modal[hidden] { display: none; }
.jay-auth-card { position: relative; width: 100%; max-width: 380px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px 24px 24px; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25); animation: jay-modal-in 0.22s ease; max-height: calc(100dvh - 40px); overflow-y: auto; overscroll-behavior: contain; }
@keyframes jay-modal-in { from { opacity: 0; transform: translateY(14px) scale(0.98); } to { opacity: 1; transform: none; } }
.jay-auth-close { position: absolute; top: 10px; right: 12px; border: 0; background: none; color: var(--muted); font-size: 18px; cursor: pointer; padding: 6px; line-height: 1; }
.jay-auth-close:hover { color: var(--text); }.jay-auth-title { text-align: center; font-size: 20px; font-weight: 700; margin-bottom: 6px; letter-spacing: -0.02em; }
.jay-auth-tabs { display: flex; gap: 8px; margin-bottom: 16px; }.jay-modal-tab { flex: 1; border: 0; background: var(--bg); color: var(--text-2); padding: 10px; border-radius: 8px; font-size: 15px; cursor: pointer; }
.jay-modal-tab.active { background: var(--primary); color: #fff; font-weight: 600; }
.jay-auth-card .auth-form input { width: 100%; box-sizing: border-box; margin-bottom: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); color: var(--text); font-size: 16px; }
.jay-auth-card .auth-form button[type="submit"] { width: 100%; padding: 12px; border: 0; border-radius: 10px; background: var(--primary); color: #fff; font-size: 16px; font-weight: 600; cursor: pointer; }
.jay-auth-card .auth-form button[type="submit"]:hover { filter: brightness(1.08); }
@media (max-width: 480px) {
  .jay-auth-modal { align-items: flex-end; padding: 0; }
  .jay-auth-card { max-width: 100%; border-radius: 18px 18px 0 0; padding-bottom: calc(24px + env(safe-area-inset-bottom)); max-height: 88dvh; }
}

/* ============ v1.3.3: 导航下拉菜单重做 ============ */

/* 下拉子菜单 */
.pc-menu .sub-menu {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 210;
  min-width: 172px; margin: 0; padding: 6px; list-style: none;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .13);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .18s ease, transform .18s ease, visibility 0s .18s;
}
/* 隐形 hover 桥：鼠标从父项滑到子菜单不断开 */
.pc-menu .sub-menu::before { content: ""; position: absolute; top: -10px; left: 0; right: 0; height: 10px; }
.pc-menu .menu-item-has-children:hover > .sub-menu,
.pc-menu .menu-item-has-children:focus-within > .sub-menu,
.pc-menu .menu-item-has-children.sub-open > .sub-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
  transition: opacity .18s ease, transform .18s ease;
}
.pc-menu .sub-menu li { margin: 0; }
.pc-menu .sub-menu a {
  display: flex; align-items: center; width: 100%; box-sizing: border-box;
  padding: 9px 12px; border-radius: var(--radius-sm); font-size: 13px; color: var(--text);
}
.pc-menu .sub-menu a:hover { background: var(--bg); color: var(--primary); }
.pc-menu .sub-menu .current-menu-item > a { color: var(--primary); font-weight: 600; background: rgba(37, 99, 235, 0.08);  background: color-mix(in srgb, var(--primary) 8%, transparent); }

/* 抽屉用户信息卡片 */
.drawer-user { padding: 12px 16px 2px; }
.drawer-user-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px; border-radius: 14px; text-decoration: none;
  background: linear-gradient(135deg, var(--card), var(--card)); 
  background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 10%, var(--card)), var(--card));
  border: 1px solid var(--border);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.drawer-user-card:hover { border-color: var(--primary); box-shadow: 0 4px 14px rgba(0, 0, 0, .08); }
.drawer-user-card img.avatar { width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--primary); flex-shrink: 0; }
.drawer-user-ph {
  width: 46px; height: 46px; border-radius: 50%; flex-shrink: 0;
  background: var(--bg); border: 1px dashed var(--border);
  display: inline-flex; align-items: center; justify-content: center; color: var(--text-3);
}
.drawer-user-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.drawer-user-name { font-weight: 700; font-size: 15px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.drawer-user-tip { font-size: 12px; color: var(--text-3); }

/* v1.3.3: 页眉用户下拉美化（展开动画 + 头部质感） */
.user-dropdown:not([hidden]) { animation: jay-userdrop-in .18s ease; transform-origin: top right; }
@keyframes jay-userdrop-in {
  from { opacity: 0; transform: translateY(-6px) scale(.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.user-dropdown-head {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), transparent); 
  background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 12%, transparent), transparent);
  border-radius: var(--radius-sm);
}

/* ============ v1.3.3: 首页第一屏重构 - 精选推荐 + 快捷入口 ============ */
.home-sec-title { display: flex; align-items: center; gap: 6px; font-size: 17px; font-weight: 700; color: var(--text); margin: 2px 0 12px; padding-left: 10px; border-left: 3px solid var(--primary); }
.home-sec-title svg { color: var(--primary); flex: none; }

/* 精选区：PC 左大右小，手机上下 */
.feat-block { margin-bottom: 20px; }
.feat-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 12px; align-items: stretch; }
.feat-big { position: relative; border-radius: var(--radius); overflow: hidden; min-height: 300px; box-shadow: var(--shadow); background: var(--card); }
.feat-big-link { display: block; position: relative; height: 100%; min-height: 300px; }
.feat-big-link img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.feat-big-link .smart-thumb { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.feat-big-link .smart-thumb svg { width: 100%; height: 100%; display: block; }
.feat-big-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(0,0,0,.78) 100%); }
.feat-big-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }.feat-badge { font-size: 11px; font-weight: 700; color: #fff; background: rgba(0, 0, 0, .6); border-radius: 999px; padding: 3px 8px; border: 1px solid rgba(255, 255, 255, .2); }
.feat-big-title { color: #fff; font-size: 20px; font-weight: 700; line-height: 1.4; margin: 0; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; /* v2.0.13: 标题改单行省略，彻底告别两行错位（杰哥建议） */ }
.feat-big-meta { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: rgba(255,255,255,.85); }
.feat-big-meta svg { vertical-align: -2px; }
.feat-big-link:hover .feat-big-title { text-decoration: underline; }
.feat-smalls { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-content: stretch; }
.feat-smalls .mag-card { height: 100%; margin: 0; }

/* ---------- v1.4.0/v2.0.0: 缩略图跟随主题色（仅 jay_thumb_color_mode=theme 时生效） ---------- */
/* v2.0.0: 渐变方案下用 stop[offset] 选择器重写 SVG 渐变停色为主题色淡色；
   右下角调色板 / 深色模式切换时自动生效，无需 JS；
   默认 8 色轮转模式下 body 无 jay-thumb-theme 类，以下规则不生效。
   精选大卡停色深（62%→30%）、列表卡停色浅（55%→28%），形成层次；
   淡底上的关键词改用深主题色，保证可读性（深色模式同样适用） */
body.jay-thumb-theme .feat-block .smart-thumb stop[offset="0"] { stop-color: color-mix(in srgb, var(--primary) 62%, white); }
body.jay-thumb-theme .feat-block .smart-thumb stop[offset="1"] { stop-color: color-mix(in srgb, var(--primary) 30%, white); }
body.jay-thumb-theme .post-card-thumb .smart-thumb stop[offset="0"] { stop-color: color-mix(in srgb, var(--primary) 55%, white); }
body.jay-thumb-theme .post-card-thumb .smart-thumb stop[offset="1"] { stop-color: color-mix(in srgb, var(--primary) 28%, white); }
/* v2.0.7 P1-14: 小工具缩略图此前漏了停色重写——文字已是全局深色，背景却仍是深色渐变，深字落深底对比度差；补与文章卡片同配比 */
body.jay-thumb-theme .widget-post-thumb .smart-thumb stop[offset="0"] { stop-color: color-mix(in srgb, var(--primary) 55%, white); }
body.jay-thumb-theme .widget-post-thumb .smart-thumb stop[offset="1"] { stop-color: color-mix(in srgb, var(--primary) 28%, white); }
body.jay-thumb-theme .smart-thumb text { fill: color-mix(in srgb, var(--primary) 72%, black); }

/* 快捷入口 */
.quick-links { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 20px; }
.qlink { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; min-width: 0; text-decoration: none; }
.qlink:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.08); }.qlink-icon { width: 40px; height: 40px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.ql-blue .qlink-icon { background: rgba(59, 130, 246, 0.13);  background: color-mix(in srgb, #3b82f6 13%, transparent); color: #3b82f6; }
.ql-green .qlink-icon { background: rgba(16, 185, 129, 0.13);  background: color-mix(in srgb, #10b981 13%, transparent); color: #10b981; }
.ql-purple .qlink-icon { background: rgba(139, 92, 246, 0.13);  background: color-mix(in srgb, #8b5cf6 13%, transparent); color: #8b5cf6; }
.ql-orange .qlink-icon { background: rgba(245, 158, 11, 0.15);  background: color-mix(in srgb, var(--warning) 15%, transparent); color: #d97706; }
.qlink-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.qlink-text b { font-size: 14px; font-weight: 700; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qlink-text i { font-style: normal; font-size: 12px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qlink > svg { color: var(--text-3); flex: none; }

@media (max-width: 767px) {
  .feat-grid { grid-template-columns: 1fr; }
  .feat-big, .feat-big-link { min-height: 220px; }
  .feat-big-title { font-size: 17px; }
  .feat-big-body { padding: 12px; }
  .quick-links { grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 16px; }
  .qlink { padding: 10px 12px; }
  .qlink-icon { width: 36px; height: 36px; }
  .home-sec-title { font-size: 16px; margin-bottom: 10px; }
}

/* ============ v1.3.4: 付费前台 ============ */
/* 购买按钮 */
.jay-buy-wrap { margin: 20px 0 8px; text-align: center; }
.jay-buy-btn { display: inline-block; border: 0; cursor: pointer; background: var(--primary); color: #fff; font-size: 16px; font-weight: 600; padding: 12px 36px; border-radius: 24px; box-shadow: 0 6px 18px rgba(37, 99, 235, 0.35);  box-shadow: 0 6px 18px color-mix(in srgb, var(--primary) 35%, transparent); transition: transform .15s ease, box-shadow .15s ease; }
.jay-buy-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(37, 99, 235, 0.45);  box-shadow: 0 10px 24px color-mix(in srgb, var(--primary) 45%, transparent); }
.jay-buy-btn:active { transform: scale(.97); }
.jay-buy-tip { margin: 10px 0 0; font-size: 13px; color: var(--muted); }

/* 积分兑换（v1.5.0） */
.jay-credit-wrap { margin: 16px 0; text-align: center; }.jay-credit-btn { display: inline-block; border: 0; cursor: pointer; background: linear-gradient(135deg, #7c3aed, #a855f7); color: #fff; font-size: 16px; font-weight: 600; padding: 12px 36px; border-radius: 24px; box-shadow: none; transition: transform .15s ease, box-shadow .15s ease; }
.jay-credit-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(124, 58, 237, .45); }
.jay-credit-btn:active { transform: scale(.97); }
.jay-credit-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.jay-credit-btn-sm { font-size: 14px; padding: 8px 20px; border-radius: 18px; }
.jay-credit-tip { margin: 8px 0 0; font-size: 13px; color: var(--muted); }

/* 支付弹窗 */
.jay-pay-modal { position: fixed; inset: 0; z-index: 9999; background: rgba(10,15,30,.55); backdrop-filter: blur(4px); display: flex; align-items: center; justify-content: center; padding: 20px; }
.jay-pay-modal[hidden] { display: none; }
.jay-pay-card { position: relative; width: 100%; max-width: 360px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px 22px 20px; box-shadow: 0 24px 60px rgba(0,0,0,.25); animation: jay-modal-in .22s ease; text-align: center; }
.jay-pay-close { position: absolute; top: 10px; right: 12px; border: 0; background: none; font-size: 24px; line-height: 1; color: var(--muted); cursor: pointer; }
.jay-pay-title { margin: 0 0 4px; font-size: 18px; }
.jay-pay-amount { margin: 0 0 12px; font-size: 28px; font-weight: 700; color: var(--primary); }
.jay-pay-tabs { display: flex; gap: 8px; margin-bottom: 14px; }.jay-pay-tab { flex: 1; border: 1px solid var(--border); background: var(--bg); color: var(--muted); padding: 9px; border-radius: 8px; font-size: 14px; cursor: pointer; }
.jay-pay-tab.active { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.jay-pay-qr { display: none; }
.jay-pay-qr.active { display: block; }
.jay-pay-qr img { width: 200px; height: 200px; object-fit: contain; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.jay-pay-noqr { color: var(--muted); font-size: 14px; padding: 40px 10px; }
.jay-pay-desc { margin: 12px 0; font-size: 14px; color: var(--text); }
.jay-pay-confirm { width: 100%; border: 0; cursor: pointer; background: var(--primary); color: #fff; font-size: 16px; font-weight: 600; padding: 12px; border-radius: var(--radius); }
.jay-pay-confirm:disabled { opacity: .6; cursor: wait; }
.jay-pay-tip { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
/* v2.0.7 NEW-1: Toast（替代订单流程的 alert，避免阻塞弹窗；用主题自己的卡片/圆角/阴影） */
.jay-toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 10000;
  transform: translateX(-50%) translateY(16px);
  max-width: min(420px, calc(100vw - 32px));
  background: var(--card); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0,0,0,.18);
  padding: 12px 18px; font-size: 14px; line-height: 1.5; text-align: center;
  opacity: 0; pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
.jay-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.jay-toast-error { border-color: var(--danger); }

/* VIP 徽章 */
.jay-vip-badge { display: inline-block; vertical-align: middle; font-size: 11px; font-weight: 700; line-height: 1; padding: 3px 8px; border-radius: 999px; margin-left: 6px; color: #fff; }.jay-vip-vip { background: linear-gradient(135deg, var(--warning), #d97706); }.jay-vip-svip { background: linear-gradient(135deg, #8b5cf6, #d946ef); }.jay-admin-badge { display: inline-block; vertical-align: middle; font-size: 11px; font-weight: 700; line-height: 1; padding: 3px 8px; border-radius: 999px; margin-left: 8px; color: #fff; background: #dc2626; }

/* 商城 */
.shop-wrap { max-width: 1100px; margin: 0 auto; padding: 24px 16px 48px; }
.shop-closed, .shop-empty { text-align: center; color: var(--muted); padding: 60px 20px; }
.shop-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.shop-title { margin: 0; font-size: 24px; }
.shop-back { color: var(--primary); font-size: 14px; }
.shop-cart-btn { position: relative; border: 1px solid var(--border); background: var(--card); color: var(--text); width: 44px; height: 44px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.shop-cart-count { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; line-height: 20px; text-align: center; background: var(--danger); color: #fff; font-size: 12px; font-weight: 700; border-radius: 10px; padding: 0 5px; }
.shop-cart-count[hidden] { display: none; }
.shop-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 900px) { .shop-grid { grid-template-columns: repeat(2, 1fr); } }
.shop-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: transform .15s ease, box-shadow .15s ease; }
.shop-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,.08); }
.shop-card-img { display: block; aspect-ratio: 1; overflow: hidden; background: var(--bg); }
.shop-card-img img { width: 100%; height: 100%; object-fit: cover; }
.shop-noimg { width: 100%; height: 100%; min-height: 120px; display: flex; align-items: center; justify-content: center; color: var(--muted); background: var(--bg); font-size: 14px; }
.shop-card-body { padding: 12px; }
.shop-card-title { display: block; font-weight: 600; color: var(--text); margin-bottom: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shop-card-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 13px; }
.shop-card-price { color: var(--danger); font-weight: 700; font-size: 16px; }
.shop-card-stock { color: var(--muted); }
.shop-card-stock .out { color: var(--danger); }
.shop-btn { display: inline-block; border: 0; cursor: pointer; background: var(--primary); color: #fff; font-size: 14px; font-weight: 600; padding: 9px 18px; border-radius: 20px; }
.shop-btn:disabled { opacity: .5; cursor: not-allowed; }
.shop-card .shop-btn { width: 100%; }
.shop-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 24px; }
@media (max-width: 700px) { .shop-detail { grid-template-columns: 1fr; } }
.shop-detail-img img { width: 100%; border-radius: 10px; }
.shop-detail-price { font-size: 28px; font-weight: 700; color: var(--danger); margin-bottom: 8px; }
.shop-detail-stock { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.shop-detail-stock .out { color: var(--danger); font-weight: 600; }
.shop-detail-desc { margin-bottom: 20px; line-height: 1.7; }
.shop-detail-actions { display: flex; gap: 12px; }
.shop-buy-now { background: var(--danger); }
/* 购物车抽屉 */
.shop-cart-drawer { position: fixed; inset: 0; z-index: 9998; background: rgba(10,15,30,.5); display: flex; justify-content: flex-end; }
.shop-cart-drawer[hidden] { display: none; }
.shop-cart-panel { width: 100%; max-width: 380px; height: 100%; background: var(--card); display: flex; flex-direction: column; animation: jay-cart-in .25s ease; }
@keyframes jay-cart-in { from { transform: translateX(100%); } to { transform: none; } }
.shop-cart-head { display: flex; align-items: center; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--border); }
.shop-cart-head h3 { margin: 0; font-size: 17px; }
.shop-cart-close { border: 0; background: none; font-size: 26px; color: var(--muted); cursor: pointer; line-height: 1; }
.shop-cart-items { flex: 1; overflow-y: auto; padding: 12px 16px; }
.shop-cart-empty { text-align: center; color: var(--muted); padding: 40px 0; }
.shop-cart-item { display: flex; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.shop-cart-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shop-cart-price { color: var(--muted); }
.shop-cart-qty { display: flex; align-items: center; gap: 6px; }
.shop-cart-qty button { width: 24px; height: 24px; border: 1px solid var(--border); background: var(--bg); border-radius: 6px; cursor: pointer; font-size: 14px; line-height: 1; }
.shop-cart-sub { font-weight: 600; min-width: 64px; text-align: right; }
.shop-cart-del { border: 0; background: none; color: var(--muted); font-size: 20px; cursor: pointer; }
.shop-cart-foot { padding: 16px; border-top: 1px solid var(--border); }
.shop-cart-total { font-size: 16px; font-weight: 700; margin-bottom: 12px; text-align: right; }
.shop-checkout { width: 100%; padding: 12px; font-size: 16px; }
/* 用户中心订单 */
.uc-order { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.uc-order-title { flex: 1; min-width: 140px; }
.uc-order-amount { font-weight: 700; color: var(--danger); }
.uc-order-status { font-size: 12px; padding: 2px 8px; border-radius: var(--radius-sm); }
.uc-order-status.st-pending { background: #fef3c7; color: #b45309; }
.uc-order-status.st-paid { background: #d1fae5; color: #047857; }
.uc-order-status.st-cancelled { background: #f3f4f6; color: #6b7280; }

/* ---------- v1.5.0: 我的文章 ---------- */
.uc-mypost-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }.uc-badge { font-size: 12px; padding: 2px 8px; border-radius: 6px; flex-shrink: 0; }
.uc-badge.st-publish { background: #d1fae5; color: #047857; }
.uc-badge.st-pending { background: #fef3c7; color: #b45309; }
.uc-badge.st-draft { background: #f3f4f6; color: #6b7280; }
/* v1.6.0: 状态徽章深色模式适配 */
[data-theme="dark"] .uc-badge.st-publish { background: rgba(16,185,129,.15); color: #34d399; }
[data-theme="dark"] .uc-badge.st-pending { background: rgba(245,158,11,.15); color: #fbbf24; }
[data-theme="dark"] .uc-badge.st-draft { background: rgba(107,114,128,.15); color: #9ca3af; }
.uc-mypost-views { font-size: 12px; color: var(--text-3); flex-shrink: 0; }
.uc-mypost-edit { font-size: 13px; color: var(--primary); flex-shrink: 0; text-decoration: none; }
.uc-mypost-edit:hover { text-decoration: underline; }
.uc-pager { display: flex; gap: 8px; justify-content: center; padding: 16px 0 8px; }
.uc-pager-cur, .uc-pager-link { min-width: 32px; height: 32px; line-height: 32px; text-align: center;
  border-radius: var(--radius-sm); font-size: 14px; }
.uc-pager-cur { background: var(--primary); color: #fff; font-weight: 700; }
.uc-pager-link { background: var(--bg); color: var(--text-2); text-decoration: none; border: 1px solid var(--border); }
.uc-pager-link:hover { border-color: var(--primary); color: var(--primary); }

/* ---------- v1.4.0: 预设头像 ---------- */
.jay-avatar {
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; line-height: 1; flex: none;
  text-shadow: 0 1px 3px rgba(0,0,0,.25); user-select: none;
}
/* 各场景沿用旧 img 头像的装饰（描边/尺寸） */
.author-avatar .jay-avatar { border: 3px solid rgba(37, 99, 235, 0.25);  border: 3px solid color-mix(in srgb, var(--primary) 25%, transparent); }
.uc-avatar .jay-avatar { border: 4px solid var(--card); box-shadow: 0 4px 16px rgba(0,0,0,.15); }
.user-avatar-btn .jay-avatar { width: 100% !important; height: 100% !important; font-size: 15px !important; }
.user-dropdown-head .jay-avatar { width: 36px !important; height: 36px !important; font-size: 15px !important; border: 2px solid var(--border); }
.drawer-user-card .jay-avatar { width: 46px !important; height: 46px !important; font-size: 19px !important; border: 2px solid var(--primary); flex-shrink: 0; }
.uc-avatar .jay-avatar { width: 88px !important; height: 88px !important; font-size: 37px !important; }
.comment-list .jay-avatar { float: left; margin-right: 10px; }
/* v2.0.4: 头像跟随主题——深色下换 8 套深色渐变（同色相、降明度），变化看得见；白字不变。
   用 data-from 匹配配色，!important 压过内联渐变；头像与选色器色块同步变深。
   （v2.0.3 的 brightness(.82) filter 太淡，看不出变化，且会把白字变灰，已删。） */
[data-theme="dark"] [data-from="#60a5fa"] { background: linear-gradient(135deg, #1d4ed8, #1e3a8a) !important; }
[data-theme="dark"] [data-from="#22d3ee"] { background: linear-gradient(135deg, #0e7490, #155e75) !important; }
[data-theme="dark"] [data-from="#4ade80"] { background: linear-gradient(135deg, #15803d, #14532d) !important; }
[data-theme="dark"] [data-from="#a3e635"] { background: linear-gradient(135deg, #4d7c0f, #365314) !important; }
[data-theme="dark"] [data-from="#fb923c"] { background: linear-gradient(135deg, #c2410c, #7c2d12) !important; }
[data-theme="dark"] [data-from="#f87171"] { background: linear-gradient(135deg, #b91c1c, #7f1d1d) !important; }
[data-theme="dark"] [data-from="#a78bfa"] { background: linear-gradient(135deg, #6d28d9, #4c1d95) !important; }
[data-theme="dark"] [data-from="#f472b6"] { background: linear-gradient(135deg, #be185d, #831843) !important; }
/* 资料页头像选择器 */
.uc-avatar-edit { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 18px; }
.uc-avatar-preview { flex: none; }
.uc-avatar-pick { flex: 1; min-width: 0; }
.uc-avatar-label { font-size: 14px; font-weight: 700; margin: 0 0 10px; }
.uc-avatar-tip { font-weight: 400; font-size: 12px; color: var(--text-3); }
.avatar-picker { display: grid; grid-template-columns: repeat(8, 1fr); gap: 8px; max-width: 420px; }
.avatar-opt {
  aspect-ratio: 1; border: 2px solid transparent; cursor: pointer; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 15px; line-height: 1;
  text-shadow: 0 1px 3px rgba(0,0,0,.25);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.avatar-opt:hover { transform: scale(1.12); }
.avatar-opt.on { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 30%, transparent); }
@media (max-width: 560px) {
  .uc-avatar-edit { flex-direction: column; }
  .avatar-picker { grid-template-columns: repeat(8, 1fr); max-width: none; }
}.jay-rank-tabs { display: flex; gap: 0; margin-bottom: 16px; border-bottom: 1px solid var(--border); }.jay-rank-tab { padding: 10px 14px; border-radius: 0; font-size: 14px; font-weight: 700; color: var(--text-2); background: transparent; text-decoration: none; border: none; transition: all .15s ease; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.jay-rank-tab:hover { color: var(--primary); border-color: var(--primary); }
.jay-rank-tab.active { color: #fff; background: var(--primary); border-color: var(--primary); }
.jay-rank-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.jay-rank-item {
  display: flex; align-items: center; gap: 14px;
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 16px;
}
.jay-rank-no {
  flex: none; width: 32px; height: 32px; border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 800; color: var(--text-3); background: var(--card, #f1f3f7);
}
.jay-rank-item.jay-rank-top1 .jay-rank-no { color: #fff; background: linear-gradient(135deg, #f6c453, #e08e0b); }
.jay-rank-item.jay-rank-top2 .jay-rank-no { color: #fff; background: linear-gradient(135deg, #cfd8e3, #8fa0b8); }
.jay-rank-item.jay-rank-top3 .jay-rank-no { color: #fff; background: linear-gradient(135deg, #e0a080, #b0653a); }
.jay-rank-avatar { flex: none; width: 44px; height: 44px; border-radius: 50%; overflow: hidden; }
.jay-rank-avatar img, .jay-rank-avatar svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.jay-rank-main { min-width: 0; flex: 1; }
.jay-rank-main a { color: var(--text); font-weight: 700; font-size: 15px; text-decoration: none; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jay-rank-main a:hover { color: var(--primary); }
.jay-rank-name { font-weight: 700; font-size: 15px; color: var(--text); }
.jay-rank-sub { display: block; margin-top: 4px; font-size: 12.5px; color: var(--text-3); }
.jay-rank-empty { padding: 30px 0; text-align: center; color: var(--text-3); }
.jay-rank-off { padding: 30px 0; text-align: center; color: var(--text-3); }
.jay-rank-note { margin-top: 16px; font-size: 12px; color: var(--text-3); text-align: center; }
/* 小工具内榜单更紧凑 */
.widget .jay-rank-item { padding: 8px 10px; gap: 10px; }
.widget .jay-rank-no { width: 26px; height: 26px; font-size: 13px; }
.widget .jay-rank-main a, .widget .jay-rank-name { font-size: 13.5px; }
.widget .jay-rank-avatar { width: 34px; height: 34px; }
@media (max-width: 560px) {
  .jay-rank-item { padding: 10px 12px; gap: 10px; }
  .jay-rank-main a { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; /* v2.0.13: 标题改单行省略，彻底告别两行错位（杰哥建议） */ }
}.signin-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 28px 20px; text-align: center; }
.signin-stats { display: flex; justify-content: center; gap: 48px; margin-bottom: 22px; }
.signin-stat strong { display: block; font-size: 32px; color: var(--primary); }
.signin-stat span { font-size: 13px; color: var(--text-3); }
.signin-btn { display: inline-block; min-width: 220px; padding: 14px 40px; font-size: 17px; font-weight: 600; color: #fff; background: var(--primary); border: none; border-radius: 999px; cursor: pointer; transition: transform .15s, opacity .15s; }
.signin-btn:hover:not(:disabled) { transform: translateY(-2px); }
.signin-btn:disabled { cursor: default; }
.signin-btn.is-signed { background: var(--border); color: var(--text-3); }
.signin-btn.is-loading { opacity: .7; }
.signin-tip { margin-top: 14px; font-size: 14px; min-height: 20px; color: var(--text-3); }
.signin-tip.ok { color: var(--success); font-weight: 600; animation: signin-pop .4s ease; }
.signin-tip.err { color: #dc2626; }
@keyframes signin-pop { 0% { transform: scale(.8); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* ---------- v1.5.0: 积分明细 ---------- */
.credit-head { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 14px; }
.credit-balance { display: flex; align-items: baseline; gap: 12px; }
.credit-balance span { font-size: 14px; color: var(--text-3); }
.credit-balance strong { font-size: 30px; color: var(--primary); }
.credit-table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); }
.credit-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.credit-table th, .credit-table td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); }
.credit-table thead th { background: var(--bg); color: var(--text-3); font-weight: 600; font-size: 13px; }
.credit-table tbody tr:last-child td { border-bottom: none; }
/* v1.5.0: 每日任务 */
.task-list { display: flex; flex-direction: column; gap: 12px; }
.task-item { display: flex; align-items: center; justify-content: space-between; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; }
.task-item.is-done { border-color: var(--primary); background: var(--card);  background: color-mix(in srgb, var(--primary) 6%, var(--card)); }
.task-info strong { display: block; font-size: 15px; margin-bottom: 4px; }
.task-info span { font-size: 13px; color: var(--text-3); }
.task-badge { font-size: 12px; color: var(--text-3); background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 2px 8px; white-space: nowrap; }
.task-item.is-done .task-badge { color: var(--primary); border-color: var(--primary); }
.task-link { margin-top: 16px; text-align: center; }
.task-link a { color: var(--primary); font-size: 14px; text-decoration: none; }
.task-link a:hover { text-decoration: underline; }
.credit-time { white-space: nowrap; color: var(--text-3); }
.credit-amt { font-weight: 700; white-space: nowrap; }
.credit-amt.plus { color: var(--success); }
.credit-amt.minus { color: #dc2626; }
.credit-note { color: var(--text-3); max-width: 220px; }
.credit-pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 14px; }
.credit-page-btn { padding: 8px 18px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--card); color: var(--text); font-size: 14px; text-decoration: none; }
.credit-page-btn:hover { border-color: var(--primary); color: var(--primary); }
.credit-pageno { font-size: 13px; color: var(--text-3); }

/* ---------- v1.5.0: 专题合集 ---------- */
.jay-topic-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 0 0 24px; }
.jay-topic-card { display: block; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; }
.jay-topic-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.jay-topic-card-cover { height: 150px; display: flex; align-items: center; justify-content: center; }
.jay-topic-card-kw { font-size: 44px; font-weight: 800; color: #fff; }
.jay-topic-card-body { padding: 14px 16px 16px; }
.jay-topic-card-title { font-size: 17px; margin-bottom: 4px; color: var(--text); }
.jay-topic-card-count { font-size: 13px; color: var(--primary); font-weight: 600; margin-bottom: 6px; }
.jay-topic-card-desc { font-size: 13px; color: var(--text-3); line-height: 1.6; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; /* v2.0.14: 摘要恢复两行截断（v2.0.13 误伤） */ }
.jay-topic-cover { border-radius: var(--radius); padding: 48px 28px; margin-bottom: 20px; color: #fff; position: relative; overflow: hidden; }
/* v2.0.0: 渐变封面 + 白字 */
.jay-topic-cover .jay-topic-title { color: #fff; }
.jay-topic-cover .jay-topic-count { color: #fff; }
.jay-topic-cover .jay-topic-badge { background: rgba(255,255,255,.12); color: #fff; }
.jay-topic-badge { display: inline-block; font-size: 12px; background: rgba(255,255,255,.25); padding: 2px 8px; border-radius: var(--radius-sm); margin-bottom: 10px; }
.jay-topic-title { font-size: 28px; margin-bottom: 8px; color: #fff; }
.jay-topic-count { font-size: 14px; opacity: .9; }
.jay-topic-list-title { font-size: 18px; font-weight: 700; margin: 24px 0 12px; }
.jay-topic-list { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.jay-topic-item { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.jay-topic-item:last-child { border-bottom: none; }
.jay-topic-item:hover { background: var(--bg); }.jay-topic-num { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--bg); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; color: var(--text-2); }
.jay-topic-item-main { flex: 1; min-width: 0; }
.jay-topic-item-title { font-size: 16px; color: var(--text); font-weight: 600; }
.jay-topic-item-title:hover { color: var(--primary); }
.jay-topic-item-meta { font-size: 12px; color: var(--text-3); margin-top: 4px; display: flex; gap: 12px; flex-wrap: wrap; }
.jay-topic-empty { padding: 24px; text-align: center; color: var(--text-3); }
.jay-topic-intro { margin-bottom: 8px; }
@media (max-width: 900px) { .jay-topic-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .jay-topic-grid { grid-template-columns: 1fr; }
  .jay-topic-cover { padding: 36px 20px; }
  .jay-topic-title { font-size: 22px; }
}

/* ---------- v1.5.0: 问答社区 ---------- */
.jay-qa-off, .jay-qa-empty { color: var(--text-3); padding: 20px 0; }
.jay-qa-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }.jay-qa-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); }.jay-qa-tab { padding: 10px 14px; border: none; border-radius: 0; color: var(--text-2); font-size: 14px; text-decoration: none; background: transparent; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.jay-qa-tab:hover { color: var(--primary); border-color: var(--primary); }
.jay-qa-tab.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.jay-qa-ask-btn { display: inline-block; padding: 8px 20px; border-radius: 20px; background: var(--primary); color: #fff; font-size: 14px; text-decoration: none; border: none; cursor: pointer; }
.jay-qa-ask-btn:hover { opacity: .9; color: #fff; }
.jay-qa-list { display: flex; flex-direction: column; gap: 10px; }.jay-qa-row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; text-decoration: none; color: var(--text); }
.jay-qa-row:hover { border-color: var(--primary); }.jay-qa-status { flex-shrink: 0; font-size: 12px; padding: 3px 10px; border-radius: 6px; }
.jay-qa-status.unsolved { background: rgba(234, 88, 12, .12); color: #ea580c; }
.jay-qa-status.solved { background: rgba(22, 163, 74, .12); color: var(--success); }
.jay-qa-main { flex: 1; min-width: 0; }
.jay-qa-title { display: block; font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.jay-qa-meta { display: flex; gap: 12px; font-size: 12px; color: var(--text-3); margin-top: 4px; }
.jay-qa-arrow { color: var(--text-3); font-size: 20px; flex-shrink: 0; }
.jay-qa-pager { margin-top: 18px; text-align: center; }
.jay-qa-pager .page-numbers { display: inline-block; padding: 6px 12px; margin: 0 3px; border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text-2); text-decoration: none; font-size: 14px; }
.jay-qa-pager .page-numbers.current { background: var(--primary); border-color: var(--primary); color: #fff; }
.jay-qa-single-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 8px; }
.jay-qa-single-head .single-title { margin: 0; }
.jay-qa-single-head .jay-qa-status { margin-top: 6px; }
.jay-qa-answers-head { display: flex; align-items: center; justify-content: space-between; margin: 28px 0 6px; }
.jay-qa-answers-head h2 { font-size: 17px; margin: 0; }
.jay-qa-answer-btn { font-size: 13px; color: var(--primary); text-decoration: none; }.jay-best-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(22, 163, 74, .12); color: var(--success); font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 6px; margin-bottom: 8px; }
.jay-best-check { font-weight: 700; }
li.jay-has-best > .comment-body, .comment.jay-has-best .comment-text { border-left: 3px solid var(--success); }
.jay-best-action { margin-top: 8px; }.jay-mark-best { font-size: 12px; padding: 5px 14px; border: 1px solid var(--success); background: transparent; color: var(--success); border-radius: 14px; cursor: pointer; border-color: var(--success); }
.jay-mark-best:hover { background: var(--success); color: #fff; }
.jay-mark-best:disabled { opacity: .6; cursor: default; }
.jay-ask-form .jay-ask-field { margin-bottom: 16px; }
.jay-ask-form label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 14px; }
.jay-ask-form .required { color: #dc2626; }
.jay-ask-form input[type="text"] { width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--card); color: var(--text); font-size: 15px; box-sizing: border-box; }
.jay-ask-tip { font-size: 13px; color: var(--text-3); }.jay-ask-notice { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.jay-ask-notice.ok { background: rgba(22, 163, 74, .1); color: var(--success); }
.jay-ask-notice.err { background: rgba(220, 38, 38, .08); color: #dc2626; }
.jay-qa-login-tip { color: var(--text-3); }
@media (max-width: 640px) {
  .jay-qa-meta { flex-wrap: wrap; gap: 8px; }
  .jay-qa-title { white-space: normal; }
  .jay-qa-toolbar { flex-direction: column; align-items: stretch; }
  .jay-qa-ask-btn { text-align: center; }
}
.jay-credit-tip-sm { font-size: 12px; color: var(--muted); margin-left: 6px; }

/* ============ v1.6.0: 教程短代码 ============ */
/* --- 警告框 --- */
.jay-warn { margin: 1.4em 0; padding: 14px 16px 14px 50px; border-radius: var(--radius); background: #fff8e1; border: 1px solid #f0d24a; color: #7a5c00; position: relative; font-size: 15px; line-height: 1.7; }
.jay-warn::before { content: "\26A0\FE0F"; position: absolute; left: 16px; top: 13px; font-size: 20px; line-height: 1; }
.jay-warn p:last-child { margin-bottom: 0; }
[data-theme="dark"] .jay-warn { background: rgba(255, 193, 7, .12); border-color: rgba(255, 193, 7, .35); color: #ffd97a; }
/* --- 步骤序号 --- */
.jay-steps { list-style: none; margin: 1.4em 0; padding: 0; }
.jay-step { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px dashed var(--border); }
.jay-step:last-child { border-bottom: 0; }
.jay-step-num { flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%; background: var(--primary); color: var(--primary-text); font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 15px; }
.jay-step-title { font-weight: 700; margin-bottom: 6px; color: var(--text); }
.jay-step-text { color: var(--text-2); font-size: 15px; line-height: 1.7; }
.jay-step-text p:last-child { margin-bottom: 0; }
/* --- 命令块一键复制 --- */
.jay-cmd { position: relative; margin: 1.4em 0; border-radius: var(--radius); background: #1f2937; overflow: hidden; }
.jay-cmd pre { margin: 0; padding: 16px 18px; overflow-x: auto; }
.jay-cmd code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 14px; line-height: 1.6; color: #e5e7eb; white-space: pre; }
.jay-cmd-copy { position: absolute; top: 8px; right: 8px; padding: 5px 12px; font-size: 12px; border: 0; border-radius: 6px; background: rgba(255, 255, 255, .12); color: #e5e7eb; cursor: pointer; }
.jay-cmd-copy:hover { background: var(--primary); color: #fff; }
[data-theme="dark"] .jay-cmd { background: #0b1220; border: 1px solid var(--border); }

/* ============ v1.6.0: 深色模式优化 ============ */

/* --- 1. 缩略图深色适配：v2.0.0 恢复最初版，渐变缩略图/封面在深色模式下保持原样 ---
 * 与图片行为一致（不像 v1.6.0 纯色版那样映射为深色底 + 浅色字），
 * 故此处不再覆盖 smart-thumb / cat-cover / jay-topic-cover 的颜色。 */

/* --- 2. 卡片 1px 描边增强深色层级 --- */
[data-theme="dark"] .post-card,
[data-theme="dark"] .mag-card,
[data-theme="dark"] .feat-big,
[data-theme="dark"] .jay-topic-card { border: 1px solid rgba(255,255,255,.08); }

/* --- 3. 排行 badge 弱底色（深色模式） --- */
[data-theme="dark"] .popular-list .rank-1 { background: rgba(239,68,68,.15); color: #f87171; }
[data-theme="dark"] .popular-list .rank-2 { background: rgba(245,158,11,.15); color: #fbbf24; }
[data-theme="dark"] .popular-list .rank-3 { background: rgba(16,185,129,.15); color: #34d399; }

/* v1.6.0: 抽屉内的按钮式导航项（深浅色切换） */
button.drawer-link { background: none; border: none; cursor: pointer; font-family: inherit; width: 100%; text-align: left; }
button.drawer-link .drawer-theme-icon { display: inline-flex; }

/* ---------- v1.7.0: 高级搜索 ---------- */
.jay-search-filter { display: flex; align-items: center; gap: 10px; margin: 12px 0 18px; padding: 12px 16px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); flex-wrap: wrap; }.jay-search-select { padding: 8px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); color: var(--text); font-size: 14px; }
.jay-search-clear { font-size: 13px; color: var(--text-2); }
.jay-search-clear:hover { color: var(--primary); }
mark.jay-search-hl { background: rgba(37, 99, 235, 0.25);  background: color-mix(in srgb, var(--primary) 25%, transparent); color: inherit; padding: 0 2px; border-radius: 3px; }
@media (max-width: 640px) {
  .jay-search-filter { flex-direction: column; align-items: stretch; }
  .jay-search-select { width: 100%; }
}

/* ---------- v1.7.0: 教程信息卡 ---------- */
.tut-card { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 16px 0 20px; padding: 14px 16px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); }
.tut-item { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tut-icon { display: inline-flex; flex-shrink: 0; color: var(--primary); }
.tut-icon svg { vertical-align: -3px; }
.tut-label { font-size: 12px; color: var(--text-3); flex-shrink: 0; }
.tut-value { font-size: 13px; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tut-level-beginner .tut-value { color: #2e7d32; }
.tut-level-intermediate .tut-value { color: #e65100; }
.tut-level-advanced .tut-value { color: #c62828; }
[data-theme="dark"] .tut-level-beginner .tut-value { color: #86efac; }
[data-theme="dark"] .tut-level-intermediate .tut-value { color: #fdba74; }
[data-theme="dark"] .tut-level-advanced .tut-value { color: #fca5a5; }
@media (max-width: 640px) {
  .tut-card { grid-template-columns: repeat(2, 1fr); }
}

/* v1.7.0: 通知中心 */
.notif-entry { position: relative; }
.notif-bell { position: relative; background: none; border: none; cursor: pointer; color: var(--text); padding: 8px; border-radius: 8px; display: flex; align-items: center; }
.notif-bell:hover { background: var(--hover-bg, rgba(0,0,0,.05)); }
.notif-dot { position: absolute; top: 2px; right: 2px; min-width: 18px; height: 18px; line-height: 18px; text-align: center; font-size: 11px; font-style: normal; font-weight: 700; color: #fff; background: var(--danger); border-radius: 999px; padding: 0 4px; }
.notif-dropdown { position: absolute; top: calc(100% + 8px); right: 0; width: 340px; max-height: 420px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow-md, 0 8px 24px rgba(0,0,0,.12)); z-index: 100; display: flex; flex-direction: column; overflow: hidden; }
.notif-dropdown-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.notif-dropdown-head strong { font-size: 15px; }
.notif-dropdown-head button { background: none; border: none; color: var(--primary); font-size: 13px; cursor: pointer; }
.notif-dropdown-head button:hover { text-decoration: underline; }
.notif-dropdown-list { overflow-y: auto; max-height: 320px; }
.notif-item { display: block; padding: 12px 16px; border-bottom: 1px solid var(--border); text-decoration: none; color: var(--text); position: relative; }
.notif-item:hover { background: var(--hover-bg, rgba(0,0,0,.03)); }
.notif-item.is-unread::before { content: ''; position: absolute; left: 6px; top: 18px; width: 6px; height: 6px; border-radius: 50%; background: var(--primary); }
.notif-item.is-unread { padding-left: 20px; }
.notif-item-title { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.notif-item-content { font-size: 13px; color: var(--text-2); margin-bottom: 4px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; /* v2.0.14: 摘要恢复两行截断（v2.0.13 误伤） */ }
.notif-item-time { font-size: 12px; color: var(--text-3); }
.notif-empty, .notif-loading { padding: 24px; text-align: center; color: var(--text-3); font-size: 14px; }
.notif-dropdown-foot { display: block; text-align: center; padding: 10px; font-size: 13px; color: var(--primary); border-top: 1px solid var(--border); text-decoration: none; }
.notif-dropdown-foot:hover { background: var(--hover-bg, rgba(0,0,0,.03)); }
/* 用户中心通知 */
.uc-notice.is-unread { border-left: 3px solid var(--primary); }
.uc-notice-content { font-size: 13px; color: var(--text-2); margin: 4px 0; }

/* v1.8.0 hotfix: 手机端列表 meta 防换行 + 间距收紧 */
@media (max-width: 767px) {
  .post-card-meta { flex-wrap: nowrap; overflow: hidden; white-space: nowrap; }
  .post-card-meta .meta-author { display: none; } /* 手机端隐藏作者，只留时间+分类 */
  .post-card-meta .meta-views { display: none; } /* 手机端隐藏阅读量 */
  .post-list { gap: 8px; } /* 卡片间距 12px → 8px */
  .post-card { padding: 10px; } /* 卡片内边距收紧 */
}

/* ============================================================
 * v1.9.0: 评论 Markdown 工具栏 + 预览 + 代码样式
 * ============================================================ */
.jay-md-toolbar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.jay-md-toolbar button[data-md] {
  width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border); border-radius: 8px; background: var(--card);
  color: var(--text-2); cursor: pointer; font-size: 14px; line-height: 1; padding: 0;
  transition: background .15s, color .15s, border-color .15s;
}
.jay-md-toolbar button[data-md]:hover { background: rgba(37, 99, 235, 0.1);  background: color-mix(in srgb, var(--primary) 10%, transparent); color: var(--primary); border-color: var(--primary); }
.jay-md-hint { font-size: 12px; color: var(--text-3); margin-left: 2px; }.jay-md-preview-btn { margin-left: auto; height: 32px; padding: 0 14px; border-radius: 6px; border: 1px solid var(--border); background: var(--card); color: var(--text-2); font-size: 13px; cursor: pointer; }
.jay-md-preview-btn:hover { color: var(--primary); border-color: var(--primary); }
.jay-md-preview-btn[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }
.jay-md-preview {
  border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px;
  min-height: 120px; background: var(--card); font-size: 14px; line-height: 1.75;
  color: var(--text); word-wrap: break-word; margin-bottom: 12px;
}
.jay-md-preview:empty::before { content: ""; }
.jay-md-empty { color: var(--text-3); font-size: 13px; }
.jay-md-preview pre {
  background: var(--code-bg); padding: 12px; border-radius: var(--radius-sm);
  overflow-x: auto; margin: .8em 0; border: 1px solid var(--border);
}
.jay-md-preview pre code { background: none; padding: 0; }
.jay-md-preview code {
  background: var(--code-bg); padding: 2px 6px; border-radius: 4px;
  font-family: "SF Mono", Consolas, monospace; font-size: .88em;
}
/* 评论正文中的 Markdown 元素：与文章页代码风格统一 */
.comment-content code {
  background: var(--code-bg); padding: 2px 6px; border-radius: 4px;
  font-family: "SF Mono", Consolas, monospace; font-size: .88em;
}
.comment-content pre {
  background: var(--code-bg); padding: 12px; border-radius: var(--radius-sm);
  overflow-x: auto; margin: .8em 0; -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  white-space: pre; word-break: normal; overflow-wrap: normal;
}
.comment-content pre code { background: none; padding: 0; }
.comment-content strong { font-weight: 700; }
.comment-content em { font-style: italic; }
@media (max-width: 767px) {
  .jay-md-hint { display: none; }
  .jay-md-toolbar { gap: 4px; }
  .jay-md-toolbar button[data-md] { width: 30px; height: 30px; }
}

/* ============================================================
 * v2.0.0 全站视觉重构：专业+有色彩
 * 规则：本块在文件末尾，用层叠覆盖旧样式；不删旧规则、不动 PHP 逻辑。
 * 设计语言：专业底色 + 有色彩点缀（品牌色做主按钮/激活/徽章，语义色做状态，
 * 渐变只用在 Hero / 榜单 / 徽章等点缀处）；小字大写分节标签；
 * 卡片改回 v1.9.0（有层次感、有阴影）；智能缩略图恢复最初版 8 套渐变；手机端优先。
 * ============================================================ */

/* ---------- v2.0.0 设计 token ---------- */



/* ---------- v2.0.0 分节标签：小字大写，替代蓝色竖条 ---------- */
.jay-section-label,
.home-sec-title,
.widget-title,
.comments-title,
.related-posts > h2,
.jay-topic-list-title,
.jay-qa-answers-head h2,
.archive-month,
.e404-popular-title {
  font-size: 12px !important;
  font-weight: 700 !important;
  /* v2.0.2: 删 letter-spacing + uppercase——这些标题全是中文，uppercase 无效，
     .12em 字距只会把中文撑散（此前“精选推荐”四字间距过大） */
  color: var(--text-3) !important;
  margin: 4px 0 14px !important;
  padding: 0 !important;
  border: none !important;
  border-left: none !important;
}
.jay-section-label svg, .home-sec-title svg, .widget-title svg { display: none !important; }
.single-content h2::after { display: none !important; }
.single-content h2 { border-bottom: 1px solid var(--border) !important; }
.single-content h3 { border-left: none !important; padding-left: 0 !important; }

/* ---------- v2.0.0 卡片：改回 v1.9.0（杰哥反馈：现在的卡片不如之前） ----------
 * 上一轮的卡片扁平化覆盖（1px 边框 + 无阴影 + hover 只位移）已整块删除，
 * 卡片恢复 v1.9.0 原有样式（有层次感、有阴影、hover 上浮 + 阴影加深）。
 * 以下 v2 规则如仍针对卡片类选择器，均已同步删除或去掉扁平化声明。 */

/* ---------- v2.0.0 按钮：去大阴影，圆角统一 8px ---------- */
.btn, .jay-btn, .comment-form input[type="submit"], .jay-pay-confirm,
.shop-btn, .jay-buy-btn, .signin-btn, .jay-qa-ask-btn, .donate-btn,
.jay-auth-card .auth-form button[type="submit"], .auth-form button,
#profile-form button, .jay-search-filter .btn {
  border-radius: 8px !important;
  box-shadow: none !important;
  letter-spacing: .02em !important;
}
.btn:hover, .jay-btn:hover { box-shadow: none !important; transform: translateY(-1px) !important; }
.jay-buy-btn:hover, .signin-btn:hover:not(:disabled), .jay-qa-ask-btn:hover { box-shadow: none !important; }
.comment-form input[type="submit"]:hover { box-shadow: none !important; }
.header-inner { height: 60px !important; gap: 16px !important; }
/* v2.0.3: 菜单重做——上面这组 v2 中性化覆盖已删除（hover 无反馈、当前项深灰、下拉阴影压弱）。 */
.header-search input { border-radius: 8px !important; background: var(--bg) !important; }
.theme-toggle, .user-login-link, .user-avatar-btn { border-radius: 8px !important; }
.user-dropdown { border-radius: 10px !important; padding: 6px !important; }
.user-dropdown-head { background: transparent !important; border-radius: 0 !important; }
/* 通知下拉恢复 v1.9.0 阴影（v2 扁平化覆盖已删除） */
.notif-bell:hover { background: var(--hover-bg) !important; }
.drawer-link { border-radius: 8px !important; padding: 10px 12px !important; }
.drawer-link:hover { background: var(--bg) !important; }
.drawer-user-card { background: var(--bg) !important; border-radius: 10px !important; }
.drawer-user-card:hover { border-color: var(--border-strong) !important; }
.drawer-user-card img.avatar, .drawer-user-card .jay-avatar { border: 1px solid var(--border) !important; }
/* 底部 Tab 栏彻底隐藏（模板已删，此为兜底防残留） */
.tab-bar { display: none !important; }
.ql-blue .qlink-icon, .ql-green .qlink-icon, .ql-purple .qlink-icon, .ql-orange .qlink-icon {
  background: var(--bg) !important; color: var(--text-2) !important;
}
/* 列表分类标签：实心主色药丸 → 中性描边 */
.post-card-meta .cat-tag {
  background: var(--bg) !important; color: var(--text-2) !important;
  border: 1px solid var(--border) !important; border-radius: 6px !important;
  padding: 1px 8px !important;
}
.cat-tag { border-radius: 6px !important; }

/* ---------- v2.0.0 文章页（卡片恢复 v1.9.0，v2 扁平化覆盖已删除） ---------- */
.single-title { letter-spacing: -0.02em !important; }
.single-content blockquote {
  border-left: 2px solid var(--border-strong) !important;
  background: var(--card) !important; border-radius: 0 8px 8px 0 !important;
}
.single-content blockquote::before { color: var(--text-3) !important; opacity: 1 !important; }
/* v2.0.2 清理：表格头反色黑底规则已被审计补丁 + “专业+有色彩”块覆盖（死代码，已删）。 */
.single-content hr { background: var(--border) !important; opacity: 1 !important; }
.code-block, .single-content pre, .comment-content pre, .jay-cmd { border-radius: 8px !important; }
/* 分享弹窗/二维码卡/作者卡恢复 v1.9.0（v2 扁平化覆盖已删除） */
.author-avatar img, .author-avatar .jay-avatar { border: 1px solid var(--border) !important; }
/* 标签恢复 v1.9.0（v2 覆盖已删除） */
.like-btn, .fav-btn { border-radius: 999px !important; }
.fav-btn.faved { background: var(--text) !important; border-color: var(--text) !important; color: var(--card) !important; }
.fav-btn:hover { border-color: var(--border-strong) !important; color: var(--text) !important; }
.jay-btn { border-radius: 8px !important; }
.jay-btn:hover { box-shadow: none !important; }
/* 教程短代码：步骤序号主色 → 中性 */
.jay-step-num { background: var(--text) !important; color: var(--card) !important; }
.jay-cmd-copy:hover { background: var(--text) !important; color: var(--card) !important; }

/* ---------- v2.0.0 评论区（卡片恢复 v1.9.0，v2 扁平化覆盖已删除） ---------- */
.comment-body { background: var(--card) !important; border-radius: 12px !important; }
.comment-reply-link:hover { background: var(--text) !important; color: var(--card) !important; border-color: var(--text) !important; }
.comment-form input[type="submit"] { border-radius: 8px !important; }
.comment-body .comment-author img { border: 1px solid var(--border) !important; }
.comment.bypostauthor > .comment-body .comment-author .fn::after {
  background: var(--text) !important; color: var(--card) !important;
}
/* 评论 Markdown 工具栏 */
.jay-md-toolbar button[data-md] { border-radius: 6px !important; }
.jay-md-preview-btn[aria-pressed="true"] { background: var(--text) !important; border-color: var(--text) !important; color: var(--card) !important; }

/* ---------- v2.0.0 登录 / 注册 ---------- */
.jay-auth-kicker {
  text-align: center; font-size: 11px; font-weight: 700;
  color: var(--text-3); margin: 0 0 10px;
}
.jay-auth-sub { text-align: center; font-size: 13px; color: var(--text-2); margin: 0 0 20px; }
.jay-modal-tab.active { background: var(--text) !important; color: var(--card) !important; }
.jay-auth-card .auth-form input { border-radius: 8px !important; background: var(--card) !important; }
.jay-auth-card .auth-form button[type="submit"] { border-radius: 8px !important; }
.auth-tab.active { background: var(--text) !important; color: var(--card) !important; }
.auth-form input { border-radius: 8px !important; background: var(--card) !important; }
.auth-form button { border-radius: 8px !important; }
.uc-avatar img, .uc-avatar .jay-avatar { border: 1px solid var(--border) !important; box-shadow: none !important; }
.uc-stat strong { color: var(--text) !important; }
.uc-tabs::-webkit-scrollbar { display: none; }
.uc-tab {
  border: none !important; background: transparent !important;
  border-radius: 0 !important; border-bottom: 2px solid transparent !important;
  padding: 12px 14px !important; margin-bottom: -1px !important;
  color: var(--text-2) !important; font-size: 14px !important; font-weight: 500 !important;
  white-space: nowrap !important; flex-shrink: 0 !important;
}
.uc-tab:hover { color: var(--text) !important; }
.uc-tab.active {
  background: transparent !important; color: var(--text) !important;
  border-bottom-color: var(--text) !important; font-weight: 700 !important;
}
.uc-panel { border-radius: 12px !important; padding: 20px !important; margin-top: 16px; }
.uc-item { padding: 12px 0 !important; }
.uc-item:first-child { padding-top: 0 !important; }
.uc-item:last-child { padding-bottom: 0 !important; }
.uc-empty { padding: 40px 20px !important; }
.uc-form { padding: 4px !important; }
.uc-form input, .uc-form textarea, #profile-form input, #profile-form textarea {
  border-radius: 8px !important; background: var(--card) !important;
}
.uc-pager-cur { background: var(--text) !important; }
.signin-stat strong { color: var(--text) !important; }
.credit-balance strong { color: var(--text) !important; }
.credit-table thead th { background: var(--bg) !important; }
/* 任务完成态恢复 v1.9.0（v2 中性化覆盖已删除） */
.task-item.is-done .task-badge { color: var(--text) !important; border-color: var(--border) !important; }
.uc-notice.is-unread { border-left: 2px solid var(--text) !important; }
.uc-mypost-edit { color: var(--text) !important; }
.jay-qa-tab:hover { color: var(--text) !important; }
.jay-qa-tab.active { background: transparent !important; color: var(--text) !important; border-bottom-color: var(--text) !important; }
.jay-qa-ask-btn { border-radius: 8px !important; }
.jay-qa-row:hover { border-color: var(--border-strong) !important; }
.jay-qa-pager .page-numbers { border-radius: 6px !important; }
.jay-qa-pager .page-numbers.current { background: var(--text) !important; border-color: var(--text) !important; color: var(--card) !important; }
.jay-ask-form input[type="text"] { border-radius: 8px !important; }
.jay-rank-tab:hover { color: var(--text) !important; }
.jay-rank-tab.active { background: transparent !important; color: var(--text) !important; border-bottom-color: var(--text) !important; }
/* 排行行恢复 v1.9.0（v2 覆盖已删除；奖牌渐变在“专业+有色彩”块保留） */
.jay-rank-no { border-radius: 6px !important; background: var(--bg) !important; color: var(--text-2) !important; }
.jay-rank-item.jay-rank-top1 .jay-rank-no { background: var(--text) !important; color: var(--card) !important; }
.jay-rank-item.jay-rank-top2 .jay-rank-no, .jay-rank-item.jay-rank-top3 .jay-rank-no {
  background: var(--bg) !important; color: var(--text) !important; border: 1px solid var(--border);
}
.popular-list .rank { border-radius: 6px !important; }
.popular-list .rank-1, .popular-list .rank-2, .popular-list .rank-3 {
  background: var(--bg) !important; color: var(--text) !important; border: 1px solid var(--border);
}
[data-theme="dark"] .popular-list .rank-1,
[data-theme="dark"] .popular-list .rank-2,
[data-theme="dark"] .popular-list .rank-3 {
  background: rgba(255, 255, 255, .06) !important; color: var(--text) !important; border-color: rgba(255, 255, 255, .08) !important;
}

/* ---------- v2.0.0 404 / 搜索 / 归档 ---------- */
/* 404 卡恢复 v1.9.0（v2 扁平化覆盖已删除） */
.e404-num {
  font-size: 96px !important; font-weight: 700 !important; letter-spacing: -0.04em !important;
  background: none !important; -webkit-background-clip: initial !important; background-clip: initial !important;
  color: var(--text) !important;
}
.e404-search .search-field { border-radius: 8px !important; background: var(--card) !important; }
.e404-search .search-submit { border-radius: 8px !important; }
.search-header strong { color: var(--text) !important; }
/* 归档头恢复 v1.9.0（v2 扁平化覆盖已删除） */
.archive-header h1 { letter-spacing: -0.02em !important; }
/* 分类封面恢复 v1.9.0（渐变 + 阴影，v2 扁平化覆盖已删除） */
.cat-cover .cat-count { border-radius: 999px !important; }
.pagination a, .pagination span { box-shadow: none !important; border: 1px solid var(--border) !important; border-radius: 8px !important; }
.pagination .current, .pagination a:hover { border-color: var(--primary) !important; }

/* ---------- v2.0.0 页脚 / 通知 / 其他 ---------- */
.site-footer { background: var(--bg) !important; margin-top: 40px !important; }
.footer-inner { padding: 32px 14px !important; }
.notice-bar { background: var(--text) !important; color: var(--card) !important; }
.hot-keys, .search-suggest { box-shadow: none !important; }
.jay-poster-canvas { border: 1px solid var(--border); }
.jay-pay-tab.active { background: var(--text) !important; border-color: var(--text) !important; color: var(--card) !important; }
.jay-pay-confirm { border-radius: 8px !important; }
.shop-cart-panel { border-left: 1px solid var(--border); }
/* 加密锁卡恢复 v1.9.0（v2 扁平化覆盖已删除） */
.donate-qrcode img { border-radius: 8px !important; }
.lightbox .lb-close, .lightbox .lb-prev, .lightbox .lb-next { border-radius: 8px !important; }

/* ---------- v2.0.0 手机端 ---------- */
@media (max-width: 767px) {
  .header-inner { gap: 10px !important; }
  .uc-tabs { margin-left: -4px !important; }
  .uc-panel { padding: 16px !important; }
  .single-article { padding: 20px 14px !important; }
  .comments-area { padding: 18px 14px !important; }
  .e404-num { font-size: 72px !important; }
  .feat-big, .feat-big-link { min-height: 200px !important; }
  .post-card { padding: 10px !important; }
  .post-list { gap: 8px !important; }
  .post-card-meta { flex-wrap: nowrap !important; overflow: hidden !important; white-space: nowrap !important; }
  .post-card-meta .meta-author, .post-card-meta .meta-views { display: none !important; }
  .jay-topic-grid { gap: 12px !important; }
  .drawer { width: min(300px, 86vw) !important; }
  .float-btns { bottom: 20px !important; right: 14px !important; }
}

/* ---------- v2.0.0 双审计补丁（方向改为专业+有色彩后，Hero 中性化覆盖已删除，渐变恢复） ---------- */
/* 下载/功能/文档/投稿 4 个模板的 inline <style> 深蓝→紫渐变 Hero + 渐变 CTA 恢复原样，
   不再用外部样式覆盖。模板 PHP 逻辑不动。 */
/* 正文表格头：反色黑底太重，改为品牌淡底（见下方“专业+有色彩”块）。 */
/* v2.0.2 清理：审计补丁的表格头规则已被“专业+有色彩”块同选择器覆盖（死代码，已删）。 */

/* ---------- v2.0.0 专业+有色彩 ---------- */
/* 方向：保留专业骨架（小字大写标签），色彩回来且有语义；卡片已改回 v1.9.0
   （有层次感、有阴影），不再是 1px 边框 + 无阴影。
   品牌色 = 主操作 / 激活；语义色 = 状态（绿=已解决/已完成/最佳，橙=待解决，
   金/银/铜=榜单奖牌，紫=积分兑换，红/金/绿=侧栏热榜）；渐变只用在 Hero / 奖牌 / 徽章三处点缀。
   本块在文件最末，后写优先，覆盖上一轮“极简”中性化规则。 */

/* 1. 主操作 → 品牌色（.jay-btn 是次按钮描边，保持不动；.btn/.jay-buy-btn/.signin-btn/.jay-qa-ask-btn 原已是品牌色） */
.comment-form input[type="submit"],
.jay-pay-confirm,
.jay-auth-card .auth-form button[type="submit"],
.auth-form button,
.e404-search .search-submit,
.jay-search-filter .btn {
  background: var(--primary) !important; border-color: var(--primary) !important;
  color: var(--primary-text) !important;
}
.jay-qa-pager .page-numbers.current { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
.uc-pager-cur { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
.pagination .current { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
/* Tab 激活下划线 / 分段激活态 → 品牌色 */
.uc-tab.active { color: var(--primary) !important; border-bottom-color: var(--primary) !important; }
.jay-qa-tab.active { color: var(--primary) !important; border-bottom-color: var(--primary) !important; }
.jay-rank-tab.active { color: var(--primary) !important; border-bottom-color: var(--primary) !important; }
.jay-modal-tab.active { background: var(--primary) !important; color: var(--primary-text) !important; }
.auth-tab.active { background: var(--primary) !important; color: var(--primary-text) !important; }
.jay-pay-tab.active { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
/* PC 导航当前项 → 品牌色文字 + 品牌色下划线 */
.pc-menu .current-menu-item > a, .pc-menu .current-menu-ancestor > a, .pc-menu > li > a.active {
  color: var(--primary) !important; box-shadow: inset 0 -2px 0 var(--primary) !important;
}
/* 2. 推广卡 → 改回 v1.9.0（渐变底 + 阴影），本块的品牌淡底覆盖已删除 */
/* 3. 分类标签 → 品牌淡底 */
.post-card-meta .cat-tag {
  background: rgba(37, 99, 235, 0.1) !important; 
  background: color-mix(in srgb, var(--primary) 10%, transparent) !important;
  color: #1c4ab0 !important; 
  color: color-mix(in srgb, var(--primary) 75%, black) !important;
  border-color: var(--border) !important; 
  border-color: color-mix(in srgb, var(--primary) 25%, var(--border)) !important;
}
/* 问答状态徽章（原已是语义色，此处重申 + 补深色） */
.jay-qa-status.unsolved { background: rgba(234, 88, 12, .12) !important; color: #ea580c !important; }
.jay-qa-status.solved { background: rgba(22, 163, 74, .12) !important; color: var(--success) !important; }
.jay-best-badge { background: rgba(22, 163, 74, .12) !important; color: var(--success) !important; }
.jay-mark-best:hover { background: var(--success) !important; color: #fff !important; }
/* 5. 排行榜奖牌恢复（金/银/铜渐变，恢复 v2 之前原值） */
.jay-rank-item.jay-rank-top1 .jay-rank-no { background: linear-gradient(135deg, #f6c453, #e08e0b) !important; color: #fff !important; border: none !important; }
.jay-rank-item.jay-rank-top2 .jay-rank-no { background: linear-gradient(135deg, #cfd8e3, #8fa0b8) !important; color: #fff !important; border: none !important; }
.jay-rank-item.jay-rank-top3 .jay-rank-no { background: linear-gradient(135deg, #e0a080, #b0653a) !important; color: #fff !important; border: none !important; }
/* 侧栏热榜 1-3（恢复原值：红/金/绿） */
.popular-list .rank-1 { background: var(--danger) !important; color: #fff !important; border: none !important; }
.popular-list .rank-2 { background: var(--warning) !important; color: #fff !important; border: none !important; }
.popular-list .rank-3 { background: #10b981 !important; color: #fff !important; border: none !important; }
.jay-credit-btn:hover { box-shadow: none !important; opacity: .92; }
/* 7. 用户中心封面 → 改回 v1.9.0（原有渐变 + 装饰），本块的品牌柔和渐变覆盖已删除 */
/* 8. 投稿/文档/功能页序号与按钮 → 品牌色 */
.jay-feat-num { background: var(--primary) !important; color: var(--primary-text) !important; }
.jay-docs-step-n { background: var(--primary) !important; color: var(--primary-text) !important; }
.jay-contribute-btn { background: var(--primary) !important; color: var(--primary-text) !important; }
.jay-step-num { background: var(--primary) !important; color: var(--primary-text) !important; }
/* 9. 正文表格头 → 品牌淡底 */
.single-content th {
  background: var(--card) !important; 
  background: color-mix(in srgb, var(--primary) 8%, var(--card)) !important;
  color: #1a45a4 !important; 
  color: color-mix(in srgb, var(--primary) 70%, black) !important;
  border-color: var(--border) !important;
}
.credit-table thead th {
  background: var(--card) !important; 
  background: color-mix(in srgb, var(--primary) 8%, var(--card)) !important;
  color: #1a45a4 !important; 
  color: color-mix(in srgb, var(--primary) 70%, black) !important;
}
/* 10. 点赞/收藏激活态 → 品牌色 */
.fav-btn.faved { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
.comment-reply-link:hover { background: var(--primary) !important; color: var(--primary-text) !important; border-color: var(--primary) !important; }
.jay-md-preview-btn[aria-pressed="true"] { background: var(--primary) !important; border-color: var(--primary) !important; color: var(--primary-text) !important; }
.jay-cmd-copy:hover { background: var(--primary) !important; color: var(--primary-text) !important; }
.comment.bypostauthor > .comment-body .comment-author .fn::after { background: var(--primary) !important; color: var(--primary-text) !important; }
.uc-notice.is-unread { border-left: 2px solid var(--primary) !important; }
.uc-mypost-edit { color: var(--primary) !important; }
.task-item.is-done .task-badge { color: var(--success) !important; border-color: rgba(22, 163, 74, .35) !important; }
/* 11. 通知栏 → 品牌色底 + 白字 */
.notice-bar { background: var(--primary) !important; color: #fff !important; }
/* 12. 快捷入口图标 → 4 色柔和恢复（恢复 v2 之前原值） */
.ql-blue .qlink-icon { background: rgba(59, 130, 246, 0.13) !important;  background: color-mix(in srgb, #3b82f6 13%, transparent) !important; color: #3b82f6 !important; }
.ql-green .qlink-icon { background: rgba(16, 185, 129, 0.13) !important;  background: color-mix(in srgb, #10b981 13%, transparent) !important; color: #10b981 !important; }
.ql-purple .qlink-icon { background: rgba(139, 92, 246, 0.13) !important;  background: color-mix(in srgb, #8b5cf6 13%, transparent) !important; color: #8b5cf6 !important; }
.ql-orange .qlink-icon { background: rgba(245, 158, 11, 0.15) !important;  background: color-mix(in srgb, var(--warning) 15%, transparent) !important; color: #d97706 !important; }
/* 搜索关键词 → 品牌色 */
.search-header strong { color: var(--primary) !important; }
/* 14. 深色模式：淡底 + 亮色字，保证可读 */
[data-theme="dark"] .post-card-meta .cat-tag {
  background: rgba(37, 99, 235, 0.15) !important; 
  background: color-mix(in srgb, var(--primary) 15%, transparent) !important;
  color: #5182ef !important; 
  color: color-mix(in srgb, var(--primary) 80%, white) !important;
  border-color: var(--border) !important; 
  border-color: color-mix(in srgb, var(--primary) 30%, var(--border)) !important;
}
[data-theme="dark"] .single-content th,
[data-theme="dark"] .credit-table thead th {
  background: rgba(37, 99, 235, 0.15) !important; 
  background: color-mix(in srgb, var(--primary) 15%, transparent) !important;
  color: #467aee !important; 
  color: color-mix(in srgb, var(--primary) 85%, white) !important;
}
[data-theme="dark"] .jay-qa-status.unsolved { background: rgba(234, 88, 12, .2) !important; color: #fb923c !important; }
[data-theme="dark"] .jay-qa-status.solved { background: rgba(22, 163, 74, .2) !important; color: #4ade80 !important; }
[data-theme="dark"] .jay-best-badge { background: rgba(22, 163, 74, .2) !important; color: #4ade80 !important; }
[data-theme="dark"] .popular-list .rank-1 { background: rgba(239, 68, 68, .15) !important; color: #f87171 !important; }
[data-theme="dark"] .popular-list .rank-2 { background: rgba(245, 158, 11, .15) !important; color: #fbbf24 !important; }
[data-theme="dark"] .popular-list .rank-3 { background: rgba(16, 185, 129, .15) !important; color: #34d399 !important; }
[data-theme="dark"] .ql-orange .qlink-icon { color: var(--warning) !important; }
/* 13. 分节标签保持小字大写中性（色彩靠按钮/徽章/标签/奖牌点缀，不每个标题上色） */

/* ============================================================
 * v2.0.2 菜单重做（杰哥反馈：美化没做，顶部和底部都有问题）
 * 现象→根因→修复：
 * 1. 顶部：手机端页眉搜索框未隐藏，汉堡 + Logo + 搜索框 + 深浅切换 + 登录在小屏上溢出
 *    （.header-search flex:1 且 input 有固有最小宽度；抽屉内已有搜索框，页眉搜索框在手机端是重复的）
 *    → ≤767px 隐藏页眉搜索框，手机顶部只留汉堡 + Logo + 深浅 + 登录。
 * 2. 抽屉：无任何当前页标识，用户不知道自己在哪
 *    → header.php 给抽屉链接加 .active + aria-current="page"，此处给品牌淡底 + 品牌色字 + 加粗。
 * 3. 底部：页脚导航链接用 --muted（浅色 3.3 / 深色 3.0，均不达标，且与页脚其他链接的 --text-2 不一致）
 *    → 改用 --text-2，hover 药丸底 + 品牌色字；与 .footer-inner a 统一。
 * 4. PC 下拉：短菜单项时下拉挤成细条 → 最小宽度 180px。
 * ============================================================ */
@media (max-width: 767px) {
  /* v2.0.9：恢复手机端页眉搜索框（杰哥反馈：顶部右边空白，头像与深浅切换显得在中间）。
     当年 v2.0.2 藏它是因 input 固有最小宽度顶溢出；改用 flex 允许收缩 + min-width: 0 解除固有宽度，即可显示且不溢出。 */
  .header-search { flex: 1 1 0; min-width: 0; }
  .header-search input { min-width: 0; }
}
.pc-menu .sub-menu { min-width: 180px; }
.drawer-link.active {
  background: rgba(37, 99, 235, .10);
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary);
  font-weight: 600;
}
.footer-nav ul { gap: 6px 8px; }
.footer-nav a { color: var(--text-2); padding: 6px 12px; border-radius: 999px; }
.footer-nav a:hover { color: var(--primary); background: var(--hover-bg); }

/* ============================================================
 * v2.0.2 触控目标（杰哥反馈“其他”项）
 * 标准：常用可点元素 ≥44px（WCAG 2.2 AA 要求 24px，44px 为 Apple HIG / 拇指友好尺寸）。
 * 密集工具栏（Markdown 工具栏 32px）已达 AA，不强行放大，避免工具栏臃肿。
 * ============================================================ */
.hamburger, .theme-toggle { width: 44px; height: 44px; }
@media (max-width: 767px) {
  .user-login-link { width: 44px; height: 44px; }
}
.drawer-close { width: 44px; height: 44px; }
.notif-bell { padding: 13px; }
.jay-auth-close { padding: 13px; }
.jay-pay-close { padding: 10px; }
.shop-cart-close { padding: 9px; }
.shop-cart-del { padding: 12px; }
.drawer-link { padding: 12px 12px !important; }
.pagination a, .pagination span { min-width: 44px; height: 44px; }
.jay-qa-pager .page-numbers { padding: 10px 14px; }

/* ============================================================
 * v2.0.2 杰哥反馈：新1 首页大空白 + 新2 顶部站名 + 新3/4 抽屉二级菜单
 * ============================================================ */
/* 新1：列表 → 页脚空白收紧（之前三处叠加：main 底 padding 40 + 分页 margin 24 + 页脚 margin-top 40 ≈ 104px） */
.main { padding-bottom: 20px; }
/* P1-5：用户中心取消 .main 60vh 最小高度——实测空白在面板下方（退出登录行 → 页脚之间，约 170px），
   元凶是 min-height 把 main 撑高 + 底 padding + 页脚 margin；面板本身无 min-height，不动面板。 */
body.uc-page .main { min-height: 0; }
.pagination { margin: 16px 0; }
.site-footer { margin-top: 20px !important; }
/* v2.0.3: Hero 已删，首页 Logo 恢复显示（否则首页无品牌标识）。 */
/* 新3/4：抽屉二级菜单（有子页面的父级可展开；工具页收进“在线工具”一个入口） */
/* v2.0.6: 子菜单一直展开（学子比：不做手风琴），沿用 v2.0.4 的两列网格 */
.drawer-sub-wrap .drawer-sub { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 8px; padding-left: 12px; }
.drawer-sub-link { font-size: 14px; }
/* 新4：PC 导航 ▾ 点按区放大（触屏可点；hover 仍可用） */
.menu-caret { cursor: pointer; padding: 8px; margin-right: -8px; }

/* v2.0.3: 页脚跟随主题色——品牌色渐变底 + 白字；换配色时页脚跟着变（全用 var(--primary)，不写死色，不亮色，不深紫）。
   第一条 background 是旧浏览器回退（纯品牌色），支持 color-mix 的用渐变版。 */
.site-footer {
  background: var(--primary) !important;
  background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--primary) 65%, #0f172a)) !important;
  border-top: none;
  color: #fff;
}
.footer-inner { padding: 28px 14px; color: rgba(255, 255, 255, .85); }
.footer-inner a { color: #fff; }
.footer-inner a:hover { color: #fff; text-decoration: underline; }
.footer-inner p:first-child { font-size: 15px; font-weight: 700; color: #fff; }
.footer-inner p:first-child a { color: #fff; }
.footer-inner p:first-child a:hover { color: #fff; }
.theme-credit, .footer-links, .footer-icp, .site-uptime, .page-loadtime { color: rgba(255, 255, 255, .75); }
.footer-links a, .footer-icp a { color: rgba(255, 255, 255, .85); }
.site-uptime span { color: #fff; }
.footer-nav a { background: rgba(255, 255, 255, .14); color: #fff; }
.footer-nav a:hover { background: rgba(255, 255, 255, .28); color: #fff; text-decoration: none; }

/* ============================================================
 * v2.0.3 菜单重做（学子比的感觉，不抄样式）：字号 15px、间距宽松、
 * hover 背景变浅 + 文字变品牌色、当前项品牌色 + 品牌下划线、
 * 下拉白底圆角 12px + 柔和分层阴影、无分隔线、行高宽松；
 * 配色、结构仍是 Jay Theme 自己的。
 * ============================================================ */
.pc-menu { gap: 4px; }
.pc-menu a { font-size: 15px; font-weight: 600; padding: 10px 14px; color: var(--text); }
.pc-menu > li > a:hover { color: var(--primary); background: var(--hover-bg); }
.pc-menu .current-menu-item > a,
.pc-menu .current-menu-ancestor > a,
.pc-menu > li > a.active {
  color: var(--primary); font-weight: 600;
  box-shadow: inset 0 -2px 0 var(--primary);
}
.pc-menu .sub-menu {
  border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, .14), 0 4px 12px rgba(0, 0, 0, .06);
  padding: 8px;
}
.pc-menu .sub-menu a { font-size: 14px; padding: 10px 14px; border-radius: 8px; }
.pc-menu .sub-menu a:hover { background: var(--hover-bg); color: var(--primary); }
/* 抽屉菜单同步：圆角加大 */
.drawer-link { border-radius: 10px; }
/* 页眉滚动后加柔和阴影（JS 加 .scrolled） */
.site-header.scrolled { box-shadow: 0 4px 16px rgba(0, 0, 0, .06); }

/* v2.0.4: 侧边栏区块搜索框（WP 核心样式写死白底 #fff），跟随主题：深色下深底白字。 */
.widget_search .wp-block-search__inside-wrapper { background: var(--card) !important; border-color: var(--border) !important; }
.widget_search .wp-block-search__input { background: var(--card) !important; color: var(--text) !important; border-color: var(--border) !important; }
.widget_search .wp-block-search__input::placeholder { color: var(--text-3); }
.widget_search .wp-block-search__button { background: var(--primary) !important; color: #fff !important; border-color: var(--primary) !important; }
.widget_search .wp-block-search__label { color: var(--text-2); }

/* ============================================================
 * v2.0.4 下拉菜单两列（mega 菜单感觉，不抄子比样式）：
 * PC 下拉 2 项及以上时两列网格；1 项保持单列，避免空列。
 * 抽屉二级菜单同步两列（手机端也能看到变化）。
 * ============================================================ */
.pc-menu .sub-menu:has(> li:nth-child(2)) {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 8px;
  min-width: 320px;
}
