/* 阅读页 — 导航与全站一致，阅读区深色沉浸 */

.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #FF8A66, #FF6382);
    z-index: 201;
    width: 0%;
    transition: width 0.1s;
}

.reader-bar {
    position: sticky;
    top: 57px;
    z-index: 99;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(192, 132, 252, 0.18);
    padding: 0.55rem 1.2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.reader-bar.hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.reader-bar-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.reader-back {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(192, 132, 252, 0.12);
    color: #562B7C;
    text-decoration: none;
    font-size: 1rem;
    flex-shrink: 0;
    transition: 0.2s;
}

.reader-back:hover {
    background: rgba(192, 132, 252, 0.22);
    color: #E25E8C;
}

.reader-info {
    min-width: 0;
}

.reader-info h3 {
    font-size: 0.88rem;
    font-weight: 700;
    color: #2D1B4E;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reader-info p {
    font-size: 0.68rem;
    color: #7D669E;
    margin-top: 2px;
}

.reader-tool {
    padding: 6px 14px !important;
    font-size: 0.75rem !important;
    border-radius: 20px !important;
}

.reader-wrap {
    background: #1a1528;
}

.reader-container {
    max-width: 800px;
    margin: 0 auto;
    padding-bottom: 72px;
}

.page-list {
    display: flex;
    flex-direction: column;
}

.page-item {
    width: 100%;
    display: block;
    background: #0f0c18;
}

.page-item img {
    width: 100%;
    display: block;
    min-height: 200px;
    background: #2a2240;
}

.page-label {
    text-align: center;
    padding: 6px;
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.35);
    background: #0f0c18;
}

.chapter-end {
    text-align: center;
    padding: 2.5rem 1rem 3rem;
    color: rgba(255, 255, 255, 0.55);
    background: #1a1528;
}

.chapter-end h4 {
    font-size: 1rem;
    color: #FF9A76;
    margin-bottom: 0.6rem;
}

.end-actions {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.end-btn.outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #fff;
}

.reader-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 150;
    background: rgba(255, 245, 250, 0.92);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(192, 132, 252, 0.2);
    padding: 0.55rem 1.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.3s ease;
}

.reader-bottom.hidden {
    transform: translateY(100%);
}

.chapter-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(192, 132, 252, 0.12);
    border: 1px solid rgba(192, 132, 252, 0.25);
    color: #562B7C;
    padding: 8px 14px;
    border-radius: 24px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s;
}

.chapter-nav-btn:hover {
    background: rgba(192, 132, 252, 0.2);
    color: #E25E8C;
}

.chapter-nav-btn.disabled {
    opacity: 0.35;
    pointer-events: none;
}

.page-indicator {
    font-size: 0.75rem;
    color: #7D669E;
    font-weight: 600;
}

.scroll-hint {
    position: fixed;
    bottom: 68px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(105deg, #FF8A66, #FF6382);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.7rem;
    z-index: 140;
    animation: readerBounce 2s infinite;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s;
    box-shadow: 0 6px 16px rgba(255, 99, 130, 0.35);
}

.scroll-hint.show {
    opacity: 1;
}

@keyframes readerBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-6px); }
}

.loading-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 50vh;
    color: rgba(255, 255, 255, 0.5);
    gap: 1rem;
}

.loading-page a {
    color: #FF9A76;
}

@media (max-width: 640px) {
    .reader-bar {
        top: 52px;
        padding: 0.5rem 1rem;
    }
    .reader-info h3 {
        font-size: 0.8rem;
    }
    .chapter-nav-btn {
        padding: 7px 10px;
        font-size: 0.72rem;
    }
}
