:root {
  color-scheme: light;
  --ink: #382c20;
  --muted: #6b5a45;
  --paper: #f1e5ce;
  --green: #214737;
  --rule: #6d543736;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
body {
  font:
    16px/1.6 system-ui,
    sans-serif;
  color: var(--ink);
  background: var(--paper);
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button,
a,
select,
input {
  touch-action: manipulation;
}
button {
  min-height: 46px;
  cursor: pointer;
  border: 0;
  background: none;
  padding: 10px 14px;
}
a {
  color: var(--green);
  text-underline-offset: 4px;
}
button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible,
canvas:focus-visible {
  outline: 3px solid #385f48;
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
.paper {
  background: var(--paper) url(media/agedPaper.webp) repeat center / 320px;
}
.leather {
  background: #493022 url(media/brownLeather.webp) repeat center / 256px;
  color: #f8ecd6;
}
#atlas {
  position: fixed;
  inset: 0;
  overflow: hidden;
  background: #e5d5b5 url(media/agedPaper.webp) repeat center / 320px;
}
#map {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}
#map:active {
  cursor: grabbing;
}
.mast {
  position: fixed;
  left: max(20px, env(safe-area-inset-left));
  top: max(20px, env(safe-area-inset-top));
  display: flex;
  gap: 8px;
  align-items: stretch;
  pointer-events: none;
}
.mast > * {
  pointer-events: auto;
}
.icon {
  width: 54px;
  padding: 14px;
}
.icon svg,
.zoom svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  vertical-align: middle;
}
.title {
  padding: 9px 18px;
  line-height: 1.2;
}
.title span {
  font-size: 10px;
  letter-spacing: 0.18em;
}
.title h1 {
  font:
    22px/1.15 Georgia,
    serif;
  margin: 4px 0 0;
}
.top-right {
  position: fixed;
  right: 20px;
  top: 20px;
}
.top-right button {
  font-size: 13px;
}
.time {
  position: fixed;
  bottom: max(36px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  padding: 9px 15px;
  gap: 16px;
  max-width: calc(100vw - 160px);
}
.kicker {
  font: 10px/1.4 system-ui;
  letter-spacing: 0.14em;
  display: block;
  opacity: 0.75;
}
.time button {
  padding: 0;
  min-height: 38px;
  white-space: nowrap;
}
.time #editionButton {
  font: 28px/1 Georgia;
  letter-spacing: -0.02em;
}
.time #editionButton span {
  font: 17px system-ui;
  margin-left: 16px;
}
.time small {
  display: block;
  font-size: 10px;
  line-height: 1.3;
  opacity: 0.8;
}
.time #layerButton {
  font: 14px/1.3 system-ui;
  text-align: left;
}
.time-rule {
  height: 34px;
  width: 1px;
  background: #f5e4c44d;
}
.zoom {
  position: fixed;
  right: 20px;
  bottom: 66px;
  display: flex;
  flex-direction: column;
}
.zoom button {
  width: 48px;
  height: 47px;
  font: 27px/1 system-ui;
  padding: 8px;
}
.zoom button + button {
  border-top: 1px solid var(--rule);
}
.credits {
  position: fixed;
  left: 0;
  bottom: 0;
  padding: 3px 12px;
  display: flex;
  align-items: center;
  gap: 16px;
  font: 10px/1.5 system-ui;
}
.credits button {
  min-height: 26px;
  font: inherit;
  padding: 2px 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.notice {
  position: fixed;
  top: 96px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 13px;
  padding: 9px 18px;
  max-width: calc(100% - 40px);
  text-align: center;
  pointer-events: none;
}
.notice[hidden] {
  display: none;
}
#pins {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.pin {
  position: absolute;
  pointer-events: auto;
  width: 35px;
  height: 35px;
  min-height: 35px;
  border: 2px solid #f1e5ce;
  border-radius: 50%;
  background: var(--green);
  color: #fff5df;
  font: 16px Georgia;
  padding: 0;
  transform: translate(-50%, -50%);
}
.pin:before {
  content: "";
  position: absolute;
  inset: -7px;
}
.pin:hover {
  background: #5e3d26;
}
.pin::after {
  content: attr(data-name);
  position: absolute;
  left: 42px;
  top: 2px;
  white-space: nowrap;
  display: none;
  background: var(--paper);
  color: var(--ink);
  padding: 3px 8px;
  font: 12px system-ui;
}
.pin:hover::after,
.pin:focus-visible::after {
  display: block;
}
dialog {
  position: fixed;
  left: auto;
  right: 0;
  top: 0;
  bottom: 0;
  margin: 0;
  padding: 0;
  width: 410px;
  max-width: 100vw;
  height: 100dvh;
  max-height: 100dvh;
  border: 0;
  background: var(--paper);
  color: var(--ink);
  overflow: hidden;
}
dialog::backdrop {
  background: #20180c24;
}
dialog[open] {
  display: flex;
  flex-direction: column;
}
.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 25px 20px 22px 28px;
  gap: 15px;
  flex-shrink: 0;
}
.drawer-head h2 {
  font: 27px/1.25 Georgia;
  margin: 7px 0 0;
}
.drawer-head .close {
  font: 30px/1 system-ui;
  padding: 0;
  width: 46px;
  flex-shrink: 0;
  min-height: 46px;
}
.drawer-body {
  padding: 0 28px 32px;
  overflow: auto;
  overscroll-behavior: contain;
  flex: 1;
}
.drawer-body h3 {
  font: 27px/1.2 Georgia;
  margin: 25px 0 16px;
}
.drawer-body h4 {
  font: 20px Georgia;
  margin-bottom: 7px;
}
.drawer-body p {
  font-size: 14px;
  line-height: 1.7;
  margin: 10px 0 18px;
}
.drawer-body p.small,
.small {
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}
.tabs {
  display: flex;
  border-bottom: 1px solid var(--rule);
  margin: 0 -5px;
}
.tabs button {
  padding: 17px 15px;
  font-size: 13px;
  flex: 1;
}
.tabs button[aria-pressed="true"] {
  border-bottom: 2px solid var(--green);
  color: var(--green);
  font-weight: 600;
}
.field {
  display: block;
  font-size: 12px;
  margin: 20px 0;
}
.field select,
.field input {
  display: block;
  width: 100%;
  padding: 13px 10px;
  background: #fbf5e780;
  border: 1px solid var(--rule);
  margin-top: 7px;
  border-radius: 0;
  font-size: 14px;
}
.sheet-option,
.place-option {
  display: block;
  width: 100%;
  text-align: left;
  padding: 15px 0;
  border-bottom: 1px solid var(--rule);
}
.sheet-option span,
.place-option span {
  display: block;
  font-size: 14px;
}
.sheet-option small,
.place-option small {
  display: block;
  font: 12px/1.5 system-ui;
  color: var(--muted);
  margin-top: 4px;
}
.sheet-option[aria-pressed="true"] span:after {
  content: " ✓";
  color: var(--green);
}
.sheet-option[aria-pressed="true"] {
  font-weight: 600;
}
.check {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  min-height: 48px;
}
.check input {
  width: 18px;
  height: 18px;
  accent-color: var(--green);
}
.cabinet-note {
  border-top: 1px solid var(--rule);
  margin-top: 22px;
  padding-top: 20px;
}
.cabinet-note b {
  font: 21px Georgia;
}
.cabinet-note p {
  font-size: 13px;
}
.text-button {
  padding: 0;
  color: var(--green);
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 4px;
  font-size: 13px;
}
footer {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
}
footer a {
  display: block;
  font-size: 13px;
  min-height: 44px;
  padding: 8px 0;
}
.inventory-row {
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
  font-size: 13px;
}
.inventory-row p {
  font-size: 12px;
  margin: 5px 0;
}
.inventory-row a {
  font-size: 12px;
}
.inventory-row em {
  font-size: 11px;
  color: var(--muted);
  display: block;
}
.status-pill {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.05em;
  padding: 2px 6px;
  background: #dadbc7;
  margin: 5px 0;
}
.tab[hidden] {
  display: none;
}
#placeCrop {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 24px;
}
#goToPlace {
  background: var(--green);
  color: #f8ecd6;
  width: 100%;
}
.fallback {
  position: fixed;
  inset: 15%;
  padding: 30px;
}
.tab {
  padding-bottom: 5px;
}
@media (max-width: 600px) {
  .mast {
    left: 12px;
    top: 12px;
    gap: 6px;
  }
  .icon {
    width: 46px;
    padding: 12px;
  }
  .title {
    padding: 9px 11px;
  }
  .title span {
    font-size: 8px;
  }
  .title h1 {
    font-size: 18px;
  }
  .top-right {
    top: 12px;
    right: 12px;
  }
  .top-right button {
    font-size: 0;
    width: 46px;
    padding: 8px;
  }
  .top-right button span {
    font-size: 20px;
  }
  .time {
    bottom: 43px;
    left: 12px;
    transform: none;
    max-width: calc(100vw - 83px);
    padding: 10px 13px;
    gap: 12px;
  }
  .time #editionButton {
    font-size: 25px;
  }
  .time .kicker {
    font-size: 8px;
  }
  .time #layerButton {
    font-size: 12px;
  }
  .time #layerButton small {
    font-size: 9px;
  }
  .time #editionButton span {
    margin-left: 5px;
  }
  .zoom {
    right: 12px;
    bottom: 43px;
  }
  .zoom button {
    width: 44px;
    height: 44px;
  }
  .credits {
    font-size: 9px;
    max-width: 100%;
  }
  .notice {
    top: 84px;
    font-size: 12px;
    width: max-content;
  }
  .drawer-body {
    padding-left: 24px;
    padding-right: 24px;
  }
  .drawer-head {
    padding-left: 24px;
  }
  .pin {
    width: 32px;
    height: 32px;
    min-height: 32px;
  }
}
@media (max-width: 350px) {
  .time-rule {
    display: none;
  }
  .time {
    gap: 8px;
    padding: 9px;
  }
  .time #layerButton {
    max-width: 97px;
    white-space: normal;
  }
  .title h1 {
    font-size: 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
/* Full-screen atlas: source identity lives in the map cabinet. */
.mast {
  left: auto;
  right: max(16px, env(safe-area-inset-right));
  top: max(16px, env(safe-area-inset-top));
}
.mast .icon {
  width: 52px;
  height: 52px;
  padding: 14px;
}
.leather {
  border: 0;
  background: #493022 url(media/brownLeather.webp) repeat center / 256px;
  border-image: url(media/stitchedLeather.webp) 200 240 fill / 25px / 0 stretch;
}
.mast .leather {
  border-image-width: 12px;
}
.drawer-head.leather {
  border-image-width: 30px;
  padding: 28px 24px 26px 32px;
}
.timeline {
  position: fixed;
  bottom: 34px;
  left: 50%;
  transform: translateX(-50%);
  width: min(580px, calc(100vw - 108px));
  padding: 13px 24px 12px;
  z-index: 2;
}
.timeline-controls {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 38px;
}
.timeline-controls button {
  padding: 3px 8px;
  min-width: 36px;
  min-height: 38px;
  font-size: 20px;
  color: #f6e8cf;
}
.timeline-controls #layerButton {
  font: 12px system-ui;
  margin-left: auto;
  white-space: nowrap;
  padding-left: 10px;
}
.year-choice select {
  font: 18px Georgia;
  color: #f8ead2;
  border: 0;
  border-radius: 0;
  background: #40291d;
  padding: 6px 4px;
  max-width: 150px;
  min-height: 38px;
}
.timeline-track {
  padding-top: 3px;
}
.timeline-track input {
  display: block;
  width: 100%;
  height: 16px;
  margin: 0;
  accent-color: #d7b67b;
  cursor: ew-resize;
  touch-action: pan-y;
}
.timeline-ticks {
  display: flex;
  justify-content: space-between;
  font: 9px system-ui;
  opacity: 0.8;
  padding-top: 1px;
}
.timeline-help {
  font: 9px system-ui;
  display: block;
  opacity: 0.8;
  text-align: center;
  padding-top: 4px;
}
.timeline-controls button:disabled {
  opacity: 0.38;
}
.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;
}
.empty-year {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 28px;
  text-align: center;
  max-width: calc(100vw - 40px);
  width: 390px;
}
.empty-year[hidden] {
  display: none;
}
.empty-year h2 {
  font: 27px Georgia;
  margin: 0 0 12px;
}
.empty-year p {
  font: 14px/1.6 system-ui;
}
.empty-year button {
  background: var(--green);
  color: #f6e8cf;
  width: 100%;
  margin-top: 8px;
}
.zoom {
  bottom: 155px;
}
.notice {
  top: 18px;
  max-width: calc(100vw - 100px);
}
@media (max-width: 600px) {
  .mast {
    right: 12px;
    left: auto;
    top: 12px;
  }
  .mast .icon {
    width: 46px;
    height: 46px;
    padding: 12px;
  }
  .timeline {
    bottom: 34px;
    left: 10px;
    transform: none;
    width: calc(100vw - 20px);
    padding: 13px 20px 12px;
  }
  .timeline-controls #layerButton {
    font-size: 11px;
  }
  .timeline-controls button {
    min-width: 32px;
    padding: 4px;
  }
  .year-choice select {
    font-size: 17px;
    max-width: 142px;
  }
  .zoom {
    right: 12px;
    bottom: 158px;
  }
  .notice {
    top: 12px;
    left: 12px;
    transform: none;
    max-width: calc(100vw - 82px);
    font-size: 11px;
  }
  .timeline-help {
    font-size: 8px;
  }
  .timeline-ticks {
    font-size: 8px;
  }
}
.timeline-controls button {
  min-height: 44px;
  min-width: 44px;
}
.timeline-controls {
  height: 44px;
}
.year-choice {
  min-width: 0;
  flex: 0 1 145px;
}
.year-choice select {
  width: 100%;
  min-height: 44px;
}
.timeline-track input {
  height: 26px;
}
.timeline-help {
  font-size: 10px;
}
@media (max-width: 600px) {
  .year-choice {
    flex-basis: 120px;
  }
  .timeline {
    padding-left: 16px;
    padding-right: 16px;
  }
  .timeline-help {
    font-size: 10px;
  }
}
@media (max-width: 390px) {
  .year-choice {
    flex: 0 0 80px;
  }
  .year-choice select {
    font-size: 14px;
    padding: 5px 0;
  }
  .timeline-controls #layerButton {
    width: 44px;
    min-width: 44px;
    padding: 4px;
    margin-left: 0;
  }
  .timeline-controls #layerLabel {
    display: none;
  }
  .timeline-controls #layerButton:before {
    content: "▤";
    font-size: 20px;
  }
  .timeline-controls #layerButton span[aria-hidden] {
    display: none;
  }
}
/* Fixed authored corner pieces keep stitching and ornaments at a consistent size. */
.leather {
  border-image-slice: 90 120 fill;
  border-image-width: 28px;
}
.mast .leather {
  border-image-width: 14px;
}
.drawer-head.leather {
  border-image-width: 34px;
}
/* Zoom controls belong to the same stitched map case as the cabinet. */
.zoom {
  background: none;
  gap: 3px;
}
.zoom button.leather {
  border-image-width: 12px;
  color: #ebce95;
  font-family: Georgia, serif;
  width: 50px;
  height: 50px;
}
.zoom button.leather:hover {
  filter: brightness(1.12);
}
.zoom button.leather:active {
  filter: brightness(0.92);
}
.zoom button.leather:focus-visible {
  outline-color: #f1dbad;
  outline-offset: 3px;
}
.zoom button + button {
  border-top: 0;
}
.zoom svg {
  stroke-width: 1.5;
}
@media (max-width: 600px) {
  .zoom button.leather {
    width: 46px;
    height: 46px;
  }
}

