/**
 * WIA Books Block Patterns - Premium Styles
 * 저자가 HTML/CSS 몰라도 프리미엄 품질의 책을 만드는 스타일
 *
 * @package WIA_Book_Blocks
 * @version 1.0.0
 */

/* ========================================================================
   1. 챕터 헤더
   ======================================================================== */

.wia-chapter-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 3em 2em;
    text-align: center;
    border-radius: 15px;
    margin: 3em 0 2em 0;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.wia-chapter-number {
    font-size: 1.2em;
    opacity: 0.9;
    margin-bottom: 0.5em;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.wia-chapter-title {
    font-size: 2.5em;
    font-weight: 800;
    margin: 0;
    line-height: 1.2;
}

.wia-chapter-subtitle {
    font-size: 1.2em;
    opacity: 0.9;
    margin-top: 0.5em;
    font-style: italic;
}

/* ========================================================================
   2. 통계 박스
   ======================================================================== */

.wia-stat-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2.5em 2em;
    border-radius: 12px;
    text-align: center;
    margin: 2em 0;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.wia-stat-value {
    font-size: 3.5em;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.3em;
}

.wia-stat-desc {
    font-size: 1.3em;
    margin: 0.5em 0;
    font-weight: 500;
}

.wia-stat-source {
    font-size: 0.9em;
    opacity: 0.8;
    font-style: italic;
    margin-top: 0.5em;
}

/* ========================================================================
   3. 하이라이트 박스
   ======================================================================== */

.wia-highlight-box {
    background: #f1f5f9;
    border-left: 5px solid #3b82f6;
    padding: 1.5em 2em;
    border-radius: 0 8px 8px 0;
    margin: 2em 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.wia-highlight-box h3 {
    color: #3b82f6;
    margin-top: 0;
    font-size: 1.3em;
}

.wia-highlight-box p:last-child {
    margin-bottom: 0;
}

/* ========================================================================
   4. 경고 박스
   ======================================================================== */

.wia-warning-box {
    background: #fef3c7;
    border-left: 5px solid #f59e0b;
    padding: 1.5em 2em;
    border-radius: 0 8px 8px 0;
    margin: 2em 0;
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.1);
}

.wia-warning-box h3 {
    color: #f59e0b;
    margin-top: 0;
    font-size: 1.3em;
}

.wia-warning-box p:last-child {
    margin-bottom: 0;
}

/* ========================================================================
   5. 정보 박스
   ======================================================================== */

.wia-info-box {
    background: #dbeafe;
    border-left: 5px solid #2563eb;
    padding: 1.5em 2em;
    border-radius: 0 8px 8px 0;
    margin: 2em 0;
    box-shadow: 0 2px 10px rgba(37, 99, 235, 0.1);
}

.wia-info-box h3 {
    color: #2563eb;
    margin-top: 0;
    font-size: 1.3em;
}

.wia-info-box p:last-child {
    margin-bottom: 0;
}

/* ========================================================================
   6. 성공 박스
   ======================================================================== */

.wia-success-box {
    background: #d1fae5;
    border-left: 5px solid #10b981;
    padding: 1.5em 2em;
    border-radius: 0 8px 8px 0;
    margin: 2em 0;
    box-shadow: 0 2px 10px rgba(16, 185, 129, 0.1);
}

.wia-success-box h3 {
    color: #10b981;
    margin-top: 0;
    font-size: 1.3em;
}

.wia-success-box p:last-child {
    margin-bottom: 0;
}

/* ========================================================================
   7. 체크리스트
   ======================================================================== */

.wia-checklist {
    background: #ecfdf5;
    border: 2px solid #10b981;
    border-radius: 8px;
    padding: 2em;
    margin: 2em 0;
}

.wia-checklist h3 {
    color: #10b981;
    margin-top: 0;
    font-size: 1.3em;
}

.wia-checklist ul {
    list-style: none;
    padding-left: 0;
}

.wia-checklist li {
    position: relative;
    padding-left: 2em;
    margin-bottom: 0.8em;
    line-height: 1.6;
}

.wia-checklist li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: bold;
    font-size: 1.3em;
}

/* ========================================================================
   8. 인용문
   ======================================================================== */

.wia-quote {
    margin: 3em 0;
}

.wia-quote blockquote {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2em 2.5em;
    border-left: none;
    border-radius: 12px;
    margin: 0;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
    position: relative;
}

