/* ====================================================
   XinLuo — Blog Styles v6
   PC: 3列网格，默认9篇大卡，展开30篇大卡(3×10)
   手机: 时间轴不变
   ==================================================== */

@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@400..700&family=Inter:wght@300..900&display=swap');

/* ========== 全局重置 ========== */
* { margin: 0; padding: 0; box-sizing: border-box; }

/* ========== 深色主题变量（默认） ========== */
:root,
html[data-theme="dark"] {
  --primary: #f97316;
  --primary-dark: #ea580c;
  --primary-light: #fdba74;
  --secondary: #f59e0b;
  --bg-body: #000000;
  --bg-surface: #0a0a0a;
  --bg-card: #111111;
  --bg-elevated: #161616;
  --bg-input: #1a1a1a;
  --text-primary: #f5f5f5;
  --text-secondary: #a3a3a3;
  --text-muted: #666666;
  --text-faint: #404040;
  --white: #ffffff;
  --border-subtle: #1f1f1f;
  --border-card: #262626;
  --border-input: #333333;
  --gradient-1: linear-gradient(135deg, #f97316 0%, #f59e0b 100%);
  --gradient-2: linear-gradient(135deg, #1a0a00 0%, #0d0d0d 100%);
  --shadow-sm: 0 2px 8px rgba(249,115,22,0.08);
  --shadow-md: 0 8px 30px rgba(249,115,22,0.12);
  --shadow-lg: 0 20px 60px rgba(249,115,22,0.15);
  --shadow-glow: 0 0 40px rgba(249,115,22,0.25);
  --nav-bg: rgba(0,0,0,0.75);
  --nav-bg-scrolled: rgba(5,5,5,0.95);
  --footer-bg: #050505;
  --shape-diamond: rgba(249,115,22,0.08);
  --shape-circle: rgba(245,158,11,0.06);
  --shape-square: rgba(251,146,60,0.06);
  --radius: 14px;
  --radius-lg: 22px;
  --transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
}

/* ========== 浅色主题变量 ========== */
html[data-theme="light"] {
  --primary: #3b82f6;
  --primary-dark: #2563eb;
  --primary-light: #93c5fd;
  --secondary: #6366f1;
  --bg-body: #f0f4f8;
  --bg-surface: #ffffff;
  --bg-card: #ffffff;
  --bg-elevated: #eef2ff;
  --bg-input: #eef2ff;
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-faint: #94a3b8;
  --white: #ffffff;
  --border-subtle: #e2e8f0;
  --border-card: #e8ecf1;
  --border-input: #cbd5e1;
  --gradient-1: linear-gradient(135deg, #3b82f6 0%, #6366f1 100%);
  --gradient-2: linear-gradient(135deg, #dbeafe 0%, #eef2ff 100%);
  --shadow-sm: 0 2px 8px rgba(59,130,246,0.06);
  --shadow-md: 0 8px 30px rgba(59,130,246,0.08);
  --shadow-lg: 0 20px 60px rgba(59,130,246,0.10);
  --shadow-glow: 0 0 40px rgba(59,130,246,0.15);
  --nav-bg: rgba(255,255,255,0.80);
  --nav-bg-scrolled: rgba(255,255,255,0.97);
  --footer-bg: #0f172a;
  --shape-diamond: rgba(59,130,246,0.07);
  --shape-circle: rgba(99,102,241,0.06);
  --shape-square: rgba(59,130,246,0.05);
  --radius: 14px;
  --radius-lg: 22px;
  --transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
}

/* ========== 基础 ========== */
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: 'Inter', 'WenQuanYi Micro Hei', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-body);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
  margin: 0; padding: 0;
}
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ========== Iconify ========== */
iconify-icon { display: inline-flex; vertical-align: middle; color: currentColor; flex-shrink: 0; }

/* ========== 几何形状装饰 ========== */
.shape-diamond { position: absolute; background: var(--shape-diamond); border:1px solid var(--border-card); transform: rotate(45deg); border-radius: 4px; z-index: 0; pointer-events: none; }
.shape-circle { position: absolute; border-radius: 50%; border:2px solid var(--shape-circle); background: transparent; z-index: 0; pointer-events: none; }
.shape-square { position: absolute; border:2px solid var(--shape-square); border-radius: 6px; z-index: 0; pointer-events: none; }
.dark-shape { display: none; }
html[data-theme="dark"] .dark-shape { display: block; }
html[data-theme="light"] .dark-shape { display: none; }

/* ========== 鼠标跟随 Spotlight ========== */
.cursor-spotlight {
  position: fixed; top: 0; left: 0;
  width: 520px; height: 520px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.4s ease;
  mix-blend-mode: screen;
}
html[data-theme="dark"] .cursor-spotlight { background: radial-gradient(circle, rgba(249,115,22,0.10) 0%, transparent 70%); }
html[data-theme="light"] .cursor-spotlight { background: radial-gradient(circle, rgba(59,130,246,0.08) 0%, transparent 70%); mix-blend-mode: multiply; }
body.cursor-active .cursor-spotlight { opacity: 1; }

/* ========== Turnstile 进站验证闸门 ========== */
.turnstile-gate {
  position: fixed; inset: 0; z-index: 99999;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
.turnstile-gate.passed { opacity: 0; visibility: hidden; pointer-events: none; }
.turnstile-gate-box {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 20px;
  padding: 48px 40px 36px;
  text-align: center;
  max-width: 420px;
  width: 90%;
  animation: gateFadeUp 0.4s ease;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
html[data-theme="dark"] .turnstile-gate-box { background: #111; border-color: #262626; }
html[data-theme="light"] .turnstile-gate-box { background: #fff; }
.turnstile-gate-logo {
  font-family: 'Caveat', cursive;
  font-size: 42px; font-weight: 700;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 4px;
}
.turnstile-gate-sub {
  font-size: 14px; color: var(--text-muted);
  margin-bottom: 24px;
}
.turnstile-gate-hint {
  font-size: 13px; color: var(--text-muted);
  margin: 20px 0 8px;
}
.turnstile-gate-footer {
  font-size: 12px; color: var(--text-faint);
  margin-top: 16px;
}
.turnstile-gate-error {
  font-size: 13px; color: #ef4444;
  margin-top: 12px; min-height: 18px;
}
.turnstile-widget { display: flex; justify-content: center; min-height: 65px; }
@keyframes gateFadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ========== 深色模式背景特效 ========== */
.dark-bg-effects { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
html[data-theme="light"] .dark-bg-effects { display: none; }
.meteors-container { position: absolute; inset: 0; }
.meteor { position: absolute; width: 2px; height: 2px; background: linear-gradient(45deg, rgba(249,115,22,0.9), transparent); border-radius: 50%; animation: meteor-fall linear infinite; opacity: 0; }
.meteor::before { content: ''; position: absolute; top: 50%; left: 50%; width: 150px; height: 1px; background: linear-gradient(90deg, rgba(249,115,22,0.3), transparent); transform: translate(-100%, -50%) rotate(-45deg); transform-origin: right; }
@keyframes meteor-fall {
  0% { opacity: 0; transform: translate(0,0) rotate(45deg); }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { opacity: 0; transform: translate(-500px,500px) rotate(45deg); }
}
.stars-container { position: absolute; inset: 0; }
.glow-star { position: absolute; width: 3px; height: 3px; background: #fdba74; border-radius: 50%; animation: star-twinkle ease-in-out infinite; }
.glow-star::after { content: ''; position: absolute; top: 50%; left: 50%; width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(circle, rgba(249,115,22,0.3) 0%, transparent 70%); transform: translate(-50%,-50%); }
@keyframes star-twinkle { 0%,100% { opacity: 0.3; transform: scale(1); } 50% { opacity: 1; transform: scale(1.3); } }

/* ========== 浅色极光 ========== */
.light-aurora-bg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
html[data-theme="dark"] .light-aurora-bg { display: none; }
html[data-theme="light"] .light-aurora-bg { display: block; }
.aurora-layer { position: absolute; border-radius: 50%; filter: blur(60px); opacity: 0.5; animation: aurora-flow ease-in-out infinite; }
.aurora-1 { width:600px;height:400px;top:-10%;left:-5%;background:linear-gradient(135deg,rgba(59,130,246,0.3),rgba(99,102,241,0.2));animation-duration:18s; }
.aurora-2 { width:500px;height:500px;top:20%;right:-10%;background:linear-gradient(135deg,rgba(99,102,241,0.25),rgba(139,92,246,0.15));animation-duration:25s;animation-direction:reverse; }
.aurora-3 { width:450px;height:350px;bottom:10%;left:20%;background:linear-gradient(135deg,rgba(56,189,248,0.2),rgba(59,130,246,0.15));animation-duration:22s; }
.aurora-4 { width:550px;height:450px;bottom:-5%;right:10%;background:linear-gradient(135deg,rgba(129,140,248,0.2),rgba(165,180,252,0.1));animation-duration:20s;animation-direction:reverse; }
@keyframes aurora-flow { 0%,100% { transform: translate(0,0) scale(1); } 33% { transform: translate(30px,-30px) scale(1.05); } 66% { transform: translate(-20px,20px) scale(0.95); } }

/* ========== 顶部导航栏 ========== */
.navbar { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; background: var(--nav-bg); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid var(--border-subtle); transition: var(--transition); padding-top: 1px; }
.navbar.scrolled { background: var(--nav-bg-scrolled); box-shadow: var(--shadow-md); }
.nav-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; height: 72px; gap: 12px; }
.nav-logo { order: 0; flex: 0 0 auto; }
.logo-text { font-family: 'Caveat', cursive; font-size: 34px; font-weight: 700; color: var(--text-primary); text-decoration: none; letter-spacing: -0.5px; transition: color 0.3s; display: inline-flex; align-items: center; }
html[data-theme="dark"] .logo-text { background: var(--gradient-1); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
html[data-theme="light"] .logo-text { color: var(--primary-dark); }
.nav-menu { order: 1; flex: 1 1 auto; display: flex; list-style: none; gap: 6px; justify-content: center; }
.nav-link { display: inline-flex; align-items: center; gap: 6px; color: var(--text-secondary); text-decoration: none; font-size: 15px; font-weight: 500; padding: 8px 16px; border-radius: 8px; transition: var(--transition); position: relative; }
.nav-link:hover, .nav-link.active { color: var(--primary); background: var(--bg-elevated); }
html[data-theme="dark"] .nav-link:hover, html[data-theme="dark"] .nav-link.active { color: var(--primary-light); background: rgba(249,115,22,0.12); }
html[data-theme="light"] .nav-link:hover, html[data-theme="light"] .nav-link.active { color: var(--primary-dark); background: rgba(59,130,246,0.08); }
.nav-actions { order: 2; flex: 0 0 auto; display: flex; align-items: center; gap: 8px; }
.theme-toggle { display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--border-card); background: var(--bg-elevated); color: var(--text-primary); cursor: pointer; transition: var(--transition); flex-shrink: 0; }
.theme-toggle:hover { background: var(--primary) !important; color: #fff !important; border-color: var(--primary) !important; transform: translateY(-2px); box-shadow: 0 4px 15px var(--shadow-glow); }
html[data-theme="dark"] .theme-toggle { color: var(--primary-light); border-color: #333; }
html[data-theme="light"] .theme-toggle { color: var(--primary-dark); }
.theme-icon { transition: opacity 0.3s ease, transform 0.3s ease; }
html[data-theme="dark"] .theme-icon-sun { display: block; }
html[data-theme="dark"] .theme-icon-moon { display: none; }
html[data-theme="light"] .theme-icon-sun { display: none; }
html[data-theme="light"] .theme-icon-moon { display: block; }
.nav-toggle { display: none; flex-direction: column; cursor: pointer; gap: 5px; padding: 8px; border-radius: 8px; transition: var(--transition); flex-shrink: 0; border: none; background: transparent; }
.nav-toggle:hover { background: var(--bg-elevated); }
html[data-theme="dark"] .nav-toggle:hover { background: rgba(249,115,22,0.15); }
html[data-theme="dark"] .nav-toggle:hover .bar { background: var(--primary-light); }
html[data-theme="light"] .nav-toggle:hover .bar { background: var(--primary-dark); }
.nav-toggle .bar { width: 25px; height: 2px; background: var(--text-primary); border-radius: 2px; transition: var(--transition); }
@media (max-width: 968px) { .nav-menu { display: none; } .nav-toggle { display: flex; } }

/* ========== 移动端侧边栏 ========== */
.sidebar-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(4px); z-index: 1500; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; }
.sidebar-overlay.active { opacity: 1; visibility: visible; }
.sidebar { position: fixed; top: 0; left: 0; width: 280px; max-width: 80vw; height: 100vh; background: var(--bg-surface); border-right: 1px solid var(--border-subtle); z-index: 1600; display: flex; flex-direction: column; transform: translateX(-100%); transition: transform 0.3s cubic-bezier(0.4,0,0.2,1); box-shadow: var(--shadow-lg); }
.sidebar.active { transform: translateX(0); }
.sidebar-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--border-subtle); min-height: 72px; }
.sidebar-logo { font-family: 'Caveat', cursive; font-size: 28px; font-weight: 700; background: var(--gradient-1); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.sidebar-close { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--border-card); background: transparent; color: var(--text-primary); cursor: pointer; transition: var(--transition); padding: 0; }
.sidebar-close:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.sidebar-nav { flex: 1; display: flex; flex-direction: column; padding: 16px 12px; gap: 4px; overflow-y: auto; }
.sidebar-link { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 12px; text-decoration: none; color: var(--text-secondary); font-size: 16px; font-weight: 500; transition: var(--transition); }
.sidebar-link:hover, .sidebar-link.active { background: var(--bg-elevated); color: var(--primary); }
html[data-theme="dark"] .sidebar-link:hover, html[data-theme="dark"] .sidebar-link.active { background: rgba(249,115,22,0.12); color: var(--primary-light); }
html[data-theme="light"] .sidebar-link:hover, html[data-theme="light"] .sidebar-link.active { background: rgba(59,130,246,0.08); color: var(--primary-dark); }
.sidebar-text { flex: 1; }
.sidebar-footer { padding: 16px 20px; border-top: 1px solid var(--border-subtle); }
.sidebar-theme-toggle { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--border-card); background: var(--bg-elevated); color: var(--text-primary); cursor: pointer; transition: var(--transition); font-family: inherit; font-size: 15px; font-weight: 500; }
.sidebar-theme-toggle:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ========== 搜索弹窗 ========== */
.search-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(8px); z-index: 2000; display: flex; align-items: flex-start; justify-content: center; padding-top: 15vh; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; }
.search-overlay.active { opacity: 1; visibility: visible; }
.search-modal { width: 90%; max-width: 600px; background: var(--bg-surface); border: 1px solid var(--border-card); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lg); transform: translateY(-20px); transition: transform 0.3s ease; }
.search-overlay.active .search-modal { transform: translateY(0); }
.search-header { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--border-subtle); }
.search-header .search-icon { color: var(--text-muted); }
.search-header input { flex: 1; background: transparent; border: none; outline: none; color: var(--text-primary); font-size: 16px; font-family: inherit; }
.search-header input::placeholder { color: var(--text-muted); }
.search-close { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--border-card); background: transparent; color: var(--text-secondary); cursor: pointer; transition: var(--transition); }
.search-close:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.search-results { max-height: 50vh; overflow-y: auto; padding: 8px; }
.search-result-item { display: block; padding: 14px 16px; border-radius: 10px; text-decoration: none; color: var(--text-primary); transition: var(--transition); border-bottom: 1px solid var(--border-subtle); }
.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--bg-elevated); }
.search-result-title { font-weight: 600; margin-bottom: 4px; }
.search-result-snippet { font-size: 13px; color: var(--text-muted); }
.search-empty { padding: 30px; text-align: center; color: var(--text-muted); }

