:root {
    --color-dark-base: #03001C; /* Very dark blue/black base */
    --color-deep-blue: #0A043C; /* Deep, rich blue */
    --color-violet-accent: #2A045C; /* Dark violet for the gradient end */
    --color-text-light: #E0E7FF; /* Off-white for body text */
    --color-highlight-cyan: #2DD4BF; /* Vibrant highlight color */
    --color-text-faded: #9CA3AF; /* Faded text for secondary info */
    --font-smooth: 'Poppins', sans-serif; /* Smooth-looking font */
}

/* Base Styles & Dark Theme Setup */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-smooth);
    color: var(--color-text-light);
    line-height: 1.6;
    background: linear-gradient(180deg, var(--color-dark-base) 0%, var(--color-deep-blue) 40%, var(--color-violet-accent) 100%);
    background-attachment: fixed; 
}

/* Typography Styles*/
h1, h2, h3 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.5em;
}

.hero-text {
    font-size: clamp(2.5rem, 6vw, 5rem); 
    font-weight: 800;
    letter-spacing: -0.05em;
    color: var(--color-text-light);
}

.highlight-text {
    color: var(--color-highlight-cyan);
}

.intro-text {
    font-size: clamp(1rem, 2vw, 1.25rem); 
    font-weight: 300; 
    color: var(--color-text-faded);
    max-width: 500px;
}

.intro-text b, 
.intro-text strong {
    font-weight: 600;
    color: var(--color-text-light);
}

/* Navbar Styling */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    background-color: rgba(3, 0, 28, 0.8); 
    backdrop-filter: blur(5px);
    z-index: 1000;
}

.navbar .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-highlight-cyan);
}

.nav-link {
    color: var(--color-text-light);
    text-decoration: none;
    margin-left: 2rem;
    font-weight: 400;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--color-highlight-cyan);
}

/* Hero Section Styling */
.hero-section {
    min-height: 100vh;
    padding: 10rem 5% 5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

.hero-left, .hero-right {
    flex: 1;
    min-width: 300px;
}

#avatar {
    max-width: 100%;
    height: auto;
    border-radius: 50%; 
    box-shadow: 0 0 50px rgba(45, 212, 191, 0.3); 
    display: block;
}


.content-section {
    min-height: 80vh;
    padding: 5rem 5%;
    border-top: 1px solid rgba(45, 212, 191, 0.1); 
}


/*Academic Timeline Styles */

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 4rem auto;
    padding: 0 1rem;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 4px; 
    background: linear-gradient(to bottom, var(--color-highlight-cyan), var(--color-violet-accent));
    transform: translateX(-50%);
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding: 10px 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    width: 20px;
    height: 20px;
    background-color: var(--color-highlight-cyan); 
    border: 3px solid var(--color-deep-blue);
    border-radius: 50%;
    transform: translateX(-50%);
    z-index: 10;
    box-shadow: 0 0 15px rgba(45, 212, 191, 0.5); 
}

/* The content card */
.timeline-content {
    background-color: var(--color-deep-blue); 
    padding: 2rem;
    border-radius: 8px;
    width: 45%; 
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--color-highlight-cyan); 
}

.timeline-content h3 {
    color: var(--color-text-light);
    margin-bottom: 0.5rem;
}

.timeline-content .grade {
    color: var(--color-highlight-cyan); 
    font-weight: 600;
    margin-top: 0.5rem;
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-right: 55%; 
    text-align: right;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: 55%; 
    text-align: left;
}


/*Projects Section Styles */

.projects-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 30px;
    margin-top: 3rem;
}

