/*
Theme Name: 나의 첫 테마
Author: (이름)
Description: 나만의 모던 매거진 테마
Version: 1.31 (Final Merged Master - Hamburger Menu)
*/

/* =================================================================
   1. 기본 레이아웃 및 타이포그래피
   ================================================================= */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    line-height: 1.9;
    background: #f9f9f9;
    color: #333;
    margin: 0;
    padding: 0;
    overflow-x: hidden; 
}
/* 모바일 메뉴가 열렸을 때 스크롤 방지 */
body.mobile-menu-open {
    overflow: hidden;
}

.container {
    max-width: 1200px; 
    margin: 30px auto;
    padding: 0 20px;
    box-sizing: border-box;
}
.header-container, .footer-container, .landing-hero {
    max-width: 1200px; 
    margin-left: auto;
    margin-right: auto;
}

a { color: #00aaff; } 
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

.card-thumbnail, .post-thumbnail a { display: none; } 
.screen-reader-text { display: none; } /* 접근성을 위한 텍스트 숨기기 */


/* =================================================================
   2. 헤더 및 메뉴 디자인
   ================================================================= */
.site-header {
background: #ffa32b;
border-bottom: 0px solid rgba(0,0,0,0.1);
padding: 0px 0;
margin-bottom: 0px; /* 랜딩 이미지와 딱 붙임 */
position: sticky;
top: 0;
z-index: 1000; 
}
.header-container {
max-width: 1200px;
margin: 0 auto;
padding: 0 14px;
display: flex;
justify-content: space-between; 
align-items: center;
gap: 20px; 
flex-wrap: nowrap; 
}
/* h1 태그 대신 .site-title-heading 클래스를 가리키도록 수정 */
.site-branding .site-title-heading {
    margin: 0;
    font-size: 30px;
    font-weight: 600;
} /* <-- 여기에 닫는 괄호 } 가 추가되었습니다. */

.site-branding .site-title-heading a {
    font-family: sans-serif; 
    font-weight: 600; /* 굵기 강조 */
    font-size: 28px; /* 크기는 적절히 조정하세요 */

    /* 2. 색상 설정 */
    color: #ffffff;
    


    /* 4. 기존 속성 수정 및 유지 */
    text-decoration: none; 
    white-space: nowrap;
}

/* --- 데스크탑 드롭다운 메뉴 스타일 --- */
.main-navigation.desktop-menu { display: flex; }
/* .main-navigation.mobile-menu { display: none; } /* 모바일 메뉴는 평소에 숨김 */
nav.main-navigation { position: relative; } 
nav.main-navigation ul { margin: 0; padding: 0; list-style: none; }

#primary-menu {
    display: flex;
    gap: 20px;
    justify-content: center;
    align-items: center;
    flex-wrap: nowrap;
}
#primary-menu > li {
    display: inline-block;
    position: relative;
    padding: 15px 0; 
    font-size: 16px;
    font-weight: bold;
    color: #8101fa;
    transition: background-color 0.3s ease;
}
#primary-menu > li:hover {
    background-color: rgba(255, 255, 255, 0.1);
    cursor: pointer;
}
#primary-menu > li > a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    padding: 15px 10px; 
    transition: color 0.2s ease;
}
#primary-menu > li > a:hover {
    color: #fff8e1;
}
ul.sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fcfcfc;
    min-width: 200px;
    box-shadow: 0px 6px 15px rgba(0, 0, 0, 0.15);
    border-top: 3px solid #FF772B;
    padding: 0;
    border-radius: 0 0 5px 5px;
    z-index: 1001; 
}
#primary-menu > li.menu-item-has-children:hover > ul.sub-menu {
    display: block;
}
ul.sub-menu li {
    display: block;
    position: relative;
    width: 100%;
    padding: 0;
    border-bottom: 1px solid #eee;
}
ul.sub-menu li:last-child { border-bottom: none; }
ul.sub-menu li a {
    display: block;
    padding: 12px 18px;
    color: #333 !important; 
    font-size: 15px;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease;
}
ul.sub-menu li a:hover {
    background-color: #3a89ff;
    color: #fff !important; 
}
ul.sub-menu ul.sub-menu {
    top: -3px;
    left: 100%;
    border-radius: 5px;
}
ul.sub-menu li.menu-item-has-children:hover > ul.sub-menu {
    display: block;
}
#primary-menu > li.menu-item-has-children > a {
    position: relative;
    padding-right: 25px; 
}
#primary-menu > li.menu-item-has-children > a::after {
    content: '▼';
    position: absolute;
    right: 10px; 
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.7);
}
ul.sub-menu li.menu-item-has-children > a {
    position: relative;
    padding-right: 25px;
}
ul.sub-menu li.menu-item-has-children > a::after {
    content: '▶';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: #aaa;
    transition: color 0.2s ease;
}
ul.sub-menu li.menu-item-has-children:hover > a::after {
    color: #fff;
}


