html {
    scroll-behavior: smooth;
    background-color: #833AB4;
    background: linear-gradient(180deg, rgba(131, 58, 180, 1) 0%, rgba(253, 29, 29, 1) 90%, rgba(252, 112, 69, 1) 100%);
}

header {
    background: transparent;
}

input[type=text]::before {
    content: var(--inputTxt, "");
    color: var(--inputColor, #550000);
    font-weight: bold;
}

input[type=text]:valid {
    --inputTxt: "✓";
    outline: 2px solid lightgreen;
    background: #aaff7f;
    font-weight: bold;
    color: #005500;
}

input[type=text]:invalid {
    --inputTxt: "✖";
    background: #ffe0dd;
}

/* Pour indiquer à quoi sert le checkbox */
/* Seulement lorsque :not(quiz) */
div:not(.quiz) label:has( .hint):before {
    content: "indice ?";
    font-size: small;
    font-weight: bold;
    color: var(--box-border);
}


label:has(input[type=checkbox]:checked) >  .hint {
    visibility: visible;
    width: auto;
    height: auto;
    margin: auto;
    opacity: 1;
}


.quiz {
    /* TODO si :not(correct) et input:checked ajout strikethrough sur li/label*/
    .correct {transition: all 0.5s ease;}

    label:has(input[type=checkbox]:checked):not(:has(.correct)) {
        color: darkred;
        opacity: 0.5;
        text-decoration: line-through 1.5pt;
    }

    input[type=checkbox]:checked:has(+ .correct) {
        & + .correct {
            color: green;
            font-weight: bold;
            font-size: larger;
        }
        & + .correct:after {
                content: "🎉";
        }
    }
}

#top {
    position: sticky;
    z-index: 100;
    top: 95vh;
    left: 97vw;
    font-size: 200%;
    & :hover {
        font-size: larger;
    }
}

table tbody tr:hover {
    font-weight: bold;
    color: #222;
    background: #ade!important;
}

/******************************/
/* APPARENCE DU SLIDESHOW */
/******************************/
.slideshow {
    width: inherit;
    overflow: hidden;
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    align-items: flex-start;

    /* Seulement les descendants directs */
    & >:is(div, section) {
        scroll-snap-align: start;
        max-width: 90%;
        padding: 0.5em;
        border-radius: 10px;
        background: var(--bg-slide, #eee);
        flex-shrink: 0;
        display : block;
        margin: inherit auto;
    }

    & >div:nth-child(odd) { --bg-slide: #b1eebd;}

    & >:is(div,section):not(:last-child):after {
        content: " ➡";
        position: relative;
        left: 95%;
        top: 95%;
        color: var(--box-border, black);
        font-size: 150%;
        font-weight: bold;
    }
    & >:is(div, section):not(:first-child):before {
        content: "⬅ " var(--box-name, "");
        color: var(--box-border, black);
        font-size: 150%;
        font-weight: bold;
    }

    & > .slide ol li::marker {
        font-weight: bold;
        font-size: 3em;
        color: darkorchid;
    }
}

#mainMenu {
    position: sticky;
    top: 0;
    width: fit-content;
    left: 5px;
    border-radius: 5px;
/*     margin: auto; */
/*     text-align: center; */
    min-height: 1.5em;
    padding: 0;
    background: #e8e8e8;
    border-bottom: 1px solid black;
    box-shadow: 0 8px 6px -6px grey;

    & > label {padding: 2em 1em;}

    ul {
        position: relative;
        padding: 0;
        margin: 0;
        left: -100vw ;
        z-index: -1;
        max-height: 0;
        max-width: 0;
        overflow-y: scroll;
        overflow-x: clip;
        transition: 0.5s ease;
        li {
/*             background: hsla(200, 50%, 60%, 0.4); */
            list-style: none;
            padding: 0.5em;
        }
        & li:hover {
            background: hsla(280, 76%, 45%, 0.3);
        }
    }
   .menuBtn {
       display: none!important;
       & ~ label:before {
            content: /*"☰ "*/ "❭";
            font-weight: bold;
            padding: 3px;
        }
    }
    .menuBtn:checked {
        &~ label:before{ content: "✕ "; }
        & ~ ul {
            display: revert;
            z-index: 50;
            max-height: min(250px, 100vh);
            max-width:  min(250px, 100vw);
            left: 0;
        }
    }
    label {cursor: pointer;}
}

/*****************************************/
/* ANIMATION LORS OUVERTURE DETAILS */
/*****************************************/
/*::details-content {
  transition: height 0.5s ease, content-visibility 0.5s ease allow-discrete;
  height: 0;
  overflow: clip;
}*/
