@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap');

/*==================== VARIABLES to change the setting ====================*/
/*==================== VARIABLES ====================*/
:root {
    --header-height: 3rem;
    --body-font: 'Poppins', sans-serif;
    --hue-color: 375;
    --first-color: hsl(var(--hue-color), 69%, 61%);
    --first-color-second: hsl(var(--hue-color), 69%, 61%);
    --first-color-alt: hsl(var(--hue-color), 57%, 53%);
    --first-color-lighter: hsl(var(--hue-color), 92%, 85%);
    --title-color: hsl(var(--hue-color), 8%, 15%);
    --text-color: hsl(var(--hue-color), 8%, 45%);
    --text-color-light: hsl(var(--hue-color), 8%, 65%);
    --input-color: hsl(var(--hue-color), 70%, 96%);
    --body-color: hsl(var(--hue-color), 60%, 99%);
    --container-color: #FFF;
    --scroll-bar-color: hsl(var(--hue-color), 12%, 90%);
    --scroll-thumb-color: hsl(var(--hue-color), 12%, 80%);
    --big-font-size: 2rem;
    --h1-font-size: 1.5rem;
    --h2-font-size: 1.25rem;
    --h3-font-size: 1.125rem;
    --normal-font-size: 0.938rem;
    --small-font-size: 0.813rem;
    --smaller-font-size: 0.75rem;
    --font-medium: 500;
    --font-semi-bold: 600;
    --mb-0-25: 0.25rem;
    --mb-0-5: 0.5rem;
    --mb-0-75: 0.75rem;
    --mb-1: 1rem;
    --mb-1-5: 1.5rem;
    --mb-2: 2rem;
    --mb-2-5: 2.5rem;
    --mb-3: 3rem;
    --z-tooltip: 10;
    --z-fixed: 100;
    --z-modal: 1000;
}

/* Font size for large devices */
@media screen and (min-width: 968px) {
    :root {
        --big-font-size: 3rem;
        --h1-font-size: 2.25rem;
        --h2-font-size: 1.5rem;
        --h3-font-size: 1.25rem;
        --normal-font-size: 1rem;
        --small-font-size: 0.875rem;
        --smaller-font-size: 0.813rem;
    }
}

body.dark-theme{
        --first-color-second: hsl(var(--hue-color), 30%, 8%);
        --title-color: hsl(var(--hue-color), 8%, 95%);
        --text-color: hsl(var(--hue-color), 8%, 75%);
        --input-color: hsl(var(--hue-color), 29%, 16%);
        --body-color: hsl(var(--hue-color), 28%, 12%);
        --container-color: hsl(var(--hue-color), 29%, 16%);
        --scroll-bar-color: hsl(var(--hue-color), 12%, 48%);
        --scroll-thumb-color: hsl(var(--hue-color), 12%, 36%);
}

/****************Light/Dark button style***************/
.nav__btns{
    display: flex;
    align-items: center;
}

.change-theme{
    font-size: 1.25rem;
    color: var(--title-color);
    margin-right: var(--mb-1);
    cursor: pointer;
}

.change-theme:hover{
    color: var(--first-color);
}

/*==================== Base Styles ====================*/
*{
    box-sizing: border-box;
    padding: 0;
    margin: 0;
}

html{
    scroll-behavior: smooth;
}

body{
    margin: 0 0 var(--header-height) 0;
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    background-color: var(--body-color);
    color: var(--text-color);
}

h1,h2,h3,h4{
    color: var(--title-color);
    font-weight: var(--font-semi-bold);
}

ul{
    list-style: none;
}

a{
    text-decoration: none;
}

img{
    max-width: 100%;
    height: auto;
}

.section{
    padding: 2rem 0 4rem;
}

.section__title{
    font-size: var(--h1-font-size);
}

.section__subtitle{
    display: block;
    font-size: var(--small-font-size);
    margin-bottom: var(--mb-3);
}

.section__title,
.section__subtitle{
    text-align: center;

}

.container{
    max-width: 768px;
    margin-left: var(--mb-1-5);
    margin-right: var(--mb-1-5);
}

.grid{
    display: grid;
    gap: 1.5rem;
}

