@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;700&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    overflow-x: hidden;
}


.language-switcher {
    position: absolute;
    top: 20px;
    left: 20px;
    cursor: pointer;
    background-color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}

.language-switcher .current-language {
    font-weight: bold;
    direction: ltr;
}

.language-switcher .language-options {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #fff;
    padding: 5px;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}

.language-switcher:hover .language-options {
    display: block;
}

.language-switcher .language-options a {
    display: block;
    padding: 5px;
    text-decoration: none;
    color: #1e1e1e;
}


.body {
    background-color: #e1e1e1;
    height: 100%;
    width: 100%;
    transition: all 0.1s ease;

    &.dark-mode {
        background-color: #1e1e1e;
    }
}

.wrapper {
    width: 100vw;
    display: inline-block;
    position: relative;

    &.header {
        height: 99vh;
    }

    .active-section {
        display: block;
    }

    .hidden-section {
        display: none;
    }

    .menu {
        display: flex;
        margin: 90px auto 0 auto;
        justify-content: center;
        gap: 2rem;

        .menu-item {
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 10px 16px;
            cursor: pointer;
            border-radius: 4px;
            position: relative;
            background-color: #fff;
            color: #1e1e1e;
            transition: all .2s ease-in-out;

            &:hover {
                background-color: #eef2ff;
            }

            &.active {
                background-color: #4d78f1;
                color: #fff;
            }
        }
    }

    .content {
        position: absolute;
        top: calc(50vh - 67px);
        z-index: 2;
        width: 100%;
        height: 67px;
        border-image: linear-gradient(to left, #1729bf 0%, transparent 100%) 1;
        border-radius: 5px; /* this doesn't work */
        border-width: 4px;
        border-style: solid;
        border-top: 0;
        border-left: 0;
        border-right: 0;

        .context {
            margin-left: calc(40vw + 32px);
            transition: all .5s ease-in-out;
            margin-top: -20px;

            .title {
                color: #040404;
                width: calc(100% - 15px);
                line-height: 1.5;
            }

            .subtitle {
                color: #1e1e1e;
                width: calc(100% - 15px);
                line-height: 1.5;
            }

            .description {
                color: #1e1e1e;
                margin: 10px 0 0 15px;
                width: calc(100% - 30px);
                padding-bottom: 70px;
                line-height: 1.8;
            }

            &.mirror {
                margin-bottom: -100%;
                padding-top: 40px;
                transition: all .5s ease-in-out;
            }
        }
    }

    .my-avatar {
        border-radius: 50%;
        width: 30vw;
        height: 30vw;
        box-shadow: 0px 0px 5px 0px rgba(23, 41, 191, 0.75);
        -webkit-box-shadow: 0px 0px 5px 0px rgba(23, 41, 191, 0.75);
        -moz-box-shadow: 0px 0px 5px 0px rgba(23, 41, 191, 0.75);
        position: absolute;
        top: calc(50vh - 15vw);
        left: 10vw;
        z-index: 2;
        background-image: url("/asset/img/pouria.jpg");
        background-size: cover;
        background-repeat: no-repeat;
        background-position: center center;
    }

    .logo {
        position: absolute;
        top: 0;
        left: calc(50vw - 100px);
        width: 200px;
        height: 70px;
        border-radius: 0 0 10px 10px;
        background-image: url("/asset/img/logo.png");
        background-size: cover;
        background-repeat: no-repeat;
        background-position: center center;
    }

    .skills {
        display: inline-grid;
        position: relative;
        width: 90%;
        height: auto;
        grid-template-columns: auto auto;
        margin: 100px 5%;
        padding: 2rem;
        column-gap: 5rem;
        border-radius: 1rem;
        row-gap: 70px;
        background-color: #efefef;

        .skill {
            display: grid;
            width: 100%;

            .label {
                width: 100%;
                display: flex;
                justify-content: space-between;

                .title {
                    font-size: 120%;
                    color: #1e1e1e;
                }

                .percentage {
                    font-size: 120%;
                    font-weight: bold;
                    font-style: italic;
                    color: #4d78f1;
                }
            }

            .progress-holder {
                margin-top: 10px;
                width: 100%;
                height: 20px;
                border-radius: 10px;
                background-color: #ffffff;
                padding: 3px;

                .progress {
                    height: 100%;
                    width: 1%;
                    background-color: #4d78f1;
                    border-radius: 10px;
                    transition: .7s linear;
                }
            }
        }
    }


    .contact {
        margin-top: 3.5rem;

        a {
            color: #1e1e1e;
            text-decoration: none;
            font-size: 1.2rem;
        }

        .contact-title {
            display: inline-block;
            position: relative;
            color: #040404;
            width: 100%;
            text-align: center;
        }

        .contact-arrow-point {
            position: absolute;
            top: 1.5rem;
            left: calc(50% - 7.5rem);
        }

        .contact-content {
            margin-top: 70px;
            width: 100%;
            display: inline-grid;
            justify-content: center;
            gap: 2rem;

            .icon {
                margin-bottom: -10px;
                margin-right: 5px;
            }
        }
    }


}

.theme-switcher {
    position: absolute;
    top: 20px;
    right: 20px;
    cursor: pointer;
}

.theme-switcher-button {
    background-image: url("/asset/img/dark-mode.png");
    background-position: center center;
    background-repeat: no-repeat;
    background-size: 24px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background-color: #fff;
    direction: ltr;
}

.flag-img {
    margin: 0 5px -2px 0;
}

.language-options {
    a {
        margin: 10px 0;
        direction: ltr;
    }
}

.dark-mode .theme-switcher-button {
    background-image: url("/asset/img/light-mode.png");
    background-color: #000;
}

@media screen and (max-width: 1024px) {
    .wrapper {
        .content {
            position: absolute;
            top: 700px;

            .context {
                margin-left: calc(5% + 20px);
            }
        }

        .my-avatar {
            position: relative;
            margin-top: 100px;
            width: 400px;
            height: 400px;
            margin-left: 5%;
            top: 0;
            left: 0;
        }

        .skills {
            margin: 50px 5%;
            grid-template-columns: auto;
        }
    }
}

@media screen and (max-width: 500px) {
    .wrapper {
        .menu {
            gap: 1rem;

            .menu-item {
                padding: 5px 8px;
            }
        }

        .content {
            position: absolute;
            top: 600px;

            .context {
                margin-left: calc(5% + 20px);
            }
        }

        .my-avatar {
            position: relative;
            display: block;
            width: 300px;
            height: 300px;
            margin: 70px auto 0 auto;
            top: 0;
            left: 0;
        }

    }
}

.dark-mode {
    .wrapper {
        .content {

            .context {

                .title {
                    color: #fff;
                }

                .subtitle {
                    color: #dfdfdf;
                }

                .description {
                    color: #dfdfdf;
                }

            }
        }

        .skills {
            background-color: #121212;

            .skill {

                .label {

                    .title {
                        color: #e1e1e1;
                    }
                }

                .progress-holder {
                    background-color: #000000;
                }
            }
        }

        .contact {
            a {
                color: #fff;
            }

            .contact-title {
                color: #fff;
            }
        }
    }
}

body.fa {
    font-family: 'Vazirmatn', sans-serif;

    .wrapper {

        .content {

            .context {
                padding-right: 20px;

            }
        }

        .contact {

            .contact-content {
                direction: ltr;
            }

            .contact-arrow-point {
                position: absolute;
                top: 2.5rem;
                right: calc(50%);
            }

        }

        .language-switcher .current-language {
            padding: 0 2px;
        }

    }

}

body.ar {

    .wrapper {

        .content {

            .context {
                padding-right: 20px;

            }
        }

        .contact {

            .contact-content {
                direction: ltr;
            }

            .contact-arrow-point {
                position: absolute;
                top: 2.5rem;
                right: calc(50%);
            }

        }

    }

}