/* Toits etc — DJ-Accessibility, retour en haut de page.
   Feuille issue de user.scss (sortie du SCSS, 2026-11-30).
   CSS natif, hors @layer : il doit l'emporter sur Cassiopeia à spécificité égale, comme user.css.
   Ordre de chargement significatif : voir templates/index.php. */

/* ---------------------- MODULES */

/* DJ accessibility */

@media screen and (width < 768px) {
    .djacc--sticky.djacc-popup {
        margin: 15px !important;
    }
}

.djacc__close {
    & svg {
        width: 1.6rem;
        height: fit-content;
    }

    & line {
        stroke-width: 3;
    }
}

.djacc-popup .djacc__bar::after {
    border: 4px solid var(--couleur-rouge) !important;
}

.djacc-popup.djacc--light .djacc__arrows:hover,
.djacc-popup.djacc--light .djacc__btn:hover {
    border-color: transparent !important;
}

.djacc__title {
    color: var(--couleur-violet) !important;
    font-family: "titres";
    font-weight: 500 !important;
}

.djacc-popup .djacc__footer-link:hover {
    color: var(--couleur-noir) !important;
}

.djacc__footer-link,
.djacc__footer-links {
    font-size: 1.4rem !important;
    line-height: 2.6rem !important;
}

.djacc__footer-logo {
    background-image: none !important;
    padding-bottom: 0 !important;
}

.djacc a {
    padding-bottom: 0.5em;
    display: inline !important;
    border-bottom: none !important;
}

.djacc :is(span, a, div) {
    font-size: 1.6rem;
    line-height: 1.6rem;
}

@media screen and (width>=768px) {
    .djacc-popup .djacc__panel {
        width: 568px !important;
        padding: 16px 32px !important;
    }
}



.djacc-popup .djacc__openbtn--default {
    background-color: var(--couleur-bleu) !important;

    &:hover {
        margin: unset !important;
        outline: 4px solid white;
    }
}

.djacc-popup .djacc__close,
.djacc-popup.djacc--light .djacc__btn:hover,
.djacc-popup.djacc--light .djacc__arrows:hover,
.djacc-popup.djacc--light .djacc__btn--active {
    background-color: var(--couleur-bleu) !important;
    color: var(--couleur-blanc) !important;
}

.djacc-popup .djacc__bar::before {
    background-color: var(--couleur-rouge) !important;
}

.djacc__item--full {

    :is(.djacc__inc:hover, .djacc__dec:hover) {
        transform: scale(1.6);
    }

    &:hover {
        :is(.djacc__inc, .djacc__dec) {
            border: none !important;
            color: var(--couleur-blanc) !important;
        }

        & line {
            stroke: var(--couleur-blanc) !important;
        }
    }


}

.djacc-popup.djacc--light {
    filter: drop-shadow(0 2px 4px #00000066);

    .djacc__btn:hover {

        & svg g,
        [stroke^="#"] {
            stroke: var(--couleur-blanc) !important;
        }

        & svg :is(path, rect:not([fill="none"]), g:not([fill="none"]) *) {
            fill: var(--couleur-blanc) !important;
        }
    }

    .djacc__btn--highlight-titles:hover {

        & svg g,
        & svg rect[stroke="none"] {
            fill: none !important;
        }
    }
}

.djacc-popup .djacc__percent {
    opacity: 1 !important;
}




/* Retour haut de page */
.module-retour-haut-page {
    position: fixed;
    bottom: 0;
    right: 0;
    width: 4.4rem;
    height: 4.4rem;


    filter: drop-shadow(0 2px 4px #00000066);
    z-index: 1;
    display: none;

    >div {
        width: 100%;
        height: 100%;
        background: var(--couleur-bleu);
        clip-path: polygon(6% 16%, 115% 25%, 115% 109%, 14.91% 110.64%);

        &:after {
            content: "";
            background-image: url("../images/chevron-bas.svg");
            width: 100%;
            height: 100%;
            background-repeat: no-repeat;
            background-size: contain;
            background-size: 85% 83%;
            background-position-x: center;
            position: absolute;
            top: 2px;
            left: 2px;
            transform: scaleY(-1);
            filter: brightness(6.7);
        }
    }

    @media (width>=992px) {
        display: block;
    }

    & a:hover::after,
    & a:focus-visible::after {
        display: block;
    }

    & a {
        color: transparent;
        position: absolute;
        top: 0;
        right: 0;
        z-index: 9999;
        background-image: none;

        &:focus {
            color: transparent !important;
        }

        &:after {
            content: attr(data-title);
            width: max-content;
            position: absolute;
            background: var(--couleur-bleu);
            color: var(--couleur-blanc);
            border-radius: var(--radius-petit);
            height: fit-content;
            padding: var(--spacing-xxxpetit) var(--spacing-xpetit);
            bottom: 14rem;
            right: 6rem;
            z-index: 10;
            display: none;
        }
    }


}
