:root {
  --bg: #0c0f12;
  --fg: #f3ede2;
  --fg-soft: #d7cec0;
  --muted: rgba(243, 237, 226, 0.72);
  --dim: rgba(243, 237, 226, 0.48);
  --border: rgba(243, 237, 226, 0.22);
  --panel: rgba(16, 19, 23, 0.88);
  --panel-solid: #111519;
  --accent: #e5b972;
  --accent-soft: rgba(229, 185, 114, 0.22);
  --shadow: 0 2px 14px rgba(0, 0, 0, 0.78);
  --select-dim: 0.78;
  --header-offset: 0px;
}

@media (prefers-contrast: more) {
  :root {
    --select-dim: 0.95;
  }
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  background: var(--bg);
  color: var(--fg);
  font-family: "Newsreader", Georgia, serif;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

a[href]:hover,
button:not(:disabled):not(.hotspot):not(.season-btn):hover,
summary:hover,
.season-btn:hover .season-meta {
  opacity: var(--select-dim);
}

button:focus-visible,
a:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 1.5px solid var(--accent);
  outline-offset: 3px;
}

#experience {
  position: relative;
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  background: var(--bg);
  user-select: none;
}

#siteHeader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 28px;
  z-index: 26;
  pointer-events: none;
  text-shadow: var(--shadow);
}

#siteHeader a {
  pointer-events: auto;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

#siteHeader .brand {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--fg);
  transition: color 0.3s ease, opacity 0.2s ease;
}

#siteHeader .edition {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10px;
  letter-spacing: 0.24em;
  color: var(--accent);
  text-transform: uppercase;
  padding-left: 14px;
  border-left: 1px solid rgba(243, 237, 226, 0.28);
}

#siteHeader .home {
  margin-left: auto;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 16px;
  color: var(--fg-soft);
  transition: color 0.3s ease, opacity 0.2s ease;
}

.amp {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 400;
}

#topTools {
  position: fixed;
  top: 62px;
  right: 28px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  z-index: 26;
}

.chip {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 999px;
  min-height: 36px;
  padding: 8px 14px;
  background: rgba(14, 17, 21, 0.72);
  backdrop-filter: blur(10px);
  transition: color 0.25s ease, border-color 0.25s ease, background 0.25s ease, opacity 0.2s ease;
}

.chip[aria-pressed="true"] {
  color: var(--accent);
  border-color: rgba(229, 185, 114, 0.72);
  background: rgba(18, 22, 27, 0.88);
}

#stage,
#edoViewport {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

#edoViewport {
  background: #0b0e11;
  touch-action: none;
}

#edoViewport.is-pannable {
  cursor: grab;
}

#edoViewport.is-dragging {
  cursor: grabbing;
}

#edoCamera {
  position: absolute;
  left: 0;
  top: 0;
  transform-origin: 0 0;
  will-change: transform;
}

.scene-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
  will-change: opacity, filter, transform;
}

.scene-layer.is-visible {
  opacity: 1;
}

#transitionVeil {
  position: absolute;
  inset: 0;
  z-index: 6;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(circle at 52% 48%, rgba(20, 23, 28, 0.12), rgba(10, 12, 16, 0.72) 85%);
  transition: opacity 0.45s ease;
}

#experience.is-stepping #transitionVeil {
  opacity: 1;
}

#atmosphereCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  pointer-events: none;
}

#companionWrap {
  position: absolute;
  left: clamp(6px, 1.1vw, 24px);
  bottom: 0;
  width: clamp(150px, min(16.5vw, 29dvh), 270px);
  z-index: 7;
  pointer-events: none;
  transform-origin: 35% 100%;
  transform: translate3d(0, 6px, 0) scale(1);
  opacity: 1;
  transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1), transform 0.85s cubic-bezier(0.22, 1, 0.36, 1), filter 0.8s ease;
}

#companionImage {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.65)) brightness(0.93) contrast(1.04);
  transition: filter 0.8s ease;
}

[data-stop="corridor"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.65)) brightness(0.9) saturate(0.88) contrast(1.05);
}