.header{
    width: 100%;
    position: fixed;
    bottom: 0;
    left: 0;
    z-index: var(--z-fixed);
    background-color: var(--body-color);
}

.nav{
    max-width: 968px;
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav__logo,
.nav__toggle{
    color: var(--title-color);
    font-weight: var(--font-medium);
}

.nav__logo:hover{
    color: var(--first-color);
}

.nav__toggle{
    font-size: 1.1rem;
    cursor: pointer;
}

.nav__toggle:hover{
    color: var(--first-color);
}

@media screen and (max-width: 767px){
    .nav__menu{
        position: fixed;
        bottom: -100%;
        left: 0;
        width: 100%;
        background-color: var(--body-color);
        padding: 2rem 1.5rem 4rem;
        box-shadow: 0 -1px 4px rgba(0,0,0,0.15);
        border-radius: 1.5rem 1.5rem 0 0;
        transition: .3s;
    }
}

.nav__list{
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.nav__link{
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: var(--small-font-size);
    color: var(--title-color);
    font-weight: var(--font-medium);
}

.nav__link:hover{
    color: var(--first-color);
}

.nav__icon{
    font-size: 1.2rem;
}

.nav__close{
    position: absolute;
    right: 1.3rem;
    bottom: 0.5rem;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--first-color);
}

.nav__close:hover{
    color: var(--first-color-alt);
}

.show-menu{
    bottom: 0;
}

.active-link{
    color: var(--first-color);
}

.scroll-header{
    box-shadow: 0 -1px 4px rgba(0,0,0,0.15);
}

.home{
    row-gap: 5rem;
    background: linear-gradient(to bottom,#ebe5e508, #bdb7b7);
    min-height: 100vh;
    padding: 2rem;
    
}
.home__container{
    gap: 1rem;
}

.home__content{
    grid-template-columns: .5fr 3fr;
    padding-top: 3.5rem;
    align-items: center;
}

.home__social{
    display: grid;
    grid-template-columns: max-content;
    row-gap: 1rem;
}

.home__social-icon{
    font-size: 1.25rem;
    color: var(--first-color);
}

.home__social-icon:hover{
    color: var(--first-color-alt);
}

.home__blob{
    width: 200px;
    fill: var(--first-color);
}

.home__blob-img{
    width: 170px;
}

.home__data{
    grid-column: 1/3;
}

.home__title{
    font-size: var(--big-font-size);
}

.home__subtitle{
    font-size: var(--h3-font-size);
    color: var(--text-color);
    font-weight: var(--font-medium);
    margin-bottom: var(--mb-0-75);
}

.home__description{
    margin-bottom: var(--mb-2);
}

.home__scroll-button{
    color: var(--first-color);
    transition: .3s;
}

.home__scroll-button:hover{
    transform: translateY(.25rem);
}

.home__scroll-mouse{
    font-size: 2rem
}

.home__scroll-name{
    font-size: var(--small-font-size);
    color: var(--title-color);
    font-weight: var(--font-medium);
    margin-right: var(--mb-0-25);
}

.home_scroll-arrow{
    font-size: 1.25rem;
}

.button{
    display: inline-block;
    background-color: var(--first-color);
    color: #FFF;
    padding: 0.5rem;
    border-radius: .5rem;
    font-weight: var(--font-medium);
}

.button:hover{
    background-color: var(--first-color-alt);
}

.button__icon{
    font-size: 1.25rem;
    margin-left: var(--mb-0-5);
    transition: .3s;
}

.button--flex{
    display: inline-flex;
    align-items: center;
}

.button--small{
    padding: .75rem 1rem;
}

.button--link{
  padding: 0;
  background-color: transparent;
  color: var(--first-color);  
}

.button--link:hover{
    background-color: transparent;
    color: var(--first-color-alt);
}

/*==================== SKILLS ====================*/
.skills__container{
    row-gap: 0;
}

.skills__header{
    display: flex;
    align-items: center;
    margin-bottom: var(--mb-2-5);
    cursor: pointer;
}

.skills__icon{
    font-size: 2rem;
    color: var(--first-color);
}

.skills__icon{
    margin-right: var(--mb-0-75);
}

.skills__title{
    font-size: var(--h3-font-size);
}

.skills__subtitle{
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}


/******************** Typing Introduction *******************/
.typing-container {
    display: block;
    min-height: 80px;
    margin-bottom: 3 rem;
    font-family: 'Courier New', monospace;
    font-size: 20px;
}

.typing-text {
    border-right: 2px solid black;
    padding-right: 5px;
    animation: blink 0.75s step-end infinite;
}

@keyframes blink {
    from, to { border-color: transparent }
    10% { border-color: black }
}

/************PROJECTS****************/
.projects__container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 968px;
    margin: 0 auto;
}

.project__item {
    background: var(--container-color);
    border-radius: 0.75rem;
    padding: 1.5rem 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.project__item:hover {
    transform: translateX(8px);
}

.project__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.project__icon {
    font-size: 1.5rem;
    color: var(--first-color);
}

.project__title {
    font-size: var(--h3-font-size);
    color: var(--title-color);
    margin-right: 1rem;
}

.project__description {
    color: var(--text-color);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.project__tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project__tech-tag {
    background: var(--first-color-lighter);
    color: var(--first-color);
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
    font-size: var(--smaller-font-size);
    font-weight: var(--font-medium);
}

.project__links {
    display: flex;
    gap: 1.5rem;
}

.project__link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--first-color);
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    transition: color 0.3s;
}

.project__link:hover {
    color: var(--first-color-alt);
}

.project__link i {
    transition: transform 0.3s;
}

.project__link:hover i {
    transform: translateX(3px);
}

/* Media Queries */
@media screen and (max-width: 768px) {
    .project__item {
        padding: 1.25rem;
    }

    .project__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .project__icon {
        align-self: flex-end;
        margin-top: -2rem;
    }
}

@media screen and (max-width: 350px) {
    .project__links {
        flex-direction: column;
        gap: 0.75rem;
    }
}
/*Experience*/

.experience__container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 968px;
    margin: 0 auto;
}

