@font-face {
    font-family: "DinaRemasteredII";
    src: url('../font/DinaRemasterII.ttc') format('truetype');
}

@font-face {
    font-family: "FiraCode";
    src: url('../font/FiraCode-Light.ttf') format('truetype');
}

:root{
    /*DARK par défaut*/ 
    --bg-color-explorateur: rgb(18,19,39);
    --bg-color-editeur: rgb(44,46,65);
    --bg-color-fichier-hover: rgb(29,28,42);
    --bg-color-fichier-selectionne: rgb(44,46,65);
    --bg-color-button: rgb(36, 162, 118);
    --bg-color-button-hover: rgb(24, 104, 76);
    --bg-color-curseur: white;
    --text-color-header: white;
    --text-color-fichier-ouvert:whitesmoke;
    --text-color-fichier-ferme:rgb(64,69,95);
    --text-color-editeur: whitesmoke;
    --text-color-date: rgb(34,216,122);
    --text-color-commentaire: rgb(47,218,159);
    --text-color-balise-formation: aqua;
    --text-color-balise-experience: burlywood;
    --text-color-mot-cle:rgb(251, 40, 226);
    --text-color-nom-classe:rgb(59, 143, 252);
    --text-color-description: #8c939b;
}

.light {
    --bg-color-explorateur: white;
    --bg-color-editeur: rgb(242,241,240);
    --bg-color-fichier-hover: rgb(186, 186, 186);
    --bg-color-fichier-selectionne: rgb(242,241,240);
    --bg-color-button: rgb(34,216,122);
    --bg-color-button-hover: rgb(27,163,92);
    --bg-color-curseur: black;
    --text-color-header: black;
    --text-color-fichier-ouvert:black;
    --text-color-fichier-ferme:rgb(149, 149, 149);
    --text-color-editeur: black;
    --text-color-date: rgb(21, 162, 89);
    --text-color-commentaire: rgb(30, 139, 101);
    --text-color-balise-formation: aqua;
    --text-color-balise-experience: burlywood;
    --text-color-mot-cle:rgb(160, 26, 145);
    --text-color-nom-classe:rgb(33,130,255);
    --text-color-description:slategrey;
}

body {
    display: grid;
    grid-template-areas:
    "header header header"
    "nav main main"
    "footer footer footer";
    grid-template-columns: 2fr 10fr;
    grid-template-rows: 1fr 10fr 1fr;
    height: 100vh;
    max-width: 1300px;
    padding: 0 20px 0 20px;
    margin: auto;
    background-color: var(--bg-color-explorateur);
    font-family: FiraCode;
}

header {
    grid-area: header;
    display: flex;
    flex-direction: row;
    align-items: center;
    font-size: 20px;
    color: var(--text-color-header);
}

.titre {
    flex-grow: 1;
    padding-left: 10px;
}

.dark-switch{
    display: flex;
    flex-direction: row;
    align-items: center;
    font-size: 15px;
}

.texte-dark-switch{
    padding-right: 10px;
}

.switch {
position: relative;
display: inline-block;
width: 40px;
height: 20px;
background-color: grey;
border-radius: 20px;
transition: all 0.3s;
}

.switch::after {
content: '';
position: absolute;
width: 18px;
height: 18px;
border-radius:50%;
background-color: white;
top: 1px;
left: 1px;
transition: all 0.3s;
}
  
.checkbox:checked + .switch::after {
left : 20px;
}
.checkbox:checked + .switch {
background-color: var(--text-color-nom-classe);
}
.checkbox {
display : none;
}
  
main {
    grid-area: main;
    background-color: var(--bg-color-editeur);
    color: var(--text-color-editeur);
    border-radius: 8px;
    overflow-y: auto;
    padding: 20px;
}

section {
    height: 100%;
}

.periode {
    padding-top: 10px;
    padding-bottom: 10px;
}

.corpsFonction {
    padding-left: 20px;
}

.commentaire {
    color: var(--text-color-commentaire);
}

.curseur {
    background-color: var(--bg-color-curseur);
    height: 1em;
    width: 1px;
    display: inline-block;
    margin-bottom: -2px;
    animation: blink 600ms linear infinite alternate;
}

.mot-cle {
    color:var(--text-color-mot-cle);
}

.fonction {
    padding-top: 20px;
}

.formation {
    color: var(--text-color-balise-formation);
}

.experience {
    color: var(--text-color-balise-experience);
}

.date {
    color: var(--text-color-date);
}

.nom-class {
    color:var(--text-color-nom-classe);
}

.description {
    color:var(--text-color-description);
}

.indente {
    padding-left: 20px;
    border-left: solid slategrey 1px;
}

.signe {
    color:firebrick ;
}

.non-visible {
    display: none;
}
  
nav {
    grid-area: nav;
    background-color: var(--bg-color-explorateur);
}

ul {
    padding-left: 0;
}

li {
    list-style: none;
    padding: 10px;
    width: 100%;
    cursor: pointer;
    color: var(--text-color-fichier-ferme);
    display: flex;
    align-items: center;
}

li:hover{
    background-color: var(--bg-color-fichier-hover);
    border-radius: 10px 0px 0px 10px;
}

.selectionne {
    background-color: var(--bg-color-fichier-selectionne);
    color: var(--text-color-fichier-ouvert);
    border-radius: 10px 0px 0px 10px;
}

.icone {
    width: 1.5rem;
    padding-right: 10px;
}

.carte-visite{
    display: flex;
    flex-direction: column;
    align-items: center;
}

.photo {
    border-radius: 50%;
    width: 50px;
    border: solid white;
}

.mail {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 200%;
}

.bouton-copie {
    min-width: 15%;
    margin-top: 20px;
    color: white;
    background-color: var(--bg-color-button);
    border: none;
    border-radius: 10px;
    padding: 10px;
}

.bouton-copie:hover {
    background-color: var(--bg-color-button-hover);
    cursor: pointer;
}

footer {
    grid-area: footer;
    background-color: var(--bg-color-explorateur);
    margin: auto;
}

.fin {
    font-style: italic;
    font-size: 75%;
}

* {
    margin: 0;
}

@keyframes blink {
    0% {
      opacity: 0;
    }
    45% {
      opacity: 0;
    }
    55% {
      opacity: 1;
    }
    100% {
      opacity: 1;
    }
}

/*RESPONSIVE*/

@media all and (max-width: 768px) {
    body {
        display: grid;
        grid-template-areas:
        "header header header"
        "nav nav nav"
        "main main main"
        "footer footer footer";
        grid-template-rows: 1fr 0.5fr 10fr 0.5fr;
        padding: 0 0 0 0;
        background-color: var(--bg-color-explorateur);
        font-family: FiraCode;
        font-size: small;
        height: 100svh;
    }

    header {
        padding: 0 10px 0 10px;
    }

    .titre {
        font-size: 15px;
    }

    main {
        border-radius: 0;
        padding: 10px;
    }

    ul {
        display: flex;
        height: 100%;
    }

    li {
        width: fit-content;
        height: 100%;
        padding: 0 10px 0 10px;
    }

    li:hover{
        background-color: var(--bg-color-fichier-hover);
        border-radius: 10px 10px 0px 0px;
    }
    
    .selectionne {
        background-color: var(--bg-color-fichier-selectionne);
        color: var(--text-color-fichier-ouvert);
        border-radius: 10px 10px 0px 0px;
    }

    .icone {
        width: 1rem;
        padding-right: 5px;
    }

    .texte-dark-switch{
        display: none;
    }

    .mail {
        font-size: 150%;
    }
}