/* ---------- Reset & base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: #1a1a1a;
    background: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; display: block; }

a {
    color: #2563eb;
    text-decoration: none;
    transition: color .15s ease;
}
a:hover { color: #1d4ed8; }

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

.section {
    padding: 5.5rem 0;
    border-top: 1px solid #eee;
}
.section-alt { background: #fafafa; }

.section-title {
    font-size: 1.75rem;
    font-weight: 600;
    letter-spacing: -.01em;
    margin: 0 0 2.5rem;
    color: #111;
    position: relative;
    padding-bottom: .75rem;
}
.section-title::after {
    content: '';
    position: absolute;
    left: 0; bottom: 0;
    width: 2.5rem; height: 3px;
    background: #2563eb;
    border-radius: 2px;
}

.subhead {
    font-size: .8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #6b7280;
    margin: 0 0 1rem;
}

.prose {
    font-size: 1.0625rem;
    color: #374151;
    max-width: 70ch;
}
.prose p { margin: 0 0 1rem; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- Nav ---------- */
.nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255,255,255,.85);
    backdrop-filter: saturate(180%) blur(10px);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid #eee;
}
.nav-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-brand {
    font-weight: 700;
    font-size: 1.05rem;
    color: #111;
    letter-spacing: -.01em;
}
.nav-links {
    display: flex;
    gap: 1.75rem;
    list-style: none;
    margin: 0; padding: 0;
}
.nav-links a {
    color: #4b5563;
    font-size: .92rem;
    font-weight: 500;
    padding: .25rem 0;
    border-bottom: 2px solid transparent;
    transition: color .15s ease, border-color .15s ease;
}
.nav-links a:hover { color: #111; }
.nav-links a.active {
    color: #111;
    border-bottom-color: #2563eb;
}

/* ---------- Hero ---------- */
.hero {
    padding: 5rem 0 4.5rem;
    background: linear-gradient(180deg, #fafafa 0%, #ffffff 100%);
}
.hero-inner {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 3.5rem;
}

.eyebrow {
    font-size: .8rem;
    font-weight: 600;
    color: #2563eb;
    text-transform: uppercase;
    letter-spacing: .12em;
    margin: 0 0 1rem;
}

.hero h1 {
    margin: 0 0 1.25rem;
    font-size: clamp(2.25rem, 5vw, 3.25rem);
    line-height: 1.1;
    font-weight: 700;
    letter-spacing: -.02em;
    color: #0a0a0a;
}

.lede {
    font-size: 1.125rem;
    line-height: 1.65;
    color: #4b5563;
    max-width: 38rem;
    margin: 0 0 2rem;
}
.lede strong { color: #111; font-weight: 600; }

.hero-actions {
    display: flex;
    gap: .75rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: .65rem 1.25rem;
    border-radius: 8px;
    font-size: .92rem;
    font-weight: 500;
    transition: all .15s ease;
    border: 1px solid transparent;
}
.btn-primary {
    background: #111;
    color: #fff;
}
.btn-primary:hover { background: #2563eb; color: #fff; }
.btn-ghost {
    background: transparent;
    color: #111;
    border-color: #d1d5db;
}
.btn-ghost:hover { border-color: #111; color: #111; }

.social {
    display: flex;
    gap: 1.25rem;
    list-style: none;
    padding: 0;
    margin: 0;
}
.social a {
    font-size: .9rem;
    color: #6b7280;
    font-weight: 500;
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}
.social a svg { flex-shrink: 0; }
.social a::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: -2px;
    height: 1px;
    background: currentColor;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .2s ease;
}
.social a:hover {
    color: #111;
}
.social a:hover::after { transform: scaleX(1); }

.hero-portrait { display: flex; justify-content: center; }
.portrait-circle {
    width: 200px; height: 200px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 20px 40px -15px rgba(37, 99, 235, .35);
}
.portrait-img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center top;
}

/* ---------- Education list ---------- */
.education { margin-top: 2.5rem; }
.edu-list {
    list-style: none;
    padding: 0; margin: 0;
}
.edu-list li {
    display: grid;
    grid-template-columns: 8rem 1fr;
    gap: 1.25rem;
    padding: .65rem 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: .98rem;
}
.edu-list li:last-child { border-bottom: 0; }
.edu-year {
    color: #6b7280;
    font-variant-numeric: tabular-nums;
    font-size: .92rem;
}
.edu-detail { color: #374151; }
.edu-detail strong { color: #111; font-weight: 600; }


/* ---------- Interest cards ---------- */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
}
.card {
    position: relative;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 1.75rem 1.5rem 1.5rem;
    overflow: hidden;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #1e40af);
}
.card::after {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 120px; height: 120px;
    border-radius: 50%;
    background: var(--card-blob, radial-gradient(circle, rgba(37,99,235,.08), transparent 70%));
    pointer-events: none;
    transition: transform .3s ease;
}
.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -10px rgba(0,0,0,.1);
    border-color: #d1d5db;
}
.card:hover::after { transform: scale(1.3); }

.card-hri::before        { background: linear-gradient(90deg, #0891b2, #2563eb); }
.card-hri::after         { background: radial-gradient(circle, rgba(8,145,178,.14), transparent 70%); }
.card-imitation::before  { background: linear-gradient(90deg, #6d28d9, #db2777); }
.card-imitation::after   { background: radial-gradient(circle, rgba(219,39,119,.13), transparent 70%); }
.card-telerobotics::before { background: linear-gradient(90deg, #1e3a8a, #312e81); }
.card-telerobotics::after  { background: radial-gradient(circle, rgba(49,46,129,.13), transparent 70%); }
.card-space::before      { background: linear-gradient(90deg, #1f2937, #fbbf24); }
.card-space::after       { background: radial-gradient(circle, rgba(251,191,36,.16), transparent 70%); }
.card-medical::before    { background: linear-gradient(90deg, #0d9488, #84cc16); }
.card-medical::after     { background: radial-gradient(circle, rgba(13,148,136,.14), transparent 70%); }

.card h3 {
    position: relative;
    margin: 0 0 .65rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: #111;
}
.card p {
    position: relative;
    margin: 0;
    color: #4b5563;
    font-size: .95rem;
    line-height: 1.55;
}

/* ---------- Expertise ---------- */
.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}
.tag-list {
    list-style: none;
    padding: 0; margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}
.tag-list li {
    background: #f3f4f6;
    color: #374151;
    padding: .35rem .75rem;
    border-radius: 6px;
    font-size: .85rem;
    font-weight: 500;
}

/* ---------- Publications ---------- */
.pub {
    display: grid;
    grid-template-columns: clamp(220px, 32vw, 300px) 1fr;
    gap: 1.25rem 1.75rem;
    padding: 1.75rem 0;
    border-bottom: 1px solid #e5e7eb;
    align-items: start;
}
.pub:last-child { border-bottom: 0; }
.pub-no-thumb { grid-template-columns: 1fr; }

.pub-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
    background: #f1f5f9;
}
.pub-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pub-meta {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: .4rem;
    flex-wrap: wrap;
}
.pub-year {
    font-size: .82rem;
    font-weight: 600;
    color: #9ca3af;
    font-variant-numeric: tabular-nums;
}
.pub-year-filed {
    font-style: italic;
}

.pub-body { min-width: 0; }
.pub-title {
    margin: 0 0 .4rem;
    font-size: 1.075rem;
    font-weight: 600;
    line-height: 1.4;
    color: #111;
}
.pub-authors {
    margin: 0 0 .2rem;
    color: #4b5563;
    font-size: .92rem;
}
.pub-authors strong { color: #111; font-weight: 600; }
.pub-note {
    margin: 0 0 .2rem;
    color: #6b7280;
    font-size: .75rem;
}
.pub-venue {
    margin: 0 0 .6rem;
    color: #6b7280;
    font-size: .9rem;
}
.pub-abstract {
    margin: 0 0 .75rem;
    color: #4b5563;
    font-size: .92rem;
    line-height: 1.55;
}
.pub-links {
    display: flex;
    align-items: center;
    gap: .65rem;
    flex-wrap: wrap;
}
.pub-links a,
.pub-links .pub-link-disabled,
.pub-cite {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
    display: inline-flex;
    align-items: center;
    font-family: inherit;
    font-size: .85rem;
    font-weight: 500;
    line-height: 1.5;
    color: #2563eb;
    padding: .25rem .65rem;
    border: 1px solid #2563eb33;
    border-radius: 6px;
    background: transparent;
    cursor: pointer;
    transition: all .15s ease;
}
.pub-links a:hover,
.pub-cite:hover {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}
.pub-links .pub-link-disabled {
    color: #9ca3af;
    border-color: #9ca3af33;
    cursor: not-allowed;
}
.pub-cite.is-copied {
    background: #166534;
    color: #fff;
    border-color: #166534;
}
.pub-tag {
    font-size: .72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    padding: .2rem .5rem;
    border-radius: 4px;
    background: #f1f5f9;
    color: #475569;
}
.pub-tag-journal {
    background: #eff6ff;
    color: #1d4ed8;
}
.pub-tag-conference {
    background: #ecfdf5;
    color: #047857;
}
.pub-tag-preprint {
    background: #fffbeb;
    color: #b45309;
}
.pub-tag-patent {
    background: #f5f3ff;
    color: #6d28d9;
}

/* ---------- Contact ---------- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}
.contact-email {
    margin-top: 1.25rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1rem;
}
.contact-meta {
    display: grid;
    gap: 1.5rem;
    font-size: .95rem;
    color: #4b5563;
}
.contact-meta p { margin: 0; }
.link-list {
    list-style: none;
    padding: 0; margin: 0;
    display: flex;
    flex-direction: column;
    gap: .35rem;
}

/* ---------- Footer ---------- */
.footer {
    border-top: 1px solid #eee;
    padding: 2rem 0;
    background: #fafafa;
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.footer p {
    margin: 0;
    font-size: .85rem;
    color: #6b7280;
}
.footer-meta { color: #9ca3af; }

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
    .nav-links { gap: 1.1rem; }
    .nav-links a { font-size: .85rem; }

    .hero { padding: 3rem 0; }
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: left;
    }
    .hero-portrait { order: -1; }
    .portrait-circle { width: 140px; height: 140px; }

    .section { padding: 4rem 0; }

    .edu-list li {
        grid-template-columns: 1fr;
        gap: .15rem;
    }

    .pub {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .pub-thumb {
        width: 100%;
        max-width: 220px;
        aspect-ratio: 16 / 9;
    }

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

@media (max-width: 480px) {
    .nav-brand { display: none; }
    .nav-links { width: 100%; justify-content: space-between; gap: .5rem; }
    .hero h1 { font-size: 2rem; }
    .lede { font-size: 1rem; }
}
