@charset "utf-8";
@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@300;400;500;600;700&display=swap");

:root {
    --color-accent: #4A7BAF;
    --color-accent-hover: #2E5F8E;
    --color-link-card: #7EB3E8;
    --color-pub-title: #4A6880;
    --color-pub-item-link: #3D6E9E;
    --color-terminal-accent: #99CCFF;
    --color-terminal-fg-dim: #ffffff;
    --color-page-bg: #f6f8fa;
    --color-text: #24292e;
    --color-highlight-bg: #EFF4FA;
    --color-nav-active-text: #ffffff;
    --color-navbar-bg: #2C3A4A;
    --font-family-monospace: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    --sticky-below-nav: 80px;
    --shadow-publication-cover: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-pub-badge: 0 1px 3px rgba(0, 0, 0, 0.2);
    --pub-mobile-overlay: rgba(255, 255, 255, 0.9);
}

/* Publications page: year sidebar (scrollspy). */
.publications-year-nav.nav-pills .nav-link {
    color: var(--color-accent);
}
.publications-year-nav.nav-pills .nav-link:hover {
    color: var(--color-accent);
    opacity: 0.8;
}
.publications-year-nav.nav-pills .nav-link.active {
    background-color: var(--color-accent);
    color: var(--color-nav-active-text);
}

/* Bold author name on papers (see author_list.html). */
.pub-author-emph {
    color: var(--color-accent);
}

html, body {
    background-color: var(--color-page-bg);
}

body {
    font-family: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    font-size: 15px;
    line-height: 1.5;
    color: var(--color-text);
    font-weight: 400;
    padding-top: 5.0rem;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-weight: 700;
}

.text-profile-position {
    font-weight: 400;
}

.text-profile-bio {
    font-weight: 400;
}

.text-profile-bio--justify {
    text-align: justify;
}

.navbar {
    background-color: var(--color-navbar-bg);
    opacity: 0.95;
}

.card {
    border-radius: 8px;
}

.inline-badge {
    height: 16px;
    vertical-align: -10%;
    margin-right: 2px;
    line-break: unset;
}

.no-break {
    white-space: nowrap;
}

.cover-image {
    width: 180px;
    max-height: 120px;
}

.abstract-body {
    min-height: 100px;
}

img.lazy {
    background-image: url('images/loading.gif');
    background-repeat: no-repeat;
    background-position: 50% 50%;
    background-size: 50px 50px;
    min-height: 80px;
}

div.lazy {
    background-image: url('images/loading.gif');
    background-repeat: no-repeat;
    background-position: 50% 50%;
    background-size: 50px 50px;
    min-height: 80px;
}

.badge-publication {
    font-size: 100%;
}

.email-text {
    font-family: var(--font-family-monospace);
    color: var(--color-accent);
}

/* Profile sidebar email + social icons (class also used for CV link in bio card). */
a.follow_href {
    color: var(--color-accent);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

a.follow_href:hover,
a.follow_href:focus {
    color: var(--color-accent-hover);
    text-decoration: none;
}

a.location_href {
    color: var(--color-accent);
    text-decoration: none;
}

a.profile_href {
    color: var(--color-accent);
}

/* Default nav + brand on dark navbar (Bootstrap navbar-light would otherwise be near-black). */
.navbar-light .navbar-nav .nav-link {
    color: var(--color-accent);
}

.navbar-light .navbar-nav .nav-item.active .nav-link,
.navbar .nav-item.active .nav-link {
    color: var(--color-nav-active-text);
    font-weight: 600;
}

.navbar-light .navbar-brand,
.navbar-light .navbar-brand strong {
    color: var(--color-accent);
}

.terminal-text {
    color: var(--color-accent);
    margin-right: 1.5rem;
    padding-left: 0;
    display: inline-flex;
    align-items: center;
}

.terminal-zju {
    color: var(--color-terminal-accent);
}

.terminal-dim {
    color: var(--color-terminal-fg-dim);
}

.navbar-toggler-compact {
    font-size: 1em;
    padding: 0.5em;
}

.terminal-cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background-color: var(--color-terminal-accent);
    margin-left: 2px;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    from, to {
        opacity: 1;
    }
    50% {
        opacity: 0;
    }
}

/* -------------------------------------------------------------------------- */
/* Publication list (_includes/widgets/publication_item.html)                */
/* -------------------------------------------------------------------------- */

a.item_link {
    color: var(--color-pub-item-link);
}

.publication-cover {
    object-fit: contain;
    max-width: 100%;
    max-height: 200px;
    box-shadow: var(--shadow-publication-cover);
}

.selected-publication {
    background-color: var(--color-highlight-bg);
}

.pub-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background-color: var(--color-accent);
    color: var(--color-nav-active-text);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.7em;
    font-weight: bold;
    z-index: 10;
    box-shadow: var(--shadow-pub-badge);
}

.publication-container {
    position: relative;
}

.pub-item-title {
    color: var(--color-pub-title);
}

.pub-mobile-overlay {
    background-color: var(--pub-mobile-overlay);
}

/* Legend: “highlighted” on publications page + matching row background */
.text-highlight-bg {
    background-color: var(--color-highlight-bg);
}

/* Card header “view all” links (publication_card, research_overview) */
.pub-link {
    color: var(--color-link-card);
}

.pub-link:hover {
    color: var(--color-link-card);
    opacity: 0.85;
    text-decoration: none;
}

/* -------------------------------------------------------------------------- */
/* Profile sidebar (_includes/widgets/profile_card_mini.html)               */
/* -------------------------------------------------------------------------- */

.sticky-below-navbar {
    top: var(--sticky-below-nav);
}

.profile-portrait-container {
    position: relative;
    display: inline-block;
}

.avatar-container {
    width: 100%;
    max-width: 200px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto;
}

.avatar-container .avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.profile-portrait-container .profile-portrait.hover {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.position-inline-logo {
    height: auto;
    max-height: 10em;
    width: 50px;
    vertical-align: middle;
    margin-left: 5px;
}

/* Education / experience logos (_includes/widgets/experience_card.html) */
.experience-inline-logo {
    height: 24px;
    width: auto;
}

/* ── YC Navbar Brand ── */
.nav-brand-yc {
    display: inline-flex;
    align-items: center;
    gap: .55rem;
    text-decoration: none;
    margin-right: 1rem;
}

.nav-brand-yc:hover { text-decoration: none; }

.nav-monogram {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--color-accent);
    color: #fff;
    font-size: .76rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    letter-spacing: .02em;
}

.nav-fullname {
    color: #fff;
    font-weight: 500;
    font-size: .95rem;
    letter-spacing: .01em;
}

.nav-fullname-zh {
    color: rgba(255,255,255,.5);
    font-weight: 300;
    font-size: .78rem;
    margin-left: .4rem;
}