/* Antique fittings are PNG artwork; native controls retain their labels and keyboard support. */
.brass-symbol {
  display: inline-block;
  width: 40px;
  height: 40px;
  flex: none;
  background-image: url(media/brassControls.png);
  background-size: 300% 300%;
  background-repeat: no-repeat;
  vertical-align: middle;
  pointer-events: none;
}
.brass-plus {
  background-position: 0 0;
}
.brass-minus {
  background-position: 50% 0;
}
.brass-fit {
  background-position: 100% 0;
}
.brass-previous {
  background-position: 0 50%;
}
.brass-next {
  background-position: 50% 50%;
}
.brass-play {
  background-position: 100% 50%;
}
.brass-pause {
  background-position: 0 100%;
}
.brass-menu {
  background-position: 50% 100%;
}
.brass-layers {
  background-position: 100% 100%;
}
.mast .leather,
.zoom button.leather {
  border-image: url(media/stitchedLeather.webp) 90 120 fill / 14px / 0 stretch;
  width: 54px;
  height: 54px;
  padding: 7px;
  display: grid;
  place-items: center;
}
.zoom {
  gap: 5px;
}
.timeline-controls button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.timeline-controls .brass-symbol {
  width: 38px;
  height: 38px;
}
.year-choice {
  background: transparent;
  border-image: url(media/brassPlaque.png) 42 74 fill / 10px 17px / 0 stretch;
  padding: 0 9px;
}
.year-choice select {
  background: transparent;
  color: #302415;
  font:
    bold 16px Georgia,
    serif;
  padding: 4px 14px 4px 3px;
  max-width: 100%;
}
.year-choice select option {
  background: #efe2c5;
  color: #382c20;
}
.timeline-controls #layerButton {
  background: transparent;
  border-image: url(media/brassPlaque.png) 42 74 fill / 10px 17px / 0 stretch;
  padding: 0 12px;
  gap: 2px;
  color: #302415;
  font:
    12px Georgia,
    serif;
  min-width: 44px;
}
#layerLabel {
  display: inline-block;
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}
.timeline-controls #layerButton .brass-symbol {
  width: 30px;
  height: 30px;
}
.timeline-controls #layerButton:before {
  content: none;
}
.timeline-ticks,
.timeline-help {
  color: #e1c48d;
  opacity: 1;
  font-family: Georgia, serif;
}
.timeline-track input {
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  height: 30px;
  outline-offset: 3px;
}
.timeline-track input::-webkit-slider-runnable-track {
  height: 9px;
  background: url(media/brassPlaque.png) center/100% 100% no-repeat;
}
.timeline-track input::-moz-range-track {
  height: 9px;
  background: url(media/brassPlaque.png) center/100% 100% no-repeat;
}
.timeline-track input::-webkit-slider-thumb {
  appearance: none;
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  border: 1px solid #382915;
  border-radius: 50%;
  background: #b99a54 url(media/brassPlaque.png) center/auto 30px;
  margin-top: -7px;
  box-shadow: 0 0 0 2px #5e4224;
}
.timeline-track input::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border: 1px solid #382915;
  border-radius: 50%;
  background: #b99a54 url(media/brassPlaque.png) center/auto 30px;
  box-shadow: 0 0 0 2px #5e4224;
}
.timeline-track input:disabled {
  opacity: 0.4;
  cursor: default;
}
.sheet-option {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  width: 100%;
}
.sheet-option img {
  width: 84px;
  height: 64px;
  object-fit: contain;
  flex: none;
}
.sheet-option div {
  min-width: 0;
}
.sheet-option span {
  overflow-wrap: anywhere;
}
.credits {
  max-width: calc(100vw - 12px);
}
.credits button {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 600px) {
  .mast .leather,
  .zoom button.leather {
    width: 50px;
    height: 50px;
    padding: 5px;
  }
  .timeline-controls #layerButton {
    width: 44px;
    padding: 0;
  }
  .timeline-controls #layerLabel {
    display: none;
  }
  .timeline-controls #layerButton .brass-symbol {
    display: inline-block;
  }
  .year-choice {
    flex: 1 1 90px;
    min-width: 0;
    padding: 0 6px;
  }
  .year-choice select {
    font-size: 14px;
    padding-left: 2px;
  }
  .timeline-controls {
    gap: 2px;
  }
}
@media (forced-colors: active) {
  .brass-symbol {
    background-image: none;
    color: ButtonText;
    font: 24px/40px serif;
  }
  .brass-plus:before {
    content: "+";
  }
  .brass-minus:before {
    content: "−";
  }
  .brass-fit:before {
    content: "↔";
  }
  .brass-previous:before {
    content: "‹";
  }
  .brass-next:before {
    content: "›";
  }
  .brass-play:before {
    content: "▶";
  }
  .brass-pause:before {
    content: "Ⅱ";
  }
  .brass-menu:before {
    content: "☰";
  }
  .brass-layers:before {
    content: "▤";
  }
  .year-choice,
  .timeline-controls #layerButton {
    border: 1px solid ButtonText;
  }
  .timeline-track input {
    appearance: auto;
    -webkit-appearance: auto;
  }
}

