@import url('https://fonts.googleapis.com/css2?family=Lexend+Deca:wght@100..900&display=swap');

/* universal selector/targets all elements in the document (unless overridden)*/
*{
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    list-style: none;
    scroll-behavior: smooth;
    text-decoration: none;
}

/* 
----Identity Guidelines----
-- Web Background = #292929
-- Background = #474747
-- Yed = #03661e
-- Emperyean = #65ca2f 
*/

/* ":root" defines global vss variables/the entire html */
:root{
/* -- defines custom properties that store values, which can be reused througought the stylesheet */
    --text-color: #fff;
    --hover-color: #65ca2f;
    --secon-hover-color: #03661e;
    --bg-color: #292929;
    --secon-bg-color: #474747;
    --select-color: #deffcc;
    --big-font:2.5rem;
    --normal-font:2rem;
    --neon-box-shadow:0 0 .5rem #65ca2f;
    --h2-font:3rem;
/* using rgba allows control the alpha(opacity), hex colours use solid colours */
    --font-neon-text-shadow:0 0 10px rgba(101, 202, 47, 0.3),
    0 0 20px rgba(101, 202, 47, 0.3),
    0 0 30px rgba(101, 202, 47, 0.3),
    0 0 40px rgba(101, 202, 47, 0.3),
    0 0 50px rgba(101, 202, 47, 0.3),
    0 0 60px rgba(101, 202, 47, 0.3),
    0 0 70px rgba(101, 202, 47, 0.3),
    0 0 100px rgba(101, 202, 47, 0.3),
    0 0 150px rgba(101, 202, 47, 0.3);
}

body{
    font-family: "Lexend Deca", sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    margin: 0;
}

header{
    display: flex;
    align-items: center;
    justify-content: space-around;
    width: 100%;
    padding: 16px 0;
    padding-bottom: 16px;
    background: var(--secon-bg-color);
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    position: relative;
    left: 0;
    right: 0;
    margin: 0;
    transition: padding .3s ease;
}

header:hover{
    padding: 20px 0;
}

.logo {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
    display: flex; /* Ensures the logo text and image are aligned horizontally */
    align-items: start;
}

.logo-img {
    flex-shrink: 0;
    width: 40px; /* Adjust width as needed */
    height: auto;
    margin-right: px; /* Reduced margin to bring it closer to the text */
}

.logo-img img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

span{
    color: var(--hover-color);
}

.navlist{
    display: flex;
    margin-left: au;
}

.navlist a{
    color: var(--hover-color);
    font-weight: 500;
    padding: 10px 20px;
    transition: .7s;
    text-shadow: 0 0 0.3rem var(--hover-color);
    border-radius: 5px;
}

.navlist a:hover{
    color: var(--text-color);
    text-shadow:0 0 10px rgba(101, 202, 47, 0.3),
    0 0 20px rgba(101, 202, 47, 0.3),
    0 0 30px rgba(101, 202, 47, 0.3),
    0 0 40px rgba(101, 202, 47, 0.3),
    0 0 50px rgba(101, 202, 47, 0.3),
    0 0 60px rgba(101, 202, 47, 0.3),
    0 0 70px rgba(101, 202, 47, 0.3),
    0 0 100px rgba(101, 202, 47, 0.3),
    0 0 150px rgba(101, 202, 47, 0.3);
}

#menu-icon{
    font-size: 1.8rem;
    z-index: 10001;
    cursor: pointer;
    margin-left: 25px;
    background: var(--hover-color);
    border-radius: 3px;
    color: var(--secon-bg-color);
    display: none;
}

section{
    padding-top: 20px;
    padding: 100px 10%;
}

/*! refer too if displaying incorrectly */
.home{
    min-height: 100vh;
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 0 10%;
}

/* role conveyor belt */
.home-content{
    max-width: 600px;
}
/*! all home content slightly altered */
.home-content h1{
    font-size: var(--big-font);
    font-weight: 700;
    max-width: 600px;
    color: #fff;
}