/* ========== 博客主内容 ========== */
.blog-main { margin-top: 72px; min-height: calc(100vh - 72px); }

/* 页面标题区 */
.blog-hero { padding: 60px 0 40px; text-align: center; position: relative; }
.blog-title { font-family: 'Caveat', cursive; font-size: 72px; font-weight: 700; background: var(--gradient-1); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; margin-bottom: 12px; letter-spacing: -1px; }
html[data-theme="light"] .blog-title { color: var(--primary-dark); }
.blog-subtitle { font-size: 18px; color: var(--text-secondary); margin-bottom: 40px; }

/* 工具栏 */
.blog-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; max-width: 800px; margin: 0 auto; padding: 16px 24px; background: var(--bg-card); border: 1px solid var(--border-card); border-radius: var(--radius); }
.blog-stats { display: flex; gap: 20px; font-size: 14px; color: var(--text-muted); }
.stat-item { display: inline-flex; align-items: center; gap: 6px; }
.stat-item iconify-icon { color: var(--primary); }
.blog-sort { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-secondary); }
.sort-select { background: var(--bg-input); border: 1px solid var(--border-input); color: var(--text-primary); padding: 6px 12px; border-radius: 8px; font-size: 14px; font-family: inherit; cursor: pointer; outline: none; transition: var(--transition); }
.sort-select:focus { border-color: var(--primary); }
.sort-select option { background: var(--bg-card); color: var(--text-primary); }

