/* =====================================================
DISSERTA — MODE SOMBRE (automatique selon le réglage du téléphone)
Fichier généré à partir des autres feuilles : les couleurs claires
sont remplacées par leurs équivalents sombres. Les retouches faites
à la main sont à la fin du fichier.
===================================================== */

@media (prefers-color-scheme: dark) {
::selection { background: #172239; color: #b9cdff; }
.brand-name { color: #b9cdff; }
.header-message i { color: #86a8ff; }
.desktop-nav { background: #181c25; }
.nav-link:hover, .nav-link.active { color: #86a8ff; background: #191d29; }
.section-icon { color: #86a8ff; }
.hero-button { color: #b9cdff; background: #181c25; }
.sidebar-category-icon, .sidebar-post-thumbnail { background: var(--illustration-bg, #1b212c); }
.sidebar-welcome { background: linear-gradient(145deg, #181c25, #1a202b); border-color: #2b3550; }
.sidebar-eyebrow { color: #86a8ff; }
.sidebar-welcome h2 { color: #b9cdff; }
.sidebar-heading-icon { color: #86a8ff; }
.sidebar-category-item:hover { background: #1c1f27; }
.sidebar-category-count { background: #1c212c; }
.sidebar-post-item { border-bottom: 1px solid #383c42; }
.sidebar-post-category { color: #86a8ff; }
.sidebar-post-item:hover .sidebar-post-title { color: #86a8ff; }
.sidebar-more-link { color: #86a8ff; }
.sidebar-empty { background: #1a1e29; }
.footer-more { color: #86a8ff; }
.site-footer { background: #181c25; }
.footer-motto { color: #86a8ff; }
.footer-heading > i { color: #86a8ff; }
.footer-subject-icon { color: #86a8ff; }
.footer-subject-list li a:hover .footer-subject-title { color: #86a8ff; }
.footer-menu a:hover { color: #86a8ff; }
.footer-mission { background: linear-gradient(145deg, #1a1f2b, #181c25); border: 1px solid #2b3550; }
.footer-bottom { background: #1a1e29; }
.footer-bottom-inner strong { color: #b9cdff; }
.footer-credit a { color: #86a8ff; }
.btn-outline { color: #86a8ff; background: #181c25; border: 1px solid #2f384b; }
input, select, textarea { background: #181c25; border: 1px solid #373c43; }
.announcement-actions .btn-light { color: #b5c4ed; background: #181c25; }
.announcement-book { color: #b2bee8; background: linear-gradient(145deg, #181c25, #151b34); }
.section-heading h2 { color: #cbd1e0; }
.section-more:hover, .card-read-more:hover { color: #9aa9e9; }
.home-content-card { background: #181c25; border: 1px solid #363a44; }
.home-card-body h3 { color: #c7cedd; }
.categories-section { background: #1c1e26; border: 1px solid #353a45; }
.home-category-card { color: #c5ccdc; background: #181c25; border: 1px solid #363a44; }
.home-category-card:hover { border-color: #2b3150; }
.category-icon-1 { background: #1e1b2d; }
.category-icon-2 { color: #95c6f1; background: #162535; }
.category-icon-3 { color: #eeb691; background: #382817; }
.category-icon-4 { color: #b6f9ed; background: #1e342d; }
.category-icon-5 { color: #e394be; background: #341524; }
.btn-outline { background: #181c25; border: 1px solid #2f354b; }
.btn-outline:hover { background: #1a1c2b; border-color: #2b3150; }
.home-empty-state { background: #1c1e26; border: 1px dashed #373a43; }
.home-empty-state h3 { color: #c2c9da; }
.home-cta { background: linear-gradient(110deg, #1a1e2b, #181b28); border: 1px solid #2b3250; }
.home-cta-icon { background: #181c25; }
.home-cta-content h2 { color: #c6ccdd; }
.listing-decoration-card { color: #b2bee7; background: linear-gradient(145deg, #181c25, #151c34); border: 1px solid rgba(61, 61, 61, 0.7); }
.listing-decoration-lines span { background: #1e2336; }
.listing-section-heading h2 { color: #c9d0de; }
.listing-result-count { background: #1a1c2b; }
.listing-search { background: #181c25; border: 1px solid #373a43; }
.listing-search input { color: #c5ccdc; }
.listing-course-card { background: #181c25; border: 1px solid #363b44; }
.listing-course-tag { background: #1a1c2c; }
.listing-course-body h3 { color: #c7cedd; }
.listing-course-link:hover { color: #9aa8e8; }
.listing-pagination a, .listing-pagination > span:not(.pagination-dots) { color: #adb6cb; background: #181c25; border: 1px solid #363a44; }
.listing-pagination a:hover { background: #1a1c2b; }
.listing-message { background: #1c1e26; border: 1px dashed #373a43; }
.listing-empty-icon { background: #1b1e2d; }
.listing-message h3 { color: #c5ccdc; }
.listing-error > i { color: #f5c083; }
.listing-bottom-banner { background: linear-gradient(110deg, #1a1e2b, #181b28); border: 1px solid #2b3250; }
.listing-bottom-icon { background: #181c25; }
.listing-bottom-banner h2 { color: #c5ccdc; }
.subjects-category-chip { color: #a8b1c3; background: #181c25; border: 1px solid #373b44; }
.subjects-category-chip > span { background: #1c212c; }
.subjects-category-chip:hover { background: #191b2a; border-color: #2b3150; }
.subjects-category-chip.active > span { background: #181c25; }
.reading-breadcrumb a { color: #a2a6b8; }
.reading-art-book { border: 1px solid rgba(61, 61, 61, 0.65); background: linear-gradient(145deg, #181c25, #1c1738); }
.reading-art-book-line { background: #272441; }
.reading-article { border: 1px solid #383842; background: #181c25; }
.reading-article-heading { border-bottom: 1px solid #383842; }
.reading-heading-icon { background: #1e1b2c; }
.reading-article-heading h2 { color: #c6c5dc; }
.reading-section { border-bottom: 1px solid #393942; }
.reading-section-number { background: #1e1b2c; }
.reading-section-title h3 { color: #c6c4dc; }
.reading-text { color: #aeb0c1; }
.reading-end-note { border: 1px solid #494332; background: #2c271a; }
.reading-end-icon { background: #42381b; color: #efce8e; }
.reading-end-note h3 { color: #ecdfc4; }
.reading-end-note p { color: #c6bba6; }
.reading-side-card { border: 1px solid #383842; background: #181c25; }
.reading-progress-card { background: linear-gradient(145deg, #1e1a2c, #181c25); }
.reading-side-icon { background: #1d173a; }
.reading-side-card h3 { color: #c5c3db; }
.reading-side-link { border-top: 1px solid #35304a; }
.reading-quick-icon { background: #1e1b2c; }
.reading-quick-icon-orange { background: #352216; }
.reading-quick-links strong { color: #bfbed6; }
.reading-related-heading h2 { color: #c6c4dc; }
.reading-related-card { border: 1px solid #383842; background: #181c25; }
.reading-related-art { background: linear-gradient(135deg, #1e1b2d, #1d183b); }
.reading-related-art-2 { background: linear-gradient(135deg, #352316, #422c1b); }
.reading-related-art-3 { background: linear-gradient(135deg, #1e3129, #273e35); color: #a1dac5; }
.reading-related-info h3 { color: #c5c3db; }
.reading-related-link { border-top: 1px solid #393942; }
.reading-not-found { border: 1px solid #383842; background: #181c25; }
.reading-not-found-icon { background: #1e1b2c; }
.reading-not-found h1 { color: #c5c3db; }
.about-page { color: #c5c3db; }
.about-hero-actions .btn { background: #181c25; color: #998fd9; }
.about-main-book { border: 1px solid rgba(61, 61, 61, 0.6); background: linear-gradient(145deg, #181c25, #1c1738); }
.about-book-spine { border-right: 1px solid #332e4c; background: #211c44; }
.about-book-line { background: #272341; }
.about-floating-card { background: rgba(24, 28, 37, 0.95); color: #c1bdd7; }
.about-card-bottom i { color: #9bdfc6; }
.about-stat { border: 1px solid #383842; background: #181c25; }
.about-stat-icon.purple { background: #1e1b2c; }
.about-stat-icon.orange { background: #352216; }
.about-stat-icon.green { background: #1e3229; color: #9cdfc5; }
.about-stat strong { color: #c5c3db; }
.about-section-illustration { border: 1px solid #302b50; background: linear-gradient(145deg, #1e1a2b, #181c25); }
.about-idea-circle { border: 1px solid #302b50; }
.about-idea-bubble { border: 4px solid #3d3d3d; background: #352216; }
.bubble-two { background: #1e3229; color: #9cdfc5; }
.bubble-three { background: #1b1636; }
.about-section-text h2, .about-centered-heading h2 { color: #c5c3db; }
.about-section-text p { color: #9ea0b0; }
.about-benefit-card { border: 1px solid #383842; background: #181c25; }
.about-benefit-icon.violet { background: #1e1b2c; }
.about-benefit-icon.peach { background: #352216; }
.about-benefit-icon.mint { background: #1e3229; color: #9cdfc5; }
.about-benefit-card h3 { color: #c5c3db; }
.about-how-section { border: 1px solid #383842; background: #1b1828; }
.about-step { border: 1px solid #302b50; background: #181c25; }
.about-step-icon { background: #1e1b2c; }
.about-step h3 { color: #c5c3db; }
.about-final-cta { border: 1px solid #302b50; background: linear-gradient(120deg, #1e1a2b, #181c25); }
.about-final-cta-icon { background: #1d1738; }
.about-final-cta-text h2 { color: #c5c3db; }
.privacy-page { color: #c5c3db; }
.privacy-art-tag { background: #181c25; color: #c1bdd7; }
.privacy-art-tag i { color: #9cdfc5; }
.privacy-intro-card { border: 1px solid #302b50; background: linear-gradient(120deg, #1e1a2b, #181c25); }
.privacy-intro-icon { background: #1c1738; }
.privacy-intro-card h2 { color: #c5c3db; }
.privacy-toc { border: 1px solid #383842; background: #181c25; }
.privacy-toc-title { border-bottom: 1px solid #383842; color: #c5c3db; }
.privacy-toc > a { color: #9ea0b0; }
.privacy-toc > a:hover { background: #1e1b2c; }
.privacy-content { border: 1px solid #383842; background: #181c25; }
.privacy-section { border-bottom: 1px solid #393942; }
.privacy-section-icon.violet { background: #1e1b2c; }
.privacy-section-icon.orange { background: #352216; }
.privacy-section-icon.green { background: #1e3229; color: #9cdfc5; }
.privacy-section-icon.blue { background: #152434; }
.privacy-section-heading h2 { color: #c5c3db; }
.privacy-section > p, .privacy-section > ul { color: #a1a2b2; }
.privacy-section h3 { color: #bbb9d2; }
.privacy-note { border: 1px solid #302b50; background: #1c1929; }
.privacy-note p { color: #a19eb5; }
.privacy-contact-section { border: 1px solid #302b50; background: linear-gradient(145deg, #1e1a2b, #181c25); }
.privacy-contact-icon { background: #1d1738; }
.privacy-contact-section h2 { color: #c5c3db; }
.privacy-bottom-banner { border: 1px solid #383842; background: #181c25; }
.privacy-bottom-icon { background: #1e1b2c; }
.privacy-bottom-banner h2 { color: #c5c3db; }
.espace-solde .btn { background: #181c25; color: #b9cdff; }
.espace-solde .btn:hover { color: #b9cdff; }
.espace-formulaire textarea, .espace-formulaire input, .espace-formulaire select { background: #1b1f26; border: 1px solid #363c44; }
.espace-formulaire textarea:focus, .espace-formulaire input:focus, .espace-formulaire select:focus { background: #181c25; }
.espace-message.erreur { background: #311818; color: #e69ea1; }
.espace-message.succes { background: #203029; color: #bed8ce; }
.espace-message.info { color: #b9cdff; }
.espace-liste-icone { background: #1e1b2c; }
.espace-liste-texte a:hover { color: #86a8ff; }
.espace-badge { background: #21252b; }
.espace-badge.publie, .espace-badge.valide { background: #203029; color: #bed8ce; }
.espace-badge.attente, .espace-badge.en_attente { background: #382c17; color: #f8d8aa; }
.espace-badge.refuse { background: #311818; color: #e69ea1; }
.espace-pack-credits { color: #b9cdff; }
.espace-etapes li::before { color: #86a8ff; }
.espace-numero { background: #1b1f26; border: 1px dashed #353b45; }
.espace-avantage i { color: #86a8ff; }
.footer-whatsapp { color: #bed8ca; background: #1f3126; }
.footer-whatsapp i { color: #99ecbc; }
.lecture-sommaire a:hover, .lecture-sommaire a.actif { color: #86a8ff; }
.lecture-sommaire a.actif::before { color: #86a8ff; }
.reading-copie .reading-text { color: #babfd5; background-color: #292519; background-image: linear-gradient(90deg, transparent 17px, rgba(229, 72, 77, 0.45) 17px, rgba(229, 72, 77, 0.45) 18.5px, transparent 18.5px),
    repeating-linear-gradient(180deg, transparent 0 31px, #232833 31px 32px); border: 1px solid #454136; }
.copie-note { color: #f6ab8d; background: #352716; }
}

@media (prefers-color-scheme: dark) and (max-width: 760px) {
.footer-mission { border: 1px solid #2b3550; }
.mobile-bottom-nav { background: rgba(24, 28, 37, 0.97); border-top: 1px solid #373b43; }
.mobile-nav-item.active { color: #86a8ff; }
.mobile-nav-item.active .mobile-nav-icon { background: #1b212c; }
}

/* -----------------------------------------------------
Retouches à la main
----------------------------------------------------- */

@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;

        --primary-light: #1c2740;

        --text: #e4e8f1;
        --text-light: #a9b3c6;
        --muted: #7d889c;

        --background: #0f131a;
        --surface: #181c25;
        --border: #2a3140;

        --shadow-sm: 0 3px 12px rgba(0, 0, 0, 0.3);
        --shadow-md: 0 8px 28px rgba(0, 0, 0, 0.35);
    }

    .site-header,
    .mobile-bottom-nav {
        background: rgba(24, 28, 37, 0.97);
        border-color: var(--border);
    }

    .brand-name,
    .footer-brand .brand-name {
        color: #e4e8f1;
    }

    .brand-name span {
        color: #7fa4ff;
    }

    /* Copie d'élève : papier sombre, lignes discrètes */
    .reading-copie .reading-text {
        color: #dfe3ec;
        background-color: #1b1f28;
        background-image:
            linear-gradient(90deg, transparent 17px, rgba(229, 72, 77, 0.55) 17px, rgba(229, 72, 77, 0.55) 18.5px, transparent 18.5px),
            repeating-linear-gradient(180deg, transparent 0 31px, rgba(255, 255, 255, 0.07) 31px 32px);
        border-color: #2a3140;
    }

    .copie-note {
        color: #fdba74;
        background: rgba(251, 146, 60, 0.12);
    }

    .footer-whatsapp {
        color: #b7ebc8;
        background: rgba(31, 170, 89, 0.14);
    }

    .espace-badge.publie,
    .espace-badge.valide,
    .espace-message.succes {
        color: #9be3bd;
        background: rgba(21, 155, 105, 0.16);
    }

    .espace-badge.attente,
    .espace-badge.en_attente {
        color: #fcd38d;
        background: rgba(245, 158, 11, 0.15);
    }

    .espace-badge.refuse,
    .espace-message.erreur {
        color: #fca5a8;
        background: rgba(229, 72, 77, 0.16);
    }

    .espace-numero,
    .espace-formulaire textarea,
    .espace-formulaire input,
    .espace-formulaire select {
        background: #141821;
        border-color: #2f3747;
    }

    .espace-liste-icone {
        background: #231f3d;
    }

    .sidebar-post-thumbnail,
    .sidebar-category-icon {
        filter: brightness(0.82) saturate(1.1);
    }
}
