@charset "UTF-8";

/* ==========================================================================
   1. 공통 기본 스타일 (Variables, Reset & Base)
   ========================================================================== */
:root {
    --primary-color: #0078FF; /* 로고 기반 블루 */
    --primary-dark: #0056b3;
    --text-main: #222222;
    --text-muted: #666666;
    --border-color: #e5e5e5;
    --bg-light: #f9f9f9;
    --font-family: -apple-system, BlinkMacSystemFont, "Malgun Gothic", "맑은 고딕", helvetica, "Apple SD Gothic Neo", sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    color: var(--text-main);
    line-height: 1.6;
    background-color: #ffffff;
    word-break: keep-all;
}

a {
    text-decoration: none;
    color: inherit;
}

a:hover {
    text-decoration: underline;
    color: var(--primary-color);
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* 중앙 정렬 컨테이너 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 이미지 플레이스홀더 (테스트용) */
.img-placeholder {
    background-color: #e0e0e0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 14.4px;
    text-align: center;
}

/* ==========================================================================
   2. 헤더 영역 (Header)
   ========================================================================== */
.site-header {
    border-bottom: 20px solid var(--primary-color);
    margin-bottom: 30px;
}

.header-top {
    background-color: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
    padding: 5px 0;
    font-size: 12.8px;
    color: var(--text-muted);
    text-align: right;
}

.header-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
}

.site-logo img {
    height: 50px;
}

.header-search {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.search-input {
    border: none;
    padding: 8px 12px;
    outline: none;
    width: 140px;
}

.search-button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 15px;
    cursor: pointer;
    font-weight: bold;
}

.main-navigation {
    /* background-color: white; */
    position: relative;
    margin: -85px auto 0;
    width: fit-content;
}

