/* Reference node hierarchy: preview, assets, prompt, compact generation controls. */
.studio-node{height:760px;background:#242424;border:1px solid #474747;overflow:visible;border-radius:12px}.studio-node.selected{border-color:#43a6b4;box-shadow:0 0 0 2px #42a6b42b}.studio-node .node-head{height:48px;border-radius:12px 12px 0 0;background:#292929;padding:7px 12px;gap:10px}.studio-node .node-head>.icon{padding:4px;width:27px;height:27px;background:#383838;border-radius:6px}.studio-node .node-head small{display:block;color:#929292;font-size:9px;line-height:13px}.studio-node .node-head strong{display:block;font-size:12px;line-height:17px}.studio-node .node-head button{height:24px;width:24px;padding:4px}.studio-node .node-head button .icon{width:14px;height:14px}.studio-node .node-body{height:calc(100% - 48px);padding:10px;overflow:visible;border-radius:0 0 12px 12px;display:flex;flex-direction:column;gap:6px;background:#222}.studio-node .node-preview{height:210px;min-height:210px;margin:0;position:relative;background:linear-gradient(#202020,#232323);border:0;border-radius:6px;font-size:12px}.studio-node .node-preview:empty:after{content:'连接素材，开始生成'}.studio-node .node-preview video{height:175px;max-height:175px}.studio-node .node-preview .node-video-result .row{padding:4px 8px}.studio-node .node-preview button{height:25px;font-size:9px}.studio-node .node-reference-actions{display:flex;gap:5px;height:30px;align-items:center}.node-reference-actions button{background:#303030;border:0;border-radius:18px;height:25px;padding:3px 9px;font-size:9px}.node-reference-actions .icon{height:12px;width:12px}.node-asset-shelf{border:1px solid #3d3d3d;border-radius:9px;padding:8px;min-height:85px;max-height:100px;overflow:auto}.node-asset-shelf>.row strong{font-size:10px}.node-asset-shelf>.row small{font-size:8px}.studio-node .reference-panel{margin:0;padding:0;border:0}.node-asset-shelf .reference-panel>.row{display:none}.node-asset-shelf .reference-tags{gap:6px;min-height:44px;overflow-x:auto;overflow-y:hidden;max-height:62px}.node-asset-shelf .reference-tag{position:relative;width:52px;height:48px;padding:0;border:1px solid #555;border-radius:6px;overflow:hidden;font-size:8px;display:flex;flex-direction:column;gap:0;flex-shrink:0;color:#eee;background:#303030}.node-asset-shelf .reference-tag img{width:100%;height:32px;object-fit:cover;border-radius:0}.node-asset-shelf .reference-tags>small{font-size:10px;white-space:normal}.node-prompt-shell{border:1px solid #5d6570;border-radius:9px;background:#242424;padding:6px;flex:1;min-height:170px;display:flex;flex-direction:column}.studio-node .node-prompt-heading{height:24px;margin:0;flex-shrink:0}.studio-node .node-prompt-heading strong{font-size:10px}.studio-node .node-prompt-heading button{height:22px;padding:0 6px;color:#bbb;background:none;border:0}.studio-node .inline-node-editor{display:flex;flex-direction:column;flex:1;min-height:0}.studio-node .inline-node-editor .keyword-highlight-editor{flex:1;height:auto;min-height:100px;margin:0}.studio-node .inline-node-editor .keyword-highlight-editor textarea,.studio-node .inline-node-editor .keyword-highlight-editor pre{background:transparent;border:0;font:11px/18px 'Microsoft YaHei',sans-serif;padding:4px;border-radius:0}.studio-node .inline-node-editor .keyword-highlight-editor textarea{background:transparent;color:transparent}.studio-node .inline-node-editor>.row{height:25px;flex-shrink:0}.studio-node .inline-node-editor>.row small{font-size:8px}.studio-node .inline-node-editor>.row button{height:22px;padding:1px 7px;font-size:9px;background:#353535;border:1px solid #595959;box-shadow:none}.studio-node .node-parameters{display:flex;align-items:center;gap:4px;position:relative;margin:0;min-height:36px;flex-shrink:0}.compact-model{display:flex!important;align-items:center;gap:3px;min-width:0;flex:1}.model-letter{display:grid;place-items:center;background:linear-gradient(135deg,#9f9f9f,#6f6f6f);border-radius:5px;width:20px;height:20px;font-size:10px;flex-shrink:0}.studio-node .compact-model select{width:100%;font-size:10px;margin:0;background:transparent;border:0;padding:5px 0;max-width:150px}.studio-node .node-parameters .generation-mode{width:72px;font-size:9px;padding:4px 0;background:transparent;border:0}.node-parameter-popover>summary{cursor:pointer;font-size:9px;white-space:nowrap;max-width:132px;overflow:hidden;text-overflow:ellipsis;color:#c8c8c8;list-style:none;padding:6px 4px}.node-parameter-popover>summary:after{content:'⌄';margin-left:3px}.node-parameter-sheet{position:absolute;z-index:20;bottom:40px;right:0;width:310px;max-height:480px;overflow:auto;display:grid;grid-template-columns:1fr 1fr;gap:12px;background:#292929;border:1px solid #515151;box-shadow:0 15px 50px #0009;border-radius:12px;padding:16px}.node-parameter-sheet>strong,.node-parameter-sheet>.node-model{grid-column:1/-1}.studio-node .node-parameter-sheet label{font-size:11px;display:flex;flex-direction:column;gap:5px}.studio-node .node-parameter-sheet select,.studio-node .node-parameter-sheet input{font-size:12px;background:#181818;border-color:#484848;border-radius:7px;height:35px;width:100%;margin:0}.studio-node .node-parameter-sheet small{font-size:9px}.studio-node .node-parameter-sheet .node-cost{margin:0;padding:10px;background:#222222}.node-generate{border:0;border-radius:8px;background:#ececec;color:#1e1e1e;width:30px;height:30px;padding:6px;flex-shrink:0}.node-generate:hover{background:#fff;color:#000}.node-generate .icon{width:16px;height:16px}.node-state-line{display:flex;align-items:center;gap:8px;min-height:20px;font-size:9px;color:#a8a8a8}.node-state-line>span:before{content:'●';color:#69cfb6;margin-right:4px}.node-state-line>small{margin-left:auto;font-size:9px}.node-state-line label{font-size:9px}.node-state-line input{margin:0}.studio-node:has(details[open]){z-index:15}.studio-node:focus-within{z-index:10}.node-parameters>.node-model{max-width:160px}.node-parameters>.node-model input{font-size:10px;width:130px;padding:4px}

.canvas{overflow:clip}.studio-node .node-parameters .compact-model{flex-direction:row;gap:4px}.studio-node .node-parameters .compact-model select{min-width:0;margin:0;padding:4px;width:100%;height:30px}.studio-node .node-parameters .compact-model .model-letter{display:grid}.studio-node .node-parameters .node-parameter-sheet>strong{grid-column:1/-1}

.provider-setup{width:720px;background:#161616;border:1px solid #333333;border-radius:18px}.provider-setup>header{min-height:112px;position:relative;display:block;padding:28px 24px 18px}.provider-setup>header .eyebrow{font-size:8px;display:block}.provider-setup>header h2{font:22px SimSun,serif;margin-top:7px}.provider-setup>header button{position:absolute;right:24px;top:22px;width:32px;height:32px;padding:6px}.provider-setup .modal-content{padding:0 24px 24px}.provider-setup .provider-tabs{margin:0 -24px 18px!important;padding:0 24px;gap:20px;min-height:48px;border-bottom:1px solid #2f2f2f;background:#121212;flex-wrap:wrap}.provider-tabs button{background:none;border:0;border-radius:0;padding:14px 0;font-size:10px;color:#949494}.provider-tabs button.active{color:#d9d9d9;border-bottom:2px solid #989898;background:none}.provider-status{display:flex;align-items:center;gap:14px;padding:16px 14px;border:1px solid #37544e;background:#1a2327;border-radius:12px;margin-bottom:12px}.provider-status>.icon{height:36px;width:36px;padding:8px;background:#60451e;color:#d6b375;border-radius:10px}.provider-status strong{font-size:12px}.provider-status small{display:block;font-size:9px;margin-top:4px}.provider-status>span{margin-left:auto;font-size:9px;color:#83c9ad}.provider-key-panel{border:1px solid #333333;border-radius:13px;padding:14px;background:#121212}.provider-key-panel label{font-size:10px;color:#b8b8b8}.provider-key-panel input{height:42px;font-size:12px}.provider-key-panel>.primary{width:100%;height:36px;font-size:12px}.provider-note{padding:17px 13px;border:1px solid #4a3735;border-radius:11px;background:#281f22;color:#cbbeb7;font-size:10px;margin-top:12px}.provider-advanced{font-size:11px;margin-top:16px;color:#b3b3b3}.provider-advanced>summary{cursor:pointer}.provider-advanced[open]>summary{margin-bottom:16px}.provider-advanced .notice{font-size:11px}.provider-advanced .two-col{margin:12px 0}

.studio-node .node-head .node-title-input{background:transparent;border:0;padding:0;margin:0;color:#eee;font-size:12px;font-weight:600;line-height:18px;height:20px;outline-offset:1px}.studio-node .node-head .node-title-input:focus{background:#333333}

/* Native select popups need explicit opaque colors; transparent select styles can inherit a white popup on Windows. */
select{color-scheme:dark}select option,select optgroup{background-color:#242424!important;color:#f5f3ff!important}select optgroup{font-weight:700}select option{font-weight:400}select option:checked{background-color:#5a5a5a!important;color:#fff!important}select option:disabled{color:#969696!important}.studio-node .compact-model select,.studio-node .generation-mode{background-color:#242424!important;color:#fff;border:1px solid #5f5f5f!important;border-radius:6px}.canvas.space-pan,.canvas.is-panning{cursor:grab}.canvas.is-panning,.canvas.is-panning *{cursor:grabbing!important;user-select:none}.canvas.space-pan .node-head{cursor:grab}

/* Image preview is the entire media surface, not a compact action button. */
.studio-node .node-preview > .media-thumbnail{width:100%;height:100%;min-height:0;padding:0;display:grid;overflow:hidden;border-radius:6px;background:#141414}
.studio-node .node-preview > .media-thumbnail img{display:block;width:100%;height:100%;min-height:0;object-fit:contain;object-position:center}

.studio-node.uploaded-image{height:370px}.uploaded-image .node-body{height:322px}.studio-node.uploaded-image .node-preview{height:275px;min-height:275px}.connection-port{position:absolute;top:91px;width:18px;height:18px;padding:0;border:3px solid #dbdbdb;border-radius:50%;background:#878787;cursor:crosshair;z-index:22}.output-port{right:-9px}.connection-draft{position:fixed;inset:0;width:100vw;height:100vh;z-index:10000;pointer-events:none}

/* Reference connection interactions: centered ports and numbered inputs. */
.connection-port{width:20px;height:20px;border:1px solid #a9b6c2;background:#22282d;color:#dbe7ef;font-size:14px;line-height:16px;padding:0;top:153px;box-shadow:0 0 0 3px #1118}.output-port{right:-10px}.input-port{left:-10px}.uploaded-image .output-port{top:185.5px}.connection-port:hover,.connection-target .connection-port{background:#407da3;border-color:#a2dcff;box-shadow:0 0 10px #59b9ff80}.studio-node.connection-target{outline:2px solid #8acaff;outline-offset:3px}.canvas-reference-edge{filter:drop-shadow(0 0 3px #70bbff70)}.reference-index{position:absolute;top:1px;left:2px;z-index:1;font:10px/15px sans-serif;min-width:15px;height:15px;text-align:center;border-radius:50%;background:#111d;color:#fff}.reference-tag{position:relative}

.canvas-reference-edge.canvas-edge-selected,.canvas-edge-hit.canvas-edge-selected + .canvas-reference-edge{stroke:#72c6ff;stroke-width:3;filter:drop-shadow(0 0 5px #62bfff)}.canvas-edge-hit:hover + .canvas-reference-edge{stroke:#d2edff}

.node-title-label{display:block;max-width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:12px;line-height:20px;cursor:grab;user-select:none}.node-title-label:active{cursor:grabbing}.node-title-label:focus-visible{outline:1px solid #909090;border-radius:3px}.node-head .grow{overflow:hidden}

.canvas-group{position:absolute;box-sizing:border-box;border:1px solid #707070;border-radius:14px;background:#ffffff04;pointer-events:none}.canvas-group>header{height:40px;padding:4px 12px;display:flex;align-items:center;gap:10px;pointer-events:auto;cursor:grab;color:#d3cfdf;white-space:nowrap}.canvas-group>header:active{cursor:grabbing}.canvas-group>header strong{font-size:13px;max-width:280px;overflow:hidden;text-overflow:ellipsis}.canvas-group>header small{margin-right:auto}.canvas-group>header button{font-size:10px;padding:2px 8px;height:25px;background:#252525}.canvas-toolbar{overflow-x:auto}.canvas-toolbar>button{flex-shrink:0}

.selection-frame{position:absolute;border:1px dashed #a3a3a3;border-radius:10px;pointer-events:none;z-index:24}.selection-actions{position:absolute;left:0;top:-46px;display:flex;align-items:center;gap:6px;white-space:nowrap;padding:5px 8px;height:38px;border:1px solid #5f5f5f;border-radius:9px;background:#232323ee;box-shadow:0 4px 16px #0006;pointer-events:auto}.selection-actions button{height:27px;padding:3px 12px;border-radius:6px;font-size:12px;background:#333333;color:#f3edff}.selection-actions button:disabled{opacity:.35}.selection-actions small{padding:0 6px;color:#bbbbbb}

.canvas-group>header strong[data-edit-group-name]{font-size:18px;line-height:28px;font-weight:600;max-width:460px;cursor:grab;user-select:none}.canvas-group>header .group-name-input{width:320px;max-width:70%;height:32px;margin:0;padding:2px 7px;font-size:18px;line-height:28px}

/* Media-first canvas cards; editing expands without a modal. */
.studio-node.compact-media{height:420px;background:#202225;border:1px solid #3c4046;border-radius:16px;box-shadow:0 10px 28px #0002}.compact-media .node-head{height:48px;background:transparent;border-bottom:0;padding:10px 14px}.compact-media .node-head small{display:none}.compact-media .node-body{height:370px;padding:0 12px 10px;gap:6px}.compact-media .node-preview{height:260px;min-height:260px;border:0;border-radius:10px;background:#151719}.compact-media .node-preview img,.compact-media .node-preview video{object-fit:contain}.compact-media .connection-port{top:173px}.compact-reference-line{display:flex;align-items:center;justify-content:space-between;height:26px;color:#9da6ae;font-size:11px}.compact-reference-line button{background:none;border:0;padding:3px 0;font-size:11px}.compact-edit>summary{cursor:pointer;display:flex;justify-content:space-between;padding:7px 0;color:#d4d9df;font-size:12px;list-style:none}.compact-edit-body{position:absolute;left:0;top:100%;width:420px;padding:16px;background:#22252a;border:1px solid #505963;border-radius:12px;box-shadow:0 16px 40px #0008;z-index:30}.compact-media:has(.compact-edit[open]){z-index:35}.compact-edit-body .inline-node-editor{max-height:260px}.compact-edit-body .node-parameters{margin-top:10px}.compact-media .node-state-line{justify-content:space-between}.compact-media .node-state-line>span:before{display:none}.compact-media .node-state-line button{margin-left:auto;height:25px;padding:3px 10px;font-size:11px}.studio-node.uploaded-image{border-radius:16px;background:#202225;border-color:#3c4046;box-shadow:0 10px 28px #0002}.uploaded-image .node-head{background:transparent;border:0}.uploaded-image .node-preview{border:0;border-radius:10px}.uploaded-image .node-head>svg{display:none}.node-head button{opacity:0;transition:opacity .15s}.studio-node:hover .node-head button,.studio-node.selected .node-head button,.studio-node:focus-within .node-head button{opacity:1}.canvas-group>header .group-connect{cursor:crosshair;border:1px solid #84b6ca;color:#cceeff;background:#233b47;border-radius:12px;padding:2px 10px}.canvas:focus{outline:none}

.compact-media .compact-edit-body{top:48px;bottom:10px;left:8px;width:calc(100% - 16px);overflow:auto;border-radius:10px;box-shadow:0 6px 16px #0006}.compact-edit-body .node-parameter-sheet{position:static;width:100%;box-shadow:none}.compact-edit-body .node-parameter-popover[open]{position:relative}.compact-edit-body .node-parameters{flex-wrap:wrap}

/* User-provided original brand artwork, displayed without cropping. */
.brand .logo{background:none;box-shadow:none;padding:0;border-radius:9px;overflow:hidden;flex-shrink:0}.brand .logo img{display:block;width:100%;height:100%;object-fit:contain}.login-brand-logo{display:block;width:96px;height:96px;object-fit:contain;border-radius:16px;margin:0 auto 18px}.login-card>h1{text-align:center}.canvas-toolbar .canvas-brand{display:flex;align-items:center;gap:7px;white-space:nowrap}.canvas-brand img{width:25px;height:25px;border-radius:5px;object-fit:contain}

/* LIBTV reference: floating tools, quiet cards, fine neutral connections. */
.canvas{background-color:#171717;background-image:radial-gradient(#383838 .8px,transparent .8px);background-size:16px 16px}.studio-node.compact-media,.studio-node.uploaded-image{border-radius:10px;background:#252525;border:1px solid #383838;box-shadow:none}.studio-node.selected{outline:1px solid #e5e5e5!important;outline-offset:0}.studio-node .node-head{background:transparent;color:#b1b1b1;position:relative}.node-title-label{font-size:12px;font-weight:400;color:#b4b4b4}.studio-node .node-preview{border-radius:8px;background:#252525}.studio-node .node-preview img,.studio-node .node-preview video{object-fit:contain}.studio-node .node-preview .media-thumbnail{background:#252525;border-radius:8px}.media-thumbnail>span{opacity:0}.media-thumbnail:hover>span{opacity:1}.media-floating-tools{position:absolute;left:0;bottom:calc(100% + 10px);z-index:45;display:none;align-items:center;gap:2px;white-space:nowrap;width:max-content;max-width:1100px;height:46px;padding:5px 9px;background:#252525;border:1px solid #444;border-radius:12px;box-shadow:0 3px 12px #0006;pointer-events:auto}.studio-node.selected>.media-floating-tools,.studio-node:focus-within>.media-floating-tools{display:flex}.media-floating-tools button{height:32px;padding:5px 10px;border:0;background:transparent;color:#dedede;font-size:12px;font-weight:400;border-radius:6px;display:flex;align-items:center;gap:5px}.media-floating-tools button:hover:not(:disabled){background:#3a3a3a}.media-floating-tools button:disabled{color:#717171;opacity:1;cursor:not-allowed}.media-floating-tools .tool-divider{height:24px;width:1px;background:#414141;margin:0 6px}.connection-port{width:20px;height:20px;border:1px solid #aaa;background:#2d2d2d;color:#eee;box-shadow:none;border-radius:50%;font-size:16px;font-weight:300}.connection-port:hover{background:#444;border-color:#fff;box-shadow:none}.canvas-reference-edge{stroke:#a5b0bb;stroke-width:1.6;filter:none}.canvas-reference-edge.canvas-edge-selected,.canvas-edge-hit.canvas-edge-selected+.canvas-reference-edge{stroke:#80c9fa;stroke-width:2;filter:drop-shadow(0 0 3px #4ca9e8)}.canvas-edge-hit:hover+.canvas-reference-edge{stroke:#d0e2f0}.node-reference-actions button,.compact-reference-line button{border-radius:16px;background:#303030}.compact-edit>summary{font-size:12px;border-top:1px solid #333}.node-state-line button{border-radius:6px;background:#ececec;color:#222}.frame-controls{display:flex;gap:8px;align-items:center;margin:12px 0}.frame-controls span{margin-left:auto;font-size:12px;color:#bcbcbc}.node-video-result{height:100%;width:100%;display:flex;flex-direction:column}.node-video-result video{width:100%;flex:1;min-height:0}.node-video-result>.row{display:none}.studio-node:hover .node-video-result>.row{display:flex;font-size:10px}.studio-node .node-head button{opacity:0}.studio-node:hover .node-head button,.studio-node.selected .node-head button{opacity:1}

/* Prompt and generation settings stay visible in the node. */
.studio-node.compact-media{height:980px}.compact-media .node-body{height:930px;display:flex;flex-direction:column}.compact-media .compact-edit{flex:1;min-height:0;overflow:auto}.compact-media .compact-edit-body{position:static;width:100%;height:auto;overflow:visible;padding:10px 0;border:0;border-radius:0;box-shadow:none;background:transparent}.compact-media .compact-edit-body .inline-node-editor{max-height:none}.compact-media .keyword-highlight-editor{height:210px;min-height:210px}.compact-media .compact-edit-body .node-parameter-popover{position:static;width:100%;flex-basis:100%}.studio-node .node-parameter-sheet{position:static;display:grid;width:100%;box-shadow:none}.studio-node .parameter-summary{display:none}.compact-media .node-parameters{display:flex;flex-wrap:wrap;gap:8px}.compact-media .node-parameter-sheet{grid-template-columns:1fr 1fr;padding:10px 0;background:transparent;border:0}.compact-media .node-parameter-sheet>small{grid-column:1/-1}.compact-media .node-state-line{flex-shrink:0}.compact-media .compact-reference-line{flex-shrink:0}

.compact-media .keyword-highlight-editor>textarea,.compact-media .keyword-highlight-editor>pre{height:210px;min-height:210px;max-height:210px}

/* Screenshot reference: preview above a compact editing card. */
.studio-node.reference-video{height:760px;background:transparent;border:0;border-radius:10px}.reference-video .node-head{height:28px;padding:2px 4px}.reference-video .node-title-label{font-size:11px;line-height:24px}.reference-video .node-body{height:732px;padding:0;display:flex;gap:8px}.reference-video .node-preview{height:236px;min-height:236px;position:relative;border:1px solid #353535;border-radius:8px;background:#080808;overflow:hidden}.reference-video .node-video-result>.row{display:none}.preview-corner-tools{position:absolute;right:8px;top:8px;display:flex;gap:2px;background:#343636ed;padding:3px;border-radius:7px;z-index:3}.preview-corner-tools button{height:24px;min-height:0;padding:3px 7px;background:transparent;border:0;color:#eee;font-size:10px}.preview-corner-tools .icon{width:13px;height:13px}.video-control-card{position:relative;flex:1;min-height:0;padding:10px;background:#222;border:1px solid #3a3a3a;border-radius:12px;display:flex;flex-direction:column;gap:8px}.reference-video .input-port{top:16px;left:-11px}.video-quick-actions{display:flex;align-items:center;gap:6px;height:26px;flex-shrink:0}.video-quick-actions button{border:0;background:#343434;border-radius:16px;font-size:10px;padding:4px 10px;height:25px}.video-quick-actions>span{margin-left:auto;color:#959c9a;font-size:9px}.video-assets .reference-panel{margin:0;padding:8px;border:1px solid #404040;border-radius:10px;background:transparent;max-height:94px;overflow:auto}.video-assets .reference-panel small{font-size:9px}.video-assets .reference-panel>.row button{font-size:9px;min-height:0;height:20px;padding:2px 5px}.video-assets .reference-tags{gap:5px;margin-top:4px}.video-assets .reference-tag{font-size:9px;background:#2c302f;border:1px solid #505b57;border-radius:6px;padding:3px}.video-assets .reference-tag img{width:28px;height:28px;object-fit:cover}.video-assets .reference-panel>button{font-size:9px;padding:2px 5px;height:20px;min-height:0}.video-prompt{border:1px solid #4a9b8e;border-radius:10px;padding:8px;flex:1;min-height:150px;display:flex;flex-direction:column}.video-prompt>.row{height:22px;flex-shrink:0}.video-prompt strong{font-size:10px;color:#d9e9e4}.video-prompt>.row button{height:20px;min-height:0;padding:1px 5px}.video-prompt .inline-node-editor{flex:1;min-height:0;max-height:none;display:flex;flex-direction:column;border:0;padding:0;background:transparent}.reference-video .keyword-highlight-editor{flex:1;height:auto;min-height:90px;max-height:none}.reference-video .keyword-highlight-editor>textarea,.reference-video .keyword-highlight-editor>pre{height:100%;min-height:90px;max-height:none;font-size:11px;line-height:1.6;background:transparent}.video-prompt .inline-node-editor>.row{height:24px;flex-shrink:0}.video-prompt .inline-node-editor small{font-size:9px}.video-prompt .inline-node-editor .row button{font-size:9px;height:22px;min-height:0;padding:2px 7px}.video-settings-strip .node-parameters{margin:0;display:flex;flex-wrap:wrap;gap:5px;border:0;padding:0}.video-settings-strip .compact-model{flex:1;max-width:none}.video-settings-strip .compact-model select{font-size:10px!important;height:27px!important}.video-settings-strip .generation-mode{height:27px;font-size:10px}.video-settings-strip .node-parameter-popover{order:3;flex:1;position:static;min-width:0}.video-settings-strip .node-parameter-sheet{display:flex;gap:5px;padding:0;border:0;background:transparent;overflow:visible}.video-settings-strip .node-parameter-sheet>strong,.video-settings-strip .node-parameter-sheet>small{display:none}.video-settings-strip .node-parameter-sheet label{flex:1;min-width:0;font-size:8px;gap:2px}.video-settings-strip .node-parameter-sheet select,.video-settings-strip .node-parameter-sheet input{height:25px;font-size:10px;padding:2px 4px}.video-settings-strip .node-generate{order:4;width:30px;height:30px;align-self:flex-end;border-radius:50%;background:#eee;color:#222}.video-node-status{display:flex;gap:5px;align-items:center;min-height:14px;font-size:9px;color:#76bcab}.video-node-status i{width:5px;height:5px;border-radius:50%;background:#76bcab;flex-shrink:0}.video-node-status span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.reference-video.selected{outline-color:#535d59!important}

/* Single-line model and parameter strip, matching the supplied reference. */
.video-settings-strip .node-parameters{display:flex;flex-wrap:nowrap;gap:6px;align-items:center;padding:2px 0}.video-settings-strip .compact-model{flex:0 1 145px;width:145px;min-width:110px;display:flex;gap:4px}.video-settings-strip .compact-model select{background:transparent!important;border:0!important;padding:2px!important;height:25px!important;font-size:10px!important}.video-settings-strip .model-letter{width:18px!important;height:18px!important;min-width:18px;background:linear-gradient(135deg,#949494,#616161);border-radius:5px;font-size:10px}.video-settings-strip .generation-mode,.video-mode-label{flex:0 0 60px;width:60px!important;min-width:0!important;font-size:9px;color:#d6dcdf;background:transparent!important;border:0!important;padding:0!important}.video-settings-strip .compact-parameter-menu{order:0;flex:1;min-width:0;width:auto;border-left:1px solid #414141;padding-left:7px;position:relative!important}.video-settings-strip .compact-parameter-menu>summary{display:block;font-size:9px;line-height:28px;color:#d0d8dc;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;list-style:none}.video-settings-strip .compact-parameter-menu>summary::-webkit-details-marker{display:none}.video-settings-strip .compact-parameter-menu:not([open])>.node-parameter-sheet{display:none}.video-settings-strip .compact-parameter-menu>.node-parameter-sheet{position:absolute!important;bottom:35px;right:0;width:280px;max-height:340px;overflow:auto;display:grid;grid-template-columns:1fr 1fr;padding:12px;background:#292929;border:1px solid #4a4a4a;border-radius:10px;box-shadow:0 8px 24px #0008;z-index:50}.video-settings-strip .compact-parameter-menu>.node-parameter-sheet>strong{display:block;grid-column:1/-1;font-size:11px}.video-settings-strip .compact-parameter-menu>.node-parameter-sheet label{font-size:10px}.video-settings-strip .compact-parameter-menu>.node-parameter-sheet select,.video-settings-strip .compact-parameter-menu>.node-parameter-sheet input{height:30px;font-size:11px}.video-settings-strip .node-generate{flex:0 0 28px;width:28px;height:28px;align-self:center;margin:0}.reference-video .video-settings-strip{flex-shrink:0}.reference-video .video-prompt{min-height:150px}

.video-settings-strip .compact-parameter-menu>summary:after{content:none}.video-settings-strip .node-parameters{min-height:30px}

.reference-video .video-output-port{top:16px;right:-11px;left:auto}.video-output-port:disabled{opacity:.3;cursor:not-allowed}.node-create-menu>small{display:block;max-width:235px;padding:8px 12px;font-size:11px;line-height:1.6;color:#aaa}

.asset-selection-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:14px 0;padding:10px 12px;border:1px solid #373737;border-radius:10px;background:#191919}.asset-selection-toolbar small{margin-left:auto;color:#aaa}.assets-grid{min-height:110px;padding:12px;position:relative}.asset-selectable{position:relative;user-select:none}.asset-selectable.asset-selected{outline:2px solid #8e8e8e;outline-offset:2px;background:#262626}.asset-selection-check{position:absolute;top:8px;left:8px;z-index:5;background:#161616cc;border-radius:5px;padding:3px;display:flex}.asset-selection-check input{width:17px;height:17px;margin:0;accent-color:#8e8e8e}.asset-marquee{position:fixed;pointer-events:none;z-index:10000;border:1px solid #999999;background:#85858526}.asset-selection-toolbar .danger{color:#ffb5bd;border-color:#8b4550;background:#48232d}

.asset-version-image{display:block;width:100%;max-height:230px;object-fit:contain;background:#131313;border-radius:8px;margin:8px 0}.asset-version-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.asset-version-grid article{padding:10px;border:1px solid #3a3a3a;border-radius:10px}.asset-version-grid details p{white-space:pre-wrap;font-size:11px}.asset-meta>.row:last-child{flex-wrap:wrap}.asset-meta>.row:last-child>.row{flex-wrap:wrap}

/* Invisible edge hit areas: proportional resizing without visible handles. */
.node-resize-edge{position:absolute;z-index:8;background:transparent;touch-action:none}.resize-n,.resize-s{left:10px;right:10px;height:8px;cursor:ns-resize}.resize-n{top:-6px}.resize-s{bottom:-6px}.resize-e,.resize-w{top:10px;bottom:10px;width:8px;cursor:ew-resize}.resize-e{right:-6px}.resize-w{left:-6px}.resize-ne,.resize-nw,.resize-se,.resize-sw{width:14px;height:14px;z-index:9}.resize-ne{right:-7px;top:-7px;cursor:nesw-resize}.resize-nw{left:-7px;top:-7px;cursor:nwse-resize}.resize-se{right:-7px;bottom:-7px;cursor:nwse-resize}.resize-sw{left:-7px;bottom:-7px;cursor:nesw-resize}.reference-video .node-preview>.media-thumbnail{width:100%;height:100%;padding:0;cursor:zoom-in}.reference-video .node-preview>.media-thumbnail video{width:100%;height:100%;object-fit:contain;pointer-events:none}.reference-video .node-preview>.media-thumbnail>span{display:none}

.studio-node .connection-port{z-index:10}

.reference-tag[data-select-reference]{cursor:pointer;outline-offset:2px}.reference-tag.reference-selected{outline:2px solid #67dbc5;background:#24443f!important;box-shadow:0 0 0 3px #67dbc530}

.studio-node .mention-image-preview{display:inline-flex;position:relative;z-index:4;pointer-events:auto;vertical-align:middle;width:34px;height:34px;min-height:0;margin:2px 4px 2px 0;padding:1px;border:1px solid #6cbca7;border-radius:5px;background:#171d1b;cursor:zoom-in}.studio-node .mention-image-preview img{width:100%;height:100%;object-fit:contain;border-radius:3px}.mention-option-image{width:28px;height:28px;object-fit:contain;margin-right:4px}.studio-node .keyword-highlight-editor pre:has(.mention-image-preview){z-index:auto}.studio-node .keyword-highlight-editor pre .asset-mention-valid{white-space:normal}

#keyword-mention-picker [role="option"] img{width:40px;height:40px;object-fit:contain;background:#171b1c;border-radius:5px;flex-shrink:0}.inline-asset-options button{display:inline-flex;align-items:center;gap:4px;min-height:38px!important}

.free-canvas [data-action="toggle-node-auto"],.free-canvas [data-action="reset-references"],.free-canvas [data-action="match-keyword-assets"],.free-canvas label:has(input[name="automatic"]),.free-canvas label:has(input[name="autoKeywordAssets"]){display:none!important}

.task-progress-panel.task-progress-inline{position:static;inset:auto;width:auto;max-width:none;max-height:none;margin:16px 28px 0;z-index:auto;pointer-events:auto;display:grid;gap:8px}.task-progress-inline:empty{display:none}.node-generation-state{width:100%;max-height:100%;padding:16px;box-sizing:border-box;overflow:auto}.node-generation-state small{white-space:normal;overflow-wrap:anywhere}

/* Compact reference labels keep the full name in the title. */
.reference-tag .reference-name{display:inline-block;max-width:8em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:middle}.reference-tag{min-width:0}.reference-tag.reference-selected{outline:2px solid #68dfd0;background:#184d48}

.selection-connect-port{position:absolute;right:-16px;top:50%;transform:translateY(-50%);width:32px;height:32px;padding:0;pointer-events:auto;cursor:crosshair;border-radius:50%;border:2px solid #8edbff;background:#233b47;color:#e2f5ff;font-size:24px;box-shadow:0 0 0 5px #151719aa}.selection-connect-port:hover{background:#39687b}

/* Reference thumbnails sit above mentions without changing textarea character positions. */
.keyword-highlight-editor .asset-mention-valid{position:relative}
.keyword-highlight-editor .mention-image-preview{position:absolute;bottom:100%;left:0;display:inline-flex;z-index:4;pointer-events:auto;width:18px;height:18px;min-height:0;margin:0;padding:1px;border:1px solid #6cbca7;border-radius:3px;background:#171d1b;cursor:zoom-in}
.keyword-highlight-editor .mention-image-preview img{width:100%;height:100%;object-fit:contain;border-radius:2px}
.keyword-highlight-editor>pre,.keyword-highlight-editor>textarea,.keyword-editor-modal .keyword-highlight-editor>textarea,.studio-node .keyword-highlight-editor>pre,.studio-node .keyword-highlight-editor>textarea,.inline-node-editor .keyword-highlight-editor>pre,.inline-node-editor .keyword-highlight-editor>textarea,.studio-node .inline-node-editor .keyword-highlight-editor>pre,.studio-node .inline-node-editor .keyword-highlight-editor>textarea{line-height:38px;padding-top:24px}
.keyword-highlight-editor pre:has(.mention-image-preview){z-index:auto}

/* Keep the mirror beneath the input; thumbnail buttons alone rise above it. */
.keyword-highlight-editor{isolation:isolate}
.keyword-highlight-editor>pre,.studio-node .keyword-highlight-editor>pre{z-index:auto;pointer-events:none}
.keyword-highlight-editor>textarea,.keyword-editor-modal .keyword-highlight-editor>textarea,.studio-node .keyword-highlight-editor>textarea{z-index:1;caret-color:#fff;cursor:text}
.keyword-highlight-editor .mention-image-preview{z-index:4;pointer-events:auto}
.keyword-editor-modal .keyword-highlight-editor{background:#0f0f0f;border-radius:8px}
.keyword-editor-modal .keyword-highlight-editor>pre{background:transparent}

/* Anchor asset choices inside the prompt viewport, away from generation controls. */
.inline-node-editor .keyword-highlight-editor{overflow:hidden}
.inline-node-editor .keyword-highlight-editor>.inline-asset-options{position:absolute;inset:auto 6px 6px;z-index:6;box-sizing:border-box;width:auto;max-width:none;max-height:min(45%,132px);overflow:auto;overscroll-behavior:contain;display:flex;align-items:flex-start;gap:4px;margin:0;padding:6px;border:1px solid #5a5a5a;border-radius:8px;background:#272727;box-shadow:0 3px 12px #0005}
.inline-node-editor .keyword-highlight-editor>.inline-asset-options:empty{display:none}

/* Keep parameter controls above neighboring nodes while the menu is open. */
.studio-node:has(.compact-parameter-menu[open]){z-index:60}
.video-settings-strip .compact-parameter-menu[open]{z-index:60}

/* Price occupies its own row so controls retain their width. */
.node-parameters:has(.node-price){flex-wrap:wrap}.node-price{flex:0 0 100%;display:flex;align-items:baseline;gap:12px;min-width:0;color:#aeaeae;font-size:12px;padding-top:6px}.node-price>span{overflow-wrap:anywhere}.node-price details{position:relative;font-size:11px}.node-price summary{cursor:pointer;color:#939393;white-space:nowrap}.node-price details>div{position:absolute;z-index:80;right:0;top:24px;width:270px;padding:12px;border:1px solid #484848;border-radius:10px;background:#1d1d1d;color:#c1c1c1;line-height:1.6}.node-price a,.model-prices-table a{color:#aeaeae}.model-prices-table{margin:12px 0;padding:12px;border:1px solid #484848;border-radius:10px}.model-prices-table>summary{cursor:pointer}.model-prices-table p{font-size:12px;color:#aaa}.model-price-scroll{overflow:auto;max-height:360px}.model-prices-table table{width:100%;border-collapse:collapse;font-size:12px}.model-prices-table th,.model-prices-table td{text-align:left;padding:10px;border-bottom:1px solid #3a3a3a;vertical-align:top}

/* Keep enlarged-editor asset choices visible beside the text, above the textarea. */
.keyword-editor-modal .keyword-highlight-editor>#keyword-mention-picker{position:absolute;left:8px;right:8px;bottom:8px;z-index:6;box-sizing:border-box;max-height:45%;overflow:auto;overscroll-behavior:contain;box-shadow:0 4px 18px #0008}
.keyword-editor-modal #keyword-mention-picker[hidden]{display:none}
.keyword-editor-modal #keyword-mention-picker [role=listbox]{max-height:160px}
.keyword-editor-modal #keyword-mention-picker [role=option]{display:flex;align-items:center;gap:8px;min-width:0}
@media(max-width:600px){.keyword-editor-modal #keyword-mention-picker [role=listbox]{grid-template-columns:1fr}}

/* Video node reference layout: wide preview and a separate compact prompt card. */
.studio-node.reference-video{width:660px;height:540px;box-sizing:border-box;background:transparent;border:0;box-shadow:none;border-radius:0}
.reference-video .node-head{height:28px;width:580px;margin:0 40px;padding:0 3px;background:transparent;gap:6px;color:#8b8b8b}
.reference-video .node-title-label{font-size:13px;line-height:28px;color:#909090}
.video-title-play{font-size:12px;color:#929292}
.video-header-tools{display:flex;gap:4px;opacity:0;pointer-events:none}
.reference-video:hover .video-header-tools,.reference-video:focus-within .video-header-tools{opacity:1;pointer-events:auto}
.reference-video .node-body{height:512px;gap:16px;overflow:visible;background:transparent;border-radius:0;padding:0}
.reference-video .node-preview{width:580px;height:326px;min-height:326px;margin:0 40px;border:1px solid #858585;border-radius:12px;background:#252525;box-sizing:border-box;overflow:hidden}
.reference-video .node-preview video,.reference-video .node-preview .media-preview-button{width:100%;height:100%;max-height:100%;object-fit:contain}
.video-empty-preview{width:100%;height:100%;position:relative}
.video-empty-play{position:absolute;top:70px;left:calc(50% - 28px);color:#555}
.video-empty-play .icon{width:56px;height:56px;fill:currentColor;stroke:none}
.video-start-options{position:absolute;left:22px;top:140px;display:flex;flex-direction:column;gap:8px;align-items:flex-start}
.video-start-options>small{font-size:10px;color:#8c8c8c;margin-bottom:2px}
.video-start-options button{display:flex;align-items:center;gap:9px;background:none;border:0;color:#e3e3e3;padding:4px 10px;font-size:11px;height:25px}
.video-start-options .icon{width:13px;height:13px}
.reference-video>.connection-port{position:absolute;top:181px;width:20px;height:20px;min-height:0;padding:0;border:2px solid #737373;background:#191919;color:#aaa;border-radius:50%;font-size:16px;line-height:16px;z-index:5;transform:none}
.reference-video>.input-port{left:20px}.reference-video>.output-port{left:auto;right:20px}
.reference-video>.output-port:disabled{opacity:.6;cursor:default}
.reference-video .video-control-card{width:660px;height:170px;flex:0 0 170px;box-sizing:border-box;padding:12px 16px 10px;gap:7px;border:1px solid #383838;border-radius:18px;background:#252525;overflow:visible}
.reference-video .video-quick-actions{height:23px;gap:4px;position:relative}
.reference-video .video-quick-actions>button,.video-connected-assets>summary{display:inline-flex;align-items:center;gap:2px;border:0;background:#303030;color:#969696;border-radius:14px;font-size:10px;line-height:22px;height:22px;padding:0 7px;cursor:pointer;white-space:nowrap}
.reference-video .video-quick-actions .icon{width:12px;height:12px}
.reference-video .video-quick-actions>.video-editor-expand{margin-left:auto;background:transparent;border-radius:4px;font-size:16px;padding:0;width:22px;justify-content:center}
.video-connected-assets>summary{list-style:none}.video-connected-assets>summary::-webkit-details-marker{display:none}
.video-connected-assets>.video-assets{position:absolute;top:29px;left:0;right:0;z-index:30;padding:8px;background:#292929;border:1px solid #4b4b4b;border-radius:9px;box-shadow:0 8px 24px #0007}
.video-connected-assets .reference-panel{max-height:150px}
.reference-video .video-prompt{border:0;background:transparent;padding:0;min-height:0;flex:1;border-radius:0;overflow:visible}
.reference-video .video-prompt .inline-node-editor{border:0;min-height:0;padding:0;margin:0;background:none}
.reference-video .video-prompt .keyword-highlight-editor{min-height:0;height:auto;margin:0;flex:1;background:transparent;outline:none}
.reference-video .video-prompt .keyword-highlight-editor>textarea,.reference-video .video-prompt .keyword-highlight-editor>pre{min-height:0;height:100%;padding:4px 0 0;font:12px/38px 'Microsoft YaHei',sans-serif;border:0;border-radius:0;background:transparent}
.reference-video .video-prompt textarea::placeholder{-webkit-text-fill-color:#737373;color:#737373;opacity:1}
.reference-video .video-prompt .inline-node-editor>.row{display:none}
.reference-video .video-settings-strip .node-parameters{flex-wrap:nowrap;gap:9px;padding:0;min-height:32px}
.reference-video .video-settings-strip .compact-model{flex:0 1 100px;width:100px;min-width:65px}
.reference-video .video-settings-strip .model-letter{background:transparent;width:16px!important;min-width:16px;font-size:12px}
.reference-video .video-settings-strip .compact-model select{font-size:12px!important;color:#eee}
.reference-video .video-settings-strip .generation-mode,.reference-video .video-settings-strip .video-mode-label{flex:0 0 82px;width:82px!important;font-size:12px}
.reference-video .video-settings-strip .compact-parameter-menu{flex:1;min-width:115px;padding-left:10px}
.reference-video .video-settings-strip .compact-parameter-menu>summary{font-size:12px;line-height:30px}
.reference-video .video-settings-strip .node-price{order:3;flex:0 1 115px;width:auto;font-size:10px;gap:0;padding:0;white-space:nowrap;color:#939393;align-items:center}
.reference-video .node-price>span{overflow:visible;text-overflow:clip;white-space:nowrap}
.reference-video .node-price summary{font-size:0;width:14px;height:20px;line-height:20px}.reference-video .node-price summary:after{content:'ⓘ';font-size:11px}
.reference-video .node-price details>div{top:auto;bottom:28px;white-space:normal}
.reference-video .video-settings-strip .node-generate{order:4;flex:0 0 32px;width:32px;height:32px;border-radius:12px;background:#939393;color:#2b2b2b}
.reference-video .node-generate .icon{display:none}.reference-video .node-generate:after{content:'↑';font-size:23px;line-height:22px}
.reference-video .video-node-status{position:absolute;bottom:-21px;left:16px;max-width:calc(100% - 32px);font-size:10px}
.reference-video .node-preview .node-generation-state{max-width:90%;margin:auto}

/* Video parameter chooser matching the canvas reference. */
.reference-video .video-settings-strip .compact-parameter-menu>.video-parameter-card{width:342px;max-height:560px;bottom:38px;right:0;padding:14px 12px 12px;display:flex;flex-direction:column;gap:10px;background:#252525;border:1px solid #383838;border-radius:17px;box-shadow:0 5px 20px #0008;overscroll-behavior:contain;box-sizing:border-box}
.reference-video .video-settings-strip .compact-parameter-menu:not([open])>.video-parameter-card{display:none}
.video-parameter-card .video-native-controls[hidden]{display:none!important}
.video-parameter-card .video-parameter-group{border:0;padding:0;margin:0;min-width:0}
.video-parameter-card .video-parameter-group legend{float:none;width:auto;font-size:11px;font-weight:400;color:#8a8a8a;padding:0;margin-bottom:8px;line-height:15px}
.video-parameter-card .video-ratio-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}
.video-parameter-card .video-parameter-choice,.video-parameter-card .video-quantity-grid>button,.video-parameter-card .video-quantity-current{height:32px;min-height:0;padding:0 6px;border:1px solid #555;border-radius:9px;background:transparent;box-shadow:none;color:#929292;font:12px 'Microsoft YaHei',sans-serif;display:flex;align-items:center;justify-content:center;box-sizing:border-box}
.video-parameter-card .video-ratio-grid>.video-parameter-choice{height:59px;flex-direction:column;gap:8px;font-size:9px;padding:6px 0}
.video-ratio-shape{display:block;border:1px solid currentColor;border-radius:1px;box-sizing:border-box}
.video-parameter-card .video-parameter-choice.is-selected,.video-parameter-card .video-quantity-current{border-color:#eee;background:#3b3b3b;color:#fff}
.video-parameter-card .video-parameter-choice:hover:not(:disabled){border-color:#aaa;background:#333}
.video-parameter-card .video-parameter-choice:disabled,.video-parameter-card .video-quantity-grid>button:disabled{opacity:.55;cursor:not-allowed}
.video-parameter-card .video-parameter-choice:focus-visible{outline:2px solid #aaa;outline-offset:2px}
.video-resolution-grid,.video-audio-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.video-quantity-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.video-duration-control{display:flex;align-items:center;gap:7px;height:23px;color:#8e8e8e;font-size:10px}
.reference-video .video-settings-strip .video-duration-control input[type=range]{appearance:none;-webkit-appearance:none;flex:1;min-width:0;width:auto;height:3px;background:#484848;border:0;border-radius:3px;padding:0;margin:0;accent-color:#eee;cursor:pointer}
.video-duration-control input[type=range]::-webkit-slider-thumb{appearance:none;-webkit-appearance:none;width:8px;height:8px;border-radius:50%;background:#fff;border:0}
.video-duration-control input[type=range]::-moz-range-thumb{width:8px;height:8px;border-radius:50%;background:#fff;border:0}
.video-duration-control output{display:block;min-width:46px;padding:2px 6px;border-radius:10px;background:#303030;color:#eee;text-align:center;font-size:10px;box-sizing:border-box}
.reference-video .video-settings-strip .video-parameter-card>label{display:flex;flex-direction:column;gap:6px;font-size:11px;color:#8e8e8e}
.reference-video .video-settings-strip .video-parameter-card>label select{font-size:11px;background:#292929}

/* Show node selection on the media preview, without a frame around the full node. */
.node.studio-node.selected{outline:none!important;outline-offset:0;box-shadow:none!important;border-color:transparent}
.node.studio-node:not(.selected) .node-preview{border-color:transparent}
.node.studio-node.selected .node-preview{border:1px solid #858585;outline:none;box-shadow:none}
/* Shared non-video node layout: wide preview and a separate compact prompt card. */
.studio-node.unified-node{width:660px;height:540px;box-sizing:border-box;background:transparent;border:0;box-shadow:none;border-radius:0}
.unified-node .node-head{height:28px;width:580px;margin:0 40px;padding:0 3px;background:transparent;gap:6px;color:#8b8b8b}
.unified-node .node-title-label{font-size:13px;line-height:28px;color:#909090}
.video-title-play{font-size:12px;color:#929292}
.video-header-tools{display:flex;gap:4px;opacity:0;pointer-events:none}
.unified-node:hover .video-header-tools,.unified-node:focus-within .video-header-tools{opacity:1;pointer-events:auto}
.unified-node .node-body{height:512px;gap:16px;overflow:visible;background:transparent;border-radius:0;padding:0}
.unified-node .node-preview{width:580px;height:326px;min-height:326px;margin:0 40px;border:1px solid #858585;border-radius:12px;background:#252525;box-sizing:border-box;overflow:hidden}
.unified-node .node-preview video,.unified-node .node-preview .media-preview-button{width:100%;height:100%;max-height:100%;object-fit:contain}
.video-empty-preview{width:100%;height:100%;position:relative}
.video-empty-play{position:absolute;top:70px;left:calc(50% - 28px);color:#555}
.video-empty-play .icon{width:56px;height:56px;fill:currentColor;stroke:none}
.video-start-options{position:absolute;left:22px;top:140px;display:flex;flex-direction:column;gap:8px;align-items:flex-start}
.video-start-options>small{font-size:10px;color:#8c8c8c;margin-bottom:2px}
.video-start-options button{display:flex;align-items:center;gap:9px;background:none;border:0;color:#e3e3e3;padding:4px 10px;font-size:11px;height:25px}
.video-start-options .icon{width:13px;height:13px}
.unified-node>.connection-port{position:absolute;top:181px;width:20px;height:20px;min-height:0;padding:0;border:2px solid #737373;background:#191919;color:#aaa;border-radius:50%;font-size:16px;line-height:16px;z-index:5;transform:none}
.unified-node>.input-port{left:20px}.unified-node>.output-port{left:auto;right:20px}
.unified-node>.output-port:disabled{opacity:.6;cursor:default}
.unified-node .video-control-card{width:660px;height:170px;flex:0 0 170px;box-sizing:border-box;padding:12px 16px 10px;gap:7px;border:1px solid #383838;border-radius:18px;background:#252525;overflow:visible}
.unified-node .video-quick-actions{height:23px;gap:4px;position:relative}
.unified-node .video-quick-actions>button,.video-connected-assets>summary{display:inline-flex;align-items:center;gap:2px;border:0;background:#303030;color:#969696;border-radius:14px;font-size:10px;line-height:22px;height:22px;padding:0 7px;cursor:pointer;white-space:nowrap}
.unified-node .video-quick-actions .icon{width:12px;height:12px}
.unified-node .video-quick-actions>.video-editor-expand{margin-left:auto;background:transparent;border-radius:4px;font-size:16px;padding:0;width:22px;justify-content:center}
.video-connected-assets>summary{list-style:none}.video-connected-assets>summary::-webkit-details-marker{display:none}
.video-connected-assets>.video-assets{position:absolute;top:29px;left:0;right:0;z-index:30;padding:8px;background:#292929;border:1px solid #4b4b4b;border-radius:9px;box-shadow:0 8px 24px #0007}
.video-connected-assets .reference-panel{max-height:150px}
.unified-node .video-prompt{border:0;background:transparent;padding:0;min-height:0;flex:1;border-radius:0;overflow:visible}
.unified-node .video-prompt .inline-node-editor{border:0;min-height:0;padding:0;margin:0;background:none}
.unified-node .video-prompt .keyword-highlight-editor{min-height:0;height:auto;margin:0;flex:1;background:transparent;outline:none}
.unified-node .video-prompt .keyword-highlight-editor>textarea,.unified-node .video-prompt .keyword-highlight-editor>pre{min-height:0;height:100%;padding:4px 0 0;font:12px/38px 'Microsoft YaHei',sans-serif;border:0;border-radius:0;background:transparent}
.unified-node .video-prompt textarea::placeholder{-webkit-text-fill-color:#737373;color:#737373;opacity:1}
.unified-node .video-prompt .inline-node-editor>.row{display:none}
.unified-node .video-settings-strip .node-parameters{flex-wrap:nowrap;gap:9px;padding:0;min-height:32px}
.unified-node .video-settings-strip .compact-model{flex:0 1 100px;width:100px;min-width:65px}
.unified-node .video-settings-strip .model-letter{background:transparent;width:16px!important;min-width:16px;font-size:12px}
.unified-node .video-settings-strip .compact-model select{font-size:12px!important;color:#eee}
.unified-node .video-settings-strip .generation-mode,.unified-node .video-settings-strip .video-mode-label{flex:0 0 82px;width:82px!important;font-size:12px}
.unified-node .video-settings-strip .compact-parameter-menu{flex:1;min-width:115px;padding-left:10px}
.unified-node .video-settings-strip .compact-parameter-menu>summary{font-size:12px;line-height:30px}
.unified-node .video-settings-strip .node-price{order:3;flex:0 1 115px;width:auto;font-size:10px;gap:0;padding:0;white-space:nowrap;color:#939393;align-items:center}
.unified-node .node-price>span{overflow:visible;text-overflow:clip;white-space:nowrap}
.unified-node .node-price summary{font-size:0;width:14px;height:20px;line-height:20px}.unified-node .node-price summary:after{content:'ⓘ';font-size:11px}
.unified-node .node-price details>div{top:auto;bottom:28px;white-space:normal}
.unified-node .video-settings-strip .node-generate{order:4;flex:0 0 32px;width:32px;height:32px;border-radius:12px;background:#939393;color:#2b2b2b}
.unified-node .node-generate .icon{display:none}.unified-node .node-generate:after{content:'↑';font-size:23px;line-height:22px}
.unified-node .video-node-status{position:absolute;bottom:-21px;left:16px;max-width:calc(100% - 32px);font-size:10px}
.unified-node .node-preview .node-generation-state{max-width:90%;margin:auto}


.studio-node.unified-node .node-preview{height:326px;min-height:326px;width:580px}
.unified-node .node-head>.icon{width:13px;height:13px;padding:0;background:transparent;border-radius:0;color:#929292}
.unified-node .generic-empty-symbol .icon{fill:none;stroke:currentColor;stroke-width:1.3}
.unified-node .generic-empty-caption{position:absolute;top:176px;left:0;width:100%;text-align:center;font-size:12px;color:#858585}
.unified-node .generic-text-output{width:100%;height:100%;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere;text-align:left;margin:0;padding:20px 24px;font:13px/1.8 'Microsoft YaHei',sans-serif;color:#dedede}
.unified-node .node-preview audio{width:calc(100% - 64px);max-width:430px}
.unified-node .uploaded-material-caption{padding:8px 0;color:#a6a6a6;font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.unified-node .generic-parameter-summary{font-size:12px;color:#bcbcbc;white-space:nowrap;flex:1}
.unified-node .video-settings-strip .generic-node-model{flex:0 1 190px;width:190px;min-width:100px;font-size:0;gap:0}
.unified-node .video-settings-strip .generic-node-model input{width:100%;height:30px;padding:4px 7px;margin:0;font-size:12px;background:transparent;border:1px solid transparent;color:#ddd}
.unified-node .video-settings-strip .generic-node-model input:focus{background:#303030;border-color:#666}
.unified-node .video-settings-strip .compact-parameter-menu>.generic-image-parameters{display:block;width:310px;padding:14px;background:#252525;bottom:38px;max-height:400px;overflow:auto}
.unified-node .generic-image-parameters .video-parameter-group{padding:0;margin:0;border:0}
.unified-node .generic-image-parameters legend{color:#aaa;font-size:11px;margin-bottom:8px}
.unified-node .generic-image-parameters .video-parameter-choice{height:35px;background:transparent;border:1px solid #555;border-radius:8px;color:#aaa;font-size:11px;padding:5px 8px}
.unified-node .generic-image-parameters .is-selected{background:#3b3b3b;border-color:#eee;color:#fff}
.unified-node .generic-image-parameters [hidden]{display:none!important}
.node.studio-node.selected{outline:none!important;box-shadow:none!important;border-color:transparent}
.node.studio-node:not(.selected) .node-preview{border-color:transparent}
.node.studio-node.selected .node-preview{border:1px solid #858585;outline:none;box-shadow:none}

.unified-node .video-settings-strip .node-model-readonly{display:block!important;font-size:12px;color:#ddd;line-height:30px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:default}

.unified-node .video-settings-strip .node-image-model select{max-width:none;width:100%;font-size:12px!important;color:#ddd;cursor:pointer}

.scene-analysis-panel pre{max-height:180px;overflow:auto;white-space:pre-wrap;word-break:break-word;font-size:11px}.scene-analysis-panel .list-row{gap:12px;align-items:flex-start}.scene-analysis-panel .error{white-space:normal}
/* Inline mention images share the actual editable line, so caret and text cannot drift. */
.inline-mention-editor>.mention-source-input{display:none!important}
.keyword-highlight-editor.inline-mention-editor>pre{pointer-events:auto!important;z-index:1!important;cursor:text;outline:none}
.keyword-highlight-editor.inline-mention-editor>pre[contenteditable=false]{cursor:default}
.keyword-highlight-editor.inline-mention-editor .asset-mention-valid{white-space:nowrap!important}
.keyword-highlight-editor.inline-mention-editor .mention-image-preview{position:static!important;inset:auto!important;display:inline-flex!important;vertical-align:middle;width:20px!important;height:20px!important;min-height:0!important;margin:0 3px!important;padding:1px!important;line-height:1;box-sizing:border-box}
.linked-text-input{margin:8px 0;padding:8px;border:1px solid #444;border-radius:8px}.linked-text-input summary{cursor:pointer;color:#ddd}.linked-text-input pre{white-space:pre-wrap;overflow-wrap:anywhere;max-height:180px;overflow:auto;font:12px/1.6 sans-serif}.connection-port:disabled{opacity:.45;cursor:wait}
