:root {
  color-scheme: dark;
  --dark: #10202a;
  --stage: #203441;
  --sheet: #f3efe7;
  --ink: #1e2d35;
  --muted: #52626c;
  --gold: #dab784;
  --edge: #38505d;
  --max: 1570px;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 18px; }
body { margin: 0; color: #f7f3e9; background: var(--dark); }
button, input { font: inherit; }
button, a, summary, input[type="range"] { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, summary:focus-visible, input:focus-visible { outline: 3px solid #c58843; outline-offset: 4px; }
a { color: inherit; }
img, canvas { display: block; }
[hidden] { display: none !important; }
.site-header, .intro, .exhibit, .exhibit-note, .archive-section, .voyage, .footer { padding-inline: clamp(16px, 4vw, 68px); }
.site-header, .intro, .exhibit, .exhibit-note, .section-title, .gallery, .documents, .document-heading, .method, .footer {
  max-width: var(--max); margin-inline: auto;
}
.site-header {
  min-height: 69px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border-bottom: 1px solid #ffffff19;
}
.wordmark { display: flex; align-items: center; gap: 11px; text-decoration: none; font-family: Georgia, serif; font-size: 1rem; letter-spacing: .12em; white-space: nowrap; }
.mark { color: var(--gold); display: inline-grid; place-items: center; border: 1px solid #aa865d; width: 34px; height: 34px; border-radius: 50%; font-size: 1.2rem; letter-spacing: 0; }
.site-header nav { display: flex; align-items: center; gap: clamp(8px, 2vw, 28px); }
.site-header nav a { color: #bac9cf; text-decoration: none; font-size: .9375rem; padding: 15px 0; white-space: nowrap; }
.site-header nav a:hover, .site-header nav a[aria-current] { color: #fff0d9; }
.intro { display: flex; justify-content: space-between; align-items: end; gap: 20px; padding-top: clamp(23px, 3.3vw, 52px); padding-bottom: 23px; }
.dateline { color: var(--gold); letter-spacing: .12em; font-size: .875rem; font-weight: 600; display: flex; align-items: center; gap: .65em; }
.dateline span { width: 14px; height: 1px; background: currentColor; }
h1, h2, h3, p, dl, dd { margin: 0; }
h1 { font-family: "Songti SC", "STSong", "Noto Serif CJK SC", Georgia, serif; font-size: clamp(2.8rem, 5.7vw, 5.8rem); line-height: 1.06; letter-spacing: -.045em; margin: .09em 0 .17em; font-weight: 700; }
.intro p { color: #c3d1d7; font-size: clamp(1rem, 1.4vw, 1.08rem); line-height: 1.7; }
.measurements { display: flex; flex: 0 0 auto; gap: clamp(16px, 2.5vw, 38px); padding-bottom: 6px; }
.measurements div { border-left: 1px solid var(--edge); padding-left: clamp(10px, 1.4vw, 20px); }
.measurements dt { color: #b4c3c8; font-size: .875rem; margin-bottom: 3px; white-space: nowrap; }
.measurements dd { color: #f8e5c8; font: clamp(1.55rem, 3vw, 2.6rem)/1.05 Georgia, serif; white-space: nowrap; }
.measurements small { font: 500 .78rem system-ui, sans-serif; color: #c6bfaf; }

.exhibit { position: relative; display: grid; grid-template-columns: minmax(0, 2.58fr) minmax(282px, 1fr); gap: 14px; align-items: stretch; }
#interior { scroll-margin-top: 8px; }
.exhibit-anchor { position: absolute; top: 0; left: 0; }
.viewer { border: 1px solid #526673; border-radius: 15px; background: #172831; min-width: 0; align-self: start; overflow: hidden; }
.view-head, .view-foot, .cut-controls, .compare-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px; }
.view-head { border-bottom: 1px solid #5f74824d; }
.modes, .angles, .zoom-buttons { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.viewer button { background: transparent; border: 1px solid transparent; color: #c6d4dc; min-height: 42px; border-radius: 8px; padding: 0 10px; font-size: .875rem; white-space: nowrap; }
.viewer button:hover { background: #ffffff12; color: white; }
.viewer .modes button[aria-pressed="true"] { background: #f2e0bd; border-color: #f2e0bd; color: #1e2b32; font-weight: 650; }
.viewer .angles button[aria-pressed="true"], .viewer button#steam[aria-pressed="true"] { background: #304754; border-color: #708890; color: #fff6e7; }
.viewer button:disabled { opacity: .40; cursor: default; }
.viewer .icon-button { border-color: #3c5462; padding: 0 12px; font-size: 1.4rem; min-width: 42px; }
.room-browser { padding: 8px 10px 9px; border-bottom: 1px solid #5f74824d; background: #182e39; }
.room-groups, .room-choices { display: flex; align-items: center; gap: 5px; overflow-x: auto; scrollbar-width: thin; }
.room-choices { margin-top: 6px; }
.viewer .room-browser button { flex: 0 0 auto; min-height: 44px; }
.viewer .room-groups button { padding-inline: 11px; border-color: #425d6a; }
.viewer .room-groups button[aria-pressed="true"] { color: #fae6bf; background: #3b4848; border-color: #9c8359; }
.viewer .room-choices button { color: #e3e8e7; background: #203b48; border-color: #4f6872; }
.viewer .room-choices button[aria-pressed="true"] { color: #1d2b32; background: #efdbb7; border-color: #efdbb7; font-weight: 680; }
.stage { position: relative; height: clamp(325px, 38vw, 590px); min-height: 265px; isolation: isolate; overflow: hidden; background: radial-gradient(ellipse at 50% 37%, #607784 0%, #364d5b 53%, #1c303c 100%); }
.viewer[data-mode="interior"] .stage { background: radial-gradient(ellipse at 47% 39%, #536e76 0%, #304b58 54%, #1a303a 100%); }
.viewer[data-mode="machinery"] .stage { height: clamp(280px, 34vw, 500px); background: radial-gradient(ellipse at 45% 46%, #49616a 0%, #30454e 54%, #182d38 100%); }
.viewer[data-ready="true"] .stage { cursor: grab; -webkit-user-select: none; user-select: none; touch-action: none; }
.viewer[data-ready="true"] .stage:active, .viewer[data-ready="true"] .stage:active .pin { cursor: grabbing; }
.stage-grid { position: absolute; inset: 0; pointer-events: none; opacity: .40; background-image: linear-gradient(#d5e4e912 1px, transparent 1px), linear-gradient(90deg, #d5e4e912 1px, transparent 1px); background-size: 36px 36px; mask-image: radial-gradient(ellipse, transparent 26%, black 90%); }
.viewport, .pins { position: absolute; inset: 0; }
.viewport canvas { width: 100%; height: 100%; touch-action: none; outline-offset: -5px; }
.pins { pointer-events: none; }
.viewer .pin { position: absolute; pointer-events: auto; display: grid; place-items: center; transform: translate(-50%, -50%); width: 27px; height: 27px; min-height: 27px; font-weight: 650; padding: 0; border-radius: 100%; border: 1px solid #f7e3bb; color: #fff1d4; background: #142632d6; box-shadow: 0 0 0 3px #12242b35; }
.viewer .pin::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; }
.viewer .pin[aria-pressed="true"], .viewer .pin:hover { color: #242e31; background: #f6ddad; border-color: #fff3df; z-index: 2; }
.viewer .room-pin { width: auto; min-width: 48px; height: 30px; min-height: 30px; padding-inline: 8px; border-radius: 6px; font-size: .82rem; }
.atlas-deck-label { position: absolute; transform: translate(-50%, -50%); padding: 1px 5px; border: 1px solid #ffe7bb; border-radius: 4px; white-space: nowrap; color: #26353a; background: #efdbbce8; font-size: .74rem; font-weight: 700; line-height: 1.3; }
.stage-caption, .scale, .status-message, .gesture-hint { position: absolute; pointer-events: none; }
.gesture-hint { left: 13px; bottom: 12px; color: #e1ebef; background: #11212ba6; border-radius: 5px; padding: 4px 8px; font-size: .8125rem; }
.stage-caption { left: 13px; top: 12px; font-size: .875rem; color: #e6eef2; }
.stage-caption span { padding: 6px 9px; border-radius: 5px; background: #11212ba6; }
.status-message { left: 50%; bottom: 18px; transform: translateX(-50%); padding: 8px 13px; border-radius: 8px; background: #0d1e2cee; text-align: center; max-width: 90%; width: max-content; font-size: .9rem; }
.scale { right: 14px; bottom: 10px; display: flex; flex-direction: column; align-items: center; gap: 4px; color: #eef2f3; font-size: .78rem; }
.scale i { width: var(--scale-width, 65px); height: 6px; border: solid #e6e9eb; border-width: 0 1px 1px; }
.historical-fallback { position: absolute; width: 100%; height: 100%; object-fit: contain; opacity: .93; }
.viewer[data-ready="true"] .historical-fallback { display: none; }
.viewer[data-ready="false"] .scale, .viewer:not([data-ready="true"]) .gesture-hint { display: none; }
.viewer[data-mode="compare"] .stage { height: clamp(170px, 23vw, 350px); min-height: 150px; }
.view-foot { border-top: 1px solid #5f74824d; }
.zoom-buttons { flex-shrink: 0; }
.viewer #propeller-closeup { color: #f1d8ad; border-color: #665b4b; }
.zoom-buttons button { min-width: 35px; }
.cut-controls, .compare-top { border-top: 1px solid #5f74824d; }
.spread { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; font-size: .875rem; color: #e4e9e9; }
.spread input { min-width: 40px; width: 100%; max-width: 250px; min-height: 38px; accent-color: #edc992; cursor: pointer; }
.spread span, .spread output { flex-shrink: 0; }
.viewer button#steam, .viewer button#compare-next, .viewer button#interior-open { border-color: #48606e; color: #ecdac0; }
.cut-controls #interior-spread { min-height: 44px; touch-action: pan-y; }
.machine-cut { justify-content: start; }
.machine-cut .spread input { min-height: 44px; touch-action: pan-y; }
.viewer #machine-open, .viewer #machine-overview { border-color: #48606e; color: #ecdac0; }
.machinery-controls { border-top: 1px solid #5f74824d; display: flex; align-items: center; gap: 13px; padding: 5px 10px 2px; }
.viewer #machine-play { background: #f2e0bd; color: #223740; font-weight: 700; border-color: #f2e0bd; min-width: 60px; min-height: 44px; }
.machine-progress { flex: 1; min-width: 0; display: grid; grid-template-rows: auto 32px; padding-top: 3px; }
.machine-progress label { color: #e9dac0; font-size: .9rem; font-weight: 650; }
.machine-progress input { width: 100%; min-width: 0; margin: 0; accent-color: #efcea0; cursor: pointer; touch-action: pan-y; }
.machine-steps { display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); padding: 5px 10px 10px; gap: 5px; }
.viewer .machine-steps button { background: #203744; border: 1px solid #506773; padding: 0 4px; min-height: 44px; }
.viewer .machine-steps button[aria-pressed="true"] { color: #ffe8b6; border-color: #bc9968; background: #3a4645; }
.machinery-legend { pointer-events: none; position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%); list-style: none; display: flex; gap: 8px; padding: 3px 6px; margin: 0; background: #172932e8; border-radius: 5px; color: #f3ede3; }
.machinery-legend li { font-size: .79rem; white-space: nowrap; display: flex; align-items: center; gap: 4px; }
.machinery-legend li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #f8d181; }
.machinery-legend [data-medium="coal"]::before { background: #ff8f4d; }
.machinery-legend [data-medium="sea"]::before, .machinery-legend [data-medium="wake"]::before { background: #87daf8; }
.machinery-legend [data-medium="feed"]::before { background: #a0e9ad; }
.machine-more { font-size: .86rem; color: #414e51; text-underline-offset: 3px; }
.machine-source p { margin-block: 8px; }
.compare-top { font-size: .875rem; color: #c8d9de; }
.viewer button.compare-media { display: block; width: 100%; height: clamp(115px, 21vw, 290px); border: 0; border-radius: 0; padding: 0; background: #1e292b; overflow: hidden; }
.compare-media img { width: 100%; height: 100%; object-fit: contain; }
.viewer button.compare-media[data-record="nara"] { height: auto; aspect-ratio: 4 / 1; position: relative; background: #dec8af; }
.compare-media[data-record="nara"] img { position: absolute; width: 106%; height: auto; left: -3%; top: 0; transform: translateY(-7.7%); }
.compare p { color: #c9d9df; margin: 9px 12px; font-size: .9rem; line-height: 1.55; }
.js-hint { padding: 10px; }
.viewer.fullscreen { position: fixed; z-index: 8; inset: min(1.6vw, 16px); overflow-y: auto; border-radius: 12px; background: #15262f; box-shadow: 0 0 0 100vmax #0b1825e8; display: flex; flex-direction: column; }
.viewer.fullscreen .stage { flex: 1 1 auto; height: auto; min-height: min(360px, 62dvh); }
.viewer.fullscreen[data-mode="compare"] .stage { min-height: 150px; }
.viewer.fullscreen .compare-media { height: min(29vh, 275px); }
.viewer.fullscreen .compare-media[data-record="nara"] { max-height: min(29vh, 275px); }
body.viewer-expanded { overflow: hidden; }

.guide { display: flex; flex-direction: column; background: var(--sheet); color: var(--ink); border-radius: 15px; padding: clamp(16px, 2vw, 26px); min-width: 0; }
.guide-body { flex: 1; }
.english-title { color: #715935; font: 600 .875rem/1.4 system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 6px; }
.guide h2 { color: #1b2a34; font-size: clamp(1.5rem, 2.4vw, 2.15rem); line-height: 1.25; margin-bottom: 8px; }
.guide p, .guide details { font-size: 1rem; line-height: 1.65; }
.guide details { margin-top: 10px; }
.guide details p { margin-top: 7px; color: #45545a; }
.guide summary, .method summary { cursor: pointer; font-weight: 650; font-size: .925rem; }
.guide .evidence-level { display: inline-block; color: #6a512e; border: 1px solid #d4c4ab; border-radius: 4px; padding: 3px 6px; margin: 9px 0 1px; font-size: .81rem; background: #f8f2e7; }
.guide .evidence-links { color: #40565d; font-size: .875rem; line-height: 1.6; }
.guide .room-deck-label { margin-bottom: 4px; color: #6c512f; font-size: .86rem; font-weight: 680; }
.guide .room-intro { line-height: 1.48; }
.room-footprint { display: flex; align-items: center; gap: 7px; margin: 11px 0 3px; color: #5c584d; font-size: .76rem; }
.room-ship-outline { position: relative; flex: 1; height: 22px; background: #ced7d2; clip-path: polygon(0 50%, 8% 12%, 73% 0, 94% 20%, 100% 50%, 94% 80%, 73% 100%, 8% 88%); }
.room-location-dot { position: absolute; top: var(--room-z); left: var(--room-x); width: 10px; height: 10px; transform: translate(-50%,-50%); border: 1px solid #fff6e3; border-radius: 50%; background: #91502b; }
.guide .room-feature { margin-top: 10px; padding: 6px 8px; border-radius: 5px; background: #e5ded0; color: #435359; font-size: .88rem; line-height: 1.49; }
.room-evidence-photos { display: grid; row-gap: 6px; }
.guide-photo { display: block; width: 100%; margin-top: 10px; padding: 0; overflow: hidden; text-align: left; border: 1px solid #c5bba7; border-radius: 8px; background: #eae1d3; color: #213640; }
.guide-photo:hover { border-color: #9e7248; }
.guide-photo img { width: 100%; aspect-ratio: 1.66; max-height: 222px; object-fit: cover; object-position: 50% 43%; background: #ddd4c4; }
.guide-photo.plan img { object-fit: contain; }
.viewer[data-mode="machinery"] + .guide .guide-photo img { object-fit: contain; background: #e3dac9; }
.guide-photo .card-copy { gap: 2px; padding: 6px 8px; }
.guide-photo .card-copy strong { font-size: .90rem; }
.guide-photo .card-date { font-size: .75rem; }
.room-extra-photos { display: grid; grid-template-columns: repeat(auto-fit, minmax(93px,1fr)); gap: 6px; }
.room-extra-photos .guide-photo { margin-top: 0; }
.room-extra-photos img { max-height: 93px; }
.evidence-links a { text-underline-offset: 3px; }
.evidence-links a + a::before { content: " · "; text-decoration: none; display: inline-block; margin-inline: 3px; }
.parts { margin-top: 18px; border-top: 1px solid #d5cec1; padding-top: 13px; }
.parts h2 { font-size: .875rem; color: #655945; margin-bottom: 9px; }
.part-buttons { display: flex; flex-wrap: wrap; gap: 5px; }
.part-buttons button { display: flex; align-items: center; gap: 5px; background: #fbf7ee; color: #263942; border: 1px solid #c9c6b9; border-radius: 7px; padding: 3px 8px; min-height: 37px; font-size: .9rem; }
.part-buttons button span { font: .85rem Georgia, serif; color: #896736; }
.part-buttons button[aria-pressed="true"], .part-buttons button:hover { background: #18303c; border-color: #18303c; color: #fff0d8; }
.part-buttons button[aria-pressed="true"] span, .part-buttons button:hover span { color: #eac688; }
.exhibit-note { color: #b7c8cf; font-size: .875rem; line-height: 1.6; padding-top: 11px; padding-bottom: clamp(26px, 5vw, 66px); }

.archive-section { background: #f3efe7; color: var(--ink); padding-block: clamp(30px, 4.4vw, 65px); max-width: none; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.section-title .dateline { color: #795b36; }
.section-title h2 { font-family: "Songti SC", "STSong", Georgia, serif; font-size: clamp(2.15rem, 4.1vw, 3.65rem); line-height: 1.13; letter-spacing: -.035em; margin-top: 4px; }
.section-title p { color: var(--muted); font-size: 1rem; line-height: 1.65; max-width: 38ch; }
.gallery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.photo-card { display: flex; flex-direction: column; align-items: start; text-align: left; width: 100%; padding: 0; background: #fdf9ef; color: var(--ink); border: 1px solid #dbd0bf; border-radius: 10px; overflow: hidden; }
.photo-card:hover { border-color: #aa8050; }
.photo-card img { object-fit: cover; object-position: 50% 45%; width: 100%; aspect-ratio: 1.65; background: #4f514e; }
.photo-card.plan img { object-fit: contain; background: #e8e1d3; padding: 7px; }
.interior-gallery .photo-card img { object-fit: contain; background: #dcd3c2; }
.interior-gallery .photo-card .card-date { font-size: .78rem; }
.card-copy { display: grid; gap: 5px; padding: 12px; line-height: 1.4; }
.card-copy strong { font-size: 1.05rem; }
.card-date, .document-meta { font-size: .875rem; color: #755a39; }
.card-detail { color: #50616a; font-size: .92rem; }
.document-heading { margin-top: 27px; margin-bottom: 12px; font-size: 1.25rem; }
.documents { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 20px; }
.document { display: flex; flex-direction: column; gap: 4px; padding: 13px 0; border-top: 1px solid #d9cdbd; }
.document a { text-decoration-thickness: 1px; text-underline-offset: 3px; font-weight: 650; font-size: 1rem; }
.document p { color: #516069; font-size: .925rem; line-height: 1.55; }
.method { margin-top: 21px; background: #e9e1d2; border-radius: 9px; padding: 13px 17px; }
.method p { margin: .8em 0; color: #374a54; font-size: 1rem; line-height: 1.7; }
.method a { text-underline-offset: 3px; }
.footer { border-top: 1px solid #ffffff1c; padding-block: 18px; display: flex; justify-content: space-between; gap: 10px; font-size: .875rem; color: #b9cbd3; }
.footer span:first-child { font-family: Georgia, serif; letter-spacing: .13em; color: #edcc9b; }
.footer a { text-underline-offset: 3px; }
dialog { width: min(94vw, 960px); max-height: 94dvh; padding: 0; border: 1px solid #b7a184; border-radius: 13px; background: #f4eee2; color: #22343f; }
dialog::backdrop { background: #09131cdd; }
.dialog-inner { padding: clamp(12px, 2vw, 24px); }
.dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 12px; }
.dialog-head p { color: #765735; margin-bottom: 3px; }
.dialog-head button { display: grid; place-items: center; min-width: 44px; min-height: 44px; background: #e4dcca; color: var(--ink); font-size: 1.35rem; border: 1px solid #c6b697; border-radius: 7px; }
.dialog-inner img { object-fit: contain; width: 100%; max-height: 61dvh; background: #dcd5c8; }
.dialog-inner > p { margin: 10px 0 0; line-height: 1.6; }

@media (max-width: 960px) {
  .exhibit { grid-template-columns: minmax(0, 2.25fr) minmax(245px, 1fr); }
  .intro { align-items: start; }
  .measurements { padding-top: 17px; }
  .stage { height: clamp(310px, 42vw, 480px); }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 730px) {
  .exhibit { grid-template-columns: minmax(0, 1fr); }
  .intro { flex-direction: column; gap: 5px; padding-bottom: 16px; }
  .measurements { padding-top: 6px; padding-bottom: 0; }
  .measurements dd { font-size: 1.65rem; }
  .view-head, .view-foot, .cut-controls, .compare-top { padding: 6px; }
  .viewer .modes button, .viewer .angles button { padding-inline: 7px; }
  .guide { min-height: 0; }
  .guide-body { min-height: 0; }
  .parts { margin-top: 12px; }
  .part-buttons button { min-height: 42px; }
  .section-title { align-items: start; flex-direction: column; gap: 7px; }
  .documents { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .machinery-legend { bottom: 36px; }
}
@media (max-width: 565px) {
  .machine-steps { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .site-header nav { flex-wrap: wrap; justify-content: flex-end; gap: 3px 9px; }
}
@media (max-width: 420px) {
  .site-header { min-height: 57px; }
  .wordmark { font-size: .85rem; gap: 5px; }
  .mark { width: 26px; height: 26px; font-size: .9rem; }
  .site-header nav a { font-size: .8rem; }
  .stage { height: 300px; }
  .stage-caption { left: 8px; }
  .viewer .pin:not(.room-pin) { width: 28px; height: 28px; min-height: 28px; }
  .zoom-buttons button { min-width: 31px; padding-inline: 5px; }
  .spread { gap: 5px; }
  .cut-controls button { padding-inline: 6px; }
  .footer { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