[data-stop="armory"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.78)) brightness(0.86) sepia(0.08) saturate(0.95) contrast(1.08);
}

[data-stop="hall"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.72)) brightness(0.95) sepia(0.12) contrast(1.04);
}

[data-stop="gate"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.58)) brightness(1) contrast(1.05);
}

[data-stop="nihonbashi"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.62)) brightness(0.97) sepia(0.18) saturate(1.08);
}

[data-stop="honcho"] #companionImage {
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.68)) brightness(0.92) sepia(0.22) saturate(1.06) contrast(1.06);
}

[data-stop="matsuri"] #companionImage {
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.8)) brightness(0.9) sepia(0.14) saturate(1.06) contrast(1.08);
}

[data-stop="alley"] #companionImage {
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.82)) brightness(0.86) saturate(0.94) contrast(1.08);
}

[data-stop="sumida"] #companionImage {
  filter: drop-shadow(0 14px 28px rgba(0, 0, 0, 0.85)) brightness(0.83) saturate(0.92) contrast(1.1);
}

#experience.is-walking #companionWrap {
  animation: edo-stride 1.15s ease-in-out infinite;
}

@keyframes edo-stride {
  0%, 100% {
    transform: translate3d(0, 6px, 0) rotate(0deg) scale(1);
  }
  50% {
    transform: translate3d(3px, 0px, 0) rotate(0.45deg) scale(1.008);
  }
}

[data-stop="quarters"] #companionWrap,
[data-stop="teahouse"] #companionWrap,
#experience.is-detail #companionWrap,
#experience.is-above #companionWrap,
#experience.is-zoomed #companionWrap {
  opacity: 0;
  transform: translate3d(-14%, 10%, 0) scale(0.96);
}

#sceneShade {
  position: absolute;
  inset: 0;
  z-index: 8;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(10, 12, 16, 0.58) 0%, rgba(10, 12, 16, 0) 22%),
    linear-gradient(0deg, rgba(10, 12, 16, 0.9) 0%, rgba(10, 12, 16, 0.56) 28%, rgba(10, 12, 16, 0) 52%);
}

#hotspots {
  position: absolute;
  inset: 0;
  z-index: 9;
  pointer-events: none;
}

#experience.is-above #hotspots,
#experience.is-stepping #hotspots {
  opacity: 0;
}

.hotspot {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px;
}

.hotspot .ring {
  position: relative;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 240, 212, 0.92);
  background: rgba(229, 185, 114, 0.25);
  box-shadow: 0 0 0 4px rgba(12, 15, 18, 0.42), 0 0 14px rgba(229, 185, 114, 0.55);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.hotspot .ring::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: #fff2d8;
}

.hotspot .label {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: var(--fg);
  background: rgba(14, 17, 21, 0.86);
  border: 1px solid rgba(243, 237, 226, 0.28);
  border-radius: 999px;
  padding: 4px 10px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.52);
  opacity: 0;
  transform: translateX(-4px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease, border-color 0.22s ease;
}

.hotspot:hover .ring,
.hotspot:focus-visible .ring,
.hotspot.is-active .ring {
  transform: scale(1.22);
  background: var(--accent);
  border-color: #fff6e6;
}

.hotspot:hover .label,
.hotspot:focus-visible .label,
.hotspot.is-active .label,
body.places-shown .hotspot .label {
  opacity: 1;
  transform: translateX(0);
}

.hotspot.is-active .label {
  border-color: var(--accent);
  color: var(--accent);
}

#aboveMap {
  position: absolute;
  inset: 0;
  z-index: 9;
  pointer-events: none;
}

#aboveMap[hidden] {
  display: none;
}

#aboveRouteSvg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.68));
}

#abovePins {
  position: absolute;
  inset: 0;
}

