:root {
    --sidebar-width: 18rem;
    --content-width: 75ch;

    --text: #1f2937;
    --muted: #6b7280;
    --border: #e5e7eb;
    --link: #2563eb;
    --background: #ffffff;
}

@media (prefers-color-scheme: dark) {
    :root {
        --text: #f3f4f6;
        --muted: #9ca3af;
        --border: #374151;
        --link: #97c4fc;
        --background: #111827;
    }
}

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

body {
    margin: 0;
    background: var(--background);
    color: var(--text);

    font-family:
        Inter,
        system-ui,
        sans-serif;

    line-height: 1.7;
}

.layout {
    display: flex;
    gap: 4rem;

    max-width: 90rem;
    margin-inline: auto;
    padding: 3rem 2rem;
}

i {
    margin-right: 0.5rem;
}

.publication-links i {
    margin-right: 0.2rem;
}

.sidebar {
    flex: 0 0 var(--sidebar-width);
    align-self: flex-start;
    position: sticky;
    top: 2rem;
}

.profile-image {
    width: 100%;
    max-width: 10rem;
    margin-left: 0.7rem;
    margin-bottom: 1.5rem;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 30%;
    display: block;
}

.profile-header {
    margin-top: 1rem;
}

.profile-header h1 {
    margin: 0;
    line-height: 1.1;
    font-size: 1.5rem;
}

.position,
.institution {
    color: var(--muted);
}

.position {
    margin: 0.5rem 0 0;
}

.institution {
    margin: 0.5rem 0 0;
}

.profile-links {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0 0;
}

.profile-links li + li {
    margin-top: 0.5rem;
}

.content {
    flex: 1;
    min-width: 0;
    max-width: var(--content-width);
}

section + section {
    margin-top: 3rem;
}

h2 {
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.publication-header {
    margin-bottom: -0.3rem;
}

.publication + .publication {
    border-top: 1px solid var(--border);
}

.publication h3 {
    margin-bottom: 0.5rem;
}

.publication {
    padding-block: 1.0rem;
    display: flex;
    gap: 1.25rem;
}

.publication-image {
    margin-top: 1.7rem;
    width: 9rem;
    height: 9rem;
    object-fit: cover;
    border-radius: 10%;
    flex-shrink: 0;
}

.publication-content {
    flex: 1;
}

.authors,
.venue {
    margin: 0;
}

a {
  text-decoration: none;
}

.venue {
    color: var(--muted);
}

.publication-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;

    list-style: none;
    padding: 0;
    margin-top: 0.75rem;
}

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

a:focus-visible {
    outline: 0.15rem solid currentColor;
    outline-offset: 0.15rem;
}

@media (max-width: 50rem) {

    .layout {
        flex-direction: column;
        gap: 2rem;
        padding: 2rem 1.25rem;
    }

    .sidebar {
        position: static;
        flex-basis: auto;
        align-self: center;
    }

    .profile-image {
        max-width: 10rem;
        margin-inline: auto;
    }

    .profile-header {
        text-align: center;
    }

    .profile-links {
        text-align: center;
    }

    .profile-links li {
        display: inline-block;
        margin: 0 0.5rem;
    }

    .profile-links li + li {
        margin-top: 0;
    }

    .content {
        max-width: 100%;
    }

    .publication {
        display: block;
        text-align: center;
    }

    .publication-content {
        text-align: left;
    }
}