.chapter-info {
    text-align: center;
    flex-grow: 1;
    margin: 0 20px;
}

.chapter-info h3 {
    margin-bottom: 5px;
    color: #333;
    font-size: 1.2em;
}

.chapter-meta {
    color: #666;
    font-size: 14px;
}

.comic-pages {
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: #FFFFFF;
    gap: 0; /* Remove gap between pages for continuous flow */
    margin: 30px 0;
}

.comic-page {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    margin-bottom: 0; /* Remove bottom margin */
}

.comic-page img {
    width: 100%;
    height: auto;
    display: block; /* Remove any inline spacing */
}

/* Chapter selector styling */
.chapter-selector {
    margin: 20px 0;
    text-align: center;
    width: 100%;
}

.chapter-selector label {
    margin-right: 10px;
    font-weight: bold;
}

.chapter-dropdown {
    padding: 8px 16px;
    border: 2px solid var(--accent-color, #4a6fa5);
    border-radius: 4px;
    background: white;
    font-size: 16px;
    cursor: pointer;
    min-width: 200px;
}

/* Responsive adjustments */
@media (max-width: 850px) {
    .comic-page {
        max-width: 100%;
    }
    
    .comic-controls {
        flex-direction: column;
        gap: 15px;
    }
    
    .chapter-info {
        order: 1;
        margin: 0;
    }
    
    .comic-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 600px) {
    .comic-viewer {
        padding: 10px;
    }
    
    .comic-page img {
        border-radius: 0;
    }
}

/* Smooth scrolling for better reading experience */
html {
    scroll-behavior: smooth;
}

/* Loading indicator */
.loading-indicator {
    text-align: center;
    padding: 40px;
    color: #666;
}

.loading-indicator i {
    font-size: 2em;
    margin-bottom: 10px;
    color: var(--accent-color, #4a6fa5);
}

/* Fixed Navigation Bar Styles - Updated for PC */
.fixed-nav-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--body-bg);
    backdrop-filter: blur(10px);
    border-top: 3px solid var(--border-line);
    z-index: 1000;
    padding: 10px 0;
    transition: transform 0.3s ease;
}

.fixed-nav-bar.hidden {
    transform: translateY(100%);
}

.fixed-nav-content {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    gap: 20px;
}

.fixed-chapter-selector {
    flex-grow: 1;
    max-width: 400px;
}

.fixed-chapter-dropdown {
    width: 100%;
    padding: 12px 16px;
    border: 3px solid var(--border-line);
    background: var(--accent-color);
    color: black;
    font-size: 14px;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

/* Scroll to top button */
.scroll-top-btn {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--body-bg);
    border: 3px solid var(--border-line);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
    z-index: 999;
}

.scroll-top-btn:hover {
    transform: translateY(-5px);
    background-color: var(--highlight);
    border-color: var(--highlight);
}

.scroll-top-btn.hidden {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.8);
}

/* Adjust body padding to prevent content from being hidden behind fixed nav */
body {
    padding-bottom: 70px; /* Height of fixed nav + some extra */
}

/* Responsive adjustments for fixed nav */
@media (max-width: 768px) {
    .fixed-nav-content {
        padding: 0 15px;
        gap: 10px;
    }

    .fixed-chapter-dropdown {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .scroll-top-btn {
        bottom: 100px;
        right: 15px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
    
    body {
        padding-bottom: 65px;
    }
}

@media (max-width: 480px) {
    .fixed-nav-content {
        padding: 0 10px;
        gap: 8px;
    }

    .fixed-chapter-dropdown {
        padding: 8px 10px;
        font-size: 12px;
    }

    .scroll-top-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}