@font-face {
    src: url("./police/tarekah-font/Tarekah-G330y.otf") format("opentype");
    font-family: "Tarekah";
}

@font-face {
    src: url("./police/Abhaya_Libre/AbhayaLibre-Regular.ttf") format("truetype");
    font-family: "Abhaya Libre";
}

/*Permet de d'importer une police locale */

/*Style du html et body */
html {
    height: 100%;
}

/*Le contenu du body restera au centre lorsque le viewport est plus grand horizontalement que celle-ci*/
body {
    background-color: rgb(33, 37, 41);
    font-family: "Abhaya Libre";
    color: white;
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;

}

/* Style du containeur principal. */
.page {
    width: 100%;
    min-height: 100vh;
    margin: 0 auto 0 auto;
    display: flex;
    flex-direction: column;
    flex: 1;

}

/*Navigation */
nav {
    display: flex;
    justify-content: center;
    align-items: center;
    padding-top: 2%;

}



footer {
    padding-bottom: 2%;
    padding-top: 8vh;
    width: 100%;
    text-align: center;
    margin-top: auto;
}

/*Enlève le style que la list a par défault */
.lien {
    list-style: none;
    display: flex;
    padding: 0;
}

.lien li {

    margin: 0 70px;
    text-align: center;
}

a {
    text-decoration: none;
    font-size: 2.5vw;
    color: white;

}

a:hover {
    text-decoration: underline;
}

.section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: auto;
}

/* Centre le texte sur la page de chaque projet */
#page-projet .section {
    text-align: center;
    padding: 0 5%;
    box-sizing: border-box;
}

header {
    margin: 10% 0 10% 0;
    height: auto;

}

/* Style de la signature */
.heros {
    display: grid;
    /*M'a permis de superposer les signatures */
    justify-items: center;
    position: relative;

}


/* Le h1 est utlisé dans la signature et les titre des projets*/
h1 {
    font-family: "Tarekah";
    font-weight: normal;
    font-size: 8vw;
}

/*Le grid-area m'a permis de superposer les signature */
.signature {
    font-style: italic;
    grid-area: 1/1/2/2;
    opacity: 100%;
    z-index: 4;

}

.signature.deux {
    color: rgb(222, 226, 230);
    opacity: 40%;
    grid-area: 1/1/4/2;
    padding: 10px 0px 0px 0px;
    filter: blur(3px);
    z-index: 3;
}

.signature.trois {
    grid-area: 1/1/4/2;
    color: rgb(173, 181, 189);
    padding: 20px 0px 0px 0px;
    opacity: 60%;
    filter: blur(3px);
    z-index: 2;
}

.signature.quatre {
    grid-area: 1/1/4/2;
    filter: blur(3px);
    opacity: 90%;
    color: rgb(73, 80, 87);
    padding: 30px 0px 0px 0px;
    z-index: 1;
}

h2 {
    font-size: 5vw;
    font-weight: normal;
    display: flex;
    justify-content: center;
}

p {
    font-size: 2vw;
}

.ligne {
    height: 1vh;
    width: 60vw;
    background-color: white;
    padding: 0.2vh;
    box-shadow: 0 0 7px 7px white;
}

img {
    width: 40%;
}



.carrousel {
    display: flex;
    flex-direction: row;
    flex-shrink: 0;
    gap: 2%;
    width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 2%;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 30px 2% 25px 2%;
    cursor: grab;
    user-select: none;
}

.carrousel.dragging {
    cursor: grabbing;
    scroll-snap-type: none;
    scroll-behavior: auto;
}

.carrousel::-webkit-scrollbar {
    display: none;
}


.couverture {
    position: relative;
    height: 40vh;
    flex-shrink: 0;
    scroll-snap-align: start;
    transition: 0.5s;
    border: 20px solid rgb(73, 80, 87);
    box-sizing: border-box;
    overflow: hidden;
}

/*La transition permet d'adoucir et de mettre une durée au changement */
.couverture img {
    height: 100%;
    width: auto;
    display: block;
    transition: 0.5s;
    -webkit-user-drag: none;
    user-drag: none;
}

.text {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: 0.5s;
    color: white;
    text-align: center;

}


/*Le :hover permet de mettre des effets au faire des changements au survol de la souris */
.couverture:hover {
    border-width: 0;
    box-shadow: 0 0 15px 15px rgb(73, 80, 87);
}

/*Lorsque couverture est survoler, l'image obtient un filtre et devient plus grands */
.couverture:hover img {
    transform: scale(1.1);
    filter: brightness(50%);
}

/*Lorsque la couverture et survoler, le texte apparait */
.couverture:hover .text {
    opacity: 1;
}


p.propos {
    width: 45%;
}

.objectif {
    text-align: center;
}

/*Empêche le texte de toucher les bords de la page*/
.page.propos {
    padding: 0 5%;
    box-sizing: border-box;
}

/*Empêche le texte de toucher les bords de la page*/
.page.contact {
    padding: 0 5%;
    box-sizing: border-box;
}

/*Rapproche et centre les infos de contact au lieu de les étirer sur toute la largeur*/
.page.contact .info {
    justify-content: center;
    gap: 15vw;
    width: auto;
}

/*Permet de mettre une distance entre les éléments*/
.info.propos {
    gap: 10vw;
}


.competences {
    display: flex;
    justify-content: center;
    align-items: start;
    gap: 120px;
    
}

.logo {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    justify-items: center;
    align-items: center;
    row-gap: 40px;
    column-gap: 60px;
}

