:root{
    --primary-color: #2E6F40;
    --secondary-color: white;
    --tertiary-color: #6F2E5D;
}

@media (orientation: landscape) {
    html {
        --in-main-side-margins: 10rem;
    }
}

@media (orientation: portrait) {
    html {
        --in-main-side-margins: 10rem;
    }
}
/*
Source - https://stackoverflow.com/a/18772399
Posted by Brian Ogden, modified by community. See post 'Timeline' for change history
Retrieved 2026-09-21, License - CC BY-SA 4.0
*/
/* CSS Reset */
* {
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    font-size: 100%;
    font-family: sans-serif;
    vertical-align: baseline;
    background: transparent;
}

html {
    margin: 0;
    height: 100%;
}

body {
    text-align: center;
    margin: 0;
    box-sizing:border-box;
    height:100%
}

.wrapper{
    /* Pour sticky footer */
    display: flex;
    flex-direction: column;
    min-height: 100%;
    box-sizing: border-box;
}

/* Block Navigation */
/* ================ */
nav {
    /* Pour sticky footer */
    flex-grow : 0; flex-shrink: 0;
    /**/
    margin: 0;
    background-color: var(--secondary-color);
    height: 3rem;
}
nav ul{
    align-items: center;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
    grid-template-rows: 1fr;
    height: 100%;
}

/* Block Liens */
/* =========== */
a {
    color: var(--primary-color);
    text-decoration: underline;
}

a:focus {
    text-decoration: overline 1.5px;
}

a:hover {
    text-decoration: overline 1.5px;
}

/* ================ */

nav ul li {
    vertical-align: middle;
    margin: 0;
    padding: 0;
    border: solid var(--primary-color);
    list-style: none;
    height: 100%;
    a {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100%;
        width: 100%;
        color: var(--primary-color);
        text-decoration: none;
        font-size: 125%;
    }
    a.current {
        color: var(--secondary-color);
        background-color: var(--primary-color);
        font-weight: bold;
    }
    a:focus{
        text-decoration: none;
    }
    a:hover {
        text-decoration: none;
        box-shadow: inset 0px 0px 5px 1px var(--primary-color);
        color: var(--primary-color);
        background-color: var(--secondary-color);
    }
    
    a.current:hover {
        color: var(--secondary-color);
        background-color: var(--primary-color);
    }
}

div.drop-content {
    display: none;
    position: absolute;
    z-index: 1;
    min-width: 20%;
    border: solid var(--primary-color);
    border-top: none;
    box-shadow: 0px 5px 5px 1px black;
}

div.drop-content a {
    float: none;
    display: block;
    background-color: var(--secondary-color);
}

a.drop-down:hover + div.drop-content {
    display:block;
    color: var(--primary-color);  
}

div.drop-content:hover {
    display: block;
}

/* =========== */



header {
    /* Pour sticky footer */
    flex-grow: 0; flex-shrink: 0;
    /**/
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    font-size: 200%;
    height: 2.5em;
}

main {
    /* Pour sticky footer */
    flex-grow: 1;
    /**/
    margin-right: 4rem;
    margin-left: 4rem;
}

h2{
    background-color: var(--primary-color);
    color: var(--secondary-color);
    margin-top: 2em;
    margin-bottom: 1em;
    font-size: 150%;
    padding-top: 0.25em;
    padding-bottom: 0.25em;
}

/* Block Résumés (pour pages projets) */
/* ================================== */
div.presentation{
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 0;
    padding-left: 0%;
    padding-right: 0%;
    margin-right: 15%;
    margin-left: 15%;
    iframe{
        grid-column: 1;
        border: solid 5px var(--primary-color);
    }
}
div.resume {
    grid-column: 2;
    display: grid;
    grid-template-columns: 1fr 1fr;
    * {
        display: flex;
        align-items: center;
        justify-content: center;
        margin-top : 0em;
        margin-bottom: 0em;
    }
    h2{
        margin-top: 0em;
    }
    .right {
        justify-content: right;
        padding-right: 0.5em;
        font-weight:bold;
        margin:0;
    }
    .left {
        justify-content: left;
        padding-left: 0.5em;
        margin:0;
    }
    .wide {
        grid-column: 1/3;
    }
}
/* ================================== */


/* Block p */
/* ================================== */
main p, main ul {
    text-align: left;
    margin-left: var(--in-main-side-margins);
    margin-right: var(--in-main-side-margins);
    margin-top: 1em;
    margin-bottom: 1em;
    font-size: 115%;
}
main ul{
    list-style-position: inside;
}
main li {
    text-align: left;
}

div.voirplus { 
    margin-top: 2em;
    margin-bottom: 1.5em;
    a {
        margin-right: 45%;
        margin-left: 45%;
        padding: 0.5em;
        background-color: var(--primary-color);
        color: var(--secondary-color);
        text-decoration: none;
        border: solid 3px var(--primary-color);
        border-radius: 1em;
        font-weight: bold;
    }


    a:focus{
        border-color: var(--secondary-color);
        box-shadow: 0px 0px 15px 5px var(--primary-color);
    }
    a:hover{
        border-color: var(--secondary-color);
        box-shadow: 0px 0px 15px 5px var(--primary-color);
    }

    a:active{
        border-color: var(--primary-color);
        box-shadow: 0px 0px 15px 5px var(--primary-color);
        background-color: var(--secondary-color);
        color: var(--primary-color);
    }
}

div.twoItems {
    display: flex;
    flex-direction: row;
    gap: 2em;
    align-content: center;
    margin-left: var(--in-main-side-margins);
    margin-right: var(--in-main-side-margins);
    p {
        align-content: center;
        margin: 0; 
    }
    .parPlusLink {
        display: flex;
        flex-direction: column;
        justify-content: space-evenly;
    }
}

div.parContainer {
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    p {
        margin-top: 1em;
        margin-bottom: 1em;
    }
}
/* Block Medias */
/*==============*/
img {
    max-width: 30vw;
    border: solid 5px var(--primary-color);
}

embed {
    height: 100%;
}
/*==============*/


footer {
    /* Pour sticky footer */
    flex-grow: 0; flex-shrink: 0;
    /**/
    padding-top: 1rem;
    padding-bottom: 1rem;
    margin-top: 4rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-top: solid 2px var(--primary-color);
    div.contacts{
        display: flex;
        align-content: center;
        justify-content: center;
        border-right: solid 2px var(--primary-color);
        .contactStart{
            text-decoration: underline 2px darkgrey;
        }
        ul {
            list-style: none;
            text-align: start;
            li{
                margin: 0.5em;
            }
        }
    }
    div.legals{
        display: flex;
        align-content: center;
        flex-direction: column;
        justify-content: space-evenly;
    }
}


