/* Shared canvas palette; node geometry and prompt mirror metrics stay in their original sheets. */
:root{--bg:#171717;--panel:#222;--line:#383838;--text:#ededed;--muted:#a2a2a2;--accent:#a2a2a2;--soft:#2d2d2d;--ui-raised:#292929;--ui-input:#191919;--ui-success:#92cbb7;--ui-error:#f3a4ad}
body{background:var(--bg);font-family:'Microsoft YaHei','PingFang SC',sans-serif}
a{color:#b9b9b9;text-underline-offset:3px}
button{background:var(--ui-raised);border-color:#414141;border-radius:8px;box-shadow:none}
button:hover:not(:disabled){background:#343434;border-color:#626262}
button:disabled{opacity:.45}
button.primary,button.cyan{background:#ececec;color:#202020;border-color:#ececec;box-shadow:none}
button.primary:hover:not(:disabled),button.cyan:hover:not(:disabled){background:#fff;border-color:#fff}
button.subtle{background:transparent;border-color:transparent}
button.danger{color:var(--ui-error)}
button.danger:hover:not(:disabled){background:#39272a;border-color:#765158}
input,textarea,select{background:var(--ui-input);border-color:#454545;border-radius:8px;color:var(--text)}
select option,select optgroup{background:#292929!important;color:var(--text)!important}
input::placeholder,textarea::placeholder{color:#929292;opacity:1}
:where(button,input,textarea,select,summary,a):focus-visible{outline:2px solid var(--accent);outline-offset:3px}
input[type=checkbox],input[type=radio],progress{accent-color:var(--accent)}
:where(.page,.modal-content) :where(input,select){min-height:36px}
:where(.page,.modal-content) input:is([type=checkbox],[type=radio]){min-height:0}
:where(.page,.modal-content) button{font-size:12px}
:where(.page,.modal-content) small{font-size:11px;line-height:1.65}
:where(.page,.modal-content) .row{min-width:0}
:where(.page,.modal-content) .row.wrap>button{max-width:100%;white-space:normal}
.sidebar{background:#1c1c1c;border-color:var(--line)}
.brand strong{font-weight:600;letter-spacing:.5px}.brand small{color:var(--muted)}
.project-picker{background:#262626;border-color:#3b3b3b;border-radius:10px}
.project-picker strong{display:inline-block;max-width:150px;overflow:hidden;text-overflow:ellipsis;vertical-align:middle}
.project-letter{background:#363636;color:#d4d4d4;border-radius:7px}
.nav button{border-radius:8px}.nav button:hover:not(:disabled){background:#292929}
.nav button.active{background:#323034;box-shadow:inset 2px 0 var(--accent)}
.nav button.active .icon,.nav button.active:after{color:#cbcbcb}
.nav button small{color:#a0a0a0;font-size:11px}.nav button .num{color:#929292}
.nav .canvas-sidebar{border-color:#454545}.nav .canvas-sidebar-item.active{background:#323034}
.nav .canvas-sidebar-add{color:#b8b8b8}.bottom-nav button{color:#b9b9b9;border-radius:8px}
.topbar{background:#1c1c1c;border-color:var(--line)}
.topbar .credit{background:#2b2b2b;border-color:#4b4b4b;color:#cbcbcb}
.topbar #storage-status{color:var(--ui-success);font-size:11px}
.test-label{background:#282828;border-color:#454545;color:#b9b9b9}
.main:has(.page){background:var(--bg)}
.page{padding:28px;max-width:1680px}
.page-heading{align-items:center;gap:20px;min-height:74px;margin-bottom:24px;flex-wrap:wrap}
.page-heading>div:first-child{flex:1 1 280px;min-width:0}
.page-heading h1,.projects-page h1{font:600 24px/1.5 'Microsoft YaHei','PingFang SC',sans-serif;letter-spacing:.2px}
.page-heading p{color:#a5a5a5;line-height:1.8}
.page-heading button{height:auto;min-height:36px;font-size:12px}.page-heading>.row{flex-wrap:wrap}
.eyebrow{color:#adadad;font-size:10px;letter-spacing:1.2px}
.panel{background:var(--panel);border-color:var(--line);border-radius:12px}
.panel-head{background:#252525;border-color:var(--line)}.panel-head h3{font-size:14px}
.panel-head small,.panel-foot small{font-size:11px}
.panel-foot{background:#202020;border-color:var(--line);flex-wrap:wrap}
.story-input{background:#1e1e1e;color:#e5e5e5;line-height:1.95}
.story-panel .panel-foot .primary{font-size:12px}
.empty .hero-icon{background:#303030;box-shadow:none;color:#b9b9b9;border-radius:18px}
.empty h2,.canvas-empty h2{font:600 19px/1.5 'Microsoft YaHei','PingFang SC',sans-serif}
.empty>p,.story-panel .empty p{font-size:12px;color:#aaa}
.chip,.badge{background:#2b2b2b;border-color:#424242;color:#bbb;font-size:11px}
.tabs{gap:6px}
.tabs button,.assets-page .tabs button{background:transparent;border:1px solid transparent;border-radius:8px;font-size:12px;padding:8px 12px}
.tabs button.active,.assets-page .tabs button.active,.choice.active{background:#323232;border-color:#686868;box-shadow:none;color:#eee}
.choice{background:#292929;border-color:#414141}.choice.active:after{color:#bbbbbb}.choice small{color:#aaa}
.stat{height:auto;min-height:72px;background:#222;border-color:#383838;font-size:12px}
.stat b{font:600 22px/1.5 'Microsoft YaHei',sans-serif;color:#eee}.stat small{font-size:11px}
.assets-page .asset-extraction{background:#222;border-color:#383838;grid-template-columns:minmax(0,1fr) minmax(240px,318px)}
.assets-page .asset-extraction h3,.asset-art>h3{font-size:14px}
.assets-page .asset-extraction small,.asset-art>p,.asset-art>label small,.asset-art>small{font-size:11px;color:#aaa}
.assets-page .asset-extraction>label{background:#1c1c1c;border-color:#414141;border-radius:10px}
.assets-page .asset-extraction .row.wrap button,.assets-page .asset-extraction .file{font-size:12px;height:auto;min-height:36px}
.assets-page [data-action=extract]{background:#29352f;border-color:#496455;color:#b7ddca}
.assets-page [data-action=add-asset],.assets-page .page-heading [data-action=nav]{background:#ececec;border-color:#ececec;color:#222}
.asset-art{background:#222;grid-template-rows:auto auto auto auto auto}
.asset-art>p{border-color:#383838;line-height:1.8}
.asset-art .choice{font-size:12px;min-height:100px}.asset-art .choice small{font-size:11px}
.asset-art textarea{font-size:12px;line-height:1.8}
.assets-page>.empty{background:#1d1d1d;border-color:#414141}
.assets-page>.empty>.icon{background:#303030;color:#b7b7b7}.assets-page>.empty p{font-size:12px}
.asset-preview{background:#1b1b1b}.asset-preview .icon{color:#a0a0a0}
.asset-meta h3{font-size:14px}.asset-meta p{font-size:12px}
.asset-selection-toolbar{background:#252525;border-color:#414141}
.asset-selectable.asset-selected{background:#2e2e2e;outline-color:#a1a1a1}
.asset-selection-toolbar .danger{background:#38262a;border-color:#71434b}
.asset-version-grid article{background:#222;border-color:#414141}.asset-version-image{background:#191919}
.narrow{max-width:1100px}
.split-controls h3,.split-controls strong{font-size:13px}.split-controls small{font-size:11px}
.split-controls .choice{font-size:12px;height:auto;min-height:64px}
.step-square{background:#323232;border-color:#595959;color:#c1c1c1}
.shot{background:#242424;border-color:#414141}
.result-panel>.panel-head{flex-wrap:wrap;gap:16px}
.result-panel>.panel-head h3{font:600 16px/1.6 'Microsoft YaHei',sans-serif}
.result-panel>.panel-head>label{width:auto;flex:1 1 220px;max-width:400px}
.result-panel>.panel-head>label small,.result-panel select,.result-panel>.empty p{font-size:12px}
.split-page-actions button{min-height:36px;font-size:12px}
button.segment-action{border-width:1px;box-shadow:none;border-radius:8px}
button.segment-start{background:#ececec;color:#222;border-color:#ececec}
button.segment-start:hover:not(:disabled){background:#fff;border-color:#fff}
button.segment-redo{background:#342f26;border-color:#695b42;color:#e5c38f}
button.segment-redo:hover:not(:disabled){background:#40392d;border-color:#9a825b}
.finish-grid{grid-template-columns:minmax(0,1fr) 300px}
.finish-grid h3{font-size:14px}.finish-grid small,.finish-grid .settings-row strong,.finish-grid select{font-size:12px}
.finish-grid .notice{background:#292929;border-color:#444;color:#ccc}
.finish-page .track{font-size:12px;background:#252525}.timeline-item{background:#252525;border-color:#414141}
.projects-page>.row{height:auto;min-height:44px;gap:16px;flex-wrap:wrap}.projects-page>.row>.row{flex-wrap:wrap}
.project-cover,.project-card:nth-child(3n) .project-cover,.project-card:nth-child(3n+1) .project-cover{background:#292929;color:#bfbfbf;border-color:#414141}
.project-card .panel-body{padding:12px 8px}.project-card .panel-body small{font-size:11px}
.project-grid>button{background:#252525!important;border-color:#414141}.project-grid>button>.icon{background:#333;color:#afafaf}
.login{background-color:var(--bg);background-image:radial-gradient(#383838 .8px,transparent .8px);background-size:16px 16px}
.login-card{background:#222;border-color:#414141;box-shadow:0 18px 70px #0004}
.login-card>p{margin-top:12px;font-size:12px;line-height:1.8}
.modal{background:#222;border-color:#454545;border-radius:14px}
.modal>header{background:#262626;border-color:#3c3c3c}.modal>header h2{font:600 18px/1.6 'Microsoft YaHei',sans-serif}
.modal-content{line-height:1.8}.modal-content .two-col{grid-template-columns:repeat(2,minmax(0,1fr))}
.modal-content label{font-size:12px;color:#d0d0d0}.modal-actions{gap:8px}
.notice,.assets-page>.notice{background:#2b2b2b;border-color:#4a4a4a;color:#c8c8c8;font-size:12px;line-height:1.8}
.error{color:var(--ui-error)}.file{background:#292929;border-color:#454545;font-size:12px}.file:hover{background:#343434}
.list-row,.settings-row{border-color:#383838}
.api-text-result,.request-preview{background:#191919;border:1px solid #383838;color:#ddd}
.provider-setup{background:#222;border-color:#454545;max-width:95vw}
.provider-setup>header h2{font:600 22px/1.5 'Microsoft YaHei',sans-serif}
.provider-setup .provider-tabs{background:#1d1d1d;border-color:#3c3c3c;gap:8px;padding-bottom:8px;padding-top:8px}
.provider-tabs button{padding:8px 12px;border:1px solid transparent;border-radius:8px;font-size:12px}
.provider-tabs button.active{background:#323232;border:1px solid #686868;color:#eee}
.provider-status{background:#26312d;border-color:#42594e}.provider-status small,.provider-status>span{font-size:11px}
.provider-status>span{color:var(--ui-success)}.provider-status>.icon{background:#38483f;color:#b2d5bf}
.provider-key-panel{background:#1c1c1c;border-color:#414141;border-radius:10px}.provider-key-panel label,.provider-advanced{font-size:12px}
.provider-note{background:#302c26;border-color:#5a4e3e;color:#d6c5aa;font-size:12px}
.model-prices-table{background:#252525;border-color:#414141}.model-prices-table th{background:#303030;color:#ddd}
.model-prices-table td,.model-prices-table th{border-color:#414141}.model-prices-table tr:hover td{background:#2b2b2b}
.task-progress-card,.compact-task-panel details{background:#262626;border-color:#474747}
.compact-task-list,.compact-task-row{border-color:#3d3d3d}.compact-task-row small,.task-detail-hint{color:#aaa}
.keyword-editor-modal .modal-actions{background:#222}.keyword-editor-modal .keyword-highlight-editor{background:#191919}
#keyword-mention-picker{background:#292929;border-color:#5a5a5a}
#keyword-mention-picker [aria-selected=true]{background:#3b3b3b;border-color:#a1a1a1}
#toast{background:#2b2b2b;border-color:#535353;color:#eee;border-radius:10px}
/* Keep dotted canvas, port hit areas, media sizes and editor overlay alignment. */
.canvas-toolbar{background:#1c1c1c;border-color:#383838}.canvas-toolbar button{background:#292929;border-color:#414141}
.canvas-toolbar .cyan{background:#ececec;color:#222;border-color:#ececec}
.canvas-empty{background:#222;border-color:#414141}.canvas-empty p,.canvas-empty button{font-size:12px}
.canvas-hint{background:#242424e8;border-color:#454545;color:#bbb}
.node-create-menu{background:#292929;border-color:#454545;border-radius:12px}.node-create-menu button:hover{background:#383838}
/* Dense production screens need readable helper text as well as shared colors. */
.story-panel .panel-foot small,.story-panel .empty .chip,.assets-page .asset-extraction small,.assets-page>.empty h3,.assets-page>.empty p,.asset-art .eyebrow,.asset-art>label small,.asset-art>small,.split-controls small,.result-panel>.panel-head>label small,.finish-grid .settings-row small,.provider-status small{font-size:11px}
.assets-page>.row button,.assets-page #asset-query,.assets-page .asset-extraction .row.wrap button,.asset-art .choice small{font-size:12px}
.projects-page>.row button{background:#292929;border-color:#414141}
.projects-page>.row .cyan{background:#ececec;border-color:#ececec;color:#222}
.story-panel .chip{font-size:11px}
.provider-setup>header .eyebrow{font-size:10px}
.topbar{min-width:0}.topbar>button{flex-shrink:0}.topbar .crumb{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.asset-art .styles{grid-template-columns:repeat(3,minmax(0,1fr))}
.asset-art .choice{white-space:normal}
@media(max-width:1200px){.assets-page .asset-extraction{grid-template-columns:minmax(0,1fr) 280px}.asset-art{grid-template-rows:auto}}
@media(max-width:900px){.two-col{grid-template-columns:minmax(0,1fr)}.story-panel{height:540px;min-height:400px}.assets-page .asset-extraction{display:flex;flex-direction:column}.assets-page .asset-extraction>label{width:100%}.finish-grid{grid-template-columns:minmax(0,1fr)}.topbar #storage-status{display:none}}
@media(max-width:760px){.page{padding:20px 16px}.page-heading{min-height:0;gap:14px}.page-heading h1{font-size:21px}.asset-art .styles{grid-template-columns:minmax(0,1fr)}.asset-art .choice{min-height:64px}.stat-row{grid-template-columns:repeat(2,minmax(0,1fr))}.modal-content .two-col{grid-template-columns:minmax(0,1fr)}.modal-overlay{padding:10px}.modal-content{padding:18px}.panel-head.row{flex-wrap:wrap}.projects-page>.row input{width:100%;flex:1 1 160px}.provider-setup .provider-tabs{gap:4px}.provider-tabs button{padding:7px 9px}.login-card{padding:24px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important}.pending{animation:none}}

/* Free creation is pinned within the shared canvas section. */
.nav .canvas-sidebar-fixed{margin:0 0 7px;border:0;border-bottom:1px solid #414141;border-radius:7px;min-height:40px;height:auto;flex-shrink:0;font-size:14px}


.nav-tree-arrow{margin-left:auto;font-size:18px;line-height:1;color:#c0c0c0;flex-shrink:0}
.nav button[aria-expanded].active:after{display:none}

/* Shared canvas interaction help and grab mode. */
.canvas.hand-mode,.canvas.hand-mode .node-head,.canvas.hand-mode [data-group-drag],.canvas.space-pan{cursor:grab}.canvas.is-panning,.canvas.is-panning *{cursor:grabbing!important;user-select:none}
.canvas-shortcuts{display:grid;grid-template-columns:repeat(4,minmax(170px,1fr));gap:24px}.modal:has(.canvas-shortcuts){width:min(1100px,94vw);max-width:1100px}.canvas-shortcuts section+section{border-left:1px solid var(--line,#373737);padding-left:20px}.canvas-shortcuts h3{color:#8dcbd1;font-size:13px}.canvas-shortcuts p{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:12px;line-height:1.8}.canvas-shortcuts kbd{font:inherit;white-space:nowrap;border:1px solid #444444;border-radius:5px;padding:1px 5px;background:#272727}.canvas-search-result{display:block;width:100%;text-align:left;margin-top:8px}#canvas-node-query{width:100%}@media(max-width:850px){.canvas-shortcuts{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:500px){.canvas-shortcuts{grid-template-columns:1fr}.canvas-shortcuts section+section{border-left:0;padding-left:0}}

/* Asset center: source entry -> focused workspace. */
.asset-center-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:28px}.asset-center-heading h1{font-size:28px;line-height:1.35;margin:8px 0}.asset-center-heading p{color:var(--muted);margin:0;font-size:13px}.asset-breadcrumb{padding:0;min-height:28px;color:var(--muted)}.asset-utilities button{font-size:12px}.asset-entry-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;max-width:1100px;margin-top:20px}.asset-entry-card{display:flex;align-items:center;gap:12px;min-height:80px;padding:18px 20px;text-align:left;background:var(--panel);border:1px solid var(--line);border-radius:14px;transition:border-color .15s,transform .15s}.asset-entry-card:hover:not(:disabled){border-color:var(--accent);transform:translateY(-2px);background:#262626}.asset-entry-symbol{display:flex;align-items:center;justify-content:center;flex-shrink:0;width:32px;height:32px;border-radius:8px;background:var(--soft);color:#cccccc}.asset-entry-symbol svg{width:18px;height:18px}.asset-entry-content{display:flex;flex-direction:column;gap:6px;flex:1;min-width:0}.asset-entry-content strong{font-size:16px;color:var(--text)}.asset-entry-content>span{font-size:13px;line-height:1.8;color:var(--muted)}.asset-entry-content small{margin-top:2px;font-size:12px;color:var(--muted)}.asset-entry-arrow{margin-left:auto;flex-shrink:0;color:var(--accent);font-size:18px;line-height:1}.asset-extraction h3{margin:0 0 6px}.asset-supplement{border-top:1px solid var(--line);padding-top:12px}.asset-supplement summary{cursor:pointer;font-size:13px;margin-bottom:8px}.asset-supplement summary small{margin-left:8px}.assets-page .asset-art{margin:16px 0 28px}.asset-art>summary{display:flex;align-items:center;gap:14px;cursor:pointer;font-size:14px;font-weight:600;list-style:none}.asset-art>summary:before{content:'›';font-size:20px;color:var(--muted)}.asset-art[open]>summary:before{content:'⌄'}.asset-art>summary::-webkit-details-marker{display:none}.asset-art>summary small{font-size:12px;font-weight:400;color:var(--muted);margin-left:auto}.asset-art-body{padding-top:20px}.asset-art-body textarea{max-height:220px}.asset-rules{margin-top:14px;color:var(--muted);font-size:12px}.asset-rules summary{cursor:pointer}.asset-library-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:28px 0 18px}.asset-library-heading h2{font-size:19px;margin:0 0 6px}.asset-library-heading small{color:var(--muted);font-size:12px}.asset-list-tools{padding-bottom:16px;border-bottom:1px solid var(--line);margin-bottom:16px}.assets-page .asset-selection-toolbar{background:transparent;border:0;border-bottom:1px solid var(--line);border-radius:0;padding:10px 0 16px;margin-bottom:20px}.assets-page .asset-selection-toolbar>small{flex-basis:100%;font-size:11px;color:var(--muted)}@media(max-width:900px){.asset-center-heading{align-items:flex-start;flex-direction:column}.asset-entry-grid{gap:16px}.asset-entry-card{padding:16px;gap:12px}.asset-entry-content strong{font-size:16px}}@media(max-width:650px){.asset-entry-grid{grid-template-columns:1fr;margin-top:20px}.asset-entry-card{min-height:72px}.asset-library-heading{align-items:flex-start;flex-direction:column}.asset-art>summary{flex-wrap:wrap}.asset-art>summary small{margin-left:0}}

/* Drag import augments the existing asset panels. */
[data-asset-import-drop]{transition:border-color .15s,background-color .15s,box-shadow .15s}.asset-drop-hint{display:block;color:var(--muted);font-size:12px;margin-top:8px}.asset-import-drag-active{border-color:var(--accent)!important;background:#2d2d2d!important;box-shadow:inset 0 0 0 2px var(--accent)}.asset-match-drop{padding:16px;border:1px dashed var(--line);border-radius:10px}.asset-match-drop p{margin-top:0}

/* Two storyboard workflows use the same entry hierarchy as the asset center. */
.manual-split-imports{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-bottom:18px}.manual-split-imports h3{font-size:17px;margin:0 0 12px}.manual-split-imports p{font-size:13px;line-height:1.8;color:var(--muted);min-height:48px}.manual-split-imports small{display:block;font-size:12px;line-height:1.8;color:var(--muted);margin-top:14px}.manual-split-imports [data-segment-drop]{border-style:dashed}.manual-split-format{margin-bottom:24px}.manual-split-format summary{cursor:pointer}.split-workspace .result-panel{margin-top:24px}@media(max-width:700px){.manual-split-imports{grid-template-columns:1fr}}

/* Administrator reporting uses the same surfaces and controls as the canvas. */
.modal.usage-modal{width:min(1500px,96vw);max-width:96vw}.usage-modal .modal-content{max-height:84vh;overflow:auto}.usage-filters{display:flex;gap:12px;align-items:end;flex-wrap:wrap;margin:18px 0}.usage-filters label{display:grid;gap:6px;min-width:140px;flex:1}.usage-filters input,.usage-filters select{width:100%;min-height:38px}.usage-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:18px 0}.usage-metrics>div{padding:16px;border:1px solid #353535;background:#202020;border-radius:12px}.usage-metrics strong{display:block;font-size:22px;margin-top:8px}.usage-table-scroll{overflow:auto;border:1px solid #353535;border-radius:12px;margin-bottom:20px}.usage-table-scroll table{width:100%;border-collapse:collapse;font-size:13px;white-space:nowrap}.usage-table-scroll th,.usage-table-scroll td{padding:12px;text-align:left;border-bottom:1px solid #353535;vertical-align:top}.usage-table-scroll th{background:#252525;color:#dad6e6;position:sticky;top:0}.usage-table-scroll td small{display:block;color:#9d9d9d;margin-top:5px;white-space:normal;max-width:260px}.usage-task-id{max-width:220px;white-space:normal;overflow-wrap:anywhere}.usage-pagination{display:flex;align-items:center;justify-content:center;gap:16px}@media(max-width:700px){.usage-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}


/* Contextual guidance stays beside its control without occupying a notice panel. */
.help-hint{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:16px;height:16px;margin-left:6px;border:1px solid #858585;border-radius:50%;color:#b6b1be;background:transparent;font:11px/1 Arial,sans-serif;vertical-align:middle;cursor:help;flex-shrink:0}
.help-hint:hover,.help-hint:focus-visible{color:#eee;border-color:#bcbcbc;outline:2px solid #bcbcbc40;outline-offset:2px}

/* Free creation is an independent canvas surface; other project pages retain their shell. */
.canvas-list-heading{display:flex;align-items:center;gap:2px}
.canvas-list-heading .canvas-list-toggle{flex:1;min-width:0;width:auto}
.canvas-section-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.canvas-list-rename{width:24px;height:26px;min-height:0;flex-shrink:0;padding:3px;border:0;background:transparent;color:var(--muted);font-size:12px}
.canvas-list-rename:hover{color:var(--text);background:#333}
body.canvas-workspace{overflow:hidden}
.canvas-workspace .sidebar,.canvas-workspace .topbar{display:none!important}
.canvas-workspace .main{position:fixed;inset:0;min-height:0;height:auto;margin:0!important;padding:0!important;overflow:hidden}
.canvas-workspace .main>.task-progress-panel{display:none}
.canvas-workspace #canvas{position:absolute;inset:0;width:100%;height:100%;min-height:0;border:0;border-radius:0;background-color:#141414;background-image:radial-gradient(#303030 .7px,transparent .7px);background-size:18px 18px;z-index:0}
.free-canvas-topbar{position:absolute;top:10px;left:12px;right:12px;z-index:40;display:flex;align-items:flex-start;justify-content:space-between;gap:16px;pointer-events:none}
.free-canvas-topbar-left,.free-canvas-topbar-right{display:flex;align-items:center;gap:4px;padding:4px;background:#222e;border:1px solid #3b3b3b;border-radius:9px;pointer-events:auto;box-shadow:0 3px 14px #0003}
.free-canvas-topbar button,.free-canvas-menu>summary{height:29px;min-height:0;padding:4px 9px;border:0;border-radius:5px;background:transparent;font-size:12px;line-height:20px}
.free-canvas-topbar button:hover,.free-canvas-menu>summary:hover{background:#363636}
.free-canvas-topbar button .icon{width:16px;height:16px}
.canvas-workspace-name{font-size:12px;font-weight:600;padding:0 8px;white-space:nowrap}
.free-workspace-menu>.free-workspace-summary{display:flex;align-items:center;gap:7px;font-weight:600}
.free-workspace-summary img{width:20px;height:20px;object-fit:contain;border-radius:4px}
.free-canvas-menu{position:relative}
.free-canvas-menu>summary{list-style:none;cursor:pointer;max-width:230px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.free-canvas-menu>summary::-webkit-details-marker{display:none}
.free-canvas-menu[open]>summary{background:#383838}
.free-canvas-menu-panel{position:absolute;top:calc(100% + 9px);left:0;min-width:210px;max-width:min(320px,85vw);max-height:70vh;overflow:auto;padding:6px;background:#252525;border:1px solid #454545;border-radius:9px;box-shadow:0 12px 32px #0008;display:flex;flex-direction:column;gap:3px}
.free-canvas-topbar-right .free-canvas-menu-panel{left:auto;right:0}
.free-canvas-menu-panel button{justify-content:flex-start;white-space:normal;text-align:left;height:auto;min-height:31px}
.free-canvas-menu-panel button[aria-current="page"]{background:#373737;color:#dedede}
.free-canvas-menu-panel hr{width:100%;margin:5px 0;border:0;border-top:1px solid #414141}
.canvas-workspace .canvas-empty.free-canvas-empty{width:min(760px,90%);min-height:0;padding:0;background:transparent;border:0;border-radius:0;box-shadow:none}
.free-canvas-empty p{font-size:13px;color:#999;margin:0 0 22px}
.free-canvas-quick-start{display:flex;justify-content:center;flex-wrap:wrap;gap:10px}
.free-canvas-quick-start button{min-width:155px;height:39px;min-height:0;padding:7px 14px;justify-content:flex-start;font-size:12px;background:#242424;border:1px solid #373737;border-radius:13px;gap:14px}
.free-canvas-quick-start button:hover{background:#303030;border-color:#666}
.free-canvas-quick-start .icon{width:17px;height:17px}
.canvas-workspace .canvas-hint,.canvas-workspace .canvas-minimap{display:none}
.canvas-workspace .canvas-tools{bottom:16px;padding:5px;border-radius:14px;background:#242424ee;box-shadow:0 6px 24px #0004}
.canvas-workspace .zoom-tools{bottom:18px;right:16px;flex-direction:row;border:1px solid #3b3b3b;border-radius:10px;overflow:hidden;background:#242424ee}
.canvas-workspace .zoom-tools button{font-size:11px;border:0;height:32px;background:transparent}
.canvas-workspace .canvas-count{left:16px;bottom:24px;color:#999;font-size:11px}
@media(max-width:700px){.canvas-workspace-name{display:none}.free-canvas-menu>summary{max-width:150px}.free-canvas-topbar{left:8px;right:8px;gap:8px}.free-canvas-topbar-left,.free-canvas-topbar-right{padding:3px}.canvas-workspace .zoom-tools{bottom:66px}.free-canvas-quick-start button{min-width:125px}.canvas-workspace .canvas-count{bottom:70px}}

/* Canvas switching stays anchored to the toolbar. */
.main>.canvas-toolbar{position:relative;z-index:45}
.canvas-switcher>summary{background:#252525;border:1px solid #454545}
.canvas-switcher-panel{width:240px;overflow:visible}
.canvas-switcher-heading{display:flex;align-items:center;justify-content:space-between;padding:0 5px 4px;color:#aaa;font-size:12px}
.canvas-switcher-heading button{width:28px;min-height:26px;justify-content:center;padding:2px;background:transparent;border:0;font-size:20px}
.canvas-switcher-list{max-height:55vh;overflow:auto}
.canvas-switcher-row{display:flex;align-items:center;border-radius:5px;min-width:0}
.canvas-switcher-row.active{background:#3b3b3b}
.canvas-switcher-row .canvas-switcher-name{flex:1;min-width:0;background:transparent;border:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.canvas-switcher-row button[aria-current="page"]{background:transparent;color:#fff}
.canvas-row-actions{display:flex;flex-direction:column;padding:3px}
.canvas-row-actions button{border:0;background:transparent;min-height:28px;font-size:12px}

.canvas-row-actions{flex-direction:row;gap:2px}
.canvas-row-actions button{width:28px;height:28px;min-height:28px;padding:5px;justify-content:center}
.canvas-row-actions .icon{width:16px;height:16px}

.project-switcher>summary{display:flex;align-items:center;gap:5px;max-width:260px}
.project-switcher>summary .icon{width:16px;height:16px;flex-shrink:0}

/* Project gallery: covers first, one menu per card. */
.projects-page{max-width:1220px;margin:0 auto;padding-top:24px}
.projects-gallery-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:26px}
.projects-gallery-heading h1{font:600 14px/1.5 "Microsoft YaHei",sans-serif}
.projects-gallery-heading input{width:220px;padding:6px 10px;font-size:12px}
.projects-gallery-heading button{font-size:12px;padding:5px 8px}
.projects-page .project-grid{grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:24px 16px}
.projects-page .project-card{background:transparent;border:0;border-radius:0;overflow:visible;min-width:0}
.projects-page .project-cover,.projects-page .project-create-cover{height:auto;aspect-ratio:16/9;width:100%;border:1px solid transparent;border-radius:9px;background:#232323;overflow:hidden;padding:0;box-shadow:none}
.projects-page .project-cover:hover{border-color:#555;background:#282828}
.projects-page .project-cover>.icon{width:38px;height:38px;color:#505050}
.projects-page .project-cover img{width:100%;height:100%;object-fit:cover}
.project-create-cover{display:flex;flex-direction:column;gap:6px;color:#eee}
.projects-page .project-create-cover{border-color:#4a4a4a;background:#292929}
.project-create-cover>.icon{width:20px;height:20px;color:#999}
.project-create-card small{display:block;margin-top:7px;font-size:10px}
.project-card-caption{padding:6px 5px 0}
.project-card-caption strong{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.project-card-caption small{font-size:10px;color:#999}
.project-card-menu{position:relative;flex-shrink:0}
.project-card-menu>summary{list-style:none;cursor:pointer;padding:2px 7px;border-radius:5px;color:#aaa;font-size:13px}
.project-card-menu>summary::-webkit-details-marker{display:none}
.project-card-menu>summary:hover,.project-card-menu[open]>summary{background:#333;color:#fff}
.project-card-menu>summary:focus-visible{outline:2px solid #aaa;outline-offset:2px}
.project-card-menu-panel{position:absolute;right:0;top:calc(100% + 5px);z-index:25;min-width:155px;display:flex;flex-direction:column;padding:6px;background:#292929;border:1px solid #484848;border-radius:9px;box-shadow:0 12px 28px #0006}
.project-card-menu-panel button{border:0;border-radius:5px;background:transparent;justify-content:flex-start;font-size:12px;padding:7px 10px}
.project-card-menu-panel button:hover{background:#3a3a3a}
@media(max-width:760px){.projects-gallery-heading{flex-wrap:wrap}.projects-page .project-grid{grid-template-columns:repeat(auto-fill,minmax(160px,1fr))}}

.canvas-switcher-row>.canvas-row-actions{flex-shrink:0;margin-left:auto}

/* Credit balance sizes to its content, independent of toolbar order. */
.topbar .credit{width:auto;min-width:max-content;height:34px;padding:6px 10px;gap:7px;white-space:nowrap;flex-shrink:0}
.topbar .credit small{display:inline-block;margin-left:3px;line-height:1.4}

.canvas-workspace .canvas-tools{z-index:10;height:auto;min-height:44px;align-items:center;justify-content:center;max-width:calc(100% - 24px);flex-wrap:wrap;overflow:visible;bottom:max(16px,env(safe-area-inset-bottom))}
.canvas-workspace .canvas-tools button{flex:0 0 34px;display:inline-flex;align-items:center;justify-content:center;line-height:1}

.modal-overlay:has(.generation-history-dialog){z-index:100;background:#0009}
.modal.generation-history-dialog{width:min(1280px,94vw);height:min(780px,88vh);max-height:88vh;border-radius:18px;background:#242424;border:1px solid #414141;display:flex;flex-direction:column;overflow:hidden}
.generation-history-dialog>header{padding:18px 20px;border-bottom:1px solid #393939;flex-shrink:0}
.generation-history-dialog>header h2{font-size:16px;font-weight:600}
.generation-history-dialog .modal-content{padding:12px 20px 20px;min-height:0;flex:1;display:flex;flex-direction:column}
.history-controls{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin-bottom:16px;font-size:11px;flex-shrink:0}
.history-filter-group,.history-type-filters{display:flex;gap:3px}
.history-controls button,.history-controls select{padding:5px 8px;background:transparent;border:0;border-radius:6px;font-size:11px;min-height:28px}
.history-filter-group{padding:3px;border-radius:8px;background:#303030}
.history-controls button[aria-pressed="true"]{background:#191919;color:#fff}
.history-controls button:hover{background:#3a3a3a}
.history-type-filters span{color:#999;margin-left:3px}
.history-control-spacer{flex:1}
.history-density{display:flex;align-items:center;gap:6px}
.history-density .icon{width:14px;height:14px;color:#aaa}
.history-density input{width:76px;padding:0;margin:0;accent-color:#ddd}
.history-results{flex:1;overflow:auto;min-height:0;--history-card-size:210px}
.history-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(var(--history-card-size),100%),1fr));gap:16px;align-items:start}
.history-result-card{border:1px solid #393939;border-radius:10px;overflow:hidden;background:#202020;min-width:0}
.history-result-preview{aspect-ratio:16/10;background:#161616;display:flex;align-items:center;justify-content:center;overflow:hidden}
.history-result-preview img,.history-result-preview video{width:100%;height:100%;object-fit:contain}
.history-result-preview audio{width:calc(100% - 16px);max-width:100%}
.history-result-caption{padding:10px;display:flex;flex-direction:column;gap:3px}
.history-result-caption strong{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.history-result-caption small{font-size:10px;color:#aaa}
.history-result-caption details{font-size:11px;color:#bbb}
.history-result-caption p{white-space:pre-wrap;overflow-wrap:anywhere;max-height:160px;overflow:auto;margin-top:8px}
.history-empty{padding:64px 16px;text-align:center;font-size:12px;color:#888}
.history-no-media{display:flex;flex-direction:column;align-items:center;gap:10px;color:#777;font-size:11px}
@media(max-width:640px){.generation-history-dialog .modal-content{padding:12px}.history-control-spacer{display:none}.history-density{margin-left:auto}}

/* Larger canvas toolbar, independent of canvas zoom. */
.canvas-workspace .canvas-tools{min-height:54px;padding:7px;gap:5px;border-radius:15px;bottom:max(18px,env(safe-area-inset-bottom));flex-wrap:nowrap}
.canvas-workspace .canvas-tools button{flex:0 0 42px;width:42px;height:38px;padding:8px;border-radius:8px}
.canvas-workspace .canvas-tools .icon{width:22px;height:22px}
@media(max-width:480px){.canvas-workspace .canvas-tools{gap:2px;padding:5px;max-width:calc(100% - 16px)}.canvas-workspace .canvas-tools button{flex-basis:34px;width:34px;height:36px}}

/* Unified monochrome UI and Hei typeface. */
:root{--accent:#e6e6e6;--soft:#303030;--bg:#141414;--panel:#222;--line:#3b3b3b;--muted:#999}
body,body *{font-family:SimHei,'Microsoft YaHei','Heiti SC',sans-serif!important}
.icon{color:#f5f5f5!important;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.video-empty-play .icon{fill:currentColor;stroke:none;color:#676767!important}
.generic-empty-symbol .icon{fill:none;stroke:currentColor}
.canvas-current-check{display:inline-flex;align-items:center;justify-content:center;flex:0 0 18px;margin-right:5px}
.canvas-current-check .icon{width:16px;height:16px}
.canvas-menu-name-input{flex:1;min-width:0;height:30px;padding:4px 8px;margin:0;background:#454545;border:1px solid #777;border-radius:6px;color:#fff;font-size:12px}
.canvas-switcher-row.active{background:#3c3c3c}
.free-workspace-summary>span{max-width:160px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* Readable canvas chrome; node and viewport scale remain independent. */
.free-canvas-topbar button,.free-canvas-menu>summary{height:34px;padding:5px 11px;font-size:14px;line-height:24px}
.free-canvas-topbar button .icon{width:18px;height:18px}
.free-workspace-summary img{width:24px;height:24px}
.canvas-home-logo{display:inline-flex;align-items:center;flex-shrink:0;border-radius:4px}
.canvas-home-logo:focus-visible{outline:2px solid #eee;outline-offset:3px}
.free-canvas-menu-panel button{height:auto;min-height:36px}
.canvas-workspace .canvas-empty.free-canvas-empty{width:min(880px,90%)}
.free-canvas-empty p{font-size:16px;max-width:none;margin-bottom:28px}
.free-canvas-quick-start{gap:12px}
.free-canvas-quick-start button{min-width:195px;height:46px;padding:9px 16px;font-size:14px;gap:16px}
.free-canvas-quick-start .icon{width:21px;height:21px}
.topbar .credit,.free-canvas-topbar .credit{height:34px;min-width:54px;width:auto;flex-shrink:0;padding:5px 10px;gap:7px;border:1px solid #383838;border-radius:8px;background:#1e1e1e;color:#f5f5f5;font-size:14px;font-weight:600;line-height:22px;font-variant-numeric:tabular-nums}
.topbar .credit .icon,.free-canvas-topbar .credit .icon{width:15px;height:18px;fill:currentColor;stroke-width:1}
.brand button.logo{padding:0;flex-shrink:0;border:0}
.home-workspace .topbar{padding:0 28px;border-bottom:0;background:#141414}
.home-brand{border:0;background:none;padding:0;width:32px;height:32px}
.home-brand img{width:30px;height:30px}
.home-page{max-width:1456px;margin:0 auto;padding:18px 28px 60px}
.home-create{width:100%;height:160px;border:1px solid #454545;border-radius:14px;background:radial-gradient(#5558 1px,transparent 1px) 8px 8px/18px 18px,linear-gradient(#202020 35%,#373737);display:flex;flex-direction:column;gap:14px}
.home-create:hover{border-color:#777;background:radial-gradient(#6668 1px,transparent 1px) 8px 8px/18px 18px,linear-gradient(#262626 35%,#404040)}
.home-create-plus{width:86px;height:50px;border-radius:16px;display:grid;place-items:center;background:linear-gradient(#fff,#dedede);box-shadow:0 6px 24px #ffffff10}
.home-create-plus .icon{width:28px;height:28px;color:#111!important;stroke-width:2}
.home-create strong{font-size:16px}
.home-functions{display:flex;justify-content:space-evenly;gap:24px;padding:32px 0 34px}
.home-functions button{border:0;background:none;display:flex;flex-direction:column;gap:10px;padding:0 12px;font-size:14px}
.home-functions button>span{width:98px;height:42px;border-radius:16px;background:linear-gradient(#242424,#2a2a2a);display:grid;place-items:center}
.home-functions button:hover>span{background:#363636}
.home-functions .icon{width:24px;height:24px}
.home-recent header{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}
.home-recent h2{font-size:16px}
.home-recent header button{font-size:13px}
.home-recent header .icon{width:14px;height:14px}
.home-projects{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.home-project{min-width:0;justify-content:flex-start;gap:14px;padding:4px;border:1px solid #303030;border-radius:24px;background:#171717;text-align:left}
.home-project-cover{width:100px;height:76px;flex-shrink:0;border-radius:20px;background:#242424;display:grid;place-items:center;overflow:hidden}
.home-project-cover img{width:100%;height:100%;object-fit:cover}
.home-project-cover .icon{width:22px;height:22px;opacity:.4}
.home-project-meta{min-width:0;display:flex;flex-direction:column;gap:3px;padding-right:10px}
.home-project-meta strong{overflow:hidden;text-overflow:ellipsis;font-size:14px}
.home-project-meta small{color:#999;font-size:12px}
.home-no-projects{color:#999;font-size:14px;grid-column:1/-1;padding:24px 0}
@media(max-width:1000px){.home-projects{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.free-canvas-topbar button,.free-canvas-menu>summary{font-size:12px;padding:5px 7px}.free-canvas-quick-start button{min-width:145px}.home-page{padding:18px 16px 36px}.home-functions{gap:8px}.home-functions button{padding:0;font-size:13px}.home-project-cover{width:76px}.home-workspace .topbar{padding:0 16px}}
@media(max-width:480px){.home-projects{grid-template-columns:1fr}.home-functions button>span{width:76px}.home-workspace .topbar{gap:6px}.home-workspace .topbar button{padding:5px 8px}.home-brand{display:none}}

.brand[data-action="home"]{cursor:pointer;border-radius:8px}
.brand[data-action="home"]:focus-visible{outline:2px solid #eee;outline-offset:2px}

/* Shared text hierarchy: regular explanations and bold primary labels. */
:root{--ui-description-size:12px;--ui-description-weight:400;--ui-primary-weight:700;--ui-description-color:#a3a3a3;--ui-primary-color:#f2f2f2}
body{font-weight:400}
:is(h1,h2,h3,h4,h5,h6,strong,b){font-weight:var(--ui-primary-weight)!important}
:is(h1,h2,h3,h4,h5,h6),.home-project-meta strong,.project-card-caption strong,.nav strong,.asset-entry-content strong{color:var(--ui-primary-color)}
button,.free-canvas-menu>summary,.canvas-switcher-name,.node-head,.node-title{font-weight:var(--ui-primary-weight)}
:is(small,.muted,.page-heading p,.asset-center-heading p,.asset-entry-content>span,.asset-meta p,.empty>p,.free-canvas-empty p,.asset-rules,.asset-drop-hint,.help-hint,.task-detail-hint,.generic-empty-caption,.uploaded-material-caption,.canvas-hint){font-size:var(--ui-description-size)!important;font-weight:var(--ui-description-weight)!important;line-height:1.65}
:is(.page-heading p,.asset-center-heading p,.asset-entry-content>span,.asset-meta p,.empty>p,.free-canvas-empty p,.asset-drop-hint,.help-hint,.task-detail-hint,.generic-empty-caption,.uploaded-material-caption){color:var(--ui-description-color)}
.brand small{font-size:8px!important;letter-spacing:2px}
.asset-meta p{height:auto;min-height:40px}

/* Split workspace uses the available width for settings and results. */
.page.split-workspace{max-width:1800px;padding:28px 32px 40px}
.split-workspace>.asset-center-heading{margin-bottom:20px;gap:16px}
.split-workspace .asset-center-heading h1{margin:4px 0;font-size:26px}
.split-workspace-layout{display:grid;grid-template-columns:minmax(460px,.9fr) minmax(0,1.4fr);gap:24px;align-items:start}
.split-setup,.split-output{min-width:0}
.split-setup{display:flex;flex-direction:column;gap:16px}
.split-setup>.split-controls{margin:0;gap:0}
.split-setup>.panel{margin-bottom:0!important}
.split-setup .split-controls>.panel{padding:18px}
.split-setup .split-controls .choice{min-width:0;flex:1;white-space:normal}
.split-setup h3{margin-bottom:6px}
.split-setup p{font-size:12px;line-height:1.65;color:#a3a3a3;margin-bottom:10px}
.split-setup label.file{display:inline-flex;margin:4px 8px 6px 0}
.split-setup #script-split-rule{height:150px;min-height:120px;margin:8px 0 4px}
.split-setup .manual-split-imports{display:grid;grid-template-columns:minmax(0,1fr);gap:16px}
.split-setup [data-episode-pager]{flex-wrap:wrap;gap:6px}
.split-setup [data-episode-pager] button{padding:6px 9px}
.split-setup .split-page-actions{display:flex;flex-wrap:wrap;gap:8px}
.split-setup .split-page-actions button{white-space:normal}
.split-output>.result-panel{margin:0;min-height:560px}
.split-output .result-panel>.panel-head{flex-wrap:wrap;gap:12px;padding:18px 20px}
.split-output .result-panel>.panel-head>.row{flex-wrap:wrap;min-width:0;max-width:100%}
.split-output .result-panel>.empty{min-height:440px!important}
.split-output .result-panel>.panel-body{padding:20px}
@media(min-width:1800px){.split-workspace-layout{grid-template-columns:minmax(500px,.85fr) minmax(0,1.4fr)}}
@media(max-width:1200px){.split-workspace-layout{grid-template-columns:minmax(0,1fr)}.split-output>.result-panel{min-height:380px}.split-output .result-panel>.empty{min-height:300px!important}}
@media(max-width:700px){.page.split-workspace{padding:20px 16px 30px}.split-workspace-layout{gap:16px}.split-setup .split-controls>.panel{padding:14px}.split-output .result-panel>.panel-head,.split-output .result-panel>.panel-body{padding:14px}}

/* Keep controls in reach while reading long split results. */
.split-settings-scroll{display:flex;flex-direction:column;gap:16px;min-width:0}
.split-settings-scroll>*{flex-shrink:0}
.split-settings-scroll>.split-controls{margin:0;gap:0}
.split-settings-scroll>.panel{margin-bottom:0!important}
.split-result-actions{flex-wrap:wrap;gap:8px;margin:0 0 16px;padding:0 0 12px;background:var(--panel);border-bottom:1px solid var(--line)}
.split-output textarea[data-shot-prompt]{height:180px;min-height:120px;max-height:none;font-size:14px;line-height:1.85;resize:vertical;padding:12px 14px}
.split-output .shot{padding:16px;margin-bottom:16px}
.split-output .shot>.row{flex-wrap:wrap;gap:10px}
.split-output .segment-action{min-height:34px;padding:6px 10px;margin:4px 4px 4px 0}
.split-setup .split-action-panel{margin:0!important;padding:14px!important}
.split-setup .split-page-actions button{min-height:38px;flex:1 1 160px;padding:8px 10px;font-size:12px}
@media(min-width:1201px) and (min-height:680px){
 .page.split-workspace{height:calc(100dvh - 90px);display:flex;flex-direction:column;padding-bottom:20px;overflow:hidden}
 .split-workspace>.asset-center-heading{flex-shrink:0;margin-bottom:16px}
 .split-workspace-layout{flex:1;min-height:0;align-items:stretch}
 .split-setup{min-height:0;overflow:hidden;gap:12px}
 .split-settings-scroll{flex:1;min-height:0;overflow:auto;padding-right:6px;scrollbar-gutter:stable;overscroll-behavior:contain}
 .split-setup>.split-action-panel{flex-shrink:0;border-color:#505050}
 .split-output{min-height:0;display:flex}
 .split-output>.result-panel{display:flex;flex-direction:column;flex:1;min-height:0;height:100%;overflow:hidden}
 .split-output .result-panel>.panel-head{flex-shrink:0;padding:14px 18px}
 .split-output .result-panel>.panel-body{flex:1;min-height:0;overflow:auto;scrollbar-gutter:stable;overscroll-behavior:contain;padding-top:0}
 .split-output .result-panel>.empty{min-height:0!important;overflow:auto}
 .split-result-actions{position:sticky;top:0;z-index:2;padding-top:12px}
}

/* Asset setup stays visible; card actions share a compact toolbar. */
.asset-art-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.asset-art-heading h3{font-size:16px;margin:0}
.assets-page .asset-art-body{padding-top:12px}
.assets-page .asset-art .styles{margin:0 0 16px;gap:12px}
.assets-page .asset-art .choice{min-height:68px;padding:12px;gap:10px}
.assets-page .asset-art .choice>.icon{width:18px;height:18px}
.assets-page .asset-art textarea#art{height:280px;min-height:240px;max-height:none;resize:vertical;font-size:14px;line-height:1.8}
.asset-supplement h3{display:flex;align-items:center;gap:8px;margin-bottom:8px}
.asset-supplement textarea{min-height:110px;font-size:13px}
.asset-card-actions{display:flex;align-items:center;gap:6px;flex-wrap:nowrap}
.asset-card-actions>.asset-action-icon{width:32px;height:32px;padding:6px}
.asset-action-icon .icon{width:16px;height:16px}
.asset-card-actions>button{height:32px}
.asset-more-menu{position:relative;flex-shrink:0}
.asset-more-menu>summary{display:flex;align-items:center;justify-content:center;list-style:none;cursor:pointer;width:32px;height:32px;border:1px solid var(--line);border-radius:8px;background:#252525;font-weight:700}
.asset-more-menu>summary::-webkit-details-marker{display:none}
.asset-more-menu>summary:hover{background:#363636}
.asset-more-menu>summary:focus-visible{outline:2px solid #eee;outline-offset:2px}
.asset-more-panel{position:absolute;right:0;bottom:calc(100% + 8px);width:176px;padding:6px;display:flex;flex-direction:column;gap:3px;border:1px solid #505050;border-radius:10px;background:#252525;box-shadow:0 8px 24px #0008;z-index:20}
.asset-more-panel button{justify-content:flex-start;width:100%;min-height:34px;border:0;background:transparent}
.asset-more-panel button:hover{background:#383838}
.asset-more-panel hr{width:100%;border:0;border-top:1px solid #444;margin:4px 0}
.assets-grid>.asset-selectable{overflow:visible;position:relative}
.assets-grid>.asset-selectable:has(.asset-more-menu[open]){z-index:21}
.asset-selectable>.asset-preview{border-radius:16px 16px 0 0;overflow:hidden}
.asset-meta>.row:last-child{flex-wrap:wrap;gap:8px;margin-top:8px}

[data-inline-multi-import] label{margin:10px 0}
[data-inline-multi-import] textarea{height:240px;min-height:180px;font-size:14px;line-height:1.8}
[data-inline-multi-import]>.row{flex-wrap:wrap;gap:8px;margin-top:12px}

.resource-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:16px;margin:0 0 20px;flex-shrink:0}
.resource-toolbar label{display:flex;align-items:center;gap:10px;font-size:13px;font-weight:700}
.resource-toolbar select{min-width:180px;max-width:300px;margin:0;font-size:13px;padding:7px 10px}
.resource-scope-project{padding:12px 0;border-bottom:1px solid var(--line)}
.resource-scope-project>div{padding-left:24px;display:flex;flex-wrap:wrap;gap:12px}
.resource-scope-project label{margin:6px 0}
.prompt-library{margin-top:28px}
.prompt-library h2{font-size:19px}
.prompt-library-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-top:16px}
.prompt-library-list textarea{height:200px;min-height:140px;font-size:14px;line-height:1.8;margin-top:10px}
.library-prompt-picker{display:flex;flex-direction:column;gap:12px}
.library-prompt-picker p{white-space:pre-wrap;color:#aaa;margin-top:8px}
@media(max-width:900px){.prompt-library-list{grid-template-columns:1fr}.resource-toolbar{gap:10px}.resource-toolbar select{min-width:130px;max-width:220px}}

/* Art direction: compact choices on the left, editable prompt on the right. */
.assets-page .asset-art{display:block!important}
.assets-page .asset-art-heading{margin-bottom:14px}
.assets-page .asset-art-body{display:grid;grid-template-columns:260px minmax(0,1fr);column-gap:24px;row-gap:8px;padding-top:0}
.assets-page .asset-art .styles{display:flex;flex-direction:column;grid-column:1;grid-row:1 / span 3;margin:0;gap:10px;align-self:start}
.assets-page .asset-art .choice{min-height:66px;padding:12px;justify-content:flex-start}
.assets-page .asset-art-body>label{grid-column:2;grid-row:1;min-width:0}
.assets-page .asset-art-body>small,.assets-page .asset-art-body>.asset-rules{grid-column:2;margin:0}
.assets-page .asset-art textarea#art{height:300px;min-height:240px;margin-top:8px}
@media(max-width:900px){.assets-page .asset-art-body{grid-template-columns:minmax(0,1fr);gap:12px}.assets-page .asset-art .styles{grid-column:1;grid-row:auto;flex-direction:row;flex-wrap:wrap}.assets-page .asset-art .choice{flex:1 1 180px}.assets-page .asset-art-body>label,.assets-page .asset-art-body>small,.assets-page .asset-art-body>.asset-rules{grid-column:1;grid-row:auto}}

.library-project-tabs{margin:14px 0;gap:6px;max-height:140px;overflow:auto}
.library-project-tabs button{font-size:12px;padding:6px 10px;max-width:220px;overflow:hidden;text-overflow:ellipsis;display:block}

.asset-batch-actions{margin-left:auto;display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.assets-page .asset-selection-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:8px}
@media(max-width:900px){.asset-batch-actions{margin-left:0;flex-basis:100%;justify-content:flex-end}}

/* Project labels grow on one line. */
.free-canvas-topbar-left{flex:0 0 auto}
.free-canvas-topbar .free-canvas-back{display:inline-flex;align-items:center;gap:6px;flex-shrink:0;white-space:nowrap}
.free-canvas-topbar-right{flex-shrink:0}
.project-switcher>summary{max-width:none;white-space:nowrap;overflow:visible;text-overflow:clip;width:max-content}
/* Preview is wider than the prompt/parameter card for every node type. */
.studio-node.reference-video .video-control-card,.studio-node.unified-node .video-control-card{width:560px;margin-left:50px;margin-right:50px;padding-left:12px;padding-right:12px}
.reference-video .video-settings-strip .node-generate,.unified-node .video-settings-strip .node-generate{flex:0 0 27px;width:27px;height:27px;min-height:27px;border-radius:9px}
.reference-video .node-generate:after,.unified-node .node-generate:after{font-size:20px;line-height:20px}
.reference-video .video-settings-strip .node-parameters,.unified-node .video-settings-strip .node-parameters{gap:6px;flex-wrap:nowrap}
.reference-video .video-settings-strip .compact-model{flex:0 0 90px;width:90px;min-width:90px}
.reference-video .video-settings-strip .generation-mode,.reference-video .video-settings-strip .video-mode-label{flex:0 0 70px;width:70px!important;font-size:11px}
.reference-video .video-settings-strip .compact-parameter-menu,.unified-node .video-settings-strip .compact-parameter-menu{flex:0 0 auto;min-width:max-content;width:max-content;padding-left:8px}
.reference-video .video-settings-strip .compact-parameter-menu>summary,.unified-node .video-settings-strip .compact-parameter-menu>summary{white-space:nowrap;overflow:visible;text-overflow:clip;max-width:none;font-size:11px}
.reference-video .video-settings-strip .node-price,.unified-node .video-settings-strip .node-price{flex:0 0 auto;min-width:64px;width:max-content;font-size:10px;justify-content:flex-end}
.reference-video .video-settings-strip .node-price>span,.unified-node .video-settings-strip .node-price>span{display:inline;max-width:none;overflow:visible;text-overflow:clip;white-space:nowrap}
.expanded-node-editor.keyword-editor-modal{width:min(980px,94vw);height:min(720px,88dvh);max-width:980px;max-height:88dvh;border-radius:18px;background:#252525;overflow:visible;position:relative}
.expanded-node-editor>header{position:absolute;right:8px;top:6px;padding:0;border:0;z-index:5;background:transparent}
.expanded-node-editor>header h2{display:none}
.expanded-node-editor>header button{height:30px;width:30px;padding:6px}
.expanded-node-editor .modal-content{height:100%;padding:14px 18px}
.expanded-node-editor [data-form="node-keywords"]{height:100%;display:flex;flex-direction:column;gap:10px;min-height:0}
.expanded-node-editor .expanded-editor-tools{flex-shrink:0;padding-right:34px;display:flex;align-items:center;flex-wrap:wrap;gap:6px}
.expanded-node-editor .expanded-auto-reference{display:flex;align-items:center;gap:5px;font-size:11px;margin:0!important;color:#aaa}
.expanded-node-editor .expanded-auto-reference input{margin:0}
.expanded-node-editor .expanded-prompt-field{display:flex;flex-direction:column;flex:1;min-height:0;margin:0!important}
.expanded-prompt-label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.expanded-node-editor .keyword-highlight-editor{height:100%;min-height:0;margin:0;background:transparent;border:0;flex:1}
.expanded-node-editor .keyword-highlight-editor>textarea,.expanded-node-editor .keyword-highlight-editor>pre{height:100%;min-height:0;border:0;border-radius:0;background:transparent;padding:8px 0;font-size:14px;line-height:1.85}
.expanded-node-editor .keyword-highlight-editor>textarea{resize:none}
.expanded-node-editor #keyword-assets{font-size:11px;max-height:65px;overflow:auto;flex-shrink:0}
.expanded-node-editor #keyword-error:empty{display:none}
.expanded-node-editor .expanded-editor-footer{flex-shrink:0;padding-top:6px}
.expanded-node-editor .expanded-editor-footer .node-parameters{display:flex;align-items:center;gap:12px;min-height:34px}
.expanded-node-editor .expanded-editor-footer .node-generate{margin-left:8px;flex-basis:32px;width:32px;height:32px;border-radius:12px;background:#f2f2f2;color:#252525}
.expanded-node-editor .expanded-editor-footer .node-price{margin-left:auto}
@media(max-width:700px){.expanded-node-editor .expanded-editor-footer .node-parameters{flex-wrap:wrap;gap:8px}.expanded-node-editor.keyword-editor-modal{height:86dvh}.expanded-node-editor .modal-content{padding:12px}}

.expanded-node-editor .video-settings-strip .node-price>span{max-width:none}

/* Asset candidates float above the short prompt instead of being clipped inside it. */
.studio-node .inline-node-editor .keyword-highlight-editor{overflow:visible}
.studio-node .inline-node-editor .keyword-highlight-editor>.inline-asset-options{inset:auto 0 calc(100% + 8px);display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;width:100%;max-height:260px;overflow-x:hidden;overflow-y:auto;padding:8px;border-radius:12px;z-index:65;background:#282828;box-shadow:0 8px 24px #0008;scrollbar-gutter:stable}
.studio-node .inline-asset-options>button{min-width:0;min-height:52px!important;height:auto!important;justify-content:flex-start;gap:8px;padding:8px!important;white-space:normal;overflow-wrap:anywhere;text-align:left;font-size:12px;line-height:1.5}
.studio-node .inline-asset-options>button .mention-option-image{width:36px;height:36px;object-fit:cover;flex-shrink:0;border-radius:6px}
.studio-node .inline-asset-options>small,.studio-node .inline-asset-options>button[data-action="references"]{grid-column:1/-1}
.studio-node .inline-asset-options>button[data-action="references"]{min-height:32px!important;justify-content:center}
.studio-node:has(.inline-asset-options:not(:empty)){z-index:70}
.free-canvas-topbar-left .canvas-switcher>summary{border:0;background:transparent;box-shadow:none}
.free-canvas-topbar-left .canvas-switcher+.canvas-switcher{border-left:1px solid #3a3a3a;padding-left:4px}
.studio-node .inline-node-editor .keyword-highlight-editor>.inline-asset-options:empty{display:none}
.studio-node .inline-node-editor .keyword-highlight-editor>.inline-asset-options:not(:empty),
#keyword-mention-picker:not([hidden]){display:flex;flex-direction:column;gap:8px;width:260px;max-width:100%;max-height:370px;overflow:hidden;padding:8px;border:1px solid #424242;border-radius:16px;background:#262626;box-shadow:0 10px 30px #0006;text-align:left}
#keyword-mention-picker[hidden]{display:none}
.mention-search{flex:0 0 auto;width:100%;height:34px!important;min-height:34px!important;padding:6px 10px!important;border:1px solid #555!important;border-radius:10px!important;background:transparent!important;font-size:12px!important}
.mention-menu-list{overflow-y:auto;overflow-x:hidden;min-height:0;max-height:300px;display:flex;flex-direction:column;gap:3px;scrollbar-width:thin}
.mention-menu-list>small,.mention-category>small{display:block;color:#999;font-size:11px;padding:5px 6px}
.studio-node .inline-asset-options .mention-menu-list button,
#keyword-mention-picker .mention-menu-list button{display:flex;align-items:center;justify-content:flex-start;width:100%;gap:8px;min-height:35px!important;height:auto!important;padding:6px!important;border:0;background:transparent;border-radius:6px;white-space:normal;text-align:left;font-size:12px;line-height:1.4}
.mention-menu-list button:hover,.mention-menu-list button[aria-selected="true"]{background:#3b3b3b!important}
.mention-menu-list button>span:last-child{min-width:0;overflow-wrap:anywhere}
.studio-node .inline-asset-options .mention-option-image,
#keyword-mention-picker .mention-option-image{width:24px;height:24px;object-fit:cover;border-radius:4px;flex-shrink:0}
.mention-file-icon{width:24px;flex-shrink:0;text-align:center;font-size:18px}
.mention-category{border:0!important;padding:0!important;background:transparent!important}
.mention-category>summary{display:flex;align-items:center;gap:9px;padding:7px 6px;list-style:none;cursor:pointer;font-size:12px;font-weight:500}
.mention-category>summary::-webkit-details-marker{display:none}
.mention-category>summary>small{margin-left:auto;color:#888}
.mention-category[open]>summary>span:last-child{transform:rotate(90deg)}
.mention-category>summary:hover{background:#333;border-radius:6px}
.node-preview>.media-thumbnail[data-canvas-media]{cursor:grab}
.node-preview>.media-thumbnail[data-canvas-media]:active{cursor:grabbing}
.hand-mode .node-preview>.media-thumbnail[data-canvas-media],.space-pan .node-preview>.media-thumbnail[data-canvas-media]{cursor:inherit}

/* Style presets remain visible; their generation rules are retained in project data. */
.assets-page .asset-art-style-only .asset-art-body{display:block;padding-top:12px}
.assets-page .asset-art-style-only .styles{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:0}
@media(max-width:650px){.assets-page .asset-art-style-only .styles{grid-template-columns:1fr}}

/* Automatic splitting uses three full-width pages with shared, saved form state. */
.page.split-workspace.split-auto-workspace{height:auto;min-height:calc(100dvh - 90px);display:block;overflow:visible;padding-bottom:32px}
.split-step-navigation{display:flex;align-items:center;justify-content:center;gap:10px;margin:0 0 28px;flex-wrap:wrap}
.split-step-navigation .split-step-pill{display:flex;align-items:center;gap:8px;min-height:36px;padding:7px 18px;border:1px solid #393939;border-radius:24px;background:#202020;color:#929292;font-size:13px;white-space:nowrap}
.split-step-navigation .split-step-pill .icon{width:15px;height:15px}
.split-step-navigation .split-step-pill.active{background:#353535;border-color:#5c5c5c;color:#f2f2f2}
.split-step-navigation .split-step-pill:hover{background:#303030;color:#eee}
.split-step-arrow{color:#777;font-size:20px}
.split-step-page{min-width:0}
.split-import-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:16px;align-items:start}
.split-selection-layout{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;align-items:start}
.split-auto-workspace .panel-body{padding:22px}
.split-style-choices{display:flex;flex-direction:row;flex-wrap:wrap;gap:10px;margin-top:12px}
.split-style-choices .choice,.split-duration-choices .choice{display:flex;align-items:center;justify-content:flex-start;gap:12px;min-height:76px;padding:14px;text-align:left;white-space:normal}
.split-style-choices .choice .icon,.split-duration-choices .choice .icon{width:22px;height:22px;flex-shrink:0}
.split-style-choices .choice>span,.split-duration-choices .choice>span{display:flex;flex-direction:column;gap:5px}
.split-style-choices .choice small,.split-duration-choices .choice small{font-size:12px;color:#a0a0a0}
.split-import-script .file{display:inline-flex;align-items:center;gap:8px;margin:18px 0 12px}
.split-import-script>small{display:block;color:#999}
.split-script-preview{margin:16px 0 0;white-space:pre-wrap;overflow-wrap:anywhere;color:#aaa;font-size:13px;line-height:1.8;max-height:180px;overflow:auto}
.split-step-footer{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}
.split-rule-editor textarea{width:100%;min-height:300px;resize:vertical;font-size:14px;line-height:1.8;margin:14px 0 8px}
.split-rule-editor>small{color:#999;font-size:12px}
.split-duration-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;border:0;padding:0;margin:20px 0 12px;min-width:0}
.split-duration-choices legend{font-size:13px;margin-bottom:12px;padding:0}
.split-auto-workspace [data-episode-pager]{flex-wrap:wrap;gap:8px}
.split-auto-workspace .split-action-panel{position:static;top:auto;z-index:auto;background:#222;border-color:#444}
.split-auto-workspace .split-page-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.split-auto-workspace .split-page-actions button{min-height:38px;padding:8px 14px}
.split-auto-workspace .split-output{display:block}
.split-auto-workspace .split-output>.result-panel{height:auto;min-height:380px;overflow:visible;display:block}
.split-auto-workspace .split-output .result-panel>.panel-body{overflow:visible;height:auto;flex:none}
.split-task-status{padding:10px 0;color:#aaa;font-size:13px}
@media(max-width:900px){.split-import-layout,.split-selection-layout{grid-template-columns:1fr}.split-step-navigation{gap:6px;margin-bottom:20px}.split-step-navigation .split-step-pill{padding:7px 10px;font-size:12px}.split-auto-workspace .split-action-panel{position:static}.split-rule-editor textarea{min-height:230px}}

.page.split-workspace.split-auto-workspace{padding-top:16px}
.split-auto-workspace>.split-step-navigation{margin-bottom:18px}
.split-auto-workspace>.asset-center-heading{margin-bottom:18px}
.split-style-choices .choice{flex:0 1 220px;min-height:54px;padding:9px 12px;gap:9px}
.split-style-choices .choice .icon{width:16px;height:16px}
.split-style-choices .choice strong{font-size:12px}
.split-style-choices .choice small{font-size:11px}
@media(max-width:500px){.split-style-choices .choice{flex:1 1 150px}}
.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(4,minmax(0,150px));gap:10px;justify-content:start}
.assets-page .asset-art-style-only .styles>.choice{min-height:66px;padding:10px;gap:8px;white-space:normal}
.assets-page .asset-art-style-only .styles>.choice>.icon{width:16px;height:16px;flex-shrink:0}
.assets-page .asset-art-style-only .styles>.choice strong{font-size:12px}
.assets-page .asset-art-style-only .styles>.choice small{font-size:10px;line-height:1.5}
#asset-art-rules-form textarea{width:100%;min-height:340px;resize:vertical;font-size:14px;line-height:1.8}
#asset-art-rules-form>small{display:block;color:#aaa;font-size:12px;line-height:1.7;margin-top:10px}
.split-header-actions{display:flex;align-items:center;gap:8px;flex-shrink:0;margin-left:auto;align-self:center}
@media(max-width:700px){.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(2,minmax(0,150px))}.split-header-actions{margin-left:0}}

/* Four fixed tiles: three presets and the total-rule editor. */
.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(2,minmax(0,150px))}
.manual-prompt-step h3{margin-bottom:16px}
.manual-import-summary{display:block;margin:12px 0;color:#aaa;font-size:12px}
.split-manual-workspace .manual-split-imports>section{padding:22px}
.split-manual-workspace .manual-split-imports small{display:block;margin-top:12px;color:#999}
.split-manual-workspace .manual-split-imports p{color:#aaa;font-size:13px;margin:12px 0}

.upload-drop-zone{transition:outline-color .15s,background-color .15s}
.upload-drop-zone.upload-drop-active{outline:2px dashed #aaa!important;outline-offset:3px;background-color:#353535!important}
.split-import-script .file:after,.manual-prompt-step>h3:after{content:" · 支持拖拽上传";font-size:11px;font-weight:400;color:#999;margin-left:6px}

/* Keep the four art tiles and their enclosing panel proportional. */
.assets-page .asset-art.asset-art-style-only{width:100%;max-width:560px;padding:16px;box-sizing:border-box}
.assets-page .asset-art-style-only .asset-art-heading{margin-bottom:10px;gap:8px}
.assets-page .asset-art-style-only .asset-art-body{padding-top:6px}
.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.assets-page .asset-art-style-only .styles>.choice{min-height:72px;padding:10px 12px}
.assets-page .asset-art-style-only .styles>.choice>.icon{width:18px;height:18px}
.assets-page .asset-art.asset-art-style-only{max-width:1100px;padding:0;border:0;background:transparent}
.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.assets-page .asset-entry-card,
.assets-page .asset-art-style-only .styles>.choice{min-height:118px;padding:18px 20px;gap:12px;box-sizing:border-box;border-radius:14px}
.assets-page .asset-art-style-only .styles>.choice>.icon{width:32px;height:32px;padding:7px;box-sizing:border-box;border-radius:8px;background:var(--soft)}
.assets-page .asset-art-style-only .styles>.choice strong{font-size:16px}
.assets-page .asset-art-style-only .styles>.choice small{font-size:12px;line-height:1.8}
@media(max-width:650px){.assets-page .asset-entry-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.assets-page .asset-entry-card,.assets-page .asset-art-style-only .styles>.choice{padding:12px;min-height:118px}.assets-page .asset-art-style-only .styles>.choice strong{font-size:14px}}

/* The script extraction module keeps four compact art options on one row. */
.assets-page .asset-art.asset-art-style-only{max-width:1100px}
.assets-page .asset-art-style-only .styles{grid-template-columns:repeat(4,minmax(140px,1fr));gap:10px;overflow-x:auto;padding-bottom:3px}
.assets-page .asset-art-style-only .styles>.choice{min-height:66px;padding:10px 12px;gap:8px;border-radius:10px}
.assets-page .asset-art-style-only .styles>.choice>.icon{width:28px;height:28px;padding:6px}
.assets-page .asset-art-style-only .styles>.choice strong{font-size:12px}
.assets-page .asset-art-style-only .styles>.choice small{font-size:10px;line-height:1.5}

/* Keep extraction status beside the supplement, within the import module. */
.assets-page .asset-extraction>.row{grid-column:1;grid-row:1}
.assets-page .asset-extraction>.asset-extraction-status{grid-column:1;grid-row:2;min-width:0;align-self:start}
.asset-extraction-status .task-progress-panel{position:static;width:100%;max-width:none;margin:0}
.assets-page .asset-extraction>.asset-supplement{grid-column:2;grid-row:1 / span 3;min-width:0}
@media(max-width:900px){.assets-page .asset-extraction>.asset-extraction-status{width:100%}}

.assets-page .asset-extraction>.row>.row :is(button,.file){background:#292929;border:1px solid #454545;color:var(--text,#eee);min-height:40px;padding:10px 14px;font-size:12px;font-weight:600;border-radius:9px;box-sizing:border-box}
.assets-page .asset-extraction>.row>.row :is(button,.file):hover{background:#343434}

.assets-page .asset-extraction:not(:has(.asset-supplement))>.asset-extraction-status{grid-column:1 / -1}
.asset-extraction-status [data-asset-table-import-status]:not([hidden]){padding:12px 14px;background:#262626;border:1px solid #474747;border-radius:9px;font-size:12px}
.asset-extraction-status [data-asset-upload-progress]>.notice{margin-top:0!important}

/* Script extraction: primary action above its two input actions. */
.assets-page .asset-extraction:has(.asset-supplement)>.row{display:grid;grid-template-columns:minmax(130px,1fr) auto;align-items:start;gap:24px}
.assets-page .asset-extraction:has(.asset-supplement)>.row>.row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;width:280px;max-width:100%;margin-left:auto}
.assets-page .asset-extraction:has(.asset-supplement)>.row>.row>[data-action=extract-ai]{grid-column:1 / -1;grid-row:1;min-height:50px;font-size:14px}
.assets-page .asset-extraction:has(.asset-supplement)>.row>.row>.file{grid-column:1;grid-row:2}
.assets-page .asset-extraction:has(.asset-supplement)>.row>.row>[data-action=import-local-asset-images]{grid-column:2;grid-row:2}
.assets-page .asset-extraction:has(.asset-supplement)>.row>.row :is(button,.file){width:100%;justify-content:center;padding-left:10px;padding-right:10px}
@media(max-width:600px){.assets-page .asset-extraction:has(.asset-supplement)>.row{grid-template-columns:1fr;gap:16px}.assets-page .asset-extraction:has(.asset-supplement)>.row>.row{width:100%}}

/* Center the action cluster within the open area before the supplement. */
.assets-page .asset-extraction:has(.asset-supplement)>.row{min-height:220px;padding-right:clamp(40px,8vw,120px);align-items:center;box-sizing:border-box}
.assets-page .asset-extraction:has(.asset-supplement)>.row>div:first-child{align-self:center}
@media(max-width:900px){.assets-page .asset-extraction:has(.asset-supplement)>.row{width:100%;min-height:180px;padding-right:40px}}
@media(max-width:600px){.assets-page .asset-extraction:has(.asset-supplement)>.row{min-height:0;padding-right:0}.assets-page .asset-extraction:has(.asset-supplement)>.row>div:first-child{align-self:auto}}

.assets-page .asset-extraction:has(.asset-supplement)>.row>div:first-child h3{font-size:20px;line-height:1.4;margin:0 0 10px}

.release-update-notice{position:fixed;z-index:10020;bottom:20px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:16px;max-width:calc(100vw - 32px);padding:12px 16px;border:1px solid #555;border-radius:12px;background:#262626;color:#eee;box-shadow:0 6px 24px #0006;font-size:12px}.release-update-notice button{flex-shrink:0;font-size:12px}

.asset-card-facts{display:grid;gap:5px;margin:10px 0;padding:9px 0;border-top:1px solid #383838;border-bottom:1px solid #383838;font-size:11px}.asset-card-facts>div{display:grid;grid-template-columns:56px minmax(0,1fr);gap:8px}.asset-card-facts dt{color:#999}.asset-card-facts dd{margin:0;color:#ddd;overflow-wrap:anywhere}

/* Compact asset cards: complete information stays available on demand. */
.assets-grid>.asset-selectable{align-self:start;min-width:0}
.assets-grid .asset-meta{min-width:0}
.assets-grid .asset-meta h3{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.assets-grid .asset-meta .badge{flex-shrink:0}
.asset-key-info{display:flex;gap:10px;color:#aaa;font-size:11px;margin:6px 0;min-width:0}
.asset-key-info>span:first-child{flex-shrink:0}
.asset-key-info>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.assets-grid .asset-description-preview{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;line-height:1.6;height:3.2em;margin:8px 0;color:#bbb;overflow-wrap:anywhere}
.asset-info-details{margin:8px 0 12px;font-size:12px}
.asset-info-details>summary{cursor:pointer;color:#ccc;width:fit-content;border-radius:4px}
.asset-info-details>summary:focus-visible{outline:2px solid #a8c9e6;outline-offset:4px}
.asset-info-body{max-height:260px;overflow:auto;overscroll-behavior:contain;padding-right:6px;overflow-wrap:anywhere}
.asset-info-body p{white-space:pre-wrap;line-height:1.6}
.assets-grid .asset-card-actions{margin-left:auto}
.split-manual-workspace .manual-split-imports{grid-template-columns:minmax(0,1fr);width:100%;max-width:1000px;margin:32px auto 18px}
.split-manual-workspace .manual-split-imports>section{min-height:300px;padding:36px;display:flex;flex-direction:column;align-items:flex-start;justify-content:center}
.split-manual-workspace .manual-prompt-step{width:100%;max-width:1000px;min-height:300px;margin:32px auto 18px;padding:36px}
.split-manual-workspace[data-manual-step="1"] .split-step-footer,.split-manual-workspace[data-manual-step="2"] .split-step-footer{width:100%;max-width:1000px;margin:20px auto 0}
@media(max-width:700px){.split-manual-workspace .manual-split-imports>section,.split-manual-workspace .manual-prompt-step{padding:24px;min-height:280px}}
/* Asset mentions: keep search visible and give each thumbnail/name its own row. */
.keyword-editor-modal .keyword-highlight-editor>#keyword-mention-picker:not([hidden]){left:8px;right:auto;bottom:8px;width:min(520px,calc(100% - 16px));max-width:calc(100% - 16px);max-height:min(520px,calc(100% - 16px));padding:12px;box-sizing:border-box}
.studio-node .inline-node-editor .keyword-highlight-editor>.inline-asset-options:not(:empty){width:min(480px,calc(100% - 12px));max-width:calc(100% - 12px);max-height:min(480px,60vh);padding:12px;box-sizing:border-box}
.keyword-editor-modal #keyword-mention-picker>.mention-menu-list,
.studio-node .inline-asset-options>.mention-menu-list{display:flex;flex-direction:column;grid-template-columns:none;flex:1 1 auto;min-height:0;max-height:none;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;scrollbar-gutter:stable;margin-top:0;gap:4px}
.keyword-editor-modal #keyword-mention-picker .mention-menu-list>*,
.studio-node .inline-asset-options .mention-menu-list>*{flex:0 0 auto}
.keyword-editor-modal #keyword-mention-picker .mention-menu-list button,
.studio-node .inline-asset-options .mention-menu-list button{min-height:56px!important;padding:8px!important;gap:12px;font-size:13px;line-height:1.5;box-sizing:border-box}
.keyword-editor-modal #keyword-mention-picker .mention-option-image,
.studio-node .inline-asset-options .mention-option-image{width:48px;height:48px;object-fit:contain;background:#191919;flex-shrink:0}
.keyword-editor-modal #keyword-mention-picker .mention-menu-list button>span:last-child,
.studio-node .inline-asset-options .mention-menu-list button>span:last-child{flex:1;min-width:0;white-space:normal;word-break:normal;overflow-wrap:anywhere}
.media-upload-status{position:fixed;right:18px;bottom:18px;z-index:12000;width:min(420px,calc(100vw - 36px));max-height:min(420px,60vh);overflow:auto;padding:14px;border:1px solid #555;border-radius:12px;background:#242424;box-shadow:0 8px 30px #0008;color:#eee}.media-upload-status header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:8px}.media-upload-status header button{min-width:28px;padding:2px 6px}.media-upload-status .task-state-caption{white-space:normal;overflow-wrap:anywhere}.media-upload-status progress{width:100%}.media-upload-status details p{font-size:12px;overflow-wrap:anywhere}
