@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@400;500;700&family=Roboto:wght@300;400;700&family=Russo+One&display=swap');

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

html {
    scroll-behavior: smooth;
}

:root {
    --bg-color: #eff0f5;
    --bg-header-color: #e5e8ee;
    --bg-navbar-color: #e0e0e7;
    --nav-font: 'Roboto', sans-serif;
    --secondary-font: 'Roboto Mono', monospace;
    --main-font: 'Russo One', sans-serif;
    --smooth-black: #393939;
    --smooth-other-black: #504f4f;
    --smooth-white: rgb(247, 247, 247);
}

body {
    background-color: var(--bg-color);
    font-family: var(--secondary-font);
}

a {
    text-decoration: none;
    /* color: inherit; */
    color: var(--smooth-black);
}

li {
    list-style-type: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--smooth-black);
}

p {
    color: var(--smooth-other-black);
    line-height: 1.3;
}

/* back to top button */

.to-top {
    position: fixed;
    bottom: 16px;
    right: 32px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    color: var(--smooth-black);
    text-decoration: none;
    opacity: 0;
    pointer-events: none;
    transition: all .4s;

}

.to-top.active {
    bottom: 40px;
    pointer-events: auto;
    opacity: 1;
}

/* header section */

.d-none2 {
    display: none;
}

.logo {
    max-width: 100%;
    height: 70px;
}

.icons-container {
    font-size: 30px;
    color: var(--smooth-black);
}

.icon {
    transition: ease .5s;
}

.icon:hover {
    color: var(--smooth-other-black);
}

.header-container {
    background-color: var(--bg-header-color);
}

.header {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    padding: 5px;
    align-items: center;
    justify-content: space-between;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    -webkit-transition: all 0.3s ease-in-out;
    transition: all 0.3s ease-in-out;
    background-color: var(--smooth-black);
}

/* navbar section */

nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1100px;
    margin: 0 auto;
    align-items: center;
}

.blog {
    border: 0;
    background-color: var(--smooth-black);
    padding: 12px 20px;
    font-weight: bold;
    border-radius: 2px;
    color: var(--smooth-white);
    cursor: pointer;
    transition: ease .5s;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.164);
    margin-right: 7px;
}

.blog:hover {
    background-color: #666565;
    color: white;
}

.nav-container {
    background-color: var(--bg-navbar-color);
}

.navbar {
    display: flex;
    flex-wrap: wrap;
}


.navbar li {
    margin-right: 35px;
    font-family: var(--nav-font);
    font-weight: bold;
    transition: ease .3s;
    border-radius: 3px;
}

.navbar li a {
    padding: 12px;
    transition: ease-out .5s;
}

.navbar li a:hover {
    color: var(--smooth-white);
    background-color: var(--smooth-black);
    border-radius: 5px;
}

/* main sec */

.img-hero img {
    max-width: 100%;
    width: 600px;
    border-radius: 5px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.315);
}

.hero-section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 0px;
    display: flex;
    flex-wrap: wrap;
    /* align-items: center; */
}

.txt-hero {
    align-items: center;
}

.txt-hero h1 {
    font-size: 2.5em;
    padding-bottom: 20px;
}

.txt-hero p {
    max-width: 500px;
    font-size: 17px;
    padding-right: 20px;
}

.btn {
    border: 0;
    margin: 30px 0px;
    background-color: #504f4f;
    padding: 18px 23px;
    font-size: 22px;
    font-weight: bold;
    border-radius: 10px;
    color: var(--smooth-white);
    cursor: pointer;
    transition: ease .5s;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.315);
}

.btn:hover {
    background-color: #393939;
    color: white;
}

/* about section */

.about-wrapper {
    display: flex;
}

.about-sec {
    max-width: 1100px;
    margin: 0 auto;
    border-top: 2px solid var(--smooth-other-black);
}

.about-wrapper {
    display: flex;
    padding-bottom: 50px;
    padding-top: 50px;
    gap: 100px;
}


#skills {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    background-color: #f0ead6;
    padding: 10px;
    color: var(--smooth-black);
    /* text-align: center; */
}

.social-links {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#social_img {
    max-width: 100%;
    border-radius: 5px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.315);
    margin-bottom: 25px;
}

.about-me h2 {
    padding: 10px 0;
    font-weight: bold;
}

.about-me p {
    padding: 10px 0;
}

/* projects section */

.project-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fit, 280px);
    gap: 15px;
    justify-content: center;
    padding-bottom: 50px;
}

.project {
    border: 1px solid var(black);
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.315);

}

.thumbnail {
    display: block;
    width: 100%;
    height: 180px;
    object-fit: initial;
}

.project-preview {
    background-color: rgb(226, 226, 226);
    padding: 15px;
}


.project-title {
    color: var(--smooth-black);
    margin: 0;
    padding-bottom: 10px;
}

.project-intro {
    color: var(--smooth-other-black);
    font-size: 14px;
    padding: 10px 0;
}

.projects-sec h1 {
    padding: 20px;
}

.projects-sec {
    max-width: 1100px;
    margin: 0 auto;
    border-top: 2px solid var(--smooth-other-black);
    border-bottom: 2px solid var(--smooth-other-black);
}

/* form section */

