@font-face {
  font-family: "Plex";
  src: url("/assets/plex-400.woff") format("woff");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Plex";
  src: url("/assets/plex-600.woff") format("woff");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}
:root {
  color-scheme: light;
  --page: #f3f1e8;
  --ink: #233c30;
  --muted: #536657;
  --line: #c8d1c0;
  --accent: #2c563e;
  --wash: #e2eadc;
  font-family: "Plex", sans-serif;
  color: var(--ink);
  background: var(--page);
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, a { -webkit-tap-highlight-color: transparent; }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled, input:disabled { cursor: wait; opacity: 0.48; }
button, a, input { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, canvas:focus-visible {
  outline: 3px solid #34694c;
  outline-offset: 4px;
}
button { color: inherit; }
a { color: var(--accent); text-underline-offset: 4px; }
.page-header {
  max-width: 1560px;
  margin: 0 auto;
  padding: 40px 44px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
h1 { margin: 0; font: 400 clamp(2rem, 3.5vw, 3.3rem)/1.08 Georgia, serif; letter-spacing: -0.03em; text-wrap: balance; }
.page-header p { margin: 12px 0 0; font-size: 17px; color: var(--muted); }
.download-kit {
  flex: 0 0 auto;
  display: inline-flex;
  gap: 24px;
  align-items: center;
  background: var(--ink);
  color: #f8faf1;
  padding: 15px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  transition: background-color 150ms;
}
.download-kit:hover { background: #3c674b; }
.workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 315px;
  max-width: 1560px;
  margin: 0 auto;
  padding: 0 28px 0 16px;
}
.viewer { min-width: 0; }
.stage {
  position: relative;
  height: clamp(450px, 57vh, 650px);
  min-height: 420px;
  overflow: hidden;
}
canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.stage-top {
  position: absolute;
  left: 30px;
  right: 28px;
  top: 15px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  pointer-events: none;
  font-size: 13px;
  color: var(--muted);
}
#pose-label { color: var(--ink); font-weight: 600; }
.view-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 30px;
}
.view-tools button {
  border: 1px solid #b9c6b2;
  background: #f6f6edd9;
  border-radius: 5px;
  min-height: 40px;
  padding: 8px 12px;
  font-size: 13px;
}
.view-tools button:hover { background: var(--wash); }
.orbit-hint { position: absolute; right: 28px; bottom: 20px; margin: 0; font-size: 12px; color: var(--muted); }
.load-state {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 30px;
  text-align: center;
  background: var(--page);
}
.load-state strong { font: 400 28px Georgia, serif; }
.load-state span { max-width: 45ch; color: var(--muted); line-height: 1.5; }
.load-state[hidden] { display: none; }
#retry { border: 1px solid var(--ink); background: transparent; padding: 10px 20px; border-radius: 6px; }
.motion-controls { display: flex; align-items: center; gap: 28px; padding: 15px 30px 0; }
.play-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 110px;
  min-height: 48px;
  padding: 13px 18px;
  border: 0;
  border-radius: 7px;
  background: var(--accent);
  color: #f8faf1;
  font-weight: 600;
}
.play-button:hover { background: #1e412d; }
.slider-group { flex: 1; min-width: 0; }
.slider-labels { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13px; }
.slider-labels button { background: none; border: 0; padding: 8px 0; min-height: 36px; font-size: 13px; }
.slider-labels button:hover { text-decoration: underline; text-underline-offset: 4px; }
.slider-labels output { font-variant-numeric: tabular-nums; color: var(--muted); }
input[type="range"] { display: block; width: 100%; height: 30px; margin: 0; accent-color: var(--accent); cursor: ew-resize; }
.motion-note { margin: 10px 30px 24px 168px; font-size: 12px; color: var(--muted); }
.inspector { border-left: 1px solid var(--line); padding: 18px 0 18px 25px; }
h2 { margin: 0 0 20px; font-size: 19px; font-weight: 600; }
.part-list { display: flex; flex-direction: column; gap: 4px; }
.part-row {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 12px 8px;
  border-radius: 6px;
  text-align: left;
}
.part-row:hover { background: #e9eedf; }
.part-row[aria-pressed="true"] { background: var(--wash); }
.part-row strong { display: block; font-size: 14px; font-weight: 600; }
.part-row small { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); }
.part-symbol { flex: 0 0 28px; width: 28px; height: 16px; border: 2px solid #628067; border-radius: 8px; }
.shell-symbol { border-top-width: 1px; background: #9eaf94; }
.cassette-symbol { height: 11px; background: #dce4cf; border-radius: 3px 7px 7px 3px; }
.deck-symbol { height: 6px; border-radius: 4px; background: #b1c4a3; }
.diffuser-symbol { background: #d1eee4; border-color: #87a899; height: 9px; }
.check-row { display: flex; align-items: center; gap: 10px; font-size: 13px; min-height: 40px; cursor: pointer; }
.check-row input, .lighting input { width: 16px; height: 16px; margin: 0; accent-color: var(--accent); }
.part-detail { padding: 20px 0 22px; border-bottom: 1px solid var(--line); }
.part-detail h3 { margin: 0 0 10px; font-size: 15px; font-weight: 600; }
.part-detail p { margin: 0 0 13px; font-size: 13px; line-height: 1.55; color: var(--muted); max-width: 37ch; }
.part-detail a { font-size: 13px; font-weight: 600; }
.electronics-note { margin: 8px 0 3px; padding: 12px; background: #e5ecde; border-radius: 6px; font-size: 12px; line-height: 1.5; }
.electronics-note[hidden] { display: none; }
.electronics-note strong { font-weight: 600; }
.electronics-note p { margin: 7px 0 0; color: var(--muted); }
.lighting { padding: 22px 0 4px; margin: 0; border: 0; }
.lighting legend { padding: 22px 0 0; font-size: 14px; font-weight: 600; }
.lighting label { display: flex; align-items: center; gap: 10px; min-height: 38px; font-size: 13px; cursor: pointer; }
.swatch { width: 10px; height: 10px; border-radius: 50%; background: var(--ink); }
.swatch.desktop { background: #a855f7; }
.swatch.cli { background: #06b6d4; }
.swatch.claude { background: #f97316; }
.paint-option { margin-top: 10px; }
.material-note { margin: 3px 0 0 26px; font-size: 12px; line-height: 1.5; color: var(--muted); }
.page-footer { max-width: 1560px; margin: 0 auto; padding: 26px 44px 28px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.page-footer p { margin: 0 0 5px; }
.page-footer strong { font-weight: 600; color: var(--ink); }
.page-footer a { margin-left: 12px; }
.no-script { padding: 30px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -80px; z-index: 10; padding: 12px 16px; background: var(--ink); color: var(--page); }
.skip-link:focus { top: 12px; }
.project-nav { max-width: 1560px; margin: 0 auto; padding: 12px 44px 0; display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 14px; }
.project-nav a, .document-header nav a { padding-block: 12px; }
.document-header { max-width: 1100px; margin: 0 auto; padding: 24px 32px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px 28px; }
.document-header > a { font: 400 23px Georgia, serif; color: var(--ink); }
.document-header nav { display: flex; flex-wrap: wrap; gap: 24px; font-size: 14px; }
.document { max-width: 80ch; margin: 0 auto; padding: 48px 28px; font-size: 17px; line-height: 1.65; overflow-wrap: break-word; }
.document h1 { max-width: none; font-size: clamp(2.2rem, 5vw, 3.4rem); margin-bottom: 28px; }
.document h2 { margin: 48px 0 16px; font-size: 25px; line-height: 1.25; }
.document h3 { margin: 32px 0 12px; font-size: 20px; line-height: 1.3; }
.document p, .document ul, .document ol { margin: 0 0 20px; }
.document li + li { margin-top: 8px; }
.document img { display: block; width: 100%; height: auto; margin: 24px 0; }
.document pre { overflow-x: auto; padding: 20px; background: var(--wash); font-size: 14px; line-height: 1.6; }
.document code { font-size: 0.88em; overflow-wrap: anywhere; }
.document pre code { font-size: inherit; overflow-wrap: normal; }
.document table { width: 100%; border-collapse: collapse; font-size: 15px; margin-bottom: 24px; }
.document th, .document td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.document th { background: var(--wash); }
.table-scroll { overflow-x: auto; }
.document-footer { max-width: 1100px; border-top: 1px solid var(--line); }
@media (max-width: 1080px) {
  .orbit-hint { display: none; }
  .workbench { grid-template-columns: minmax(0, 1fr) 285px; }
  .inspector { padding-left: 18px; }
  .motion-controls { gap: 18px; }
  .motion-note { margin-left: 158px; }
}
@media (max-width: 760px) {
  .project-nav { padding-inline: 22px; }
  .document-header { padding: 20px 22px; }
  .document { padding: 32px 22px; font-size: 16px; }
  .document th, .document td { padding: 10px; }
  .page-header { padding: 26px 22px 14px; gap: 20px; align-items: flex-start; }
  h1 { font-size: 31px; max-width: 13ch; }
  .page-header p { font-size: 14px; max-width: 25ch; line-height: 1.4; }
  .download-kit { padding: 11px 13px; gap: 10px; font-size: 12px; margin-top: 4px; }
  .workbench { display: block; padding: 0; }
  .stage { height: 420px; min-height: 0; }
  .stage-top { left: 22px; right: 22px; top: 12px; font-size: 11px; }
  .view-tools { padding: 0 22px; display: grid; grid-template-columns: 1fr 1fr; }
  .view-tools button { min-height: 44px; font-size: 12px; }
  .motion-controls { padding: 12px 22px 0; gap: 18px; }
  .play-button { min-width: 94px; padding: 12px; }
  .motion-note { margin: 11px 22px 25px; line-height: 1.4; }
  .inspector { border-left: 0; border-top: 1px solid var(--line); margin: 0 22px; padding: 24px 0 0; }
  .part-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
  .part-row { align-items: flex-start; gap: 9px; padding: 13px 8px; min-height: 80px; }
  .part-symbol { margin-top: 3px; flex-basis: 24px; width: 24px; }
  .part-row strong { font-size: 13px; }
  .part-row small { font-size: 11px; line-height: 1.4; }
  .part-detail { padding-top: 16px; }
  .part-detail p { max-width: 60ch; font-size: 14px; }
  .lighting label { min-height: 44px; }
  .material-note { max-width: 48ch; font-size: 12px; }
  .page-footer { padding: 25px 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
