html {
    overscroll-behavior: none;
    scroll-behavior: smooth;
}

body {
    background-color: #f5f5f5;
    overscroll-behavior: none;
    scroll-behavior: smooth;
    font-family: "Montserrat", sans-serif;
    font-weight: 400;
    font-style: normal;

    img.lang {
        transition: all 1s;
        z-index: 1000;
        position: absolute;
        height: 40px;
        left: 3vw;
        top: 90dvh;
    }

    img.lang:hover {
        cursor: pointer;
    }
}

h1,
h2,
h3,
h4,
h5,
h6,
h7 {
    font-family: "adelphi-pe-variable", sans-serif;
    font-variation-settings: "slnt" 0, "opsz" 18, "wght" 850;
    font-weight: 850;
    text-transform: uppercase;
}

h2 {
    font-size: 48px;
}

.hide {
    transform: translateX(-200px);
}

.sticky {
    position: sticky;
    top: 0;
    height: 48px;
    z-index: 100;
    background-color: #f5f5f5;

    .logo {
        img {
            height: 40px;
        }
    }
}

header {
    width: -webkit-fill-available;
    top: 0;
    transition: all 1s;
    height: 96px;
    padding: 16px 32px;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #000000;

    .logo {
        padding: 16px 0;
        display: flex;
        align-items: center;
        gap: 32px;

        img {
            transition: all 1s;
            height: 80px;
        }

        h1 {
            display: none;
        }
    }

    nav {
        height: 100%;
        padding: 0 8px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 20px;

        a {
            text-align: center;
            position: relative;
            color: #000;
            text-decoration: none;
            font-size: 12px;
            font-weight: 700;
            transition: all 0.5s;
            width: 100px;
            height: 40px;
            border-radius: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        a::before {
            z-index: 1;
            content: '';
            position: absolute;
            transition: all 0.3s;
            height: 100%;
            width: 100%;
            background-color: #dadada77;
            box-shadow: 4px 4px 4px #00000042;
            border-radius: 16px;
        }

        a:hover::before {
            opacity: 0;
            transform: scale(0.5, 0.5);
        }

        a::after {
            content: '';
            position: absolute;
            width: 100%;
            height: 100%;
            border-radius: 16px;
            z-index: 1;
            opacity: 0;
            transition: all 0.3s;
            border: 1px solid rgba(0, 0, 0, 0.5);
            transform: scale(1.2, 1.2);
        }

        a:hover::after {
            opacity: 1;
            transform: scale(1, 1);
        }
    }
}

section.me {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 64px 0;

    .row {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 64px;
        padding: 8px;
        min-height: 700px;
        height: max-content;

        .pictures-container {
            position: relative;
            min-height: 600px;
            height: -webkit-fill-available;
            min-width: 464px;
            flex: 1;
            display: flex;
            justify-content: center;
            align-items: center;

            .one {
                z-index: 3;
                rotate: 0deg;
            }

            .two {
                z-index: 2;
                rotate: 8deg;
            }

            .three {
                z-index: 1;
                rotate: 16deg;
            }

            .picture {
                position: absolute;
                width: 420px;
                height: 500px;
                background-color: #fff;
                border: 1px solid#000;
                box-shadow: 8px 8px 4px #00000032;
                transition: all 0.5s;

                div.imgContainer {
                    position: absolute;
                    top: 20px;
                    left: 20px;
                    width: 380px;
                    height: 380px;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    overflow: hidden;

                    img {
                        height: 380px;
                        width: fit-content;
                    }
                }
            }

            .picture:hover {
                transform: scale(1.05);
                cursor: pointer;
            }

            nav {
                width: 160px;
                position: absolute;
                bottom: -20px;
                display: flex;
                align-items: center;
                justify-content: space-around;

                img {
                    transition: all 0.5s;
                    height: 40px;
                }

                img:hover {
                    transform: scale(1.05) translateX(10px);
                    cursor: pointer;
                }

                :first-child {
                    transform: rotateY(180deg);
                }

                :first-child:hover {
                    transform: rotateY(180deg) scale(1.05) translateX(10px);
                }
            }

        }

        .about-me {
            display: flex;
            position: relative;
            height: -webkit-fill-available;
            flex: 1;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            padding: 32px;
            gap: 16px;

            .title {
                width: 420px;
                display: flex;
                align-items: center;
                gap: 128px;
                overflow: hidden;
                transition: all 2.5s;
                padding: 8px 0;

                h2 {
                    text-wrap-mode: nowrap;
                    text-align: center;
                    width: 420px;
                    min-width: 420px;
                }
            }

            .text-container {
                width: 100%;
                display: flex;
                padding: 8px;
                gap: 16px;
                justify-content: center;
                align-items: center;

                .swipper:last-child {
                    transform: rotateY(180deg);
                }

                .swipper {
                    display: flex;
                    align-items: center;
                    justify-content: center;

                    button {
                        display: flex;
                        padding: 0;
                        border: none;
                        position: relative;
                        height: 64px;
                        width: 64px;
                        align-items: center;
                        justify-content: center;
                        background: none;

                        img {
                            position: absolute;
                        }
                    }

                    button:hover {
                        cursor: pointer;
                        animation: oscillement 1.5s ease-in-out infinite alternate;
                    }

                }

                .text {
                    transition: all 2.5s;
                    width: 420px;
                    display: flex;
                    gap: 128px;
                    padding: 24px;
                    overflow: hidden;

                    p {
                        width: 380px;
                        min-width: 380px;
                        padding: 20px;
                        text-align: center;
                        font-size: 24px;
                    }
                }

            }

            .timeline {
                filter: drop-shadow(4px 4px 4px #00000043);
                padding: 32px 0;
                position: relative;
                display: flex;
                align-items: center;

                .timeline-line {
                    height: 1.5px;
                }

                .year {
                    transition: all 500ms;
                    position: absolute;
                    display: flex;
                    flex-direction: column;
                    justify-content: center;

                    img {
                        height: 80px;
                    }
                }

                .y2005 {
                    left: 5%;
                }

                .y2023 {
                    left: 40%;
                }

                .y2024 {
                    left: 55%;
                }

                .selected {
                    transform: scale(1.35);
                }

            }
        }
    }
}

section.my-projects {
    height: 80dvh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 64px;
    padding-bottom: 32px;

    .container {
        width: 100%;
        width: 75%;
        height: 80%;
        display: flex;
        gap: 10px;
        margin-inline: 50px;

        img {
            width: 100%;
            height: 100%;
            display: block;
        }

        .card {
            color: #000;
            min-width: 75px;
            height: 100%;
            border-radius: 30px;
            overflow: hidden;
            display: flex;
            align-items: flex-end;
            flex-grow: 1;
            cursor: pointer;
            position: relative;
            transition: flex-grow 0.5s cubic-bezier(0.16, 1, 0.3, 1);

            --transition-timing: 0.35s;

            >.background {
                position: absolute;
                inset: 0;
                object-fit: cover;
                object-position: center;
                filter: brightness(0.4);
                z-index: -1;
                transition: var(--transition-timing) ease;
            }

            >.card-content {
                display: flex;
                align-items: center;
                position: absolute;
                left: 10px;
                right: 10px;
                bottom: 20px;
                overflow: hidden;
                transition: var(--transition-timing);
                z-index: 10;

                >* {
                    transition: var(--transition-timing);
                }

                >.profile-image {
                    min-width: 50px;
                    max-width: 50px;
                    height: 50px;
                    border: 1px solid white;
                    display: flex;
                    justify-content: center;
                    align-items: center;
                    border-radius: 50%;
                    overflow: hidden;

                    >svg {
                        width: 40px;

                        * {
                            fill: #fefefe;
                        }
                    }
                }

                >.title {
                    white-space: pre;
                    margin-left: 10px;
                    translate: 0 100%;
                    opacity: 0;
                }
            }

            >.backdrop {
                position: absolute;
                left: 0;
                right: 0;
                bottom: 0;
                height: 100px;
                z-index: 0;
                background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.7));
            }
        }

        .card:hover {
            flex-grow: 7;

            >.background {
                filter: brightness(1);
            }

            >.card-content {
                inset: 20px;
                top: auto;
            }

            .profile-image {
                border: 1px solid rgb(0, 0, 0);

                >svg {
                    * {
                        fill: #000;
                    }
                }
            }

            .title {
                opacity: 1;
                translate: 0 0;
            }
        }
    }
}