.form-container {
    width: 100%;
    padding: 30px;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

form {
    background: var(--bg-navbar-color);
    display: flex;
    flex-direction: column;
    padding: 2vw 2vw;
    width: 90%;
    max-width: 600px;
    border-radius: 10px;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.466);
}

form h3 {
    color: var(--smooth-black);
    font-weight: 800;
    margin-bottom: 20px;
}

form input,
form textarea {
    font-family: var(--secondary-font);
    border: 0;
    margin: 10px 0;
    padding: 20px;
    outline: none;
    background: var(--smooth-white);
    border-radius: 5px;
    font-size: 16px;
    resize: none;
}

form button {
    padding: 15px;
    background-color: #504f4f;
    color: #fff;
    font-size: 18px;
    border: none;
    outline: none;
    cursor: pointer;
    width: 150px;
    margin: 20px auto 0;
    border-radius: 30px;
    transition: ease .5s;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.315);
}

form button:hover {
    background-color: #393939;
    color: white;
}

/* footer section */

footer {
    text-align: center;
    padding: 8px;
    background-color: var(--bg-navbar-color);
}

@media(max-width: 1200px) {
    main {
        width: 100%;
        margin: auto;
    }

    .header {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .header-container {
        max-width: 1200px;
    }

    .nav-container {
        max-width: 1200px;
    }


    nav {
        justify-content: space-between;
    }

    .hero-section {
        width: 100%;
        justify-content: center;
    }

    .txt-hero {
        padding-left: 30px;
        margin: 0;
    }

    .img-hero {
        width: 530px;
        padding: 20px;
    }

    .about-wrapper {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 20px;
    }

    #skills {
        display: flex;
        margin: 0 auto;
        flex-wrap: wrap;
        text-align: center;
        max-width: 300px;
    }

    .about-sec h2 {
        text-align: center;
    }

    .p-about {
        display: flex;
    }

    .about-me p {
        max-width: 300px;
    }

    #social_img {
        width: 500px;
    }

    footer {
        text-align: center;
    }
}


@media(max-width: 800px) {

    .logo {
        max-width: 100%;
        padding: 0 20px;
        margin: 0px;
    }

    .header {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-evenly;
    }

    a {
        color: var(--smooth-black);
    }

    .nav-link a {
        color: var(--smooth-white);
    }

    .d-none {
        display: none;
    }

    .d-none2 {
        display: inline-block;
    }

    .hamburger {
        display: block;
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .navbar {
        position: fixed;
        left: -100%;
        top: 70px;
        gap: 0;
        flex-direction: column;
        background-color: var(--smooth-white);
        width: 100%;
        text-align: center;
        transition: .3s;
    }

    .navbar ul li {
        margin: 16px;
        color: var(--smooth-white);
    }

    .navbar.active {
        left: 0;
    }

    main {
        width: 100%;
        margin: auto;
    }


    .nav-container {
        max-width: 800px;
    }

    .navbar {
        display: flex;
        flex-direction: column;
        flex-wrap: wrap;
        padding: 8px 0px;
    }

    .navbar li {
        margin: 5px 0px;
    }

    nav {
        padding: 0px 15px;
    }

    .btn-nav {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-content: space-between;
    }

    .hero-section {
        width: 100%;
        padding: 10px 0px;
        margin: 0;
    }

    .txt-hero {
        padding: 20px;
    }

    .img-hero {
        width: 530px;
        padding-bottom: 30px;
    }

    .about-wrapper {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
    }

    .about-me p,
    .p-about-2 {
        max-width: 300px;
        text-align: center;
        margin: 0 auto;
    }

    .p-about {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .about-sec h2 {
        text-align: center;
    }

    #skills {
        display: flex;
        margin: 0 auto;
        flex-wrap: wrap;
        text-align: center;
        max-width: 300px;
    }

    #social_img {
        width: 530px;
    }
}

@media (max-width: 480px) {

    .navbar {
        position: fixed;
        left: -100%;
        top: 120px;
        gap: 0;
        flex-direction: column;
        background-color: var(--smooth-white);
        width: 100%;
        text-align: center;
        transition: .3s;
    }

    .to-top.active {
        opacity: 0;
    }

    .logo {
        max-width: 100%;
        padding: 0px;
        margin: 0px;
    }

    .navbar {
        display: flex;
        flex-direction: column;
        flex-wrap: wrap;
        padding: 8px 0px;
    }

    .navbar li {
        margin: 5px 0px;
    }

    .btn-nav {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-content: space-between;
    }

    .hero-section {
        width: 100%;

    }

    .img-hero {
        width: 350px;
        padding-bottom: 30px;
    }

    .txt-hero {
        text-align: left;
        padding-left: 40px;
    }

    .txt-hero p {
        max-width: 600px;
    }

    .txt-hero h1 {
        font-size: 2em;
    }

    .about-wrapper {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
    }

    .about-me p,
    .p-about-2 {
        max-width: 300px;
        text-align: center;
        margin: 0 auto;
    }

    .p-about {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .about-sec h2 {
        text-align: center;
    }

    #skills {
        display: flex;
        margin: 0 auto;
        text-align: center;
        max-width: 300px;
    }

    #social_img {
        width: 350px;
    }
}