/* 데스크탑 검색창 (기본 보임) */
.header-search-form.desktop-search { display: block; }
.header-search-form form { display: flex; align-items: center; }
.header-search-form input[type="search"] {
    font-size: 13px; height: 28px; border: 1px solid #ddd;
    border-radius: 4px; padding: 0 6px;
    width: 150px; 
}
.header-search-form input[type="submit"] {
    height: 28px; font-size: 13px; margin-left: 4px;
}

/* 모바일 햄버거 버튼 (평소에 숨김) */
.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
}

/* =================================================================
   2-1. 모바일 메뉴 (전체 화면)
   ================================================================= */
.mobile-menu-container {
    display: none; /* 평소에 숨김 */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh; /* 화면 전체 높이 */
    background: #00aaff;
    z-index: 999; /* 헤더 바로 아래 */
    overflow-y: auto;
    padding-top: 80px; /* 헤더 높이만큼 여백 */
    box-sizing: border-box;
}
.mobile-menu-container.toggled {
    display: block; /* JS로 'toggled' 클래스 추가 시 보임 */
}
.mobile-menu ul {
    display: block;
    text-align: center;
}
.mobile-menu ul li {
    display: block;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}
.mobile-menu ul li a {
    display: block;
    padding: 20px;
    font-size: 1.2rem;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
}
.mobile-menu ul li a:hover {
    background: rgba(255,255,255,0.1);
}
/* 모바일 하위 메뉴 스타일 */
.mobile-menu ul.sub-menu {
    display: none; /* 평소에 숨김 */
    background: rgba(0,0,0,0.1);
    font-size: 0.9em;
}
.mobile-menu .menu-item-has-children.submenu-open > ul.sub-menu {
    display: block; /* JS로 'submenu-open' 클래스 추가 시 보임 */
}
.mobile-menu ul.sub-menu li a {
    padding: 15px 20px;
    font-size: 1rem;
}
/* 모바일 하위 메뉴 화살표 */
.mobile-menu .menu-item-has-children > a {
    position: relative;
}
.mobile-menu .menu-item-has-children > a::after {
    content: '▼';
    font-size: 10px;
    margin-left: 10px;
    display: inline-block;
    transition: transform 0.3s ease;
}
.mobile-menu .menu-item-has-children.submenu-open > a::after {
    transform: rotate(180deg);
}

/* 모바일 메뉴 안의 검색창 */
.mobile-search-form {
    padding: 30px 20px;
}
.mobile-search-form .search-form {
    display: flex;
    max-width: 400px;
    margin: 0 auto;
}
.mobile-search-form .search-field {
    flex: 1;
    height: 40px;
    padding: 8px 12px;
    border: 1px solid #fff;
    border-radius: 4px 0 0 4px;
    font-size: 1rem;
    background: #fff;
    color: #333;
}
.mobile-search-form .search-submit {
    height: 40px;
    background: #fff;
    color: #f97316;
    border: 1px solid #fff;
    padding: 8px 12px;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
}


/* =================================================================
   2-2. 모바일 헤더 반응형 (768px 이하)
   ================================================================= */
@media (max-width: 768px) {
    .header-container {
        flex-wrap: nowrap; 
        gap: 10px;
    }
    .site-branding h1 { font-size: 10px; }

    /* 데스크탑 메뉴와 검색창 숨기기 */
    .main-navigation.desktop-menu { display: none !important; }
    .header-search-form.desktop-search { display: none !important; }

    /* 모바일 햄버거 버튼 보이기 */
    .mobile-menu-toggle {
        display: block;
    }
}
/* =================================================================
   2-2. [추가] 2단계 카테고리 메뉴 오버레이 스타일
   ================================================================= */
.category-step2-overlay {
    /* 1단계 메뉴와 동일하게 전체 화면을 덮습니다. */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #00aaff; 
    z-index: 1001; 
    overflow-y: auto;
    box-sizing: border-box;
    padding-top: 60px; /* 헤더와 뒤로가기 버튼 공간 */
    
    /* 기본적으로 화면 상단 밖으로 숨김 */
    transform: translateY(-100%);
    transition: transform 0.4s ease-in-out; 
}