/* A surveyor's rotating index opens a paper chart register above the map rail. */
.year-choice {
  padding: 0;
}
.year-choice > select[hidden],
.edition-trigger[hidden],
.edition-popover[hidden] {
  display: none;
}
.timeline-controls .edition-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3px;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 4px 9px;
  color: #332617;
  font:
    bold 17px Georgia,
    serif;
}
.edition-trigger:focus {
  outline: none;
}
.edition-trigger:focus-visible {
  outline: 1px dashed #654b22;
  outline-offset: -6px;
}
.edition-trigger[aria-expanded="true"] {
  background: #684a1612;
}
#editionValue {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.navigator-dial {
  position: relative;
  display: block;
  flex: none;
  width: 27px;
  height: 27px;
  border: 1px solid #73542b;
  border-radius: 50%;
  background: #c5a15c url(media/brassPlaque.png) center/auto 40px;
}
.navigator-dial:before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 50%;
  background: repeating-conic-gradient(#60451f 0deg 2deg, transparent 2deg 30deg);
  mask-image: radial-gradient(transparent 49%, #000 52%, #000 65%, transparent 69%);
}
.navigator-dial:after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 50%;
  background: #49331b;
}
.navigator-needle {
  position: absolute;
  inset: 3px;
  background: url(media/brassControls.png) 50% 0/300% 300%;
  transform: rotate(var(--dial-bearing, 0deg));
}
.timeline-controls .edition-chevron {
  width: 18px;
  height: 18px;
  transform: rotate(-90deg);
}
.edition-trigger[aria-expanded="true"] .edition-chevron {
  transform: rotate(90deg);
}
.edition-popover {
  position: absolute;
  z-index: 5;
  left: 50%;
  bottom: calc(100% + 12px);
  transform: translateX(-50%);
  width: min(380px, calc(100vw - 28px));
  padding: 14px 15px 12px;
  color: #392c1c;
}
.edition-index-heading {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 3px 8px 12px;
  color: #6e5125;
  font:
    11px Georgia,
    serif;
  letter-spacing: 0.12em;
}
.edition-index-heading small {
  font-size: 11px;
  letter-spacing: 0;
  white-space: nowrap;
}
.edition-index-rule {
  height: 1px;
  flex: 1;
  background: #b69a66;
}
#editionList {
  max-height: min(330px, 43dvh, max(60px, calc(100dvh - 280px)));
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #9b7842 #e6d6b6;
}
.edition-option {
  position: relative;
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 8px 10px 8px 21px;
  border-bottom: 1px solid #8a6f3c2b;
  cursor: pointer;
}
.edition-option:before {
  content: "";
  position: absolute;
  left: 5px;
  top: 50%;
  width: 7px;
  height: 1px;
  background: #a58247;
}
.edition-option.is-active {
  background: #a87d2824;
}
.edition-option[aria-selected="true"] {
  color: #382819;
  background: #ac842b18;
}
.edition-option[aria-selected="true"]:before {
  width: 10px;
  height: 10px;
  left: 2px;
  margin-top: -5px;
  background: url(media/brassControls.png) 100% 50%/300% 300%;
}
.edition-date {
  font:
    bold 21px/1.2 Georgia,
    serif;
}
.edition-caption {
  font:
    12px/1.35 Georgia,
    serif;
  color: #705b3c;
}
@media (max-width: 600px) {
  .timeline-controls .edition-trigger {
    font-size: 15px;
    padding: 4px 7px;
  }
  .navigator-dial {
    width: 23px;
    height: 23px;
  }
  .navigator-dial:after {
    inset: 8px;
  }
}
@media (max-width: 390px) {
  .navigator-dial {
    display: none;
  }
  .timeline-controls .edition-trigger {
    font-size: 13px;
    padding: 4px 7px;
  }
  .timeline-controls .edition-chevron {
    width: 14px;
    height: 14px;
  }
}
@media (forced-colors: active) {
  .edition-popover {
    border: 1px solid CanvasText;
    background: Canvas;
    color: CanvasText;
  }
  .edition-trigger:focus-visible {
    outline: 2px solid Highlight;
  }
  .edition-option.is-active {
    outline: 2px solid Highlight;
    outline-offset: -2px;
  }
  .edition-caption {
    color: CanvasText;
  }
}
.edition-option {
  grid-template-columns: 100px minmax(0, 1fr);
}
.edition-date {
  white-space: nowrap;
  font-size: 20px;
}
.edition-trigger:focus-visible {
  outline: none;
}
.edition-trigger:focus-visible #editionValue {
  text-decoration: underline;
  text-decoration-color: #705120;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}
