/* ===== 블로그 (네이버 블로그 스타일 레이아웃) ===== */

.blog-layout {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 110px 24px 80px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 36px;
  align-items: start;
}

/* ---- 사이드바 ---- */
.blog-sidebar { position: sticky; top: 90px; display: flex; flex-direction: column; gap: 20px; }

.profile-card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 28px 22px; text-align: center;
}
.profile-avatar {
  width: 76px; height: 76px; margin: 0 auto 14px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-dark), var(--bg-soft));
  border: 2px solid var(--accent);
  display: flex; align-items: center; justify-content: center; font-size: 2rem;
}
.profile-card h2 { font-size: 1.15rem; font-weight: 900; margin-bottom: 6px; }
.profile-desc { font-size: 0.82rem; color: var(--text-dim); margin-bottom: 16px; }
.profile-stats {
  display: flex; justify-content: center; gap: 18px;
  border-top: 1px solid var(--line); padding-top: 14px;
  font-size: 0.75rem; color: var(--text-dim);
}
.profile-stats strong { color: var(--accent); font-family: var(--font-en); }

.category-box {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 22px;
}
.category-box h3 {
  font-size: 0.8rem; letter-spacing: 0.15em; color: var(--text-dim);
  font-family: var(--font-en); margin-bottom: 12px;
}
.category-list { list-style: none; }
.category-list li { border-bottom: 1px solid var(--line); }
.category-list li:last-child { border-bottom: 0; }
.category-list a {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 4px; font-size: 0.88rem; color: var(--text-dim);
  transition: color .2s, padding-left .2s;
}
.category-list a:hover, .category-list a.cat-active { color: var(--accent); padding-left: 10px; }
.category-list em { font-style: normal; font-size: 0.75rem; font-family: var(--font-en); }

.sidebar-note {
  background: rgba(74,222,128,.06); border: 1px dashed var(--accent-dark);
  border-radius: var(--radius); padding: 16px 18px;
  font-size: 0.78rem; color: var(--text-dim); line-height: 1.6;
}
.sidebar-note code {
  background: var(--panel); padding: 1px 6px; border-radius: 4px;
  color: var(--accent); font-size: 0.75rem;
}

/* ---- 글 목록 ---- */
.blog-head { margin-bottom: 28px; }
.blog-head h1 { font-size: 1.7rem; font-weight: 900; margin-bottom: 8px; }
.blog-head p { font-size: 0.9rem; color: var(--text-dim); }

.post-list { display: flex; flex-direction: column; gap: 16px; }
.post-item {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); transition: .25s;
}
.post-item:hover { border-color: var(--accent); transform: translateY(-3px); }
.post-link { display: flex; gap: 22px; padding: 26px 28px; align-items: center; }
.post-text { flex: 1; }
.post-cat { font-size: 0.75rem; color: var(--accent); font-weight: 600; }
.post-text h2 { font-size: 1.2rem; font-weight: 700; margin: 8px 0 10px; }
.post-text p {
  font-size: 0.88rem; color: var(--text-dim); margin-bottom: 14px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.post-meta { font-size: 0.75rem; color: var(--text-dim); }
.post-thumb {
  width: 110px; height: 110px; flex-shrink: 0; border-radius: 12px;
  background: linear-gradient(135deg, var(--bg-soft), var(--accent-dark));
  display: flex; align-items: center; justify-content: center; font-size: 2.4rem;
}

.empty-msg {
  text-align: center; padding: 70px 0; color: var(--text-dim); font-size: 0.9rem;
}

.nav a.nav-active { color: var(--accent); }

/* ---- 포스트 본문 ---- */
.post-page {
  max-width: 820px; margin: 0 auto; padding: 120px 24px 80px;
}
.post-header { margin-bottom: 40px; border-bottom: 1px solid var(--line); padding-bottom: 28px; }
.post-header .post-cat { font-size: 0.8rem; }
.post-header h1 { font-size: clamp(1.6rem, 4vw, 2.2rem); font-weight: 900; margin: 12px 0 14px; }
.post-header .post-meta { font-size: 0.82rem; }
.post-content { font-size: 1rem; line-height: 1.9; }
.post-content p { margin-bottom: 22px; }
.post-content h2 {
  font-size: 1.3rem; margin: 44px 0 16px; padding-left: 14px;
  border-left: 4px solid var(--accent);
}
.post-content strong { color: var(--accent); }
.post-content img { border-radius: var(--radius); margin: 10px 0 24px; }
.post-footer {
  margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
}
.post-tags { font-size: 0.82rem; color: var(--accent); }
.back-to-list { font-size: 0.85rem; color: var(--text-dim); transition: color .2s; }
.back-to-list:hover { color: var(--accent); }

/* ---- 마인드맵 ---- */
.mindmap-wrap {
  background: var(--bg-soft); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; margin: 10px 0 28px;
  overflow-x: auto;
}
.mindmap-wrap svg { display: block; margin: 0 auto; min-width: 640px; }
.mm-caption { text-align: center; font-size: 0.78rem; color: var(--text-dim); margin-top: 10px; }

/* ---- 반응형 ---- */
@media (max-width: 900px) {
  .blog-layout { grid-template-columns: 1fr; }
  .blog-sidebar { position: static; }
  .post-link { flex-direction: row-reverse; padding: 20px; }
  .post-thumb { width: 80px; height: 80px; font-size: 1.8rem; }
}
