:root {
  color-scheme: light;
  --ink: #163f50;
  --steel: #214d5c;
  --red: #bf422b;
  --paper: #f6eac9;
  --bench: #e2e9e0;
  --rule: #a2b3ac;
  --serif: "Old Standard TT", "Iowan Old Style", "Songti SC", "STSong", "Noto Serif CJK SC", Georgia, serif;
  --sans: "Inter", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "Courier Prime", "SFMono-Regular", Consolas, monospace;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  color: var(--ink);
  background-color: var(--bench);
  background-image: repeating-linear-gradient(115deg, transparent 0 6px, rgb(49 85 81 / 1.6%) 6.5px, transparent 7px);
  font: 16px/1.5 var(--sans);
}
button { appearance: none; width: auto; height: auto; margin: 0; white-space: normal; font: inherit; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: default; }
button:focus-visible, summary:focus-visible, a:focus-visible { outline: 3px solid #075b87; outline-offset: 3px; }
button { touch-action: manipulation; }
.library, .sr-only { position: absolute; }
.library { width: 0; height: 0; pointer-events: none; }
.sr-only { width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.mast, main, nav.aiplay-shell { width: min(1152px, calc(100% - 64px)); margin-left: auto; margin-right: auto; }
.mast { display: flex; align-items: center; justify-content: space-between; padding: 17px 0 15px; border-bottom: 1px solid #819993; }
.wordmark { display: flex; align-items: center; gap: 12px; }
.wordmark svg { flex: none; }
.wordmark h1 { margin: 0; font: 800 26px/1.05 var(--serif); letter-spacing: .08em; }
.wordmark span { display: block; margin-top: 4px; font: italic 14px/1 var(--serif); letter-spacing: .045em; }
.sound { display: inline-flex; align-items: center; gap: 7px; padding: 8px 13px; min-height: 44px; border: 1px solid #91a49c; border-radius: 30px; background: transparent; font-size: 13px; }
.sound[aria-pressed="true"] { background: #d0ddd3; border-color: var(--ink); }
main { padding-top: 21px; }
.workbench { display: grid; grid-template-columns: minmax(0, 1.87fr) minmax(0, 1fr); align-items: center; gap: clamp(26px, 4.2vw, 68px); }
.workbench > *, .rack-items > *, .gauge-copy { min-width: 0; }
.print-bed {
  position: relative; isolation: isolate; min-width: 0; padding: 11px clamp(19px, 3.3vw, 46px) 10px;
  color: #e5e5c9; border: 1px solid #143845; border-radius: 10px;
  background-color: var(--steel);
  background-image: repeating-linear-gradient(160deg, transparent 0 13px, rgb(223 236 218 / 3%) 13.5px, transparent 14px), linear-gradient(115deg, #2e5d68, #214b59 54%, #193e4d);
  box-shadow: 0 3px 0 #183a45, 0 8px 18px -12px #0b2c36;
}
.print-bed::before, .print-bed::after {
  content: ""; position: absolute; z-index: -1; inset-block: 43px 37px; width: 4px;
  background: repeating-linear-gradient(to bottom, rgb(224 235 207 / 33%) 0 1px, transparent 1px 8px);
}
.print-bed::before { left: 9px; }
.print-bed::after { right: 9px; }
.bed-head, .bed-foot { display: flex; align-items: center; font-size: 11px; letter-spacing: .055em; }
.bed-head { justify-content: space-between; padding-bottom: 10px; color: #f0edd9; }
.bed-head span:last-child { font: 11px/1 var(--mono); letter-spacing: .1em; }
.bed-foot { justify-content: center; gap: 20px; padding-top: 12px; color: #f2edd6; }
.bed-foot span { display: inline-flex; align-items: center; gap: 6px; }
.key-ink { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.key-ink.blue { background: #143d51; border: 1px solid #c1d3cf; }
.key-ink.red { background: #ed7352; border: 1px solid #ef967c; }
.sheet-mount { position: relative; }
.paper-stack {
  position: relative; background: var(--paper);
  box-shadow: 0 1px 0 #9c997e, 1px 3px 0 #e5d6b1, 1px 4px 0 #afaa8f, 2px 6px 0 #d5c8a7, 3px 10px 13px rgb(4 25 33 / 42%);
}
#poster { width: 100%; height: auto; display: block; }
.preview-ink { opacity: .77; }
.pressed-ink { visibility: hidden; }
#ink-wipe { transform-origin: 0 0; transform: scaleY(0); }
.print-bed[data-phase="pull"] .pressed-ink { visibility: visible; }
.print-bed[data-phase="pull"] #ink-wipe { animation: lay-ink .58s cubic-bezier(.35,.03,.48,1) both; }
.print-bed[data-phase="proof"] .preview-ink { opacity: 1; }
@keyframes lay-ink { to { transform: scaleY(1); } }
.sheet-imprint { font: 600 11px var(--serif); }
.sheet-imprint .latin { font: italic 13px var(--serif); }
.print-title { font: 800 41px var(--serif); letter-spacing: .08em; }
.print-english { font: italic 15px var(--serif); letter-spacing: .04em; }
.series-name { font: 600 14px var(--serif); letter-spacing: .16em; }
.series-number { font: 12px var(--mono); letter-spacing: .1em; }
#seal-text { font: 800 21px var(--serif); letter-spacing: .1em; }
.drag-surface {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; padding: 0;
  border-radius: 0; background: transparent; cursor: grab; touch-action: none; -webkit-user-select: none; user-select: none;
}
.drag-surface:focus-visible { outline: 3px dashed #b4e1de; outline-offset: 4px; }
.drag-surface.dragging { cursor: grabbing; }
.roller {
  position: absolute; z-index: 2; inset: 0 -7px; opacity: 0; pointer-events: none;
}
.roller i {
  display: block; height: 17px; border: 1px solid #102f38; border-radius: 8px;
  background: linear-gradient(#75918d, #264957 30%, #132f3c 69%, #426471 91%, #213f47);
  box-shadow: 0 7px 7px rgb(22 49 53 / 35%);
}
.print-bed[data-phase="pull"] .roller { animation: roll .58s cubic-bezier(.35,.03,.48,1) both; }
@keyframes roll {
  0% { opacity: 0; transform: translateY(-4%); }
  8% { opacity: 1; }
  83% { opacity: 1; }
  100% { opacity: 0; transform: translateY(99%); }
}
.console { padding: 9px 0; }
.control-kicker { display: flex; align-items: center; gap: 7px; color: #416558; font-size: 13px; font-weight: 650; }
.reg-symbol { color: var(--red); font: 23px/1 var(--serif); }
.console h2 { font: 800 clamp(31px, 3.5vw, 48px)/1.16 var(--serif); letter-spacing: .03em; margin: 8px 0 9px; }
.instructions { margin: 0; min-height: 2.95em; font-size: 15px; line-height: 1.6; max-width: 32em; color: #344e50; }
.alignment { display: flex; align-items: center; gap: 15px; padding-block: 13px 12px; margin: 12px 0 6px; border-block: 1px solid var(--rule); }
.gauge-pair { display: flex; flex: none; gap: 7px; }
.gauge-item { display: grid; justify-items: center; gap: 3px; font-size: 10px; line-height: 1.1; color: #455e59; }
.gauge-item svg { display: block; }
.lens { fill: #f4ebcf; stroke: #7c9288; stroke-width: 1; }
.graticule { fill: none; stroke: #55766f; stroke-dasharray: 1 2.5; stroke-width: .85; }
.gauge-copy { display: grid; gap: 3px; font-size: 13px; line-height: 1.5; }
.gauge-copy b { font: 700 17px/1.2 var(--serif); }
.gauge-copy span { color: #385551; }
.alignment.is-exact .lens { fill: #eef3d5; stroke: #52774c; stroke-width: 2; }
.adjusters { margin: 10px 0; }
.control-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.control-row + .control-row { margin-top: 5px; }
.control-row > span { flex: none; color: #3e5753; font-size: 13px; }
.nudge-group { display: grid; width: 191px; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 5px; flex: none; }
.turn-group { display: grid; width: 191px; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; flex: none; }
.control-row button {
  display: grid; place-items: center; height: 44px; min-width: 44px; padding: 0 6px;
  border: 1px solid #91a69e; border-radius: 5px; color: var(--ink); background: #f4f4e7;
  box-shadow: 0 2px 0 #9caf9f; font-size: 21px; line-height: 1;
}
.nudge-group button { width: 44px; padding: 0; }
.turn-group button { font-size: 13px; padding-inline: 13px; }
.control-row button:active, .pull:active { transform: translateY(2px); box-shadow: none; }
.pull {
  display: flex; gap: 9px; align-items: center; justify-content: center; width: 100%; min-height: 49px;
  margin-top: 16px; border: 1px solid #94361e; border-radius: 6px; background: var(--red); color: #fff5de;
  box-shadow: 0 3px 0 #813521; font: 750 18px/1.25 var(--serif); letter-spacing: .06em;
}
.pull[aria-disabled="true"] { cursor: progress; background: #995240; }
.proof-note { display: flex; align-items: center; gap: 15px; margin: 18px 0 12px; padding-block: 13px; border-block: 1px solid var(--rule); }
.impression { flex: none; display: grid; place-items: center; width: 58px; height: 39px; border: 3px double var(--red); color: var(--red); font: 700 19px/1 var(--serif); transform: rotate(-5deg); }
.proof-note p { margin: 0; font: 16px/1.65 var(--serif); }
.retry { display: block; margin: 10px auto 0; min-height: 44px; padding: 5px 14px; border: 0; text-decoration: underline; text-underline-offset: 4px; color: #33584f; background: transparent; font-size: 14px; }
.rack { margin-top: 22px; }
.rack-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.rack-heading h2 { margin: 0; font: 750 23px/1.2 var(--serif); letter-spacing: .05em; }
.rack-heading > span { color: #436158; font-size: 13px; font-variant-numeric: tabular-nums; }
.rack-items { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.swatch {
  display: flex; align-items: center; gap: 13px; padding: 7px; width: 100%; min-width: 0; text-align: left;
  background: #eaf0e5; border: 1px solid #a6b6ac; border-radius: 4px;
}
.swatch[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); background: #f1f0dd; }
.thumbnail { flex: none; overflow: hidden; min-width: 0; max-width: 100%; width: clamp(78px, 7.5vw, 101px); height: 49px; border: 1px solid #b7ad8c; background: var(--paper); }
.swatch-copy { display: grid; gap: 2px; }
.swatch-copy b { font: 700 17px/1.25 var(--serif); }
.swatch-copy small { color: #4a6158; font-size: 11px; }
.swatch.has-proof small { color: #9d3926; }
nav.aiplay-shell {
  position: relative; top: auto; right: auto; bottom: auto; left: auto; z-index: 3; transform: none; gap: 3px; justify-content: flex-start;
  margin-top: 18px; margin-bottom: max(6px, env(safe-area-inset-bottom)); padding: 0; max-width: none;
  border: 0; border-top: 1px solid var(--rule); border-radius: 0; box-shadow: none; background: transparent; color: var(--ink);
}
nav.aiplay-shell > a, nav.aiplay-shell summary { min-height: 44px; display: inline-flex; align-items: center; padding: 7px 8px; color: #36534e !important; font-size: 12px; }
nav.aiplay-shell > a:first-child { padding-left: 0; }
nav.aiplay-shell > a.aiplay-filing { margin-left: auto; flex-basis: auto; padding: 7px 0 7px 6px; min-height: 44px; color: #49655d !important; }
nav.aiplay-shell details > div {
  top: auto; bottom: calc(100% + 3px); left: 0; transform: none; width: min(300px,100%); padding: 14px;
  color: #f3edda; background: #21444e; font: 13px/1.5 var(--sans);
}
nav.aiplay-shell details small { color: #d9dfcf; }
@media (hover: hover) {
  .sound:hover, .control-row button:hover { border-color: var(--ink); background: #e7eddb; }
  .pull:hover { background: #a93623; }
  .swatch:hover { border-color: var(--ink); }
}
@media (max-width: 920px) {
  .mast, main, nav.aiplay-shell { width: calc(100% - 40px); }
  .workbench { grid-template-columns: minmax(0,1.5fr) minmax(0,1fr); gap: 23px; }
}
@media (max-width: 740px) {
  .mast, main, nav.aiplay-shell { width: min(590px, calc(100% - 28px)); }
  .mast { padding-block: 11px; }
  .wordmark { gap: 8px; }
  .wordmark svg { width: 37px; height: 37px; }
  .wordmark h1 { font-size: 23px; }
  .wordmark span { font-size: 12px; }
  main { padding-top: 14px; }
  .workbench { grid-template-columns: minmax(0,1fr); gap: 17px; }
  .print-bed { padding: 8px clamp(16px,4vw,25px) 7px; }
  .bed-head { padding-bottom: 6px; }
  .bed-foot { padding-top: 9px; }
  .print-bed::before { left: 6px; }
  .print-bed::after { right: 6px; }
  .console { padding: 0; }
  .control-kicker { font-size: 12px; }
  .console h2 { font-size: 30px; margin-block: 3px 5px; }
  .instructions { min-height: 0; font-size: 14px; }
  .alignment { padding-block: 8px; margin: 9px 0 6px; }
  .gauge-item svg { width: 43px; height: 43px; }
  .gauge-pair { gap: 11px; }
  .adjusters { margin: 8px 0; }
  .pull { margin-top: 10px; min-height: 46px; }
  .rack { margin-top: 21px; }
  .rack-items { gap: 7px; }
  .swatch { display: grid; grid-template-columns: minmax(0,1fr); gap: 6px; padding: 5px 5px 6px; }
  .thumbnail { width: 100%; height: auto; aspect-ratio: 2.5; }
  .swatch-copy { padding-left: 2px; gap: 2px; }
  .swatch-copy b { font-size: 15px; }
  nav.aiplay-shell { margin-top: 14px; }
}
@media (max-width: 360px) {
  nav.aiplay-shell { justify-content: center; }
  nav.aiplay-shell > a.aiplay-filing { margin-inline: auto; }
  .control-row { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .print-bed[data-phase="pull"] .roller, .print-bed[data-phase="pull"] #ink-wipe { animation: none; }
  .control-row button:active, .pull:active { transform: none; }
}