@media (min-width: 601px) {
  .year-choice {
    flex: 0 0 176px;
  }
  .timeline-controls #layerButton {
    flex: 0 1 180px;
    min-width: 44px;
    overflow: hidden;
  }
  #layerLabel {
    min-width: 0;
    flex: 0 1 auto;
  }
}
@media (max-width: 390px) {
  .timeline-controls .edition-trigger {
    padding: 4px;
    gap: 1px;
  }
  .timeline-controls .edition-chevron {
    width: 12px;
    height: 12px;
  }
}
@media (forced-colors: active) {
  .edition-trigger:focus-visible {
    outline: 2px solid Highlight;
    outline-offset: -3px;
  }
}

/* Screenshot signature and cartographic fittings. */
.map-watermark {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  left: max(16px, env(safe-area-inset-left));
  width: clamp(170px, 29vw, 260px);
  height: auto;
  opacity: 0.58;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}
#menuButton {
  padding: 0;
  display: grid;
  place-items: center;
}
#menuButton .brass-menu {
  transform: translateY(2px);
}
.zoom {
  bottom: calc(34px + var(--timeline-height, 150px) + 14px);
}
.timeline-track input::-webkit-slider-thumb {
  width: 32px;
  height: 32px;
  margin-top: -12px;
  border: 0;
  background: url(media/compassThumb.svg) center / contain no-repeat;
  box-shadow: none;
}
.timeline-track input::-moz-range-thumb {
  width: 32px;
  height: 32px;
  border: 0;
  background: url(media/compassThumb.svg) center / contain no-repeat;
  box-shadow: none;
}
@media (max-width: 600px) {
  .map-watermark {
    top: 12px;
    left: 12px;
  }
}