/* JS로 'is-active' 클래스 추가 시 화면에 표시 */
.category-step2-overlay.is-active {
    transform: translateY(0);
}

.category-overlay-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 10px 20px;
    background: #ff8c00; 
    color: #fff;
    z-index: 1020;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.category-overlay-header .back-btn {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 500;
    cursor: pointer;
    padding: 5px 10px;
}
.category-overlay-header .back-btn .icon-arrow-left {
    margin-right: 5px;
}

/* 2단계 메뉴 목록 스타일 */
.category-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}
.category-menu ul li {
    display: block;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}
.category-menu ul li a {
    display: block;
    padding: 15px 20px;
    font-size: 1.1rem;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
}
.category-menu ul li a:hover {
    background: rgba(255,255,255,0.1);
}

/* =================================================================
   3. 랜딩 이미지 (Hero) 섹션 (LCP 개선 적용)
   ================================================================= */
.landing-hero {
    background: none !important; /* 빈 ruleset 방지 + LCP 영향 최소화 */
}

/* =================================================================
   4. 카드 그리드 레이아웃 (색상 통일 및 호버 적용)
   ================================================================= */
.main-content-area {
  margin-top: 0;
  margin-bottom: 30px;
}

.card-grid-section {
  margin-top: 20px;
  position: relative;
  z-index: 20;
}

/* 1. 간격 수정 (15px -> 25px) */
.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px; /* 시원하게 간격 늘림 */
  margin-bottom: 15px;
}

/* 2. 카드 디자인 수정 (파랑 -> 흰색 + 퍼플톤) */
.card-item {
  border: 1px solid #e0e0e0; /* 옅은 회색 테두리 */
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06); /* 옅은 그림자 */
  transition: all 0.3s ease;
  display: flex;
  background-color: #ffffff !important; /* 흰색 배경 */
  overflow: hidden;
  min-height: 180px;
  position: relative;
  flex-direction: column;
  isolation: isolate; /* 오버레이가 카드 내부에서만 보이도록 */
}

/* 파스텔 퍼플 오버레이 (기본: 투명, 호버: 서서히 보임) */
.card-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(171, 146, 255, 0.12) 0%,
    rgba(239, 234, 255, 0.35) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 0; /* 콘텐츠 아래, 배경 위 */
}

.card-thumbnail img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  display: block;
  transition: transform 0.4s ease; /* 호버 시 살짝 확대 */
}

.card-link {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 0;
  text-decoration: none;
  color: #555; /* 3. 텍스트 색상 변경 (어두운색) */
  width: 100%;
  height: 100%;
}

/* 4. 기존 호버 스타일 제거 (새 스타일로 대체) */
.card-link:hover {
  text-decoration: none;
}

.card-icon {
  background-color: #fff;
  color: #8a6eff; /* 퍼플 포인트 컬러 */
  display: flex;
  justify-content: center;
  align-items: center;
  height: 70px;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
}

.icon-placeholder {
  font-size: 3rem;
  font-weight: 300;
}

.card-content {
  padding: 15px 15px 5px 15px !important;
  text-align: left;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 10px 0;
  line-height: 1.4;
  color: #111; /* 기본 검은색 */
  transition: color 0.3s ease;
}

.card-excerpt {
  font-size: 0.9rem;
  color: #555; /* 본문 회색 */
  line-height: 1.5;
  margin-bottom: 0;
  flex-grow: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  line-clamp: 5;
  -webkit-box-orient: vertical;
}

.card-cta {
  display: none !important;
}

.card-content > :last-child {
  margin-bottom: 0;
}

.cta-arrow {
  color: #8a6eff; /* 퍼플 포인트 컬러 */
  font-size: 1.5rem;
  font-weight: 700;
  transition: transform 0.3s ease;
}

/* 4. 새 호버 효과 (퍼플톤) */
.card-item:hover {
  background-color: #ffffff !important; /* 호버 시에도 흰색 유지 */
  border-color: #c1adff !important; /* 테두리 파스텔 퍼플 */
  transform: translateY(-5px); /* 살짝 떠오르는 효과 */
  box-shadow:
    0 10px 20px rgba(138, 110, 255, 0.22),
    0 3px 8px rgba(0, 0, 0, 0.08); /* 퍼플톤 강조 그림자 */
}
.card-item:hover::before {
  opacity: 1; /* 파스텔 퍼플 그라데이션 오버레이 표시 */
}
.card-item:hover .card-thumbnail img {
  transform: scale(1.03);
}

