/* CreateAI — a video-first creative workspace */
:root{color-scheme:dark;--bg:#101014;--card:#1a1a21;--line:#303039;--ink:#f3f2f7;--ink2:#a6a3b4;--ink3:#777484;--accent:#d4c4ff;--green:#d4c4ff;--grad:linear-gradient(110deg,#d4c4ff,#a798ee)}
*{box-sizing:border-box}body{background:var(--bg);color:var(--ink);font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;-webkit-font-smoothing:antialiased}a{text-decoration:none;color:inherit}button,input{font:inherit}button,a{touch-action:manipulation}button{transition:background .18s,transform .18s}button:not(:disabled):active{transform:translateY(1px)}:focus-visible{outline:2px solid #cbb9ff;outline-offset:3px}button:disabled{cursor:not-allowed}::selection{background:#cbb9ff45}::-webkit-scrollbar{width:5px;height:5px}::-webkit-scrollbar-thumb{background:#45414e;border-radius:6px}
.sidebar{width:184px;flex:0 0 184px;background:#131317;border-color:#292830}.s-brand{padding:30px 20px 36px;font-size:21px;letter-spacing:-1px;color:#f4edff}.s-brand::before{content:'▶';display:inline-grid;place-items:center;margin-right:8px;width:28px;height:28px;border:1px solid #b5a1ef;border-radius:9px;color:#d9caff;font-size:12px;vertical-align:2px}.sidebar-nav{padding:0 12px;gap:8px}.mi{padding:12px 14px;font-size:13px;border-radius:9px;color:#96939f}.mi::before{display:inline-block;width:25px;color:#b7b2c2;font-size:15px}.mi:nth-child(1)::before{content:'⌂'}.mi:nth-child(2)::before{content:'✧'}.mi:nth-child(3)::before{content:'▤'}.mi:nth-child(4)::before{content:'◇'}.mi:nth-child(5)::before{content:'⚙'}.mi.active{background:#2b253b;color:#e2d5ff}.mi.active::before{color:#d4c4ff}.mi:hover{background:#222127;color:#fff}.s-foot{padding:18px 12px}.s-kf{font-size:10px;color:#777482;font-weight:400}.s-point{padding:16px;background:linear-gradient(135deg,#2a2239,#1c1925);border-color:#40344e;border-radius:12px;color:#aaa0bb}.s-point b{font-size:25px;color:#e0d1ff}.s-me{color:#b6afc4;font-weight:400}.btn-logout{border-color:#34303e;color:#9d95aa}
.view-create .main{display:grid;grid-template-columns:minmax(0,1fr) 220px}.view-create .stage{grid-column:1;grid-row:1;padding:32px;overflow-y:auto;background:radial-gradient(ellipse at 90% 0,#24203050,transparent 50%),#101014}.view-create .hist{grid-column:2;grid-row:1;width:auto;flex:auto;background:#15151b;border-left:1px solid #2c2933;border-right:0;padding:30px 14px}.hist-h{margin-bottom:24px}.hist-h-t strong{font-size:14px}.hist-h-t span{font-size:10px;color:#787382;margin-top:7px}.hbtn{border-color:#36313f;color:#a39aad}.hbtn.is-new{color:#e0d0ff;background:#30263f;border-color:#4d3c65}.hitem{padding:12px;border:1px solid #2d2935;background:#1b1921;border-radius:10px;margin-bottom:5px}.hitem.on{background:#2b2439;border-color:#66527d}.hitem .ht{color:#c2bbc9}.hitem .hm{font-size:10px}.empty{font-size:12px;color:#777181;line-height:1.8}
.view-create .page{display:grid;grid-template-columns:minmax(300px,.88fr) minmax(280px,1.12fr);grid-template-rows:auto auto auto auto 1fr;gap:18px 24px;padding:0;background:none;border:0;min-height:100%;flex:0 0 auto;overflow:visible;align-content:start}.studio-heading{grid-column:1/-1;display:flex;justify-content:space-between;align-items:center;padding-bottom:18px}.section-tag{font-size:10px;font-weight:600;letter-spacing:2.5px;color:#a594c4}.studio-heading h1{font-size:27px;font-weight:600;letter-spacing:-1px;margin:9px 0}.studio-heading p{font-size:12px;color:#8c8598;margin:0}.studio-heading>a{font-size:11px;color:#c8b9e0;border:1px solid #3b3348;border-radius:8px;padding:9px 12px}.view-create .tabs{grid-column:1;grid-row:2;margin:0;gap:0;border-bottom:1px solid #302b37;padding-bottom:10px}.view-create .tabs div.on{font-size:13px;padding:0;background:none;color:#e2d5f7;height:24px;line-height:24px}.view-create .tabs::after{content:'01 / 创作设置';margin-left:auto;font-size:10px;letter-spacing:1px;color:#756b83;padding-top:4px}
.view-create .pwrap{grid-column:1;grid-row:3;margin:0;background:#1a1821;border:1px solid #3c3349;border-radius:14px;min-height:325px;flex:none;overflow:visible}.view-create .pwrap:focus-within{border-color:#594b68;box-shadow:none}.view-create .phead{padding:15px;border-bottom:1px solid #322b3c;min-height:50px;flex-wrap:wrap}.plabel{font-size:12px;color:#dfd5eb}.phint{font-size:9px;color:#7f738d;display:block;margin:4px 0 0}.mbtn{font-size:10px;border-color:#4c3d5e;color:#baabc9}.view-create .refbox{background:#18161e;border-bottom:1px solid #332b3e;padding:14px;min-height:104px;border-radius:0}.view-create .pinput{min-height:132px;padding:16px;font-size:13px;line-height:1.9;background:#1a1821;color:#eee5f9;caret-color:#d6bcff}.view-create .pinput:focus,.view-create .pinput:focus-visible{outline:none;box-shadow:none}.pinput:empty::before{color:#73667f}.pmeta{background:#1a1821;border-radius:0 0 14px 14px;color:#796d88}.ref-add{background:#25202f!important;border-color:#5d4c70!important;color:#b6a0ce!important}.view-create .prow-row{grid-column:1;grid-row:4;grid-template-columns:1fr 1fr;gap:10px;margin:0}.view-create .pick{height:49px;padding:10px 12px;background:#1c1923;border:1px solid #39313f;border-radius:9px}.pick .k{font-size:10px;color:#8f809e}.pick .v{font-size:11px;color:#ded2e9}.pick .lk{font-size:8px;color:#7e6d8e;border-color:#42364d}.mlist{background:#211c2b;border-color:#554261;box-shadow:0 16px 32px #0006}.mitem2{font-size:11px;color:#c8b9d7}.mitem2.on{background:#3b2b4e;border-color:#70548d}.view-create .acts{grid-column:1;grid-row:5;position:static;display:grid;grid-template-columns:1fr auto;gap:12px;align-content:start;border:0;margin:0;padding:0;background:transparent}.acts .tip{font-size:10px;color:#8d7f9d;white-space:normal}.acts .cost{font-size:11px;color:#cbb0ec}.acts #genBtn{grid-column:1;height:46px;font-size:13px;padding:0 22px;background:#d2b7f4;color:#271434;border-radius:9px;border:1px solid #dec9fa;box-shadow:0 6px 24px #a77adc12}.acts .btn.g{height:46px;padding:0 18px;border:1px solid #43344f;color:#b6a2c4;background:#201927;border-radius:9px}
.view-create .stage-view{grid-column:2;grid-row:2/6;align-self:stretch;margin:0;min-height:540px;border:1px solid #3a3043;border-radius:16px;flex:none;background:#17131d;box-shadow:0 20px 70px #0003}.stage-view.is-idle{background:linear-gradient(180deg,#100d1a20 0%,#15102060 40%,#151020f5 82%),url('/images/home/hero.jpg') center 35%/cover}.stage-view.is-idle::before{content:'02 / 成片预览';position:absolute;left:22px;top:20px;font-size:10px;letter-spacing:1px;color:#f1e8ffbd;z-index:1}.stage-idle{position:absolute;bottom:38px;left:20px;right:20px;gap:14px;text-align:center}.stage-idle>span{width:45px;height:45px;background:#e0c4ff1a;border-color:#dfbcff70;color:#f3dbff;animation:none;backdrop-filter:blur(12px)}.stage-idle strong{font-size:20px;font-weight:500;color:#fff0ff;letter-spacing:-.5px}.stage-idle small{font-size:11px;color:#c5b0d3}.stage-idle .preview-eyebrow{font-size:9px;letter-spacing:3px;color:#c2a4d7}.preview-tags{display:flex;gap:8px;margin-top:8px}.preview-tags b{font-size:9px;font-weight:400;border:1px solid #b69ac145;border-radius:5px;padding:5px 8px;color:#d5bdde}.stage-state{color:#dfcbed}.stage-video{background:#110c18}.toast{box-shadow:0 12px 40px #0006;border-radius:10px!important;font-size:12px!important;max-width:calc(100vw - 32px)}
.back-home{position:absolute;top:28px;left:32px;color:#b5a9c7;font-size:13px}.auth{position:relative;width:430px;margin:10vh max(6vw,calc((100vw - 1100px)/2)) 0 auto;padding:42px;border:1px solid #4b3a5c;border-radius:20px;background:#1b1426e8;box-shadow:0 35px 90px #0005;backdrop-filter:blur(24px)}.auth::before{content:'CREATEAI / STUDIO';display:block;font-size:10px;letter-spacing:3px;color:#c9abeb;margin-bottom:36px}.auth h1{font-size:30px;letter-spacing:-1px}.auth-subtitle{color:#a897b6;font-size:13px;margin-top:10px}.auth input{height:48px;background:#140e1d;border-color:#493455;color:#f4eaff}.auth label{font-weight:400;color:#bfaccb;font-size:12px}.auth .btn-primary{height:48px;background:#d4b6f2;color:#291336;border:0;border-radius:9px;font-weight:650}.view-login,.view-admin-login{min-height:100vh;background:linear-gradient(90deg,#130d1b33,#140d1aaa 55%,#100c16f0),url('/images/home/hero.jpg') left 40%/cover fixed}.view-login::before,.view-admin-login::before{content:'想象之外，\a 镜头之内。';white-space:pre;position:absolute;left:max(6vw,calc((100vw - 1100px)/2));top:39vh;font-size:clamp(32px,4vw,64px);font-weight:600;letter-spacing:-2px;line-height:1.4;color:#f9ebff;text-shadow:0 3px 35px #0006}
.view-recharge .main,.view-password .main,.view-usage-history .main{background:#131017}.panel,.card{background:#1d1824;border-color:#3a2c46;border-radius:14px}.btn-primary,.btn:not(.g):not(.ghost){background:#ceb4ee;color:#241330}.btn.ghost{border:1px solid #584063;background:#251b2d;color:#d5bbdf}.btn:disabled{opacity:.4}input:focus{border-color:#c3a0e3!important}th{background:#231a2d!important;color:#bda6ce!important}td{border-color:#382c42!important}.view-admin-cards,.view-admin-password{background:#130f19}.view-admin-cards .wrap,.view-admin-password .wrap{max-width:1180px}.s-point b,.cost{font-variant-numeric:tabular-nums}
@media(min-width:1700px){.view-create .stage{padding:42px 5vw}.view-create .stage-view{min-height:650px}}
@media(max-width:1250px){.sidebar{width:160px;flex-basis:160px}.view-create .main{grid-template-columns:minmax(0,1fr)}.view-create .stage{padding:24px}.view-create .hist{grid-column:1;grid-row:2;height:auto;min-height:180px;max-height:280px;border-left:0;border-top:1px solid #33283d}.view-create .hist-l{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));overflow:auto}.view-create .main{overflow-y:auto;display:block}.view-create .stage{overflow:visible}.view-create .hist{position:static}.hist-h{margin-bottom:14px}}
@media(max-width:800px){.app{height:auto;min-height:100dvh;overflow:visible;flex-direction:column}.sidebar{width:100%;height:auto;flex:none;display:block;border-right:0;border-bottom:1px solid #3d2e48}.s-brand{padding:17px 20px;font-size:20px}.sidebar-nav{flex-direction:row;overflow:auto;padding:0 12px 12px;gap:3px}.mi{white-space:nowrap;padding:8px 12px;font-size:11px}.mi::before{display:none}.s-foot{display:none}.view-create .main{overflow:visible}.view-create .stage{padding:24px 16px}.view-create .page{display:flex;flex-direction:column;gap:16px;min-height:0}.studio-heading{padding:0 0 8px}.studio-heading h1{font-size:24px}.studio-heading p{font-size:11px}.studio-heading>a{display:none}.view-create .tabs{order:1}.studio-heading{order:0}.view-create .pwrap{order:2;min-height:320px}.view-create .prow-row{order:3}.view-create .acts{order:4}.view-create .stage-view{order:5;min-height:480px;width:100%;flex:auto;margin-top:12px}.view-create .hist{max-height:300px}.view-create .hist-l{grid-template-columns:1fr 1fr}.auth{margin:110px auto 32px;padding:32px 24px;width:410px}.view-login::before,.view-admin-login::before{display:none}.back-home{left:24px}.stage-idle strong{font-size:22px}.phint{display:inline;font-size:9px}.view-create .phead{flex-wrap:nowrap}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
.view-create .refbox:not(.has-items) .reflist{width:calc(100% - 28px);left:14px;top:14px}.view-create .refbox:not(.has-items) .radd{width:100%;height:74px;border:1px dashed #59456c;border-radius:9px;background:#251d2f;color:#c0a4d9;display:flex;align-items:center;justify-content:center;gap:14px;flex:none}.upload-label{font-size:12px;text-align:left;line-height:1.6}.upload-label small{display:block;font-size:9px;color:#8d769f;margin-top:3px}.view-create .stage-view.is-idle::before{content:'02 / 成片预览 · 当前为风格示例'}.view-create .stage-view.is-idle>div{z-index:1}
@media(max-width:800px){.view-create .hist-l{grid-template-columns:1fr}.view-create .hist{padding:20px 16px}}
@media(max-width:800px){.view-create .main{display:flex;flex-direction:column}.view-create .stage{order:0}.view-create .hist{order:1;flex:none;width:100%;height:auto;max-height:320px}.s-foot{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:0 20px 14px;margin:0}.s-foot .s-kf,.s-foot .s-me{display:none}.s-foot .s-point{margin:0;padding:0;border:0;background:none;display:flex;align-items:center;gap:10px;font-size:10px}.s-foot .s-point b{display:inline;font-size:15px;margin:0}.s-foot .btn-logout{width:auto;padding:6px 12px;font-size:10px}}

/* 提交过程给出即时反馈，避免重复点击；任务受理后恢复编辑。 */
.view-create .acts #genBtn{display:flex;align-items:center;justify-content:center;gap:8px}
.view-create .acts #genBtn[aria-busy="true"]{opacity:.85;cursor:progress}
.submit-spinner{width:14px;height:14px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:svSpin .8s linear infinite}
.view-create .page.is-submitting .pwrap,.view-create .page.is-submitting .prow-row{pointer-events:none}
