/* Portfolio styles: warm, personal, editorial */
:root {
    /* Warm light theme */
    --bg: #fafaf9;
    --bg-hero: #f5f5f4;
    --text: #292524;
    --text-muted: #57534e;
    --accent: #b45309;
    --accent-hover: #92400e;
    --border: #e7e5e4;
    --card-bg: #ffffff;
    --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    --card-border: 1px solid var(--border);

    /* Dark theme – warm neutrals */
    --dark-bg: #1c1917;
    --dark-bg-hero: #292524;
    --dark-text: #fafaf9;
    --dark-text-muted: #a8a29e;
    --dark-accent: #d97706;
    --dark-accent-hover: #f59e0b;
    --dark-border: #44403c;
    --dark-card-bg: #292524;
    --dark-card-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    --dark-nav-bg: rgba(28, 25, 23, 0.96);
}

/* Aliases used by components */
:root {
    --primary-color: var(--accent);
    --light-color: var(--card-bg);
    --dark-color: var(--text);
    --text-color: var(--text);
}

/* Theme Toggle Styles */
.theme-toggle {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1001;
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 0.4rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    color: var(--accent);
    box-shadow: var(--card-shadow);
    transition: color 0.2s ease, border-color 0.2s ease;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    color: var(--accent-hover);
    border-color: var(--accent);
}

.theme-icon {
    transition: all 0.3s ease;
    width: 20px;
    height: 20px;
}

/* Dark theme – warm neutrals */
[data-theme="dark"] {
    --bg: var(--dark-bg);
    --bg-hero: var(--dark-bg-hero);
    --text: var(--dark-text);
    --text-muted: var(--dark-text-muted);
    --accent: var(--dark-accent);
    --accent-hover: var(--dark-accent-hover);
    --border: var(--dark-border);
    --card-bg: var(--dark-card-bg);
    --card-shadow: var(--dark-card-shadow);
    --primary-color: var(--dark-accent);
    --light-color: var(--dark-card-bg);
    --dark-color: var(--dark-text);
    --text-color: var(--dark-text);
}

[data-theme="dark"] body {
    background-color: var(--dark-bg);
    color: var(--dark-text);
}

[data-theme="dark"] .theme-toggle {
    background: var(--dark-card-bg);
    color: var(--dark-accent);
    border-color: var(--dark-border);
}

[data-theme="dark"] nav {
    background: var(--dark-nav-bg);
    border-bottom: 1px solid var(--dark-border);
}

[data-theme="dark"] .mobile-menu {
    background: var(--dark-nav-bg);
    border-top: 1px solid var(--dark-border);
}

[data-theme="dark"] .stat-item,
[data-theme="dark"] .project-card,
[data-theme="dark"] .experience-item,
[data-theme="dark"] .publication-card,
[data-theme="dark"] .contact-item,
[data-theme="dark"] .contact-info {
    background: var(--dark-card-bg);
    border-color: var(--dark-border);
}

[data-theme="dark"] .project-content,
[data-theme="dark"] .publication-title,
[data-theme="dark"] .company-name,
[data-theme="dark"] .contact-details h4,
[data-theme="dark"] .contact-info h3 {
    color: var(--dark-text);
}

[data-theme="dark"] .form-group input,
[data-theme="dark"] .form-group textarea {
    background: var(--dark-bg);
    border-color: var(--dark-border);
    color: var(--dark-text);
}

[data-theme="dark"] .form-group input:focus,
[data-theme="dark"] .form-group textarea:focus {
    border-color: var(--dark-accent);
}

[data-theme="dark"] .contact {
    background: var(--dark-bg);
}

[data-theme="dark"] .hero h1,
[data-theme="dark"] .hero .subtitle,
[data-theme="dark"] .hero .description {
    color: var(--dark-text);
}

[data-theme="dark"] footer {
    background: var(--dark-bg-hero);
    color: var(--dark-text);
}

[data-theme="dark"] .footer-about p,
[data-theme="dark"] .footer-links a,
[data-theme="dark"] .footer-contact p,
[data-theme="dark"] .footer-bottom p {
    color: var(--dark-text-muted);
}

[data-theme="dark"] .footer-links a:hover,
[data-theme="dark"] .footer-contact a:hover {
    color: var(--dark-accent);
}

[data-theme="dark"] .social-link {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--dark-border);
}

[data-theme="dark"] .social-link:hover {
    background: var(--dark-accent);
}

[data-theme="dark"] .contact .section-title,
[data-theme="dark"] .section-title {
    color: var(--dark-text);
    background: transparent;
    padding: 0;
    text-shadow: none;
}

[data-theme="dark"] .section-title::after {
    background: var(--dark-accent);
}

[data-theme="dark"] .contact-item:hover {
    background: var(--dark-border);
}

