/*Fonts from google*/
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --bg-color: #fdfdfd;
    --text-color: #333;
    --main-color:#8854d0;
    --second-bg-color: #f0f0f0;
    --box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Dark Mode Variables */
.dark-mode {
    --bg-color: #1f1f1f;
    --text-color: #fff;
    --main-color: #d4a5a5;
    --second-bg-color: #323232;
    --box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    scroll-behavior: smooth;
    font-family: 'Poppins', sans-serif;
    transition: background-color 0.3s, color 0.3s;
}

html {
    font-size: 62.5%;
    overflow-x: hidden;
}

body {
    /* Colour changing */
    background: linear-gradient(-45deg, #fff1eb, #ace0f9, #e0c3fc, #fdfbfb);
    background-size: 400% 400%;
    animation: gradientBG 20s ease infinite; /* Slower (20s) for a calm vibe */
    color: var(--text-color);
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Navigatin bar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 2rem 9%;
    background: var(--bg-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    box-shadow: var(--box-shadow);
}

.logo {
    font-size: 2.5rem;
    color: var(--text-color);
    font-weight: 600;
}

.nav-links {
    display: flex;
    gap: 3.5rem;
    list-style: none;
}

.nav-links a {
    font-size: 1.7rem;
    color: var(--text-color);
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--main-color);
}

#theme-toggle {
    background: none;
    font-size: 2rem;
    color: var(--text-color);
    cursor: pointer;
}

.hamburger {
    font-size: 3.6rem;
    color: var(--text-color);
    display: none;
    cursor: pointer;
}

/* Sections */
section {
    min-height: 100vh;
    padding: 10rem 9% 2rem;
}

/* Home */
#home {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4rem;
}

.home-content h1 {
    font-size: 5.6rem;
    font-weight: 700;
    line-height: 1.3;
}

.home-content h3 {
    font-size: 3.6rem;         
    font-weight: 800;          
    color: #1a1a1a;            
    text-shadow: 2px 2px 0px rgba(255, 255, 255, 0.6); 
    margin-bottom: 1rem;      
}

.home-content h3 span {
    color: #000;            
    text-shadow: 0px 4px 10px rgba(0,0,0,0.2); 
}

.home-content p {
    font-size: 1.6rem;
    margin: 2rem 0 3rem;
}

.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background: transparent;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    margin-right: 1.5rem;
    transition: .5s ease;
}

.social-icons {
    margin-bottom: 2.5rem; 
}

.social-icons a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background: transparent;
    border: .2rem solid var(--main-color);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    margin-right: 1.5rem;
    transition: .5s ease;
}

.btn {
    display: inline-block;
    padding: 1rem 2.8rem;
    background: var(--main-color);
    border-radius: 4rem;
    font-size: 1.6rem;
    color: var(--bg-color);
    letter-spacing: .1rem;
    font-weight: 600;
    transition: .5s ease;
}

.home-img img {
    width: 30vw;
    border-radius: 50%;
    box-shadow: 0 0 25px var(--main-color);
}

/* About */
#about {
    background: var(--second-bg-color);
}

.heading {
    text-align: center;
    font-size: 4.5rem;
    margin-bottom: 3rem;
}

.heading span {
    color: var(--main-color);
}

.about-text h3 {
    font-size: 2.6rem;
}

.about-text p {
    font-size: 1.6rem;
    margin: 2rem 0;
}

.skills-grid {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.skill-item {
    font-size: 1.5rem;
    background: var(--bg-color);
    padding: 1rem 2rem;
    border-radius: 5px;
    box-shadow: var(--box-shadow);
}

/* Projects */
.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background: rgba(255, 255, 255, 0.25); /* Semi-transparent white */
    backdrop-filter: blur(10px);             /* The Blur Magic */
    -webkit-backdrop-filter: blur(10px);     /* Safari support */
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    transition: transform 0.5s, box-shadow 0.5s;
}

.project-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.project-card:hover {
    transform: translateY(-10px);
}

.project-img {
    width: 100%;
    height: 250px; 
    overflow: hidden; 
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    object-position: center;
    transition: transform 0.5s ease;
}

.project-card:hover .project-img img {
    transform: scale(1.1);
}

.project-info {
    padding: 2rem;
}

.project-info h4 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.project-info p {
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
}

.btn-small {
    font-size: 1.4rem;
    color: var(--main-color);
    font-weight: 600;
}

/* Contact */
form {
    max-width: 70rem;
    margin: 1rem auto;
    text-align: center;
    margin-bottom: 3rem;
}

.input-box {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.input-box input, textarea {
    width: 100%;
    padding: 1.5rem;
    font-size: 1.6rem;
    color: var(--text-color);
    background: var(--second-bg-color);
    border-radius: .8rem;
    margin: .7rem 0;
}

.input-box input {
    width: 49%;
}

/* Footer */
footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 2rem 9%;
    background: var(--second-bg-color);
}

.footer-text p {
    font-size: 1.6rem;
}

.footer-iconTop a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: .8rem;
    background: var(--main-color);
    border-radius: .8rem;
    color: white;
}

/* Mobile Responsive Media Queries */
@media (max-width: 768px) {
    .hamburger {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 1rem 3%;
        background: var(--bg-color);
        border-top: .1rem solid rgba(0,0,0,.1);
        display: none;
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links.active {
        display: flex;
    }

    #home {
        flex-direction: column;
    }

    .home-img img {
        width: 70vw;
        margin-top: 2rem;
    }

    .input-box input {
        width: 100%;
    }
}

/* Animated Background for Dark Mode */
body.dark-mode {
    background: linear-gradient(-45deg, #0f2027, #203a43, #2c5364, #2b1055);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

/* Glass Card Colour for darkmode */
body.dark-mode .project-card, 
body.dark-mode .navbar,
body.dark-mode .skill-item,
body.dark-mode input, 
body.dark-mode textarea {
    background: rgba(0, 0, 0, 0.6); /* Dark glass */
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;

}
