.post-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 100px 24px 120px;
}

/* Back link */
.post-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
  margin-bottom: 40px;
  transition: color 0.15s;
}
.post-back:hover { color: var(--blue); }

/* Header */
.post-cats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.post-cat {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--blue);
  background: var(--blue-dim);
  padding: 3px 10px;
  border-radius: 4px;
}
.post-title {
  font-family: var(--font-head);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  margin-bottom: 20px;
}
.post-meta {
  display: flex;
  gap: 16px;
  align-items: center;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

/* Prose */
.post-body { color: var(--text); font-family: var(--font-body); font-size: 17px; line-height: 1.8; }
.post-body h2 { font-family: var(--font-head); font-size: 28px; font-weight: 700; margin: 2em 0 0.6em; color: var(--text); }
.post-body h3 { font-family: var(--font-head); font-size: 22px; font-weight: 600; margin: 1.8em 0 0.5em; color: var(--text); }
.post-body h4 { font-family: var(--font-head); font-size: 18px; font-weight: 600; margin: 1.5em 0 0.4em; color: var(--text); }
.post-body p { margin: 0 0 1.4em; }
.post-body a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.post-body a:hover { opacity: 0.8; }
.post-body strong { font-weight: 600; color: var(--text); }
.post-body em { font-style: italic; }
.post-body code { font-family: var(--mono); font-size: 0.88em; background: rgba(0,171,233,0.1); color: var(--blue); padding: 2px 6px; border-radius: 4px; }
.post-body blockquote {
  border-left: 3px solid var(--blue);
  margin: 1.6em 0;
  padding: 12px 0 12px 24px;
  color: var(--muted);
  font-style: italic;
}
.post-body ul, .post-body ol {
  padding-left: 1.5em;
  margin-bottom: 1.4em;
}
.post-body li { margin-bottom: 0.4em; }
.post-body img {
  max-width: 100%;
  width: auto;
  height: auto;
  border-radius: var(--radius-lg);
  margin: 1.6em auto;
  display: block;
}
.post-body figure { margin: 2em 0; }
.post-body figcaption { font-size: 13px; color: var(--muted); text-align: center; margin-top: 8px; }
.post-body pre {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  overflow-x: auto;
  margin: 1.6em 0;
}
.post-body pre code {
  background: none;
  color: var(--text);
  padding: 0;
  font-size: 14px;
}

/* States (used by post.html dynamic fallback) */
.post-loading, .post-error, .post-not-found {
  text-align: center;
  padding: 80px 0;
  color: var(--muted);
  font-size: 16px;
}
.post-loading::after {
  content: '';
  display: block;
  width: 32px;
  height: 32px;
  border: 2px solid var(--border);
  border-top-color: var(--blue);
  border-radius: 50%;
  margin: 20px auto 0;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
