@font-face {
  font-family: "DM Mono";
  src: url("/assets/dm-mono-regular.074cc9762a6d849a.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --background: #243c78;
  --ink: #fffdf8;
  /* Interpolate the existing phone and desktop spacing from 390px to 1280px. */
  --fluid-step: clamp(0rem, (100vw - 24.375rem) / 55.625, 1rem);
  --text-name: clamp(3rem, 2.35rem + 5.36vw, 7rem);
  --text-role: clamp(1.125rem, 0.960675rem + 0.674157vw, 1.5rem);
  --text-bio: clamp(1rem, 0.945225rem + 0.224719vw, 1.125rem);
  --text-contact: var(--text-bio);
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

body {
  position: relative;
  isolation: isolate;
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding-block: calc(2.25rem + 2.25 * var(--fluid-step))
    calc(6.75rem + 0.25 * var(--fluid-step));
  padding-inline: calc(1.625rem + 3.975 * var(--fluid-step));
  background: var(--background);
  color: var(--ink);
  font-family: "DM Mono", monospace;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

.identity {
  position: relative;
  width: min(100%, 1040px);
  min-width: 0;
}

.contours {
  position: absolute;
  inset-block-start: 0;
  inset-inline-end: 0;
  z-index: -1;
  inline-size: clamp(24.375rem, 65vw, 60rem);
  max-inline-size: 100%;
  block-size: 100%;
  overflow: clip;
  opacity: 0.17;
  pointer-events: none;
}

.contours path {
  transform-origin: 350px 260px;
  vector-effect: non-scaling-stroke;
}

@media (prefers-reduced-motion: no-preference) {
  .contours path {
    animation: contour-flow 8s cubic-bezier(0.45, 0, 0.55, 1) infinite alternate;
    animation-delay: -2s;
  }

  .contours path:nth-child(2) { animation-delay: -2.65s; }
  .contours path:nth-child(3) { animation-delay: -3.3s; }
  .contours path:nth-child(4) { animation-delay: -3.95s; }
  .contours path:nth-child(5) { animation-delay: -4.6s; }
}

@keyframes contour-flow {
  from { transform: translate(-9px, -14px) rotate(-1deg); }
  to { transform: translate(11px, 14px) rotate(1deg); }
}

h1,
p {
  margin: 0;
  font-weight: 400;
}

h1 {
  font-size: var(--text-name);
  line-height: 1.04;
  letter-spacing: -0.065em;
  overflow-wrap: anywhere;
}

.role {
  margin-block-start: calc(1.25rem + 0.375 * var(--fluid-step));
  font-size: var(--text-role);
  line-height: 1.5;
}

.bio {
  max-inline-size: 60ch;
  margin-block-start: calc(1.75rem + 1.25 * var(--fluid-step));
  font-size: var(--text-bio);
  line-height: 1.65;
  text-wrap: pretty;
}

.contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px calc(1.75rem + 0.5 * var(--fluid-step));
  margin-block-start: calc(1.5rem + 0.625 * var(--fluid-step));
  font-size: var(--text-contact);
  line-height: 1.5;
}

a {
  color: inherit;
  text-underline-offset: 0.3em;
}

.contact a {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  min-height: 44px;
  padding: 7px 0;
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
}

@media (hover: hover) and (pointer: fine) {
  .contact a:hover {
    text-decoration-thickness: 2px;
  }
}

.contact a:active {
  text-decoration-thickness: 3px;
}

a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 7px;
}

::selection {
  background: var(--ink);
  color: var(--background);
}

@media (max-width: 760px) {
  body {
    place-items: start center;
  }
}
