/* ============================================================
 * 明亮极简主题 —— Chen_yang_ 的个人博客
 * 配色与尺寸统一用 CSS 变量，想改风格只动 :root 即可
 * ============================================================ */
:root {
  --bg: #fbfbfd;
  --bg-alt: #f4f4f7;
  --card: #ffffff;
  --text: #17181d;
  --text-2: #5b6070;
  --text-3: #9aa0ae;
  --border: #e9eaef;
  --border-strong: #dcdde3;

  --accent: #6366f1;
  --accent-2: #8b5cf6;
  --accent-soft: #eef0ff;
  --accent-text: #4f46e5;
  --grad: linear-gradient(120deg, #6366f1 0%, #8b5cf6 100%);

  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(23,24,29,.04), 0 2px 10px rgba(23,24,29,.04);
  --shadow-md: 0 6px 24px rgba(23,24,29,.07);
  --shadow-lg: 0 16px 48px rgba(23,24,29,.10);

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --font-mono: "SF Mono", "JetBrains Mono", "Cascadia Code", Consolas,
    "Courier New", monospace;

  --header-h: 64px;
  --maxw: 1080px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

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

/* ---------- 顶部导航 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(251, 251, 253, .82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; }
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 17px; letter-spacing: .2px;
}
.brand-dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--grad);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.nav-links { display: flex; gap: 6px; }
.nav-links a {
  padding: 7px 13px; border-radius: 9px;
  color: var(--text-2); font-size: 14.5px; font-weight: 500;
  transition: color .18s, background .18s;
}
.nav-links a:hover { color: var(--text); background: var(--bg-alt); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 96px 0 72px; }
.hero-inner { text-align: center; max-width: 720px; }
.mesh { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.mesh i {
  position: absolute; border-radius: 50%;
  filter: blur(70px); opacity: .55; animation: float 14s ease-in-out infinite;
}
.mesh i:nth-child(1) { width: 420px; height: 420px; left: -80px; top: -120px; background: #dbe0ff; }
.mesh i:nth-child(2) { width: 380px; height: 380px; right: -60px; top: 20px; background: #f0e0ff; animation-delay: -5s; }
.mesh i:nth-child(3) { width: 300px; height: 300px; left: 40%; bottom: -160px; background: #ffe4f0; animation-delay: -9s; }
@keyframes float {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-30px) translateX(20px); }
}

.hero-avatar { display: inline-block; margin-bottom: 26px; }
.hero-avatar img {
  width: 96px; height: 96px; border-radius: 50%; object-fit: cover;
  border: 4px solid #fff; box-shadow: var(--shadow-md), 0 0 0 1px var(--border);
}
.hero-name {
  margin: 0 0 6px; font-size: 46px; font-weight: 800; letter-spacing: -1px;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-tagline { margin: 0 0 20px; color: var(--text-2); font-size: 18px; }
.hero-intro { margin: 0 auto 26px; color: var(--text-2); font-size: 15.5px; max-width: 600px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 30px; }
.badge {
  padding: 5px 13px; border-radius: 999px; font-size: 13px; font-weight: 500;
  background: #fff; color: var(--text-2); border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.hero-actions { display: flex; gap: 12px; justify-content: center; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 22px; border-radius: 12px; font-size: 15px; font-weight: 600;
  border: 1px solid transparent; transition: transform .15s, box-shadow .15s, background .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 6px 18px rgba(99,102,241,.32); }
.btn-primary:hover { box-shadow: 0 10px 26px rgba(99,102,241,.42); }
.btn-ghost { background: #fff; color: var(--text); border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- 通用 Section ---------- */
.section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 640px; margin-bottom: 36px; }
.section-kicker {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: 2.5px;
  color: var(--accent); text-transform: uppercase; margin-bottom: 8px;
}
.section-title { margin: 0 0 8px; font-size: 30px; font-weight: 800; letter-spacing: -.5px; }
.section-desc { margin: 0; color: var(--text-3); font-size: 15px; }

/* ---------- 关于我 ---------- */
.about-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.about-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 22px; box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s;
}
.about-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.about-card-icon { font-size: 30px; margin-bottom: 12px; }
.about-card h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; }
.about-card p { margin: 0; color: var(--text-2); font-size: 14px; }

