:root {
  --link: #08338f;
  --link-hover: #496a86;
  --text: #222222;
  --muted: #555555;
  --line: #dddddd;
  --callout: rgba(8, 51, 143, 0.055);
}

* { box-sizing: border-box; }
html { background: #ffffff; }

body {
  margin: 0;
  color: var(--text);
  background: #ffffff;
  font-family: "Lato", Verdana, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.3;
}

a { color: var(--link); text-decoration: none; }
a:hover, a:focus-visible { color: var(--link-hover); }
::selection { background: #d9e4ec; }

.page {
  width: min(100%, 1000px);
  margin: 0 auto;
  padding: 0 0 20px;
}

.bio {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 230px;
  align-items: center;
  gap: 30px;
  padding: 26px 25px 10px;
}

.bio-copy { min-width: 0; }

.profile-photo {
  display: block;
  width: 230px;
  aspect-ratio: 0.84;
  overflow: hidden;
  border: 1px solid #dddddd;
  background: #f4f4f4;
}

.profile-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}

h1 {
  margin: 0 0 24px;
  font-size: 36px;
  font-weight: 400;
  line-height: 1.3;
  text-align: center;
}

h1 span[lang] { color: #333333; }
.bio p { margin: 0 0 18px; }
.profile-links { text-align: center; }

.profile-links span, .paper-links span {
  padding: 0 4px;
  color: #555555;
}

.application-callout {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin: 0 20px 8px;
  padding: 7px 10px;
  border-left: 3px solid var(--link);
  border-radius: 2px;
  background: var(--callout);
  line-height: 1.35;
}

.callout-label {
  flex: 0 0 auto;
  color: var(--link);
  font-weight: 700;
}

.application-callout strong { color: var(--link); font-weight: 600; }
.content-section { padding: 0 20px 10px; }

h2 {
  display: inline-block;
  margin: 0;
  font-size: 32px;
  font-weight: 400;
  line-height: 1;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.content-section > p { margin: 14px 0; }

.contribution-note {
  margin-top: -6px !important;
  margin-bottom: 0 !important;
  line-height: 1.3;
}

.publication-list { width: 100%; }

.publication {
  display: grid;
  grid-template-columns: 30% 70%;
  align-items: start;
}

.teaser-cell { padding: 18px 10px 18px 20px; text-align: center; }

.teaser-cell img {
  display: block;
  width: 100%;
  max-height: 190px;
  object-fit: contain;
  margin: 0 auto;
}

.paper-info { min-width: 0; padding: 17px 20px 18px 9px; }

.paper-info h3 {
  margin: 0 0 5px;
  color: #000000;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
}

.paper-info p { margin: 4px 0 0; }
.paper-authors, .paper-venue, .paper-links { line-height: 1.3; }
.paper-links { margin-top: 8px !important; }
.paper-links a { display: inline-block; }

.experience-section { padding: 10px 20px 0; }
.experience-list { margin-top: 13px; }

.experience-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  padding: 9px 0 15px;
}

.institution-mark {
  display: flex;
  width: 100px;
  height: 68px;
  align-items: center;
  justify-content: center;
  justify-self: center;
  border: 1px solid #dddddd;
  background: #ffffff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.utah-mark { color: #cc0000; border-bottom: 5px solid #ffffff; }
.sjtu-mark { color: #9e1b32; border-bottom: 5px solid #9e1b32; }

.experience-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.experience-title h3 { margin: 0; font-size: 18px; line-height: 1.3; }
.experience-date { flex: 0 0 auto; color: var(--muted); white-space: nowrap; }
.experience-info p { margin: 4px 0 0; }

footer {
  padding: 10px 20px 0;
  color: #777777;
  font-size: 12px;
  text-align: right;
}

footer p { margin: 0; }

@media (max-width: 640px) {
  body { overflow-x: hidden; }
  .page { width: 100%; }

  .bio {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 14px;
    padding: 18px 20px 8px;
  }

  .bio-copy { width: 100%; }
  .profile-photo { width: min(58vw, 210px); }
  h1 { margin-bottom: 20px; font-size: 32px; line-height: 1.15; }
  .profile-links { line-height: 1.7; }
  .application-callout { align-items: flex-start; gap: 4px 10px; }
  .callout-label { width: 100%; }
  .publication { display: block; }
  .teaser-cell, .paper-info { width: 100%; }
  .teaser-cell { padding: 12px 20px 5px; }
  .teaser-cell img { width: min(78vw, 320px); max-height: none; }
  .paper-info { padding: 5px 20px 17px; }

  .experience-item {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
  }

  .institution-mark { width: 76px; height: 54px; font-size: 16px; }
  .experience-title { display: block; }
  .experience-date { display: block; margin-top: 2px; white-space: normal; }

  .paper-info h3, .paper-authors, .paper-venue, .paper-links, .bio p {
    overflow-wrap: break-word;
  }

  footer { padding: 6px 20px 0; text-align: center; }
}

@media (max-width: 430px) {
  .bio { padding: 16px 18px 8px; }
  .teaser-cell img { width: min(74vw, 288px); }
}
