/* ==========================================================================
   博客：原创 / 转载 / 评论
   ========================================================================== */

.blog-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 24px;
}

.blog-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.blog-list > .state {
  grid-column: 1 / -1;
}

.blog-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out), border-color 0.3s;
}

.blog-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--accent) 18%, var(--line));
  box-shadow: var(--shadow-md);
}

.blog-cover {
  display: block;
  aspect-ratio: 16 / 8.4;
  overflow: hidden;
  background: var(--surface-2);
}

.blog-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-out);
}

.blog-card:hover .blog-cover img {
  transform: scale(1.025);
}

.blog-cover-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: rgba(255, 255, 255, 0.85);
  font-family: var(--font-serif);
  font-size: 42px;
  letter-spacing: -0.05em;
}

.blog-card-body {
  padding: 22px;
}

.blog-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--faint);
  font-size: 10.5px;
  font-variant-numeric: tabular-nums;
}

.blog-card h2 {
  margin-top: 10px;
  font-size: clamp(20px, 2.3vw, 27px);
  line-height: 1.22;
  letter-spacing: -0.035em;
}

.blog-card h2 a {
  color: var(--text);
}

.blog-excerpt {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-source {
  margin-top: 8px;
  color: var(--faint);
  font-size: 10.5px;
}

.blog-read {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 18px;
  color: var(--accent-text);
  font-size: 12px;
  font-weight: 550;
}

.article-page .wrap {
  max-width: 880px;
}

.article-back {
  display: inline-flex;
  color: var(--faint);
  font-size: 12px;
  margin-bottom: 26px;
}

.article-head h1 {
  margin-top: 14px;
  font-size: clamp(34px, 5.3vw, 62px);
  line-height: 1.06;
  letter-spacing: -0.055em;
}

.article-lead {
  max-width: 680px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.article-source {
  margin-top: 12px;
  color: var(--faint);
  font-size: 12px;
}

.article-cover {
  display: block;
  width: 100%;
  margin-top: 30px;
  padding: 0;
  border: 0;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: var(--surface-2);
  cursor: zoom-in;
}

.article-cover img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: cover;
}

.article-cover-fallback {
  min-height: 280px;
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.86);
  font-family: var(--font-serif);
  font-size: 62px;
  background: linear-gradient(145deg, var(--accent), var(--violet));
}

.article-body {
  margin-top: 38px;
  font-size: 16px;
  line-height: 1.9;
}

.article-body h2 {
  margin-top: 2.2em;
  font-size: clamp(24px, 3vw, 32px);
  letter-spacing: -0.035em;
}

.article-body h3 {
  margin-top: 1.8em;
  font-size: 21px;
}

.article-body p {
  margin: 1em 0;
}

.article-body blockquote {
  margin: 1.4em 0;
  padding: 2px 0 2px 20px;
  border-left: 2px solid var(--accent);
  color: var(--muted);
}

.article-body pre {
  margin: 1.3em 0;
}

.article-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 52px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

@media (max-width: 760px) {
  .blog-list {
    grid-template-columns: 1fr;
  }

  .blog-card-body {
    padding: 18px;
  }

  .article-head h1 {
    font-size: 34px;
  }

  .article-body {
    margin-top: 28px;
    font-size: 15px;
  }

  .article-foot {
    flex-direction: column;
  }

  .article-foot .btn {
    width: 100%;
  }
}