.above-stop {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  min-height: 44px;
  padding: 4px 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.above-pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #14181c;
  border: 2px solid var(--fg);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.72);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.above-pin-label {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.04em;
  white-space: nowrap;
  color: var(--fg);
  background: rgba(14, 17, 21, 0.88);
  border: 1px solid rgba(243, 237, 226, 0.3);
  border-radius: 999px;
  padding: 5px 11px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.55);
  transition: border-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.above-stop.is-current .above-pin-dot {
  border-color: var(--accent);
  background: var(--accent);
  transform: scale(1.22);
}

.above-stop.is-current .above-pin-label {
  border-color: var(--accent);
  color: var(--accent);
}

#caption {
  position: fixed;
  left: clamp(24px, 5.4vw, 80px);
  bottom: 92px;
  max-width: min(500px, calc(100vw - 80px));
  z-index: 20;
  text-shadow: var(--shadow);
  transition: left 0.55s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease, bottom 0.35s ease;
}

@media (min-width: 900px) {
  body.edo-with-companion #experience[data-mode="overview"]:not(.is-above):not(.is-zoomed) #caption {
    left: clamp(232px, 21.5vw, 336px);
    max-width: min(470px, calc(100vw - 410px));
  }
}

.eyebrow {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  text-shadow: 0 1px 10px rgba(8, 10, 14, 0.94);
  margin-bottom: 8px;
}

#title {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(32px, 4.1vw, 52px);
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: -0.01em;
  color: var(--fg);
  margin-bottom: 10px;
}

#description {
  font-size: 17px;
  line-height: 1.48;
  color: var(--fg-soft);
  max-width: 44ch;
  margin-bottom: 18px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

#primary,
#readButton {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  min-height: 44px;
  padding: 10px 20px;
  border-radius: 999px;
  transition: background 0.25s ease, border-color 0.25s ease, color 0.25s ease, opacity 0.2s ease;
}

#primary {
  background: rgba(229, 185, 114, 0.92);
  color: #121518;
  text-shadow: none;
  border: 1px solid rgba(255, 232, 192, 0.6);
}

#primary.is-door,
#readButton {
  background: rgba(14, 17, 21, 0.72);
  color: var(--fg);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

#readButton[aria-expanded="true"] {
  border-color: var(--accent);
  color: var(--accent);
}

#information {
  position: fixed;
  top: 112px;
  right: 28px;
  bottom: 168px;
  width: min(420px, calc(100vw - 56px));
  z-index: 35;
  overflow-y: auto;
  padding: 28px 26px 26px;
  background: var(--panel);
  backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65);
  color: var(--fg);
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

#information[hidden] {
  display: none;
}

#information .close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 40px;
  height: 40px;
  font-size: 24px;
  line-height: 1;
  color: var(--fg-soft);
  border-radius: 50%;
  transition: opacity 0.2s ease;
}

#infoTitle {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 29px;
  font-weight: 500;
  line-height: 1.15;
  margin-bottom: 14px;
  padding-right: 28px;
}

#infoFigure {
  margin: 0 0 16px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(243, 237, 226, 0.14);
  background: rgba(8, 10, 13, 0.72);
}

#infoFigure[hidden] {
  display: none;
}

#infoImage {
  display: block;
  width: 100%;
  height: auto;
  max-height: 290px;
  object-fit: contain;
}

#infoFigureCaption {
  padding: 8px 11px;
  border-top: 1px solid rgba(243, 237, 226, 0.1);
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--fg-soft);
}

#infoText p {
  font-size: 16.5px;
  line-height: 1.62;
  color: var(--fg-soft);
  margin-bottom: 13px;
}

#infoWord,
#infoPicture {
  font-size: 15px;
  line-height: 1.5;
  padding: 11px 13px;
  margin: 14px 0;
  background: var(--accent-soft);
  border-left: 2px solid var(--accent);
  border-radius: 4px;
  color: var(--fg);
}

#infoWord a,
#infoPicture a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

#infoSources {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(243, 237, 226, 0.14);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#infoSources a {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 12px;
  line-height: 1.45;
  color: var(--fg-soft);
  transition: opacity 0.2s ease;
}

#moreNotes {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid rgba(243, 237, 226, 0.14);
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 12px;
}

