/* V14: direct manipulation, clear editing / walkthrough states and original loading. */
.panorama-loading{position:absolute;inset:0;z-index:7;display:grid;place-items:center;background:#111c2b45;pointer-events:none}
.panorama-loading[hidden],.selection-tools[hidden],.target-picker[hidden]{display:none!important}
.loading-card{width:min(330px,calc(100% - 36px));padding:22px 24px;border:1px solid #ffffff36;border-radius:16px;background:#172334ed;box-shadow:0 14px 50px #0003;color:#edf3ff;backdrop-filter:blur(16px);display:flex;flex-direction:column;gap:12px;pointer-events:auto;text-align:center}
.loading-card strong{font-size:14px;line-height:1.5}.loading-card small{font-size:11px;line-height:1.7;color:#b5c3d6}.loading-card progress{width:100%;height:5px;border-radius:6px;accent-color:#80adff;border:0;overflow:hidden}.loading-card button{font:inherit;border:1px solid #ffffff4a;border-radius:8px;background:#4c80dc;color:white;padding:10px;cursor:pointer}.loading-card [hidden]{display:none!important}
.panorama-busy #editor-pano,.panorama-busy #panorama{pointer-events:none}.panorama-busy .pnlm-load-box{visibility:hidden!important}
.viewer>.panorama-loading{position:fixed;z-index:4}.viewer>.panorama-loading .loading-card{background:#172334ed}.viewer.panorama-busy .viewer-footer,.viewer.panorama-busy .viewer-head{z-index:6}
.editor-modes{pointer-events:auto;display:flex;align-items:center;padding:3px;border:1px solid #ffffff28;border-radius:9px;background:#171d28dc;backdrop-filter:blur(12px)}
.editor-v12 .editor-modes button{border:0;background:transparent;min-height:32px;padding:6px 11px;font-size:11px;color:#a9b5c7;gap:6px;border-radius:6px}.editor-v12 .editor-modes svg{width:15px;height:15px}.editor-v12 .editor-modes button[aria-pressed=true]{background:#417cf4;color:white}.editor-v12 .editor-modes button:last-child[aria-pressed=true]{background:#297d6b}
.canvas-add-tools{position:absolute;left:50%;bottom:55px;transform:translateX(-50%);z-index:5;display:flex;gap:4px;align-items:center;padding:5px;border:1px solid #ffffff2d;border-radius:12px;background:#192230e8;box-shadow:0 5px 18px #0002;backdrop-filter:blur(14px);max-width:calc(100% - 40px)}
.editor-v12 .canvas-add-tools button{white-space:nowrap;min-height:38px;font-size:11px;padding:8px 12px;background:transparent;border-color:transparent}.editor-v12 .canvas-add-tools button:hover{background:#3a4f70}.editor-v12 .canvas-add-tools svg{width:17px;height:17px}.editor-walking .canvas-add-tools{display:none}
.selection-tools{position:absolute;top:64px;left:50%;transform:translateX(-50%);z-index:6;display:flex;align-items:center;gap:4px;border:1px solid #849fc761;border-radius:10px;background:#192333ed;padding:5px 7px;box-shadow:0 7px 22px #0003;backdrop-filter:blur(14px);max-width:calc(100% - 32px)}
.selection-tools>strong{font-size:11px;font-weight:500;padding:0 7px;max-width:120px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.editor-v12 .selection-tools button{white-space:nowrap;font-size:10px;padding:7px;min-height:32px;background:transparent;border-color:transparent}.editor-v12 .selection-tools .selection-icon{width:32px;min-width:32px;padding:7px}.selection-icon>span{display:none}.editor-v12 .selection-tools button:hover{background:#3a4f70}.editor-v12 .selection-tools svg{width:16px;height:16px}.editor-v12 .selection-tools button[aria-label="进入目标场景"]{background:#3563aa;color:white}
.editor-v12.editor-walking .hotspot-annotation{cursor:pointer;touch-action:manipulation}.editor-v12.editor-walking .display-only{cursor:default}
.editor-v12 .field input.style-range{display:block;padding:0;margin:10px 0 0;border:0;border-radius:0;background:transparent;height:16px;width:100%;accent-color:#77a0fc;box-shadow:none;cursor:ew-resize}
.color-presets{display:flex;gap:9px;margin:-3px 0 15px}.editor-v12 .color-presets button{display:block;min-width:24px;width:24px;min-height:24px;height:24px;padding:0;border-radius:50%;border:2px solid #ffffff55;box-shadow:0 0 0 2px #222832}.editor-v12 .color-presets button:hover{border-color:white;transform:scale(1.1)}
.target-picker{border:1px solid #414a5a;border-radius:8px;margin:12px 0;background:#1d222b}.target-picker summary{padding:12px;cursor:pointer;min-height:42px;font-size:11px;color:#c1d4f5}.target-picker>.field{margin:0 9px 10px}.target-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;padding:0 8px 9px;max-height:300px;overflow:auto}.editor-v12 .target-grid button{display:block;padding:0;overflow:hidden;background:#151b25;border:2px solid transparent;min-width:0}.editor-v12 .target-grid button.active{border-color:#7fa9ff}.target-grid img{display:block;width:100%;height:58px;object-fit:cover}.target-grid span{display:block;padding:7px;font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.scene-item.scene-drop-target,.overview-scene.scene-drop-target{outline:3px solid #9ebfff;outline-offset:-3px}.scene-item[draggable=true]{cursor:grab}.scene-item:active[draggable=true]{cursor:grabbing}
dialog.scene-overview{width:min(900px,calc(100vw - 32px));max-width:900px}.scene-overview-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:12px;max-height:60dvh;overflow:auto;padding:4px}.scene-overview .overview-scene{display:block;padding:0;text-align:left;overflow:hidden;border:2px solid #dbe2ec;border-radius:10px;background:#f6f8fb;min-width:0;color:#263a51;cursor:grab}.overview-scene.active{border-color:#497bf1}.overview-scene img{display:block;width:100%;height:92px;object-fit:cover}.overview-scene span{display:block;padding:10px 10px 3px;font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.overview-scene small{display:block;padding:2px 10px 10px;font-size:10px;color:#7d8ba0}
.scene-drawer-head{display:flex;align-items:center;justify-content:space-between;padding:0 0 9px;gap:12px}.scene-drawer-head strong{font-size:10px;font-weight:500;color:#c3d2e7;letter-spacing:.3px}.scene-drawer-head strong span{margin-left:6px;color:#8ea4c3}.scene-drawer-head>div{display:flex;gap:5px}.viewer .scene-drawer-head button{width:30px;height:28px;min-width:30px;min-height:28px;padding:0 6px;font-size:22px;line-height:1;border-color:#ffffff25;background:#ffffff0b}.viewer button:disabled{opacity:.3;cursor:default}
.viewer #scene-list .scene-index{position:absolute;left:5px;top:5px;background:#102037b5;border-radius:4px;padding:2px 5px;font-size:9px;line-height:1.4;color:white}.viewer-scene-search{display:block;font-size:0;margin:0 0 9px}.viewer-scene-search[hidden]{display:none!important}.viewer-scene-search input{display:block;width:100%;padding:9px 11px;color:#e0eaf7;background:#0f192980;border:1px solid #ffffff2b;border-radius:7px;font:11px system-ui}.viewer-scene-search input::placeholder{color:#a0b2cb}
.draft-preview #preview{padding:4px 8px;border-radius:5px;background:#253b6199;font-size:10px;display:inline!important}.draft-preview .studio-link{border:1px solid #bdd4ff44;background:#294879ed;color:#eef5ff}.draft-preview .studio-link:hover{background:#3c62a1}
@media(max-width:1150px){.editor-v12 .scene-actions button{padding:5px 7px;font-size:10px}.editor-v12 .scene-actions svg{display:none}.editor-v12 .editor-modes button{padding:5px 8px;font-size:10px}.editor-v12 .stage-top{gap:8px}.editor-v12 .stage-scene-name{max-width:25%}.selection-tools>strong{max-width:85px}}
@media(max-width:800px){.editor-v12 .editor-modes{position:absolute;top:35px;left:0;padding:2px}.editor-v12 .editor-modes button{min-height:30px;font-size:10px;padding:6px 8px}.editor-v12 .editor-modes svg{width:13px;height:13px}.editor-v12 .stage-scene-name{max-width:55%}.canvas-add-tools{bottom:48px;left:8px;right:8px;transform:none;max-width:none;justify-content:center;padding:3px;border-radius:9px;gap:1px}.editor-v12 .canvas-add-tools button{font-size:9px;padding:6px 7px;gap:4px;min-height:36px}.editor-v12 .canvas-add-tools svg{width:14px;height:14px}.selection-tools{left:8px;right:8px;transform:none;top:87px;max-width:none;justify-content:center;padding:4px;gap:0}.selection-tools>strong{display:none}.editor-v12 .selection-tools button{font-size:9px;min-height:36px}.editor-v12 .selection-tools .selection-icon{width:33px;min-width:33px;padding:7px}.editor-v12 .color-presets button{min-width:32px;width:32px;min-height:32px;height:32px}.editor-v12 .scene-actions button{font-size:9px;padding:5px}.scene-overview-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.viewer .scene-drawer-head button{min-width:36px;width:36px;min-height:34px;height:34px}.draft-preview #preview{font-size:8px;padding:3px 5px;max-width:50%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}}
@media(prefers-reduced-motion:reduce){.color-presets button{transition:none!important}}
.walk-audio{position:absolute;z-index:6;bottom:64px;left:50%;transform:translateX(-50%);padding:12px;background:#1c293cec;border:1px solid #ffffff3b;border-radius:12px;display:grid;grid-template-columns:1fr 32px;gap:8px;width:min(340px,calc(100% - 28px));box-shadow:0 5px 25px #0003}.walk-audio[hidden]{display:none!important}.walk-audio strong{font-size:12px;font-weight:500;grid-column:1}.walk-audio audio{grid-column:1;grid-row:2;width:100%;height:34px;color-scheme:dark}.editor-v12 .walk-audio button{grid-column:2;grid-row:1/3;padding:6px;min-width:28px;align-self:center}.walk-audio button span{display:none}
/* V15: enhanced text editing & music UX */
.inline-text-editor{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);z-index:9;width:min(380px,calc(100% - 32px));padding:14px;border-radius:14px;background:#182130f2;border:1px solid #7fa9ff66;box-shadow:0 16px 48px #0008;backdrop-filter:blur(16px);display:flex;flex-direction:column;gap:10px}
.inline-text-editor[hidden]{display:none!important}
.inline-text-editor header{display:flex;align-items:center;justify-content:space-between;font-size:12px;color:#c7d6ee}
.inline-text-editor header small{font-size:10px;color:#8ea1bc}
.inline-text-editor textarea{width:100%;min-height:86px;padding:10px 12px;border-radius:8px;border:1px solid #4a5a75;background:#101722;color:#f3f6fb;font:14px/1.55 system-ui;resize:vertical;box-sizing:border-box}
.inline-text-editor textarea:focus{outline:1px solid #7fa9ff;border-color:#7fa9ff}
.inline-text-editor .inline-actions{display:flex;gap:8px;justify-content:flex-end}
.selection-colors{display:flex;align-items:center;gap:5px;padding:0 4px;border-left:1px solid #ffffff22;border-right:1px solid #ffffff22}
.editor-v12 .selection-colors button{width:18px;min-width:18px;height:18px;min-height:18px;padding:0;border-radius:50%;border:1.5px solid #ffffff77}
.editor-v12 .selection-colors button:hover{transform:scale(1.18);border-color:#fff}
.chip-row{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0 12px}
.editor-v12 .chip-row button{flex:1;min-width:0;min-height:30px;padding:5px 8px;font-size:11px;background:#1b1f27;border-color:#3d4452;color:#b7c3d6;white-space:nowrap}
.editor-v12 .chip-row button.active{background:#345699;border-color:#78a3ff;color:#fff}
.style-details{margin:10px 0;border:1px solid #39404d;border-radius:8px;background:#1d2129}
.style-details summary{padding:9px 12px;cursor:pointer;font-size:11px;color:#b8c7de}
.style-details>div{padding:0 10px 10px}
.audio-card.drop-audio{border-color:#6d9cff;background:#202b40}
.audio-meta{display:flex;align-items:center;gap:8px;margin-bottom:10px;padding:8px 10px;border-radius:7px;background:#141820;border:1px solid #303744}
.audio-meta svg{width:16px;height:16px;color:#7ca8ff;flex:none}
.audio-meta>div{min-width:0;flex:1}
.audio-meta strong{display:block;font-size:11px;font-weight:500;color:#eef3fb;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.audio-meta small{display:block;font-size:10px;color:#8b9bb4;margin-top:2px}
.audio-drop-zone{border:1.5px dashed #475266;border-radius:8px;padding:14px 10px;text-align:center;color:#9eb0c8;font-size:11px;line-height:1.6;margin-bottom:10px;cursor:pointer;transition:border-color .15s,background .15s}
.audio-drop-zone:hover{border-color:#749fff;background:#222b3d;color:#dce8ff}
.audio-upload-progress{margin:6px 0 10px;font-size:11px;color:#8cb6ff}
.audio-upload-progress progress{display:block;width:100%;height:5px;margin-top:5px;accent-color:#6c9bff}
.editor-v12 .stage-bgm-btn{pointer-events:auto;background:#161b24bd;border:1px solid #ffffff30;font-size:11px;min-height:32px;padding:6px 10px;backdrop-filter:blur(12px)}
.editor-v12 .stage-bgm-btn[hidden]{display:none!important}
.editor-v12 .stage-bgm-btn.playing{background:#2a5599e0;border-color:#8cb6ff;color:#fff}
.editor-v12 .stage-bgm-btn svg{width:15px;height:15px}
.canvas-add-tools .has-music::after{content:'';width:6px;height:6px;border-radius:50%;background:#4be0a8;margin-left:2px}
@media(max-width:800px){.editor-v12 .viewport-tools{display:flex;flex-direction:row;gap:1px;bottom:8px;right:8px}.editor-v12 .viewport-tools button{width:30px;min-width:30px;min-height:34px;height:34px}.canvas-add-tools{bottom:56px}.editor-v12 .canvas-add-tools button{min-height:40px}.selection-tools{top:auto;bottom:112px}.selection-colors{display:none}}
