:root{color-scheme:light;--bg:#f7f9fc;--paper:#fff;--ink:#17243b;--muted:#7b879b;--line:#e8edf5;--brand:#5965e9;--brand-hover:#4754da;--soft:#eef0ff;--green:#28a77d;--red:#d75465;--radius:18px;font-family:Inter,'PingFang SC','Microsoft YaHei',sans-serif;font-synthesis:none;color:var(--ink);background:var(--bg)}*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button,a,input,textarea{-webkit-tap-highlight-color:transparent}a{color:inherit;text-decoration:none}button{cursor:pointer}button:disabled{opacity:.45;cursor:not-allowed}button,input,textarea{color:inherit}button:focus-visible,a:focus-visible,summary:focus-visible{outline:2px solid var(--brand);outline-offset:4px}input,textarea{outline:none}input:focus-visible{border-color:var(--brand)}[hidden]{display:none!important}.site-header{height:82px;background:var(--paper);border-bottom:1px solid var(--line)}.header-inner{height:100%;max-width:1456px;margin:auto;padding:0 40px;display:flex;align-items:center;gap:40px}.brand{display:flex;align-items:center;gap:12px;font-size:23px;font-weight:750;white-space:nowrap}.brand>span:last-child{display:flex;align-items:center;gap:14px}.brand-mark{display:grid;place-items:center;width:38px;height:38px;background:var(--brand);color:white;border-radius:12px;font-size:20px;font-weight:700}.brand small{font-size:13px;font-weight:500;color:var(--muted)}.brand-divider{width:1px;height:18px;background:var(--line)}nav{display:flex;gap:30px;height:100%;align-items:center}nav a{font-size:14px;color:var(--muted);height:100%;display:flex;align-items:center;position:relative}nav a[aria-current=true]{color:var(--brand);font-weight:650}nav a[aria-current=true]:after{content:'';position:absolute;height:3px;bottom:0;left:10px;right:10px;background:var(--brand);border-radius:3px}.header-actions{margin-left:auto;display:flex;align-items:center;gap:24px;font-size:14px}.text-link{color:var(--muted)}.text-link:hover{color:var(--brand)}.button{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:13px 23px;border-radius:10px;border:1px solid transparent;font-size:14px;font-weight:600;white-space:nowrap;transition:background .15s,color .15s}.button.primary{background:var(--brand);color:#fff;box-shadow:0 4px 10px #5965e91a}.button.primary:hover{background:var(--brand-hover)}.button.dark{background:var(--ink);color:#fff}.button.outline{background:var(--paper);border-color:var(--line)}.button.outline:hover{background:var(--bg)}.button.text{background:transparent;color:var(--muted);padding:8px 10px}.button.text:hover{background:var(--soft);color:var(--brand)}.button.small{padding:9px 15px;font-size:13px}.workspace{max-width:1320px;margin:auto;padding:0 40px;min-height:calc(100dvh - 180px)}.hero{text-align:center;padding:48px 0 30px}.eyebrow{color:var(--brand);font-size:13px;font-weight:600;letter-spacing:1px}.hero h1{font-size:36px;letter-spacing:-1.2px;margin:15px 0 12px;font-weight:750}.hero h1 span{color:var(--brand)}.hero p{font-size:15px;color:var(--muted);margin:0}.editor-shell{background:var(--paper);border:1px solid var(--line);border-radius:var(--radius);box-shadow:0 12px 44px #25385806;overflow:hidden}.editor-topbar{display:flex;align-items:center;justify-content:space-between;padding:18px 25px;border-bottom:1px solid var(--line)}.editor-mode{display:flex;align-items:center;gap:9px;font-size:14px;font-weight:650}.live-dot{width:7px;height:7px;border-radius:50%;background:var(--brand)}.mode-tag{padding:3px 8px;font-size:11px;background:var(--soft);color:var(--brand);border-radius:5px;margin-left:5px;font-weight:500}.editor-meta{display:flex;gap:20px;color:var(--muted);font-size:12px}.columns{display:grid;grid-template-columns:1fr 1fr}.editor-pane{min-width:0}.editor-pane+.editor-pane{border-left:1px solid var(--line)}.pane-heading{height:64px;display:flex;align-items:center;justify-content:space-between;padding:0 25px}.pane-heading h2{font-size:14px;margin:0;font-weight:650}.pane-heading>div{display:flex;gap:6px}.editor-pane textarea{display:block;width:100%;height:350px;min-height:240px;resize:none;border:0;background:transparent;padding:0 25px 22px;font-size:15px;line-height:1.95;letter-spacing:.1px}.editor-pane textarea::placeholder{color:#adb5c4}.result-pane{background:#fcfdff}.pane-bottom{display:flex;justify-content:space-between;gap:15px;padding:15px 25px;color:var(--muted);font-size:11px;min-height:47px}.result-area{position:relative}.result-empty{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;pointer-events:none;padding-bottom:40px}.result-empty h3{font-size:15px;font-weight:550;color:#8793a9;margin:17px 0 9px}.result-empty p{font-size:12px;color:#a4adbc;margin:0}.empty-shape{width:43px;height:51px;background:linear-gradient(140deg,#f2f4fc,#e8ecfb);border:1px solid #e1e6f6;border-radius:8px;position:relative;transform:rotate(-8deg)}.empty-shape:before,.empty-shape:after{content:'';position:absolute;left:10px;right:10px;height:3px;background:#ccd3eb;border-radius:3px;top:19px}.empty-shape:after{top:28px;right:16px}.editor-actionbar{display:flex;align-items:center;justify-content:space-between;border-top:1px solid var(--line);padding:19px 25px}.cost{display:flex;flex-direction:column;gap:6px}.cost strong{font-size:13px;font-weight:550}.cost span{font-size:11px;color:var(--muted)}.action-buttons{display:flex;gap:10px}#start{min-width:142px}.history-panel{margin-top:16px;font-size:13px;color:var(--muted)}summary{cursor:pointer}.history-panel summary{display:inline-block;padding:9px 0}.history-item{display:flex;justify-content:space-between;text-align:left;gap:16px;width:100%;border:0;border-bottom:1px solid var(--line);padding:15px;background:var(--paper);font-size:13px;border-radius:7px}.history-item:hover{background:var(--soft)}.history-item span{color:var(--muted);white-space:nowrap}.benefit-row{display:grid;grid-template-columns:repeat(3,1fr);max-width:900px;margin:32px auto 46px;gap:30px;text-align:center}.benefit-row div{display:flex;flex-direction:column;gap:9px}.benefit-row b{font-size:13px;font-weight:550}.benefit-row span{font-size:12px;color:var(--muted)}.site-footer{max-width:1320px;margin:auto;padding:22px 40px;display:flex;justify-content:space-between;font-size:11px;color:#919bad}.page-heading{display:flex;align-items:center;justify-content:space-between;margin:38px 0 24px}.page-heading h1{font-size:28px;letter-spacing:-.6px;margin:10px 0}.surface{background:var(--paper);border:1px solid var(--line);border-radius:14px;padding:26px;margin-bottom:20px}.surface h2{font-size:16px;margin:0 0 20px}.account-grid{display:grid;grid-template-columns:1fr 1.3fr;gap:20px}.balance-detail{font-size:22px;font-weight:650}.subtle{color:var(--muted);font-size:12px;line-height:1.8}.inline-form{display:flex;gap:10px}input{padding:12px 14px;border:1px solid var(--line);border-radius:9px;width:100%;min-width:0;background:#fff;transition:border-color .15s}label{display:flex;flex-direction:column;gap:10px;font-size:13px}form{display:flex;flex-direction:column;gap:18px}.row{padding:15px 0;border-bottom:1px solid var(--line);font-size:13px;line-height:1.7;overflow-wrap:anywhere}.row:last-child{border-bottom:0}.empty-list{padding:35px;text-align:center;color:var(--muted);font-size:13px}.password-section form{max-width:450px;margin-top:25px}.admin-layout{display:grid;grid-template-columns:190px 1fr;gap:38px}.admin-sidebar{padding-top:36px;position:sticky;top:0;align-self:start;display:flex;flex-direction:column;gap:8px;min-height:70vh}.admin-sidebar h1{font-size:17px;margin:10px 12px 28px}.admin-sidebar>a,.sidebar-item{padding:13px 15px;font-size:13px;color:var(--muted);border-radius:9px}.admin-sidebar>a:hover,.sidebar-item.active{background:var(--soft);color:var(--brand)}.sidebar-bottom{margin-top:auto;padding:25px 12px;font-size:12px;color:var(--muted)}.admin-content{min-width:0}.generate-section{display:flex;align-items:center;gap:30px;justify-content:space-between}.generate-section h2{margin-bottom:8px}.generate-section p{margin:0}.generate-section form{flex-direction:row;align-items:end;gap:12px}.generate-section input{width:140px}.generate-section label:first-child input{width:90px}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:20px}.section-heading h2{margin:0}.pagination{display:flex;align-items:center;gap:10px;font-size:11px;color:var(--muted)}.table-scroll{overflow:auto}table{border-collapse:collapse;width:100%;font-size:12px;white-space:nowrap}th{text-align:left;background:var(--bg);font-size:11px;font-weight:500;color:var(--muted)}td,th{padding:14px 12px;border-bottom:1px solid var(--line)}td .button{font-size:11px}.badge{display:inline-flex;align-items:center;padding:4px 9px;border-radius:5px;background:var(--soft);color:var(--brand);font-size:11px}.badge.redeemed{background:#ebf7f1;color:#278562}.badge.revoked{background:#f4f5f7;color:#8d95a3}.generated-box textarea{width:100%;height:170px;border:1px solid var(--line);border-radius:9px;padding:15px;font-family:monospace;line-height:1.9;resize:vertical}.notice{position:fixed;top:94px;left:50%;transform:translateX(-50%);z-index:30;background:var(--ink);color:#fff;border-radius:12px;box-shadow:0 8px 30px #17243b20;padding:14px 24px;font-size:13px;max-width:calc(100% - 32px);white-space:pre-wrap}.notice:empty{display:none}dialog{border:0;border-radius:22px;padding:0;width:min(440px,calc(100vw - 32px));box-shadow:0 30px 100px #17243b30;color:var(--ink)}dialog::backdrop{background:#17243b66;backdrop-filter:blur(4px)}.auth-shell{padding:38px;position:relative}.auth-shell>.brand-mark{margin-bottom:25px}.auth-shell h2{font-size:24px;margin:0 0 10px}.auth-shell p{font-size:13px;color:var(--muted);margin-bottom:30px}.auth-close{position:absolute;right:18px;top:18px;font-size:11px!important}#auth-error{color:var(--red);font-size:12px}#auth-error:empty{display:none}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}html[data-route=admin] #rewrite,html[data-route=account] #rewrite{display:none}*{scrollbar-width:thin;scrollbar-color:#d6dce8 transparent}*::-webkit-scrollbar{width:6px;height:6px}*::-webkit-scrollbar-thumb{background:#d6dce8;border-radius:5px}@media(min-width:1500px){.editor-pane textarea{height:410px}}@media(max-width:1100px){.header-inner{gap:25px;padding:0 25px}.brand small,.brand-divider{display:none}nav{gap:20px}.workspace{padding:0 24px}.generate-section{align-items:stretch;flex-direction:column;gap:20px}.generate-section form{justify-content:start}.admin-layout{grid-template-columns:155px 1fr;gap:20px}.header-actions{gap:15px}}@media(max-width:760px){.site-header{height:auto}.header-inner{padding:16px 20px;gap:14px;flex-wrap:wrap}.brand{font-size:20px}.brand-mark{width:32px;height:32px;font-size:17px;border-radius:10px}.header-actions{gap:12px}.header-actions .text-link{font-size:12px}nav{order:3;width:100%;height:37px;gap:28px}nav a{font-size:13px}.workspace{padding:0 16px}.hero{padding:31px 8px 24px}.hero h1{font-size:26px;line-height:1.5}.hero h1 span{display:block}.hero p{font-size:12px}.eyebrow{font-size:11px}.columns{grid-template-columns:1fr}.editor-pane+.editor-pane{border-left:0;border-top:1px solid var(--line)}.editor-pane textarea{height:270px;font-size:14px;padding:0 18px 18px}.editor-topbar{padding:15px 18px}.editor-meta{gap:10px;font-size:10px}.pane-heading{padding:0 18px}.pane-bottom{padding:13px 18px;font-size:10px}.editor-actionbar{padding:16px;gap:10px}.cost span{font-size:9px}.cost strong{font-size:11px}#start{min-width:110px;padding:12px 16px}.benefit-row{gap:14px;margin:25px 0}.benefit-row b{font-size:11px}.benefit-row span{font-size:10px;line-height:1.6}.site-footer{padding:20px;gap:12px;flex-direction:column;align-items:center}.account-grid{grid-template-columns:1fr;gap:0}.surface{padding:19px}.page-heading h1{font-size:24px}.admin-layout{grid-template-columns:1fr;gap:0}.admin-sidebar{position:static;min-height:0;padding-top:20px;flex-direction:row;flex-wrap:wrap;align-items:center;gap:4px}.admin-sidebar h1{width:100%;margin:5px 10px 12px}.sidebar-bottom{display:none}.admin-sidebar>a,.sidebar-item{padding:9px;font-size:11px}.admin-content .page-heading{margin-top:20px}.generate-section form{flex-wrap:wrap}.generate-section input{width:125px}.section-heading{flex-wrap:wrap}.table-scroll{margin:0 -10px}.auth-shell{padding:30px}dialog::backdrop{backdrop-filter:none}}@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}
:root{--result:#fcfdff;--field:#fff;--on-ink:#fff;--scroll:#d6dce8;--empty-bg:#eef0fb;--empty-line:#ccd3eb;--good-bg:#ebf7f1;--good-ink:#278562}
:root[data-theme=dark]{color-scheme:dark;--bg:#141923;--paper:#1d2431;--ink:#e7ebf5;--muted:#9aa8be;--line:#333e50;--brand:#929aff;--brand-hover:#7c88f2;--soft:#303951;--result:#1a212d;--field:#19212e;--on-ink:#141923;--scroll:#526079;--empty-bg:#262f43;--empty-line:#455273;--good-bg:#233e37;--good-ink:#7ddbb7}
.result-pane{background:var(--result)}input,dialog{background:var(--field)}.button.dark,.notice{color:var(--on-ink)}.empty-shape{background:var(--empty-bg);border-color:var(--line)}.empty-shape:before,.empty-shape:after{background:var(--empty-line)}.badge.redeemed{background:var(--good-bg);color:var(--good-ink)}.badge.revoked{background:var(--bg);color:var(--muted)}*{scrollbar-color:var(--scroll) transparent}*::-webkit-scrollbar-thumb{background:var(--scroll)}.hero{padding:28px 0 24px}.hero h1{margin:8px 0}.workspace{min-height:calc(100dvh - 82px);padding-bottom:30px}.header-actions{gap:14px}
