/* ─── BLOG LISTING ─── */
.blog-listing {
  max-width: 820px; margin: 0 auto;
  padding: 140px 24px 60px;
}

.blog-header {
  margin-bottom: 48px;
}

.blog-header h1 {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700; letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.blog-header p {
  font-size: 17px; color: var(--text-secondary);
  max-width: 520px;
}

.blog-grid {
  display: flex; flex-direction: column; gap: 20px;
}

.blog-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-decoration: none; color: inherit;
  transition: all 0.3s var(--ease);
  box-shadow: var(--shadow-sm);
  display: block;
}

.blog-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.blog-card-meta {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 14px;
}

.blog-card-meta time {
  font-size: 13px; color: var(--text-muted); font-weight: 500;
}

.blog-tag {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px; border-radius: 100px;
  background: var(--accent-soft); color: var(--accent);
}

.blog-card h2 {
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.02em; line-height: 1.3;
  margin-bottom: 10px;
}

.blog-card p {
  font-size: 15px; color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 16px;
}

.read-more {
  font-size: 14px; font-weight: 600; color: var(--accent);
}

/* ─── ARTICLE ─── */
.blog-article {
  max-width: 720px; margin: 0 auto;
  padding: 120px 24px 60px;
}

.article-header {
  margin-bottom: 48px;
}

.article-meta {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 24px;
  font-size: 14px; color: var(--text-muted);
}

.back-link {
  font-size: 14px; font-weight: 600; color: var(--accent);
  text-decoration: none; transition: opacity 0.2s;
}
.back-link:hover { opacity: 0.8; }

.reading-time {
  padding-left: 16px;
  border-left: 1px solid var(--border);
}

.article-header h1 {
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 700; line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.article-subtitle {
  font-size: 18px; color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 20px;
}

.author-row {
  display: flex; align-items: center; gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.author-info strong {
  display: block; font-size: 15px;
}

.author-info a {
  font-size: 14px; color: var(--accent);
  text-decoration: none;
}
.author-info a:hover { text-decoration: underline; }

/* ─── ARTICLE BODY ─── */
.article-body h2 {
  font-size: 26px; font-weight: 700;
  letter-spacing: -0.02em;
  margin-top: 48px; margin-bottom: 16px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

.article-body h2:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.article-body p {
  font-size: 17px; line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.article-body strong {
  color: var(--text);
}

.article-body a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.article-body a:hover { opacity: 0.8; }

.article-body ul {
  margin: 16px 0 24px 20px;
}

.article-body ul li {
  font-size: 16px; line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.article-body .code-block {
  background: var(--bg-code);
  border-radius: var(--radius);
  padding: 28px 24px;
  overflow-x: auto;
  box-shadow: var(--shadow-md);
  margin: 24px 0;
  position: relative;
}

.article-body .code-block::before {
  content: '';
  position: absolute; top: 14px; left: 18px;
  width: 8px; height: 8px; border-radius: 50%;
  background: #ff5f57;
  box-shadow: 16px 0 0 #ffbd2e, 32px 0 0 #27c93f;
}

.article-body .code-block pre {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 13px; line-height: 1.8; color: #c9c9d0;
  margin-top: 12px;
  white-space: pre;
}

/* ─── ARTICLE CTA ─── */
.article-cta {
  margin-top: 56px;
  padding: 40px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  text-align: center;
  box-shadow: var(--shadow-md);
}

.article-cta p {
  font-size: 17px; color: var(--text-secondary);
  margin-bottom: 24px;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 640px) {
  .blog-listing { padding: 100px 16px 40px; }
  .blog-header h1 { font-size: 32px; }
  .blog-card { padding: 24px 20px; }
  .blog-card h2 { font-size: 19px; }

  .blog-article { padding: 100px 16px 40px; }
  .article-header h1 { font-size: 26px; }
  .article-subtitle { font-size: 16px; }
  .article-meta { flex-wrap: wrap; gap: 10px; }
  .reading-time { border-left: none; padding-left: 0; }

  .article-body h2 { font-size: 22px; margin-top: 36px; padding-top: 24px; }
  .article-body p { font-size: 16px; }
  .article-body .code-block { padding: 20px 16px; }
  .article-body .code-block pre { font-size: 11px; }

  .article-cta { padding: 28px 20px; }
  .article-cta .btn-hero { width: 100%; justify-content: center; }
}
