/* =====================================================
   YEJI SOLUTION — 블로그/인사이트 공통 스타일
   메인 사이트(index.html)의 디자인 토큰을 그대로 재사용
===================================================== */
:root {
  color-scheme: light;
  --bg: #FFFFFF;
  --bg-soft: #F7F8FA;
  --bg-band: #EAEEF6;
  --bg-naver: #F1FBF4;
  --line: #E8EAED;
  --line-strong: #D5D8DD;
  --text: #1A1D24;
  --text-sub: #4B5563;
  --text-dim: #5F6672;
  --naver: #00C73C;
  --naver-dark: #006B21;
  --zigzag: #FF3F7E;
  --zigzag-dark: #B31449;
  --brand: #1B2A4E;
  --brand-accent: #2563EB;
  --dur-base: 0.30s;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  /* 프리미엄 토큰 동기화 (메인과 일관) */
  --shadow-sm: 0 1px 2px rgba(26,29,36,0.04), 0 2px 6px rgba(26,29,36,0.05);
  --shadow-lg: 0 10px 24px rgba(26,29,36,0.08), 0 28px 60px rgba(26,29,36,0.10);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
::selection { background: rgba(0,199,60,0.20); color: var(--text); }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: rgba(27,42,78,0.22); border-radius: 8px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: rgba(27,42,78,0.38); border: 3px solid transparent; background-clip: content-box; }
.post-date, .post-read, .article-head .post-meta { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--brand-accent); outline-offset: 2px; border-radius: 3px; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  font-family: Pretendard, -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
}
a { color: inherit; text-decoration: none; }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }
.wrap-wide { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* ===== HEADER (메인과 동일 톤) ===== */
header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.86);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: 1080px; margin: 0 auto; padding: 0 24px;
  height: 62px; display: flex; align-items: center; justify-content: space-between;
}
.brand { font-size: 17px; font-weight: 800; letter-spacing: -0.01em; }
.brand .accent-n { color: var(--naver-dark); }
.brand .sub { color: var(--text-dim); font-weight: 500; font-size: 14px; }
.nav-menu { display: flex; gap: 22px; align-items: center; }
.nav-menu a { font-size: 14px; font-weight: 600; color: var(--text-sub); transition: color var(--dur-base) var(--ease-out); }
.nav-menu a:hover, .nav-menu a.is-current { color: var(--text); }
/* .nav-menu a 보다 우선순위를 높여 흰색·굵기·배경이 덮이지 않게 */
.nav-menu a.nav-cta {
  font-size: 13.5px; font-weight: 700; color: #fff;
  background: var(--brand); padding: 9px 16px; border-radius: 8px;
  transition: transform var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out);
}
.nav-menu a.nav-cta:hover { background: #0f1c3a; color: #fff; transform: translateY(-1px); }
/* 좁은 화면: 보조 링크만 숨기고 CTA는 항상 노출(메뉴가 통째로 사라지는 문제 해결) */
@media (max-width: 720px) {
  .nav { padding: 0 16px; gap: 12px; }
  .brand { font-size: 15px; white-space: nowrap; }
  .brand .sub { display: none; }
  .nav-menu { gap: 0; flex-shrink: 0; }
  .nav-menu a:not(.nav-cta) { display: none; }
  .nav-menu a.nav-cta { white-space: nowrap; font-size: 12.5px; padding: 8px 13px; }
}

/* ===== 블로그 목록 ===== */
.blog-hero { padding: 64px 0 36px; text-align: center; }
.blog-hero .eyebrow {
  display: inline-block; font-size: 12px; font-weight: 800; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--naver-dark); margin-bottom: 14px;
}
.blog-hero h1 { font-size: clamp(26px, 5vw, 38px); font-weight: 900; letter-spacing: -0.02em; line-height: 1.25; }
.blog-hero p { margin-top: 14px; font-size: 15px; color: var(--text-sub); }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.blog-tools { padding: 4px 0 18px; }
.blog-search input {
  width: 100%; min-height: 48px; padding: 0 16px 0 44px;
  border: 1px solid var(--line-strong); border-radius: 12px; color: var(--text);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%235F6672' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-4-4'/%3E%3C/svg%3E") 15px center/18px no-repeat;
  font: inherit; font-size: 15px;
}
.blog-search input:focus { border-color: var(--brand-accent); outline: 2px solid rgba(37,99,235,.18); }
.blog-filters { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.blog-filter {
  min-height: 40px; padding: 0 15px; border: 1px solid var(--line-strong); border-radius: 999px;
  background: #fff; color: var(--text-sub); font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer;
}
.blog-filter.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.blog-count { margin-top: 12px; color: var(--text-dim); font-size: 13px; }

.post-list { display: grid; gap: 18px; padding: 16px 0 72px; }
.post-card[hidden] { display: none; }
.post-card:nth-child(-n+3) { border-color: #CCD6EA; background: linear-gradient(145deg, #fff 0%, #F8FAFF 100%); }
.post-card:nth-child(-n+3)::before { content: '추천'; display: inline-block; margin-bottom: 12px; padding: 3px 9px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 800; }
.post-card {
  display: block; background: #fff; border: 1px solid var(--line);
  border-radius: 16px; padding: 26px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out);
}
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
.post-meta { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.post-tag {
  font-size: 11px; font-weight: 800; letter-spacing: 0.04em;
  padding: 3px 9px; border-radius: 5px;
}
.post-tag.naver { background: var(--bg-naver); color: var(--naver-dark); }
.post-tag.zigzag { background: #FEF1F5; color: var(--zigzag-dark); }
.post-tag.strategy { background: #EEF2FF; color: var(--brand); }
.post-tag.coupang { background: #FFF0F1; color: #B8000F; }
.post-tag.ohouse { background: #EEF3FF; color: #2851D4; }
.post-tag.kakao { background: #FFF7DB; color: #7A5F00; }
.post-date { font-size: 12.5px; color: var(--text-dim); font-weight: 600; }
.post-read { font-size: 12.5px; color: var(--text-dim); margin-left: auto; }
.post-card h2 { font-size: 20px; font-weight: 800; line-height: 1.4; letter-spacing: -0.01em; }
.post-card p { margin-top: 10px; font-size: 14.5px; color: var(--text-sub); line-height: 1.7; }
.post-more { margin-top: 14px; font-size: 13.5px; font-weight: 700; color: var(--brand-accent); }

/* ===== 글 본문 (article) ===== */
.article-head { padding: 56px 0 28px; }
.article-head .post-meta { justify-content: flex-start; }
.article-head h1 { font-size: clamp(26px, 4.6vw, 40px); font-weight: 900; line-height: 1.3; letter-spacing: -0.02em; }
.article-head .lead { margin-top: 18px; font-size: 17px; color: var(--text-sub); line-height: 1.75; }
.article-head .byline { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 13px; color: var(--text-dim); }
.article-head .byline b { color: var(--text-sub); font-weight: 700; }
.article-head .byline .author-link { color: var(--text-sub); font-weight: 700; text-decoration: underline; text-decoration-color: rgba(0, 199, 60, .35); text-underline-offset: 3px; }
.article-head .byline .author-link:hover { color: var(--naver); text-decoration-color: currentColor; }

.article-toc {
  margin: 0 0 28px; padding: 20px 22px; border: 1px solid var(--line);
  border-radius: 14px; background: var(--bg-soft);
}
.toc-title { display: block; margin-bottom: 10px; color: var(--brand); font-size: 14px; }
.article-toc ol { margin: 0; padding-left: 20px; }
.article-toc li { margin: 6px 0; color: var(--text-dim); font-size: 14px; }
.article-toc a { color: var(--text-sub); text-decoration: none; }
.article-toc a:hover { color: var(--naver-dark); text-decoration: underline; text-underline-offset: 3px; }
.article-body h2 { scroll-margin-top: 82px; }

.article-body { padding: 8px 0 56px; font-size: 16.5px; line-height: 1.85; color: #20242c; }
.article-body h2 {
  font-size: 23px; font-weight: 800; line-height: 1.4; letter-spacing: -0.01em;
  margin: 44px 0 14px; padding-top: 10px;
}
.article-body h3 { font-size: 18px; font-weight: 800; margin: 30px 0 10px; color: var(--text); }
.article-body p { margin: 14px 0; }
.article-body strong { font-weight: 800; color: var(--text); }
.article-body ul, .article-body ol { margin: 14px 0 14px 4px; padding-left: 22px; }
.article-body li { margin: 8px 0; }
.article-body a { color: var(--brand-accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.article-body blockquote {
  margin: 22px 0; padding: 16px 20px; background: var(--bg-soft);
  border-left: 4px solid var(--brand); border-radius: 0 10px 10px 0;
  font-size: 15.5px; color: var(--text-sub); font-style: italic;
}
.callout {
  margin: 24px 0; padding: 20px 22px; border-radius: 14px;
  background: var(--bg-naver); border: 1px solid #BFE9CB;
}
.callout .callout-ttl { font-size: 13px; font-weight: 800; color: var(--naver-dark); letter-spacing: 0.02em; margin-bottom: 8px; }
.callout p { margin: 6px 0; font-size: 15px; color: #1f3a29; }

.key-list { list-style: none; margin: 20px 0; padding: 0; }
.key-list li {
  position: relative; padding: 14px 16px 14px 50px; margin: 10px 0;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  font-size: 15.5px; counter-increment: keyitem;
}
.key-list li::before {
  content: counter(keyitem);
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  width: 26px; height: 26px; border-radius: 7px;
  background: var(--brand); color: #fff;
  font-size: 13px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.key-list { counter-reset: keyitem; }

/* ===== 글 하단 CTA ===== */
.article-cta {
  margin: 48px 0 12px; padding: 34px 30px; border-radius: 18px;
  background: linear-gradient(160deg, #1f3057 0%, #1B2A4E 100%);
  color: #fff; text-align: center;
}
.article-cta h3 { font-size: 21px; font-weight: 800; line-height: 1.4; }
.article-cta p { margin-top: 12px; font-size: 14.5px; color: rgba(255,255,255,0.78); line-height: 1.7; }
.article-cta .cta-row { margin-top: 22px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
/* CTA가 .article-body 안에 있어 본문 글자색·링크 규칙에 덮이는 것 방지 */
.article-body .article-cta h3 { color: #fff; }
.article-body .article-cta a { text-decoration: none; color: #fff; }
.article-body .article-cta .btn-primary,
.article-body .article-cta .btn-ghost { color: #fff; }
.btn-primary {
  background: var(--naver); color: #fff; font-weight: 800; font-size: 15px;
  padding: 13px 24px; border-radius: 10px;
  transition: transform var(--dur-base) var(--ease-out), filter var(--dur-base) var(--ease-out);
}
.btn-primary:hover { transform: translateY(-2px); filter: brightness(1.06); }
.btn-ghost {
  background: rgba(255,255,255,0.10); color: #fff; font-weight: 700; font-size: 15px;
  padding: 13px 24px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.25);
  transition: background var(--dur-base) var(--ease-out);
}
.btn-ghost:hover { background: rgba(255,255,255,0.18); }

.back-link { display: inline-block; margin: 8px 0 4px; font-size: 14px; font-weight: 700; color: var(--text-dim); }
.back-link:hover { color: var(--text); }

/* ===== 다른 글 ===== */
.more-posts { padding: 8px 0 72px; border-top: 1px solid var(--line); margin-top: 40px; }
.more-posts .mp-ttl { font-size: 14px; font-weight: 800; color: var(--text-dim); letter-spacing: 0.04em; text-transform: uppercase; padding-top: 28px; margin-bottom: 16px; }

/* ===== FOOTER ===== */
footer { background: #0F1117; color: rgba(255,255,255,0.66); padding: 44px 0 36px; }
.footer-grid { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.footer-brand-name { font-size: 17px; font-weight: 800; color: #fff; }
.footer-brand-name .accent-n { color: var(--naver); }
.footer-tagline { margin-top: 10px; font-size: 13.5px; line-height: 1.7; }
.footer-links { margin-top: 18px; display: flex; gap: 18px; flex-wrap: wrap; font-size: 13.5px; font-weight: 600; }
.footer-links a:hover { color: #fff; }
.footer-copy { margin-top: 26px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,0.12); font-size: 12.5px; color: rgba(255,255,255,0.68); }

/* ===== 토픽 클러스터 (주제별 상호 링크) ===== */
.topic-cluster {
  margin: 40px 0 8px; padding: 26px 28px;
  background: #fff; border: 1px solid var(--line, #E8EAED);
  border-radius: 16px;
}
.tc-head { margin-bottom: 16px; }
.tc-tag {
  display: inline-block; font-size: 12px; font-weight: 800;
  letter-spacing: 0.04em; padding: 5px 12px; border-radius: 999px;
  background: #EEF2FF; color: #1B2A4E;
}
.tc-tag.naver   { background: #E9FBEF; color: #009B2F; }
.tc-tag.zigzag  { background: #FEF1F5; color: #E32869; }
.tc-tag.coupang { background: #FDEEEC; color: #B32B21; }
.tc-tag.ohouse  { background: #EDF5FD; color: #2A6FB3; }
.tc-desc {
  margin: 10px 0 0; font-size: 13.5px; line-height: 1.6;
  color: var(--text-sub, #4B5563);
}
.tc-list { list-style: none; margin: 0; padding: 0; }
.tc-list li { border-top: 1px solid var(--line, #E8EAED); }
.tc-list a {
  display: flex; align-items: center; min-height: 48px;
  padding: 12px 0; font-size: 14.5px; font-weight: 600;
  color: var(--text, #1A1D24); text-decoration: none; line-height: 1.5;
  transition: color 0.15s;
}
.tc-list a:hover { color: #009B2F; }
.tc-list a::before { content: '→'; margin-right: 10px; color: #A3AAB6; flex-shrink: 0; }
.tc-all {
  display: inline-block; margin-top: 16px; font-size: 13.5px;
  font-weight: 700; color: var(--text-sub, #4B5563); text-decoration: none;
  padding: 10px 0; min-height: 44px; display: flex; align-items: center;
}
.tc-all:hover { color: #009B2F; }
@media (max-width: 640px) {
  .topic-cluster { padding: 22px 20px; border-radius: 14px; }
  .tc-list a { font-size: 14px; }
}
