/* Mobile-first approach */

@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');


:root{
    --color-accent: #5eead4;
    --color-highlight: #e2e8f0;
    --background-accent: rgba(45, 212, 191, .1);
}


html{
    scroll-behavior: smooth;
}


*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter", sans-serif;
}


body{
    background: #0f1721;
    color: #94a3b8;
    padding: 4rem 2rem;
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 6rem;
}


.underlay{
    position: fixed;
    background: #172554;
    inset: 0;
    opacity: 0.15;
}


header, main, footer{
    position: relative;
    z-index: 10;
}


p{
    /* font-size: 0.9rem; */
    line-height: 1.5rem;
}


p::selection, h1::selection, h2::selection, h3::selection, h4::selection, h5::selection, h6::selection{
    background-color: var(--color-accent);
    color: #0f172a;
}


/* header section starts here */

header h1, header h4, .light-text{
    color: var(--color-highlight);
}


header a{
    text-decoration: none;
}


header h1{
    font-weight: 600;
    font-size: 2.2rem;
}


nav{
    display: none;
}


header h4{
    font-weight: 400;
    font-size: 1.1rem;
}


nav a{
    font-size: 0.9rem;
}

header p{
    max-width: 300px;
}


.social-link-container{
    display: flex;
    align-items: center;
    gap: 1rem;
}


.social-link{
    font-size: 1.2rem;
    color: inherit;
    text-decoration: none;
    transition-duration: 200ms;
}


.social-link:hover{
    color: var(--color-highlight);
}


header{
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 300px;
}


.nav-link:hover{
    color: var(--color-accent);
    cursor: pointer;
}


.nav-link{
    max-width: fit-content;
}


/* header section ends here */


/* main section starts here */

/* about section(main section) starts here */
main{
    display: flex;
    flex-direction: column;
    gap: 6rem;
}


section{
    display: flex;
    flex-direction: column;
    gap: 2.8rem;
}


section h2{
    text-transform: uppercase;
    font-size: 1rem;
    font-weight: 500;
}


.sticky-header{
    position: sticky;
    top: 0;
    padding: 1rem 0;
}


.sticky-header h2{
    position: relative;
    z-index: 2;
}


.sticky-header::before{
    content: '';
    position: absolute;
    inset: 0;
    background: #101a31;
    opacity: 0.8;
}


.about-content{
    display: flex;
    flex-direction: column;
    gap: 1rem;
}


.about-content p{
    font-size: 1rem;
}


.anchor-icon{
    padding-left: 0.5rem;
}


#about-section .technologies{
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 50px;
    flex-wrap: wrap;
}

.technologies  img{
    width: 32px;
    height: 32px;
}


.mail-and-resume{
    display: flex;
    flex-direction: column;
    gap: 1rem;
    color: var(--color-highlight);
}


.mail-and-resume p span{
    text-decoration: underline;
}


.mail-and-resume p span:hover{
    color: var(--color-accent);
    cursor: pointer;
}


/* about section(main section) ends here */


/* experience section(main section) starts here */
.experience-content{
    display: flex;
    flex-direction: column;
    gap: 4rem;
}


.anchor-text{
    color: var(--color-highlight);
}


.experience-card a{
    text-decoration: none;
}


.anchor-text:hover{
    color: var(--color-accent);
}


.experience-card{
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 0.5rem;
}


.card-column{
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}


.experience-card .tenure{
    opacity: 0.7;
    text-transform: uppercase;
    font-size: 0.8rem;
}


.experience-card h3{
    font-size: 1rem;
    font-weight: 500;
}


.experience-card p{
    font-size: 0.9rem;
}


.card-header{
    font-weight: 400;
    font-size: 1rem;
}


.skills-container{
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    color: var(--color-accent);
}


.skills-container .skill{
    border-radius: 0.5rem;
    padding: 0.25rem 0.5rem;
    background: var(--background-accent);
}


.skill p{
    font-size: 0.8rem;
}


/* For navbar click and scroll */
#experience-section, #project-section{
    padding-top: 2.4rem;
}


/* experience section(main section) ends here */


/* project section(main section) starts here */
.project-content{
    display: flex;
    flex-direction: column;
    gap: 4rem;
}


.project-card{
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 0.5rem;
}


.project-card a{
    text-decoration: none;
}


.project-image-container{
    max-width: 150px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    display: grid;
    place-items: center;
    order: 2;
    border-radius: 0.25rem;
}


.project-image-container img{
    object-fit: cover;
    width: 100%;
    height: 100%;
}


.project-card{
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 1rem;
}


.project-archive-link{
    text-decoration: none;
    color: var(--color-highlight);
    position: relative;
    transition-duration: 200ms;
    margin-right: auto;
}


.project-archive-link span{
    transition-duration: 200ms;
}


.project-archive-link:hover span{
    padding-left: 0.5rem;
}


.project-archive-link::after{
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    bottom: 0;
    background: transparent;
    transition-duration: 200ms;
}


.project-archive-link:hover::after{
    background-color: var(--color-accent);
}

/* project section(main section) ends here */

/* main section ends here */


/* footer section starts here */

footer .anchor-text{
    text-decoration: none;
}


footer{
    display: flex;
    flex-direction: column;
    gap: 2rem;
    justify-content: space-between;
    align-items: flex-start;
}


footer p{
    font-size: 0.9rem;
}


.scroll-to-top{
    text-decoration: none;
    color: var(--color-accent);
    background: var(--background-accent);
    padding: 0 0.75rem;
    aspect-ratio: 1/1;
    display: grid;
    place-items: center;
    border-radius: 100%;
    overflow: hidden;
    font-size: 1.1rem;
    transition-duration: 200ms;
}


.scroll-to-top:hover{
    opacity: 0.8;
}

/* footer section ends here */


/* Responsive */
@media screen and (min-width: 640px) {
    .experience-card, .project-card{
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .card-column{
        grid-column: 2/5;
    }

    .project-image-container{
        order: 0;
    }

    header{
        max-width: unset;
    }

    header h1{
        font-size: 3rem;
    }

    header h4{
        font-size: 1.4rem;
    }

    header p{
        max-width: 300px;
    }

    .social-link-container{
        gap: 1rem;
    }

    .social-link-container i{
        font-size: 1.5rem;
    }

    .mail-and-resume{
        flex-direction: row;
        justify-content: space-between;
        color: var(--color-highlight);
        font-size: 1.1rem;
    }

    .technologies  img{
        width: 50px;
        height: 50px;
    }
}


@media screen and (min-width: 1040px) {
    body{
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
        padding: 6rem;
        padding-top: 0;
    }

    header{
        position: sticky;
        top: 0;
        height: 100vh;
        padding-bottom: 6rem;
    }

    header, main{
        max-width: 600px;
        width: 100%;
        padding-top: 6rem;
    }

    header{
        margin-left: auto;
    }

    main{
        margin-right: auto;
    }

    .sticky-header{
        display: none;
    }

    footer{
        grid-column: span 2 / span 2;
        flex-direction: row;
        max-width: 1200px;
        margin: 0 auto;
        width: 100%;
    }

    nav{
        display: flex;
        flex-direction: column; 
        gap: 0.5rem;
        flex: 1;
        padding: 5rem 0;
    }

    nav a{
        font-size: 1rem;
        color: var(--color-highlight);
    }


    .social-link-container{
        gap: 1rem;
    }

    .social-link-container i{
        font-size: 1.5rem;
    }

}