/* (아이콘 호버는 퍼플톤 유지) */
.card-item:hover .card-icon {
  background-color: #fff !important;
  color: #8a6eff !important;
}

/* 4. 새 호버 텍스트 효과 */
.card-item:hover .card-title {
  color: #8a6eff !important; /* 제목만 퍼플 */
}

.card-item:hover .card-excerpt,
.card-item:hover .card-meta,
.card-item:hover .card-link {
  color: #555 !important; /* 본문은 그대로 회색 */
}

.card-item:hover .cta-arrow {
  color: #8a6eff !important; /* 화살표 퍼플 */
}

/* =================================================================
   4-1. [수정] 고정 글 (Sticky Post) 스타일 (데스크톱)
   ================================================================= */

/* 카드 자체는 그리드 전폭 사용 (컬럼 수 변해도 안전) */
.card-grid .card-item.sticky {
  grid-column: 1 / -1; /* 1 / span 4 대신 -1로 전폭 */
  display: block;       /* 부모 flex 영향 제거 */
  min-height: 0;
}

/* 앵커를 가로 플렉스 컨테이너로 전환해 썸네일/내용을 좌우 배치 */
.card-grid .card-item.sticky .card-link {
  display: flex;
  flex-direction: row;
  align-items: stretch; /* 썸네일과 본문 높이 일치 */
  width: 100%;
  height: 100%;
  gap: 0;               /* 필요하면 16px 등으로 조정 */
}

/* 고정 글 썸네일 */
.card-item.sticky .card-thumbnail {
  width: 40%;
  height: 250px;
  flex: 0 0 40%;
  overflow: hidden;            /* 이미지 넘침 방지 */
  border-radius: 8px 0 0 8px;
}

.card-item.sticky .card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px 0 0 8px;
}

/* 고정 글 콘텐츠 */
.card-item.sticky .card-content {
  width: 60%;
  flex: 1 1 60%;
  min-width: 0;                /* 긴 제목/요약 줄바꿈 허용 (flex overflow fix) */
  padding: 20px 30px !important;
}

.card-item.sticky .card-title {
  font-size: 1.5rem;
}

.card-item.sticky .card-excerpt {
  -webkit-line-clamp: 3;
  line-clamp: 3;
  font-size: 1rem;
}

/* 반응형: 좁은 화면에서는 세로 스택 */
@media (max-width: 900px) {
  .card-grid .card-item.sticky .card-link {
    flex-direction: column;
  }
  .card-item.sticky .card-thumbnail {
    width: 100%;
    height: 200px;
    flex-basis: auto;
    border-radius: 8px 8px 0 0;
  }
  .card-item.sticky .card-thumbnail img {
    border-radius: 8px 8px 0 0;
  }
  .card-item.sticky .card-content {
    width: 100%;
    padding: 16px 18px !important;
  }
}

/* =================================================================
   5. 페이지네이션 (Pagination) 스타일 
   ================================================================= */
