/* This stylesheet deliberately scopes every selector below the existing hero. */
.profile-document {
  --document-paper: #fff;
  --document-ink: #34384c;
  --document-muted: #555e70;
  --document-line: #dfe4ee;
  --document-accent: var(--color-blue);
  color-scheme: light;
  background: var(--document-paper);
  color: var(--document-ink);
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
}
.profile-document .document-container {
  width: min(100%, 760px);
  margin-inline: auto;
  padding-inline: 32px;
}
.profile-document main.document-container {
  padding-top: 112px;
  padding-bottom: 104px;
}
.profile-document .profile-section {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 28px;
  scroll-margin-top: 56px;
}
.profile-document .document-label {
  margin: 0;
  padding-top: 3px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 17px;
  font-weight: 400;
  font-style: italic;
  line-height: 1.6;
  color: var(--document-ink);
}
.profile-document .document-body {
  min-width: 0;
}
.profile-document .document-body > p {
  margin: 0 0 22px;
}
.profile-document .document-body > p:last-child {
  margin-bottom: 0;
}
.profile-document .document-intro {
  margin-bottom: 28px !important;
  text-wrap: balance;
  font-size: 30px;
  font-weight: 400;
  letter-spacing: normal;
  line-height: 1.6;
}
.profile-document .document-intro em {
  color: var(--document-accent);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1em;
  font-weight: 400;
}
.profile-document .document-inline-link {
  color: var(--document-accent);
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 4px;
  transition: text-decoration-color var(--uscode-motion-duration-fast);
}
.profile-document .document-inline-link:hover {
  text-decoration-color: currentColor;
}
.profile-document .stack-groups {
  margin: 0;
}
.profile-document .stack-group {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  align-items: baseline;
  column-gap: 16px;
}
.profile-document .stack-group + .stack-group {
  margin-top: 12px;
}
.profile-document .stack-group dt {
  color: var(--document-muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
}
.profile-document .stack-group dd {
  min-width: 0;
  margin: 0;
}
.profile-document .stack-items {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--document-ink);
  font-size: 15px;
  line-height: 1.6;
}
.profile-document .stack-items li {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
}
.profile-document .stack-separator {
  margin-inline: 8px;
  color: #b7c0d0;
}
.profile-document .document-stack,
.profile-document .document-experience,
.profile-document .document-teaching {
  margin-top: 96px;
}
.profile-document .document-experience-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.profile-document .experience-item + .experience-item {
  margin-top: 27px;
}
.profile-document .experience-company {
  margin: 0 0 5px;
  color: var(--document-ink);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.6;
}
.profile-document .experience-company a {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  color: inherit;
  text-decoration: none;
  transition: color var(--uscode-motion-duration-fast);
}
.profile-document .experience-company-name {
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 4px;
  transition: text-decoration-color var(--uscode-motion-duration-fast);
}
.profile-document .experience-company a:hover,
.profile-document .experience-company a:focus-visible {
  color: var(--document-accent);
}
.profile-document .experience-company a:hover .experience-company-name,
.profile-document .experience-company a:focus-visible .experience-company-name {
  text-decoration-color: currentColor;
}
.profile-document .experience-company .link-arrow {
  color: inherit;
  font-size: 12px;
}
.profile-document .experience-line {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.profile-document .experience-role {
  min-width: 0;
  color: var(--document-ink);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
}
.profile-document .experience-period {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 5px;
  padding: 2px 10px;
  border: 1px solid var(--document-line);
  border-radius: 999px;
  color: var(--document-ink);
  font-size: 14px;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  line-height: 1.45;
  white-space: nowrap;
}
.profile-document .experience-period.is-current {
  border-color: transparent;
}
.profile-document .experience-status-dot {
  width: 5px;
  height: 5px;
  margin-right: 2px;
  border-radius: 50%;
  background: var(--document-accent);
}
.profile-document .experience-line .document-rule {
  transform: translateY(1px);
}
.profile-document .document-rule {
  display: block;
  flex: 1 1 25px;
  min-width: 16px;
  height: 1px;
  background: var(--document-line);
}
.profile-document .document-code {
  margin-top: 105px;
}
.profile-document .document-code-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 25px;
}
.profile-document .document-code-heading .document-label {
  padding: 0;
}
.profile-document .link-arrow {
  display: inline-block;
  flex-shrink: 0;
  width: 0.85em;
  height: 0.85em;
  vertical-align: baseline;
  color: var(--document-accent);
  transition: transform var(--uscode-motion-duration-fast)
    var(--uscode-motion-ease-out);
}
.profile-document .link-arrow::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  background: currentColor;
  mask: url("assets/icons/arrow-right.svg") center / contain no-repeat;
  transform: rotate(-45deg);
}
.profile-document .contribution-grid {
  display: grid;
  grid-template-rows: repeat(7, minmax(0, 1fr));
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 4px;
  width: 100%;
}
.profile-document .contribution-day {
  display: block;
  position: relative;
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  aspect-ratio: 1;
  border-radius: 3px;
  background: #e8ebf0;
  box-shadow: inset 0 0 0 1px rgb(52 56 76 / 4%);
  transition: background var(--uscode-motion-duration-press);
}
.profile-document .contribution-day[data-level="1"] {
  background: #d0ddff;
}
.profile-document .contribution-day[data-level="2"] {
  background: #98b7ff;
}
.profile-document .contribution-day[data-level="3"] {
  background: #5b88f9;
}
.profile-document .contribution-day[data-level="4"] {
  background: var(--document-accent);
}
.profile-document .contribution-day[data-level="none"] {
  background: transparent;
  box-shadow: none;
  pointer-events: none;
}
.profile-document .contribution-day:is(:hover, :focus-visible) {
  outline: 2px solid var(--document-ink);
  outline-offset: 1px;
  z-index: 1;
}
.profile-document .activity-scroll {
  overflow: visible;
  padding: 3px 0 8px;
}
.profile-document .activity-calendar {
  position: relative;
  width: 100%;
}
.profile-document .activity-error {
  margin: 0;
  color: var(--document-muted);
  font-size: 14px;
  line-height: 1.7;
}
.profile-document .activity-tooltip {
  position: fixed;
  z-index: 20;
  max-width: calc(100vw - 20px);
  padding: 8px 11px;
  border-radius: 7px;
  background: var(--document-ink);
  color: #fff;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  line-height: 1.5;
  pointer-events: none;
  box-shadow: 0 4px 12px rgb(0 0 0 / 8%);
}
.profile-document .activity-tooltip[hidden] {
  display: none;
}
.profile-document .document-code-bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-top: 20px;
}
.profile-document .document-branch {
  display: block;
  width: min(48%, 360px);
  height: auto;
  color: #78a0ff;
}
.profile-document .document-profile-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  margin-left: auto;
  color: var(--document-ink);
  font-size: 16px;
  font-weight: 400;
  white-space: nowrap;
  transition: color var(--uscode-motion-duration-fast);
}
.profile-document .document-profile-link:hover {
  color: var(--document-accent);
}
.profile-document .profile-contact {
  padding-top: 65px;
  padding-bottom: 34px;
  background: var(--document-accent);
  color: #fff;
}
.profile-document .profile-contact .document-label {
  display: flex;
  align-items: center;
  align-self: start;
  min-height: 48px;
  padding-top: 0;
  color: #fff;
}
.profile-document .document-contact-rows {
  margin-top: 0;
}
.profile-document .document-contact-row {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 48px;
  font-size: 16px;
  color: #fff;
  transition: color var(--uscode-motion-duration-fast);
}
.profile-document .document-contact-row > span:first-child {
  flex-shrink: 0;
}
.profile-document .document-contact-row > span:last-child {
  flex-shrink: 0;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 4px;
  transition: text-decoration-color var(--uscode-motion-duration-fast);
}
.profile-document .document-contact-row .document-rule {
  background: rgb(255 255 255 / 32%);
  transform: translateY(1px);
}
.profile-document
  .document-contact-row:is(:hover, :focus-visible)
  > span:last-child {
  text-decoration-color: currentColor;
}
.profile-document .profile-contact :focus-visible {
  outline-color: #fff;
}
.profile-document .document-footer {
  --footer-inset: clamp(24px, 4.1vw, 72px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 74px;
  padding-top: 23px;
  position: relative;
  color: #fff;
  font-size: 13px;
  line-height: 1.6;
}
.profile-document .document-footer p {
  margin: 0;
}
.profile-document footer.document-container {
  width: 100%;
  padding-inline: var(--footer-inset);
}
@media (hover: hover) and (pointer: fine) {
  .profile-document .contribution-day:not([data-level="none"]):hover {
    background: #a7c1ff;
  }
}
@media (max-width: 700px) {
  .profile-document .document-container {
    padding-inline: 26px;
  }
  .profile-document .profile-section {
    grid-template-columns: 102px minmax(0, 1fr);
    gap: 24px;
  }
  .profile-document main.document-container {
    padding-top: 80px;
    padding-bottom: 80px;
  }
  .profile-document .document-intro {
    font-size: 27px;
  }
  .profile-document .experience-line {
    flex-wrap: wrap;
    gap: 7px;
  }
  .profile-document .experience-role {
    flex-basis: 100%;
  }
  .profile-document .experience-line .document-rule {
    display: none;
  }
}
@media (max-width: 540px) {
  .profile-document .stack-group {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 4px;
  }
  .profile-document .stack-group + .stack-group {
    margin-top: 14px;
  }
  .profile-document {
    font-size: 16px;
  }
  .profile-document .document-container {
    padding-inline: 24px;
  }
  .profile-document main.document-container {
    padding-top: 54px;
    padding-bottom: 64px;
  }
  .profile-document .profile-section {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
    scroll-margin-top: 30px;
  }
  .profile-document .document-label {
    font-size: 16px;
    padding: 0;
  }
  .profile-document .document-intro {
    font-size: 28px;
    margin-bottom: 24px !important;
  }
  .profile-document .document-body > p {
    line-height: 1.6;
  }
  .profile-document .document-stack,
  .profile-document .document-experience,
  .profile-document .document-teaching {
    margin-top: 64px;
  }
  .profile-document .experience-line {
    flex-wrap: wrap;
    gap: 7px;
  }
  .profile-document .experience-role {
    flex-basis: 100%;
    font-size: 16px;
  }
  .profile-document .experience-line .document-rule {
    display: none;
  }
  .profile-document .experience-item + .experience-item {
    margin-top: 25px;
  }
  .profile-document .document-code {
    margin-top: 64px;
  }
  .profile-document .document-code-heading {
    gap: 12px;
    margin-bottom: 20px;
  }
  .profile-document .document-code-heading .document-label {
    font-size: 16px;
  }
  .profile-document .contribution-grid {
    gap: 2px;
  }
  .profile-document .contribution-day {
    border-radius: 1.5px;
  }
  .profile-document .document-code-bottom {
    flex-direction: column;
    gap: 13px;
    margin-top: 14px;
  }
  .profile-document .document-branch {
    width: 73%;
    max-width: 260px;
  }
  .profile-document .document-profile-link {
    align-self: flex-end;
    font-size: 16px;
  }
  .profile-document .profile-contact {
    padding-top: 44px;
    padding-bottom: 26px;
  }
  .profile-document .profile-contact .document-label {
    min-height: 0;
  }
  .profile-document .document-contact-row {
    font-size: 16px;
    gap: 8px;
  }
  .profile-document .document-contact-row .document-rule {
    min-width: 10px;
  }
  .profile-document .document-footer {
    margin-top: 50px;
    padding-top: 21px;
    gap: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .profile-document .link-arrow {
    transition: none;
    transform: none !important;
  }
}