.nav-list {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.nav-list li a {
    display: block;
    padding: 25px 0;
    font-size: 16px;
    font-weight: bold;
}

.nav-list li a:hover {
    color: var(--primary-color);
    text-decoration: none;
}

/* ==========================================================================
   3. 메인 레이아웃 및 공통 컴포넌트
   ========================================================================== */
.main-layout {
    display: flex;
    gap: 40px;
    margin-bottom: 60px;
}

.main-content {
    flex: 1; /* 남은 공간 모두 차지 (약 70%) */
    min-width: 0; /* Flex 버그 방지 */
}

/* 버튼 컴포넌트 공통 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

/* ==========================================================================
   4. 우측 사이드바 영역 (Sidebar)
   ========================================================================== */
.aside.view-sidebar {
    width: 320px; /* 고정 넓이 (약 30%) */
    flex-shrink: 0;
}

.sidebar-section {
    margin-bottom: 30px;
    border: 1px solid var(--border-color);
    padding: 20px;
    background-color: var(--bg-light);
}

.sidebar-title {
    font-size: 19.2px;
    font-weight: bold;
    margin-bottom: 15px;
    border-bottom: 2px solid var(--text-main);
    padding-bottom: 5px;
}

.sidebar-list li {
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px dashed var(--border-color);
}

.sidebar-list li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-list a {
    font-size: 15.2px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ad-banner {
    background-color: #eee;
    text-align: center;
    padding: 50px 0;
    margin-bottom: 30px;
    color: #999;
    font-weight: bold;
}

/* ==========================================================================
   5. 푸터 영역 (Footer)
   ========================================================================== */
.site-footer {
    background-color: #222;
    color: #ccc;
    padding: 40px 0;
    font-size: 14.4px;
    margin-top: 60px;
}

.footer-nav {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #444;
}

.footer-nav a {
    color: #fff;
    font-weight: bold;
}

.footer-info {
    line-height: 1.8;
}

.footer-info span {
    display: inline-block;
    margin-right: 15px;
}

.copyright {
    margin-top: 20px;
    color: #888;
}

/* ==========================================================================
   6. 공통 반응형 분기점 (Responsive)
   ========================================================================== */
@media (max-width: 992px) {
    .main-layout {
        flex-direction: column;
    }
    .aside.view-sidebar {
        width: 100%;
    }
}

@media (max-width: 768px) {
    
     .main-navigation { margin-top: auto;  width:auto;
    }

    
    .header-main {
        flex-direction: column;
        gap: 15px;
    }
    .nav-list {
        flex-wrap: nowrap;
        gap: 20px;
        overflow-x: auto;
        justify-content: flex-start;
        -webkit-overflow-scrolling: touch; /* iOS 부드러운 스크롤 */
        -ms-overflow-style: none; /* IE and Edge 스크롤바 숨기기 */
        scrollbar-width: none; /* Firefox 스크롤바 숨기기 */
    }
    .nav-list::-webkit-scrollbar {
        display: none; /* Chrome, Safari, Opera 스크롤바 숨기기 */
    }
    .nav-list li {
        flex-shrink: 0; /* 스크롤 시 메뉴 아이템 크기 축소 방지 */
    }
    
        .nav-list li a {
        padding: 5px 0; }
    
    .search-input {
        width: 100%;
    }
    .footer-nav {
        flex-wrap: wrap;
    }
}


/* 메인 페이지 전용 스타일 */
    .news-section { margin-bottom: 50px; }
    .section-header {display: flex;justify-content: space-between;align-items: center;/* border-bottom: 2px solid var(--primary-color); *//* margin-bottom: 20px; */padding-bottom: 10px;}
    .section-title { font-size: 22.4px; font-weight: bold; color: var(--primary-color); }
    .section-more { font-size: 13.6px; color: var(--text-muted); }

    /* 주요 기사 */
    .hero-article { margin-bottom: 30px; }
    .hero-article .article-thumb { height: 400px; margin-bottom: 15px; }
    .hero-article .article-title { font-size: 28.8px; font-weight: bold; margin-bottom: 10px; }
    .hero-article .article-desc { font-size: 16px; color: var(--text-muted); }

    /* 일반 기사 그리드 */
    .article-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .news-card { display: flex; flex-direction: column; }
    .news-card .article-thumb { height: 180px; margin-bottom: 10px; }
    .news-card .article-title { font-size: 17.6px; font-weight: bold; margin-bottom: 5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .article-meta { font-size: 12.8px; color: #888; margin-top: 5px; }

    /* 이미지 공통 */
    .article-thumb img, .video-thumb img, .photo-card img, .scroll-card img { width: 100%; height: 100%; object-fit: cover; display: block; }

    /* 유튜브 섹션 */
    .youtube-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
    .youtube-card .video-thumb { height: 140px; background-color: #000; position: relative; margin-bottom: 10px; }
    .youtube-card .video-thumb::after { content: "▶"; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: white; font-size: 32px; opacity: 0.8; }

    /* 리스트형 기사 */
    .article-list-item { display: flex; gap: 15px; margin-bottom: 15px; padding-bottom: 15px; border-bottom: 1px solid var(--border-color); }
    .article-list-item .article-thumb { width: 150px; height: 100px; flex-shrink: 0; }
    .article-list-item .article-content { flex: 1; }

    /* 포토 뉴스 */
    .photo-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; }
    .photo-card { position: relative; overflow: hidden; border-radius: 4px; display: block; height: 220px; }
    .photo-card img { transition: transform 0.3s ease; }
    .photo-card:hover img { transform: scale(1.05); }
    .photo-overlay { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(0,0,0,0.85)); padding: 30px 15px 15px; color: white; }
    .photo-title { font-size: 17.6px; font-weight: bold; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

    /* 오피니언 */
    .opinion-list { display: flex; flex-direction: column; gap: 15px; }
    .opinion-item { display: flex; align-items: center; gap: 20px; padding: 20px; background: var(--bg-light); border: 1px solid var(--border-color); border-radius: 8px; transition: border-color 0.2s; }
    .opinion-item:hover { border-color: var(--primary-color); }
    .author-avatar { width: 70px; height: 70px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
    .author-name { font-size: 14.4px; color: var(--primary-color); font-weight: bold; margin-bottom: 5px; display: block; }
    .opinion-title { font-size: 19.2px; font-weight: bold; }
    .opinion-desc { font-size: 15.2px; color: var(--text-muted); margin-top: 5px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }

    /* 가로 스크롤 (라이프&트래블) */
    .scroll-grid { display: flex; gap: 20px; overflow-x: auto; padding-bottom: 15px; scroll-snap-type: x mandatory; }
    .scroll-grid::-webkit-scrollbar { height: 6px; }
    .scroll-grid::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 3px; }
    .scroll-card { flex: 0 0 220px; scroll-snap-align: start; }
    .scroll-card img { height: 150px; margin-bottom: 12px; border-radius: 8px; }

    /* 실시간 속보 */
    .breaking-list { border-top: 2px solid var(--text-main); }
    .breaking-list li { border-bottom: 1px solid var(--border-color); }
    .breaking-list a { display: flex; align-items: center; padding: 15px 10px; gap: 15px; transition: all 0.2s; }
    .breaking-list a:hover { background-color: var(--bg-light); padding-left: 20px; color: var(--primary-color); }
    .breaking-list .time { color: var(--primary-color); font-weight: bold; font-size: 15.2px; flex-shrink: 0; width: 50px; }

    @media (max-width: 992px) {
        .article-grid, .youtube-grid, .photo-grid { grid-template-columns: repeat(2, 1fr); }
    }
    @media (max-width: 768px) {
        .article-grid, .youtube-grid, .photo-grid { grid-template-columns: 1fr; }
        .article-list-item { flex-direction: column; }
        .article-list-item .article-thumb { width: 100%; height: 200px; }
        .scroll-card { flex: 0 0 80%; }
        .opinion-item { flex-direction: column; text-align: center; }
    }


    /* 리스트 페이지 전용 스타일 */
    .page-header { margin-bottom: 30px; padding-bottom: 15px; border-bottom: 2px solid var(--text-main); }
    .page-title { font-size: 28.8px; font-weight: bold; color: var(--primary-color); }
    .page-subtitle { font-size: 16px; color: var(--text-muted); margin-top: 5px; }

    .article-list { display: flex; flex-direction: column; gap: 25px; }
    .list-item { display: flex; gap: 20px; border-bottom: 1px solid var(--border-color); padding-bottom: 25px; }
    .list-item .thumb { width: 220px; height: 140px; flex-shrink: 0; border-radius: 4px; overflow: hidden; }
    .list-item .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
    .list-item:hover .thumb img { transform: scale(1.05); }
    .list-item .content { flex: 1; display: flex; flex-direction: column; justify-content: center; }
    .list-item .title { font-size: 20.8px; font-weight: bold; margin-bottom: 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .list-item .desc { font-size: 16px; color: var(--text-muted); margin-bottom: 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .list-item .meta { font-size: 13.6px; color: #888; display: flex; gap: 10px; align-items: center; }

    .pagination { display: flex; justify-content: center; align-items: center; gap: 5px; margin-top: 40px; }
    .page-link { padding: 8px 12px; border: 1px solid var(--border-color); color: var(--text-main); font-size: 14.4px; }
    .page-link:hover { background-color: var(--bg-light); text-decoration: none; }
    .page-link.active { background-color: var(--primary-color); color: white; border-color: var(--primary-color); font-weight: bold; }

    @media (max-width: 768px) {
        .list-item { flex-direction: column; }
        .list-item .thumb { width: 100%; height: 200px; }
    }



 /* 기사 뷰 전용 스타일 */
    .article-header { border-bottom: 1px solid var(--border-color); padding-bottom: 20px; margin-bottom: 30px; }
    .article-category { display: inline-block; color: white; background-color: var(--primary-color); padding: 4px 10px; font-size: 13.6px; font-weight: bold; margin-bottom: 15px; border-radius: 3px; }
    .article-header .article-title { font-size: 28.8px; font-weight: 900; line-height: 1.3; margin-bottom: 15px; color: #111; }

    .article-info { display: flex; justify-content: space-between; align-items: center; color: var(--text-muted); font-size: 15.2px; }
    .writer-info span { display: inline-block; margin-right: 15px; }

    .share-buttons { display: flex; gap: 10px; }
    .btn-share { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border-color); background: white; display: flex; justify-content: center; align-items: center; cursor: pointer; color: #333; font-weight: bold; }
    .btn-share:hover { background-color: var(--bg-light); border-color: var(--primary-color); }

    .article-body { font-size: 18.4px; line-height: 1.8; color: #333; letter-spacing: -0.08rem; }
    .article-body p { margin-bottom: 20px; }
    .article-figure { margin: 30px 0; text-align: center; }
    .article-figure img { display: inline-block; width: 100%; border-radius: 4px; }
    .article-caption { font-size: 14.4px; color: #888; margin-top: 10px; }

    .article-tags { margin-top: 50px; padding-top: 20px; border-top: 1px dashed var(--border-color); }
    .tag-item { display: inline-block; padding: 5px 12px; background-color: var(--bg-light); border: 1px solid var(--border-color); border-radius: 20px; font-size: 14.4px; margin-right: 8px; margin-bottom: 8px; color: #555; }
    .tag-item:hover { background-color: var(--primary-color); color: white; text-decoration: none; border-color: var(--primary-color); }

    @media (max-width: 768px) {
        .article-title{ font-size: 20px; line-height: 1.2; }
        .hero-article .article-title,
        .article-header .article-title { font-size: 25.6px; line-height: 1.2; }
        
        
         .article-body { font-size: 16px;}
        
        
        .article-info { flex-direction: column; align-items: flex-start; gap: 15px; }
    }

    /* 탭 UI 전용 스타일 */
    .page-header { text-align: center; margin-bottom: 40px; }
    .page-title { font-size: 32px; font-weight: bold; color: #111; }

    .tab-container { max-width: 900px; margin: 0 auto; }
    
    .tab-menu { display: flex; border-bottom: 2px solid var(--border-color); margin-bottom: 30px; flex-wrap: wrap; }
    .tab-button { flex: 1; min-width: 150px; padding: 15px 10px; background: none; border: none; font-size: 16.8px; font-weight: bold; color: var(--text-muted); cursor: pointer; position: relative; transition: color 0.2s; }
    .tab-button:hover { color: var(--primary-color); }
    .tab-button.active { color: var(--primary-color); }
    .tab-button.active::after { content: ''; position: absolute; bottom: -2px; left: 0; width: 100%; height: 3px; background-color: var(--primary-color); }

    .tab-content { display: none; padding: 20px; background: white; min-height: 400px; line-height: 1.8; font-size: 16.8px; }
    .tab-content.active { display: block; animation: fadeIn 0.3s ease; }
    @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

    .content-title { font-size: 24px; font-weight: bold; color: var(--primary-dark); margin-bottom: 20px; padding-bottom: 10px; border-bottom: 1px dashed var(--border-color); }
    .contact-box { background-color: var(--bg-light); border: 1px solid var(--border-color); padding: 30px; border-radius: 8px; margin-top: 20px; text-align: center; }
    .contact-email { display: block; font-size: 24px; font-weight: bold; color: var(--primary-color); margin: 15px 0; }
    
    @media (max-width: 768px) {
        /* 탭 메뉴 모바일 가로 스크롤 적용 */
        .tab-menu { flex-wrap: nowrap; overflow-x: auto; justify-content: flex-start; -webkit-overflow-scrolling: touch; -ms-overflow-style: none; scrollbar-width: none; border-bottom: 2px solid var(--border-color); }
        .tab-menu::-webkit-scrollbar { display: none; }
        .tab-button { flex: 0 0 auto; min-width: max-content; padding: 10px 10px; }
        
        
        .content-title{ font-size: 20px; }
        .contact-email{ font-size: 20px; }
        
        
    }