@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');
.creator-library-header{display:flex;align-items:center;gap:20px;padding:30px 25px;margin:25px 0 12px;border:1px solid #3c304b;border-radius:15px;background:linear-gradient(120deg,#282034,#191923)}.creator-library-avatar{height:72px;width:72px;flex-shrink:0;border-radius:50%;display:grid;place-items:center;background:#473154;color:#d9b7ee;font:700 28px Manrope}.creator-library-header h2{margin:0 0 8px;font-size:22px}.creator-library-header p{color:#d0bcde;font-size:13px;margin:0 0 10px}.creator-library-header>.secondary{margin-left:auto;white-space:nowrap}.your-character-gallery .portrait-grid{grid-template-columns:repeat(auto-fill,minmax(185px,1fr));gap:17px}.your-character-gallery .portrait-cover{height:315px}.your-character-gallery .portrait-caption{padding:50px 14px 14px}.your-character-gallery .portrait-caption h3{font-size:15px}.your-character-gallery .portrait-caption p{-webkit-line-clamp:2}.ip-card-label{display:block;color:#d5b6eb;font-size:10px;margin:5px 0;overflow-wrap:anywhere}.ip-fields{border:1px solid #4a365d;border-radius:12px;background:#211a2b;padding:20px;margin:24px 0}.ip-fields h2{margin-top:0}.ip-fields select{margin-bottom:0}.ip-fields .small{line-height:1.8}@media(max-width:700px){.creator-library-header{padding:20px;gap:13px;flex-wrap:wrap}.creator-library-header>.secondary{margin-left:0}.creator-library-avatar{width:55px;height:55px}.your-character-gallery .portrait-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.your-character-gallery .portrait-cover{height:290px}}@media(max-width:380px){.your-character-gallery .portrait-grid{grid-template-columns:1fr}}
.story-mode .story-profile{overflow:hidden}.small-avatar-settings{display:flex;align-items:center;gap:17px;border:1px solid #4e3c60;border-radius:12px;padding:17px;margin:22px 0;background:#231a2e}.small-avatar-settings .story-round-avatar{width:64px;height:64px;flex-shrink:0}.small-avatar-settings b{font-size:13px}.small-avatar-settings p{font-size:11px;line-height:1.7;margin:6px 0 10px}.small-avatar-settings .secondary{padding:8px 12px;font-size:12px}
.avatar-edit-button{width:100%;height:100%;padding:0;display:grid;place-items:center;border-radius:50%;overflow:hidden;position:relative;background:transparent;color:inherit;font:inherit}.avatar-edit-button img{width:100%;height:100%;object-fit:cover}.avatar-edit-button:hover:after{content:'✎';position:absolute;inset:0;display:grid;place-items:center;background:#1c1128a6;color:white;font-size:17px}.avatar-edit-button:focus-visible{outline:2px solid #e1b6ff;outline-offset:-3px}#small-portrait-editor{max-width:480px}#small-portrait-editor .dialog-top h2{font-size:19px}#small-portrait-editor p{line-height:1.8}#small-portrait-editor input[type=range]{padding:0;accent-color:#bb9bea}#small-portrait-editor .portrait-cancel[aria-label]{font-size:25px;color:#c5b1d4}.portrait-crop-stage{display:flex;justify-content:center;margin:20px 0}.portrait-crop-stage canvas{width:210px;height:210px;border-radius:50%;border:2px solid #ac85c7;background:#25192f;box-shadow:0 0 0 7px #a177b41a}#small-portrait-editor .dialog-actions{flex-wrap:wrap}
.mobile-profile-button{display:none}@media(max-width:650px){.mobile-profile-button{display:block;padding:6px;font-size:10px}.story-mode .story-profile.mobile-profile-visible{display:flex;position:absolute;left:0;top:0;bottom:0;width:min(310px,90%);z-index:12;box-shadow:15px 0 40px #0009}}
.portrait-card{position:relative}.card-hover-panel{position:absolute;inset:0 0 46px;z-index:3;background:linear-gradient(155deg,#211b2df5,#100f18fa);padding:18px;display:flex;flex-direction:column;gap:10px;opacity:0;visibility:hidden;transform:translateY(12px);transition:opacity .18s ease,transform .18s ease,visibility .18s;pointer-events:none}.portrait-card:hover:not(.preview-dismissed) .card-hover-panel,.portrait-card:focus-within:not(.preview-dismissed) .card-hover-panel,.portrait-card.preview-open .card-hover-panel{opacity:1;visibility:visible;transform:translateY(0);pointer-events:auto}.hover-panel-title{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.hover-panel-title h3,.hover-panel-title h2{margin:0;line-height:1.45;overflow-wrap:anywhere}.hover-panel-title h3{font-size:16px}.preview-close{font-size:22px;color:#c2adc9;padding:0 3px;line-height:1}.creator-preview{display:flex;align-items:center;gap:10px;background:#ffffff08;border:1px solid #ffffff08;padding:11px;border-radius:10px}.creator-avatar{width:33px;height:33px;border-radius:50%;display:grid;place-items:center;background:#4b3657;color:#e2c9ef;font-size:14px;flex-shrink:0}.creator-preview small{display:block;color:#a89ab5;font-size:10px;margin-bottom:4px}.creator-preview b{display:block;font-size:12px;color:#e4d6ec;overflow-wrap:anywhere}.hover-intro-scroll{overflow-y:auto;min-height:0;flex:1;overscroll-behavior:contain;scrollbar-color:#72577d transparent;padding-right:7px;white-space:pre-wrap;font-size:12px;line-height:1.8;color:#c5b8ce}.hover-intro-scroll h4{margin:0 0 10px;color:#e4d4ed;font-size:12px}.card-hover-panel>.primary{padding:9px 12px;font-size:11px}.card-hover-panel>.copy-character-id{text-align:left;align-self:flex-start;padding:0}.portrait-footer .row{gap:10px}.portrait-footer .preview-toggle{font-size:10px}.story-profile{position:relative}.story-profile-toggle{position:absolute;top:12px;right:12px;z-index:7;background:#14101dcc;border:1px solid #81658f77;color:#dfc9e9;padding:7px 10px;border-radius:18px;font-size:10px;backdrop-filter:blur(8px)}.story-profile-preview{position:absolute;inset:27% 0 0;z-index:6;background:linear-gradient(#17111df5,#100d16);border-top:1px solid #72507e44;padding:23px 20px;display:flex;flex-direction:column;gap:14px;opacity:0;visibility:hidden;transform:translateY(20px);transition:opacity .2s ease,transform .2s ease,visibility .2s;pointer-events:none}.story-profile:hover:not(.preview-dismissed) .story-profile-preview,.story-profile:focus-within:not(.preview-dismissed) .story-profile-preview,.story-profile.profile-preview-open .story-profile-preview{opacity:1;visibility:visible;transform:translateY(0);pointer-events:auto}.story-profile-preview h2{font-size:19px}.story-profile-preview>.copy-character-id{align-self:flex-start}.story-profile-intro{flex:1;overflow:auto;min-height:0;white-space:pre-wrap;line-height:1.9;font-size:13px;color:#c3b5cd;scrollbar-color:#72577d transparent;padding-right:8px;overscroll-behavior:contain}.story-profile-intro h3{font-size:14px;color:#e1cee9;margin:2px 0 12px}.story-profile-preview .creator-preview{padding:13px}.preview-toggle{white-space:nowrap}@media(prefers-reduced-motion:reduce){.card-hover-panel,.story-profile-preview{transition:none;transform:none}}@media(hover:none){.portrait-card:hover:not(.preview-open):not(:focus-within) .card-hover-panel{opacity:0;visibility:hidden;pointer-events:none}}@media(max-width:650px){.card-hover-panel{padding:13px;gap:8px}.creator-preview{padding:8px}.hover-intro-scroll{font-size:11px}}
.lore-reading-panel{height:380px;max-height:55dvh;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;padding:8px 18px 12px 4px;margin-top:17px;border-top:1px solid #50415d66;scrollbar-color:#715780 #1a1622}.lore-reading-panel p{line-height:1.95;margin:16px 0;color:#c2b7cd;overflow-wrap:anywhere}.lore-reading-panel h3{font-size:13px;letter-spacing:1.1px;line-height:1.7;color:#ddc6f0;margin:29px 0 12px}.lore-reading-panel .lore-description{color:#dfccec;font-style:italic}.lore-reading-panel:focus-visible{outline:2px solid #b699d5;outline-offset:4px}@media(max-width:650px){.lore-reading-panel{height:320px;padding-right:10px}}
.world-art .world-cover-image{width:100%;height:100%;object-fit:cover;display:block}.lore-gallery-cover{display:block;width:100%;height:auto;object-fit:contain;border-radius:14px;border:1px solid #584264;margin-top:22px}@media(max-width:650px){.lore-gallery-cover{height:auto}}
.copy-character-id{display:inline-block;cursor:pointer;color:#c0a6d3;font-size:11px;font-family:inherit;font-variant-numeric:tabular-nums;padding:3px 0;background:none;border:0;border-radius:3px}.copy-character-id:hover{color:#e5d1f6;text-decoration:underline}.copy-character-id:focus-visible{outline:2px solid #c3a0ea;outline-offset:3px}
.story-mode .story-stage{grid-template-columns:260px minmax(0,1fr) 250px;position:relative}.story-cast-panel{background:#100d18e6;border-left:1px solid #ffffff12;padding:26px 20px;overflow:auto;min-width:0}.story-cast-panel>h2{font-size:17px;margin:18px 0 14px;display:flex;align-items:center;justify-content:space-between}.story-cast-panel>h2>span{background:#302539;color:#c4add8;font-size:11px;border-radius:20px;padding:4px 8px}.story-cast-person{display:flex;align-items:flex-start;gap:11px;padding:18px 0;border-bottom:1px solid #ffffff0c}.story-cast-person>div:last-child{min-width:0}.story-cast-person h3{font-size:13px;line-height:1.6;margin:0 0 4px;overflow-wrap:anywhere}.story-cast-person p{font-size:10px;line-height:1.7;margin:3px 0;color:#aa98b7}.story-cast-person .cast-role{color:#c3b0d4}.story-cast-person .cast-id{font-variant-numeric:tabular-nums;color:#ad93c0}.story-cast-person .story-round-avatar{width:38px;height:38px}.cast-player-section{margin-top:30px}.cast-list-toggle{display:none}@media(min-width:1600px){.story-mode .story-stage{grid-template-columns:340px minmax(0,1fr) 280px}}@media(max-width:1100px){.story-mode .story-stage{grid-template-columns:210px minmax(0,1fr) 210px}.story-cast-panel{padding:23px 14px}.story-cast-person{gap:8px}}@media(max-width:950px){.story-mode .story-stage{grid-template-columns:230px minmax(0,1fr)}.story-cast-panel{display:none;position:absolute;right:0;top:0;bottom:0;width:270px;z-index:5;background:#14101df7;box-shadow:-15px 0 45px #0009}.story-stage.cast-visible .story-cast-panel{display:block}.cast-list-toggle{display:block;font-size:10px;padding:7px 10px;margin-left:auto}.story-type-controls{margin-left:0}}@media(max-width:650px){.story-mode .story-stage{grid-template-columns:minmax(0,1fr)}.cast-list-toggle{padding:6px}.story-topbar>span{display:none}}
.narration-button{border:1px solid #715d80;border-radius:8px;padding:7px 10px;color:#d2b9e3;font:700 20px Georgia,serif;line-height:1}.narration-button:hover{background:#46304f}
.story-mode .story-stage{background:radial-gradient(ellipse at 80% 25%,#49304566,transparent 70%),linear-gradient(115deg,#17121b,#261b29)}.story-mode .story-stage.mafia{background:radial-gradient(ellipse at 85% 20%,#642b2344,transparent 65%),linear-gradient(115deg,#171117,#301f1d)}.story-mode .story-stage.vampire{background:radial-gradient(ellipse at 80% 20%,#601c3444,transparent 60%),linear-gradient(115deg,#150e16,#2e1823)}.story-mode .story-composer textarea{min-height:43px;height:43px}
.story-start-label{display:block;font-size:15px;color:#b5a9c7;font-weight:400;margin-bottom:7px}.story-start-name{display:block;font-size:25px}.selected-companions{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:10px}.companion-chip{display:flex;align-items:center;gap:9px;background:#382b4b;border:1px solid #6a4f88;border-radius:20px;padding:7px 11px;font-size:12px}.companion-chip small{color:#bba7d0;font-variant-numeric:tabular-nums}.companion-chip button{font-size:18px;padding:0 2px}#companion-results{border:1px solid #4a3c60;border-radius:9px;background:#161520;max-height:230px;overflow:auto;padding:5px;margin-top:7px}#companion-results button{width:100%;display:flex;align-items:center;justify-content:space-between;text-align:left;padding:12px;border-radius:6px;gap:10px}#companion-results button:hover,#companion-results button[aria-selected=true]{background:#393044}#companion-results small,.character-code{color:#b3a6c4;font-size:10px;font-variant-numeric:tabular-nums}.story-mode .sidebar,.story-mode main>header{display:none}.story-mode #content.chat-content{padding:0 22px 22px;max-width:none}.story-mode{background:#09090d}.story-topbar{height:62px;display:flex;align-items:center;gap:18px;font-size:11px;letter-spacing:1px;color:#c6b9d2}.story-back{background:#202025;border-radius:50%;width:35px;height:35px;font-size:21px}.story-type-controls{margin-left:auto;display:flex;align-items:center;gap:7px;letter-spacing:0}.story-type-controls label{margin:0 5px 0 0;color:#b6a8c4;font-size:11px}.story-type-controls button{border:1px solid #403744;border-radius:7px;padding:6px 10px}.story-type-controls select{width:80px;margin:0;padding:6px;font-size:12px}.story-stage{height:calc(100dvh - 84px);min-height:500px;border:1px solid #3b2d3d;border-radius:20px;overflow:hidden;display:grid;grid-template-columns:310px minmax(0,1fr);background:radial-gradient(ellipse at 80% 25%,#49304566,transparent 70%),linear-gradient(115deg,#17121b,#261b29);color:#eee9ef}.story-stage.mafia{background:radial-gradient(ellipse at 85% 20%,#642b2344,transparent 65%),linear-gradient(115deg,#171117,#301f1d)}.story-stage.vampire{background:radial-gradient(ellipse at 80% 20%,#601c3444,transparent 60%),linear-gradient(115deg,#150e16,#2e1823)}.story-profile{background:#0b0b0ee6;border-right:1px solid #4b35474d;overflow:auto;display:flex;flex-direction:column}.story-portrait{min-height:250px;height:52%;flex-shrink:0;position:relative}.story-portrait:after{content:'';position:absolute;inset:70% 0 0;background:linear-gradient(transparent,#0b0b0e)}.story-portrait img{width:100%;height:100%;object-fit:cover;object-position:top}.story-portrait-empty{height:100%;background:radial-gradient(ellipse at 50% 40%,#71547955,transparent 75%),linear-gradient(125deg,#29202d,#15131c);display:flex;flex-direction:column;justify-content:center;align-items:center;color:#a88db9}.story-portrait-empty span{font-size:115px;opacity:.45}.story-portrait-empty p{font:600 20px Manrope}.story-profile-info{padding:20px;margin-top:auto}.story-profile-info h2{font-size:20px;margin:0 0 8px}.story-tags{display:flex;gap:7px;flex-wrap:wrap}.story-tags>span{background:#9c8a9d24;border:1px solid #ccb9cb1a;border-radius:5px;font-size:10px;padding:4px 7px;color:#c1b5c2}.story-facts{display:flex;margin:25px 0;gap:12px}.story-facts>div{flex:1;min-width:0;text-align:center;border-right:1px solid #322933}.story-facts>div:last-child{border:0}.story-facts b{font-size:13px;overflow-wrap:anywhere}.story-facts small{display:block;color:#948898;font-size:10px;margin-top:7px}.story-lore{font-size:11px;color:#a696ad;line-height:1.8}.story-lore summary{cursor:pointer;color:#c8b7d1}.story-lore textarea{min-height:100px;font-size:12px}.story-conversation{display:flex;flex-direction:column;min-width:0;min-height:0}.story-chat-header{height:72px;flex-shrink:0;padding:12px 24px;display:flex;align-items:center;gap:12px;border-bottom:1px solid #ffffff0a;background:#100d1222}.story-chat-header small{display:block;color:#a698ae;font-size:11px;margin-top:5px}.story-chat-header #undo-turn{margin-left:auto;font-size:11px}.story-round-avatar{flex-shrink:0;width:34px;height:34px;border-radius:50%;overflow:hidden;background:#46344d;display:grid;place-items:center;font-weight:600;color:#c7afd8;font-size:15px}.story-round-avatar img{width:100%;height:100%;object-fit:cover}.story-mode .story-transcript{min-height:0;max-height:none;flex:1;overflow:auto;padding:25px 32px;margin:0;scrollbar-color:#685161 transparent}.story-introduction{max-width:750px;margin:0 auto 30px;text-align:center}.story-introduction h2{font-size:22px;margin:4px 0 10px}.story-introduction .story-tags{justify-content:center;margin:18px 0}.story-intro{background:#08070aaa;border:1px solid #8e6e821a;border-radius:15px;text-align:left;padding:15px 18px;font-size:var(--story-font);line-height:1.7;color:#d2c9d4;margin-top:22px}.story-intro summary{cursor:pointer;font-size:13px;display:block;color:#b3a4b8}.story-intro summary b{color:#e2d7e8;margin-right:8px}.story-intro p{white-space:pre-wrap}.story-disclosure{font-size:11px;color:#b4a1bb;margin:25px 0}.story-message-row{display:flex;align-items:flex-start;gap:12px;max-width:780px;margin:0 auto 24px}.story-bubble{background:#09080bd9;border:1px solid #ffffff05;border-radius:19px;padding:20px 23px;max-width:88%;min-width:0}.story-message-author{display:block;color:#c2a7d2;font-size:10px;letter-spacing:1px;margin-bottom:10px}.story-message-text{font-size:var(--story-font);line-height:1.85;white-space:pre-wrap;overflow-wrap:anywhere;color:#eee8ef}.story-narration{font-style:italic;color:#ac9bb5}.story-message-row.user{flex-direction:row-reverse}.story-message-row.user .story-bubble{background:#32243cbd}.story-message-row.user .story-message-author{color:#c8b8de}.story-composer-area{flex-shrink:0;padding:10px 26px 15px;max-width:100%;background:linear-gradient(transparent,#0a080b44)}.story-cast-chips{display:flex;gap:7px;flex-wrap:wrap;max-width:780px;margin:0 auto 10px}.story-cast-chips>span{border:1px solid #89758c66;background:#0c090f55;color:#c2b0cb;padding:6px 11px;font-size:10px;border-radius:18px}.story-mode .story-composer{display:flex;gap:12px;align-items:center;max-width:780px;margin:auto;border:1px solid #947e9766;background:#08070bad;border-radius:15px;padding:11px 14px}.story-composer textarea{min-height:43px;height:43px;max-height:140px;padding:9px 4px;flex:1;font-size:var(--story-font);line-height:1.5}.story-send{font-size:25px;color:#c7accf;padding:5px 10px}.story-composer-hint{font-size:9px;text-align:center;color:#9a88a3;margin-top:8px}@media(min-width:1600px){.story-stage{grid-template-columns:380px minmax(0,1fr)}.story-portrait{height:65%}}@media(max-width:950px){.story-stage{grid-template-columns:240px minmax(0,1fr)}.story-mode .story-transcript{padding:20px 15px}.story-bubble{padding:16px;max-width:90%}.story-message-row{gap:8px}.story-profile-info{padding:17px}.story-topbar>span .small{display:none}}@media(max-width:650px){.story-mode #content.chat-content{padding:0 8px 8px}.story-topbar{height:54px;gap:9px}.story-topbar>span{font-size:9px}.story-type-controls{gap:3px}.story-type-controls label{display:none}.story-type-controls select{width:65px}.story-type-controls button{padding:5px}.story-stage{grid-template-columns:1fr;height:calc(100dvh - 62px);min-height:400px;border-radius:13px}.story-profile{display:none}.story-chat-header{height:65px;padding:10px 14px}.story-chat-header b{font-size:12px}.story-chat-header #undo-turn{font-size:10px}.story-composer-area{padding:8px 12px}.story-bubble{max-width:90%;padding:14px}.story-round-avatar{width:27px;height:27px}.story-introduction h2{font-size:19px}.story-mode .story-transcript{padding:18px 12px}}
.field-counter{text-align:right;font-size:11px;color:#b4a9c5;padding:7px 2px 0;font-variant-numeric:tabular-nums}.field-counter.at-limit{color:#efbd85}
[hidden]{display:none!important}.vampire{background:radial-gradient(ellipse at 65% 25%,#b9567055,transparent),linear-gradient(135deg,#371a2f,#171324);color:#edb3bd}.admin-banner{border:1px solid #a78451;border-radius:14px;padding:24px;display:flex;justify-content:space-between;gap:24px;align-items:center;background:linear-gradient(120deg,#342b24,#221d2b)}.admin-banner h2{margin-top:0}.admin-banner p{color:#c6b99f;line-height:1.8}.admin-lore-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.admin-enabled header{border-bottom-color:#ba8d45}.admin-enabled #engine-badge:before{content:'ADMIN · ';color:#f0c782}@media(max-width:700px){.admin-lore-grid{grid-template-columns:1fr}.admin-banner{display:block}.admin-banner button{margin-top:12px}}
.fantasy{background:radial-gradient(ellipse at 70% 25%,#be94e655,transparent),linear-gradient(135deg,#24302d,#392e50);color:#d9c3ed}.superhero{background:radial-gradient(ellipse at 65% 25%,#619de955,transparent),linear-gradient(135deg,#183956,#38264c);color:#b7d1f6}.account-panel{border:1px solid #504263;border-radius:14px;padding:26px;background:linear-gradient(115deg,#282033,#1a1c28);margin:25px 0}.account-panel h2{margin:0 0 10px}.account-panel p{line-height:1.8}.persona-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.persona-grid .persona-card{margin:0;overflow-wrap:anywhere}.persona-grid .persona-card>p{clear:both}.selected-persona{border-color:#bd9aff;box-shadow:inset 0 0 0 1px #bd9aff33}.google-setup{padding:15px 0}.google-setup summary{cursor:pointer;color:#c3a6f0}#google-signin{margin:18px 0}nav{overflow-y:auto}nav button{flex-shrink:0}@media(max-width:700px){.persona-grid{grid-template-columns:1fr}nav{overflow-x:auto}nav button{white-space:nowrap}}
.ghostwriter-panel{max-width:985px;border:1px solid #74578e;border-radius:16px;padding:27px;margin:0 0 35px;background:radial-gradient(ellipse at 95% 0,#75539a33,transparent 65%),#1c1928}.ghostwriter-panel h2{font-size:24px;margin:8px 0}.ghostwriter-panel .subtitle{margin-top:8px;max-width:760px;font-size:13px}.ghostwriter-panel label{font-weight:600}.ghost-options{display:grid;grid-template-columns:1fr 1fr;gap:20px}.ghost-options select{margin-bottom:0}.ghostwriter-panel>textarea{min-height:100px}.ghostwriter-panel>.small{line-height:1.8}.ghostwriter-panel .row{margin-top:18px}#ghost-status{padding-top:8px;color:#cbb6eb;white-space:pre-wrap}#character-form[inert]{opacity:.55}@media(max-width:600px){.ghostwriter-panel{padding:20px}.ghost-options{grid-template-columns:1fr;gap:0}}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.lore-summary{border:1px solid #353044;border-radius:12px;margin:22px 0;padding:18px;color:#b7b1c6;line-height:1.8}.lore-summary summary{cursor:pointer;color:#ddd4ef}.lore-summary summary span{margin-left:18px}.gallery-tools{display:flex;gap:14px;margin-top:25px}.gallery-tools input{flex:1;border-radius:30px;padding-left:20px;background:#1e1e29}.gallery-tools select{width:150px;margin:0;border-radius:30px}.filter-chips{display:flex;gap:9px;flex-wrap:wrap;margin:20px 0 24px}.filter-chip{background:#252530;padding:10px 18px;border-radius:24px;color:#bcb5cb}.filter-chip.selected{background:#e9e0ff;color:#251937}.portrait-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:19px}.portrait-card{border:1px solid #302b3d;border-radius:15px;overflow:hidden;background:#1b1a24}.portrait-cover{display:block;position:relative;width:100%;height:345px;overflow:hidden;text-align:left}.portrait-cover>img{width:100%;height:100%;object-fit:cover;transition:transform .3s}.portrait-cover:hover>img{transform:scale(1.04)}.portrait-fallback{position:absolute;inset:0;display:grid;place-items:center;font:600 90px Manrope;color:#d1bedf55}.no-portrait{position:absolute;top:20px;left:20px;right:20px;font-size:10px;color:#d1c5dd99}.portrait-caption{position:absolute;bottom:0;left:0;right:0;padding:65px 18px 18px;background:linear-gradient(transparent,#0c0b12f5)}.portrait-caption h3{color:white;font-size:18px}.portrait-caption p{font-size:12px;color:#c4bdcc;line-height:1.6;margin:7px 0 0;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}.portrait-footer{display:flex;justify-content:space-between;align-items:center;padding:14px 17px;font-size:11px;color:#a99eb9}.creator-layout{display:grid;grid-template-columns:minmax(0,650px) minmax(220px,300px);gap:35px;align-items:start}.creator-heading{margin-bottom:30px}.creator-fields{min-width:0}.creator-fields>label{font-weight:600;margin-top:26px}.creator-fields h2{font-size:18px;margin:27px 0 12px}.gender-options{display:flex;gap:10px;margin:10px 0}.gender-options button{flex:1}.gender-options .selected{background:#453355;border-color:#ad82f3;color:#e8d8ff}.appearance-upload{display:flex;gap:20px;align-items:center}.upload-tile{cursor:pointer;margin:0;width:180px;min-height:105px;border:1px solid #806295;border-radius:12px;background:linear-gradient(120deg,#372542,#282031);display:flex;flex-direction:column;justify-content:center;align-items:center;gap:10px;position:relative;overflow:hidden}.upload-tile>span{font-size:25px}.upload-tile input{position:absolute;inset:0;opacity:0;cursor:pointer}.information-card{background:#1d1d28;padding:24px;border:1px solid #2e2b3b;border-radius:14px}.information-card label{font-weight:600}.information-card input,.information-card textarea{background:#2a2935;border-color:#383441}.information-card textarea{min-height:130px}.field-help{color:#9c95ab;font-size:12px;line-height:1.7;margin:5px 0 12px}.permission-box{display:flex;justify-content:space-between;gap:15px;padding:17px;border:1px solid #66527e;border-radius:10px}.lore-picker{background:#20202b;border:1px solid #3b344c;border-radius:12px;padding:17px}.lore-toggle{display:flex;justify-content:space-between;width:100%;padding:0;color:#e0d3f4;text-align:left}.lore-toggle span{color:#ba9af0;font-size:12px}#attached-lore{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}.lore-option{display:flex;gap:12px;align-items:flex-start;padding:13px 0;border-top:1px solid #393144}.lore-option input{width:16px;margin-top:3px;accent-color:#bb9cf7}.lore-option small{display:block;line-height:1.7;color:#9991a9;margin-top:6px}.creator-actions{display:flex;justify-content:flex-end;gap:14px;margin-top:30px}.character-preview{position:sticky;top:30px;background:#20202a;border:1px solid #383143;border-radius:18px;padding:22px}.character-preview #portrait-preview{height:340px;width:100%;border:0;overflow:hidden;background:linear-gradient(160deg,#35303d,#15151d);margin:20px 0}.character-preview #portrait-preview img{height:100%;width:100%;object-fit:cover;border:0;border-radius:14px}.preview-silhouette{font-size:210px;color:#5b506766}.character-preview h2{font-size:22px}.character-preview p{font-size:12px;line-height:1.8;color:#b4a9c5;overflow-wrap:anywhere}.world-art{width:100%}.world-art:hover{filter:brightness(1.15)}@media(max-width:1000px){.creator-layout{grid-template-columns:minmax(0,1fr) 220px;gap:20px}.character-preview{padding:15px}.character-preview #portrait-preview{height:250px}}@media(max-width:750px){.creator-layout{display:flex;flex-direction:column}.creator-fields{width:100%}.character-preview{position:static;width:100%;order:-1}.character-preview #portrait-preview{height:180px}.portrait-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.portrait-cover{height:300px}.gallery-tools select{width:110px}.information-card{padding:18px}}@media(max-width:400px){.portrait-grid{grid-template-columns:1fr}.appearance-upload{gap:10px}.upload-tile{width:140px}}
.persona-portrait{width:104px;height:104px;object-fit:cover;border-radius:14px;border:1px solid #66517e;display:block}.persona-card>.persona-portrait{float:left;margin:0 22px 14px 0}.persona-card{display:flow-root}.persona-details{color:#cbb5ff!important}.identity-fields{display:grid;grid-template-columns:1fr 1fr;gap:15px}.portrait-editor{display:flex;gap:18px;align-items:center}.portrait-editor>div:last-child{flex:1;min-width:0}#portrait-preview{width:104px;min-height:104px;flex-shrink:0;display:grid;place-items:center;border:1px dashed #554663;border-radius:14px;text-align:center}.portrait-editor input{padding:8px;font-size:11px}#image-status:empty{display:none}@media(max-width:450px){.identity-fields{grid-template-columns:1fr}.portrait-editor{align-items:flex-start}.persona-card>.persona-portrait{float:none;margin-bottom:18px}}
:root{color-scheme:dark;--bg:#101119;--panel:#171923;--line:#2b2c3b;--muted:#9699ac;--text:#efeff6;--accent:#b6a0ff}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font:14px 'DM Sans',sans-serif}button,input,textarea,select{font:inherit}button,a,input,textarea,select{outline-offset:4px}button{cursor:pointer;border:0;color:inherit;background:none}a{color:inherit;text-decoration:none}.app{display:flex;min-height:100vh}.sidebar{width:250px;flex-shrink:0;padding:32px 22px;border-right:1px solid var(--line);display:flex;flex-direction:column;position:sticky;top:0;height:100vh;background:#12131c}.brand{font:800 25px Manrope,sans-serif;letter-spacing:-1px;display:flex;gap:10px;align-items:center}.prism{color:#c6adff;font-size:37px}.edition{font-size:8px;letter-spacing:2px;color:var(--muted);margin:8px 0 32px 3px}.primary{background:#b9a3ff;color:#211438;border-radius:9px;padding:13px 20px;font-weight:700}.primary:hover{background:#cbbaff}.new-story{width:100%;text-align:left;margin-bottom:34px}.nav-label,.eyebrow{font-size:10px;letter-spacing:2px;color:var(--muted);font-weight:700}.nav-label{padding-left:13px;margin-bottom:12px}nav button{width:100%;display:flex;gap:14px;align-items:center;text-align:left;padding:14px 12px;color:var(--muted);border-radius:8px;margin-bottom:5px}nav button.active{background:#282337;color:#cbb5ff}.sidebar-bottom{margin-top:auto}.private-card{padding:17px 12px;border:1px solid var(--line);border-radius:10px;font-size:12px}.private-card p{font-size:11px;color:var(--muted);line-height:1.8;margin-bottom:0}.status-dot{display:inline-block;width:6px;height:6px;background:#9ac7ae;border-radius:50%;margin-right:7px}.settings-btn{font-size:11px;color:var(--muted);padding:22px 0}.version{display:block;font-size:8px;letter-spacing:1.5px;color:#686c80}main{flex:1;min-width:0}header{height:80px;border-bottom:1px solid var(--line);padding:0 44px;display:flex;align-items:center;justify-content:space-between;font-size:12px;color:var(--muted)}.header-right{display:flex;align-items:center;gap:22px}#engine-badge{font-size:9px;letter-spacing:1px;border:1px solid #524533;background:#29251f;color:#d2bd91;border-radius:5px;padding:6px 10px}.avatar{border:1px solid #4a405f;background:#2d253c;color:#d8c3ff;width:34px;height:34px;display:grid;place-items:center;border-radius:50%;font-size:9px}#content{padding:40px 44px;max-width:1500px;margin:auto}h1,h2,h3{font-family:Manrope,sans-serif}h1{font-size:36px;letter-spacing:-1.5px;font-weight:600;margin:12px 0}h2{font-size:22px;font-weight:600;letter-spacing:-.5px}h3{font-size:18px;margin:9px 0}.subtitle{color:var(--muted);line-height:1.8;max-width:640px}.hero{position:relative;overflow:hidden;min-height:290px;border:1px solid #4b415f;border-radius:15px;margin-top:28px;padding:32px;background:radial-gradient(ellipse at 90% 0%,#54426155,transparent 60%),linear-gradient(115deg,#252333,#202333 50%,#393342)}.hero-text{position:relative;z-index:1;max-width:65%}.hero h2{font-size:34px;line-height:1.2;margin:15px 0}.hero p{color:#bdb8cd;line-height:1.8;max-width:390px}.tag{font-size:9px;letter-spacing:1px;border:1px solid #67607066;padding:5px 8px;border-radius:5px;display:inline-block;margin-right:5px;color:#d0c6e1}.hero-art{position:absolute;right:4%;bottom:0;width:32%;height:100%;opacity:.6;display:flex;align-items:flex-end;gap:7px;transform:perspective(700px) rotateY(-15deg)}.tower{background:linear-gradient(90deg,#292838,#676077);border:1px solid #a89bb74d;flex:1;height:60%;position:relative;box-shadow:15px 0 40px #0006}.tower:nth-child(2){height:85%;clip-path:polygon(0 18%,50% 0,100% 18%,100% 100%,0 100%)}.tower:nth-child(3){height:70%}.tower:after{content:'';position:absolute;inset:35% 18% 0;background:repeating-linear-gradient(0deg,transparent 0 22px,#d5b89066 23px 29px);opacity:.6}.section-heading{display:flex;justify-content:space-between;align-items:center;margin:32px 0 18px}.section-heading h2{margin:0;font-size:18px}.small{font-size:12px;color:var(--muted)}.world-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.world-card{border:1px solid var(--line);border-radius:12px;overflow:hidden;background:var(--panel)}.world-art{height:135px;position:relative;overflow:hidden;display:grid;place-items:center}.world-art span{font-family:serif;font-size:78px;opacity:.35;text-shadow:0 0 40px currentColor}.college{background:radial-gradient(ellipse at 70% 20%,#b3896c55,transparent),linear-gradient(135deg,#29393e,#3c3048);color:#e8d4b8}.mafia{background:radial-gradient(ellipse at 70% 40%,#99473555,transparent),linear-gradient(135deg,#30212c,#191b29);color:#d9a79b}.werewolf{background:radial-gradient(circle at 70% 25%,#c1c8c744,transparent 27%),linear-gradient(135deg,#263c39,#15212a);color:#bddec8}.world-body{padding:20px}.world-body p{color:var(--muted);font-size:12px;line-height:1.7;min-height:40px}.card-bottom{display:flex;align-items:center;justify-content:space-between;border-top:1px solid var(--line);padding-top:15px;margin-top:19px}.text-button{color:#c6adff;font-size:12px;font-weight:600}.secondary{border:1px solid var(--line);border-radius:8px;padding:10px 15px;color:#cfcbdc;background:#20212e}.secondary:hover{border-color:#9d85d9}.notice{padding:15px 18px;border:1px solid #494130;background:#29251d66;color:#c8ba9c;border-radius:9px;font-size:12px;line-height:1.7;margin:20px 0}.character-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:18px}.character{padding:25px;border:1px solid var(--line);border-radius:12px;background:var(--panel)}.character p{color:var(--muted);line-height:1.8}.initials{height:45px;width:45px;border-radius:12px;background:#383048;display:grid;place-items:center;color:#d0b8ff;font:600 18px Manrope}.row{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.spread{justify-content:space-between}.persona-card{border:1px solid #594770;background:linear-gradient(110deg,#282033,#1b1c29);padding:24px;border-radius:12px;margin:25px 0}.persona-card p{color:var(--muted);line-height:1.7}.story-item{padding:22px;background:var(--panel);border:1px solid var(--line);border-radius:12px;margin:15px 0}.story-item h3{margin-top:0}.chat-layout{display:grid;grid-template-columns:minmax(0,1fr) 245px;gap:24px}.chat-main{min-width:0}.chat-head{display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid var(--line);padding-bottom:20px}.chat-head h2{margin:7px 0}.transcript{min-height:250px;max-height:53vh;overflow-y:auto;padding:25px 6px;scroll-behavior:smooth}.message{margin-bottom:25px;line-height:1.9;white-space:pre-wrap;color:#d3d0df}.message .speaker{font-size:10px;font-weight:700;letter-spacing:1.5px;display:block;margin-bottom:7px;color:#bda7ed}.message.user{background:#252235;border:1px solid #3e3455;border-radius:10px;padding:17px 20px;margin-left:8%}.message.user .speaker{color:#a4b8d6}.composer{padding:15px;border:1px solid #514466;border-radius:12px;background:#1c1b29}.composer textarea{border:0;background:none;resize:vertical;min-height:65px;margin:0}.composer-footer{display:flex;justify-content:space-between;align-items:center;gap:12px}.chat-side{border-left:1px solid var(--line);padding-left:23px}.chat-side h3{font-size:14px;margin:20px 0 12px}.cast-mini{padding:12px 0;border-bottom:1px solid var(--line)}.cast-mini b{display:block;margin-bottom:5px}.cast-mini span{font-size:11px;color:var(--muted);line-height:1.6}.chat-side textarea{font-size:12px;min-height:150px}.settings-panel{max-width:720px;background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:26px;margin-top:25px}label{display:block;color:#c8c4d6;font-size:12px;margin:18px 0 8px}input,textarea,select{width:100%;border:1px solid #393747;background:#11121b;color:var(--text);border-radius:7px;padding:12px}textarea{resize:vertical;min-height:90px;line-height:1.6}select{margin-bottom:15px}dialog{max-width:570px;width:calc(100% - 32px);max-height:90vh;background:#1b1b28;border:1px solid #554663;border-radius:15px;color:var(--text);padding:26px}dialog::backdrop{background:#06070cd9;backdrop-filter:blur(5px)}.dialog-top,.dialog-actions{display:flex;align-items:center;justify-content:space-between;gap:12px}.dialog-top h2{margin:0}.dialog-top .close{font-size:27px;color:var(--muted)}.dialog-actions{justify-content:flex-end;margin-top:24px}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:#e1d5ff;color:#231937;padding:12px 22px;border-radius:9px;display:none;z-index:10;max-width:90%;box-shadow:0 8px 40px #0007}button:disabled{opacity:.5;cursor:wait}.empty{padding:50px;text-align:center;color:var(--muted)}.field-pair{display:grid;grid-template-columns:1fr 100px;gap:15px}.danger{color:#e4a7a7}.divider{border:0;border-top:1px solid var(--line);margin:25px 0}code{font-size:12px;color:#d6c1ff}#connection-result{line-height:1.7;color:var(--muted)}@media(min-width:1450px){#content{padding-top:50px}.hero{min-height:330px}.world-art{height:175px}}@media(max-width:1050px){.sidebar{width:210px;padding:25px 16px}#content{padding:30px 25px}header{padding:0 25px}.world-grid{grid-template-columns:1fr}.world-card{display:grid;grid-template-columns:180px 1fr}.world-art{height:100%}.chat-layout{grid-template-columns:1fr}.chat-side{border-left:0;border-top:1px solid var(--line);padding:15px 0}.hero-text{max-width:78%}}@media(max-width:650px){.app{display:block}.sidebar{width:100%;height:auto;position:static;padding:16px;border-right:0;border-bottom:1px solid var(--line)}.brand{font-size:22px}.edition,.nav-label,.sidebar-bottom,.sidebar .new-story{display:none}nav{display:flex;margin-top:14px;gap:5px}nav button{font-size:11px;padding:10px;gap:6px;margin:0}header{height:55px;padding:0 18px;font-size:10px}#content{padding:25px 18px}h1{font-size:29px}.hero{padding:24px;min-height:290px}.hero-text{max-width:100%}.hero-art{opacity:.15;width:60%}.hero h2{font-size:29px}.world-card{display:block}.world-art{height:120px}.character-grid{grid-template-columns:1fr}.section-heading{gap:12px}.chat-head{align-items:flex-start;gap:10px}.chat-head .row{gap:6px}.chat-head button{font-size:11px;padding:8px}.composer-footer .small{font-size:10px}.header-right{gap:10px}}

.world-card button.world-art{padding:0;border:0;line-height:0}.world-card .world-art:has(.world-cover-image){background:transparent}.world-card .world-cover-image{display:block;width:100%;height:100%;object-fit:cover}
.save-reminder{position:sticky;top:10px;z-index:8;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:14px 18px;margin:0 0 20px;border:1px solid #c19a52;border-radius:12px;background:#33291e;color:#ffe1ab;box-shadow:0 6px 20px #0005}.save-reminder[hidden]{display:none}.creator-layout>.save-reminder{grid-column:1/-1}.save-reminder button{white-space:nowrap}
.guide-card{max-width:900px;background:#1c1b28;border:1px solid #373342;border-radius:16px;padding:26px;margin:24px 0;line-height:1.8}.guide-definitions{margin:0}.guide-definitions dt{font-weight:700;color:#d9c4ff;margin-top:26px}.guide-definitions dd{margin:8px 0 24px;color:#c3bfce}.guide-example{padding:14px 18px;background:#101018;border-radius:9px;white-space:normal;color:#e0d8ee}.guide-card details{padding:16px 0;border-top:1px solid #373342}.guide-card summary{cursor:pointer;font-weight:600}.story-narrator{color:#c6b4f2;background:#a889ee12;border-radius:5px;padding:2px 4px;font-style:normal}
.story-mode .story-composer .composer-persona{position:relative;flex:0 0 44px;width:44px;height:44px;padding:0;border:2px solid #bc9ee5;border-radius:50%;background:#302139;display:grid;place-items:center;color:#e7d6ff;font-size:20px}.composer-persona>img{width:100%;height:100%;object-fit:cover;border-radius:50%}.composer-persona .persona-chevron{position:absolute;bottom:-5px;right:-5px;font-size:12px;background:#302139;border-radius:50%;width:18px;height:18px}.story-cast-chips>button{display:flex;align-items:center;gap:7px;border:1px solid #79677c;background:#17101d;color:#bbacbf;border-radius:24px;padding:5px 10px;font-size:11px}.story-cast-chips>button[aria-pressed=true]{border-color:#c9a2ed;background:#4d345d;color:#fff;box-shadow:0 0 0 1px #c9a2ed33}.story-cast-chips>.recipient-label{border:0;background:none;padding:8px 3px}.recipient-avatar{width:24px;height:24px;border-radius:50%;overflow:hidden;display:grid;place-items:center;background:#3c294b}.recipient-avatar img{width:100%;height:100%;object-fit:cover}.message-recipients{display:block;font-size:10px;color:#b9a5ca;margin-top:10px}#story-persona-picker{width:min(540px,92vw);max-height:80dvh;overflow-y:auto;padding:25px;border:1px solid #51425f;border-radius:20px;background:#201e2a;color:#eee8f5}#story-persona-picker::backdrop{background:#0009}.story-persona-choices{display:grid;gap:12px;margin:20px 0}.story-persona-choice{display:flex;align-items:center;gap:14px;width:100%;text-align:left;padding:14px;border:1px solid transparent;border-radius:14px;background:#2d2a38;color:#eee8f5}.story-persona-choice[aria-pressed=true]{border-color:#d0b1f0;background:#3b2d49}.picker-portrait{width:62px;height:62px;flex-shrink:0;overflow:hidden;border-radius:12px;background:#4e3c5d;display:grid;place-items:center;font-size:24px}.picker-portrait img{width:100%;height:100%;object-fit:cover}.story-persona-choice>span:nth-child(2){min-width:0;flex:1}.story-persona-choice b{font-size:16px}.story-persona-choice small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#bfb1cc;margin-top:6px}@media(max-width:650px){.story-mode .story-composer{gap:7px;padding:9px}.story-mode .story-composer .composer-persona{width:35px;height:35px;flex-basis:35px}.story-cast-chips{flex-wrap:nowrap;overflow-x:auto;padding-bottom:4px}.story-cast-chips>button{flex-shrink:0}}
.world-art.pirate,.portrait-cover.pirate{background:radial-gradient(ellipse at 65% 15%,#d4ab6555,transparent 50%),linear-gradient(150deg,#163e55,#071b2a 70%,#153c47)}.world-art.historical-romance,.portrait-cover.historical-romance{background:radial-gradient(ellipse at 30% 20%,#edc6a455,transparent 55%),linear-gradient(145deg,#593748,#282133 70%,#423145)}.world-art.cyberpunk,.portrait-cover.cyberpunk{background:linear-gradient(125deg,#07383f,#18192f 45%,#491b5144),repeating-linear-gradient(90deg,#32dedc33 0 2px,transparent 2px 40px)}.world-art.pirate>span,.world-art.historical-romance>span,.world-art.cyberpunk>span{font-size:86px;text-shadow:0 4px 25px #0006}.story-stage.pirate{background:radial-gradient(ellipse at top,#1b3c4b,#0d111c 80%)}.story-stage.historical-romance{background:radial-gradient(ellipse at top,#49303d,#15101c 80%)}.story-stage.cyberpunk{background:radial-gradient(ellipse at top left,#10383b,transparent 70%),radial-gradient(ellipse at bottom right,#3b1746,#10101b 80%)}
.compact-lore-picker{border:1px solid #454052;border-radius:14px;background:#191822;overflow:hidden}.compact-lore-picker .lore-toggle{width:100%;display:flex;justify-content:space-between;gap:12px;padding:17px 18px;background:#282334;color:#eee4fa;text-align:left}.compact-lore-picker #attached-lore{display:flex;flex-wrap:wrap;gap:7px;padding:12px 16px;margin:0}.attached-lore-chip{display:flex;align-items:center;gap:10px;padding:7px 10px;border:1px solid #8c71af;border-radius:18px;background:#392d49;color:#e6d9fa;font-size:11px}.compact-lore-picker #lore-options{padding:0 12px 12px}.compact-lore-picker #lore-options[hidden]{display:none}.lore-search-bar{display:flex;gap:8px;align-items:center;padding:8px 0 12px}.lore-search-bar input{margin:0;min-width:0;flex:1}.lore-search-bar button{padding:10px 14px}.lore-option-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-height:340px;overflow-y:auto;padding:2px 5px 2px 0;scrollbar-width:thin}.lore-option-grid .lore-choice{display:flex;align-items:center;gap:10px;margin:0;padding:12px 10px;border:1px solid #393442;border-radius:10px;background:#24212e;cursor:pointer;min-width:0;min-height:72px}.lore-option-grid .lore-choice[hidden]{display:none}.lore-choice:has(input:checked){border-color:#b18bdf;background:#3c2e4b}.lore-choice:focus-within{outline:2px solid #d9b7ff;outline-offset:-2px}.lore-choice input{width:15px;height:15px;flex:0 0 15px;margin:0;accent-color:#c19bea}.lore-choice-icon{font-size:23px;width:25px;flex:0 0 25px;text-align:center;color:#c9b2e0}.lore-choice-text{min-width:0}.lore-choice-text b{display:block;font-size:12px;line-height:1.4;overflow-wrap:anywhere}.lore-choice-text small{display:block;color:#b9a5cc;font-size:11px;margin-top:5px;line-height:1.3}@media(max-width:500px){.lore-option-grid{grid-template-columns:1fr;max-height:310px}}
#story-persona-picker{box-sizing:border-box;overflow-x:hidden}.story-persona-choices,.story-persona-choice{min-width:0;max-width:100%;box-sizing:border-box}.story-persona-choice>span:nth-child(2){overflow:hidden}.story-persona-choice b{display:block;overflow-wrap:anywhere}.story-persona-choice small{white-space:normal;overflow-wrap:anywhere}
.add-story-cast{margin:18px 0;padding:13px;border:1px solid #4a3b54;border-radius:12px;background:#211927}.add-story-cast label{font-size:12px;margin:0 0 9px;display:block;color:#d5c1e3}.add-story-cast input{width:100%;box-sizing:border-box;margin:0;font-size:12px;min-width:0}.add-story-cast>button{width:100%;font-size:12px;margin-top:10px;padding:9px}.add-story-cast #cast-id-result{font-size:11px;color:#b7a5c2;overflow-wrap:anywhere;margin-top:9px}.cast-match-preview{display:flex;align-items:center;gap:8px}.cast-match-preview img{width:34px;height:34px;object-fit:cover;border-radius:50%}.cast-match-preview b,.cast-match-preview small{display:block}.cast-match-preview small{margin-top:4px}
.story-mode .story-composer textarea#message{height:130px;min-height:130px;max-height:240px;resize:vertical;overflow-y:auto}.story-mode .story-composer{align-items:flex-end}.story-mode .story-composer .composer-persona,.story-mode .story-composer .narration-button,.story-mode .story-composer .story-send{margin-bottom:5px}@media(max-width:650px){.story-mode .story-composer textarea#message{height:100px;min-height:100px;max-height:180px}}
.story-cast-person .remove-story-cast{font-size:11px;color:#d6b3ca;padding:4px 0;margin:0 0 5px;text-align:left}.story-cast-person .remove-story-cast:hover{color:#ffc6dc;text-decoration:underline}
.persona-grid:has(.redesigned-persona-card){display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,320px),1fr));gap:20px;align-items:stretch}.persona-grid .redesigned-persona-card{min-width:0;max-width:100%;margin:0;padding:0;overflow:hidden;display:flex;flex-direction:column;border-radius:18px;background:#1d1a28}.redesigned-persona-card .persona-card-image{position:relative;aspect-ratio:1/1;width:100%;background:#292234;display:grid;place-items:center;overflow:hidden}.redesigned-persona-card .persona-card-image>img{width:100%;height:100%;object-fit:cover;object-position:center 25%;border:0;border-radius:0;float:none;margin:0;max-width:none}.persona-card-image>span{font-size:80px;color:#bba0d8}.persona-adjust{position:absolute;bottom:12px;right:12px;border:1px solid #b39acb99;border-radius:20px;padding:8px 12px;background:#181120dd;color:#f0e1ff;font-size:11px}.persona-card-content{padding:20px;display:flex;flex-direction:column;flex:1;min-width:0}.persona-card-content h3{margin:10px 0;font-size:22px;overflow-wrap:anywhere}.persona-status{font-size:10px;text-transform:uppercase;letter-spacing:1.5px;color:#b39acb}.selected-persona .persona-status{color:#d8bdff}.persona-nametag{align-self:flex-start;background:#3e2d50;color:#e0c5f8;padding:5px 10px;border-radius:15px;font-size:12px}.redesigned-persona-card .persona-description-preview{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;font-size:12px;line-height:1.7;margin:0 0 20px}.persona-card-actions{display:flex;align-items:center;gap:18px;margin-top:auto}.persona-card-actions .danger{margin-left:auto}.profile-crop-mode .portrait-crop-stage,.profile-crop-mode #portrait-canvas{border-radius:12px;clip-path:none;mask-image:none}.profile-crop-mode .portrait-crop-stage::after{display:none}
#editor .portrait-editor #portrait-preview.adjustable-persona-image{cursor:pointer;overflow:visible;height:auto;min-height:120px;display:flex;flex-direction:column;align-items:center;gap:8px;border:0;background:none;flex-shrink:0}#editor .adjustable-persona-image .persona-portrait{width:120px;height:120px;object-fit:cover;border-radius:14px;margin:0;float:none;object-position:center}#editor .portrait-adjust-hint{display:block;color:#d5b9f4;font-size:11px;text-align:center;line-height:1.4}#editor .adjustable-persona-image:hover .portrait-adjust-hint{text-decoration:underline}#editor .adjustable-persona-image:focus-visible{outline:2px solid #c5a0ec;outline-offset:5px;border-radius:14px}
.world-art.motorcycle-club,.portrait-cover.motorcycle-club{background:radial-gradient(ellipse at 70% 20%,#c47a3a55,transparent 55%),linear-gradient(145deg,#3b3030,#17191e 70%,#30241b);color:#e3b890}.world-art.furry,.portrait-cover.furry{background:radial-gradient(ellipse at 25% 20%,#dbab8266,transparent 50%),linear-gradient(145deg,#4c4057,#253b3a 70%,#1f293c);color:#ead7bd}.world-art.motorcycle-club>span,.world-art.furry>span{font-size:86px;text-shadow:0 4px 25px #0006}.story-stage.motorcycle-club{background:radial-gradient(ellipse at top,#43302b,#111017 80%)}.story-stage.furry{background:radial-gradient(ellipse at top,#3c354b,#11151c 80%)}
.ensemble-editor{padding:20px;border:1px solid #514061;border-radius:13px;background:#221c2d;margin:24px 0}.ensemble-switch{display:flex;align-items:center;gap:10px;line-height:1.6}.ensemble-switch input{width:auto}.ensemble-member{border:1px solid #4c4058;border-radius:10px;padding:16px;margin:15px 0;background:#191620}.ensemble-member h3{margin:0;font-size:14px}.ensemble-member .field-pair{grid-template-columns:minmax(0,1fr) 95px}.prism-helper-avatar{position:relative;flex:0 0 38px;width:38px;height:42px;border:1px solid #c8a5ff;border-radius:12px;background:linear-gradient(140deg,#8d65cb,#335b8c);color:#fff;box-shadow:0 0 15px #a27be644;padding:0;display:grid;place-items:center}.prism-helper-avatar>span{font-size:31px;line-height:1}.prism-helper-avatar>i{position:absolute;left:12px;top:13px;font-size:10px;font-style:normal;letter-spacing:2px;color:#17112a}.story-cast-chips>.inner-thought-button{border-color:#766087;color:#e3cfff;margin-right:auto}#prism-assistant{width:min(650px,94vw);box-sizing:border-box}#prism-assistant textarea{min-height:140px;box-sizing:border-box}#prism-draft{min-height:230px!important;max-height:45dvh}#prism-assistant #prism-generate{margin-top:14px}.private-thoughts{white-space:pre-wrap;line-height:1.9;max-height:45dvh;overflow:auto;padding:18px;border:1px solid #514061;background:#141019;border-radius:12px}.private-thoughts .story-narration{color:#c6b4d8}@media(max-width:650px){.story-mode .story-composer{flex-wrap:wrap}.story-mode .story-composer textarea#message{flex-basis:calc(100% - 60px)}.story-mode .story-composer .prism-helper-avatar{margin-left:auto}.ensemble-editor{padding:12px}}
.world-art.shifter,.portrait-cover.shifter{background:radial-gradient(ellipse at 75% 20%,#b3a0cc55,transparent 50%),linear-gradient(140deg,#32473e,#22263b 65%,#3c2d49);color:#dac8e8}.story-stage.shifter{background:radial-gradient(ellipse at top,#343b43,#13131f 80%)}
.world-carousel{margin:30px 0 35px;border:1px solid #4a3b59;border-radius:22px;overflow:hidden;background:#191420;box-shadow:0 16px 45px #0002}.world-slide-scene{position:relative;min-height:420px;isolation:isolate;background:#292133;overflow:hidden}.world-slide-art{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center 45%;z-index:-3;animation:world-art-reveal .4s ease}.world-slide-fallback{position:absolute;inset:0;display:grid;place-items:center;font-size:170px;opacity:.3;z-index:-3}.world-slide-shade{position:absolute;inset:0;z-index:-1;background:linear-gradient(90deg,#110e1bf5 0%,#110e1bd9 28%,#110e1b80 52%,#110e1b05 85%),linear-gradient(0deg,#110e1b70,transparent 45%)}.world-slide-copy{padding:52px 44px;max-width:570px;min-height:420px;box-sizing:border-box;display:flex;flex-direction:column;align-items:flex-start;justify-content:center}.world-slide-kicker{font-size:9px;letter-spacing:2px;color:#d3bddf;font-weight:700;display:flex;flex-wrap:wrap;align-items:center;gap:12px}.world-slide-kicker span{border:1px solid #ddc4ef55;border-radius:18px;padding:6px 10px;letter-spacing:.5px;color:#f1deff;background:#22172b66}.world-slide-copy h2{font-size:clamp(30px,3.2vw,49px);line-height:1.1;letter-spacing:-1.5px;margin:22px 0 16px;color:#fff;text-wrap:balance}.world-slide-copy p{font-size:14px;color:#e1d5e7;line-height:1.8;margin:0 0 25px;max-width:440px}.world-slide-copy .primary{padding:14px 21px}.world-carousel-controls{display:flex;justify-content:space-between;gap:18px;align-items:center;padding:14px 20px;background:#1b1723;border-top:1px solid #44344e}.world-carousel-arrows{display:flex;align-items:center;gap:16px;flex-shrink:0}.world-carousel-arrows button{padding:8px 14px;font-size:18px}.world-carousel-controls select{width:auto;max-width:55%;margin:0;background:#282030;border-color:#51405f;font-size:12px;padding:10px 32px 10px 12px}.world-carousel:focus-visible{outline:2px solid #c5a6f4;outline-offset:4px}@keyframes world-art-reveal{from{opacity:.35}to{opacity:1}}@media(prefers-reduced-motion:reduce){.world-slide-art{animation:none}}@media(max-width:650px){.world-slide-scene{min-height:410px}.world-slide-copy{min-height:410px;max-width:100%;padding:95px 25px 28px;justify-content:flex-end}.world-slide-shade{background:linear-gradient(0deg,#110e1bf5 0%,#110e1bd9 36%,#110e1b40 80%)}.world-slide-art{object-position:65% center}.world-slide-copy h2{font-size:34px;margin-top:16px}.world-slide-copy p{font-size:12px;margin-bottom:18px}.world-slide-kicker{font-size:8px;gap:7px}.world-carousel-controls{padding:12px;gap:10px}.world-carousel-arrows{gap:9px}.world-carousel-controls select{max-width:58%;min-width:0;font-size:11px}.world-carousel{border-radius:16px;margin-top:22px}}
.world-art.angels-demons,.portrait-cover.angels-demons{background:linear-gradient(110deg,#b89a6455,#252033 48%,#652c3444);color:#eddbb8}.story-stage.angels-demons{background:radial-gradient(ellipse at top left,#443849,transparent 70%),radial-gradient(ellipse at bottom right,#4b252c,#14111c 80%)}
.gallery-tools #character-search{min-width:0}.gallery-tools #gallery-gender{width:165px;flex-shrink:0}.gallery-tools #gallery-sort{flex-shrink:0}@media(max-width:750px){.gallery-tools{flex-wrap:wrap}.gallery-tools #character-search{flex-basis:100%;width:100%}.gallery-tools #gallery-gender,.gallery-tools #gallery-sort{flex:1;width:auto;min-width:120px}}
.ensemble-id-picker{border:1px solid #665077;background:#191520;padding:16px;border-radius:12px;margin:18px 0}.ensemble-id-picker label{margin-top:0}.ensemble-id-picker .row{flex-wrap:nowrap}.ensemble-id-picker input{min-width:0;flex:1}.ensemble-id-picker button{white-space:nowrap}.ensemble-id-picker #ensemble-id-match{margin-top:10px;color:#d4b9f2}
.story-emphasis,.story-emphasis em{font-weight:700;font-style:italic}.story-message-text .story-emphasis{color:inherit}
.story-bubble[data-message-index]{cursor:pointer}.story-bubble[data-message-index]:focus-visible{outline:2px solid #c4a3f0;outline-offset:4px}.message-action-preview{max-height:110px;overflow:auto;white-space:pre-wrap;font-size:12px;line-height:1.7;color:#b9a9c5;background:#13101b;border-radius:10px;padding:14px}.message-action-buttons{display:grid;gap:10px;margin:18px 0}.message-action-buttons>button{text-align:left;padding:16px}.message-action-buttons small{display:block;color:#afa0bd;font-size:11px;margin-top:7px;font-weight:400}#message-actions textarea{min-height:170px}#message-actions p{line-height:1.7}



.chat-loading-spinner {
  display: inline-block;
  width: 0.8em;
  height: 0.8em;
  box-sizing: border-box;
  border: 2px solid #786482;
  border-top-color: #ead4f5;
  border-radius: 50%;
  vertical-align: -0.05em;
  animation: chat-loading-spin 0.8s linear infinite;
}
@keyframes chat-loading-spin { to { transform: rotate(1turn); } }
@media (prefers-reduced-motion: reduce) {
  .chat-loading-spinner { animation: none; }
}

.story-reply-loading { display: flex; align-items: center; gap: 12px; width: fit-content; max-width: 100%; margin: 12px 0 18px; padding: 12px 16px; border: 1px solid #6a507e; border-radius: 12px; background: #2b2035; color: #ead4f5; font-size: 14px; }
.story-reply-loading .chat-loading-spinner { flex: 0 0 18px; width: 18px; height: 18px; }

#private-scene { width: auto; max-width: 45%; margin: 0 8px; padding: 7px 9px; font-size: 12px; }
#message-actions.message-context-menu {
  position: fixed;
  inset: var(--message-menu-top, 12px) auto auto var(--message-menu-left, 12px);
  margin: 0;
  width: min(190px, calc(100vw - 24px));
  box-sizing: border-box;
  padding: 8px;
  border: 1px solid #4e4353;
  border-radius: 14px;
  background: #17131a;
}
#message-actions.message-context-menu::backdrop { background: transparent; backdrop-filter: none; }
.message-context-menu .message-action-buttons { display: grid; gap: 2px; }
.message-context-menu button { padding: 11px 12px; text-align: left; background: transparent; border-radius: 8px; color: inherit; }
.message-context-menu button:hover, .message-context-menu button:focus-visible { background: #33283c; }
.message-context-menu #message-action-status:empty { display: none; }

.story-mode .story-composer .story-composer-controls {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.story-mode .story-composer-controls > button {
  flex: 0 0 auto;
  margin: 0;
}
@media (max-width: 650px) {
  .story-mode .story-composer { flex-wrap: nowrap; }
  .story-mode .story-composer textarea#message { flex: 1 1 0; min-width: 0; }
}

.settings-btn[hidden] { display: none; }

.account-photo { width: 64px; height: 64px; flex: 0 0 64px; border-radius: 50%; background: #38294b; display: grid; place-items: center; overflow: hidden; }
.account-photo img { width: 100%; height: 100%; object-fit: cover; }
.account-folder-tabs { display:flex; flex-wrap:wrap; gap:6px; border-bottom:1px solid #786194; margin-top:18px; }
.account-folder-tabs button { border:1px solid #554566; border-bottom:0; border-radius:12px 12px 0 0; padding:11px 20px; background:#251d30; color:#e6dbf4; }
.account-folder-tabs button[aria-pressed=true] { background:#bba0fa; color:#1c1426; }
.character-feedback { width:min(620px, 94vw); max-height:85dvh; overflow:auto; box-sizing:border-box; }
.feedback-messages { max-height:36dvh; overflow:auto; margin:12px 0; }
.feedback-messages article { padding:12px 0; border-bottom:1px solid #514061; }
.feedback-messages p { white-space:pre-wrap; overflow-wrap:anywhere; }
.space-header { padding: 8px 0 0; margin-bottom: 24px; background: radial-gradient(ellipse at 48% 30%, #2d1e413d, transparent 72%); }
.space-header h1 { margin: 0 0 22px; font-size: clamp(2rem, 4vw, 3rem); }
.space-profile-row { gap: 22px; align-items: center; }
.space-profile-info h2 { margin: 6px 0 2px; }
.space-profile-info p { margin: 0; color: #beb1cd; overflow-wrap: anywhere; }
.space-private-badge { display: inline-block; padding: 4px 10px; border: 1px solid #544564; border-radius: 20px; color: #d6c2ee; font-size: 12px; }
.space-avatar-control { position: relative; flex: none; }
.space-avatar-control .account-photo { width: clamp(74px, 10vw, 120px); height: clamp(74px, 10vw, 120px); box-sizing: border-box; border: 3px solid #c7a8f2; font-size: 32px; }
.space-photo-edit { position: absolute; right: 0; bottom: 0; display: grid; place-items: center; width: 34px; height: 34px; margin: 0; border-radius: 50%; background: #d6baf9; color: #20162b; cursor: pointer; }
.space-avatar-control:focus-within .space-photo-edit { outline: 2px solid white; outline-offset: 2px; }
.space-sign-out { margin-left: auto; }
.space-folder-tabs { gap: 8px; margin-top: 24px; }
.space-folder-tabs button { display: flex; align-items: center; gap: 10px; padding: 12px clamp(10px, 2vw, 28px); }
.space-folder-icon { position: relative; width: 17px; height: 12px; border: 1.5px solid currentColor; border-radius: 2px; }
.space-folder-icon::before { content: ''; position: absolute; top: -5px; left: -1.5px; width: 8px; height: 4px; border: 1.5px solid currentColor; border-bottom: 0; border-radius: 2px 2px 0 0; }
.space-character-heading h2, .space-character-heading p { margin: 0; }
.space-character-heading p { margin-top: 4px; }
.space-character-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px; }
.space-character-card { min-width: 0; border: 1px solid #544564; border-radius: 14px; background: #231e2e; }
.space-character-art { display: grid; place-items: center; padding: 0; width: 100%; aspect-ratio: 1.6; overflow: hidden; border-radius: 13px 13px 0 0; background: radial-gradient(at top, #523766, #21182d); color: #ddc7f5; font-size: 42px; }
.space-character-art img { width: 100%; height: 100%; min-height: 0; object-fit: cover; object-position: center top; }
.space-card-caption { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; }
.space-card-caption h3, .space-card-caption p { margin: 0; overflow-wrap: anywhere; }
.space-card-actions { position: relative; flex: none; }
.space-card-actions summary { display: grid; place-items: center; width: 32px; height: 32px; cursor: pointer; list-style: none; font-size: 22px; }
.space-card-actions summary::-webkit-details-marker { display: none; }
.space-card-actions > div { position: absolute; z-index: 2; right: 0; width: max-content; padding: 6px; border: 1px solid #645277; border-radius: 10px; background: #21192a; box-shadow: 0 8px 22px #100b19aa; }
.space-card-actions button { display: block; width: 100%; padding: 8px 10px; text-align: left; }
.character-detail-layout { display:grid; grid-template-columns:minmax(150px, .9fr) minmax(200px, .9fr) minmax(300px, 1.6fr); align-items:start; gap:24px; margin-top:20px; }
.character-detail-art { aspect-ratio: 3/5; display:grid; place-items:center; overflow:hidden; border-radius:16px; background:#292033; font-size:48px; }
.character-detail-art img { width:100%; height:100%; min-height:0; object-fit:cover; }
.character-detail-info h1,.character-feedback-panel h2 { margin-top:0; }
.character-detail-intro { line-height:1.65; overflow-wrap:anywhere; margin:18px 0; }
.character-feedback-panel { min-width:0; padding:20px; border:1px solid #544564; border-radius:14px; background:linear-gradient(145deg,#292132,#1a1622); }
.character-feedback-panel form { border:1px solid #514061; border-radius:10px; padding:12px; }
.character-feedback-panel textarea { min-height:90px; }
@media(max-width:1100px){.character-detail-layout{grid-template-columns:minmax(130px,1fr) minmax(0,2fr)}.character-feedback-panel{grid-column:1/-1}}
@media(max-width:560px){.character-detail-layout{grid-template-columns:minmax(0,1fr)}.character-detail-art{aspect-ratio:4/3}.character-feedback-panel{padding:12px}}
.header-account-controls { display:flex; align-items:center; gap:12px; }
.header-popover { position:relative; }
.header-popover summary { display:flex; align-items:center; gap:7px; padding:4px; cursor:pointer; list-style:none; }
.header-popover summary::-webkit-details-marker { display:none; }
.header-popover-panel { position:absolute; right:0; top:calc(100% + 6px); z-index:40; min-width:170px; padding:12px; border:1px solid #514061; border-radius:10px; background:#231c2d; }
.header-popover-panel p { margin:6px 0 0; }
.header-profile-avatar { position:relative; width:28px; height:28px; overflow:hidden; }
.header-profile-avatar:empty::before,.header-profile-avatar:empty::after { content:''; position:absolute; background:#c4b7d2; }
.header-profile-avatar:empty::before { width:7px; height:7px; border-radius:50%; top:5px; }
.header-profile-avatar:empty::after { width:13px; height:7px; border-radius:8px 8px 4px 4px; bottom:5px; }
.header-profile-avatar img { width:100%; height:100%; object-fit:cover; }
.header-bell { position:relative; width:12px; height:13px; font-size:0; border:1.5px solid currentColor; border-radius:8px 8px 3px 3px; }
.header-bell::after { content:''; position:absolute; bottom:-4px; left:3px; width:4px; height:2px; border-radius:50%; background:currentColor; }
.space-character-grid,
.persona-grid:has(.redesigned-persona-card) {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 16px;
}
.persona-grid .redesigned-persona-card { border-radius: 14px; }
.redesigned-persona-card .persona-card-image { aspect-ratio: 1.6; }
.redesigned-persona-card .persona-card-image > img { min-height: 0; object-position: center top; }
.redesigned-persona-card .persona-card-content { padding: 14px 16px; }
.redesigned-persona-card .persona-card-content h3 { margin: 4px 0; font-size: 18px; }
.redesigned-persona-card .persona-description-preview { -webkit-line-clamp: 2; margin-bottom: 10px; }
.redesigned-persona-card .persona-card-actions { gap: 8px; flex-wrap: wrap; }
#portrait-canvas { cursor: grab; touch-action: none; } #portrait-canvas:active { cursor: grabbing; }
.creator-directory { display:grid; grid-template-columns:repeat(auto-fill,minmax(min(100%,275px),1fr)); gap:16px; margin-top:20px; }
.creator-directory-card { display:flex; flex-direction:column; gap:12px; padding:20px; border:1px solid #514061; border-radius:16px; background:linear-gradient(145deg,#292334,#1b1824); }
.creator-directory-heading { display:flex; align-items:center; gap:16px; margin-bottom:12px; }
.creator-directory-heading h1,.creator-directory-heading h2,.creator-directory-card p { margin:0; overflow-wrap:anywhere; }
.creator-directory-avatar { display:grid; place-items:center; flex:0 0 76px; width:76px; height:76px; border:1px solid #866aa0; border-radius:50%; overflow:hidden; background:#392a49; font-size:26px; }
.creator-directory-avatar img,.creator-directory-preview img { width:100%; height:100%; object-fit:cover; }
.creator-directory-preview { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; border-top:1px solid #514061; padding-top:12px; }
.creator-directory-preview > div { display:grid; place-items:center; aspect-ratio:4/5; overflow:hidden; border-radius:9px; background:#392a49; }
.creator-directory-preview img { object-position:center top; }
.creator-directory-card > button { margin-top:auto; }
#creator-collection { margin-top:18px; }
@media (min-width: 761px) {
  .sidebar {
    background: linear-gradient(to bottom, #12131c 31%, transparent 72%, #12131c66),
      url('/assets/sidebar-castle.png') center bottom / 100% auto no-repeat #12131c;
  }
}
.saved-controls { display:flex; align-items:center; gap:5px; flex:none; }
.saved-icon { display:grid; place-items:center; width:30px; height:30px; padding:0; border:1px solid #514061; border-radius:8px; color:#dbc8ef; background:#211a2a; }
.saved-favorite { font-size:20px; }
.saved-icon[aria-pressed=true] { color:#e1baff; background:#463158; }
.saved-bookmark span { display:block; width:10px; height:14px; background:currentColor; clip-path:polygon(0 0,100% 0,100% 100%,50% 73%,0 100%,0 0,15% 14%,15% 77%,50% 55%,85% 77%,85% 14%,15% 14%); }
.saved-bookmark[aria-pressed=true] span { clip-path:polygon(0 0,100% 0,100% 100%,50% 73%,0 100%); }
.portrait-footer:has(.saved-controls) { flex-wrap:wrap; gap:6px; }
.creator-directory-heading:has(.saved-controls) { flex-wrap:wrap; }
.space-card-caption:has(.saved-controls) { flex-wrap:wrap; }
.portrait-small-preview { display:grid; justify-items:center; align-content:center; gap:8px; color:#bcaecb; font-size:12px; }
.portrait-crop-stage { align-items:center; gap:16px; }
.portrait-crop-stage .portrait-small-preview canvas { width:42px; height:42px; border-width:1px; box-shadow:none; }
#portrait-zoom-value { margin-left:8px; color:#cdb7e9; }
#portrait-reset-framing { margin-top:10px; }
.creator-directory-summary { flex: 1 1 110px; min-width: 0; }
.creator-directory-card .creator-directory-bio { margin-top: 6px; color: #d5c9e1; font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.creator-directory-card .creator-directory-open { width: 100%; min-height: 40px; border: 1px solid #c5a5ee; border-radius: 10px; background: #443455; color: #f5ebff; font-weight: 700; }
.creator-directory-card .creator-directory-open:hover, .creator-directory-card .creator-directory-open:focus-visible { background: #59436f; }
#creator-bio { min-height: 56px; }
.creator-directory-card { gap: 14px; }
.creator-directory-card .creator-directory-heading { display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: start; gap: 14px; margin: 0; }
.creator-directory-card .creator-directory-avatar { width: 64px; height: 64px; }
.creator-directory-summary h2 { font-size: 20px; line-height: 1.25; }
.creator-directory-card > p.small { padding: 10px 0 0; border-top: 1px solid #514061; }
.creator-directory-card .creator-directory-preview { padding-top: 0; border-top: 0; }
.creator-directory-actions { display: flex; align-items: stretch; gap: 8px; margin-top: auto; }
.creator-directory-card .creator-directory-open { width: auto; flex: 1; min-width: 0; padding: 8px; background: #5a4270; }
.creator-directory-actions .saved-icon { width: 34px; height: 40px; }
.space-profile-panel { display:grid; grid-template-columns:minmax(220px, 1fr) minmax(260px, 1.45fr); gap:24px; max-width:940px; padding:24px; border:1px solid #493b59; border-radius:16px; background:#1e1928; }
.space-profile-panel .space-profile-row { display:flex; flex-direction:column; align-items:flex-start; gap:12px; min-width:0; }
.space-profile-panel .space-sign-out { margin:0; }
.space-profile-panel #creator-visibility { width:auto; max-width:100%; margin:8px 0 0; background:#2b2137; }
.space-profile-panel form { min-width:0; margin:0; padding-left:24px; border-left:1px solid #493b59; }
.space-profile-panel form label:first-child { margin-top:0; }
.space-profile-panel textarea { min-height:68px; }
.space-profile-save { display:flex; justify-content:flex-end; margin-top:12px; }
@media(max-width:700px) {
  .space-profile-panel { grid-template-columns:1fr; gap:16px; padding:16px; }
  .space-profile-panel form { padding:16px 0 0; border-left:0; border-top:1px solid #493b59; }
}
#portrait-select-canvas { border-radius: 8px; touch-action: none; cursor: crosshair; background: #17121e; }
#portrait-select-canvas[hidden], #portrait-canvas[hidden] { display: none; }
.comment-author { display:flex; align-items:center; }
.comment-author summary { display:inline-grid; place-items:center; width:36px; height:36px; overflow:hidden; border-radius:50%; border:1px solid #665078; background:#38294b; cursor:pointer; vertical-align:middle; list-style:none; }
.comment-author summary::-webkit-details-marker { display:none; }
.comment-author img { width:100%; height:100%; object-fit:cover; }
.comment-author strong { margin-left:8px; overflow-wrap:anywhere; }
.feedback-messages .public-comment { display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:start; gap:12px; padding-right:8px; }
.public-comment > p { margin:0; padding-top:7px; }
.public-comment .comment-author { position:relative; }
.public-comment .comment-author strong { position:absolute; z-index:2; top:100%; left:0; margin:4px 0 0; padding:5px 8px; width:max-content; max-width:160px; border-radius:6px; background:#30243c; }
.public-comment > button { align-self:start; margin-top:4px; }
.comment-actions { display:flex; align-items:center; flex-wrap:wrap; gap:5px; }
.saved-icon:has(small) { display:inline-flex; justify-content:center; gap:4px; width:auto; min-width:34px; padding:0 6px; }
.saved-icon small { font-size:11px; font-variant-numeric:tabular-nums; }
.portrait-generator {
  width:min(1000px, calc(100% - 28px)); max-width:none; max-height:92dvh; overflow:auto;
  padding:clamp(16px, 3vw, 32px); background:linear-gradient(135deg,#30263a,#211a2a);
  border-color:#715a7d; box-shadow:0 24px 90px #08050cca;
}
.portrait-generator > .dialog-top { border-bottom:1px solid #644f70; padding-bottom:15px; margin-bottom:18px; }
.portrait-generator-layout { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px; }
.portrait-generator-controls { min-width:0; }
.portrait-styles { border:0; padding:0; margin:0; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.portrait-styles legend, .portrait-generator-result h3 { font-size:17px; font-weight:700; margin:0 0 10px; padding:0; }
.portrait-style { position:relative; overflow:hidden; margin:0; cursor:pointer; border:2px solid #65536f; border-radius:10px; }
.portrait-style input { position:absolute; opacity:0; width:1px; height:1px; }
.portrait-style:has(input:checked), .portrait-style:hover { border-color:#d4a6ff; }
.portrait-style:has(input:focus-visible) { outline:2px solid white; outline-offset:2px; }
.portrait-style:has(input:checked)::after { content:'✓'; position:absolute; top:6px; right:6px; background:#d4a6ff; color:#211438; border-radius:50%; width:22px; height:22px; display:grid; place-items:center; font-weight:800; }
.portrait-style-thumbnail {
  display:block; aspect-ratio:210 / 130;
  background-image:url('/assets/portrait-style-reference.png'); background-size:796.2% 723.8%;
  background-position:32.1% 29.6%;
}
.portrait-style:nth-of-type(2) .portrait-style-thumbnail { background-position:48.3% 29.6%; }
.portrait-style:nth-of-type(3) .portrait-style-thumbnail { background-position:32.1% 51.7%; }
.portrait-style:nth-of-type(4) .portrait-style-thumbnail { background-position:48.3% 51.7%; }
.portrait-style-label { display:block; padding:6px 9px; background:#1b1523; color:#f3e9ff; font-weight:700; }
.portrait-generator textarea { width:100%; margin-bottom:10px; }
.portrait-generator-controls > .primary { width:100%; }
.portrait-generator-result { border-left:1px solid #644f70; padding-left:20px; min-width:0; }
.portrait-preview-frame {
  position:relative; display:grid; place-items:center; text-align:center; min-height:240px;
  aspect-ratio:4 / 5; max-height:52dvh; border:1px solid #65536f; border-radius:12px; overflow:hidden; background:#1b1523;
}
.generated-portrait-preview { position:absolute; width:100%; height:100%; object-fit:contain; }
.portrait-preview-frame > p { padding:10px; }
.portrait-preview-frame[aria-busy="true"]::after {
  content:''; position:absolute; width:30px; height:30px; border:3px solid #684e80; border-top-color:#e2c1ff;
  border-radius:50%; animation:portrait-spin .8s linear infinite; box-shadow:0 0 0 8px #1b1523cc;
}
@keyframes portrait-spin { to { transform:rotate(360deg); } }
@media(prefers-reduced-motion:reduce) { .portrait-preview-frame[aria-busy="true"]::after { animation:none; } }
.portrait-generation-status { min-height:1.4em; margin:7px 0; }
.portrait-generator-actions { display:flex; flex-wrap:wrap; gap:8px; }
.portrait-generator-actions > button { flex:1 0 auto; }
.portrait-generator [hidden] { display:none; }
@media(max-width:680px) {
  .portrait-generator-layout { grid-template-columns:minmax(0,1fr); }
  .portrait-generator-result { border-left:0; border-top:1px solid #644f70; padding:14px 0 0; }
}
.route-top { display:flex; align-items:center; gap:14px; padding:12px 18px; background:#211a2c; border-bottom:1px solid #615076; }
.route-top strong { color:#d8b9f2; font:italic 700 clamp(1.2rem,3vw,1.8rem) Georgia,serif; }
.route-top button:last-child { margin-left:auto; }
.route-layout { display:grid; grid-template-columns:minmax(0, 2.4fr) minmax(265px,1fr); min-height:calc(100dvh - 68px); }
.route-stage { position:relative; isolation:isolate; display:flex; flex-direction:column; justify-content:flex-end; gap:10px; padding:clamp(14px,4vw,42px); min-width:0; min-height:650px; background:radial-gradient(ellipse at 30% 20%,#392d50,#131019 75%); }
.route-background,.route-portrait { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:-3; }
.route-portrait { width:min(72%,650px); object-position:center top; z-index:-2; mask-image:linear-gradient(to right,black 70%,transparent); }
.route-stage::after { content:''; position:absolute; inset:0; z-index:-1; background:linear-gradient(transparent 20%,#15101ac2 62%,#15101a); }
.route-dialogue { margin-top:190px; border:1px solid #b092c8; border-radius:12px; background:#1b1523ec; box-shadow:inset 0 0 0 3px #aa85c326; }
.route-speaker { display:inline-block; position:relative; margin:-16px 0 0 18px; padding:6px 16px; border:1px solid #b092c8; border-radius:8px; background:#453453; color:#efddff; font:700 19px Georgia,serif; }
.route-dialogue-text { padding:12px 20px; max-height:34dvh; overflow:auto; white-space:pre-wrap; font:clamp(1rem,1.6vw,1.24rem)/1.6 Georgia,serif; overflow-wrap:anywhere; }
.route-choices { display:grid; gap:6px; }
.route-choices > button { text-align:left; background:#392d48ed; border-color:#a98bbd; }
.route-choices > button:hover { background:#574168; }
#route-choice-status { margin:0; }
#route-reply { display:flex; align-items:end; gap:10px; }
#route-reply textarea { min-height:54px; margin:0; resize:vertical; min-width:0; }
.route-cast { min-width:0; background:#191520; border-left:1px solid #514061; padding:16px; }
.route-cast h2 { margin-top:0; font:italic 700 26px Georgia,serif; }
.route-cast-member { display:grid; grid-template-columns:44px minmax(0,1fr); gap:9px; margin-bottom:8px; padding:9px; border:1px solid #514061; border-radius:10px; background:#262031; overflow-wrap:anywhere; }
.route-avatar { display:grid; place-items:center; width:44px; height:44px; overflow:hidden; border-radius:8px; background:#443450; }
.route-avatar img { width:100%; height:100%; object-fit:cover; }
.route-primary { color:#e2c1ff; font-size:12px; }
.route-love { display:flex; align-items:center; gap:6px; color:#dcb9fa; font-size:12px; }
.route-love meter { flex:1; min-width:20px; height:12px; }
.route-love meter::-webkit-meter-optimum-value { background:#b990e4; }
.route-notes,.route-history { max-height:44dvh; overflow:auto; overflow-wrap:anywhere; }
.route-note-text,.route-history article { white-space:pre-wrap; line-height:1.5; }
.route-history article { padding:10px 0; border-bottom:1px solid #514061; }
.route-reference-dialog { width:min(680px,94vw); }
@media(max-width:780px){.route-layout{grid-template-columns:1fr}.route-cast{border-left:0}.route-stage{min-height:520px}.route-dialogue{margin-top:120px}}
.route-reply-controls { display:flex; align-items:center; gap:6px; flex-wrap:wrap; justify-content:flex-end; } #route-reply textarea { flex:1 1 220px; } #route-reply { flex-wrap:wrap; }
#random-world-route { border:1px solid #e8caff; background:linear-gradient(120deg,#e5c5ff,#b593f8); color:#251537; font-weight:800; }
#random-world-route:not(:disabled):hover { background:#f0dbff; }
#random-world-route:disabled { opacity:1; background:#302641; color:#cbbcdd; border-color:#76618d; cursor:not-allowed; }
.header-sign-in > summary { border:1px solid #a887d1; border-radius:12px; padding:4px 9px; color:#f1e7fc; font-weight:700; }
#header-sign-in-panel { width:min(282px,calc(100vw - 32px)); box-sizing:border-box; padding:16px; border-color:#a887d1; box-shadow:0 12px 28px #0b0712aa; }
#header-sign-in-panel h2 { margin:0; font-size:17px; }
#header-google-signin { margin-top:14px; }
.header-popover [hidden] { display:none; }
.gallery-popular,.gallery-active-filters {display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:16px 0;}
.gallery-active-filters:empty {display:none;}
.gallery-popular .filter-chip,.gallery-active-filters .filter-chip {padding:8px 13px;border-radius:9px;}
.gallery-popular > .small,.gallery-active-filters > .small {margin-right:8px;}
#open-gallery-filters {white-space:nowrap;border-color:#8970ac;}
#gallery-filter-count:not(:empty) {display:inline-grid;place-items:center;min-width:22px;height:22px;border-radius:50%;background:#d7b5fc;color:#261734;margin-left:7px;}
#gallery-filter-dialog {width:min(440px,calc(100vw - 24px));max-width:none;margin:0;position:fixed;left:auto;right:24px;top:110px;max-height:calc(100dvh - 130px);background:linear-gradient(135deg,#292134,#1b1925);padding:22px;box-shadow:0 18px 55px #0009;}
#gallery-filter-dialog::backdrop {background:#08071033;backdrop-filter:none;}
#gallery-filter-dialog label {margin:0;}
#gallery-filter-dialog > label {margin:18px 0 8px;}
#gallery-filter-dialog select {margin-bottom:0;}
.gallery-visibility {border:0;padding:0;margin:18px 0;display:flex;}
.gallery-visibility legend {font-size:13px;margin-bottom:8px;}
.gallery-visibility label {flex:1;position:relative;}
.gallery-visibility input {position:absolute;opacity:0;width:1px;height:1px;}
.gallery-visibility span {display:block;padding:10px;text-align:center;border:1px solid #61506e;background:#211c2b;}
.gallery-visibility input:checked + span {background:#c5a3f2;color:#221430;}
.gallery-visibility input:focus-visible + span {outline:2px solid white;}
.gallery-tag-options {max-height:230px;overflow:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:16px 0;padding:2px;}
.gallery-tag-options label {display:flex;align-items:center;gap:8px;cursor:pointer;min-width:0;}
.gallery-tag-options input {width:18px;height:18px;flex-shrink:0;accent-color:#c5a3f2;}
.gallery-tag-options span {overflow-wrap:anywhere;}
.gallery-tag-options [hidden],#gallery-tag-empty[hidden] {display:none;}
#gallery-filter-dialog .dialog-actions {border-top:1px solid #61506e;padding-top:16px;justify-content:space-between;}
@media(max-width:650px){#gallery-filter-dialog{right:12px;top:70px;max-height:calc(100dvh - 90px);}#open-gallery-filters{width:100%;}}
.character-workshop {width:min(960px,calc(100vw - 28px));max-width:none;background:linear-gradient(135deg,#30243b,#211a2b);border-color:#9b78b8;}
.character-workshop .dialog-top {align-items:flex-start;}
.character-workshop textarea {min-height:95px;}
.character-workshop [hidden] {display:none;}
.workshop-suggestion {display:flex;align-items:flex-start;gap:14px;padding:16px;border:1px solid #77618b;border-radius:12px;background:#211a2b;cursor:pointer;}
.workshop-suggestion:has(input:checked) {background:#4a365d;border-color:#d0a5f4;}
.workshop-suggestion input {width:20px;height:20px;flex-shrink:0;accent-color:#c4a1ef;}
.workshop-suggestion span span,.workshop-suggestion small {display:block;margin-top:7px;}
.workshop-comparison {display:grid;grid-template-columns:1fr 1fr;gap:16px;}
.workshop-comparison > div {min-width:0;}
.workshop-comparison pre {white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;font-size:13px;line-height:1.7;max-height:340px;overflow:auto;background:#16121d;padding:14px;border:1px solid #665071;border-radius:10px;}
.workshop-change h4 {font-size:16px;margin-bottom:10px;}
@media(max-width:650px){.workshop-comparison{grid-template-columns:1fr;}}
#character-form #portrait-preview{position:relative}.refine-portrait-button{position:absolute;bottom:16px;right:16px;z-index:2;box-shadow:0 4px 18px #0008}.refine-image-dialog{width:min(1200px,calc(100vw - 32px));max-width:1200px;max-height:calc(100dvh - 32px);overflow:auto;padding:28px;border:1px solid #655276;border-radius:24px;background:linear-gradient(135deg,#262032,#15121e);color:#eee9f8}.refine-tabs{display:flex;gap:10px;margin:20px 0}.refine-layout{display:grid;grid-template-columns:minmax(240px,1fr) 2fr;gap:24px}.refine-comparison{display:grid;grid-template-columns:1fr 1fr;gap:14px}.refine-comparison figure{margin:0;min-width:0;background:#100e17;border:1px solid #51435e;border-radius:14px;overflow:hidden}.refine-comparison figcaption{padding:12px 16px;border-bottom:1px solid #51435e}.refine-comparison img{width:100%;height:340px;object-fit:contain}.refine-comparison [data-empty]{padding:50px 20px;color:#b7aac8;text-align:center}.refine-upload{display:inline-block;cursor:pointer}.refine-image-dialog textarea{min-height:140px}.refine-image-dialog [data-status]{min-height:28px}.refine-image-dialog [hidden]{display:none!important}@media(max-width:760px){.refine-layout{grid-template-columns:1fr}.refine-comparison img{height:240px}.refine-image-dialog{padding:18px}}
.portrait-cover,.space-character-art{position:relative}.new-character-badge{position:absolute;top:12px;left:12px;z-index:2;display:inline-flex;align-items:center;padding:5px 11px;border-radius:999px;background:#cda9ff;color:#241137;font-size:12px;font-weight:800;letter-spacing:.04em;line-height:1.3;box-shadow:0 3px 12px #0005;pointer-events:none}.shared-party-title{display:block;color:#cfb3fa;font-size:13px;font-weight:600;line-height:1.4;margin:4px 0;overflow-wrap:anywhere}
.portrait-cover>.new-character-badge,.space-character-art>.new-character-badge{font-size:12px;text-shadow:none;width:auto;height:auto;min-height:0;transform:none;inset:12px auto auto 12px}.space-card-caption>.shared-party-title{flex-basis:100%;order:2}

/* Multiple-character setup: self-contained sharing card and aligned controls. */
.ensemble-editor .ensemble-section-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:18px}.ensemble-editor .ensemble-section-heading h2{margin:0 0 5px}.ensemble-editor .ensemble-section-heading p{margin:0;line-height:1.6}.ensemble-capacity{flex-shrink:0;border:1px solid #514061;border-radius:999px;padding:5px 9px;font-size:11px;color:#cbb8e3}.ensemble-editor .ensemble-switch{margin:0;padding:14px 16px;background:#191620;border:1px solid #514061;border-radius:12px;align-items:flex-start;cursor:pointer}.ensemble-editor .ensemble-switch input,.ensemble-editor .party-share-option input[type=checkbox]{appearance:auto;flex:0 0 18px;width:18px;height:18px;min-height:0;margin:3px 0 0;padding:0;accent-color:#c3a3ff}.ensemble-editor .ensemble-switch span,.ensemble-editor .party-share-option span{min-width:0}.ensemble-editor .ensemble-switch strong,.ensemble-editor .party-share-option strong{display:block;font-size:14px;font-weight:650;color:#eee7f8}.ensemble-editor .ensemble-switch small,.ensemble-editor .party-share-option small{display:block;font-size:12px;font-weight:400;line-height:1.6;color:#afa1bf;margin-top:3px}.party-sharing-card{margin-top:16px;padding:18px;background:linear-gradient(135deg,#2a2038,#1b1724);border:1px solid #69527f;border-radius:14px}.ensemble-editor .party-share-option{display:flex;align-items:flex-start;gap:12px;margin:0;cursor:pointer;line-height:1.5}.party-sharing-card #party-title-field{margin:18px 0 0;padding-top:17px;border-top:1px solid #4c3d5b}.party-sharing-card #party-title-field>label{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 8px;font-size:13px;font-weight:600}.party-sharing-card #party-title-field>label .small{font-size:11px;font-weight:400}.party-sharing-card #party-title{margin:0;width:100%;box-sizing:border-box;background:#121019}.party-sharing-card #party-title-help{font-size:12px;line-height:1.6;margin:7px 0 0;color:#b5a4c8}.party-sharing-details{margin-top:16px;padding-top:14px;border-top:1px solid #4c3d5b;color:#a99ab9;font-size:12px;line-height:1.7}.party-sharing-details p{margin:0}.party-sharing-details p+p{margin-top:5px}.ensemble-members-heading{margin-top:24px}.ensemble-editor .ensemble-members-heading h3{font-size:15px;margin:0 0 6px}.ensemble-members-heading p{margin:0 0 14px}.ensemble-editor [hidden]{display:none!important}@media(max-width:520px){.ensemble-editor .ensemble-section-heading{display:block}.ensemble-capacity{display:inline-block;margin-top:10px}.party-sharing-card{padding:14px}.ensemble-editor .ensemble-switch{padding:12px}}
.gallery-popular .gallery-new-filter{color:#d9bbff;border:1px solid #795b99;background:#352541;font-weight:700;letter-spacing:.03em}.gallery-popular .gallery-new-filter.selected{background:#c3a3ff;border-color:#c3a3ff;color:#23142f;box-shadow:0 0 0 2px #c3a3ff22}
.creator-world-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;margin:24px 0}.creator-world-card{border:1px solid #594569;border-radius:18px;overflow:hidden;background:linear-gradient(135deg,#282033,#1a1623)}.creator-world-art{aspect-ratio:16/9;background:linear-gradient(135deg,#3b2c52,#13121e);display:grid;place-items:center;overflow:hidden}.creator-world-art img{width:100%;height:100%;object-fit:cover}.creator-world-art>span{font-size:64px;color:#b89bdf}.creator-world-copy{padding:22px}.creator-world-copy h3{font-size:23px;margin:10px 0}.creator-world-copy p{font-size:14px;line-height:1.7;color:#baafc9}.creator-world-copy .row{margin-top:18px;flex-wrap:wrap}.creator-public-tabs{margin:20px 0}.world-workshop{width:min(1120px,calc(100vw - 32px));max-width:1120px;max-height:calc(100dvh - 32px);overflow:auto;background:linear-gradient(135deg,#2c2038,#17131f);border:1px solid #715387;border-radius:22px;padding:28px;color:#eee8f5;box-sizing:border-box}.world-workshop-layout{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.2fr);gap:30px;margin-top:20px}.world-workshop label{font-size:13px;font-weight:600}.world-workshop input,.world-workshop textarea,.world-workshop select{box-sizing:border-box;width:100%}.world-workshop textarea{min-height:100px}.world-workshop #world-idea{min-height:180px}.world-workshop [data-world-panel] textarea{min-height:230px}.world-workshop .world-lore-tabs{display:flex;flex-wrap:wrap;gap:6px;margin:20px 0 10px}.world-lore-tabs button{font-size:12px;padding:8px 10px}.world-workshop-art{margin-top:20px;aspect-ratio:16/9;display:grid;place-items:center;background:#100e17;border:1px solid #594567;border-radius:13px;overflow:hidden}.world-workshop-art img{width:100%;height:100%;object-fit:contain}.world-workshop-art p{font-size:13px;text-align:center;color:#aa97bc}.world-workshop-idea{padding-right:24px;border-right:1px solid #51405f}.world-workshop .world-upload{cursor:pointer;font-size:12px;font-weight:400;display:inline-block;width:auto;margin:0}.world-character-picker{max-height:220px;overflow:auto;border:1px solid #51405f;border-radius:12px;background:#17121e;margin:12px 0;padding:10px}.world-character-picker label{display:flex;align-items:center;gap:10px;margin:0;padding:10px;cursor:pointer}.world-character-picker input[type=checkbox]{width:18px;height:18px;flex:0 0 18px;accent-color:#c6a5ff;margin:0}.world-character-picker small{display:block;color:#ad9abb;font-size:11px;margin-top:3px}.world-workshop [data-status]{padding:12px 0;color:#d3b6f4;min-height:20px}.world-workshop [aria-busy=true] [data-build]::before{content:'◌ ';display:inline-block;animation:spin 1s linear infinite}.world-workshop .small{line-height:1.7;color:#b7a7c6}.world-workshop [hidden],.creator-world-grid [hidden],.creator-public-tabs~[hidden]{display:none!important}@media(max-width:780px){.world-workshop-layout{grid-template-columns:1fr}.world-workshop-idea{padding:0 0 20px;border-right:0;border-bottom:1px solid #51405f}.creator-world-grid{grid-template-columns:1fr}.world-workshop{padding:18px}.world-workshop .dialog-top h2{font-size:22px}}
/* Shared character cards preserve the same presentation in Your Space and discovery. */
.portrait-cover>img{object-position:center top;transform-origin:center top}.space-character-portrait-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,260px),1fr));gap:22px}.space-character-portrait-grid .portrait-cover{height:400px}.space-character-portrait-grid .portrait-caption{padding:65px 20px 20px}.space-character-portrait-grid .portrait-caption h3{font-size:20px}.space-character-portrait-grid .portrait-caption p{-webkit-line-clamp:3}.space-character-portrait-grid .portrait-footer{flex-wrap:wrap;gap:12px;padding:16px 20px}.space-character-portrait-grid .portrait-footer>.row{width:100%;justify-content:flex-start;gap:22px}.space-character-portrait-grid .portrait-footer .text-button{font-size:13px;padding:0}@media(max-width:620px){.space-character-portrait-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.space-character-portrait-grid .portrait-cover{height:340px}.space-character-portrait-grid .portrait-caption{padding:50px 12px 14px}.space-character-portrait-grid .portrait-caption h3{font-size:16px}.space-character-portrait-grid .portrait-footer{padding:12px}}@media(max-width:400px){.space-character-portrait-grid{grid-template-columns:1fr}}
/* Character editor: pre-made worlds and personal worlds share one attached selection. */
.split-world-picker{container-type:inline-size;margin-top:20px}.world-picker-columns{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px}.world-picker-panel{min-width:0;border:1px solid #655078;border-radius:16px;padding:16px;background:linear-gradient(140deg,#251b30,#18131f)}.world-picker-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:16px}.world-picker-heading h3{font-size:17px;margin:0 0 6px;color:#eee2ff}.world-picker-heading p{margin:0;font-size:12px;line-height:1.6;color:#b9a7cb}.world-picker-heading .primary{font-size:12px;padding:9px 12px;white-space:nowrap}.world-picker-panel>input[type=search]{box-sizing:border-box;width:100%;margin:0 0 14px;min-width:0;font-size:12px;padding:11px 12px;background:#18121f}.world-picker-list{display:flex;flex-direction:column;gap:10px;max-height:350px;overflow-y:auto;scrollbar-width:thin;padding:2px}.world-picker-choice{display:flex;align-items:center;gap:10px;min-width:0;min-height:78px;margin:0;border:1px solid #51405f;border-radius:11px;background:#211827;cursor:pointer;overflow:hidden;padding:0 10px 0 0}.world-picker-choice:has(input:checked){border-color:#c6a0f2;box-shadow:inset 0 0 0 1px #c6a0f2;background:#392544}.world-picker-choice:focus-within{outline:2px solid #d2b0ff;outline-offset:1px}.world-picker-thumbnail{display:grid;place-items:center;align-self:stretch;width:76px;flex:0 0 76px;background:linear-gradient(135deg,#57406d,#21192c);color:#d7b5f3;font-size:28px;overflow:hidden}.world-picker-thumbnail img{width:100%;height:100%;min-height:78px;max-height:100px;object-fit:cover;object-position:center top}.world-picker-text{flex:1;min-width:0;padding:10px 0}.world-picker-text b{display:block;overflow-wrap:anywhere;font-size:12px;line-height:1.5}.world-picker-text small{display:block;font-size:10px;line-height:1.5;color:#ba9fcb;margin-top:4px;overflow-wrap:anywhere}.world-picker-choice input[type=checkbox]{appearance:auto;flex:0 0 17px;width:17px;height:17px;padding:0;margin:0;accent-color:#c69bf4}.world-picker-ownership{margin:14px 0 0;line-height:1.7;font-size:11px}.world-picker-attached{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin-top:16px;padding:16px;border:1px solid #655078;border-radius:14px;background:#211729}.world-picker-attached>strong{font-size:13px;color:#e7d5f8}.world-picker-attached #attached-lore{display:flex;gap:8px;flex-wrap:wrap;margin:0}.world-picker-attached .attached-lore-chip{border-radius:9px;background:#5c3c77;color:#f0e1ff;padding:8px 11px}.split-world-picker [hidden]{display:none!important}@container(max-width:560px){.world-picker-columns{grid-template-columns:1fr}.world-picker-heading{flex-wrap:nowrap}.world-picker-list{max-height:300px}.world-picker-thumbnail{width:90px;flex-basis:90px}}
.chat-reference-control{display:inline-flex;align-items:center;gap:7px;max-width:260px;padding:5px 9px;border:1px solid #5d496e;border-radius:8px;background:#241b2d;color:#bca4d3;font-size:10px;line-height:1.5;min-width:0}.chat-reference-control>span{white-space:nowrap}.chat-reference-control code{color:#dec5fa;font:11px ui-monospace,monospace;max-width:165px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;user-select:text}.chat-reference-control:hover{border-color:#bc94e7;background:#352640}.story-item .chat-reference-control{display:flex;margin:8px 0;width:fit-content}.story-topbar>.chat-reference-control{max-width:190px}.story-topbar>.chat-reference-control code{max-width:100px}@media(max-width:600px){.chat-reference-control{max-width:200px}.chat-reference-control code{max-width:110px}}
.featured-creators{margin:25px 0 28px;padding:22px;border:1px solid #58406e;border-radius:20px;background:radial-gradient(ellipse at top,#76519833,transparent 75%),#19131f}.featured-creators h2{font-size:23px;margin:0 0 6px;color:#dcc0ff}.featured-creators>p{margin:0 0 18px}.featured-creator-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px}.featured-creator-card{display:flex;flex-direction:column;align-items:center;min-width:0;padding:18px 12px 12px;border:1px solid #73528c;border-radius:14px;background:radial-gradient(ellipse at top,#7c4aa540,transparent 60%),linear-gradient(145deg,#2c1e38,#19121f);text-align:center}.featured-creator-avatar{width:90px;height:90px;border:2px solid #c6a2f0;box-shadow:0 0 24px #b66bf522;border-radius:50%;overflow:hidden;display:grid;place-items:center;background:#4a325d;font-size:32px;color:#e0c2ff}.featured-creator-avatar img{width:100%;height:100%;object-fit:cover}.featured-creator-card h3{font-size:16px;margin:14px 0 8px;overflow-wrap:anywhere}.featured-creator-bio{color:#c9b8d6;font-size:12px;line-height:1.6;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;margin:0 0 10px;min-height:58px}.featured-creator-card>.small{font-size:11px;margin:auto 0 8px}.featured-creator-card>.creator-directory-open{margin:12px 0 0;width:100%;font-size:12px;padding:9px 6px}.creator-id-control{display:inline-flex;align-items:center;gap:5px;padding:5px 0;background:transparent;border:0;color:#bdadce;font-size:11px;max-width:100%;flex-wrap:wrap}.creator-id-control code{font:11px ui-monospace,monospace;color:#ead7ff;user-select:text}.creator-id-control:hover{color:#e6c7ff}.creator-directory-card>.creator-id-control{margin:0 0 12px}.all-creators-heading{margin:24px 0 18px;font-size:23px}@media(max-width:1200px){.featured-creator-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@media(max-width:750px){.featured-creators{padding:16px}.featured-creator-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.featured-creator-avatar{width:74px;height:74px}}@media(max-width:390px){.featured-creator-grid{grid-template-columns:1fr}}
.rank-crystal{position:absolute;top:12px;right:12px;z-index:4;width:27px;height:40px;filter:drop-shadow(0 2px 5px #000b);display:block;pointer-events:auto}.rank-crystal svg{display:block;width:100%;height:100%}.portrait-cover>.rank-crystal{inset:12px 12px auto auto;font-size:0;text-shadow:none}.creator-directory-card,.featured-creator-card,.creator-directory-heading{position:relative}.creator-directory-card>.rank-crystal,.featured-creator-card>.rank-crystal{top:10px;right:10px;width:22px;height:33px}.featured-creator-card .creator-directory-heading{display:flex;flex-direction:column;align-items:center;text-align:center;margin-bottom:8px}.featured-creator-card h2{font-size:16px;margin:12px 0 6px}.featured-creator-card .creator-directory-summary{min-width:0}.creator-score-breakdown{font-size:11px;color:#c1accf;line-height:1.6;margin:0 0 8px}.featured-creator-card .creator-directory-actions{width:100%;display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:auto}.featured-creator-card .creator-directory-open{flex-basis:100%;font-size:12px;padding:8px}.creator-ranking-tools{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin:14px 0}.creator-ranking-tools>label{font-size:12px;margin:0}.creator-ranking-tools>select{width:auto;margin:0}.ranking-filter-panel{position:relative;min-width:160px}.ranking-filter-panel>summary{cursor:pointer;list-style:none;padding:11px 16px;border:1px solid #79608f;border-radius:10px;background:#2c2038;color:#d9c3ec;font-size:13px}.ranking-filter-fields{position:absolute;top:calc(100% + 6px);right:0;z-index:20;min-width:270px;display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:16px;background:#24192e;border:1px solid #8e6aaa;border-radius:12px;box-shadow:0 12px 24px #0009}.ranking-filter-fields label{font-size:11px;margin:0}.ranking-filter-fields input{width:100%;min-width:0;box-sizing:border-box;margin:6px 0 0;padding:8px}.ranking-filter-fields [data-ranking-status]{grid-column:1/-1;margin:0;font-size:11px}.gallery-ranking-filters{display:flex;justify-content:flex-end;margin:12px 0}.featured-characters{margin:24px 0 28px}.featured-characters h2{font-size:25px;margin:0 0 6px}.featured-character-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px;margin-top:18px}.featured-character-card{min-width:0;overflow:hidden;background:linear-gradient(150deg,#2b2036,#17121e);border:1px solid #624779;border-radius:16px}.featured-character-art{display:block;position:relative;padding:0;width:100%;height:310px;text-align:left;overflow:hidden;background:#24192e}.featured-character-art>img{height:100%;width:100%;object-fit:cover;object-position:center top}.featured-character-name{position:absolute;inset:auto 0 0;padding:60px 14px 15px;background:linear-gradient(transparent,#1c1429f5);font-size:17px;font-weight:700;color:#fff;overflow-wrap:anywhere}.featured-character-actions{display:flex;flex-direction:column;align-items:flex-start;gap:12px;padding:12px}.featured-character-actions .text-button{font-size:12px;padding:0}.featured-character-actions .saved-controls{width:100%;justify-content:space-between}.featured-character-empty{font-size:64px;color:#b99ed0;display:grid;place-items:center;height:100%}@media(max-width:1050px){.featured-character-grid{gap:8px}.featured-character-art{height:260px}.featured-character-name{font-size:14px;padding:45px 9px 12px}.featured-character-actions{padding:9px}.featured-character-actions .text-button{font-size:10px}}@media(max-width:700px){.featured-character-grid{display:flex;overflow-x:auto;padding-bottom:12px;scroll-snap-type:x mandatory}.featured-character-card{flex:0 0 190px;scroll-snap-align:start}.featured-character-art{height:280px}.ranking-filter-fields{min-width:240px}.featured-character-name{font-size:16px}}
.portrait-cover span.rank-crystal{font-size:0;text-shadow:none}.portrait-cover span.new-character-badge{font-size:12px;text-shadow:none}.featured-character-art .rank-crystal{inset:12px 12px auto auto}.creator-directory-card>.rank-crystal{pointer-events:none}
/* Featured character cards use the complete gallery-card anatomy. */
.featured-character-grid>.portrait-card{min-width:0;display:flex;flex-direction:column}.featured-character-grid .portrait-cover{height:375px;flex-shrink:0;padding:0}.featured-character-grid .portrait-cover>img{object-position:center top}.featured-character-grid .portrait-caption{padding:65px 15px 18px}.featured-character-grid .portrait-caption h3{font-size:19px}.featured-character-grid .portrait-caption p{font-size:12px;line-height:1.7;-webkit-line-clamp:3}.featured-character-grid .portrait-footer{padding:14px;gap:10px;display:flex;flex-wrap:wrap;margin-top:auto}.featured-character-grid .portrait-footer>.row{width:100%;gap:18px;flex-wrap:wrap}.featured-character-grid .portrait-footer .text-button{font-size:12px;padding:0}.featured-character-grid .portrait-footer>span{font-size:10px;margin-left:auto}.featured-character-grid .saved-controls{gap:6px}.featured-character-grid .rank-crystal{width:30px;height:44px;top:12px;right:12px}.featured-creator-grid{align-items:start}.featured-creator-concept{align-self:start;max-width:260px;padding:14px 12px 12px;gap:0;background:radial-gradient(ellipse at 50% 0,#9358c942,transparent 65%),linear-gradient(155deg,#291a38,#17101f);box-shadow:inset 0 1px 0 #d4a8ff35,0 4px 18px #0003}.featured-creator-concept::before{content:'✦ · ✧';position:absolute;top:6px;left:9px;color:#e7bdff;font-size:14px;letter-spacing:6px;opacity:.6;pointer-events:none}.featured-creator-concept .featured-creator-avatar{width:104px;height:104px;margin:0 0 4px;border-color:#c89bef;box-shadow:0 0 18px #be80ff30}.featured-creator-concept h3{font-size:17px;line-height:1.4;margin:7px 0 5px;color:#f2e8fb}.featured-creator-concept .featured-creator-bio{min-height:0;margin:0 0 10px;font-size:12px;line-height:1.6;-webkit-line-clamp:3;color:#dfd0e8}.featured-creator-stats{font-size:11px;line-height:1.6;margin:0 0 4px;color:#cfbadf;display:flex;justify-content:center;gap:10px;flex-wrap:wrap}.featured-creator-stats span{white-space:nowrap}.featured-creator-concept>.creator-id-control{margin:0;padding:4px 0;font-size:10px}.featured-creator-concept>.creator-directory-open{width:100%;margin:9px 0 0;padding:8px 10px;border:1px solid #bb8ee0;border-radius:9px;background:linear-gradient(110deg,#5c3778,#342142);color:#f4e5ff;font-size:12px;font-weight:600;box-shadow:inset 0 0 8px #bb83f21f}.featured-creator-concept>.creator-directory-open:hover{background:#6a4384;border-color:#e0bcff}.featured-creator-concept>.rank-crystal{top:10px;right:10px;width:25px;height:37px}@media(max-width:1050px){.featured-character-grid .portrait-cover{height:340px}.featured-character-grid .portrait-caption{padding:55px 10px 14px}.featured-character-grid .portrait-caption h3{font-size:16px}.featured-character-grid .portrait-footer{padding:10px}.featured-character-grid .portrait-footer>span{flex-basis:100%;margin:0}.featured-character-grid .rank-crystal{width:25px;height:37px}}@media(max-width:700px){.featured-character-grid>.portrait-card{flex:0 0 230px;scroll-snap-align:start}.featured-character-grid .portrait-cover{height:365px}.featured-creator-concept{max-width:none}}
/* Creator directory cards: profile, compact statistics, character preview, one action row. */
.creator-directory{grid-template-columns:repeat(auto-fill,minmax(min(100%,340px),1fr));align-items:start}.creator-directory-redesigned{position:relative;gap:0;padding:22px;border:1px solid #89629f;border-radius:20px;background:radial-gradient(ellipse at 55% -10%,#8f45be28,transparent 58%),linear-gradient(140deg,#281b32,#19121f);box-shadow:inset 0 2px 0 #c695e838,0 5px 20px #0003;overflow:visible}.creator-directory-redesigned::before{content:'';position:absolute;top:-1px;left:12%;right:12%;height:1px;background:linear-gradient(90deg,transparent,#d9acff,transparent);box-shadow:0 0 12px #b477df88;pointer-events:none}.creator-card-profile{display:grid;grid-template-columns:76px minmax(0,1fr);align-items:center;gap:16px;padding-right:20px;margin-bottom:14px}.creator-directory-redesigned .creator-directory-avatar{width:76px;height:76px;flex-basis:76px;border:2px solid #be96de;box-shadow:0 0 15px #a25ed022}.creator-card-profile h2{font-size:21px;line-height:1.3;margin:0 0 7px;color:#f3e9fb;overflow-wrap:anywhere}.creator-directory-redesigned .creator-card-bio{font-size:13px;color:#d1bddf;line-height:1.65;margin:0}.creator-directory-redesigned>.creator-id-control{align-self:flex-start;margin:0 0 15px;padding:0;font-size:11px;gap:7px;color:#b99acf}.creator-directory-redesigned>.rank-crystal{width:26px;height:39px;top:17px;right:15px}.creator-card-stats{display:grid;grid-template-columns:1fr 1fr;align-items:center;border-top:1px solid #77558d;border-bottom:1px solid #77558d;padding:13px 0;margin:0 0 14px;color:#e3ceeF;font-size:14px;gap:10px}.creator-character-stat,.creator-likes-stat{display:flex;align-items:center;gap:7px;min-width:0;white-space:nowrap}.creator-likes-stat{border-left:1px solid #765588;padding-left:14px}.creator-character-stat>span,.creator-likes-stat>span:first-child{font-size:21px;line-height:1;color:#cfabea}.creator-like-info{position:relative;display:inline-flex;margin-left:auto}.creator-like-info>button{padding:0;border:0;background:transparent;color:#c5a2df;font-size:15px;line-height:1.2;cursor:help}.creator-like-tooltip{position:absolute;right:-8px;bottom:calc(100% + 10px);z-index:12;display:none;width:200px;white-space:normal;padding:10px 12px;border:1px solid #9b75b7;border-radius:9px;background:#302039;color:#f2e4fb;font-size:12px;line-height:1.6;box-shadow:0 5px 15px #0007}.creator-like-info:hover .creator-like-tooltip,.creator-like-info:focus-within .creator-like-tooltip{display:block}.creator-directory-redesigned .creator-preview-label{margin:0 0 10px;color:#bda0d0;font-size:12px;line-height:1.6}.creator-directory-redesigned .creator-directory-preview{gap:9px;border:0;padding:0;margin:0 0 18px}.creator-directory-redesigned .creator-directory-preview>div{aspect-ratio:4/5;border:1px solid #815e96;border-radius:11px}.creator-directory-redesigned .creator-directory-preview img{object-position:center top}.creator-directory-redesigned .creator-directory-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:center;margin:0}.creator-directory-redesigned .creator-directory-open{min-width:0;width:100%;height:42px;padding:8px 10px;border:1px solid #d4aff0;border-radius:10px;background:linear-gradient(115deg,#c396f2,#b188e6);color:#21132d;font-size:14px;font-weight:750;box-shadow:inset 0 1px 0 #f2dbff66}.creator-directory-redesigned .creator-directory-open:hover{background:#d0acf6}.creator-directory-redesigned .saved-controls{display:flex;gap:8px}.creator-directory-redesigned .saved-icon{width:39px;height:42px;padding:0;border:1px solid #b48acc;border-radius:10px;background:#2a1c34;color:#e0c4f1;font-size:21px}.creator-directory-redesigned .saved-icon small{display:none}.creator-directory-redesigned .saved-icon[aria-pressed=true]{background:#674483;border-color:#debcfa}@media(max-width:420px){.creator-directory-redesigned{padding:16px}.creator-card-profile{grid-template-columns:64px minmax(0,1fr);gap:12px;padding-right:18px}.creator-directory-redesigned .creator-directory-avatar{width:64px;height:64px}.creator-card-profile h2{font-size:19px}.creator-card-stats{font-size:12px;gap:7px}.creator-likes-stat{padding-left:9px}.creator-directory-redesigned .creator-directory-open{font-size:12px}.creator-directory-redesigned .saved-icon{width:34px}.creator-directory-redesigned .saved-controls{gap:6px}}
.admin-world-picker,.admin-creator-management{padding:20px;border:1px solid #51405f;border-radius:14px;background:#1b1723;margin:18px 0 26px}.admin-world-picker>.row{align-items:center;flex-wrap:wrap}.admin-world-picker select{flex:1;min-width:200px;margin:0}.admin-world-picker button{white-space:nowrap}.admin-creator-management h2{margin-top:0}.admin-creator-management form>.row{align-items:center}.admin-creator-management form>.row input{margin:0;flex:1;min-width:0}.admin-creator-editor{margin-top:20px;padding:18px;border:1px solid #6b4f82;border-radius:12px;background:#22182c}.admin-creator-editor h3{margin:0}.admin-ranking-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:18px 0;padding:14px;background:#17111f;border:1px solid #4f3b60;border-radius:10px}.admin-ranking-stats strong{display:block;font-size:23px;color:#ddbcff}.admin-ranking-stats span{display:block;font-size:11px;line-height:1.6;color:#b09bc2;margin-top:5px}.admin-feature-toggle{display:flex;align-items:flex-start;gap:12px;border:1px solid #5d456e;border-radius:10px;padding:14px;margin:18px 0;cursor:pointer}.admin-feature-toggle input[type=checkbox]{flex:0 0 18px;width:18px;height:18px;margin:3px 0 0;min-height:0;accent-color:#c4a0ef}.admin-feature-toggle small{display:block;color:#b49ec7;line-height:1.7;margin-top:5px;font-size:12px}@media(max-width:600px){.admin-ranking-stats{grid-template-columns:1fr 1fr}.admin-world-picker,.admin-creator-management{padding:15px}.admin-world-picker button{width:100%}}
#admin-character-result .story-item{flex-wrap:wrap;align-items:flex-start}#admin-character-result .story-item>.row{flex-wrap:wrap}

.moderation-message,.moderation-alert{padding:18px;margin:12px 0;border:1px solid #5f496e;border-radius:12px}.moderation-message small{display:block;margin:8px 0}.moderation-message textarea{width:100%;min-height:90px}.moderation-message button,.moderation-alert button{margin:6px}.moderation-message strong{display:block}

.public-comment > [data-report-message]{grid-column:2;grid-row:2;justify-self:start}.public-comment > .comment-actions{grid-column:3;grid-row:1}

/* Keep World Workshop controls inside the viewport at every size. */
.world-workshop-layout > section{min-width:0}.world-workshop .row,.world-workshop .dialog-actions{flex-wrap:wrap}.world-workshop .small,.world-workshop label{overflow-wrap:anywhere}.world-workshop .dialog-top{align-items:flex-start}.world-workshop [data-close]{flex-shrink:0}@media(max-width:780px){.world-workshop{width:calc(100vw - 24px);max-height:calc(100dvh - 24px)}.world-workshop-layout{gap:20px}}

.world-character-search-row{display:flex;align-items:start;gap:8px}.world-character-search-row input{min-width:0;flex:1}.world-character-search-row button{flex-shrink:0}.world-attachment-selection{padding:14px;border:1px solid #665078;border-radius:12px;background:#20182b;margin-bottom:12px}.world-attachment-selection strong{font-size:13px}.world-attachment-selection [data-selected-characters]{display:flex;gap:7px;flex-wrap:wrap;margin-top:10px}.world-selected-character{font-size:12px;padding:7px 10px;border:1px solid #8d6ab0;background:#3d2d52;border-radius:20px;text-align:left;overflow-wrap:anywhere;max-width:100%}.world-selected-character span{margin-left:6px}.world-workshop [data-character-match-count]{margin:0}@media(max-width:520px){.world-character-search-row{flex-wrap:wrap}.world-character-search-row input{flex-basis:100%}}

.admin-character-visibility{font-size:13px;font-weight:600;margin:10px 0}.admin-character-visibility.is-live,.admin-character-live{color:#83e5a7}.admin-character-visibility.is-private{color:#b8afc6}button.admin-make-public{background:#194b32;border-color:#398b5e;color:#b5f4cf}button.admin-make-public:hover{background:#236441;border-color:#69c48c}button.admin-make-private{background:#54262e;border-color:#a34b5c;color:#ffd2d9}button.admin-make-private:hover{background:#71333e;border-color:#cf6d7f}

.gallery-tools>.ranking-filter-panel{flex:0 0 150px;min-width:0;margin:0}.gallery-tools>.ranking-filter-panel>summary{box-sizing:border-box;min-height:46px;display:flex;align-items:center;white-space:nowrap}.gallery-tools #character-search{min-width:0}.gallery-tools>.ranking-filter-panel>summary::-webkit-details-marker{display:none}@media(max-width:650px){.gallery-tools>.ranking-filter-panel{flex:1;min-width:140px}.gallery-tools>.ranking-filter-panel .ranking-filter-fields{right:0;min-width:0;width:min(280px,calc(100vw - 68px));box-sizing:border-box}}

.creator-search-toolbar{display:flex;align-items:center;gap:18px;margin:20px 0}.creator-search-toolbar>#creator-search{flex:1;min-width:0;width:auto;margin:0}.creator-search-toolbar>.creator-ranking-tools{flex:0 0 auto;flex-wrap:nowrap;margin:0;gap:12px}.creator-search-toolbar .ranking-filter-panel{min-width:150px}.creator-search-toolbar .ranking-filter-panel>summary{min-height:46px;box-sizing:border-box;display:flex;align-items:center;white-space:nowrap}.creator-search-toolbar .creator-ranking-tools>label{white-space:nowrap}@media(max-width:950px){.creator-search-toolbar{flex-wrap:wrap}.creator-search-toolbar>#creator-search{flex-basis:100%;width:100%}.creator-search-toolbar>.creator-ranking-tools{margin-left:auto;flex-wrap:wrap}}@media(max-width:520px){.creator-search-toolbar>.creator-ranking-tools{width:100%;margin:0}.creator-search-toolbar .creator-ranking-tools>select{flex:1;min-width:0}.creator-search-toolbar .ranking-filter-panel{width:100%}.creator-search-toolbar .ranking-filter-fields{min-width:0;width:min(280px,calc(100vw - 68px));box-sizing:border-box}}

.refine-layout>section{min-width:0}.refine-image-dialog .refine-layout{grid-template-columns:minmax(0,.85fr) minmax(0,1.6fr)}.refine-image-dialog .refine-comparison img{height:420px}.refine-image-dialog .refine-comparison [data-empty]{min-height:320px;padding:24px;display:grid;place-items:center;box-sizing:border-box}.refine-image-dialog .refine-loading{min-height:320px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:16px;padding:20px;text-align:center}.refine-status{padding:14px 16px;border:1px solid #806099;border-radius:12px;background:#32233e;color:#eee3f7;overflow-wrap:anywhere}.refine-status[data-kind=error]{background:#4a232d;border-color:#d07388;color:#ffd5de}.refine-status[data-kind=success]{background:#1d3e30;border-color:#569d76;color:#c1f4d6}.refine-image-dialog textarea[aria-invalid=true]{border:2px solid #e58da0}.refine-image-dialog [data-generate]{display:inline-flex;align-items:center;gap:8px}.refine-image-dialog .dialog-top{align-items:flex-start}.refine-image-dialog .dialog-top>[data-close]{flex-shrink:0}@media(max-width:760px){.refine-image-dialog .refine-layout{grid-template-columns:1fr}.refine-image-dialog .refine-comparison img{height:280px}.refine-image-dialog .refine-loading,.refine-image-dialog .refine-comparison [data-empty]{min-height:240px}.refine-image-dialog .refine-tabs,.refine-image-dialog .dialog-actions{flex-wrap:wrap}}

/* Reliable saves and story reference tools. */
#workspace-save-status{position:fixed;bottom:12px;left:50%;transform:translateX(-50%);z-index:1200;max-width:min(760px,calc(100vw - 32px));padding:10px 16px;border:1px solid #8c70aa;border-radius:12px;box-shadow:0 5px 25px #0009;font-size:13px;pointer-events:none;box-sizing:border-box}.save-progress{background:#2e253b;color:#eadffa}.save-alert{background:#553039;color:#ffe0e7;border-color:#d68698!important}.saved-story-heading{display:flex;align-items:center;gap:16px;min-width:0}.saved-story-avatar{width:58px;height:58px;border-radius:50%;overflow:hidden;flex-shrink:0;display:grid;place-items:center;background:#433153}.saved-story-avatar img{width:100%;height:100%;object-fit:cover}.character-workshop-cta{padding:15px 24px;border:1px solid #e5c9ff;box-shadow:0 0 22px #ab7ed442;font-weight:700}.story-reference-tabs{display:flex;gap:6px;margin:0 0 14px!important;flex-wrap:wrap}.story-reference-tabs button{padding:9px 13px;border-radius:9px;font-size:13px}.story-reference-tabs button[aria-pressed=true]{background:#b99af4;color:#20132e}.story-cast-panel [hidden]{display:none!important}.story-note-entry{padding:12px 0;border-bottom:1px solid #594467;overflow-wrap:anywhere}.story-note-entry p{white-space:pre-wrap;font-size:13px}.story-note-entry small{font-size:11px;color:#b8a5ce}.route-notes{max-height:none;overflow:visible}.route-notes input,.story-history-panel input{width:100%;min-width:0;box-sizing:border-box}.route-notes textarea{min-height:100px;font-size:13px}.route-notes details{margin-top:18px}.route-history article p{font-size:12px;line-height:1.6;white-space:pre-wrap}.route-history article small{display:block;color:#b8a5ce}.route-history article button{font-size:11px;padding:7px 10px;margin:4px}.story-conversation{position:relative}.chat-jump-bottom{position:absolute;bottom:270px;left:50%;transform:translateX(-50%);z-index:9;background:#211b29e8;color:#b9abc8;border:1px solid #55445f;border-radius:24px;box-shadow:0 2px 8px #0005;padding:7px 14px;font-size:12px}.chat-jump-bottom[hidden],#workspace-save-status[hidden]{display:none}.history-highlight{outline:2px solid #c7a6fa;outline-offset:3px}.story-history-panel .route-history{max-height:52dvh;overflow:auto}.route-dialogue-text[data-message-index]{cursor:pointer}@media(max-width:780px){.story-cast-panel.cast-visible{max-height:60dvh}.chat-jump-bottom{bottom:230px}}

@media(max-width:1100px){.story-stage.cast-visible{grid-template-columns:minmax(0,1fr) minmax(230px,32%)}.story-stage.cast-visible .story-profile{display:none}.story-stage.cast-visible .story-conversation{grid-column:1;grid-row:1}.story-stage.cast-visible .story-cast-panel{display:block;position:static;grid-column:2;grid-row:1;width:auto;max-height:none;min-height:0;overflow:auto}}@media(max-width:650px){.story-stage.cast-visible{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) minmax(160px,35%)}.story-stage.cast-visible .story-cast-panel{grid-column:1;grid-row:2;border-left:0;border-top:1px solid #594467}.story-stage.cast-visible .story-conversation{grid-column:1;grid-row:1}.story-reference-tabs{position:sticky;top:0;background:#191420;z-index:2;padding-bottom:7px}.story-stage.cast-visible .route-history{max-height:none}}

.chat-jump-bottom:hover{background:#35283f;color:#e2d4ef;border-color:#80678f}.chat-jump-bottom:focus-visible{outline:2px solid #ad8fca;outline-offset:3px}
/* Tester release: fit the reading area and composer inside the visible browser viewport. */
body.story-mode{height:var(--chat-vh,100dvh);min-height:0;overflow:hidden}
body.story-mode .app,body.story-mode main{height:100%;min-height:0;overflow:hidden}
body.story-mode main{display:flex;flex-direction:column}
body.story-mode #content.chat-content{flex:1;min-height:0;display:flex;flex-direction:column;box-sizing:border-box;padding-bottom:max(8px,env(safe-area-inset-bottom))}
body.story-mode .story-topbar{height:auto;min-height:46px;flex:0 0 auto;gap:8px;flex-wrap:wrap;padding:6px 0;box-sizing:border-box}
body.story-mode .story-topbar>button.secondary{font-size:11px;padding:6px 9px}
body.story-mode .story-stage{height:auto;min-height:0;flex:1}
body.story-mode .story-chat-header{height:auto;min-height:64px;flex-wrap:wrap;padding:10px 16px;box-sizing:border-box}
body.story-mode .story-composer-area{padding:8px 16px;min-height:0;max-height:46%;overflow:auto}
body.story-mode .story-composer textarea#message{height:clamp(65px,12dvh,130px);min-height:55px;max-height:20dvh;outline-color:#b89adf}
body.story-mode .story-transcript{overscroll-behavior:contain;scroll-padding-bottom:20px}
body.story-mode .story-composer-hint{margin:6px 0 0}
#prism-assistant.writing-helper-panel{inset:auto 18px 18px auto;margin:0;width:min(440px,42vw);max-height:calc(var(--chat-vh,100dvh) - 80px);overflow:auto;z-index:70;box-shadow:0 10px 35px #0007}
body:has(#prism-assistant.writing-helper-panel[open]) .story-conversation{padding-right:min(450px,33vw)}
#prism-assistant.writing-helper-panel textarea{min-height:90px}
#prism-assistant.writing-helper-panel #prism-draft{min-height:130px!important;max-height:25dvh}
.tester-tool-panel{position:fixed;right:16px;top:64px;width:min(520px,calc(100vw - 32px));max-height:calc(var(--chat-vh,100dvh) - 90px);overflow:auto;z-index:1500;background:#211b2b;border:1px solid #76608e;border-radius:16px;padding:20px;box-sizing:border-box;box-shadow:0 12px 40px #0008}
.tester-tool-panel article,.staff-tools article,.staff-tools details{padding:12px;border-bottom:1px solid #54405f}
.tester-tool-panel small{display:block;color:#b9a8ca}.tester-tool-panel textarea{width:100%;min-height:120px}.report-text{white-space:pre-wrap;overflow-wrap:anywhere}
.staff-tools{margin:24px 0;padding:20px;border:1px solid #54405f;border-radius:14px}.staff-tools form{max-width:650px;margin-bottom:20px}
#provider-outage-banner{position:fixed;top:8px;left:50%;transform:translateX(-50%);z-index:1600;background:#4c3541;color:#fff1f4;border:1px solid #c893a2;padding:10px 15px;border-radius:12px;display:flex;align-items:center;gap:12px;max-width:90vw}
.notes-context-view{padding:10px;border:1px solid #564067;border-radius:10px;margin-bottom:14px}.stop-reply{font-size:12px;margin:6px;max-width:100%;overflow-wrap:anywhere}
/* Use a clean portrait region of the reference sheet, without its baked-in selection badge. */
.portrait-style:first-of-type .portrait-style-thumbnail{background-size:400% 260%;background-position:87% 43%}
.portrait-style:hover:not(:has(input:checked)){border-color:#8b759b}
@media(max-width:900px){#prism-assistant.writing-helper-panel{width:min(380px,48vw);right:8px;bottom:8px;padding:16px}body:has(#prism-assistant.writing-helper-panel[open]) .story-conversation{padding-right:0}body.story-mode .story-chat-header{gap:7px}body.story-mode .story-chat-header>button,body.story-mode .story-chat-header select{font-size:11px;padding:7px;max-width:100%}}
@media(max-width:650px){#prism-assistant.writing-helper-panel{width:calc(100vw - 16px);max-height:44%;top:auto;bottom:8px}body:has(#prism-assistant.writing-helper-panel[open]) .story-stage{padding-bottom:0}body.story-mode .story-composer-area{max-height:43%;padding:6px 8px}.story-topbar .story-type-controls{margin-left:0}.story-topbar{letter-spacing:0}.story-topbar>span{display:none}.story-chat-header #undo-turn{margin-left:0}.story-chat-header .story-round-avatar{display:none}}

/* One live selection indicator; exclude the checkmark printed in the reference artwork. */
.portrait-style:first-of-type .portrait-style-thumbnail{background-size:388.84% 353.76%;background-position:79.71% 35.56%}
.portrait-style:hover:not(:has(input:checked)){border-color:#8b759b}
.portrait-prompt-disclosure{margin:18px 0;padding:12px 14px;border:1px solid #65536f;border-radius:10px;background:#1b1523}
.portrait-prompt-disclosure summary{cursor:pointer;color:#d7b8f4;font-weight:600}
.portrait-prompt-disclosure[open] summary{margin-bottom:14px}
.portrait-prompt-disclosure textarea{min-height:230px;max-height:45dvh;resize:vertical;box-sizing:border-box}
#portrait-prompt-count{text-align:right;font-variant-numeric:tabular-nums;margin:4px 0}

#chat-feedback-dialog{width:min(640px,94vw);max-height:88dvh;overflow:auto;box-sizing:border-box}#chat-feedback-dialog textarea{width:100%;min-height:140px;box-sizing:border-box}.feedback-message-preview{white-space:pre-wrap;overflow-wrap:anywhere;max-height:28dvh;overflow:auto;background:#141019;border:1px solid #594467;border-radius:10px;padding:14px;margin:12px 0;font-size:13px;line-height:1.7}.chat-feedback-entry{padding:14px 0;border-bottom:1px solid #594467}.chat-feedback-entry summary{cursor:pointer;font-weight:600}.chat-feedback-entry small{display:block;color:#baabcb;overflow-wrap:anywhere}
.report-workspace{margin:24px 0;padding:22px;border:1px solid #574164;border-radius:16px;background:#1c1724}.report-filters{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:16px 0}.report-filters [data-report-tabs]{display:flex;gap:6px;flex-wrap:wrap}.report-filters [aria-pressed=true]{background:#b99af4;color:#20132e}.report-filters form{display:flex;gap:8px;flex:1;min-width:210px;margin:0}.report-filters input{margin:0;min-width:0}.report-workspace-grid{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(260px,1fr);gap:18px}.report-list-row{display:grid;grid-template-columns:90px minmax(0,1fr) 54px 85px;gap:10px;width:100%;text-align:left;padding:14px 10px;border:1px solid #4a3a57;border-radius:9px;margin:0 0 7px;align-items:center;font-size:12px}.report-list-row[aria-pressed=true]{background:#4c345f;border-color:#bb94e3}.report-list-row small,.report-detail small,.report-audit small{display:block;font-size:10px;color:#baacc9;overflow-wrap:anywhere}.report-priority{border:1px solid #6f567f;border-radius:6px;padding:4px;text-align:center}.report-priority.high{border-color:#a17d32;color:#e9c777}.report-detail{border:1px solid #5d456d;border-radius:12px;padding:18px;overflow-wrap:anywhere;min-width:0}.report-detail h3{margin:0 0 10px}.report-detail textarea{width:100%;box-sizing:border-box;min-height:100px}.report-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}.report-actions button{font-size:12px;padding:9px 12px}.report-status-chip{display:inline-block;padding:4px 9px;border:1px solid #86639e;border-radius:8px;font-size:11px}.report-note{white-space:pre-wrap;padding:10px;background:#16101e;border-radius:8px}.report-audit{margin-top:22px;padding-top:18px;border-top:1px solid #574164}.report-table-wrap{overflow:auto}.report-audit table{width:100%;border-collapse:collapse;font-size:12px}.report-audit th,.report-audit td{text-align:left;padding:10px;border-bottom:1px solid #493650;vertical-align:top}.provider-status-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.provider-status-card{border:1px solid #5b4669;border-radius:10px;padding:16px;display:grid;gap:8px}.provider-status-card small{color:#b7a4c4}.provider-state.operational{color:#a5dbb8}.provider-state.outage{color:#f5acaa}.provider-state.unknown{color:#d0b887}.moderation-message-text{white-space:pre-wrap;overflow-wrap:anywhere}
/* The helper occupies reference space, leaving the conversation scrollable. */
body:has(#prism-assistant.writing-helper-panel[open]) .story-conversation{padding-right:0}
@media(min-width:651px){body:has(#prism-assistant.writing-helper-panel[open]) .story-stage{grid-template-columns:minmax(0,1fr) minmax(280px,32%)}body:has(#prism-assistant.writing-helper-panel[open]) .story-profile,body:has(#prism-assistant.writing-helper-panel[open]) .story-cast-panel{display:none}body:has(#prism-assistant.writing-helper-panel[open]) .story-conversation{grid-column:1;grid-row:1}#prism-assistant.writing-helper-panel{top:85px;bottom:18px;right:22px;width:max(280px,calc((100vw - 44px)*.32));max-height:calc(var(--chat-vh,100dvh) - 105px);padding:18px;box-sizing:border-box}}
@media(max-width:850px){.report-workspace-grid{grid-template-columns:minmax(0,1fr)}.report-list-row{grid-template-columns:75px minmax(0,1fr) 50px 70px;font-size:11px}.provider-status-grid{grid-template-columns:1fr}.report-workspace{padding:14px}}
@media(max-width:650px){body:has(#prism-assistant.writing-helper-panel[open]) #content.chat-content{padding-bottom:calc(var(--chat-vh,100dvh)*.42)}#prism-assistant.writing-helper-panel{width:calc(100vw - 16px);max-height:40%;right:8px;bottom:8px;top:auto}.report-list-row{grid-template-columns:65px minmax(0,1fr) 45px}.report-list-row>span:last-child{grid-column:2/4}}
#message-actions.message-context-menu{max-height:calc(var(--chat-vh,100dvh) - 16px);overflow-y:auto}
@media(max-width:650px){#prism-assistant.writing-helper-panel{max-height:calc(var(--chat-vh,100dvh)*.4)}}

/* Rotating world art stays behind the existing sidebar controls. */
.sidebar{isolation:isolate}
.sidebar-world-art{display:none;position:absolute;bottom:0;left:0;width:100%;height:min(78%,650px);overflow:hidden;pointer-events:none;z-index:-1}
.sidebar-world-art img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;opacity:0;transition:opacity 1.6s ease}
.sidebar-world-art img.visible{opacity:1}
.sidebar-world-art:after{content:'';position:absolute;inset:0;background:linear-gradient(to bottom,#12131c 0%,#12131c40 28%,transparent 48%,#12131c55 78%,#12131ccc 100%)}
@media(min-width:761px){.sidebar-world-art{display:block}.sidebar:has(.sidebar-world-art img.visible){background:#12131c}.sidebar:has(.sidebar-world-art) .private-card{background:#15121edb}}
@media(prefers-reduced-motion:reduce){.sidebar-world-art img{transition:none}}

/* Staff review workspace — concept-art layout, scoped away from player screens. */
.staff-workspace{--staff-line:#72567f;--staff-muted:#c0b0ca;min-width:0;border:1px solid #654678;border-radius:18px;background:radial-gradient(ellipse at 12% 100%,#48305040,transparent 65%),linear-gradient(135deg,#1d1427,#100e19);padding:22px;color:#f3eaf8}
.staff-workspace-header{display:flex;align-items:center;justify-content:space-between;gap:16px;height:auto;padding:0 0 20px;margin-bottom:20px;border-bottom:1px solid var(--staff-line);background:none;font-size:14px;letter-spacing:normal}
.staff-workspace h1,.staff-workspace h2,.staff-workspace h3{font-family:Georgia,'Times New Roman',serif;color:#ead7f6;letter-spacing:-.02em}.staff-workspace h1{font-size:34px;margin:0}.staff-workspace h2{font-size:29px;margin:0}.staff-workspace h3{font-size:23px}.staff-workspace .row{flex-wrap:wrap}.staff-role-badge{display:inline-block;white-space:nowrap;border:1px solid #a274c0;border-radius:15px;padding:5px 13px;background:linear-gradient(#674080,#3e2454);font:12px 'DM Sans',sans-serif;color:#f3dcff;letter-spacing:0}
.staff-workspace-body{display:grid;grid-template-columns:170px minmax(0,1fr);gap:22px;align-items:start}.staff-navigation{display:flex;flex-direction:column;gap:9px;margin:0;position:sticky;top:24px}.staff-navigation button{display:flex;align-items:center;gap:11px;width:100%;margin:0;padding:12px 11px;text-align:left;font:14px 'DM Sans',sans-serif;letter-spacing:0;border:1px solid transparent;border-radius:9px;color:#e7dcef;background:transparent}.staff-navigation button>span{font-size:22px;line-height:1;width:23px}.staff-navigation button[aria-pressed=true]{background:linear-gradient(120deg,#75429c,#44215e);border-color:#a477bf;box-shadow:inset 0 1px #ffffff20}.staff-navigation button:hover{background-color:#59366955}.staff-main{min-width:0}.staff-main>[hidden]{display:none!important}.staff-locked{padding:24px;border:1px solid #665071;border-radius:12px;line-height:1.7}.staff-workspace .admin-creator-management,.staff-workspace .admin-banner,.staff-workspace .admin-world-picker{background:#241b2d;border:1px solid #6b507b;border-radius:13px;padding:20px;margin:0 0 20px}.staff-workspace .admin-banner{gap:20px}.staff-workspace [data-staff-pane=content]>.section-heading{margin-top:20px}.staff-workspace input,.staff-workspace textarea,.staff-workspace select{background:#17121f;border-color:#725b80;color:#eee4f5}.staff-workspace button:focus-visible{outline:2px solid #e6c9ff;outline-offset:3px}.staff-workspace .primary{background:linear-gradient(#ad5ce8,#7b30b9);border:1px solid #be8ce8;color:white;box-shadow:inset 0 1px #ffffff30}.staff-workspace .secondary{background:#1b1425;border:1px solid #9d7bb0;color:#f2e5fa}.staff-workspace .text-button{color:#d6a5f4;text-decoration:underline;text-underline-offset:3px}.staff-workspace .small{color:var(--staff-muted);line-height:1.6}
.staff-workspace .report-workspace{margin:0;padding:0;border:0;background:none;border-radius:0}.staff-workspace .report-workspace>.section-heading{gap:14px;align-items:center;margin:0 0 16px}.staff-workspace .report-filters{justify-content:space-between;align-items:center;margin:0 0 8px;gap:12px}.staff-workspace [data-report-tabs]{gap:5px}.staff-workspace [data-report-tab]{padding:9px 13px;min-height:41px;font-size:13px;white-space:nowrap;border-color:#5c436d;border-radius:10px}.staff-workspace [data-report-tab][aria-pressed=true]{background:linear-gradient(#d59aff,#ae6ee5);border-color:#daaaff;color:#1b0829;box-shadow:inset 0 1px 4px #ffffff90}.report-tab-count{display:inline-grid;place-items:center;border-radius:12px;padding:1px 6px;margin-left:4px;background:#79459a;color:white;font-size:12px}.staff-workspace .report-filters form{flex:0 1 310px;min-width:220px;align-items:center;border:1px solid #886c9a;border-radius:9px;padding:0 10px;gap:7px;background:#21192a}.report-filters form>span{font-size:25px;color:#d9c5e8}.staff-workspace .report-filters input{background:none;border:0;padding:10px 0;font-size:12px;min-width:0}.staff-workspace .report-filters form button{font-size:11px;padding:5px 0}.staff-workspace [data-report-status]{font-size:11px;margin:0 0 12px}.staff-workspace .report-workspace-grid{grid-template-columns:minmax(0,1fr);gap:16px;align-items:start}.report-list-panel{border:1px solid #80628f;border-radius:12px;overflow:auto;min-width:0;min-height:300px;background:#14101c}.report-list-head,.staff-workspace .report-list-row{display:grid;grid-template-columns:88px minmax(115px,1fr) 60px 70px 61px;gap:10px;align-items:center;min-width:455px}.report-list-head{padding:13px 12px;color:#eee2f4;font-size:11px;background:#2c2237;border-bottom:1px solid #735780}.staff-workspace .report-list-row{margin:0;border:0;border-bottom:1px solid #4c3a59;border-radius:0;padding:13px 12px;min-height:65px;font-size:12px;background:transparent;color:#f4eaf9}.staff-workspace .report-list-row[aria-pressed=true]{background:linear-gradient(100deg,#60397d,#392547);box-shadow:inset 0 0 0 1px #c78feb;border-radius:8px}.report-list-row:hover{background-color:#56346a55}.staff-workspace .report-list-row small{font-size:10px;margin-top:4px;color:#c8b5d5}.report-row-summary{line-height:1.5;overflow-wrap:anywhere}.report-type{line-height:1.6}.staff-workspace .report-priority{padding:3px 6px;font-size:11px;border-radius:6px;background:#45324f}.staff-workspace .report-priority.high{background:#614319;border:1px solid #dfab38;color:#ffe39a}.staff-workspace .report-status-chip{border:1px solid #8a64a0;background:#4d315c;padding:3px 7px;border-radius:6px;font-size:10px;width:max-content;max-width:100%}.report-received{font-size:11px;color:#d5c2e0}.report-pagination{display:flex;justify-content:space-between;gap:10px;padding:9px 12px;font-size:11px}.report-pagination button{padding:5px;font-size:11px}.report-empty{padding:35px 18px;text-align:center;color:#bfaccb}.report-empty>span{font-size:30px;color:#bc8bd6}.report-empty h3{font-size:18px;margin:12px 0}.report-empty p{font-size:12px;line-height:1.6}.staff-workspace .report-detail{background:linear-gradient(135deg,#2a2033,#1e1727);border-color:#80628f;border-radius:12px;padding:19px}.report-detail-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}.staff-workspace .report-detail h3{margin:0;font-size:24px}.report-detail-summary{font-family:Georgia,serif;font-size:19px;margin:12px 0;white-space:pre-wrap;overflow-wrap:anywhere}.report-detail>p{font-size:13px;line-height:1.65}.report-preview-box{border:1px solid #60496e;border-radius:9px;background:#34283e88;padding:10px;margin:15px 0}.report-preview-box>span{font-size:11px;color:#e4d2ee}.staff-workspace .feedback-message-preview{margin:7px 0 0;padding:10px;max-height:220px;overflow:auto;background:#15101d;border:1px solid #51405e;border-radius:6px;font-size:12px;white-space:pre-wrap;line-height:1.7}.staff-workspace .report-detail label{color:#f0e0f7;font-size:12px;margin-top:16px}.staff-workspace .report-detail textarea{margin-top:7px;min-height:90px}.staff-workspace .report-actions{align-items:center;gap:10px;margin-top:18px}.staff-workspace .report-actions button{font-size:13px;padding:10px 15px;border-radius:8px}.report-actions [data-review-action=note]{margin-left:auto}.report-staff-notes{margin-top:16px;border-top:1px solid #594264;padding-top:12px;font-size:12px}.report-staff-notes summary{color:#c7afd6;cursor:pointer}.staff-workspace .report-note{font-size:12px;white-space:pre-wrap}.report-action-notice{margin:16px 0 0}.staff-workspace .report-audit{margin-top:23px;border:1px solid #80628f;background:linear-gradient(130deg,#2a2033,#19121f);border-radius:12px;padding:16px}.staff-workspace .report-audit h2{font-size:25px}.report-audit .section-heading{margin-bottom:16px;gap:12px;flex-wrap:wrap}.staff-workspace .report-table-wrap{border:1px solid #624b71;border-radius:10px;max-height:360px}.staff-workspace .report-audit th{background:#2c2237;position:sticky;top:0;white-space:nowrap}.staff-workspace .report-audit td{font-size:12px;max-width:260px;overflow-wrap:anywhere}.staff-workspace .report-audit table{min-width:600px}.staff-workspace .report-audit td button{font-size:12px;padding:0}.staff-workspace [data-staff-pane=reports] .report-audit tbody tr:nth-child(n+7){display:none}.staff-workspace [data-staff-pane=reports] .report-audit>.report-pagination{display:none}.staff-workspace [data-staff-pane=activity] .report-audit{margin-top:0}.staff-workspace [data-staff-pane=activity] [data-full-log]{display:none}.staff-workspace [data-staff-pane=activity] .report-table-wrap{max-height:65vh}.moderation-access{display:flex;gap:18px;align-items:center;padding:20px;margin-top:20px;border:1px solid #80628f;border-radius:12px;background:#2a2033}.moderation-access>span{font-size:36px;color:#dcb8f0}.moderation-access h3{font-size:20px;margin:0 0 5px}.moderation-access p{font-size:12px;margin:0;color:#d6c2df}.staff-moderator .staff-workspace-body{grid-template-columns:minmax(0,1fr)}.staff-moderator .staff-navigation{position:static;flex-direction:row;flex-wrap:wrap;border-bottom:1px solid #5e456c;padding-bottom:14px}.staff-moderator .staff-navigation button{width:auto}.staff-moderator .report-actions [data-review-action=resolve],.staff-moderator .report-actions [data-review-action=escalate]{flex:1}
@media(min-width:1550px){.staff-admin .report-workspace-grid{grid-template-columns:minmax(455px,1.2fr) minmax(300px,.9fr)}}
@media(max-width:1000px){.staff-workspace{padding:16px}.staff-workspace-body{grid-template-columns:minmax(0,1fr)}.staff-navigation{position:static;flex-direction:row;flex-wrap:wrap;border-bottom:1px solid #5e456c;padding-bottom:14px;gap:5px}.staff-navigation button{width:auto;font-size:12px;padding:8px}.staff-navigation button>span{font-size:17px;width:18px}.staff-workspace h1{font-size:29px}.staff-workspace h2{font-size:25px}}
@media(max-width:650px){.staff-workspace-header{align-items:flex-start;flex-wrap:wrap}.staff-workspace{padding:14px;border-radius:12px}.staff-workspace h1{font-size:27px}.staff-workspace .report-filters form{flex:1 1 100%;min-width:0}.staff-workspace .report-workspace-grid{grid-template-columns:minmax(0,1fr)}.staff-workspace .report-list-row>span:last-child{grid-column:auto}.staff-workspace .report-actions button{flex:1}.report-actions [data-review-action=note]{margin-left:0}.staff-workspace .report-audit{padding:12px}.staff-workspace .report-detail{padding:15px}.report-list-panel{min-height:220px}}

.staff-identity-form{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:18px 0;border-bottom:1px solid #645174;margin-bottom:20px}.staff-identity-form label{flex:1;min-width:180px}.staff-identity-form p{flex-basis:100%;margin:0}.official-staff-reply{border:1px solid #8866a1;border-radius:12px;padding:16px;margin:12px 0;background:#251c32}.official-staff-reply p{white-space:pre-wrap}.staff-player-reply{margin-top:24px;border-top:1px solid #645174;padding-top:20px}.feedback-inbox-entry{border-bottom:1px solid #645174;padding:18px 0}#my-feedback-dialog{width:min(780px,94vw);max-height:85dvh;overflow:auto}nav button.staff-mode-active{border:1px solid #bb93ef;background:#46305c;box-shadow:inset 3px 0 #c6a4ff}nav button.staff-mode-active small{display:block;font-size:11px;margin-top:4px;color:#dec6ff}

.feedback-unread-count{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;margin-left:9px;padding:0 6px;border-radius:99px;background:#bda0ed;color:#20142e;font-size:12px;font-weight:700}.official-staff-reply[data-unread-reply]{border-color:#c6a4ff}

/* Your Space profile and library */
.space-page-heading{display:flex;align-items:center;justify-content:space-between;margin:8px 0 28px}.space-page-heading h1{margin:8px 0;font-size:clamp(32px,4vw,48px);letter-spacing:-1.6px}.space-page-heading p{margin:0;color:#aaa1ba}.space-heading-mark{font-size:80px;color:#b99ade;opacity:.6;padding-right:20px}.space-profile-redesigned.space-profile-panel{position:relative;max-width:none;display:block;padding:30px;border-radius:22px;background:radial-gradient(ellipse at 95% 0, #59376e44,transparent 60%),linear-gradient(120deg,#231b30,#17141f);overflow:hidden;box-shadow:0 12px 32px #0002;border-color:#544163}.space-profile-redesigned:before{content:'';position:absolute;left:0;right:0;top:0;height:4px;background:linear-gradient(90deg,#bba0ec,#754798,transparent)}.space-profile-redesigned .space-profile-row{flex-direction:row;align-items:center;gap:24px;flex-wrap:wrap}.space-profile-redesigned .space-profile-info{flex:1;min-width:180px}.space-profile-kicker{font-size:10px;letter-spacing:2px;color:#bca2d8;font-weight:700}.space-profile-redesigned .space-profile-info h2{font-size:clamp(24px,3vw,32px);margin:7px 0 10px;letter-spacing:-.7px}.space-profile-redesigned .space-creator-bio{color:#d0c5dd;max-width:650px;font-size:15px;line-height:1.65}.space-profile-meta{display:flex;gap:14px;align-items:center;flex-wrap:wrap;margin-top:16px}.space-profile-redesigned #creator-visibility{margin:0;font-size:12px;border-radius:20px;padding:6px 12px;min-height:34px}.space-profile-redesigned .space-sign-out{align-self:flex-start;border:0;background:transparent;font-size:12px;color:#a99ab9;padding:6px}.space-profile-redesigned .space-profile-editor{margin:24px 0 0;padding-top:18px;border-top:1px solid #ffffff12}.space-profile-editor summary{display:flex;align-items:center;justify-content:space-between;cursor:pointer;color:#d8c0f5;font-size:14px;font-weight:600;list-style:none}.space-profile-editor summary::-webkit-details-marker{display:none}.space-profile-editor[open] summary span{transform:rotate(180deg)}.space-profile-redesigned form{border:0;padding:12px 0 0;max-width:760px}.space-profile-redesigned form input,.space-profile-redesigned form textarea{background:#121019;border-color:#4c3c5d;border-radius:10px}.space-profile-redesigned form label{font-size:13px}.space-profile-redesigned form label span{float:right;font-size:11px}.space-library-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:32px 0 16px}.space-library-heading h2{font-size:21px;margin:0}.space-library-heading>span{color:#94869f;font-size:12px}.space-header .space-folder-tabs{display:flex;gap:7px;flex-wrap:wrap;margin:0 0 24px;border:1px solid #44354f;padding:7px;border-radius:15px;background:#17131e}.space-header .space-folder-tabs button{flex:1;justify-content:center;gap:9px;min-width:108px;border:0;border-radius:10px;background:transparent;padding:13px 16px;color:#b9acc8;white-space:nowrap}.space-header .space-folder-tabs button[aria-pressed=true]{background:#bba0ec;color:#20142f;box-shadow:0 2px 10px #0003}.space-header .space-folder-tabs button:hover{background:#3d2d4e;color:#eee0ff}.space-header .space-folder-tabs button[aria-pressed=true]:hover{background:#c8acf7;color:#20142f}.space-tab-icon{font-size:20px;line-height:1}@media(max-width:650px){.space-profile-redesigned.space-profile-panel{padding:22px 18px}.space-profile-redesigned .space-profile-row{gap:16px}.space-profile-redesigned .space-sign-out{margin-left:auto}.space-heading-mark,.space-library-heading>span{display:none}.space-profile-meta{gap:8px}.space-header .space-folder-tabs button{min-width:85px;padding:11px 8px;font-size:12px}.space-page-heading{margin-bottom:20px}}

/* Header studio access and private save information */
.header-save-info{display:flex;flex-direction:column;gap:5px;padding:12px 0;min-width:0;max-width:540px}.header-save-info strong{font-weight:500;font-size:12px;color:#ddd4ec}.header-save-info>span{font-size:11px;line-height:1.5;color:#a49ab7}.staff-studio-button{border:1px solid #78618f;border-radius:9px;background:#2a2136;color:#dfc7ff;font-size:12px;padding:10px 15px;white-space:nowrap;text-align:center}.staff-studio-button:hover{background:#3c2b50;border-color:#bd9de0}.staff-studio-button.staff-mode-active{background:#45305d;border-color:#c09be8;box-shadow:inset 3px 0 #c6a4ff}.staff-studio-button small{display:block;font-size:10px;margin-top:4px;color:#d0b3ed}main>header{gap:20px;height:auto;min-height:80px}.header-right{flex-shrink:0}@media(max-width:760px){main>header{flex-wrap:wrap;padding:14px 20px;gap:12px}.header-save-info{max-width:100%}.header-right{gap:14px;flex-wrap:wrap}.staff-studio-button{font-size:11px;padding:9px 12px}}

.staff-studio-button{display:inline-flex;align-items:center;gap:12px;border-color:#645373;background:#211b2a;color:#c5b5d5}.studio-button-label{font-weight:600}.studio-mode-status{display:inline-flex;align-items:center;gap:5px;padding:4px 7px;border:1px solid #6e5b7e;border-radius:20px;font-size:9px;font-weight:800;letter-spacing:.7px;color:#b9acc5;background:#15111b}.studio-mode-dot{width:6px;height:6px;border-radius:50%;background:#86788f}.staff-studio-button.staff-mode-active{background:linear-gradient(120deg,#614080,#39254f);border:2px solid #ceaaf8;color:#fff;box-shadow:0 0 0 3px #b893ed18}.staff-studio-button.staff-mode-active .studio-mode-status{background:#d3b8f5;border-color:#dfc9fb;color:#28163b}.staff-studio-button.staff-mode-active .studio-mode-dot{background:#315e49;box-shadow:0 0 0 2px #315e4920}.staff-studio-button.staff-mode-active:hover{background:linear-gradient(120deg,#704c91,#493062)}@media(max-width:480px){.staff-studio-button{gap:8px}.studio-mode-status{font-size:8px}}

#site-announcement{position:relative;z-index:20;display:flex;align-items:center;justify-content:center;gap:14px;padding:14px 24px;background:#3d2d50;border-bottom:1px solid #bc95df;color:#f2e6ff;font-size:14px;line-height:1.6}#site-announcement>span:last-child{white-space:pre-wrap;overflow-wrap:anywhere;max-width:1100px}.announcement-enabled{display:flex;gap:10px;align-items:center}.announcement-enabled input{width:auto;margin:0}.announcement-schedule{display:grid;grid-template-columns:1fr 1fr;gap:16px}.announcement-preview{background:#3d2d50;border:1px solid #bc95df;border-radius:10px;padding:16px;margin:16px 0}.announcement-preview p{white-space:pre-wrap;overflow-wrap:anywhere}@media(max-width:600px){.announcement-schedule{grid-template-columns:1fr}#site-announcement{padding:12px 16px;font-size:12px}}

.header-feedback-button{position:relative;flex-shrink:0;display:grid;place-items:center;width:42px;height:42px;border:1px solid #68527d;border-radius:12px;background:#2a2136;color:#d4b9f3;margin-right:-6px}.header-feedback-button:hover{background:#443052;border-color:#bf98e5;color:#f4e8ff}.header-feedback-button .feedback-unread-count{position:absolute;right:-7px;top:-7px;margin:0;min-width:18px;height:18px;font-size:10px;padding:0 4px;border:2px solid #101119}main>header>.header-save-info{margin-right:auto}@media(max-width:760px){.header-feedback-button{width:38px;height:38px;margin-right:0}main>header>.header-save-info{flex:1;min-width:160px;max-width:calc(100% - 58px)}}

/* Membership and billing */
.billing-page{margin:34px 0 20px;color:#eee8f5}.billing-heading{display:flex;justify-content:space-between;align-items:center;gap:18px;margin-bottom:24px}.billing-heading h2{font-size:clamp(28px,3vw,40px);letter-spacing:-1px;margin:9px 0}.billing-heading p,.billing-plans-heading p{color:#aea2bd;line-height:1.6;margin:8px 0}.billing-preview-tag,.billing-current-pill,.billing-monthly{border:1px solid #655075;background:#2b2037;color:#dac1ef;font-size:11px;padding:8px 12px;border-radius:30px;white-space:nowrap}.billing-overview{border:1px solid #5b456e;border-radius:18px;background:radial-gradient(ellipse at top right,#58366b55,transparent 70%),#211a2b;overflow:hidden}.billing-membership{display:flex;align-items:center;gap:20px;padding:26px 28px}.billing-symbol{width:58px;height:58px;display:grid;place-items:center;border:1px solid #7e5b9a;border-radius:16px;font-size:40px;color:#c5a3e6;background:#31203f}.billing-label{font-size:9px;letter-spacing:1.5px;color:#b39ac9}.billing-membership h3{font-size:22px;margin:7px 0}.billing-membership p{color:#b7a8c8;font-size:13px;margin:6px 0}.billing-current-pill{margin-left:auto;background:#253329;border-color:#4b6653;color:#b9d8c3}.billing-account-facts{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid #493652;background:#17131f77;padding:20px 28px;gap:20px}.billing-account-facts>div{display:flex;flex-direction:column;gap:8px}.billing-account-facts span{font-size:11px;color:#aa9ab8}.billing-account-facts strong{font-size:13px;font-weight:500}.billing-plans-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:34px 0 30px}.billing-plans-heading h3{font-size:23px;margin:0}.billing-plans-heading p{font-size:12px}.billing-monthly{background:#15111c;border-color:#44324f;color:#bba8cc}.billing-plan-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}.billing-plan{position:relative;border:1px solid #51405e;border-radius:18px;background:linear-gradient(160deg,#231b2d,#17131e);padding:26px 24px;display:flex;flex-direction:column}.billing-featured{border-color:#c09cec;background:radial-gradient(ellipse at top,#68438d44,transparent 70%),#241b31;box-shadow:0 0 0 1px #b991db44}.billing-recommended{position:absolute;left:24px;right:24px;top:-13px;background:#bda0ec;color:#21142e;border-radius:20px;padding:6px;text-align:center;letter-spacing:1.5px;font-size:9px;font-weight:800}.billing-plan-top{min-height:110px}.billing-plan-gem{float:right;color:#baa0d6;font-size:28px}.billing-plan h3{font-size:24px;margin:0 0 12px}.billing-plan-top p{font-size:12px;color:#b1a0c0;line-height:1.6;max-width:210px;margin:0}.billing-price{display:flex;align-items:baseline;gap:8px;padding-bottom:22px;border-bottom:1px solid #56406477;flex-wrap:wrap}.billing-price strong{font-size:38px;letter-spacing:-1.4px;font-weight:600}.billing-price>span{font-size:12px;color:#aa98bd}.billing-allowance-label{color:#baa6ca;font-size:10px;text-transform:uppercase;letter-spacing:1px;margin:22px 0 4px}.billing-plan ul{list-style:none;padding:0;margin:0 0 24px}.billing-plan li{display:flex;align-items:baseline;justify-content:space-between;gap:8px;padding:12px 0;font-size:12px;border-bottom:1px solid #47355155;color:#c4b8d1}.billing-plan li strong{color:#f1e7ff;font-size:14px;font-weight:600}.billing-plan button{width:100%;padding:13px;margin-top:auto;cursor:default;opacity:.8}.billing-plan>small{text-align:center;font-size:9px;color:#a793b8;line-height:1.6;margin-top:12px}.billing-trial{display:flex;align-items:center;gap:18px;margin:24px 0 32px;border:1px solid #584568;border-radius:14px;padding:20px 24px;background:#21182c}.billing-trial>span:first-child{font-size:28px;color:#c5a8e4}.billing-trial h3{font-size:17px;margin:0 0 6px}.billing-trial p{font-size:12px;color:#bcaaca;margin:0;line-height:1.6}.billing-trial>.billing-preview-tag{margin-left:auto}.billing-bottom-grid{display:grid;grid-template-columns:1.2fr 1fr;gap:22px}.billing-explainer,.billing-history{padding:24px;border:1px solid #45354f;border-radius:16px;background:#18131f}.billing-bottom-grid h3{font-size:18px;margin:0 0 16px}.billing-explainer details{padding:14px 0;border-top:1px solid #44324f}.billing-explainer summary{font-size:12px;color:#d4bce9;cursor:pointer;line-height:1.7}.billing-explainer details p{color:#a999ba;font-size:12px;line-height:1.8;margin-bottom:0}.billing-history-empty{text-align:center;padding:18px 12px 25px}.billing-history-empty>span{font-size:32px;color:#967caa}.billing-history-empty h4{font-size:15px;margin:15px 0 10px}.billing-history-empty p,.billing-launch-note{font-size:12px;color:#a999ba;line-height:1.8}.billing-launch-note{padding-top:16px;border-top:1px solid #44324f;font-size:11px}@media(max-width:950px){.billing-plan{padding:24px 16px}.billing-price strong{font-size:30px}.billing-bottom-grid{grid-template-columns:1fr}.billing-heading{align-items:flex-start;flex-direction:column}}@media(max-width:680px){.billing-plan-grid{grid-template-columns:1fr;gap:28px}.billing-plan-top{min-height:85px}.billing-membership{flex-wrap:wrap;padding:22px 18px}.billing-current-pill{margin-left:0}.billing-account-facts{grid-template-columns:1fr;padding:18px;gap:15px}.billing-account-facts>div{flex-direction:row;justify-content:space-between}.billing-plans-heading{align-items:flex-start;flex-direction:column}.billing-trial{flex-wrap:wrap;padding:18px}.billing-trial>.billing-preview-tag{margin-left:0}.billing-explainer,.billing-history{padding:20px}}

/* Crystal credit packs and separate allowance balances */
.billing-balance-grid{display:grid;grid-template-columns:1.8fr 1fr;gap:20px}.billing-balance-grid .billing-membership{padding:23px}.billing-monthly-balances{padding:20px 24px;border-top:1px solid #574363}.billing-monthly-balances h4{margin:0 0 6px;font-size:15px}.billing-monthly-balances>p{color:#a996b9;font-size:11px;line-height:1.7;margin:0 0 18px}.billing-meter-row{display:grid;grid-template-columns:1.2fr 1fr auto;gap:14px;align-items:center;margin:16px 0;font-size:12px;color:#c4b3d4}.billing-meter-row strong{font-size:10px;font-weight:400;color:#9c8daa}.billing-meter-track{height:7px;border-radius:20px;background:#45334f66}.billing-credit-balance{position:relative;overflow:hidden;background:radial-gradient(ellipse at bottom,#59327355,transparent 75%),#21182d;border:1px solid #735187;border-radius:18px;padding:23px;display:flex;flex-direction:column;align-items:center;text-align:center}.billing-credit-balance .section-heading{width:100%;border-bottom:1px solid #644475;padding-bottom:16px;margin:0}.billing-credit-balance h3{font-size:17px;margin:0}.billing-credit-balance .section-heading>span{color:#c4a0e5}.billing-crystal-art{width:200px;max-width:100%;aspect-ratio:1;background-image:url('/assets/billing-crystals-v1.png');background-size:300% 100%;background-repeat:no-repeat;background-position:0 0}.billing-crystal-medium{background-position:50% 0}.billing-crystal-large{background-position:100% 0}.billing-credit-balance .billing-crystal-art{width:108px;margin:12px 0 -7px;opacity:.85}.billing-credit-total{font-size:26px;letter-spacing:-.5px;font-weight:600;color:#e0c5fa}.billing-credit-balance p{font-size:12px;color:#bca7cf;line-height:1.7}.billing-credit-balance small{font-size:10px;color:#a993bd;margin-top:auto;line-height:1.7}.billing-plan-top{min-height:95px}.billing-credit-shop{margin-top:40px;padding-top:4px;border-top:1px solid #554263}.billing-credit-shop .billing-plans-heading h3{font-size:clamp(26px,3vw,36px);letter-spacing:-1px}.billing-credit-packs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}.billing-credit-pack{position:relative;display:flex;flex-direction:column;align-items:center;padding:15px 24px 22px;border:1px solid #805799;border-radius:18px;background:radial-gradient(ellipse at 50% 25%,#64408933,transparent 70%),linear-gradient(140deg,#251b30,#17131e);overflow:hidden}.billing-credit-pack h4{font-size:25px;margin:0 0 8px;letter-spacing:-.5px}.billing-pack-price{font-size:21px;margin-bottom:18px;color:#e1d5ed}.billing-credit-pack button{width:100%;margin-top:auto;opacity:.7;cursor:default}.billing-credit-pack small{color:#a792b8;font-size:9px;margin-top:12px;text-align:center}.billing-best-value{position:absolute;right:14px;top:14px;z-index:1;background:#c8aaeb;color:#271736;padding:5px 8px;border-radius:8px;font-size:10px;font-weight:700}.billing-credit-rates{display:grid;grid-template-columns:repeat(4,1fr);border:1px solid #755687;border-radius:14px;background:#21182b;padding:18px 8px;margin:24px 0 16px}.billing-credit-rates>div{display:flex;align-items:center;justify-content:center;gap:12px;padding:4px 10px;border-right:1px solid #644672}.billing-credit-rates>div:last-child{border:0}.billing-credit-rates>div>span{font-size:27px;color:#c5a0e2}.billing-credit-rates p{font-size:10px;line-height:1.7;margin:0;color:#c8b8d5}.billing-credit-rates strong{display:block;font-size:13px;color:#efdcff}.billing-credit-policy{text-align:center;color:#bda9ce;font-size:12px;line-height:1.8;margin:16px 0 24px}.billing-credit-example{border:1px solid #654e76;border-radius:14px;padding:18px 22px;background:#21182b;margin-bottom:28px}.billing-credit-example summary{cursor:pointer;color:#cdb0e5;font-size:12px}.billing-credit-example>div{display:flex;align-items:center;gap:16px;margin-top:20px}.billing-credit-example>div>span{font-size:28px;color:#cca7ed}.billing-credit-example h4{margin:0 0 6px;font-size:15px}.billing-credit-example p{color:#b6a0c7;font-size:12px}.billing-credit-example button{margin-left:auto;opacity:.65;cursor:default}.billing-credit-example button+button{margin-left:0}.billing-credit-example>p{margin-bottom:0}@media(max-width:950px){.billing-balance-grid{grid-template-columns:1fr 1fr}.billing-balance-grid .billing-current-pill{display:none}.billing-balance-grid .billing-symbol{display:none}.billing-meter-row{grid-template-columns:1fr auto}.billing-meter-track{display:none}.billing-credit-rates{grid-template-columns:repeat(2,1fr);gap:16px}.billing-credit-rates>div:nth-child(2){border:0}.billing-credit-pack{padding:16px}.billing-credit-pack h4{font-size:21px}}@media(max-width:680px){.billing-balance-grid{grid-template-columns:1fr}.billing-credit-packs{grid-template-columns:1fr}.billing-credit-pack .billing-crystal-art{width:180px}.billing-credit-balance{padding:20px}.billing-credit-balance .billing-crystal-art{width:90px}.billing-credit-example>div{flex-wrap:wrap}.billing-credit-example button{margin-left:0}.billing-credit-rates>div{justify-content:flex-start}.billing-credit-shop .billing-plans-heading{gap:8px}.billing-meter-row{grid-template-columns:1fr auto}}

.device-history-settings{margin-top:24px}.device-history-settings>p{color:#b8a8c9;line-height:1.8}.device-memory-toggle{display:flex;align-items:center;gap:10px}.device-memory-toggle input{width:auto;margin:0}.device-memory-excerpt{white-space:pre-wrap;overflow-wrap:anywhere;padding:14px;background:#15111d;border:1px solid #4c385e;border-radius:10px;max-height:240px;overflow:auto;font-size:12px;line-height:1.7}.device-history-settings .row{flex-wrap:wrap}

/* Fill the composer beside the full height of its action buttons. */
body.story-mode .story-composer textarea#message{align-self:stretch;height:auto;max-height:none;margin:0}

body > dialog.training-dialog[open] {
  width: min(1240px, 88vw);
  max-width: none;
  max-height: calc(100dvh - 32px);
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  color: #f3f0f8;
  background: #181720;
  border: 1px solid #c19dec;
  border-radius: 18px;
  box-shadow: 0 24px 80px #080613a8;
  font-family: var(--sb-ui, 'Segoe UI', sans-serif);
}
body > .training-dialog::backdrop {
  background: #0b0913b8;
  backdrop-filter: blur(5px);
}
.training-dialog-layout {
  display: grid;
  grid-template-columns: minmax(0, 34fr) minmax(0, 66fr);
  min-height: min(660px, calc(100dvh - 36px));
}
.training-dialog-art {
  position: relative;
  overflow: hidden;
  background: #111027;
}
.training-dialog-art img, .training-dialog-art::after {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.training-dialog-art img {
  display: block;
  object-fit: cover;
  object-position: center 58%;
}
.training-dialog-art::after {
  content: '';
  background: linear-gradient(90deg, transparent 78%, #181720);
}
.training-dialog-content {
  display: grid;
  align-content: center;
  gap: clamp(14px, 1.5vw, 24px);
  padding: clamp(32px, 4.5vw, 66px) clamp(22px, 3vw, 40px) clamp(26px, 3.6vw, 52px) clamp(22px, 2.5vw, 38px);
  font-size: clamp(16px, 1.55vw, 23px);
  line-height: 1.45;
}
#training-dialog-title {
  margin: 0;
  color: inherit;
  font-family: inherit;
  font-size: clamp(29px, 4.25vw, 60px);
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.08;
}
#training-dialog-title span { display: block; }
.training-dialog-content p { margin: 0; }
.training-dialog-privacy {
  padding: clamp(14px, 2vw, 26px);
  background: #211c2d;
  border: 1px solid #c19dec;
  border-radius: 13px;
}
.training-dialog .training-dialog-privacy h3 {
  margin: 0 0 8px;
  color: #d1abf5;
  font-family: inherit;
  font-size: clamp(19px, 2.6vw, 35px);
  line-height: 1.15;
}
.training-dialog-privacy ul {
  margin: 0;
  padding-inline-start: 1.2em;
  list-style: disc;
}
.training-dialog-privacy li + li { margin-block-start: 4px; }
.training-dialog-status { color: #ffc1cd; }
.training-dialog-status:empty { display: none; }
.training-dialog-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 6px;
}
.training-dialog-actions button {
  min-height: 48px;
  padding: 11px 10px;
  border-radius: 11px;
  font-weight: 750;
  line-height: 1.25;
}
.training-dialog-actions .secondary {
  color: #f3f0f8;
  background: transparent;
  border-color: #e0d8ec;
}
.training-dialog-actions .secondary:hover { background: #30283d; }
.training-dialog-actions .primary {
  color: #211331;
  background: #cfabf5;
  border-color: #cfabf5;
}
.training-dialog-actions .primary:hover { background: #e2c9ff; }
.training-dialog-close {
  position: absolute;
  inset: 8px 10px auto auto;
  width: 44px;
  height: 44px;
  color: #ddd3eb;
  background: #181720b8;
  border-radius: 9px;
  font-size: 32px;
  line-height: 1;
}
.training-dialog-close:hover { background: #30283d; }
.training-dialog button:focus-visible { outline: 2px solid #e6ccff; outline-offset: 3px; }
@media (max-width: 680px) {
  body > dialog.training-dialog[open] { width: calc(100vw - 24px); }
  .training-dialog-layout { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .training-dialog-art { height: clamp(86px, 18dvh, 152px); }
  .training-dialog-art img { object-position: center 73%; }
  .training-dialog-art::after { background: linear-gradient(180deg, transparent 58%, #181720); }
  .training-dialog-content { padding: 14px 17px 22px; }
  #training-dialog-title { font-size: clamp(24px, 6.4vw, 38px); }
  .training-dialog-actions { gap: 9px; }
  .training-dialog-actions button { font-size: .9rem; }
}
.training-settings p{line-height:1.55}
.training-settings label{display:flex;align-items:center;gap:8px;margin:12px 0}
.training-settings input{width:auto;margin:0}
.training-settings .training-exclusions{margin:8px 0 14px;padding-inline-start:24px;list-style:disc;line-height:1.6}
.training-exclusions li+li{margin-block-start:4px}
.chat-credit-balance{display:inline-block;white-space:nowrap}
.story-topbar .chat-credit-balance{font-size:0.72rem}
.training-review summary{cursor:pointer;font-weight:600}
.training-review-card{border-top:1px solid #514464;padding:12px 0;overflow-wrap:anywhere}
.training-review-card h3{font-size:0.9rem;margin:8px 0 4px}
.training-review-card p{white-space:pre-wrap;max-height:220px;overflow:auto;margin:0 0 10px}
.training-review-card .row{flex-wrap:wrap}

.staff-invite-form{display:flex;align-items:end;flex-wrap:wrap;gap:12px}
.staff-invite-form label{flex:1 1 240px;min-width:0}
.staff-invite-form input,.staff-invite-form button{margin-bottom:0}
.staff-invite-list{list-style:none;margin:14px 0 0;padding:0}
.staff-invite-list li{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:12px;padding:12px 0;border-top:1px solid #51405f;overflow-wrap:anywhere}
.staff-invite-actions{align-items:center;flex-wrap:wrap;gap:8px}
.staff-invite-draft{padding:6px;color:#dcc8f6}
