:root {
  --bg: #ffffff;
  --ink: #111111;
  --muted: #666666; /* 5.7:1 on white, passes WCAG AA */
  --line: #e6e6e6;
  --pill: #efefef;
  --pill-hover: #e2e2e2;
  --green: #74ff4a;
  --green-pale: #dcffcf;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --mono: "IBM Plex Mono", SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html,
body {
  height: 100%;
}
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.45;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
}
button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

/* ---------- chrome ---------- */
header {
  position: fixed;
  inset: 0 0 auto 0;
  height: 64px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  /* scrolled page text fades out behind the wordmark instead of overlapping it */
  background: linear-gradient(var(--bg) 75%, transparent);
}
.wordmark {
  font-family: var(--serif);
  font-size: 25px;
  letter-spacing: -0.02em;
  text-decoration: none;
  pointer-events: auto;
}
.pill {
  background: var(--pill);
  border-radius: 999px;
  padding: 5px 10px;
  font-family: var(--mono);
  font-size: 11px;
  transition: background 0.15s;
}
.pill:hover {
  background: var(--pill-hover);
}
#menuBtn {
  position: fixed;
  top: 16px;
  right: 20px;
  z-index: 40;
}

.switcher {
  position: fixed;
  left: 20px;
  bottom: 18px;
  z-index: 20;
  display: flex;
  gap: 10px;
}
.switcher button {
  padding: 2px 0;
  color: var(--ink);
}
.switcher button[aria-current="true"] {
  color: var(--muted);
}
#findBtn {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 20;
}
.clock {
  position: fixed;
  right: 20px;
  bottom: 18px;
  z-index: 20;
  color: var(--muted);
}

/* ---------- views ---------- */
.view {
  position: fixed;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.35s ease,
    visibility 0s linear 0.35s;
}
.view.active {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s ease;
}

/* [2] resume + [3] contact: scrolling document */
.doc {
  overflow-y: auto;
  padding: 110px 20px 90px;
}
.doc-inner {
  max-width: 760px;
  margin: 0 auto;
}
.doc h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 34px;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}
.doc .sub {
  color: var(--muted);
  margin-bottom: 40px;
}
.doc .sub a {
  color: var(--ink);
}
.section-label {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 36px 0 4px;
}
.row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 20px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.row .when {
  color: var(--muted);
}
.row h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 20px;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.row .role {
  margin: 2px 0 8px;
  color: var(--muted);
}
.row ul {
  list-style: none;
}
.row li {
  padding-left: 14px;
  position: relative;
  font-size: 12px;
}
.row li + li {
  margin-top: 4px;
}
.row li::before {
  content: "–";
  position: absolute;
  left: 0;
  color: var(--muted);
}
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tag {
  background: var(--pill);
  border-radius: 999px;
  padding: 3px 9px;
}

.contact-list {
  border-bottom: 1px solid var(--line);
}
.contact-list a {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  gap: 20px;
  align-items: baseline;
  padding: 18px 0;
  border-top: 1px solid var(--line);
  text-decoration: none;
}
.contact-list a .v {
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 34px);
  letter-spacing: -0.02em;
  line-height: 1.1;
  word-break: break-word;
}
.contact-list a .arr {
  color: var(--muted);
  transition:
    transform 0.2s,
    color 0.2s;
}
.contact-list a:hover .arr {
  transform: translate(3px, -3px);
  color: var(--ink);
}
.contact-list a:hover .v {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}
.contact-list .k {
  color: var(--muted);
}

