:root {
  --paper: #e9e7df;
  --ink: #29392f;
  --muted: #526255;
  --rule: #bdc5b8;
  --stage: #cbd5c6;
  --accent: #d6c78c;
  --ease: cubic-bezier(.23,1,.32,1);
  color-scheme: light;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: 'Yu Gothic', 'Meiryo', sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-underline-offset: .3em; }
button, input { font: inherit; accent-color: var(--ink); }
button { color: inherit; cursor: pointer; }
button:disabled, input:disabled { cursor: default; opacity: .5; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid var(--ink); outline-offset: 5px; }
.skip { position: fixed; top: -5rem; left: 1rem; padding: 1rem; background: white; z-index: 20; }
.skip:focus { top: 1rem; }
.masthead { max-width: 1600px; margin: auto; display: flex; align-items: center; gap: 2rem; padding: 26px 4vw; border-bottom: 1px solid var(--rule); font-size: 12px; }
.back { min-height: 24px; display: inline-flex; align-items: center; }
.masthead__name { margin-left: auto; letter-spacing: .12em; font-weight: 600; }
.fiction { font-size: 11px; color: var(--muted); }
main { max-width: 1600px; margin: auto; }
.exhibit { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(0, 1.4fr); gap: 30px; padding: 44px 4vw 28px; }
.intro { padding: 10px 0 0; }
.eyebrow { font-size: 13px; letter-spacing: .12em; margin: 0 0 28px; }
h1 { font: 500 36px/1.25 'Yu Mincho', 'Hiragino Mincho ProN', serif; margin: 0; letter-spacing: .18em; }
h1 span { display: block; font: italic 400 clamp(60px,6.5vw,105px)/.96 Georgia, 'Times New Roman', serif; letter-spacing: -.055em; margin-top: 20px; }
.intro__copy { font-size: 14px; line-height: 2.1; margin: 28px 0 20px; }
.intro__instruction { font-size: 12px; line-height: 1.9; color: var(--muted); }
.scent-story { border-top: 1px solid var(--rule); padding-top: 19px; margin-top: 30px; max-width: 360px; min-height: 160px; }
.scent-story__name { margin: 0 0 10px; font: 500 25px/1.3 'Yu Mincho', serif; }
.scent-story p:not(.scent-story__name) { font-size: 12px; line-height: 1.9; }
.scent-story__notes { color: var(--muted); font-size: 10px !important; }
.stage-wrap { min-width: 0; }
.stage { height: clamp(480px,48vw,680px); position: relative; overflow: hidden; background: var(--stage); border-radius: 52% 52% 3px 3px; isolation: isolate; }
.stage::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at var(--light-x,38%) 24%, #f9f3dbb3, transparent 52%), linear-gradient(160deg, transparent 50%, #344a3421); z-index: -1; }
.stage-word { position: absolute; top: 11%; left: 0; width: 100%; text-align: center; font: 400 clamp(90px,14vw,200px)/1 'Yu Mincho', serif; color: #fff9; letter-spacing: .02em; pointer-events: none; }
#scene { width: 100%; height: 100%; display: block; opacity: 0; touch-action: pan-y; user-select: none; cursor: grab; }
#scene:active { cursor: grabbing; }
.stage.is-ready #scene { opacity: 1; }
.fallback { position: absolute; height: 100%; width: 100%; inset: 0; pointer-events: none; }
.stage.is-ready .fallback { visibility: hidden; }
.stage.is-open .stage-word { visibility: hidden; }
.moment { position: absolute; left: 26px; right: 26px; top: 9%; text-align: center; pointer-events: none; }
.moment span { font: 10px/1.5 sans-serif; letter-spacing: .22em; }
.moment p { margin: 12px 0 0; font: 400 clamp(15px,1.8vw,26px)/1.6 'Yu Mincho',serif; letter-spacing: .09em; }
.stage.is-open .moment { color: #fffaec; text-shadow: 0 1px 8px #182a2e; }
.stage:not(.is-open) .moment { top: auto; bottom: 12%; }
.stage.is-open .stage-caption { color: #fff9e6; text-shadow: 0 1px 4px #1c232d; }
.scent-action { display: flex; align-items: center; gap: 20px; padding-top: 20px; }
.spray { min-height: 50px; padding: 14px 26px; background: var(--ink); color: #fffaec; border: 1px solid var(--ink); border-radius: 2px; font-size: 14px; letter-spacing: .06em; }
.spray:hover { background: #415247; }
.scent-action p { font-size: 11px; line-height: 1.8; color: var(--muted); }
.interaction-help { margin-top: 16px; border-top: 1px solid var(--rule); font-size: 11px; }
.interaction-help summary { min-height: 44px; padding: 14px 0; cursor: pointer; width: fit-content; }
.interaction-help summary:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.interaction-help p { margin: 0 0 14px; line-height: 1.9; color: var(--muted); }
.wind-control { display: flex; flex-wrap: wrap; gap: 12px; padding-bottom: 8px; }
.wind-control button { padding: 10px 14px; min-height: 44px; background: transparent; border: 1px solid var(--rule); font-size: 12px; }
.display-options { display: flex; flex-wrap: wrap; gap: 24px; padding: 4px 0 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.fallback-landscape { position: absolute; inset: 0; opacity: 0; background: linear-gradient(#afcfdb,#c8e0dd 50%,#668e8d); }
.stage.is-open .fallback-landscape { opacity: 1; }
.stage.is-ready .fallback-landscape { visibility: hidden; }
.fallback-landscape i { position: absolute; width: 130%; height: 38%; left: -15%; bottom: 3%; border-radius: 50%; background: #dbeae1aa; box-shadow: 0 -70px 55px #e8f4e555; transform: rotate(-8deg); }
.fallback-landscape b { position: absolute; inset: 0; background: radial-gradient(circle at var(--light-x,32%) 24%,#fff8d766,transparent 36%); }
.stage[data-scent=forest] .fallback-landscape { background: repeating-conic-gradient(from 150deg at 64% 0%,#fff4ba22 0deg 6deg,transparent 6deg 16deg),linear-gradient(#5b784f,#213e35); }
.stage[data-scent=forest] .fallback-landscape i { background: #173729; bottom: -18%; box-shadow: -180px -200px 0 30px #17372999,220px -240px 0 20px #294b3288; }
.stage[data-scent=dusk] .fallback-landscape { background: linear-gradient(#4b4a64,#cf7557 50%,#704e59); }
.stage[data-scent=dusk] .fallback-landscape b { background: radial-gradient(circle at var(--light-x,67%) 37%,#ffdaa1 0 7%,#ffbb7144 9%,transparent 39%); }
.stage[data-scent=dusk] .fallback-landscape i { background: #473b4e; bottom: -17%; box-shadow: 0 -70px 80px #ffae7033; }
.stage.is-open #fallback-cap { transform: translate(145px,365px); }
.stage-caption { position: absolute; bottom: 20px; left: 30px; right: 30px; margin: 0; display: flex; justify-content: space-between; font: 10px/1.5 sans-serif; letter-spacing: .12em; pointer-events: none; }
.render-message { position: absolute; bottom: 48px; left: 20px; right: 20px; font-size: 11px; line-height: 1.5; text-align: center; background: #e9e7dfed; padding: 8px; }
[hidden] { display: none !important; }
.view-controls { display: flex; align-items: center; gap: 20px; padding: 15px 2px 0; font-size: 11px; flex-wrap: wrap; }
.rotate-controls { display: flex; align-items: center; gap: 8px; margin-right: auto; }
.rotate-controls button { height: 44px; width: 44px; border: 1px solid var(--rule); border-radius: 50%; background: transparent; font-size: 24px; }
.rotate-controls button:hover { background: #d8ddcf; }
.text-button { min-height: 44px; padding: 6px 0; border: 0; border-bottom: 1px solid var(--ink); background: transparent; }
.text-button[aria-pressed=true] { font-weight: bold; }
.scents { border: 0; margin: 0 0 24px; padding: 0; display: flex; gap: 20px; justify-content: space-between; min-width: 0; }
.scents legend { font-size: 12px; margin-bottom: 18px; padding: 0; }
.scent-option { position: relative; display: flex; align-items: center; gap: 12px; min-height: 52px; cursor: pointer; font-size: 15px; }
.scent-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.scent-dot { width: 29px; height: 29px; display: inline-block; background: var(--swatch); border-radius: 50%; flex-shrink: 0; }
.scent-option input:checked + .scent-dot { outline: 1px solid var(--ink); outline-offset: 4px; }
.scent-option input:focus-visible + .scent-dot { outline: 3px solid var(--ink); outline-offset: 5px; }
.scent-option small { display: block; font: 10px/1.7 sans-serif; color: var(--muted); margin-top: 4px; }
footer { display: flex; flex-wrap: wrap; column-gap: 25px; max-width: 1600px; padding: 20px 4vw; margin: auto; font-size: 10px; line-height: 1.8; color: var(--muted); }
footer p { margin: 0; }
footer a { margin-left: auto; }
.no-js { margin: 20px 4vw; font-size: 13px; }
@media (max-width: 1000px) {
  .exhibit { grid-template-columns: minmax(250px, .8fr) minmax(0,1.3fr); gap: 22px; }
  .stage { height: 530px; }
  .scents { gap: 12px; }
  .scent-option { gap: 9px; }
  .fiction { display: none; }
}
@media (max-width: 680px) {
  .masthead { padding: 18px 6vw; }
  .exhibit { display: flex; flex-direction: column; padding: 28px 6vw 25px; gap: 25px; }
  .intro { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
  .eyebrow { grid-column: 1 / -1; font-size: 12px; margin-bottom: 18px; }
  h1 { font-size: 28px; }
  h1 span { font-size: clamp(48px,10.5vw,70px); margin-top: 15px; }
  .intro__copy { font-size: 11px; margin: 2px 0; line-height: 2; }
  .intro__instruction { grid-column: 1 / -1; font-size: 11px; margin: 20px 0 0; }
  .scent-story { grid-column: 1 / -1; min-height: 0; margin: 20px 0 0; padding-top: 15px; display: grid; grid-template-columns: 60px 1fr; gap: 0 18px; max-width: none; }
  .scent-story__name { font-size: 22px; }
  .scent-story p:not(.scent-story__name) { margin: 0 0 5px; font-size: 11px; }
  .scent-story__notes { grid-column: 2; }
  .stage { height: 450px; border-radius: 48% 48% 3px 3px; }
  .stage-word { font-size: 105px; }
  .moment { left: 16px; right: 16px; }
  .moment p { font-size: 17px; letter-spacing: .03em; }
  .scent-action { gap: 12px; }
  .spray { padding: 14px 16px; white-space: nowrap; font-size: 12px; }
  .scent-action p { font-size: 10px; }
  .view-controls { gap: 15px; }
  .rotate-controls { gap: 6px; }
  .rotate-controls button { width: 40px; height: 44px; }
  .scent-option { font-size: 14px; }
  .scent-dot { width: 23px; height: 23px; }
  footer { padding: 20px 6vw; display: block; }
  footer p { margin-bottom: 6px; }
}
@media (max-width: 360px) { .stage { height: 390px; } .scent-option { gap: 7px; } .scent-option small { font-size: 9px; } .view-controls { gap: 12px; font-size: 10px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; } }
