:root {
  --page: #f2efe8;
  --surface: #f8f6f1;
  --ink: #17191e;
  --muted: #666a73;
  --line: #d7d1c6;
  --line-strong: #bbb4a8;
  --accent: #3157d5;
  --selection: #cdd7ff;
  --sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --page: #111318;
    --surface: #171a20;
    --ink: #f1efe9;
    --muted: #a3a6ad;
    --line: #2d3138;
    --line-strong: #454a54;
    --accent: #9db0ff;
    --selection: #334b9d;
  }
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.62;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration-color: color-mix(in srgb, var(--accent) 58%, transparent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--accent);
  text-decoration-color: currentColor;
}

a:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 70%, transparent);
  outline-offset: 4px;
  border-radius: 3px;
}

svg {
  display: block;
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.skip-link {
  position: fixed;
  z-index: 20;
  top: 1rem;
  left: 1rem;
  padding: 0.6rem 0.85rem;
  transform: translateY(-180%);
  border: 1px solid var(--line-strong);
  border-radius: 0.35rem;
  background: var(--surface);
  font-size: 0.85rem;
  font-weight: 750;
}

.skip-link:focus { transform: translateY(0); }

.site-shell {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 30px 0 28px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  min-height: 48px;
  margin-bottom: clamp(40px, 5.5vw, 70px);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.82rem;
  font-weight: 780;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: color-mix(in srgb, var(--surface) 74%, transparent);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
}

.header-links {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.header-links a { text-decoration: none; }

.hero {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(360px, 1fr);
  gap: clamp(56px, 8vw, 108px);
  align-items: center;
}

.portrait {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 0.4rem;
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(31, 31, 35, 0.1);
}

.portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid color-mix(in srgb, white 16%, transparent);
  border-radius: inherit;
  pointer-events: none;
}

.portrait picture,
.portrait img {
  display: block;
  width: 100%;
  height: 100%;
}

.portrait img {
  object-fit: cover;
  object-position: center center;
}

.intro { padding: 12px 0; }

.eyebrow {
  margin: 0 0 1.35rem;
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 820;
  letter-spacing: 0.16em;
  line-height: 1.3;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(4rem, 7.2vw, 6.45rem);
  font-weight: 850;
  letter-spacing: -0.030em;
  line-height: 0.9;
}

.role {
  max-width: 24rem;
  margin: 1.7rem 0 0;
  color: var(--muted);
  font-family: var(--serif);
  font-size: clamp(1.45rem, 2.5vw, 2rem);
  line-height: 1.22;
}

.bio {
  max-width: 42rem;
  margin-top: 2.1rem;
  padding-top: 1.65rem;
  border-top: 1px solid var(--line-strong);
}

.bio p {
  max-width: 48ch;
  margin: 0;
  color: var(--muted);
}

.bio p + p { margin-top: 0.75rem; }

.bio a {
  color: var(--ink);
  font-weight: 680;
}

.project-links {
  margin-top: 2rem;
  border-top: 1px solid var(--line);
}

.project-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.78rem 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.project-links a > span {
  display: flex;
  align-items: baseline;
  gap: 0.7rem;
}

.project-links strong {
  font-size: 0.95rem;
  font-weight: 790;
}

.project-links small {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 620;
}

.project-links svg {
  color: var(--muted);
  transition: transform 160ms ease;
}

.project-links a:hover svg { transform: translate(2px, -2px); }

.site-footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
  margin-top: clamp(46px, 7vw, 82px);
  padding-top: 22px;
  border-top: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 660;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1rem;
}

.footer-links > span {
  color: var(--ink);
  font-weight: 790;
}

.footer-links a { text-decoration: none; }
.footer-links small { font-size: 0.68em; letter-spacing: 0.06em; }
.site-footer p { margin: 0; white-space: nowrap; }

@media (max-width: 850px) {
  .site-shell {
    width: min(700px, calc(100% - 38px));
    padding-top: 24px;
  }

  .hero {
    grid-template-columns: minmax(250px, 0.8fr) minmax(320px, 1fr);
    gap: 48px;
  }

  h1 { font-size: clamp(3.5rem, 9vw, 5rem); }
  .role { font-size: clamp(1.25rem, 3.2vw, 1.65rem); }
}

@media (max-width: 680px) {
  body { font-size: 16px; }

  .site-shell {
    width: min(100% - 30px, 520px);
    padding-top: 18px;
  }

  .site-header {
    margin-bottom: 34px;
  }

  .wordmark > span:last-child { display: none; }

  .hero {
    grid-template-columns: 1fr;
    gap: 38px;
  }

  .portrait {
    width: 100%;
    max-height: min(122vw, 610px);
  }

  .intro { padding: 0; }
  .eyebrow { margin-bottom: 1rem; }

  h1 {
    font-size: clamp(4rem, 18vw, 5.75rem);
    line-height: 0.9;
  }

  .role {
    max-width: 21rem;
    margin-top: 1.4rem;
    font-size: clamp(1.45rem, 6vw, 1.8rem);
  }

  .bio {
    margin-top: 1.75rem;
    padding-top: 1.35rem;
  }

  .project-links { margin-top: 1.65rem; }
  .project-links a { padding: 0.82rem 0; }

  .site-footer {
    flex-direction: column;
    gap: 1rem;
    margin-top: 52px;
  }

  .site-footer p { order: 2; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media print {
  :root {
    --page: #fff;
    --surface: #fff;
    --ink: #000;
    --muted: #444;
    --line: #ccc;
    --line-strong: #999;
  }

  body { background: #fff; }
  .site-shell { width: 100%; padding: 0; }
  .header-links, .site-footer { display: none; }
  .hero { grid-template-columns: 42% 1fr; gap: 40px; }
}