/* ========== 空状态 ========== */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state iconify-icon { margin-bottom: 16px; opacity: 0.5; }
.empty-state p { font-size: 16px; }

/* ========== 流光描边按钮 ========== */
.btn-glow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 22px; border: none; border-radius: 10px;
  font-size: 14px; font-weight: 600; font-family: inherit;
  color: #fff; cursor: pointer; position: relative;
  background: var(--gradient-1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}
html[data-theme="dark"] .btn-glow { background: linear-gradient(135deg, #f97316 0%, #f59e0b 100%); }
html[data-theme="light"] .btn-glow { background: linear-gradient(135deg, #3b82f6 0%, #6366f1 100%); }
.btn-glow::before {
  content: ''; position: absolute; inset: -2px; border-radius: 12px; padding: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: border-flow 3s linear infinite; opacity: 0; transition: opacity 0.3s ease;
}
.btn-glow:hover::before { opacity: 1; }
.btn-glow:hover { transform: translateY(-2px); box-shadow: var(--shadow-glow); }
@keyframes border-flow { 0% { background-position: 0% 50%; } 100% { background-position: 200% 50%; } }

/* ========== 显示更多按钮容器 ========== */
.load-more-wrap, .load-more-wrap-mobile { text-align: center; margin: 40px 0; }
.load-more-wrap[style*="display: none"], .load-more-wrap-mobile[style*="display: none"] { display: none !important; }

/* ========== PC 端网格布局 ========== */
.blog-grid-section { padding: 20px 0 40px; }
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}
/* 展开后仍然是3列，行数变多（3×10=30篇） */
.post-grid.expanded {
  grid-template-columns: repeat(3, 1fr);
}

/* ========== 文章卡片（大卡，PC端统一使用） ========== */
.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius);
  padding: 28px;
  text-align: left;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.post-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--gradient-1); opacity: 0; transition: opacity 0.3s ease;
}
.post-card:hover { border-color: var(--primary); box-shadow: var(--shadow-md); transform: translateY(-3px); }
.post-card:hover::before { opacity: 1; }

