/* ===== Reset & Base ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 70px;
}

body {
    font-family: 'Source Sans 3', 'Source Sans Pro', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    color: #333;
    background: #fff;
}

a {
    color: #1a5276;
    text-decoration: none;
}

a:hover {
    color: #0d3b5a;
    text-decoration: underline;
}

/* ===== Navigation ===== */
header {
    position: sticky;
    top: 0;
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
    z-index: 100;
}

nav {
    max-width: 820px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-name a {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 28px;
}

.nav-links a {
    font-size: 15px;
    color: #555;
    text-decoration: none;
    letter-spacing: 0.02em;
}

.nav-links a:hover {
    color: #1a5276;
    text-decoration: none;
}

/* ===== Main Content ===== */
main {
    max-width: 820px;
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 50px 0;
    border-bottom: 1px solid #eee;
}

.section:last-child {
    border-bottom: none;
}

h2 {
    font-size: 26px;
    font-weight: 600;
    margin-bottom: 28px;
    color: #222;
}

/* ===== About Section ===== */
.about-container {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.about-photo {
    flex-shrink: 0;
}

.about-photo img {
    width: 200px;
    height: 240px;
    object-fit: cover;
    border-radius: 4px;
    background: #f0f0f0;
}

.about-text h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 4px;
    color: #222;
}

.affiliation {
    font-size: 17px;
    color: #666;
    margin-bottom: 18px;
    line-height: 1.5;
}

.about-text p {
    margin-bottom: 12px;
}

.contact-info {
    margin-top: 20px;
    font-size: 15px;
}

.contact-label {
    font-weight: 600;
    color: #555;
}

/* ===== Research Section ===== */
.research-category {
    margin-bottom: 32px;
}

.research-category:last-child {
    margin-bottom: 0;
}

h3 {
    font-size: 19px;
    font-weight: 600;
    color: #444;
    margin-bottom: 14px;
    padding-bottom: 6px;
    border-bottom: 1px solid #eee;
}

.paper {
    margin-bottom: 20px;
    padding-left: 0;
}

.paper:last-child {
    margin-bottom: 0;
}

.paper-title {
    font-weight: 600;
    font-size: 16px;
    color: #222;
    margin-bottom: 2px;
}

.paper-coauthors {
    font-size: 15px;
    color: #666;
    font-style: italic;
    margin-bottom: 4px;
}

.paper-abstract {
    font-size: 15px;
    margin-bottom: 4px;
}

.abstract-toggle {
    color: #1a5276;
    cursor: pointer;
    font-size: 14px;
}

.abstract-toggle:hover {
    text-decoration: underline;
}

.abstract-text {
    display: none;
    margin-top: 8px;
    font-size: 14px;
    color: #555;
    line-height: 1.6;
    padding: 12px 16px;
    background: #fafafa;
    border-left: 3px solid #ddd;
}

.paper-abstract.show .abstract-text {
    display: block;
}

.paper-links {
    font-size: 14px;
}

.paper-links a {
    margin-right: 12px;
}

/* ===== Teaching Section ===== */
.teaching-category {
    margin-bottom: 32px;
}

.teaching-category:last-child {
    margin-bottom: 0;
}

.teaching-list {
    list-style: none;
    padding: 0;
}

.teaching-list li {
    padding: 6px 0;
    font-size: 16px;
    border-bottom: 1px solid #f0f0f0;
}

.teaching-list li:last-child {
    border-bottom: none;
}

.course-name {
    font-weight: 600;
    color: #222;
}

.course-role {
    color: #666;
    font-size: 15px;
}

.course-term {
    float: right;
    color: #888;
    font-size: 14px;
}

.course-eval {
    clear: both;
    font-size: 14px;
    color: #666;
    margin-top: 4px;
    font-style: italic;
}

/* ===== CV Section ===== */
.cv-link {
    font-weight: 600;
}

/* ===== Footer ===== */
footer {
    max-width: 820px;
    margin: 0 auto;
    padding: 30px 24px;
    text-align: center;
    font-size: 14px;
    color: #999;
}

/* ===== Responsive ===== */
@media (max-width: 640px) {
    body {
        font-size: 16px;
    }

    .about-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .about-photo img {
        width: 160px;
        height: 200px;
    }

    .about-text h1 {
        font-size: 26px;
    }

    nav {
        padding: 12px 16px;
    }

    .nav-links {
        gap: 18px;
    }

    .section {
        padding: 36px 0;
    }

    h2 {
        font-size: 22px;
    }
}
