:root {
  color-scheme: dark;
  --ink: #f1e9df;
  --soft: #b5b9bc;
  --copper: #e1a482;
  font-family: system-ui, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #101619;
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; }
button { font: inherit; }
:focus-visible { outline: 2px solid #ffd0a5; outline-offset: 4px; }
.cover {
  position: relative;
  height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.72fr) minmax(0, 1fr);
  grid-template-areas: "title exhibit controls";
  align-items: center;
  padding: clamp(12px, 4.5svh, 54px) clamp(14px, 4.2vw, 80px);
  gap: clamp(8px, 2.1vw, 38px);
  overflow: hidden;
  background: radial-gradient(ellipse at 50% 43%, #34434a 0%, #1c282e 36%, transparent 74%), #101619;
}
.cover .portfolio-menu summary {
  background: #201e27;
  color: var(--ink);
  border-radius: 5px;
}
.cover .menu-icon {
  width: 16px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 -5px currentColor, 0 5px currentColor;
}
.cover-copy { grid-area: title; align-self: start; margin-top: clamp(24px, 17svh, 170px); z-index: 1; pointer-events: none; }
.cover h1 {
  margin: 0;
  font: 400 clamp(27px, 4.45vw, 88px)/.91 Georgia, "Times New Roman", serif;
  letter-spacing: -.065em;
  white-space: nowrap;
}
.exhibit { grid-area: exhibit; position: relative; min-width: 0; min-height: 0; height: 100%; }
.stage {
  display: grid;
  place-items: center;
  position: relative;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.stage.is-dragging { cursor: grabbing; }
.floor {
  position: absolute;
  left: 50%;
  width: 76%;
  height: 8%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #030608;
  filter: blur(23px);
  opacity: .65;
}
.instructions { grid-area: controls; min-width: 0; }
.controls-actions { display: grid; gap: clamp(4px, 1.8svh, 20px); }
.control-row { display: flex; align-items: center; justify-content: flex-end; gap: clamp(5px, 1.2vw, 16px); }
.reset {
  display: grid;
  grid-template-columns: max-content clamp(12px, 4vw, 57px);
  gap: clamp(6px, 1.45vw, 22px);
  align-items: center;
  justify-content: end;
  min-height: clamp(31px, 6svh, 54px);
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  white-space: nowrap;
  cursor: pointer;
  font-size: clamp(.79rem, 1.4vw, 1.28rem);
}
.reset::after { content: ""; height: 1px; background: currentColor; }
.demo-controls { display: grid; justify-items: start; }
.reset[aria-pressed="true"] { color: var(--copper); }
.reset:disabled { opacity: .42; cursor: default; }
.reset:enabled:hover { color: var(--copper); }
.route-level {
  font: inherit;
  font-size: clamp(.72rem, 1.08vw, .96rem);
  color: var(--soft);
  background: #212c32;
  border: 1px solid #8d9ba45c;
  border-radius: 2px;
  min-width: 0;
  max-width: 100%;
  padding: 3px 2px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.model, .fallback, .model-controls { position: absolute; inset: 0; width: 100%; height: 100%; }
.model { display: block; z-index: 1; }
.fallback { object-fit: contain; padding: 5% 14%; z-index: 2; }
.model-controls { pointer-events: none; z-index: 3; }
.model-target {
  position: absolute;
  width: var(--target-width, 44px);
  min-height: 44px;
  transform: translate(-50%, -50%);
  border: 0;
  border-radius: 4px;
  padding: 0;
  background: transparent;
  pointer-events: auto;
  touch-action: none;
  cursor: pointer;
}
.model-target[disabled] { pointer-events: none; }
.model-target[data-level] { cursor: ew-resize; }
.model-target:hover:not([disabled]) { border: 1px solid #fff3d4b3; }
.stage.is-dragging { touch-action: none; }
[hidden] { display: none !important; }

@media (max-width: 760px) {
  .cover { grid-template-columns: minmax(0, 1fr) minmax(0, 1.65fr) minmax(106px, .72fr); }
}
@media (max-width: 470px) {
  .cover {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto minmax(0, 1fr);
    grid-template-areas: "title title" "exhibit controls";
    row-gap: 2px;
  }
  .cover-copy { margin-top: 0; }
  .cover h1 { font-size: clamp(28px, 8vw, 37px); }
  .controls-actions { gap: 4px; }
}
@media (max-height: 350px) {
  .cover-copy { margin-top: 10px; }
  .controls-actions { gap: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; transition-duration: .001s !important; }
}



.case-study {
  color-scheme: light;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #251e1d;
  background: #f1ebe2;
  font-synthesis: none;
  line-height: 1.75;
}
.case-study :where(figure, h2, h3, p) { margin: 0; }
.case-study a { color: inherit; }
.case-study :focus-visible { outline-color: currentColor; }
.case-study img { display: block; max-width: 100%; }
.empathy-footer .home-button {
  display: grid;
  place-items: center;
  width: min(100%, 32rem);
  min-height: 4.5rem;
  margin-inline: auto;
  padding: 1rem 2rem;
  border-radius: .75rem;
  background: #813e2d;
  color: #fff7f1;
  font-size: clamp(1.25rem, 1.1rem + .7vw, 1.65rem);
  font-weight: 700;
  text-decoration: none;
}
.empathy-footer .home-button:hover { background: #692f22; }
.empathy-footer .home-button:focus-visible { outline-color: #813e2d; }
.artwork-viewer {
  width: min(96vw, 104rem);
  max-width: 96vw;
  max-height: 94svh;
  border: 0;
  padding: 0;
  background: #201c20;
  color: #f8eee2;
}
.artwork-viewer::backdrop { background: #111015e6; }
.artwork-viewer form { display: flex; justify-content: end; padding: .5rem 1rem; }
.artwork-viewer button { background: transparent; border: 1px solid currentColor; padding: .25rem .7rem; color: inherit; cursor: pointer; }
.artwork-viewer img { width: 100%; height: min(82svh, 100rem); object-fit: contain; }
@media (pointer: coarse) { .cover .stage { touch-action: pan-y; } }

.chapters {
  position: sticky;
  z-index: 2;
  top: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding-inline: 6%;
  background: #f1ebe2;
  border-bottom: 1px solid #cbc0b4;
}
.chapters a {
  padding: .65rem .35rem;
  text-align: center;
  color: #853d28;
  font-size: .85rem;
  font-weight: 700;
  text-decoration: none;
}
.chapters a:hover { background: #e7dac9; }
.chapters a span { margin-left: .35em; color: #251e1d; }
.module { padding-block: clamp(3rem, 7.5vw, 7rem); scroll-margin-top: 4.5rem; }
.module-wrap { max-width: 90rem; width: 88%; margin-inline: auto; }
.module-dark { color: #f8eee2; background: #251f23; }
.module-paper { background: #f1ebe2; }
.module-clay { background: #ead9cc; }
.module-label {
  margin-bottom: 1.15rem;
  color: #853d28;
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .09em;
}
.module-dark .module-label { color: #f2af89; }
.project-context { max-width: 56rem; margin-bottom: clamp(2.5rem, 6vw, 5.5rem); }
.project-context h2, .showcase-title {
  margin-bottom: 1.25rem;
  font: 600 clamp(2rem, 5.25vw, 5.5rem)/1.16 "Songti SC", STSong, Georgia, serif;
  letter-spacing: -.035em;
}
.module-dark .showcase-title { font-size: clamp(1.45rem, 3.3vw, 3.1rem); }
.intro { max-width: 48em; font-size: clamp(1rem, 1.3vw, 1.2rem); }
.intro + .intro { margin-top: .65rem; }
.showcase-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: clamp(.8rem, 2.75vw, 2.5rem);
}
.module-dark .showcase-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
.artwork-link { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; border-radius: .8rem; cursor: zoom-in; }
.artwork-link:hover { outline: 1px solid currentColor; outline-offset: 4px; }
.showcase-note { max-width: 54em; margin-top: 1.35rem; }
.feature-image img {
  height: clamp(17rem, 47vw, 37rem);
  width: 100%;
  object-fit: contain;
  object-position: center;
  background: #181719;
  border-radius: .8rem;
}
.module-dark .feature-image img { height: clamp(18rem, 54vw, 46rem); }
.module-paper .feature-image img { background: #ded1c2; }
.module-clay .feature-image img { background: #d6c0af; }
figcaption { font-size: .9rem; line-height: 1.55; }
.feature-image figcaption, .evidence-grid figcaption { margin-top: .8rem; }

.subsection { margin-top: clamp(2.5rem, 6vw, 5.5rem); }
.subsection h2, .subsection h3 {
  margin-bottom: 1rem;
  font-size: clamp(1.4rem, 3vw, 2.45rem);
  line-height: 1.24;
}
.process-details {
  margin-top: clamp(1.5rem, 4vw, 3.5rem);
  border-block: 1px solid #97877980;
}
.process-details > summary { padding-block: .85rem; cursor: pointer; font-weight: 650; }
.process-details > summary:hover { text-decoration: underline; }
.process-details > .subsection { margin-top: clamp(1.5rem, 3vw, 2.5rem); padding-bottom: 1rem; }
.process-intro { max-width: 54em; margin: .1rem 0 1.1rem; }
.switcher-controls { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .9rem; }
.switcher-controls a {
  padding: .55rem .8rem;
  border: 1px solid #978779;
  border-radius: .4rem;
  font-weight: 650;
  text-decoration: none;
}
.switcher-controls a:hover { text-decoration: underline; }
.switcher-controls [aria-current] { background: #873e29; color: #fff5e6; border-color: #873e29; }
.frame {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(1rem, 4vw, 3.5rem);
  margin-bottom: 1rem;
  padding: clamp(.75rem, 2vw, 1.5rem);
  border: 1px solid #97877980;
  border-radius: .8rem;
}
.frame img {
  width: 100%;
  height: clamp(16rem, 38vw, 26rem);
  object-fit: contain;
  border-radius: .4rem;
  background: #171519;
}
.module-paper .frame img, .module-clay .frame img { background: #dfd2c6; }
.frame-square img { background: #ccccca; }
.frame figcaption { max-width: 32rem; font-size: 1rem; }
.frame strong { display: block; margin-bottom: .5rem; font-size: 1.25rem; }
.frame.is-current { animation: reveal-in 280ms ease-out both; }
@keyframes reveal-in {
  from { opacity: .25; transform: translateY(5px); }
  to { opacity: 1; transform: none; }
}
.evidence-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(.75rem, 2vw, 1.5rem); }
.evidence-grid-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.evidence-grid img { width: 100%; height: clamp(10rem, 24vw, 22rem); object-fit: contain; background: #dfd2c6; border-radius: .6rem; }
.evidence-grid + p { max-width: 54em; margin-top: 1.25rem; }
.empathy-footer { padding: clamp(2rem, 6vw, 5rem) 6%; }

@media (max-width: 740px) {
  .showcase-grid, .module-dark .showcase-grid, .frame { grid-template-columns: 1fr; }
  .feature-image img, .module-dark .feature-image img { height: auto; max-height: 36rem; }
  .frame { align-content: start; }
  .evidence-grid { grid-template-columns: 1fr; }
  .evidence-grid img { height: auto; max-height: 22rem; }
}

@media (max-width: 420px) {
  .chapters { padding-inline: 2%; }
  .chapters a { font-size: .73rem; padding-inline: .15rem; }
  .chapters a span { margin-left: .15em; }
}
@media (prefers-reduced-motion: reduce) {
  .frame.is-current { animation: none; }
}
