/* Globla Settings */
:root {
    --color-bg-dark: #0a0a0a;
    --color-primary-dark: #fffdf2;
    --color-accent-dark: #8c0d14;

    --color-bg-light: #eeeeee;
    --color-primary-light: #0a0a0a;
    --color-accent-light: #b4121b;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    padding: 0;
    margin: 0;
    font-family: 'Poppins', 'Helvetica Neue', Helvetica, Arial;
    transition: all 0.5s ease-in-out;
    overflow-x: hidden;
    overflow-y: auto;
    background-color: var(--color-bg-light);
    color: var(--color-primary-light);
}

body.dark {
    background-color: var(--color-bg-dark);
    color: var(--color-primary-dark);
}

#canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

button.btn {
    background-color: inherit;
    color: inherit;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease-in-out;
}

a {
    color: inherit;
}

.btn i {
    scale: 1.5;
}

#dark-light-switch {
    background-color: transparent;
    color: inherit;
    width: 2rem;
    height: 2rem;
    bottom: 20px;
    right: 20px;
    border: none;

    &:hover {
        cursor: pointer;
        transform: scale(1.5);
    }
}

h1 {
    font-size: 5.61rem;
    margin-bottom: 1.25rem;
    font-weight: 200;
    letter-spacing: -5px;
}

h3 {
    font-size: 3.157rem;
    margin-bottom: 0.5rem;
    font-weight: 400;
    letter-spacing: -1px;
}

p {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    line-height: 1.5;
}

.highlighted-text {
    font-weight: bold;
    position: relative;
    display: inline-block;
    background: radial-gradient(circle at center, #ffa083, #b4121b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    transition: background-position 0.1s ease-out;
}

/* Navigation Bar */

#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: fit-content;
    background-color: transparent;
    padding: 1rem;
    margin-bottom: 0.5rem;
    z-index: 999;
}

#navbar.scrolled {
    backdrop-filter: blur(15px);
}

.nav-items {
    width: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
}

.nav-items>li {
    list-style-type: none;
    cursor: pointer;
    font-weight: 400;
    letter-spacing: 1px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.nav-items>li:hover {
    transform: translateY(-5px);
}

.menu-item {
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: inherit;
    transition: all 0.3s ease-in-out;
}


.nav-menu-container {
    display: flex;
    width: 100%;
    justify-content: space-evenly;
}

.mobile-menu-button {
    display: none;
}

/* Intersection Observer Display */

#navbar.main-content {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

#about.main-content {
    opacity: 0;
    transform: translateX(100px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

#projects.show-on-scroll,
#contact.show-on-scroll {
    opacity: 0;
    transform: translateX(100px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.main-content.show,
#navbar.show,
#about.show,
#projects.show,
#contact.show {
    opacity: 1;
    transform: translateY(0);
}

/* Wlecome Screen */

.welcome-screen {
    position: relative;
    z-index: 1000;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.welcome-screen.hidden {
    animation: fadeOut 0.5s forwards ease;
}

i.material-icons {
    line-height: 1;
    margin-right: 0.25rem;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
}

#about,
#projects,
#contact {
    text-align: center;
    padding: 4rem 2rem;
}

#about i {
    font-size: 3.157rem;
    margin-bottom: 0.5rem;
}

.skills-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.comfortable-container {
    text-align: left;
}

.learning-container {
    text-align: right;
}

.introduction p {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    line-height: 1.5;
    padding: 2.5em 10rem;
}

.introduction img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    margin-top: 1.25rem;
    border-radius: 40% 60% 70% 30% / 40% 40% 60% 50%;
}

.project-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    margin-top: 1rem;
    gap: 2rem;
}

.project-card {
    width: 350px;
    height: fit-content;
    min-width: 300px;
    padding: 1.25rem;
    border-radius: 10px;
    box-shadow: 0 5px 10px rgba(116, 116, 116, 0.5);
    transition: all 0.3s ease-in-out;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(116, 116, 116, 0.7);
}

.project-card img {
    border-radius: 5px;
    width: 350px;
    height: auto;
    object-fit: cover;
}

.project-card button {
    margin-top: 0.25rem;
    border: 1px solid gray;
    font-size: 1rem;
}

#contact i {
    font-size: 3.75rem;
    margin-bottom: 0.5rem;
}

#contact a {
    text-decoration: none;
    color: inherit;
}

/* Animations */
@keyframes fadeOut {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

@keyframes bounce {
    from {
        transform: translateY(0);
        opacity: 0.6;
    }

    to {
        transform: translateY(-10px);
        opacity: 1;
    }
}

@keyframes typewriter {
    0% {
        width: 0;
    }

    100% {
        width: 100%;
    }

    50% {
        width: 100%;
    }

    100% {
        width: 0;
    }
}

/* Media Queries */

@media (max-width: 768px) {
    .mobile-menu-button {
        display: block;
        margin: 0 auto;
    }

    #navbar {
        background-color: transparent;
        transition: background-color 0.3s ease;
    }

    #navbar.scrolled {
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        background-color: transparent;
    }

    .nav-menu-container {
        display: flex;
        visibility: hidden;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        opacity: 0;
        transform: translateY(-30%);
        transition: transform 0.7s ease-in-out, opacity 0.3s ease-in-out, background-color 0.3s ease;
    }

    .nav-menu-container.active {
        width: 100%;
        height: 50vh;
        z-index: 1000;
        visibility: visible;
        opacity: 1;
        transform: translateY(0);
        display: flex;
        justify-content: center;
        align-items: center;
        background-color: var(--color-bg-light);
    }

        /* Theme-specific menu container styles */
    
        body.dark .nav-menu-container,
        body.dark .nav-menu-container.active {
            background-color: var(--color-bg-dark);
        }

    .nav-items {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 0;
        gap: 1.5rem;
        margin-right: 0.33rem;
        margin: 0 auto;
    }  
    /* Ensure individual nav items are centered */
    .nav-items > * {
        text-align: center;
        width: 100%;
    }

    h1 {
        font-size: 3.927rem;
        margin-bottom: 0.5rem;
        letter-spacing: -2px;
    }

    h3 {
        font-size: 2.25rem;
        margin-bottom: 0.5rem;
        font-weight: 400;
        letter-spacing: -1px;
    }

    .skills-wrapper {
        display: flex;
        flex-direction: column;
        align-items: center;
        margin-top: 2.75rem;
    }

    .comfortable-container {

        text-align: center;
    }

    .learning-container {
        text-align: center;
    }

    .introduction p {
        font-size: 1rem;
        margin-bottom: 0.25rem;
        line-height: 1.75;
        padding: 1.5rem 1rem;
    }

    .project-card img {
        border-radius: 5px;
        width: 300px;
        height: auto;
        object-fit: cover;
    }
}