.experience__item {
    background: var(--container-color);
    border-radius: 0.75rem;
    padding: 1.5rem 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.experience__item:hover {
    transform: translateX(8px);
}

.experience__header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.experience__main {
    flex: 1;
    min-width: 250px;
}

.experience__title {
    font-size: var(--h3-font-size);
    color: var(--title-color);
    margin-bottom: 0.5rem;
}

.experience__company,
.experience__date,
.experience__location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-color);
    font-size: var(--small-font-size);
}

.experience__period {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.experience__list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.experience__description {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.experience__list-icon {
    color: var(--first-color);
    font-size: 1.25rem;
    margin-top: 0.25rem;
}

.experience__description p {
    color: var(--text-color);
    line-height: 1.6;
}

.experience__tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--first-color-lighter);
}

.experience__tech-tag {
    background: var(--first-color-lighter);
    color: var(--first-color);
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
    font-size: var(--smaller-font-size);
    font-weight: var(--font-medium);
}

/* Media Queries */
@media screen and (max-width: 768px) {
    .experience__item {
        padding: 1.25rem;
    }

    .experience__header {
        flex-direction: column;
        gap: 1rem;
    }

    .experience__period {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1rem;
    }
}

@media screen and (max-width: 350px) {
    .experience__tech {
        gap: 0.5rem;
    }

    .experience__description {
        gap: 0.75rem;
    }
}


/*Certification*/

.credentials__container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
    padding: 1rem;
}

.credentials__group {
    position: relative;
    background: var(--container-color);
    padding: 2rem;
    border-radius: 1.25rem;
    transition: all 0.4s ease;
}

.credentials__group:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.credentials__header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--first-color-lighter);
}

.credentials__header i {
    font-size: 2rem;
    color: var(--first-color);
}

.credentials__header h3 {
    font-size: var(--h2-font-size);
    color: var(--title-color);
}

/* Publication Styles */
.publication__journal {
    display: inline-block;
    background: var(--first-color-lighter);
    color: var(--first-color);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: var(--small-font-size);
    margin-bottom: 1rem;
}

