.profile-photo {
  float: left;
  width: 180px;
  aspect-ratio: 1123 / 1401;
  margin: 0 1.25rem 1rem 0;
  border-radius: 8px;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

html[data-theme="dark"] .profile-photo {
  filter: brightness(0.82);
}

.degree-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.05rem;
  height: 1.05rem;
  margin-left: 0.25rem;
  border: 1px solid var(--global-divider-color);
  border-radius: 50%;
  background: transparent;
  color: var(--global-text-color-light);
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  line-height: 1;
  vertical-align: text-top;
}

.degree-toggle:hover,
.degree-toggle:focus {
  border-color: var(--global-theme-color);
  color: var(--global-theme-color);
}

.degree-details {
  margin: -0.25rem 0 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--global-divider-color);
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.04);
}

html[data-theme="dark"] .degree-details {
  background: rgba(255, 255, 255, 0.06);
}

.degree-details p:first-child {
  margin-top: 0;
}

.degree-details p:last-child {
  margin-bottom: 0;
}

.publications {
  clear: both;
  margin: 1rem 0 1.75rem;
}

.publications h2 {
  margin-bottom: 0.2rem;
}

.publications > p {
  margin: 0 0 1rem;
}

.publication {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  column-gap: 1rem;
  row-gap: 0.3rem;
  margin: 0 0 1.1rem;
}

.publication p {
  margin: 0;
  line-height: 1.35;
}

.publication-title {
  display: block;
  margin-bottom: 0.15rem;
  color: var(--global-theme-color);
  font-weight: 600;
  line-height: 1.25;
}

.publication-title:hover {
  color: var(--global-hover-color);
  text-decoration: underline;
}

.publication p:last-child {
  align-self: center;
  white-space: nowrap;
  text-align: right;
  font-weight: 600;
}

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

  .publication p:last-child {
    align-self: start;
  }
}
