/* =========================
   Global Reset & Base
========================= */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: #eee;                 /* 页面外背景：浅灰 */
  font-family: -apple-system, BlinkMacSystemFont,
               "Segoe UI", Roboto, Helvetica, Arial,
               "PingFang SC", "Noto Sans CJK SC",
               "Microsoft YaHei", sans-serif;
  color: #111;
  line-height: 1.7;
  font-size: 120%; 
}

/* =========================
   Top Blog Header (Avatar)
========================= */
.blog-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  background: #FAF3DD;
  margin-bottom: 40px;
}

.avatar {
  width: 48px;
  height: 48px;
}

.avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.blog-name h2 {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 600;
}

/* =========================
   Main Content Container
========================= */
.container {
  background: #FAF3DD;                 /* 内容背景：白色 */
  margin: 24px auto;
  padding: 24px 20px 40px;
  
}

/* =========================
   Responsive Width Rules
========================= */

/* 小尺寸设备：全宽 */
.container {
  width: 100%;
}

/* ≥ 8 寸设备（平板 / 小笔记本） */
@media (min-width: 768px) {
  .container {
    width: 70%;
   
  }
}

/* ≥ 11 寸设备（标准笔记本及以上） */
@media (min-width: 1024px) {
  .container {
    width: 50%;
  }
}

/* =========================
   Article Header
========================= */
.container > header {
  text-align: center;
  margin-bottom: 32px;
}

.cover-image {
  width: 100%;
  height: auto;
  
  margin-bottom: 20px;
}

.container > header h1 {
  font-size: 1.8rem;
  margin: 0;
  font-weight: 700;
}

/* =========================
   Article Content
========================= */
main section {
  margin-bottom: 48px;
}

main h2 {
  font-size: 1.3rem;
  margin-bottom: 12px;
  font-weight: 600;
}

main p {
  margin: 0 0 16px;
}

/* =========================
   Images in Article
========================= */
.photo {
  width: 100%;
  height: auto;
  
  margin-top: 16px;
}

.caption {
  margin-top: 8px;
  font-size: 0.9rem;
  color: #666;
  line-height: 1.5;
}

.caption .credit {
  
  margin-top: 4px;
  
  color: #999;
}

/* =========================
   Footer
========================= */
footer {
  margin-top: 40px;
  text-align: center;
  font-size: 1.2rem;
  color: #666;
}

/* =========================
   Home (Post List)
========================= */
.home-header {
  margin: 0 0 18px;
}

.home-header h1 {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 700;
  text-align: left;
}

/* 列表整体 */
.post-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* 每条文章 */
.post-item {
  
  background: #fff;
}

/* 整条可点击 */
.post-link {
  display: flex;
  gap: 14px;
  padding: 14px;
  text-decoration: none;
  color: inherit;
  align-items: center;
}

/* 缩略图：手机上偏小，避免占太多 */
.post-thumb {
  width: 92px;
  height: 72px;
  object-fit: cover;
  flex-shrink: 0;
  background: #f3f3f3;
}

/* 文字区 */
.post-meta {
  min-width: 0;
}

.post-date {
  font-size: 0.85rem;
  color: #888;
  margin-bottom: 4px;
}

.post-title {
  font-size: 1.15rem;
  margin: 0 0 6px;
  font-weight: 700;
}

.post-desc {
  margin: 0;
  color: #444;
  font-size: 0.95rem;
}

/* 轻交互（克制） */
.post-link:hover {
  background: rgba(0,0,0,0.02);
}

/* 小屏：缩略图在上，文字在下（更像手机卡片列表） */
@media (max-width: 420px) {
  .post-link {
    flex-direction: column;
    align-items: stretch;
  }

  .post-thumb {
    width: 100%;
    height: 160px;
  }
}

/* 平板：缩略图稍大 */
@media (min-width: 768px) {
  .post-thumb {
    width: 140px;
    height: 104px;
  }
}

/* 桌面：缩略图再稍大一点 */
@media (min-width: 1024px) {
  .post-thumb {
    width: 160px;
    height: 116px;
  }
}