.pagination-container { margin-top: 40px; text-align: center; }
.pagination-container .nav-links { display: inline-flex; gap: 5px; }
.pagination-container .page-numbers { display: inline-block; padding: 8px 12px; border: 1px solid #ddd; border-radius: 4px; background: #fff; color: #555; text-decoration: none; transition: all 0.3s ease; }
.pagination-container .page-numbers:hover { background: #f0f0f0; color: #333; }
.pagination-container .page-numbers.current { background: #00aaff; color: #fff; border-color: #00aaff; font-weight: bold; } 
.pagination-container .prev, .pagination-container .next { padding: 8px 10px; }
.pagination-container .dots { padding: 8px 0; border: none; background: none; }


/* =================================================================
   6. 푸터 (Footer) 디자인 
   ================================================================= */
.site-footer {
    background-color: #ffffff;
    color: #555;
    padding: 15px 0;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-top: 40px;
    border-top: 1px solid #eee;
}
.footer-container {
    padding: 0 20px;
    text-align: center;
}
.footer-navigation ul { margin: 0 0 15px 0; padding: 0; list-style: none; display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }
.footer-navigation a { color: #555; text-decoration: none; transition: color 0.3s ease; }
.footer-navigation a:hover { color: #00aaff; text-decoration: underline; } 
.copyright-text { margin: 0; color: #888; }


/* =================================================================
   7. 본문 콘텐츠 기본 스타일 
   ================================================================= */
.entry-content, .page-content {
    line-height: 1.9;
    font-size: 1.1rem;
    color: #333;
}
.entry-content h2, .page-content h2 {
    font-size: 24px;
    margin-top: 35px;
    margin-bottom: 30px;
    padding-bottom: 2px;
    border-bottom: 2px solid #00aaff;
    font-weight: 700;
    color: #00aaff; 
}
.entry-content h3, .page-content h3 {
    font-size: 19px;
    margin-top: 30px;
    margin-bottom: 12px;
    color: #cc3333; 
}
.entry-content p, .page-content p {
    margin-bottom: 1.5rem;
}
.entry-content ul, .page-content ul { list-style-type: disc; }
.entry-content ul, .entry-content ol,
.page-content ul, .page-content ol { 
    line-height: 1.9; 
    margin-bottom: 1.5rem; 
    padding-left: 20px; 
}
.entry-content blockquote {
    border-left: 4px solid #00aaff;
    padding: 10px 20px;
    margin: 20px 0;
    font-style: italic;
    background: #f7f7f7;
}

/* ================================================================
   8. TABLE (표) 반응형 (오렌지 테마)
   ================================================================ */
.table-wrap {
    width: 100%;
    max-width: 900px; 
    margin: 24px auto;
    overflow-x: auto; 
    -webkit-overflow-scrolling: touch;
    border-radius: 6px;
}
.table-wrap table {
    width: 100%;
    border-collapse: collapse;
    min-width: 720px; 
    text-align: center;
    font-size: 15px;
    line-height: 1.6;
    border: 1px solid #000;
    background-color: #fff;
}
.table-wrap th,
.table-wrap td {
    border: 0.5px solid #000;
    padding: 12px 10px;
    white-space: normal; 
    word-break: keep-all;
}
.table-wrap thead th {
    background-color: #ff7a00; 
    color: #fff;
    font-weight: bold;
}
.table-wrap tbody tr:nth-child(even) {
    background-color: #fff7ed; 
}
.table-wrap tbody tr:hover {
    background-color: #ffe2bf;
    transition: background-color 0.25s ease;
}
@media (max-width: 900px) {
    .table-wrap { max-width: 100%; }
    .table-wrap table { width: max-content; min-width: 600px; font-size: 14px; }
}
@media (max-width: 600px) {
    .table-wrap table { min-width: 520px; font-size: 13px; }
}


/* =================================================================
   9. [워드프레스용] 전문 콘텐츠 스타일 (Highlight Box, Process Grid 등)
   ================================================================= */
.article-card, .article-process, .article-tab-link {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border-radius: 12px;
    box-sizing: border-box;
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}
.article-card:hover, .article-process:hover, .article-tab-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}
.article-tab-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    /* 크기 UP */
    padding: 14px 28px !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    border-radius: 999px !important;

    /* 오렌지 컨셉 */
    background: linear-gradient(135deg, #f97316, #fb923c) !important;
    color: #ffffff !important;
    border: none !important;

    /* 클릭 유도력 증가 */
    box-shadow: 0 10px 22px rgba(249, 115, 22, 0.45) !important;
    text-decoration: none !important;

    transition: transform 0.25s ease, box-shadow 0.25s ease !important;
}

/* Hover */
.article-tab-link:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 14px 28px rgba(249, 115, 22, 0.55) !important;
}

/* Active (눌렀을 때) */
.article-tab-link:active {
    transform: scale(0.97);
    box-shadow: 0 6px 14px rgba(249, 115, 22, 0.35) !important;
}

/* 모바일에서 더 버튼처럼 */
@media (max-width: 600px) {
    .article-tab-link {
        width: 100% !important;
        max-width: 360px !important;
        margin: 0 auto !important;
        font-size: 18px !important;
        padding: 16px 30px !important;
    }
}

.article-highlight {
    background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
    border: 2px solid #0ea5e9;
    padding: 28px;
    margin: 32px 0;
    position: relative;
    border-radius: 16px;
    color: #0f172a;
    line-height: 1.7;
}
.article-highlight::before {
    content: "💡";
    position: absolute;
    top: -15px;
    left: 24px;
    background: #0ea5e9;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
}
.article-highlight h3 {
    color: #0c4a6e;
    margin: 0 0 16px 0;
    font-size: 1.3em;
    font-weight: bold;
}
.article-highlight p {
    color: #0f172a;
    margin: 0;
}
.entry-content .article-process-grid,
.wp-block-group .article-process-grid,
.article-process-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
    gap: 24px !important;
    margin: 32px auto !important;
    max-width: 1100px !important;
    width: 100% !important;
    justify-content: center !important;
}
.article-process-grid > * {
    grid-column: auto !important;
    width: auto !important;
    margin: 0 !important;
}
.article-process {
    position: relative !important;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 28px;
    text-align: center;
    background: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.article-process h4 {
    color: #1e40af;
    margin: 12px 0 16px 0;
    font-size: 1.1em;
    font-weight: bold;
}
.article-process-step::before {
    content: attr(data-step);
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}
@media (max-width: 1024px) {
    .article-process-grid {
        grid-template-columns: repeat(2, minmax(240px, 1fr)) !important;
    }
}
@media (max-width: 600px) {
    .article-process-grid {
        grid-template-columns: 1fr !important;
    }
}

/* =================================================================
   10. 아카이브 페이지 헤더 
   ================================================================= */
.archive-header {
    margin-bottom: 40px;
    padding: 20px 0;
    border-bottom: 2px solid #eee;
}
.archive-title {
    font-size: 2.2rem;
    color: #111;
    margin: 0;
    font-weight: 700;
}
.archive-description {
    font-size: 1.1rem;
    color: #555;
    margin-top: 10px;
}


/* =================================================================
   11. 반응형 디자인 (4열 레이아웃 최적화)
   ================================================================= */
@media (max-width: 992px) { 
    .container, .header-container, .footer-container {
        padding-left: 15px;
        padding-right: 15px;
        border-radius: 0 !important; 
        box-shadow: none !important; 
    }
    .card-grid-section {
        margin-top: 0; 
    }
    .card-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    .hero-title {
        font-size: 2rem;
    }
    .card-item {
        min-height: 350px; 
    }
    .card-title { font-size: 1rem; }
}

/* ★★★ (통합) 모바일 크기: 2열 -> 1열 ★★★ */
@media (max-width: 600px) {
    .card-grid-section {
        margin-top: 0; 
    }
    .card-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    .container, .header-container, .footer-container {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    /* ★★★ (통합) 모바일 랜딩 이미지 잘림 현상 수정 (contain) ★★★ */
    .landing-hero { 
        background-size: contain !important;
        background-repeat: no-repeat !important;
        min-height: 150px !important;
        /* (선택) 이미지 배경과 유사한 색상 */
        background-color: #f9f9f9; 
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    .card-item {
        min-height: 300px;
    }
    .card-content { padding: 15px; }
    .card-title { font-size: 0.95rem; }
    .card-excerpt { font-size: 0.8rem; -webkit-line-clamp: 5; line-clamp: 5;}
}
/* =================================================================
   11-1. [추가] 랜딩 히어로 모바일 꽉 채우기 (Full-Bleed)
   ================================================================= */
@media (max-width: 992px) {
.landing-hero {
/* .container의 좌우 패딩 15px를 무시하고 늘림 */
width: calc(100% + 30px);
margin-left: -15px;
margin-right: -15px;

/* 기존 속성 유지 */
border-radius: 0 !important; 
box-shadow: none !important; 
}
}

@media (max-width: 600px) {
.landing-hero {
/* .container의 좌우 패딩 10px를 무시하고 늘림 */
width: calc(100% + 20px);
margin-left: -10px;
margin-right: -10px;
}
}
/* =================================================================
   12. 검색 및 아카이브 페이지 스타일 오버라이드
   ================================================================= */
body.archive .card-item,
body.search .card-item {
    background-color: #ffffff !important; 
    border-color: #e0e0e0 !important; 
}
body.archive .card-title,
body.search .card-title {
    color: #111 !important;
}
body.archive .card-excerpt,
body.search .card-excerpt {
    color: #555 !important;
}
body.archive .card-icon,
body.search .card-icon {
    background-color: #ffffff !important;
    color: #ff9900 !important;
}
body.archive .cta-arrow,
body.search .cta-arrow {
    color: #ff9900 !important;
}
body.archive .card-item:hover,
body.search .card-item:hover {
    background-color: #ff9900 !important;
    border-color: #ff9900 !important;
}
body.archive .card-item:hover .card-title,
body.search .card-item:hover .card-excerpt {
    color: #fff !important;
}
body.archive .card-item:hover .card-icon {
    background-color: #fff !important;
    color: #111 !important; 
}
.entry-content,
.page-content {
    max-width: 900px;
    margin: 0 auto; 
}
.single .container {
    max-width: 900px;
    margin: 0 auto;
}
/* =================================================================
   13. 관련 글 (Related Posts) 스타일 (v2.0 - 썸네일 3열)
   ================================================================= */

.related-posts-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #eee;
}

/* 1. 요청하신 H2 제목 스타일 (파란색 + 밑줄) */
.related-posts-title {
    font-size: 24px;
    font-weight: 700;
    color: #00aaff; /* 파란색 */
    margin: 0;      /* 상하 여백 제거 */
    padding-bottom: 2px; /* 밑줄과의 간격 */
    border-bottom: 2px solid #00aaff; /* 밑줄 */
    display: inline-block; /* 내용만큼만 밑줄이 그어지도록 */
}

/* 2. 그리드 3열로 변경 및 제목과의 간격 */
.related-posts-grid {
    grid-template-columns: repeat(3, 1fr); /* 3열로 변경 */
    margin-top: 20px; /* 제목과 그리드 사이 여백 */
}

/* 3. 썸네일 카드 스타일 오버라이드 (주황색 박스 제거) */
.related-posts-grid .card-item {
    min-height: 0; /* 최소 높이 제거 */
    background-color: transparent !important; /* 배경 제거 */
    border: none !important; /* 테두리 제거 */
    box-shadow: 0 4px 10px rgba(0,0,0,0.08); /* 그림자 */
    border-radius: 8px;
    overflow: hidden; /* 둥근 모서리 */
}
.related-posts-grid .card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}
.related-posts-grid .card-link {
    padding: 0; /* 내부 여백 제거 */
}

/* 4. 썸네일 이미지 비율 유지 스타일 */
.related-posts-grid .card-item img {
    width: 100%; /* 너비 100% */
    height: auto;  /* 높이 자동 (비율 유지) */
    display: block;
    transition: transform 0.3s ease;
}
.related-posts-grid .card-item:hover img {
    transform: scale(1.05); /* 호버 시 이미지 확대 */
}

/* 5. 썸네일 없을 때 대체 스타일 */
.related-no-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #f0f0f0;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    border-radius: 8px;
}

/* 6. 반응형 수정 (태블릿 2열, 모바일 1열) */
@media (max-width: 992px) { /* 메인 그리드와 동일하게 992px로 변경 */
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 600px) {
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
}

/* =================================================================
   14. (통합) WiseHub 시리즈 박스 스타일
   ================================================================= */
.wisehub-series-box {
    background-color: #f9f9f9; 
    border: 1px solid #e0e0e0; 
    border-left: 5px solid #0073aa; 
    border-radius: 8px; 
    padding: 20px 24px;
    margin: 30px 0; 
    box-shadow: 0 2px 4px rgba(0,0,0,0.03);
}
.wisehub-series-box h3 {
    font-size: 1.3em; 
    font-weight: 700;
    margin: 0 0 15px 0; 
    padding: 0;
    color: #1d2327; 
}
.wisehub-series-box ol {
    margin: 0;
    padding-left: 20px; 
    counter-reset: series-counter; 
}
.wisehub-series-box li {
    font-size: 1em;
    font-weight: 500;
    margin-bottom: 10px; 
    color: #333;
    list-style: none; 
    counter-increment: series-counter; 
    position: relative;
    padding-left: 5px;
}
.wisehub-series-box li::before {
    content: counter(series-counter) "."; 
    position: absolute;
    left: -25px;
    font-weight: 700;
    color: #0073aa; 
    font-size: 1.1em;
}
.wisehub-series-box li:last-child {
    margin-bottom: 0; 
}
.wisehub-series-box li a {
    text-decoration: none;
    color: #333;
    border-bottom: 1px dashed #ccc; 
    transition: all 0.2s ease;
}
.wisehub-series-box li a:hover {
    color: #0073aa;
    border-bottom-color: #0073aa; 
}
/* =================================================================
   15. 모바일 메뉴 터치 영역 및 스크롤 문제 최종 수정
   ================================================================= */

/* 1. 메뉴 잘림 문제 해결: 스크롤 영역 강제 지정 */
.mobile-menu-container {
    height: 100vh;
    padding-top: 50px; /* 헤더 높이만큼 줄여서 스크롤 가능하게 합니다. */
    overflow-y: scroll; 
    -webkit-overflow-scrolling: touch;
}

/* 2. 메뉴 항목 전체를 터치 영역으로 확장 */
.mobile-menu ul li a {
    position: relative;
    z-index: 10; 
    padding: 20px; /* 기존 padding을 유지하면서 터치 영역을 확실하게 */
    box-sizing: border-box; 
    width: 100%;
}

/* 3. 하위 메뉴 화살표 영역과 링크 영역 겹침 문제 해결 */
.mobile-menu .menu-item-has-children > a {
    padding-right: 40px; /* 화살표 영역과 링크 영역을 분리 */
}
.mobile-menu .menu-item-has-children > a::after {
    position: absolute;
    right: 15px; /* 화살표를 오른쪽 끝으로 이동 */
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none; /* ★ 중요: 화살표는 터치 이벤트에 반응하지 않게 합니다. */
}
/* =================================================================
   16. [추가] 2단계 카테고리 오버레이 스타일 및 1단계 카테고리 항목 재정의
   ================================================================= */

/* 🌟 [수정/추가] 카테고리 항목의 하위 메뉴는 1단계에서 완전히 숨김 🌟 */
.mobile-menu-container #primary-menu-mobile .menu-item-1698 > .sub-menu {
    display: none !important; 
}

/* [선택적] 카테고리 항목이 토글 화살표를 표시하지 않도록 조정 */
.mobile-menu-container #primary-menu-mobile .menu-item-1698 > a::after {
    content: none !important;
}

/* 🌟 [추가] 2단계 카테고리 오버레이 스타일 🌟 */

/* 2단계 메뉴에는 '혜택/복지'와 그 하위 카테고리만 필요합니다. */
.category-step2-overlay #category-step2-list > li {
    display: none; /* 기본적으로 모두 숨김 */
}

