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

:root {
    --bg-color: #fafafa;
    --text-color: #1a1a1a;
    --text-secondary: #666;
    --border-color: #ddd;
    --card-bg: #fff;
    --hover-bg: #f8f8f8;
}

body.dark-mode {
    --bg-color: #1a1a1a;
    --text-color: #e5e5e5;
    --text-secondary: #a0a0a0;
    --border-color: #404040;
    --card-bg: #2a2a2a;
    --hover-bg: #333;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--bg-color);
    font-size: 15px;
    transition: background 0.3s, color 0.3s;
}

a {
    color: #2563eb;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

body.dark-mode a {
    color: #93c5fd;
}

.dark-mode-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: all 0.3s;
}

.dark-mode-toggle:hover {
    background: var(--hover-bg);
}

.dark-mode-toggle .sun-icon {
    display: block;
}

.dark-mode-toggle .moon-icon {
    display: none;
}

body.dark-mode .dark-mode-toggle .sun-icon {
    display: none;
}

body.dark-mode .dark-mode-toggle .moon-icon {
    display: block;
}

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

header {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    margin-bottom: 40px;
}

.header-info {
    flex: 1;
}

.profile-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

h1 {
    font-size: 2em;
    margin-bottom: 10px;
}

.title, .affiliation {
    font-size: 1.1em;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.email {
    font-size: 1em;
    color: var(--text-secondary);
    margin: 10px 0;
}

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

.links .btn {
    padding: 8px 16px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-color);
    font-size: 0.95em;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.links .btn svg {
    vertical-align: middle;
}


.links .btn:hover {
    background: var(--hover-bg);
    text-decoration: none;
}

section {
    margin-bottom: 40px;
}

h2 {
    font-size: 1.5em;
    margin-bottom: 20px;
    border-bottom: 2px solid #333;
    padding-bottom: 5px;
}

.bio p {
    font-size: 1.05em;
    margin-bottom: 15px;
}

.pub-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    justify-content: center;
}

.filter-btn {
    padding: 8px 18px;
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-color);
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    transition: all 0.2s;
}

.filter-btn:hover {
    background: var(--hover-bg);
    border-color: #2563eb;
}

.filter-btn.active {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.paper.hidden {
    display: none;
}

.news-list {
    margin-bottom: 20px;
}

.news-item {
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
}

.news-date {
    color: var(--text-secondary);
    min-width: 85px;
    flex-shrink: 0;
    font-weight: 500;
}

.news-date::before { content: '['; }
.news-date::after  { content: ']'; }

.news-content {
    flex: 1;
    line-height: 1.5;
}

.show-more {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--text-secondary);
    font-size: 0.9em;
    padding: 5px 14px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    background: var(--card-bg);
    transition: all 0.2s;
}

.show-more:hover {
    background: var(--hover-bg);
    border-color: #9ca3af;
    color: var(--text-color);
    text-decoration: none;
}

.paper {
    display: flex;
    gap: 25px;
    margin-bottom: 30px;
    align-items: center;
}

.paper img, .paper video {
    width: 200px;
    min-width: 200px;
    max-width: 200px;
    height: auto;
    flex-shrink: 0;
    border-radius: 8px;
}

.paper-info h3 {
    font-size: 1.1em;
    font-weight: 600;
    margin-bottom: 5px;
    line-height: 1.3;
}

.authors {
    font-size: 0.95em;
    margin-bottom: 3px;
    color: var(--text-color);
}

.venue {
    font-style: italic;
    color: var(--text-secondary);
    font-size: 0.95em;
    margin-bottom: 5px;
}

.paper-info .links {
    font-size: 0.9em;
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.paper-info .links a {
    padding: 3px 10px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.85em;
}

.paper-info .links a:hover {
    background: var(--hover-bg);
    text-decoration: none;
}

.edu-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.edu-logo {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 8px;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
}

.edu-logo img {
    max-width: 70px;
    max-height: 70px;
    object-fit: contain;
}

.edu-content {
    flex: 1;
}

.edu-content p {
    margin-bottom: 5px;
}

.edu-content p:first-child {
    font-size: 1.1em;
    font-weight: 600;
}

.edu-content p:first-child strong {
    font-weight: 600;
}

.edu-year {
    float: right;
    font-style: italic;
    font-weight: 400;
}

.exp-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px 40px;
}

.exp-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.exp-logo {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.exp-logo img {
    max-width: 60px;
    max-height: 60px;
    object-fit: contain;
}

.exp-content h3 {
    font-size: 1.05em;
    font-weight: 600;
    margin-bottom: 4px;
    line-height: 1.3;
}

.exp-content .exp-date {
    color: var(--text-secondary);
    font-size: 0.95em;
    margin-bottom: 4px;
}

.exp-content .exp-host {
    color: var(--text-secondary);
    font-size: 0.95em;
}

.activities ul {
    list-style-position: inside;
    padding-left: 0;
}

.activities li {
    margin-bottom: 8px;
}

.awards-list {
    margin-bottom: 20px;
    list-style-position: inside;
    padding-left: 0;
}

.award-item {
    display: list-item;
    margin-bottom: 8px;
}

.award-item span {
    display: inline;
}

.award-year {
    float: right;
    color: var(--text-secondary);
    min-width: 85px;
    text-align: right;
    font-weight: 500;
}


@media (max-width: 600px) {
    body {
        font-size: 14px;
    }

    .container {
        padding: 20px 10px;
        max-width: 100%;
    }

    header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 15px;
        margin-bottom: 30px;
    }

    .header-info {
        width: 100%;
    }

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

    h1 {
        font-size: 1.4em;
        margin-bottom: 8px;
    }

    h2 {
        font-size: 1.2em;
    }

    .title, .affiliation {
        font-size: 1em;
    }

    .email {
        font-size: 0.9em;
        word-break: break-word;
    }

    .links {
        justify-content: center;
        flex-wrap: wrap;
    }

    .bio p {
        font-size: 1em;
    }

    .pub-filters {
        flex-wrap: wrap;
        gap: 8px;
    }

    .filter-btn {
        font-size: 0.8em;
        padding: 6px 12px;
    }

    .paper {
        flex-direction: column;
        margin-bottom: 30px;
    }

    .paper img, .paper video {
        width: 100%;
        max-width: 100%;
        min-width: 100%;
    }

    .paper-info h3 {
        font-size: 1.05em;
    }

    .authors, .venue {
        font-size: 0.9em;
    }

    .exp-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .edu-item {
        gap: 15px;
    }

    .edu-logo {
        width: 60px;
        height: 60px;
    }

    .edu-logo img {
        max-width: 50px;
        max-height: 50px;
    }

    .edu-content p:first-child {
        font-size: 1em;
    }

    .news-item {
        flex-direction: column;
        gap: 5px;
    }

    .news-date {
        min-width: auto;
    }

    .activities ul, .awards-list {
        padding-left: 20px;
    }

    .award-year {
        float: none;
        display: block;
        text-align: left;
        margin-top: 4px;
        min-width: auto;
    }
}

