/* 凤希AI · 极简画布 console.html 样式（从页面内联剥离） */
.app,.app *{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;box-sizing:border-box;line-height:1.5}
body{background:#eceff5;color:#232a36;overflow:hidden}
.app{display:flex;height:100vh;height:100dvh}

/* ============ 左侧导航 ============ */
.side{width:232px;flex:0 0 232px;background:#101c31;color:#c9d4e3;display:flex;flex-direction:column;height:100%;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.18) transparent}
.brand{display:flex;align-items:center;gap:10px;padding:16px 16px 14px}
.brand .lg{width:30px;height:30px;border-radius:9px;background:linear-gradient(135deg,#4a7ee6,#7aa5ff);display:flex;align-items:center;justify-content:center;color:#fff;font-size:15px;font-weight:700;flex:0 0 auto}
.brand .t1{font-size:13.5px;font-weight:600;color:#fff;letter-spacing:.3px}
.brand .t2{font-size:11px;color:rgba(255,255,255,.5);margin-top:1px}
.nav{flex:1;overflow-y:auto;padding:4px 10px 4px;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.18) transparent}
/* 深色底上的滚动条：轨道必须透明，否则 Chromium 用浅色默认底，白条很扎眼 */
.side::-webkit-scrollbar,.nav::-webkit-scrollbar{width:6px;height:6px;background:transparent}
.side::-webkit-scrollbar-track,.nav::-webkit-scrollbar-track{background:transparent}
.side::-webkit-scrollbar-thumb,.nav::-webkit-scrollbar-thumb{background:rgba(255,255,255,.18);border-radius:3px}
.side::-webkit-scrollbar-thumb:hover,.nav::-webkit-scrollbar-thumb:hover{background:rgba(255,255,255,.3)}
.side::-webkit-scrollbar-corner,.nav::-webkit-scrollbar-corner{background:transparent}
.nav .grp{font-size:10.5px;letter-spacing:.8px;color:rgba(255,255,255,.52);padding:10px 8px 4px}
.nav button,.nav a.navlink{display:flex;align-items:center;gap:9px;width:100%;padding:6px 9px;margin-bottom:0;background:none;border:0;border-radius:7px;color:#c9d4e3;font-size:13px;text-align:left;cursor:pointer;position:relative;transition:background .13s,color .13s}
.nav a.navlink{text-decoration:none;margin-top:2px;opacity:.92}
.nav button:hover,.nav a.navlink:hover{background:rgba(255,255,255,.06);color:#fff}
.nav button.on{background:rgba(74,126,230,.22);color:#fff;font-weight:500}
.nav button.on:before{content:"";position:absolute;left:0;top:8px;bottom:8px;width:3px;border-radius:2px;background:#6f9cff}
.nav button i,.nav a.navlink i{width:16px;height:16px;flex:0 0 auto;opacity:.85}
.nav button svg,.nav a.navlink svg{width:16px;height:16px;display:block;stroke:currentColor;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round}
.nav button span,.nav a.navlink span{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

.srv{margin:8px;padding:11px;background:rgba(255,255,255,.055);border:1px solid rgba(255,255,255,.08);border-radius:9px}
.srv label{display:block;font-size:10.5px;color:rgba(255,255,255,.55);margin-bottom:5px}
.srv .row{display:flex;gap:5px}
.srv input{flex:1;min-width:0;background:#fff;border:0;border-radius:5px;padding:5px 7px;font-size:11.5px;color:#22304a}
.srv .go{background:#3b74e8;color:#fff;border:0;border-radius:5px;padding:0 9px;font-size:11.5px;cursor:pointer;white-space:nowrap}
.srv .go:hover{background:#3268d8}
.srv .st{display:flex;align-items:center;gap:5px;margin-top:7px;font-size:11px;color:rgba(255,255,255,.62);min-width:0}
.srv .st span{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;line-height:1.2}
.srv .st em{width:6px;height:6px;border-radius:50%;background:#7b8798;flex:0 0 auto}
.srv .st em.ok{background:#3ddc84;box-shadow:0 0 0 3px rgba(61,220,132,.16)}
.srv .st em.bad{background:#ff6b5e;box-shadow:0 0 0 3px rgba(255,107,94,.15)}
/* 用过的服务地址：点输入框在它上方弹出，一条一个；右侧 × 单条删除 */
.srv .row{position:relative}
.srv .hostlist{position:absolute;left:0;right:0;bottom:calc(100% + 6px);z-index:60;background:#17243a;border:1px solid rgba(255,255,255,.14);border-radius:8px;box-shadow:0 12px 28px rgba(0,0,0,.42);padding:4px}
.srv .hostlist[hidden]{display:none}
.srv .hostlist .hh{font-size:10px;letter-spacing:.4px;color:rgba(255,255,255,.42);padding:3px 7px 5px}
.srv .hostlist .hi{display:flex;align-items:center;gap:4px;padding:5px 6px 5px 8px;border-radius:5px;cursor:pointer}
.srv .hostlist .hi:hover{background:rgba(255,255,255,.08)}
.srv .hostlist .hi.on{background:rgba(74,126,230,.22)}
.srv .hostlist .hu{flex:1;min-width:0;font-size:11.5px;color:#dbe4f2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.srv .hostlist .hx{flex:0 0 auto;width:17px;height:17px;line-height:16px;text-align:center;border-radius:4px;font-size:13px;font-weight:400;color:rgba(255,255,255,.45)}
.srv .hostlist .hx:hover{background:rgba(255,107,94,.2);color:#ff918a}

/* ============ 右侧主区 ============ */
.main{flex:1;min-width:0;display:flex;flex-direction:column;height:100%}
.head{padding:14px 22px;background:#fff;border-bottom:1px solid #e4e9f1;display:flex;align-items:center;gap:14px;flex:0 0 auto}
.head .h1{font-size:16px;font-weight:600;letter-spacing:.2px}
.head .h2{font-size:12px;color:#7a8598;margin-top:2px}
.head .sp{flex:1}
.btn{font:inherit;font-size:12.5px;padding:6px 13px;border-radius:7px;border:1px solid #d9e0ec;background:#fff;color:#3d4a5f;cursor:pointer;white-space:nowrap;transition:all .13s}
.btn:hover{border-color:#b9c8e0;background:#f7faff;color:#2b5fd0}
.btn.pri{background:#3b74e8;border-color:#3b74e8;color:#fff}
.btn.pri:hover{background:#2f66dd;border-color:#2f66dd;color:#fff}
.btn.pri:disabled{background:#b8c6dd;border-color:#b8c6dd;cursor:default}
/* 标题右侧「提示词写作参考」入口 */
.btn.gbtn{display:inline-flex;align-items:center;gap:6px;border-color:#cddff9;background:#f4f8ff;color:#2b5fd0}
.btn.gbtn:hover{background:#e9f2ff;border-color:#a9c8f2;color:#2350b8}
.btn.gbtn[hidden]{display:none}
.btn.gbtn svg{width:14px;height:14px;stroke:currentColor;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round}
/* 标题右侧「新手实操教程」外链（独立页面 /tutorial/，新窗口打开） */
.btn.tl{display:inline-flex;align-items:center;gap:6px;text-decoration:none;border-color:#cddff9;background:#f4f8ff;color:#2b5fd0}
.btn.tl:hover{background:#e9f2ff;border-color:#a9c8f2;color:#2350b8}
.btn.tl svg{width:14px;height:14px;stroke:currentColor;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round}

.work{flex:1;min-height:0;display:flex}
.work[hidden]{display:none}   /* .work 的 display:flex 会盖掉 [hidden]，必须显式关掉 */
.formcol{width:700px;flex:0 0 700px;background:#fff;border-right:1px solid #e4e9f1;overflow-y:auto;padding:16px 20px 20px}
.outcol{flex:1;min-width:0;display:flex;flex-direction:column;padding:14px 18px 0;overflow:hidden}

.fld{margin-bottom:14px}
.fld-row{display:flex;gap:10px;margin-bottom:14px}
.fld-row>.fld{flex:1 1 0;min-width:0;margin-bottom:0}
.fld-row>.fld input[type=number]{padding:8px 8px}
.tgl{display:flex;align-items:center;gap:8px;height:35px;cursor:pointer;user-select:none}
.tgl input{position:absolute;opacity:0;width:0;height:0}
.tgl-ui{position:relative;flex:0 0 auto;width:36px;height:20px;border-radius:10px;background:#cfd7e4;transition:background .15s}
.tgl-ui:after{content:"";position:absolute;top:2px;left:2px;width:16px;height:16px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(0,0,0,.18);transition:transform .15s}
.tgl input:checked+.tgl-ui{background:#3b74e8}
.tgl input:checked+.tgl-ui:after{transform:translateX(16px)}
.tgl-tx{font-size:12px;color:#6b7890;white-space:nowrap}
.fld .lb{display:flex;align-items:center;gap:6px;font-size:12.5px;color:#43506a;margin-bottom:5px;font-weight:500}
.fld .hint{font-size:11px;color:#93a0b4;margin-top:4px;line-height:1.45}
/* 提示词预填说明：这是示例不是标准答案 */
.fld .prompt-tip{font-size:11px;line-height:1.6;color:#6f7c92;background:#f4f8ff;border:1px solid #e0eafb;border-radius:7px;padding:7px 9px;margin-top:7px}
.fld .prompt-tip b{color:#2f62c9;font-weight:600}
.fld .prompt-tip button{font:inherit;font-size:10.5px;color:#3d6fd0;background:#fff;border:1px solid #cddcf5;border-radius:5px;padding:2px 7px;cursor:pointer;white-space:nowrap;margin-left:4px}
.fld .prompt-tip button:hover{background:#e9f2ff;border-color:#a9c4f0}
.fld .prompt-tip button[data-open-guide]{background:none;border:0;padding:0;margin:0;color:#2f62c9;text-decoration:underline;text-underline-offset:2px;font-size:inherit}
.fld .prompt-tip button[data-open-guide]:hover{background:none;color:#1a4aa8}
/* 图片提示词：文生图 / 图生图 模式切换 */
.fld .tpl-modes{display:flex;align-items:center;gap:6px;margin:2px 0 7px;flex-wrap:wrap}
.fld .tpl-modes>span{font-size:11px;color:#8a93a0;margin-right:2px}
.fld .tpl-modes button{font:inherit;font-size:11.5px;color:#5b6880;background:#fff;border:1px solid #dbe3ef;border-radius:6px;padding:5px 11px;cursor:pointer;white-space:nowrap;transition:all .13s}
.fld .tpl-modes button:hover{border-color:#9fc0f0;color:#2b5fd0}
.fld .tpl-modes button.on{background:#eaf2ff;border-color:#7fa8ee;color:#2350b8;font-weight:600}
.fld .lb .req{color:#e2554e;font-style:normal;margin-left:1px}
.fld textarea,.fld input[type=text],.fld input[type=number]{width:100%;border:1px solid #dde4ef;border-radius:7px;padding:8px 10px;font-size:13px;color:#232a36;background:#fff;transition:border .13s,box-shadow .13s}
.fld textarea{min-height:92px;resize:vertical;line-height:1.6;white-space:pre-wrap}
.fld textarea:focus,.fld input:focus{border-color:#7ba3f5;box-shadow:0 0 0 3px rgba(59,116,232,.1);outline:0}
/* 分镜范围：起始第 N 个 ~ 结束第 M 个 */
.fld .rng{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.fld .rng .rl{font-size:12.5px;color:#5b6880}
.fld .rng .rl.sep{color:#c3cddd}
.fld .rng .rl.tip{font-size:11px;color:#9aa7bb;margin-left:2px}
.fld .rng input[type=number]{width:66px;flex:0 0 auto;padding:7px 6px;text-align:center;font-family:inherit}
/* 平均分段时长：快捷选项（10 秒默认 / 15 秒 16G 以上建议） */
.fld .segdur{display:flex;align-items:center;gap:6px;flex-wrap:nowrap}
.fld .segdur input[type=number]{width:66px;flex:0 0 auto;padding:7px 6px;text-align:center;font-family:inherit}
.fld .segdur .u{font-size:12px;color:#7c8899;flex:0 0 auto}
.fld .sdopts{display:flex;gap:5px;flex:1;min-width:0;margin-top:0}
.fld .sdopts button{flex:1;min-width:0;font:inherit;font-size:11px;padding:8px 2px;border:1px solid #dde4ef;background:#fff;color:#6b7890;border-radius:6px;cursor:pointer;white-space:nowrap}
.fld .sdopts button:hover{border-color:#a9c4f0;color:#3d6fd0}
.fld .sdopts button.on{border-color:#8fb0e8;background:#eaf1fd;color:#2f62c9;font-weight:600}
/* 多场景编辑器 */
.scenes{display:flex;flex-direction:column;gap:9px}
.srow{border:1px solid #e2e8f2;border-radius:9px;padding:9px 10px 10px;background:#fbfcfe}
.srow .shd{display:flex;align-items:center;gap:9px;margin-bottom:7px}
.srow .shd b{font-size:12px;color:#2b5fd0;font-weight:600}
.srow .shd .dur{display:flex;align-items:center;gap:4px;font-size:11.5px;color:#7c8899;margin-left:auto}
.srow .shd .dur input{width:52px;border:1px solid #dde4ef;border-radius:5px;padding:2px 6px;font:inherit;font-size:11.5px;text-align:center}
.srow .shd .dur input.warn{border-color:#e8b271;background:#fffaf1;color:#a4611b;font-weight:600}
.srow .shd .relay{display:flex;align-items:center;gap:3px;font-size:11.5px;color:#5d738f;white-space:nowrap;cursor:pointer}
.srow .shd .relay input{width:13px;height:13px;margin:0;accent-color:#2b5fd0;cursor:pointer}
.srow .shd .dwx{display:none;font-style:normal;font-size:11px;color:#b8742a;background:#fff6e8;border:1px solid #f3e0c2;border-radius:6px;padding:1px 7px;white-space:nowrap}
.srow .shd .dwx.on{display:inline-block}
.srow .shd .sdel{width:19px;height:19px;line-height:1;border:0;border-radius:5px;background:#f0f3f8;color:#8b98ac;cursor:pointer;font-size:13px;padding:0}
.srow .shd .sdel:hover{background:#fdeceb;color:#d4564d}
.srow textarea{width:100%;min-height:56px;border:1px solid #dde4ef;border-radius:7px;padding:7px 9px;font:inherit;font-size:12.5px;line-height:1.6;color:#232a36;background:#fff;resize:vertical}
.srow textarea:focus{border-color:#7ba3f5;box-shadow:0 0 0 3px rgba(59,116,232,.1);outline:0}
.simg{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:0 0 7px}
.simg .chip{position:relative;display:flex;align-items:center;gap:5px;background:#fff;border:1px solid #e2e8f2;border-radius:7px;padding:2px 5px 2px 2px;max-width:100%}
.simg .chip img{width:26px;height:26px;border-radius:5px;object-fit:cover;display:block;background:#eef1f7}
.simg .chip i{font-style:normal;font-size:10.5px;color:#5b6880;max-width:96px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.simg .chip em{cursor:pointer;font-style:normal;color:#a5b0c1;font-size:12px;padding:0 1px}
.simg .chip em:hover{color:#d4564d}
.simg .spick{font:inherit;font-size:11.5px;color:#3d6fd0;background:#f2f7ff;border:1px dashed #b7cdf5;border-radius:7px;padding:5px 10px;cursor:pointer}
.simg .spick:hover{background:#e9f2ff}
.sAdd{width:100%;margin-top:9px;padding:7px 0;font-size:12.5px}

.pickbox{border:1px solid #dde4ef;border-radius:8px;padding:8px;background:#fafbfe;display:flex;align-items:center;gap:10px;min-height:52px}
.pickbox .pv{width:40px;height:40px;border-radius:6px;background:#eef1f7;flex:0 0 auto;overflow:hidden;display:flex;align-items:center;justify-content:center;color:#9aa7bb;font-size:13px}
.pickbox .pv img{width:100%;height:100%;object-fit:cover;display:block}
.pickbox .nm{flex:1;min-width:0}
.pickbox .nm b{display:block;font-size:12.5px;font-weight:500;color:#2b3648;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pickbox .nm span{font-size:11px;color:#95a1b4}
.pickbox .acts{display:flex;gap:6px;flex:0 0 auto}
.pickbox .acts button{font:inherit;font-size:11.5px;padding:4px 10px;border-radius:6px;border:1px solid #cfdaea;background:#fff;color:#3d6fd0;cursor:pointer}
.pickbox .acts button:hover{background:#eef4ff;border-color:#a9c4f0}
.pickbox .acts button.clr{color:#8b97a9;border-color:#e2e8f1}
.pickbox .acts button.clr:hover{color:#d4564d;border-color:#f0c3bf;background:#fff5f4}
/* 目录字段：手写 + 点选 */
.fld .diredit{display:flex;gap:8px;align-items:center}
.fld .diredit input{flex:1;min-width:0}
.fld .diredit button{flex:0 0 auto;font:inherit;font-size:12px;padding:8px 13px;border-radius:7px;border:1px solid #cfdaea;background:#fff;color:#3d6fd0;cursor:pointer;white-space:nowrap}
.fld .diredit button:hover{background:#eef4ff;border-color:#a9c4f0}

.runbar{display:flex;gap:8px;border-top:1px solid #eef1f6;margin-top:16px;padding-top:14px}
.runbar .btn{flex:1;padding:9px 0;font-size:13.5px}

.panel{background:#fff;border:1px solid #e4e9f1;border-radius:11px;display:flex;flex-direction:column;overflow:hidden;flex:1;min-height:0}
.panel .ph{display:flex;align-items:center;gap:10px;padding:9px 14px;border-bottom:1px solid #eef1f6;flex:0 0 auto}
.panel .ph b{font-size:12.5px;font-weight:600;color:#3a465c}
.panel .ph .sp{flex:1}
.panel .ph .tag{font-size:11px;color:#8d99ac}
.pbody{flex:1;min-height:0;overflow-y:auto;padding:14px}

.prog{display:none;margin-bottom:12px}
.prog.on{display:block}
.prog .bar{height:6px;background:#eef1f6;border-radius:4px;overflow:hidden}
.prog .bar i{display:block;height:100%;width:0;background:linear-gradient(90deg,#4a7ee6,#7aa5ff);border-radius:4px;transition:width .25s}
.prog .tx{display:flex;justify-content:space-between;font-size:11.5px;color:#7c8899;margin-top:5px}

.empty{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;color:#a5b0c1;font-size:13px;padding:40px 0}
.empty .ic{width:44px;height:44px;border-radius:12px;background:#f2f5fa;display:flex;align-items:center;justify-content:center;color:#c3cddd}
.empty .ic svg{width:22px;height:22px;stroke:currentColor;stroke-width:1.6;fill:none}

.res{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:10px}
.res figure{margin:0;border:1px solid #e6ebf3;border-radius:9px;overflow:hidden;background:#fafbfe;max-width:340px}
.res img,.res video{width:100%;display:block;background:#000}
.res audio{width:100%;display:block;margin:0}
/* 音频结果：不要上面那张占位图，播放条横跨整行、占满宽度 */
.res figure.aud{grid-column:1 / -1;max-width:none}
.res .audbox{padding:12px 10px}
.res figcaption{display:flex;align-items:center;gap:6px;padding:6px 9px;font-size:11px;color:#7f8b9d;border-top:1px solid #eef1f6}
.res figcaption b{flex:1;font-weight:400;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.res figcaption a{color:#3d6fd0;font-size:11px;text-decoration:none}
.logbox{margin-top:12px;border-top:1px dashed #e8edf4;padding-top:10px;font-size:11.5px;color:#7c8899;max-height:120px;overflow-y:auto}
.logbox div{padding:1.5px 0}
.logbox div.err{color:#d4564d}

.tasks{flex:0 0 auto;background:#fff;border:1px solid #e4e9f1;border-radius:11px;margin:12px 0 14px;overflow:hidden;display:flex;flex-direction:column;max-height:262px}
.tasks.collapsed .tk-body{display:none}
.tasks .ph{display:flex;align-items:center;gap:10px;padding:9px 14px;border-bottom:1px solid #eef1f6;cursor:pointer;flex:0 0 auto}
.tasks .ph b{font-size:12.5px;font-weight:600;color:#3a465c}
.tasks .ph .tag{font-size:11px;color:#98a4b7}
.tasks .ph .sp{flex:1}
.tasks .ph .hact{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap}
.tasks .ph .hact:hover{text-decoration:underline}
.tasks .ph .chev{color:#9aa7bb;transition:transform .18s}
.tasks.collapsed .ph .chev{transform:rotate(-90deg)}
.tk-body{overflow-y:auto;flex:1;min-height:0}
.tk{display:flex;align-items:center;gap:11px;padding:8px 14px;border-bottom:1px solid #f2f5f9}
.tk:last-child{border-bottom:0}
.tk .th{width:44px;height:44px;border-radius:6px;background:#f1f4f9;flex:0 0 auto;overflow:hidden;display:flex;align-items:center;justify-content:center;color:#a9b5c6;font-size:13px}
.tk .th img,.tk .th video{width:100%;height:100%;object-fit:cover;display:block}
.tk .info{flex:1;min-width:0}
.tk .info b{display:block;font-size:12.5px;font-weight:500;color:#2b3648;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tk .info span{font-size:11px;color:#98a4b7}
.tk .badge{font-size:10.5px;padding:1.5px 7px;border-radius:10px;white-space:nowrap}
.tk .badge.ok{background:#e9f8ef;color:#2c9b5e}
.tk .badge.run{background:#eef4ff;color:#3b74e8}
.tk .badge.err{background:#fdeceb;color:#d4564d}
.tk .dl{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap}
.tk .dl:hover{text-decoration:underline}
.tk-empty{padding:26px 0;text-align:center;color:#aab5c6;font-size:12.5px}

/* ============ 进行中队列（右栏面板 + 左栏专属页共用） ============ */
.runq{margin:12px 0 0;max-height:184px}
.runq + .tasks{margin-top:10px}
.runq.idle .tk-body,.runq.collapsed .tk-body{display:none}
.runq.collapsed .ph .chev{transform:rotate(-90deg)}
.qtk{padding:7px 14px;position:relative}
.qtk .qi{width:28px;height:28px;flex:0 0 auto;border-radius:8px;background:#eef4ff;color:#3b74e8;display:flex;align-items:center;justify-content:center}
.qtk .qi svg{width:16px;height:16px;stroke:currentColor;stroke-width:1.8;fill:none;stroke-linecap:round;stroke-linejoin:round;animation:qspin 2.4s linear infinite}
@keyframes qspin{to{transform:rotate(360deg)}}
.qtk .qbar{height:4px;background:#eef1f6;border-radius:3px;overflow:hidden;margin-top:5px}
.qtk .qbar i{display:block;height:100%;width:0;background:linear-gradient(90deg,#4a7ee6,#7aa5ff);border-radius:3px;transition:width .3s}
.qtk .qview{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap;border:1px solid #cddcf5;background:#f4f8ff;border-radius:6px;padding:3px 9px}
.qtk .qview:hover{background:#e9f2ff}
.navcnt{display:inline-block;min-width:16px;padding:0 4px;border-radius:8px;background:rgba(255,255,255,.14);color:#cbd8ea;font-size:10px;text-align:center;font-style:normal;line-height:16px}
.navcnt.on{background:#3b74e8;color:#fff}
.runwrap{display:none}
.runwrap.on{display:flex}
.runwrap .hpanel{flex:1;margin:14px 18px 14px}
.runwrap .ph .hact{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap}
.runwrap .ph .hact:hover{text-decoration:underline}
.runwrap .qtk{padding:10px 16px}

/* ============ 素材选择弹层 ============ */
.pmask{position:fixed;inset:0;background:rgba(16,28,49,.5);z-index:800;display:none;align-items:center;justify-content:center;padding:24px}
.pmask.on{display:flex}
.pdlg{width:min(1180px,100%);height:min(680px,100%);background:#fff;border-radius:13px;display:flex;flex-direction:column;overflow:hidden;box-shadow:0 24px 60px rgba(16,28,49,.3)}
.pdlg header{display:flex;align-items:center;gap:12px;padding:13px 16px;border-bottom:1px solid #eef1f6;flex:0 0 auto}
.pdlg header b{font-size:14px}
.pdlg header input{flex:1;max-width:220px;border:1px solid #e0e6f0;border-radius:6px;padding:5px 9px;font-size:12.5px}
.pdlg header .newdir{flex:0 0 auto;font:inherit;font-size:12px;white-space:nowrap;padding:5px 11px;border:1px solid #cddcf5;border-radius:6px;background:#f4f8ff;color:#3d6fd0;cursor:pointer}
.pdlg header .newdir:hover{background:#e9f2ff;border-color:#a9c4f0}
.pdlg header .x{margin-left:auto;background:none;border:0;font-size:18px;color:#96a2b5;cursor:pointer;line-height:1}
.pdlg .tabs{display:flex;gap:5px;flex-wrap:wrap;padding:10px 16px 0;flex:0 0 auto;max-height:88px;overflow-y:auto;scrollbar-gutter:stable}
.pdlg .phint{margin:9px 16px 0;padding:7px 11px;border-radius:7px;background:#fff8e6;border:1px solid #f0dcaa;color:#87611a;font-size:12px;line-height:1.65;flex:0 0 auto}
.pdlg .phint b{color:#6d4c08}
.pdlg .phint[hidden]{display:none}
.pdlg .tabs button{font:inherit;font-size:12px;padding:4px 12px;border-radius:14px;border:1px solid #e2e8f2;background:#fff;color:#5b6880;cursor:pointer}
.pdlg .tabs button.on{background:#eef4ff;border-color:#b7cdf5;color:#2b5fd0;font-weight:500}
.pdlg .grid{flex:1;min-height:0;overflow-y:auto;padding:12px 16px;display:flex;flex-wrap:wrap;gap:8px;align-content:flex-start;scrollbar-gutter:stable}
.pdlg .gi{width:118px;height:118px;border-radius:8px;overflow:hidden;border:2px solid transparent;background:#f2f5fa;cursor:pointer;position:relative;flex:0 0 auto}
.pdlg .gi:hover{border-color:#9dbcf5}
.pdlg .gi.on{border-color:#3b74e8;box-shadow:0 2px 8px rgba(59,116,232,.22)}
.pdlg .gi img,.pdlg .gi video{width:100%;height:100%;object-fit:cover;display:block;background:#0d0f18}
.pdlg .gi .nm{position:absolute;left:0;right:0;bottom:0;padding:4px 6px;font-size:10px;color:#fff;background:linear-gradient(transparent,rgba(0,0,0,.62));overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pdlg .gi .n{position:absolute;top:0;left:0;width:19px;height:19px;background:#3b74e8;color:#fff;font-size:10.5px;line-height:19px;text-align:center;border-radius:0 0 5px 0;display:none;z-index:2}
.pdlg .gi.on .n{display:block}
.pdlg .gi.file{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:8px;text-align:center}
.pdlg .gi.file .ic{font-size:22px;color:#9db0c9}
.pdlg .gi.file .fn{font-size:10.5px;color:#6b7a91;line-height:1.35;word-break:break-all;max-height:34px;overflow:hidden}
.pdlg .gi.dir{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;background:#f7faff}
.pdlg .gi.dir .ic{font-size:24px;color:#8fb0e8}
.pdlg .gi.dir .fn{font-size:11px;color:#44536b;padding:0 6px;text-align:center;word-break:break-all}
.pstrip{flex:0 0 auto;display:none;gap:8px;padding:9px 16px 10px;border-top:1px solid #eef1f6;background:#fbfcfe;overflow-x:auto;overflow-y:hidden;align-items:flex-start}
.pstrip.on{display:flex}
.pstrip .ph{flex:0 0 auto;font-size:11px;color:#8b98ac;padding-top:27px;line-height:1.5;white-space:nowrap}
.pstrip .pc{position:relative;flex:0 0 auto;width:66px;padding-bottom:2px}
.pstrip .pc img{width:66px;height:66px;border-radius:6px;object-fit:cover;display:block;background:#eef1f7;border:1px solid #e2e8f2}
.pstrip .pc .no{position:absolute;top:3px;left:3px;min-width:15px;height:15px;line-height:15px;padding:0 3px;border-radius:8px;background:rgba(59,116,232,.92);color:#fff;font-size:9.5px;text-align:center;z-index:2}
.pstrip .pc .ops{display:flex;gap:2px;justify-content:center;margin-top:3px}
.pstrip .pc .ops button{flex:0 0 auto;width:19px;height:17px;line-height:15px;border:1px solid #dbe3f0;background:#fff;color:#4a576e;border-radius:4px;font-size:10.5px;cursor:pointer;padding:0}
.pstrip .pc .ops button:hover:not(:disabled){background:#eef4ff;border-color:#b7cdf5;color:#2b5fd0}
.pstrip .pc .ops button.rm{color:#8b98ac}
.pstrip .pc .ops button.rm:hover{background:#fdeceb;border-color:#f0c4c1;color:#d4564d}
.pstrip .pc .ops button:disabled{opacity:.3;cursor:default}
.pstrip .pc .nm{font-size:9.5px;color:#7c8899;margin-top:3px;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pdlg footer{display:flex;align-items:center;gap:9px;padding:11px 16px;border-top:1px solid #eef1f6;flex:0 0 auto}
.pdlg footer .sel{flex:1;font-size:12px;color:#7c8899;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pdlg footer .hb{position:relative;overflow:hidden}
.pdlg footer .hb input{position:absolute;inset:0;opacity:0;cursor:pointer;width:100%;height:100%}
.pdlg footer .hb.off{border-color:#e4e9f1;background:#f6f8fc;color:#a9b3c3}
.pdlg footer .hb.off input{cursor:not-allowed}
/* 素材选择器内新建子目录 */
.dirdlg{width:min(430px,100%)}
.dirdlg .cdlg-inner,.dirdlg .dirbody{padding:16px 18px 4px}
.dirdlg label{display:block;font-size:12.5px;color:#5b6880;margin-bottom:7px}
.dirdlg #dirName{width:100%;box-sizing:border-box;border:1px solid #dbe3f0;border-radius:7px;padding:9px 11px;font-size:13px;outline:none}
.dirdlg #dirName:focus{border-color:#8fb0e8;box-shadow:0 0 0 3px rgba(59,116,232,.1)}
.dirdlg .dirnote{font-size:11.5px;color:#93a0b4;margin-top:8px;line-height:1.6}
.dirdlg .dirnote.err{color:#d4564d}
.fxtoast{position:fixed;top:20px;left:50%;transform:translateX(-50%) translateY(-14px);background:#101c31;color:#fff;font-size:13px;padding:9px 17px;border-radius:9px;box-shadow:0 10px 28px rgba(16,28,49,.3);opacity:0;transition:opacity .2s,transform .2s;z-index:2000;pointer-events:none;max-width:70vw;text-align:center}
.fxtoast.on{opacity:1;transform:translateX(-50%) translateY(0)}
.pload{display:none;align-items:center;gap:8px;font-size:12px;color:#5b6880;padding:0 16px 10px}
.pload.on{display:flex}
.pload .pb{flex:1;height:4px;background:#eef1f6;border-radius:3px;overflow:hidden}
.pload .pb i{display:block;height:100%;width:0;background:#3b74e8;transition:width .2s}

/* ============ 提示词写作参考弹层 ============ */
.gmask{position:fixed;inset:0;background:rgba(16,28,49,.5);z-index:880;display:none;align-items:center;justify-content:center;padding:24px}
.gmask.on{display:flex}
.gdlg{width:min(1180px,100%);height:min(720px,100%);background:#fff;border-radius:13px;display:flex;flex-direction:column;overflow:hidden;box-shadow:0 24px 60px rgba(16,28,49,.3)}
.gdlg header{display:flex;align-items:baseline;gap:10px;padding:13px 18px;border-bottom:1px solid #eef1f6;flex:0 0 auto}
.gdlg header b{font-size:14px;color:#232a36}
.gdlg header .sub{font-size:11.5px;color:#8b98ac}
.gdlg header .x{margin-left:auto;background:none;border:0;font-size:19px;line-height:1;color:#96a2b5;cursor:pointer;padding:0 2px}
.gdlg header .x:hover{color:#4a5568}
.gtabs{display:flex;gap:6px;flex-wrap:wrap;padding:11px 18px 0;flex:0 0 auto}
.gtabs button{font:inherit;font-size:12px;padding:5px 13px;border-radius:14px;border:1px solid #e2e8f2;background:#fff;color:#5b6880;cursor:pointer;transition:all .13s}
.gtabs button:hover{border-color:#b7cdf5;color:#2b5fd0}
.gtabs button.on{background:#eef4ff;border-color:#b7cdf5;color:#2b5fd0;font-weight:500}
.gbody{flex:1;min-height:0;overflow-y:auto;padding:14px 18px 20px}
.glead{font-size:12.5px;color:#5b6880;line-height:1.72;background:#f6f9ff;border:1px solid #e4eefc;border-radius:8px;padding:9px 12px;margin:0 0 14px}
.gsec{margin:0 0 11px}
.gsec h4{margin:0 0 4px;font-size:12.5px;color:#2b5fd0;font-weight:600}
.gsec p{margin:0;font-size:12.5px;color:#4a5568;line-height:1.74}
.gbody code{background:#f2f5fa;border-radius:4px;padding:1px 4px;font-size:11.5px;color:#b4483f;font-family:ui-monospace,Menlo,Consolas,monospace}
.gtl{display:flex;align-items:center;gap:8px;font-size:12px;color:#43506a;font-weight:600;margin:0 0 7px}
.gtl:before{content:"";width:3px;height:12px;border-radius:2px;background:#3b74e8}
.gmore{font-size:11.5px;color:#9aa7bb;margin:-8px 0 12px}
.gplay{margin:0 0 14px;background:#f7f9fc;border:1px solid #e6ecf5;border-radius:8px;padding:9px 11px;font-size:11.5px;line-height:1.66;color:#39445a;white-space:pre-wrap;word-break:break-word;font-family:ui-monospace,Menlo,Consolas,monospace}
.grules{margin:14px 0 0;padding:0;list-style:none}
.grules li{position:relative;padding:0 0 7px 14px;font-size:12.5px;color:#4a5568;line-height:1.72}
.grules li:before{content:"";position:absolute;left:0;top:8px;width:5px;height:5px;border-radius:50%;background:#9fc0f2}
.grules.checks{counter-reset:ck;margin-top:4px}
.grules.checks li{counter-increment:ck;padding:0 0 9px 24px}
.grules.checks li:before{content:counter(ck);left:0;top:1px;width:17px;height:17px;line-height:17px;border-radius:50%;background:#eef4ff;color:#2b5fd0;font-size:10.5px;text-align:center;font-weight:600}
.gdlg footer{display:flex;align-items:center;gap:9px;padding:11px 18px;border-top:1px solid #eef1f6;background:#fbfcfe;flex:0 0 auto}
.gdlg footer .gnote{flex:1;font-size:11.5px;color:#93a0b4}
.gdlg footer .btn[hidden]{display:none}
/* 使用声明弹层：复用 .gmask/.gdlg 骨架，尺寸小一点、内容自适应高度 */
.tdlg{width:min(740px,100%);height:auto;max-height:min(760px,100%)}
.tlead{font-size:13px;color:#43506a;line-height:1.85;margin:0 0 12px;padding:10px 12px;background:#f5f8fe;border-left:3px solid #7fa8ee;border-radius:0 6px 6px 0}
/* 编号自己用 counter 画：reset.css 把 ol 的 list-style 全关了，原生 marker 在部分浏览器不出 */
.tlist{margin:0;padding:0;list-style:none;counter-reset:tm}
.tlist li{position:relative;font-size:12.5px;color:#4a5568;line-height:1.85;margin-bottom:10px;padding-left:27px;counter-increment:tm}
.tlist li:before{content:counter(tm);position:absolute;left:0;top:4px;width:18px;height:18px;line-height:18px;border-radius:50%;background:#eef4ff;color:#2b5fd0;font-size:10.5px;text-align:center;font-weight:600}
.tlist li b{color:#232a36;margin-right:3px}
.tlist li:last-child{margin-bottom:0}

/* ================= 任务记录 · 产物预览弹层 ================= */
.vdlg{width:min(980px,100%);height:min(800px,100%)}
.vstage{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;background:#101c31;overflow:auto;padding:14px}
.vstage img{max-width:100%;max-height:100%;object-fit:contain;display:block}
.vstage video{max-width:100%;max-height:100%;display:block;background:#000}
.vstage .audbox{width:90%;max-width:760px;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;gap:14px;padding:20px 22px;border-radius:12px;background:#f6f8fc;border:1px solid #2b3d59;box-shadow:0 10px 30px rgba(0,0,0,.28);color:#7c8899}
.vstage .audbox audio{width:100%;max-width:100%;display:block}
.vstage .vnone{color:#8b98ac;font-size:12.5px;text-align:center;max-width:70%;line-height:1.9}
.vstrip .vc .va{width:58px;height:58px;border-radius:6px;background:#eef1f7;border:1px solid #e2e8f2;display:flex;align-items:center;justify-content:center}
.vstrip .vc.cur .va{border:2px solid #3b74e8}
.vstrip{flex:0 0 auto;display:none;gap:7px;padding:9px 14px;border-top:1px solid #eef1f6;background:#fbfcfe;overflow-x:auto;overflow-y:hidden;align-items:flex-start}
.vstrip.on{display:flex}
.vstrip .vc{position:relative;flex:0 0 auto;width:58px;padding-bottom:16px;cursor:pointer}
.vstrip .vc img,.vstrip .vc video{width:58px;height:58px;border-radius:6px;object-fit:cover;display:block;background:#eef1f7;border:1px solid #e2e8f2}
.vstrip .vc .nm{position:absolute;left:0;right:0;bottom:0;font-size:9px;color:#7c8899;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.vstrip .vc.cur img,.vstrip .vc.cur video{border:2px solid #3b74e8}
.tk[data-tk]{cursor:pointer}
.tk[data-tk]:hover{background:#f6f9fe}
.tk .dl:hover,.tk .vprev:hover{text-decoration:underline}
.tk .vprev{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap;border:1px solid #cddcf5;background:#f4f8ff;border-radius:6px;padding:3px 9px}

/* ============ 任务记录页（左栏专属菜单） ============ */
.histwrap{display:none}
.histwrap.on{display:flex}
.histwrap .hpanel{flex:1;margin:14px 18px 14px}
.histwrap .ph #hRefresh,.histwrap .ph .hact{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap}
.histwrap .ph #hRefresh:hover,.histwrap .ph .hact:hover{text-decoration:underline}
.histwrap .ph .hact.warn{color:#c0563a}
.hcats{display:flex;gap:4px;margin-right:8px}
.hcats button{height:24px;padding:0 10px;border:1px solid #dde4ef;background:#fff;border-radius:12px;color:#5a6b83;font-size:11.5px;cursor:pointer}
.hcats button:hover{border-color:#a9c3ec;color:#3d6fd0}
.hcats button.on{background:#eaf1fd;border-color:#8fb0e8;color:#2f62c9;font-weight:600}
.hsearch{height:24px;width:150px;padding:0 9px;border:1px solid #dde4ef;border-radius:12px;font-size:11.5px;color:#46536b;background:#fff;margin-right:8px;outline:none}
.hsearch:focus{border-color:#8fb0e8}
.tk .del{font-size:11.5px;color:#c0563a;cursor:pointer;white-space:nowrap;border:1px solid #f0d3cb;background:#fdf5f3;border-radius:6px;padding:3px 9px}
.tk .del:hover{background:#fbe9e4}
/* 查看提示词：运行区按钮 + 任务记录行按钮 */
.btnv{font-size:11.5px;color:#3d6fd0;cursor:pointer;white-space:nowrap;border:1px solid #cddcf5;background:#f4f8ff;border-radius:6px;padding:3px 9px}
.btnv:hover{background:#e9f2ff;border-color:#a9c4f0}
.btnv[hidden]{display:none}
.pmv{font-size:11.5px;color:#4a5a74;cursor:pointer;white-space:nowrap;border:1px solid #dde4ef;background:#fff;border-radius:6px;padding:3px 9px}
.pmv:hover{border-color:#9fc0f0;color:#2b5fd0;background:#f4f8ff}
/* 提示词查看弹层 */
.pmdlg{width:min(1180px,100%);height:min(720px,100%)}
.pmdlg .pmbody{flex:1;min-height:0;overflow:auto;margin:0;padding:15px 18px;background:#f7f9fc;color:#2c3648;font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12.5px;line-height:1.7;white-space:pre-wrap;word-break:break-word}
.hlist{flex:1;min-height:0;overflow-y:auto}
/* 通用确认弹层 */
.cdlg{width:min(440px,100%);background:#fff;border-radius:14px;padding:18px 20px 14px;box-shadow:0 18px 50px rgba(20,32,52,.22)}
.cdlg header b{font-size:15px;color:#22314a}
.cdlg .cbody{margin:12px 0 4px;font-size:13px;color:#46536b;line-height:1.8}
.cdlg footer{display:flex;justify-content:flex-end;gap:8px;margin-top:14px}
/* TTS 引擎选择弹层 */
.ttsdlg header{display:flex;align-items:center;border-bottom:1px solid #eef1f6;padding-bottom:11px;margin-bottom:4px}
.ttsdlg header b{flex:1}
.ttsdlg header .x{margin-left:auto;background:none;border:0;font-size:20px;line-height:1;color:#96a2b5;cursor:pointer;padding:0 2px}
.ttsdlg header .x:hover{color:#4a5568}
.ttsdlg .ttsopts{display:flex;flex-direction:column;gap:9px;margin:12px 0 4px}
.ttsopt{display:flex;align-items:center;gap:12px;width:100%;text-align:left;padding:12px 13px;border:1px solid #dde4ef;border-radius:9px;background:#fff;cursor:pointer;transition:border-color .13s,background .13s,transform .13s}
.ttsopt:hover{border-color:#7fb59a;background:#f4faf7;transform:translateY(-1px)}
.ttsopt .ic{width:38px;height:38px;flex:0 0 auto;border-radius:9px;background:#e3f0ea;display:flex;align-items:center;justify-content:center;font-size:19px}
.ttsopt .tx{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.ttsopt .tx b{font-size:13.5px;color:#22314a}
.ttsopt .tx em{font-style:normal;font-size:11.5px;color:#78859a}
.ttsopt .tx code{font-size:10.5px;color:#3b74e8;word-break:break-all;margin-top:2px}
.ttsopt .ar{font-size:22px;color:#b6c2d3}
.ttsnote{font-size:11.5px;color:#8a93a0;line-height:1.65;background:#f7f9fc;border-radius:7px;padding:8px 10px;margin-top:8px}
.hpager{flex:0 0 auto;display:flex;align-items:center;justify-content:center;gap:6px;padding:10px 14px;border-top:1px solid #eef1f6;background:#fbfcfe;flex-wrap:wrap}
.hpager:empty{display:none}
.hpager button{min-width:30px;height:28px;padding:0 9px;border:1px solid #d8e0ec;background:#fff;border-radius:6px;color:#4a5a74;font-size:12px;cursor:pointer}
.hpager button:hover:not(:disabled){border-color:#8fb0e8;color:#3d6fd0}
.hpager button.on{background:#3b74e8;border-color:#3b74e8;color:#fff;font-weight:600}
.hpager button:disabled{opacity:.45;cursor:default}
.hpager .dots{color:#aab5c6;font-size:12px;padding:0 2px}

@media (max-width:980px){
  .side{width:100%;flex:0 0 auto;height:auto;flex-direction:row;overflow-x:auto}
  .app{flex-direction:column;height:100dvh;overflow:auto}
  .brand{display:none}
  .nav{display:flex;gap:4px;padding:6px;overflow-x:auto}
  .nav .grp{display:none}
  .nav button,.nav a.navlink{width:auto;white-space:nowrap;padding:6px 11px}
  .nav button i,.nav a.navlink i{display:none}
  .srv{margin:6px;min-width:230px}
  .main{height:auto}
  .work{flex-direction:column}
  .formcol{width:100%;flex:0 0 auto;border-right:0;border-bottom:1px solid #e4e9f1}
  .outcol{min-height:420px}
  .head{flex-wrap:wrap;padding:12px 14px}
}
