/* CSS Variables for easy theme customization */
:root {
    --primary-color: #1e3a8a; /* Professional navy blue */
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --accent-color: #60a5fa;
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-color: #ffffff;
    --bg-light: #f9fafb;
    --bg-section: #f3f4f6;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.12);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-light);
}

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

/* Header and Navigation */
header {
    background-color: var(--bg-color);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

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

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

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

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* Main Content */
main {
    min-height: calc(100vh - 200px);
}

.section {
    display: none;
    padding: 3rem 0;
    animation: fadeIn 0.5s ease-in;
}

.section.active {
    display: block;
}

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

.section h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 2rem;
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 0.5rem;
    display: inline-block;
}

.section h3 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.section h4 {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
}

.section p {
    margin-bottom: 1rem;
    color: var(--text-light);
    font-size: 1.05rem;
    line-height: 1.8;
}

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

.section a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* About Section */
.about-content {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

.profile-header {
    text-align: center;
    margin-bottom: 2rem;
}

.profile-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary-color);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.profile-photo:hover {
    box-shadow: var(--shadow-hover);
    transform: scale(1.05);
}

.bio p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.locations {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--bg-light);
}

.locations h3 {
    margin-top: 1.5rem;
}

/* Research Section */
.research-content {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

.research-list {
    list-style: none;
    padding-left: 0;
}

.research-list li {
    padding: 0.8rem 0;
    padding-left: 2rem;
    position: relative;
    font-size: 1.05rem;
    color: var(--text-light);
}

.research-list li:before {
    content: "▸";
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: 0;
}

.research-projects {
    list-style: none;
    padding-left: 0;
}

.research-projects li {
    padding: 1rem 0;
    padding-left: 1.5rem;
    position: relative;
    font-size: 1rem;
    color: var(--text-light);
    border-bottom: 1px solid var(--bg-light);
    line-height: 1.7;
}

.research-projects li:before {
    content: "→";
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* Publications */
#publications-container {
    margin-top: 2rem;
}

.publications-controls {
    margin-bottom: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: center;
}

.publications-controls button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
}

.publications-controls button:hover {
    background-color: var(--primary-light);
    box-shadow: var(--shadow-hover);
}

.pub-year {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid var(--primary-light);
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pub-year:hover {
    color: var(--primary-light);
}

.pub-year::before {
    content: '▼';
    font-size: 0.8em;
    transition: transform 0.3s ease;
}

.pub-year.collapsed::before {
    transform: rotate(-90deg);
}

.pub-year-group {
    margin-bottom: 1.2rem;
}

.pub-year-group.collapsed {
    display: none;
}

.publication-entry {
    background: var(--bg-light);
    padding: 1rem;
    margin-bottom: 0.8rem;
    border-radius: var(--border-radius);
    border-left: 3px solid var(--primary-color);
    transition: var(--transition);
}

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

.pub-title {
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--text-color);
    margin-bottom: 0.3rem;
    line-height: 1.4;
}

.pub-authors {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
    line-height: 1.3;
}

.pub-venue {
    color: var(--text-light);
    font-size: 0.9rem;
    font-style: italic;
    margin-bottom: 0.3rem;
    line-height: 1.3;
}

.pub-links {
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.pub-links a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    margin-right: 0.5rem;
}

.pub-links a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Teaching Section */
.teaching-content {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

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

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

.course-item strong {
    color: var(--primary-color);
    font-size: 1.1rem;
    display: block;
    margin-bottom: 0.5rem;
}

.course-item p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* Service Section */
.service-content {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

.service-list {
    list-style: none;
    padding-left: 0;
}

.service-list li {
    padding: 0.8rem 0;
    padding-left: 2rem;
    position: relative;
    font-size: 1.05rem;
    color: var(--text-light);
    border-bottom: 1px solid var(--bg-light);
}

.service-list li:before {
    content: "▸";
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* People Section */
.people-content {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 2rem;
}

.people-list,
.collaborators-list {
    list-style: none;
    padding-left: 0;
}

.people-list li,
.collaborators-list li {
    padding: 0.8rem 0;
    padding-left: 2rem;
    position: relative;
    font-size: 1.05rem;
    color: var(--text-light);
    border-bottom: 1px solid var(--bg-light);
}

.people-list li:before {
    content: "•";
    color: var(--primary-color);
    font-weight: bold;
    font-size: 1.5rem;
    position: absolute;
    left: 0;
}

.collaborators-list li:before {
    content: "→";
    color: var(--primary-color);
    font-weight: bold;
    position: absolute;
    left: 0;
}

.prospective-students {
    background: var(--bg-light);
    padding: 1.5rem;
    margin-top: 2rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-light);
}

.prospective-students p {
    margin-bottom: 0;
    font-size: 1rem;
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.contact-info,
.links {
    background: var(--bg-color);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.contact-info h3,
.links h3 {
    margin-top: 1.5rem;
    color: var(--primary-color);
}

.contact-info h3:first-child,
.links h3:first-child {
    margin-top: 0;
}

.contact-info p {
    margin-bottom: 1rem;
}

.link-list {
    list-style: none;
    padding-left: 0;
}

.link-list li {
    margin-bottom: 0.8rem;
}

.link-list a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    display: inline-block;
}

.link-list a:hover {
    color: var(--primary-dark);
    transform: translateX(5px);
}

/* Footer */
footer {
    background-color: var(--text-color);
    color: var(--bg-color);
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

footer p {
    color: var(--bg-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .navbar .container {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .section h2 {
        font-size: 2rem;
    }

    .about-content,
    .research-content,
    .teaching-content,
    .people-content {
        padding: 1.5rem;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }

    .publication-entry {
        padding: 1rem;
    }

    .profile-photo {
        width: 150px;
        height: 150px;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 1.2rem;
    }

    .nav-menu {
        gap: 0.5rem;
        font-size: 0.9rem;
    }

    .section {
        padding: 2rem 0;
    }

    .section h2 {
        font-size: 1.5rem;
    }

    .section h3 {
        font-size: 1.3rem;
    }

    .publication-entry {
        transform: none;
    }

    .publication-entry:hover {
        transform: none;
    }

    .course-item:hover {
        transform: none;
    }

    .profile-photo {
        width: 120px;
        height: 120px;
    }
}
