/* Book Page Specific Styles */

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Scroll Margin for Fixed Headers */
.content-section h2 {
    scroll-margin-top: 2rem;
}

/* Breadcrumb */
.breadcrumb {
    background: var(--bg-light);
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

    .breadcrumb a {
        color: var(--primary-color);
        text-decoration: none;
        transition: var(--transition);
    }

        .breadcrumb a:hover {
            text-decoration: underline;
        }

    .breadcrumb span {
        color: var(--text-light);
    }

/* Book Header Section */
.book-header {
    background: var(--bg-white);
    padding: 3rem 0;
    border-bottom: 1px solid var(--border-color);
}

.book-header-content {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 3rem;
    align-items: start;
}

.book-cover-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: sticky;
    top: 2rem;
}

.book-cover {
    width: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

    .book-cover img {
        width: 100%;
        height: auto;
        display: block;
    }

.buy-button {
    display: block;
    padding: 1rem;
    background: var(--primary-color);
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: var(--transition);
}

    .buy-button:hover {
        background: var(--primary-dark);
        transform: translateY(-2px);
        box-shadow: var(--shadow-md);
    }

.book-info-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.book-category-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: var(--bg-light);
    color: var(--primary-color);
    border-radius: var(--radius-lg);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    width: fit-content;
}

.book-page-title {
    font-family: 'Georgia', 'Times New Roman', serif;
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
    margin: 0;
}

.book-author-large {
    font-size: 1.25rem;
    color: var(--text-light);
    margin: 0;
}

    .book-author-large strong {
        color: var(--text-dark);
    }

.book-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding: 1rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.meta-item {
    font-size: 0.95rem;
    color: var(--text-light);
}

.book-excerpt {
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-dark);
}

/* Content Layout */
.book-content {
    padding: 3rem 0 4rem;
    background: var(--bg-light);
}

.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 3rem;
    align-items: start;
}

.main-article {
    background: var(--bg-white);
    padding: 2.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

/* Content Sections */
.content-section {
    margin-bottom: 3rem;
}

    .content-section:last-child {
        margin-bottom: 0;
    }

    .content-section h2 {
        font-size: 1.75rem;
        font-weight: 700;
        color: var(--text-dark);
        margin-bottom: 1.25rem;
        padding-bottom: 0.75rem;
        border-bottom: 2px solid var(--primary-color);
    }

    .content-section h3 {
        font-size: 1.35rem;
        font-weight: 600;
        color: var(--text-dark);
        margin: 2rem 0 1rem;
    }

    .content-section p {
        font-size: 1.05rem;
        line-height: 1.8;
        color: var(--text-dark);
        margin-bottom: 1.25rem;
    }

    .content-section strong {
        color: var(--primary-color);
        font-weight: 600;
    }

/* Key Takeaways */
.takeaways-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.takeaway-item {
    display: grid;
    grid-template-columns: 60px 1fr;
    gap: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    border-left: 4px solid var(--primary-color);
}

.takeaway-number {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    border-radius: 50%;
    flex-shrink: 0;
}

.takeaway-content h3 {
    font-size: 1.15rem;
    margin: 0 0 0.5rem 0;
    color: var(--text-dark);
}

.takeaway-content p {
    margin: 0;
    font-size: 1rem;
    line-height: 1.6;
}

/* Comparison Table */
.comparison-table {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.comparison-column {
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
}

    .comparison-column h4 {
        font-size: 1.15rem;
        font-weight: 600;
        margin-bottom: 1rem;
        color: var(--primary-color);
    }

    .comparison-column ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .comparison-column li {
        padding: 0.5rem 0 0.5rem 1.5rem;
        position: relative;
        font-size: 0.95rem;
        line-height: 1.6;
    }

        .comparison-column li:before {
            content: "•";
            position: absolute;
            left: 0;
            color: var(--primary-color);
            font-weight: 700;
        }

/* Quotes */
.quotes-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.book-quote {
    padding: 1.5rem 2rem;
    background: var(--bg-light);
    border-left: 4px solid var(--secondary-color);
    border-radius: var(--radius-md);
    margin: 0;
    font-style: italic;
    font-size: 1.15rem;
    line-height: 1.7;
    color: var(--text-dark);
}

    .book-quote p {
        margin: 0;
    }

/* Styled List */
.styled-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

    .styled-list li {
        padding: 1rem 0 1rem 1.5rem;
        position: relative;
        border-bottom: 1px solid var(--border-color);
        font-size: 1.05rem;
        line-height: 1.7;
    }

        .styled-list li:last-child {
            border-bottom: none;
        }

        .styled-list li:before {
            content: "✓";
            position: absolute;
            left: 0;
            color: var(--primary-color);
            font-weight: 700;
        }

/* Author Box */
.author-box {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--radius-md);
    border-left: 4px solid var(--primary-color);
    margin-top: 3rem;
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 1.5rem;
    align-items: start;
}

.author-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

    .author-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.author-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 0.5rem 0;
}

