:root {
  --bg: #0b0b0c;
  --fg: #ecebe6;
  --muted: #85847f;
  --accent: #ff6a3d;
  --path: rgba(236, 235, 230, 0.085);
  --dist: rgba(236, 235, 230, 0.32);
  --rule: rgba(236, 235, 230, 0.14);
  --serif: "Instrument Serif", ui-serif, Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --pad: clamp(1.5rem, 7vw, 7rem);
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f5f3ec;
    --fg: #151514;
    --muted: #6d6c66;
    --accent: #d4471c;
    --path: rgba(21, 21, 20, 0.075);
    --dist: rgba(21, 21, 20, 0.3);
    --rule: rgba(21, 21, 20, 0.14);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
}

html {
  height: 100%;
}

body {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  /* Horizontal drags reach the page (to change sigma) while vertical scrolling still works. */
  touch-action: pan-y pinch-zoom;
  -webkit-tap-highlight-color: transparent;
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

#field,
.veil {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.veil {
  background: linear-gradient(
    90deg,
    var(--bg) 0%,
    color-mix(in srgb, var(--bg) 75%, transparent) 38%,
    transparent 72%
  );
}

main,
footer {
  position: relative;
  z-index: 1;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 48rem;
  padding: clamp(2rem, 7vh, 5rem) var(--pad);
}

.kicker {
  margin-bottom: 2rem;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.kicker sub {
  font-size: 0.75em;
}

h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3.5rem, 11vw, 7.5rem);
  line-height: 0.9;
  letter-spacing: -0.02em;
}

.role {
  margin-top: 1.25rem;
  color: var(--accent);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.bio {
  max-width: 36ch;
  margin-top: 2rem;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  line-height: 1.4;
}

.bio em {
  color: var(--muted);
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.75rem;
  margin-top: 2.5rem;
  padding: 0;
  list-style: none;
}

.links a {
  padding-bottom: 2px;
  border-bottom: 1px solid var(--rule);
  color: var(--fg);
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}

.links a span {
  display: inline-block;
  margin-left: 0.3em;
  transition: transform 0.2s;
}

.links a:hover,
.links a:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.links a:hover span,
.links a:focus-visible span {
  transform: translate(2px, -2px);
}

footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding: 1rem var(--pad);
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 11px;
}

.readout {
  font-variant-numeric: tabular-nums;
}

.hint-touch {
  display: none;
}

@media (hover: none) {
  .hint-pointer {
    display: none;
  }

  .hint-touch {
    display: inline;
  }
}

@media (max-width: 640px) {
  .veil {
    background: color-mix(in srgb, var(--bg) 55%, transparent);
  }
}

main > * {
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

main > :nth-child(2) { animation-delay: 0.08s; }
main > :nth-child(3) { animation-delay: 0.16s; }
main > :nth-child(4) { animation-delay: 0.24s; }
main > :nth-child(5) { animation-delay: 0.32s; }

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

@media (prefers-reduced-motion: reduce) {
  main > * {
    animation: none;
  }
}