/* ---------- menu overlay ---------- */
.menu {
  position: fixed;
  inset: 0;
  z-index: 30;
  pointer-events: none;
}
.menu .sheet {
  position: absolute;
  inset: 0 0 auto 0;
  background: var(--bg);
  padding: 20px;
  min-height: 290px;
  transform: translateY(-100%);
  transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.1, 1);
  display: flex;
  justify-content: space-between;
}
.menu .scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.08);
  opacity: 0;
  transition: opacity 0.3s;
}
.menu.open {
  pointer-events: auto;
}
.menu.open .sheet {
  transform: none;
}
.menu.open .scrim {
  opacity: 1;
}
.mark {
  width: 22px;
  height: 22px;
}
.menu nav {
  margin-right: 60px;
  font-family: var(--serif);
  font-size: 15px;
}
.menu nav > div + div {
  margin-top: 16px;
}
.menu nav a,
.menu nav button {
  text-decoration: none;
  display: block;
  font-family: var(--serif);
  font-size: 15px;
  text-align: left;
}
.menu nav .child {
  padding-left: 18px;
}
.menu nav a:hover,
.menu nav button:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- detail panel ---------- */
.panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(460px, 100%);
  z-index: 35;
  background: var(--bg);
  border-left: 1px solid var(--line);
  transform: translateX(100%);
  transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.1, 1);
  padding: 64px 28px 40px;
  overflow-y: auto;
}
.panel.open {
  transform: none;
}
.panel .close {
  position: absolute;
  top: 16px;
  right: 70px;
}
.panel canvas {
  width: 100%;
  height: auto;
  aspect-ratio: 31/28;
  display: block;
  margin-bottom: 22px;
  background: var(--green-pale);
}
.panel .meta {
  color: var(--muted);
}
.panel h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 30px;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 6px 0 16px;
}
.panel p {
  font-size: 12px;
}
.panel ul {
  list-style: none;
  margin-top: 14px;
}
.panel li {
  padding: 10px 0;
  border-top: 1px solid var(--line);
  font-size: 12px;
}
.panel .tags {
  margin-top: 18px;
}

/* ---------- find palette ---------- */
.find {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding-top: 18vh;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.find.open {
  display: flex;
}
.find .box {
  width: min(520px, calc(100% - 32px));
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}
.find input {
  width: 100%;
  border: 0;
  outline: 0;
  padding: 16px 18px;
  font-family: var(--serif);
  font-size: 20px;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
}
.find ol {
  list-style: none;
  max-height: 50vh;
  overflow-y: auto;
  padding: 6px;
}
.find li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-radius: 6px;
  cursor: pointer;
}
.find li .t {
  color: var(--muted);
  flex: none;
}
.find li.sel {
  background: var(--pill);
}
.find .empty {
  padding: 14px 18px;
  color: var(--muted);
}

.contact-layout {
  max-width: 920px;
}
/* photo under the heading, contact links beside it (stacked on phones) */
.contact-body {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  align-items: start;
}
.contact-body > .contact-list {
  min-width: 0;
}
.portrait {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

@media (max-width: 640px) {
  .globe-callout .contact-body {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .portrait {
    width: 160px;
  }
  .row,
  .contact-list a {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .contact-list a .arr {
    display: none;
  }
  .clock {
    display: none;
  }
  .legend {
    bottom: 50px;
  }
  .menu nav {
    margin-right: 44px;
  }
  #findBtn {
    left: auto;
    right: 20px;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition-duration: 0s !important;
  }
}

.plain {
  text-decoration: none;
}
.body-text {
  font-size: 12px;
}

/* [1] home: headline + globe */
.legend {
  position: absolute;
  left: 20px;
  bottom: 52px;
  max-width: 280px;
  z-index: 1;
}
.legend p + p {
  margin-top: 10px;
}
#globe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}
#globe:active {
  cursor: grabbing;
}
.globe-callout {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  max-width: min(520px, calc(100vw - 32px));
  background: rgba(255, 255, 255, 0.85);
  padding: 2px 0;
}
.globe-callout div:first-child {
  color: var(--muted);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.intro {
  position: absolute;
  top: 76px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 32px);
  max-width: 640px;
  text-align: center;
  pointer-events: none;
  z-index: 1;
}
.intro h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(24px, 3.6vw, 36px);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.menu-label {
  font-family: var(--serif);
  font-size: 15px;
  color: var(--muted);
}

/* scrollable pages are focusable for keyboard scrolling; only show a ring for keyboard focus */
.doc:focus {
  outline: none;
}
.doc:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: -2px;
}
