/*
Theme Name: GeneratePress Dark
Theme URI: https://economicnote.com
Description: GeneratePress Child Theme – Full Dark Mode, Homepage 최적화
Author: economicnote
Template: generatepress
Version: 1.6.1
*/

/* ===============================
   CSS Variables
=============================== */
:root {
  --bg-main: #0f0f0f;
  --bg-card: #1c1c1c;
  --text-main: #dcdcdc; /* 기존보다 약간 어둡게 조정 */
  --text-sub: #b3b3b3;  /* 기존보다 약간 어둡게 조정 */
  --accent: #63e6be;
  --border: #2a2a2a;
  --hover-bg: #252525;
  --hover-text: #ffffff;
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Inter', 'Noto Sans KR', sans-serif;
}

/* ===============================
   전체 Wrapper & 본문 다크모드
=============================== */
html, body, #page, .site, .site-content, .site-main, article.homepage-wrapper, .inside-article {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-sans);
}

.entry-content, .post-content, .page-content, .wp-block {
    background-color: var(--bg-main);
    color: var(--text-main);
}

.entry-content *, .post-content *, .page-content *, .wp-block * {
    background-color: inherit;
    color: inherit;
}

/* ===============================
   링크 & 버튼
=============================== */
a, a * { 
    color: var(--accent); 
    text-decoration: none; /* 밑줄 제거 */
    transition: color 0.3s ease; 
}
a:hover, a:hover * { color: var(--hover-text); }

/* ===============================
   Hero Section 중앙 정렬
=============================== */
.site-header, .inside-header, .home-hero, .hero-block, .hero-section, .hero-banner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-color: var(--bg-main) !important;
    color: var(--text-main) !important;
    border-bottom: 1px solid var(--border);
}

.home-title, .home-sub { margin-left: auto; margin-right: auto; text-align: center; }

.home-hero a, .hero-block a, .hero-section a, .hero-banner a { color: var(--accent) !important; }
.home-hero a:hover, .hero-block a:hover, .hero-section a:hover, .hero-banner a:hover { color: var(--hover-text) !important; }

/* ===============================
   Home Menu
=============================== */
.home-menu-wrapper {
    max-width: 1200px;
    margin: 20px auto 40px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    text-align: center;
}

.home-menu-btn {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 12px 25px;
    transition: background-color 0.3s ease, color 0.3s ease;
}
.home-menu-btn a { color: var(--accent); font-weight: 600; font-size: 0.95rem; text-decoration: none; display: block; text-align: center; }
.home-menu-btn:hover { background-color: var(--hover-bg); }
.home-menu-btn:hover a { color: var(--hover-text); }

/* ===============================
   Newsroom Section (경제 지표 / 정책 브리핑 / 전문가 의견)
=============================== */
.newsroom-section {
    max-width: 1200px;
    margin: 0 auto 60px;
    padding: 40px 20px;
    border-bottom: 1px solid var(--border);
    color: var(--text-main);
}

.newsroom-section h2 {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-main);
}

.section-desc { font-size: 1rem; color: var(--text-sub); margin-bottom: 25px; }

/* ===============================
   Card & Post List 통합 스타일
=============================== */
.ecos-dashboard, .post-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

/* 카드 & 글 리스트 */
.econ-card, .post-list article {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.6);
    color: var(--text-main);
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

/* 호버 시 배경만 옅어지고 글자색 유지 */
.econ-card:hover, .post-list article:hover {
    background-color: #2a2a2a;
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.8);
}

/* 제목, 내용, 메타 색상 유지 */
.econ-card h3, .post-list article h3,
.econ-card p, .post-list p,
.econ-card small, .post-list small {
    color: var(--text-main);
}

/* 링크 스타일 (밑줄 제거) */
.post-list article a {
    color: var(--text-main);
    font-weight: 600;
    text-decoration: none;
}
.post-list article a:hover { color: var(--text-main); }

/* 쇼트코드 & 플러그인 inherit 처리 */
.post-list *, .ecos-dashboard *, .widget * {
    background-color: inherit;
    color: inherit;
    border-color: var(--border);
}

/* 데이터 노트 */
.data-note { font-size: 0.8rem; color: var(--text-sub); text-align: right; margin-top: 10px; }

/* ===============================
   사이드바 제거
=============================== */
.sidebar, .site-sidebar { display: none !important; }
.content-area, .site-main { width: 100% !important; margin: 0 auto; }

/* ===============================
   푸터
=============================== */
footer, .site-footer, .site-footer * { background-color: var(--bg-main); color: var(--text-main); border-color: var(--bg-main); }
.site-footer a { color: var(--accent); text-decoration: none; }
.site-footer a:hover { color: var(--hover-text); text-decoration: none; }

/* ===============================
   본문 감싸는 영역 (inside-article)
=============================== */
.inside-article, .inside-article > * {
    background-color: var(--bg-main) !important;
    color: var(--text-main) !important;
    border-color: var(--border) !important;
}

/* ===============================
   반응형
=============================== */
@media(max-width:768px){
    .home-hero { padding: 40px 15px; }
    .home-title { font-size: 1.9rem; }
    .newsroom-section { padding: 25px 15px; }
    .newsroom-section h2 { font-size: 1.4rem; }
    .home-menu-wrapper { flex-direction: column; gap: 10px; align-items: center; }
    .home-menu-btn { width: 80%; }
    .ecos-dashboard, .post-list { grid-template-columns: 1fr; }
}