.home-content p{
    max-width: 600px;
}
/*
.home-image{
    margin-left: 2rem;
}

.home-image .img-box img {
    width: 50%; /* scaling down *
    max-width: 500px;
    height: auto; /* maintain aspect ratio *
    border-radius: 10px;
}

@media (max-width: 768px){ /* phone stuff *
    .home {
        flex-direction: column; /* stacks vertically*
        align-items: center;
    }

    .home-image, .home-content{
        max-width: 100%;
    }

    .home-image .img-box img{
        width: 80%;
    }
}

.logo-img img {
    width: 100%; /* Make the image take full width of the container *
    height: auto; /* Keep the image’s natural aspect ratio *
    object-fit: contain;
}

/* Media query for smaller screens *
@media (max-width: 768px) {
    .logo-img {
        width: 50%;  /* On smaller screens, make the image larger relative to the container *
    }
}

@media (max-width: 480px) {
    .logo-img {
        width: 70%;  /* On very small screens, increase the size more *
    }
}
*/

.change-text{
    font-size: 1.5rem;
    font-weight: 600;
}

#pronunciation{
    color: #929292;
}

.change-text h3{
    position: relative;
    display: inline-block;
    margin: 0;
    vertical-align: top;
    color: #fff;
}

.change-text h3 .word{
    position: absolute;
    display: flex;
    opacity: 0;
}

.change-text h3 .word .letter{
    transform-origin: center center 25px;
}

.change-text h3 .word .letter.out{
    transform: rotateX(90deg);
    transition: 0.32s cubic-bezier(0.6,0,0.7,0.2);
}

.change-text h3 .word .letter.in{
    transition: 0.38s ease;
}

.change-text h3 .word .letter.behind{
    transform: rotateX(-90deg);
}

.home-content p{
    color: #bdbdbd;
    line-height: 1.6;
}

.info-box{
display: inline-flex;
justify-content: space-between;
align-items: center;
width:300px;
margin: 1rem 0 2rem;
}

.info-box h5{
    font-weight:600;
    color: var(--text-color);
    font-size: 1rem;
}

.info-box span{
    font-size: .9rem;
    color: #bdbdbd
}

/* buttons */
.btn-box{
    display: flex;
    justify-content: space-between;
    width: 320px;
    height: 45px;
}

/* button glow */
.btn-box a.btn{
    background: var(--hover-color);
    color: var(--bg-color);
    width: 150px;
    height: 100%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-size: 1rem;
    letter-spacing: 1px;
    font-weight: 600;
    transition: .6s;
    box-shadow: var(--neon-box-shadow);
    border-radius: 5px;
    position: relative;
    overflow: hidden;
    z-index: 0;
    border: 2px solid var(--hover-color);
}

a.btn:hover{
    box-shadow: 0 0 15px rgba(101, 202, 47, 0.8), 0 0 30px rgba(101, 202, 47, 0.6);
}

a.btn#hire-me:hover{
    color: var(--bg-color);
}

a.btn#download-cv:hover{
    color: var(--hover-color);
}

a.btn#read-more:hover{
    color: var(--hover-color);
}

a.btn#send-mess:hover{
    color: var(--bg-color);
}

a.btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    background: var(--bg-color);
    width: 0;
    height: 100%;
    z-index: -1;
    transition: width 0.4s;
}

a.btn:hover::before {
    width: 100%;
}

a.btn:nth-child(2){
    background-color: var(--bg-color);
    color: var(--hover-color);
}

a.btn:nth-child(2):hover{
    color: var(--bg-color);

}

a.btn:nth-child(2)::before{
    background: var(--hover-color);
}

.social-icons{
    margin-top: 8rem;
    display: flex;
    justify-content: space-between;
    width: 220px;
    height: 40px;
    margin-bottom: 2rem;
    margin-left: .6rem;
}

