/* 팜시크릿 — 팜스레터 상세 (letter-view.html)
 * 베이스: common.css + letters.css (.lt-card, .lt-sub, .tk-post-cat, .lt-cat-*)
 * 톤: 가독성 우선, 본문 max-width 720px, 부드러운 라인
 */

/* ═════════════════════════════════════════════
   1. 페이지 컨테이너
   ═════════════════════════════════════════════ */
.lv-page {
  background: #fff;
  padding-bottom: 60px;
}

/* ═════════════════════════════════════════════
   2. 브레드크럼
   ═════════════════════════════════════════════ */
.lv-crumb {
  border-bottom: 1px solid #eef0f3;
  padding: 14px 0;
  font-size: 13px;
  color: #9ca3af;
}
.lv-crumb a {
  color: #6b7280;
  text-decoration: none;
  transition: color 0.15s ease;
}
.lv-crumb a:hover { color: var(--color-brand); }
.lv-crumb-sep {
  margin: 0 8px;
  color: #d1d5db;
}
.lv-crumb-cur {
  color: #4b5563;
  font-weight: 500;
  display: inline-block;
  max-width: 60vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}

/* ═════════════════════════════════════════════
   3. 아티클 헤드
   ═════════════════════════════════════════════ */
.lv-head {
  padding: 40px 0 24px;
  max-width: 720px;
}
.lv-cat {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  padding: 6px 12px !important;
  border-radius: 9999px;
  font-size: 12.5px !important;
  font-weight: 700;
  margin-bottom: 16px;
}
.lv-cat-icon {
  width: 18px;
  height: 18px;
  object-fit: contain;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.08));
}
.lv-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 3.6vw, 40px);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.03em;
  color: #111827;
  margin: 0 0 16px;
  word-break: keep-all;
}
.lv-title em {
  font-style: normal;
  color: var(--color-brand);
}
.lv-deck {
  font-family: var(--font-display);
  font-size: clamp(15px, 1.6vw, 17px);
  font-weight: 400;
  line-height: 1.65;
  color: #4b5563;
  letter-spacing: -0.01em;
  margin: 0 0 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid #eef0f3;
}

.lv-byline {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: center;
}
@media (min-width: 720px) {
  .lv-byline {
    grid-template-columns: auto 1fr auto;
    gap: 20px;
  }
}
.lv-author {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.lv-author-ava {
  width: 38px;
  height: 38px;
  border-radius: 9999px;
  background: linear-gradient(135deg, #fed7aa, #fb923c);
  color: #7c2d12;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  flex-shrink: 0;
}
.lv-author-name {
  display: flex;
  flex-direction: column;
  line-height: 1.35;
  min-width: 0;
}
.lv-author-name strong {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}
.lv-author-name span {
  font-size: 12px;
  color: #9ca3af;
}
.lv-author:hover .lv-author-name strong { color: var(--color-brand); }

.lv-meta {
  list-style: none;
  margin: 0;
  padding: 12px 16px;
  background: #f9fafb;
  border-radius: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  font-size: 13px;
  color: #4b5563;
  font-family: var(--font-mono);
}
.lv-meta li {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}
.lv-meta-label {
  font-family: var(--font-label);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #9ca3af;
}

.lv-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.lv-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 9999px;
  font-size: 12.5px;
  font-weight: 600;
  color: #4b5563;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lv-action:hover {
  background: #f4f5f7;
  border-color: #d1d5db;
  color: #111827;
  transform: translateY(-1px);
}
.lv-action.is-on {
  background: var(--color-brand);
  border-color: var(--color-brand);
  color: #fff;
  box-shadow: 0 4px 12px rgba(254,105,27,0.28);
}
.lv-action.is-on:hover {
  background: var(--color-brand-dark);
  border-color: var(--color-brand-dark);
}
.lv-action svg {
  flex-shrink: 0;
  color: currentColor;
}

/* ═════════════════════════════════════════════
   4. 커버 이미지
   ═════════════════════════════════════════════ */
.lv-cover {
  margin: 0 auto 36px;
  max-width: 720px;
  padding: 0;
}
.lv-cover img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: 14px;
  display: block;
  background: #f3f4f6;
}
.lv-cover figcaption {
  margin-top: 10px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 12.5px;
  color: #9ca3af;
  text-align: center;
}

