@font-face {
  font-family: Inter;
  src: url("./assets/inter.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Masthead JP";
  src: url("./assets/display-jp.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Masthead KR";
  src: url("./assets/display-kr.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Masthead TC";
  src: url("./assets/display-tc.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Masthead Arabic";
  src: url("./assets/display-ar.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: light;
  --frame: #e8e3db;
  --paper: #f8f5ef;
  --card: #fffdf9;
  --ink: #26251e;
  --body: #45433a;
  --muted: #635e55;
  --accent: #8b482f;
  --line: #dcd6cb;
  --display: "STIX Two Text", Didot, Baskerville, "Times New Roman", serif;
  --edge: clamp(.5rem, 1.45vw, 1.8rem);
  --gutter: clamp(1.1rem, 4.9vw, 5.8rem);
  font: 100%/1.5 Inter, system-ui, sans-serif;
  color: var(--ink);
  background: var(--frame);
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; padding: var(--edge); }
.paper { min-height: calc(100vh - 2 * var(--edge)); min-height: calc(100svh - 2 * var(--edge)); background: var(--paper); }
.shell { width: min(92rem, calc(100% - 2 * var(--gutter))); margin-inline: auto; }
a { color: inherit; text-decoration: none; }
a, select, button { -webkit-tap-highlight-color: transparent; }
button, select { color: inherit; font: inherit; }
button { cursor: pointer; }
a:focus-visible, button:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only, .skip-link:not(:focus) {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); margin: -1px; white-space: nowrap;
}
.skip-link:focus { position: fixed; z-index: 5; inset: .75rem auto auto .75rem; padding: .5rem 1rem; background: var(--card); }

.site-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: clamp(4.4rem, 9vh, 6.3rem); }
.brand { display: inline-flex; align-items: center; gap: .35rem; font: 400 clamp(1.24rem, 1.8vw, 1.76rem)/1 var(--display); letter-spacing: -.055em; }
.brand-home { display: inline-flex; align-items: center; min-height: 44px; }
.domain-end { color: var(--muted); }
.mascot { position: relative; display: grid; place-items: center; flex: none; width: 48px; height: 48px; padding: 0; border: 0; border-radius: 6px; background: transparent; touch-action: manipulation; }
.mascot:disabled { cursor: default; }
.mascot-sprite {
  position: relative; display: block; width: 100%; height: 100%; pointer-events: none;
  background: url("./assets/hamster-faces.png") 0 0 / 400% 200% no-repeat;
  image-rendering: pixelated;
}
/* The first cell is the stationary body. The others contain only facial details. */
.mascot[data-face] .mascot-sprite::after { content: ""; position: absolute; inset: 0; background: inherit; }
.mascot[data-face="blink"] .mascot-sprite::after { background-position: calc(100% / 3) 0; }
.mascot[data-face="wink"] .mascot-sprite::after { background-position: calc(200% / 3) 0; }
.mascot[data-face="rosy"] .mascot-sprite::after { background-position: 100% 0; }
.mascot[data-face="blush"] .mascot-sprite::after { background-position: 0 100%; }
.mascot[data-face="hearts"] .mascot-sprite::after { background-position: calc(100% / 3) 100%; }
.mascot[data-face="glance"] .mascot-sprite::after { background-position: calc(200% / 3) 100%; }
.mascot[data-face="tongue"] .mascot-sprite::after { background-position: 100% 100%; }

.site-header nav { display: flex; align-items: center; gap: clamp(1.1rem, 3vw, 3.3rem); }
.site-header nav a { display: inline-flex; align-items: center; min-height: 44px; white-space: nowrap; font-size: clamp(.8rem, .95vw, .94rem); }
.site-header nav a:hover, .site-header nav a[aria-current], .archive-link:hover, .inside-links a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: .35em; }

.intro {
  display: grid;
  grid-template-columns: minmax(0, .87fr) minmax(0, 1.13fr);
  align-items: center;
  gap: clamp(.8rem, 2.2vw, 2.5rem);
  min-height: clamp(21rem, 55vh, 43rem);
  padding-block: clamp(1rem, 1.3vw, 1.6rem) clamp(1.2rem, 2vw, 2.15rem);
}
.intro-copy { min-width: 0; padding-bottom: .55rem; }
.publication { margin: 0 0 .36rem .14rem; color: var(--accent); font-size: .7rem; font-weight: 590; letter-spacing: .16em; text-transform: uppercase; }
.wordmark { margin: 0; font: 400 clamp(5.1rem, 9.3vw, 11rem)/1.04 var(--display); letter-spacing: -.057em; }
.word-window { display: block; position: relative; overflow: hidden; height: 1.25em; width: 100%; }
.word-face { position: absolute; inset: 0; display: flex; align-items: center; justify-content: start; letter-spacing: -.057em; }
.word-face:not([style]) { font-size: .9em; }
.word-ink { display: inline-block; flex: none; white-space: nowrap; padding: 0 .035em .025em .008em; }
.word-face[lang="ja"] { font-family: "Masthead JP", sans-serif; }
.word-face[lang="ko"] { font-family: "Masthead KR", sans-serif; }
.word-face[lang="zh-Hant"] { font-family: "Masthead TC", sans-serif; }
.word-face[lang="ar"] { font-family: "Masthead Arabic", serif; line-height: 1.34; letter-spacing: normal; }
.word-face.east { font-weight: 700; letter-spacing: -.07em; }
.word-face.leaving .word-ink { animation: word-leaves 380ms cubic-bezier(.45,.04,.75,.48) both; }
.word-face.arriving .word-ink { animation: word-arrives 405ms cubic-bezier(.22,.64,.22,1) both; }
@keyframes word-leaves {
  0% { transform: translate(0, 0); opacity: 1; clip-path: inset(-12% 0 -10% 0); }
  80%, 100% { transform: translate(-.045em, -.53em); opacity: 0; clip-path: inset(0 0 74% 0); }
}
@keyframes word-arrives {
  0%, 10% { transform: translate(.05em, .53em); opacity: 0; clip-path: inset(68% 0 0 0); }
  100% { transform: translate(0, 0); opacity: 1; clip-path: inset(-12% 0 -10% 0); }
}
.intro-deck { max-width: 30ch; margin: .2rem 0 0 .12rem; color: var(--body); font-size: clamp(1rem, 1.3vw, 1.28rem); line-height: 1.5; letter-spacing: -.022em; }
.intro-deck p { margin: 0; }
.intro-deck .intro-greeting { block-size: 1.5em; margin-bottom: .6em; white-space: nowrap; }
.word-tools { display: inline-flex; align-items: center; gap: .15rem; color: var(--muted); margin: clamp(.55rem, 1.35vw, 1.3rem) 0 0 .12rem; }
.language { display: inline-flex; align-items: center; gap: .42rem; position: relative; }
.globe { width: 13px; height: 13px; border: 1px solid currentColor; border-radius: 50%; display: inline-block; position: relative; }
.globe::before, .globe::after { content: ""; position: absolute; }
.globe::before { inset: -1px 2.7px; border: 1px solid currentColor; border-radius: 50%; }
.globe::after { height: 1px; background: currentColor; left: 0; right: 0; top: calc(50% - .5px); }
.language select { appearance: none; background: transparent; border: 0; border-radius: 0; cursor: pointer; font-size: .78rem; padding: .4rem .95rem .4rem .12rem; min-height: 44px; }
.language select option { color: var(--ink); background: var(--card); }
.language::after { content: ""; position: absolute; right: .22rem; top: calc(50% - 4px); width: 5px; height: 5px; transform: rotate(45deg); border: solid currentColor; border-width: 0 1px 1px 0; pointer-events: none; }
.playback { position: relative; display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; background: none; padding: 0; }
.playback::before { content: ""; position: absolute; left: .22rem; height: 11px; width: 1px; background: var(--line); }
.playback:hover, .language:hover { color: var(--accent); }
.transport-icon { display: block; width: 7px; height: 9px; border-inline: 2px solid currentColor; }
.playback.stopped .transport-icon { width: 8px; height: 9px; border: 0; background: currentColor; clip-path: polygon(0 0,100% 50%,0 100%); }

.atlas { display: grid; justify-self: end; justify-items: end; margin: 0; min-width: 0; width: 100%; }
.city-art { display: block; width: auto; max-width: 100%; height: auto; max-height: clamp(16rem, 47vh, 36rem); object-fit: contain; }
.atlas figcaption { margin: .3rem .3rem 0 0; color: var(--muted); font: italic .92rem/1.35 var(--display); }

.work-strip { display: grid; grid-template-columns: minmax(8rem, .72fr) minmax(0, 4fr); gap: clamp(.8rem, 1.35vw, 1.6rem); padding-block: clamp(.8rem, 1.25vw, 1.5rem); margin-bottom: 0; border-block: 1px solid var(--line); scroll-margin-block: 1rem; }
main.shell:has(.work-strip) { padding-bottom: clamp(2rem, 5.5vh, 5rem); }
.strip-heading { display: flex; flex-direction: column; justify-content: center; align-items: start; gap: .65rem; border-right: 1px solid var(--line); padding-right: .7rem; }
.strip-heading h2 { margin: 0; font: 400 clamp(1.8rem, 2.8vw, 3.05rem)/.99 var(--display); letter-spacing: -.055em; }
.strip-heading h2 span { display: block; }
.archive-link { display: inline-flex; align-items: center; gap: .35rem; min-height: 32px; color: var(--muted); font-size: .74rem; }
.work-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(.55rem, 1.05vw, 1.25rem); }
.work-cards li { display: flex; min-width: 0; }
.work-card { display: flex; flex-flow: column; align-items: start; width: 100%; background: var(--card); padding: clamp(.72rem, 1.2vw, 1.45rem); }
.work-card img { display: block; align-self: center; width: 100%; height: clamp(3.25rem, 8vh, 6.4rem); object-fit: contain; margin: .05rem 0 clamp(.56rem, 1.05vw, 1rem); }
.work-type { color: var(--muted); font-size: .7rem; line-height: 1.35; letter-spacing: .01em; }
.work-card h3 { margin: .27rem 0 0; font: 400 clamp(1.03rem, 1.44vw, 1.48rem)/1.1 var(--display); letter-spacing: -.028em; text-wrap: pretty; }
.work-card:hover h3, .work-card:focus-visible h3 { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .16em; }

.inside { padding-block: clamp(3.5rem, 10vh, 8rem) 5rem; display: grid; grid-template-columns: minmax(0,.82fr) minmax(0,1.18fr); align-items: baseline; gap: clamp(2rem, 6vw, 7rem); }
.inside h1 { margin: 0; font: 400 clamp(4.4rem, 8.5vw, 9.75rem)/.95 var(--display); letter-spacing: -.058em; }
.inside-text { max-width: 37rem; }
.inside-text p { margin: 0 0 1.3em; color: var(--body); font-size: clamp(1.03rem, 1.42vw, 1.32rem); line-height: 1.55; }
.inside-text p a { color: var(--accent); text-decoration: underline; text-underline-offset: .18em; }
.inside-links { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; }
.inside-links a { display: inline-block; padding-block: .55rem; font-size: .86rem; text-decoration: underline; text-underline-offset: .36em; }

.altruism-page { row-gap: clamp(2rem, 4vw, 4rem); }
.altruism-page hgroup { min-width: 0; margin: 0; }
.altruism-subtitle { margin: .8rem 0 0; color: var(--muted); font: italic clamp(1.15rem, 1.8vw, 1.6rem)/1.35 var(--display); text-wrap: balance; }
.altruism-page .inside-text p:last-child { margin-bottom: 0; }
.charity-section { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; align-items: start; row-gap: 1.4rem; padding-top: clamp(1.4rem, 3vw, 2.8rem); border-top: 1px solid var(--line); }
.charity-section h2 { margin: 0; max-width: 16ch; font: 400 clamp(1.9rem, 3.5vw, 3.5rem)/1.06 var(--display); letter-spacing: -.04em; text-wrap: balance; }
.charity-list { max-width: 37rem; list-style: none; margin: 0; padding: 0; }
.charity-list li + li { border-top: 1px solid var(--line); }
.charity-list a { display: block; padding-block: .9rem; }
.charity-list li:first-child a { padding-top: 0; }
.charity-name { color: var(--accent); font: 400 clamp(1.3rem, 1.8vw, 1.65rem)/1.2 var(--display); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .16em; }
.charity-description { display: block; margin-top: .3rem; color: var(--body); font-size: 1rem; line-height: 1.5; }
.charity-list a:hover .charity-name, .charity-list a:focus-visible .charity-name { color: var(--ink); }


#greeting { color: var(--accent); }
.competencies { padding-block: clamp(2rem, 6vw, 6rem) 5rem; }
.competencies h1 { margin: 0; font: 400 clamp(3rem, 7.6vw, 8rem)/1.03 var(--display); letter-spacing: -.055em; }
.credential { display: flex; align-items: center; gap: .7rem; margin: 1.25rem 0 0; color: var(--accent); font: 400 clamp(1.2rem, 1.9vw, 1.8rem)/1.35 var(--display); }
.credential::before { content: ""; width: 2rem; border-top: 1px solid currentColor; }
.competency-groups { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: clamp(1.2rem, 3.4vw, 4rem); margin: clamp(1.5rem, 3vw, 3rem) 0 clamp(2rem, 5vw, 5rem); }
.competency-groups section { border-top: 1px solid var(--line); padding-top: 1.1rem; }
.competency-groups h2, .writing-sample h2 { margin: 0; font: 400 clamp(1.65rem, 2.5vw, 2.6rem)/1.12 var(--display); letter-spacing: -.037em; }
.competency-groups p { max-width: 35ch; color: var(--body); font-size: 1rem; line-height: 1.58; }
.writing-sample { padding-top: 1.35rem; border-top: 1px solid var(--line); }
.sample-link { display: inline-flex; align-items: center; gap: .9rem; margin-top: .65rem; min-height: 44px; color: var(--body); font-size: 1rem; }
.sample-link small, .sample-hint, .sample-form label span { color: var(--muted); font-size: .84rem; }
.sample-link span { text-decoration: underline; text-underline-offset: .24em; text-decoration-thickness: 1px; }
.sample-link:hover { color: var(--accent); }
.sample-editor { margin-top: .5rem; color: var(--body); }
.sample-editor summary { cursor: pointer; width: fit-content; padding-block: .52rem; }
.sample-editor summary:hover { color: var(--accent); }
.sample-editor summary:focus-visible, .sample-form input:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.sample-form { display: grid; justify-items: start; gap: .45rem; max-width: 27rem; margin: .55rem 0 .25rem; }
.sample-form label { font-size: .9rem; font-weight: 550; }
.sample-form input { min-width: 0; width: 100%; font: inherit; color: var(--ink); }
.sample-form input[type="text"] { padding: .55rem .7rem; background: var(--card); border: 1px solid var(--line); }
.sample-form input::file-selector-button { margin-right: .65rem; padding: .48rem .65rem; background: var(--card); border: 1px solid var(--line); color: var(--ink); font: inherit; cursor: pointer; }
.sample-form button { border: 1px solid var(--ink); background: var(--ink); color: var(--card); padding: .55rem 1rem; min-height: 44px; margin-top: .4rem; }
.sample-hint { margin: 0 0 .45rem; }
.sample-error, .sample-feedback { font-size: .94rem; margin-block: .65rem; }
.sample-error { color: var(--accent); }

@media (min-width: 43.81rem) and (max-width: 62rem) {
  :root { --gutter: 2rem; }
  .work-strip { grid-template-columns: 6.6rem minmax(0, 1fr); }
  .work-card { padding: .72rem; }
  .work-type { font-size: .66rem; }
  .strip-heading h2 { font-size: 1.7rem; }
}
@media (max-width: 43.8rem) {
  :root { --edge: clamp(.38rem, 1.3vw, .62rem); --gutter: clamp(1rem, 4.4vw, 2rem); }
  .site-header { min-height: 3.9rem; gap: .75rem; }
  .site-header nav { gap: clamp(.7rem, 2.9vw, 1.4rem); }
  .site-header nav a { font-size: .8rem; }
  .brand { font-size: 1.25rem; gap: .32rem; }
  .intro { grid-template-columns: 1fr; min-height: 0; gap: .1rem; padding-block: clamp(1.45rem, 5.2vw, 2.5rem) clamp(1.15rem, 3.8vw, 1.7rem); }
  .intro-copy { padding: 0; }
  .publication { margin-bottom: .07rem; font-size: .64rem; }
  .wordmark { font-size: clamp(4.4rem, 16.8vw, 7.6rem); }
  .intro-deck { font-size: 1rem; margin-top: .1rem; }
  .word-tools { margin-top: .15rem; }
  .atlas { justify-self: center; width: min(100%, 31rem); }
  .city-art { width: 100%; max-height: none; }
  .atlas figcaption { font-size: .82rem; margin-top: .15rem; }
  .work-strip { grid-template-columns: 1fr; gap: .75rem; padding-block: .65rem .9rem; }
  .strip-heading { flex-direction: row; justify-content: space-between; align-items: center; border: 0; padding: 0; gap: .75rem; }
  .strip-heading h2 { font-size: clamp(1.55rem, 4.6vw, 2.1rem); line-height: 1.15; }
  .strip-heading h2 span { display: inline; }
  .work-cards { grid-template-columns: repeat(2, minmax(0,1fr)); gap: .6rem; }
  .work-card { padding: .8rem .85rem .95rem; }
  .work-card img { height: clamp(3.25rem, 14vw, 5.5rem); margin-bottom: .55rem; }
  .work-card h3 { font-size: clamp(1.07rem, 3.75vw, 1.4rem); }
  .inside { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 28rem) {
  .site-header nav { gap: clamp(.55rem, 2.15vw, .72rem); }
}
@media (max-width: 24rem) {
  .site-header nav a { white-space: normal; line-height: 1.2; text-wrap: balance; }
}
@media (max-width: 21.5rem) {
  .site-header { gap: .35rem; }
  .site-header nav { column-gap: .48rem; }
  .work-card { padding: .67rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .word-face.leaving .word-ink, .word-face.arriving .word-ink { animation: none; }
}

@media (max-width: 43.8rem) {
  .competency-groups { grid-template-columns: 1fr; gap: 1.1rem; }
  .competency-groups p { max-width: 52ch; margin: .55rem 0 0; }
}
@media (max-width: 36rem) {
  .site-header { flex-direction: column; align-items: flex-start; gap: 0; padding-top: .55rem; }
  .site-header nav { width: 100%; justify-content: space-between; flex-wrap: nowrap; gap: .3rem; }
}
@font-face { font-family: "Greeting ja"; src: url("./assets/greeting-ja.woff") format("woff"); font-display: swap; }
#greeting:lang(ja) { font-family: "Greeting ja", sans-serif; }
@font-face { font-family: "Greeting ko"; src: url("./assets/greeting-ko.woff") format("woff"); font-display: swap; }
#greeting:lang(ko) { font-family: "Greeting ko", sans-serif; }
@font-face { font-family: "Greeting zh-Hant"; src: url("./assets/greeting-zh-Hant.woff") format("woff"); font-display: swap; }
#greeting:lang(zh-Hant) { font-family: "Greeting zh-Hant", sans-serif; }
@font-face { font-family: "Greeting ar"; src: url("./assets/greeting-ar.woff") format("woff"); font-display: swap; }
#greeting:lang(ar) { font-family: "Greeting ar", sans-serif; }
