/* ============================================================
   RoozBook - Book Page Styles
   ============================================================ */

.book-page {
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 20px;
    padding: 30px 40px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.04);
}

.book-header {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
}

.book-cover {
    width: 200px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.book-cover img {
    width: 100%;
    height: auto;
    display: block;
}

.book-info {
    flex: 1;
}

.book-title {
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.3;
    color: #1e2a36;
    margin-bottom: 12px;
}

.book-author,
.book-translator,
.book-publisher {
    font-size: 0.95rem;
    color: #555;
    margin-bottom: 4px;
}

.book-author strong,
.book-translator strong,
.book-publisher strong {
    color: #1a1a1a;
    margin-left: 4px;
}

.book-meta-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin: 16px 0;
    padding: 14px;
    background: #f8fafc;
    border-radius: 8px;
}

.book-meta-item {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 0.95rem;
    border-bottom: 1px dotted #e0e0e0;
}

.book-meta-item:last-child {
    border-bottom: none;
}

.book-meta-label {
    color: #999;
}

.book-meta-value {
    font-weight: 600;
    color: #1a1a1a;
}

.book-section {
    margin-top: 24px;
}

.book-section h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e67e22;
    color: #2c3e50;
}

.book-description-text {
    font-size: 1.05rem;
    line-height: 2;
    color: #1e293b;
}

/* Related Posts */
.book-related {
    margin-top: 28px;
}

.book-related h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e67e22;
    color: #2c3e50;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.related-post-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #eee;
    transition: all 0.2s ease;
    display: block;
}

.related-post-card:hover {
    border-color: #e67e22;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.related-post-img {
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.related-post-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
}

.related-post-card:hover .related-post-img img {
    transform: scale(1.05);
}

.related-post-body {
    padding: 12px;
}

.related-post-title {
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.4;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.related-post-date {
    font-size: 0.75rem;
    color: #999;
}

/* Books List Grid */
.books-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 28px;
}

.book-card-item {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    border: 1px solid #eee;
    transition: all 0.2s ease;
}

.book-card-item:hover {
    border-color: #e67e22;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.book-card-cover-link {
    display: block;
    width: 120px;
    height: 170px;
    margin: 0 auto 12px;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.book-card-cover-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.book-card-info h3 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.4;
}

.book-card-info h3 a {
    color: #1a1a1a;
}

.book-card-info h3 a:hover {
    color: #e67e22;
}

.book-card-author {
    font-size: 0.82rem;
    color: #e67e22;
    margin-bottom: 2px;
}

.book-card-publisher {
    font-size: 0.78rem;
    color: #999;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
}

.page-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e0e0e0;
    background: #fff;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.85rem;
    color: #555;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.page-btn.active,
.page-btn:hover {
    background: #e67e22;
    color: #fff;
    border-color: #e67e22;
}

.page-dots {
    padding: 0 4px;
    color: #999;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 768px) {
    .book-page {
        padding: 20px 16px;
        border-radius: 0;
    }
    
    .book-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .book-cover {
        width: 160px;
    }
    
    .book-title {
        font-size: 1.5rem;
    }
    
    .book-meta-grid {
        grid-template-columns: 1fr;
    }
    
    .related-posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .books-grid {
        grid-template-columns: 1fr;
    }
}