body, html {
    padding: 0;
    margin: 0;
}

body {
    background: url("./images/rails-beton.webp");
    background-size: cover;
    background-attachment: fixed;
    background-position: bottom left;
    min-height: 100vh;

    font-family: sans-serif;
    color: darkslategrey;
}

header {

    padding: 30px;
    position: relative;
    box-sizing: border-box;

    h1, img {
        font-size: 2rem;
    }

    h1 {
        position: absolute;
        top: 40px;
        left: 75px;
        color: transparent;
    }

    img {
        filter: drop-shadow(3px 3px 10px rgba(0,0,0,0.5));
        width: 11em;
        transform: rotate(2deg);
        max-width: 100%;
    }
}

main {
    background: url("./images/texture-papier.webp");
    background-size: 150px;
    height: fit-content;
    margin: 30px 50px;
    padding: 25px;
    max-width: 600px;
    box-shadow: 3px 3px 10px rgba(0,0,0,0.5);
    align-self: end;
    justify-self: end;

    & > :first-child {
        margin-top: 0;
    }

    & > :last-child {
        margin-bottom: 0;
    }
}

footer {
    padding: 30px;
    box-sizing: border-box;
    text-align: end;

    img {
        width: 100%;
        max-width: 700px;
        filter: drop-shadow(3px 3px 10px rgba(0,0,0,0.5));
        margin-bottom: -125px;
        transform: rotate(-3deg);

        position: relative;
        z-index: 2;
    }
}

body > footer {
    background: black;
    display: flex;
    flex-direction: row;
    margin: 0;
    padding: 1rem 4rem;
    padding-bottom: 50px;
    gap: 1rem;
    justify-content: center;

    img {
        filter: unset;
        height: 4rem;
        width: unset;
        margin: 0;
    }
}

@media screen and (min-width: 900px) {
    body > footer {
        justify-content: end;
    }
}

#section-principale {
    min-height: 100vh;
    display: grid;
    grid-template-rows: min-content 1fr min-content;
}

@media screen and (min-width: 900px) {
    #section-principale {
        grid-template-columns: max-content 1fr;

        footer {
            grid-column: 1 / 3;
            grid-row: 3;
        }

        header {
            grid-row: 1;
            grid-column: 1;
        }

        main {
            grid-row: 1 / 3;
            grid-column: 2z;
        }

    }
}

#gallerie {
    margin-top: -50px;
    padding: 25px;
    padding-top: 175px;
    padding-bottom: 100px;
    background: linear-gradient(to bottom, transparent, black 800px);
    min-height: 100vh;

    display: grid;
    grid-template-columns: 1fr;
    grid-auto-rows: min-content;
    grid-auto-flow: row dense;
    gap: 25px;

    img {
        max-width: 100%;
    }
}

@media screen and (min-width: 900px) {
    #gallerie {
        grid-template-columns: 1fr 1fr;
        padding-top: 100px;

        img.portrait {
            grid-row: span 2;
        }

        img.landscape {
            grid-column: span 2;
        }
    }
}