:root{--bg:#f7f7f2;--paper:#fff;--ink:#283431;--muted:#89908a;--line:#e7e9e1;--green:#214f42;--accent:#d97b57;--soft:#eff3ed}*{box-sizing:border-box}body{margin:0;font-family:Inter,"Segoe UI","Microsoft YaHei",sans-serif;background:var(--bg);color:var(--ink);font-size:14px}button,input,select,textarea{font:inherit}button,a,input,select,textarea{outline-offset:4px}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}button,a{touch-action:manipulation}button{color:inherit}a{color:inherit;text-decoration:none}[hidden]{display:none!important}.sidebar{width:218px;height:100vh;position:fixed;background:#f0f1e9;padding:38px 24px;border-right:1px solid var(--line);display:flex;flex-direction:column}.brand{display:flex;gap:11px;align-items:center;font-size:25px;letter-spacing:3px;font-weight:650}.brand-icon{background:var(--green);color:#f4f2d8;font-size:22px;letter-spacing:0;border-radius:13px;width:44px;height:49px;display:grid;place-items:center;transform:rotate(-6deg)}.brand small{display:block;font-size:8px;letter-spacing:1.8px;font-weight:500;margin-top:4px}.nav-label{font-size:11px;color:#92998e;margin:60px 12px 16px;letter-spacing:2px}.nav-item{display:flex;align-items:center;gap:12px;border:0;background:none;width:100%;font-size:13px;padding:15px 13px;text-align:left;border-radius:7px;margin-bottom:8px}.nav-item>span:first-child{font-size:18px}.nav-item.active{background:#e1e7da;color:var(--green);font-weight:600}.nav-dot{width:5px;height:5px;border-radius:50%;background:var(--green);margin-left:auto}.sidebar-bottom{margin-top:auto;font-size:11px;color:#667461}.local-dot,.status-dot{width:6px;height:6px;border-radius:50%;background:#9aa496;display:inline-block;margin-right:7px}.local-dot{background:#659071}.sidebar-bottom p{font-size:10px;color:#9a9f94;margin-top:12px}.sidebar-bottom small{display:block;font-size:9px;letter-spacing:1.3px;color:#a2a69b;margin-top:27px}.main-shell{margin-left:218px}header{height:73px;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;padding:0 45px;font-size:11px;color:#8b9289}header b{font-weight:400;margin:0 13px;color:#b9bdb4}.quiet{border:1px solid #dfe4d9;background:#fff9;padding:9px 14px;border-radius:5px;font-size:11px}main{max-width:1380px;margin:auto;padding:43px 45px 24px}.heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:31px}.eyebrow{font-size:9px;color:#84917d;letter-spacing:2px;font-weight:650}h1{font-size:29px;letter-spacing:-.8px;margin:13px 0 12px;font-weight:650}h1 span{color:var(--green)}.heading p{font-size:12px;color:var(--muted);margin:0;line-height:1.8}.edition{font-size:10px;color:#a0a596;border-left:1px solid #dfe3d8;padding-left:19px;white-space:nowrap}.edition span{display:block;font-family:Georgia,serif;font-size:34px;color:#b1bba6;margin-top:5px}.workspace{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(300px,1fr);gap:22px}.panel{background:var(--paper);border:1px solid var(--line);border-radius:10px}.editor{display:flex;flex-direction:column;padding:23px}.panel-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:23px;min-height:25px}.panel-heading h2{font-size:14px;font-weight:600;margin:0;display:flex;align-items:center;gap:10px}.step{font-size:10px;font-weight:500;color:#8e9d82;border:1px solid #e2e7dc;display:inline-grid;place-items:center;width:24px;height:24px;border-radius:50%;font-family:Georgia,serif}.text-button{border:0;background:none;font-size:11px;color:#6f846c;padding:4px 0}.dropzone{border:1.5px dashed #d4ddcc;border-radius:7px;min-height:355px;flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;background:#fafbf7;cursor:pointer;transition:.2s}.dropzone:hover,.dropzone.drag{background:#eef4e9;border-color:#76936c}.dropzone h3{font-size:14px;font-weight:500;margin:24px 0 0}.dropzone p{font-size:11px;color:#9da495;margin:12px 0 20px}.dropzone p span{color:#627a54;border-bottom:1px solid #aebd9e}.dropzone small{font-size:10px;color:#a5aa9e}.upload-art{width:120px;height:108px;position:relative;display:grid;place-items:center}.upload-art:before{content:"";width:110px;height:90px;border-radius:50%;background:#edf0e4;position:absolute;transform:rotate(-30deg)}.case-outline{position:relative;display:block;width:53px;height:91px;border:2px solid #7d9272;background:#f9fbf5;border-radius:11px;transform:rotate(-13deg);box-shadow:8px 6px 0 #dce4d1}.case-outline i{position:absolute;top:7px;left:6px;width:15px;height:21px;border:1.5px solid #90a281;border-radius:5px}.case-outline b{position:absolute;font-size:35px;font-weight:400;color:#a9b697;top:32px;left:13px}.art-spark{position:absolute;right:5px;top:4px;color:#d4a26d;font-size:24px;font-weight:300}.source-note{display:flex;gap:8px;margin-top:18px;color:#9a9f93;align-items:flex-start}.source-note span{font-size:14px}.source-note p{font-size:10px;line-height:1.8;margin:0}.controls{padding:23px;display:flex;flex-direction:column}.mode-switch{background:#f3f5ef;display:flex;border-radius:6px;padding:4px;gap:4px}.mode-switch button{flex:1;border:0;background:none;font-size:11px;padding:11px 4px;border-radius:4px;color:#8b9583;white-space:nowrap}.mode-switch button.selected{background:#fff;color:var(--green);box-shadow:0 1px 5px #283a1920;font-weight:600}.mode-description{font-size:10px;color:#969e90;line-height:1.8;margin:13px 0 20px}.toggle-line{display:flex;justify-content:space-between;align-items:center;gap:10px}.toggle-line strong{font-size:11px;font-weight:500}.toggle-line small{display:block;font-size:9px;color:#a0a697;margin-top:7px;line-height:1.5}.toggle-line input{appearance:none;flex:none;width:30px;height:17px;border-radius:20px;background:#cbd1c5;position:relative;cursor:pointer}.toggle-line input:checked{background:var(--green)}.toggle-line input:after{content:"";position:absolute;width:11px;height:11px;background:white;top:3px;left:3px;border-radius:50%;transition:.15s}.toggle-line input:checked:after{left:16px}.field{font-size:11px;display:block;margin-top:21px;font-weight:500}.field>span{color:#adb2a7;font-size:9px;margin-left:5px;font-weight:400}input:not([type=checkbox]),textarea,select{display:block;width:100%;border:1px solid #e2e6dc;border-radius:5px;background:#fff;color:var(--ink);padding:10px 11px;margin-top:10px;font-size:11px}textarea{resize:vertical;min-height:74px;line-height:1.8}textarea::placeholder,input::placeholder{color:#afb5a8}select{padding-right:22px;cursor:pointer}.divider{height:1px;background:#eef0e8;margin:21px 0 0}.format-row{display:flex;justify-content:space-between;font-size:9px;color:#9ca493;margin:15px 0 24px}.format-row b{font-weight:500;color:#737f69;margin-left:5px}.primary{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;border:0;border-radius:6px;background:var(--green);color:#fff;padding:14px 16px;font-size:12px;font-weight:500;transition:.2s}.primary:hover:not(:disabled){background:#173d32}.primary>span:last-child{margin-left:auto}.primary>span:first-child{font-size:16px}.privacy{text-align:center;font-size:9px;color:#a5ad9b;margin:12px 0 0;line-height:1.7}.result{margin-top:22px;padding:21px 23px}.result .panel-heading{margin-bottom:16px}.badge{font-size:9px;color:#96a18b;background:#f2f5ee;border:1px solid #e8eddf;padding:5px 9px;border-radius:4px}.result-empty{min-height:95px;display:flex;align-items:center;justify-content:center;gap:15px;background:#fafbf8;border:1px solid #f0f2e9;border-radius:6px}.result-empty>span{font-size:30px;color:#c8d1be}.result-empty strong{font-size:11px;font-weight:500;color:#98a38d}.result-empty p{font-size:10px;color:#b2b9aa;margin:8px 0 0}.bottom-note{font-size:9px;color:#9ea694;display:flex;align-items:center;gap:8px;margin-top:20px;line-height:1.8}.bottom-note>span:first-child{font-size:15px;color:#8e9e81}.bottom-brand{margin-left:auto;font-size:8px;letter-spacing:1px;color:#b6bdaa;white-space:nowrap}.image-editor{flex:1;min-width:0}.canvas-area{height:355px;display:flex;align-items:center;justify-content:center;background:#f2f3ee;border-radius:6px;padding:12px;overflow:hidden}canvas{display:block;max-width:100%;max-height:100%;touch-action:none}.image-footer{display:flex;justify-content:space-between;align-items:center;font-size:10px;color:#929e88;margin-top:10px;gap:10px}.image-footer>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.manual-guide{font-size:11px;background:#f5f7f0;border-radius:6px;padding:16px;line-height:1.8}.manual-guide strong{font-weight:500}.manual-guide p{color:#8d9c81}.manual-guide small{display:block;font-size:9px;color:#9ba78e;margin-top:13px}.dimensions{display:flex;align-items:end;gap:10px;margin-top:12px}.dimensions label{flex:1;font-size:10px;color:#9aa28f;min-width:0}.dimensions>span{padding-bottom:10px}.dimensions input{margin-top:7px}.result-content{display:grid;grid-template-columns:1fr 1fr;gap:28px;align-items:center}.result-preview{height:340px;padding:15px;background-color:#f7f8f3;background-image:linear-gradient(45deg,#edf0e7 25%,transparent 25%),linear-gradient(-45deg,#edf0e7 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#edf0e7 75%),linear-gradient(-45deg,transparent 75%,#edf0e7 75%);background-size:20px 20px;background-position:0 0,0 10px,10px -10px,-10px 0;border-radius:6px;text-align:center}.result-preview img{max-width:100%;max-height:100%;box-shadow:0 4px 20px #283a1915}.result-details{padding:10px 15px 10px 0}.result-details h3{font-size:22px;font-weight:500;margin:18px 0}.result-details p{font-size:11px;line-height:1.9;color:#8b9780}.result-details .primary{width:max-content;margin-top:25px;padding:13px 23px}dialog{border:1px solid var(--line);border-radius:12px;padding:30px;max-width:560px;width:calc(100% - 32px);color:var(--ink);max-height:92vh;overflow:auto;box-shadow:0 20px 100px #1d322635}dialog::backdrop{background:#263b3360;backdrop-filter:none}.dialog-title{display:flex;justify-content:space-between;align-items:start}.dialog-title h2{font-size:23px;margin:12px 0 0;font-weight:550}.close{border:0;background:#f2f4ed;border-radius:50%;width:29px;height:29px;font-size:22px;line-height:1}.dialog-intro{font-size:11px;line-height:1.9;color:#8d9882;margin-top:19px}.field small{display:block;font-size:10px;font-weight:400;line-height:1.8;color:#99a48d;margin-top:7px}.settings-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.settings-note{font-size:10px;line-height:1.8;color:#9aa48f;background:#f5f7f0;padding:12px;margin:22px 0}#toast{position:fixed;bottom:26px;left:50%;transform:translateX(-50%);background:#263e34;color:#fff;padding:14px 22px;border-radius:7px;box-shadow:0 5px 25px #0002;font-size:12px;max-width:min(600px,90vw);line-height:1.8;z-index:20}#toast.error{background:#864d3c}.busy{position:relative}.busy:before{content:"";display:inline-block;width:12px;height:12px;border:2px solid #ffffff60;border-top-color:#fff;border-radius:50%;animation:spin .8s linear infinite;margin-right:8px}@keyframes spin{to{transform:rotate(360deg)}}@media(min-width:1550px){main{padding-top:55px}.dropzone,.canvas-area{min-height:415px}.canvas-area{height:415px}}@media(max-width:1100px){.sidebar{width:176px;padding:32px 18px}.main-shell{margin-left:176px}header{padding:0 26px}main{padding:32px 26px}.workspace{gap:16px;grid-template-columns:minmax(0,1.15fr) minmax(285px,1fr)}h1{font-size:24px}.editor,.controls{padding:18px}.edition{display:none}.bottom-brand{display:none}}@media(max-width:800px){.sidebar{display:none}.main-shell{margin-left:0}header{height:60px;padding:0 20px}main{padding:27px 20px}.heading{margin-bottom:24px}h1{font-size:25px;line-height:1.5}.heading p{font-size:11px;max-width:360px}.workspace{grid-template-columns:1fr}.dropzone{min-height:300px}.canvas-area{height:370px}.controls{padding:22px}.mode-switch button{font-size:12px}.field,.toggle-line strong{font-size:12px}.toggle-line small,.mode-description,.privacy{font-size:11px}.result-content{grid-template-columns:1fr}.result-details{padding:5px 0}.result-details h3{font-size:20px}.result-details .primary{width:100%}.result-empty{padding:20px}.result-empty p{line-height:1.8}.bottom-note{align-items:flex-start}.result-preview{height:380px}.settings-grid{grid-template-columns:1fr;gap:0}}
.secondary{display:block;width:100%;margin-top:10px;border:1px solid #d5dfce;background:#f4f7ef;color:#31513d;border-radius:6px;padding:11px;font-size:11px}.controls .field>small{display:block;font-weight:400;color:#97a28b;font-size:10px;line-height:1.7;margin-top:8px}.controls .primary{margin-top:12px}.batch-progress{margin-top:18px;font-size:10px;color:#819075}.batch-progress progress{display:block;width:100%;height:6px;margin-top:10px;accent-color:#214f42}.queue-toolbar{display:flex;justify-content:space-between;align-items:center;margin:18px 0 9px;font-size:11px}.queue-toolbar strong{font-weight:500}.queue-list{max-height:260px;overflow:auto;display:flex;flex-direction:column;gap:5px}.queue-row{display:flex;align-items:center;border:1px solid #e7eddf;border-radius:6px;min-width:0}.queue-row.selected{background:#edf3e5;border-color:#b7c7a9}.queue-select{display:flex;align-items:center;gap:10px;text-align:left;min-width:0;flex:1;border:0;background:none;padding:7px;cursor:pointer}.queue-select img{width:36px;height:46px;object-fit:contain;border-radius:4px;background:#e7ebe1}.queue-select span{min-width:0}.queue-select strong{display:block;font-size:11px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.queue-select small{display:block;font-size:9px;margin-top:5px;color:#8d9b80}.remove-item{background:none;border:0;color:#8a947f;font-size:19px;padding:9px}.status-download_failed,.status-error{color:#a05a37!important}.status-done{color:#557d4a!important}.batch-results{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:15px;margin-top:20px}.batch-results:empty{display:none}.result-card{border:1px solid #e1e8d9;border-radius:7px;padding:12px;min-width:0}.result-card-preview{height:155px;width:100%;background:#f2f5ed;border:0;border-radius:4px;cursor:pointer}.result-card-preview img{max-width:100%;height:100%;object-fit:contain}.result-card>strong{display:block;font-size:11px;font-weight:500;margin:10px 0 7px;overflow-wrap:anywhere}.result-card>small{font-size:10px;color:#8a9a7d}.card-error{font-size:10px;line-height:1.8;color:#a0704f;overflow-wrap:anywhere;max-height:100px;overflow:auto}.card-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:10px}.result-actions{display:flex;align-items:center;gap:13px;flex-wrap:wrap}.download-problem{padding:20px;background:#fbf4e9;border:1px solid #ead6b6;border-radius:6px;line-height:1.9;font-size:12px;color:#876241}.download-problem .secondary{width:auto;margin-bottom:12px}.history-list{margin-top:20px}.history-row{border:1px solid #e4eadc;border-radius:6px;padding:13px;margin-top:10px}.history-row>strong{display:block;font-size:12px;font-weight:500}.history-row>small{display:block;font-size:10px;color:#8a997c;margin:8px 0}.history-row .text-button{margin-right:20px}#recoverLinkForm{padding:0 0 20px;border-bottom:1px solid #e3eadc}#recoverLinkForm>small{font-size:10px;color:#92a084;display:block;margin-top:10px}@media(max-width:800px){.result .panel-heading{gap:15px;align-items:flex-start;flex-wrap:wrap}.result-actions{gap:10px}.batch-results{grid-template-columns:repeat(2,minmax(0,1fr))}.queue-select strong{max-width:230px}.result-card{padding:9px}.card-actions{gap:4px}.card-actions .text-button{font-size:10px}.result-card-preview{height:130px}}

html{scrollbar-gutter:stable}dialog{overscroll-behavior:contain}dialog::backdrop{background:rgba(38,59,51,.55);backdrop-filter:none}#history{max-width:1080px;width:calc(100% - 40px)}.history-toolbar{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin:20px 0}.history-toolbar button.active{background:#214f42;color:white}.history-storage{font-size:11px;color:#728369;line-height:1.8;overflow-wrap:anywhere;padding:12px;background:#f2f5ed;border-radius:6px}.history-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:14px}.history-card{border:1px solid #e1e8d9;border-radius:7px;padding:12px;min-width:0}.history-card img{width:100%;height:180px;object-fit:contain;background:#f4f6ef;border-radius:4px;cursor:pointer}.history-card strong{display:block;font-size:12px;margin:10px 0;overflow-wrap:anywhere}.history-card small{display:block;font-size:10px;color:#7e8c73;line-height:1.8}.history-card .card-actions{margin-bottom:8px}.history-path{font-size:10px;overflow-wrap:anywhere;color:#98a38c;max-height:55px;overflow:auto}.history-preview{background:#f2f4ed;border-radius:6px;padding:10px;text-align:center;margin-bottom:20px}.history-preview img{max-width:100%;max-height:65vh}.history-preview p{font-size:11px;overflow-wrap:anywhere}.retry-summary{font-size:11px;color:#947449;line-height:1.8}#historyMore{margin:20px auto;max-width:260px}.history-heading-actions{display:flex;gap:14px;align-items:center}@media(max-width:650px){.history-grid{grid-template-columns:1fr 1fr}.history-card{padding:8px}.history-card img{height:140px}#history{padding:18px;width:calc(100% - 20px)}}

:root{--bg:#f7f8fa;--paper:#fff;--ink:#25352f;--muted:#737e87;--line:#dfe5e8;--green:#24634e;--accent:#477aa7;--soft:#edf3f5}
h1,.brand,.brand small,.nav-label,.eyebrow,.sidebar-bottom small,.bottom-brand{letter-spacing:0}
.sidebar{background:#f0f3f5}
.brand-icon{border-radius:8px;transform:none;color:#fff}
.nav-item.active{background:#dfece6}
main{padding-top:24px}
.heading{margin-bottom:20px}
h1{font-size:23px;margin:9px 0}
.edition span{font-size:25px;color:#477aa7}
.workspace{gap:0;border-top:1px solid var(--line);border-bottom:1px solid var(--line);background:#fff}
.panel{border:0;border-radius:0}
.editor{border-right:1px solid var(--line);min-width:0}
.controls{min-width:0}
.result{border-top:1px solid var(--line);padding:22px 0;background:transparent}
.dropzone{background:#f8fafb;border-color:#c6d2da}
.dropzone small{text-align:center;line-height:1.8;padding:0 12px}
.dropzone h3{color:#354d5d}
.dropzone:hover,.dropzone.drag{background:#eef5f6;border-color:#73999c}
.canvas-area{background:#f2f5f7}
.mode-switch{background:#edf2f4}
.mode-switch button{white-space:normal;min-height:42px;line-height:1.5}
.field{font-size:12px;margin-top:17px}
.field textarea{font-size:12px;line-height:1.8}
#referencePrompt{min-height:134px}
#resetPrompt{display:block;margin:5px 0 0 auto;font-size:19px;width:28px;height:28px;padding:0}
.result-empty{background:transparent;border:0}
.result-preview{height:auto;min-height:340px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;background:#eef2f4}
.result-preview figure{margin:0;min-width:0;display:flex;flex-direction:column;align-items:center;gap:8px}
.result-preview figcaption{font-size:11px;color:#586d7b}
.result-preview img{width:100%;height:300px;object-fit:contain;box-shadow:none}
.result-preview.single{grid-template-columns:1fr}
.result-details h3{font-size:17px;overflow-wrap:anywhere}
dialog{border-radius:8px}
.queue-row.selected{background:#eaf3f0;border-color:#acc8bd}
.batch-progress{color:#5f7381}
.result-actions{min-width:0}
.result-actions .quiet{white-space:normal}
.generated-prompt{white-space:pre-wrap;overflow-wrap:anywhere;font-size:12px;line-height:1.7;max-height:240px;overflow:auto}
.prompt-details{min-width:0}
#settings h3{font-size:14px;margin:24px 0 0}
.prompt-config-line{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:18px;font-size:12px}
.prompt-config-line strong{font-weight:500}
.prompt-config-line button{width:32px;height:32px;font-size:18px;flex:none}
@media(max-width:800px){.editor{border-right:0;border-bottom:1px solid var(--line)}main{padding:20px 16px}.controls{padding:20px}.heading h1{font-size:22px}.result-preview img{height:260px}.result-preview{min-height:290px}.bottom-note{font-size:10px}}
@media(max-width:400px){header{padding:0 12px;gap:8px}header b{margin:0 6px}.mode-switch button{font-size:11px}.editor,.controls{padding:16px}.queue-select strong{max-width:170px}.result-preview{gap:8px;padding:8px}.result-preview img{height:220px}}
#extractionOptions{margin-top:16px}.corner-controls{display:flex;align-items:center;gap:10px;margin-bottom:14px}.corner-controls label{flex:1;min-width:0}#resetExtractionCorners{width:28px;height:28px;flex:none;font-size:19px;padding:0}.corner-controls strong{overflow-wrap:anywhere}
.image-footer .text-button{flex:none;white-space:nowrap}
#transparentOption{margin-top:18px;align-items:flex-start}#transparentOption small{max-width:290px}
.result-preview img,.result-card-preview img,.history-card>img,.history-preview img{background-color:#fff;background-image:conic-gradient(#e7e9e5 25%,transparent 0 50%,#e7e9e5 0 75%,transparent 0);background-size:16px 16px}