.publication__title {
    font-size: var(--h3-font-size);
    color: var(--title-color);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.publication__authors {
    color: var(--text-color);
    font-size: var(--normal-font-size);
    margin-bottom: 1.5rem;
}

.publication__links {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.publication__date {
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}

/* Certification Styles */
.certification__item {
    position: relative;
    padding-left: 2rem;
}

.certification__badge {
    position: absolute;
    left: -1rem;
    top: 0;
    color: var(--first-color);
    font-size: 2rem;
}

.certification__title {
    font-size: var(--h3-font-size);
    color: var(--title-color);
    margin-bottom: 0.75rem;
}

.certification__issuer {
    color: var(--text-color);
    font-size: var(--normal-font-size);
    margin-bottom: 1.5rem;
}

.certification__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.certification__date {
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}

.credential__link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--first-color);
    font-size: var(--small-font-size);
    font-weight: var(--font-medium);
    transition: all 0.3s;
}

.credential__link:hover {
    color: var(--first-color-alt);
    transform: translateX(4px);
}

/* Media Queries */
@media screen and (max-width: 768px) {
    .credentials__container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .credentials__group {
        padding: 1.5rem;
    }
}

@media screen and (max-width: 350px) {
    .credentials__group {
        padding: 1rem;
    }

    .publication__links, 
    .certification__footer {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }
}

/*CONTACT*/
.contact__container{
    row-gap: 2rem;
}

.contact__information{
    display: flex;
    margin-bottom: var(--mb-0-25);
}

.contact__icon{
    font-size: 2rem;
    color: var(--first-color);
    margin-right: var(--mb-0-75);
}

.contact__title{
    font-size: var(--h3-font-size);
    font-weight: var(--font-medium);
    text-align: left;
}

.contact__subtitle{
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}

/*FOOTER*/
.footer{
    padding-top: 2rem;
}

.footer__container{
    row-gap: 3.5rem;
}

.footer__bg{
    background-color: var(--first-color-second);
    padding: 2rem 0 3rem;
}

.footer__title{
    font-size: var(--h1-font-size);
    margin-bottom: var(--mb-0-25);
}

.footer__subtitle{
    font-size: var(--small-font-size);
}

.footer__links{
    display: grid;
    flex-direction: column;
    row-gap: 1.5rem;
    grid-template-columns: repeat(3, 1fr);
}

.footer__link:hover{
    color: var(--first-color-lighter);
}

.footer__socials{
    display: grid;
    grid-template-columns: repeat(3, 2fr);
}

.footer__social{
    font-size: 1.25rem;
    margin-right: var(--mb-1-5);
}

.footer__social:hover{
    color: var(--first-color-lighter);
}

.footer__title,
.footer__subtitle,
.footer__link,
.footer__social{
    color: #FFF;
}

/*SCROLL*/
.scrollup{
    position: fixed;
    right: 1rem;
    bottom: 0;
    background-color: var(--first-color);
    opacity: .8;
    padding: 0 .3rem;
    border-radius: 0.4rem;
    z-index: var(--z-tooltip);
    transition: .4s;
}

.scrollup:hover{
    background-color: var(--first-color-alt);
}

.scrollup__icon{
    font-size: 1.5rem;
    color: #FFF;
}

.show-scroll{
    bottom: 5rem;
}

::-webkit-scrollbar{
    width: .60rem;
    background-color: var(--scroll-bar-color);
    border-radius: .5rem;
}

::-webkit-scrollbar-thumb{
    background-color: var(--scroll-thumb-color);
    border-radius: .5rem;
}

::-webkit-scrollbar-thumb:hover{
    background-color: var(--text-color-light);
}
 

/*MEDIA QUERIES*/
/* For small devices */
@media screen and (max-width: 350px){
    .container{
        margin-left: var(--mb-1);
        margin-right: var(--mb-1);
    }

    .nav__menu{
        padding: 2rem .25rem 4rem;
    }
    .nav__list{
        column-gap: 0;
    }

    .home__content{
        grid-template-columns: .25fr 3fr;
    }
    .skills__title{
        font-size: var(--normal-font-size);
    }
    .footer__links{
        column-gap: 1rem;
        grid-template-columns: repeat(2, 3fr);
        justify-content: center;
    }

    .footer__socials{
        grid-template-columns: repeat(5, 1fr);
    }
}

