/* =========================================================
   Jinxin Wang — Academic Homepage
   ========================================================= */


/* ---------------------------------------------------------
   Global
   --------------------------------------------------------- */

:root {
    --text: #292929;
    --text-dark: #202020;
    --text-muted: #666a6d;

    --link: #47759a;
    --link-hover: #2f5878;

    --line: #eceeef;
    --selection: #dce8f0;

    --content-width: 960px;
}


*,
*::before,
*::after {
    box-sizing: border-box;
}


html {
    background: #ffffff;
}


body {
    margin: 0;

    background: #ffffff;
    color: var(--text);

    font-family:
        "Source Sans 3",
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Arial,
        sans-serif;

    font-size: 16.5px;
    font-weight: 400;
    line-height: 1.56;

    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


::selection {
    background: var(--selection);
}


/* ---------------------------------------------------------
   Main layout
   --------------------------------------------------------- */

#layout-content {
    width: 100%;
    max-width: var(--content-width);

    margin: 0 auto;
    padding: 48px 42px 52px;
}


/* ---------------------------------------------------------
   Links
   --------------------------------------------------------- */

a {
    color: var(--link);

    text-decoration: none;

    transition:
        color 0.12s ease,
        text-decoration-color 0.12s ease;
}


a:visited {
    color: var(--link);
}


a:hover {
    color: var(--link-hover);

    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}


a:focus-visible {
    outline: 2px solid #9ab3c5;
    outline-offset: 2px;

    border-radius: 2px;
}


/* ---------------------------------------------------------
   Header
   --------------------------------------------------------- */

.profile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 54px;

    padding: 0 2px 28px;
}


.profile-info {
    flex: 1 1 auto;

    min-width: 0;
}


.profile-info h1 {
    margin: 0 0 10px;

    color: var(--text-dark);

    font-size: 30px;
    font-weight: 600;
    line-height: 1.16;

    letter-spacing: -0.022em;
}


.profile-meta {
    margin: 0 0 8px;

    color: #454545;

    font-size: 16.5px;
    line-height: 1.45;
}


.profile-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;

    margin-top: 7px;

    font-size: 15.8px;
    font-weight: 500;
}


.profile-links a + a::before {
    content: "·";

    display: inline-block;

    margin: 0 9px;

    color: #a0a4a7;

    font-weight: 400;

    pointer-events: none;
}


.profile-photo {
    flex: 0 0 auto;
}


.profile-photo img {
    display: block;

    width: 150px;
    height: auto;

    border: 0;
    border-radius: 4px;
}


/* ---------------------------------------------------------
   Sections
   --------------------------------------------------------- */

.section {
    padding: 25px 2px 27px;

    border-top: 1px solid var(--line);
}


.section h2 {
    margin: 0 0 16px;

    color: #222222;

    font-size: 20px;
    font-weight: 600;
    line-height: 1.25;

    letter-spacing: -0.012em;
}


.contents {
    text-align: left;
}


/* ---------------------------------------------------------
   Paragraphs
   --------------------------------------------------------- */

p {
    margin: 0 0 13px;

    font-size: 16.5px;
    line-height: 1.58;
}


#bio p {
    line-height: 1.61;
}


#bio p:last-child {
    margin-bottom: 0;
}


/* ---------------------------------------------------------
   Selected papers
   --------------------------------------------------------- */

.paper-legend {
    margin-bottom: 19px;

    color: var(--text-muted);

    font-size: 15.5px;
}


.paper {
    margin: 0 0 18px;
}


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


.paper-main {
    margin-bottom: 2px;

    line-height: 1.48;
}


.paper-title {
    color: #202020;

    font-weight: 500;
}


.paper-authors {
    line-height: 1.48;
}


.paper-authors strong {
    font-weight: 600;
}


.paper-note {
    margin-top: 1px;

    color: #5f6366;

    line-height: 1.46;
}


.paper-status {
    color: #555b5f;
}


/* ---------------------------------------------------------
   Lists
   --------------------------------------------------------- */

ul {
    margin: 5px 0 0;
    padding-left: 23px;
}


li {
    margin: 0 0 5px;

    line-height: 1.52;
}


li:last-child {
    margin-bottom: 0;
}


/* ---------------------------------------------------------
   Professional service
   --------------------------------------------------------- */

.service-intro {
    margin-bottom: 4px;
}


/* ---------------------------------------------------------
   Teaching
   --------------------------------------------------------- */

.teaching-list {
    line-height: 1.54;
}


.teaching-item {
    margin-bottom: 4px;
}


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


/* ---------------------------------------------------------
   Footer
   --------------------------------------------------------- */

.footer {
    padding: 24px 2px 6px;

    border-top: 1px solid var(--line);
}


.footer p {
    margin: 0;

    color: #64686b;

    font-size: 15.5px;
}


/* =========================================================
   Tablet
   ========================================================= */

@media (max-width: 760px) {

    #layout-content {
        max-width: 100%;

        padding: 32px 24px 40px;
    }


    .profile-header {
        gap: 36px;

        padding-bottom: 24px;
    }


    .profile-info h1 {
        font-size: 27px;
    }


    .profile-photo img {
        width: 135px;
    }


    .section {
        padding-top: 23px;
        padding-bottom: 25px;
    }


    .paper {
        margin-bottom: 17px;
    }

}


/* =========================================================
   Phone
   ========================================================= */

@media (max-width: 580px) {

    body {
        font-size: 16px;
    }


    #layout-content {
        padding: 24px 18px 34px;
    }


    .profile-header {
        display: block;

        padding-bottom: 23px;
    }


    .profile-info h1 {
        margin-bottom: 9px;

        font-size: 26px;
    }


    .profile-meta {
        font-size: 16px;
    }


    .profile-links {
        font-size: 15.5px;
    }


    .profile-photo {
        margin-top: 19px;
    }


    .profile-photo img {
        width: 125px;
    }


    .section {
        padding: 22px 0 23px;
    }


    .section h2 {
        margin-bottom: 14px;

        font-size: 19px;
    }


    p {
        font-size: 16px;
        line-height: 1.56;
    }


    #bio p {
        line-height: 1.58;
    }


    .paper-legend {
        font-size: 15px;
    }


    .paper {
        margin-bottom: 16px;
    }


    ul {
        padding-left: 21px;
    }


    .footer {
        padding-top: 21px;
    }


    .footer p {
        font-size: 15px;
    }

}
