html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-weight: normal;
    font-size: 12pt;
    color: var(--noir);
}

:root{
    --gris-f:#a7a7a7;
    --gris-m:#CECECE;
    --gris-c:#EFEFEF;
    --noir:#262626;
    --blanc:#ffffff;
}

body {
    background: white;
    font-family: "arial", sans-serif;
    min-height: 100%;
}

header h1 {
    font-size: 31pt;
    font-weight: bold;
    padding-bottom: 5px;    
}

header {
    border-bottom: solid 5px var(--noir);
    width: 75%;
    margin: 100px auto 50px;
}

main {
    margin: auto;
    margin-top: 35px;
}

main {
    margin-top: 120px;
}

main .carte:nth-child(3n+1),
#nav a:nth-child(3n+1) {
    background: var(--gris-c);
}

main .carte:nth-child(3n+2),
#nav a:nth-child(3n+2) {
    background: var(--gris-m);
}

#video {
    display: flex;
    justify-content: center;
    width: 75%;
    margin: auto;
    margin-bottom: 70px;
}

#video a img {
    aspect-ratio: 16/9;
    width: 100%;
}

#nav {
    margin: 40px auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(135px, 1fr));
    grid-gap: 5px 0;
    width: 75%;
}

#nav a {
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--gris-f);
    font-size: 12pt;
    text-decoration: none;
    text-align: center;
    height: 45px;
}

#nav a:hover {
    font-weight: 600;
}

.afficher {
    overflow: hidden;
    height: 0;
}

.cartes{
    display: flex;
    flex-wrap: wrap;
}

.carte {
    background-color: var(--gris-f);
    padding: 50px 12%;
    width: 50%;
}

.carte h2 {
    font-size: 19pt;
    font-weight: bold
}

.carte .parenthese {
    font-style: italic;
}

.carte p {
    margin-bottom: 16px;
}

.contenu_carte {
    padding-bottom: 4px;
}

.contenu_carte h3 {
    font-weight: bold;
    margin-bottom: 12px;
}

.meta_file {
    color: red;
}

/*-----Bouton-----*/

.boutton {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--gris-m);
    height: 35px;
    padding-left: 10px;
    width: 75%;
    margin: auto;
    cursor: pointer;
}

.boutton h3 {
    font-weight: bold;
}

.boutton .fleche {
    background: var(--gris-f);
    height: 35px;
    width: 35px;
}

#scrollToTopButton {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    font-size: 18px;
    background-color: var(--blanc);
    color: white;
    border: solid 1px var(--noir);
    outline: none;
    cursor: pointer;
    padding: 15px;
    border-radius: 50px;
    opacity: 0;
    transition: opacity 0.3s;
    height: 50px;
    width: 50px;
}

#scrollToTopButton.show {
    display: block;
    opacity: 1;
    transition: opacity 0.3s;
}

#scrollToTopButton:hover {
    background-color: var(--blanc);
    color: var(--color-vert);
}

/*-----FOOTER-----*/

footer {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
    background: black;
    position: relative;
    bottom: 0px;
}

footer p {
    color: white;
}

@media screen and (max-width: 991px) {

    .carte {
        background-color: var(--gris-f);
        padding: 50px 12%;
        width: 100%;
    }
}

@media screen and (max-width: 768px) {
 
    #video {
        display: block;
    }
}