/* '카테고리' 항목 (menu-item-1698)만 보이게 하고 그 하위 메뉴를 표시합니다. */
.category-step2-overlay #category-step2-list > .menu-item-1698 {
    display: block !important; 
}

/* 그리고 그 하위 메뉴를 펼쳐서 혜택/복지 목록이 바로 보이게 합니다. */
.category-step2-overlay #category-step2-list > .menu-item-1698 > .sub-menu {
    display: block !important;
}

/* 혜택/복지의 하위 메뉴도 펼칩니다. (3단계까지 펼치는 CSS) */
.category-step2-overlay #category-step2-list .sub-menu .sub-menu {
    display: block !important;
}
/* =================================================================
   17. [수정] 푸터 정보가 상단에 표시되는 문제 해결 
   ================================================================= */

/* 1. 푸터 컨테이너가 다른 고정 요소 위에 올라가지 않도록 위치와 Z-index를 명시 */
.site-footer {
    position: relative !important; /* 항상 문서 흐름을 따르도록 */
    z-index: 50 !important;       /* 오버레이(1001)보다 훨씬 낮게 설정 */
    margin-top: 40px;             /* 기존 여백 유지 */
}

/* 2. 푸터 내의 메뉴 항목이 혹시라도 상단으로 고정되는 것을 방지 */
.site-footer .footer-navigation,
.site-footer .copyright-text {
    position: relative !important;
    z-index: 55 !important;
}

