*,
*::before,
*::after {
    box-sizing: border-box !important;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth !important;
}

/* Custom Properties */
:root {
    --ff-primary: 'Source Sans Pro', sans-serif;
    --ff-secondary: 'Source Code Pro', monospace;

    --fw-ref: 300;
    --fw-bold: 900;

    --clr-light: #fff;
    --clr-dark: #303030;
    --clr-accent: #5fb8bb;

    --fs-h1: 2.7rem;
    --fs-h2: 2.25rem;
    --fs-h3: 1.25rem;
    --fs-body: 1rem;

    --bs: 0.25em 0.25em 0.75em rgba(0, 0, 0, .25),
        0.125em 0.125em 0.25em rgba(0, 0, 0, .15);
}

/* General Styles */

body {
    background-color: var(--clr-light);
    color: var(--clr-dark);
    margin: 0;
    font-family: var(--ff-primary);
    font-size: var(--fs-body);
    line-height: 1.6;
    position: relative;
}

section {
    padding: 5em 2em;
}

img {
    display: block;
    max-width: 100%;
}

a {
    text-decoration: none;
    color: var(--clr-accent);
}

.btn {
    display: inline-block;
    padding: .5em 2.5em;
    background: var(--clr-accent);
    color: var(--clr-dark);
    cursor: pointer;
    text-decoration: none;
    font-size: .8em;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: var(--fw-bold);
    transition: transform 500ms ease-in-out;
    border-radius: 50px;
}

.btn:hover {
    transform: scale(1.2);
}

/* Typography */
h1,
h2,
h3 {
    line-height: 1;
    margin: 0;
}

h1 {
    font-size: var(--fs-h1);
}

h2 {
    font-size: var(--fs-h2);
}

h3 {
    font-size: var(--fs-h3);
}

.section__title {
    margin-bottom: .25em;
}

.section__title--intro {
    font-weight: var(--fw-bold);
}

.section__subtitle--intro {
    display: inline-block;
}

.section__subtitle {
    margin: 0;
    font-size: var(--fs-h3);
    padding: 0;
}

.section__subtitle--intro,
.section__subtitle--about {
    font-family: var(--ff-secondary);
    margin-bottom: 1em;
    padding: .25em;
}

/* head */

.header {
    position: fixed;
    z-index: 2;
}

.nav {
    transform: 0.5s;
}

.logo i {
    z-index: 4;
    transition: 0.5s;
}

@media (min-width: 940px) {
    .logo i {
        display: none;
    }

    .nav {
        display: flex;
    }

    .nav__list {
        list-style: none;
        display: flex;
        flex-direction: row;
        gap: 1rem;
        font-size: 1.35rem;
        align-items: center;
        justify-content: center;
    }

    .nav__item a {
        text-decoration: none;
        color: white;
        font-weight: 600;
        transition: 0.5s;
    }

    .nav__item a:hover {
        color: var(--clr-accent);
    }

    .header-scroll .nav a {
        background:
            linear-gradient(to right, white, white),
            linear-gradient(to right, white, white);
        background-size: 0% 0.1em, 0 0.1em;
        background-position: 100% 100%, 0 100%;
        background-repeat: no-repeat;
        transition: background-size 500ms;
    }

    .header-scroll a:hover {
        background-size: 0 0.1em, 100% 0.1em;
    }

    .header-scroll .nav a:hover {
        color: white;
    }
}

.header-scroll .logo__title--duong {
    color: white;
}

.nav__item a {
    background:
        linear-gradient(to right, var(--clr-accent), var(--clr-accent)),
        linear-gradient(to right, var(--clr-accent), var(--clr-accent));
    background-size: 0% 0.1em, 0 0.1em;
    background-position: 100% 100%, 0 100%;
    background-repeat: no-repeat;
    transition: background-size 500ms;
}

.nav__item a:hover {
    background-size: 0 0.1em, 100% 0.1em;
}

@media (max-width: 940px) {
    .logo i {
        display: block;
    }

    .nav {
        display: flex;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--clr-dark);
        justify-content: center;
        align-items: center;
        z-index: 2;
        transition: 0.5s;
    }

    .nav .nav__list {
        list-style: none;
        display: flex;
        flex-direction: column;
        gap: 3rem;
        font-size: 1.35rem;
        align-items: center;
    }

    .nav .nav__item a {
        text-decoration: none;
        color: white;
        font-weight: 600;
        transition: 0.5s;
    }

    .nav .nav__item a:hover {
        color: var(--clr-accent);
    }

    .nav-animation {
        transition: 0.5s;
        left: -100%;
    }
}

