:root {
    --bg-color: #0b1219;
    --text-color: #e6edf3;
    --accent-color: #0ea5e9;
    --accent-secondary: #2dd4bf;
    --surface-color: #161b22;
    --surface-border: #30363d;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-heading: 'Inter', sans-serif;
    --transition-speed: 0.3s;
    --mouse-x: 50%;
    --mouse-y: 50%;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

main {
    flex: 1;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--accent-color);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color var(--transition-speed);
}

a:hover {
    color: var(--accent-secondary);
    text-shadow: 0 0 8px rgba(126, 231, 135, 0.4);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section.container {
    margin-top: 2rem;
}

/* Header & Nav */
header {
    background-color: rgba(13, 17, 23, 0.95);
    border-bottom: 1px solid var(--surface-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    font-family: var(--font-heading);
    background: linear-gradient(45deg, var(--accent-color), var(--accent-secondary));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo img {
    height: 40px;
    width: auto;
    /* Reset background clip for the image itself if needed, 
       but since it's an img tag, text styles shouldn't affect it 
       unless we treat it wierdly. 
       However, the parent has webkit-text-fill-color: transparent 
       which might make the image invisible in some browsers if it inherits?
       Actually, text-fill-color only affects text. 
       But let's be safe and wrap the text in a span.
    */
}

.logo span {
    background: linear-gradient(45deg, var(--accent-color), var(--accent-secondary));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-secondary);
    transition: width var(--transition-speed);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Hexagonal Pattern (Benzene Rings) */
    background-image:
        radial-gradient(circle, var(--surface-border) 1px, transparent 1px),
        radial-gradient(circle, var(--surface-border) 1px, transparent 1px);
    background-size: 40px 40px;
    background-position: 0 0, 20px 20px;
    opacity: 0.1;
    /* Very subtle */
    z-index: -2;
    pointer-events: none;
}

/* Canvas for Molecular Network */
#molecular-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    /* Behind content, in front of hex pattern */
    pointer-events: none;
}

/* Updated Hero - Clean & Professional */
.hero {
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

/* Removed the old .hero::before pulse animation to reduce "gamer" feel */

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.1);
    }
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 0 0 20px rgba(0, 240, 255, 0.3);
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem;
    color: #8b949e;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: transparent;
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    font-family: var(--font-heading);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-speed);
}

.btn:hover {
    background: rgba(0, 240, 255, 0.1);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.4);
    transform: translateY(-2px);
}

/* Section General */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-secondary);
    margin: 10px auto 0;
}

/* Grid Layouts */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--surface-color);
    border: 1px solid var(--surface-border);
    padding: 1.5rem;
    border-radius: 4px;
    /* Techy sharp corners or slightly rounded */
    transition: transform var(--transition-speed), border-color var(--transition-speed);
}

.card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-color);
}

/* Footer */
footer {
    background: var(--surface-color);
    padding: 2rem 0;
    text-align: center;
    margin-top: auto;
    border-top: 1px solid var(--surface-border);
}


/* Timeline Layout */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding-left: 3rem;
    border-left: 2px solid var(--surface-border);
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -3.6rem;
    /* 3rem padding + 2px border + ~0.5rem is center? 
       Border is at 0 of padding box? No, border is on .timeline.
       Start of .timeline content is +3rem.
       Border is at 0px relative to .timeline content-box? No.
       If .timeline has padding-left: 3rem, border is on the left edge.
       So left: -3rem pushes to border.
       We want center of 12px dot on the 2px border.
       so left: calc(-3rem - 5px); 
    */
    top: 5px;
    width: 12px;
    height: 12px;
    background: var(--accent-color);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-color);
    transition: transform var(--transition-speed);
}

.timeline-item:hover::before {
    transform: scale(1.3);
    background: var(--accent-secondary);
    box-shadow: 0 0 15px var(--accent-secondary);
}

.timeline-year {
    font-size: 1.5rem;
    color: var(--accent-color);
    font-family: var(--font-heading);
    margin-bottom: 1rem;
    position: relative;
    line-height: 1;
}



.timeline-content {
    background: linear-gradient(90deg, rgba(13, 17, 23, 0.95) 0%, rgba(13, 17, 23, 0.6) 100%);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    /* Safari support */
    padding: 1.5rem;
    border-radius: 8px;
    /* No border to keep it open */
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    /* Soft shadow for lift */
}

.publication-list {
    list-style: none;
    padding: 0;
}

.publication-list li {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(48, 54, 61, 0.5);
    /* Subtle separator */
}

.publication-list li:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Mobile Navigation */
.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px;
    transition: all 0.3s ease;
}

@media screen and (max-width: 960px) {
    body {
        overflow-x: hidden;
    }

    .nav-links {
        position: fixed;
        right: 0px;
        height: 100vh;
        top: 0;
        background-color: var(--surface-color);
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 60%;
        transform: translateX(100%);
        transition: transform 0.5s ease-in;
        z-index: 998;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.5);
    }

    .nav-links li {
        opacity: 0;
        margin: 1.5rem 0;
    }

    .burger {
        display: block;
        position: relative;
        z-index: 1001;
    }

    .logo span {
        display: none;
    }

    /* Reduce content padding on mobile to make boxes wider */
    .section,
    section,
    .card,
    .profile-header,
    .timeline {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    .card {
        padding: 1.5rem 1rem !important;
    }

    .timeline {
        padding-left: 2rem !important;
    }

    .timeline-item::before {
        left: -2.6rem;
    }

    section {
        padding-top: 40px;
        padding-bottom: 40px;
    }

    /* Improved Mobile Menu Style */
    .nav-links {
        background-color: rgba(22, 27, 34, 0.98);
        width: 75%;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
    }

    .nav-links li a {
        font-size: 1.2rem;
        display: block;
        width: 100%;
        text-align: center;
        padding: 10px;
    }
}

.nav-active {
    transform: translateX(0%);
}

@keyframes navLinkFade {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0px);
    }
}

.toggle .line1 {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.toggle .line2 {
    opacity: 0;
}

.toggle .line3 {
    transform: rotate(45deg) translate(-5px, -6px);
}