:root{
  --sidebar-w:230px;
  --primary:#3b6cf6;
  --primary-dark:#2c54c9;
  --bg:#f4f6fb;
  --text:#1f2937;
  --muted:#6b7280;
  --border:#e5e7eb;
}
*{box-sizing:border-box}
body{margin:0;font-family:"Segoe UI","Microsoft YaHei",system-ui,sans-serif;background:var(--bg);color:var(--text);font-size:14px;}

/* ====== 登录注册页 ====== */
.auth-body{
  min-height:100vh;display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#4a6cf7 0%,#6d5df6 50%,#8e5df0 100%);padding:20px;
}
.auth-card{
  width:100%;max-width:400px;background:#fff;border-radius:16px;padding:36px 32px;
  box-shadow:0 20px 60px rgba(0,0,0,.2);animation:fadeUp .6s ease;
}
@keyframes fadeUp{from{opacity:0;transform:translateY(20px)}to{opacity:1;transform:none}}
.auth-brand{font-size:2.6rem;color:var(--primary);text-align:center;margin-bottom:6px}
.auth-hint{margin-top:14px;text-align:center;color:var(--muted);font-size:12px}
.form-label{font-weight:600;color:#374151;font-size:13px}

/* ====== 主框架布局 ====== */
.app-wrapper{display:flex;min-height:100vh}
.sidebar{
  width:var(--sidebar-w);background:linear-gradient(180deg,#1e293b 0%,#0f172a 100%);color:#cbd5e1;
  position:fixed;top:0;bottom:0;left:0;display:flex;flex-direction:column;padding:18px 0;z-index:10;
}
.brand{padding:6px 22px 22px;font-size:1.25rem;font-weight:700;color:#fff;display:flex;align-items:center;gap:8px}
.nav-menu{display:flex;flex-direction:column;padding:0 10px;gap:4px}
.nav-item{
  display:flex;align-items:center;gap:12px;padding:11px 14px;color:#cbd5e1;text-decoration:none;
  border-radius:8px;transition:.2s;font-weight:500;
}
.nav-item i{font-size:1.15rem}
.nav-item:hover{background:rgba(255,255,255,.08);color:#fff}
.nav-item.active{
  background:linear-gradient(90deg,rgba(59,108,246,.22) 0%,rgba(59,108,246,.08) 100%);
  color:#60a5fa;position:relative;font-weight:700;
  box-shadow:inset 3px 0 0 #60a5fa
}
.nav-item.active i{color:#3b82f6}
.main{margin-left:var(--sidebar-w);flex:1;display:flex;flex-direction:column;min-width:0}

.topbar{
  background:#fff;height:60px;display:flex;align-items:center;justify-content:space-between;
  padding:0 24px;border-bottom:1px solid var(--border);position:sticky;top:0;z-index:5;
}
.topbar-title{font-size:1.15rem;font-weight:700}
.topbar-user{display:flex;align-items:center;gap:6px;color:var(--muted)}
.topbar-user .btn{color:var(--muted);border-color:var(--border)}
.topbar-user-link{padding:6px 10px;border-radius:10px;color:#1e293b;transition:.2s;background:rgba(59,108,246,.06);border:1px solid rgba(59,108,246,.12)}
.topbar-user-link:hover{background:rgba(59,108,246,.13);color:var(--primary-dark)}
.topbar-avatar{width:36px;height:36px;border-radius:50%;border:2px solid #fff;background:#eef2ff;box-shadow:0 1px 3px rgba(0,0,0,.08)}
.topbar-nick{font-weight:700;font-size:14px;color:#1e293b;line-height:1.1}
.topbar-real{font-size:12px;color:var(--muted)}

/* ====== 语言切换器 ====== */
.lang-switcher{font-size:13px;}
.lang-switcher .lang-btn{color:#6b7280;text-decoration:none;padding:2px 8px;border-radius:6px;transition:.2s;border:1px solid transparent}
.lang-switcher .lang-btn:hover{color:#3b6cf6;background:rgba(59,108,246,.08)}
.lang-switcher .lang-btn.active{color:#3b6cf6;background:rgba(59,108,246,.1);font-weight:700;border-color:rgba(59,108,246,.25)}
.lang-switcher .lang-sep{color:#e5e7eb;margin:0 2px}

/* ====== 个人中心 ====== */
.profile-header{background:linear-gradient(135deg,#eef2ff 0%,#f5f3ff 100%);border:1px solid #e0e7ff}
.profile-avatar{width:84px;height:84px;border-radius:20px;background:#fff;border:4px solid #fff;box-shadow:0 4px 14px rgba(59,108,246,.15)}

/* 选考科目卡片 */
.subject-chip{display:block;position:relative;padding:14px 16px;border:2px solid #e5e7eb;border-radius:12px;cursor:pointer;transition:all .2s;background:#fff;user-select:none}
.subject-chip:hover{border-color:#c7d2fe;background:#f5f3ff}
.subject-chip .check-icon{font-size:1.4rem;color:#d1d5db;transition:color .2s}
.subject-chip.selected{border-color:#6366f1;background:#eef2ff}
.subject-chip.selected .check-icon{color:#6366f1}

.content{padding:22px 24px;flex:1}

/* ====== 底部ICP备案号 ====== */
.app-footer{
  padding:12px 24px;background:#fff;border-top:1px solid var(--border);
  font-size:12px;color:var(--muted);
}
.app-footer .icp-link{
  color:var(--muted);text-decoration:none;transition:.2s;
}
.app-footer .icp-link:hover{color:var(--primary)}
.auth-footer{
  position:fixed;bottom:12px;left:0;right:0;
  font-size:12px;color:rgba(255,255,255,.85);
}
.auth-footer .icp-link{
  color:rgba(255,255,255,.85);text-decoration:none;transition:.2s;
}
.auth-footer .icp-link:hover{color:#fff;text-decoration:underline}

/* ====== 错题题干图片 ====== */
.question-title-cell{overflow:hidden;word-wrap:break-word}
.question-title-cell img{max-width:100%;max-height:200px;border-radius:6px;margin:2px 0;vertical-align:middle}

/* ====== 卡片 ====== */
.card{border:1px solid var(--border);border-radius:12px;box-shadow:0 1px 3px rgba(0,0,0,.04)}
.card-header{background:#fff;border-bottom:1px solid var(--border);font-weight:700;padding:12px 16px;border-radius:12px 12px 0 0}
.card-header i{color:var(--primary)}

/* ====== 统计卡 ====== */
.stat-card{
  border-radius:12px;padding:18px 20px;color:#fff;display:flex;align-items:center;gap:14px;
  box-shadow:0 4px 12px rgba(0,0,0,.08);
}
.stat-icon{font-size:2rem;opacity:.85}
.stat-label{font-size:12px;opacity:.9}
.stat-value{font-size:1.6rem;font-weight:700;line-height:1.2}
.stat-value.stat-sm{font-size:1.15rem}
.stat-blue{background:linear-gradient(135deg,#4a90ff,#2c6cf0)}
.stat-green{background:linear-gradient(135deg,#36c98c,#1ea67a)}
.stat-purple{background:linear-gradient(135deg,#9b6df0,#7d4dd6)}
.stat-orange{background:linear-gradient(135deg,#ffa64d,#f47a1f)}

/* ====== 表格 ====== */
.table thead th{font-weight:700;color:#374151;font-size:13px}
.table td{vertical-align:middle}

/* ====== 掌握度星 ====== */
.mastery-stars i{color:#d1d5db;font-size:1rem;margin-right:1px}
.mastery-stars i.active{color:#f5a623}

/* ====== 得分率标签 ====== */
.rate-tag{display:inline-block;padding:2px 10px;border-radius:20px;font-size:12px;font-weight:700}
.rate-good{background:#dcfce7;color:#15803d}
.rate-mid{background:#fef3c7;color:#b45309}
.rate-bad{background:#fee2e2;color:#b91c1c}

/* ====== 进度条 ====== */
.progress{background:#e5e7eb;border-radius:10px}

/* ====== 按钮 ====== */
.btn-primary{background:var(--primary);border-color:var(--primary)}
.btn-primary:hover{background:var(--primary-dark);border-color:var(--primary-dark)}

/* ====== 状态/优先级标 ====== */
.status-tag{display:inline-block;padding:2px 10px;border-radius:12px;font-size:12px;font-weight:600}
.status-tag.todo{background:#fee2e2;color:#b91c1c}
.status-tag.done{background:#dcfce7;color:#15803d}
.status-tag.doing{background:#dbeafe;color:#1d4ed8}
.pri-tag{display:inline-block;padding:1px 8px;border-radius:6px;font-size:11px;font-weight:700}
.pri-tag.pri-h{background:#ffd1d1;color:#991b1b}
.pri-tag.pri-m{background:#fff3c2;color:#926208}
.pri-tag.pri-l{background:#d1fae5;color:#065f46}
.line-clamp-2{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}

/* 卡片左边框(优先级色) - 覆盖了 card border */
.card.border-start.border-5.border-danger{border-left-color:#dc3545!important}
.card.border-start.border-5.border-success{border-left-color:#198754!important}
.card.border-start.border-5.border-warning{border-left-color:#ffc107!important}

/* 滚动条美化 */
::-webkit-scrollbar{width:8px;height:8px}
::-webkit-scrollbar-thumb{background:#cbd5e1;border-radius:4px}
::-webkit-scrollbar-thumb:hover{background:#94a3b8}

/* 隐藏 number input spinner */
.sp-no-spinner::-webkit-inner-spin-button,.sp-no-spinner::-webkit-outer-spin-button{margin:0;-webkit-appearance:none;appearance:none}
.sp-no-spinner{-moz-appearance:textfield}

/* ======================================================================
   个人博客 (前台 + 后台)
   ====================================================================== */

.blog-body{
  background:#f7f8fc;color:#1f2937;font-size:15px;line-height:1.7;
  display:flex;flex-direction:column;min-height:100vh;
}

/* ---------- 顶部导航 ---------- */
.blog-nav{
  position:sticky;top:0;z-index:50;background:rgba(255,255,255,.88);
  backdrop-filter:saturate(180%) blur(12px);border-bottom:1px solid #e8ecf4;
}
.blog-nav-inner{
  max-width:1080px;margin:0 auto;padding:0 24px;height:62px;
  display:flex;align-items:center;justify-content:space-between;gap:16px;
}
.blog-brand{display:flex;align-items:center;gap:10px;text-decoration:none;color:#111827;font-weight:800;font-size:16px}
.blog-brand-mark{
  width:32px;height:32px;border-radius:10px;display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#4a6cf7,#8e5df0);color:#fff;font-size:15px;font-weight:800;
  box-shadow:0 4px 12px rgba(74,108,247,.32);
}
.blog-links{display:flex;align-items:center;gap:4px;flex-wrap:wrap}
.blog-links a{
  color:#4b5563;text-decoration:none;font-size:14px;font-weight:600;
  padding:7px 12px;border-radius:9px;transition:.18s;
}
.blog-links a:hover{color:#3b6cf6;background:#eef2ff}
.blog-link-demo{color:#3b6cf6!important;background:#eef2ff}
.blog-link-demo:hover{background:#e0e9ff!important}
.blog-link-admin{color:#7c3aed!important}
.blog-link-login{border:1px solid #dbe3f3}

/* ---------- 提醒条 ---------- */
.blog-flash-wrap{max-width:1080px;margin:18px auto 0;padding:0 24px;width:100%}
.blog-flash{
  display:flex;align-items:center;gap:8px;padding:11px 16px;border-radius:10px;
  font-size:14px;font-weight:600;margin-bottom:8px;
}
.blog-flash.ok{background:#ecfdf5;color:#047857;border:1px solid #a7f3d0}
.blog-flash.err{background:#fef2f2;color:#b91c1c;border:1px solid #fecaca}

/* ---------- 首页 Hero ---------- */
.hero{padding:72px 24px 56px;text-align:center}
.hero-inner{max-width:720px;margin:0 auto}
.hero-avatar{
  width:78px;height:78px;margin:0 auto 22px;border-radius:24px;
  display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#4a6cf7,#8e5df0);color:#fff;
  font-size:32px;font-weight:800;box-shadow:0 14px 34px rgba(74,108,247,.32);
}
.hero-name{font-size:34px;font-weight:800;margin:0 0 12px;letter-spacing:-.5px;color:#111827}
.hero-bio{font-size:16px;color:#6b7280;margin:0 auto;max-width:560px;line-height:1.8}
.hero-actions{display:flex;justify-content:center;gap:12px;margin-top:26px;flex-wrap:wrap}
.btn-hero-primary,.btn-hero-ghost{
  display:inline-flex;align-items:center;gap:7px;padding:10px 20px;border-radius:11px;
  font-size:14px;font-weight:700;text-decoration:none;transition:.2s;border:1px solid transparent;
}
.btn-hero-primary{background:#3b6cf6;color:#fff;box-shadow:0 6px 18px rgba(59,108,246,.28)}
.btn-hero-primary:hover{background:#2c54c9;color:#fff;transform:translateY(-1px)}
.btn-hero-ghost{background:#fff;color:#374151;border-color:#e2e8f4}
.btn-hero-ghost:hover{border-color:#c7d2fe;color:#3b6cf6;background:#f8faff}
.hero-stats{display:flex;align-items:center;justify-content:center;gap:22px;margin-top:34px}
.hero-stat{display:flex;flex-direction:column;align-items:center;gap:2px}
.hero-stat strong{font-size:22px;font-weight:800;color:#111827}
.hero-stat span{font-size:12px;color:#9ca3af;font-weight:600;letter-spacing:.4px}
.hero-stat-sep{width:1px;height:26px;background:#e5e7eb}

/* ---------- 区块 ---------- */
.blog-section{max-width:1080px;margin:0 auto;padding:12px 24px 40px;width:100%}
.section-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}
.section-head h2{font-size:19px;font-weight:800;margin:0;display:flex;align-items:center;gap:8px;color:#111827}
.section-head h2 i{color:#3b6cf6}
.section-more{
  font-size:13px;font-weight:700;color:#6b7280;text-decoration:none;
  display:inline-flex;align-items:center;gap:4px;transition:.18s;
}
.section-more:hover{color:#3b6cf6}

/* ---------- 文章卡片 ---------- */
.post-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.post-card{
  background:#fff;border:1px solid #e8ecf4;border-radius:16px;overflow:hidden;
  transition:.22s;box-shadow:0 1px 2px rgba(16,24,40,.04);
}
.post-card:hover{transform:translateY(-3px);border-color:#c7d2fe;box-shadow:0 12px 28px rgba(59,108,246,.13)}
.post-card-link{display:block;text-decoration:none;color:inherit;height:100%}
.post-card-body{padding:20px 22px}
.post-meta{display:flex;align-items:center;gap:10px;font-size:12px;color:#9ca3af;font-weight:600;margin-bottom:9px}
.post-cat{
  background:#eef2ff;color:#4f46e5;padding:2px 9px;border-radius:7px;
  font-size:11px;font-weight:800;letter-spacing:.3px;
}
.post-title{font-size:17px;font-weight:800;margin:0 0 8px;color:#111827;line-height:1.45}
.post-summary{
  margin:0;color:#6b7280;font-size:13.5px;line-height:1.75;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
}
.post-foot{margin-top:14px;font-size:12px;color:#9ca3af;font-weight:600;display:flex;gap:14px}
.post-views{margin-left:auto;display:inline-flex;align-items:center;gap:5px;font-weight:600;color:#9ca3af}
.post-views i{font-size:13px}

/* 列表页: 单列文章流 */
.post-list{display:flex;flex-direction:column;gap:14px}
.post-list .post-card-body{padding:22px 26px}
.post-list .post-title{font-size:19px}
.post-read-more{
  display:inline-flex;align-items:center;gap:5px;margin-top:14px;
  font-size:12.5px;font-weight:800;color:#3b6cf6;
}
.post-read-more i{transition:transform .18s}
.post-card:hover .post-read-more i{transform:translateX(3px)}

/* ---------- 项目卡片 ---------- */
.project-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.project-card{
  background:#fff;border:1px solid #e8ecf4;border-radius:16px;padding:22px 24px;
  display:flex;flex-direction:column;gap:12px;transition:.22px;
  box-shadow:0 1px 2px rgba(16,24,40,.04);
}
.project-card:hover{border-color:#c7d2fe;box-shadow:0 12px 28px rgba(59,108,246,.12)}
.project-head{display:flex;align-items:flex-start;gap:13px}
.project-icon{
  width:44px;height:44px;flex:0 0 44px;border-radius:13px;display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#eef2ff,#f5f3ff);color:#4f46e5;font-size:20px;
}
.project-head h3{font-size:16px;font-weight:800;margin:0 0 3px;color:#111827}
.project-subtitle{font-size:12px;color:#9ca3af;margin:0;font-weight:600}
.project-online{
  margin-left:auto;font-size:11px;font-weight:800;color:#047857;background:#ecfdf5;
  padding:3px 9px;border-radius:7px;white-space:nowrap;
}
.project-desc{margin:0;font-size:13.5px;color:#6b7280;line-height:1.78}
.project-highlights{margin:0;padding-left:18px;color:#4b5563;font-size:13px;line-height:1.9}
.project-highlights li::marker{color:#a5b4fc}
.project-tags{display:flex;flex-wrap:wrap;gap:6px}
.project-tag{
  font-size:11.5px;font-weight:700;color:#4f46e5;background:#f1f5ff;
  padding:3px 9px;border-radius:6px;
}
.project-link{
  margin-top:auto;align-self:flex-start;font-size:13px;font-weight:800;color:#3b6cf6;
  text-decoration:none;display:inline-flex;align-items:center;gap:5px;padding-top:6px;
}
.project-link:hover{color:#2c54c9}
.project-grid-wide{grid-template-columns:repeat(auto-fit,minmax(420px,1fr))}
.project-card-lg{padding:26px 28px}

/* ---------- 内容容器 ---------- */
.blog-container{max-width:1080px;margin:0 auto;padding:0 24px 46px;width:100%}

/* ---------- 页头 / 搜索 / 分页 ---------- */
.page-head{max-width:1080px;margin:0 auto;padding:46px 24px 24px;width:100%}
.page-head h1{font-size:28px;font-weight:800;margin:0 0 6px;color:#111827;letter-spacing:-.4px}
.page-head p{margin:0;color:#9ca3af;font-size:14px;font-weight:600}
.page-head-row{display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap}
.page-head .blog-search{max-width:520px;margin:0;padding:0;width:100%}

.blog-search{
  max-width:1080px;margin:0 auto;padding:0 24px;width:100%;
  display:flex;align-items:center;gap:10px;
}
.blog-search input[type=text]{
  flex:1;max-width:420px;padding:10px 15px;border:1px solid #e2e8f4;border-radius:11px;
  font-size:14px;outline:none;transition:.18s;background:#fff;
}
.blog-search input[type=text]:focus{border-color:#a5b4fc;box-shadow:0 0 0 3px rgba(99,102,241,.12)}
.blog-search button{
  padding:10px 18px;border:none;border-radius:11px;background:#3b6cf6;color:#fff;
  font-size:14px;font-weight:700;cursor:pointer;display:inline-flex;align-items:center;gap:6px;
}
.blog-search button:hover{background:#2c54c9}
.search-box{position:relative;display:flex;align-items:center;flex:1;min-width:0}
.search-box i{position:absolute;left:14px;font-size:14px;color:#9ca3af;pointer-events:none}
.search-box input[type=text]{width:100%;max-width:none;padding-left:38px}
.search-clear{font-size:16px;color:#c3c9d6;text-decoration:none;font-weight:700;line-height:1}
.search-clear:hover{color:#ef4444}
.active-filter{
  max-width:1080px;margin:14px auto 0;padding:0 24px;font-size:13px;color:#4b5563;width:100%;
}
.active-filter span{font-weight:800;color:#4f46e5}
.active-filter a{margin-left:8px;color:#9ca3af;text-decoration:none;font-weight:800}

.blog-pager{
  max-width:1080px;margin:8px auto 40px;padding:0 24px;width:100%;
  display:flex;align-items:center;justify-content:center;gap:18px;
}
.blog-pager a{
  font-size:13px;font-weight:700;color:#4b5563;text-decoration:none;
  padding:8px 16px;border:1px solid #e2e8f4;border-radius:10px;background:#fff;transition:.18s;
}
.blog-pager a:hover{border-color:#c7d2fe;color:#3b6cf6}
.pager-info{font-size:13px;color:#9ca3af;font-weight:700}

/* ---------- 空状态 ---------- */
.empty-state{text-align:center;padding:50px 20px;color:#9ca3af}
.empty-state i{font-size:34px;color:#d1d5db;display:block;margin-bottom:10px}
.empty-state p{margin:0 0 10px;font-size:14px;font-weight:600}
.empty-state a{font-size:13px;font-weight:800;color:#3b6cf6;text-decoration:none}

/* ---------- 文章详情 ---------- */
.post-shell{
  max-width:1080px;margin:0 auto;padding:38px 24px 64px;width:100%;
  display:grid;grid-template-columns:minmax(0,1fr) 296px;gap:26px;align-items:start;
}
.post-card{
  background:#fff;border:1px solid #e8ecf4;border-radius:20px;
  padding:42px 46px 36px;box-shadow:0 24px 60px -42px rgba(15,23,42,.28);min-width:0;
}
.post-hero{padding-bottom:26px;margin-bottom:30px;border-bottom:1px solid #eef2f7}
.post-kicker{display:flex;align-items:center;gap:10px;font-size:12px;color:#9ca3af;font-weight:700;margin-bottom:14px;flex-wrap:wrap}
.kicker-dot{width:3px;height:3px;border-radius:50%;background:#d1d5db}
.kicker-reads{display:inline-flex;align-items:center;gap:4px}
.post-title{font-size:36px;font-weight:800;line-height:1.28;margin:0 0 12px;color:#0f172a;letter-spacing:-.9px}
.post-byline{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.byline-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;flex:none}
.byline-avatar-text{
  display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#6366f1,#3b6cf6);color:#fff;font-size:16px;font-weight:800;
}
.byline-info{display:flex;flex-direction:column;line-height:1.35;margin-right:auto}
.byline-info strong{font-size:13.5px;color:#111827;font-weight:800}
.byline-info span{font-size:12px;color:#9aa3b2}
.post-tags{display:flex;flex-wrap:wrap;gap:7px}
.post-tag{
  font-size:11.5px;font-weight:700;color:#4f46e5;background:#f1f5ff;
  padding:3px 10px;border-radius:6px;text-decoration:none;
}
.post-tag:hover{background:#e0e9ff;color:#4338ca}
.post-body{font-size:16px;line-height:1.9}

/* ---------- 详情页侧栏 ---------- */
.post-side{position:sticky;top:84px;display:flex;flex-direction:column;gap:16px}
.side-card{
  background:#fff;border:1px solid #e8ecf4;border-radius:18px;padding:20px 20px 18px;
  box-shadow:0 18px 40px -36px rgba(15,23,42,.3);transition:.18s;
}
.side-card:hover{border-color:#dbe3f3}
.side-avatar{width:54px;height:54px;border-radius:16px;object-fit:cover;margin-bottom:12px}
.side-avatar-text{
  display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#6366f1,#3b6cf6);color:#fff;font-size:22px;font-weight:800;
}
.side-author h3{margin:0 0 4px;font-size:15px;font-weight:800;color:#111827}
.side-author p{margin:0 0 12px;font-size:12.5px;color:#9aa3b2;line-height:1.6}
.side-title{font-size:11.5px;font-weight:800;letter-spacing:.8px;color:#9aa3b2;margin:0 0 12px}
.side-posts{list-style:none;margin:0 0 12px;padding:0;display:flex;flex-direction:column;gap:2px}
.side-posts a{
  display:flex;align-items:baseline;gap:10px;padding:7px 0;text-decoration:none;
  color:#4b5563;font-size:13px;font-weight:600;line-height:1.5;
}
.side-posts a:hover{color:#3b6cf6}
.side-posts a span:first-child{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.side-date{font-size:11px;color:#b0b7c3;font-weight:700;flex:none}
.side-empty{margin:0 0 12px;font-size:12.5px;color:#b0b7c3}
.side-link{font-size:12.5px;font-weight:800;color:#3b6cf6;text-decoration:none;display:inline-flex;align-items:center;gap:5px}
.side-cta p{margin:0 0 10px;font-size:13px;color:#6b7280;font-weight:600}
.side-cta-btn{font-size:13px;padding:8px 14px}

/* ---------- Markdown 正文 ---------- */
.md-content{font-size:15.5px;line-height:1.85;color:#374151;word-wrap:break-word}
.md-content h1,.md-content h2,.md-content h3,.md-content h4{
  font-weight:800;color:#111827;line-height:1.4;margin:1.6em 0 .6em;letter-spacing:-.2px;
}
.md-content h1{font-size:26px}
.md-content h2{font-size:21px;padding-bottom:.35em;border-bottom:1px solid #eef2f7}
.md-content h3{font-size:18px}
.md-content h4{font-size:16px}
.md-content p{margin:0 0 1.05em}
.md-content a{color:#3b6cf6;text-decoration:none;border-bottom:1px solid rgba(59,108,246,.28)}
.md-content a:hover{border-bottom-color:#3b6cf6}
.md-content ul,.md-content ol{margin:0 0 1.05em;padding-left:1.5em}
.md-content li{margin:.28em 0}
.md-content li::marker{color:#a5b4fc}
.md-content blockquote{
  margin:1.2em 0;padding:12px 18px;border-left:3px solid #a5b4fc;
  background:#f6f8ff;border-radius:0 10px 10px 0;color:#4b5563;
}
.md-content blockquote p:last-child{margin-bottom:0}
.md-content code{
  background:#f1f3f9;color:#c2410c;padding:.15em .4em;border-radius:5px;
  font-size:.9em;font-family:ui-monospace,Consolas,monospace;
}
.md-content pre{
  background:#0f172a;color:#e2e8f0;padding:16px 18px;border-radius:12px;
  overflow:auto;font-size:13px;line-height:1.7;margin:1.2em 0;
}
.md-content pre code{background:none;color:inherit;padding:0;font-size:inherit}
.md-content img{max-width:100%;border-radius:10px;margin:1em 0}
.md-content hr{border:none;border-top:1px solid #e8ecf4;margin:2em 0}
.md-content table{width:100%;border-collapse:collapse;margin:1.2em 0;font-size:14px}
.md-content th,.md-content td{border:1px solid #e8ecf4;padding:8px 12px;text-align:left}
.md-content th{background:#f8fafc;font-weight:800;color:#111827}

/* ---------- 后台表格 ---------- */
.admin-table-wrap{
  max-width:1080px;margin:0 auto;padding:0 24px 50px;width:100%;
}
.admin-table{
  width:100%;border-collapse:separate;border-spacing:0;background:#fff;
  border:1px solid #e8ecf4;border-radius:14px;overflow:hidden;font-size:13.5px;
}
.admin-table th{
  background:#f8fafc;color:#6b7280;font-size:12px;font-weight:800;letter-spacing:.3px;
  text-align:left;padding:12px 16px;border-bottom:1px solid #e8ecf4;white-space:nowrap;
}
.admin-table td{padding:12px 16px;border-bottom:1px solid #f1f5f9;color:#4b5563;vertical-align:middle}
.admin-table tr:last-child td{border-bottom:none}
.admin-table tbody tr:hover{background:#fafbff}
.admin-title a{color:#111827;font-weight:700;text-decoration:none}
.admin-title a:hover{color:#3b6cf6}
.ta-r{text-align:right}
.status-pill{font-size:11px;font-weight:800;padding:3px 10px;border-radius:7px;white-space:nowrap}
.status-pub{background:#ecfdf5;color:#047857}
.status-draft{background:#fef3c7;color:#92400e}
.admin-actions{white-space:nowrap}
.btn-mini{
  display:inline-block;padding:5px 11px;border-radius:7px;border:1px solid #e2e8f4;
  background:#fff;color:#4b5563;font-size:12px;font-weight:700;text-decoration:none;
  cursor:pointer;transition:.18s;margin-left:6px;
}
.btn-mini:hover{border-color:#c7d2fe;color:#3b6cf6;background:#f8faff}
.btn-mini-danger:hover{border-color:#fecaca;color:#dc2626;background:#fef2f2}

/* ---------- 编辑器 ---------- */
.editor-form{max-width:1080px;margin:0 auto;padding:0 24px 50px;width:100%}
.editor-meta{display:flex;gap:14px;margin-bottom:14px;flex-wrap:wrap}
.editor-field{display:flex;flex-direction:column;gap:6px;min-width:150px}
.editor-field-grow{flex:1}
.editor-field label{font-size:12px;font-weight:800;color:#6b7280;letter-spacing:.3px}
.editor-field input,.editor-field select{
  padding:10px 14px;border:1px solid #e2e8f4;border-radius:10px;font-size:14px;
  outline:none;background:#fff;transition:.18s;color:#111827;
}
.editor-field input:focus,.editor-field select:focus{
  border-color:#a5b4fc;box-shadow:0 0 0 3px rgba(99,102,241,.12);
}
.editor-split{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:6px}
.editor-pane{
  background:#fff;border:1px solid #e8ecf4;border-radius:14px;overflow:hidden;
  display:flex;flex-direction:column;min-height:460px;
}
.editor-pane-head{
  display:flex;align-items:center;justify-content:space-between;gap:10px;
  padding:10px 16px;background:#f8fafc;border-bottom:1px solid #eef2f7;
  font-size:12px;font-weight:800;color:#6b7280;
}
.editor-hint{font-weight:600;color:#b0b7c3;font-size:11px}
#mdEditor{
  flex:1;border:none;outline:none;resize:vertical;padding:16px 18px;
  font-family:ui-monospace,Consolas,monospace;font-size:13.5px;line-height:1.8;
  color:#1f2937;background:#fff;min-height:400px;
}
.editor-preview{background:#fff}
.editor-preview .md-content{padding:16px 20px;overflow:auto;flex:1}
.editor-actions{
  display:flex;justify-content:flex-end;gap:10px;margin-top:18px;
}

/* ---------- 页脚 ---------- */
.blog-footer{margin-top:auto;background:#fff;border-top:1px solid #e8ecf4}
.blog-footer-inner{
  max-width:1080px;margin:0 auto;padding:22px 24px;display:flex;align-items:center;
  justify-content:center;gap:10px;font-size:12.5px;color:#9ca3af;font-weight:600;
}
.blog-footer-inner a{color:#9ca3af;text-decoration:none}
.blog-footer-inner a:hover{color:#3b6cf6}
.blog-footer-dot{color:#d1d5db}

/* ---------- 博主登录 ---------- */
.admin-login-wrap{
  max-width:1080px;margin:0 auto;padding:64px 24px 80px;width:100%;
  display:flex;justify-content:center;
}
.admin-login-card{
  width:100%;max-width:380px;background:#fff;border:1px solid #e8ecf4;border-radius:18px;
  padding:34px 30px 26px;box-shadow:0 12px 40px rgba(31,41,55,.08);
}
.admin-login-head{text-align:center;margin-bottom:24px}
.admin-login-head .blog-brand-mark{margin:0 auto 14px;width:44px;height:44px;font-size:19px;border-radius:14px}
.admin-login-head h1{font-size:21px;font-weight:800;margin:0 0 6px;color:#111827}
.admin-login-head p{margin:0;font-size:13px;color:#9aa3b2}
.admin-login-form{display:flex;flex-direction:column;gap:14px}
.admin-login-btn{width:100%;justify-content:center;border:none;cursor:pointer}
.admin-login-tip{
  margin:18px 0 0;font-size:12.5px;color:#9aa3b2;text-align:center;line-height:1.7;
}
.admin-login-tip a{color:#3b6cf6;text-decoration:none;font-weight:700}
.admin-login-tip a:hover{text-decoration:underline}

/* ---------- 首页头像 / 关于我入口 ---------- */
.hero-avatar-img{
  width:78px;height:78px;margin:0 auto 22px;border-radius:24px;object-fit:cover;display:block;
  box-shadow:0 10px 28px rgba(74,108,247,.28);border:3px solid #fff;
}
.hero-about-link{
  display:inline-flex;align-items:center;gap:6px;margin-top:18px;
  color:#6b7280;font-size:13px;font-weight:700;text-decoration:none;transition:.18s;
}
.hero-about-link:hover{color:#3b6cf6}

/* ---------- 后台操作区 ---------- */
.admin-head-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.admin-head-actions .btn-mini{display:inline-flex;align-items:center;gap:5px;text-decoration:none}

/* ---------- 关于页 ---------- */
.about-hero{text-align:center;padding:56px 0 34px}
.about-avatar{
  width:104px;height:104px;border-radius:30px;object-fit:cover;display:block;margin:0 auto 20px;
  box-shadow:0 12px 32px rgba(31,41,55,.14);border:4px solid #fff;background:#eef2ff;
}
.about-avatar-initial{
  display:flex;align-items:center;justify-content:center;font-size:40px;font-weight:800;color:#fff;
  background:linear-gradient(135deg,#4a6cf7,#8e5df0);border:none;
  box-shadow:0 12px 32px rgba(74,108,247,.3);
}
.about-hero h1{font-size:28px;font-weight:800;color:#111827;margin:0 0 8px}
.about-headline{color:#6b7280;font-size:15px;margin:0 0 16px}
.about-links{display:flex;justify-content:center;gap:10px;flex-wrap:wrap}
.about-links a{
  display:inline-flex;align-items:center;gap:6px;padding:7px 14px;border-radius:10px;
  background:#fff;border:1px solid #e8ecf4;color:#4b5563;font-size:13px;font-weight:700;
  text-decoration:none;transition:.18s;
}
.about-links a:hover{border-color:#c7d2fe;color:#3b6cf6;background:#f5f7ff}
.about-bio{background:#fff;border:1px solid #e8ecf4;border-radius:16px;padding:26px 30px;margin-bottom:34px}
.about-bio .empty-state{padding:20px 0}
.about-gallery{margin-bottom:50px}

/* ---------- 个人资料编辑 ---------- */
.profile-edit-top{display:flex;gap:26px;align-items:flex-start;margin-bottom:8px}
.profile-avatar-box{display:flex;flex-direction:column;align-items:center;gap:10px;flex-shrink:0}
.profile-avatar-box img,.profile-avatar-empty{
  width:92px;height:92px;border-radius:26px;object-fit:cover;display:flex;align-items:center;
  justify-content:center;background:linear-gradient(135deg,#4a6cf7,#8e5df0);color:#fff;
  font-size:34px;font-weight:800;border:3px solid #fff;box-shadow:0 8px 22px rgba(74,108,247,.24);
}
.profile-avatar-btn{cursor:pointer;display:inline-flex;align-items:center;gap:5px}
.profile-fields{flex:1;display:grid;grid-template-columns:1fr 1fr;gap:14px;min-width:0}
.profile-bio-input{
  width:100%;min-height:180px;padding:14px 16px;border:1px solid #e2e8f4;border-radius:12px;
  font-family:ui-monospace,Consolas,monospace;font-size:13.5px;line-height:1.8;resize:vertical;
  outline:none;background:#fff;color:#111827;
}
.profile-bio-input:focus{border-color:#a5b4fc;box-shadow:0 0 0 3px rgba(99,102,241,.12)}
.profile-photos{margin-top:40px}
.photo-upload{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-bottom:18px}
.photo-upload input[type=file]{
  padding:8px 12px;border:1px dashed #cbd5e1;border-radius:10px;background:#fff;font-size:13px;
}
.photo-upload input[type=text]{
  flex:1;min-width:180px;padding:9px 14px;border:1px solid #e2e8f4;border-radius:10px;
  font-size:13.5px;outline:none;background:#fff;
}
.photo-upload input[type=text]:focus{border-color:#a5b4fc}
.photo-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:14px}
.photo-item{
  display:block;background:#fff;border:1px solid #e8ecf4;border-radius:14px;overflow:hidden;
  text-decoration:none;color:#4b5563;
}
.photo-item img{width:100%;height:150px;object-fit:cover;display:block;background:#f3f4f6}
.photo-item > span{display:block;padding:8px 12px;font-size:12.5px;color:#6b7280}
.photo-item-foot{
  display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 10px;
}
.photo-item-foot span{font-size:12.5px;color:#6b7280;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.photo-empty{color:#9aa3b2;font-size:13.5px}

/* ---------- 项目状态 ---------- */
.status-pill.pill-open{background:#dcfce7;color:#15803d}
.status-pill.pill-maintain{background:#fef3c7;color:#b45309}
.status-pill.pill-closed{background:#e5e7eb;color:#6b7280}
.project-card-off{opacity:.92}
.project-link-disabled{
  display:inline-flex;align-items:center;gap:6px;margin-top:16px;padding:8px 16px;
  border-radius:10px;background:#f3f4f6;color:#9aa3b2;font-size:13.5px;font-weight:700;
  cursor:not-allowed;
}
.project-down-tip{
  display:flex;align-items:center;gap:8px;margin-bottom:18px;padding:12px 16px;
  border-radius:10px;background:#fef3c7;border:1px solid #fde68a;color:#92400e;
  font-size:13.5px;font-weight:600;
}
.status-form{display:inline-flex;align-items:center;gap:8px}
.status-form select{
  padding:6px 10px;border:1px solid #e2e8f4;border-radius:9px;background:#fff;
  font-size:13px;outline:none;
}
.project-row-sub{font-size:12px;color:#9aa3b2;font-weight:500;margin-top:2px}
.admin-note{
  margin-top:18px;font-size:13px;color:#6b7280;line-height:1.9;background:#fff;
  border:1px solid #e8ecf4;border-radius:12px;padding:14px 18px;
}

/* ---------- 点赞 / 评论 ---------- */
.post-actions{display:flex;align-items:center;gap:12px;margin:42px 0 0;padding-top:26px;border-top:1px solid #eef2f7}
.like-btn{
  display:inline-flex;align-items:center;gap:7px;padding:9px 18px;border-radius:999px;
  border:1px solid #e2e8f4;background:#fff;color:#4b5563;font-size:13.5px;font-weight:700;
  cursor:pointer;transition:.18s;
}
.like-btn:hover{border-color:#c7d2fe;color:#3b6cf6;background:#f7f9ff}
.like-btn.liked{border-color:#fecdd3;background:#fff1f2;color:#e11d48}
.like-btn i{font-size:15px}
.like-count{display:inline-block;font-variant-numeric:tabular-nums}
.like-count.like-pop{animation:likePop .36s ease}
@keyframes likePop{0%{transform:scale(1)}40%{transform:scale(1.4)}100%{transform:scale(1)}}
.comment-jump{
  display:inline-flex;align-items:center;gap:6px;color:#6b7280;font-size:13.5px;
  font-weight:700;text-decoration:none;padding:9px 14px;border-radius:999px;transition:.18s;
}
.comment-jump:hover{color:#3b6cf6;background:#f4f7ff}
.comments{margin:38px 0 0;padding-top:30px;border-top:1px solid #eef2f7}
.comments-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:18px}
.comments-head h2{display:flex;align-items:center;gap:8px;font-size:18px;font-weight:800;color:#0f172a;margin:0}
.count-badge{font-size:11.5px;font-weight:800;color:#3b6cf6;background:#eef3ff;padding:2px 8px;border-radius:999px}
.comments-tip{font-size:12px;color:#b0b7c3}
.comment-list{display:flex;flex-direction:column}
.comment-item{display:flex;gap:12px;padding:16px 0;border-bottom:1px solid #f4f6fb}
.comment-item:last-child{border-bottom:none}
.comment-avatar{
  width:34px;height:34px;border-radius:50%;flex:none;background:#eef2f7;color:#64748b;
  display:flex;align-items:center;justify-content:center;font-size:13px;font-weight:800;
}
.comment-main{flex:1;min-width:0}
.comment-head{display:flex;align-items:baseline;gap:10px;margin-bottom:4px}
.comment-head strong{font-size:13.5px;color:#374151}
.comment-head span{font-size:12px;color:#9aa3b2}
.comment-item p{margin:0;font-size:14px;color:#374151;line-height:1.75;white-space:pre-wrap;word-break:break-word}
.comment-empty-box{
  text-align:center;padding:34px 16px;background:#fafbff;border:1px dashed #e2e8f4;border-radius:16px;
}
.comment-empty-box i{font-size:28px;color:#c7d2fe;display:block;margin-bottom:8px}
.comment-empty-box p{margin:0 0 4px;font-size:14px;font-weight:700;color:#6b7280}
.comment-empty-box span{font-size:12.5px;color:#9aa3b2}
.composer{
  margin-top:20px;background:#f8fafc;border:1px solid #e8ecf4;border-radius:16px;
  padding:16px 18px;display:flex;flex-direction:column;gap:12px;
}
.composer-top{display:flex;align-items:center;gap:10px}
.composer-top input[type=text]{
  flex:1;max-width:260px;padding:8px 12px;border:1px solid #e2e8f4;border-radius:10px;
  background:#fff;font-size:13px;outline:none;transition:.18s;
}
.composer textarea{
  min-height:104px;padding:12px 14px;border:1px solid #e2e8f4;border-radius:12px;background:#fff;
  font-family:inherit;font-size:14px;line-height:1.7;resize:vertical;outline:none;transition:.18s;
}
.composer input:focus,.composer textarea:focus{border-color:#a5b4fc;box-shadow:0 0 0 3px rgba(99,102,241,.12)}
.composer-foot{display:flex;align-items:center;justify-content:space-between;gap:12px}
.composer-hint{font-size:12px;color:#a5adba}
.composer-foot button{border:none;cursor:pointer}
.comment-closed{color:#9aa3b2;font-size:13.5px;margin-top:16px}
.post-nav{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:38px;padding-top:26px;border-top:1px solid #eef2f7}
.post-nav-item{
  display:flex;flex-direction:column;gap:6px;padding:14px 18px;border:1px solid #e8ecf4;
  border-radius:14px;background:#fcfdff;text-decoration:none;transition:.18s;
}
.post-nav-item:hover{border-color:#c7d2fe;background:#f7f9ff}
.post-nav-label{display:inline-flex;align-items:center;gap:5px;font-size:11.5px;font-weight:800;color:#9aa3b2}
.post-nav-item strong{
  font-size:13.5px;font-weight:700;color:#374151;line-height:1.5;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
}
.post-nav-next{text-align:right;align-items:flex-end}

/* 复选框行 */
.editor-check .check-line{display:inline-flex;align-items:center;gap:7px;font-size:13.5px;color:#4b5563}
.editor-check .check-line input{width:15px;height:15px;accent-color:#3b6cf6}

/* ---------- 响应式 ---------- */
@media (max-width:820px){
  .post-grid,.project-grid{grid-template-columns:1fr}
  .editor-split{grid-template-columns:1fr}
  .editor-pane{min-height:300px}
  .blog-nav-inner{height:auto;padding:12px 18px;flex-wrap:wrap}
  .blog-links{width:100%;justify-content:flex-start;gap:2px}
  .blog-links a{padding:6px 9px;font-size:13px}
  .hero{padding:52px 20px 40px}
  .hero-name{font-size:28px}
  .page-head{padding:34px 20px 18px}
  .page-head-row{flex-direction:column;align-items:stretch;gap:14px}
  .page-head .blog-search{max-width:none}
  .blog-container{padding:0 20px 36px}
  .post-shell{grid-template-columns:1fr;padding:26px 20px 46px;gap:18px}
  .post-side{position:static}
  .post-card{padding:30px 22px 26px;border-radius:16px}
  .post-title{font-size:26px;letter-spacing:-.5px}
  .post-body{font-size:15.5px}
  .post-nav{grid-template-columns:1fr}
  .comments-tip{display:none}
  .composer-top input[type=text]{max-width:none}
  .admin-table th:nth-child(4),.admin-table td:nth-child(4){display:none}
  .profile-edit-top{flex-direction:column;align-items:stretch;gap:18px}
  .profile-avatar-box{flex-direction:row;justify-content:flex-start}
  .profile-fields{grid-template-columns:1fr}
  .about-hero{padding:40px 0 24px}
}