#moreNotes summary {
  cursor: pointer;
  color: var(--muted);
  padding: 4px 0;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 10.5px;
}

#moreNotes label {
  display: block;
  margin: 10px 0 6px;
  color: var(--dim);
  font-size: 11px;
}

#moreNotes select {
  width: 100%;
  background: #14191e;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  font: inherit;
}

#source {
  display: inline-block;
  margin-top: 16px;
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  transition: opacity 0.2s ease;
}

#travelStatus {
  position: fixed;
  top: 64px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 28;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  background: rgba(14, 17, 21, 0.88);
  border: 1px solid rgba(229, 185, 114, 0.45);
  border-radius: 999px;
  backdrop-filter: blur(12px);
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 12px;
  color: var(--fg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

#travelStatus[hidden] {
  display: none;
}

.travel-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.travel-track {
  width: 56px;
  height: 2px;
  background: rgba(243, 237, 226, 0.18);
  border-radius: 999px;
  overflow: hidden;
}

.travel-light {
  width: 100%;
  height: 100%;
  transform-origin: left center;
  transform: scaleX(0);
  background: var(--accent);
}

#skipTravel {
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 4px 6px;
}

#zoomControls {
  position: fixed;
  right: 28px;
  bottom: 168px;
  z-index: 22;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: opacity 0.25s ease;
}

body.edo-info-open #zoomControls {
  opacity: 0;
  pointer-events: none;
}

#zoomControls button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(14, 17, 21, 0.78);
  backdrop-filter: blur(8px);
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 18px;
  color: var(--fg);
  display: grid;
  place-items: center;
  transition: border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

#zoomControls button:disabled {
  opacity: 0.34;
  cursor: default;
}

#viewNavigation {
  position: fixed;
  right: 28px;
  bottom: 92px;
  z-index: 22;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.view-context {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  text-shadow: var(--shadow);
}

.view-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.view-buttons button {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  min-height: 38px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(14, 17, 21, 0.78);
  backdrop-filter: blur(8px);
  color: var(--fg);
  transition: border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.view-buttons button:disabled {
  opacity: 0.34;
  cursor: default;
}

.view-buttons button[aria-pressed="true"] {
  border-color: var(--accent);
  color: var(--accent);
}

footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 24px;
  height: 52px;
  z-index: 24;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 0 28px;
}

#backButton {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  min-height: 40px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(14, 17, 21, 0.78);
  color: var(--fg);
  flex-shrink: 0;
  transition: opacity 0.2s ease;
}

#journeyStops {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 4px 0;
  margin: 0 auto;
}

#journeyStops::-webkit-scrollbar {
  display: none;
}

.stop-btn {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  min-height: 36px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(243, 237, 226, 0.18);
  background: rgba(14, 17, 21, 0.65);
  color: var(--muted);
  transition: color 0.25s ease, border-color 0.25s ease, background 0.25s ease, opacity 0.2s ease;
}

.stop-btn.is-active {
  color: #111519;
  background: var(--accent);
  border-color: var(--accent);
}

#count {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--muted);
  flex-shrink: 0;
  text-shadow: var(--shadow);
}

#disclosure {
  position: fixed;
  left: 28px;
  bottom: 7px;
  z-index: 24;
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--dim);
  text-shadow: var(--shadow);
}

#routeDialog {
  margin: auto;
  max-width: min(600px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  padding: 28px 26px;
  background: var(--panel-solid);
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.72);
}

#routeDialog::backdrop {
  background: rgba(8, 10, 13, 0.74);
  backdrop-filter: blur(6px);
}

#routeDialog .close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  height: 38px;
  font-size: 22px;
  color: var(--fg-soft);
}

#routeDialog h2 {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 30px;
  font-weight: 400;
  margin-bottom: 12px;
}

#routeDialog p {
  font-size: 16px;
  line-height: 1.55;
  color: var(--fg-soft);
  margin-bottom: 14px;
}

#routeDialog ul {
  padding-left: 18px;
  display: grid;
  gap: 8px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--fg-soft);
}

.season-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 18px;
}