/* 3. 모바일 메뉴가 열렸을 때 (body.mobile-menu-open일 때) 푸터가 보이는 경우에 대비하여 */
body.mobile-menu-open .site-footer {
    display: none; /* 모바일 메뉴가 열리면 푸터를 숨겨서 오버레이 뒤에 깔리는 현상 방지 */
}
/* =================================================================
   18. [요청 수정] 랜딩 이미지 제거 및 썸네일 카드 적용
   ================================================================= */

/* 1. (선택 사항) HTML에서 삭제하지 않았을 경우를 대비해 CSS로 숨김 */
.landing-hero {
    display: none;
}

/* 2. 랜딩 이미지가 사라졌으므로, 헤더와 카드 목록 사이에 여백 추가 */
.card-grid-section {
    margin-top: 30px; /* 원하는 만큼 여백 조절 */
}

/* 3. 숨겨져 있던 썸네일 영역을 다시 보이게 함
   (기존 line 41의 'display: none'을 덮어씁니다) */
.card-thumbnail {
    display: block !important; 
    width: 100%;
    height: 160px; /* 썸네일 높이 (원하는 대로 조절하세요) */
    overflow: hidden;
}

/* 4. 썸네일 이미지가 찌그러지지 않고 영역을 꽉 채우도록 함 */
.card-thumbnail img {
    height: 100% !important; /* 기존 120px 값을 덮어쓰고 100%로 채움 */
    object-fit: cover;
}

/* 5. 썸네일을 사용하는 대신, 기존 아이콘(이모티콘) 영역은 숨김 */
.card-icon {
    display: none;
}