.wia-quote blockquote::before {
    content: """;
    font-size: 5em;
    position: absolute;
    top: -0.2em;
    left: 0.2em;
    opacity: 0.2;
    font-family: Georgia, serif;
}

.wia-quote blockquote p {
    font-size: 1.3em;
    line-height: 1.6;
    margin: 0;
    font-style: italic;
}

.wia-quote cite {
    display: block;
    text-align: right;
    margin-top: 1em;
    font-style: normal;
    opacity: 0.9;
    font-size: 1.1em;
}

/* ========================================================================
   9. 비교 테이블
   ======================================================================== */

.wia-comparison-table {
    margin: 2em 0;
    overflow-x: auto;
}

.wia-comparison-table table {
    width: 100%;
    border-collapse: collapse;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.wia-comparison-table thead {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.wia-comparison-table th {
    padding: 1.2em 1em;
    text-align: left;
    font-weight: 600;
    font-size: 1.1em;
}

.wia-comparison-table tbody tr {
    border-bottom: 1px solid #e5e7eb;
}

.wia-comparison-table tbody tr:last-child {
    border-bottom: none;
}

.wia-comparison-table tbody tr:nth-child(even) {
    background: #f9fafb;
}

.wia-comparison-table td {
    padding: 1em;
}

.wia-comparison-table td:first-child {
    font-weight: 600;
    color: #374151;
}

/* ========================================================================
   10. 저자 소개
   ======================================================================== */

.wia-author-bio {
    display: flex;
    align-items: center;
    gap: 2em;
    background: #f9fafb;
    padding: 2em;
    border-radius: 12px;
    margin: 3em 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.wia-author-image {
    flex-shrink: 0;
}

.wia-author-image img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.wia-author-info {
    flex: 1;
}

.wia-author-name {
    margin: 0 0 0.3em 0;
    font-size: 1.8em;
    color: #111827;
}

.wia-author-title {
    margin: 0 0 1em 0;
    color: #6b7280;
    font-size: 1.1em;
}

.wia-author-desc {
    margin: 0;
    line-height: 1.6;
    color: #374151;
}

/* Responsive */
@media (max-width: 768px) {
    .wia-author-bio {
        flex-direction: column;
        text-align: center;
    }
}

/* ========================================================================
   11. 주요 포인트
   ======================================================================== */

.wia-key-points {
    background: #fef3c7;
    border: 3px solid #f59e0b;
    border-radius: 12px;
    padding: 2em;
    margin: 2em 0;
}

.wia-key-points h3 {
    color: #f59e0b;
    margin-top: 0;
    font-size: 1.5em;
}

.wia-key-points ul {
    margin-bottom: 0;
}

.wia-key-points li {
    margin-bottom: 1em;
    line-height: 1.6;
}

.wia-key-points li:last-child {
    margin-bottom: 0;
}

.wia-key-points li strong {
    color: #f59e0b;
}

/* ========================================================================
   12. 단계별 가이드
   ======================================================================== */

.wia-step-guide {
    margin: 2em 0;
}

.wia-step {
    display: flex;
    gap: 1.5em;
    margin-bottom: 2em;
    align-items: flex-start;
}

.wia-step:last-child {
    margin-bottom: 0;
}

.wia-step-number {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.wia-step-content {
    flex: 1;
    background: #f9fafb;
    padding: 1.5em;
    border-radius: 8px;
    border-left: 3px solid #667eea;
}

.wia-step-content h4 {
    margin: 0 0 0.5em 0;
    color: #111827;
    font-size: 1.3em;
}

.wia-step-content p {
    margin: 0;
    line-height: 1.6;
    color: #374151;
}

/* ========================================================================
   PDF/EPUB Export Optimization
   ======================================================================== */

@media print {
    /* 페이지 브레이크 최적화 */
    .wia-chapter-header,
    .wia-stat-box,
    .wia-quote blockquote {
        page-break-inside: avoid;
    }

    /* 색상 유지 */
    * {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    /* 박스 그림자 제거 (인쇄용) */
    .wia-chapter-header,
    .wia-stat-box,
    .wia-quote blockquote {
        box-shadow: none;
    }
}

/* ========================================================================
   Responsive Design
   ======================================================================== */

@media (max-width: 768px) {
    .wia-chapter-title {
        font-size: 2em;
    }

    .wia-stat-value {
        font-size: 2.5em;
    }

    .wia-comparison-table {
        font-size: 0.9em;
    }

    .wia-step {
        flex-direction: column;
    }

    .wia-step-number {
        margin: 0 auto;
    }
}
