:root {
  color-scheme: dark;
  font-family: "Helvetica Neue", Arial, "PingFang SC", sans-serif;
  color: #fff;
  background: #131313;
  --chinese: "Source Han Sans SC", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --top: clamp(1rem, 2.3vw, 2.6rem);
  --arrow-size: 2rem;
  --edge: clamp(1.1rem, 3.2vw, 3.75rem);
}
* { box-sizing: border-box; }
body, h1, p { margin: 0; }
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 1.25rem 2.5rem;
  min-height: 100vh;
  min-height: 100svh;
  padding: var(--edge);
}
.screen, .screen::after, video { position: absolute; inset: 0; }
.screen { z-index: -1; overflow: hidden; }
.screen::after {
  content: "";
  background: linear-gradient(180deg, #0007, transparent 21%, transparent 66%, #000b);
}
video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .28s ease;
}
video.is-current { opacity: 1; }
video.is-current { z-index: 1; }
.screen::after { z-index: 2; }
h1 {
  position: absolute;
  inset: calc(var(--top) + 3.6rem) var(--edge) auto;
  display: flex;
  justify-content: space-between;
  font-size: clamp(2.65rem, 7.8vw, 9rem);
  line-height: .9;
  font-weight: 750;
  letter-spacing: .015em;
}
/* Compensate for the outer C side bearings at display size. */
h1 span:first-child { margin-inline-start: -.042em; }
h1 span:last-child { margin-inline-end: -.055em; }
.signature {
  position: absolute;
  top: var(--top);
  left: var(--edge);
  display: flex;
  align-items: center;
  min-height: 2.35rem;
  font-size: clamp(.63rem, 1vw, .82rem);
  letter-spacing: .05em;
}
.credits {
  font-family: var(--chinese);
  font-size: clamp(.75rem, .95vw, .94rem);
  font-weight: 400;
  letter-spacing: .015em;
  line-height: 1.55;
}
#role { font-size: 1.08em; font-weight: 400; }
#company { margin-top: .22rem; font-size: .92em; font-weight: 300; }
#logos { display: flex; align-items: center; gap: 1.25rem; margin-bottom: .75rem; }
[hidden] { display: none !important; }
#logos img { max-height: 2rem; max-width: 7rem; object-fit: contain; }
#logos img[data-logo="actus"] { width: 4.8rem; }
.carousel {
  position: absolute;
  right: var(--edge);
  top: 52%;
  transform: translateY(-50%);
  width: clamp(15rem, 23vw, 25rem);
}
.top-links { position: absolute; top: var(--top); right: var(--edge); display: flex; gap: .55rem; font-family: var(--chinese); }
.top-links :is(a, button) {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; box-shadow: inset 0 0 0 1.25px #fff7; color: white; text-decoration: none;
  width: auto; height: 38px; padding: 0 16px;
  line-height: 18px;
  font-family: inherit; font-size: 13px; font-weight: 400; letter-spacing: .02em;
  -webkit-font-smoothing: antialiased;
  border-radius: 999px; background: transparent;
  transition: background-color .2s, color .2s;
}
.top-links :is(a, button):hover { background: white; color: #171717;  }
#chapter {
  display: flex;
  align-items: baseline;
  gap: .7rem;
  margin-bottom: .5rem;
  font-size: .7rem;
  letter-spacing: .075em;
  text-transform: uppercase;
}
#chapter b { font-family: ui-monospace, monospace; white-space: nowrap; }
.controls { display: grid; grid-template-columns: minmax(0, 1fr) repeat(2, var(--arrow-size)); align-items: center; gap: .45rem; }
#seek {
  appearance: none; width: 100%; min-width: 0; margin: 0;
  height: 2rem; background: transparent; cursor: ew-resize;
}
#seek::-webkit-slider-runnable-track {
  height: .42rem; border-radius: 999px;
  background: linear-gradient(to right, white var(--played, 0%), #fff5 var(--played, 0%));
}
#seek::-moz-range-track {
  height: .42rem; border-radius: 999px;
  background: linear-gradient(to right, white var(--played, 0%), #fff5 var(--played, 0%));
}
#seek::-webkit-slider-thumb {
  appearance: none; width: .66rem; height: .66rem; margin-top: -.12rem; border: 0; border-radius: 50%; background: white;
}
#seek::-moz-range-thumb { width: .66rem; height: .66rem; border: 0; border-radius: 50%; background: white; }
button {
  width: 2rem;
  height: 2rem;
  border: 1px solid #fffc;
  border-radius: 50%;
  padding: 0;
  background: #0003;
  color: #fff;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.controls button {
  display: grid; place-items: center;
  width: var(--arrow-size); height: var(--arrow-size);
  background: #fffe; color: #252525;
}
.controls button::before {
  content: "";
  width: .36rem; height: .36rem;
  border-top: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  transform: translateX(-.09rem) rotate(45deg);
}
#previous::before { transform: translateX(.09rem) rotate(-135deg); }
.controls button:hover { background: #cfcfcf; }
button:hover { background: #fff; color: #111; }
button:focus-visible { outline: 2px solid white; outline-offset: 3px; }
@media (max-width: 620px) {
  .hero { grid-template-columns: 1fr; align-content: end; }
  .top-links { gap: .3rem; }
  .top-links :is(a, button) { padding-inline: 9px; }
  .carousel { width: min(65vw, 19rem); top: 54%; }
  :root { --arrow-size: 2.75rem; }
  .screen::after {
    background: linear-gradient(180deg, #0007, transparent 20%, transparent 50%, #000c);
  }
}
@media (prefers-reduced-motion: reduce) { video { transition: none; } }

.scroll-cue {
  position: absolute;
  inset: auto auto var(--edge) 50%;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 1px;
  pointer-events: none;
}
.scroll-cue span {
  width: .62rem;
  height: .62rem;
  border-right: 1px solid white;
  border-bottom: 1px solid white;
  transform: rotate(45deg);
  opacity: .5;
  animation: scroll-cue 2.1s ease-in-out infinite;
}
.scroll-cue span:nth-child(2) { animation-delay: .16s; }
.scroll-cue span:nth-child(3) { animation-delay: .32s; }
@keyframes scroll-cue {
  0%, 45%, 100% { opacity: .48; }
  22% { opacity: 1; }
}
@media (max-width: 620px) {
  .scroll-cue { bottom: calc(var(--edge) + 5rem); }
}
@media (prefers-reduced-motion: reduce) {
  .scroll-cue span { animation: none; opacity: .8; }
}

.scroll-cue {
  pointer-events: auto;
  padding: .35rem .8rem .55rem;
}
html { scroll-behavior: smooth; }
.about {
  background: #ecebed;
  color: #20211f;
  color-scheme: light;
  font-family: var(--chinese);
  padding-inline: var(--edge);
}
.about h2, .about h3, .about h4 { margin: 0; }
.about-intro, .experience {
  max-width: 94rem;
  margin-inline: auto;
}
.about-intro {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  align-items: end;
}
.about-cover {
  position: relative;
  isolation: isolate;
  grid-column: 1 / -1;
  min-height: 100svh;
  overflow: hidden;
  background: #ecebed;
}
.about .portrait {
  position: absolute;
  inset: 0;
  z-index: -1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.about-heading {
  position: absolute;
  inset: 43% var(--edge) auto;
  text-align: center;
  color: #20211f;
}
.about h2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: baseline;
  font-size: clamp(1.85rem, 5.7vw, 7rem);
  font-weight: 600;
  letter-spacing: -.055em;
  line-height: 1.1;
  white-space: nowrap;
}
.about h2 > :first-child { justify-self: start; }
.english-name {
  grid-column: 2;
  justify-self: end;
  text-align: right;
  font-family: "Helvetica Neue", Arial, sans-serif;
}
.about-caption {
  display: block;
  margin-top: -.14rem;
  font: 500 clamp(.7rem, 1vw, .9rem)/1.2 "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0;
}
.about-summary {
  grid-column: 8 / 13;
  padding: 2rem clamp(1rem, 3vw, 3rem) clamp(2rem, 5vw, 5rem);
  font-size: clamp(.88rem, 1.3vw, 1.08rem);
  line-height: 1.85;
}
.practice {
  margin-bottom: 1.25rem;
  font-weight: 550;
  font-size: clamp(1.65rem, 3.45vw, 3.5rem);
  letter-spacing: -.045em;
  line-height: 1.22;
}
.experience { padding-bottom: clamp(3rem, 7vw, 7rem); }
.experience ol { list-style: none; margin: 0; padding: 0; }
.experience-contact {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem clamp(.85rem, 3.2vw, 3.25rem);
  margin-block-start: clamp(1.7rem, 3vw, 2.7rem);
  font-size: clamp(.8rem, 1vw, .93rem);
  font-style: normal;
}
.experience-contact > span {
  display: inline-flex;
  align-items: center;
  gap: .45em;
  white-space: nowrap;
}
.contact-icon {
  width: 1.15em;
  height: 1.15em;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

.site-nav {
  position: fixed;
  z-index: 5;
  inset: 0 0 auto;
  height: calc(var(--top) + 3.05rem);
  pointer-events: none;
  color: #fff;
  transition: background-color .2s, color .2s;
}
.site-nav .top-links { pointer-events: auto; }
.site-nav.is-light { color: #20211f; }
.site-nav.is-light .top-links :is(a, button) { color: inherit; box-shadow: inset 0 0 0 1.25px #20211f50; }
.site-nav.is-light .top-links :is(a, button):hover {
  color: #fff; background: #20211f;
}
#about, #experience { scroll-margin-top: calc(var(--top) + 3.05rem); }
.about-summary {
  grid-column: 1 / -1;
  display: grid;
  container-type: inline-size;
  grid-template-columns: 5fr 3fr 4fr;
  align-items: start;
  padding: clamp(1.8rem, 4vw, 4rem) 0 clamp(2.75rem, 5.5vw, 5.75rem);
}
.about-summary .practice {
  grid-column: 1;
  margin: 0;
  font-size: min(clamp(1.65rem, 3.45vw, 3.5rem), 3.6cqi);
  text-align: left;
}
.about-bio { grid-column: 3; line-height: 1.72; }
.about-bio, .experience-row { font-size: clamp(.85rem, 1.15vw, 1.06rem); }
.nowrap { white-space: nowrap; }
#experience { scroll-margin-top: calc(var(--top) + 3.5rem); }
.experience ol { border-top: 1px solid #20211f45; }
.experience li { border-bottom: 1px solid #20211f45; }
.experience-row {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.2fr) minmax(0, .7fr) 21ch;
  text-align: left;
  align-items: center;
  gap: clamp(.55rem, 2vw, 2rem);
  padding: clamp(.95rem, 2vw, 1.7rem) clamp(.45rem, 1vw, 1rem);
  color: inherit;
  text-decoration: none;
  transition: background-color .2s, color .2s;
}
.entry-focus { font-size: clamp(1rem, 1.85vw, 1.85rem); font-weight: 500; }
.entry-date { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
a.experience-row:is(:hover, :focus-visible) { color: #fff; background: #20211f; }
.experience-page { background: #ecebed; color: #20211f; color-scheme: light; }
.experience-detail { max-width: 58rem; margin: auto; padding: clamp(2rem, 8vw, 7rem) var(--edge); font-family: var(--chinese); }
.experience-detail > a { color: inherit; }
.experience-detail h1 { position: static; display: block; font-size: clamp(2.2rem, 6vw, 5rem); letter-spacing: -.045em; line-height: 1.15; }
.detail-date { margin: 3rem 0 .65rem; font-variant-numeric: tabular-nums; }
.detail-company { margin-top: .9rem; }
.detail-copy { max-width: 43em; margin-top: 2rem; line-height: 1.85; }
.detail-copy p + p { margin-top: .6rem; }
@media (max-width: 620px) {
  .about-cover { min-height: 82svh; }
  .about h2 { font-size: clamp(1.45rem, 6vw, 2.4rem); }
  .about-summary { display: block; }
  .about-summary .practice {
    margin-bottom: 1rem;
    padding-right: .5em;
    font-size: min(clamp(1.65rem, 3.45vw, 3.5rem), 8.25cqi);
  }
  .experience-row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "focus date" "company company" "brand brand";
    row-gap: .35rem;
  }
  .entry-focus { grid-area: focus; }
  .entry-company { grid-area: company; }
  .entry-brand { grid-area: brand; }
  .entry-brand:empty { display: none; }
  .entry-date { grid-area: date; }
}

.about-intro { max-width: none; margin-inline: calc(-1 * var(--edge)); }
.about-summary { width: min(calc(100% - 2 * var(--edge)), 94rem); margin-inline: auto; }

.detail-copy h2 { font-size: 1.3rem; margin: 1.8rem 0 .35rem; }

.project-entry { position: absolute; inset: 0; }
.project-entry:focus-visible { outline-offset: -5px; }
.hero:has(.project-entry:not([hidden])) :is(h1, .credits) { pointer-events: none; }
