/* Styles pour la page de lecture BD */
.bd-reader {
    min-height: 100vh;
    background: white;
    color: #ffffff;
}

/* Support du mode sombre */
@media (prefers-color-scheme: dark) {

    .bd-reader,
    .bd-header,
    .bd-title {
        background-color: var(--pico-background-color) !important;
    }
}

/* En-tête */
.bd-header {
    position: sticky;
    top: 0;
    background: white;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 10;
    padding: 0.3rem 2rem 0.5rem 2rem;
}

.bd-header-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.bd-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

/* Galerie d'images */
.bd-gallery {
    display: flex;
    flex-direction: column;
    align-items: center;
    /* gap: 2rem; */
    gap: 0rem;
    padding: 2rem;
}

.bd-page {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    background: #1a1a1a;
    overflow: hidden;
    margin-bottom: 1.25rem;
}

.bd-image-container {
    width: 100%;
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
}

.bd-image {
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.bd-caption {
    padding: 1rem;
    background: #2d2d2d;
    color: #e2e8f0;
    font-size: 0.9rem;
    text-align: center;
    border-top: 1px solid #404040;
}

/* Texte de référence */
.bd-reference {
    border-top: 1px solid rgba(102, 126, 234, 0.3);
    padding: 3rem 2rem;
    margin-top: 2rem;
}

.bd-reference-content {
    max-width: 900px;
    margin: 0 auto;
}

.bd-reference-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #667eea;
    text-align: center;
}

.bd-reference-text {
    font-size: 1rem;
    line-height: 1.8;
    color: #e2e8f0;
    background: rgba(0, 0, 0, 0.3);
    padding: 2rem;
    border-radius: 0.5rem;
    border-left: 4px solid #667eea;
}

.bd-reference-text p,
.bd-reference-text ul,
.bd-reference-text li {
    margin-bottom: 1rem;
    color: white;
}

.bd-reference-text p:last-child {
    margin-bottom: 0;
}

/* Bouton retour en haut */
/* Bouton retour en haut */
.scroll-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    font-size: 2rem;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.6);
}


/* Responsive */
@media (max-width: 768px) {
    .bd-header {
        padding: 0.15rem 1rem 0.3rem 1rem;
    }

    .bd-title {
        font-size: 1.35rem;
    }

    .bd-gallery {
        padding: 1rem;
        /* gap: 1rem; */
        gap: 0rem;
    }

    .bd-caption {
        font-size: 0.8rem;
        padding: 0.75rem;
    }

    .bd-reference {
        padding: 2rem 1rem;
    }

    .bd-reference-text {
        padding: 1rem;
        font-size: 0.9rem;
    }

    .scroll-top {
        bottom: 1rem;
        right: 1rem;
        width: 48px;
        height: 48px;
    }
}

@media (max-width: 480px) {
    .bd-title {
        font-size: 1.125rem;
    }

    .bd-reference-content h3 {
        font-size: 1.25rem;
    }

    .bd-reference-text {
        font-size: 0.85rem;
        line-height: 1.6;
    }
}