/* ============================================================
   brand-news-detail-wanted.css — 싱클 브랜드 소식 상세 (Wanted DS 클론)
   원본: claude.ai/design "Syncle 블로그 상세" (bd6a7d69)
   Wanted DS 런타임 없이 순수 CSS. 토큰: css/wanted-ds.css
   공용 셸(사이드바/헤더/푸터) 내부에 메인 콘텐츠만 교체.
   중앙 720px 리딩 컬럼 + 좌측 플로팅 공유 레일 + 에디토리얼 프로즈.
   본문(#article-body)은 작성자 Tiptap/임포트 HTML → 기본 프로즈 스타일만 제공.
   ============================================================ */

.blog-content-area { background: var(--ws-bg, #fff); }
.bn-stage { background: var(--ws-bg, #fff); color: var(--ws-text-normal); font-family: var(--font-sans); }
.bn-main { max-width: 880px; margin: 0 auto; padding: 38px 40px 56px; }

/* ── 스크롤 진행률 바 (디자인 .prog: 상단 3px, 블루 채움) ── */
.bn-prog {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 1200;
  background: transparent; pointer-events: none;
}
.bn-prog > i {
  display: block; height: 100%; width: 0; background: var(--ws-primary);
  border-radius: 0 2px 2px 0; transition: width .08s linear;
}

/* ── 좌측 플로팅 공유 레일 (디자인 .rail: 콘텐츠 영역 좌측 정렬, 스퀘어클+블러) ── */
.bn-rail {
  /* 헤더 콘텐츠(1240) 좌측 패딩(40)과 정렬 → 로고 x선에 맞춤 */
  position: fixed; left: max(16px, calc((100% - 1240px) / 2 + 40px)); top: 320px;
  display: flex; flex-direction: column; gap: 9px; z-index: 40;
}
.bn-rbtn {
  width: 44px; height: 44px; border-radius: 15px; cursor: pointer;
  background: rgba(255, 255, 255, .9);
  -webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px);
  border: 1px solid rgba(0, 0, 0, .06); box-shadow: 0 6px 20px rgba(0, 0, 0, .1);
  color: var(--ws-text-neutral); display: flex; align-items: center; justify-content: center;
  transition: transform .16s cubic-bezier(.34, 1.56, .64, 1), color .16s, background .16s;
}
.bn-rbtn:hover { color: var(--ws-primary); transform: scale(1.07); }
.bn-rbtn:active { transform: scale(.92); }
@media (prefers-reduced-motion: reduce) { .bn-rbtn, .bn-rbtn:hover, .bn-rbtn:active { transform: none; transition: color .16s, background .16s; } .bn-prog > i { transition: none; } }

/* ── 메타 (카테고리 + 날짜) ── */
.bn-meta, .toss-article__meta { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.bn-cat, #article-category {
  display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 8px;
  background: var(--blue-95); color: var(--ws-primary); font: 600 14px/1 var(--font-sans); white-space: nowrap;
}
.bn-date, #article-date { color: var(--ws-text-assistive); font: 500 14px/1 var(--font-sans); }

/* ── 제목 / 부제 ── */
.bn-title, #article-title {
  color: var(--ws-text-strong); margin: 0 0 18px;
  font: 700 40px/1.26 var(--font-sans); letter-spacing: -0.025em;
  /* balance는 줄을 일찍 꺾어 제목이 좁아 보임 → 제거. keep-all로 한국어 단어 중간 끊김 방지 */
  word-break: keep-all; overflow-wrap: break-word;
}
.bn-sub, #article-subtitle { color: var(--ws-text-neutral); margin: -6px 0 18px; font: 500 19px/1.5 var(--font-sans); word-break: keep-all; }

/* ── 작성자(회사) 칩 ── */
.bn-author, .toss-article__company { margin: 0 0 30px; }
.bn-author-link, .toss-article__company-link { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.bn-avatar, .toss-article__company-logo {
  width: 44px; height: 44px; border-radius: 12px; flex: none; object-fit: cover;
  background: var(--ws-fill); box-shadow: inset 0 0 0 1px var(--ws-line-alt);
}
.bn-avatar--initial { display: inline-flex; align-items: center; justify-content: center; background: var(--ws-text-strong); color: #fff; font: 700 16px/1 var(--font-sans); box-shadow: none; }
.bn-author-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.bn-author-name, .toss-article__company-name { color: var(--ws-text-strong); font: 600 15px/1.3 var(--font-sans); }
.bn-author-meta { color: var(--ws-text-assistive); font: 500 13px/1.3 var(--font-sans); }

/* ── 히어로 이미지 ── */
.bn-hero, .toss-article__hero { margin: 0 0 12px; border-radius: 16px; overflow: hidden; background: var(--ws-fill); box-shadow: inset 0 0 0 1px var(--ws-line-alt); }
.bn-hero img, .toss-article__hero-image { display: block; width: 100%; height: auto; }
.bn-hero-cap { text-align: center; color: var(--ws-text-assistive); font: 500 12px/1.5 var(--font-sans); margin: 0 0 8px; }

/* ── 리드(발췌) ── */
.bn-lead, .toss-article__info-banner { margin: 22px 0 8px; }
.bn-lead p, .toss-article__info-text, #excerpt-text {
  margin: 0; color: var(--ws-text-strong); font: 600 19px/1.68 var(--font-sans);
}

/* ============================================================
   본문 프로즈 (#article-body) — 작성자 HTML에 기본 에디토리얼 스타일
   ============================================================ */
.bn-body, .toss-article__body { color: var(--ws-text-strong); font: 500 19px/1.72 var(--font-sans); }
.bn-body > *:first-child { margin-top: 0; }
.bn-body p { margin: 0 0 18px; }
.bn-body h1 { font: 700 32px/1.3 var(--font-sans); color: var(--ws-text-strong); letter-spacing: -0.02em; margin: 46px 0 16px; word-break: keep-all; }
.bn-body h2 { font: 700 26px/1.3 var(--font-sans); color: var(--ws-text-strong); letter-spacing: -0.02em; margin: 44px 0 16px; word-break: keep-all; }
.bn-body h3 { font: 600 20px/1.4 var(--font-sans); color: var(--ws-text-strong); margin: 30px 0 12px; word-break: keep-all; }
.bn-body h4 { font: 600 17px/1.4 var(--font-sans); color: var(--ws-text-strong); margin: 24px 0 10px; word-break: keep-all; }
.bn-body a { color: var(--ws-primary); text-decoration: none; font-weight: 600; }
.bn-body a:hover { text-decoration: underline; }
.bn-body strong, .bn-body b { font-weight: 700; color: var(--ws-text-strong); }
.bn-body em, .bn-body i { font-style: italic; }
.bn-body mark { background: var(--blue-95); color: var(--ws-primary); padding: 0 3px; border-radius: 4px; }
.bn-body ul, .bn-body ol { margin: 0 0 18px; padding-left: 22px; }
.bn-body li { margin: 0 0 8px; }
.bn-body li::marker { color: var(--ws-text-neutral); }
.bn-body img { max-width: 100%; height: auto; border-radius: 12px; margin: 8px 0; }
.bn-body figure { margin: 20px 0; }
.bn-body figcaption { text-align: center; color: var(--ws-text-assistive); font: 500 13px/1.5 var(--font-sans); margin-top: 8px; }
.bn-body hr { border: none; border-top: 1px solid var(--ws-line); margin: 32px 0; }
/* 인용/콜아웃 (측면 스트라이프 대신 전체 배경 틴트) */
.bn-body blockquote {
  margin: 22px 0; padding: 18px 20px; border-radius: 12px; background: var(--blue-95);
  color: var(--ws-text-strong); font: 500 18px/1.6 var(--font-sans);
}
.bn-body blockquote p:last-child { margin-bottom: 0; }
/* 코드 */
.bn-body code { font-family: var(--ws-font-mono, ui-monospace, "SF Mono", Menlo, monospace); font-size: .9em; background: var(--ws-fill); padding: 2px 6px; border-radius: 6px; }
.bn-body pre { background: var(--ws-fill); border-radius: 12px; padding: 16px 18px; overflow-x: auto; margin: 20px 0; box-shadow: inset 0 0 0 1px var(--ws-line); }
.bn-body pre code { background: none; padding: 0; font-size: 14px; line-height: 1.6; }
/* 표 */
.bn-body table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 15px; display: block; overflow-x: auto; }
.bn-body th, .bn-body td { padding: 11px 14px; text-align: left; border-bottom: 1px solid var(--ws-line); vertical-align: top; }
.bn-body th { background: var(--ws-fill); color: var(--ws-text-neutral); font: 700 13.5px/1.4 var(--font-sans); white-space: nowrap; }
.bn-body td { font: 500 15px/1.5 var(--font-sans); color: var(--ws-text-strong); }
.bn-body iframe { max-width: 100%; border-radius: 12px; margin: 20px 0; border: none; }

/* ── 태그 ── */
.bn-tags, .toss-article__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 34px 0 0; padding-top: 28px; border-top: 1px solid var(--ws-line); }
.bn-tag, .toss-article__tag {
  display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border-radius: 8px;
  background: var(--ws-fill); color: var(--ws-text-neutral); font: 500 13px/1 var(--font-sans); white-space: nowrap;
  text-decoration: none;
}

/* ── 관련 소식 ── */
.toss-related-section { margin-top: 40px; }
.toss-related-section__title { color: var(--ws-text-strong); margin: 0 0 16px; font: 700 20px/1.4 var(--font-sans); }
.toss-related-grid, #related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.toss-article-card {
  display: flex; flex-direction: column; text-decoration: none; color: inherit;
  border-radius: 12px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--ws-line);
  transition: box-shadow .2s var(--ws-ease-standard, cubic-bezier(.4,0,.2,1)), transform .2s var(--ws-ease-standard, cubic-bezier(.4,0,.2,1));
}
.toss-article-card:hover { box-shadow: var(--ws-shadow-strong, 0 8px 24px rgba(0,0,0,.12)); transform: translateY(-2px); }
.toss-article-card__image { aspect-ratio: 16/10; background: var(--ws-fill); overflow: hidden; }
.toss-article-card__image img { width: 100%; height: 100%; object-fit: cover; }
.toss-article-card__body { padding: 13px 14px 15px; display: flex; flex-direction: column; gap: 6px; }
.toss-article-card__title { color: var(--ws-text-strong); margin: 0; font: 600 15px/1.4 var(--font-sans); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.toss-article-card__excerpt { color: var(--ws-text-neutral); margin: 0; font: 500 13px/1.5 var(--font-sans); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.toss-article-card__date { color: var(--ws-text-assistive); margin-top: 2px; font: 500 12px/1 var(--font-sans); }

/* ── 스켈레톤 ── */
@keyframes bnShimmer { 0% { opacity: .55; } 50% { opacity: 1; } 100% { opacity: .55; } }
.toss-article-skeleton { animation: bnShimmer 1.3s ease-in-out infinite; }
.toss-skeleton { background: var(--ws-fill); border-radius: 8px; }
.toss-skeleton__meta { display: flex; gap: 10px; margin-bottom: 18px; }
.toss-skeleton__badge { width: 64px; height: 26px; border-radius: 8px; }
.toss-skeleton__date { width: 90px; height: 26px; }
.toss-skeleton__title { height: 40px; margin-bottom: 12px; }
.toss-skeleton__title--short { width: 60%; }
.toss-skeleton__subtitle { width: 40%; height: 20px; margin: 20px 0; }
.toss-skeleton__hero { height: 360px; border-radius: 16px; margin-bottom: 28px; }
.toss-skeleton__content { display: flex; flex-direction: column; gap: 14px; }
.toss-skeleton__line { height: 18px; }
.toss-skeleton__line--full { width: 100%; }
.toss-skeleton__line--long { width: 92%; }
.toss-skeleton__line--medium { width: 70%; }
.toss-skeleton__line--short { width: 45%; }

/* ── 에러 상태 ── */
.toss-error-state { display: none; flex-direction: column; align-items: center; text-align: center; padding: 72px 24px; }
.toss-error-state__icon { width: 64px; height: 64px; border-radius: 50%; background: var(--ws-fill); display: flex; align-items: center; justify-content: center; font-size: 26px; color: var(--ws-text-assistive); margin-bottom: 18px; }
.toss-error-state__title { color: var(--ws-text-strong); margin: 0 0 8px; font: 700 22px/1.4 var(--font-sans); }
.toss-error-state__description { color: var(--ws-text-neutral); margin: 0 0 24px; font: 500 15px/1.6 var(--font-sans); }
.toss-error-state__actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.toss-error-state__btn { display: inline-flex; align-items: center; gap: 7px; height: 44px; padding: 0 18px; border-radius: 10px; border: none; cursor: pointer; font: 600 15px/1 var(--font-sans); text-decoration: none; }
.toss-error-state__btn--primary { background: var(--ws-primary); color: #fff; }
.toss-error-state__btn--secondary { background: var(--ws-fill); color: var(--ws-text-neutral); }

/* ── 토스트 ── */
.bn-toast {
  position: fixed; left: 50%; bottom: 32px; transform: translateX(-50%) translateY(8px); z-index: 2000;
  background: var(--ws-inverse-bg, #1b1c1e); color: #fff; font: 600 13px/1 var(--font-sans); padding: 11px 18px;
  border-radius: 10px; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.bn-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── 반응형 ── */
@media (max-width: 1080px) {
  .bn-rail { display: none; }
}
@media (max-width: 768px) {
  .bn-main { padding: 22px 20px 44px; }
  .bn-title, #article-title { font-size: 28px; line-height: 1.32; margin-bottom: 14px; }
  .bn-sub, #article-subtitle { font-size: 17px; }
  .bn-lead p, .toss-article__info-text, #excerpt-text { font-size: 17px; }
  .bn-body, .toss-article__body { font-size: 17px; line-height: 1.7; }
  .bn-body h2 { font-size: 22px; margin-top: 36px; }
  .bn-body h3 { font-size: 18px; }
  .toss-related-grid, #related-grid { grid-template-columns: 1fr; }
  .toss-article-card { flex-direction: row; }
  .toss-article-card__image { flex: none; width: 128px; aspect-ratio: 1/1; }
  .toss-article-card__body { flex: 1; min-width: 0; }
}