.header {
    width: 100%;
    transition: 0.5s;
    padding: 3rem 3rem 0;
}

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


.logo i {
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

.logo__title {
    text-decoration: none;
    color: white;
}

.logo__title--duong {
    color: var(--clr-accent);
}

.header-scroll {
    background-color: var(--clr-accent);
    padding: 2rem 2.5rem;
}

/* intro section */

.intro {
    position: relative;
    background-color: rgb(122, 119, 119);
    background-image: url(../img/backgroundimage.jpg);
    background-size: cover;
    background-blend-mode: multiply;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex-direction: column;
    color: #fff;
}

.section__subtitle--intro span {
    color: var(--clr-accent);
    font-size: 1.5rem;
}

/* about me */

.about-me {
    text-align: center;
    max-width: 1000px;
    margin: 0 auto;
}

.section__title--about-container {
    margin-bottom: 2.5rem;
    color: var(--clr-accent);
    position: relative;
}

.fa-user {
    font-size: 3.5rem;
    margin-bottom: 0.5rem;
}

.title-container {
    position: relative;
}

.about-me__body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.section__title--about {
    font-size: var(--fs-h2);
}

.about-me__body img {
    max-width: 90%;
    object-fit: cover;
    border-radius: 10px;
}

@media (min-width: 700px) {
    .about-me__body {
        flex-direction: row;
    }
}

.about-me__image {
    overflow: hidden;
    transition: transform 0.5s;
}

.transform-image {
    transform: translateX(-100%);
}


/* services */
.my-services {
    background-color: var(--clr-dark);
    background-image: url(../img/background2.jpg);
    background-size: cover;
    background-blend-mode: multiply;
    color: var(--clr-light);
    text-align: center;
}

.section__title--service {
    color: var(--clr-accent);
    position: relative;
    text-align: center;
}

.section__title--service::after {
    content: '';
    display: block;
    width: 3em;
    height: 1px;
    margin: 0.5em auto 1em;
    color: var(--clr-accent);
    background: var(--clr-light);
    opacity: 0.25;
}

.service {
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
}

.services {
    margin-bottom: 2em;
}

@media (min-width: 800px) {
    .services {
        display: flex;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
        gap: 1.5em;
    }

    .service+.service {
        margin-left: 2em;
    }
}

/* my skills */

.my-skill {
    max-width: 900px;
    margin: 0 auto;
}

.my-project-container {
    display: flex;
    justify-content: center;
}

.section__title--skill {
    color: var(--clr-accent);
    text-align: center;
}

.info i {
    color: var(--clr-accent);
    font-size: var(--fs-h3);
}

.skills-bar .bar {
    margin: 20px 0;
}

.skills-bar .bar:first-child {
    margin-top: 0;
}

.info span {
    color: var(--clr-dark);
    font-weight: 600;
}

.skills-bar .bar .progress-line {
    position: relative;
    height: 5px;
    width: 100%;
    background-color: #ede8e8;
    box-shadow: inset 0px 1px 1px rgba(0, 0, 0, 0.05),
        0px 1px 1px rgba(255, 255, 255, 0.8);
    transform: scaleX(0);
}

.bar .progress-line span {
    height: 100%;
    width: 80%;
    position: absolute;
    background-color: var(--clr-accent);
    border-radius: 10px;
    transform: scaleX(0);
}

.progress-line-animation {
    transform-origin: left;
    animation: animate 0.8s cubic-bezier(1, 0, 0.5, 1) forwards;
}

.progess-line-span-animation {
    transform-origin: left;
    animation: animate 0.8s 0.8s cubic-bezier(1, 0, 0.5, 1) forwards;
}

@keyframes animate {
    100% {
        transform: scaleX(1);
    }
}

/* footer */

.footer {
    background-color: #111;
    color: var(--clr-light);
    padding: 2.5rem 0;
    text-align: center;
    font-size: var(--fs-h3);
}

.footer-link i {
    transition: 0.5s;
}

.footer-link i:hover {
    opacity: .7;
    transform: scale(1.2);
}

.footer__link {
    font-size: var(--fs-h3);
    font-weight: var(--fw-bold);
}

.footer__link:hover {
    text-decoration: underline;
}

.social-list {
    list-style: none;
    display: flex;
    justify-content: center;
    margin: 2em 0 0;
    padding: 0;
}

.social-list__item {
    margin: 0 .5em;
}

.social-list__link {
    padding: .5em;
}