.story-studio-shell{width:min(1580px,calc(100% - 36px));margin:auto;padding-bottom:60px}.ss-head{display:flex;justify-content:space-between;align-items:end;gap:24px;padding:38px 0 24px}.ss-head h1{font:clamp(20px,3vw,34px)/1.7 'Press Start 2P';margin:12px 0}.ss-head h1 span{color:#69e8df}.ss-head p:not(.eyebrow){max-width:850px;color:#aebbd2;font-size:13px;line-height:1.8}.ss-head>a{font-size:9px;color:#75eee3;white-space:nowrap}.ss-chapterbar,.ss-meta,.ss-editor,.ss-sequence,.ss-preview{background:#11182a;border:1px solid #2d3c5a;padding:18px;margin-bottom:14px}.ss-chapterbar{display:grid;grid-template-columns:1.5fr 1fr 1fr auto;gap:12px;align-items:end}.ss-chapterbar label,.ss-meta label,.ss-editor label{display:grid;gap:7px;color:#aebbd2;font-size:10px;letter-spacing:.5px}.ss-chapterbar select,.ss-meta input,.ss-editor input,.ss-editor select,.ss-editor textarea,.ss-editor button,.ss-editor input[type=color]{width:100%;padding:11px;background:#091326;border:1px solid #354867;color:#eef5ff;font:12px Inter;border-radius:5px}.ss-chapterbar button,.ss-actions button,.ss-import,.ss-section-head button{padding:11px 14px;background:#182b45;border:1px solid #45617e;color:#e5f5ff;font-size:9px;font-weight:800;letter-spacing:.5px;cursor:pointer;border-radius:5px}.ss-meta{display:grid;grid-template-columns:1fr 1.4fr;gap:12px}.ss-workspace{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(320px,.65fr);gap:14px;align-items:start}.ss-section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}.ss-section-head h2{font:11px/1.7 'Press Start 2P';margin:8px 0}.ss-section-head>span{font-size:8px;color:#76e9df}.builder-intro,.builder-panel,.repeat-group{background:#0b1428;border:1px solid #344967;border-radius:7px;padding:14px;margin:12px 0}.builder-intro{border-left:3px solid #66dcd2}.builder-intro b,.builder-panel h3,.repeat-group h4{font-size:10px;color:#f1d98d;letter-spacing:.4px}.builder-intro p,.panel-help,.field-help{font-size:11px;color:#9eafc9;line-height:1.65;margin:7px 0 0}.scene-top-grid,.field-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.scene-top-grid{margin:14px 0}.builder-panel h3{margin:0 0 5px}.builder-panel>p{margin:0 0 14px}.builder-panel label{margin:10px 0}.builder-panel textarea{min-height:82px;resize:vertical;line-height:1.5}.builder-panel input[type=checkbox]{width:auto}.builder-panel .checkline{display:flex;align-items:center;gap:9px}.builder-panel .checkline input{width:auto}.repeat-list{display:grid;gap:10px}.repeat-row{display:grid;grid-template-columns:1fr 1fr;gap:9px;padding:12px;background:#111d33;border:1px solid #2c405e;border-radius:6px}.repeat-row .wide{grid-column:1/-1}.repeat-row .remove-row{grid-column:1/-1;width:auto;justify-self:end;padding:7px 10px;color:#ffc4d2;border-color:#75485b}.add-row{width:auto!important;margin-top:10px;background:#183d48!important;border-color:#3b8b88!important}.field-full{grid-column:1/-1}.scene-type-note{font-size:11px;color:#d1dbee;background:#13243b;padding:10px;border-radius:5px;margin:10px 0}.scene-list{display:grid;gap:8px;max-height:900px;overflow:auto}.scene-card{padding:12px;background:#0b1428;border:1px solid #354665;border-radius:6px}.scene-card.active{border-color:#62e6db;background:#102a37}.scene-card-head{display:flex;justify-content:space-between;gap:10px}.scene-card-head strong{font-size:10px}.scene-card-head small{font-size:8px;color:#78e5da}.scene-card p{font-size:10px;color:#9daec7;line-height:1.5;margin:8px 0}.scene-card-actions{display:flex;gap:6px;flex-wrap:wrap}.scene-card-actions button{padding:6px 8px;background:#1a2b44;border:1px solid #435879;color:#d8eaff;font-size:8px;cursor:pointer;border-radius:4px}.scene-card-actions .delete{border-color:#7b425a;color:#ffc9d9}.ss-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}.ss-actions .primary{background:#15504e;border-color:#61ded0}.ss-import{display:inline-flex;align-items:center;position:relative;overflow:hidden}.ss-import input{position:absolute;inset:0;opacity:0;cursor:pointer}.ss-preview{margin-top:14px}.preview-screen{max-width:850px;margin:0 auto;padding:28px;background:radial-gradient(ellipse at top,#20395a,#090f1e 70%);border:5px solid #364866;min-height:260px}.preview-screen>span{font:9px 'Press Start 2P';color:#70eee2}.preview-screen h3{font:14px 'Press Start 2P';line-height:1.7;color:#f3d477}.preview-screen p{font-size:13px;line-height:1.8;color:#e1eaff;white-space:pre-wrap}.preview-choices{display:flex;flex-wrap:wrap;gap:8px;margin:18px 0}.preview-choices button,.preview-screen>button{padding:11px 14px;background:#153c4b;border:1px solid #69dfd4;color:#f1fffe;font-size:10px;cursor:pointer}.preview-minigame{padding:14px;background:#091326;border:1px solid #405778;margin:14px 0}.preview-minigame canvas{display:block;width:min(100%,520px);height:auto;margin:auto;image-rendering:pixelated;border:2px solid #637b9d}.preview-minigame .game-controls{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin:10px}.preview-minigame button{padding:9px 13px;background:#1a3b51;border:1px solid #5a9baf;color:#fff;cursor:pointer}.preview-progress{font-size:8px!important;color:#8fa1bd!important}.validation-note{padding:10px;border:1px solid #9c7142;background:#332817;color:#ffe2a5;font-size:11px;line-height:1.6;margin:12px 0;border-radius:5px}@media(max-width:980px){.ss-workspace{grid-template-columns:1fr}.ss-chapterbar{grid-template-columns:1fr 1fr}}@media(max-width:620px){.story-studio-shell{width:calc(100% - 20px)}.ss-head{display:block}.ss-head>a{display:inline-block;margin-top:12px}.ss-meta,.ss-two,.scene-top-grid,.field-grid{grid-template-columns:1fr}.ss-chapterbar{grid-template-columns:1fr}.repeat-row{grid-template-columns:1fr}.repeat-row .wide{grid-column:auto}.ss-section-head h2{font-size:9px}}
.tilemap-editor{margin-top:14px;padding:12px;background:#091326;border:1px solid #405778;border-radius:6px}.tilemap-editor>b{font-size:10px;color:#f1d98d}.tilemap-tools{display:flex;align-items:end;gap:10px;margin:10px 0}.tilemap-tools label{flex:1}.tilemap-tools button{width:auto!important;white-space:nowrap}.tilemap-editor canvas{display:block;max-width:100%;height:auto;image-rendering:pixelated;border:2px solid #5b7192;touch-action:none}.preview-visual{margin:0 0 18px;padding:10px;background:#081326;border:1px solid #415775}.preview-visual canvas{display:block;margin:auto;image-rendering:pixelated}.preview-visual p{font-size:10px!important;color:#9eb5d1!important;text-align:center;margin:8px 0 0}

/* 8J.3 friendly authoring refresh */
.story-studio-shell{width:min(1440px,calc(100% - 40px));padding-bottom:72px;color:#edf3ff}
.ss-head{padding:30px 0 20px;align-items:center}.ss-head h1{font-size:clamp(17px,2.5vw,27px);letter-spacing:.02em}.ss-head p:not(.eyebrow){font-size:14px;max-width:680px}
.ss-chapterbar,.ss-meta,.ss-editor,.ss-sequence,.ss-preview{background:#111a2b;border-color:#293b56;border-radius:12px;box-shadow:0 10px 30px #03081335}
.ss-chapterbar{padding:14px 16px;gap:10px}.ss-meta{padding:14px 16px}.ss-chapterbar label,.ss-meta label,.ss-editor label{font-size:11px;letter-spacing:.2px;color:#c1cde0}
.ss-chapterbar select,.ss-meta input,.ss-editor input,.ss-editor select,.ss-editor textarea,.ss-editor button,.ss-editor input[type=color]{border-radius:8px;padding:12px 13px;background:#0a1323;border-color:#344966;font-size:13px}
.ss-chapterbar button,.ss-actions button,.ss-import,.ss-section-head button{border-radius:8px;font-size:10px;padding:12px 15px}
.ss-workspace{grid-template-columns:minmax(0,1.55fr) minmax(285px,.65fr);gap:16px}
.ss-editor,.ss-sequence{padding:20px}
.ss-section-head{margin-bottom:18px}.ss-section-head h2{font:10px/1.8 'Press Start 2P';color:#f3f6ff}
.ss-section-head>span{font-size:9px;letter-spacing:.4px}
.builder-intro{display:grid;grid-template-columns:1fr auto;align-items:center;gap:8px 16px;padding:16px 18px;border:1px solid #31536a;border-left:4px solid #6bded2;border-radius:10px;background:linear-gradient(110deg,#102b3b,#101b2e)}
.builder-intro b{font-size:12px;color:#e6fffb;letter-spacing:.2px}.builder-intro p{font-size:12px;line-height:1.6;margin:5px 0 0;color:#b7c8dc}.builder-intro button{width:auto!important;white-space:nowrap;background:#16534f!important;border-color:#4cc9bd!important;font-weight:700}.builder-intro small{grid-column:1/-1;color:#91a8c2;font-size:10px}
.scene-top-grid{margin:16px 0 12px}.scene-top-grid label{font-size:12px!important;font-weight:700}.scene-top-grid select,.scene-top-grid input{font-size:14px!important}
.scene-type-note{padding:12px 14px;border-radius:9px;background:#15283b;border:1px solid #2e4d65;color:#c9d9ed;font-size:12px;line-height:1.6;margin:12px 0}
.builder-panel,.repeat-group{padding:0;margin:10px 0;background:#0d1728;border:1px solid #293e5b;border-radius:10px;overflow:hidden}
.builder-panel.is-foldable,.repeat-group.is-foldable{transition:border-color .15s ease}
.fold-toggle{width:100%!important;display:flex;align-items:center;gap:10px;text-align:left;padding:14px 15px!important;border:0!important;border-radius:0!important;background:transparent!important;color:#eef5ff!important}
.fold-toggle:hover{background:#14253b!important}
.fold-chevron{display:grid;place-items:center;width:23px;height:23px;border-radius:7px;background:#1b3048;color:#79e7dc;font-size:21px;line-height:1;transition:transform .15s}
.is-open>.fold-toggle .fold-chevron{transform:rotate(90deg)}
.fold-title{font-size:12px;font-weight:750;letter-spacing:.1px}
.fold-hint{margin-left:auto;color:#8fa5c0;font-size:10px;font-weight:500}
.fold-body{display:none;padding:0 15px 16px;border-top:1px solid #233750}
.is-open>.fold-body{display:block}
.fold-body>.panel-help{margin:12px 0 4px;font-size:11px}
.builder-panel .fold-body>.field-grid{padding-top:8px}
.repeat-group{margin:12px 0;background:#101d30}
.repeat-group .fold-body{padding-top:10px}
.repeat-group .fold-toggle{padding:11px 12px!important}
.repeat-group .fold-title{font-size:11px}
.repeat-group .fold-hint{font-size:9px}
.repeat-row{padding:13px;background:#0b1526;border-color:#2a3e59;border-radius:8px;gap:10px}
.repeat-row label{font-size:10px}.repeat-row input,.repeat-row textarea,.repeat-row select{font-size:12px!important}
.repeat-row .remove-row{width:auto!important}
.add-row{width:auto!important;padding:10px 13px!important;border-radius:8px!important;font-size:10px!important}
.field-help,.panel-help{font-size:11px;line-height:1.55;color:#94a9c4}
.tilemap-editor{border-radius:9px;padding:14px}.tilemap-tools{align-items:end}.tilemap-editor canvas{border-radius:6px}
.ss-actions{gap:9px}.ss-actions button.primary{background:#17605b;border-color:#62d9cc}.ss-actions button{font-size:10px}
.scene-card{border-radius:9px;padding:14px}.scene-card-head strong{font-size:11px}.scene-card p{font-size:11px}.scene-card-actions button{font-size:9px;padding:8px 10px;border-radius:6px}
.scene-list{max-height:700px}.ss-sequence .ss-actions{display:grid;grid-template-columns:1fr 1fr}.ss-sequence .ss-actions button{width:100%}
.validation-note{border-radius:8px}
@media(max-width:980px){.ss-workspace{grid-template-columns:1fr}.ss-sequence{order:2}}
@media(max-width:620px){.story-studio-shell{width:calc(100% - 18px)}.ss-editor,.ss-sequence{padding:13px}.builder-intro{grid-template-columns:1fr}.builder-intro button{white-space:normal}.builder-intro small{grid-column:auto}.fold-hint{display:none}.ss-sequence .ss-actions{grid-template-columns:1fr}.ss-head h1{line-height:1.9}}

/* Shared player-facing scene runtime inside Story Studio preview */
.preview-visual{display:grid;gap:10px}.preview-visual canvas{display:block;width:100%;max-width:680px;height:auto;margin:auto;image-rendering:pixelated;border:1px solid #425b7a}
.preview-visual button,.preview-visual .runtime-button{padding:10px 13px;background:#183d50;border:1px solid #5795a8;border-radius:5px;color:#f5fbff;font-size:10px;font-weight:700;cursor:pointer}
.preview-visual .runtime-dialogue,.preview-visual .runtime-panel,.preview-visual .runtime-game{padding:12px;margin:9px 0;background:#101d31;border:1px solid #38516e;border-radius:7px;text-align:left}
.preview-visual .runtime-speaker{color:#62e8dd}.preview-visual .runtime-feedback,.preview-visual .runtime-caption{font-size:11px;line-height:1.6;color:#c5d5e9}
.preview-visual .runtime-controls{display:flex;flex-wrap:wrap;gap:7px;justify-content:center}.preview-visual .runtime-game-canvas{display:block;max-width:100%;margin:auto}

/* 8J usability pass — plain-language expandable guidance */
.panel-guide,.choice-guide{margin:7px 0 10px;border:1px solid #2b4662;border-radius:7px;background:#0b1b2c}
.panel-guide summary,.choice-guide summary{cursor:pointer;list-style:none;padding:9px 11px;color:#8fe3dc;font-size:10px;font-weight:700}
.panel-guide summary::-webkit-details-marker,.choice-guide summary::-webkit-details-marker{display:none}
.panel-guide summary:before,.choice-guide summary:before{content:"＋";display:inline-block;margin-right:8px;color:#70d8cd}
.panel-guide[open] summary:before,.choice-guide[open] summary:before{content:"−"}
.panel-guide p,.choice-guide p{margin:0;padding:0 11px 11px;color:#bdcce0;font-size:11px;line-height:1.65}
.choice-guide{margin-top:5px}.choice-guide summary{font-size:9px;padding:7px 9px;color:#a9c4df}
.panel-help{margin-bottom:8px}
.builder-panel>.fold-body>.panel-guide,.repeat-group>.fold-body>.panel-guide{margin:8px 0 12px}
.field-help{line-height:1.55}

.select-field{display:grid;align-content:start;gap:0;min-width:0}.select-field>label{display:grid;gap:7px;color:#c1cde0;font-size:11px;letter-spacing:.2px}.select-field .choice-guide{margin-top:5px}

.field-help-wrap{display:grid;align-content:start;min-width:0}.field-help-wrap>label{display:grid;gap:7px;color:#c1cde0;font-size:11px;letter-spacing:.2px}.field-help-wrap .choice-guide{margin-top:5px}.field-help-wrap>.field-full{grid-column:1/-1}

.field-help-wrap.field-full{grid-column:1/-1}

.field-grid>.field-help-wrap:has(>label.field-full),.repeat-row>.field-help-wrap:has(>label.field-full){grid-column:1/-1}