/* ═════════════════════════════════════════════
   5. 본문 (Medium 톤 — max 720)
   ═════════════════════════════════════════════ */
.lv-body {
  max-width: 720px;
  position: relative;
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1.85;
  color: #1f2937;
  letter-spacing: -0.005em;
  word-break: keep-all;
}
.lv-body p {
  margin: 0 0 22px;
}
.lv-body strong { font-weight: 700; color: #111827; }
.lv-body em { font-style: normal; color: var(--color-brand); font-weight: 600; }
.lv-lede {
  font-size: 19px;
  line-height: 1.7;
  font-weight: 500;
  color: #111827;
  border-left: 4px solid var(--color-brand);
  padding-left: 16px;
  margin-bottom: 28px !important;
}
.lv-body h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  line-height: 1.35;
  color: #111827;
  letter-spacing: -0.02em;
  margin: 44px 0 14px;
  scroll-margin-top: 80px;
}
.lv-body h2::before {
  content: '';
  display: block;
  width: 32px;
  height: 3px;
  background: var(--color-brand);
  margin-bottom: 12px;
  border-radius: 2px;
}
.lv-body h3 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.4;
  color: #111827;
  margin: 32px 0 12px;
}
.lv-body ul,
.lv-body ol {
  padding-left: 22px;
  margin: 0 0 22px;
}
.lv-body ul li,
.lv-body ol li {
  margin-bottom: 8px;
  line-height: 1.75;
}
.lv-body ul li::marker { color: var(--color-brand); }
.lv-body ol li::marker { color: var(--color-brand); font-weight: 700; }
.lv-body blockquote {
  margin: 26px 0;
  padding: 20px 22px;
  background: #fff7f1;
  border-left: 4px solid var(--color-brand);
  border-radius: 0 10px 10px 0;
  font-family: var(--font-display);
  font-size: 16px;
  line-height: 1.7;
  color: #4b5563;
  font-style: italic;
}
.lv-body blockquote::before {
  content: '"';
  font-family: Georgia, serif;
  font-size: 32px;
  font-style: normal;
  color: var(--color-brand);
  line-height: 0;
  vertical-align: -8px;
  margin-right: 4px;
}
.lv-inline {
  margin: 32px 0;
}
.lv-inline img {
  width: 100%;
  border-radius: 10px;
  display: block;
  background: #f3f4f6;
}
.lv-inline figcaption {
  margin-top: 10px;
  font-style: italic;
  font-size: 12.5px;
  color: #9ca3af;
  text-align: center;
}
.lv-closing {
  margin-top: 32px !important;
  padding-top: 24px;
  border-top: 1px solid #eef0f3;
  font-size: 15px;
  color: #6b7280;
  font-style: italic;
}

