/* CSS Variables for easy customization */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary-color: #0f172a;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-light: #94a3b8;
    --background: #ffffff;
    --background-alt: #f8fafc;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --transition: all 0.3s ease;
}

/* Reset and base styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.125rem; }

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* Container */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.25rem;
}

.nav-menu a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
}

.nav-menu a:hover {
    color: var(--primary-color);
}

/* Hamburger menu button */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    margin: 5px 0;
    transition: var(--transition);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6rem 1.5rem 4rem;
    background: linear-gradient(135deg, var(--background) 0%, var(--background-alt) 100%);
}

.hero-content {
    max-width: 700px;
}

.hero-image {
    margin-bottom: 2rem;
}

.profile-placeholder {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 3rem;
    font-weight: 700;
    color: white;
    box-shadow: var(--shadow-lg);
}

.profile-image {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto;
    box-shadow: var(--shadow-lg);
    border: 4px solid white;
}

.hero h1 {
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
}

.hero-title {
    font-size: 1.25rem;
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 1rem;
}

.hero-tagline {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* Sections */
.section {
    padding: 5rem 0;
}

.section-alt {
    background: var(--background-alt);
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--secondary-color);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 2px;
}

/* About Section */
.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about-content p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.credentials {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.credential {
    background: var(--background-alt);
    border: 1px solid var(--border-color);
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

/* Experience Timeline */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}

.timeline-item {
    position: relative;
    padding-left: 2.5rem;
    padding-bottom: 3rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -6px;
    top: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--primary-color);
    border: 3px solid var(--background-alt);
}

.timeline-content {
    background: var(--background);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.timeline-header h3 {
    color: var(--secondary-color);
}

.timeline-date {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

.company {
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 1rem;
}

.experience-list {
    list-style: none;
}

.experience-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.experience-list li::before {
    content: '\2022';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Compact timeline items for earlier career */
.timeline-item-compact .timeline-content {
    padding: 1rem 1.5rem;
}

.timeline-item-compact .company {
    margin-bottom: 0;
}

/* Invited Talks Section */
.talks-list {
    max-width: 800px;
    margin: 0 auto;
}

.talk-item {
    background: var(--background);
    padding: 1.25rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.talk-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.talk-title {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.talk-venue {
    font-size: 0.9rem;
    color: var(--primary-color);
    font-style: italic;
}

/* PhD Supervision Section */
.phd-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.phd-column h3 {
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
}

.phd-item {
    background: var(--background);
    padding: 1.25rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.phd-item:hover {
    box-shadow: var(--shadow);
}

.phd-name {
    font-weight: 600;
    color: var(--secondary-color);
}

.phd-year {
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 600;
}

.phd-role {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* Grants & Funding Section */
.grants-total {
    text-align: center;
    margin-bottom: 3rem;
}

.grants-total .stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.grants-total .stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.grants-list {
    max-width: 800px;
    margin: 0 auto;
}

.grant-item {
    background: var(--background);
    padding: 1.25rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    transition: var(--transition);
}

.grant-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.grant-details {
    flex: 1;
}

.grant-title {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.grant-funder {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.grant-amount {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.1rem;
    white-space: nowrap;
}

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

.skill-category {
    background: var(--background);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.skill-category h3 {
    color: var(--secondary-color);
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: var(--background-alt);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.skill-tag:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Publications Section */
.publications-header {
    text-align: center;
    margin-bottom: 3rem;
}

.publication-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.scholar-btn {
    display: inline-flex;
    align-items: center;
}

.publications-subtitle {
    text-align: center;
    color: var(--secondary-color);
    margin-bottom: 2rem;
    font-size: 1.25rem;
}

.publications-list {
    max-width: 900px;
    margin: 0 auto;
}

/* Book feature card */
.book-feature {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 2rem;
    transition: var(--transition);
}

.book-feature:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.book-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    opacity: 0.8;
    margin-bottom: 0.5rem;
}

.book-feature h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.book-feature p {
    opacity: 0.9;
    font-size: 0.95rem;
}

.publication-item {
    background: var(--background);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.publication-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

a.publication-link {
    display: block;
    text-decoration: none;
    cursor: pointer;
}

a.publication-link:hover .publication-title {
    color: var(--primary-color);
}

.publication-authors {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.publication-title {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.publication-journal {
    font-size: 0.9rem;
    color: var(--primary-color);
    font-style: italic;
}

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

.education-card {
    background: var(--background);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: var(--transition);
}

.education-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.education-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
}

.education-card h3 {
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.education-card h4 {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.education-school {
    color: var(--text-secondary);
    font-weight: 500;
}

.education-date {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.education-details {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Media Section */
.media-intro {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 2.5rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.media-outlets {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.media-badge {
    background: var(--background-alt);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.media-highlights {
    max-width: 800px;
    margin: 0 auto;
}

.media-item {
    background: var(--background);
    padding: 1.25rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.media-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.media-item-title {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.media-item-detail {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Contact Section */
.contact-content {
    max-width: 800px;
    margin: 0 auto;
}

.contact-intro {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 3rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: var(--background-alt);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    flex-shrink: 0;
}

.contact-item h4 {
    color: var(--secondary-color);
    margin-bottom: 0.25rem;
}

.contact-item a,
.contact-item p {
    color: var(--text-secondary);
}

.contact-item a:hover {
    color: var(--primary-color);
}

.social-links h4 {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.social-icons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.social-link {
    width: 48px;
    height: 48px;
    background: var(--background-alt);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition);
}

.social-link:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

/* Footer */
.footer {
    background: var(--secondary-color);
    color: var(--text-light);
    padding: 2rem 0;
    text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 { font-size: 2.25rem; }
    h2 { font-size: 1.75rem; }

    .nav-toggle {
        display: block;
    }

    .nav-menu {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
        z-index: 999;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu a {
        font-size: 1.25rem;
    }

    .hero {
        padding-top: 5rem;
    }

    .profile-placeholder {
        width: 120px;
        height: 120px;
        font-size: 2.5rem;
    }

    .section {
        padding: 3rem 0;
    }

    .timeline::before {
        left: 6px;
    }

    .timeline-marker {
        left: 0;
    }

    .timeline-item {
        padding-left: 2rem;
    }

    .timeline-header {
        flex-direction: column;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

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

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

    .grant-item {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

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