/* ============================================================
   CoursGest — préparation des animations (anime.js)
   Les éléments sont masqués uniquement lorsque html.cg-motion est posé.
   Cette classe est ajoutée par le script inline de <head>, puis retirée par
   animations.js dès que les animations d'entrée sont lancées (ou par un
   filet de sécurité au bout de 3 s). Le contenu plus bas dans la page n'est
   donc jamais conditionné à un défilement.
   Sans JavaScript, ou avec prefers-reduced-motion, rien n'est masqué.
   ============================================================ */

html.cg-motion .sidebar-brand,
html.cg-motion .sidebar-section,
html.cg-motion .sidebar-link,
html.cg-motion .sidebar-footer,
html.cg-motion .topbar,
html.cg-motion .content > .alert,
html.cg-motion .page-header,
html.cg-motion .content .card:not(#ctx-menu),
html.cg-motion .content .stat-card,
html.cg-motion .day-head,
html.cg-motion .calendar-event-row,
html.cg-motion .login-art-brand,
html.cg-motion .login-art h2,
html.cg-motion .login-art p,
html.cg-motion .login-card {
    opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
    html.cg-motion .sidebar-brand,
    html.cg-motion .sidebar-section,
    html.cg-motion .sidebar-link,
    html.cg-motion .sidebar-footer,
    html.cg-motion .topbar,
    html.cg-motion .content > .alert,
    html.cg-motion .page-header,
    html.cg-motion .content .card:not(#ctx-menu),
    html.cg-motion .content .stat-card,
    html.cg-motion .day-head,
    html.cg-motion .calendar-event-row,
    html.cg-motion .login-art-brand,
    html.cg-motion .login-art h2,
    html.cg-motion .login-art p,
    html.cg-motion .login-card {
        opacity: 1;
    }
}

/* L'impression ne doit jamais dépendre d'une animation déclenchée au défilement. */
@media print {
    html.cg-motion .sidebar-brand,
    html.cg-motion .sidebar-section,
    html.cg-motion .sidebar-link,
    html.cg-motion .sidebar-footer,
    html.cg-motion .topbar,
    html.cg-motion .content > .alert,
    html.cg-motion .page-header,
    html.cg-motion .content .card:not(#ctx-menu),
    html.cg-motion .content .stat-card,
    html.cg-motion .day-head,
    html.cg-motion .calendar-event-row,
    html.cg-motion .login-art-brand,
    html.cg-motion .login-art h2,
    html.cg-motion .login-art p,
    html.cg-motion .login-card {
        opacity: 1 !important;
        transform: none !important;
    }
}
