/* Global Styles */
body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #001F3F;
    color: #ffffff;
    line-height: 1.6;
    height: 100vh;
    overflow-x: hidden;
}

/* Loading Gradient */
body {
    animation: loading-gradient 3s infinite;
}

/* Sticky Header */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #001F3F;
    color: white;
    z-index: 1000;
    box-shadow: 0 4px 2px -2px rgba(0, 0, 0, 0.2);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

nav ul li {
    display: inline;
}

nav ul li a {
    color: white;
    text-decoration: none;
    padding: 0.5rem;
    font-size: 1.1rem;
    transition: background-color 0.3s ease;
}

nav ul li a:hover {
    background-color: #003366;
    border-radius: 5px;
}

/* Download CV Button */
.cv-button {
    padding: 0.7rem 1.5rem;
    background-color: #007BFF;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.cv-button:hover {
    background-color: #0056b3;
}

/* About Section */
#about {
    background-color: #001F3F;
    padding: 4rem 2rem;
    margin-top: 70px;
    flex-direction: column;
}

.about-container {
    display: flex;
    align-items: center;
    justify-content: space-around;
    flex-wrap: wrap;
}

.about-header {
    font-size: 36px;
    font-weight: bold;
    margin: 0;
}

.name {
    color: #e8ff00;
    font-weight: bold;
    font-size: 48px;
}

.slogan {
    font-size: 24px;
    font-family: 'Source Code Pro', monospace;
    white-space: nowrap;
    overflow: hidden;
    border-right: 3px solid;
    width: 0;
    animation: typing 4s steps(40, end) forwards;
}

/* Keyframe for typing effect */
@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

/*Remove the blinking cursor after typing */
.slogan.typed {
    border-right: none;
}

.about-image .profile-pic {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    border: 5px solid #ffffff;
    object-fit: cover;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

/* Education & Experience Sections */
section#education, section#experience {
    background-color: #001F3F;
    padding: 4rem 2rem;
}

h2 {
    font-size: 2rem;
    color: #ffffff;
    margin-bottom: 2rem;
}

.education-container, .experience-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Experience Items */
.experience-item, .education-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #ffffff;
    color: #001F3F;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Text Styling */
.exp-text, .education-text {
    display: flex;
    flex-direction: column;
}

/* Project Section (Grid Tiles) */
#projects {
    background-color: #001F3F;
    padding: 4rem 2rem;
}

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

.project-tile {
    background-color: #ffffff;
    color: #001F3F;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.github-button {
    position: absolute;
    top: 10px;
    right: 10px;
    color: #333;
    font-size: 24px;
    text-decoration: none;
    transition: color 0.3s;
}

.project-tile:hover {
    transform: scale(1.05);
}

/* Contact Section */
#contact {
    background-color: #001F3F;
    color: white;
    padding: 4rem 2rem;
    text-align: center;
}

#contact h2 {
    font-size: 2rem;
    color: white;
    margin-bottom: 1rem;
}

#contact p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* Send email */
.cv-button {
    padding: 0.7rem 1.5rem;
    background-color: #007BFF;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.cv-button:hover {
    background-color: #0056b3;
}

/* Footer */
footer {
    background-color: #001F3F;
    color: white;
    text-align: center;
    padding: 1rem 0;
    position: relative;
    bottom: 0;
    width: 100%;
    margin-top: 2rem;
    white-space: normal;
}

/* Responsiveness */
@media (max-width: 768px) {
    .about-container {
        flex-direction: column;
        text-align: center;
    }

    .about-image {
        margin-top: 2rem;
    }

    nav ul {
        flex-direction: column;
        gap: 1rem;
    }

    nav {
        padding: 1rem;
    }

    .education-container, .experience-container {
        gap: 1.5rem; 
    }

    .experience-item, .education-item {
        flex-direction: column; 
        align-items: center;
    }

    .exp-img, .education-img {
        margin-top: 1rem;
    }

    .project-grid {
        grid-template-columns: 1fr; 
    }

    #contact {
        padding: 2rem 1rem;
    }

    #contact h2 {
        font-size: 1.5rem; 
    }
}

@media (max-width: 480px) {
    .about-header {
        font-size: 28px; 
    }

    .name {
        font-size: 36px; 
    }

    .slogan {
        font-size: 18px; 
    }

    nav ul {
        gap: 0.5rem; 
    }
}

@media (max-width: 768px) {
    .slogan {
        animation: none; 
        width: auto; 
        border-right: none;
        white-space: normal;
    }
    .nav-left {
        display: none;
    }
}