/* CV + Contact page */
:root {
  --background: #000000;
  --foreground: #ffffff;
  --muted: #a6a6a6;
  --rule: rgba(255, 255, 255, 0.24);
  --font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --page-gutter: clamp(24px, 5.1vw, 76px);
  --home-copy-size: clamp(19px, 2.9vw, 36px);
  --cv-body-size: clamp(16px, 1.25vw, 18px);
  --cv-role-size: clamp(15px, 1.12vw, 16px);
  --cv-date-size: clamp(13px, 1vw, 14px);
  --section-size: clamp(19px, 1.55vw, 22px);
  --regular: 400;
  --semibold: 600;
  --bold: 700;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  background: var(--background);
}

.cv-body {
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-family);
  font-weight: var(--regular);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.cv-page {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
  column-gap: clamp(34px, 5.2vw, 76px);
  width: 100%;
  height: 100vh;
  height: 100svh;
  padding: 0 var(--page-gutter);
  overflow: hidden;
  background: var(--background);
}

.contact-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: 100%;
  padding: 0;
}

.contact-content {
  width: min(76%, 420px);
  margin: 0 auto;
}

.profile-copy {
  width: min(100%, 420px);
  color: var(--foreground);
  font-size: var(--home-copy-size);
  font-weight: var(--bold);
  line-height: 1.2;
}

.identity-copy {
  width: 100%;
}

.profile-copy h1 {
  margin: 0;
  text-align: center;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  text-transform: lowercase;
}

.biography-wrap {
  width: 100%;
  margin: 1.2em auto 0;
}

.biography {
  width: 100%;
  margin: 0;
  font-style: normal;
  font-weight: var(--semibold);
  text-transform: lowercase;
  text-align: justify;
  text-align-last: justify;
  line-height: 1.2;
}

.hide-on-hover,
.preserve-word {
  display: inline;
}

.identity-copy:hover .hide-on-hover {
  color: #000000;
  text-decoration: none;
}

.email-link {
  display: block;
  width: 100%;
  margin-top: 1.7em;
  color: var(--foreground);
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cv-column {
  min-width: 0;
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 0 0 128px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.32) transparent;
}

.cv-content {
  width: min(100%, 760px);
  margin: 0 auto;
  padding-top: clamp(30px, 5vh, 58px);
}

.cv-section {
  margin: 0;
}

.section-title {
  margin: 0;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--rule);
  color: var(--foreground);
  font-size: var(--section-size);
  font-weight: var(--bold);
  line-height: 1.2;
}

.cv-entry {
  position: relative;
  display: grid;
  grid-template-columns: minmax(105px, 22%) minmax(0, 1fr);
  column-gap: clamp(8px, 0.9vw, 14px);
  padding: 15px 0;
}

.cv-entry::after {
  position: absolute;
  right: 18%;
  bottom: 0;
  left: 0;
  height: 1px;
  background: var(--rule);
  content: "";
}

.entry-date {
  color: var(--muted);
  font-size: var(--cv-date-size);
  line-height: 1.4;
}

.entry-details {
  min-width: 0;
}

.entry-organisation,
.entry-role {
  display: block;
  font-size: var(--cv-body-size);
  line-height: 1.28;
}

.entry-organisation {
  color: var(--foreground);
  font-weight: var(--bold);
}

.entry-link {
  color: var(--foreground);
  text-decoration: none;
}

.entry-link:hover,
.entry-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.entry-role {
  margin-top: 2px;
  color: var(--foreground);
  font-size: var(--cv-role-size);
}

.entry-action {
  display: inline-block;
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--cv-date-size);
  line-height: 1.3;
  text-decoration: none;
}

.entry-action:hover,
.entry-action:focus-visible {
  color: var(--foreground);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.education-section {
  margin-top: 36px;
}

.education-section .section-title {
  border-bottom: 0;
  padding-bottom: 6px;
}

.download-cv {
  display: inline-block;
  margin-top: 28px;
  padding-bottom: 3px;
  border-bottom: 1px solid currentColor;
  color: var(--foreground);
  font-size: var(--cv-body-size);
  font-weight: var(--regular);
  text-decoration: none;
}

.download-cv:hover,
.download-cv:focus-visible {
  color: var(--foreground);
}

.cv-footer {
  position: fixed;
  right: var(--page-gutter);
  bottom: 0;
  left: var(--page-gutter);
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0 5.1vh;
  pointer-events: none;
  color: var(--foreground);
  font-size: clamp(13px, 1.2vw, 17px);
  line-height: 1.2;
}

.cv-footer a {
  color: var(--foreground);
  pointer-events: auto;
  text-decoration: none;
}

.cv-footer a:hover,
.cv-footer a:focus-visible {
  color: var(--foreground);
}

@media (max-width: 1000px) {
  .cv-page {
    column-gap: clamp(22px, 3vw, 34px);
  }

  .contact-content {
    width: min(84%, 420px);
  }

  .profile-copy {
    font-size: clamp(19px, 2.5vw, 28px);
  }
}

@media (max-width: 760px) {
  .cv-body {
    overflow: auto;
  }

  .cv-page {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 100svh;
    padding: 0 var(--page-gutter);
    overflow: visible;
  }

  .contact-panel {
    min-height: auto;
    height: auto;
    padding: 9vh 0 64px;
  }

  .contact-content {
    width: min(100%, 420px);
  }

  .profile-copy {
    font-size: clamp(19px, 3.5vw, 28px);
  }

  .cv-column {
    height: auto;
    overflow: visible;
    padding-bottom: 48px;
  }

  .cv-content {
    padding-top: 0;
  }

  .cv-footer {
    position: relative;
    right: auto;
    left: auto;
    margin: 0 var(--page-gutter);
    padding: 20px 0 28px;
  }
}

@media (max-width: 460px) {
  .profile-copy {
    font-size: 19px;
  }

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