.author-content p {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-dark);
    margin: 0;
}

/* CTA Box */
.cta-box {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 2.5rem;
    border-radius: var(--radius-md);
    text-align: center;
    margin-top: 3rem;
}

    .cta-box h3 {
        font-size: 1.75rem;
        margin: 0 0 0.75rem 0;
        color: white;
    }

    .cta-box p {
        font-size: 1.1rem;
        margin: 0 0 1.5rem 0;
        opacity: 0.95;
        color: white;
    }

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: white;
    color: var(--primary-color);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 1.05rem;
    transition: var(--transition);
}

    .cta-button:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    }

/* Sidebar */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    position: sticky;
    top: 2rem;
}

.sidebar-widget {
    background: var(--bg-white);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

    .sidebar-widget h3 {
        font-size: 1.15rem;
        font-weight: 600;
        margin: 0 0 1rem 0;
        color: var(--text-dark);
    }

/* Table of Contents */
.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

    .toc-list li {
        margin-bottom: 0.75rem;
    }

    .toc-list a {
        color: var(--text-light);
        text-decoration: none;
        font-size: 0.95rem;
        transition: var(--transition);
        display: block;
        padding: 0.25rem 0;
    }

        .toc-list a:hover {
            color: var(--primary-color);
            padding-left: 0.5rem;
        }

/* Related Books */
.related-books {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.related-book-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    text-decoration: none;
    transition: var(--transition);
}

    .related-book-item:hover {
        background: var(--border-color);
        transform: translateX(4px);
    }

.related-book-thumbnail {
    width: 50px;
    height: 50px;
    background: white;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.related-book-info h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 0.25rem 0;
}

.related-book-info p {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 0;
}

/* Responsive Design for Book Pages */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        order: -1;
    }

    .book-header-content {
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .book-header-content {
        grid-template-columns: 1fr;
    }

    .book-cover-section {
        position: static;
        max-width: 300px;
        margin: 0 auto;
    }

    .book-page-title {
        font-size: 2rem;
    }

    .main-article {
        padding: 1.5rem;
    }

    .comparison-table {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .takeaway-item {
        grid-template-columns: 50px 1fr;
        gap: 1rem;
        padding: 1rem;
    }

    .takeaway-number {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }

    .content-section h2 {
        font-size: 1.5rem;
    }

    .sidebar-widget {
        padding: 1.25rem;
    }

    .author-box {
        grid-template-columns: 100px 1fr;
        gap: 1rem;
        padding: 1.5rem;
    }

    .author-image {
        width: 100px;
        height: 100px;
    }
}

@media (max-width: 480px) {
    .book-header {
        padding: 2rem 0;
    }

    .book-page-title {
        font-size: 1.75rem;
    }

    .book-author-large {
        font-size: 1.1rem;
    }

    .book-meta {
        flex-direction: column;
        gap: 0.5rem;
    }

    .main-article {
        padding: 1.25rem;
    }

    .cta-box {
        padding: 2rem 1.5rem;
    }

        .cta-box h3 {
            font-size: 1.5rem;
        }

    .author-box {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 1.5rem;
    }

    .author-image {
        width: 100px;
        height: 100px;
        margin: 0 auto;
    }

    .author-content h3 {
        font-size: 1.15rem;
    }
}
