/* Book Chapters Page Styles */

/* Page Hero Section with Video Background */
.page-hero {
    background: linear-gradient(135deg, #0891b2 0%, #06b6d4 100%);
    color: var(--white);
    padding: 6rem 0 4rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-hero-video-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.page-hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
}

/* Video Overlay for better text readability */
.page-hero-video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(8, 145, 178, 0.75);
    z-index: 1;
}

/* Ensure content is above video */
.page-hero .container {
    position: relative;
    z-index: 2;
}

.page-title {
    font-size: 3rem;
    margin-bottom: 0;
    color: var(--white);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Book Chapters Section */
.book-chapters-section {
    padding: var(--section-padding);
    background: var(--lighter-bg);
}

.chapters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2.5rem;
    margin-top: 3rem;
}

.chapter-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    position: relative;
}

.chapter-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-left-color: var(--accent-color);
}

.chapter-content {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.chapter-number {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.chapter-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.chapter-authors {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.chapter-authors strong {
    color: var(--primary-color);
    font-weight: 600;
}

.chapter-images {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.chapter-image {
    flex: 1;
    min-width: 120px;
    max-width: 48%;
    height: 160px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    background: #f8fafc;
}

.chapter-image.single {
    max-width: 100%;
    height: 200px;
}

.chapter-publication {
    font-size: 0.9rem;
    color: var(--accent-color);
    font-style: italic;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chapter-publication i {
    font-size: 1rem;
}

.chapter-link-icon {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--primary-color);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    opacity: 0;
    transition: var(--transition);
}

.chapter-card:hover .chapter-link-icon {
    opacity: 1;
}

/* No images placeholder */
.chapter-no-images {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8fafc 0%, #e0f2fe 100%);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.chapter-no-images i {
    font-size: 2.5rem;
    color: var(--primary-color);
    opacity: 0.3;
}

/* Responsive Design */
@media (max-width: 768px) {
    .chapters-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .chapter-image {
        min-width: 100%;
        max-width: 100%;
    }
    
    .chapter-title {
        font-size: 1rem;
    }
    
    .chapter-authors {
        font-size: 0.9rem;
    }
    
    .chapter-content {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .chapter-card {
        margin: 0 0.5rem;
    }
    
    .chapter-content {
        padding: 1.25rem;
    }
}
