:root{font-family:"Segoe UI","Microsoft YaHei",system-ui,sans-serif;color:#202838;background:#e9edf3;font-size:16px;color-scheme:light;--accent:#cc3f70;--stroke:#dde2ea;--muted:#687388;--panel:#fff}
*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,select,input[type=color],input[type=range]{cursor:pointer}button{border:0}button:disabled{opacity:.45;cursor:default}button:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible,textarea:focus-visible{outline:3px solid #cc3f7077;outline-offset:3px}button:hover{filter:brightness(.97)}input[aria-invalid=true]{border-color:#ce294c!important;background:#fff1f4}button,input,select{min-width:0}button{min-height:38px;font-size:.875rem;white-space:nowrap}select{border:1px solid var(--stroke);background:var(--panel);color:inherit;border-radius:8px;padding:9px 30px 9px 10px;font-size:.875rem;width:100%}h1,h2,p{margin:0}.app-header{height:70px;display:flex;align-items:center;justify-content:space-between;padding:0 26px;background:#fff;border-bottom:1px solid var(--stroke)}.brand{display:flex;align-items:center;gap:12px}.brand h1{font-size:1.125rem;letter-spacing:.01em}.brand h1 span{font-weight:450;color:var(--muted);margin-left:8px}.brand-mark{display:grid;grid-template-columns:repeat(2,9px);gap:3px;background:#202838;padding:7px;border-radius:9px}.brand-mark i{height:9px;border-radius:2px;background:#ff7096}.brand-mark i:nth-child(2){background:#bd93f9}.brand-mark i:nth-child(3){background:#8be9fd}.brand-mark i:nth-child(4){background:#50fa7b}.header-meta{display:flex;gap:14px;font-size:.8125rem;color:var(--muted)}.workbench{display:grid;grid-template-columns:360px minmax(0,1fr);height:calc(100dvh - 70px);min-height:620px}.editor{background:var(--panel);border-right:1px solid var(--stroke);display:flex;flex-direction:column;min-height:0}.editor-scroll{overflow-y:auto;padding:22px 22px 16px;flex:1;scrollbar-width:thin}.mode-switch{display:grid;grid-template-columns:1fr 1fr;border-radius:10px;padding:4px;background:#eef1f6;margin-bottom:22px}.mode-switch button{border-radius:7px;background:transparent;color:var(--muted);font-weight:600}.mode-switch button[aria-pressed=true]{color:#202838;background:#fff;box-shadow:0 1px 5px #18233815}.preset-line{display:flex;align-items:center;justify-content:space-between;font-size:.875rem;margin-bottom:6px}.text-button{padding:0;background:none;color:var(--accent);min-height:28px}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:24px 0 12px}.section-heading h2{font-size:.9375rem;font-weight:650}.section-heading>span{font-size:.75rem;color:var(--muted)}.core-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:16px}.color-control{min-width:0}.core-grid .color-control{border:1px solid var(--stroke);border-radius:10px;padding:10px;background:#fbfcfe}.color-label{display:flex;align-items:center;justify-content:space-between;gap:4px;min-width:0;font-size:.875rem;line-height:1.5;margin-bottom:7px}.color-value{display:flex;align-items:center;gap:8px}.color-value input[type=color]{width:31px;height:31px;padding:0;border:0;flex:none;background:none;overflow:hidden;border-radius:6px}.color-value input[type=color]::-webkit-color-swatch-wrapper{padding:0}.color-value input[type=color]::-webkit-color-swatch{border:1px solid #0002;border-radius:6px}.color-text{width:100%;border:1px solid var(--stroke);border-radius:6px;background:#fff;padding:6px;color:inherit;min-width:0;font-family:Consolas,monospace;font-size:.8125rem}.core-grid .color-text{padding:5px;font-size:.75rem}.outline-button{border:1px solid var(--stroke);border-radius:8px;background:var(--panel);color:inherit;padding:8px 12px}.primary-button{background:var(--accent);color:#fff;border-radius:8px;padding:11px 12px;font-weight:600}.full-width{width:100%}.control-hint{color:var(--muted);font-size:.75rem;line-height:1.65;margin-top:8px}.contrast-checks{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-top:16px}.contrast-item{display:flex;justify-content:space-between;gap:5px;background:#f0f3f7;padding:7px 9px;border-radius:6px;font-size:.75rem;color:var(--muted)}.contrast-item b{color:#3c5a4b;font-weight:600}.contrast-item.low b{color:#b55d18}.advanced-heading h2 span{font-size:.75rem;font-weight:400;color:var(--muted)}details.color-group{border-top:1px solid var(--stroke)}details.color-group>summary{padding:13px 0;cursor:pointer;font-size:.875rem;font-weight:550;list-style:none;display:flex;align-items:center;justify-content:space-between}details.color-group>summary::after{content:'+';font-size:1.1rem;color:var(--muted)}details[open].color-group>summary::after{content:'−'}.group-count{font-size:.75rem;color:var(--muted);font-weight:400;margin-left:auto;margin-right:12px}.group-fields>.color-control{padding:12px 0;border-top:1px solid #eef1f6}.group-fields{padding-bottom:8px}.color-state{font-size:.75rem;background:#f0f3f7;color:var(--muted);padding:2px 6px;border-radius:4px;white-space:nowrap}.color-state.locked{background:#fff0f5;color:var(--accent)}.auto-button{min-height:24px;padding:3px 5px;border-radius:4px;background:none;color:var(--accent);font-size:.75rem}.advanced-value{display:grid;grid-template-columns:31px minmax(0,1fr) auto;gap:7px;align-items:center}.alpha-control{display:flex;align-items:center;gap:8px;margin-top:8px;color:var(--muted);font-size:.75rem}.alpha-control input{flex:1;min-width:0;accent-color:var(--accent)}.alpha-control output{width:39px;text-align:right}.subgroup-heading{font-size:.8125rem;font-weight:600;color:var(--muted);padding-top:16px}.field-contrast{font-size:.75rem;color:var(--muted);margin-top:5px;line-height:1.5}.export-panel{padding:14px 22px 16px;border-top:1px solid var(--stroke);box-shadow:0 -6px 16px #18233804}.export-panel #status{font-size:.75rem;line-height:1.55;color:var(--muted);margin-bottom:10px;min-height:19px;overflow-wrap:anywhere}#status.error{color:#bc294b}.export-secondary{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:8px}.export-note{font-size:.75rem;color:var(--muted);margin-top:10px;line-height:1.5}.preview-panel{padding:22px 24px 14px;display:flex;flex-direction:column;min-height:0;min-width:0;gap:14px}.preview-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap}.preview-title{display:flex;flex-direction:column;gap:5px}.eyebrow{font-size:.75rem;color:var(--muted)}.preview-title strong{font-size:1rem;font-weight:600}.preview-options{display:flex;align-items:flex-end;gap:9px;flex-wrap:wrap}.preview-options label{font-size:.75rem;color:var(--muted);display:flex;flex-direction:column;gap:5px}.preview-options select{width:auto;min-width:86px;padding-top:8px;padding-bottom:8px}.preview-frame-wrap{position:relative;flex:1;min-height:480px;overflow:hidden;border:1px solid #cdd4e0;border-radius:13px;box-shadow:0 8px 28px #283b5410;background:#fff}.preview-frame-wrap iframe{width:100%;height:100%;display:block;border:0}.preview-frame-wrap #preview-error{position:absolute;inset:20px auto auto 20px;padding:12px;background:#fff1f4;color:#bc294b;font-size:.875rem;max-width:400px;border-radius:8px}.preview-footer{display:flex;justify-content:space-between;gap:12px;font-size:.75rem;color:var(--muted);line-height:1.5}dialog{max-width:760px;width:calc(100% - 40px);border:1px solid var(--stroke);border-radius:14px;padding:24px;color:inherit;box-shadow:0 24px 80px #10203033}dialog::backdrop{background:#18233888}.dialog-heading{display:flex;justify-content:space-between;align-items:center;gap:10px}.dialog-heading h2{font-size:1.125rem}dialog p{font-size:.875rem;color:var(--muted);margin:16px 0}dialog textarea{width:100%;height:48vh;resize:vertical;border:1px solid var(--stroke);border-radius:8px;padding:12px;font:13px/1.6 Consolas,monospace}[hidden]{display:none!important}
body[data-mode=dark]{color-scheme:dark;color:#e4e9f2;background:#111722;--panel:#1b2331;--stroke:#344051;--muted:#adb7c8;--accent:#ff86aa}body[data-mode=dark] .app-header{background:var(--panel)}body[data-mode=dark] .brand-mark{background:#364255}body[data-mode=dark] .mode-switch{background:#111722}body[data-mode=dark] .mode-switch button[aria-pressed=true]{background:#344051;color:#fff}body[data-mode=dark] .core-grid .color-control,body[data-mode=dark] .contrast-item,body[data-mode=dark] .color-state{background:#232d3c}body[data-mode=dark] .color-text{background:#111722}body[data-mode=dark] .primary-button{color:#251721}body[data-mode=dark] .group-fields>.color-control{border-color:#2a3545}body[data-mode=dark] .contrast-item b{color:#a1d7b4}body[data-mode=dark] .contrast-item.low b{color:#ffb97e}body[data-mode=dark] .color-state.locked{background:#422839;color:#ff96b5}body[data-mode=dark] input[aria-invalid=true]{background:#42232d}body[data-mode=dark] #status.error{color:#ff99ad}
@media(min-width:1700px){.workbench{grid-template-columns:390px minmax(0,1fr)}.preview-panel{padding-inline:34px}}@media(max-width:1050px){.workbench{grid-template-columns:330px minmax(0,1fr)}.editor-scroll,.export-panel{padding-inline:18px}.preview-panel{padding-inline:16px}.preview-toolbar{gap:12px}.preview-options{gap:6px}.preview-options select{min-width:76px}}@media(max-width:760px){.app-header{height:auto;min-height:68px;padding:14px 16px;gap:12px;flex-wrap:wrap}.header-meta{font-size:.75rem}.brand h1{font-size:1rem}.workbench{display:flex;flex-direction:column;height:auto;min-height:0}.editor{border-right:0}.editor-scroll{overflow:visible;padding:18px}.core-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.core-grid .color-value{flex-direction:column;align-items:stretch}.core-grid .color-value input[type=color]{width:100%;height:32px}.color-label{font-size:.8125rem}.export-panel{padding:16px 18px}.preview-panel{padding:20px 12px}.preview-frame-wrap{flex:none;height:78vh;min-height:520px}.preview-options{gap:8px}.preview-footer{flex-wrap:wrap}.section-heading>span{font-size:.75rem}}@media(max-width:420px){.core-grid{grid-template-columns:1fr 1fr}.core-grid .color-value{flex-direction:row;align-items:center}.core-grid .color-value input[type=color]{width:31px}.brand h1 span{margin-left:4px}.preview-options label{flex:1}.preview-options select{width:100%}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}