.social-icons a{
    display: inline-flex;
    width: 50px;
    height: 100%;
    justify-content: center;
    align-items: center;
    background: var(--bg-color);
    color: var(--hover-color);
    border: 2px solid var(--hover-color);
    transition: .6s;
    box-shadow: 0 0 0.3rem #65ca2f;
    border-radius: 5px;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.social-icons a i{
    font-size: 1.5rem;
    transition: color 0.6s;
}

.social-icons a:hover{
    background: var(--hover-color);
    border-color: var(--hover-color);
    color: var(--bg-color);
    box-shadow: 0 0 15px rgba(101, 202, 47, 0.8), 0 0 30px rgba(101, 202, 47, 0.6);
}

/*! irrelevant until further notice */
/* 
.social-icons a:hover i {
    color: var(--bg-color); /* turns into when hovered *
    background: var(--hover-color);
    border-color: var(--hover-color);
    transition: color .6s;
}

.social-icons a::before{ 
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    transition: .6s;
    z-index: -1;
}
*/

.home-image{
    position: relative;
}

.img-box{
    text-align: center;
}

.img-box img{
    width: 100%;
    max-width: 350px;
    height: auto;
    border-radius: 60px;
}

.liquid-shape{
    position: absolute;
    width: 70%;
    height: auto;
    z-index: -1;
    top: 10%;
    margin: none;
}

/*
.liquid-shape:nth-child(2){ /* glow?? (not functioning) *
    filter: blur(50px);
}
*/



/* --- About segment --- */
.about{
    display: flex;
    justify-content: center;
    align-items: center;
    grid-gap: 2em;
    background: var(--secon-bg-color);
    border-radius: 10px;
    padding: 1em;
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    left: 20px;
}

.about-image{
    position: relative;
}

.img-about{
    text-align: center;
}

.img-about img{
    width: 100%;
    max-width: 350px;
    height: auto;
    border-radius: 25px;
}


.about-content span{
    color: #fdfdfd;
    font-size: 1.25rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.about-content h2{
    color: var(--hover-color);
    font-weight: 700;
    font-size: var(--normal-font);
}

.about-content h3{
    font-weight: 600;
    font-size: 1.5rem;
    margin-bottom: .2rem;
}

.about-content p{
    color: #fdfdfd;
    font-weight: 400;
    margin-bottom: 1.5rem;
}

.info-about1, 
.info-about2, 
.info-about3{
    font-size: .8rem !important; /* not fully functional? */
    display: block;
    border: 1px solid var()
}

/* skills */
.skills{
    display: flex;
    justify-content: center;
    align-items: center;
    grid-gap: 2em;
    background: var(--secon-bg-color);
    border-radius: 10px;
    padding: 1em;
    max-width: 900px;
    max-height: 297.5px;
    overflow: hidden;
    margin: 0 auto;
    position: relative;
    left: 20px;
    margin-top: 20px;
}

.skill-main{
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr; /* creates 2 individual columns */
    grid-row-gap: 30px;
    grid-column-gap: 290px;
}

.skill-left, .skill-right{
    width: 100%;
    overflow-wrap: break-word; /* ensures text wraps within its container */
    word-wrap: break-word;
    hyphens: auto; /* adds hyphens when words are broken */
}

.skill-bar{
    width: 100%;
}

.bar{
    background-color: white; /* background color for the incomplete part */
    border-radius: 5px; 
    height: 10px; 
    position: relative;
    width: 100%; /* ensures all bars occupy the same width */
}

.bar span{
    display: block; 
    height: 100%; 
    background-color: var(--hover-color); /* color of the progress */
    border-radius: 5px; 
    position: absolute; 
    left: 0; 
    transition: width 0.5s ease; /* smooth transition effect */
    box-shadow: 0 0 10px rgba(101, 202, 47, 0.6);
}

/* width for each skill bar */
.skill-bar .bar span[data-skill="html"]{
    width: 75%; 
}

.skill-bar .bar span[data-skill="css"]{
    width: 80%; 
}

.skill-bar .bar span[data-skill="javascript"]{
    width: 60%; 
}

.skill-bar .bar span[data-skill="python"]{
    width: 55%; 
}

.portfolio{
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2em;
    margin-top: 20px;
    margin-left: 38px;
}

.projects{
    margin-left: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr; /* 2 columns layout */
    grid-gap: 30px; /* spacing between items */
    max-width: 900px;
    margin: 0px auto;
    padding: 20px;
    background-color: var(--secon-bg-color);
    border-radius: 10px;
}

.project-img{
    background-color: var(--bg-color);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 250px; /* ensure enough space for content */
    max-height: 100%; /* remove any fixed height limit */
}

.project-img img{
    width: 100%; 
    height: auto;
    border-radius: 5px;
    border: 3px solid var(--hover-color);
    box-shadow: 0 0 10px var(--hover-color),
    0 0 15px var(--hover-color);
    transition: transform 0.3s ease-in-out;
}

.project-img img:hover{
    transform: scale(1.05);
}

.project-img h2{
    margin-top: 10px;
    color: var(--hover-color);
    margin-bottom: 10px;
}

.project-img p{
    color: var(--text-color);
    word-wrap: break-word;  
    overflow-wrap: break-word; /* another way to force word breaks */
    flex-grow: 1;
    margin-bottom: 15px;
    white-space: normal; /* allow multi-line text */
    text-overflow: unset; /* remove ellipsis */
}

.project-img{
    overflow: visible; /* make sure content is fully shown */
}

/* --- Contact segment --- */
.contact{
    background: var(--secon-bg-color);
    width: 100%;
}

.contact form{
    text-align: center;
    max-width: 50rem;
    margin: 1rem auto;
    margin-bottom: 3rem;
}

.contact form input,
.contact form textarea{
    width: 100%;
    color: var(--text-color);
    background: var(--bg-color);
    margin-bottom: .8rem;
    border: none;
    border-radius: 5px;
    padding: .7rem;
}

.contact form textarea{
    resize: none;
}

.formBtn{
    display: flex;
    justify-content: center;
    width: 100%;
}

.btn-box .btn{
    color: var(--bg-color);
    width: 150px;
    height: 100%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-size: 1rem;
    letter-spacing: 1px;
    font-weight: 600;
    transition: .6s;
    box-shadow: var(--neon-box-shadow);
    border-radius: 5px;
    position: relative;
    z-index: 0;
    border: 2px solid var(--hover-color);
}

.btn:hover{
    box-shadow: 0 0 15px rgba(101, 202, 47, 0.8), 0 0 30px rgba(101, 202, 47, 0.6);
}

.btn::before{
    content: "";
    position: absolute;
    left: 0;
    background: var(--hover-color);
    width: 0;
    height: 100%;
    transition: width 0.3s;
}

#send-mess{
    font-family: "Lexend Deca", sans-serif;
    color: var(--hover-color);
    background: var(--bg-color);
}

a.btn#send-mess:hover::before{
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%; /* Full height */
    z-index: 1; /* Place behind the text */
    transition: width 0.3s ease; /* Smooth animation */
}

#send-mess:hover{
    color: var(--bg-color);
}


.btn:hover::before{
    color: var(--bg-color);
    width: 100%;
    z-index: -1;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .home {
        flex-direction: column;
        text-align: center;
    }

    .home-content h1 {
        font-size: 2rem;
    }

    .btn-box {
        flex-direction: column;
        align-items: center;
        gap: 10px;
        width: auto;
    }

    .btn-box a.btn {
        width: 80%;
    }

    .social-icons {
        justify-content: center;
        gap: 10px;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: center;
    }

    .logo {
        font-size: 20px;
    }

    .navlist {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    #menu-icon {
        display: block;
    }

    .navlist a {
        padding: 10px;
        font-size: 1rem;
    }

    .home-content p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .home-content h1 {
        font-size: 1.8rem;
    }

    .home-content p {
        font-size: 0.8rem;
    }

    .btn-box {
        flex-direction: column;
        width: 100%;
    }

    .btn-box a.btn {
        width: 90%;
        font-size: 0.9rem;
    }

    .social-icons a {
        width: 40px;
        height: 40px;
        font-size: 0.8rem;
    }

    .contact form input,
    .contact form textarea {
        font-size: 0.9rem;
        padding: 0.5rem;
    }
}
