/* ========================================
   Blog 页面专属样式
   ======================================== */

/* Google Font 引入（在 _includes/head.html 里加） */
/* <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap" rel="stylesheet"> */

/* ---------- 容器 ---------- */
.blog-container {
  max-width: 780px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ---------- 页面标题区 ---------- */
.blog-header {
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 2px solid #f0f0f0;
}

.blog-title {
  font-size: 2.4rem;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 8px;
  letter-spacing: -0.5px;
}

.blog-subtitle {
  color: #888;
  font-size: 1rem;
  margin: 0;
}

/* ---------- 标签筛选栏 ---------- */
.blog-tags-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}

.tag-btn {
  padding: 6px 16px;
  border: 1.5px solid #e0e0e0;
  border-radius: 999px;
  background: white;
  color: #555;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.tag-btn:hover {
  border-color: #4f46e5;
  color: #4f46e5;
}

.tag-btn.active {
  background: #4f46e5;
  border-color: #4f46e5;
  color: white;
}

/* ---------- 年份标签 ---------- */
.year-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #aaa;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin: 32px 0 16px;
  padding-left: 72px; /* 和卡片内容对齐 */
}

/* ---------- 文章卡片 ---------- */
.blog-card {
  margin-bottom: 16px;
  animation: fadeIn 0.4s ease;
}

.blog-card-inner {
  display: flex;
  gap: 20px;
  padding: 20px 24px;
  border-radius: 12px;
  border: 1.5px solid #f0f0f0;
  background: #fff;
  transition: all 0.25s ease;
  align-items: flex-start;
}

.blog-card-inner:hover {
  border-color: #4f46e5;
  box-shadow: 0 4px 20px rgba(79, 70, 229, 0.08);
  transform: translateY(-2px);
}

/* ---------- 日期区域 ---------- */
.blog-card-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 48px;
  padding-top: 2px;
}

.date-day {
  font-size: 1.5rem;
  font-weight: 700;
  color: #4f46e5;
  line-height: 1;
}

.date-mon {
  font-size: 0.75rem;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
}

/* ---------- 文章内容区 ---------- */
.blog-card-content {
  flex: 1;
}

.blog-card-title {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 0 0 8px;
  line-height: 1.4;
}

.blog-card-title a {
  color: #1a1a2e;
  text-decoration: none;
  transition: color 0.2s;
}

.blog-card-title a:hover {
  color: #4f46e5;
}

.blog-card-excerpt {
  font-size: 0.9rem;
  color: #666;
  margin: 0 0 12px;
  line-height: 1.6;
}

/* ---------- 元信息（标签 + 阅读时间） ---------- */
.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.blog-card-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.tag {
  padding: 2px 10px;
  background: #f0efff;
  color: #4f46e5;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
}

.read-time {
  font-size: 0.78rem;
  color: #bbb;
  margin-left: auto;
}

/* ---------- 动画 ---------- */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- 响应式 ---------- */
@media (max-width: 600px) {
  .blog-title { font-size: 1.8rem; }
  .blog-card-inner { padding: 16px; gap: 14px; }
  .date-day { font-size: 1.2rem; }
  .year-label { padding-left: 62px; }
}