.post-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.post-tag { display: inline-block; padding: 3px 10px; background: var(--bg-elevated); color: var(--primary); border: 1px solid var(--border-card); border-radius: 20px; font-size: 12px; font-weight: 500; }
html[data-theme="dark"] .post-tag { color: var(--primary-light); }

.post-title { font-size: 20px; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; line-height: 1.4; }
.post-excerpt { font-size: 14px; color: var(--text-secondary); line-height: 1.7; margin-bottom: 16px; flex: 1; }
.post-meta { display: flex; align-items: center; gap: 16px; font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }
.post-meta span { display: inline-flex; align-items: center; gap: 4px; }

.post-read-more { display: inline-flex; align-items: center; gap: 6px; padding: 8px 18px; background: var(--bg-elevated); color: var(--primary); border: 1px solid var(--border-card); border-radius: 8px; font-size: 14px; font-weight: 500; text-decoration: none; transition: var(--transition); cursor: pointer; align-self: flex-start; }
.post-read-more:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ========== 手机端时间轴 ========== */
.blog-timeline-section { padding: 20px 0 40px; }
.timeline-mobile { position: relative; max-width: 700px; margin: 0 auto; padding: 20px 0; }
.timeline-mobile::before { content: ''; position: absolute; top: 0; bottom: 0; left: 20px; width: 2px; background: linear-gradient(to bottom, transparent, var(--primary) 10%, var(--primary) 90%, transparent); transform: translateX(-50%); opacity: 0.4; }

