:root {
    --color-piok: #D03F15;
    --color-sgdf: #003A5D;
}

html, body {width: 100%; height: 100%; margin: 0;}
html {font-family: Inter,SF Pro,Segoe UI,Roboto,Oxygen,Ubuntu,Helvetica Neue,Helvetica,Arial,sans-serif;}
body.scroll {overflow: hidden;}

/* GLOB */
p {padding: 0; margin: 0;}
a {text-decoration: none; color: inherit;}
.contenu:after {
    content: '';
    display: block;
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    left: 0;
    opacity: 25%;
    background-image: url('../images/piok.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    z-index: -1;
}
.input {
    display: flex;
    margin-bottom: 1rem;
}
.input input, .input select {
    margin-right: .5rem;
    border-radius: .25rem;
    border: 1px solid gray;
    padding: .25rem;
}
label:has(+ .input) {
    font-size: 1rem;
}
/* FIN GLOB */

.adm {
    margin: 1rem;
}

nav {
    position: relative;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    padding: 0.5rem;
    background-color: white;
    color: var(--color-piok);
    box-shadow: 0 0.2rem 0.01rem 0 var(--color-piok);
}
nav>.nav-titre {
    display: flex; 
    flex-direction: row;
    align-items: center;
}
nav>.nav-titre>img {
    width: 30px;
    height: 30px;
}
nav>.nav-titre>p {
    font-size: 1.5rem;
    font-weight: 500;
    padding: 0 1rem;
}


nav>#nav-menu {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0 2.5rem;
    font-size: 1.2rem;
}
nav>#nav-menu a, nav>#nav-menu span {
    margin-right: 20px;
}
nav>#nav-menu li:hover {
    text-decoration: underline;
    text-decoration-thickness: 0.2rem;
}
nav>#nav-menu li.active {
    text-decoration: underline;
    text-decoration-color: var(--color-sgdf);
    text-decoration-thickness: 0.2rem;
}
#nav-menu-btn {
    display: none;
    background-color: inherit;
    font-size: 1.5rem;
    color: var(--color-piok);
    border: none;
}
@media only screen and (max-width: 992px) {
    nav {
        justify-content: space-between;
    }
    #nav-menu-btn {
        display: block;
        cursor: pointer;
    }
    #nav-menu {
        display: none !important;
        flex-direction: column;
        width: auto;
        margin-top: 1rem;
        position: absolute;
        top: 100%;
        right: 0;
        border: solid 1px grey;
        border-radius: 0.3rem;
        background-color: white;
        box-shadow: 2px 2px 2px 0 var(--color-piok);
        z-index: 100;
        gap: 0 !important;
        padding: 0 0.3rem !important;
    }
    #nav-menu.show {
        display: flex !important;
    }
    nav>#nav-menu li {
        border: solid 0.02rem var(--color-piok);
        padding: 0.3rem 0.2rem;
        width: 100%;
        color: black;
    }
}

#objectif {
    margin: 0 auto 0.5rem auto;
    position:sticky;
    top: 0;   
    display: flex;
    flex-direction: row;
    flex-wrap:wrap;
    align-items: center;
    width: 100%;
    /* box-shadow: 0 0.4rem 1rem 0 var(--color-piok); */
    border-bottom: solid 0.1rem var(--color-piok);
}
#objectif>#bar {
    position: relative;
    top: 50%;
    border-radius: 5rem;
    background-color: rgb(241, 236, 236);
    border: solid 0.1rem black;
}
#objectif>#bar>#bar-actuelle {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(0, -50%);
    border-radius: 5rem;
    background-color: var(--color-piok);
    transition: width 1.5s ease;
    width: 0%;
}
#objectif>#bar>#bar-img>img {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(-50%, -55%);
    transition: left 1.5s ease;
}
#objectif>#bar-comment {
    text-align: center;
    flex: 1;
}
/* PHONE */
@media only screen and (max-width: 600px) {
    #objectif {
        margin: 0.5rem auto 0.5rem auto;
    }
    #objectif>#bar {
        width: 90%;
        height: 1.5rem;
        margin: 0 0.5rem;
        left: 50%;
        transform: translate(-50%, 0);
    }
    #objectif>#bar>#bar-actuelle {
        height: 1.5rem;
    }
    #objectif>#bar>#bar-img>img {
        height: 2.5rem;
        width: 2.5rem;
    }
    #objectif>#bar-comment {
        font-size: large;
        margin: 0.5rem 3rem;
    }
}
/* TABLETS */
@media only screen and (min-width: 600px) {
    #objectif {
        margin: 0.5rem auto 0.5rem auto;
    }
    #objectif>#bar {
        width: 90%;
        height: 1.5rem;
        margin: 0 0.5rem;
        left: 50%;
        transform: translate(-50%, 0);
    }
    #objectif>#bar>#bar-actuelle {
        height: 1.5rem;
    }
    #objectif>#bar>#bar-img>img {
        height: 2.5rem;
        width: 2.5rem;
    }
    #objectif>#bar-comment {
        font-size: large;
        margin: 0.5rem 3rem;
    }
}
/* DESKTOP */
@media only screen and (min-width: 992px) {
    #objectif {
        margin: 0 auto 0.5rem auto;
    }
    #objectif>#bar {
        width: 60%;
        height: 1.5rem;
        margin: 0 5rem;
        left: 0%;
        transform: translate(0, 0);
    }
    #objectif>#bar>#bar-actuelle {
        height: 1.5rem;
    }
    #objectif>#bar>#bar-img>img {
        height: 2.5rem;
        width: 2.5rem;
    }
    #objectif>#bar-comment {
        font-size: x-large;
        margin: 1rem 3rem;
    }
}