.notice {
  top: max(76px, calc(env(safe-area-inset-top) + 60px));
}

/* The source label is part of the leather case, with brass lettering. */
:root {
  --timeline-bottom: max(16px, env(safe-area-inset-bottom));
}
.timeline {
  bottom: var(--timeline-bottom);
  filter: drop-shadow(0 0 3px #291a1266) drop-shadow(0 0 10px #291a1250);
}
.timeline .credits {
  position: static;
  width: 100%;
  max-width: 100%;
  margin-top: 5px;
  padding: 4px 0 0;
  gap: 12px;
  border-top: 1px solid #c5a36755;
  color: #e2c58c;
  font:
    11px/1.4 Georgia,
    serif;
  text-shadow: 0 0 1px #24150e;
}
.timeline .credits button {
  flex: 1;
  min-width: 0;
  min-height: 30px;
  text-align: left;
  text-decoration-color: #c5a36788;
}
.zoom-readout {
  flex: none;
  font-variant-numeric: tabular-nums;
}
.zoom-caption {
  font-size: 9px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.8;
  margin-right: 4px;
}
.zoom {
  bottom: calc(var(--timeline-bottom) + var(--timeline-height, 180px) + 14px);
}
#menuButton,
.zoom button.leather {
  filter: drop-shadow(0 0 2px #291a1266) drop-shadow(0 0 6px #291a1250);
}
#menuButton:hover,
.zoom button.leather:hover {
  filter: brightness(1.1) drop-shadow(0 0 2px #291a1266) drop-shadow(0 0 6px #291a1250);
}
#menuButton:active,
.zoom button.leather:active {
  filter: brightness(0.94) drop-shadow(0 0 2px #291a1266);
}
.edition-popover:not([hidden]) {
  box-shadow:
    0 0 5px #291a1255,
    0 0 18px #291a1244;
}
.notice {
  box-shadow:
    0 0 3px #291a1240,
    0 0 10px #291a1233;
}
@media (max-width: 390px) {
  .timeline .credits {
    font-size: 10px;
    gap: 8px;
  }
  .zoom-caption {
    display: none;
  }
}

/* Overhead light: material shadows have equal spread on every side. */
dialog {
  box-shadow:
    0 0 5px #291a1266,
    0 0 22px #291a1255;
}
.drawer-head.leather {
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 0 3px #291a1277) drop-shadow(0 0 8px #291a1244);
}
.drawer-body.paper {
  background-color: #e1cba5;
  background-image:
    linear-gradient(90deg, #85531f24, transparent 12%, transparent 88%, #85531f24),
    url(media/agedPaper.webp);
  background-size:
    100% 100%,
    480px 480px;
  background-blend-mode: multiply;
}
.tabs {
  margin: 0 -28px 18px;
  padding: 10px 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 0;
  border-image: url(media/brassPlaque.png) 42 74 fill / 10px 17px / 0 stretch;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 5px #39261055;
}
.tabs button {
  position: relative;
  padding: 9px 4px;
  min-height: 44px;
  border: 0;
  border-radius: 2px;
  background: transparent;
  color: #392b18;
  font:
    15px/1.2 Georgia,
    serif;
  letter-spacing: 0.02em;
}
.tabs button + button {
  border-left: 1px solid #72522377;
}
.tabs button[aria-pressed="true"] {
  border-bottom: 0;
  background: #3d2b18;
  color: #f3d79a;
  font-weight: 600;
  box-shadow:
    inset 0 0 0 1px #806334,
    inset 0 0 5px #1d120c88;
}
.tabs button:hover {
  background-color: #5a3e1a22;
}
.tabs button[aria-pressed="true"]:hover {
  background-color: #49341e;
}
.tabs button:focus-visible {
  outline: 2px solid #493219;
  outline-offset: -3px;
}
.timeline .credits .zoom-readout {
  flex: none;
  min-height: 30px;
  padding: 4px 0 4px 8px;
  text-align: right;
  white-space: nowrap;
  text-decoration: none;
  color: #efd496;
}
.timeline .credits .zoom-readout:hover {
  color: #fff0bd;
  text-decoration: underline;
}
.timeline .credits .zoom-readout:focus-visible {
  outline: 2px solid #d9b875;
  outline-offset: 2px;
}
@media (max-width: 600px) {
  .tabs {
    margin-left: -24px;
    margin-right: -24px;
  }
}
@media (forced-colors: active) {
  .tabs {
    border: 1px solid ButtonText;
    border-image: none;
  }
  .tabs button[aria-pressed="true"] {
    outline: 2px solid Highlight;
    outline-offset: -4px;
  }
}

/* The chart index has its own portrait frame; its corners never stretch. */
.edition-popover:not([hidden]) {
  border: 0;
  border-image: url(media/chartFrame.png) 80 / 26px / 0 round;
  padding: 28px 24px 24px;
  background: #efe0bf url(media/agedPaper.webp) repeat center / 480px;
  border-radius: 3px;
}
.edition-index-heading {
  padding: 0 4px 12px;
  gap: 6px;
  font-size: 10px;
}
.edition-index-heading small {
  font-size: 10px;
}
.edition-option {
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 8px;
  padding: 10px 8px 10px 18px;
  min-height: 56px;
}
.edition-date {
  font-size: 23px;
}
.edition-caption {
  font-size: 12px;
  line-height: 1.45;
}
.edition-option:hover,
.edition-option.is-active {
  background: #ad874d28;
}
.edition-option[aria-selected="true"] {
  background: #ad874d3d;
  box-shadow: inset 2px 0 #91642d;
}

/* Inset, individually fitted brass tabs keep the artwork's proportions. */
.tabs {
  margin: 16px 0 20px;
  padding: 0;
  gap: 6px;
  background: transparent;
  border-image: none;
  box-shadow: none;
}
.tabs button {
  border: 0;
  border-image: none;
  padding: 10px 4px;
  background: url(media/brassPlaque.png) center / contain no-repeat;
  color: #49341d;
  font-size: 14px;
  min-height: 44px;
  box-shadow: none;
  text-shadow: 0 0 1px #f2deb066;
}
.tabs button + button {
  border-left: 0;
}
.tabs button[aria-pressed="true"],
.tabs button[aria-pressed="true"]:hover {
  background: url(media/brassPlaque.png) center / contain no-repeat;
  color: #31200e;
  box-shadow: none;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-color: #8c5b28;
}
.tabs button:hover {
  background-color: transparent;
  filter: brightness(1.13);
}
.tabs button[aria-pressed="true"]::after {
  content: "◆";
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  color: #8d622d;
  font-size: 9px;
}
.tabs button:focus-visible {
  outline-color: #91642d;
  outline-offset: 1px;
}
.sheet-option {
  border-radius: 3px;
}
.sheet-option:hover,
.sheet-option:focus-visible {
  background: #f5e4ba99;
  box-shadow: inset 0 0 0 1px #a27e45;
}
.sheet-option:hover img {
  filter: contrast(1.08);
}
.sheet-option[aria-pressed="true"] {
  background: #c4a16d4d;
  box-shadow: inset 3px 0 #8b6130;
}
@media (prefers-reduced-motion: no-preference) {
  .sheet-option {
    transition:
      background-color 140ms ease,
      box-shadow 140ms ease;
  }
}

/* End ornaments stay fixed while the ruler's middle repeats. */
.timeline-track {
  position: relative;
}
.timeline-track::before {
  content: "";
  position: absolute;
  top: 3px;
  left: 0;
  right: 0;
  height: 32px;
  border-image: url(media/timelineRail.png) 0 96 fill / 0 35px / 0 round;
  pointer-events: none;
}
.timeline-track input {
  position: relative;
  height: 32px;
  z-index: 1;
}
.timeline-track input::-webkit-slider-runnable-track {
  background: transparent;
}
.timeline-track input::-moz-range-track {
  background: transparent;
}
.timeline-events {
  position: absolute;
  top: 3px;
  left: 16px;
  right: 16px;
  height: 32px;
  z-index: 2;
  pointer-events: none;
}
.timeline-event {
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  min-width: 20px;
  max-width: 20px;
  min-height: 20px;
  max-height: 20px;
  aspect-ratio: 1;
  padding: 0;
  cursor: pointer;
  position: absolute;
  top: 6px;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  transform: translateX(-50%);
  pointer-events: auto;
  border: 1px solid #795325;
  border-radius: 50%;
  background: #c5a05a;
  box-shadow: 0 0 3px #281a0e88;
  color: #483017;
  font:
    16px/1 Georgia,
    serif;
  text-decoration: none;
}
.timeline-event:hover,
.timeline-event:focus-visible {
  background: #efd394;
  outline: 2px solid #f1ddb3;
  outline-offset: 2px;
}
.timeline .credits #creditsButton {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.original-download {
  flex: none;
  color: #e9cc91;
  font:
    10px/1.4 Georgia,
    serif;
  white-space: nowrap;
  padding: 7px 0;
}
.original-download[hidden] {
  display: none;
}
.inventory-download {
  display: inline-block;
  margin-top: 8px;
}

#provenanceView {
  width: min(100vw, 1000px);
  box-shadow:
    0 0 8px #291a1277,
    0 0 24px #291a1266;
  background: #eeddbb url(media/agedPaper.webp) repeat center/480px;
}
#provenanceContent {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.provenance-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  width: 44px;
  height: 44px;
  padding: 0;
  font:
    30px/1 Georgia,
    serif;
  color: #ecd4a0;
  background: #493022 url(media/brownLeather.webp);
  border-image: url(media/stitchedLeather.webp) 90 120 fill / 10px / 0 stretch;
  box-shadow: 0 0 6px #291a1266;
}
.provenance-page {
  line-height: 1.7;
}
.provenance-page header {
  padding: 30px 74px 30px 28px;
  background: #493022 url(media/brownLeather.webp);
  border-image: url(media/stitchedLeather.webp) 90 120 fill / 24px / 0 stretch;
  color: #f4e1bd;
}
.provenance-page header a {
  color: inherit;
}
.provenance-page h1 {
  font:
    clamp(28px, 5vw, 40px)/1.2 Georgia,
    serif;
}
.provenance-page main {
  max-width: 960px;
  margin: auto;
  padding: 24px;
}
.provenance-page nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
}
.provenance-page article {
  padding: 25px 0;
  border-top: 1px solid #a9916c;
  scroll-margin-top: 18px;
}
.provenance-page h2 {
  font:
    26px/1.25 Georgia,
    serif;
}
.provenance-page dl {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 10px;
}
.provenance-page dt {
  font-weight: 600;
}
.provenance-page dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.provenance-page code,
.provenance-page .small {
  font-size: 12px;
}
.provenance-page aside {
  padding: 18px;
  margin: 20px 0;
  border: 1px solid #a9916c;
}
@media (max-width: 520px) {
  .provenance-page dl {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .provenance-page dd {
    margin-bottom: 12px;
  }
}
@media (forced-colors: active) {
  .tabs button {
    background: Canvas;
    border: 1px solid ButtonText;
    color: ButtonText;
  }
  .tabs button[aria-pressed="true"] {
    outline: 2px solid Highlight;
  }
  .edition-popover:not([hidden]) {
    border-image: none;
    border: 1px solid CanvasText;
  }
  .timeline-event {
    background: Canvas;
    color: LinkText;
  }
}

@media (max-width: 390px) {
  .edition-option {
    grid-template-columns: 86px minmax(0, 1fr);
  }
  .edition-date {
    font-size: 18px;
  }
  .edition-caption {
    font-size: 11px;
  }
}

/* Fixed-proportion London corner art joins independently repeating engraved edges. */
:root {
  --map-corner-size: clamp(64px, 12vw, 112px);
  --map-rim-size: 8px;
}
.map-decoration {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 1;
  pointer-events: none;
  user-select: none;
  filter: drop-shadow(0 0 1px #2f200b66) drop-shadow(0 0 3px #2f200b44);
}
/* Opaque backing seals the perimeter, including alpha margins in the corner art. */
.map-decoration::before {
  content: "";
  position: absolute;
  inset: 0;
  border: var(--map-rim-size) solid #b18a44;
  box-shadow: inset 0 0 0 1px #60431e;
}
.map-decoration[hidden] {
  display: none;
}
.map-corner {
  position: absolute;
  width: var(--map-corner-size);
  height: var(--map-corner-size);
  background: url(media/londonAnimalCorners.png) 0 0 / 200% 200% no-repeat;
}
.map-corner-nw {
  top: 0;
  left: 0;
}
.map-corner-ne {
  top: 0;
  right: 0;
  background-position: 100% 0;
}
.map-corner-sw {
  bottom: 0;
  left: 0;
  background-position: 0 100%;
}
.map-corner-se {
  bottom: 0;
  right: 0;
  background-position: 100% 100%;
}
.map-edge {
  position: absolute;
}
.map-edge-top,
.map-edge-bottom {
  left: calc(var(--map-corner-size) * 0.75);
  right: calc(var(--map-corner-size) * 0.75);
  height: var(--map-rim-size);
  background: url(media/brassMapEdge.svg) repeat-x center / 32px 8px;
}
.map-edge-top {
  top: 0;
}
.map-edge-bottom {
  bottom: 0;
}
.map-edge-left,
.map-edge-right {
  top: calc(var(--map-corner-size) * 0.75);
  bottom: calc(var(--map-corner-size) * 0.75);
  width: var(--map-rim-size);
  background: url(media/brassMapEdgeVertical.svg) repeat-y center / 8px 32px;
}
.map-edge-left {
  left: 0;
}
.map-edge-right {
  right: 0;
}
.map-frame-rosette {
  position: absolute;
  top: 0;
  left: calc(50% - 12px);
  width: 24px;
  height: 24px;
  background: url(media/compassThumb.svg) center / contain no-repeat;
}
.mast {
  z-index: 3;
}
.zoom {
  z-index: 2;
  right: max(12px, env(safe-area-inset-right));
}
.map-frame-off .zoom {
  right: max(12px, env(safe-area-inset-right));
}
@media (max-height: 560px) {
  :root {
    --map-corner-size: 52px;
  }
}
@media (max-width: 390px) {
  .map-frame-rosette {
    width: 18px;
    height: 18px;
    left: calc(50% - 9px);
    top: -2px;
  }
}
@media (forced-colors: active), print {
  .map-decoration {
    display: none;
  }
  .zoom {
    right: 12px;
  }
}

.zoom {
  bottom: calc(var(--timeline-bottom) + var(--timeline-height, 180px) + 32px);
}
@media (max-height: 560px) {
  .zoom {
    flex-direction: row;
    bottom: calc(var(--timeline-bottom) + var(--timeline-height, 180px) + 20px);
  }
}
@media (max-width: 390px) {
  .map-frame-rosette {
    top: 0;
  }
}

/* Remove every painted part of the chart index when its picker is closed. */
#editionPopover[hidden] {
  display: none !important;
  visibility: hidden;
  border: 0;
  border-image: none;
  background: none;
  box-shadow: none;
  filter: none;
  pointer-events: none;
}

/* The postal signature follows the timeline; cabinet and zoom share one column. */
.timeline .map-watermark {
  position: absolute;
  top: auto;
  bottom: calc(100% + 12px);
  left: 0;
  width: clamp(170px, 29vw, 260px);
}
.zoom {
  flex-direction: column;
}
@media (max-height: 560px) {
  .zoom button.leather {
    width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
  }
  .zoom .brass-symbol {
    width: 24px;
    height: 24px;
  }
}

.cabinet-home {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 24px;
  margin: 0 0 16px;
  border: 1px solid transparent;
  border-image: url(media/brassPlaque.png) 42 74 fill / 10px 18px / 0 stretch;
  color: #392b18;
  font:
    15px/1.4 Georgia,
    serif;
  text-decoration: none;
  box-shadow: 0 0 5px #39261055;
}
.cabinet-home:hover {
  filter: brightness(1.08);
  text-decoration: underline;
}
.cabinet-home:focus-visible {
  outline: 2px solid #795325;
  outline-offset: 3px;
}
@media (forced-colors: active) {
  .cabinet-home {
    border: 1px solid LinkText;
    border-image: none;
    color: LinkText;
    box-shadow: none;
  }
}