[data-theme="dark"] .contact-icon {
    background: var(--dark-accent);
}

[data-theme="dark"] .contact-details a:hover {
    color: var(--dark-accent);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    width: 2.5rem;
    height: 2px;
    background: var(--accent);
    border-radius: 0;
}
/* Mobile responsiveness for theme toggle */
        @media (max-width: 768px) {
            .theme-toggle {
                top: 0.75rem;
                right: 4rem; /* Move away from hamburger menu */
                width: 40px;
                height: 40px;
                font-size: 0.9rem;
            }
            
            .theme-icon {
                width: 18px;
                height: 18px;
            }
            
            .mobile-menu-btn {
                font-size: 1.4rem;
                padding: 0.4rem;
            }
        }

        @media (max-width: 480px) {
            .theme-toggle {
                top: 0.5rem;
                right: 3.5rem; /* Further adjust for smaller screens */
                width: 36px;
                height: 36px;
                font-size: 0.85rem;
            }
            
            .theme-icon {
                width: 16px;
                height: 16px;
            }
            
            .mobile-menu-btn {
                font-size: 1.3rem;
                padding: 0.3rem;
                margin-right: 0.25rem;
            }
            
            .theme-toggle:active {
    transform: scale(0.95);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}
        }

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.65;
    color: var(--text);
    scroll-behavior: smooth;
    background-color: var(--bg);
}

        /* Navigation */
        nav {
            position: fixed;
            top: 0;
            width: 100%;
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
            z-index: 1000;
            transition: all 0.3s ease;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
            height: 80px; /* Fixed height for consistent spacing */
            box-sizing: border-box;
        }

[data-theme="dark"] nav {
    background: var(--dark-nav-bg);
    border-bottom: 1px solid var(--dark-border);
}

/* Add scroll effect to nav if needed */
nav.scrolled {
    background: rgba(255, 255, 255, 0.98); /* Light theme scrolled state */
}

[data-theme="dark"] nav.scrolled,
[data-theme="dark"] #navbar.scrolled { /* Increased specificity with potential ID */
    background: var(--dark-nav-bg) !important; /* Force dark background */
    border-bottom: 1px solid var(--dark-border) !important; /* Maintain border */
}

[data-theme="dark"] nav.scrolled .nav-links a,
[data-theme="dark"] #navbar.scrolled .nav-links a {
    color: var(--dark-text) !important;
}

[data-theme="dark"] nav.scrolled .nav-links a:hover,
[data-theme="dark"] #navbar.scrolled .nav-links a:hover {
    color: var(--dark-accent) !important;
}

[data-theme="dark"] nav.scrolled .nav-links a::after,
[data-theme="dark"] #navbar.scrolled .nav-links a::after {
    background: var(--dark-accent) !important;
}

[data-theme="dark"] nav.scrolled .mobile-menu-btn,
[data-theme="dark"] #navbar.scrolled .mobile-menu-btn {
    color: var(--dark-text) !important;
}

