:root,:root[data-theme=dark]{color-scheme:dark;--bg:#0e0d0b;--surface:#17150f;--surface-2:#211e16;--border:#2c281e;--border-strong:#4a4332;--track:#2c281e;--text:#f4efe3;--muted:#a9a08c;--accent:#d9b44a;--on-accent:#1a1405;--accent-ink:#e2c268;--accent-soft:rgba(217,180,74,0.14);--accent-2:#c2643a;--ok:#6ee7b7;--ok-bg:rgba(52,211,153,0.14);--warn:#fcd38a;--warn-bg:rgba(245,165,36,0.15);--err:#fca5a5;--err-bg:rgba(248,113,113,0.1);--err-border:rgba(248,113,113,0.35);--focus:rgba(217,180,74,0.35);--shadow:0 12px 32px rgba(0,0,0,0.45);--topbar-bg:rgba(23,21,15,0.88)}:root[data-theme=light]{color-scheme:light;--bg:#faf7f0;--surface:#ffffff;--surface-2:#f4efe3;--border:#e6decb;--border-strong:#cfc3a6;--track:#ede5d2;--text:#1f1b14;--muted:#655d4e;--accent:#d9b44a;--on-accent:#1a1405;--accent-ink:#7e5c0c;--accent-soft:rgba(185,140,30,0.14);--accent-2:#a4512b;--ok:#146c43;--ok-bg:#e5f5ec;--warn:#7f4c00;--warn-bg:#fcf1dc;--err:#a3191b;--err-bg:#fdeeee;--err-border:#f0b8b8;--focus:rgba(126,92,12,0.3);--shadow:0 12px 32px rgba(60,45,10,0.12);--topbar-bg:rgba(255,255,255,0.9)}:root{--radius:12px;--radius-sm:10px;--font-display:"Playfair Display",Georgia,serif;--font-body:"Inter",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;--topbar-h:64px}*{box-sizing:border-box;margin:0;padding:0}body,html{min-height:100%}body{font-family:var(--font-body);background:var(--bg);color:var(--text);font-size:15px;line-height:1.55;-webkit-font-smoothing:antialiased}a{color:var(--accent-ink);text-decoration:none}img,video{max-width:100%;display:block}svg{flex-shrink:0}:focus-visible{outline:3px solid var(--focus);outline-offset:2px}h1,h2{font-family:var(--font-display);font-weight:700;line-height:1.2}h1{font-size:1.6rem}h2{font-size:1.25rem;margin-bottom:12px}h3{font-size:1rem;font-weight:700;margin-bottom:8px}@media (min-width:720px){h1{font-size:1.85rem}h2{font-size:1.4rem}}.container{width:100%;max-width:1080px;margin:0 auto;padding:16px}@media (min-width:720px){.container{padding:28px}}.muted{color:var(--muted);font-size:.88rem}.small{font-size:.82rem}.row{gap:10px;flex-wrap:wrap;align-items:center}.row,.stack{display:flex}.stack{flex-direction:column;gap:12px}.grid{display:grid;grid-gap:12px;gap:12px;grid-template-columns:minmax(0,1fr)}.spacer{flex:1 1}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}@media (min-width:720px){.grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}}.eyebrow{font-size:.72rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--muted)}.card{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:16px;margin-bottom:16px}@media (min-width:720px){.card{padding:20px}}.card.flat{margin-bottom:0}label.field{display:flex;flex-direction:column;gap:6px;font-size:.85rem;font-weight:600;color:var(--muted)}label.field .hint{font-weight:400;font-size:.8rem}input,select,textarea{width:100%;font:inherit;font-size:16px;background:var(--surface);color:var(--text);border:1px solid var(--border-strong);border-radius:var(--radius-sm);padding:10px 12px;min-height:44px;outline:none;transition:border-color .15s,box-shadow .15s}input:focus,select:focus,textarea:focus{border-color:var(--accent);box-shadow:0 0 0 3px var(--focus)}textarea{resize:vertical;min-height:96px;line-height:1.55}textarea.small{min-height:72px;font-size:14px}input.title-input{font-family:var(--font-display);font-size:1.2rem;font-weight:700}.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;font:inherit;font-weight:600;font-size:.9rem;cursor:pointer;min-height:44px;padding:10px 16px;border-radius:var(--radius-sm);background:transparent;color:var(--text);border:1px solid var(--border-strong);transition:background .15s,border-color .15s,transform .1s;white-space:nowrap}.btn:hover:not(:disabled){background:var(--surface-2)}.btn:active:not(:disabled){transform:scale(.98)}.btn:disabled{opacity:.5;cursor:not-allowed}.btn.primary{background:var(--accent);color:var(--on-accent);border-color:var(--accent)}.btn.primary:hover:not(:disabled){background:var(--accent);filter:brightness(1.06)}.btn.soft{background:var(--accent-soft);color:var(--accent-ink);border-color:transparent}.btn.soft:hover:not(:disabled){background:var(--accent-soft);filter:brightness(1.1)}.btn.ghost{border-color:transparent;color:var(--muted)}.btn.danger{color:var(--err);border-color:var(--err-border)}.btn.danger:hover:not(:disabled){background:var(--err-bg)}.btn.sm{min-height:36px;padding:6px 12px;font-size:.84rem}.btn.block{width:100%}.icon-btn{width:44px;min-height:44px;padding:0}.icon-btn.sm{width:36px;min-height:36px}.spinner{width:16px;height:16px;border-radius:50%;border:2px solid;border-right:2px solid transparent;animation:spin .8s linear infinite;display:inline-block;flex-shrink:0}@keyframes spin{to{transform:rotate(1turn)}}@media (prefers-reduced-motion:reduce){.spinner{animation-duration:2s}}.pill{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:999px;font-size:.78rem;font-weight:600;white-space:nowrap;background:var(--surface-2);color:var(--muted)}.pill.ok{background:var(--ok-bg);color:var(--ok)}.pill.warn{background:var(--warn-bg);color:var(--warn)}.pill.err{background:var(--err-bg);color:var(--err)}.pill.accent{background:var(--accent-soft);color:var(--accent-ink)}.chip{display:inline-flex;align-items:center;gap:5px;padding:3px 9px;border-radius:999px;font-size:.78rem;background:var(--surface-2);color:var(--muted)}.tag-babak{padding:3px 8px;border-radius:6px;font-size:.7rem;font-weight:700;letter-spacing:.06em;background:var(--accent-soft);color:var(--accent-ink)}.topbar{position:-webkit-sticky;position:sticky;top:0;z-index:40;display:flex;gap:12px;min-height:var(--topbar-h);padding:max(8px,env(safe-area-inset-top)) 16px 8px;background:var(--topbar-bg);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);border-bottom:1px solid var(--border)}.brand,.topbar{align-items:center}.brand{display:inline-flex;gap:10px;color:var(--text)}.brand-word{font-family:var(--font-display);font-weight:700;font-size:1.05rem;letter-spacing:.04em;white-space:nowrap}.topbar-title{min-width:0;display:none;flex-direction:column;padding-left:14px;border-left:1px solid var(--border)}.topbar-title b{font-size:.95rem}.topbar-title b,.topbar-title span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.topbar-title span{font-size:.78rem;color:var(--muted)}.topbar-actions{margin-left:auto;display:flex;gap:8px;align-items:center}.hide-mobile{display:none}@media (min-width:720px){.topbar{padding-left:24px;padding-right:24px}.topbar-title{display:flex}.hide-mobile{display:inline-flex}}@media (max-width:719px){.hide-desktop-only{display:inline-flex}}.editor{width:100%;max-width:1320px;margin:0 auto}.sidenav{display:none}.stepchips{position:-webkit-sticky;position:sticky;top:var(--topbar-h);z-index:30;display:flex;gap:8px;overflow-x:auto;padding:10px 16px;background:var(--surface);border-bottom:1px solid var(--border);scrollbar-width:none;-webkit-overflow-scrolling:touch}.stepchips::-webkit-scrollbar{display:none}.stepchip{flex:0 0 auto;display:inline-flex;align-items:center;gap:6px;min-height:36px;padding:6px 12px;border-radius:999px;font:inherit;font-size:.84rem;font-weight:600;cursor:pointer;background:var(--surface-2);color:var(--text);border:1px solid transparent}.stepchip.done{background:var(--ok-bg);color:var(--ok)}.stepchip.active{background:var(--accent);color:var(--on-accent)}.stepchip.locked{color:var(--muted);opacity:.75}.editor-main{min-width:0;padding:16px 16px 120px}@media (min-width:960px){.editor{display:grid;grid-template-columns:260px minmax(0,1fr);grid-gap:0;gap:0}.stepchips{display:none}.sidenav{display:flex;flex-direction:column;gap:4px;position:-webkit-sticky;position:sticky;top:var(--topbar-h);align-self:start;height:calc(100vh - var(--topbar-h));padding:24px 16px;border-right:1px solid var(--border);background:var(--surface)}.editor-main{padding:28px 32px 48px}}.navitem{display:flex;align-items:center;gap:12px;width:100%;padding:10px;min-height:52px;border-radius:var(--radius);font:inherit;font-size:.92rem;font-weight:600;text-align:left;cursor:pointer;background:transparent;border:none;color:var(--text)}.navitem:hover{background:var(--surface-2)}.navitem.active{background:var(--accent-soft)}.navitem .sub,.navitem.locked{color:var(--muted)}.navitem .sub{display:block;font-size:.78rem;font-weight:400}.navitem.active .sub{color:var(--accent-ink)}.badge{width:28px;height:28px;border-radius:999px;flex-shrink:0;display:grid;place-items:center;font-size:.8rem;font-weight:700;background:var(--surface-2);color:var(--muted)}.navitem.done .badge{background:var(--ok-bg);color:var(--ok)}.navitem.active .badge{background:var(--accent);color:var(--on-accent)}.nav-progress{margin-top:auto;padding:14px;border-radius:var(--radius);background:var(--surface-2);display:flex;flex-direction:column;gap:8px;font-size:.82rem}.step-head{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px 16px;margin-bottom:18px}.step-head .titles{flex:1 1 320px;display:flex;flex-direction:column;gap:4px}.step-actions{display:flex;gap:10px}@media (max-width:959px){.step-actions{position:fixed;left:0;right:0;bottom:0;z-index:35;padding:12px 16px calc(14px + env(safe-area-inset-bottom));background:var(--surface);border-top:1px solid var(--border);box-shadow:0 -8px 24px rgba(0,0,0,.12)}.step-actions .btn{flex:1 1}.step-actions .btn.primary{flex:2 1}}.progress{height:8px;border-radius:999px;background:var(--track);overflow:hidden}.progress>div{height:100%;border-radius:999px;background:var(--accent);transition:width .4s}.progress.indeterminate>div{width:35%;animation:slide 1.4s ease-in-out infinite}@keyframes slide{0%{transform:translateX(-100%)}to{transform:translateX(300%)}}@media (prefers-reduced-motion:reduce){.progress.indeterminate>div{animation:none;width:100%;opacity:.5}}.task-card{display:flex;flex-direction:column;gap:10px}.task-card .head{align-items:center;gap:10px}.alert,.task-card .head{display:flex;flex-wrap:wrap}.alert{gap:12px;align-items:flex-start;padding:14px 16px;margin-bottom:16px;border-radius:var(--radius);border:1px solid var(--border);background:var(--surface)}.alert .body{flex:1 1 260px;display:flex;flex-direction:column;gap:2px;min-width:0}.alert .body b{font-size:.92rem}.alert .body span{font-size:.88rem;overflow-wrap:anywhere}.alert .actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.alert.err{background:var(--err-bg);border-color:var(--err-border)}.alert.err .body b{color:var(--err)}.alert.ok{background:var(--ok-bg);border-color:transparent}.alert.ok .body b{color:var(--ok)}.alert.lock{background:var(--surface-2);border-color:transparent}.scene-card{display:flex;gap:14px}.scene-thumb{width:84px;aspect-ratio:9/16;flex-shrink:0;border-radius:var(--radius-sm);background:var(--surface-2);color:var(--muted);overflow:hidden;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;font-size:.72rem;font-weight:600;text-align:center;padding:4px}.scene-thumb.r16x9{aspect-ratio:16/9;width:120px}.scene-thumb.r1x1{aspect-ratio:1/1;width:96px}.scene-thumb img,.scene-thumb video{width:100%;height:100%;object-fit:cover}@media (min-width:720px){.scene-thumb{width:104px}}.scene-body{flex:1 1;min-width:0;display:flex;flex-direction:column;gap:8px}.scene-body .top{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.dialogue{padding:8px 10px;border-radius:8px;background:var(--surface-2);font-size:.88rem;display:flex;flex-direction:column;gap:2px}.dialogue b{color:var(--accent-ink)}details.more>summary{list-style:none;cursor:pointer;display:inline-flex;align-items:center;gap:6px;min-height:36px;padding:6px 12px;border-radius:var(--radius-sm);border:1px solid var(--border);font-size:.84rem;font-weight:600}details.more>summary::-webkit-details-marker{display:none}details.more[open]>summary{background:var(--surface-2)}details.more>.inner{margin-top:10px;display:flex;flex-direction:column;gap:12px}.media{position:relative;width:100%;border-radius:var(--radius-sm);overflow:hidden;background:var(--surface-2);border:1px solid var(--border);display:flex;align-items:center;justify-content:center;color:var(--muted);font-size:.82rem}.media.r9x16{aspect-ratio:9/16;max-height:420px}.media.r16x9{aspect-ratio:16/9}.media.r1x1{aspect-ratio:1/1}.media img,.media video{width:100%;height:100%;object-fit:cover}.stat{padding:16px;border-radius:var(--radius);background:var(--surface-2)}.stat b{display:block;font-family:var(--font-display);font-size:1.8rem;color:var(--accent-ink);line-height:1.1}.stat span{font-size:.8rem;color:var(--muted)}.switch{position:relative;width:46px;height:26px;flex:0 0 auto}.switch input{position:absolute;opacity:0;width:100%;height:100%;margin:0;cursor:pointer;min-height:0}.switch span{position:absolute;inset:0;background:var(--border-strong);border-radius:99px;transition:.2s;pointer-events:none}.switch span:before{content:"";position:absolute;width:20px;height:20px;left:3px;top:3px;background:#fff;border-radius:50%;transition:.2s}.switch input:checked+span{background:var(--accent)}.switch input:checked+span:before{transform:translateX(20px)}.switch input:focus-visible+span{outline:3px solid var(--focus);outline-offset:2px}.toast{position:fixed;left:50%;transform:translateX(-50%);z-index:100;bottom:calc(96px + env(safe-area-inset-bottom));max-width:min(92vw,520px);padding:12px 14px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--border-strong);box-shadow:var(--shadow);font-size:.9rem;display:flex;align-items:center;gap:10px}.toast.error{border-color:var(--err-border);color:var(--err)}@media (min-width:960px){.toast{bottom:24px}}.auth-wrap{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:20px}.auth-card{width:100%;max-width:400px}.project-item{display:flex;gap:14px;align-items:center;width:100%;text-align:left;font:inherit;color:inherit;cursor:pointer}.project-item:hover{border-color:var(--border-strong)}.project-thumb{width:54px;aspect-ratio:9/16;border-radius:8px;background:var(--surface-2);object-fit:cover;flex:0 0 auto;display:grid;place-items:center}.empty{text-align:center;padding:40px 16px;color:var(--muted)}.divider{height:1px;background:var(--border);margin:14px 0}.status{font-size:.8rem;padding:4px 10px;border-radius:8px;display:inline-flex;gap:6px;align-items:center}.status.PROCESSING,.status.QUEUED{background:var(--warn-bg);color:var(--warn)}.status.FAILED{background:var(--err-bg);color:var(--err)}.status.SUCCEEDED{background:var(--ok-bg);color:var(--ok)}.prompt-preview{margin:0;max-height:280px;overflow:auto;padding:12px;border-radius:var(--radius-sm);background:var(--surface-2);border:1px solid var(--border);font:12.5px/1.55 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;white-space:pre-wrap;overflow-wrap:anywhere;color:var(--text)}.asset-card{display:flex;flex-direction:column;gap:10px}.asset-head{display:flex;gap:14px;align-items:flex-start}.asset-thumb{width:76px;height:76px;flex-shrink:0;overflow:hidden;border-radius:var(--radius-sm);background:var(--surface-2);color:var(--muted);display:grid;place-items:center}.asset-thumb a,.asset-thumb img{display:block;width:100%;height:100%;object-fit:cover}.asset-title{flex:1 1;min-width:0;display:flex;flex-direction:column;gap:6px}.asset-foot{display:flex;align-items:center;gap:8px;padding-top:10px;border-top:1px solid var(--border)}.inline-input{background:transparent;border-color:transparent;padding:6px 8px;margin-left:-8px;width:calc(100% + 8px);min-height:36px}.inline-input:hover{background:var(--surface-2)}.inline-input:focus{background:var(--surface);border-color:var(--accent)}input.inline-input.name{font-weight:700;font-size:1.05rem}textarea.inline-input{resize:none;min-height:0;font-size:.92rem;line-height:1.5;color:var(--muted);field-sizing:content;max-height:11em}textarea.inline-input:focus{color:var(--text)}details.disclosure{border-top:1px solid var(--border)}details.disclosure>summary{list-style:none;cursor:pointer;display:flex;align-items:center;gap:8px;min-height:44px;font-size:.88rem;font-weight:600}details.disclosure>summary>span:first-child{flex:1 1}details.disclosure>summary::-webkit-details-marker{display:none}details.disclosure>summary svg{transition:transform .15s;color:var(--muted)}details.disclosure[open]>summary svg{transform:rotate(180deg)}details.disclosure>.inner{display:flex;flex-direction:column;gap:12px;padding-bottom:6px}.asset-media{position:relative;display:flex;justify-content:center;margin:-4px -4px 2px;border-radius:var(--radius-sm);overflow:hidden;background:var(--surface-2)}.asset-media button{display:block;padding:0;border:0;background:none;cursor:zoom-in}.asset-media img{display:block;object-fit:cover}.asset-media.r9x16 img{height:320px;aspect-ratio:9/16}.asset-media.r1x1 img{height:280px;aspect-ratio:1/1}.asset-media.r16x9 button,.asset-media.r16x9 img{width:100%;aspect-ratio:16/9}.asset-media .media-status{position:absolute;left:10px;bottom:10px}dialog.viewer{border:0;padding:0;margin:auto;background:transparent;color:var(--text);max-width:min(96vw,1200px);max-height:96vh;overflow:visible}dialog.viewer::-webkit-backdrop{background:rgba(0,0,0,.82)}dialog.viewer::backdrop{background:rgba(0,0,0,.82)}.viewer-bar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 12px;margin-bottom:8px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--border)}dialog.viewer img{display:block;margin:0 auto;max-width:100%;max-height:calc(96vh - 80px);object-fit:contain;border-radius:var(--radius-sm)}