:root{--commerce-blue:#4564df;--commerce-ink:#26313f;--commerce-muted:#687589;--commerce-line:#e2e6ec}
.commerce-portal{min-height:100vh;background:#f7f8fa;font-size:14px}.loading-copy{padding:48px;color:var(--commerce-muted)}
.commerce-brand{display:inline-flex;align-items:center;gap:10px;font-weight:650;font-size:18px;letter-spacing:-.4px}.commerce-mark{width:31px;height:31px;border-radius:9px;background:var(--commerce-blue);color:white;display:grid;place-items:center}.commerce-mark svg{width:22px;height:22px}
.commerce-header{height:72px;padding:0 40px;background:#fff;border-bottom:1px solid var(--commerce-line);display:flex;align-items:center;justify-content:space-between;gap:24px}.commerce-nav{display:flex;gap:22px;align-items:center;font-size:14px}.commerce-nav a{color:var(--commerce-muted)}.commerce-nav a[aria-current]{color:var(--commerce-blue);font-weight:600}
.commerce-shell{max-width:1136px;margin:auto;padding:40px 32px 64px}.commerce-title{display:flex;justify-content:space-between;align-items:center;gap:20px;margin:0 0 26px}.commerce-title h1{font-size:28px;font-weight:650;letter-spacing:-.8px;margin-bottom:7px}.commerce-title p{color:var(--commerce-muted);line-height:1.7}
.commerce-test{background:#fff8e7;border:1px solid #f0dfad;border-radius:8px;color:#7a5a13;padding:12px 16px;line-height:1.7;margin-bottom:24px;font-size:13px}.commerce-studio-banner{padding:7px 18px;background:#fff8e7;color:#765919;font-size:12px;text-align:center}.commerce-studio-banner+.topbar{position:relative}.commerce-studio .header-actions>[data-action="download-local"]{display:none}.commerce-studio .workspace-name{display:none}
.commerce-balance{display:flex;gap:48px;align-items:center;background:white;border:1px solid var(--commerce-line);border-radius:12px;padding:28px 32px;margin-bottom:32px}.commerce-balance dl{margin:0}.commerce-balance dt{font-size:13px;color:var(--commerce-muted);margin-bottom:8px}.commerce-balance dd{font-size:38px;font-weight:600;font-variant-numeric:tabular-nums;margin:0;line-height:1.1;letter-spacing:-1px}.commerce-balance dd small{font-size:13px;font-weight:400;letter-spacing:0;margin-left:8px;color:var(--commerce-muted)}.commerce-balance .balance-note{margin-left:auto;max-width:290px;font-size:13px;line-height:1.8;color:var(--commerce-muted)}
.commerce-section{margin:32px 0}.commerce-section h2{font-size:18px;font-weight:600;margin-bottom:5px}.commerce-section>.subcopy{font-size:13px;color:var(--commerce-muted);margin-bottom:18px;line-height:1.8}.commerce-packs{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}.commerce-pack{background:white;border:1px solid var(--commerce-line);padding:23px;border-radius:10px}.commerce-pack h3{font-size:15px;font-weight:500;color:var(--commerce-muted)}.commerce-pack .pack-credits{font-size:29px;font-weight:600;margin:18px 0 8px;font-variant-numeric:tabular-nums}.commerce-pack .pack-credits small{font-size:13px;font-weight:400}.commerce-pack p{color:var(--commerce-muted);margin-bottom:20px;font-size:13px}.commerce-pack button{width:100%;min-height:42px}
.commerce-tabs{display:flex;gap:26px;border-bottom:1px solid var(--commerce-line);margin-top:32px}.commerce-tabs button{padding:13px 0;border-bottom:2px solid transparent;color:var(--commerce-muted);font-size:14px}.commerce-tabs button.active{color:var(--commerce-blue);border-bottom-color:var(--commerce-blue);font-weight:600}.commerce-table-wrap{overflow:auto;background:white;border:1px solid var(--commerce-line);border-top:0;border-radius:0 0 10px 10px}.commerce-table{border-collapse:collapse;width:100%;text-align:left;white-space:nowrap;font-size:13px}.commerce-table th{background:#fafbfc;font-size:12px;color:var(--commerce-muted);font-weight:500;padding:14px 18px}.commerce-table td{padding:16px 18px;border-top:1px solid #edf0f4;font-variant-numeric:tabular-nums}.commerce-table td.wrap{white-space:normal;min-width:200px;max-width:350px;line-height:1.8}.commerce-empty{text-align:center;padding:44px;color:var(--commerce-muted);background:white}.commerce-label{display:inline-flex;align-items:center;border-radius:5px;padding:3px 8px;background:#f0f3f8;color:#5a6980;font-size:12px}.commerce-label.good{background:#ebf6ef;color:#2d7550}.commerce-positive{color:#23774c}.commerce-negative{color:#4b5c73}
.commerce-form{display:grid;gap:19px}.commerce-form label{display:grid;gap:8px;font-size:13px;color:#4e5c6d}.commerce-form input,.commerce-form select,.commerce-form textarea{border:1px solid #d6dce5;border-radius:7px;background:white;width:100%;min-height:44px;padding:11px 12px;font-size:14px}.commerce-form textarea{min-height:80px;resize:vertical}.commerce-form .button{min-height:45px}.commerce-form .form-help{font-size:12px;color:var(--commerce-muted);line-height:1.8}.commerce-form .inline-result{overflow-wrap:anywhere;font-size:12px;padding:12px;background:#eff3ff;border-radius:6px}.commerce-error{font-size:13px;color:#ae3e3e;line-height:1.7;min-height:20px}
.commerce-login{min-height:100vh;display:grid;grid-template-columns:minmax(360px,1.1fr) minmax(390px,1fr);background:white}.commerce-login-photo{position:relative;min-height:100vh;background:#e7e7e3;overflow:hidden}.commerce-login-photo img{width:100%;height:100%;position:absolute;object-fit:cover;object-position:center 30%}.commerce-login-photo img.login-cover{object-position:center 45%}.commerce-login-photo .photo-caption{position:absolute;bottom:30px;left:32px;padding:9px 13px;color:white;background:#1f2b3980;border-radius:6px;font-size:12px;backdrop-filter:blur(8px)}.commerce-login-content{display:flex;flex-direction:column;padding:38px 54px}.commerce-login-form{margin:auto;width:100%;max-width:360px;padding:40px 0}.commerce-login-form h1{font-size:28px;font-weight:600;letter-spacing:-.8px;margin-bottom:10px}.commerce-login-form>.subcopy{color:var(--commerce-muted);font-size:14px;line-height:1.8;margin-bottom:30px}.commerce-login-footer{font-size:12px;color:var(--commerce-muted);line-height:1.8}.commerce-login-footer a{color:var(--commerce-blue)}.commerce-demo-entry{margin-top:16px;width:100%}
.commerce-dialog{width:min(460px,calc(100vw - 32px));max-height:90vh;border:1px solid var(--commerce-line);border-radius:14px;padding:26px;box-shadow:0 20px 80px #17213628;color:var(--commerce-ink)}.commerce-dialog::backdrop{background:#17243866;backdrop-filter:blur(3px)}.commerce-dialog .dialog-top{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:20px}.commerce-dialog h2{font-size:20px;font-weight:600}.commerce-close{width:32px;height:32px;display:grid;place-items:center;border-radius:7px;color:#67778b}.commerce-close:hover{background:#f0f3f8}.commerce-close svg{width:18px;height:18px}.commerce-dialog .payment-body{text-align:center;display:grid;justify-items:center;gap:15px;padding:8px 0}.commerce-dialog .qr{width:240px;height:240px;border:1px solid var(--commerce-line);border-radius:10px;padding:8px}.commerce-dialog .payment-amount{font-size:28px;font-weight:600;font-variant-numeric:tabular-nums}.commerce-dialog .payment-note{color:var(--commerce-muted);font-size:13px;line-height:1.8;max-width:320px}.commerce-dialog .button{width:100%;min-height:44px}
.commerce-admin-grid{display:grid;grid-template-columns:1fr 1fr;gap:24px}.commerce-admin-box{background:white;border:1px solid var(--commerce-line);border-radius:10px;padding:24px}.commerce-admin-box h2{font-size:17px;margin-bottom:20px}.commerce-admin-metrics{display:flex;gap:40px;padding:20px 0 8px}.commerce-admin-metrics strong{font-size:28px;font-weight:600}.commerce-admin-metrics p{color:var(--commerce-muted);font-size:12px;margin-top:4px}.commerce-admin-forms{margin-top:28px}.commerce-account-pill{display:inline-flex;align-items:center;gap:9px;padding:8px 12px;border:1px solid #dce3f1;border-radius:8px;color:#405885;background:white;font-size:13px;min-height:36px;font-variant-numeric:tabular-nums}.commerce-account-pill svg{width:17px;height:17px}.commerce-account-pill:hover{background:#f4f6ff}
#commerce-status{position:fixed;bottom:28px;left:50%;transform:translateX(-50%);z-index:500;padding:11px 18px;border-radius:9px;background:#283545;color:white;box-shadow:0 6px 20px #18253624;max-width:calc(100vw - 32px);font-size:13px;display:none}#commerce-status.visible{display:block}
@media(max-width:800px){.commerce-header{padding:0 20px;height:64px}.commerce-nav{gap:14px;font-size:12px}.commerce-shell{padding:28px 18px 50px}.commerce-login{grid-template-columns:1fr}.commerce-login-photo{display:none}.commerce-login-content{padding:28px;min-height:100vh}.commerce-packs{gap:10px}.commerce-pack{padding:16px}.commerce-pack .pack-credits{font-size:24px}.commerce-balance{padding:24px;gap:30px;flex-wrap:wrap}.commerce-balance dd{font-size:31px}.commerce-balance .balance-note{margin-left:0;max-width:none}.commerce-admin-grid{grid-template-columns:1fr}.commerce-studio .header-actions #save-state{display:none}.commerce-title h1{font-size:24px}.commerce-dialog{padding:22px}}
@media(max-width:480px){.commerce-packs{grid-template-columns:1fr}.commerce-pack{display:grid;grid-template-columns:1fr auto;column-gap:16px}.commerce-pack h3{grid-column:1}.commerce-pack .pack-credits{grid-column:1;margin:10px 0}.commerce-pack p{grid-column:1;margin-bottom:0}.commerce-pack button{grid-column:2;grid-row:1/4;align-self:center}.commerce-nav .nav-studio{display:none}.commerce-tabs{gap:22px}.commerce-account-pill{font-size:12px;padding:7px}.commerce-studio .header-actions{gap:6px}}
@media(prefers-reduced-motion:reduce){.commerce-portal *{scroll-behavior:auto;transition:none!important}}

.reset-link{width:100%;min-height:108px;margin-top:14px;border:1px solid var(--commerce-line);border-radius:7px;padding:12px;font-size:12px;line-height:1.7;resize:vertical}.commerce-login-form{padding-top:24px;padding-bottom:24px}
/* M1：商业版只使用内置 AI 模特，隐藏真人模特上传入口（服务端仍会拒绝 source=upload）。 */
.commerce-studio [data-upload="model"]{display:none!important}
.commerce-form fieldset{border:1px solid var(--commerce-line);border-radius:7px;padding:12px;margin:14px 0}.commerce-form fieldset label{display:flex;gap:8px;align-items:center;margin:6px 0;font-size:13px}.commerce-form fieldset legend{padding:0 6px;font-size:12px;color:var(--commerce-muted)}
.totp-qr{display:block;width:220px;max-width:100%;margin:14px auto;border:1px solid var(--commerce-line);border-radius:10px;background:#fff}
@media(max-width:760px){
  .commerce-shell{padding-bottom:calc(56px + env(safe-area-inset-bottom))}
  .commerce-header{padding-top:env(safe-area-inset-top)}
  .commerce-form input,.commerce-form select,.commerce-form textarea{font-size:16px}
  .commerce-table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch}
  .commerce-dialog{max-height:90dvh;overflow:auto;padding-bottom:calc(20px + env(safe-area-inset-bottom))}
  .commerce-nav{gap:12px;flex-wrap:wrap}
}