.timeline-mobile-item { position: relative; padding: 16px 16px 16px 50px; opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.6s ease; }
.timeline-mobile-item.visible { opacity: 1; transform: translateY(0); }
.timeline-mobile-dot { position: absolute; top: 24px; left: 12px; width: 16px; height: 16px; border-radius: 50%; background: var(--primary); border: 3px solid var(--bg-body); box-shadow: 0 0 12px var(--shadow-glow); z-index: 2; }

/* 手机端卡片（在时间轴内，样式稍紧凑但仍是大卡风格） */
.timeline-mobile .post-card { padding: 20px; }

/* ========== 留言板 ========== */
.blog-comments { padding: 60px 0; background: var(--bg-surface); border-top: 1px solid var(--border-subtle); }
.section-title { font-size: 28px; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; text-align: center; }
.section-desc { font-size: 15px; color: var(--text-muted); text-align: center; margin-bottom: 40px; }

.comment-form-wrap { max-width: 700px; margin: 0 auto 40px; }
.comment-form { background: var(--bg-card); border: 1px solid var(--border-card); border-radius: var(--radius); padding: 24px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.comment-form input, .comment-form textarea { width: 100%; background: var(--bg-input); border: 1px solid var(--border-input); color: var(--text-primary); padding: 12px 16px; border-radius: 10px; font-size: 14px; font-family: inherit; outline: none; transition: var(--transition); resize: vertical; }
.comment-form input:focus, .comment-form textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(249,115,22,0.1); }
html[data-theme="light"] .comment-form input:focus, html[data-theme="light"] .comment-form textarea:focus { box-shadow: 0 0 0 3px rgba(59,130,246,0.1); }
.form-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; }
.form-hint { font-size: 12px; color: var(--text-muted); }