.icon-wrap {
    width: 60%;
    position: relative;
    display: flex;
    justify-content: center;
}

.icon {
    width: 100%;
    display: block;
    filter: brightness(50%);
}

.icon:hover {
    width: 100%;
    display: block;
    filter: brightness(100%);
    transform: scale(1.1);
    transition: 0.5s ;

}

/*Bulle qui affiche le nom du logiciel au survol, comme une infobulle de site web*/
.icon-wrap::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translate(-50%, 5px);
    margin-bottom: 10px;
    padding: 6px 12px;
    background-color: rgb(73, 80, 87);
    color: white;
    font-size: 14px;
    white-space: nowrap;
    border-radius: 6px;
    opacity: 0;
    pointer-events: none;
    transition: 0.3s;
    z-index: 10;
}

.icon-wrap::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translate(-50%, 5px);
    margin-bottom: 2px;
    border: 6px solid transparent;
    border-top-color: rgb(73, 80, 87);
    opacity: 0;
    pointer-events: none;
    transition: 0.3s;
    z-index: 10;
}

.icon-wrap:hover::after,
.icon-wrap:hover::before {
    opacity: 1;
    transform: translate(-50%, 0);
}

.categorie {
    position: absolute;
    bottom: 30px;
}

.svg {
    width: 5vw;
    margin: 2vw;
    transition: 0.5s;
}

.svg:hover {
    transform: scale(1.3);
}

.info {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 20vw;
    width: 100%;
}

/*Enleve le text-decoration, puisque l'autre a au survol a un text-direction*/
.info a {
    text-decoration: none;
}

.info p a {
    font-size: 2vw;
}

h3 {
    font-size: 50px;
}

.resume {
    font-size: 25px;
}

.section.titre {
    height: 60vh;
}

.galerie {
    display: flex;
    flex-direction: row;
    flex-shrink: 0;
    justify-content: safe center;
    gap: 2%;
    width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scroll-padding-inline: 2%;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 30px 2% 25px 2%;
    cursor: grab;
    user-select: none;
}

.galerie::-webkit-scrollbar {
    display: none;
}

.galerie.dragging {
    cursor: grabbing;
    scroll-snap-type: none;
    scroll-behavior: auto;
}

.galerie div {
    display: flex;          /* transforme chaque div en conteneur flex */
    justify-content: center; /* centre horizontalement son contenu */
    align-items: center;
    flex-shrink: 0;
    scroll-snap-align: start;
}

.galerie img:hover {
    transform: scale(1.05);
    box-shadow: 0 0 10px 10px rgb(73, 80, 87);
}



.galerie img {
    height: 35vh;
    width: auto;
    display: block;
    object-fit: cover;
    transition: 0.5s;
    -webkit-user-drag: none;
    user-drag: none;
}

.galerie video {
    width: 60vw;
    display: block;
}



.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
    cursor: pointer;
}

.lightbox-img {
    width: auto;
    max-width: 100%;
    max-height: 100%;

}

.close {
    position: absolute;
    top: 20px;
    right: 40px;
    color: white;
    font-size: 50px;
    cursor: pointer;
    z-index: 1000;
}



.section.logiciel .icon-wrap {
    width: 100%;
}

.logiciel-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 40px;
}

.extra {
    width: 50%;
    transition: 0.5s;
}

.extra:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px 15px rgb(73, 80, 87);
}





/* Ceci permet de changer la disposition ou les valeurs lorsque le viewport répond aux restrictions*/
/*Ceci et les vw/vh/% ont permis de faire la page responsive */
@media (max-width: 768px) {

    .section.projet {
        margin-top: 5vh;
        height: auto;
    }


    .carrousel {
        gap: 20px;
    }

    .couverture {
        height: 30vh;
        border-width: 10px;
    }

    .galerie img {
    height:20vh;
    }

    .galerie video {
    width: 90vw;
    }



    .info {
        flex-direction: column;
        gap: 5vw;
        text-align: center;
        align-items: center;
    }

    h2 {
        font-size: 9vw;
        text-align: center;
    }

    a {
        font-size: 4.5vw;
    }

    p {
        font-size: 4vw;
        text-align: center;
    }

    .info p a {
        font-size: 4vw;
    }

    .lien li {
        margin: 0 25px;
    }

    .competences {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 60px;
    }

    footer {
        padding-top: 10vh;
        padding-bottom: 5vh;
    }

    p.propos {
        width: 100%;
    }

    .profil {
        width: 70%;
    }

    .ligne {
        height: 0.1vh;
        box-shadow: 0 0 4px 4px white;
    }

    .signature.deux {
        padding: 4px 0px 0px 0px;
    }

    .signature.trois {
        padding: 7px 0px 0px 0px;
    }

    .signature.quatre {
        padding: 15px 0px 0px 0px;
    }

    .categorie {
        bottom: -7px;
    }

    .section.logiciel .icon-wrap {
        width: 70%;
    }


}


@media (max-width: 1440px) {
    footer {
        padding-top: 10vh;
        padding-bottom: 5vh;
    }

    .page.propos footer {
        padding-top: 10vh;
    }

    .competences {
        gap: 40px;
    }

    .icon-wrap {
        width: 80%;
    }

    .text h3 {
        font-size: 4vh;
    }

    .resume {
        font-size: 3vh;
    }

    .text h3 {
        margin-bottom: 0.5em;

    }


    .text p {
        margin-top: -0.5em;
        width: 80%;
    }


}