/* =============================================================
   m-blog-page 전용 스타일
   다른 페이지에 영향 없도록 .m-blog-page 스코프 내에서만 적용
   ============================================================= */

/* ─── CSS 변수 (블로그 전용) ─── */
.m-blog-page {
    --blog-primary: #3caaf5;
    --blog-text-main: #111827;
    --blog-text-muted: #4B5563;
    --blog-text-light: #9CA3AF;
    --blog-border: #E5E7EB;
    --blog-bg-gray: #f8fafa;
}

/* ─── 탭 메뉴 래퍼 ─── */
.m-blog-page .m-blog-tab-wrap {
    padding: 0 0 0 0;
}

/* ─── 탭 버튼 컨테이너: 가로 스크롤 ─── */
.m-blog-page .m-blog-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box; /* swiper-wrapper와 동일 */
    gap: 0;
    padding: 0; /* padding 제거 */
    /* 스크롤바 숨김 */
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.m-blog-page .m-blog-tabs::-webkit-scrollbar {
    display: none;
}

/* ─── 탭 버튼 개별 ─── */
.m-blog-page .m-blog-tab-btn {
    flex: 0 0 auto;
    display: block;
    height: 42px;
    padding: 1px 15px 0;
    font-size: 15px;
    font-weight: bold;
    color: #333;
    background: none;
    border: none;
    border-bottom: 2px solid #fff;
    line-height: 39px;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s;
    outline: none;
}

@media all and (orientation: landscape) {
    .m-blog-page .m-blog-tab-btn {
        height: 36px;
        line-height: 33px;
    }
}

.m-blog-page .m-blog-tab-btn.active {
    color: var(--blog-primary);
    font-weight: 700;
    border-bottom-color: var(--blog-primary);
}

.m-blog-page .m-blog-tab-btn:active {
    opacity: 0.7;
}

/* ─── 콘텐츠 영역 ─── */
.m-blog-page .m-blog-content {
    padding: 24px 20px 60px 20px;
}

/* ─── 검색 박스 ─── */
.m-blog-page .search-box {
    position: relative;
    margin-bottom: 32px;
    display: flex;
    gap: 8px;
}

.m-blog-page .search-box .input-wrap {
    position: relative;
    flex: 1;
}

.m-blog-page .search-box .input-wrap input {
    width: 100%;
    background-color: var(--blog-bg-gray);
    border: 1px solid var(--blog-border);
    border-radius: 8px;
    padding: 12px 16px 12px 44px;
    font-size: 14px;
    color: var(--blog-text-main);
    box-sizing: border-box;
}

.m-blog-page .search-box .input-wrap svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--blog-text-light);
    width: 18px;
    height: 18px;
}

.m-blog-page .search-box .btn-search {
    flex-shrink: 0;
    padding: 0 16px;
    background-color: var(--blog-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

/* ─── Featured Post ─── */
.m-blog-page .featured-card {
    margin-bottom: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--blog-border);
}

.m-blog-page .featured-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
    background: #eee;
}

.m-blog-page .featured-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.m-blog-page .post-badge {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    color: var(--blog-primary);
    margin-bottom: 8px;
}

.m-blog-page .featured-title {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 12px;
    color: var(--blog-text-main);
}



.m-blog-page .post-meta {
    font-size: 12px;
    color: var(--blog-text-light);
    font-weight: 500;
}

/* ─── Blog List ─── */
.m-blog-page .blog-list {
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin-bottom: 48px;
}

.m-blog-page .list-card {
    display: flex;
    flex-direction: column;
}

.m-blog-page .list-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 12px;
    background: #eee;
}

.m-blog-page .list-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.m-blog-page .list-title {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 8px;
    color: var(--blog-text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ─── Pagination ─── */
.m-blog-page .m-blog-pagination {
    display: flex;
    justify-content: center;
    gap: 4px;
}

.m-blog-page .m-blog-pagination .page-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 500;
    color: var(--blog-text-muted);
    border-radius: 4px;
    border: 1px solid transparent;
    cursor: pointer;
    background: none;
}

.m-blog-page .m-blog-pagination .page-btn.active {
    border-color: var(--blog-border);
    color: var(--blog-text-main);
    font-weight: 700;
}