section.gallery {
    height: 80dvh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 64px;
    padding-bottom: 32px;
    overflow: hidden;
    position: relative;

    div.gallery-box {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 16px;
        padding: 0 64px;
        min-width: 316px;
        max-width: 964px;
        overflow: auto;
        scroll-behavior: smooth;
        -ms-overflow-style: none;
        scrollbar-width: none;
        position: relative;


        a.img-frame {
            transition: all 0.75s;
            overflow: hidden;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 300px;
            height: 300px;

            .img-v {
                width: 100%;
            }

            .img-h {
                height: 100%;
            }
        }

        a.img-frame:hover {
            cursor: pointer;
            transform: scale(1.2);
            position: relative;
            z-index: 2;
            box-shadow: 4px 4px 4px #00000046;
        }
    }

    .white-blur {
        position: sticky;
        width: 100%;
        height: 64px;
        bottom: 0;
        background: linear-gradient(to top, #f5f5f5, #f5f5f500);
    }

    div.gallery-box.hovering .img-frame:not(:hover) {
        filter: blur(4px);
    }

    div.gallery-box .img-frame:hover {
        transform: scale(1.2);
        position: relative;
        z-index: 2;
    }
}

section.contact-me {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 64px;
    padding-bottom: 32px;

    div.contact-row {
        width: -webkit-fill-available;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-around;
        padding: 32px;

        div.contact-box {
            width: 526px;
            height: 366px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: space-between;
            gap: 16px;
            padding: 16px;
            border-radius: 32px;
            background-color: #fff;
            border: 1px solid #000;
            box-shadow: 8px 8px 4px rgba(0, 0, 0, 0.25);

            div.text-box {
                width: -webkit-fill-available;
                padding: 0 48px;
                height: 176px;
                display: flex;
                align-items: center;
                justify-content: center;
                border-radius: 24px;
                background-color: #e7e7e7;

                p {
                    text-align: center;
                    font-size: 24px;
                }
            }

            div.button-box {
                width: -webkit-fill-available;
                padding: 0 48px;
                height: 176px;
                display: flex;
                align-items: center;
                justify-content: center;

                a {
                    transition: all 0.25s;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    gap: 16px;
                    color: #000;
                    text-decoration: none;
                    width: 192px;
                    height: 64px;
                    border-radius: 100px;
                    background-color: #fff;
                    box-shadow: 0 0 0 2px #dadada77;
                    background-color: #fff;
                    font-size: 16px;
                    text-transform: capitalize;

                    img {
                        transition: all 0.25s;
                    }
                }

                a:hover {
                    cursor: pointer;
                    background-color: #dadada77;

                    img {
                        background-color: #fff;
                        padding: 4px;
                        border-radius: 100%;
                        animation: oscillement-button-contact-me 1.5s ease-in-out infinite alternate;
                    }
                }
            }
        }
    }
}

section.project {
    height: -webkit-fill-available;
    width: -webkit-fill-available;
    padding: 32px 0;
    gap: 64px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;

    div.project-row {
        display: flex;
        align-items: center;
        justify-content: space-around;
        flex-wrap: wrap-reverse;

        >a {
            width: 50%;

            img {
                width: 100%;
            }
        }

        div.container {
            height: 400px;
            width: 360px;
            padding: 16px;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 24px;
            border-radius: 32px;
            background-color: #fff;
            box-shadow: 4px 4px 4px rgba(0, 0, 0, 0.25);

            div.text-box {
                width: -webkit-fill-available;
                height: 188px;
                display: flex;
                align-items: center;
                justify-content: center;
                border-radius: 24px;
                background-color: #e7e7e7;

                p {
                    padding: 0 16px;
                    font-size: 20px;
                    line-height: 24px;
                }
            }
        }

        div.button-box {
            width: -webkit-fill-available;
            padding: 0 48px;
            height: 188px;
            display: flex;
            align-items: center;
            justify-content: center;

            a {
                transition: all 0.25s;
                display: flex;
                align-items: center;
                justify-content: center;
                gap: 16px;
                color: #000;
                text-decoration: none;
                width: 192px;
                height: 64px;
                border-radius: 100px;
                background-color: #fff;
                box-shadow: 0 0 0 2px #dadada77;
                background-color: #fff;
                font-size: 16px;
                text-transform: capitalize;

                img {
                    transition: all 0.25s;
                }
            }

            a:hover {
                cursor: pointer;
                background-color: #dadada77;

                img {
                    background-color: #fff;
                    padding: 4px;
                    border-radius: 100%;
                    animation: oscillement-button-contact-me 1.5s ease-in-out infinite alternate;
                }
            }
        }
    }
}


@media (max-width: 1024px) {

    header nav {
        flex-direction: column;
    }

    header.sticky nav {
        flex-direction: row;
    }

    section.me {

        .pictures-container .picture {
            width: 336px;
            height: 400px;

            img {
                width: 304px;
                height: auto;
                top: 16px;
                left: 16px;
            }
        }
    }

    section.my-projects {

        div.container {
            flex-direction: column;
        }
    }

    h2 {
        font-size: 32px;
    }

    section.project {

        div.project-row {
            gap: 32px;

            div.container {
                div.text-box {
                    padding: 0 16px;

                    p {
                        font-size: 16px;
                    }
                }
            }
        }
    }
}

@media (max-width: 425px) {

    header nav {
        flex-direction: column;
    }

    header.sticky nav {
        flex-direction: column;
        font-size: 8px;
    }

    section.me {

        .row {

            .pictures-container {
                max-width: 425px;
                min-width: 300px;

                .picture {
                    width: 252px;
                    height: 300px;

                    div.imgContainer {

                        width: 212px;
                        height: 212px;

                        img {
                            width: fit;
                            height: 228px;
                            top: 16px;
                            left: 12px;
                        }
                    }
                }

                nav img {
                    height: 20px;
                    width: auto;
                }
            }

            .about-me {
                height: -webkit-fill-available;
                padding: unset;
                gap: unset;

                .title {
                    width: unset;
                    max-width: 80vw;
                    gap: 128px;
                    padding: 8px 0;

                    h2 {
                        width: unset;
                        max-width: 80vw;
                        min-width: 80vw;
                    }
                }

                .text-container {
                    width: 70vw;
                    padding: 8px;
                    gap: 16px;

                    .swipper {
                        width: 10vw;

                        button {
                            height: 32px;
                            width: 32px;

                            img {
                                scale: 0.5;
                            }
                        }
                    }

                    .text {
                        min-width: 152px;
                        gap: 128px;
                        padding: 24px;

                        p {
                            width: 152px;
                            min-width: 152px;
                            padding: unset;
                            font-size: 12px;
                        }
                    }
                }

                .timeline {
                    padding: 32px 0;

                    .timeline-line {
                        height: 0.66px;

                        h3 {
                            font-size: 8px;
                        }

                    }

                    .year {

                        img {
                            height: 40px;
                        }
                    }
                }
            }
        }
    }

    h2 {
        font-size: 16px;
    }

    section.project {

        div.project-row {
            gap: 32px;

            div.container {
                flex-direction: column;

                div.text-box {
                    padding: 0 8px;

                    p {
                        font-size: 8px;
                    }
                }
            }
        }
    }

    section.contact-me {
        gap: 0;
        padding-bottom: 0;

        div.contact-row {
            width: -webkit-fill-available;
            padding: 32px;
            gap: 16px;

            div.contact-box {
                width: 75%;
                height: unset;
                gap: 16px;
                padding: 16px;

                div.text-box {
                    width: -webkit-fill-available;
                    padding: 0 48px;
                    height: 140px;

                    p {
                        font-size: 12px;
                    }
                }

                div.button-box {
                    width: -webkit-fill-available;
                    padding: 0;
                    height: 140px;

                    a {
                        font-size: 11px;
                        height: unset;
                        width: unset;
                        padding: 16px;
                    }
                }
            }

            div.anim-lettre-box {

                >img {
                    width: 220px;
                }
            }
        }
    }
}

@keyframes oscillement {
    100% {
        transform: translateX(-10px);
    }
}

@keyframes oscillement-button-contact-me {
    100% {
        transform: translateX(5px);
    }
}