*{box-sizing:border-box}body{margin:0;background:#0d0e10;color:#eee;font:14px Arial,sans-serif}button,input,textarea,select{background:#191b1f;color:#eee;border:1px solid #30343a;border-radius:7px;padding:10px}button{cursor:pointer}button:disabled{opacity:.45;cursor:not-allowed}.top{height:48px;border-bottom:1px solid #25272b;display:flex;align-items:center;padding:0 16px;gap:15px}.brand{font-weight:800;font-size:18px}.layout{display:grid;grid-template-columns:190px 1fr;min-height:calc(100vh - 48px)}.side{border-right:1px solid #25272b;padding:14px}.side button{width:100%;margin:4px 0;text-align:left}.main{padding:22px 28px;max-width:1500px;width:100%;margin:0 auto;align-self:start}.builder-wrap{max-width:1120px;margin:8px auto 0}.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:14px}.card,.panel{background:#141619;border:1px solid #24272c;border-radius:10px;padding:16px}.card h3{margin-top:0}.primary{background:#eee;color:#111}.tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:10px}.tabs button.active{background:#eee;color:#111}.field{margin:12px 0}.field label{display:block;margin-bottom:6px;font-weight:600}.field input,.field textarea,.field select{width:100%}.field textarea{min-height:120px}.field textarea.tall{min-height:220px}.row{display:flex;gap:8px}.row>*{flex:1}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:12px}.grid3{display:grid;grid-template-columns:1fr 1fr 1fr;gap:12px}.section-head{display:flex;align-items:center;justify-content:space-between;gap:15px;margin:4px 0 14px}.section-head h1,.section-head h2{margin:0}.subcard{border:1px solid #2d3035;border-radius:8px;padding:12px;margin:10px 0;background:#111316}details.item{padding:0}details.item summary{cursor:pointer;padding:12px;list-style:none}.stat-editor{padding:0 12px 12px}.play{display:grid;grid-template-columns:190px minmax(430px,780px) 290px;gap:16px;justify-content:center}.chat{height:calc(100vh - 92px);display:flex;flex-direction:column}.msgs{flex:1;overflow:auto;padding:12px}.msg{margin:14px 0;line-height:1.6}.msg.user{background:#1a1c20;padding:12px;border-radius:8px}.compose{display:flex;gap:8px}.compose textarea{flex:1;min-height:72px;resize:vertical}.tiny{color:#92979f;font-size:12px}.item{background:#191b1f;padding:10px;border-radius:7px;margin:7px 0}.empty{padding:22px;border:1px dashed #34383f;border-radius:8px;color:#92979f;text-align:center}.danger{border-color:#7b3030;color:#ffb0b0}.danger:hover{background:#3b1f1f}#saveState{margin:8px 0 12px}.wide-btn{display:block;width:100%;text-align:left;margin:7px 0}.right-rail>.wide-btn,.play-left>.wide-btn{width:100%}.side-detail{border-top:1px solid #30343a;margin-top:12px;padding-top:12px}.side-detail textarea{width:100%;min-height:100px}.mini-card{background:#191b1f;border-radius:7px;padding:10px;margin:8px 0}.stat-line{display:flex;justify-content:space-between;gap:8px}.progress{height:10px;background:#2a2d32;border-radius:20px;overflow:hidden;margin:8px 0}.progress>div{height:100%}.suggestions{display:grid;gap:8px;margin:6px 0 16px}.suggestions button{text-align:left;line-height:1.4;background:#1a1c20}.suggestions button:hover{border-color:#777}.example-row select{flex:0 0 130px}.example-row button{flex:0 0 auto}.example-row textarea{min-height:70px}.memory-tabs{margin-bottom:8px}hr{border:0;border-top:1px solid #30343a;margin:16px 0}
@media(max-width:1050px){.play{grid-template-columns:1fr}.play .rail{display:block}.chat{height:auto;min-height:650px}.layout{grid-template-columns:1fr}.side{display:none}.grid3{grid-template-columns:1fr}.grid2{grid-template-columns:1fr}.builder-wrap{margin-top:0}}
/* V1.4 additions */
.tagbox{display:flex;flex-wrap:wrap;gap:7px;align-items:center;background:#111316;border:1px solid #30343a;border-radius:8px;padding:8px;min-height:46px}.tagbox>input{border:0;background:transparent;min-width:210px;flex:1;padding:6px}.tag{display:inline-flex;align-items:center;gap:4px;background:#24272c;border:1px solid #3b3f46;border-radius:999px;padding:5px 8px}.tag button{border:0;background:transparent;padding:0 2px;color:#aaa}.file-btn{display:inline-block;background:#191b1f;border:1px solid #30343a;border-radius:7px;padding:10px;cursor:pointer}.media-row{display:flex;gap:14px;align-items:flex-start}.thumb{width:120px;height:150px;object-fit:cover;border-radius:8px;border:1px solid #30343a}.media-fields{flex:1}.formline{display:flex;align-items:center;gap:8px;padding:8px 0}.formline input{width:auto}.mini-card summary{cursor:pointer;list-style:none}.mini-card summary::-webkit-details-marker{display:none}.expanded-character{margin-top:9px;padding-top:9px;border-top:1px solid #30343a;white-space:pre-wrap;color:#cfd2d7;line-height:1.45}.suggestion-card{display:grid;grid-template-columns:1fr 46px;gap:6px}.suggestion-fill{text-align:left;line-height:1.4;background:#1a1c20}.suggestion-send{font-size:16px}.stat-change-row{display:flex;gap:6px;flex-wrap:wrap;margin:-4px 0 12px}.stat-change{font-size:11px;border:1px solid #3a3d43;border-radius:999px;padding:3px 7px;color:#bfc4cb}.streaming{min-height:24px}.msg p{margin:0 0 14px}.msg p:last-child{margin-bottom:0}.msg.assistant{white-space:normal}.builder-wrap{margin-top:0}.panel textarea{line-height:1.45}
@media(max-width:700px){.media-row{flex-direction:column}.thumb{width:100px;height:125px}.suggestion-card{grid-template-columns:1fr 42px}}
.mini-card summary{display:flex;gap:9px;align-items:flex-start}.char-avatar{width:44px;height:44px;object-fit:cover;border-radius:7px;flex:0 0 auto}.scene-images{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px;margin:10px 0 14px}.scene-images figure{margin:0}.scene-images img{display:block;width:100%;max-height:430px;object-fit:contain;border-radius:9px;border:1px solid #30343a;background:#0c0d0f}.scene-images figcaption{font-size:11px;color:#92979f;margin-top:4px}
/* V1.5 */
.story-cover{width:100%;aspect-ratio:3/4;object-fit:cover;border-radius:8px;border:1px solid #30343a;background:#111316}.placeholder{display:flex;align-items:center;justify-content:center;font-size:42px;color:#666}.character-cover{width:100%;height:190px;object-fit:cover;border-radius:8px;border:1px solid #30343a;background:#111316}.builder-split{display:grid;grid-template-columns:minmax(560px,1.25fr) minmax(360px,.75fr);gap:18px;align-items:start}.builder-left{min-width:0}.builder-preview{position:sticky;top:18px;max-height:calc(100vh - 85px);overflow:auto}.preview-title{display:flex;gap:12px;align-items:center;border-bottom:1px solid #30343a;padding-bottom:12px}.preview-title img{width:58px;height:76px;object-fit:cover;border-radius:7px}.preview-stats{display:flex;gap:8px;flex-wrap:wrap;padding:10px 0;border-bottom:1px solid #30343a}.preview-stats span{font-size:11px;background:#1b1d21;padding:6px 8px;border-radius:6px}.preview-scene{font-family:Georgia,serif;font-size:15px;line-height:1.65;padding-top:12px}.profile-cover{display:block;width:130px;aspect-ratio:3/4;object-fit:cover;border-radius:8px;margin:8px 0}.example-convo summary{display:flex;justify-content:space-between;cursor:pointer}.example-chat{padding:12px;display:flex;flex-direction:column;gap:10px}.example-bubble{width:min(78%,680px);background:#1a1c20;border:1px solid #30343a;border-radius:12px;padding:10px}.example-bubble.user{align-self:flex-end}.example-bubble.character{align-self:flex-start}.example-bubble textarea{width:100%;min-height:70px;border:0;background:transparent;padding:5px}.example-bubble .danger{float:right;padding:5px}.example-composer{display:grid;grid-template-columns:130px 1fr auto;gap:8px;padding:12px}.example-composer textarea{min-height:70px}.over-budget{color:#ff8f8f}.compose-tools{display:flex;justify-content:space-between;align-items:center;position:relative}.play-menu{position:relative}.play-menu summary{cursor:pointer;list-style:none;border:1px solid #30343a;border-radius:999px;padding:5px 10px}.menu-pop{position:absolute;right:0;bottom:36px;width:230px;background:#141619;border:1px solid #30343a;border-radius:9px;padding:7px;z-index:20;box-shadow:0 8px 28px #000}.menu-pop button{width:100%;text-align:left;margin:3px 0}.msg.assistant{position:relative}.msg-edit{opacity:0;position:absolute;right:0;top:0;padding:4px 7px}.msg.assistant:hover .msg-edit{opacity:1}.cursor{animation:blink .8s steps(1) infinite}@keyframes blink{50%{opacity:0}}
@media(max-width:1150px){.builder-split{grid-template-columns:1fr}.builder-preview{position:relative;top:auto;max-height:none}.example-composer{grid-template-columns:1fr}}

/* V1.6 polish */
.copy-code-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.copy-code-row code{flex:1;min-width:220px;padding:9px 11px;border:1px solid #303640;border-radius:8px;background:#0d1117;color:#d9e0ea;overflow-wrap:anywhere}.color-preset{display:flex;align-items:center;gap:10px}.color-preset select{flex:1}.color-swatch{width:22px;height:22px;border-radius:50%;border:2px solid #59616d;display:inline-block;flex:0 0 auto}.inline-story-image{margin:16px 0}.inline-story-image img{display:block;max-width:100%;max-height:520px;border-radius:10px;object-fit:contain}.inline-story-image figcaption{margin-top:6px;color:#9aa4b2;font-size:12px}.missing-media{display:inline-block;padding:4px 8px;border:1px dashed #7a3941;border-radius:6px;color:#f2a5ad;background:#251216}
/* V1.7 */
.play-story-title{display:flex;align-items:center;gap:10px;margin-bottom:10px}.play-story-title h3{margin:0}.play-story-title img{width:42px;height:54px;object-fit:cover;border-radius:7px;border:1px solid #30343a}.color-menu{position:relative}.color-menu>summary{display:flex;align-items:center;gap:9px;border:1px solid #30343a;border-radius:7px;padding:9px;cursor:pointer;list-style:none}.color-options{position:absolute;z-index:30;top:44px;left:0;min-width:190px;background:#141619;border:1px solid #30343a;border-radius:8px;padding:6px;box-shadow:0 10px 28px #000}.color-options button{width:100%;display:flex;align-items:center;gap:9px;text-align:left;border:0}.icon-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(82px,1fr));gap:7px}.icon-choice{display:flex;flex-direction:column;align-items:center;gap:4px;font-size:20px}.icon-choice span{font-size:10px;color:#aeb4bd}.icon-choice.selected{border-color:#eee;background:#25282d}.achievement-tabs{padding:8px 0 12px;border-bottom:1px solid #30343a}.achievement-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}.achievement-unlocked,.achievement-locked{min-height:92px;border:1px solid #30343a;border-radius:8px;display:flex;flex-direction:column;align-items:center;justify-content:center;overflow:hidden;gap:4px}.achievement-unlocked img{width:100%;height:72px;object-fit:cover}.achievement-unlocked span,.achievement-locked span{font-size:10px;padding:3px}.achievement-locked{background:#101216;color:#69707a}.ending-unlocked{margin:10px 0;padding:10px;border:1px solid #6e5a24;border-radius:8px;background:#241f12}.typing-label{color:#92979f;font-style:italic;margin-right:5px}

/* V1.8 */
.toolbar{display:flex;gap:7px;flex-wrap:wrap;align-items:center;justify-content:flex-end}
.details-toolbar{display:flex;gap:7px;flex-wrap:wrap}
details.stat-item>summary,details.lore-item>summary,details.ending-item>summary{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;cursor:pointer;list-style:none}
details.stat-item>summary::-webkit-details-marker,details.lore-item>summary::-webkit-details-marker,details.ending-item>summary::-webkit-details-marker{display:none}
.detail-title{display:flex;align-items:center;gap:8px;min-width:0}.detail-toggle::after{content:'+';font-size:20px;color:#aeb4bd}.stat-item[open] .detail-toggle::after,.lore-item[open] .detail-toggle::after,.ending-item[open] .detail-toggle::after{content:'−'}
.lore-body,.ending-body{padding:0 12px 12px}.group-chip,.rarity-chip{font-size:10px;color:#b9bec6;border:1px solid #3a3e45;border-radius:999px;padding:3px 7px}.group-tag{border-color:#4b5563}
.stat-icon{display:inline-flex;align-items:center;justify-content:center;font-size:20px;line-height:1;font-family:"Segoe UI Symbol","Noto Sans Symbols 2",sans-serif;font-variant-emoji:text}
.icon-choice .stat-icon{font-size:22px}.stat-line b{display:flex;align-items:center;gap:6px}.preview-stats .stat-icon{font-size:14px}
.achievement-unlocked{aspect-ratio:4/3;min-height:0;background:#101216}.achievement-unlocked img{width:100%;height:100%;object-fit:cover;display:block}.achievement-locked{aspect-ratio:4/3;min-height:0}
.inline-edit-box{width:100%;min-height:260px;max-height:60vh;resize:vertical;line-height:1.6;font:inherit;background:#111316;border:1px solid #4a5059;border-radius:8px;padding:12px;color:#e7e7e7}.inline-edit-actions{display:flex;gap:8px;margin-top:8px}.msg.editing{padding:0}
.ending-requirement{padding:10px}.ending-item textarea.tall{min-height:220px}
@media(max-width:700px){.toolbar{justify-content:flex-start}.inline-edit-box{min-height:200px}.achievement-grid{grid-template-columns:repeat(2,1fr)}}
.stat-icon svg{width:1em;height:1em;display:block;overflow:visible}

/* V1.9 */
.story-cover-frame,.character-cover-frame,.location-cover-frame,.profile-cover-frame,.preview-cover-frame,.panel-thumb-frame,.play-cover-thumb-frame,.crop-preview-frame{display:block;overflow:hidden;background:#111316;border:1px solid #30343a;border-radius:8px}
.story-cover-frame{width:100%;aspect-ratio:3/4}.story-cover-frame .story-cover{width:100%;height:100%;object-fit:cover;border:0;border-radius:0;display:block;transform-origin:center}
.character-cover-frame,.location-cover-frame{width:100%;height:190px}.character-cover-frame .character-cover,.location-cover-frame .location-cover{width:100%;height:100%;object-fit:cover;border:0;border-radius:0;display:block;transform-origin:center}
.profile-cover-frame{width:150px;aspect-ratio:3/4;margin:8px 0}.profile-cover-frame .profile-cover{width:100%;height:100%;object-fit:cover;border:0;border-radius:0;margin:0;display:block;transform-origin:center}
.preview-cover-frame{width:68px;height:90px;flex:0 0 auto}.preview-cover-frame .preview-cover{width:100%;height:100%;object-fit:cover;border:0;border-radius:0;display:block;transform-origin:center}
.panel-thumb-frame{width:58px;height:72px;flex:0 0 auto;transition:transform .18s ease;transform-origin:right center;position:relative;z-index:1}.panel-thumb-frame .panel-thumb{width:100%;height:100%;object-fit:cover;display:block;transform-origin:center}.mini-card:hover .panel-thumb-frame{transform:scale(3.1);z-index:40;box-shadow:0 10px 35px #000}.location-panel-thumb{width:66px;height:78px}
.play-cover-button{padding:0;border:0;background:transparent;position:relative;z-index:4}.play-cover-thumb-frame{width:68px;height:88px;transition:transform .18s ease;transform-origin:top right}.play-cover-thumb-frame .play-cover-thumb{width:100%;height:100%;object-fit:cover;display:block;transform-origin:center}.play-cover-button:hover .play-cover-thumb-frame{transform:scale(2.25);z-index:60;box-shadow:0 10px 35px #000}.play-story-title{min-height:92px;align-items:flex-start}.play-story-title h3{padding-top:8px}
.thumbnail-crop-panel{margin:10px 0;padding:12px;background:#0f1114;border:1px solid #30343a;border-radius:9px}.thumbnail-crop-panel[hidden]{display:none}.crop-preview-frame{width:180px;aspect-ratio:1/1;margin:10px 0}.crop-preview-frame img{width:100%;height:100%;object-fit:cover;display:block;transform-origin:center}.thumbnail-crop-panel input[type=range]{padding:0}
.image-preview-overlay{position:fixed;inset:0;background:#000c;display:flex;align-items:center;justify-content:center;z-index:9999;padding:24px;box-sizing:border-box}.image-preview-card{position:relative;width:min(92vw,900px);max-width:92vw;max-height:92vh;overflow:hidden;background:#141619;border:1px solid #3a3e45;border-radius:12px;padding:12px;text-align:center;box-shadow:0 20px 80px #000;box-sizing:border-box}.image-preview-card img{display:block;width:auto;height:auto;max-width:100%;max-height:calc(92vh - 64px);object-fit:contain;border-radius:8px;margin:0 auto 8px}.image-preview-close{position:absolute;right:8px;top:8px;font-size:22px;padding:4px 10px;background:#111c;z-index:2}
.location-locked summary{align-items:center}.locked-location-thumb{width:58px;height:66px;border:1px dashed #4a5059;border-radius:8px;display:flex;align-items:center;justify-content:center;font-size:24px;color:#747b85;background:#101216}.location-discovered{margin:10px 0;padding:9px 10px;border:1px solid #3d5e4a;border-radius:8px;background:#142019;color:#cfe8d7}.post-turn-status{margin-top:10px;color:#92979f;font-size:12px;font-style:italic}
.location-card p{min-height:42px}
@media(max-width:700px){.panel-thumb-frame{width:54px;height:66px}.mini-card:hover .panel-thumb-frame{transform:none}.play-cover-button:hover .play-cover-thumb-frame{transform:none}.play-cover-thumb-frame{width:72px;height:92px}.crop-preview-frame{width:150px}}
.story-cover-frame.placeholder,.character-cover-frame.placeholder,.location-cover-frame.placeholder{display:flex;align-items:center;justify-content:center}

/* V1.9.1 usability patch */
.panel-help{margin:-2px 0 10px}.panel-help>summary{display:inline-flex;align-items:center;gap:5px;cursor:pointer;color:#92979f;font-size:12px;list-style:none}.panel-help>summary::-webkit-details-marker{display:none}.help-q{display:inline-flex;align-items:center;justify-content:center;width:17px;height:17px;border:1px solid #4a5059;border-radius:50%;font-weight:700;color:#cfd2d7}.help-text{margin-top:7px;padding:8px 9px;background:#101216;border-left:2px solid #444b55;color:#b9bec6;font-size:12px;line-height:1.45}.memory-tabs{display:flex;align-items:center;justify-content:space-between;gap:8px}.memory-card{display:flex;align-items:center;justify-content:space-between;gap:8px}.memory-card .formline{flex:1;margin:0}.memory-card .formline span{line-height:1.4}.chat-media-image{cursor:zoom-in;transition:transform .18s ease,box-shadow .18s ease;position:relative;z-index:1}.chat-media-image:hover{transform:scale(1.06);z-index:10;box-shadow:0 10px 28px #000}.achievement-unlocked{cursor:zoom-in}.achievement-thumb-frame{display:block;width:100%;height:100%;overflow:hidden}.achievement-thumb-frame .achievement-thumb{width:100%;height:100%;object-fit:cover;display:block}.side-detail h4{margin-bottom:6px}

/* V1.9.2 usability polish */
.profile-cover-button{display:block;width:max-content;padding:0;border:0;background:transparent;cursor:zoom-in;margin:0 0 8px}.profile-cover-button .profile-cover-frame{transition:transform .18s ease,box-shadow .18s ease}.profile-cover-button:hover .profile-cover-frame{transform:scale(1.08);box-shadow:0 10px 28px #000}.thumbnail-adjust-row{display:flex;align-items:center;gap:10px;margin:8px 0}.saved-thumb-preview-frame{display:inline-block;width:48px;height:60px;overflow:hidden;border:1px solid #30343a;border-radius:7px;background:#111316;vertical-align:middle}.saved-thumb-preview-frame .saved-thumb-preview{width:100%;height:100%;object-fit:cover;display:block}.inline-help{margin:5px 0 0}.mini-card[open] .guide-preview{display:none}@media(max-width:700px){.profile-cover-button:hover .profile-cover-frame{transform:none}.saved-thumb-preview-frame{width:44px;height:56px}}

/* V1.10 pacing, performance, and character ordering */
.character-order-tools{display:flex;align-items:center;gap:6px;margin:8px 0 4px}.character-order-tools button{padding:5px 8px}.drag-handle{cursor:grab;font-size:18px;color:#b8bec7;user-select:none}.reorder-card.dragging{opacity:.55}.reorder-card.drag-over{outline:2px solid #686f79;outline-offset:2px}.stream-suggestion,.stream-suggestion-arrow{cursor:pointer}.post-turn-status{opacity:.9}.compose textarea:not(:disabled){transition:border-color .15s ease}
@media(max-width:700px){.drag-handle{display:none}.character-order-tools button{padding:7px 10px}}

/* V1.10.2 creator polish, lore management, discovery, and precise thumbnail hover */
.side-scroll-list{max-height:52vh;overflow-y:auto;overflow-x:visible;padding-right:5px;scrollbar-gutter:stable}.character-locked{display:flex;align-items:center;gap:9px}.lore-search-row{display:flex;align-items:center;gap:10px;margin:8px 0 10px}.lore-search-row input{flex:1}.lore-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:12px}.pagination{display:flex;align-items:center;gap:5px;flex-wrap:wrap}.pagination button{padding:6px 9px}.pagination button.active{background:#eee;color:#111}.lore-order-tools{display:flex;align-items:center;justify-content:flex-end;gap:6px;margin:0 0 6px}.lore-order-tools button{padding:5px 8px}.linked-stories>summary{cursor:pointer;border:1px solid #30343a;border-radius:7px;padding:9px;list-style:none}.linked-stories>summary::-webkit-details-marker{display:none}.linked-story-options{margin-top:6px;padding:8px 10px;border:1px solid #30343a;border-radius:8px;background:#101216;max-height:230px;overflow:auto}.achievement-tile{min-width:0}.achievement-unlocked{width:100%;padding:0;color:inherit}.achievement-label{font-size:10px;color:#c5cad1;margin-top:4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:center}.panel-thumb-frame{transition:none!important}.mini-card:hover .panel-thumb-frame{transform:none!important;box-shadow:none!important;z-index:1!important}.panel-thumb-float{position:fixed;display:block;overflow:hidden;background:#111316;border:1px solid #30343a;border-radius:8px;z-index:9998;pointer-events:none;box-shadow:0 10px 35px #000}.panel-thumb-float img{width:100%;height:100%;object-fit:cover;display:block;pointer-events:none}.right-rail{overflow:visible}
@media(max-width:700px){.side-scroll-list{max-height:420px}.panel-thumb-float{display:none}.lore-footer{align-items:flex-start}.pagination{justify-content:flex-start}}


/* V1.11 Skills Foundation */
.skill-template-body{padding:10px 12px 12px}.skill-modal-overlay{position:fixed;inset:0;background:#000b;z-index:9999;display:flex;align-items:center;justify-content:center;padding:24px}.skill-modal{width:min(860px,94vw);max-height:82vh;overflow-x:hidden;overflow-y:auto;background:#15171a;border:1px solid #343941;border-radius:14px;box-shadow:0 24px 90px #000;padding:18px;scrollbar-gutter:stable}.skill-modal-tabs{display:flex;gap:8px;margin:4px 0 14px}.skill-modal-tabs button.active{background:#f0f0f0;color:#111}.skill-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;max-height:62vh;overflow:auto;padding-right:5px}.skill-tile{min-height:92px;border:1px solid #30343a;border-radius:11px;background:#101216;padding:10px;display:flex;align-items:center;gap:8px}.skill-info{flex:1;min-width:0;text-align:left;background:transparent;border:0;padding:4px}.skill-info b,.skill-info span{display:block;overflow:hidden;text-overflow:ellipsis}.skill-info span{font-size:11px;color:#92979f;margin-top:6px}.skill-actions{display:flex;align-items:center;gap:7px}.skill-catalog{padding:5px 7px}.skill-disabled{opacity:.58}.switch{position:relative;display:inline-block;width:38px;height:22px;flex:0 0 auto}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background:#4a4f57;border-radius:999px;transition:.15s}.slider:before{content:'';position:absolute;width:16px;height:16px;left:3px;top:3px;background:#eee;border-radius:50%;transition:.15s}.switch input:checked+.slider{background:#8b5cf6}.switch input:checked+.slider:before{transform:translateX(16px)}.switch input:disabled+.slider{cursor:not-allowed;opacity:.45}
@media(max-width:800px){.skill-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:520px){.skill-grid{grid-template-columns:1fr}}

.skill-unlocked{margin:10px 0;padding:9px 10px;border:1px solid #594b78;border-radius:8px;background:#1b1625;color:#e4d8ff}

/* V1.11.1 Skills refinement */
.tip-help{display:inline-block;position:relative;margin-left:4px;vertical-align:middle}.tip-help>summary{list-style:none;cursor:pointer}.tip-help>summary::-webkit-details-marker{display:none}.tip-help .help-text{position:absolute;z-index:50;top:22px;left:0;width:min(330px,70vw);margin:0;padding:9px 10px;border:1px solid #343941;border-left:2px solid #59606b;border-radius:7px;background:#101216;box-shadow:0 10px 28px #000;color:#c3c7cd;font-weight:400}.aetheris-toast{position:fixed;left:50%;bottom:28px;z-index:12000;transform:translate(-50%,12px);opacity:0;background:#171a1f;border:1px solid #464c56;border-radius:9px;padding:10px 14px;box-shadow:0 12px 38px #000;color:#f1f1f1;transition:.18s ease;pointer-events:none}.aetheris-toast.show{opacity:1;transform:translate(-50%,0)}.compact-modal{width:min(560px,92vw);max-height:76vh;overflow:auto}.modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:16px}.skill-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.skill-tile{min-height:66px;padding:8px 9px}.skill-info{padding:2px}.skill-info span{margin-top:3px}.skill-actions{gap:5px}.skill-delete{padding:5px 7px}.skill-detail-list{display:grid;gap:8px;margin-top:14px}.skill-detail-list>div{display:flex;justify-content:space-between;gap:16px;border-top:1px solid #2b2f35;padding-top:8px}.skill-detail-list span{text-align:right;color:#b9bec6}

/* V1.12.1 pre-playtest QOL */
.play{transition:grid-template-columns .15s ease}
.play.left-collapsed{grid-template-columns:28px minmax(430px,970px) 290px}
.play.right-collapsed{grid-template-columns:190px minmax(430px,1070px) 28px}
.play.left-collapsed.right-collapsed{grid-template-columns:28px minmax(430px,1260px) 28px}
.play-left,.right-rail{position:relative;min-width:0}
.rail-toggle{position:absolute;z-index:80;top:10px;width:28px;height:38px;padding:0;display:flex;align-items:center;justify-content:center;font-size:20px;font-weight:700;background:#1b1e23}
.play-left .left-toggle{right:-15px}.right-rail .right-toggle{left:-15px}
.play.left-collapsed .play-left,.play.right-collapsed .right-rail{padding:0;background:transparent;border-color:transparent}
.play.left-collapsed .play-left .rail-content,.play.right-collapsed .right-rail .rail-content{display:none}
.play.left-collapsed .play-left .left-toggle{right:0}.play.right-collapsed .right-rail .right-toggle{left:0}
@media(max-width:1050px){.play,.play.left-collapsed,.play.right-collapsed,.play.left-collapsed.right-collapsed{grid-template-columns:1fr}.play.left-collapsed .play-left,.play.right-collapsed .right-rail{min-height:38px}.play-left .left-toggle,.play.left-collapsed .play-left .left-toggle,.right-rail .right-toggle,.play.right-collapsed .right-rail .right-toggle{left:auto;right:8px;top:0}}

/* V1.12.2 compact media editors */
.media-item>summary{cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:10px}.media-item>summary .detail-title{display:flex;align-items:center;gap:10px;min-width:0}.media-summary-thumb{width:42px;height:42px;object-fit:cover;border-radius:8px;flex:0 0 auto}.media-item[open]>summary{margin-bottom:12px}


/* V1.12.5 safe playtest QOL (UI only) */
.suggestion-card{display:grid;grid-template-columns:42px minmax(0,1fr) 48px;gap:6px;align-items:stretch}
.suggestion-edit,.suggestion-send{display:flex;align-items:center;justify-content:center;min-height:44px;padding:0}
.suggestion-text{display:flex;align-items:center;padding:10px 12px;border:1px solid var(--border);border-radius:8px;background:#1a1c20;line-height:1.35;min-width:0}
.continue-scene-row{display:flex;justify-content:flex-start;margin:8px 0 8px 0}
.continue-scene-btn{font-size:13px;padding:7px 12px}
.playthrough-counter{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;box-sizing:border-box;margin:0 0 12px 0;padding:0 0 10px 0;border-bottom:1px solid var(--border);font-size:13px}
.playthrough-counter span{color:var(--muted);text-align:right}

/* V1.12.10 Starting Classes */
.class-skill-list{display:grid;gap:6px;max-height:320px;overflow:auto;padding:6px 2px}.class-choice-card{display:flex;flex-direction:column;gap:10px;min-width:220px}.class-choice-card .primary,.class-choice-card button{margin-top:auto}.class-player-card{padding:8px 2px}.class-player-card h3{margin-top:0}.class-item .detail-title{gap:10px;align-items:center}

/* Starting Classes refinement */
details.class-item>summary{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;cursor:pointer;list-style:none}
details.class-item>summary::-webkit-details-marker{display:none}
.class-item[open] .detail-toggle::after{content:'−'}
.class-skill-tags{display:flex;flex-wrap:wrap;gap:7px;margin-top:9px}.class-skill-tag{display:inline-flex;align-items:center;gap:6px;padding:6px 8px;border:1px solid #34383f;border-radius:999px;background:#111316}.class-skill-tag button{border:0;background:transparent;padding:0 2px;color:#aeb4bd;font-size:16px}.class-skill-tag button:hover{color:#fff}
.class-image-editor-preview{height:90px;transition:height .18s ease;border:1px solid #30343a;border-radius:9px;overflow:hidden;background:#0f1114;margin:8px 0}.class-image-editor-preview img{width:100%;height:100%;object-fit:cover;display:block}
.class-choice-card{position:relative;overflow:hidden;isolation:isolate;min-height:245px}.class-choice-card .class-choice-content{position:relative;z-index:3;display:flex;flex-direction:column;gap:10px;height:100%}.class-choice-card.has-image{background:#111316}.class-choice-art{position:absolute;inset:0;z-index:0;overflow:hidden}.class-choice-art img{width:100%;height:100%;object-fit:cover;display:block;transition:filter .25s ease,opacity .25s ease,transform .25s ease}.class-choice-shade{position:absolute;inset:0;z-index:1;background:linear-gradient(to bottom,rgba(10,11,13,.12),rgba(10,11,13,.58) 55%,rgba(10,11,13,.88));transition:background .25s ease}.class-choice-card.has-image h3,.class-choice-card.has-image p,.class-choice-card.has-image .tiny{text-shadow:0 1px 3px #000}.class-choice-card.has-image p,.class-choice-card.has-image .tiny{transition:color .25s ease,opacity .25s ease}.class-choice-card.has-image:not(:hover) p,.class-choice-card.has-image:not(:hover) .tiny{opacity:.78}.class-choice-card.has-image:hover .class-choice-art img{filter:grayscale(.65) brightness(.42)}.class-choice-card.has-image:hover .class-choice-shade{background:rgba(8,9,11,.64)}.class-choice-card.has-image:hover p,.class-choice-card.has-image:hover .tiny{opacity:1;color:#f1f3f5}

/* V1.14 Memory V1 */
.memory-tabs{display:flex;gap:6px;flex-wrap:wrap;margin:8px 0 12px}.memory-tabs button{padding:6px 8px;font-size:12px}.memory-tabs button.active{background:#f0f0f0;color:#111}.memory-toolbar{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-bottom:8px}.memory-card{display:flex;align-items:flex-start;gap:8px}.memory-card-main{display:flex;align-items:flex-start;gap:9px;flex:1;min-width:0}.memory-copy{flex:1;min-width:0;overflow-wrap:anywhere}.memory-copy b{display:block;margin-bottom:4px}.memory-card-actions{display:flex;gap:5px}.memory-card-actions button{padding:5px 7px}.memory-status{font-size:10px;text-transform:uppercase;letter-spacing:.05em;padding:2px 6px;border:1px solid #3a3f46;border-radius:999px;color:#b9bec6}.memory-status.completed{color:#9bd4ae}.memory-status.failed,.memory-status.abandoned{color:#d3a5a5}

/* V1.14.1 Memory manager UI */
.memory-turn-counter{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:8px 0;padding:8px 11px;border-top:1px solid var(--border);border-bottom:1px solid var(--border);font-size:12px;color:var(--muted)}
.memory-turn-counter b{font-size:14px;color:#f0f0f0}.memory-modal{width:min(920px,94vw);height:min(760px,86vh);display:flex;flex-direction:column}.memory-modal>.section-head{flex:0 0 auto;margin-bottom:8px}.memory-modal>.section-head h2{margin:0}.memory-close{font-size:22px;line-height:1;padding:5px 10px}.memory-modal-tabs{display:flex;gap:8px;flex-wrap:wrap;padding:8px 0 14px;border-bottom:1px solid #2d3137}.memory-modal-tabs button{padding:8px 13px}.memory-modal-tabs button.active{background:#f0f0f0;color:#111}.memory-modal #memoryModalContent{display:flex;flex-direction:column;min-height:0;flex:1}.memory-modal-scroll{overflow:auto;min-height:0;flex:1;padding:14px 5px 4px 0}.memory-modal-toolbar{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:12px}.memory-toolbar-actions{display:flex;gap:8px}.memory-long-list{display:grid;gap:8px}.memory-entry{margin:0}.memory-entry>summary{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;cursor:pointer;list-style:none}.memory-entry>summary::-webkit-details-marker{display:none}.memory-entry .detail-toggle::after{content:'+'}.memory-entry[open] .detail-toggle::after{content:'−'}.memory-entry-body{padding:0 12px 12px}.memory-entry-text{line-height:1.5;white-space:pre-wrap}.memory-entry-actions{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px;padding-top:10px;border-top:1px solid #2d3137}.memory-entry-actions .formline{margin:0}.memory-disabled{opacity:.62}.memory-add-card{margin:0 0 12px;padding:12px;border:1px solid #343941;border-radius:10px;background:#101216}.memory-add-card textarea{min-height:110px}.memory-state-card{border:1px solid #30343a;border-radius:11px;background:#101216;padding:14px;margin-bottom:10px}.memory-state-card h3{margin:0}.memory-state-card p{line-height:1.5;margin:8px 0 0}.memory-state-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:10px 0}.memory-state-grid>div,.memory-state-section{padding:10px;border:1px solid #292d33;border-radius:8px;background:#15171a}.memory-state-grid span,.memory-state-grid strong,.memory-state-section span{display:block}.memory-state-grid strong{margin-top:3px}.memory-state-section{margin-top:10px}.memory-state-section p{margin:5px 0 0}.memory-state-section ul{margin:6px 0 0;padding-left:20px}.memory-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.memory-role{font-size:11px;color:var(--muted)}
@media(max-width:650px){.memory-modal{height:min(820px,92vh)}.memory-grid,.memory-state-grid{grid-template-columns:1fr}.memory-entry-actions,.memory-modal-toolbar{align-items:stretch;flex-direction:column}.memory-toolbar-actions{justify-content:flex-end}}

.memory-tab-buttons{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.memory-modal-turn{margin-left:auto;color:var(--muted);font-size:12px;white-space:nowrap;padding:8px 2px}.memory-status.paused{color:#d8c58a}

.collection-modal{width:min(1040px,94vw);height:min(86vh,900px);max-height:calc(100vh - 32px);box-sizing:border-box;overflow:hidden;display:flex;flex-direction:column}.collection-modal>.section-head{flex:0 0 auto;position:sticky;top:0;z-index:2;background:#15171a;padding-bottom:10px}.collection-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-rows:max-content;align-content:start;gap:12px;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;min-height:0;flex:1 1 auto;padding:4px 8px 16px 0}.collection-card{min-width:0;min-height:250px;align-self:start;border:1px solid #30343a;border-radius:12px;background:#101216;padding:12px;overflow:hidden}.collection-card h3{margin:0}.collection-card p{margin:8px 0 0;line-height:1.45;color:#d6d8dc}.collection-card-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:9px}.collection-state{font-size:11px;color:var(--muted);white-space:nowrap}.collection-thumb-frame{display:block;width:100%;height:210px;overflow:hidden;background:#111316;border:1px solid #30343a;border-radius:9px;cursor:zoom-in}.collection-thumb-frame img{width:100%;height:100%;object-fit:cover;display:block;transform-origin:center}.collection-thumb-frame:hover{outline:1px solid #6b7280;outline-offset:1px}.collection-locked{text-align:center}.collection-locked>summary{list-style:none;cursor:pointer}.collection-locked>summary::-webkit-details-marker{display:none}.collection-locked-thumb{height:150px;border:1px dashed #4a5059;border-radius:9px;display:flex;align-items:center;justify-content:center;font-size:42px;color:#747b85;background:#0d0f12;margin-bottom:9px}.collection-card-detail{text-align:left;padding-top:10px}.collection-card-detail p{margin-top:5px}@media(max-width:850px){.collection-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:560px){.collection-grid{grid-template-columns:1fr}.collection-thumb-frame{height:190px}}

/* V1.14.26 active-skill composer picker */
.continue-scene-row{align-items:center;gap:8px;position:relative}.active-skill-picker{position:relative}.active-skill-picker>summary{list-style:none;cursor:pointer}.active-skill-picker>summary::-webkit-details-marker{display:none}.active-skill-use-menu{position:absolute;left:0;bottom:calc(100% + 7px);width:min(330px,72vw);max-height:280px;overflow:auto;background:#141619;border:1px solid #34383f;border-radius:10px;padding:7px;z-index:40;box-shadow:0 10px 32px #000}.active-skill-use-menu button{width:100%;display:flex;justify-content:space-between;gap:10px;text-align:left;margin:3px 0}.active-skill-use-menu button span{font-size:11px;color:#92979f}.active-skill-use-menu button.selected{border-color:#8b5cf6;background:#211a31}

/* V1.14.27 multi-use active skill composer */
.active-skill-controls{display:flex;align-items:center;gap:8px;min-width:0;flex-wrap:wrap}.active-skill-chip-row{display:flex;align-items:center;gap:6px;flex-wrap:wrap}.active-skill-chip{display:inline-flex;align-items:center;gap:8px;padding:7px 10px;border:1px solid #6285ad;border-radius:9px;background:#172335;color:#eaf4ff;box-shadow:0 0 0 1px rgba(118,169,225,.08) inset;cursor:pointer}.active-skill-chip:hover{background:#1d2d43;border-color:#7aa5d5}.active-skill-chip b{font-size:15px;line-height:1;color:#a9c9ed}.active-skill-picker>summary.continue-scene-btn{border:1px solid #34383f;border-radius:8px;background:#17191c;color:#f1f1f1;display:inline-flex;align-items:center;min-height:34px}


/* V1.14.28 player/stats rail + compact play popouts */
.right-rail .rail-content{overflow:hidden}
.right-rail-page{min-width:0}
.rail-slide-right{animation:aetherisRailFromRight .18s ease-out}
.rail-slide-left{animation:aetherisRailFromLeft .18s ease-out}
@keyframes aetherisRailFromRight{from{opacity:.35;transform:translateX(28px)}to{opacity:1;transform:translateX(0)}}
@keyframes aetherisRailFromLeft{from{opacity:.35;transform:translateX(-28px)}to{opacity:1;transform:translateX(0)}}
.modal-note-box{width:100%;min-height:220px;resize:vertical}
.achievements-modal .skill-modal-tabs{margin-top:0}
.achievements-modal-scroll{overflow:auto;min-height:0;flex:1;padding-right:5px}
.achievements-modal .achievement-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
@media(max-width:700px){.achievements-modal .achievement-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* V1.14.29 player home shell + focused play mode */
.app-shell{min-height:100vh;background:#0d0e10}.app-rail{position:fixed;inset:0 auto 0 0;width:210px;border-right:1px solid #25272b;background:#101114;padding:20px 14px;display:flex;flex-direction:column;z-index:50}.app-brand{font-size:20px;font-weight:900;letter-spacing:.3px;margin:4px 8px 22px}.app-rail nav{display:grid;gap:8px}.app-nav-btn{display:flex;align-items:center;gap:11px;width:100%;text-align:left;border:0;background:transparent;padding:12px 13px;font-size:15px}.app-nav-btn:hover,.app-nav-btn.active{background:#1b1d22;border:1px solid #343840}.app-nav-btn span:first-child{font-size:18px;width:22px;text-align:center}.app-rail-foot{margin-top:auto;padding:12px}.app-content{min-height:100vh;margin-left:210px;padding-bottom:20px}.creator-toolbar{min-height:54px;border-bottom:1px solid #25272b;display:flex;align-items:center;gap:8px;padding:8px 24px;position:sticky;top:0;background:#0d0e10e8;backdrop-filter:blur(12px);z-index:30}.creator-toolbar button.active{background:#eee;color:#111}.mobile-bottom-nav{display:none}.player-home{max-width:1320px;margin:0 auto}.featured-story{min-height:320px;border:1px solid #252a31;border-radius:18px;background:linear-gradient(135deg,#171a20,#101216);display:grid;grid-template-columns:minmax(220px,350px) 1fr;gap:30px;align-items:center;padding:28px;margin-bottom:30px;overflow:hidden}.featured-copy{max-width:650px}.featured-copy h1{font-size:38px;line-height:1.08;margin:8px 0 12px}.featured-copy p{font-size:16px;color:#b5bac2;line-height:1.5}.eyebrow{font-size:11px;font-weight:800;letter-spacing:1.5px;color:#9fa7b4}.featured-cover-frame{display:block;height:270px;max-width:230px;margin:auto;border-radius:14px;overflow:hidden;box-shadow:0 18px 42px #0008}.featured-cover{width:100%;height:100%;object-fit:cover;display:block}.empty-feature{grid-template-columns:1fr}.library-section{margin:28px 0}.library-section-head{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:12px}.library-section-head h2{margin:0;font-size:22px}.story-row{display:flex;gap:14px;overflow-x:auto;padding:2px 2px 12px;scroll-snap-type:x proximity}.story-row::-webkit-scrollbar{height:8px}.library-story-card{flex:0 0 190px;min-width:0;background:#141619;border:1px solid #242a31;border-radius:13px;overflow:hidden;cursor:pointer;scroll-snap-align:start;transition:transform .16s ease,border-color .16s ease}.library-story-card:hover{transform:translateY(-2px);border-color:#4b535f}.library-story-card.compact{flex-basis:160px}.library-cover-frame{display:block;width:100%;height:245px;overflow:hidden;background:#111318}.library-story-card.compact .library-cover-frame{height:210px}.library-cover{width:100%;height:100%;object-fit:cover;display:block}.library-story-info{display:grid;gap:5px;padding:11px}.library-story-info>b{font-size:14px}.library-story-info span,.library-story-info small{color:#9299a3;font-size:11px;line-height:1.35}.placeholder-card{opacity:.62;cursor:default}.placeholder-card:hover{transform:none;border-color:#242a31}.placeholder{display:flex;align-items:center;justify-content:center;font-size:36px;color:#616977;background:linear-gradient(135deg,#181b21,#101216)}.explore-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(175px,1fr));gap:16px}.explore-grid .library-story-card{width:100%;flex:auto}.empty-row{min-width:100%;padding:24px;border:1px dashed #34383f;border-radius:10px;color:#92979f;text-align:center}.link-btn{background:transparent;border:0;padding:6px;color:#bbc2cc}.history-page{max-width:1100px;margin:0 auto}.history-grid{display:grid;gap:14px}.history-card{display:grid;grid-template-columns:100px 1fr;gap:16px;align-items:center;background:#141619;border:1px solid #252a31;border-radius:12px;padding:12px}.history-card h3{margin:0 0 5px}.history-cover-frame{display:block;width:88px;height:120px;overflow:hidden;border-radius:9px}.history-cover{width:100%;height:100%;object-fit:cover;display:block}.play-mode-header{height:52px;border-bottom:1px solid #25272b;display:flex;align-items:center;gap:10px;padding:0 16px;background:#101114;position:sticky;top:0;z-index:60}.play-back{border:0;background:transparent;font-size:24px;padding:5px 9px}.play-mode-title{font-size:17px;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.play-main{padding:18px 22px}.play-main .play{margin:0 auto}.play-main .chat{height:calc(100vh - 88px)}
@media(max-width:900px){.app-rail{display:none}.app-content{margin-left:0;padding-bottom:72px}.mobile-bottom-nav{position:fixed;display:grid;grid-template-columns:repeat(4,1fr);left:0;right:0;bottom:0;height:64px;background:#101114f5;border-top:1px solid #2a2d33;z-index:80;backdrop-filter:blur(12px)}.mobile-bottom-nav .app-nav-btn{display:grid;justify-items:center;align-content:center;gap:2px;border:0!important;border-radius:0;padding:5px;font-size:10px}.mobile-bottom-nav .app-nav-btn span:first-child{font-size:19px;width:auto}.creator-toolbar{padding:8px 12px;overflow-x:auto}.main{padding:18px 16px}.featured-story{grid-template-columns:140px 1fr;min-height:230px;padding:18px;gap:18px}.featured-cover-frame{height:190px;max-width:140px}.featured-copy h1{font-size:28px}.featured-copy p{font-size:14px}.play-main{padding:10px}.play-main .chat{height:auto;min-height:650px}}
@media(max-width:600px){.featured-story{grid-template-columns:1fr}.featured-art{display:none}.featured-copy h1{font-size:26px}.library-story-card{flex-basis:145px}.library-cover-frame{height:195px}.library-story-card.compact{flex-basis:135px}.library-story-card.compact .library-cover-frame{height:180px}.explore-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.history-card{grid-template-columns:74px 1fr}.history-cover-frame{width:66px;height:92px}.play-mode-header{height:48px}.play-main{padding:7px}}


/* V1.14.43 Explore carousel + Event Images */
.explore-featured{position:relative;padding-left:64px;padding-right:64px}
.explore-arrow{position:absolute;top:50%;transform:translateY(-50%);z-index:3;width:42px;height:64px;border-radius:14px;font-size:34px;line-height:1;display:flex;align-items:center;justify-content:center;background:rgba(15,20,32,.82);border:1px solid rgba(255,255,255,.16);box-shadow:0 8px 24px rgba(0,0,0,.28)}
.explore-arrow:hover:not(:disabled){transform:translateY(-50%) scale(1.04)}
.explore-arrow:disabled{opacity:.28;cursor:default}
.explore-prev{left:12px}.explore-next{right:12px}
.event-images-toggle{margin-top:10px;padding:10px 12px;border:1px solid rgba(255,255,255,.09);border-radius:10px;background:rgba(255,255,255,.025)}
.event-images-toggle .tiny{display:block;margin-top:2px}
@media(max-width:760px){.explore-featured{padding-left:46px;padding-right:46px}.explore-arrow{width:34px;height:54px;font-size:28px}.explore-prev{left:6px}.explore-next{right:6px}}

/* Ending rarity system: classic RPG difficulty tiers */
.ending-rarity-badge{width:30px;height:30px;display:inline-grid;place-items:center;transform:rotate(45deg);border:2px solid currentColor;border-radius:5px;background:#11151a;box-shadow:0 0 0 2px #11151a,0 0 10px currentColor;flex:0 0 auto}
.ending-rarity-badge span{transform:rotate(-45deg);font-weight:900;font-family:Georgia,serif;font-size:15px;line-height:1;text-shadow:0 1px 2px #000}
.rarity-common{color:#43b35b}.rarity-rare{color:#4387e8}.rarity-epic{color:#a45bea}.rarity-legendary{color:#e2b93b}
.rarity-text-common{border-color:#43b35b;color:#76d887}.rarity-text-rare{border-color:#4387e8;color:#75a9f3}.rarity-text-epic{border-color:#a45bea;color:#c38af1}.rarity-text-legendary{border-color:#e2b93b;color:#f0d36e}
.ending-unlocked .ending-rarity-badge{width:22px;height:22px;margin-right:8px;vertical-align:middle}.ending-unlocked .ending-rarity-badge span{font-size:11px}
.mini-card .ending-rarity-badge{width:20px;height:20px;margin-right:7px;vertical-align:middle}.mini-card .ending-rarity-badge span{font-size:10px}
\n\n/* V1.14.47 creator/library quality-of-life */
.library-controls{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0 0 16px}.library-controls>input{flex:1 1 280px;min-width:220px}.library-controls>label{display:flex;align-items:center;gap:8px;color:#b8bec7}.library-controls select{min-width:150px}.story-tag-row{display:flex;gap:6px;flex-wrap:wrap;margin:-3px 0 12px}.story-tag-row .tag{font-size:11px;padding:4px 7px}.library-story-group{border:1px solid #292d33;border-radius:11px;background:#111316;margin:12px 0;overflow:hidden}.library-story-group>summary{cursor:pointer;list-style:none;padding:13px 15px;display:flex;align-items:center;justify-content:space-between;gap:12px;background:#17191d}.library-story-group>summary::-webkit-details-marker{display:none}.library-story-group>summary:after{content:'+';color:#92979f;font-size:18px}.library-story-group[open]>summary:after{content:'−'}.library-story-group>.cards{padding:14px}.unsaved-modal{width:min(540px,94vw)}.unsaved-modal .modal-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap}.lore-item textarea,.lore-item input{user-select:text;-webkit-user-select:text}.lore-item .drag-handle{touch-action:none}
@media(max-width:650px){.library-controls{align-items:stretch}.library-controls>input,.library-controls>label{width:100%}.library-controls>label{justify-content:space-between}.library-controls select{flex:1}.unsaved-modal .modal-actions button{flex:1 1 100%}}

/* V1.14.47.1 streamlined library + endings polish */
.library-controls-stacked{display:grid;justify-items:start;align-items:start;gap:8px}.library-controls-stacked>input{width:min(560px,100%);min-width:0}.library-controls-stacked>label{display:grid;gap:5px;justify-items:start}.library-controls-stacked select{min-width:180px}.history-sort{display:flex;justify-content:flex-start;margin:0 0 16px}.history-sort label{display:grid;gap:5px;color:#b8bec7}.history-sort select{min-width:170px}
.story-filter-tag{appearance:none;background:transparent;border:1px solid #3a3f48;color:#b7bdc8;border-radius:7px;padding:4px 8px;font-size:11px;line-height:1.15;cursor:pointer;box-shadow:none}.story-filter-tag:hover{border-color:#70667f;color:#d9d3e2;background:rgba(139,92,246,.05)}.story-filter-tag.active{background:#2a2038;border-color:#a78bfa;color:#d8c9ff}.explore-tag-strip{display:flex;gap:7px;flex-wrap:wrap;align-items:center;margin:10px 0 20px}.explore-tag-strip .story-filter-tag:not(.active){opacity:.72}.clear-tag-filter{background:transparent;border:0;color:#a99db8;font-size:11px;padding:4px 7px}.public-story-tags{display:flex;gap:5px;flex-wrap:wrap;margin-top:4px}.public-story-tags .story-filter-tag{padding:3px 6px;font-size:10px}.story-tag-row .story-filter-tag{font-size:11px}
.story-section-search{width:min(620px,100%);margin:0 0 12px}.story-other-pool{margin:18px 0 4px;border:1px solid #2c3037;border-radius:10px;background:#101216;overflow:hidden}.story-other-pool>summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 14px;background:#15171b}.story-other-pool>summary::-webkit-details-marker{display:none}.story-other-pool>summary:after{content:'+';color:#8f96a0;margin-left:auto}.story-other-pool[open]>summary:after{content:'−'}.story-other-body{padding:12px}.story-other-body .wide-btn{margin:5px 0}
.ending-editor-image{display:block;width:min(100%,520px);max-height:300px;object-fit:contain;border:1px solid #30343a;border-radius:10px;background:#0c0e11;margin:8px 0 10px}.ending-scene-image{margin:10px 0 14px}.ending-scene-image img{display:block;max-width:min(100%,760px);max-height:70vh;object-fit:contain;border-radius:10px;border:1px solid #34383f;background:#0b0d10;cursor:zoom-in}.ending-final-panel{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin:10px 0;padding:12px 14px;border:1px solid #3b3348;border-radius:10px;background:#17131d}.ending-final-panel b{color:#e8e0ef}
@media(max-width:650px){.library-controls-stacked>input{width:100%}.ending-final-panel{align-items:stretch;flex-direction:column}.ending-final-panel button{width:100%}}

/* V1.14.48 — Nyra's Worlds + Story Preview */
:root{--nw-violet:#a78bfa;--nw-soft:#c4b5fd}body{background:radial-gradient(circle at 65% -20%,#24163a 0,#0b0b14 34%,#08090d 70%);color:#f4f1fa}.app-shell{background:transparent}.app-content{margin-left:0}.main{padding-top:24px}.worlds-header{height:82px;position:sticky;top:0;z-index:50;display:flex;align-items:center;gap:28px;padding:0 26px;border-bottom:1px solid #2b2440;background:#080810f0;backdrop-filter:blur(16px)}.brand-lockup{display:flex;align-items:center;min-width:190px;height:70px;cursor:pointer;user-select:none}.brand-compass{width:43px;font-size:37px;color:#c4b5fd;text-shadow:0 0 16px #8b5cf6;transform:rotate(45deg);margin-right:8px}.brand-words{position:relative;width:125px;height:57px}.brand-words b{position:absolute;left:0;top:5px;font-family:Georgia,serif;font-size:25px;color:#eee9f8}.brand-words i{position:absolute;left:39px;top:27px;font-family:'Segoe Script','Brush Script MT',cursive;font-size:24px;color:#bda3ff;line-height:1;transform:rotate(-3deg)}.worlds-nav{display:flex;justify-content:center;gap:5px;flex:1;height:100%;overflow-x:auto}.worlds-nav .app-nav-btn{width:auto;min-width:max-content;border:0;border-bottom:2px solid transparent;border-radius:0;background:transparent;padding:0 13px;color:#bdb6cc}.worlds-nav .app-nav-btn:hover{background:#a78bfa0b;color:#eee8ff;border-color:#5f4b86}.worlds-nav .app-nav-btn.active{background:#a78bfa0d;color:#d7c7ff;border-color:#a78bfa}.worlds-nav .nav-icon{font-size:19px;color:#9f7aea;width:auto}.primary{background:linear-gradient(135deg,#4b2b72,#6d3fa2);border-color:#9a6de0;color:#fff}.library-controls-stacked{display:grid;justify-items:start;align-items:start;gap:12px;margin-bottom:18px}.library-controls-stacked>input{width:min(560px,100%);min-width:0}.library-controls-stacked>label{display:grid;gap:7px;justify-items:start;margin:0}.library-controls-stacked select{min-width:220px}.preview-visible-toggle{margin:12px 0 8px;padding:9px 10px;border:1px solid #2f2a3c;border-radius:9px;background:#0d0d16}.preview-visible-toggle>span:first-child{display:grid;gap:2px}.story-detail-page{max-width:1450px;margin:0 auto;padding:4px 8px 30px}.preview-back{border:0;background:transparent;color:#b899ff;padding:8px 4px;margin-bottom:8px}.story-detail-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(320px,.92fr);gap:22px}.story-detail-main,.featured-characters{background:linear-gradient(180deg,#0e0e18,#0a0a12);border:1px solid #2d2940;border-radius:16px;padding:18px;box-shadow:0 18px 45px #0005}.story-hero-frame{display:block;width:100%;height:clamp(320px,48vw,570px);overflow:hidden;border-radius:13px;border:1px solid #373047;background:#0b0b12}.story-hero{width:100%;height:100%;object-fit:cover;display:block}.story-detail-main h1{font-family:Georgia,serif;color:#c4a7ff;font-size:34px;margin:18px 2px 8px}.story-detail-description{color:#c5c0d0;font-size:16px;line-height:1.6;margin:0 2px 13px}.story-detail-tags{display:flex;gap:8px;flex-wrap:wrap;margin:10px 2px 20px}.story-facts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));border-top:1px solid #312a42;padding-top:17px}.story-facts>div{display:grid;grid-template-columns:32px 1fr;grid-template-rows:auto auto;column-gap:8px;padding:4px 14px;border-right:1px solid #282333}.story-facts>div:last-child{border-right:0}.fact-icon{grid-row:1/3;font-size:24px;color:#a987e8;align-self:center}.story-facts small{color:#8f83a8;font-size:10px}.story-facts b{font-size:14px;color:#ded7e9}.featured-characters{align-self:start;position:sticky;top:104px}.featured-characters>h2{font-family:Georgia,serif;color:#b68df2;text-align:center;font-size:17px}.featured-character-card{width:100%;display:grid;grid-template-columns:88px 1fr 20px;align-items:center;gap:12px;text-align:left;background:#11111d;border:1px solid #302a42;border-radius:11px;padding:7px;margin:0 0 9px;color:#eee}.featured-character-thumb-frame{display:block;width:88px;height:88px;overflow:hidden;border-radius:8px}.featured-character-thumb{width:100%;height:100%;object-fit:cover}.featured-character-card>span:nth-child(2){display:grid;gap:5px}.featured-character-card b{font-family:Georgia,serif;color:#b78ef4;font-size:16px}.featured-character-card small{color:#aaa3b8;line-height:1.35}.character-chevron{font-size:27px;color:#8f78b6}.story-preview-actions{display:grid;grid-template-columns:.7fr 1.5fr;gap:10px;margin-top:18px;padding-top:14px;border-top:1px solid #2d2940}.story-preview-actions button{min-height:48px}.preview-character-large-frame{display:block;width:220px;height:220px;margin:0 auto 16px;border-radius:13px;overflow:hidden}.preview-character-large{width:100%;height:100%;object-fit:cover}.preview-character-modal p{line-height:1.6;color:#c7c1d0}@media(max-width:1050px){.story-detail-grid{grid-template-columns:1fr}.featured-characters{position:static}.story-facts{grid-template-columns:repeat(2,1fr)}}@media(max-width:700px){.worlds-header{height:auto;flex-direction:column;align-items:flex-start;padding:7px 10px 0}.brand-lockup{height:56px}.worlds-nav{width:100%;height:48px;justify-content:flex-start}.worlds-nav .app-nav-btn{height:48px}.story-hero-frame{height:300px}.featured-character-card{grid-template-columns:68px 1fr 16px}.featured-character-thumb-frame{width:68px;height:68px}}

/* V1.14.48.1 — Nyra's Worlds visual correction pass */
:root{
  --nw-bg:#080811;
  --nw-bg-2:#0c0b16;
  --nw-panel:#10101b;
  --nw-panel-2:#141321;
  --nw-panel-soft:#171522;
  --nw-border:#302946;
  --nw-border-soft:#262139;
  --nw-violet:#a978f2;
  --nw-violet-bright:#c7a7ff;
  --nw-lavender:#ded0ff;
  --nw-text:#f3eefb;
  --nw-muted:#aaa1bb;
}
body{
  background:
    radial-gradient(circle at 63% -18%,rgba(95,51,142,.30) 0,rgba(31,20,51,.18) 27%,transparent 46%),
    linear-gradient(180deg,#090914 0%,#080810 45%,#07070d 100%);
  color:var(--nw-text);
}
.worlds-header{
  background:linear-gradient(180deg,rgba(10,9,18,.98),rgba(8,8,15,.96));
  border-bottom:1px solid #33294b;
  box-shadow:0 9px 30px rgba(0,0,0,.24);
}
.brand-lockup{min-width:205px}
.brand-compass{width:47px;height:47px;display:grid;place-items:center;margin-right:9px;transform:none;font-size:0;filter:drop-shadow(0 0 9px rgba(153,100,235,.45))}
.compass-svg{width:45px;height:45px;overflow:visible}
.compass-long{fill:rgba(124,84,184,.22);stroke:#d7c2ff;stroke-width:1.55;stroke-linejoin:round}
.compass-short{fill:rgba(35,20,56,.92);stroke:#9f70e3;stroke-width:1.15;stroke-linejoin:round;transform:rotate(45deg);transform-origin:32px 32px}
.brand-words{width:137px;height:58px}
.brand-words b{font-size:25px;letter-spacing:.2px;text-shadow:0 1px 12px rgba(0,0,0,.7)}
.brand-words i{left:43px;top:27px;font-size:25px;color:#c09aff;text-shadow:0 0 12px rgba(152,95,235,.22)}
.worlds-nav{gap:8px}
.worlds-nav .app-nav-btn{color:#d1c9dc;padding:0 14px;gap:9px;transition:background .16s ease,color .16s ease,border-color .16s ease}
.worlds-nav .app-nav-btn:hover{background:linear-gradient(180deg,rgba(161,110,235,.07),rgba(105,64,158,.04));border-color:#6e518f;color:#f2ebff}
.worlds-nav .app-nav-btn.active{background:linear-gradient(180deg,rgba(168,116,237,.11),rgba(89,54,133,.06));border-color:#bd8cff;color:#f2ebff;box-shadow:inset 0 -6px 16px rgba(150,91,232,.06)}
.worlds-nav .nav-icon{width:22px;height:22px;display:grid;place-items:center;color:#aa7ce9}
.nav-svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;overflow:visible}
.worlds-nav .app-nav-btn.active .nav-icon{color:#c296ff;filter:drop-shadow(0 0 6px rgba(167,120,242,.42))}

/* Make the entire creator/home shell use the preview's layered violet/navy surface language. */
.card,.panel,.subcard,.mini-card,.history-card,.library-story-card,.library-story-group,.story-other-pool{
  background:linear-gradient(180deg,var(--nw-panel-2),var(--nw-panel));
  border-color:var(--nw-border);
  box-shadow:0 10px 28px rgba(0,0,0,.18);
}
.card:hover,.library-story-card:hover{border-color:#55446f}
.story-card{background:linear-gradient(180deg,#171522 0%,#12111d 100%);border:1px solid #332c47}
.story-card .story-cover-frame{border-color:#3b3150;background:#0b0a12;box-shadow:0 8px 24px rgba(0,0,0,.32)}
.story-card h3{color:#f4effa}
.story-card p{color:#c1b8ca}
.featured-story{
  border-color:#352d49;
  background:linear-gradient(135deg,#151322 0%,#0e0d18 55%,#0b0b13 100%);
  box-shadow:0 18px 44px rgba(0,0,0,.25),inset 0 1px rgba(255,255,255,.015);
}
.featured-copy h1,.library-section-head h2,.section-head h1,.section-head h2{color:#f1ebf8}
.featured-copy p{color:#bcb3c8}
.eyebrow{color:#b187ef}
.library-story-card{border-color:#302944}
.library-story-info>b{color:#eee8f7}
.library-story-info span,.library-story-info small{color:#9f97ad}
.library-cover-frame{background:#0b0b13}
.history-card{border-color:#302944}
.empty-row,.empty{border-color:#443855;color:#9f96ad;background:rgba(14,13,23,.45)}
.placeholder{color:#876eaa;background:linear-gradient(135deg,#171421,#0d0c15)}
.library-story-group>summary,.story-other-pool>summary{background:linear-gradient(180deg,#191725,#14131f);color:#eee8f7}

/* Inputs and controls should live in the same darker violet surfaces instead of neutral charcoal. */
button,input,textarea,select{background:#171621;color:#f2edf8;border-color:#393148}
button:hover{border-color:#58496e}
input:focus,textarea:focus,select:focus{outline:none;border-color:#8d68c5;box-shadow:0 0 0 2px rgba(167,120,242,.10)}
.primary{background:linear-gradient(135deg,#60378e,#7d49b3);border-color:#a876ea;box-shadow:0 6px 18px rgba(91,45,138,.22)}
.primary:hover{background:linear-gradient(135deg,#6b3e9c,#8b54c1);border-color:#c092ff}
.story-filter-tag{border-color:#4a405c;color:#c7bdd5;background:rgba(9,8,15,.22)}
.story-filter-tag:hover{border-color:#8061a7;color:#e4d7f6;background:rgba(126,75,184,.09)}
.story-filter-tag.active{background:#291d3b;border-color:#b77cff;color:#eadcff;box-shadow:0 0 0 1px rgba(183,124,255,.08) inset}

/* Preview already had the correct structure; deepen its surfaces to match the approved mockup. */
.story-detail-main,.featured-characters{background:linear-gradient(180deg,#11101d,#0b0b14);border-color:#342b49;box-shadow:0 18px 48px rgba(0,0,0,.34)}
.featured-character-card{background:linear-gradient(180deg,#151321,#10101a);border-color:#342b49}
.featured-character-card:hover{border-color:#5d4779;background:linear-gradient(180deg,#181526,#11101c)}
.story-hero-frame{border-color:#413454;background:#080810;box-shadow:0 12px 32px rgba(0,0,0,.28)}
.story-detail-main h1{color:#c7a5ff}
.story-detail-description{color:#c7bfd1}
.story-facts{border-color:#362b4a}
.story-facts>div{border-color:#2b233b}
.fact-icon{color:#b98df7}
.featured-characters>h2,.featured-character-card b{color:#c196ff}
.preview-back{color:#c69dff}
.story-preview-actions{border-color:#332a47}

/* Make My Stories cards feel less like black slabs behind their artwork. */
.cards{gap:16px}
.cards>.card{background:linear-gradient(180deg,#171522,#11101a);border-color:#332c47}
.cards>.card:last-child{background:linear-gradient(180deg,#14131d,#0f0e17)}

/* Keep the compact brand readable on smaller screens without making it huge. */
@media(max-width:900px){.brand-lockup{min-width:185px}.brand-compass{width:40px;height:40px}.compass-svg{width:39px;height:39px}.brand-words{width:125px}.brand-words b{font-size:23px}.brand-words i{font-size:23px;left:39px}}


/* V1.14.48.2 — clean preview rebuild from V1.14.48.1 */
/* The story cover must always be shown whole. The existing preview panel itself supplies
   any unused space: no crop, no nested frame, and no second border. */
.story-hero-frame{
  display:flex;
  width:100%;
  height:clamp(320px,48vw,570px);
  align-items:center;
  justify-content:center;
  overflow:hidden;
  border:0 !important;
  border-radius:13px;
  background:transparent !important;
  box-shadow:none !important;
}
.story-hero{
  width:100%;
  height:100%;
  object-fit:contain !important;
  object-position:center center !important;
  transform:none !important;
  transform-origin:center center !important;
  display:block;
}

/* Opening text is part of the storefront, not a dropdown. */
.opening-preview-panel{
  margin-top:14px;
  border-top:1px solid #332a47;
  padding-top:14px;
}
.opening-preview-head{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:10px;
}
.opening-preview-head h3{
  margin:0;
  font-family:Georgia,serif;
  color:#c4a7ff;
  font-size:17px;
}
.opening-preview-head small{color:#8f83a8}
.opening-preview-icon{color:#ad84ec;font-size:20px}
.opening-preview-body{
  max-height:360px;
  overflow-y:auto;
  padding:12px 13px;
  border:1px solid #302a42;
  border-radius:11px;
  background:#11111d;
  color:#d9d3e4;
  line-height:1.55;
  scrollbar-width:thin;
}
.opening-preview-body p:first-child{margin-top:0}
.opening-preview-body p:last-child{margin-bottom:0}

.story-tag-draggable{cursor:grab;user-select:none}.story-tag-draggable.dragging{opacity:.45}.story-tag-draggable button{cursor:pointer}

.save-state-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;align-items:center}.save-state-row .wide-btn{margin:0}.save-delete-x{min-width:34px;height:34px;padding:0;font-size:18px}

/* V2.0.0 reading-size adjustment for playthrough story/player messages only. */
.msg.assistant,.msg.user{font-size:15.5px}

/* Smooth waterfall treatment for live story streaming only. */
#streamMsg.streaming .stream-waterfall-body{white-space:normal}
#streamMsg.streaming .stream-waterfall-word{opacity:1;color:inherit}
#streamMsg.streaming .stream-waterfall-word:last-child{filter:none}


/* V2.0.28 — Purchasable Stats + Authored New Skills */
.disabled-section{opacity:.55}.disabled-section input:disabled,.disabled-section select:disabled{cursor:not-allowed}
.compact-toggle{display:inline-flex;align-items:center;gap:8px;font-size:12px;font-weight:700;white-space:nowrap}
.field-label-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.field-label-row>label:first-child{margin:0}
.skill-list-heading{align-items:flex-end;gap:12px}.skill-list-tools{display:flex;gap:8px;align-items:center;margin-left:auto;flex-wrap:wrap;justify-content:flex-end}.skill-list-tools input{width:190px}.skill-list-tools select{width:auto;min-width:125px}
.purchase-config{border:1px solid rgba(139,92,246,.28);background:rgba(139,92,246,.06);border-radius:12px;padding:12px;margin:10px 0 16px}.purchase-tier-row{display:grid;grid-template-columns:1fr 1fr 1fr auto;gap:8px;align-items:end;margin:8px 0}.purchase-tier-row .danger{height:38px;min-width:38px;padding:0}
.warn{color:#f59e0b}.stat-value-actions{display:flex;align-items:center;gap:8px}.stat-plus,.stat-max{min-width:32px;height:28px;padding:0 8px;border-radius:8px;font-weight:900}.stat-plus.disabled,.stat-max.disabled{opacity:.45;pointer-events:none}.stat-purchase-meta{display:flex;justify-content:space-between;gap:8px;margin-top:6px;font-size:11px;color:var(--muted)}
.new-skills-intro{margin:0 0 12px;color:var(--muted);font-size:12px}.pool-stat-group{border:1px solid var(--line);border-radius:12px;margin:10px 0;overflow:hidden}.pool-stat-group>summary{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:12px 14px;cursor:pointer;background:rgba(255,255,255,.025)}.pool-stat-body{padding:12px}.pool-section-title{font-weight:800;font-size:12px;text-transform:uppercase;letter-spacing:.04em;margin:10px 0 7px;color:var(--muted)}.pool-skill{display:flex;align-items:center;gap:10px;margin-bottom:8px}.pool-skill .skill-info{flex:1;text-align:left}.pool-skill small{display:block;color:var(--muted);margin-top:3px}.pool-lock{padding:0 10px;opacity:.6}.milestone-notice-row{padding:10px 0;border-bottom:1px solid var(--line)}.milestone-notice-row:last-child{border-bottom:0}
@media(max-width:900px){.skill-list-heading{align-items:stretch;flex-direction:column}.skill-list-tools{margin-left:0;justify-content:flex-start}.purchase-tier-row{grid-template-columns:1fr 1fr}.purchase-tier-row .danger{grid-column:2}.stat-purchase-meta{flex-direction:column}}

/* V2.0.29.3 — Class Starting Skill Picker */
.class-skill-picker-modal{width:min(980px,95vw);max-height:86vh;overflow:hidden;display:flex;flex-direction:column}
.class-skill-picker-modal .skill-list-tools{margin-bottom:10px}
.class-skill-picker-modal .skill-list-tools input{width:100%}
#classSkillPickerBody{min-height:0;overflow-y:auto;padding-right:6px;scrollbar-gutter:stable}
.class-skill-picker-count{padding:2px 0 8px}
.class-skill-picker-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;padding-bottom:6px}
.class-skill-picker-card{display:flex;flex-direction:column;gap:8px;min-height:170px;border:1px solid #30343a;border-radius:11px;background:#101216;padding:11px}
.class-skill-picker-card.selected{border-color:#8b5cf6;box-shadow:inset 0 0 0 1px #8b5cf655}
.class-skill-picker-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}
.class-skill-picker-head span{font-size:11px;color:#aeb4bd;white-space:nowrap}
.class-skill-picker-desc{color:#d7d9dd;line-height:1.35;flex:1}
.class-skill-picker-card button{align-self:flex-start;margin-top:auto}
@media(max-width:720px){.class-skill-picker-grid{grid-template-columns:1fr}}
/* V2.0.29.4 content-management tools */
.skill-book-controls{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin:10px 0 8px}
.skill-book-tabs{display:flex;gap:6px;flex-wrap:wrap}
.skill-book-tabs button.active{background:#6d4bd8;border-color:#8b6cf0;color:#fff}
.bulk-skill-toolbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:8px 0 12px}
.bulk-check{display:inline-flex;align-items:center;margin-right:8px}
.bulk-check input{width:auto;margin:0}
.skill-book-item summary{display:flex;align-items:center;gap:8px}
.skill-book-item summary .tiny{margin-left:auto;margin-right:8px}
@media(max-width:720px){.skill-book-controls{align-items:stretch;flex-direction:column}.skill-book-controls .skill-list-tools{margin-left:0}.skill-book-item summary .tiny{display:none}}

.play-response-length{margin:10px 0;padding:10px;border:1px solid #2f333a;border-radius:9px;background:#111318;display:grid;gap:7px}.play-response-length select{width:100%;min-height:38px}

.help-dot{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;border-radius:50%;padding:0;margin-left:4px;font-size:12px;line-height:1;vertical-align:middle}

.skill-page-tabs{display:flex;flex-wrap:wrap;gap:8px;margin:10px 0 14px}
.skill-page-tabs button{min-width:38px;padding:7px 11px}
.skill-page-tabs button.selected{font-weight:700}

/* V2.0.29.8.5.21 — UI-only Location Ambience */
.play{position:relative;isolation:isolate}
.location-ambience-bg,.location-ambience-shade{position:fixed;inset:0;pointer-events:none}
.location-ambience-bg{z-index:-2;background-position:center center;background-size:cover;background-repeat:no-repeat;filter:saturate(.9);animation:nwAmbienceIn .45s ease-out}
.location-ambience-shade{z-index:-1;background:rgba(4,4,10,.66)}
.play>.panel{position:relative;z-index:0}
@keyframes nwAmbienceIn{from{opacity:0}to{opacity:1}}
@media (max-width:1100px){.location-ambience-bg,.location-ambience-shade{display:none}}

/* V2.0.29.8.5.24 — persistent, flicker-free Location Ambience */
html.nw-has-location-ambience body::before,
html.nw-has-location-ambience body::after{content:"";position:fixed;inset:0;pointer-events:none}
html.nw-has-location-ambience body::before{z-index:-2;background-image:var(--nw-location-ambience);background-position:center center;background-size:cover;background-repeat:no-repeat;filter:saturate(.9)}
html.nw-has-location-ambience body::after{z-index:-1;background:rgba(4,4,10,.66)}
body{position:relative;z-index:0}
@media (max-width:1100px){
  html.nw-has-location-ambience body::before,
  html.nw-has-location-ambience body::after{display:none}
}

/* V2.0.29.8.5.28.1 — Player-facing permanent-death status */
.character-dead{filter:grayscale(.72);opacity:.68}.character-dead:hover{opacity:.78}.death-badge{display:inline-flex;align-items:center;gap:4px;width:max-content;margin-top:3px;padding:2px 7px;border:1px solid #7a5555;border-radius:999px;background:#211719;color:#d9b8b8;font-size:10px;font-weight:800;letter-spacing:.08em;line-height:1.35;text-transform:uppercase}.collection-state.death-badge{margin-top:0;white-space:nowrap}.character-dead .panel-thumb-frame,.character-dead .collection-thumb-frame{filter:grayscale(1);opacity:.72}

/* 8.5.29.1 Map Workspace Rebuild */
.map-builder-mode{display:block!important}.map-builder-mode .builder-left{width:100%!important;max-width:none!important}.map-workspace-panel{padding:0!important;overflow:hidden}.map-save-row{margin-bottom:0}
.map-shell{display:flex;flex-direction:column;height:min(72vh,820px);min-height:500px}
.map-topbar{display:flex;align-items:center;gap:7px;padding:8px;flex:0 0 auto;overflow-x:auto;white-space:nowrap;border-bottom:1px solid rgba(255,255,255,.08)}
.map-enable{display:flex;align-items:center;gap:5px}.map-tabs-strip{display:flex;gap:4px;flex:1;min-width:100px;overflow-x:auto}.map-tabs-strip button.active{background:rgba(130,88,190,.55);border-color:rgba(205,180,255,.65)}
.map-more{font-size:18px}.map-zoom-label{min-width:42px;text-align:center;font-size:11px}.map-hint{font-size:11px;opacity:.62;padding:5px 9px;flex:0 0 auto}
.map-viewport{position:relative;flex:1;min-height:0;overflow:hidden;touch-action:none;background-color:rgba(18,14,27,.82);background-image:radial-gradient(rgba(220,205,255,.12) 1px,transparent 1px);background-size:22px 22px;cursor:grab}
.map-viewport:active{cursor:grabbing}.map-world{position:absolute;left:0;top:0;width:4000px;height:4000px;transform-origin:0 0;will-change:transform}
.map-lines{position:absolute;inset:0;width:4000px;height:4000px;pointer-events:none}.map-lines line{stroke:rgba(191,158,246,.68);stroke-width:3;stroke-linecap:round}
.map-card{position:absolute;width:190px;min-height:90px;padding:12px;border:1px solid rgba(181,145,235,.62);border-radius:12px;background:rgba(37,28,52,.98);box-shadow:0 6px 20px rgba(0,0,0,.3);user-select:none;touch-action:none;cursor:grab}
.map-card:active{cursor:grabbing}.map-card-name{text-align:center;font-weight:750;margin-bottom:9px}.map-card-actions{text-align:center}.map-card-actions button{font-size:11px;padding:5px 8px}
.map-edge-label{font-size:9px;opacity:.68;margin-top:4px;text-align:center}.map-empty{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:9px;pointer-events:none}.map-empty button{pointer-events:auto}.map-empty span{font-size:12px;opacity:.6}
@media(max-width:700px){.map-shell{height:calc(100dvh - 205px);min-height:420px}.map-topbar{padding:5px}.map-hint{display:none}.map-tabs-strip{max-width:42vw}.map-card{width:155px;min-height:76px;padding:9px}.map-card-name{font-size:13px}.map-save-row{display:flex;gap:6px}.map-builder-mode .tabs{overflow-x:auto;white-space:nowrap;flex-wrap:nowrap}}

/* 8.5.29.2 Map multi-route + containment */
.map-card{overflow:visible}.map-port{position:absolute;width:25px;height:25px;padding:0!important;border-radius:7px;font-size:10px;font-weight:800;z-index:4}
.map-port-n{top:-13px;left:calc(50% - 12px)}.map-port-s{bottom:-13px;left:calc(50% - 12px)}.map-port-e{right:-13px;top:calc(50% - 12px)}.map-port-w{left:-13px;top:calc(50% - 12px)}
.map-inside-btn{font-size:10px!important}.map-connect-source{outline:2px solid rgba(221,200,255,.95)!important;box-shadow:0 0 0 4px rgba(155,105,230,.2)!important}
.map-connect-status{position:absolute;left:50%;bottom:14px;transform:translateX(-50%);padding:7px 12px;border-radius:999px;background:rgba(31,23,45,.94);border:1px solid rgba(190,155,240,.7);font-size:11px;pointer-events:none;z-index:10}
.map-parent-label,.map-child-count{font-size:9px;text-align:center;opacity:.62;margin-top:4px}.map-contain-line{stroke:rgba(220,220,230,.55)!important;stroke-width:2!important;stroke-dasharray:7 7}.map-route-line{stroke-width:3!important}

/* 8.5.29.3 Direct cardinal drag wiring */
.map-port{cursor:crosshair}
.map-port.map-route-source{transform:scale(1.18);box-shadow:0 0 0 3px rgba(205,180,255,.28);border-color:rgba(235,225,255,.95)}
.map-port.map-route-target{transform:scale(1.22);box-shadow:0 0 0 4px rgba(126,231,135,.28);border-color:rgba(126,231,135,.95)}
.map-route-preview{stroke:rgba(235,225,255,.9)!important;stroke-width:3!important;stroke-dasharray:7 6;pointer-events:none}

/* 8.5.29.4 Map direct controls + compact context menu */
.map-port.map-port-closed{
  color:#ff6b6b;
  border-color:rgba(255,107,107,.72);
  background:rgba(105,25,35,.42);
  font-weight:900;
  cursor:pointer;
}
.map-port.map-port-closed:hover{border-color:#ff7b7b;background:rgba(125,30,42,.58)}
.map-node-menu{
  position:fixed;
  z-index:100000;
  width:min(260px,calc(100vw - 16px));
  padding:8px;
  border:1px solid rgba(180,160,220,.35);
  border-radius:12px;
  background:#171323;
  box-shadow:0 12px 36px rgba(0,0,0,.42);
  color:#f3efff;
}
.map-node-menu-group{padding:5px 4px 8px}
.map-node-menu-label{font-size:12px;color:#aaa2bb;margin:0 0 6px 2px}
.map-node-dir-row{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.map-node-dir-row button,.map-node-menu-item{
  min-height:40px;
  border:1px solid rgba(180,160,220,.28);
  border-radius:9px;
  background:#211a31;
  color:#f3efff;
  cursor:pointer;
}
.map-node-dir-row button:hover,.map-node-menu-item:hover{background:#2b2140}
.map-node-dir-row button:disabled{opacity:.28;cursor:default}
.map-node-menu-item{display:block;width:100%;text-align:left;padding:9px 11px;margin-top:5px}
.map-node-menu-sep{height:1px;background:rgba(180,160,220,.18);margin:7px 2px}
.map-node-menu-item.danger{color:#ff8a8a}
@media(max-width:600px){
  .map-node-menu{width:min(300px,calc(100vw - 16px));padding:9px}
  .map-node-dir-row button,.map-node-menu-item{min-height:44px}
}

/* 8.5.29.5 Map UX completion pass */
.map-viewport{touch-action:none;overscroll-behavior:contain}
.map-add-wrap{position:relative}
.map-location-picker{
  position:fixed;z-index:100000;width:min(330px,calc(100vw - 16px));padding:8px;
  border:1px solid rgba(180,160,220,.35);border-radius:12px;background:#171323;
  box-shadow:0 12px 36px rgba(0,0,0,.42);color:#f3efff
}
.map-location-search{
  width:100%;min-height:42px;padding:9px 11px;border-radius:9px;border:1px solid rgba(180,160,220,.3);
  background:#211a31;color:#f3efff;font-size:16px;outline:none
}
.map-location-search:focus{border-color:rgba(188,160,255,.8)}
.map-location-results{display:flex;flex-direction:column;gap:4px;max-height:320px;overflow:auto;margin-top:7px}
.map-location-result{
  min-height:42px;padding:9px 11px;border:0;border-radius:8px;background:transparent;color:#f3efff;
  text-align:left;cursor:pointer
}
.map-location-result:hover,.map-location-result:focus{background:#2b2140}
.map-location-none{padding:12px;color:#aaa2bb;font-size:13px}
.map-tab-wrap{display:inline-flex;align-items:center}
.map-tab-wrap .map-tab-edit{min-width:28px;padding:5px 7px;margin-left:-3px}
.map-tab-rename{
  min-width:100px;max-width:180px;padding:6px 8px;border-radius:8px;border:1px solid rgba(188,160,255,.72);
  background:#211a31;color:#f3efff;font-size:14px
}
.map-portal-btn.connected{border-color:rgba(101,216,255,.65);color:#9de8ff}
.portal-menu small,.portal-current small{display:block;margin-top:3px;color:#aaa2bb;font-size:11px}
.portal-current{padding:8px 9px}
.map-portal-toast{
  position:fixed;left:50%;bottom:18px;transform:translateX(-50%);z-index:100001;max-width:min(520px,calc(100vw - 24px));
  padding:10px 14px;border-radius:10px;background:#211a31;color:#f3efff;border:1px solid rgba(188,160,255,.4);
  box-shadow:0 8px 28px rgba(0,0,0,.35);font-size:13px
}
@media(max-width:600px){
  .map-location-picker{width:calc(100vw - 16px)}
  .map-location-result{min-height:46px}
  .map-card-actions{gap:4px;flex-wrap:wrap}
}

/* 8.5.29.6 Portal gate controls */
.portal-field{display:block;padding:6px 7px}
.portal-field>span{display:block;font-size:11px;color:#aaa2bb;margin:0 0 5px 2px}
.portal-field select{width:100%;min-height:40px;border:1px solid rgba(180,160,220,.3);border-radius:8px;background:#211a31;color:#f3efff;padding:7px 9px;font-size:14px}
.portal-gate-summary{padding:5px 9px 8px;color:#aaa2bb;font-size:11px;line-height:1.35}


/* 8.5.29.10 — Map Character Geography */
.map-character-count{display:block;margin:7px auto 0!important;padding:3px 8px!important;font-size:10px!important;opacity:.9}
.map-card.map-character-drop{outline:2px solid rgba(126,231,135,.95);box-shadow:0 0 0 4px rgba(126,231,135,.16),0 6px 20px rgba(0,0,0,.3)}
.map-character-panel{position:fixed;z-index:10030;width:min(380px,calc(100vw - 16px));max-height:min(70vh,560px);overflow:auto;padding:12px;border:1px solid rgba(181,145,235,.55);border-radius:12px;background:rgba(28,21,40,.99);box-shadow:0 14px 45px rgba(0,0,0,.55)}
.map-character-panel-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:7px}.map-character-panel-head button{padding:3px 8px}
.map-character-panel>input{width:100%;margin:9px 0}.map-character-list{display:flex;flex-direction:column;gap:6px;margin:7px 0}
.map-character-row,.map-character-drag{display:flex;align-items:center;gap:9px;padding:8px;border:1px solid rgba(255,255,255,.09);border-radius:9px;background:rgba(255,255,255,.035)}
.map-character-row>span,.map-character-drag>span{display:flex;flex:1;min-width:0;flex-direction:column;gap:2px}.map-character-row small,.map-character-drag small{font-size:10px;opacity:.7}.map-character-row.disabled{opacity:.48}.map-character-drag[draggable=true]{cursor:grab}.map-character-drag[draggable=true]:active{cursor:grabbing}.map-character-drag button{margin-left:auto}
@media(max-width:700px){.map-character-panel{left:8px!important;right:8px!important;width:auto;max-height:72vh}.map-character-count{font-size:9px!important}}

/* V2.0.29.8.5.29.15 — Corrected Infinity Door mark: separate sharp serif I + D, violet brand, gold light only */
.id-brand-lockup{min-width:235px;gap:9px}.id-header-logo{width:58px;height:48px;flex:0 0 58px;overflow:visible}.id-logo{overflow:visible}.id-logo .id-letter-fill{fill:url(#idViolet);filter:url(#idGlow)}.id-logo .id-d-fill{filter:url(#idGlow)}.id-logo .id-seam{fill:none;stroke:#130b1d;stroke-width:1.8;opacity:.92}.id-logo .id-door-frame{fill:none;stroke:#c59cff;stroke-width:1.9;stroke-linecap:square;filter:url(#idGlow)}.id-logo .id-door{fill:url(#idDoorViolet);stroke:#a855f7;stroke-width:1.8;stroke-linejoin:miter;transform-box:fill-box;transform-origin:left center;filter:url(#idGlow)}.id-logo .id-knob{fill:#d8c3ff;filter:url(#idGlow)}.id-brand-name{display:grid;gap:2px;white-space:nowrap}.id-brand-name b{font-family:Georgia,"Times New Roman",serif;font-size:17px;letter-spacing:.5px;color:#eee9f8}.id-brand-name small{font-size:9px;letter-spacing:.8px;color:#a78bfa;text-transform:uppercase}
.id-splash{position:fixed;inset:0;z-index:100000;background:#05050a;display:grid;place-items:center;overflow:hidden;cursor:pointer;opacity:1;transition:opacity .8s ease}.id-splash-stage{position:relative;width:min(34vw,430px);min-width:230px;aspect-ratio:1.48;display:grid;place-items:center;perspective:900px}.id-splash-logo{position:relative;z-index:4;width:100%;height:100%;overflow:visible}.id-splash-logo .id-i{clip-path:inset(100% 0 0 0);animation:idRevealI .72s cubic-bezier(.4,0,.2,1) .2s forwards}.id-splash-logo .id-d{clip-path:inset(0 100% 0 0);animation:idRevealD 1.15s cubic-bezier(.45,0,.18,1) .78s forwards}.id-splash-logo .id-seam{opacity:0;animation:idSeam .18s ease 1.88s forwards}.id-splash-logo .id-door-frame{stroke-dasharray:72;stroke-dashoffset:72;animation:idDrawDoor .42s ease 1.78s forwards}.id-splash-logo .id-door{opacity:0;animation:idDoorReveal .22s ease 2.08s forwards,idDoorOpen 1.15s cubic-bezier(.2,.75,.2,1) 2.48s forwards}.id-splash-logo .id-knob{opacity:0;animation:idKnob .2s ease 2.2s forwards}.id-light-beam{position:absolute;z-index:2;left:39%;top:20%;width:15%;height:61%;opacity:0;transform-origin:left center;clip-path:polygon(0 5%,100% 0,100% 100%,0 95%);background:linear-gradient(90deg,#fff9d9e8,#f4d36c7d 38%,transparent);filter:blur(5px);animation:idBeam 1.3s ease 2.58s forwards}.id-light-bloom{position:absolute;z-index:1;width:10%;aspect-ratio:1;border-radius:50%;opacity:0;background:#fff5bd;box-shadow:0 0 60px 25px #f3ce68,0 0 180px 90px #c9993655;animation:idBloom 1.2s ease 3.02s forwards}.id-splash.leaving{opacity:0;pointer-events:none}.id-splash.leaving .id-light-bloom{transform:scale(24);opacity:1}
@keyframes idRevealI{to{clip-path:inset(0 0 0 0)}}@keyframes idRevealD{to{clip-path:inset(0 0 0 0)}}@keyframes idSeam{to{opacity:.92}}@keyframes idDrawDoor{to{stroke-dashoffset:0}}@keyframes idDoorReveal{to{opacity:1}}@keyframes idKnob{to{opacity:1}}@keyframes idDoorOpen{0%{transform:perspective(600px) rotateY(0deg)}100%{transform:perspective(600px) rotateY(-72deg)}}@keyframes idBeam{0%{opacity:0;transform:scaleX(.08)}45%{opacity:.78}100%{opacity:.95;transform:scaleX(3.2)}}@keyframes idBloom{0%{opacity:0;transform:scale(.2)}55%{opacity:.55}100%{opacity:.95;transform:scale(9)}}
@media(max-width:700px){.id-brand-lockup{min-width:185px}.id-header-logo{width:49px;height:40px}.id-brand-name b{font-size:15px}.id-brand-name small{font-size:7px}.id-splash-stage{width:min(58vw,330px)}}
@media(prefers-reduced-motion:reduce){.id-splash-logo .id-i,.id-splash-logo .id-d,.id-splash-logo .id-seam,.id-splash-logo .id-door-frame,.id-splash-logo .id-door,.id-splash-logo .id-knob,.id-light-beam,.id-light-bloom{animation-duration:.01ms!important;animation-delay:.01ms!important}.id-splash{transition-duration:.15s}}


/* V2.0.29.8.5.29.16 — Opener-only rebuild: crisp separate serif I + D; gold appears only beyond the door. */
.id-splash-stage-v2{width:min(35vw,440px);min-width:240px;aspect-ratio:4/3;perspective:1100px}
.id-opener-svg{position:relative;z-index:5;width:100%;height:100%;overflow:visible}
.id-opener-svg .opener-stroke{fill:none;stroke:#a978f4;stroke-width:3;stroke-linecap:square;stroke-linejoin:miter;filter:url(#openerVioletGlow);stroke-dasharray:100;stroke-dashoffset:100}
.id-opener-svg .opener-fill{fill:url(#openerVioletFill);opacity:0;filter:url(#openerVioletGlow)}
.id-opener-svg .opener-i-stroke{animation:openerDrawI .72s cubic-bezier(.45,0,.2,1) .18s forwards}
.id-opener-svg .opener-i-fill{animation:openerFillIn .16s ease .82s forwards}
.id-opener-svg .opener-d-stroke{animation:openerDrawD 1.12s cubic-bezier(.45,0,.18,1) .78s forwards}
.id-opener-svg .opener-d-fill{animation:openerFillIn .18s ease 1.82s forwards}
.id-opener-svg .opener-frame-stroke{fill:none;stroke:#bb8cf8;stroke-width:2.2;stroke-linecap:square;stroke-dasharray:100;stroke-dashoffset:100;filter:url(#openerVioletGlow);animation:openerFrame .34s ease 1.90s forwards}
.id-opener-svg .opener-door-group{transform-box:fill-box;transform-origin:left center}
.id-opener-svg .opener-door{fill:url(#openerDoorFill);stroke:#8d4bd6;stroke-width:2;stroke-linejoin:miter;opacity:0;filter:url(#openerVioletGlow);animation:openerDoorAppear .18s ease 2.10s forwards,openerDoorSwing 1.08s cubic-bezier(.18,.78,.18,1) 2.48s forwards}
.id-opener-svg .opener-door-panel{fill:none;stroke:#7740b5;stroke-width:1.2;opacity:0;animation:openerDoorAppear .18s ease 2.12s forwards,openerDoorSwing 1.08s cubic-bezier(.18,.78,.18,1) 2.48s forwards;transform-box:fill-box;transform-origin:left center}
.id-opener-svg .opener-knob{fill:#d8c3ff;opacity:0;filter:url(#openerVioletGlow);animation:openerDoorAppear .18s ease 2.18s forwards,openerDoorSwing 1.08s cubic-bezier(.18,.78,.18,1) 2.48s forwards;transform-box:fill-box;transform-origin:left center}
.id-gold-slit{position:absolute;z-index:3;left:45.2%;top:25%;width:1.2%;height:50%;opacity:0;background:linear-gradient(180deg,#ffeaa6,#fff7d4 45%,#e4a83d);filter:blur(1px) drop-shadow(0 0 10px #e9b34e);animation:openerGoldSlit .7s ease 2.52s forwards}
.id-light-beam-v2{z-index:2;left:46%;top:25%;width:11%;height:51%;clip-path:polygon(0 4%,100% 0,100% 100%,0 96%);background:linear-gradient(90deg,#fff8d7e8,#ffd87885 35%,transparent);filter:blur(5px);animation:openerBeam 1.22s ease 2.62s forwards}
.id-light-bloom-v2{z-index:1;background:#fff5bd;box-shadow:0 0 62px 25px #f3ce68,0 0 190px 95px #c999364f;animation:openerBloom 1.14s ease 3.02s forwards}
@keyframes openerDrawI{to{stroke-dashoffset:0}}
@keyframes openerDrawD{to{stroke-dashoffset:0}}
@keyframes openerFillIn{to{opacity:1}}
@keyframes openerFrame{to{stroke-dashoffset:0}}
@keyframes openerDoorAppear{to{opacity:1}}
@keyframes openerDoorSwing{0%{transform:perspective(750px) rotateY(0deg)}100%{transform:perspective(750px) rotateY(-70deg)}}
@keyframes openerGoldSlit{0%{opacity:0;transform:scaleX(.2)}45%{opacity:.85}100%{opacity:1;transform:scaleX(1.8)}}
@keyframes openerBeam{0%{opacity:0;transform:scaleX(.04)}45%{opacity:.7}100%{opacity:.95;transform:scaleX(3.25)}}
@keyframes openerBloom{0%{opacity:0;transform:scale(.2)}55%{opacity:.5}100%{opacity:.94;transform:scale(9)}}
@media(max-width:700px){.id-splash-stage-v2{width:min(64vw,350px)}}
@media(prefers-reduced-motion:reduce){.id-opener-svg .opener-i-stroke,.id-opener-svg .opener-i-fill,.id-opener-svg .opener-d-stroke,.id-opener-svg .opener-d-fill,.id-opener-svg .opener-frame-stroke,.id-opener-svg .opener-door,.id-opener-svg .opener-door-panel,.id-opener-svg .opener-knob,.id-gold-slit,.id-light-beam-v2,.id-light-bloom-v2{animation-duration:.01ms!important;animation-delay:.01ms!important}}


/* V2.0.29.8.5.29.17 — Crisp opener geometry pass. No fluffy violet bloom; no protruding serif caps. */
.id-opener-svg .opener-stroke{stroke:#a978f4;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;filter:none}
.id-opener-svg .opener-fill{filter:none}
.id-opener-svg .opener-frame-stroke{stroke-width:1.55;filter:none}
.id-opener-svg .opener-door{stroke-width:1.35;filter:none}
.id-opener-svg .opener-knob{filter:none}

/* V2.0.29.8.5.29.18 — weighted door swing: one fixed hinge, slightly slower creak-open. */
.id-opener-svg .opener-door-group{
  transform-box:view-box;
  transform-origin:110px 90px;
  animation:openerDoorGroupSwing 1.58s cubic-bezier(.22,.08,.18,1) 2.48s forwards;
}
.id-opener-svg .opener-door,
.id-opener-svg .opener-door-panel,
.id-opener-svg .opener-knob{
  transform:none;
  transform-origin:initial;
}
.id-opener-svg .opener-door{animation:openerDoorAppear .18s ease 2.10s forwards}
.id-opener-svg .opener-door-panel{animation:openerDoorAppear .18s ease 2.12s forwards}
.id-opener-svg .opener-knob{animation:openerDoorAppear .18s ease 2.18s forwards}
@keyframes openerDoorGroupSwing{
  0%{transform:perspective(750px) rotateY(0deg)}
  18%{transform:perspective(750px) rotateY(-7deg)}
  58%{transform:perspective(750px) rotateY(-40deg)}
  100%{transform:perspective(750px) rotateY(-70deg)}
}

/* V2.0.29.8.5.29.19 — fluid hinge pass: one uninterrupted door rotation, no staged velocity handoff. */
.id-opener-svg .opener-door-group{
  transform-box:view-box;
  transform-origin:110px 90px;
  will-change:transform;
  backface-visibility:hidden;
  animation:openerDoorGroupSwingFluid 1.58s cubic-bezier(.42,.04,.18,1) 2.48s forwards;
}
@keyframes openerDoorGroupSwingFluid{
  from{transform:perspective(750px) rotateY(0deg)}
  to{transform:perspective(750px) rotateY(-70deg)}
}


/* V2.0.29.8.5.29.20 — header refinement only. Keep .19 opener locked.
   The compact header uses the existing crisp ID geometry; a restrained warm
   light lives behind the partially-open door. Gold is not applied to the ID. */
.id-header-logo .id-header-door-light{
  display:block;
  fill:#f3c969;
  opacity:.9;
  filter:drop-shadow(0 0 2px rgba(243,201,105,.55));
}
.id-header-logo .id-door-group{
  transform:none;
}
.id-header-logo .id-door{
  fill:url(#idDoorViolet);
  stroke:#9f67e8;
  stroke-width:1.35;
  filter:none;
}
.id-header-logo .id-door-frame{
  stroke:#b98af3;
  stroke-width:1.35;
  filter:none;
}
.id-header-logo .id-knob{
  fill:#f0dca0;
  filter:none;
}
.id-header-logo .id-letter-fill{
  filter:none;
}
.id-logo:not(.id-header-logo) .id-header-door-light{display:none}

/* V2.0.29.8.5.29.21 — purpose-built small-format header mark only.
   The .19 Fluid Hinge opener is intentionally untouched. */
.id-header-static{
  width:58px;
  height:48px;
  flex:0 0 58px;
  overflow:visible;
  display:block;
}
.id-header-static .id-header-letter{
  fill:url(#headerViolet);
  stroke:#b991ef;
  stroke-width:.55;
  stroke-linejoin:miter;
  shape-rendering:geometricPrecision;
}
.id-header-static .id-header-light-wedge{
  fill:url(#headerGold);
  opacity:.9;
  filter:url(#headerGoldGlow);
}
.id-header-static .id-header-light-slit{
  fill:#f8d679;
  opacity:.98;
  filter:url(#headerGoldGlow);
}
.id-header-static .id-header-door-panel{
  fill:url(#headerDoor);
  stroke:#a66ee8;
  stroke-width:1.15;
  stroke-linejoin:miter;
}
.id-header-static .id-header-door-detail{
  fill:none;
  stroke:#7d48ba;
  stroke-width:.8;
  opacity:.9;
}
.id-header-static .id-header-knob{
  fill:#f2d78b;
  stroke:#5d3816;
  stroke-width:.35;
}
@media(max-width:700px){.id-header-static{width:49px;height:40px;flex-basis:49px}}


/* V2.0.29.8.5.29.22 — canonical static Infinity Door artwork.
   Static brand surfaces now use the approved app-icon artwork directly.
   The .19 Fluid Hinge opener remains unchanged. */
.id-header-master-logo{width:58px;height:58px;flex:0 0 58px;display:block;object-fit:contain;border-radius:14px}
@media(max-width:700px){.id-header-master-logo{width:49px;height:49px;flex-basis:49px;border-radius:12px}}

/* V2.0.29.8.5.29.23 — Infinity Door typography alignment
   Brand/major display headings get the crisp serif voice; controls, navigation,
   forms, and story prose deliberately remain sans-serif for readability. */
:root{--id-display-serif:Georgia,"Times New Roman",Times,serif}
.featured-copy h1,
.library-section-head h2,
.section-head h1,
.section-head h2,
.story-detail-main h1,
.featured-characters>h2{
  font-family:var(--id-display-serif);
  font-weight:700;
  letter-spacing:.012em;
  text-rendering:geometricPrecision;
  -webkit-font-smoothing:antialiased;
}
.featured-copy h1{font-size:38px;line-height:1.08}
.library-section-head h2{font-size:25px;line-height:1.15}
.section-head h1{letter-spacing:.008em}
.eyebrow{font-family:inherit;font-weight:800;letter-spacing:.12em}

/* V2.0.29.8.5.29.30 — static master-trace go/no-go test.
   Purposefully no opener motion yet: establish whether the clean vector silhouette
   is faithful enough to the approved master before spending time animating it. */
.id-master-trace-test{background:#05050a}
.id-master-trace-stage{position:relative;width:min(37vw,470px);min-width:270px;aspect-ratio:390/335;display:grid;place-items:center}
.id-master-trace-svg{width:100%;height:100%;overflow:visible;display:block}
.id-master-trace-note{position:absolute;left:50%;bottom:-18px;transform:translateX(-50%);font:600 8px/1 system-ui,sans-serif;letter-spacing:2.2px;color:#6f6680;opacity:.55;white-space:nowrap}
@media(max-width:700px){.id-master-trace-stage{width:min(72vw,390px)}}


/* V2.0.29.8.5.29.34 — timing polish only. LOCKED .32 geometry remains untouched.
   Door swing is continuous; gold is allowed to appear as soon as the hinge begins moving. */
.id-master-trace-test .id-master-trace-stage{perspective:1000px}
.id-master-trace-test .trace-i,
.id-master-trace-test .trace-i-detail{opacity:0;clip-path:inset(100% 0 0 0);animation:traceRevealI .72s cubic-bezier(.45,0,.2,1) .20s forwards}
.id-master-trace-test .trace-d,
.id-master-trace-test .trace-d-detail{opacity:0;clip-path:inset(0 100% 0 0);animation:traceRevealD 1.05s cubic-bezier(.45,0,.18,1) .78s forwards}
.id-master-trace-test .trace-spine{opacity:0;animation:traceAppear .20s ease 1.72s forwards}
.id-master-trace-test .trace-door-open{opacity:0;transform-box:view-box;transform-origin:211px 177px;transform:perspective(850px) scaleX(2.72);animation:traceDoorResolve .28s ease 1.92s forwards,traceDoorOpen 1.72s cubic-bezier(.38,.02,.16,1) 2.42s forwards;will-change:transform;backface-visibility:hidden}
.id-master-trace-test .trace-gold{opacity:0;pointer-events:none}
.id-master-trace-test .trace-edge-light{animation:traceEdgeLight 1.15s cubic-bezier(.25,.05,.18,1) 2.48s forwards}
.id-master-trace-test .trace-edge-core{animation:traceGoldCore 1.22s cubic-bezier(.25,.05,.18,1) 2.53s forwards}
.id-master-trace-test .trace-gold-threshold{animation:traceThresholdLight 1.34s cubic-bezier(.25,.05,.18,1) 2.52s forwards}
.id-master-trace-test .trace-gold-floor{transform-box:view-box;transform-origin:224px 292px;animation:traceFloorLight 1.48s cubic-bezier(.25,.05,.18,1) 2.58s forwards}
.id-master-trace-test .trace-gold-core{animation:traceGoldCore 1.30s cubic-bezier(.25,.05,.18,1) 2.56s forwards}
@keyframes traceRevealI{0%{opacity:0;clip-path:inset(100% 0 0 0)}15%{opacity:1}100%{opacity:1;clip-path:inset(0 0 0 0)}}
@keyframes traceRevealD{0%{opacity:0;clip-path:inset(0 100% 0 0)}12%{opacity:1}100%{opacity:1;clip-path:inset(0 0 0 0)}}
@keyframes traceAppear{to{opacity:1}}
@keyframes traceDoorResolve{0%{opacity:0}100%{opacity:1}}
@keyframes traceDoorOpen{
  0%{transform:perspective(850px) scaleX(2.72)}
  14%{transform:perspective(850px) scaleX(2.66)}
  34%{transform:perspective(850px) scaleX(2.42)}
  58%{transform:perspective(850px) scaleX(1.88)}
  80%{transform:perspective(850px) scaleX(1.30)}
  100%{transform:perspective(850px) scaleX(1)}
}
@keyframes traceEdgeLight{0%{opacity:0}10%{opacity:.08}35%{opacity:.28}100%{opacity:.55}}
@keyframes traceGoldCore{0%{opacity:0}12%{opacity:.10}40%{opacity:.42}100%{opacity:.9}}
@keyframes traceThresholdLight{0%{opacity:0}10%{opacity:.06}34%{opacity:.24}100%{opacity:.62}}
@keyframes traceFloorLight{0%{opacity:0;transform:scaleX(.03)}16%{opacity:.05;transform:scaleX(.12)}42%{opacity:.24;transform:scaleX(.42)}100%{opacity:.72;transform:scaleX(1)}}
.id-splash.leaving .id-master-trace-stage{filter:brightness(1.10);transition:filter .55s ease}
.id-splash.leaving .trace-gold-threshold{opacity:.96!important;transform:scale(3.8);transform-origin:235px 293px;transition:opacity .45s ease,transform .72s cubic-bezier(.22,.1,.18,1)}
.id-splash.leaving .trace-gold-floor{opacity:.94!important;transform:scaleX(2.5);transition:opacity .45s ease,transform .72s cubic-bezier(.22,.1,.18,1)}
@media(prefers-reduced-motion:reduce){
 .id-master-trace-test .trace-i,.id-master-trace-test .trace-i-detail,.id-master-trace-test .trace-d,.id-master-trace-test .trace-d-detail,.id-master-trace-test .trace-spine,.id-master-trace-test .trace-door-open,.id-master-trace-test .trace-gold{animation-duration:.01ms!important;animation-delay:.01ms!important}
}

/* V2.0.29.8.5.29.35 — two-fix polish only.
   1) Remove intermediate scale keyframes that caused visible stepping in the door swing.
   2) Increase only the final splash light footprint ~16–18% for a softer handoff.
   LOCKED .32 logo geometry, sequence timing, UI, and all other effects are unchanged. */
.id-master-trace-test .trace-door-open{
  animation:traceDoorResolve .28s ease 1.92s forwards,traceDoorOpen35 1.72s cubic-bezier(.42,.04,.18,1) 2.42s forwards;
}
@keyframes traceDoorOpen35{
  from{transform:perspective(850px) scaleX(2.72)}
  to{transform:perspective(850px) scaleX(1)}
}
.id-splash.leaving .trace-gold-threshold{transform:scale(4.45)}
.id-splash.leaving .trace-gold-floor{transform:scaleX(2.92)}

/* V2.0.29.8.5.29.36 — assembly smoothing only.
   LOCKED .32 geometry remains untouched.
   - D body reveals first; decorative highlight strokes wait until the bowl is substantially formed.
   - Door resolves gradually during the end of the D assembly instead of popping in afterward.
   - Door's baked warm edge is neutralized; actual gold is supplied only by the timed light layers.
   - .35 hinge motion, final bloom footprint, and all UI behavior remain unchanged. */
.id-master-trace-test .trace-d{
  animation:traceRevealD 1.05s cubic-bezier(.45,0,.18,1) .78s forwards;
}
.id-master-trace-test .trace-d-detail{
  opacity:0;
  clip-path:none;
  animation:traceDDetail36 .26s ease 1.62s forwards;
}
@keyframes traceDDetail36{
  from{opacity:0}
  to{opacity:1}
}
.id-master-trace-test .trace-spine{
  opacity:0;
  animation:traceSpine36 .30s ease 1.68s forwards;
}
@keyframes traceSpine36{
  from{opacity:0}
  to{opacity:1}
}
.id-master-trace-test .trace-door-open{
  opacity:0;
  animation:traceDoorResolve36 .42s cubic-bezier(.22,.1,.18,1) 1.72s forwards,traceDoorOpen35 1.72s cubic-bezier(.42,.04,.18,1) 2.42s forwards;
}
@keyframes traceDoorResolve36{
  0%{opacity:0}
  35%{opacity:.16}
  100%{opacity:1}
}
/* The final path inside the door group was a permanent warm/orange edge. It read as
   premature light before the door moved. Keep it violet; timed gold layers take over later. */
.id-master-trace-test .trace-door-open > path:last-of-type{
  stroke:#7f35aa;
  opacity:.48;
}

/* V2.0.29.8.5.29.37 — final assembly cleanup.
   Two surgical fixes only:
   1) Door is integrated into the tail of the D build with one long continuous resolve, removing the late pop/clunk.
   2) Every gold/light layer is hard-gated until AFTER hinge motion begins; closed door contains no warm edge. */
.id-master-trace-test .trace-door-open{
  opacity:0;
  animation:traceDoorIntegrate37 .68s cubic-bezier(.32,.02,.18,1) 1.34s forwards,
            traceDoorOpen35 1.72s cubic-bezier(.42,.04,.18,1) 2.42s forwards;
}
@keyframes traceDoorIntegrate37{
  0%{opacity:0}
  18%{opacity:.05}
  55%{opacity:.42}
  100%{opacity:1}
}
/* No baked warm seam while closed. */
.id-master-trace-test .trace-door-open > path:first-of-type{fill:url(#traceDoor);}
.id-master-trace-test .trace-door-open > path:last-of-type{stroke:#713092;opacity:.42}

/* Gold cannot bleed through the closed door. Visibility flips only after the 2.42s hinge start. */
.id-master-trace-test .trace-gold{opacity:0;visibility:hidden;pointer-events:none}
.id-master-trace-test .trace-edge-light{animation:traceEdgeLight37 1.10s cubic-bezier(.25,.05,.18,1) 2.50s forwards}
.id-master-trace-test .trace-edge-core{animation:traceGoldCore37 1.18s cubic-bezier(.25,.05,.18,1) 2.53s forwards}
.id-master-trace-test .trace-gold-threshold{animation:traceThresholdLight37 1.30s cubic-bezier(.25,.05,.18,1) 2.52s forwards}
.id-master-trace-test .trace-gold-floor{animation:traceFloorLight37 1.44s cubic-bezier(.25,.05,.18,1) 2.57s forwards}
.id-master-trace-test .trace-gold-core{animation:traceGoldCore37 1.26s cubic-bezier(.25,.05,.18,1) 2.54s forwards}
@keyframes traceEdgeLight37{0%{visibility:visible;opacity:0}12%{visibility:visible;opacity:.06}38%{visibility:visible;opacity:.26}100%{visibility:visible;opacity:.55}}
@keyframes traceGoldCore37{0%{visibility:visible;opacity:0}14%{visibility:visible;opacity:.08}42%{visibility:visible;opacity:.40}100%{visibility:visible;opacity:.9}}
@keyframes traceThresholdLight37{0%{visibility:visible;opacity:0}12%{visibility:visible;opacity:.05}38%{visibility:visible;opacity:.22}100%{visibility:visible;opacity:.62}}
@keyframes traceFloorLight37{0%{visibility:visible;opacity:0;transform:scaleX(.03)}18%{visibility:visible;opacity:.04;transform:scaleX(.10)}44%{visibility:visible;opacity:.22;transform:scaleX(.40)}100%{visibility:visible;opacity:.72;transform:scaleX(1)}}
/* Preserve .35's slightly larger final bloom, but only once the splash is actually leaving. */
.id-splash.leaving .trace-gold{visibility:visible}

/* V2.0.29.8.5.29.38 — coherent door assembly + truly cold closed seam.
   Two changes only:
   1) The complete door group is revealed by the SAME left-to-right assembly motion as the D,
      rather than fading in as a separate late object. All door details move as one unit.
   2) Closed-door artwork contains no warm/orange pixels. Actual gold remains hard-gated
      until after the hinge has visibly begun moving. */
.id-master-trace-test .trace-door-open{
  opacity:1;
  clip-path:inset(0 100% 0 0);
  animation:traceDoorAssemble38 1.05s cubic-bezier(.45,0,.18,1) .78s forwards,
            traceDoorOpen35 1.72s cubic-bezier(.42,.04,.18,1) 2.42s forwards;
}
@keyframes traceDoorAssemble38{
  0%{opacity:1;clip-path:inset(0 100% 0 0)}
  100%{opacity:1;clip-path:inset(0 0 0 0)}
}
/* Closed door stays purely violet/dark. These declarations intentionally override
   the earlier .36/.37 seam rules and remove any residual warm-looking edge. */
.id-master-trace-test .trace-door-open > path:first-of-type{fill:url(#traceDoorWarm);stroke:#8e37c4}
.id-master-trace-test .trace-door-open > path:last-of-type{stroke:#713092;opacity:.42}
/* Light stays completely unavailable until the door has already started moving. */
.id-master-trace-test .trace-gold{opacity:0;visibility:hidden;pointer-events:none}
.id-master-trace-test .trace-edge-light{animation:traceEdgeLight37 1.10s cubic-bezier(.25,.05,.18,1) 2.56s forwards}
.id-master-trace-test .trace-edge-core{animation:traceGoldCore37 1.18s cubic-bezier(.25,.05,.18,1) 2.59s forwards}
.id-master-trace-test .trace-gold-threshold{animation:traceThresholdLight37 1.30s cubic-bezier(.25,.05,.18,1) 2.58s forwards}
.id-master-trace-test .trace-gold-floor{animation:traceFloorLight37 1.44s cubic-bezier(.25,.05,.18,1) 2.63s forwards}
.id-master-trace-test .trace-gold-core{animation:traceGoldCore37 1.26s cubic-bezier(.25,.05,.18,1) 2.60s forwards}

/* V2.0.29.8.5.29.39 — premature seam-light cleanup only.
   The thin right-edge gold was technically gated, but it began only .14s after
   hinge motion and sits above the door in SVG paint order, so it still read as
   light bleeding through the closed/near-closed door. Keep it unavailable until
   the door has visibly opened. No logo, hinge, assembly, bloom, or UI changes. */
.id-master-trace-test .trace-edge-light{
  opacity:0;
  visibility:hidden;
  animation:traceEdgeLight39 1.02s cubic-bezier(.25,.05,.18,1) 2.93s forwards;
}
.id-master-trace-test .trace-edge-core{
  opacity:0;
  visibility:hidden;
  animation:traceGoldCore39 1.02s cubic-bezier(.25,.05,.18,1) 2.98s forwards;
}
@keyframes traceEdgeLight39{
  0%{visibility:visible;opacity:0}
  18%{visibility:visible;opacity:.05}
  46%{visibility:visible;opacity:.24}
  100%{visibility:visible;opacity:.55}
}
@keyframes traceGoldCore39{
  0%{visibility:visible;opacity:0}
  22%{visibility:visible;opacity:.06}
  52%{visibility:visible;opacity:.36}
  100%{visibility:visible;opacity:.9}
}

/* V2.0.29.8.5.29.41 — Boss identity + scoped lore polish */
.character-card,.collection-card,.mini-card{position:relative}.boss-badge{position:absolute;top:10px;right:10px;z-index:4;display:grid;justify-items:center;gap:1px;min-width:42px;padding:4px 5px 3px;border:1px solid #8d5c8f;border-radius:8px;background:#130d18e8;color:#d9a7df;box-shadow:0 4px 14px #0008;pointer-events:none}.boss-badge svg{width:27px;height:27px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.boss-badge svg circle{fill:currentColor;stroke:none}.boss-badge b{font-size:9px;line-height:1;letter-spacing:.12em}.boss-badge.compact{top:7px;right:7px;min-width:34px;padding:3px}.boss-badge.compact svg{width:22px;height:22px}.boss-badge.compact b{font-size:8px}.character-dead .boss-badge{filter:none;opacity:1;color:#c59bc9;background:#151018ed}.library-story-group .character-card{min-width:0}

/* V2.0.29.8.5.29.43 — jump-to-latest control */
.panel.chat{position:relative}
.jump-to-bottom{position:absolute;left:50%;right:auto;bottom:132px;z-index:20;width:38px;height:38px;border-radius:50%;opacity:0;pointer-events:none;transform:translate(-50%,8px);transition:opacity .15s ease,transform .15s ease}
.jump-to-bottom.show{opacity:1;pointer-events:auto;transform:translate(-50%,0)}

/* Relationship-first player Character card view */
.character-player-card{min-height:0;padding:0}.character-player-card>summary{list-style:none;cursor:pointer;padding:12px}.character-player-card>summary::-webkit-details-marker{display:none}.character-player-card[open]>summary{border-bottom:1px solid #30343a}.character-card-expanded{padding:12px}.character-info-switch{display:flex;align-items:center;justify-content:center;gap:8px;margin-bottom:10px;font-size:12px;color:#cfd2d7}.character-info-switch .switch{margin:0}.character-info-pane{min-height:48px}.character-info-pane p{margin:0;white-space:pre-wrap}.character-relationship-role{font-size:12px;font-weight:700;color:#d9dbe0;margin-bottom:6px}.character-player-card .collection-thumb-frame{cursor:pointer}.character-player-card .small.danger{margin:0 12px 10px}

/* .44.22 polish retry: Locations and Characters share one touch-friendly outer scroller. */
.collection-modal .achievements-modal-scroll{overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;touch-action:pan-y;-webkit-overflow-scrolling:touch;min-height:0;flex:1}
.collection-modal .achievements-modal-scroll>.collection-grid{overflow:visible;min-height:auto;touch-action:pan-y}

/* .44.22 polish retry: clearly selected Explore tag. */
.story-filter-tag.active{background:#4a2870;border-color:#c58cff;color:#fff;box-shadow:0 0 0 1px rgba(197,140,255,.18) inset}

/* 3.0.5 final UI/QoL polish */
.featured-character-list{max-height:306px;overflow-y:auto;padding-right:5px;scrollbar-gutter:stable}
.featured-character-list::-webkit-scrollbar{width:8px}.featured-character-list::-webkit-scrollbar-thumb{background:#513b70;border-radius:8px}.featured-character-list::-webkit-scrollbar-track{background:#0c0b13;border-radius:8px}
.map-tab-wrap .map-tab-edit{box-sizing:border-box;min-width:34px;width:34px;height:34px;padding:0;margin-left:4px;display:inline-flex;align-items:center;justify-content:center;line-height:1;vertical-align:middle}
.map-tabs-strip>.map-tab-wrap>button[data-map-tab]{height:34px}
.map-action-overlay{position:fixed;inset:0;z-index:10000;background:rgba(3,3,9,.72);display:flex;align-items:center;justify-content:center;padding:20px;backdrop-filter:blur(5px)}
.map-action-modal{width:min(520px,94vw);max-height:min(680px,88vh);overflow:auto;background:linear-gradient(180deg,#171226,#0d0b16);border:1px solid #67479a;border-radius:16px;box-shadow:0 24px 70px rgba(0,0,0,.62),0 0 28px rgba(139,92,246,.14);padding:18px;color:#f7f3ff}
.map-action-head{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:12px}.map-action-head h3{margin:0;color:#d4b8ff;font-family:Georgia,serif;font-size:20px}.map-action-head button{width:34px;height:34px;padding:0;border-radius:9px}.map-action-body p{color:#c8bfd6;line-height:1.5;margin:8px 0 14px}.map-choice-grid{display:grid;gap:9px}.map-choice-button{width:100%;min-height:44px;background:linear-gradient(135deg,#4b2b72,#6d3fa2);border:1px solid #9a6de0;color:#fff;border-radius:10px;font-weight:700;text-align:left;padding:10px 14px}.map-choice-button:hover{background:linear-gradient(135deg,#593486,#7a48b4);border-color:#c2a0f4}.map-action-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:16px}.map-action-field{display:grid;gap:7px;color:#c8bfd6}.map-action-field input{width:100%;background:#0b0a12;color:#fff;border:1px solid #4b3a63;border-radius:9px;padding:11px 12px}

/* 3.0.8 — local profiles / ownership / publishing */
.profile-gate{min-height:100vh;display:grid;place-items:center;padding:32px;background:radial-gradient(circle at 50% 20%,rgba(130,74,204,.18),transparent 34%),#090711;color:#f4efff}
.profile-gate-card{width:min(620px,94vw);background:linear-gradient(180deg,#151121,#0f0c18);border:1px solid #65458a;border-radius:24px;padding:30px;box-shadow:0 24px 80px rgba(0,0,0,.55)}
.profile-gate-card h1{margin:.25rem 0 1rem}.profile-gate-card .primary{width:100%;margin-top:10px}
.profile-image-row{display:flex;align-items:center;gap:16px;margin:12px 0 20px;flex-wrap:wrap}
.profile-avatar-large,.account-avatar{width:96px;height:96px;border-radius:22px;object-fit:cover;border:1px solid #7650a3;background:#171221}
.profile-tag-input{display:flex;align-items:center;border:1px solid var(--border,#49385d);border-radius:10px;background:#0e0b16;overflow:hidden}.profile-tag-input span{padding:0 0 0 12px;color:#b995e8;font-weight:700}.profile-tag-input input{border:0!important;background:transparent!important;flex:1}
.profile-switch-modal,.profile-login-modal{max-width:560px}.profile-choice-list{display:grid;gap:10px;margin:16px 0}.profile-choice{display:flex;align-items:center;gap:14px;text-align:left;padding:12px 14px;border:1px solid #49355f;background:#171120;border-radius:14px}.profile-choice:hover{border-color:#9765ce;background:#21162e}.profile-choice img,.profile-choice-placeholder{width:54px;height:54px;border-radius:14px;object-fit:cover;display:grid;place-items:center;background:#251833}.profile-choice span:not(.profile-choice-placeholder){display:grid;gap:2px}.profile-choice small{color:#a895bc}
.account-page{max-width:1100px;margin:0 auto;padding-bottom:70px}.account-profile-card{display:flex;align-items:center;gap:20px;padding:22px;border:1px solid #4a3760;border-radius:20px;background:linear-gradient(135deg,#171120,#100d18);margin:18px 0 30px}.account-profile-copy{flex:1;min-width:0}.account-profile-copy h2{margin:0 0 4px;font-size:28px}.profile-handle{color:#c69bf5;font-weight:700;margin-bottom:6px}.account-avatar.placeholder{display:grid;place-items:center;font-size:30px;color:#b785ee}.account-link-list{display:grid;gap:8px;margin:8px 0 28px}.account-link-list>button{display:flex;justify-content:space-between;align-items:center;text-align:left;padding:15px 17px;border:1px solid #372b46;background:#121019;border-radius:12px}.account-link-list>button:hover{border-color:#7650a3;background:#191322}.account-link-list small{display:block;color:#998ba7;font-weight:400;margin-top:3px}.account-link-list b{font-size:23px;color:#b88ae7}.account-favorites{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:14px}.danger-zone{border-color:#6e3746!important}
.favorite-story-btn{position:absolute;right:10px;top:10px;width:38px;height:38px;border-radius:999px!important;padding:0!important;display:grid;place-items:center;z-index:3;font-size:22px;background:rgba(12,9,18,.84)!important;border:1px solid #6a4b82!important;color:#eee!important}.favorite-story-btn.active{color:#e9b9ff!important;border-color:#b06df0!important;background:rgba(77,38,105,.9)!important}.library-story-card{position:relative}.favorite-preview-btn.active{border-color:#ad70e4;color:#e4c0ff}
.visibility-badge{display:inline-flex;align-items:center;padding:5px 10px;border-radius:999px;font-size:12px;font-weight:800;letter-spacing:.04em;text-transform:uppercase;margin:10px 0 2px}.visibility-badge.published{background:#392252;color:#d9b4ff;border:1px solid #7750a0}.visibility-badge.private{background:#1b1820;color:#b7aebf;border:1px solid #49414f}.publish-btn{border-color:#8756bb!important;color:#e0c2ff!important}
.publish-modal{max-width:720px}.publish-cover{width:150px;aspect-ratio:2/3;object-fit:cover;border-radius:14px;border:1px solid #4d3861;float:left;margin:0 18px 12px 0}.publish-summary{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}.publish-summary span{padding:7px 10px;border-radius:10px;background:#1a1324;border:1px solid #49365f;color:#cbb8d9}
.history-card-title{display:flex;align-items:center;gap:10px}.history-card-title h3{margin-right:auto}.pin-history-btn{padding:5px 9px!important;min-width:38px}.history-card.pinned{border-color:#72509a;box-shadow:inset 3px 0 0 #8457b5}
@media (max-width:700px){.account-profile-card{align-items:flex-start;flex-wrap:wrap}.account-profile-card>button{width:100%}.account-avatar{width:78px;height:78px}.publish-cover{float:none;width:120px}.profile-gate-card{padding:22px}}
.featured-creator{color:#b998d5;font-size:13px;font-weight:700;margin-top:-8px;margin-bottom:10px}.story-creator-chip{display:flex;align-items:center;gap:8px;color:#b6a6c5;margin:-4px 0 14px}.story-creator-chip img{width:30px;height:30px;border-radius:9px;object-fit:cover;border:1px solid #60437b}.story-creator-chip b{color:#d7b3f6}
\n\n/* 3.0.11 account/publishing polish */
/* Keep the established nav icons; only the former theme/sun icon becomes a door. */
.nav-door-star{opacity:0;transition:opacity .16s ease}.worlds-nav .app-nav-btn:hover .nav-door-star,.worlds-nav .app-nav-btn.active .nav-door-star{opacity:1}
/* "My Door" keeps the navigation's existing visual right edge by giving the centered row a small left bias. */
.worlds-nav{transform:translateX(-18px)}
/* Compact Favorites bookshelf cards: fixed compact width and full, uncropped cover art. */
.account-favorites{grid-template-columns:repeat(auto-fill,180px);align-items:start;justify-content:start}
.account-favorites .library-story-card.compact{width:180px;flex:none}
.account-favorites .library-story-card.compact .library-cover-frame{height:auto;aspect-ratio:3/4;background:#0b0a12}
.account-favorites .library-story-card.compact .library-cover{object-fit:contain}
.account-favorites .library-story-card.compact .library-story-info{padding:10px;gap:5px}
.account-favorites .library-story-card.compact .public-story-tags{gap:4px}
.account-favorites .library-story-card.compact .story-filter-tag{font-size:10px;padding:4px 6px}
/* Stable two-column action geometry for owned story cards. */
.story-card-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:12px}
.story-card-actions button{width:100%;min-width:0;margin:0;min-height:44px}
@media(max-width:700px){.worlds-nav{transform:none}.account-favorites{grid-template-columns:repeat(auto-fill,minmax(145px,180px))}.account-favorites .library-story-card.compact{width:100%}}


/* 3.0.13 Nyra beginner tutorial */
.beginner-tutorial{position:fixed;inset:0;z-index:9990;pointer-events:none;overflow:hidden}.nyra-stage{position:absolute;inset:0;pointer-events:none}.nyra-guide-image{position:absolute;display:block;object-fit:contain;pointer-events:none;filter:drop-shadow(0 12px 24px rgba(18,7,28,.34));user-select:none}.nyra-speech-wrap{position:absolute;pointer-events:auto;width:min(430px,38vw)}.nyra-dialogue{position:relative;color:#fbf8ff;background:linear-gradient(145deg,rgba(57,35,83,.96),rgba(29,18,48,.975));border:1px solid rgba(220,184,105,.82);border-radius:18px;padding:19px 22px 16px;box-shadow:inset 0 0 0 3px rgba(125,88,164,.19),0 12px 32px rgba(17,7,29,.3)}.nyra-dialogue:before,.nyra-dialogue:after{content:'◇';position:absolute;color:#d8b56c;font-size:12px;text-shadow:0 0 8px rgba(216,181,108,.35)}.nyra-dialogue:before{left:9px;top:7px}.nyra-dialogue:after{right:9px;bottom:7px}.nyra-crest{text-align:center;color:#d7b56c;letter-spacing:.32em;font:700 11px Georgia,serif;margin:-4px 0 4px}.nyra-name{text-align:center;color:#ddbd74;letter-spacing:.22em;font:800 12px Georgia,serif;margin-bottom:8px}.nyra-copy{font:600 17px/1.48 Georgia,'Times New Roman',serif;color:#fcf9ff;text-shadow:0 1px 0 rgba(0,0,0,.18)}.nyra-copy b{color:#f1dcff}.nyra-aside{font-style:italic;color:#e9dcf5}.nyra-actions{display:flex;align-items:center;gap:12px;justify-content:space-between;flex-wrap:wrap;margin-top:16px}.nyra-primary{border:1px solid #c9a0ef!important;background:linear-gradient(180deg,#7b50aa,#5b347f)!important;color:#fff!important;border-radius:10px!important;padding:9px 15px!important;font-weight:800!important;box-shadow:inset 0 0 0 1px rgba(255,255,255,.08),0 3px 10px rgba(24,8,36,.22)}.nyra-primary:hover{background:linear-gradient(180deg,#8a5cba,#68408c)!important}.nyra-exit{margin-left:auto!important;background:transparent!important;border:0!important;color:#c9b8d8!important;padding:8px 4px!important;text-decoration:underline;text-underline-offset:3px;font-size:12px!important}.nyra-exit:hover{color:#f0e5fb!important}.tutorial-target{position:relative!important;z-index:9989!important;outline:3px solid rgba(186,126,235,.92)!important;outline-offset:4px!important;box-shadow:0 0 0 7px rgba(119,57,164,.18),0 0 22px rgba(170,96,229,.6)!important;animation:tutorialPulse 1.7s ease-in-out infinite}.tutorial-target-soft{outline-width:2px!important;box-shadow:0 0 0 5px rgba(119,57,164,.12),0 0 15px rgba(170,96,229,.38)!important}.nyra-side-right.nyra-pose-welcome .nyra-guide-image{right:1.2vw;bottom:-3vh;width:min(47vw,670px);max-height:91vh}.nyra-side-right.nyra-pose-welcome .nyra-speech-wrap{right:min(43vw,600px);bottom:16vh}.nyra-pose-poof .nyra-guide-image{right:2.5vw;bottom:2vh;width:min(31vw,390px);max-height:72vh}.nyra-pose-poof .nyra-speech-wrap{right:min(31vw,405px);bottom:19vh}.nyra-pose-guide-left .nyra-guide-image{left:1vw;top:auto;bottom:-3vh;width:min(22vw,300px);max-height:54vh}.nyra-pose-guide-left .nyra-speech-wrap{left:min(22vw,315px);top:auto;bottom:2vh}.nyra-pose-presenter .nyra-guide-image,.nyra-pose-explorer .nyra-guide-image{left:1.5vw;top:22vh;width:min(28vw,360px);max-height:68vh}.nyra-pose-presenter .nyra-speech-wrap,.nyra-pose-explorer .nyra-speech-wrap{left:min(28vw,375px);top:24vh}.nyra-pose-author .nyra-guide-image{right:2vw;top:20vh;width:min(29vw,380px);max-height:70vh}.nyra-pose-author .nyra-speech-wrap{right:min(28vw,390px);top:23vh}.nyra-pose-history .nyra-guide-image{right:1vw;top:15vh;width:min(31vw,410px);max-height:78vh}.nyra-pose-history .nyra-speech-wrap{right:min(31vw,425px);top:22vh}.nyra-pose-demon .nyra-guide-image,.nyra-pose-demon-secret .nyra-guide-image{right:1.5vw;top:17vh;width:min(29vw,380px);max-height:74vh}.nyra-pose-demon .nyra-speech-wrap,.nyra-pose-demon-secret .nyra-speech-wrap{right:min(29vw,395px);top:24vh}.nyra-pose-mage .nyra-guide-image{right:1vw;top:15vh;width:min(31vw,410px);max-height:78vh}.nyra-pose-mage .nyra-speech-wrap{right:min(31vw,425px);top:23vh}.nyra-pose-cozy .nyra-guide-image{left:1vw;bottom:0;width:min(38vw,500px);max-height:79vh}.nyra-pose-cozy .nyra-speech-wrap{left:min(37vw,500px);bottom:17vh}.nyra-poof-active .nyra-guide-image{animation:nyraPoofIn .52s cubic-bezier(.2,.9,.22,1.18)}.nyra-poof-active .nyra-stage:after{content:'✦  ◇  ✦';position:absolute;right:16vw;bottom:37vh;color:#e4c2ff;font-size:28px;letter-spacing:.5em;text-shadow:0 0 12px #9d53d4;animation:nyraSpark .75s ease-out both;pointer-events:none}@keyframes tutorialPulse{0%,100%{filter:none}50%{filter:brightness(1.08)}}@keyframes nyraPoofIn{0%{opacity:0;transform:scale(.55) rotate(-4deg)}65%{opacity:1;transform:scale(1.07) rotate(1deg)}100%{transform:scale(1)}}@keyframes nyraSpark{0%{opacity:0;transform:scale(.4) rotate(-12deg)}35%{opacity:1}100%{opacity:0;transform:scale(1.7) rotate(12deg)}}
@media(max-width:900px){.nyra-guide-image{max-height:47vh!important;width:min(43vw,320px)!important;top:auto!important;bottom:0!important;left:auto!important;right:1.5vw!important}.nyra-speech-wrap{width:min(92vw,520px)!important;left:4vw!important;right:auto!important;top:auto!important;bottom:43vh!important}.nyra-pose-welcome .nyra-guide-image{width:min(55vw,420px)!important;max-height:55vh!important}.nyra-pose-welcome .nyra-speech-wrap{bottom:48vh!important}.nyra-pose-cozy .nyra-guide-image{width:min(58vw,440px)!important;max-height:50vh!important}.nyra-copy{font-size:16px}}
@media(max-width:560px){.nyra-guide-image{width:min(55vw,270px)!important;max-height:39vh!important}.nyra-speech-wrap{width:92vw!important;left:4vw!important;bottom:37vh!important}.nyra-dialogue{padding:16px 17px 13px;border-radius:15px}.nyra-copy{font-size:15px;line-height:1.42}.nyra-pose-welcome .nyra-guide-image{width:min(67vw,330px)!important;max-height:43vh!important}.nyra-pose-welcome .nyra-speech-wrap{bottom:40vh!important}.nyra-pose-cozy .nyra-guide-image{width:min(72vw,360px)!important;max-height:42vh!important}.tutorial-target{outline-offset:2px!important}}
@media(prefers-reduced-motion:reduce){.tutorial-target,.nyra-guide-image,.nyra-stage:after{animation:none!important}}

@media(max-width:900px){.nyra-pose-guide-left .nyra-guide-image{left:1vw!important;right:auto!important;top:auto!important;bottom:-1vh!important;width:min(36vw,270px)!important;max-height:42vh!important}.nyra-pose-guide-left .nyra-speech-wrap{left:min(35vw,280px)!important;right:auto!important;top:auto!important;bottom:2vh!important;width:min(60vw,430px)!important}}
@media(max-width:560px){.nyra-pose-guide-left .nyra-guide-image{width:min(42vw,210px)!important;max-height:34vh!important}.nyra-pose-guide-left .nyra-speech-wrap{left:4vw!important;bottom:35vh!important;width:92vw!important}}

/* 3.0.17 — Skill Point Rewards + creator polish */
.skill-point-reward-mode{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}.skill-point-reward-mode button{min-width:110px}.skill-point-reward-mode button.active{background:linear-gradient(135deg,#4b2b72,#6d3fa2);border-color:#9a6de0;color:#fff;box-shadow:inset 0 0 0 1px rgba(255,255,255,.05),0 0 14px rgba(139,92,246,.16)}
.auto-skill-point-config{margin:10px 0 14px;padding:12px;border:1px solid #49365f;border-radius:12px;background:#120e1a}.input-prefix{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.input-prefix input{width:120px}


/* 3.0.24 — Admin user database + usage foundation */
.account-usage-line{margin-top:12px;padding-top:12px;border-top:1px solid #372b46;color:#bcaec9}.account-usage-line b{color:#e1c6ff}.admin-user-list{display:grid;gap:9px;margin-top:14px}.admin-user-row{display:grid;grid-template-columns:minmax(180px,1.5fr) minmax(130px,1fr) minmax(140px,1fr) minmax(170px,1.2fr) 28px;gap:14px;align-items:center;width:100%;text-align:left;padding:14px 16px;border:1px solid #3c2e4c;background:#121019;border-radius:13px}.admin-user-row:hover{border-color:#8058aa;background:#191322}.admin-user-row>span{display:grid;gap:3px;min-width:0}.admin-user-row small{color:#9f91ad;overflow:hidden;text-overflow:ellipsis}.admin-user-row strong{font-size:24px;color:#b88ae7}.admin-user-row.suspended{border-color:#6e3746;opacity:.78}.admin-stat-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:18px 0 28px}.admin-stat-grid .panel{display:grid;gap:5px;margin:0}.admin-stat-grid b{font-size:22px;color:#e6ccff}.admin-stat-grid span{font-size:12px;color:#a99ab7}.admin-entitlement-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px 18px;align-items:end}.admin-check{display:flex;align-items:center;gap:10px;padding:12px;border:1px solid #49365f;border-radius:10px;background:#120e1a}.admin-check input{width:auto}.danger-check{border-color:#6e3746}.usage-history{display:grid;gap:0}.usage-history-row{display:grid;grid-template-columns:120px 100px 110px 90px minmax(180px,1fr);gap:12px;padding:10px 4px;border-bottom:1px solid #30263b;font-size:13px}.usage-history-row:last-child{border-bottom:0}
@media(max-width:800px){.admin-user-row{grid-template-columns:1fr 1fr}.admin-user-row>strong{display:none}.admin-stat-grid{grid-template-columns:1fr 1fr}.usage-history-row{grid-template-columns:1fr 1fr}.admin-entitlement-grid{grid-template-columns:1fr}}
@media(max-width:520px){.admin-user-row,.admin-stat-grid{grid-template-columns:1fr}.usage-history-row{grid-template-columns:1fr}.admin-user-detail .account-profile-card{display:block}.admin-user-detail .account-avatar{margin-bottom:12px}}


/* 3.0.26 — beta social, analytics, and mobile polish */
.story-social-bits{display:block;margin-top:2px;color:#a89ab9!important}.story-social-summary{display:flex;gap:14px;flex-wrap:wrap;margin:10px 2px 4px;color:#bba9d0;font-size:12px}.story-comments-section{max-width:1450px;margin:22px auto 0;background:linear-gradient(180deg,#0e0e18,#0a0a12);border:1px solid #2d2940;border-radius:16px;padding:18px}.story-comment-compose{display:grid;grid-template-columns:1fr auto;gap:10px;align-items:end;margin-bottom:14px}.story-comment-compose textarea{min-height:86px;resize:vertical}.story-comment{border-top:1px solid #2e293b;padding:14px 2px}.story-comment:first-child{border-top:0}.story-comment>div{display:flex;gap:10px;align-items:center}.story-comment small{color:#8f83a8}.story-comment p{white-space:pre-wrap;line-height:1.5;margin:8px 0}.story-preview-mobile-tabs{display:none}.admin-cost-summary,.admin-activity-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:0 0 12px}.admin-activity-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-cost-summary .panel,.admin-activity-grid .panel{display:grid;gap:5px}.admin-cost-summary b,.admin-activity-grid b{font-size:22px;color:#c8a8ff}.usage-history-row{grid-template-columns:110px repeat(5,minmax(0,1fr))!important}.mobile-player-handle,.mobile-player-backdrop{display:none}

@media(max-width:700px){
  .main{padding:12px 10px}.worlds-header{padding-left:8px;padding-right:8px}.worlds-nav{overflow-x:auto;overscroll-behavior-inline:contain;scrollbar-width:none}.worlds-nav::-webkit-scrollbar{display:none}.worlds-nav .app-nav-btn{flex:0 0 auto;padding:8px 10px;font-size:13px}
  .cards{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.story-card{padding:9px}.story-card .story-cover-frame{aspect-ratio:3/4;height:auto}.story-card h3{font-size:15px;margin:9px 0 5px}.story-card p{font-size:12px;min-height:0}.story-card-actions{grid-template-columns:1fr}.story-card-actions button{min-height:38px;padding:8px;font-size:12px}.visibility-badge{font-size:10px}
  .library-cover-frame,.library-story-card.compact .library-cover-frame{height:auto;aspect-ratio:3/4}.library-cover{object-fit:cover}.explore-grid{gap:10px}.library-story-info{padding:8px}.library-story-info>b{font-size:13px}
  .story-preview-mobile-tabs{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 12px;position:sticky;top:0;z-index:12;background:#0d0e10;padding:6px 0}.story-preview-tab-btn.active{background:#6f45a0;border-color:#a67ad3}.story-preview-tab-panel{display:none!important}.story-preview-tab-panel.mobile-tab-active{display:block!important}.story-detail-grid{grid-template-columns:1fr}.story-detail-main,.featured-characters{padding:13px}.story-detail-main h1{font-size:28px}.story-hero-frame{height:auto;aspect-ratio:3/4}.story-hero{object-fit:cover}.story-facts{grid-template-columns:repeat(2,1fr)}.story-facts>div{padding:8px}.story-comments-section{margin-top:0;padding:13px}.story-comment-compose{grid-template-columns:1fr}.story-comment-compose button{width:100%}
  .play-main{padding:0}.play-main .play{display:block;min-height:calc(100dvh - 48px)}.play .chat{height:calc(100dvh - 48px);min-height:0;border-radius:0;border-left:0;border-right:0}.play-left{display:none!important}.right-rail{display:block!important;position:fixed!important;z-index:90;top:48px;right:0;bottom:0;width:min(86vw,340px);max-width:none!important;margin:0!important;border-radius:14px 0 0 14px!important;transform:translateX(105%);transition:transform .22s ease;overflow:auto;box-shadow:-18px 0 40px #0009}.play.mobile-player-open .right-rail{transform:translateX(0)}.right-rail .right-toggle{display:none!important}.mobile-player-handle{display:grid;place-items:center;position:fixed;z-index:92;right:0;top:42%;width:34px;height:64px;border-radius:12px 0 0 12px;background:#5d357f;border:1px solid #a06fd0;border-right:0;color:white;font-size:25px;padding:0;box-shadow:0 4px 18px #0008}.play.mobile-player-open .mobile-player-handle{right:min(86vw,340px);transform:rotate(180deg)}.mobile-player-backdrop{display:none;position:fixed;inset:48px 0 0 0;z-index:89;border:0;border-radius:0;background:#0008;padding:0}.play.mobile-player-open .mobile-player-backdrop{display:block}.compose{padding:8px;gap:7px}.compose textarea{min-height:58px}.compose-tools,.continue-scene-row{padding-left:8px;padding-right:8px}.msgs{padding:10px}
  .admin-cost-summary{grid-template-columns:1fr}.admin-activity-grid{grid-template-columns:1fr 1fr}.usage-history-row{grid-template-columns:1fr 1fr!important;gap:6px 10px}
}

/* 3.0.27 — mobile drawer + cover-first Explore polish */
.mobile-featured-position,.mobile-playthrough-tools{display:none}
@media(max-width:700px){
  /* Keep the full nav reachable without forcing landscape. */
  .worlds-nav{overflow-x:auto!important;overflow-y:hidden;white-space:nowrap;-webkit-overflow-scrolling:touch;touch-action:pan-x;scroll-snap-type:x proximity}
  .worlds-nav .app-nav-btn{scroll-snap-align:start}

  /* Player drawer: quieter handle, higher placement, correct layer order, independent scroll. */
  .right-rail{z-index:1001!important;overflow-y:auto!important;overflow-x:hidden!important;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;opacity:1!important;filter:none!important;background:#0b0b12!important}
  .right-rail .rail-content{min-height:max-content;padding-bottom:calc(28px + env(safe-area-inset-bottom))}
  .mobile-player-backdrop{z-index:1000!important;background:rgba(0,0,0,.58)!important}
  .mobile-player-handle{z-index:1002!important;top:27%!important;width:30px!important;height:54px!important;background:rgba(93,53,127,.72)!important;border-color:rgba(160,111,208,.72)!important;box-shadow:0 4px 14px rgba(0,0,0,.42)!important;opacity:.72;transition:right .22s ease,transform .22s ease,opacity .16s ease}
  .mobile-player-handle:active,.play.mobile-player-open .mobile-player-handle{opacity:.96}
  .mobile-playthrough-tools{display:grid;gap:8px;margin:14px 0;padding-top:14px;border-top:1px solid #30263b}
  .mobile-playthrough-tools h3{margin:0 0 2px;font-size:14px;color:#c9b0e7;letter-spacing:.06em}

  /* Phone Explore is cover-first. Desktop/tablet keep the existing text-led hero. */
  .explore-featured{display:flex!important;flex-direction:column!important;align-items:center!important;min-height:0!important;padding:18px 44px 20px!important;gap:12px!important;text-align:center;touch-action:pan-y}
  .explore-featured .featured-art{display:block!important;width:min(68vw,270px)}
  .explore-featured .featured-cover-frame{width:100%!important;max-width:none!important;height:auto!important;aspect-ratio:3/4;margin:0 auto!important;border-radius:16px}
  .explore-featured .featured-copy{width:100%;display:grid;justify-items:center;gap:5px}
  .explore-featured .featured-copy .eyebrow{margin-top:2px}
  .explore-featured .featured-copy h1{font-size:25px!important;margin:2px 0 0!important;line-height:1.08}
  .explore-featured .featured-creator{font-size:12px}
  .explore-featured .featured-copy p{font-size:13px!important;line-height:1.35;margin:2px 0 6px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
  .explore-featured .explore-arrow{top:43%!important;width:32px!important;height:52px!important;opacity:.78}
  .mobile-featured-position{display:block;font-size:11px;color:#9385a6;margin-top:2px}
}
