@font-face {
  font-family: Cabinet Serif;
  src: url('display.woff') format('woff');
  font-display: swap;
}
.cab-shell {
  --night: #101816;
  --cream: #f1eadb;
  --gold: #ccb282;
  --edge: #606157;
  --pad-x: clamp(18px, 4.6vw, 84px);
}
.cab-shell a,
.cab-head a {
  color: inherit;
  text-decoration: none;
}
.cab-shell button,
.cab-head summary {
  font: inherit;
  color: inherit;
}
.cab-shell button {
  cursor: pointer;
}
.cab-shell :focus-visible,
.cab-head :focus-visible {
  outline: 2px solid #ebcf95;
  outline-offset: 4px;
}
.cab-shell {
  font-family: Arial, Helvetica, sans-serif;
  min-height: 360px;
  height: 100vh;
  height: 100svh;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  position: relative;
  isolation: isolate;
  background: radial-gradient(ellipse at 50% 54%, #18221d 0, #111916 47%, #101714 76%, #101613 100%);
}
.cab-head {
  height: clamp(60px, 8vh, 86px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 10;
  padding: 0 var(--pad-x);
  background: #101714;
  color: var(--cream);
  font-family: Arial, Helvetica, sans-serif;
}
.cab-head:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: var(--pad-x);
  right: var(--pad-x);
  height: 1px;
  background: linear-gradient(90deg, #76807055, #737d7038 72%, #76807055);
}
.cab-heading {
  margin: 0;
  padding: .65rem var(--pad-x) .15rem;
  color: var(--cream);
  text-align: center;
  font: 400 clamp(1.35rem, 2.3vw, 2.3rem)/1.18 Cabinet Serif, Georgia, serif;
}
.cab-word {
  font-size: clamp(22px, 2.1vw, 31px);
  font-weight: 650;
  letter-spacing: -0.079em;
  line-height: 1;
}
.cab-word span {
  color: var(--gold);
}
.cab-head nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.4vw, 42px);
  font-size: 15px;
}
.cab-head nav > a {
  padding: 12px 0;
}
.cab-head nav > a:hover,
.site-menu a:hover {
  text-decoration: underline;
  text-underline-offset: 0.23em;
}
.site-menu {
  position: relative;
}
.site-menu summary {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: 10px;
  list-style: none;
  cursor: pointer;
}
.site-menu summary::-webkit-details-marker {
  display: none;
}
.site-menu summary i {
  width: 19px;
  height: 8px;
  border-block: 1px solid currentColor;
  display: block;
}
.site-menu[open] summary i {
  height: 1px;
}
.site-menu > div {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 205px;
  background: #1b2620;
  border: 1px solid #64705b;
  padding: 6px 0;
  box-shadow: 0 16px 36px #0005;
}
.site-menu > div a {
  display: block;
  padding: 12px 20px;
  color: #f6edd8;
}
.rotary-stage5 {
  min-width: 0;
  min-height: 0;
  position: relative;
  overflow: hidden;
  outline-offset: -6px !important;
  touch-action: pinch-zoom;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.rotary-stage5.dragging {
  cursor: grabbing;
}
.art-area {
  position: absolute;
  inset: clamp(10px, 1.7vh, 25px) 0 clamp(4px, 1vh, 14px);
  display: grid;
  place-items: center;
  pointer-events: none;
}
.machine-frame {
  width: min(100%, calc((100svh - clamp(60px, 8vh, 86px) - clamp(90px, 13vh, 120px) - 28px) * 1.5));
  aspect-ratio: 3/2;
  position: relative;
  max-height: 100%;
  min-width: 1px;
}
.machine-layer {
  width: 1536px;
  height: 1024px;
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: 0 0;
  transform: scale(var(--machine-scale, 0.5));
  pointer-events: none;
  isolation: isolate;
}
.machine-photograph {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  display: block;
  mask-image:
    linear-gradient(to right, transparent, #000 6%, #000 95%, transparent),
    linear-gradient(to bottom, transparent, #000 1.3%, #000 91%, transparent);
  mask-composite: intersect;
}
.face-anchor {
  position: absolute;
  left: 0;
  top: 0;
  width: 800px;
  height: 450px;
  transform-origin: 0 0;
  pointer-events: none;
}
.paper-print,
.leaf-back {
  position: absolute;
  inset: 0;
  border-radius: 22px;
  overflow: hidden;
  color: #383427;
}
.paper-print {
  font-family: Arial, Helvetica, sans-serif;
  text-align: left;
}
.paper-mast {
  position: absolute;
  top: 39px;
  left: 49px;
  right: 49px;
  padding-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid #514831b0;
  color: #484231;
}
.paper-mast b {
  font:
    700 24px/1 Georgia,
    serif;
  letter-spacing: 0.025em;
}
.paper-mast small {
  font:
    17px/1 'Courier New',
    monospace;
  letter-spacing: 0.04em;
}
.state-title {
  position: absolute;
  left: 46px;
  top: 50%;
  transform: translateY(-50%);
  width: 570px;
  font:
    400 110px/0.87 'Cabinet Serif',
    Georgia,
    'Times New Roman',
    serif;
  letter-spacing: -0.061em;
  white-space: pre-line;
}
.state-title.long {
  font-size: 85px;
  line-height: 0.88;
}
.state-title.extra {
  font-size: 70px;
  line-height: 0.93;
}
.paper-stamp {
  position: absolute;
  right: 51px;
  top: 43%;
  transform: rotate(-9deg);
  width: 100px;
  height: 100px;
  border: 3px double #80512d;
  border-radius: 50%;
  display: grid;
  place-content: center;
  text-align: center;
  color: #765033;
  opacity: 0.9;
  box-shadow: inset 0 0 0 6px transparent;
}
.paper-stamp:before {
  content: '';
  position: absolute;
  inset: 5px;
  border: 1px solid currentColor;
  border-radius: 50%;
}
.paper-stamp span {
  font:
    bold 13px/1.1 'Courier New',
    monospace;
  letter-spacing: 0.14em;
}
.paper-stamp b {
  font:
    bold 40px/1.05 'Courier New',
    monospace;
  letter-spacing: -0.065em;
}
.paper-action {
  position: absolute;
  bottom: 64px;
  left: 52px;
  font:
    700 20px/1.25 'Courier New',
    monospace;
  letter-spacing: 0.025em;
  border-bottom: 1px solid #6e604c;
}
.moving-sheet {
  display: none;
  will-change: transform;
}
.moving-sheet .paper-print,
.leaf-back {
  background:
    var(--paper-grain) center/cover,
    #e5cba5;
  border: 1.5px solid #f9e3bd;
  box-shadow: inset 0 -3px 2px #94744773;
}
.leaf-back {
  display: none;
}
.leaf-back:before {
  content: '';
  position: absolute;
  inset: 52px 55px;
  background: repeating-linear-gradient(to bottom, transparent 0 60px, #87674659 61px 62px);
}
.ring,
.wheel-strip,
.hub,
.tab-type {
  position: absolute;
  display: block;
  pointer-events: none;
}
.ring {
  z-index: 5;
}
.wheel-strip {
  overflow: hidden;
}
.wheel-strip img {
  max-width: none;
  height: 100%;
  display: block;
  will-change: transform;
}
.hub {
  border-radius: 50%;
  overflow: hidden;
}
.hub i,
.hub img {
  display: block;
  transform-origin: 50% 50%;
}
.hub img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  will-change: transform;
}
.tab-type {
  font:
    700 18px/1 'Courier New',
    monospace;
  letter-spacing: 0.2em;
  color: #695335;
  text-align: center;
  opacity: 0.84;
}
.tap-card {
  position: absolute;
  inset: 0;
  display: block;
  z-index: 7;
  cursor: pointer;
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
}
.knob-zone {
  position: absolute;
  width: 19%;
  height: 49%;
  z-index: 8;
  cursor: ns-resize;
  pointer-events: auto;
  touch-action: pinch-zoom;
}
.cab-controls {
  height: clamp(90px, 13vh, 120px);
  margin: 0 var(--pad-x);
  border-top: 1px solid #77827665;
  display: grid;
  grid-template-columns: 1fr minmax(230px, 390px) 1fr;
  gap: 32px;
  align-items: center;
  color: var(--cream);
  font:
    15px/1.25 Arial,
    Helvetica,
    sans-serif;
}
.turn-controls,
.view-controls,
.range-label {
  display: flex;
  align-items: center;
}
.turn-controls {
  gap: 8px;
}
.turn-controls button,
.view-button {
  background: transparent;
  border: 1px solid #7d8271;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #eee5d2;
  transition:
    background 0.15s,
    color 0.15s;
}
.turn-controls button:hover,
.view-button:hover {
  background: #e2c9a2;
  color: #20271f;
}
.turn-controls button:focus-visible {
  outline-offset: 2px;
}
.chev {
  display: block;
  width: 9px;
  height: 9px;
  border: solid currentColor;
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(-45deg);
  margin-left: -3px;
}
.chev.back {
  transform: rotate(135deg);
  margin-left: 3px;
}
.play-icon {
  display: block;
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 8px solid currentColor;
  margin-left: 3px;
}
[aria-pressed='true'] .play-icon {
  width: 8px;
  height: 10px;
  margin: 0;
  border: solid currentColor;
  border-width: 0 2px;
}
.rail {
  align-self: center;
}
.range-label {
  justify-content: space-between;
  color: #d9d3c2;
  font:
    12px/1.1 'Courier New',
    monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.rail-track {
  position: relative;
  height: 24px;
  display: flex;
  align-items: center;
}
.rail-track:before {
  content: '';
  height: 7px;
  width: 100%;
  background: repeating-linear-gradient(90deg, #84907b9c 0 1px, transparent 1px calc(2% - 0.02px));
  border-bottom: 1px solid #6e7668;
}
.rail-track input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  appearance: none;
  background: transparent;
  cursor: ew-resize;
}
.rail-track input::-webkit-slider-thumb {
  appearance: none;
  width: 8px;
  height: 17px;
  background: #d2b181;
  border: 1px solid #ebd2a6;
  border-radius: 2px;
}
.rail-track input::-moz-range-thumb {
  width: 7px;
  height: 16px;
  background: #d2b181;
  border: 1px solid #ebd2a6;
  border-radius: 2px;
}
.view-controls {
  justify-content: flex-end;
  gap: 22px;
}
.view-button {
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 0;
  min-width: 70px;
  width: auto;
  font-size: 14px !important;
  white-space: nowrap;
}
.view-button:hover {
  background: none;
  color: #eed3a9;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.view-button:before {
  content: '';
  width: 13px;
  height: 11px;
  display: inline-block;
  border: 1px solid currentColor;
  transform: skewY(-12deg);
}
.open-guide {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  white-space: nowrap;
  border: 1px solid #a69470;
  border-radius: 3px;
  padding: 0 17px;
  font-weight: 600;
  color: #e6d0aa !important;
}
.open-guide:hover {
  background: #dac4a2;
  color: #20271f !important;
}
.cab-help {
  color: #c5c6b6;
  margin-left: 8px;
  font-size: 14px;
}
.screen-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
@media (max-width: 760px) {
  .cab-head {
    height: 61px;
  }
  .cab-controls {
    grid-template-columns: auto 1fr auto;
    gap: 18px;
  }
  .cab-help {
    display: none;
  }
  .view-controls {
    gap: 12px;
  }
  .cab-head nav {
    font-size: 14px;
  }
}
@media (max-width: 560px) {
  .cab-shell {
    min-height: 460px;
  }
  .cab-head {
    height: 58px;
  }
  .cab-controls {
    height: auto;
    min-height: 116px;
    padding: 12px 0 max(14px, env(safe-area-inset-bottom));
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 6px 13px;
  }
  .rail {
    grid-row: 1;
    grid-column: 1/-1;
    min-width: 0;
  }
  .turn-controls {
    grid-column: 1;
    gap: 6px;
  }
  .view-controls {
    grid-column: 2;
    gap: 12px;
    min-width: 0;
  }
  .turn-controls button {
    width: 39px;
    height: 39px;
  }
  .open-guide {
    padding: 0 10px;
    min-height: 39px;
    font-size: 14px;
  }
  .view-button {
    min-width: 54px;
    font-size: 13px !important;
  }
  .view-button:before {
    display: none;
  }
  .art-area {
    inset: 0;
  }
  .machine-frame {
    width: 100%;
    max-height: none;
  }
  .range-label {
    font-size: 12px;
  }
  .cab-head nav {
    gap: 18px;
  }
}
@media (max-height: 480px) and (orientation: landscape) {
  .cab-shell {
    min-height: 285px;
  }
  .cab-head {
    height: 45px;
  }
  .cab-controls {
    height: 58px;
    min-height: 58px;
  }
  .art-area {
    inset: 0;
  }
  .machine-frame {
    width: min(100%, calc((100svh - 103px) * 1.5));
  }
}
@media (prefers-reduced-motion: reduce) {
  .cab-shell,
  .cab-shell * {
    scroll-behavior: auto !important;
  }
  .turn-controls button {
    transition: none;
  }
}
@media (max-width: 560px) and (orientation: portrait) {
  .machine-frame {
    width: 118%;
    max-width: none;
    left: -2.2%;
  }
  .art-area {
    justify-items: center;
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 355px) {
  .cab-controls {
    gap: 6px 8px;
  }
  .view-controls {
    gap: 6px;
  }
  .view-button {
    min-width: 0;
    font-size: 12px !important;
  }
  .open-guide {
    padding: 0 8px;
    font-size: 13px;
  }
  .turn-controls {
    gap: 3px;
  }
}
.leaf-back {
  display: block;
}
.machine-layer[hidden],
.turn-controls button[hidden] {
  display: none;
}

/* Both faces share the projected paper outline and hinge. */
.moving-sheet {
  z-index: 3;
  pointer-events: none;
}
.under-sheet {
  z-index: 2;
}
.rotary-tab {
  position: absolute;
  left: var(--tab-left, 65px);
  top: -25px;
  width: 124px;
  height: 31px;
  background:
    var(--paper-grain) center/cover,
    #e8cca4;
  border: 1px solid #9b784c;
  border-bottom: 0;
  border-radius: 13px 13px 0 0;
  display: grid;
  place-items: center;
  color: #624729;
  font:
    700 15px/1 'Courier New',
    monospace;
  letter-spacing: 0.12em;
}
.moving-sheet .paper-print,
.moving-sheet .leaf-back {
  box-shadow:
    inset 0 2px 1px #fff1d0,
    inset 0 -4px 1px #a47b48;
  border: 1px solid #b79a71;
}
.paper-shade {
  position: absolute;
  inset: 0;
  border-radius: 22px;
  background: linear-gradient(
    167deg,
    rgba(38, 23, 7, 0.57),
    rgba(65, 39, 13, 0.28) 52%,
    rgba(58, 37, 15, 0.07)
  );
  opacity: 0;
  pointer-events: none;
}
.tray-mark {
  position: absolute;
  inset: 0;
  transform: scaleY(-1);
  border-radius: 22px;
  overflow: hidden;
  pointer-events: none;
}
.tray-mark:before {
  content: '';
  position: absolute;
  inset: 42px 46px;
  background: repeating-linear-gradient(to bottom, transparent 0 48px, #88674742 49px 51px);
}
.tray-mark span {
  position: absolute;
  right: 49px;
  bottom: 27px;
  font:
    700 17px/1 'Courier New',
    monospace;
  letter-spacing: 0.08em;
  color: #735c3d;
}
.leaf-back:before {
  display: none;
}
.tray-sheet {
  z-index: 1;
}

/* Static artwork and the directory remain available while the controls are unavailable. */
.cab-controls[hidden] {
  visibility: hidden;
  pointer-events: none;
}
.tap-card[hidden],
.knob-zone[hidden] {
  display: none;
}
.cab-shell:not([data-cabinet-ready]) .rotary-stage5 {
  cursor: auto;
  touch-action: auto;
}
.cab-shell:not([data-cabinet-ready]) .machine-layer {
  width: 100%;
  height: 100%;
  transform: none;
}
.cab-shell:not([data-cabinet-ready]) .machine-layer > :not(picture) {
  display: none;
}
.cab-head nav > a {
  text-decoration: underline;
  text-underline-offset: 0.23em;
}
.cab-shell .site-menu > div {
  z-index: 2;
}
.cab-shell .site-menu[open] > summary {
  color: #f6edd8;
}

.machine-layer[data-view='front'] {
  --paper-grain: url('front-paper.webp');
}
.machine-layer[data-view='front'] .artwork-tab0 {
  left: 470px;
  top: 38px;
  width: 180px;
  transform: rotate(-0.4deg);
}
.machine-layer[data-view='front'] .artwork-tab1 {
  left: 665px;
  top: 20px;
  width: 170px;
  transform: rotate(0.4deg);
}
.machine-layer[data-view='front'] .artwork-tab2 {
  left: 937px;
  top: 31px;
  width: 178px;
  transform: rotate(0.4deg);
}
.machine-layer[data-view='front'] .artwork-knob0 {
  left: 149px;
  top: 285px;
  width: 118px;
  height: 302px;
}
.machine-layer[data-view='front'] .artwork-knob1 {
  left: 1240px;
  top: 269px;
  width: 143px;
  height: 424px;
}
.machine-layer[data-view='front'] .hub {
  left: 1407px;
  top: 438px;
  width: 24px;
  height: 78px;
}
.machine-layer[data-view='front'] .hub i {
  width: 24px;
  height: 24px;
  transform-origin: 0 0;
  transform: scaleY(3.25);
}
.machine-layer[data-view='front'] .artwork-ring0 {
  left: 452px;
  top: 453px;
  width: 55px;
  height: 99px;
}
.machine-layer[data-view='front'] .artwork-ring1 {
  left: 934px;
  top: 456px;
  width: 52px;
  height: 101px;
}

.machine-layer[data-view='side'] {
  --paper-grain: url('side-paper.webp');
}
.machine-layer[data-view='side'] .artwork-tab0 {
  left: 515px;
  top: 55px;
  width: 157px;
  transform: rotate(4deg);
}
.machine-layer[data-view='side'] .artwork-tab1 {
  left: 707px;
  top: 43px;
  width: 160px;
  transform: rotate(4deg);
}
.machine-layer[data-view='side'] .artwork-tab2 {
  left: 895px;
  top: 71px;
  width: 159px;
  transform: rotate(4deg);
}
.machine-layer[data-view='side'] .artwork-knob0 {
  left: 273px;
  top: 260px;
  width: 123px;
  height: 216px;
}
.machine-layer[data-view='side'] .artwork-knob1 {
  left: 1071px;
  top: 314px;
  width: 162px;
  height: 340px;
}
.machine-layer[data-view='side'] .artwork-fan {
  left: 1010px;
  top: 90px;
  width: 268px;
  height: 324px;
}
.machine-layer[data-view='side'] .hub {
  left: 1227px;
  top: 460px;
  width: 64px;
  height: 88px;
}
.machine-layer[data-view='side'] .hub i {
  width: 64px;
  height: 64px;
  transform-origin: 0 0;
  transform: scaleY(1.375);
}
.machine-layer[data-view='side'] .artwork-ring0 {
  left: 457px;
  top: 444px;
  width: 62px;
  height: 91px;
}
.machine-layer[data-view='side'] .artwork-ring1 {
  left: 802px;
  top: 474px;
  width: 65px;
  height: 96px;
}
