/* Story W002 read-only Hosted World viewer and release presentation. */
.compatibility-line { margin-top: 9px; color: var(--muted); font-size: .72rem; }
.detail-panels { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.release-history { display: grid; gap: 8px; margin: 12px 0 0; padding: 0; list-style: none; }
.release-history li { display: flex; justify-content: space-between; gap: 16px; padding-top: 8px; border-top: 1px solid var(--line); }
.release-history span { color: var(--muted); font-size: .8rem; }
.viewer-canvas { touch-action: none; cursor: grab; }
.viewer-canvas.dragging { cursor: grabbing; }
.viewer-world { position: absolute; inset: 0; transform-origin: 0 0; will-change: transform; }
.viewer-overlay-root,.viewer-tile-root { position: absolute; inset: 0; }
.viewer-overlay-root { z-index: auto; pointer-events: none; }
.viewer-tile-root { z-index: 10; }
.viewer-overlay { position: absolute; max-width: none; user-select: none; }
.viewer-reference-image { z-index: 0; object-fit: fill; pointer-events: none; }
.viewer-elevation-image { z-index: 20; object-fit: fill; pointer-events: none; }
.viewer-poi,.viewer-note { z-index: 30; width: 26px; height: 26px; padding: 0; pointer-events: auto; cursor: pointer; border: 2px solid #b7cbe5; border-radius: 50%; background: #24639a center/cover no-repeat; box-shadow: 0 2px 9px rgba(0,0,0,.75); transform-origin: center; }
.viewer-note { width: 22px; height: 22px; border-radius: 4px; }
.viewer-poi::before,.viewer-note::before { content: ""; }
.viewer-poi:hover,.viewer-poi:focus-visible,.viewer-note:hover,.viewer-note:focus-visible,.viewer-poi.selected,.viewer-note.selected { border-color: var(--green-light); box-shadow: 0 0 0 4px rgba(117,213,164,.2),0 2px 9px rgba(0,0,0,.75); outline: 0; }
.viewer-canvas .viewer-tile { position: absolute; max-width: none; object-fit: cover; pointer-events: none; user-select: none; background: var(--surface-2); }
.viewer-layer-list { display: grid; gap: 8px; }
.viewer-layer-list button { display: flex; align-items: center; gap: 9px; text-align: left; cursor: pointer; }
.viewer-layer-list button::before { content: ""; width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; background: var(--muted); }
.viewer-layer-list button.active { color: var(--text); border-color: rgba(117,213,164,.35); background: rgba(117,213,164,.09); }
.viewer-layer-list button.active::before { background: var(--green-light); box-shadow: 0 0 9px rgba(117,213,164,.65); }
.viewer-loading { position: absolute; top: 14px; left: 50%; z-index: 30; transform: translateX(-50%); padding: 7px 11px; color: var(--text); background: rgba(9,13,12,.88); border: 1px solid var(--line); border-radius: 8px; font-size: .75rem; }
.viewer-performance { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: .72rem; }
.viewer-explorer-panel { display: grid; align-content: start; gap: 18px; }
.viewer-explorer-panel section { display: grid; gap: 8px; }
.viewer-explorer-panel [hidden] { display: none !important; }
.viewer-stage.viewer-stage-focused { grid-template-columns: 520px minmax(0,1fr); transition: grid-template-columns .2s ease; }
.viewer-stage.viewer-stage-focused.viewer-stage-collapsed { grid-template-columns: 58px minmax(0,1fr); }
.viewer-panel-collapse { width: 42px !important; min-height: 42px; justify-self: end; color: var(--text) !important; font-size: 1.4rem; cursor: pointer; }
.viewer-stage-collapsed .viewer-explorer-panel { padding-inline: 8px; }
.viewer-stage-collapsed .viewer-explorer-panel > :not(.viewer-panel-collapse) { display: none !important; }
.viewer-layer-mode { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; }
.viewer-layer-mode button { cursor: pointer; }
.viewer-layer-mode button[aria-pressed="true"] { color: var(--text); border-color: rgba(117,213,164,.35); background: rgba(117,213,164,.09); }
.viewer-control-help { margin: 0; }
.viewer-overlay-controls { display: grid; gap: 6px; }
.viewer-overlay-controls button { display: flex; align-items: center; gap: 9px; text-align: left; cursor: pointer; }
.viewer-overlay-controls button[aria-pressed="false"] { color: var(--muted); opacity: .72; }
.viewer-key { width: 13px; height: 13px; flex: 0 0 auto; border: 2px solid #b7cbe5; background: #24639a; }
.viewer-key-poi { border-radius: 50%; }
.viewer-key-note { border-radius: 3px; }
.viewer-search { display: grid; gap: 7px; color: var(--text); font-size: .78rem; font-weight: 750; }
.viewer-search input { min-width: 0; width: 100%; padding: 10px; color: var(--text); background: var(--surface-2); border: 1px solid var(--line); border-radius: 8px; }
.viewer-search-results { display: grid; gap: 5px; max-height: 240px; overflow-y: auto; }
.viewer-search-results button { display: flex; justify-content: space-between; gap: 8px; text-align: left; cursor: pointer; }
.viewer-search-results small { color: var(--muted); }
.viewer-toc { display: grid; gap: 4px; }
.viewer-toc details>div { display: grid; gap: 4px; margin: 4px 0 4px 12px; padding-left: 8px; border-left: 1px solid var(--line); }
.viewer-toc summary { list-style-position: outside; color: var(--muted); }
.viewer-toc summary button { width: calc(100% - 18px); }
.viewer-toc button,.viewer-level-list button { text-align: left; cursor: pointer; }
.viewer-level-list { display: grid; grid-template-columns: 44px minmax(0,1fr) 44px; align-items: center; gap: 6px; }
.viewer-level-list strong { text-align: center; }
.viewer-level-list button:disabled { cursor: not-allowed; opacity: .4; }
.viewer-elevation-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px; }
.viewer-level-list button.active,.viewer-elevation-list button.active { color: var(--text); border-color: rgba(117,213,164,.35); background: rgba(117,213,164,.09); }
.viewer-controls { z-index: 30; }
.world-view-tabs { width: fit-content; display: flex; gap: 5px; margin-bottom: 12px; padding: 5px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.world-view-tabs button { min-height: 38px; padding: 0 16px; color: var(--muted); background: transparent; border: 1px solid transparent; border-radius: 8px; font-weight: 750; cursor: pointer; }
.world-view-tabs button[aria-pressed="true"] { color: var(--text); background: rgba(117,213,164,.1); border-color: rgba(117,213,164,.25); }
.world-view-tabs button:focus-visible { outline: 3px solid var(--green-light); outline-offset: 2px; }
.maps-view-note { min-height: 25px; margin-bottom: 8px; color: var(--muted); font-size: .84rem; }
.membership-badge { color: var(--green-light); font-weight: 800; }

@media (max-width: 760px) {
  .detail-panels { grid-template-columns: 1fr; }
  .viewer-stage.viewer-stage-focused,.viewer-stage.viewer-stage-focused.viewer-stage-collapsed { grid-template-columns: 1fr; }
  .viewer-panel-collapse { display: none; }
}
