/* ========== 小物法 - 奶油风全局样式 ========== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #fdf6ec; /* 奶油底 */
  color: #4a3f35;
  min-height: 100vh;
}
a { color: #c4713b; text-decoration: none; }
a:hover { text-decoration: underline; }

/* 顶部导航 */
.nav {
  background: #fffdf8;
  border-bottom: 1px solid #f0e2cf;
  padding: 12px 20px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 10;
  box-shadow: 0 2px 8px rgba(196,113,59,.06);
}
.nav-brand { font-size: 22px; font-weight: 800; color: #b5651d; display: flex; align-items: center; gap: 8px; }
.nav-brand .atom { font-size: 26px; }
.nav-links { display: flex; align-items: center; gap: 14px; font-size: 15px; }
.nav-btn {
  background: #e8a87c; color: #fff; border: none; border-radius: 20px;
  padding: 7px 18px; font-size: 14px; cursor: pointer; transition: .2s;
}
.nav-btn:hover { background: #d98e5f; text-decoration: none; }
.nav-btn.ghost { background: transparent; color: #b5651d; border: 1px solid #e0c3a3; }
.nav-user { color: #8a7a68; font-size: 14px; }

/* 主容器 */
.container { max-width: 960px; margin: 0 auto; padding: 30px 16px 60px; }

/* 卡片 */
.card {
  background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px;
  padding: 24px; box-shadow: 0 4px 16px rgba(196,113,59,.05);
}

/* 欢迎区（品牌个性化） */
.hero { text-align: center; padding: 34px 16px 26px; }
.hero h1 { font-size: 42px; color: #b5651d; letter-spacing: 6px; }
.hero .sub { color: #8a7a68; margin-top: 10px; font-size: 16px; letter-spacing: 2px; }
.hero .atom-big { font-size: 56px; display: block; margin-bottom: 8px; }

/* 原子轨道动画 */
.atom-wrap { width: 100px; height: 100px; margin: 0 auto 6px; }
.atom-svg { width: 100%; height: 100%; }
.orbit { transform-origin: 60px 60px; }
.orbit-1 { animation: orbitSpin1 9s linear infinite; }
.orbit-2 { animation: orbitSpin2 13s linear infinite; }
.orbit-3 { animation: orbitSpin3 17s linear infinite; }
@keyframes orbitSpin1 { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes orbitSpin2 { from { transform: rotate(60deg); } to { transform: rotate(420deg); } }
@keyframes orbitSpin3 { from { transform: rotate(120deg); } to { transform: rotate(480deg); } }
/* 悬停互动：轨道加速 */
.atom-wrap:hover .orbit-1 { animation-duration: 2.2s; }
.atom-wrap:hover .orbit-2 { animation-duration: 3.2s; }
.atom-wrap:hover .orbit-3 { animation-duration: 4.2s; }
.atom-wrap:hover .electron { r: 6px; }

/* 品牌艺术字：三字错落 + 橙棕渐变 */
.brand-title {
  font-size: 62px; font-weight: 800; letter-spacing: 12px; line-height: 1.2;
  margin: 4px 0 0; text-shadow: 0 3px 14px rgba(196,113,59,.18);
}
.brand-title span { display: inline-block; }
.brand-title .t1 { color: #e8a87c; transform: translateY(-8px) scale(.82); }
.brand-title .t2 { color: #b5651d; transform: translateY(2px) scale(1.12); text-shadow: 0 4px 18px rgba(181,101,29,.30); }
.brand-title .t3 { color: #8a5a2b; transform: translateY(6px) scale(.88); }
/* 公式点缀 */
.formula {
  margin-top: 16px; font-size: 16px; color: #c0b2a2; letter-spacing: 2px;
  font-family: Georgia, 'Times New Roman', serif; font-style: italic;
}

/* 分类卡片 */
.cats { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 30px; }
.cat-card {
  background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px;
  padding: 26px 22px; text-align: center; transition: .25s;
}
.cat-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(196,113,59,.12); border-color: #e8a87c; }
.cat-card .icon { font-size: 40px; }
.cat-card h3 { margin: 12px 0 8px; color: #b5651d; }
.cat-card p { color: #8a7a68; font-size: 14px; line-height: 1.6; }
.cat-card .tag { display: inline-block; margin-top: 10px; font-size: 12px; color: #c4713b; background: #fdf1e2; padding: 3px 12px; border-radius: 12px; }

/* 表单 */
.form-card { max-width: 400px; margin: 40px auto; }
.form-card h2 { text-align: center; color: #b5651d; margin-bottom: 22px; }
.form-item { margin-bottom: 16px; }
.form-item label { display: block; font-size: 14px; color: #8a7a68; margin-bottom: 6px; }
.form-item input {
  width: 100%; padding: 11px 14px; border: 1px solid #e0c3a3; border-radius: 10px;
  font-size: 15px; background: #fffdf8; outline: none; transition: .2s;
}
.form-item input:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }
.btn-primary {
  width: 100%; background: #e8a87c; color: #fff; border: none; border-radius: 10px;
  padding: 12px; font-size: 16px; cursor: pointer; transition: .2s;
}
.btn-primary:hover { background: #d98e5f; }
.btn-primary:disabled { opacity: .6; cursor: not-allowed; }
.form-tip { text-align: center; margin-top: 14px; font-size: 14px; color: #8a7a68; }
.msg { text-align: center; margin-top: 14px; font-size: 14px; min-height: 20px; }
.msg.ok { color: #4a9d5f; }
.msg.err { color: #d9534f; }

/* 后台表格 */
.toolbar { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.filter-btn {
  background: #fff; border: 1px solid #e0c3a3; border-radius: 16px; padding: 6px 16px;
  font-size: 13px; color: #8a7a68; cursor: pointer; transition: .2s;
}
.filter-btn.active { background: #e8a87c; color: #fff; border-color: #e8a87c; }
table { width: 100%; border-collapse: collapse; background: #fffdf8; border-radius: 12px; overflow: hidden; }
th, td { padding: 12px 10px; text-align: left; border-bottom: 1px solid #f5e9d8; font-size: 14px; }
th { background: #fdf1e2; color: #b5651d; font-weight: 600; }
tr:last-child td { border-bottom: none; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 12px; }
.badge.pending { background: #fdf1e2; color: #c4713b; }
.badge.approved { background: #e7f5ea; color: #3d8a52; }
.badge.banned { background: #fdeaea; color: #c0392b; }
.btn-sm {
  border: none; border-radius: 8px; padding: 5px 12px; font-size: 13px; cursor: pointer; transition: .2s;
}
.btn-sm.green { background: #e7f5ea; color: #3d8a52; }
.btn-sm.green:hover { background: #cdeeda; }
.btn-sm.red { background: #fdeaea; color: #c0392b; }
.btn-sm.red:hover { background: #f8d3d3; }
.btn-sm.gray { background: #f0eae2; color: #8a7a68; }
.empty { text-align: center; color: #b5a898; padding: 40px 0; }

/* 页脚 */
.footer { text-align: center; color: #c0b2a2; font-size: 13px; padding: 30px 0 20px; }

/* 提示条 */
.tip-bar {
  background: #fdf1e2; border: 1px solid #f0dcc0; border-radius: 12px; padding: 14px 18px;
  font-size: 14px; color: #8a6a45; margin-bottom: 20px; line-height: 1.7;
}

/* ========== 分类 Tab ========== */
.cat-tabs { display: flex; gap: 10px; flex-wrap: wrap; margin: 8px 0 22px; }
.cat-tab {
  background: #fff; border: 1px solid #e0c3a3; border-radius: 20px; padding: 8px 20px;
  font-size: 14px; color: #8a7a68; cursor: pointer; transition: .2s; font-family: inherit;
}
.cat-tab:hover { border-color: #e8a87c; color: #b5651d; }
.cat-tab.active { background: #e8a87c; color: #fff; border-color: #e8a87c; }
.cat-tab.forum-link { background: #e8a87c; color: #fff; border-color: #e8a87c; font-weight: 600; }
.cat-tab.forum-link:hover { background: #d98e5f; color: #fff; }

/* ========== 动态速递四栏 ========== */
.feed-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 6px 0 26px; }
.feed-card { background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 14px; padding: 14px 16px 10px; box-shadow: 0 4px 16px rgba(196,113,59,.05); }
.feed-title { display: flex; align-items: center; justify-content: space-between; color: #b5651d; font-size: 15px; font-weight: 700; margin-bottom: 8px; text-decoration: none; }
.feed-title:hover { text-decoration: none; color: #d98e5f; }
.feed-more { font-size: 11px; color: #c4713b; font-weight: 400; }
.feed-item { display: block; padding: 7px 0; border-bottom: 1px dashed #f5e9d8; text-decoration: none; }
.feed-item:last-child { border-bottom: none; }
.feed-item:hover { text-decoration: none; }
.feed-item-title { display: block; font-size: 13px; color: #4a3f35; line-height: 1.4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-item:hover .feed-item-title { color: #c4713b; }
.feed-item-meta { display: block; font-size: 11px; color: #b5a898; margin-top: 2px; }
.feed-empty { font-size: 13px; color: #c0b2a2; padding: 14px 0; text-align: center; }

/* ========== 访问计数器 ========== */
.stats-bar { font-size: 13px; color: #b5a898; margin-bottom: 12px; }
.stats-bar b { color: #c4713b; }

/* ========== 文章列表 ========== */
.articles { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.article-card {
  display: block; background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px;
  overflow: hidden; text-decoration: none; transition: .25s; box-shadow: 0 4px 16px rgba(196,113,59,.05);
}
.article-card:hover { transform: translateY(-4px); box-shadow: 0 10px 28px rgba(196,113,59,.14); border-color: #e8a87c; text-decoration: none; }
.ac-cover { height: 150px; background-size: cover; background-position: center; background-color: #f5e9d8; }
.ac-cover-empty {
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #fdf1e2, #f5e9d8); color: #d9a05b; font-size: 40px;
}
.ac-body { padding: 14px 16px 16px; }
.ac-meta { display: flex; align-items: center; gap: 10px; font-size: 12px; color: #b5a898; margin-bottom: 8px; flex-wrap: wrap; }
.cat-badge {
  display: inline-block; background: #fdf1e2; color: #c4713b; font-size: 12px;
  padding: 2px 10px; border-radius: 12px;
}
.ac-tag { font-size: 12px; color: #c4713b; margin-left: 2px; }
.ac-title { font-size: 16px; color: #4a3f35; line-height: 1.5; margin-bottom: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ac-summary { font-size: 13px; color: #8a7a68; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ========== 窄容器（文章页/编辑器） ========== */
.container.narrow { max-width: 760px; }

/* ========== 文章详情页 ========== */
.back-link { display: inline-block; color: #c4713b; font-size: 14px; margin-bottom: 16px; }
.article-page { background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px; padding: 28px 26px 20px; box-shadow: 0 4px 16px rgba(196,113,59,.05); }
.article-title { font-size: 26px; color: #4a3f35; line-height: 1.4; margin-bottom: 12px; }
.article-meta { display: flex; align-items: center; gap: 12px; font-size: 13px; color: #b5a898; margin-bottom: 20px; flex-wrap: wrap; border-bottom: 1px solid #f5e9d8; padding-bottom: 16px; }
.article-cover { margin-bottom: 18px; }
.article-cover img { width: 100%; border-radius: 12px; }
.video-wrap { position: relative; width: 100%; padding-top: 56.25%; margin: 16px 0; border-radius: 12px; overflow: hidden; background: #1a1512; }
.video-wrap iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.article-content { font-size: 16px; color: #4a3f35; line-height: 1.9; word-break: break-word; }
.article-content p { margin: 0 0 14px; }
.article-content h2, .article-content h3 { color: #b5651d; margin: 22px 0 10px; line-height: 1.5; }
.article-content h2 { font-size: 21px; } .article-content h3 { font-size: 18px; }
.article-content img { max-width: 100%; border-radius: 10px; margin: 8px 0; }
.article-content blockquote {
  border-left: 4px solid #e8a87c; background: #fdf1e2; margin: 14px 0; padding: 10px 16px;
  color: #8a6a45; border-radius: 0 10px 10px 0;
}
.article-content strong { color: #b5651d; }
.article-content a { color: #c4713b; text-decoration: underline; }
.article-content ul, .article-content ol { margin: 0 0 14px; padding-left: 24px; }
.article-content li { margin-bottom: 6px; }
.article-content code {
  background: #f5efe3; color: #a04d1a; padding: 2px 7px; border-radius: 6px; font-size: 14px;
  font-family: Menlo, Consolas, monospace;
}
.article-tail { margin-top: 26px; border-top: 1px solid #f5e9d8; padding-top: 16px; }

/* ========== 文章内视频/附件区 ========== */
.media-block { margin-top: 24px; border-top: 1px solid #f5e9d8; padding-top: 18px; }
.media-title { color: #b5651d; font-size: 16px; margin-bottom: 12px; }
.clip-card { margin-bottom: 16px; }
.clip-name { font-size: 13px; color: #8a7a68; margin-bottom: 6px; }
.clip-card video { width: 100%; border-radius: 12px; background: #1a1512; display: block; }
/* 回复可见：锁定卡片/提示 */
.lock-card {
  background: #fdf1e2; border: 1px dashed #e0b78a; border-radius: 12px;
  padding: 16px; text-align: center;
}
.lock-card .clip-name { font-size: 14px; color: #8a5a2b; margin-bottom: 8px; }
.lock-body { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; }
.lock-tip { font-size: 13px; color: #b5651d; }
.lock-inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.att-item {
  display: flex; align-items: center; gap: 10px; background: #fdf6ec; border: 1px solid #f0e2cf;
  border-radius: 10px; padding: 10px 14px; margin-bottom: 8px;
}
.att-name { flex: 1; font-size: 14px; color: #4a3f35; word-break: break-all; }
.att-size { font-size: 12px; color: #b5a898; white-space: nowrap; }

/* ========== 评论区 ========== */
.comments-section {
  background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px;
  padding: 22px 24px 26px; margin-top: 20px; box-shadow: 0 4px 16px rgba(196,113,59,.05);
}
.comments-title { color: #b5651d; font-size: 18px; margin-bottom: 16px; }
.comment-item { padding: 14px 0; border-bottom: 1px solid #f5e9d8; }
.comment-item:last-child { border-bottom: none; }
.comment-main { display: flex; gap: 12px; }
.comment-avatar, .reply-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: #e8a87c; color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 600;
  flex-shrink: 0;
}
.comment-body { flex: 1; min-width: 0; }
.comment-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; flex-wrap: wrap; }
.comment-head b { color: #4a3f35; font-size: 14px; }
.comment-time, .reply-time { color: #b5a898; font-size: 12px; }
.comment-content { color: #4a3f35; font-size: 15px; line-height: 1.7; word-break: break-word; }
.reply-btn {
  border: none; background: transparent; color: #c4713b; font-size: 12px; cursor: pointer;
  padding: 4px 0 0; margin-top: 4px;
}
.reply-btn:hover { text-decoration: underline; }
.reply-input-wrap { display: flex; gap: 8px; margin-top: 10px; }
.reply-input { flex: 1; padding: 8px 12px; border: 1px solid #e0c3a3; border-radius: 10px; font-size: 14px; background: #fffdf8; outline: none; }
.reply-input:focus { border-color: #e8a87c; }
.reply-list { margin: 10px 0 0 48px; background: #fdf6ec; border-radius: 12px; padding: 10px 14px; }
.reply-item { display: flex; gap: 10px; padding: 8px 0; }
.reply-item + .reply-item { border-top: 1px dashed #f0e2cf; }
.reply-avatar { width: 28px; height: 28px; font-size: 13px; background: #d9a05b; }
.reply-body { flex: 1; min-width: 0; }
.reply-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 2px; flex-wrap: wrap; }
.reply-head b { color: #4a3f35; font-size: 13px; }
.reply-content { color: #4a3f35; font-size: 14px; line-height: 1.6; word-break: break-word; }
/* 贴吧楼层回复：楼层号 / 回复对象标记 */
.floor-tag { color: #c4713b; font-size: 12px; background: #fdf1e2; padding: 1px 8px; border-radius: 10px; }
.reply-to-tag { color: #c4713b; }
.comment-box { margin-top: 16px; padding-top: 16px; border-top: 1px solid #f5e9d8; }
.comment-login-tip {
  background: #fdf1e2; border-radius: 12px; padding: 14px 16px; font-size: 14px; color: #8a6a45;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.comment-input-row { display: flex; gap: 10px; align-items: center; }
.comment-input-row .input {
  flex: 1; padding: 11px 14px; border: 1px solid #e0c3a3; border-radius: 10px; font-size: 15px;
  background: #fffdf8; outline: none; transition: .2s;
}
.comment-input-row .input:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }
.comment-tip { font-size: 12px; color: #b5a898; margin-top: 8px; }
.input { font-family: inherit; }

/* ========== 编辑器 ========== */
.editor-card h2 { font-size: 20px; }
.editor-toolbar { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; flex-wrap: wrap; }
.ed-btn {
  width: 42px; height: 38px; border: 1px solid #e0c3a3; background: #fff; border-radius: 10px;
  font-size: 15px; color: #8a6a45; cursor: pointer; transition: .2s; font-family: inherit;
}
.ed-btn:hover { background: #fdf1e2; border-color: #e8a87c; }
.ed-sep { width: 1px; height: 22px; background: #f0e2cf; margin: 0 4px; }
#f-content {
  width: 100%; padding: 14px; border: 1px solid #e0c3a3; border-radius: 12px;
  font-size: 15px; line-height: 1.8; background: #fffdf8; outline: none; transition: .2s;
  font-family: inherit; resize: vertical; min-height: 220px;
}
#f-content:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }
.editor-hint { font-size: 12px; color: #b5a898; margin-top: 6px; }
.up-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.up-hint { font-size: 12px; color: #b5a898; }
.up-list { margin-top: 10px; display: flex; flex-direction: column; gap: 8px; }
.up-item {
  display: flex; align-items: center; gap: 10px; background: #fdf6ec; border: 1px solid #f0e2cf;
  border-radius: 10px; padding: 8px 12px;
}
.up-name { flex: 1; font-size: 14px; color: #4a3f35; word-break: break-all; }
.up-size { font-size: 12px; color: #b5a898; white-space: nowrap; }
.up-lock { display: flex; align-items: center; gap: 4px; font-size: 12px; color: #b5651d; cursor: pointer; white-space: nowrap; user-select: none; }
.up-lock input { width: 15px; height: 15px; accent-color: #b5651d; cursor: pointer; }
.cover-picker { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.cover-preview { width: 160px; height: 100px; border-radius: 12px; overflow: hidden; border: 1px solid #f0e2cf; background: #fdf1e2; }
.cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.cover-empty { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: #c0b2a2; font-size: 13px; }
.cover-ops { display: flex; flex-direction: column; gap: 8px; padding-top: 4px; }
.btn-row { display: flex; align-items: center; gap: 14px; margin-top: 20px; flex-wrap: wrap; }
.btn-primary.ghost-link { background: transparent; color: #b5651d; border: 1px solid #e0c3a3; text-align: center; width: auto; padding: 12px 24px; }

/* ========== 后台 Tab ========== */
.admin-tabs { display: flex; gap: 10px; margin-bottom: 18px; flex-wrap: wrap; }
.admin-tab {
  background: #fff; border: 1px solid #e0c3a3; border-radius: 20px; padding: 9px 22px;
  font-size: 14px; color: #8a7a68; cursor: pointer; transition: .2s; font-family: inherit;
  text-decoration: none;
}
.admin-tab:hover { border-color: #e8a87c; color: #b5651d; text-decoration: none; }
.admin-tab.active { background: #e8a87c; color: #fff; border-color: #e8a87c; }
.admin-tab-link { background: #fdf1e2; color: #c4713b; border-color: #f0dcc0; }
.article-admin-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; gap: 12px; flex-wrap: wrap; }
.table-wrap { overflow-x: auto; }
.comment-btn { background: #fdf1e2; color: #c4713b; }
.comment-btn:hover { background: #f8e3c8; }

/* 后台评论管理 */
.admin-comments { display: flex; flex-direction: column; gap: 14px; }
.admin-comment { background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 12px; padding: 14px 16px; }
.admin-comment-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; flex-wrap: wrap; }
.admin-comment-head b { color: #4a3f35; font-size: 14px; }
.admin-comment-head span { color: #b5a898; font-size: 12px; flex: 1; }
.admin-comment-content { color: #4a3f35; font-size: 14px; line-height: 1.7; word-break: break-word; }
.admin-replies { margin: 10px 0 0 20px; border-left: 3px solid #f0e2cf; padding-left: 14px; display: flex; flex-direction: column; gap: 10px; }
.admin-reply { background: #fdf6ec; border-radius: 10px; padding: 10px 14px; }

/* 手机端适配 */
@media (max-width: 560px) {
  .article-page { padding: 20px 16px 16px; }
  .article-title { font-size: 21px; }
  .articles { grid-template-columns: 1fr; }
  .nav { padding: 10px 14px; }
  .nav-brand { font-size: 19px; }
  .hero { padding: 24px 12px 20px; }
  .atom-wrap { width: 78px; height: 78px; }
  .brand-title { font-size: 44px; letter-spacing: 8px; }
  .formula { font-size: 13px; }
}
@media (max-width: 760px) {
  .feed-grid { grid-template-columns: 1fr 1fr; }
}

/* ========== 贴吧 ========== */
.forum-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; flex-wrap: wrap; }
.forum-head h2 { color: #b5651d; font-size: 22px; }
.forum-sub { color: #8a7a68; font-size: 13px; margin-bottom: 14px; }
.tab-count { font-size: 12px; opacity: .8; }
.post-list { display: flex; flex-direction: column; gap: 12px; }
.post-card {
  display: block; background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 14px;
  padding: 14px 16px; text-decoration: none; transition: .25s; box-shadow: 0 4px 16px rgba(196,113,59,.05);
}
.post-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(196,113,59,.12); border-color: #e8a87c; text-decoration: none; }
.post-title { font-size: 16px; color: #4a3f35; font-weight: 600; line-height: 1.5; word-break: break-word; }
.post-badge {
  display: inline-block; font-size: 11px; font-weight: 400; padding: 1px 8px;
  border-radius: 10px; margin-right: 6px; vertical-align: 2px;
}
.post-badge.pin { background: #fdf1e2; color: #c4713b; }
.post-badge.lock { background: #fdeaea; color: #c0392b; }
.post-badge.media { background: #e7f5ea; color: #3d8a52; }
.post-meta { display: flex; align-items: center; gap: 10px; font-size: 12px; color: #b5a898; margin-top: 8px; flex-wrap: wrap; }
.post-forum { color: #c4713b; }
.new-post-form {
  background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 14px;
  padding: 18px; margin-bottom: 20px; box-shadow: 0 4px 16px rgba(196,113,59,.05);
}
.np-select { width: 100%; padding: 11px 14px; border: 1px solid #e0c3a3; border-radius: 10px; font-size: 15px; background: #fffdf8; outline: none; }
.np-select:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }
.np-textarea {
  width: 100%; padding: 12px 14px; border: 1px solid #e0c3a3; border-radius: 10px;
  font-size: 15px; line-height: 1.7; background: #fffdf8; outline: none; transition: .2s;
  font-family: inherit; resize: vertical; min-height: 120px;
}
.np-textarea:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }

/* ========== 帖子详情页 ========== */
.post-page { background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 16px; padding: 28px 26px 20px; box-shadow: 0 4px 16px rgba(196,113,59,.05); }
.post-main .post-title { font-size: 24px; color: #4a3f35; line-height: 1.4; margin-bottom: 12px; word-break: break-word; }
.post-content {
  font-size: 16px; color: #4a3f35; line-height: 1.9; word-break: break-word;
  white-space: pre-wrap; margin-top: 18px; padding-top: 18px; border-top: 1px solid #f5e9d8;
}
.admin-bar { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; border-top: 1px dashed #f0e2cf; padding-top: 16px; }
.lock-banner {
  background: #fdeaea; border: 1px solid #f5c6c6; border-radius: 12px;
  padding: 12px 16px; font-size: 14px; color: #c0392b; margin-top: 16px; text-align: center;
}
.reply-del { flex-shrink: 0; align-self: center; }

/* ========== 贴吧媒体（发帖上传 + 详情渲染） ========== */
.media-hint { font-size: 12px; color: #b5a898; }
.media-err { font-size: 13px; color: #c0392b; }
.media-pick { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.media-preview { margin-top: 10px; }
.media-img-wrap { display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap; }
.media-img-wrap img { max-width: 240px; max-height: 180px; border-radius: 10px; border: 1px solid #f0e2cf; }
.media-file { display: flex; align-items: center; gap: 10px; background: #fdf6ec; border: 1px solid #f0e2cf; border-radius: 10px; padding: 10px 14px; flex-wrap: wrap; }
.post-media { margin-top: 16px; }
.post-media img { max-width: 100%; border-radius: 12px; border: 1px solid #f0e2cf; }
.post-media video { width: 100%; border-radius: 12px; background: #1a1512; display: block; }
.post-media.file { display: flex; align-items: center; gap: 12px; background: #fdf6ec; border: 1px solid #f0e2cf; border-radius: 12px; padding: 12px 16px; flex-wrap: wrap; }
.post-media-name { flex: 1; font-size: 14px; color: #4a3f35; word-break: break-all; }

/* ========== 友情链接（后台表单 + 前台展示区） ========== */
.link-form { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; align-items: center; }
.link-input {
  flex: 1; min-width: 180px; padding: 10px 14px; font-size: 14px; color: #4a3f35;
  background: #fffdf8; border: 1px solid #e8d9c3; border-radius: 10px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.link-input:focus { border-color: #e8a87c; box-shadow: 0 0 0 3px rgba(232,168,124,.15); }
.links-bar {
  background: #fffdf8; border: 1px solid #f0e2cf; border-radius: 14px;
  padding: 18px 22px; margin-top: 26px;
}
.links-bar-title { font-size: 15px; color: #b5651d; font-weight: 600; margin-bottom: 12px; }
.links-list { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.links-list a {
  color: #8a5a2b; text-decoration: none; font-size: 14px; padding: 6px 12px;
  border-radius: 20px; background: #fdf6ec; border: 1px solid #f0e2cf;
  transition: all .2s; display: inline-flex; align-items: center; gap: 6px;
}
.links-list a:hover { background: #f7ead6; border-color: #e8a87c; color: #b5651d; transform: translateY(-1px); }
.links-list .link-desc { color: #b5a898; font-size: 12px; }
/* 链接分组 */
.links-list { display: block; }
.link-group { margin-bottom: 10px; }
.link-group:last-child { margin-bottom: 0; }
.link-group-name {
  font-size: 13px; color: #a0836a; font-weight: 600;
  margin: 0 0 6px; padding-left: 2px; letter-spacing: .5px;
}
.link-group a { margin: 0 8px 8px 0; }
@media (max-width: 560px) {
  .link-form { flex-direction: column; align-items: stretch; }
  .link-input { min-width: 0; }
  .links-bar { padding: 14px 16px; }
  .links-list { gap: 6px 10px; }
}