.project-card {
    flex: 1 1 100%; /* Default to 1 per row on small screens */
    background-color: var(--color-deep-blue);
    padding: 2.5rem;
    border-radius: 10px;
    border: 1px solid rgba(45, 212, 191, 0.15); 
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

@media (min-width: 768px) {
    .project-card {
        flex: 1 1 calc(50% - 15px); /* 2 per row on tablets */
    }
}

@media (min-width: 1024px) {
    .project-card {
        flex: 1 1 calc(33.333% - 20px); /* 3 per row on desktops */
        max-width: calc(33.333% - 20px); /* Keeps the grid aligned for odd bottom elements */
    }
}

.project-card:hover {
    transform: translateY(-5px); 
    box-shadow: 0 12px 40px rgba(45, 212, 191, 0.2); 
}

.project-card h3 {
    color: var(--color-highlight-cyan);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.tech-stack {
    color: var(--color-text-faded);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.description {
    color: var(--color-text-light);
    margin-bottom: 1.5rem;
}

.project-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

/* Reusable Button Styles */
.cta-button {
    padding: 10px 18px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease, color 0.3s ease;
    white-space: nowrap; 
}

.cta-button.primary {
    background-color: var(--color-highlight-cyan);
    color: var(--color-dark-base);
}

.cta-button.primary:hover {
    background-color: #14B8A6; 
}

.cta-button.secondary {
    background-color: transparent;
    color: var(--color-highlight-cyan);
    border: 1px solid var(--color-highlight-cyan);
}

.cta-button.secondary:hover {
    background-color: rgba(45, 212, 191, 0.1); 
}


/* Contact Section Styles */

.contact-section {
    min-height: 40vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 5%;
}

.contact-section h2 {
    margin-bottom: 0.5rem;
}

.contact-prompt {
    color: var(--color-text-faded);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.contact-links {
    display: flex;
    gap: 30px;
    margin-bottom: 3rem;
}

.contact-icon-link {
    font-size: 2.5rem; 
    color: var(--color-text-light);
    transition: color 0.3s ease, transform 0.3s ease;
}

.contact-icon-link:hover {
    color: var(--color-highlight-cyan); 
    transform: translateY(-5px) scale(1.1); 
}

.copyright {
    font-size: 0.8rem;
    color: var(--color-text-faded);
}


/* Achievements Section Styles */

.achievements-list {
    list-style: none; 
    padding: 0;
    margin: 3rem auto 0;
    max-width: 800px;
}

.achievement-item {
    background-color: var(--color-deep-blue);
    padding: 1.5rem 2rem;
    margin-bottom: 20px;
    border-radius: 8px;
    border-left: 5px solid var(--color-highlight-cyan); 
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    transition: background-color 0.3s ease;
}

.achievement-item:hover {
    background-color: var(--color-violet-accent);
}

.achievement-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-text-light);
    margin-bottom: 0.3rem;
}

.achievement-details {
    font-size: 1rem;
    font-weight: 300;
    color: var(--color-text-faded); 
}


/*Experience Section Styles */
.experience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 30px;
    margin-top: 3rem;
}

.experience-card {
    background-color: var(--color-deep-blue);
    padding: 2rem;
    border-radius: 10px;
    border-top: 3px solid var(--color-highlight-cyan); 
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%; 
}

.experience-card:hover {
    transform: translateY(-5px); 
    box-shadow: 0 12px 40px rgba(45, 212, 191, 0.2);
}

.role-title {
    color: var(--color-highlight-cyan); 
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.company-date {
    color: var(--color-text-faded);
    font-size: 0.95rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
}

.experience-bullets {
    list-style: none; 
    padding: 0;
}

.experience-bullets li {
    position: relative;
    padding-left: 1.5rem; 
    margin-bottom: 10px;
    color: var(--color-text-light);
    font-size: 1rem;
    line-height: 1.4;
}


.experience-bullets li::before {
    content: '\f111'; 
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    color: var(--color-highlight-cyan);
    position: absolute;
    left: 0;
    font-size: 0.6rem;
    top: 0.4rem;
}


/* Clubs & Leadership Section Styles */

.clubs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 3rem;
}

.club-card {
    background: linear-gradient(145deg, rgba(10, 4, 60, 0.9), rgba(42, 4, 92, 0.45));
    padding: 2.2rem 2rem;
    border-radius: 14px;
    border: 1px solid rgba(45, 212, 191, 0.12);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    overflow: hidden;
}

.club-card::before {
    content: '';
    position: absolute;
    top: -60%;
    right: -30%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(45, 212, 191, 0.06) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.club-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 44px rgba(45, 212, 191, 0.15);
    border-color: rgba(45, 212, 191, 0.35);
}

.club-card:hover::before {
    opacity: 1.5;
}

.club-icon-wrap {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-highlight-cyan), #14b8a6);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
    box-shadow: 0 0 18px rgba(45, 212, 191, 0.3);
}

.club-icon-wrap i {
    font-size: 1.15rem;
    color: var(--color-dark-base);
}

.club-role-badge {
    display: inline-block;
    padding: 4px 14px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: var(--color-highlight-cyan);
    border: 1px solid rgba(45, 212, 191, 0.35);
    border-radius: 20px;
    background: rgba(45, 212, 191, 0.08);
    margin-bottom: 0.9rem;
}

.club-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-text-light);
    margin-bottom: 0.6rem;
    line-height: 1.35;
}

.club-description {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--color-text-faded);
    line-height: 1.55;
}

/* Cursor Sparkle Container */
.sparkle-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none; 
    z-index: 9999;
}

/* Individual Sparkle Style */
.sparkle {
    position: absolute;
    width: 8px; 
    height: 8px;
    background-color: var(--color-highlight-cyan); 
    border-radius: 50%;
    
    box-shadow: 0 0 6px 3px rgba(45, 212, 191, 0.7); 
    
    transition: 
        transform 0.8s ease-out, 
        opacity 0.8s ease-out;
    
    opacity: 1; 
}

.sparkle-fade {
    opacity: 0 !important; 
    transform: scale(0.2) translateY(-25px);
}


.menu-toggle {
    display: none; /* Hide on desktop */
    background: transparent;
    border: none;
    color: var(--color-highlight-cyan);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

@media (max-width: 768px) {
   
    .hero-section {
        flex-direction: column;
        text-align: center;
    }
    .hero-left {
        order: -1;
    }
  
    .menu-toggle {
        display: block; 
    }
    .nav-links-container {
        position: absolute;
        top: 100%; 
        left: 0;
        width: 100%;
        display: flex;
        flex-direction: column;
        background-color: var(--color-dark-base);
        padding: 1rem 0;
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
    }
    .nav-links-container.open {
        transform: translateX(0);
    }
    .nav-link {
        width: 100%;
        padding: 0.75rem 5%;
        margin: 0;
        text-align: left;
        border-bottom: 1px solid rgba(45, 212, 191, 0.1);
    }

  
    .timeline::before {
        left: 20px;
    }
    .timeline-item {
        justify-content: flex-start;
    }
    .timeline-dot {
        left: 20px;
        transform: translateX(-50%);
    }
    .timeline-content,
    .timeline-item:nth-child(odd) .timeline-content,
    .timeline-item:nth-child(even) .timeline-content {
        width: calc(100% - 60px);
        margin-left: 60px;
        margin-right: 0;
        text-align: left;
    }
    
    
    .achievement-item {
        padding: 1.2rem 1.5rem;
    }
    .achievement-title {
        font-size: 1.1rem;
    }
}