/*
Theme Name: AI 타스코 Child
Theme URI: https://ai.tasko.kr
Description: AI 타스코 - AI 정보 전문 블로그 (Twenty Twenty-Five 자식 테마)
Author: AI 타스코
Template: twentytwentyfive
Version: 1.0.0
Text Domain: ai-tasko-child
*/

/* ==========================================
   AI 타스코 - 블로그 레이아웃 최적화
   ========================================== */

/* 본문 영역 너비 최적화 - 가독성 향상 */
.wp-block-post-content,
.entry-content,
.post-content {
    max-width: 780px;
    margin-left: auto;
    margin-right: auto;
}

/* 싱글 포스트 본문 최적화 */
.single .wp-block-post-content > * {
    max-width: 780px;
}

/* 타이포그래피 최적화 */
.wp-block-post-content p,
.entry-content p {
    font-size: clamp(1rem, 1.05rem, 1.1rem);
    line-height: 1.85;
    word-break: keep-all;
    word-wrap: break-word;
}

/* 제목 스타일 */
.wp-block-post-content h1,
.wp-block-post-content h2,
.wp-block-post-content h3,
.wp-block-post-content h4 {
    word-break: keep-all;
    line-height: 1.4;
    margin-top: 2em;
    margin-bottom: 0.6em;
}

/* 코드 블록 */
.wp-block-post-content code,
.wp-block-post-content pre {
    font-size: 0.9em;
    background: #f5f5f5;
    border-radius: 4px;
}

/* 이미지 반응형 */
.wp-block-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 목차 (Easy ToC) 스타일 최적화 */
#ez-toc-container {
    background: #f8f9ff;
    border: 1px solid #e0e4ff;
    border-left: 4px solid #503AA8;
    border-radius: 8px;
    padding: 1.2em 1.5em;
    margin: 1.5em 0;
    max-width: 100%;
}

#ez-toc-container .ez-toc-title {
    font-size: 1em;
    font-weight: 700;
    color: #111;
}

#ez-toc-container ul {
    margin: 0.5em 0 0 0;
}

#ez-toc-container ul li {
    margin: 0.3em 0;
    font-size: 0.92em;
}

#ez-toc-container a {
    color: #503AA8;
    text-decoration: none;
}

#ez-toc-container a:hover {
    text-decoration: underline;
}

/* ==========================================
   반응형 최적화 (모바일)
   ========================================== */
@media (max-width: 768px) {
    .wp-block-post-content p,
    .entry-content p {
        font-size: 1rem;
        line-height: 1.8;
    }

    .wp-site-blocks {
        padding-left: 16px;
        padding-right: 16px;
    }

    #ez-toc-container {
        padding: 1em 1.2em;
    }

    /* 모바일 헤더 최적화 */
    .wp-block-site-title a {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .wp-block-post-content h2 {
        font-size: 1.3rem;
    }
    .wp-block-post-content h3 {
        font-size: 1.15rem;
    }
}

/* ==========================================
   AI 테마 색상 (퍼플/테크)
   ========================================== */
a {
    color: #503AA8;
}

a:hover {
    color: #3d2a8a;
}

/* 포스트 메타 정보 */
.wp-block-post-date,
.wp-block-post-author__name {
    color: #686868;
    font-size: 0.875rem;
}

/* 태그/카테고리 */
.wp-block-post-terms a {
    background: #503AA8;
    color: white;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    text-decoration: none;
    display: inline-block;
    margin: 2px;
}

.wp-block-post-terms a:hover {
    background: #3d2a8a;
    color: white;
}

/* ==========================================
   애드센스 광고 영역 최적화
   ========================================== */
.adsense-top,
.adsense-mid,
.adsense-bottom {
    text-align: center;
    margin: 2em auto;
    overflow: hidden;
    display: block;
}

/* 읽기 진행 바 */
#reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #503AA8, #FFEE58);
    z-index: 9999;
    width: 0%;
    transition: width 0.1s;
}