#corps {
    position: relative;
    overflow-y: auto;
    scrollbar-width:none;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
}
#corps>#inside {
    flex:1;
}

#scrollbar {
    position:sticky;
    top: 0;
    right: 0;
    width: 1rem;
    padding: 0.2rem 0.5rem;
}
#scrollbar:hover {
    cursor: pointer;
}
#scrollbar>#scroll-route {
    width: 100%;
    height: 100%;
    border-radius: 5rem;
    border: dotted 0.1rem black;
}
#scrollbar #scroll-img {
    position: absolute;
    right: 0;
    top: 0;
    width: 2rem;
    height: 2rem;
    z-index: 15;
}
#scrollbar #scroll-poub {
    position: absolute;
    right: 0;
    bottom: 0;
    width: 3rem;
    height: 3rem;
    z-index: 15;
}

/* Qui sommes nous? */
.en-tete img, .liste-infos img {
    width: 100%;
    height: 100%; 
    object-fit: cover;
}

.en-tete {
    display: flex;
    flex-direction: column;
}

.en-tete .image {
    max-height: 60vh;
    overflow: hidden; /* Chrome */
}

.en-tete .texte {
    padding: max(5vh, 5vw);
}
.en-tete .texte h1 {
    margin-top: 0;
}
.liste-infos p {
    margin-bottom: .75rem;
}

.liste-infos a, .en-tete a {
    text-decoration: none;
    color: revert;
}


#corps > #inside:has(div.en-tete) {
    padding: 0;
}

#objectif:has(~ #corps>#inside>.en-tete) {
    margin-bottom: 0;
}

.liste-infos {
    display: grid;
    gap: 0rem;
    
}
.liste-infos .texte {
    padding: max(5vh, 5vw);
}

@media only screen and (min-width: 600px) {
    .liste-infos {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-flow: dense;
    }
    .liste-infos :nth-child(1) {
        order: 1;
    }
    .liste-infos :nth-child(2) {
        order: 2;
    }
    .liste-infos :nth-child(3) {
        order: 4;
    }
    .liste-infos :nth-child(4) {
        order: 3;
    }

}

/* Fin Qui sommes nous? */

/* Planning */

.evenement {
    border-left: 4px solid rgb(160, 2, 2);
    padding-right: 0;
    padding: 2em;
    position: relative;
    display: flex;
    flex-direction: column;
}

.evenement .date {
    font-size: 2rem;
    margin-right: .5rem;
}

.evenement .heure {
    font-size: 1.25rem;
}

.evenement button {
    margin: auto;
    margin-right: 0;
}

.evenement .lieu {
    margin-bottom: .75rem;
}
.evenement div {
    display: flex;
    align-items: center;
}

.evenement::before {
    content: '';
    position: absolute;
    border-radius: 50%;
    padding: .5em;
    background-color: rgb(160, 2, 2);
    right: 100%; 
    margin-right: calc(-.5em + 2px);
    top: 2.75em;
}

/* Fin Planning */


/* CONNEXION */
.contenu.connexion {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}
.bloc-connexion {
    margin: 50px 0;
    padding: 15px 10px;
    background-color: #FAFAFA;
    border-radius: 15px;
    border: solid 0.1rem grey;
    box-shadow: 2px 2px 10px 0 black;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 450px;
}
.bloc-connexion>h1 {
    color: var(--color-piok);
    text-decoration: underline;
    text-decoration-color: var(--color-sgdf);
}
.bloc-connexion>form {
    width: 300px;
    padding: 0 2rem 1rem 2rem;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
}
.bloc-connexion>form input[type=submit] {
    background-color: rgb(2, 160, 68);
    border: none;
    border-radius: .25rem;
    padding: .5rem .75rem;
    font-weight: bold;
    color: white;
}
.bloc-connexion>form input[type=submit] {
    background-color: rgb(2, 160, 68);
    border: none;
    border-radius: .25rem;
    padding: .5rem .75rem;
    font-weight: bold;
    color: white;
}
.bloc-connexion>form .input input,
.bloc-connexion>form .input select {
    width: 100%;
    border-radius: .25rem;
    border: 1px solid gray;
    padding: .25rem;
}
.message {
    padding: 1rem;
    background-color: rgb(66, 194, 119);
    border-radius: 0.25rem;
    border: 1px solid rgb(2, 160, 68);
    color: white;
    margin-bottom: 1rem;
}
.message.erreur {
    background-color: rgb(230, 68, 68);
    border-color: rgb(160, 2, 2);
}
/* FIN CONNEXION */