/* ---------- 社交名片 ---------- */
.scroll-row {
  display: flex; gap: 14px; overflow-x: auto; padding: 2px 2px 14px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.scroll-row::-webkit-scrollbar { height: 8px; }
.scroll-row::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 999px; }
.scroll-row > * { scroll-snap-align: start; flex: 0 0 auto; }
.social-grid .social-card { flex: 0 0 250px; }

/* ---------- 伙伴 ---------- */
.partner-card {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  padding: 20px 16px; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-sm); flex: 0 0 130px;
  transition: transform .2s, box-shadow .2s;
}
.partner-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.partner-avatar { width: 64px; height: 64px; border-radius: 50%; overflow: hidden; background: var(--grad); display: flex; align-items: center; justify-content: center; }
.partner-avatar img { width: 100%; height: 100%; object-fit: cover; }
.partner-name { font-size: 14px; font-weight: 600; color: var(--text); text-align: center; }

/* ---------- 网易云歌单 ---------- */
.playlist-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.playlist-card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s; }
.playlist-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.playlist-cover { width: 100%; aspect-ratio: 1; object-fit: cover; }
.playlist-body { padding: 10px 12px; }
.playlist-name { font-size: 13.5px; font-weight: 600; line-height: 1.4; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.playlist-jump {
  display: inline-block; margin-top: 10px; padding: 6px 14px; border-radius: 8px;
  background: var(--accent-soft); color: var(--accent-text); font-size: 12.5px; font-weight: 600;
  transition: background .18s, color .18s;
}
.playlist-jump:hover { background: var(--accent); color: #fff; }
.playlist-empty { grid-column: 1 / -1; text-align: center; color: var(--text-3); padding: 20px; }

/* ---------- 背景音乐呼出栏 ---------- */
.bgm-bar { position: fixed; left: 22px; bottom: 22px; z-index: 45; }
.bgm-btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px;
  border-radius: 999px; border: 1px solid var(--border); background: #fff;
  box-shadow: var(--shadow-md); color: var(--text-2); font-size: 13.5px; font-weight: 600;
  cursor: pointer; transition: color .18s, border-color .18s, transform .12s;
}
.bgm-btn:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-2px); }
.bgm-disc { display: inline-block; font-size: 16px; color: var(--accent); }
.bgm-disc.spin { animation: bgmSpin 2.5s linear infinite; }
@keyframes bgmSpin { from { transform: rotate(0); } to { transform: rotate(360deg); } }

/* ---------- 动画增强 ---------- */
.hero-avatar img { animation: avatarFloat 4s ease-in-out infinite; }
@keyframes avatarFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes cardIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.about-card, .partner-card, .playlist-card { animation: cardIn .5s ease both; }
.social-card {
  display: flex; align-items: center; gap: 14px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s, border-color .2s;
}
.social-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.social-avatar {
  width: 52px; height: 52px; border-radius: 50%; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 20px;
  background: var(--grad); overflow: hidden;
}
.social-avatar img { width: 100%; height: 100%; object-fit: cover; }
.social-info { min-width: 0; flex: 1; }
.social-name { font-weight: 700; font-size: 15.5px; display: flex; align-items: center; gap: 7px; }
.social-handle { color: var(--text-3); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.social-open {
  flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-3); border: 1px solid var(--border); background: #fff;
  transition: color .18s, border-color .18s;
}
.social-card:hover .social-open { color: var(--accent); border-color: var(--accent); }

/* ---------- GitHub 项目 ---------- */
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.project-card {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s;
}
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.project-head { display: flex; align-items: center; gap: 9px; }
.project-head svg { flex: 0 0 auto; color: var(--text-2); }
.project-name { font-weight: 700; font-size: 15.5px; color: var(--text); word-break: break-word; }
.project-desc {
  margin: 0; color: var(--text-2); font-size: 13.5px; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 4.8em; flex: 1;
}
.project-meta { display: flex; align-items: center; gap: 14px; font-size: 12.5px; color: var(--text-3); }
.project-lang { display: inline-flex; align-items: center; gap: 6px; }
.project-lang-dot { width: 10px; height: 10px; border-radius: 50%; }
.project-links { display: flex; gap: 16px; padding-top: 12px; border-top: 1px solid var(--border); font-size: 13.5px; font-weight: 600; }
.project-links a { color: var(--accent); }
.project-links a:hover { text-decoration: underline; }
.projects-empty {
  grid-column: 1 / -1; text-align: center; color: var(--text-3); font-size: 14px;
  padding: 30px; border: 1px dashed var(--border-strong); border-radius: var(--radius);
}
.projects-empty a { color: var(--accent); font-weight: 600; }