[data-theme="dark"] nav.scrolled .logo,
[data-theme="dark"] #navbar.scrolled .logo {
    color: var(--dark-text) !important;
    -webkit-text-fill-color: var(--dark-text) !important;
}
        .nav-container {
            max-width: 1200px;
            margin: 0 auto;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 1rem 2rem;
        }

        .logo {
            font-size: 1.4375rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            color: var(--text);
            letter-spacing: -0.02em;
        }

        .nav-links {
            display: flex;
            list-style: none;
            gap: 2rem;
        }

        .nav-links a {
            text-decoration: none;
            color: var(--text);
            font-weight: 500;
            font-size: 0.9375rem;
            transition: color 0.2s ease;
            position: relative;
        }

        .nav-links a:hover {
            color: var(--accent);
        }

        .nav-links a::after {
            content: '';
            position: absolute;
            width: 0;
            height: 1px;
            bottom: -4px;
            left: 0;
            background: var(--accent);
            transition: width 0.2s ease;
        }

        .nav-links a:hover::after {
            width: 100%;
        }

        /* Mobile Menu */
        .mobile-menu-btn {
            display: none;
            background: none;
            border: none;
            font-size: 1.5rem;
            cursor: pointer;
            color: var(--text);
            padding: 0.5rem;
            margin-right: 0.5rem;
        }

        .mobile-menu {
            display: none;
            position: absolute;
            top: 100%;
            left: 0;
            width: 100%;
            background: var(--card-bg);
            backdrop-filter: blur(10px);
            border-top: 1px solid var(--border);
        }

        .mobile-menu .nav-links {
            flex-direction: column;
            padding: 1rem 2rem;
            gap: 1rem;
        }

        /* Hero Section – warm, minimal */
        .hero {
            min-height: calc(100vh - 80px);
            height: calc(100vh - 80px);
            background: var(--bg-hero);
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
            overflow: hidden;
            box-sizing: border-box;
            margin-top: 80px;
        }

        .hero-container {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 4rem;
            max-width: 1200px;
            width: 100%;
            z-index: 1;
            animation: fadeInUp 1s ease;
            box-sizing: border-box;
            padding: 2rem;
        }

        .hero-photo {
            flex-shrink: 0;
            display: block !important;
        }

        .profile-photo {
            width: 300px;
            height: 300px;
            border-radius: 50%;
            object-fit: cover;
            border: 3px solid var(--border);
            box-shadow: var(--card-shadow);
            transition: border-color 0.2s ease;
            display: block !important;
            visibility: visible !important;
        }

        .profile-photo:hover {
            border-color: var(--accent);
        }

        .hero-content {
            text-align: left;
            color: var(--text);
            z-index: 1;
            max-width: 600px;
            padding: 0 2rem;
        }

        .hero h1 {
            font-size: 2.75rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            margin-bottom: 0.5rem;
            letter-spacing: -0.02em;
            color: var(--text);
        }

        .hero .subtitle {
            font-size: 1.125rem;
            font-weight: 500;
            margin-bottom: 1rem;
            color: var(--text-muted);
        }

        .hero .description,
        .hero p {
            font-size: 1rem;
            line-height: 1.7;
            margin-bottom: 1.5rem;
            color: var(--text);
        }

        .cta-buttons {
            display: flex !important;
            gap: 0.75rem;
            justify-content: flex-start;
            flex-wrap: wrap;
            align-items: center;
            width: 100%;
            visibility: visible !important;
        }

        .btn {
            padding: 0.625rem 1.25rem;
            border-radius: 6px;
            font-weight: 500;
            font-size: 0.9375rem;
            text-decoration: none;
            display: inline-flex !important;
            align-items: center;
            gap: 0.5rem;
            transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
            cursor: pointer;
            visibility: visible !important;
            white-space: nowrap;
            flex-shrink: 0;
            box-sizing: border-box;
            min-height: 44px;
        }

        .btn-primary {
            background: var(--accent);
            color: #fff;
            border: 1px solid var(--accent);
        }

        .btn-primary:hover {
            background: var(--accent-hover);
            border-color: var(--accent-hover);
        }

        .btn-secondary {
            background: transparent;
            color: var(--accent);
            border: 1px solid var(--accent);
        }

        .btn-secondary:hover {
            background: var(--accent);
            color: #fff;
        }

        .btn-outline {
            background: transparent;
            color: var(--text);
            border: 1px solid var(--border);
        }

        .btn-outline:hover {
            border-color: var(--accent);
            color: var(--accent);
        }

        .btn:hover {
            box-shadow: var(--card-shadow);
        }

        /* Hero Education */
        .hero-education {
            display: flex;
            flex-direction: column;
            gap: 1rem;
            margin: 1.5rem 0;
            align-items: flex-start;
        }

        .education-badge {
            text-align: left;
            transition: none;
            max-width: 500px;
        }

        .education-badge .degree {
            display: block;
            font-weight: 600;
            font-size: 1rem;
            margin-bottom: 0.2rem;
            color: var(--text);
        }

        .education-badge .university {
            display: block;
            font-size: 0.9375rem;
            color: var(--text-muted);
            margin-bottom: 0.25rem;
        }

        .education-badge .gpa {
            display: inline-block;
            padding: 0.25rem 0.5rem;
            border-radius: 4px;
            font-size: 0.875rem;
            font-weight: 600;
            color: var(--text);
            background: var(--border);
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* Sections */
        section {
            padding: 4rem 2rem;
        }

        .container {
            max-width: 1200px;
            margin: 0 auto;
        }

        .section-header {
            text-align: left;
            margin-bottom: 2.5rem;
        }

        .section-title {
            font-size: 1.75rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            color: var(--text);
            margin-bottom: 1rem;
            position: relative;
            letter-spacing: -0.02em;
        }

        .section-title::after {
            content: '';
            position: absolute;
            bottom: -0.5rem;
            left: 0;
            width: 2.5rem;
            height: 2px;
            background: var(--accent);
            border-radius: 0;
        }


        /* About Section - Removed repetitive text */
        .about-content {
            display: grid;
            grid-template-columns: 1fr;
            gap: 3rem;
            align-items: center;
        }

        .stats {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 1.5rem;
            margin: 0 auto;
            max-width: 800px;
        }

        .stat-item {
            text-align: center;
            padding: 2rem 1.5rem;
            background: var(--card-bg);
            border: var(--card-border);
            border-radius: 8px;
            box-shadow: var(--card-shadow);
            transition: border-color 0.2s ease;
            position: relative;
        }

        .stat-item:hover {
            border-color: var(--accent);
        }

        .stat-item > :first-child {
            font-size: 2rem;
            margin-bottom: 0.5rem;
            display: block;
        }

        .stat-number {
            font-size: 2rem;
            font-weight: 700;
            font-family: 'Source Serif 4', Georgia, serif;
            color: var(--accent);
        }

        /* Projects Section */
        .projects-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
            gap: 2rem;
        }

        .project-card {
            background: var(--card-bg);
            border: var(--card-border);
            border-radius: 8px;
            overflow: hidden;
            box-shadow: var(--card-shadow);
            transition: border-color 0.2s ease, box-shadow 0.2s ease;
        }

        .project-card:hover {
            border-color: var(--accent);
            box-shadow: var(--card-shadow);
        }

        .project-header {
            background: var(--bg-hero);
            padding: 1.25rem 1.5rem;
            color: var(--text);
            border-bottom: 1px solid var(--border);
        }

        .project-header h3 {
            font-size: 1.15rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            margin-bottom: 0.35rem;
        }

        .project-date {
            font-size: 0.875rem;
            color: var(--text-muted);
        }

        .project-content {
            padding: 1.5rem;
        }

        .project-content ul {
            list-style: none;
            padding: 0;
        }

        .project-content li {
            margin-bottom: 0.75rem;
            padding-left: 1.25rem;
            position: relative;
        }

        .project-content li::before {
            content: '▸';
            position: absolute;
            left: 0;
            color: var(--accent);
            font-weight: bold;
        }

        /* Project Buttons */
        .project-buttons {
            display: flex;
            gap: 0.75rem;
            margin-top: 1.25rem;
            flex-wrap: wrap;
        }

        .project-btn {
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
            padding: 0.5rem 1rem;
            border-radius: 6px;
            text-decoration: none;
            font-weight: 500;
            font-size: 0.875rem;
            transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
            border: 1px solid var(--border);
            cursor: pointer;
        }

        .project-btn:hover {
            border-color: var(--accent);
            color: var(--accent);
        }

        .codebase-btn,
        .video-btn {
            background: var(--accent);
            color: #fff;
            border-color: var(--accent);
        }

        .codebase-btn:hover,
        .video-btn:hover {
            background: var(--accent-hover);
            border-color: var(--accent-hover);
            color: #fff;
        }

        /* Experience Section */
        .experience-timeline {
            position: relative;
            padding-left: 2rem;
        }

        .experience-timeline::before {
            content: '';
            position: absolute;
            left: 0.375rem;
            top: 0;
            bottom: 0;
            width: 2px;
            background: var(--accent);
        }

        .experience-item {
            position: relative;
            background: var(--card-bg);
            border: var(--card-border);
            margin-bottom: 2rem;
            padding: 2rem;
            border-radius: 8px;
            box-shadow: var(--card-shadow);
            margin-left: 2rem;
            transition: border-color 0.2s ease;
        }

        .experience-item:hover {
            border-color: var(--accent);
        }

        .experience-item::before {
            content: '';
            position: absolute;
            left: -2.125rem;
            top: 2rem;
            width: 10px;
            height: 10px;
            background: var(--accent);
            border-radius: 50%;
            border: 2px solid var(--card-bg);
            box-shadow: 0 0 0 2px var(--accent);
        }

        .experience-header {
            margin-bottom: 1rem;
        }

        .company-name {
            font-size: 1.1rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            color: var(--text);
        }

        .position {
            color: var(--accent);
            font-weight: 600;
            margin: 0.25rem 0;
        }

        .duration {
            color: var(--text-muted);
            font-size: 0.875rem;
        }

        /* Publications Section */
        .publications-grid {
            display: grid;
            gap: 1.5rem;
        }

        .publication-card {
            background: var(--card-bg);
            border: var(--card-border);
            padding: 1.5rem 2rem;
            border-radius: 8px;
            box-shadow: var(--card-shadow);
            transition: border-color 0.2s ease;
            cursor: pointer;
        }

        .publication-card:hover {
            border-color: var(--accent);
        }

        .publication-title {
            font-size: 1.05rem;
            font-weight: 600;
            font-family: 'Source Serif 4', Georgia, serif;
            color: var(--text);
            margin-bottom: 0.5rem;
            line-height: 1.4;
        }

        .publication-authors {
            color: var(--text-muted);
            margin-bottom: 0.5rem;
            font-size: 0.9375rem;
            font-style: italic;
        }

        .publication-venue {
            color: var(--accent);
            font-weight: 500;
            font-size: 0.875rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        /* Contact Section */
        .contact {
            background: var(--bg);
            padding: 4rem 0;
            margin-bottom: 0;
        }

        .contact-content {
            display: grid;
            grid-template-columns: 1fr;
            gap: 2rem;
            max-width: 800px;
            margin: 0 auto;
            padding: 0 2rem;
        }

        .contact-items {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 1.5rem;
            align-items: start;
        }

        .contact-info h3 {
            color: var(--text);
            margin-bottom: 2rem;
            font-size: 1.25rem;
            font-family: 'Source Serif 4', Georgia, serif;
        }

        .contact-item {
            display: flex;
            align-items: center;
            gap: 1rem;
            margin-bottom: 1.5rem;
            padding: 1rem;
            background: var(--card-bg);
            border: var(--card-border);
            border-radius: 8px;
            box-shadow: var(--card-shadow);
            transition: border-color 0.2s ease;
            width: 100%;
            box-sizing: border-box;
        }

        .contact-item:hover {
            border-color: var(--accent);
        }

        .contact-icon {
            width: 48px;
            height: 48px;
            background: var(--accent);
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #fff;
            font-size: 1.25rem;
            flex-shrink: 0;
        }

        .contact-icon svg {
            width: 22px;
            height: 22px;
            color: #fff;
            fill: currentColor;
        }

        .contact-details {
            flex: 1;
            min-width: 0;
        }

        .contact-details h4 {
            margin: 0 0 0.35rem 0;
            color: var(--text);
            font-size: 1rem;
            font-weight: 600;
        }

        .contact-details p,
        .contact-details a {
            margin: 0;
            color: var(--text-muted);
            text-decoration: none;
            word-break: break-all;
            font-size: 0.9375rem;
        }

        .contact-details a:hover {
            color: var(--accent);
        }

        /* Footer */
        footer {
            background: var(--bg-hero);
            color: var(--text);
            padding: 3rem 2rem 2rem;
            text-align: center;
            border-top: 1px solid var(--border);
        }

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
    text-align: left;
}

