:root {
  color-scheme: light;
  --bg: #ffffff;
  --ink: #202124;
  --muted: #5f6368;
  --line: #e1e3e1;
  --line-strong: #cfd3cf;
  --link: #1f5f8b;
  --link-hover: #174260;
  --accent: #8b3d2e;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.65;
}

a {
  color: var(--link);
  text-decoration: none;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

.page {
  display: grid;
  grid-template-columns: 250px minmax(0, 820px);
  gap: 58px;
  width: min(1120px, calc(100% - 56px));
  margin: 0 auto;
  padding: 54px 0 44px;
}

.profile {
  position: sticky;
  top: 34px;
  align-self: start;
  min-height: calc(100vh - 68px);
}

.portrait {
  display: block;
  width: 180px;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: #eef0ee;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin: 24px 0 6px;
  font-size: 2.15rem;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: 0;
}

.role {
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 1.02rem;
  font-weight: 600;
}

.location {
  margin-bottom: 7px;
  color: var(--muted);
  line-height: 1.45;
}

.focus {
  max-width: 210px;
  margin: 14px 0 12px;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.45;
}

.focus p {
  margin-bottom: 5px;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.focus ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.focus li + li {
  margin-top: 2px;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.links a,
.pub-links a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 3px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: #fff;
  color: var(--link);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
}

.links a:hover,
.pub-links a:hover {
  border-color: var(--link);
  color: var(--link-hover);
  text-decoration: none;
}

.content {
  min-width: 0;
}

.intro {
  padding: 0 0 30px;
  border-bottom: 1px solid var(--line);
  font-size: 1rem;
}

.intro p {
  max-width: 760px;
}

.intro p:last-child,
.section > :last-child,
.entry > :last-child {
  margin-bottom: 0;
}

.section {
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
}

h2 {
  margin-bottom: 18px;
  color: var(--ink);
  font-size: 1.22rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 6px;
  font-size: 1.04rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0;
}

.publication {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 16px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.publication:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.pub-media {
  display: block;
  align-self: start;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: #fff;
}

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

.pub-media.cmasan img {
  object-fit: contain;
  padding: 6px;
}

.venue {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: baseline;
  margin-bottom: 5px;
  color: var(--accent);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0;
}

.acceptance {
  color: var(--muted);
  font-weight: 500;
}

.acceptance strong {
  color: var(--ink);
  font-weight: 700;
}

.authors {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.96rem;
}

.publication p:not(.venue):not(.authors) {
  margin-bottom: 0;
  color: #383b40;
}

.pub-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.entry {
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.entry:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.entry-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
}

.entry-head span {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.92rem;
}

.entry-role {
  margin-bottom: 2px;
  color: var(--accent);
  font-weight: 650;
}

.entry-meta {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.94rem;
}

ul {
  margin: 0;
  padding-left: 19px;
}

li + li {
  margin-top: 4px;
}

.compact-list {
  margin-bottom: 0;
}

footer {
  padding: 30px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

@media (max-width: 860px) {
  .page {
    grid-template-columns: 1fr;
    gap: 30px;
    width: min(100% - 34px, 720px);
    padding-top: 28px;
  }

  .profile {
    position: static;
    min-height: 0;
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    column-gap: 20px;
    align-items: start;
  }

  .portrait {
    grid-row: span 5;
    width: 118px;
  }

  h1 {
    margin-top: 0;
    font-size: 1.85rem;
  }

  .links {
    margin-top: 12px;
  }

  .intro {
    padding-top: 4px;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 15px;
  }

  .page {
    width: min(100% - 24px, 560px);
    padding-top: 18px;
  }

  .profile {
    grid-template-columns: 92px minmax(0, 1fr);
    column-gap: 15px;
  }

  .portrait {
    width: 92px;
  }

  h1 {
    font-size: 1.5rem;
  }

  .role,
  .location {
    margin-bottom: 4px;
  }

  .focus {
    margin: 8px 0 8px;
  }

  .section {
    padding: 28px 0;
  }

  .publication {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 12px;
  }

  .pub-media {
    max-width: none;
  }

  .entry-head {
    display: block;
  }

  .entry-head span {
    display: block;
    margin-top: 2px;
  }
}

@media (max-width: 430px) {
  .publication {
    grid-template-columns: 1fr;
  }

  .pub-media {
    width: 96px;
  }
}
