@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css");

/* [기본 변수 설정] */
:root {
    --primary-color: #2563eb;
    --text-color: #222222;
    --bg-color: #FFFFFF;
    --nav-height: 70px;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Pretendard', sans-serif; }
body { background-color: var(--bg-color); color: var(--text-color); padding-top: var(--nav-height); line-height: 1.6; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* [상단바 공통 디자인 - 메인/서브 완벽 일치] */
header {
    position: fixed; top: 0; left: 0; width: 100%; height: var(--nav-height);
    background: #FFFFFF; border-bottom: 1px solid #EEEEEE;
    z-index: 1000; display: flex; align-items: center;
}

.nav-container {
    width: 100%; 
    max-width: 1200px; /* ★이 숫자가 로고 위치를 결정합니다. 1200을 원하면 여기를 수정 */
    margin: 0 auto; 
    padding: 0 20px;
    display: flex; justify-content: space-between; align-items: center;
}


.logo a { 
    font-size: 22px; /* ★폰트 크기 22px로 통일 */
    font-weight: 800; 
    color: var(--primary-color); 
}

/* [네비게이션 메뉴 스타일] */
.nav-menu { display: flex; gap: 25px; }
.nav-menu li { position: relative; padding: 20px 0; }
.nav-menu li a { font-size: 15px; font-weight: 600; color: #555555; transition: 0.2s; }
.nav-menu li a:hover { color: var(--primary-color); }

/* [드롭다운 메뉴] */
.dropdown {
    position: absolute; top: 100%; left: 0; background: #FFFFFF;
    border: 1px solid #EEEEEE; min-width: 180px; display: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05); border-radius: 0 0 8px 8px;
}
.has-dropdown:hover .dropdown { display: block; }
.dropdown li { padding: 0; }
.dropdown li a { display: block; padding: 12px 20px; font-size: 14px; border-bottom: 1px solid #F9F9F9; }
.dropdown li a:hover { background: #F4F7FF; color: var(--primary-color); }

/* [메인 페이지 전용 스타일 유지] */
.hero-container { padding: 80px 20px; background: #F4F7FF; border-bottom: 1px solid #EEEEEE; }
.hero-content {
    max-width: 1100px; margin: 0 auto; display: flex;
    justify-content: space-between; align-items: center; gap: 40px;
}
.hero-text { flex: 1; }
.hero-text h1 { font-size: 46px; font-weight: 800; line-height: 1.3; margin-bottom: 20px; color: #111; }
.hero-text p { font-size: 20px; color: #555; margin-bottom: 30px; }
.btn { display: inline-block; padding: 15px 40px; border-radius: 50px; font-weight: 700; transition: all 0.3s; }
.btn-primary { background-color: var(--primary-color); color: white; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(37, 99, 235, 0.3); }

.hero-character { flex: 1; text-align: center; }
.floating-char { width: 400px; animation: float 3s ease-in-out infinite; }
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* 1. 인기 서비스 섹션 (기존: 흰색) */
.service-section {
    padding: 80px 20px;
    background-color: #FFFFFF; /* [이 부분을 원하는 색상으로 변경] */
}

/* 2. 행정 실무 서비스 섹션 (기존: #FAFAFA 연회색) */
.bg-light {
    background-color: #FAFAFA; /* [이 부분을 원하는 색상으로 변경] */
    border-top: 1px solid #EEEEEE;
}
.section-header { text-align: center; margin-bottom: 40px; }
.section-header h2 { font-size: 28px; font-weight: 800; margin-bottom: 10px; }
.section-header p { color: #666; }

.menu-container { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; max-width: 1200px; margin: 0 auto; }
.menu-card { background: #FFF; border-radius: 20px; border: 1px solid #EEEEEE; transition: 0.3s; position: relative; }
.menu-card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.05); border-color: #BFDBFE; }
.menu-card a { display: block; padding: 35px 30px; }

.badge { position: absolute; top: 20px; right: 20px; padding: 4px 12px; font-size: 12px; font-weight: 800; border-radius: 20px; }
.badge-hot { background: #FEE2E2; color: #EF4444; }
.badge-new { background: #DBEAFE; color: var(--primary-color); }
.badge-ready { background: #F3F4F6; color: #9CA3AF; }

.card-info h3 { font-size: 20px; font-weight: 700; margin-bottom: 8px; color: #111; }
.card-info p { font-size: 15px; color: #666; }
.disabled { opacity: 0.6; pointer-events: none; background: #F9FAFB; padding: 35px 30px; }

footer { text-align: center; padding: 40px 0; color: #AAAAAA; font-size: 14px; border-top: 1px solid #EEEEEE; }

@media (max-width: 768px) {
    .hero-content { flex-direction: column; text-align: center; }
    .floating-char { width: 250px; margin-top: 30px; }
}

/* [상단바 좌측 전략 메뉴 디자인 추가] */

/* 1. 좌측 그룹 (로고 + 전략메뉴) 정렬 */
.header-left-group {
    display: flex;
    align-items: center;
    gap: 15px; /* 로고와 메뉴 사이 간격 */
}

/* 2. 구분선 스타일 */
.divider {
    color: #E2E8F0; /* 아주 연한 회색 (시선 방해 금지) */
    font-size: 18px;
    font-weight: 300;
    margin-right: 5px; /* 구분선과 메뉴 글자 사이 간격 */
}

/* 3. 전략 메뉴 (소개, 정책달력) 텍스트 스타일 */
.strat-nav {
    display: flex;
    align-items: center;
    gap: 15px; /* 메뉴끼리의 간격 */
}

.strat-item {
    font-size: 15px; /* 로고(22px)보다 작게 설정하여 계층 구분 */
    font-weight: 600; /* 적당한 굵기 */
    color: #4B5563; /* 진한 회색 (검정보다 부드럽게) */
    text-decoration: none;
    transition: all 0.2s;
}

.strat-item:hover {
    color: var(--primary-color); /* 마우스 올리면 브랜드 색상(파랑)으로 변경 */
    transform: translateY(-1px); /* 살짝 떠오르는 효과 */
}

/* [모바일 방어 코드] 화면이 좁아지면 전략 메뉴 숨김 (레이아웃 깨짐 방지) */
@media (max-width: 768px) {
    .strat-nav {
        display: none;
    }
}

/* [수정] 듀얼 프로모션 섹션 - 텍스트 전용 버전 */
.promo-section {
    padding: 60px 20px;
    background-color: #FAFAFA;
    border-bottom: 1px solid #EEEEEE;
}

.promo-container {
    max-width: 1100px; /* hero-content와 정렬 통일 */
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.promo-card {
    text-decoration: none;
    background: #ffffff;
    border-radius: 20px;
    border: 1px solid #E2E8F0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center; /* 텍스트를 세로 중앙 정렬 */
}

/* 이미지 대신 텍스트 영역을 더 넓고 강조되게 설정 */
.promo-text {
    padding: 50px 40px; /* 여백을 늘려 카드 크기 확보 */
    width: 100%;
}

.badge-text {
    display: inline-block;
    color: var(--primary-color);
    font-size: 13px;
    font-weight: 800;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.promo-text h3 {
    font-size: 26px; /* 텍스트만 있으므로 크기를 키움 */
    font-weight: 800;
    color: #111827;
    margin-bottom: 12px;
}

.promo-text p {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}

.promo-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(37, 99, 235, 0.1);
    border-color: var(--primary-color);
}

/* 모바일 대응 */
@media (max-width: 768px) {
    .promo-container { grid-template-columns: 1fr; }
    .promo-text { padding: 40px 30px; }
}

/* [콘텐츠 페이지 전용 스타일 - 최종 정리본] */
.page-header { text-align: center; padding: 100px 20px 60px; background: #F4F7FF; }
.page-header h1 { font-size: 36px; font-weight: 800; margin-bottom: 10px; color: #111; }
.page-header p { color: #666; font-size: 18px; }

.content-section { padding: 80px 20px; background: #fff; }
.bg-light-gray { background: #F9FAFB; }
.section-container { max-width: 1200px; margin: 0 auto; }
.content-title { text-align: center; font-size: 32px; font-weight: 800; margin-bottom: 50px; color: #111; }

/* 그리드 설정: PC 5열 / 태블릿 3열 / 모바일 2열 */
.content-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr); 
    gap: 20px;
    margin-bottom: 50px;
}

.content-card {
    display: block;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #E5E7EB;
    transition: all 0.3s ease;
}
.content-card:hover { transform: translateY(-8px); box-shadow: 0 12px 24px rgba(0,0,0,0.08); border-color: var(--primary-color); }

/* 썸네일 비율 설정 */
.card-thumb { width: 100%; padding-top: 56.25%; position: relative; background-color: #f1f5f9; overflow: hidden; }
#section-blog .card-thumb { padding-top: 100%; } /* 블로그만 정사각형 */

.card-thumb img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }

/* 날짜 라벨 (사진 위 배치) */
.card-date-label {
    position: absolute; bottom: 8px; right: 8px;
    background: rgba(0, 0, 0, 0.6); color: #fff;
    padding: 3px 8px; border-radius: 4px;
    font-size: 11px; font-weight: 600; z-index: 10;
}

/* 기존 하단 박스 제거 */
.content-card .card-body { display: none; }

/* 버튼 및 반응형 대응 */
.load-more-container { text-align: center; }
.btn-load-more { padding: 15px 50px; background: #fff; border: 1px solid #ddd; border-radius: 50px; cursor: pointer; }

@media (max-width: 992px) { .content-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 480px) {
    .content-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 12px; }
    .page-header { padding: 60px 20px 40px; }
}

/* 유튜브 섹션 전용: 1줄 4열로 확장 및 시각적 안정화 */
#section-youtube .content-grid {
    grid-template-columns: repeat(4, 1fr);
}

/* 태블릿 및 모바일에서도 유튜브가 너무 작아지지 않게 방어 */
@media (max-width: 992px) {
    #section-youtube .content-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    #section-youtube .content-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px;
    }
}

/* [행정지식 섹션 최종 통합 디자인] */

/* 1. 상단 검색 영역 */
.knowledge-search-area { padding: 100px 20px 60px; text-align: center; background: #fff; }
.knowledge-search-area h1 { font-size: 32px; font-weight: 800; margin-bottom: 30px; color: #111; }
.search-box { max-width: 600px; margin: 0 auto; position: relative; }
.search-box input { 
    width: 100%; padding: 18px 30px; border-radius: 50px; 
    border: 1px solid #E2E8F0; background: #F8FAFC; font-size: 16px; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.03); outline: none; transition: 0.3s;
}
.search-box input:focus { border-color: var(--primary-color); background: #fff; }

/* 2. 카테고리 탭 */
.knowledge-tabs { display: flex; justify-content: center; gap: 10px; margin-bottom: 50px; flex-wrap: wrap; }
.tab-btn { 
    padding: 10px 22px; border-radius: 30px; border: 1px solid #E2E8F0; 
    background: #fff; font-weight: 600; font-size: 14px; color: #64748B; cursor: pointer; transition: 0.3s;
}
.tab-btn.active { background: var(--primary-color); color: #fff; border-color: var(--primary-color); }

/* 3. 지식 카드 그리드 (직사각형 텍스트 중심) */
.knowledge-grid { 
    display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); 
    gap: 25px; max-width: 1200px; margin: 0 auto 100px; padding: 0 20px;
}
.k-card { 
    background: #fff; border: 1px solid #E2E8F0; border-radius: 20px; 
    padding: 35px 30px; transition: 0.3s; height: 200px;
    display: flex; flex-direction: column; justify-content: center; text-decoration: none;
}
.k-card:hover { transform: translateY(-8px); box-shadow: 0 15px 30px rgba(37, 99, 235, 0.1); border-color: var(--primary-color); }
.k-date { font-size: 13px; color: #94A3B8; margin-bottom: 15px; display: block; }
.k-title { font-size: 20px; font-weight: 800; line-height: 1.4; color: #1E293B; }

/* 4. 상세 페이지 본문 스타일 */
.article-container { max-width: 800px; margin: 80px auto; padding: 0 20px; }
.kb-breadcrumb { color: var(--primary-color); font-weight: 800; margin-bottom: 10px; }
.kb-main-title { font-size: 36px; font-weight: 800; line-height: 1.3; margin-bottom: 20px; color: #111; }
.kb-body { font-size: 18px; line-height: 1.8; color: #334155; }
.kb-p { margin-bottom: 25px; }
.kb-h2 { font-size: 24px; font-weight: 800; margin: 50px 0 20px; color: #0F172A; }
.kb-image { margin: 40px 0; text-align: center; }
.kb-image img { max-width: 100%; border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.kb-quote { border-left: 5px solid var(--primary-color); padding: 20px 30px; background: #F8FAFC; margin: 40px 0; border-radius: 0 12px 12px 0; font-style: italic; }
