/* 크리티컬 대표홈페이지 — blog 화면 스타일 (원본 Vue 컴포넌트 scoped 스타일을 전역으로 옮김) */

/* ── views/blog/modules/BlHero.vue ── */
.blh {
  padding: calc(var(--header-h) + 88px) 0 0;
}
.blh__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px 64px;
  padding-bottom: 48px;
}
.blh__title {
  font-size: clamp(40px, 5vw, 76px);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -0.055em;
  word-break: keep-all;
  animation: blh-in 0.8s var(--ease) both;
}
.blh__title em {
  font-style: normal;
  color: var(--brand);
}
.blh__lead {
  padding-bottom: 8px;
  font-size: 16px;
  line-height: 1.75;
  color: var(--mute);
  word-break: keep-all;
  animation: blh-in 0.8s var(--ease) 0.12s both;
}

/* 아래 선 — 경로 · 최근 글 */
.blh__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-top: 2px solid var(--ink);
  font-size: 14px;
  color: var(--mute);
  animation: blh-in 0.8s var(--ease) 0.2s both;
}
.blh__crumb {
  display: flex;
  align-items: center;
  gap: 10px;
}
.blh__crumb a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  transition: color 0.2s;
}
.blh__crumb a:hover {
  color: var(--ink);
}
.blh__crumb span[aria-hidden] {
  color: #c9cacd;
}
.blh__crumb [aria-current] {
  font-weight: 600;
  color: var(--ink);
}
.blh__latest b {
  margin-left: 6px;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
}

@keyframes blh-in {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
}
@media (prefers-reduced-motion: reduce) {
  .blh__title,
  .blh__lead,
  .blh__bar {
    animation: none;
  }
}

@media (max-width: 1024px) {
  .blh__head {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 768px) {
  .blh {
    padding-top: calc(var(--header-h) + 40px);
  }
  .blh__head {
    gap: 16px;
    padding-bottom: 32px;
  }
  .blh__title {
    font-size: 34px;
  }
  .blh__lead {
    padding-bottom: 0;
    font-size: 15px;
  }
  .blh__lead br {
    display: none;
  }
  .blh__bar {
    font-size: 13px;
  }
}

/* ── views/blog/modules/BlList.vue ── */
.bl {
  padding: 64px 0 120px;
}

/* 분류 탭 — 큰 글자, 고른 탭은 검정 + 아래 빨간 선 */
.bl-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 32px;
}
.bl-tab {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  min-height: 48px;
  padding: 10px 0 6px;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #b4b6ba;
  transition: color 0.2s;
}
/* 개수는 글자 오른쪽 위에 작게 */
.bl-tab sup {
  position: relative;
  top: -0.8em;
  margin-left: 3px;
  line-height: 1;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
}
.bl-tab::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.bl-tab:hover {
  color: var(--ink-2);
}
.bl-tab.is-on {
  color: var(--ink);
}
.bl-tab.is-on::after {
  transform: scaleX(1);
}
.bl-tab.is-on sup {
  color: var(--brand);
}
.bl-count {
  margin-top: 36px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  color: var(--mute);
}
.bl-count b {
  margin-right: 4px;
  color: var(--ink);
}

/* 4열 — 글이 늘면 오른쪽으로 채우고 다음 줄로 */
.bl-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 52px 24px;
  margin-top: 36px;
}
.bl-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.bl-thumb {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 6px;
  background: var(--paper);
}
.bl-thumb > img,
.bl-cover {
  width: 100%;
  height: 100%;
  transition: transform 0.6s var(--ease);
}
.bl-thumb > img {
  object-fit: cover;
}
.bl-card:hover .bl-thumb > img,
.bl-card:hover .bl-cover {
  transform: scale(1.04);
}

/* 썸네일이 없을 때 — 분류 · 제목 글자 표지, 오른쪽 아래 심볼 */
.bl-cover {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 26px 24px;
  background: linear-gradient(165deg, #fbf3f3 0%, #f4e6e7 100%);
}
.bl-cover__cat {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--brand);
}
.bl-cover__title {
  position: relative;
  z-index: 1;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: clamp(20px, 1.6vw, 25px);
  font-weight: 800;
  line-height: 1.36;
  letter-spacing: -0.045em;
  color: var(--ink);
  word-break: keep-all;
}
.bl-cover__mark {
  position: absolute;
  right: -10%;
  bottom: -14%;
  width: 62%;
  opacity: 0.16;
}
.bl-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 9px;
  border-radius: var(--radius-pill);
  background: var(--gold);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  color: var(--ink);
}

.bl-card__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: -0.03em;
  word-break: keep-all;
  transition: color 0.2s;
}
.bl-card:hover .bl-card__title {
  color: var(--brand);
}
.bl-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.bl-chips span {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 11px;
  border-radius: 4px;
  background: var(--paper);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--mute);
}
.bl-chips .is-cat {
  background: var(--ink);
  letter-spacing: 0.04em;
  color: #fff;
}

.bl-empty {
  padding: 80px 0;
  text-align: center;
  color: var(--mute);
}
.bl-more {
  display: flex;
  justify-content: center;
  margin-top: 64px;
}
.bl-more button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 32px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  transition:
    background 0.2s,
    color 0.2s;
}
.bl-more button:hover {
  background: var(--ink);
  color: #fff;
}
.bl-more b {
  color: var(--brand);
}

@media (max-width: 1200px) {
  .bl-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 1024px) {
  .bl-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 768px) {
  .bl {
    padding: 48px 0 72px;
  }
  /* 탭은 가로로 밀어서 보기 */
  .bl-tabs {
    flex-wrap: nowrap;
    gap: 22px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .bl-tabs::-webkit-scrollbar {
    display: none;
  }
  .bl-tab {
    flex-shrink: 0;
    font-size: 20px;
  }
  .bl-count {
    margin-top: 20px;
  }
  .bl-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
    margin-top: 28px;
  }
  .bl-more {
    margin-top: 44px;
  }
}

/* ── views/blog/index.vue ── */
.blog {
  overflow-x: clip;
}