/* ---------- 视频 ---------- */
.video-layout { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.video-frame {
  position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius);
  overflow: hidden; background: #0b0c0f; box-shadow: var(--shadow-md); border: 1px solid var(--border);
}
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-now { display: flex; align-items: center; gap: 10px; margin-top: 14px; padding: 0 4px; }
.video-now-label {
  font-size: 11px; font-weight: 700; letter-spacing: .5px; color: var(--accent);
  padding: 3px 9px; border-radius: 6px; background: var(--accent-soft); flex: 0 0 auto;
}
.video-now-title {
  font-size: 14.5px; font-weight: 600; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.video-list { display: flex; flex-direction: column; gap: 10px; max-height: 460px; overflow-y: auto; padding-right: 4px; }
.video-item {
  display: flex; gap: 12px; align-items: center; padding: 10px;
  border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--card);
  cursor: pointer; transition: border-color .18s, box-shadow .18s, transform .18s;
}
.video-item:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); transform: translateX(3px); }
.video-item.active { border-color: var(--accent); background: var(--accent-soft); }
.video-item-thumb { width: 112px; height: 63px; border-radius: 8px; object-fit: cover; flex: 0 0 auto; background: var(--bg-alt); }
.video-item-body { min-width: 0; }
.video-item-title {
  font-size: 13.5px; font-weight: 600; line-height: 1.45; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.video-item-meta { font-size: 12px; color: var(--text-3); margin-top: 4px; }
.video-empty { color: var(--text-3); font-size: 14px; padding: 20px; text-align: center; border: 1px dashed var(--border-strong); border-radius: var(--radius-sm); }

/* ---------- 音乐播放器 ---------- */
.player {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-md); padding: 22px; display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 24px;
}
.player-main { display: flex; flex-direction: column; gap: 16px; }
.player-top { display: flex; gap: 16px; align-items: center; }
.player-cover { width: 92px; height: 92px; border-radius: 14px; object-fit: cover; flex: 0 0 auto; box-shadow: var(--shadow-sm); }
.player-head { min-width: 0; }
.player-playlist-name { font-weight: 800; font-size: 18px; margin: 0 0 4px; }
.player-song {
  color: var(--text-2); font-size: 14px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; margin: 0 0 10px;
}
.player-bar { position: relative; height: 6px; border-radius: 999px; background: var(--bg-alt); cursor: pointer; }
.player-bar-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 999px; background: var(--grad); }
.player-time { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-3); margin-top: 6px; }
.player-controls { display: flex; align-items: center; gap: 10px; }
.player-btn {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border);
  background: #fff; display: flex; align-items: center; justify-content: center;
  color: var(--text); transition: border-color .18s, color .18s, transform .12s;
}
.player-btn:hover { border-color: var(--accent); color: var(--accent); }
.player-btn:active { transform: scale(.94); }
.player-btn-play { width: 52px; height: 52px; background: var(--grad); color: #fff; border: none; box-shadow: 0 6px 16px rgba(99,102,241,.3); }
.player-btn-play:hover { color: #fff; }
.player-vol { display: flex; align-items: center; gap: 8px; margin-left: auto; color: var(--text-3); }
.player-vol input[type="range"] { width: 84px; accent-color: var(--accent); }
.player-lyric { min-height: 56px; margin-top: 12px; padding: 10px 12px; background: var(--bg-alt); border-radius: 10px; text-align: center; }
.lrc-cur { margin: 0 0 4px; font-size: 14.5px; font-weight: 600; color: var(--text); }
.lrc-next { margin: 0; font-size: 12.5px; color: var(--text-3); opacity: .8; }

.player-list { border-left: 1px solid var(--border); padding-left: 20px; display: flex; flex-direction: column; }
.player-list-title { font-size: 12px; font-weight: 700; letter-spacing: 1px; color: var(--text-3); margin: 0 0 10px; }
.player-tracks { list-style: none; margin: 0; padding: 0; overflow-y: auto; max-height: 300px; }
.player-track {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 9px;
  cursor: pointer; transition: background .15s; font-size: 13.5px;
}
.player-track:hover { background: var(--bg-alt); }
.player-track.playing { background: var(--accent-soft); color: var(--accent-text); font-weight: 600; }
.player-track.disabled { opacity: .45; cursor: not-allowed; }
.player-track-idx { width: 20px; color: var(--text-3); font-variant-numeric: tabular-nums; text-align: right; flex: 0 0 auto; }
.player-track-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.player-track-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-track-badge { font-size: 10px; padding: 1px 6px; border-radius: 5px; background: var(--border); color: var(--text-3); flex: 0 0 auto; }
.player-track-dur { color: var(--text-3); font-variant-numeric: tabular-nums; flex: 0 0 auto; font-size: 12px; }
.player-meta-row { display: flex; align-items: center; gap: 10px; margin-top: 2px; }
.player-outlink { font-size: 12.5px; color: var(--accent); font-weight: 600; }
.player-fallback { text-align: center; color: var(--text-2); padding: 40px 20px; }
.player-fallback a { color: var(--accent); font-weight: 600; }

/* ---------- 文章 ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.blog-card {
  display: flex; flex-direction: column; background: var(--card);
  border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s;
}
.blog-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.blog-cover { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.blog-body { padding: 20px; display: flex; flex-direction: column; flex: 1; }
.blog-date { font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.blog-title { margin: 6px 0 8px; font-size: 17.5px; font-weight: 700; line-height: 1.4; }
.blog-summary {
  margin: 0 0 16px; color: var(--text-2); font-size: 14px; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.blog-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; color: var(--accent-text); background: var(--accent-soft); padding: 3px 9px; border-radius: 6px; }
.blog-empty { grid-column: 1 / -1; text-align: center; color: var(--text-3); padding: 30px; border: 1px dashed var(--border-strong); border-radius: var(--radius); }

/* ---------- 文章详情 ---------- */
.article-view { padding: 48px 0 80px; }
.article-container { max-width: 760px; }
.back-link { display: inline-block; color: var(--accent); font-weight: 600; font-size: 14.5px; margin-bottom: 24px; }
.back-link:hover { text-decoration: underline; }
.article-head { margin-bottom: 24px; }
.article-title { margin: 0 0 12px; font-size: 34px; font-weight: 800; letter-spacing: -.5px; line-height: 1.25; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; color: var(--text-3); font-size: 14px; }
.article-meta .tag { margin-left: 6px; }
.article-cover-wrap { margin-bottom: 28px; }
.article-cover-wrap img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-md); }
.article-foot { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }

/* 正文排版（markdown 渲染结果） */
.markdown-body { font-size: 16.5px; color: var(--text); }
.markdown-body h1, .markdown-body h2, .markdown-body h3, .markdown-body h4 {
  font-weight: 800; letter-spacing: -.3px; margin: 1.6em 0 .6em; line-height: 1.35;
}
.markdown-body h1 { font-size: 28px; }
.markdown-body h2 { font-size: 23px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.markdown-body h3 { font-size: 19px; }
.markdown-body h4 { font-size: 17px; }
.markdown-body p { margin: 0 0 1.1em; }
.markdown-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.markdown-body ul, .markdown-body ol { margin: 0 0 1.1em; padding-left: 1.5em; }
.markdown-body li { margin: .3em 0; }
.markdown-body blockquote {
  margin: 1.2em 0; padding: 12px 18px; border-left: 3px solid var(--accent);
  background: var(--bg-alt); border-radius: 0 10px 10px 0; color: var(--text-2);
}
.markdown-body blockquote p { margin: 0; }
.markdown-body code {
  font-family: var(--font-mono); font-size: .88em; background: var(--bg-alt);
  padding: 2px 6px; border-radius: 6px; color: #c026d3;
}
.markdown-body pre {
  background: #17181d; color: #e7e9ee; padding: 18px 20px; border-radius: 12px;
  overflow-x: auto; margin: 1.3em 0; line-height: 1.6;
}
.markdown-body pre code { background: none; color: inherit; padding: 0; font-size: 13.5px; }
.markdown-body img { border-radius: 12px; margin: 1.2em 0; box-shadow: var(--shadow-sm); }
.markdown-body hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }
.markdown-body strong { font-weight: 700; }

/* ---------- 页脚 ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg-alt); padding: 40px 0; }
.footer-inner { text-align: center; color: var(--text-3); font-size: 13.5px; }
.footer-inner p { margin: 4px 0; }
.footer-meta { font-size: 12.5px; }

/* ---------- 回到顶部 ---------- */
.back-top {
  position: fixed; right: 22px; bottom: 22px; width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--border); background: #fff; color: var(--text-2);
  box-shadow: var(--shadow-md); opacity: 0; pointer-events: none; transform: translateY(8px);
  transition: opacity .25s, transform .25s; z-index: 40; font-size: 17px;
}
.back-top.show { opacity: 1; pointer-events: auto; transform: translateY(0); }
.back-top:hover { color: var(--accent); border-color: var(--accent); }

