/*
Theme Name: Soap (비누) - JOBKOR Senior Optimized
Theme URI: https://monim.net
Author: monim
Version: 1.1
*/

/* 1. 영문 폰트: Inter (구글 폰트에서 가져오기) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

/* 2. 한글 폰트: 나눔스퀘어 네오 */
@font-face {
    font-family: 'NanumSquareNeo';
    src: url(https://hangeul.pstatic.net/hangeul_static/webfont/NanumSquareNeo/NanumSquareNeoTTF-bRg.eot);
    src: url(https://hangeul.pstatic.net/hangeul_static/webfont/NanumSquareNeo/NanumSquareNeoTTF-bRg.eot?#iefix) format("embedded-opentype"),
         url(https://hangeul.pstatic.net/hangeul_static/webfont/NanumSquareNeo/NanumSquareNeoTTF-bRg.woff) format("woff"),
         url(https://hangeul.pstatic.net/hangeul_static/webfont/NanumSquareNeo/NanumSquareNeoTTF-bRg.ttf) format("truetype");
    font-display: fallback;
    unicode-range: U+AC00-D7A3, U+1100-11FF, U+3130-318F, U+A960-A97F, U+D7B0-D7FF;
}

/* 3. 사이트 전체 폰트 적용 및 기본 크기/색상 세팅 (시니어 배려) */
body, button, input, select, textarea, h1, h2, h3, h4, h5, h6, .nav-link, .navbar-brand {
    font-family: 'NanumSquareNeo', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    word-break: keep-all;
    font-size: 18px; /* 기본 글씨 크기 18px로 상향 */
    color: #222; /* 전체적으로 글씨를 더 진하게 (명도 대비 증가) */
}

html {
}

/* 상단 메뉴: 글씨 키우고 클릭 영역 넓히기 */
.navbar-nav .menu-item a {
    text-decoration: none !important;
    color: #333 !important; /* 기존 #555에서 더 진하게 */
    padding: 0.8rem 1rem !important; /* 터치하기 쉽도록 위아래 여백 확대 */
    display: block;
    transition: color 0.2s ease;
    font-size: 1.15rem; /* 메뉴 글씨 확대 */
    font-weight: 600; /* 메뉴를 또렷하게 */
}

.navbar-nav .menu-item a:hover {
    color: #0d6efd !important;
}

/* 목록 게시물 제목 */
.post-title a {
    text-decoration: none;
    color: #111; /* 기존 #222에서 더 또렷하게 */
    transition: 0.2s;
    font-size: 1.35rem; /* 리스트 제목 확대 */
    font-weight: 700;
}

.post-title a:hover {
    color: #0d6efd;
}

/* 모바일 메뉴 보정 */
@media (max-width: 991.98px) {
    .navbar-nav .menu-item a {
        padding: 12px 0 !important; /* 모바일에서 누르기 편하게 간격 추가 */
        border-bottom: 1px solid #f8f9fa;
        font-size: 1.2rem; /* 모바일 메뉴 글씨도 크게 */
    }
}

/* 나눔스퀘어 네오 폰트 보정 */
.navbar-brand, .nav-link, .menu-item a {
    font-family: 'NanumSquareNeo', sans-serif !important;
}

/* -------------------------------------------
   본문 (Entry Content) 최적화
------------------------------------------- */

/* 1. 본문 문단: 1.2rem(약 19.2px)로 시원하게 확대 */
.entry-content p {
    margin-bottom: 2rem !important;
    line-height: 1.8;
    font-size: 1.2rem;
    color: #111; /* 본문 텍스트 명도 대비 극대화 */
}

/* 2. 본문 내 중간 제목: 구분이 확실하도록 크기 및 여백 지정 */
.entry-content h1,
.entry-content h2,
.entry-content h3 {
    margin-top: 3.5rem !important;
    margin-bottom: 1.5rem !important;
    word-break: keep-all;
    color: #000;
    font-weight: 700;
}

.entry-content h1 { font-size: 2.2rem !important; }
.entry-content h2 { font-size: 1.8rem !important; }
.entry-content h3 { font-size: 1.5rem !important; }

/* 3. 이미지 캡션/인용구 여백 */
.entry-content figure {
    margin-top: 2.5rem;
    margin-bottom: 2.5rem;
}

/* -------------------------------------------
   썸네일 이미지 및 특수 요소
------------------------------------------- */

/* 썸네일 액자 효과 */
.post-list .ratio {
    border: 2px solid #efefef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.post-list .ratio:hover {
    border-color: #dee2e6;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

.post-list .ratio img {
    transition: transform 0.4s ease-in-out;
}

.post-list .ratio:hover img {
    transform: scale(1.08);
}

/* 현재 보고 있는 페이지 메뉴 강조 */
.navbar-nav .current-menu-item a {
    color: #0d6efd !important;
    font-weight: 700 !important;
}

/* 인용구 (Blockquote) */
blockquote,
.wp-block-quote {
    position: relative;
    margin: 2.5rem 0;
    padding: 2rem;
    background-color: #fcfcfc; /* 배경을 살짝 더 눈 편하게 */
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    text-align: center;
}

blockquote::before,
.wp-block-quote::before {
    content: "“";
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: #fcfcfc;
    padding: 0 10px;
    font-size: 3rem;
    color: #cccccc;
    font-family: serif;
    line-height: 1;
}

/* 인용구 텍스트: 기존보다 크게, 더 진하게 */
blockquote p,
.wp-block-quote p {
    margin: 0;
    font-size: 1.25rem !important;
    color: #111 !important;
    font-weight: 600;
}

/* 강조 및 인라인 스타일 */
mark {
    background-color: #fff2ac;
    color: #111; /* 강조 텍스트도 또렷하게 */
    padding: 0.1em 0.3em;
    border-radius: 2px;
}

p code,
li code {
    font-family: Consolas, Monaco, monospace;
    background-color: #f0f1f3;
    color: #e83e8c;
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-size: 1rem; /* 코드도 살짝 키움 */
}

sup, sub {
    font-size: 75%;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}
sup { top: -0.5em; }
sub { bottom: -0.25em; }

del, s {
    text-decoration: line-through;
    color: #888888;
}

/* 페이징 버그 방지 */
.page-item .page-link {
    box-shadow: none !important;
    outline: none !important;
    font-size: 1.1rem; /* 페이징 번호도 살짝 크게 */
    padding: 0.5rem 1rem;
}

/* 코드 블록 (블랙 테마) */
.wp-block-code {
    background-color: #1e1e1e;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 2rem auto;
    overflow-x: auto;
    border: 1px solid #333;
    box-sizing: border-box;
}

.wp-block-code code {
    font-family: 'Fira Code', 'Cascadia Code', Consolas, Monaco, 'Andale Mono', monospace;
    font-size: 1rem; /* 코드 블록 텍스트도 가독성 위해 상향 */
    color: #dcdcdc;
    line-height: 1.6;
    white-space: pre;
    word-break: normal;
}

/* -------------------------------------------
   에디터 내부 스타일 (style-editor.css 영역)
------------------------------------------- */
.editor-styles-wrapper .wp-block-code {
    background-color: #1e1e1e !important;
    border-radius: 8px;
    padding: 1.5rem;
    border: 1px solid #333;
    margin: 1.5rem 0;
}

.editor-styles-wrapper .wp-block-code code,
.editor-styles-wrapper .wp-block-code .block-editor-rich-text__editable {
    font-family: Consolas, Monaco, monospace !important;
    font-size: 16px !important; /* 에디터 환경 폰트 키움 */
    color: #dcdcdc !important;
    line-height: 1.6 !important;
    background: transparent !important;
    outline: none !important;
}

.editor-styles-wrapper .wp-block-code .block-editor-rich-text__editable::selection {
    background-color: #264f78;
}

.text-brand {
    color: #3e90da !important;
}

/* 데스크톱 해상도(992px 이상)에서만 Hover 작동 */
@media all and (min-width: 992px) {
    .navbar .dropdown:hover .dropdown-menu {
        display: block;
        margin-top: 0; 
    }
}