/* 비회원 본문 게이팅 */
.lv-body.is-gated {
  max-height: 720px;
  overflow: hidden;
}
.lv-body.is-gated::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 360px;
  background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.92) 50%, #fff 100%);
  pointer-events: none;
}
.lv-gate {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(560px, calc(100% - 24px));
  z-index: 2;
  padding: 0;
}
.lv-gate-card {
  background: #fff;
  border: 1px solid rgba(254,105,27,0.25);
  border-radius: 16px;
  padding: 24px 24px 22px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.08);
  text-align: center;
}
.lv-gate-pill {
  display: inline-block;
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--color-brand);
  background: rgba(254,105,27,0.1);
  padding: 5px 12px;
  border-radius: 9999px;
  margin-bottom: 12px;
}
.lv-gate-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}
.lv-gate-desc {
  font-size: 13.5px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 18px;
}
.lv-gate-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
}
.lv-gate-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 18px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  color: #111827;
  background: #f4f5f7;
  transition: all 0.15s ease;
}
.lv-gate-btn:hover { background: #e5e7eb; }
.lv-gate-btn--primary {
  background: var(--color-brand);
  color: #fff;
  box-shadow: 0 6px 16px rgba(254,105,27,0.3);
}
.lv-gate-btn--primary:hover { background: var(--color-brand-dark); }

/* ═════════════════════════════════════════════
   6. 태그
   ═════════════════════════════════════════════ */
.lv-tags {
  max-width: 720px;
  margin: 36px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 24px;
  border-top: 1px solid #eef0f3;
}
.lv-tags a {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 9999px;
  background: #f4f5f7;
  font-size: 12.5px;
  font-weight: 500;
  color: #4b5563;
  text-decoration: none;
  transition: all 0.15s ease;
}
.lv-tags a:hover {
  background: var(--color-brand-soft, rgba(254,105,27,0.08));
  color: var(--color-brand);
}

/* ═════════════════════════════════════════════
   7. 저자 카드
   ═════════════════════════════════════════════ */
.lv-author-card {
  max-width: 720px;
  margin: 36px auto 0;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 18px;
  align-items: start;
  padding: 24px;
  background: linear-gradient(180deg, #fff7f1 0%, #fff 100%);
  border: 1px solid rgba(254,105,27,0.18);
  border-radius: 14px;
}
.lv-author-card-ava {
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  background: linear-gradient(135deg, #fed7aa, #fb923c);
  color: #7c2d12;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
}
.lv-author-card-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.lv-author-card-label {
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--color-brand);
}
.lv-author-card-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.01em;
}
.lv-author-card-bio {
  font-size: 13.5px;
  color: #6b7280;
  line-height: 1.65;
  margin: 2px 0 6px;
}
.lv-author-card-bio strong { color: #111827; font-weight: 700; }
.lv-author-card-more {
  align-self: flex-start;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-brand);
  text-decoration: none;
}
.lv-author-card-more:hover { color: var(--color-brand-dark); }

/* ═════════════════════════════════════════════
   8. 이전/다음 글 네비
   ═════════════════════════════════════════════ */
.lv-nav {
  max-width: 720px;
  margin: 36px auto 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 720px) {
  .lv-nav { grid-template-columns: 1fr 1fr; }
}
.lv-nav-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  border: 1px solid #eef0f3;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: all 0.18s ease;
}
.lv-nav-item:hover {
  border-color: #d1d5db;
  background: #fafbfc;
}
.lv-nav-prev { text-align: left; }
.lv-nav-next { text-align: right; }
.lv-nav-label {
  font-family: var(--font-label);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #9ca3af;
  text-transform: uppercase;
}
.lv-nav-item:hover .lv-nav-label { color: var(--color-brand); }
.lv-nav-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: #111827;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  letter-spacing: -0.01em;
}

/* ═════════════════════════════════════════════
   9. 관련 글
   ═════════════════════════════════════════════ */
.lv-related {
  margin-top: 56px;
  padding-top: 36px;
  border-top: 1px solid #eef0f3;
}
.lv-related-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.lv-related-title {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: #111827;
  letter-spacing: -0.02em;
  margin: 0;
}
.lv-related-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-brand);
  text-decoration: none;
}
.lv-related-more:hover { color: var(--color-brand-dark); }

/* ═════════════════════════════════════════════
   10. 구독 CTA 영역 (letters.css .lt-sub 재사용)
   ═════════════════════════════════════════════ */
.lv-sub-wrap {
  margin-top: 56px;
}

/* ═════════════════════════════════════════════
   11. 반응형 보정
   ═════════════════════════════════════════════ */
@media (max-width: 720px) {
  .lv-head { padding: 28px 0 20px; }
  .lv-byline { gap: 12px; }
  .lv-meta { gap: 10px; font-size: 11.5px; }
  .lv-actions { flex-wrap: wrap; }
  .lv-cover { padding: 0; margin-bottom: 28px; }
  .lv-body { font-size: 16px; line-height: 1.8; }
  .lv-body h2 { font-size: 21px; margin-top: 36px; }
  .lv-lede { font-size: 17px; padding-left: 12px; }
  .lv-author-card {
    grid-template-columns: 56px 1fr;
    gap: 14px;
    padding: 18px;
  }
  .lv-author-card-ava { width: 56px; height: 56px; font-size: 19px; }
  .lv-related { margin-top: 44px; }
}