/* ---------- 入场动画 ---------- */
[data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
[data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .mesh i { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- 账户（左上角） ---------- */
.header-left { display: flex; align-items: center; gap: 16px; min-width: 0; }
.account-box { display: flex; align-items: center; }
.account-login {
  font-size: 13.5px; font-weight: 600; color: var(--accent);
  padding: 6px 15px; border: 1px solid var(--accent); border-radius: 999px;
  transition: background .18s, color .18s;
}
.account-login:hover { background: var(--accent); color: #fff; }
.account-me { display: inline-flex; align-items: center; gap: 8px; }
.account-avatar {
  width: 30px; height: 30px; border-radius: 50%; overflow: hidden; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center; background: var(--grad);
}
.account-avatar img { width: 100%; height: 100%; object-fit: cover; }
.account-name { font-size: 13.5px; font-weight: 600; color: var(--text); max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.role-badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 6px; flex: 0 0 auto; }
.role-badge.admin { background: var(--accent-soft); color: var(--accent-text); }
.role-badge.user { background: var(--bg-alt); color: var(--text-2); border: 1px solid var(--border); }

/* ---------- 文章卡片浏览/点赞 ---------- */
.blog-meta-row { display: flex; gap: 14px; color: var(--text-3); font-size: 12.5px; margin: 0 0 12px; }

/* ---------- 文章详情：点赞 / 评论 ---------- */
.meta-dot { color: var(--text-3); }
.article-actions { margin: 28px 0 8px; display: flex; }
.like-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: 999px; border: 1px solid var(--border-strong);
  background: #fff; color: var(--text-2); font-size: 15px; font-weight: 600;
  transition: border-color .18s, color .18s, transform .12s, background .18s;
}
.like-btn:hover { border-color: #f43f5e; color: #f43f5e; transform: translateY(-2px); }
.like-btn.liked { background: #fff1f2; border-color: #f43f5e; color: #f43f5e; }
.like-btn svg { display: block; }

.comments { margin-top: 26px; padding-top: 24px; border-top: 1px solid var(--border); }
.comments-head { font-size: 17px; font-weight: 800; margin-bottom: 16px; }
.comments-count { color: var(--text-3); font-weight: 500; font-size: 14px; }
.comments-login { color: var(--text-3); font-size: 14px; background: var(--bg-alt); padding: 14px 16px; border-radius: 10px; }
.comments-login a { color: var(--accent); font-weight: 600; }
.comment-form { display: flex; gap: 10px; margin-bottom: 20px; }
.comment-form textarea {
  flex: 1; min-height: 64px; padding: 12px; border: 1px solid var(--border-strong);
  border-radius: 12px; font-size: 14.5px; font-family: inherit; resize: vertical;
}
.comment-form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.comment-form .btn { align-self: flex-end; }
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-item { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.comment-item:last-child { border-bottom: none; }
.comment-avatar { width: 38px; height: 38px; border-radius: 50%; overflow: hidden; flex: 0 0 auto; background: var(--grad); display: flex; align-items: center; justify-content: center; }
.comment-avatar img { width: 100%; height: 100%; object-fit: cover; }
.comment-main { min-width: 0; flex: 1; }
.comment-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.comment-meta b { font-size: 14px; }
.comment-meta span { font-size: 12px; color: var(--text-3); }
.comment-content { font-size: 14.5px; color: var(--text); line-height: 1.7; overflow-wrap: break-word; }
.comments-empty { color: var(--text-3); font-size: 14px; text-align: center; padding: 20px; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .video-layout { grid-template-columns: 1fr; }
  .player { grid-template-columns: 1fr; }
  .player-list { border-left: none; border-top: 1px solid var(--border); padding-left: 0; padding-top: 16px; }
  .hero-name { font-size: 38px; }
}
@media (max-width: 560px) {
  .blog-grid, .projects-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .account-name { display: none; }
  .hero { padding: 64px 0 48px; }
  .section { padding: 52px 0; }
  .hero-name { font-size: 32px; }
  .article-title { font-size: 27px; }
}