.season-btn {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 0;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid rgba(229, 185, 114, 0.3);
  background: rgba(255, 255, 255, 0.035);
  color: var(--fg);
  text-align: left;
}

.season-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  height: auto;
  object-fit: cover;
  border-bottom: 1px solid rgba(229, 185, 114, 0.2);
}

.season-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 9px 11px 10px;
  transition: opacity 0.2s ease;
}

.season-meta strong {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.season-meta span {
  font-size: 14.5px;
  line-height: 1.3;
  color: var(--fg-soft);
}

@media (max-width: 520px) {
  .season-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 900px) and (max-width: 1220px) {
  body.edo-info-open #caption {
    opacity: 0;
    pointer-events: none;
  }
}

@media (max-width: 899px) {
  #siteHeader {
    padding: 0 16px;
    gap: 10px;
  }

  #siteHeader .edition {
    display: none;
  }

  #topTools {
    top: 56px;
    right: 14px;
    left: 14px;
    justify-content: flex-start;
  }

  .chip {
    font-size: 9.5px;
    letter-spacing: 0.14em;
    padding: 6px 11px;
  }

  #companionWrap {
    width: 132px;
    left: -8px;
    bottom: 148px;
    opacity: 0.86;
  }

  #caption {
    left: 16px;
    right: 16px;
    bottom: 118px;
    max-width: none;
  }

  #title {
    font-size: 25px;
    margin-bottom: 6px;
  }

  #description {
    font-size: 14.5px;
    line-height: 1.4;
    margin-bottom: 10px;
  }

  .actions {
    flex-wrap: wrap;
    gap: 8px;
  }

  #primary,
  #readButton {
    font-size: 10.5px;
    letter-spacing: 0.1em;
    min-height: 38px;
    padding: 8px 13px;
    white-space: nowrap;
  }

  #zoomControls {
    top: 104px;
    right: 14px;
    bottom: auto;
  }

  #viewNavigation {
    left: 16px;
    right: 16px;
    bottom: 76px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .view-buttons button {
    min-height: 34px;
    padding: 5px 10px;
    font-size: 10px;
  }

  .view-context {
    display: none;
  }

  footer {
    left: 0;
    right: 0;
    bottom: 22px;
    height: 46px;
    padding: 0 14px;
  }

  #information {
    top: 60px;
    left: 12px;
    right: 12px;
    bottom: 24px;
    width: auto;
  }

  #disclosure {
    left: 16px;
    font-size: 9px;
  }
}

@media (max-width: 480px) {
  #companionWrap {
    display: none;
  }

  #viewNavigation {
    bottom: 74px;
  }

  #caption {
    bottom: 114px;
  }

  #zoomControls {
    top: 112px;
  }
}

@media (max-height: 640px) and (min-width: 900px) {
  #companionWrap {
    width: clamp(160px, 15vw, 220px);
  }

  #caption {
    bottom: 82px;
  }

  #title {
    font-size: clamp(26px, 3.6vw, 38px);
  }

  #information {
    top: 98px;
    bottom: 162px;
  }
}

.hotspot {
  justify-content: flex-start;
  padding: 6px 6px 6px 16px;
  transform: translate(-22px, -50%) scale(calc(1 / var(--cam-scale, 1)));
  transform-origin: 22px 50%;
}

.hotspot.is-flipped {
  flex-direction: row-reverse;
  padding: 6px 16px 6px 6px;
  transform: translate(calc(-100% + 22px), -50%) scale(calc(1 / var(--cam-scale, 1)));
  transform-origin: calc(100% - 22px) 50%;
}

.above-stop {
  transform: translate(-15px, -50%) scale(calc(1 / var(--cam-scale, 1)));
  transform-origin: 15px 50%;
}

.above-stop.is-flipped {
  flex-direction: row-reverse;
  transform: translate(calc(-100% + 15px), -50%) scale(calc(1 / var(--cam-scale, 1)));
  transform-origin: calc(100% - 15px) 50%;
}

.hotspot.is-covered,
.above-stop.is-covered {
  visibility: hidden;
}

