:root {
    --color-bg: #ffffff;
    --color-text: #1f2933;
    --color-muted: #6b7280;
    --color-accent: #1f3a93;
    --color-border: #e5e7eb;
    --color-soft: #f7f8fa;
    --max-width: 880px;
    --font-sans: -apple-system, BlinkMacSystemFont, "Helvetica Neue",
                 "Hiragino Sans", "Hiragino Kaku Gothic ProN",
                 "Noto Sans JP", Meiryo, sans-serif;
    --font-serif: "Times New Roman", "Hiragino Mincho ProN",
                  "Yu Mincho", "Noto Serif JP", serif;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-sans);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.75;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    margin-top: 3rem;
    padding: 0 1.5rem;
}

/* ===== Header ===== */
.site-header {
    border-bottom: 1px solid var(--color-border);
    padding: 3rem 0 2.5rem;
    background: var(--color-soft);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.icon-wrap {
    flex-shrink: 0;
    position: relative;
    width: 140px;
    height: 140px;
}

.icon {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    background: #ddd;
}

.icon-fallback {
    display: none;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: var(--color-accent);
    color: #fff;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    border: 3px solid #fff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.header-text {
    flex: 1;
    min-width: 240px;
}

.name-ja {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    margin: 0 0 0.2rem;
    letter-spacing: 0.04em;
}

.name-en {
    font-size: 1rem;
    color: var(--color-muted);
    margin: 0 0 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.affiliation {
    margin: 0;
    color: var(--color-text);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ===== Main sections ===== */
main {
    padding-top: 5rem;
    padding-bottom: 3rem;
}

main > section {
    margin-bottom: 4rem;
}

main > section:last-child {
    margin-bottom: 0;
}

h2 {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    margin: 0 0 1.2rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--color-accent);
    display: inline-block;
    letter-spacing: 0.05em;
}

.tbd {
    color: var(--color-muted);
    font-style: italic;
}

/* ===== Biography table ===== */
.bio-table {
    width: 100%;
    border-collapse: collapse;
}

.bio-table th,
.bio-table td {
    text-align: left;
    padding: 0.7rem 1rem;
    vertical-align: top;
    border-bottom: 1px solid var(--color-border);
    font-weight: normal;
}

.bio-table th {
    width: 9rem;
    color: var(--color-muted);
    white-space: nowrap;
    font-feature-settings: "tnum";
}

.bio-table tr:last-child th,
.bio-table tr:last-child td {
    border-bottom: none;
}

/* ===== Contact list ===== */
.contact-list {
    display: grid;
    grid-template-columns: 7rem 1fr;
    gap: 0.7rem 1.5rem;
    margin: 0;
}

.contact-list dt {
    color: var(--color-muted);
    font-size: 0.9rem;
    padding-top: 0.1rem;
}

.contact-list dd {
    margin: 0;
}

.contact-list a {
    color: var(--color-accent);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.contact-list a:hover {
    border-bottom-color: var(--color-accent);
}

/* ===== Footer ===== */
.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 1.5rem 0;
    color: var(--color-muted);
    text-align: center;
    margin-top: 2rem;
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
    .site-header {
        padding: 2rem 0 1.5rem;
    }

    .header-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1.2rem;
    }

    .name-ja {
        font-size: 1.8rem;
    }

    main {
        padding-top: 3rem;
        padding-bottom: 2rem;
    }

    .bio-table th {
        width: 7.5rem;
        font-size: 0.85rem;
    }

    .bio-table th,
    .bio-table td {
        padding: 0.6rem 0.5rem;
    }

    .contact-list {
        grid-template-columns: 1fr;
        gap: 0.1rem 0;
    }

    .contact-list dt {
        margin-top: 0.7rem;
    }
}
