/*
 * sellmate.io 블로그(WWW-7). views: pages/blog_index(목록) · pages/blog_show(글).
 * 수치는 2026-11-12 원본 /blog 를 1920px 에서 잰 값이다. 본문 글자 크기는 원본 편집기가 넣은 인라인 style 이 정한다.
 */

/* ---------- 목록 ---------- */
.sm-blog { box-sizing: content-box; max-width: 1160px; margin: 0 auto; padding: 70px 20px 145px; color: #252525; }
.sm-blog__heading { margin: 0; color: rgb(0, 41, 95); font-size: 34.28px; font-weight: 700; line-height: 1.2; letter-spacing: 2px; }

/* 분류 탭: 6칸 148px(가운데), 바깥·칸 사이 1px 선, 고른 칸은 진회색 바탕 */
.sm-blog__tabs { display: flex; width: max-content; max-width: 100%; margin: 50px auto 0; border: 1px solid #d0d0d0; }
.sm-blog__tab { display: flex; align-items: center; justify-content: center; box-sizing: border-box; width: 149px; height: 40px; padding: 0 2px;
    background: #fff; color: #212121; font-size: 14px; text-decoration: none; }
.sm-blog__tab + .sm-blog__tab { border-left: 1px solid #d0d0d0; }
.sm-blog__tab.is-active { background: rgb(74, 72, 74); color: #fff; }
.sm-blog__tab:focus-visible { outline: 2px solid rgb(0, 41, 95); outline-offset: -2px; }
.sm-blog__line { height: 0; margin: 12px 0 32px; border: 0; border-top: 1px solid #efefef; }

/* 카드: 3열 365px · 사이 32px, 1px 테두리 · 모서리 12px */
.sm-blog__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin: 0; padding: 0; list-style: none; }
.sm-blog-card { display: flex; flex-direction: column; box-sizing: border-box; height: 100%; overflow: hidden; border: 1px solid #eee; border-radius: 12px;
    color: inherit; text-decoration: none; }
.sm-blog-card__thumb { display: block; aspect-ratio: 363 / 206; overflow: hidden; background: #f5f5f5; }
.sm-blog-card__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.sm-blog-card__body { display: flex; flex: 1; flex-direction: column; padding: 20px 20px 22px; }
.sm-blog-card__title { color: #000; font-size: 18px; line-height: 1.3; overflow-wrap: anywhere; }
.sm-blog-card__new { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 6px; border-radius: 50%;
    background: #ff4e3c; color: #fff; font-size: 10px; font-style: normal; font-weight: 700; line-height: 1; vertical-align: 2px; }
.sm-blog-card__summary { margin-top: 5px; color: #757575; font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.sm-blog-card__date { margin-top: auto; padding-top: 20px; color: #757575; font-size: 11px; line-height: 1.2; }
.sm-blog-card:hover .sm-blog-card__title { text-decoration: underline; }
.sm-blog-card:focus-visible { outline: 2px solid rgb(0, 41, 95); outline-offset: 2px; }
.sm-blog__empty { padding: 80px 0; color: #757575; text-align: center; }

/* 쪽 번호: 작은 숫자, 지금 쪽만 진하게 */
.sm-blog__pages { display: flex; justify-content: center; gap: 6px; margin-top: 81px; }
.sm-blog__page { display: inline-flex; align-items: center; justify-content: center; min-width: 24px; height: 25px; border-radius: 50%;
    color: rgba(37, 37, 37, 0.4); font-size: 17px; text-decoration: none; }
.sm-blog__page.is-active { color: #252525; }
.sm-blog__page.is-disabled { color: rgba(37, 37, 37, 0.2); }
.sm-blog__page:hover:not(.is-disabled) { color: #252525; }

/* ---------- 글 ---------- */
.sm-blog-post { box-sizing: content-box; max-width: 870px; margin: 0 auto; padding: 106px 15px 100px; color: #252525; }
.sm-blog-post__head { text-align: center; }
.sm-blog-post__board { display: inline-block; color: #252525; font-size: 15px; line-height: 41px; text-decoration: none; }
.sm-blog-post__title { margin: 20px -15px 0; font-size: 34.28px; font-weight: 400; line-height: 1.4; overflow-wrap: anywhere; }
.sm-blog-post__category { color: inherit; text-decoration: none; }
.sm-blog-post__date { margin: 120px 0 0; padding-bottom: 20px; color: rgba(37, 37, 37, 0.7); font-size: 13px; line-height: 16px; }

/* 본문(원본 ImWeb 편집기 fr-view 기본값). 글 위젯 기본은 20px · 줄 간격 1.4 */
/* 원본 본문 칸은 위아래 22px, 그 안 글 상자는 위 16px 여백이다. 글 상자 여백은 첫 요소(예: h2 의 20px)와 겹쳐 큰 쪽만 남는다 */
.sm-blog-post__body { padding: 22px 0; font-size: 20px; line-height: 1.4; overflow-wrap: anywhere; }
.sm-blog-post__content { margin-top: 16px; }
.sm-blog-post__content::after { display: block; clear: both; content: ""; }
.sm-blog-post__body p { margin: 0; }
/* 제목 태그 기본(원본 실측): 큰 기본 글자 크기가 줄 높이를 정하고, 실제 글자 크기는 안의 span 이 정한다 */
.sm-blog-post__body :is(h1, h2, h3, h4, h5, h6) { margin: 20px 0 10px; font-weight: 400; line-height: 1.2; }
.sm-blog-post__body h1 { font-size: 80px; }
.sm-blog-post__body h2 { font-size: 64.28px; }
.sm-blog-post__body h3 { font-size: 51.42px; }
.sm-blog-post__body h4 { margin-top: 10px; font-size: 42.86px; }
.sm-blog-post__body h5 { margin-top: 10px; font-size: 34.28px; }
.sm-blog-post__body h6 { margin-top: 10px; font-size: 25.72px; line-height: 1.4; }
.sm-blog-post__body ol, .sm-blog-post__body ul { margin: 0 0 10px; padding-left: 40px; }
.sm-blog-post__body :is(ol, ul) :is(ol, ul) { margin-bottom: 0; }
.sm-blog-post__body a { color: #363636; text-decoration: none; }
.sm-blog-post__body a:hover { text-decoration: underline; }
.sm-blog-post__body blockquote { margin: 0 0 20px; padding: 10px 15px; border-left: 5px solid #ccc; }
.sm-blog-post__body hr { clear: both; height: 0; margin: 20px 0; border: 0; border-top: 1px solid #ddd; }
.sm-blog-post__body table { max-width: 100%; border-collapse: collapse; }
.sm-blog-post__body td, .sm-blog-post__body th { padding: 8px; border: 1px solid #ddd; }
.sm-blog-post__body table.noBorder td, .sm-blog-post__body table.noBorder th { border: 0; }
/* 편집기 이미지 정렬(ImWeb 의 Froala 설정 실측): dib 한 줄 차지(위아래 10px) · dii 글 사이(위아래 5px, 좌우 0)
   fic 는 dib 일 때만 가운데, fil·fir 는 dib 면 왼·오른쪽 붙임, dii 면 글을 감싸며 띄운다 */
.sm-blog-post__body img { max-width: 100%; height: auto; }
.sm-blog-post__body img.fr-dib { display: block; float: none; margin: 10px auto; }
.sm-blog-post__body img.fr-dib.fr-fil { margin-left: 0; }
.sm-blog-post__body img.fr-dib.fr-fir { margin-right: 0; }
.sm-blog-post__body img.fr-dii { display: inline-block; float: none; margin: 5px 0; vertical-align: bottom; }
.sm-blog-post__body img.fr-dii.fr-fil { float: left; max-width: calc(100% - 5px); margin: 5px 5px 5px 0; }
.sm-blog-post__body img.fr-dii.fr-fir { float: right; max-width: calc(100% - 5px); margin: 5px 0 5px 5px; }
/* 본문 안 단추 링크(원본 a.btn 실측. btn-primary 테두리는 원본 그대로 초록) */
.sm-blog-post__body a.btn { display: inline-block; padding: 10px 24px; border: 1px solid #ccc; border-radius: 6px; background: #fff; color: #333;
    font-size: 12px; line-height: 1.4286; text-decoration: none; }
.sm-blog-post__body a.btn-primary { border-color: rgb(0, 210, 85); background: rgb(0, 41, 95); color: #fff; }

/* 앞뒤 글 · 목록 단추 */
.sm-blog-post__neighbors { margin-top: 31px; border-top: 1px solid #eee; }
.sm-blog-post__neighbor { display: flex; align-items: center; gap: 10px; height: 40px; overflow: hidden; border-bottom: 1px solid #eee;
    color: #252525; font-size: 13px; text-decoration: none; white-space: nowrap; text-overflow: ellipsis; }
.sm-blog-post__neighbor:hover { text-decoration: underline; }
.sm-blog-post__arrow { flex: none; width: 7px; height: 7px; margin: 0 6px 0 4px; border-top: 1px solid #999; border-left: 1px solid #999; transform: rotate(45deg); }
.sm-blog-post__neighbor--older .sm-blog-post__arrow { margin-top: -4px; transform: rotate(-135deg); }
.sm-blog-post__list { display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; height: 30px; margin-top: 12px; padding: 0 24px;
    border-radius: 6px; background: rgb(0, 41, 95); color: #fff; font-size: 12px; text-decoration: none; }

/* 모바일(991px 이하) — 2026-11-12 원본을 375px 에서 잰 값 */
@media (max-width: 991px) {
    .sm-blog { padding: 15px 15px 96px; }
    /* 원본 모바일은 'BLOG' 머리말을 보이지 않는다(화면낭독기용으로만 남긴다) */
    .sm-blog__heading { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    /* 분류 탭: 가운데 정렬로 줄바꿈되는 글자 단추, 고른 것만 둥근 테두리 */
    .sm-blog__tabs { flex-wrap: wrap; justify-content: center; gap: 0 5px; width: auto; max-width: 310px; margin: 0 auto; border: 0; }
    .sm-blog__tab { width: auto; height: 26px; padding: 4px 15px; border: 1px solid transparent; border-radius: 50px; background: none;
        color: rgba(37, 37, 37, 0.7); font-size: 13px; }
    .sm-blog__tab + .sm-blog__tab { border-left: 1px solid transparent; }
    .sm-blog__tab.is-active { height: 28px; border-color: #252525; background: none; color: #252525; }
    .sm-blog__line { display: none; }
    .sm-blog__grid { grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 50px; }
    .sm-blog__pages { margin-top: 38px; }

    .sm-blog-post { padding: 35px 15px 90px; }
    /* 원본 모바일은 'blog' 머리말이 없고 제목이 왼쪽 정렬이다(글자 크기는 PC 와 같다) */
    .sm-blog-post__board { display: none; }
    .sm-blog-post__head { text-align: left; }
    /* 원본 모바일 제목 칸은 300px 이고 위 4px · 아래 15px 여백이 있다(같은 자리에서 줄이 바뀌게) */
    .sm-blog-post__title { max-width: 300px; margin: 0; padding: 4px 0 15px; }
    .sm-blog-post__date { margin-top: 41px; padding-bottom: 11px; font-size: 11px; line-height: 13px; }
    .sm-blog-post__body { padding: 20px 0; font-size: 15px; }
    .sm-blog-post__body h1 { font-size: 32px; }
    .sm-blog-post__body h2 { font-size: 28px; }
    .sm-blog-post__body h3 { font-size: 24px; }
    .sm-blog-post__body h4 { font-size: 20px; line-height: 1.5; }
    .sm-blog-post__body h5 { font-size: 18px; line-height: 1.5; }
    .sm-blog-post__body h6 { font-size: 16px; line-height: 1.4; }
    /* 원본 본문 일부는 줄바꿈 없는 글(white-space: pre)이라 모바일에서 화면 밖으로 잘린다(원본은 넘침을 숨겨 글이 잘려 보인다).
       공백은 그대로 두고 줄만 바꿔 글이 다 보이게 한다. 선택자는 정화기가 정리한 style 형식('white-space:pre;') 기준 */
    .sm-blog-post__content [style*="white-space:pre;"] { white-space: pre-wrap !important; }
    .sm-blog-post__neighbors { margin: 32px -15px 0; }
    .sm-blog-post__neighbor { height: 36px; padding: 0 15px; }
}
