/* 全局变量统一规范 */
:root {
  --bg-page: #f7f3f0;
  --bg-card: #ffffff;
  --text-title: #2c2c2c;
  --text-body: #555555;
  --text-light: #999;
  --primary: #8c6d62;
  --primary-light: #b8a39b;
  --border: #e8e2dd;
  --shadow-soft: 0 4px 24px rgba(140, 109, 98, 0.08);
  --shadow-float: 0 10px 30px rgba(140, 109, 98, 0.12);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --transition: all 0.28s ease;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  background-color: var(--bg-page);
  font-family: "Noto Serif SC", "Microsoft YaHei", serif;
  color: var(--text-body);
  line-height: 1.82;
  font-size: 15px;
}
a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}
img {
  max-width: 100%;
  display: block;
  border-radius: var(--radius-md);
}
input, textarea, button, select {
  font-family: inherit;
}

/* 顶部毛玻璃导航 */
.header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(10px);
  background: rgba(255,255,255,0.75);
  border-bottom: 1px solid var(--border);
  padding: 22px 7%;
  z-index: 99;
}
.header-inner {
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.header h1 {
  font-size: 26px;
  font-weight: 500;
  color: var(--text-title);
  letter-spacing: 2px;
}
.nav {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}
.nav a {
  font-size: 15px;
  padding: 6px 0;
  position: relative;
  color: var(--text-body);
}
.nav a::after {
  content: "";
  width: 0;
  height: 2px;
  background: var(--primary);
  position: absolute;
  left: 0;
  bottom: 0;
  transition: var(--transition);
}
.nav a:hover {
  color: var(--primary);
}
.nav a:hover::after {
  width: 100%;
}

/* 主体容器 */
.container {
  max-width: 1300px;
  margin: 48px auto;
  width: 86%;
  display: grid;
  grid-template-columns: 72% 26%;
  gap: 2%;
}
@media (max-width: 768px) {
  .container {
    grid-template-columns: 100%;
  }
}

/* 文章卡片 */
.post-item {
  background: var(--bg-card);
  padding: 32px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  margin-bottom: 28px;
  transition: var(--transition);
  border: 1px solid transparent;
}
.post-item:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-float);
  border-color: var(--border);
}
.cover-img {
  width: 100%;
  height: 230px;
  object-fit: cover;
  margin-bottom: 20px;
}
.post-title {
  font-size: 24px;
  color: var(--text-title);
  font-weight: 500;
  margin-bottom: 12px;
}
.post-title a:hover {
  color: var(--primary);
}
.post-meta {
  display: flex;
  gap: 20px;
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 16px;
}
.post-desc {
  font-size: 15px;
  color: var(--text-body);
  margin-bottom: 20px;
}
.read-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 20px;
  background: var(--primary);
  color: #fff !important;
  border-radius: var(--radius-sm);
  font-size: 14px;
}
.read-more:hover {
  background: var(--primary-light);
}

/* 侧边栏 */
.side-box {
  background: var(--bg-card);
  padding: 26px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  margin-bottom: 24px;
}
.side-box h3 {
  font-size: 18px;
  color: var(--text-title);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 18px;
  font-weight: 500;
}
.tag-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.tag-group .tag {
  padding: 5px 14px;
  background: var(--bg-page);
  border-radius: 99px;
  font-size: 13px;
  color: var(--text-body);
}
.tag-group .tag:hover {
  background: var(--primary);
  color: white;
}

/* 分页 */
.page {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 40px;
}
.page a, .page span {
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-size: 14px;
}
.page span {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
.page a:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* 文章详情页 */
.article-page {
  background: var(--bg-card);
  padding: 42px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}
.article-title {
  font-size: 32px;
  color: var(--text-title);
  line-height: 1.4;
  margin-bottom: 16px;
  font-weight: 500;
}
.article-cover {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  margin: 24px 0;
}
.article-content {
  font-size: 16px;
  margin: 36px 0;
}
.article-content p {
  margin-bottom: 18px;
}

/* 评论区 */
.comment-form {
  margin: 46px 0 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.comment-form input, .comment-form textarea {
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fcfafa;
  font-size: 15px;
}
.comment-form input:focus, .comment-form textarea:focus {
  outline: none;
  border-color: var(--primary);
}
.comment-form button {
  width: fit-content;
  padding: 12px 28px;
  border: none;
  background: var(--primary);
  color: white;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 15px;
  transition: var(--transition);
}
.comment-form button:hover {
  background: var(--primary-light);
}
.comment-item {
  padding: 18px 0;
  border-bottom: 1px dashed var(--border);
}
.cm-nick {
  font-size: 16px;
  color: var(--text-title);
  font-weight: 500;
}
.cm-time {
  font-size: 12px;
  color: var(--text-light);
  margin-bottom: 8px;
}

/* 页脚 */
.footer {
  text-align: center;
  padding: 50px 0 30px;
  color: var(--text-light);
  font-size: 14px;
}
.empty {
  text-align: center;
  padding: 70px 0;
  color: var(--text-light);
  font-size: 16px;
}
.archive-list li {
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 16px;
}