/* ADM */
table.contributions th, table.contributeurs th {
    padding-top: .5rem;
    padding-bottom: .5rem;
    background-color: rgb(2, 160, 68);
    color: white;
}

table.contributions tr:nth-child(even), table.contributeurs tr:nth-child(even) {
    background-color: #f2f2f2;
}

table.contributions tr:hover, table.contributeurs tr:hover {
    background-color: #ddd;
}

table.contributions td, table.contributions th, table.contributeurs td, table.contributeurs th {
    border: 1px solid #ddd;
    padding: .5rem;
}

table.contributions, table.contributeurs {
    border-collapse: collapse;
    width: 100%;
}

.titre {
    display: flex;
    justify-content: space-between;
    align-items: center;
    word-wrap: anywhere;
    max-width: 100vw;
}

.titre a {
    text-decoration: none;
    font-weight: bold;
    padding: .5rem;
}
.adm summary {
    font-size: 1.5rem;
    font-weight: bold;
    margin: 2rem auto .5rem -1rem;
}
.adm details {
    margin: auto 1rem;
}

.adm #div-image {
    display: flex;
    flex-direction: column;
    max-width: max(25vh, 25vw);
    margin-bottom: 1rem;
}

/* FIN ADM */

/* ERREUR */
.contenu.erreur {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-height: 80vh;
    margin: 0.2rem;
}
.contenu.erreur>img{
    max-width: 1000px;
    width: 100%; 
}
.contenu.erreur>h2{
    padding: 0.5rem 0.7rem;
    background-color: #FCFCFC;
    border: solid 0.2rem grey;
    border-radius: 0.5rem;
}
.contenu.erreur>h2:hover {
    background-color: #F2F2F2;
    cursor: pointer;
}
/* FIN ERREUR */

/* ACTIONS */
#corps>#inside {
    /* display: flex;
    flex-direction: row;
    flex-wrap: nowrap; */
    position: relative;
    padding: 0.5rem 2rem;
    height: 100%;
    width: 100%;
    gap: 1rem;
}
#corps>#inside>#fresque {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
}
#corps>#inside>#fresque>.svg-sgdf {
    position: absolute;
    background-color: white;;
    transform: translate(-50%,-50%);
    height: 2rem;
    width: 2rem;
}
#corps>#inside>#contributions {
    display: flex;
    flex-direction: column-reverse;
    justify-content: center;
    align-items: center;
    gap: 5rem;
}



.bloc-contribution {
    position: relative;
    padding: 1rem 2rem;
    font-size: 1rem;
    text-align: center;
    min-width: 70%;
    border: dotted 0.2rem var(--color-piok);
    border-radius: 0.5rem;
    background-color: #FDFDFDDD;
}
.bloc-contribution>.lieudate {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
}
.bloc-contribution>.lieudate>.lieu {
    font-size: x-large;
    font-weight: 600;
}
.bloc-contribution>.lieudate>.lieu>.date {
    font-size: large;
}
.bloc-contribution>.corps {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    margin: 0.5rem;
}
.bloc-contribution>.corps img {
    max-height: 100%;
    max-width: 100%;
}
.bloc-contribution>.corps>.description {
    padding: 0.5rem;
    flex: 1;
    text-align: start;
}


@media only screen and (max-width: 600px) {
    .bloc-contribution {
        width: 90%;
    }
    .bloc-contribution>.lieudate {
        flex-direction: column;
        align-items: center;
    }
    .bloc-contribution>.corps>.image {
        width: 100%;
        padding: 0.2rem;
    }
}
/* TABLETS */
@media only screen and (min-width: 600px) {
    .bloc-contribution {
        width: 90%;
    }    
    .bloc-contribution>.lieudate {
        flex-direction: column;
        align-items: center;
    }
    .bloc-contribution>.corps>.image {
        width: 100%;
        padding: 0.2rem;
    }
}
@media only screen and (min-width: 992px) { 
    .bloc-contribution {
        width: 70%;
    }
    .bloc-contribution>.lieudate {
        flex-direction: row;
        align-items: baseline;
        gap: 0.5rem;
    }
    .bloc-contribution>.corps>.image {
        width: 40%;
        padding: 0.2rem;
    }
}