.footer-about h3 {
    color: var(--text);
    font-family: 'Source Serif 4', Georgia, serif;
    margin-bottom: 1rem;
    font-size: 1.15rem;
}

.footer-about p {
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-size: 0.9375rem;
}

.footer-links h4,
.footer-contact h4 {
    color: var(--text);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a,
.footer-contact a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a,
.footer-contact a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
    font-size: 0.9375rem;
}

.footer-links a:hover,
.footer-contact a:hover {
    color: var(--accent);
}

.footer-contact p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    font-size: 0.9375rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin: 2rem 0;
}

.social-link {
    width: 44px;
    height: 44px;
    background: var(--card-bg);
    border: var(--card-border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.social-link:hover {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

        .social-link svg {
            width: 24px;
            height: 24px;
            fill: currentColor;
        }

        .footer-bottom {
            border-top: 1px solid var(--border);
            padding-top: 2rem;
            text-align: center;
        }

        .footer-bottom p {
            color: var(--text-muted);
            margin: 0.5rem 0;
            font-size: 0.875rem;
        }

        .footer-bottom .highlight {
            color: var(--accent);
            font-weight: 600;
        }

        /* Responsive Design */
        @media (max-width: 1024px) {
            .hero-container {
                gap: 3rem;
                max-width: 1000px;
            }
            
            .profile-photo {
                width: 250px;
                height: 250px;
            }
            
            .hero h1 {
                font-size: 3rem;
            }
            
            .section-title {
                font-size: 2.2rem;
            }
            
            .projects-grid {
                grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            }
        }

        @media (max-width: 768px) {
            .theme-toggle {
                top: 0.5rem;
                right: 4rem; /* Move away from hamburger button */
                width: 45px;
                height: 45px;
                font-size: 1rem;
            }
            
            .mobile-menu-btn {
                display: block;
            }
            
            .nav-links {
                display: none;
            }
            
            .mobile-menu.active {
                display: block;
            }
            
            .mobile-menu.active .nav-links {
                display: flex;
            }
            
            .hero-container {
                flex-direction: column;
                gap: 2rem;
                text-align: center;
            }
            
            .profile-photo {
                display: none;
            }
            
            .hero-content {
                text-align: center;
                max-width: 100%;
            }
            
            .cta-buttons {
                justify-content: center;
                flex-wrap: nowrap;
                align-items: center;
            }
            
            .hero {
                min-height: calc(100vh - 80px);
                height: calc(100vh - 80px);
                margin-top: 80px;
            }
            
            .hero h1 {
                font-size: 2.5rem;
            }
            
            .hero .subtitle {
                font-size: 1.1rem;
            }
            
            .hero .description {
                font-size: 0.95rem;
            }
            
            .hero-education {
                margin: 1.5rem 0;
            }
            
            .education-badge {
                max-width: 350px;
            }
            
            .education-badge .degree {
                font-size: 1rem;
            }
            
            .education-badge .university {
                font-size: 0.85rem;
            }
            
            .section-title {
                font-size: 2rem;
            }
            
            section {
                padding: 3rem 1rem;
            }
            
            .nav-container {
                padding: 1rem;
            }
            
            .logo {
                font-size: 1.35rem;
            }
            
            .about-content {
                gap: 2rem;
            }
            
            .stats {
                grid-template-columns: repeat(2, 1fr);
                gap: 1rem;
            }
            
            .stat-item {
                padding: 1.5rem 1rem;
            }
            
            .projects-grid {
                grid-template-columns: 1fr;
                gap: 1.5rem;
            }
            
            .project-card {
                margin: 0 auto;
                max-width: 400px;
            }
            
            .experience-timeline {
                padding-left: 1rem;
            }
            
            .experience-timeline::before {
                left: 0.5rem;
            }
            
            .experience-item {
                margin-left: 1.5rem;
                padding: 1.5rem;
            }
            
            .experience-item::before {
                left: -2.25rem;
            }
            
            .contact-content {
                grid-template-columns: 1fr;
                gap: 2rem;
                padding: 0 1rem;
            }
            
            .contact-items {
                grid-template-columns: 1fr;
                gap: 1rem;
            }
            
            .contact-item {
                padding: 0.75rem;
            }
            
            .footer-top {
                grid-template-columns: 1fr;
                gap: 2rem;
                text-align: center;
            }
            
            .social-links {
                gap: 0.75rem;
            }
            
            .social-link {
                width: 45px;
                height: 45px;
            }
        }

        /* Comprehensive Mobile Responsiveness - All Devices */
        @media (max-width: 768px) {
            .theme-toggle {
                top: 0.5rem;
                right: 4rem;
                width: 40px;
                height: 40px;
                font-size: 0.9rem;
            }
            
            .theme-toggle .theme-icon {
                width: 18px;
                height: 18px;
            }
            
            .mobile-menu-btn {
                font-size: 1.4rem;
                padding: 0.4rem;
            }
            
            .hero {
                min-height: calc(100vh - 80px); /* Account for nav bar */
                padding: 2rem 0 1rem 0; /* Top padding for nav, bottom for content */
                margin-top: 80px; /* Push content below nav */
            }
            
            .hero-container {
                flex-direction: column;
                gap: 1.5rem;
                padding: 0 1rem;
                justify-content: flex-start; /* Start from top */
                min-height: calc(100vh - 80px);
                align-items: center;
            }
            
            .hero-photo {
                order: 1;
                display: block !important;
                margin-top: 1rem;
            }
            
            .profile-photo {
                width: 160px;
                height: 160px;
                margin-bottom: 0.5rem;
                object-fit: cover;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero-content {
                order: 2;
                text-align: center;
                padding: 0 0.5rem;
                width: 100%;
            }
            
            .hero h1 {
                font-size: 1.8rem;
                margin-bottom: 0.5rem;
            }
            
            .hero .subtitle {
                font-size: 1rem;
                margin-bottom: 0.5rem;
            }
            
            .hero .description {
                font-size: 0.85rem;
                line-height: 1.4;
                margin-bottom: 1rem;
            }
            
            .hero-education {
                margin: 0.75rem 0;
            }
            
            .education-badge {
                padding: 0.6rem 0.8rem;
                max-width: 280px;
                margin: 0.25rem auto;
            }
            
            .education-badge .degree {
                font-size: 0.85rem;
            }
            
            .education-badge .university {
                font-size: 0.75rem;
            }
            
            .cta-buttons {
                display: flex !important;
                flex-direction: column;
                gap: 0.75rem;
                align-items: center;
                width: 100%;
                margin-top: 1rem;
                visibility: visible !important;
            }
            
            .btn {
                width: 100%;
                max-width: 260px;
                padding: 0.7rem 1.25rem;
                font-size: 0.85rem;
                justify-content: center;
                display: flex !important;
                visibility: visible !important;
            }
        }

        @media (max-width: 480px) {
            .theme-toggle {
                top: 0.5rem;
                right: 3.5rem;
                width: 36px;
                height: 36px;
                font-size: 0.85rem;
            }
            
            .theme-toggle .theme-icon {
                width: 16px;
                height: 16px;
            }
            
            .mobile-menu-btn {
                font-size: 1.3rem;
                padding: 0.3rem;
                margin-right: 0.25rem;
            }
            
            .hero {
                min-height: calc(100vh - 80px);
                padding: 1.5rem 0 1rem 0;
                margin-top: 80px;
            }
            
            .hero-container {
                gap: 1.25rem;
                padding: 0 0.75rem;
                justify-content: flex-start;
                min-height: calc(100vh - 80px);
            }
            
            .profile-photo {
                width: 140px;
                height: 140px;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero h1 {
                font-size: 1.6rem;
            }
            
            .hero .subtitle {
                font-size: 0.9rem;
            }
            
            .hero .description {
                font-size: 0.8rem;
                margin-bottom: 0.75rem;
            }
            
            .cta-buttons {
                gap: 0.6rem;
                margin-top: 0.75rem;
                display: flex !important;
                flex-direction: column;
                align-items: center;
                width: 100%;
                visibility: visible !important;
            }
            
            .btn {
                max-width: 240px;
                padding: 0.6rem 1rem;
                font-size: 0.8rem;
                display: flex !important;
                justify-content: center;
                visibility: visible !important;
            }
        }

        @media (max-width: 430px) {
            .theme-toggle {
                top: 0.5rem;
                right: 3rem;
                width: 32px;
                height: 32px;
                font-size: 0.8rem;
            }
            
            .theme-toggle .theme-icon {
                width: 14px;
                height: 14px;
            }
            
            .mobile-menu-btn {
                font-size: 1.2rem;
                padding: 0.25rem;
                margin-right: 0.2rem;
            }
            
            .hero {
                min-height: calc(100vh - 80px);
                padding: 1rem 0;
                margin-top: 80px;
            }
            
            .hero-container {
                gap: 1rem;
                padding: 0 0.5rem;
                justify-content: flex-start;
                min-height: calc(100vh - 80px);
            }
            
            .profile-photo {
                width: 120px;
                height: 120px;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero h1 {
                font-size: 1.4rem;
                margin-bottom: 0.4rem;
            }
            
            .hero .subtitle {
                font-size: 0.85rem;
                margin-bottom: 0.4rem;
            }
            
            .hero .description {
                font-size: 0.75rem;
                line-height: 1.3;
                margin-bottom: 0.6rem;
            }
            
            .hero-education {
                margin: 0.5rem 0;
            }
            
            .education-badge {
                padding: 0.5rem 0.7rem;
                max-width: 260px;
            }
            
            .education-badge .degree {
                font-size: 0.8rem;
            }
            
            .education-badge .university {
                font-size: 0.7rem;
            }
            
            .cta-buttons {
                gap: 0.5rem;
                margin-top: 0.6rem;
                display: flex !important;
                flex-direction: column;
                align-items: center;
                width: 100%;
                visibility: visible !important;
            }
            
            .btn {
                max-width: 220px;
                padding: 0.5rem 0.9rem;
                font-size: 0.75rem;
                display: flex !important;
                justify-content: center;
                visibility: visible !important;
            }
        }

        /* Landscape Mode for Mobile Devices */
        @media (max-width: 768px) and (orientation: landscape) {
            .hero {
                min-height: calc(100vh - 80px);
                padding: 0.5rem 0;
                margin-top: 80px;
            }
            
            .hero-container {
                flex-direction: row;
                gap: 2rem;
                align-items: center;
                justify-content: center;
                min-height: calc(100vh - 80px);
            }
            
            .hero-photo {
                order: 1;
            }
            
            .profile-photo {
                width: 100px;
                height: 100px;
                margin-bottom: 0;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero-content {
                order: 2;
                text-align: left;
                padding: 0 1rem;
            }
            
            .hero h1 {
                font-size: 1.4rem;
                margin-bottom: 0.3rem;
            }
            
            .hero .subtitle {
                font-size: 0.9rem;
                margin-bottom: 0.3rem;
            }
            
            .hero .description {
                font-size: 0.75rem;
                margin-bottom: 0.5rem;
            }
            
            .hero-education {
                margin: 0.4rem 0;
            }
            
            .education-badge {
                padding: 0.4rem 0.6rem;
                max-width: 240px;
                margin: 0.2rem 0;
            }
            
            .education-badge .degree {
                font-size: 0.75rem;
            }
            
            .education-badge .university {
                font-size: 0.65rem;
            }
            
            .cta-buttons {
                flex-direction: row;
                gap: 0.5rem;
                margin-top: 0.5rem;
                justify-content: flex-start;
                display: flex;
            }
            
            .btn {
                width: auto;
                max-width: none;
                padding: 0.5rem 1rem;
                font-size: 0.75rem;
                display: flex;
            }
        }

        @media (max-width: 480px) and (orientation: landscape) {
            .hero {
                margin-top: 80px;
                min-height: calc(100vh - 80px);
            }
            
            .hero-container {
                gap: 1.5rem;
                min-height: calc(100vh - 80px);
            }
            
            .profile-photo {
                width: 80px;
                height: 80px;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero h1 {
                font-size: 1.2rem;
            }
            
            .hero .subtitle {
                font-size: 0.8rem;
            }
            
            .hero .description {
                font-size: 0.7rem;
            }
            
            .cta-buttons {
                gap: 0.4rem;
                display: flex !important;
                visibility: visible !important;
            }
            
            .btn {
                padding: 0.4rem 0.8rem;
                font-size: 0.7rem;
                display: flex !important;
                visibility: visible !important;
            }
        }

        /* Extra Small Devices */
        @media (max-width: 360px) {
            .theme-toggle {
                right: 2.5rem;
                width: 28px;
                height: 28px;
                font-size: 0.75rem;
            }
            
            .theme-toggle .theme-icon {
                width: 12px;
                height: 12px;
            }
            
            .mobile-menu-btn {
                font-size: 1.1rem;
                padding: 0.2rem;
            }
            
            .hero {
                margin-top: 80px;
                min-height: calc(100vh - 80px);
            }
            
            .hero-container {
                min-height: calc(100vh - 80px);
                justify-content: flex-start;
            }
            
            .profile-photo {
                width: 100px;
                height: 100px;
                display: block !important;
                visibility: visible !important;
            }
            
            .hero h1 {
                font-size: 1.2rem;
            }
            
            .hero .subtitle {
                font-size: 0.8rem;
            }
            
            .hero .description {
                font-size: 0.7rem;
            }
            
            .cta-buttons {
                display: flex !important;
                flex-direction: column;
                align-items: center;
                width: 100%;
                visibility: visible !important;
            }
            
            .btn {
                max-width: 200px;
                padding: 0.4rem 0.8rem;
                font-size: 0.7rem;
                display: flex !important;
                visibility: visible !important;
                justify-content: center;
            }
        }

        @media (max-width: 480px) {
            .section-title {
                font-size: 1.8rem;
            }
            
            .stats {
                grid-template-columns: 1fr;
                gap: 1rem;
            }
            
            .stat-item {
                padding: 1.5rem;
            }
            
            .project-header {
                padding: 1.2rem;
            }
            
            .project-content {
                padding: 1.2rem;
            }
            
            .project-buttons {
                gap: 0.75rem;
                margin-top: 1rem;
            }
            
            .project-btn {
                padding: 0.6rem 1rem;
                font-size: 0.85rem;
            }
            
            .experience-item {
                padding: 1.2rem;
            }
            
            .publication-card {
                padding: 1.5rem;
            }
            
            .contact-content {
                padding: 0 0.5rem;
            }
            
            .contact-item {
                flex-direction: column;
                text-align: center;
                gap: 0.5rem;
            }
            
            .contact-icon {
                margin-bottom: 0.5rem;
            }
            
            footer {
                padding: 2rem 1rem 1.5rem;
            }
            
            .social-link {
                width: 40px;
                height: 40px;
            }
            
            .social-link svg {
                width: 20px;
                height: 20px;
            }
        }

        /* Additional mobile optimizations */
        @media (max-width: 360px) {
            .hero h1 {
                font-size: 1.8rem;
            }
            
            .section-title {
                font-size: 1.6rem;
            }
            
            .project-btn {
                padding: 0.5rem 0.8rem;
                font-size: 0.8rem;
            }
        }

        /* iPhone 14 and smaller screens specific optimizations */
        @media (max-width: 430px) {
            .theme-toggle {
                top: 0.5rem;
                right: 3rem;
                width: 32px;
                height: 32px;
                font-size: 0.8rem;
            }
            
            .theme-icon {
                width: 14px;
                height: 14px;
            }
            
            .mobile-menu-btn {
                font-size: 1.2rem;
                padding: 0.25rem;
                margin-right: 0.2rem;
            }
            
            .hero {
                min-height: calc(100vh - 80px);
                padding: 1.5rem 0;
                margin-top: 80px;
            }
            
            .hero-container {
                gap: 1.5rem;
                padding: 0 0.75rem;
                justify-content: flex-start;
                min-height: calc(100vh - 80px);
            }
            
            .profile-photo {
                width: 160px;
                height: 160px;
                display: block;
            }
            
            .hero h1 {
                font-size: 1.8rem;
                margin-bottom: 0.5rem;
            }
            
            .hero .subtitle {
                font-size: 1rem;
                margin-bottom: 0.5rem;
            }
            
            .hero .description {
                font-size: 0.85rem;
                margin-bottom: 1rem;
            }
            
            .cta-buttons {
                gap: 0.75rem;
                margin-top: 1rem;
                display: flex;
                flex-direction: column;
                align-items: center;
                width: 100%;
            }
            
            .btn {
                max-width: 260px;
                padding: 0.7rem 1.25rem;
                font-size: 0.85rem;
                display: flex;
                justify-content: center;
            }
            
            .education-badge {
                padding: 0.6rem 0.8rem;
                max-width: 280px;
            }
        }

        /* Animation for fade-in elements */
        .fade-in {
            opacity: 0;
            transform: translateY(20px);
            transition: all 0.6s ease;
        }

        .fade-in.visible {
            opacity: 1;
            transform: translateY(0);
        }
