:root{color-scheme:light;--paper:#f5f4ef;--white:#fff;--ink:#262921;--muted:#6f7268;--line:#dedfd7;--soft:#eeeee7;--accent:#526449;--danger:#983e31;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:14px;line-height:1.5;background:var(--paper);color:var(--ink)}
*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button,a,input,select{-webkit-tap-highlight-color:transparent}button{cursor:pointer}button:disabled,input:disabled,select:disabled{cursor:not-allowed;opacity:.55}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid var(--accent);outline-offset:3px}button{border:0}a{color:inherit}h1,h2,h3,p{margin:0}h2{font-size:16px;font-weight:600;letter-spacing:-.025em}h3{font-size:19px;font-weight:500;letter-spacing:-.03em}img{display:block;max-width:100%}[hidden]{display:none!important}.page{max-width:1336px;padding:0 48px;margin:auto}.masthead{display:flex;align-items:center;gap:22px;height:100px;border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:8px;font-family:Georgia,"Times New Roman",serif;font-size:33px;text-decoration:none;letter-spacing:-1.7px}.brand-dot{width:7px;height:7px;background:var(--accent);border-radius:50%;margin:9px 0 0}.masthead-label{font-size:11px;letter-spacing:.09em;text-transform:uppercase;color:var(--muted);border-left:1px solid var(--line);padding-left:22px}.masthead>.text-button{margin-left:auto;font-size:12px}.intro{display:flex;align-items:flex-end;justify-content:space-between;gap:40px;padding:45px 0 37px}.eyebrow{font-size:10px;letter-spacing:.16em;text-transform:uppercase;color:var(--muted);margin-bottom:13px}h1{font-size:42px;line-height:1.15;font-weight:450;letter-spacing:-1.9px}h1 em{font-family:Georgia,"Times New Roman",serif;font-weight:400}.intro-note{max-width:250px;font-size:12px;line-height:1.7;color:var(--muted)}.mono{font-family:ui-monospace,SFMono-Regular,Menlo,monospace}.workspace{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);align-items:start;gap:24px}.setup{display:grid;gap:20px}.panel{background:var(--white);border:1px solid var(--line);border-radius:12px;padding:25px 27px}.section-heading,.section-title{display:flex;align-items:center;gap:10px}.section-heading{justify-content:space-between;margin-bottom:19px}.step{width:25px;height:25px;border:1px solid var(--line);border-radius:50%;display:inline-flex;align-items:center;justify-content:center;font-size:10px;color:var(--muted);flex-shrink:0}.badge{border:1px solid var(--line);border-radius:20px;padding:3px 9px;font-size:10px;white-space:nowrap}.badge.connected{background:#eef4e9;border-color:#d5e2cd;color:#3b5530}.badge.error{color:var(--danger);border-color:#e7c4bb}.section-note{font-size:12px;color:var(--muted);line-height:1.65;margin:-5px 0 18px}label{font-size:12px;font-weight:500;display:block;margin-bottom:7px}input[type=text],input[type=password],select{width:100%;min-width:0;border:1px solid var(--line);border-radius:6px;padding:10px 11px;background:#fff;color:var(--ink);min-height:42px}input::placeholder{color:#92958c}select{padding-right:22px}.key-field{position:relative}.key-field input{padding-right:67px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace}.key-field button{position:absolute;right:11px;top:12px;font-size:11px}.connection-actions{display:flex;align-items:center;gap:8px;margin-top:10px}.connection-actions .hint{margin-right:auto;max-width:200px}.text-button{background:none;color:var(--muted);padding:0;text-decoration:underline;text-underline-offset:4px;text-decoration-color:#c1c4b9}.text-button:hover{color:var(--ink)}.small-button{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;padding:8px 12px;min-height:35px;background:var(--white);border:1px solid var(--line);border-radius:6px;color:var(--ink);font-size:11px;font-weight:500}.small-button:hover{background:var(--soft)}.dark{background:var(--ink);border-color:var(--ink);color:var(--white)}.dark:hover{background:#40463a}.hint{font-size:11px;font-weight:400;line-height:1.6;color:var(--muted);margin-top:6px}.connection-actions .hint{margin-top:0}.status{font-size:12px;color:var(--muted);line-height:1.65;margin-top:13px;overflow-wrap:anywhere}.status.error{color:var(--danger)}.status.success{color:var(--accent)}.notice{padding:14px 18px;border:1px solid #dcd6b9;background:#f8f6e9;color:#675e37;border-radius:8px;margin-bottom:20px;font-size:12px}.people-list{display:grid;gap:10px}.person-card{display:flex;align-items:center;border:1px solid var(--line);border-radius:8px;overflow:hidden;background:#fafaf7}.person-card.selected{border-color:var(--accent);background:#f4f7f0;box-shadow:0 0 0 1px var(--accent)}.person-select{background:none;display:flex;align-items:center;gap:13px;text-align:left;padding:10px;flex:1;min-width:0;color:var(--ink)}.person-select img{width:48px;height:56px;object-fit:cover;border-radius:4px;background:var(--soft)}.person-copy{min-width:0}.person-name{display:block;font-size:13px;overflow-wrap:anywhere}.person-count{font-size:10px;color:var(--muted)}.person-card>.small-button{margin-right:10px}.empty-small{border:1px dashed var(--line);padding:28px 16px;text-align:center;border-radius:8px;font-size:13px;color:var(--ink)}.empty-small span{display:inline-block;margin-top:6px;font-size:11px;color:var(--muted)}.subtle-label{font-size:10px;color:var(--muted)}.scene-bookmark{display:flex;gap:8px;margin-top:15px}.scene-bookmark input{font-size:11px;min-height:36px;padding:8px 10px}.saved-scenes{display:flex;flex-wrap:wrap;gap:7px;margin-top:12px}.scene-chip{display:flex;max-width:100%;background:var(--soft);border-radius:5px;border:1px solid transparent}.scene-chip.selected{border-color:var(--accent)}.scene-chip button{background:none;padding:6px 9px;font-size:11px;color:var(--ink);overflow-wrap:anywhere;min-width:0}.scene-chip button:first-child{text-align:left}.scene-chip button:last-child{padding-left:6px;color:var(--muted)}.options-heading{display:flex;align-items:center;gap:10px;border-top:1px solid var(--line);margin:24px 0 20px;padding-top:23px}.option-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.option-grid select{font-size:12px}.checkbox-label{display:flex;gap:11px;align-items:flex-start;margin:19px 0 23px;cursor:pointer}.checkbox-label input{accent-color:var(--accent);width:16px;height:16px;margin:2px 0 0}.checkbox-label .hint{display:block;margin-top:1px}.generate-button{display:flex;align-items:center;justify-content:space-between;width:100%;padding:15px 18px;border-radius:6px;background:var(--accent);color:white;font-size:13px;font-weight:500}.generate-button:hover{background:#3e5036}.generate-button>span:last-child{font-size:20px;line-height:1}.generation-note{font-size:10px;color:var(--muted);line-height:1.7;margin-top:13px}.results-panel{position:sticky;top:24px;border:1px solid var(--line);border-radius:12px;padding:25px 27px;background:#f0f0e9;min-height:688px;display:flex;flex-direction:column}.result-placeholder{min-height:520px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:25px 5px}.frame-art{position:relative;width:124px;height:160px;border:1px solid #b8bdae;border-radius:55px 55px 2px 2px;margin-bottom:30px;background:linear-gradient(155deg,#e4e9dc,#eaebe3 58%,#dce1d4)}.frame-art-inner{position:absolute;inset:15px;border:1px solid #b8bdae;border-radius:45px 45px 1px 1px}.frame-art-circle{position:absolute;width:24px;height:24px;border-radius:50%;background:#c5cdb9;top:46px;left:49px}.result-placeholder p{font-size:12px;color:var(--muted);line-height:1.75;margin-top:12px}.model-label{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:9px;letter-spacing:.04em;border:1px solid #d0d4c8;border-radius:20px;padding:5px 10px;margin-top:25px;color:var(--muted)}.results-note{font-size:10px;color:var(--muted);border-top:1px solid var(--line);padding-top:14px;margin-top:auto;line-height:1.7}.generation-status{padding:13px 14px;margin:0 0 15px;background:#fff;border:1px solid var(--line);border-radius:7px}.results-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-bottom:18px}.result-card{min-width:0}.result-card:only-child{grid-column:1/-1}.result-card button{display:block;background:transparent;width:100%;padding:0}.result-card img{border-radius:7px;width:100%;height:auto;max-height:570px;object-fit:contain;background:#e6e7df}.result-caption{display:flex;gap:8px;justify-content:space-between;margin-top:8px;font-size:11px}.result-caption a{text-underline-offset:3px}.result-placeholder.busy .frame-art{animation:breath 2s ease-in-out infinite}@keyframes breath{50%{opacity:.4}}footer{display:flex;justify-content:space-between;gap:16px;border-top:1px solid var(--line);padding:25px 0 30px;margin-top:45px;color:var(--muted);font-size:10px}footer span{margin:0 8px}dialog{color:var(--ink);border:1px solid var(--line);border-radius:12px;background:var(--white);padding:27px;width:min(540px,calc(100% - 32px));max-height:calc(100dvh - 40px);overflow:auto;box-shadow:0 18px 80px #20271930}dialog::backdrop{background:#242c2566;backdrop-filter:blur(3px)}dialog h2{font-size:19px}.icon-button{border:1px solid var(--line);border-radius:50%;background:#fff;color:var(--muted);width:29px;height:29px;line-height:1;font-size:20px;display:flex;align-items:center;justify-content:center}.photo-heading{display:flex;justify-content:space-between;align-items:center;margin-top:23px}.photo-heading label{margin:0}.file-input{width:100%;font-size:11px;color:var(--muted);margin:13px 0 17px}.file-input::file-selector-button{border:1px solid var(--line);border-radius:5px;background:var(--soft);padding:8px 11px;color:var(--ink);font:inherit;margin-right:10px;cursor:pointer}.photo-list{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.photo-tile{min-width:0}.photo-tile>button:first-child{background:none;padding:0;width:100%;border-radius:5px;overflow:hidden}.photo-tile img{width:100%;height:118px;object-fit:cover}.photo-label{font-size:9px;color:var(--muted);margin-top:5px}.photo-actions{display:flex;flex-wrap:wrap;gap:7px;margin-top:6px}.photo-actions button{font-size:10px}.dialog-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:25px}.dialog-actions>.danger{margin-right:auto}.danger{color:var(--danger)}.confirm-dialog{width:min(440px,calc(100% - 32px))}.confirm-dialog p{font-size:13px;color:var(--muted);line-height:1.7;margin-top:14px}.preview-dialog{padding:18px;width:fit-content;max-width:calc(100% - 32px);background:var(--paper)}.preview-dialog>.icon-button{margin:0 0 13px auto}.preview-dialog img{max-height:75dvh;max-width:85vw;object-fit:contain;border-radius:4px}
@media(max-width:1100px){.page{padding:0 32px}.workspace{gap:18px;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr)}.panel,.results-panel{padding:21px}.intro{gap:25px}h1{font-size:36px}.intro-note{max-width:225px}.connection-actions{flex-wrap:wrap}.connection-actions .hint{flex-basis:100%;max-width:none}.connection-actions #clear-key{margin-left:auto}.option-grid{gap:8px}.results-grid{grid-template-columns:1fr}}
@media(max-width:800px){.workspace{grid-template-columns:1fr}.results-panel{position:static;min-height:480px}.result-placeholder{min-height:360px}.intro{align-items:flex-start;flex-direction:column;gap:16px;padding:32px 0 27px}.intro-note{max-width:390px}.connection-actions{flex-wrap:nowrap}.connection-actions .hint{flex-basis:auto}.connection-actions #clear-key{margin-left:0}.results-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.masthead{height:82px}.masthead-label{font-size:9px;padding-left:15px}.masthead{gap:15px}}
@media(max-width:480px){.page{padding:0 18px}.masthead{height:74px;gap:10px;flex-wrap:wrap}.brand{font-size:29px}.masthead-label{display:none}.masthead>.text-button{font-size:10px}h1{font-size:33px;letter-spacing:-1.5px}.eyebrow{font-size:9px}.panel,.results-panel{padding:20px 18px}.section-heading{gap:8px}.section-title{gap:8px}.section-heading h2{font-size:15px}.small-button{padding:8px 10px;font-size:10px}.connection-actions .hint{font-size:10px;max-width:100px}.option-grid{gap:6px}.option-grid label{font-size:11px}.option-grid select{font-size:11px;padding-left:8px}.results-grid{gap:12px}.result-caption{font-size:10px}.photo-list{gap:8px;grid-template-columns:repeat(2,minmax(0,1fr))}.photo-tile img{height:150px}.photo-actions button{font-size:11px}.scene-bookmark{gap:6px}footer{flex-direction:column;gap:7px;margin-top:28px;padding:21px 0}.result-placeholder h3{font-size:18px}.result-placeholder p{font-size:11px}}
@media(prefers-reduced-motion:reduce){.result-placeholder.busy .frame-art{animation:none}}
/* v0.8：场景目录、后台批次与身份评分沿用现有品牌样式。 */
.output-area{display:grid;gap:20px;min-width:0}.output-area .results-panel{position:static;min-height:560px}.output-area .result-placeholder{min-height:390px}.scene-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;max-height:430px;overflow-y:auto;padding:2px;margin-top:15px}.scene-card{display:flex;flex-direction:column;min-width:0;text-align:left;padding:0;border:1px solid var(--line);border-radius:8px;background:var(--white);overflow:hidden;color:var(--ink)}.scene-card.selected{border-color:var(--accent);box-shadow:0 0 0 1px var(--accent);background:#f4f7f0}.scene-thumbnail{position:relative;flex-shrink:0;display:flex;align-items:center;justify-content:center;width:100%;aspect-ratio:4/3;background:var(--soft);font-size:10px;color:var(--muted);text-align:center}.scene-thumbnail img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}.scene-copy{display:grid;gap:4px;padding:10px 12px;min-width:0;width:100%}.scene-name{font-size:12px;font-weight:550;overflow-wrap:anywhere}.scene-count{font-size:10px;color:var(--muted)}.option-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.retry-note{margin-top:12px}.batch-meta{margin:0 0 19px;overflow-wrap:anywhere}.batch-meta h3{font-size:17px;margin-bottom:5px}.batch-meta p{font-size:11px;color:var(--muted);line-height:1.8}.resume-button{align-self:flex-start;margin:0 0 15px}.result-frame{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;min-height:180px;border:1px solid var(--line);border-radius:7px;background:#e6e7df;padding:15px;text-align:center;color:var(--muted);font-size:11px;overflow-wrap:anywhere}.result-frame.loaded{display:block;min-height:0;border:0;padding:0}.result-frame .small-button{width:auto}.result-caption{flex-wrap:wrap}.similarity-row{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}.similarity-score,.retry-badge{display:inline-block;border-radius:4px;padding:4px 6px;font-size:10px;line-height:1.5}.similarity-score.good{color:#355330;background:#e2eadc}.similarity-score.low{color:#873c2f;background:#f1e2da}.similarity-score.unavailable{color:var(--muted);background:#e7e7df}.retry-badge{color:#76602d;background:#eee9d9}.history-panel{min-width:0}.history-panel>.status{margin:0 0 15px}.history-list{display:grid;gap:8px;max-height:540px;overflow-y:auto;padding:2px}.history-item{display:grid;gap:7px;width:100%;text-align:left;padding:13px;border:1px solid var(--line);border-radius:7px;background:#fafaf7;color:var(--ink);min-width:0}.history-item.selected{border-color:var(--accent);background:#f4f7f0}.history-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.history-heading strong{font-size:12px;font-weight:550;overflow-wrap:anywhere}.history-detail{font-size:10px;line-height:1.6;color:var(--muted);overflow-wrap:anywhere}.batch-status{font-size:9px;border:1px solid var(--line);padding:2px 6px;border-radius:4px;white-space:nowrap}.batch-status.running,.batch-status.queued{border-color:#becab4;color:var(--accent)}.batch-status.failed,.batch-status.partial{color:var(--danger);border-color:#ddc2b8}#load-history{margin-top:15px}.scene-list::-webkit-scrollbar{width:6px}.scene-list::-webkit-scrollbar-thumb{background:#c8ccbf;border-radius:4px}
@media(max-width:480px){.scene-list{gap:9px;max-height:370px}.scene-copy{padding:9px}.scene-name{font-size:11px}.output-area .results-panel{min-height:460px}.output-area .result-placeholder{min-height:300px}.results-grid{grid-template-columns:1fr}.result-frame{min-height:220px}.similarity-score,.retry-badge{font-size:11px}.history-heading{gap:6px}}
/* v0.9：公开共享提示与旧人物显式迁移，不改变生成页的基本布局。 */
.shared-notice{display:flex;align-items:center;gap:20px;justify-content:space-between;padding:18px 20px;background:#eaf0e4;border:1px solid #d4deca;border-radius:8px;margin-bottom:12px}.shared-notice strong{font-size:13px;font-weight:600}.shared-notice p{font-size:12px;line-height:1.7;color:#56634d;margin-top:5px;max-width:780px}#workspace-status{margin:0 0 20px}.person-thumbnail{display:flex;align-items:center;justify-content:center;width:48px;height:56px;flex-shrink:0;background:var(--soft);border-radius:4px;color:var(--muted);font-size:9px;text-align:center}.person-thumbnail img{width:48px;height:56px;object-fit:cover}.editor-sharing{padding:12px 14px;background:#eef2e9;border:1px solid #dce4d5;border-radius:6px;color:#536148;font-size:12px;line-height:1.7;margin-bottom:18px}.editor-thumbnail{display:flex;align-items:center;justify-content:center;min-height:118px;background:var(--soft);color:var(--muted);font-size:10px}.editor-thumbnail img{width:100%;object-fit:cover}.preference-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}.dialog-actions{flex-wrap:wrap}.import-list{display:grid;gap:10px;margin-top:15px}.import-person{border:1px solid var(--line);padding:12px;border-radius:7px}.import-person label{display:flex;align-items:center;gap:12px;margin:0;cursor:pointer}.import-person input{accent-color:var(--accent);width:16px;height:16px;flex-shrink:0}.import-person img{width:42px;height:52px;object-fit:cover;border-radius:4px}.import-person strong{display:block;overflow-wrap:anywhere;font-size:12px;font-weight:550}.import-person .hint{display:block;font-size:10px}.import-person-status{font-size:10px;margin-top:8px}.legacy-cleanup{margin-top:24px;padding-top:18px;border-top:1px solid var(--line)}.legacy-cleanup p{font-size:11px;line-height:1.7;color:var(--muted);margin-bottom:12px}.legacy-cleanup button{font-size:11px}
@media(max-width:800px){.shared-notice{align-items:flex-start;flex-direction:column;gap:12px}}@media(max-width:480px){.shared-notice{padding:15px}.shared-notice p{font-size:11px}.masthead>.text-button{max-width:190px;text-align:right;line-height:1.6}.editor-thumbnail{min-height:150px}}

/* v0.10：共享凭据与用量入口；本机选择继续留在生成流程内。 */
.masthead-actions{margin-left:auto;display:flex;align-items:center;gap:18px}.masthead-actions>.text-button{font-size:11px}.settings-dialog{width:min(700px,calc(100% - 32px))}.settings-dialog section{min-width:0}.settings-dialog h3{font-size:16px}.settings-dialog .section-heading{margin-bottom:14px}.masked-key{font-size:13px;padding:12px 14px;margin:10px 0;background:var(--soft);border-radius:6px;overflow-wrap:anywhere}.key-settings-form{margin-top:20px}.key-settings-form>.small-button{margin-top:14px}.usage-section{margin-top:26px;padding-top:23px;border-top:1px solid var(--line)}.usage-section select{max-width:190px}.usage-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:18px 0 12px}.usage-metric{min-width:0;padding:13px;background:#f5f6f1;border:1px solid var(--line);border-radius:7px}.usage-metric dt{font-size:10px;color:var(--muted)}.usage-metric dd{margin:5px 0 0;font-size:21px;line-height:1.4;overflow-wrap:anywhere}.usage-recent{list-style:none;padding:0;margin:16px 0 0;display:grid;gap:8px}.usage-item{display:flex;flex-wrap:wrap;justify-content:space-between;gap:5px 12px;border-top:1px solid var(--line);padding-top:10px;font-size:11px;overflow-wrap:anywhere;min-width:0}.usage-item strong{font-weight:500}.usage-item span{color:var(--muted)}.usage-request{flex-basis:100%;font-size:10px}#usage-empty{margin-top:16px}
@media(max-width:600px){.masthead-actions{gap:8px;align-items:flex-end;flex-direction:column}.masthead-actions>.text-button{font-size:9px;max-width:200px;text-align:right}.masthead{height:92px;flex-wrap:nowrap}.masthead-label{display:none}.settings-dialog{padding:20px 18px}.usage-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.usage-metric dd{font-size:18px}}