.comment-list { max-width: 700px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.comment-item { background: var(--bg-card); border: 1px solid var(--border-card); border-radius: var(--radius); padding: 18px 20px; animation: commentIn 0.4s ease; }
@keyframes commentIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.comment-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.comment-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--gradient-1); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 14px; flex-shrink: 0; }
.comment-name { font-weight: 600; color: var(--text-primary); font-size: 14px; }
.comment-time { font-size: 12px; color: var(--text-muted); }
.comment-body { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

/* ========== 页脚 ========== */
.footer { background: var(--footer-bg); padding: 40px 0 24px; color: var(--text-muted); }
html[data-theme="dark"] .footer { background: #050505; }
html[data-theme="light"] .footer { background: #0f172a; color: #94a3b8; }
.footer-content { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 20px; margin-bottom: 24px; }
.footer-brand .footer-logo { font-family: 'Caveat', cursive; font-size: 28px; font-weight: 700; color: var(--primary); display: block; margin-bottom: 4px; }
.footer-brand p { font-size: 13px; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 14px; transition: color 0.3s; }
.footer-links a:hover { color: var(--primary); }
.footer-social { display: flex; gap: 12px; }
.footer-social a { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--border-card); color: var(--text-muted); transition: var(--transition); }
.footer-social a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.footer-bottom { text-align: center; font-size: 13px; border-top: 1px solid var(--border-subtle); padding-top: 20px; }

/* ========== 回到顶部 ========== */
.back-to-top { position: fixed; bottom: 30px; right: 30px; width: 48px; height: 48px; border-radius: 14px; border: 1px solid var(--border-card); background: var(--bg-elevated); color: var(--primary); cursor: pointer; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: var(--transition); z-index: 999; }
.back-to-top.visible { opacity: 1; visibility: visible; }
.back-to-top:hover { background: var(--primary); color: #fff; border-color: var(--primary); transform: translateY(-3px); }

/* ========== AOS 滚动入场 ========== */
.aos-init { opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.6s ease; }
.aos-init.visible { opacity: 1; transform: translateY(0); }

/* ========== 响应式 ========== */
@media (max-width: 968px) {
  /* PC 网格隐藏，手机时间轴显示 */
  .blog-grid-section { display: none; }
  .blog-timeline-section { display: block; }
}
@media (min-width: 969px) {
  /* PC 上隐藏手机时间轴 */
  .blog-timeline-section { display: none; }
  .blog-grid-section { display: block; }
}

@media (max-width: 768px) {
  .blog-title { font-size: 48px; }
  .blog-subtitle { font-size: 16px; }
  .blog-toolbar { flex-direction: column; align-items: flex-start; }
  .form-row { grid-template-columns: 1fr; }
  .footer-content { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  .nav-container { padding: 0 16px; }
  .container { padding: 0 16px; }
  .blog-title { font-size: 40px; }
  .post-card { padding: 20px; }
}