.profile__frame {
    width: 180px;
    height: 180px;
    position: relative;
    border-radius: 50%;
    /* margin-left: auto; */
    padding: 6px;
    background: linear-gradient(145deg, var(--first-color-lighter), var(--first-color));
    box-shadow: 
        0 10px 20px rgba(128, 121, 121, 0.1),
        0 6px 6px rgba(235, 84, 84, 0.1),
        inset 0 -5px 12px rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile__photo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--container-color);
    transition: transform 0.3s ease;
    filter: contrast(1.05) brightness(1.05);
}

.profile__frame:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 15px 30px rgba(0, 0, 0, 0.15),
        0 10px 10px rgba(0, 0, 0, 0.12),
        inset 0 -5px 12px rgba(255, 255, 255, 0.3);
}

.profile__frame:hover .profile-photo {
    transform: scale(1.02);
}  

.courses__container {
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.course__card {
    background-color: var(--container-color);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.course__card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.course__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 1rem;
    text-align: center;
}

.course__icon {
    font-size: 2rem;
    color: var(--first-color);
    margin-bottom: 0.75rem;
}

.course__title {
    font-size: var(--h3-font-size);
    font-weight: var(--font-medium);
    margin-bottom: 0.25rem;
}

.course__subtitle {
    font-size: var(--small-font-size);
    color: var(--text-color-light);
}

.course__content {
    padding-top: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.course__list {
    padding-left: 1.25rem;
}

.course__list li {
    margin-bottom: 0.5rem;
    font-size: var(--normal-font-size);
    color: var(--text-color);
}

/* For medium devices */
@media screen and (max-width: 768px) {
    .courses__container {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* For small devices */
@media screen and (max-width: 576px) {
    .courses__container {
        grid-template-columns: 1fr;
    }
}

/* For medium devices */
@media screen and (min-width: 568px){
    .home__content{
        grid-template-columns: max-content 1fr 1fr;
    }
    .home__data{
        grid-column: initial;
    }
    .home__img{
        order: 1;
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
    }
 
    .about__container,
    .skills__container,
    .footer__container{
        grid-template-columns: repeat(2, 1fr);
    }

    .profile__frame {
        width: 220px;
        height: 220px;
        padding: 7px;
    }

    .contact__container{
        grid-template-columns: repeat(3, 1fr);
    }

    .footer__container{
        grid-template-columns: repeat(3, 1fr);
    }
    .footer__links{
        grid-template-columns: repeat(2,3fr);
    }
    .footer__link{
        font-size: var(--smaller-font-size);
    }
    .footer__socials{
        grid-template-columns: repeat(3,2fr);
        justify-content: center;
    }
}

@media screen and (min-width: 768px){
    .container{
        margin-left: auto;
        margin-right: auto;
    }

    body{
        margin: 0;
    }

    .section{
        padding: 5rem 0 2rem;
    }
    .section__subtitle{
        margin-bottom: 4rem;
    }

    .header{
        top: 0;
        bottom: initial;
    }

    .header,
    .main,
    .footer__container{
        padding: 0 1rem;
    }

    .nav{
        height: calc(var(--header-height) + 1.5rem);
        column-gap: 1rem;
    }
    .nav__icon,
    .nav__close,
    .nav__toggle{
        display: none;
    }
    .nav__list{
        display: flex;
        column-gap: 2rem;
    }
    .nav__menu{
        margin-left: auto;
    }
    .change-theme{
        margin: auto;
    }

    .home__container{
        row-gap: 5rem;
    }
    .home__content{
        padding-top: 5.5rem;
        column-gap: 2rem;
    }

    .footer__container{
        grid-template-columns: repeat(3, 1fr);
    }
    .footer__bg{
        padding: 3rem 0 3.5rem;
    }
    .footer__links{
        flex-direction: row;
        column-gap: 2rem;
    }
    .footer__socials{
        justify-self: flex-end;
    }
    .footer__copy{
        margin-top: 4.5rem;
    }
}

/* For large devices */
@media screen and (min-width: 1024px){
    .header,
    .main,
    .footer__container{
        padding: 0;
    }

    .home__social{
        transform: translateX(-6rem);
    }

    .contact__information{
        text-align: center;
    }

    .profile__frame {
        width: 380px;
        height: 380px;
        padding: 8px;
    }
}