.hotspot.is-tucked .label,
.hotspot.is-tucked.is-active .label,
body.places-shown .hotspot.is-tucked .label,
.above-stop.is-tucked .above-pin-label {
  opacity: 0;
}

.hotspot.is-tucked:hover .label,
.hotspot.is-tucked:focus-visible .label,
body.places-shown .hotspot.is-tucked:hover .label,
body.places-shown .hotspot.is-tucked:focus-visible .label,
.above-stop.is-tucked:focus-visible .above-pin-label {
  opacity: 1;
}

#experience.is-fitted .above-stop:not(.is-current) .pin-name {
  display: none;
}

#experience.is-fitted .above-stop {
  z-index: 1;
}

#experience.is-fitted .above-stop.is-current {
  z-index: 0;
}

@media (max-height: 600px) {
  #experience.is-fitted #description {
    display: none;
  }
}

#aboveRoutePath {
  stroke: rgba(240, 200, 132, 0.92);
  stroke-width: 3;
  vector-effect: non-scaling-stroke;
}

#hint {
  margin-top: 14px;
  max-width: 46ch;
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 12px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--fg-soft);
}

#hint[hidden] {
  display: none;
}

@media (max-width: 899px) {
  #siteHeader {
    flex-wrap: wrap;
    align-content: center;
    row-gap: 0;
  }

  #siteHeader .brand {
    min-height: 36px;
  }

  #siteHeader .home {
    min-height: 36px;
  }

  #siteHeader .edition {
    display: block;
    order: 3;
    flex-basis: 100%;
    margin-top: -6px;
    padding-left: 0;
    border-left: 0;
    font-size: 9px;
    letter-spacing: 0.2em;
    line-height: 14px;
  }

  .view-buttons {
    flex-wrap: nowrap;
  }

  #experience.is-detail #fromAbove {
    display: none;
  }

  #hint {
    margin-top: 10px;
    font-size: 11.5px;
  }

  #hint .keys {
    display: none;
  }
}

@media (max-width: 360px) {
  #disclosure {
    letter-spacing: 0.02em;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

#detailPicker { max-width: 100%; min-height: 44px; padding: 9px 30px 9px 12px; border: 1px solid rgba(229,185,114,.5); border-radius: 4px; color: #efd4a7; background: #1d2224; font: inherit; }
#detailPicker[hidden], #primary[hidden], #restoreView[hidden], #viewPrevious[hidden] { display: none; }
#restoreView { position: fixed; top: 20px; right: 20px; z-index: 80; }

#quietNav { position: fixed; left: 50%; bottom: max(20px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 80; display: flex; gap: 8px; }
#quietNav[hidden] { display: none; }
#quietNav button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--border); background: rgba(14, 17, 21, 0.6); backdrop-filter: blur(8px); color: var(--fg); font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif; font-size: 18px; display: grid; place-items: center; transition: opacity 0.2s ease; }
#quietNav button:disabled { opacity: 0.3; cursor: default; }
#quietNav button:nth-child(2) { margin-left: 10px; }
#quietNav button:nth-child(3) { margin-right: 10px; }
.is-quiet #travelStatus { visibility: hidden; }
.is-quiet #siteHeader, .is-quiet #topTools, .is-quiet #caption, .is-quiet #viewNavigation, .is-quiet footer, .is-quiet #zoomControls, .is-quiet #hotspots, .is-quiet #aboveMap, .is-quiet #disclosure, .is-quiet #sceneShade { visibility: hidden; }
@media (max-width: 700px) {
  #topTools { gap: 4px; }
  #topTools .chip { padding-inline: 7px; min-height: 44px; letter-spacing: .05em; }
  #detailPicker { max-width: 62%; font-size: 14px; }
}

@media (max-width: 360px) and (orientation: portrait) {
  #topTools { display: grid; grid-template-columns: repeat(2, 1fr); }
  #zoomControls { top: 160px; }
  #information { top: 156px; }
}
@media (min-width: 361px) and (max-width: 700px) and (orientation: portrait) {
  #information { top: 110px; }
}
