:root{--bg:#f4f6fa;--surface:#fff;--ink:#162337;--muted:#748097;--line:#e7ecf3;--blue:#255ce8;--blue-light:#edf3ff;--green:#218360;--red:#b53548;--radius:16px;font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;color:var(--ink);font-size:16px;font-synthesis:none}*{box-sizing:border-box}body{margin:0;background:var(--bg)}button,input{font:inherit}button{cursor:pointer}button:disabled{opacity:.55;cursor:wait}[hidden]{display:none!important}button:focus-visible,input:focus-visible{outline:3px solid #8baaff;outline-offset:3px}button{transition:background .15s,color .15s}h1,h2,p{margin:0}h1{font-size:2rem;letter-spacing:-.04em;line-height:1.3}h2{font-size:1.125rem;letter-spacing:-.02em}small{font-size:.8125rem}.muted{color:var(--muted);font-size:.875rem;line-height:1.7}.eyebrow{font-size:.75rem;font-weight:700;letter-spacing:.13em;color:var(--blue);margin-bottom:10px}.topbar{height:76px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 max(24px,calc((100vw - 1184px)/2));gap:16px}.brand{display:flex;align-items:center;gap:12px;font-weight:800;letter-spacing:.045em;font-size:1.125rem}.brand-mark{display:grid;place-items:center;width:38px;height:38px;border-radius:11px;background:var(--blue);color:white;font-size:1.5rem;font-weight:600}.brand-note{font-weight:400;font-size:.875rem;letter-spacing:0;margin-left:14px;color:var(--muted);padding-left:14px;border-left:1px solid var(--line)}.top-actions{display:flex;align-items:center;gap:24px}.host{color:var(--muted);font-size:.8125rem;font-variant-numeric:tabular-nums}.text-button{background:none;border:0;padding:8px;color:var(--muted);font-size:.875rem}.text-button:hover{color:var(--blue)}main{max-width:1232px;padding:40px 24px;margin:auto}.page-heading{display:flex;justify-content:space-between;align-items:flex-end;gap:20px;margin-bottom:28px}.page-heading h1{margin-bottom:8px}.refresh-area{display:flex;align-items:center;gap:14px}.refresh-area .muted{font-size:.8125rem}.primary,.secondary{border-radius:9px;padding:11px 18px;min-height:44px;font-size:.875rem;font-weight:600}.primary{background:var(--blue);border:1px solid var(--blue);color:white}.primary:hover{background:#174acb}.secondary{background:#fff;border:1px solid #dce3ed;color:#45536a}.secondary:hover{background:#edf2f9}.summary-grid{display:grid;grid-template-columns:1.08fr 1.08fr 1fr;gap:20px;margin-bottom:28px}.summary-card{position:relative;border-radius:var(--radius);padding:24px;background:white;border:1px solid var(--line);overflow:hidden}.summary-label{font-size:.875rem;color:var(--muted)}.summary-number{display:flex;align-items:baseline;gap:9px;margin:18px 0 16px;font-variant-numeric:tabular-nums}.summary-number>span{font-size:2.5rem;font-weight:650;letter-spacing:-.05em;line-height:1}.summary-number small{font-size:.875rem;color:var(--muted)}.summary-foot{display:flex;justify-content:space-between;gap:8px;align-items:center;font-size:.8125rem;color:var(--muted);min-height:25px}.used-card{background:#163a8c;border-color:#163a8c;color:white}.used-card .summary-label,.used-card .summary-foot,.used-card .summary-number small{color:#c0d1f3}.used-card progress{position:absolute;bottom:0;left:0;width:100%;height:4px;border:0;border-radius:0;background:#2c4b8f}.used-card progress::-webkit-progress-bar{background:#2c4b8f}.used-card progress::-webkit-progress-value{background:#81b6ff}.used-card progress::-moz-progress-bar{background:#81b6ff}.reset-date{font-size:1.875rem;letter-spacing:-.03em;font-weight:650;margin:20px 0 16px;line-height:1.2}.days-badge{border-radius:6px;background:#f0f3f8;color:#627087;padding:3px 8px}.blue-text{color:var(--blue)}.panel{background:#fff;border:1px solid var(--line);border-radius:var(--radius);margin-bottom:24px;overflow:hidden}.panel-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:24px}.panel-heading p{margin-top:6px}.count-badge{font-size:.75rem;vertical-align:middle;background:#f0f3f8;color:#71809a;font-weight:600;padding:3px 7px;border-radius:5px;margin-left:6px}.unit-label{font-size:.8125rem;color:var(--muted);white-space:nowrap}.account-columns,.account-row{display:grid;grid-template-columns:1.05fr 1.55fr 1fr .7fr 100px;gap:24px;align-items:center;padding:0 24px}.account-columns{background:#f8fafc;border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding-top:12px;padding-bottom:12px;font-size:.8125rem;color:var(--muted)}.account-row{min-height:112px;border-bottom:1px solid var(--line)}.account-row:last-child{border-bottom:0}.account-identity{display:flex;gap:12px;align-items:center}.avatar{width:42px;height:42px;flex-shrink:0;background:#edf3ff;border:1px solid #e3ebfb;color:var(--blue);border-radius:12px;display:grid;place-items:center;font-variant-numeric:tabular-nums;font-weight:700;font-size:.875rem}.account-row:nth-child(2) .avatar{background:#f1edff;border-color:#eae2ff;color:#7753bd}.account-row:nth-child(3) .avatar{background:#e9f5f1;border-color:#dceee7;color:#32876d}.account-row:nth-child(4) .avatar{background:#fff4e8;border-color:#f6e9d7;color:#a57930}.account-identity strong{display:block;font-size:.9375rem;font-weight:600}.account-identity small{display:block;margin-top:6px;color:var(--muted);font-variant-numeric:tabular-nums}.usage-numbers{display:flex;justify-content:space-between;gap:8px;font-size:.875rem;font-variant-numeric:tabular-nums;margin-bottom:10px}.usage-numbers strong{font-weight:600}.usage-numbers span{color:var(--muted);font-size:.8125rem}.account-row progress{width:100%;height:6px;display:block;border:0;border-radius:10px;background:#edf1f7;overflow:hidden}.account-row progress::-webkit-progress-bar{background:#edf1f7}.account-row progress::-webkit-progress-value{background:var(--blue);border-radius:10px}.account-row progress::-moz-progress-bar{background:var(--blue)}.account-row.exhausted progress::-webkit-progress-value{background:var(--red)}.capacity strong{font-weight:600;font-size:.9375rem;font-variant-numeric:tabular-nums}.capacity small{display:block;color:var(--muted);margin-top:6px;line-height:1.5}.status{display:inline-flex;border-radius:6px;padding:5px 8px;font-size:.75rem;font-weight:550;white-space:nowrap;background:#eef7f3;color:var(--green)}.status.exhausted,.status.fault{background:#fff0f2;color:var(--red)}.status.stopped{background:#fff6e9;color:#98702d}.add-button{border:1px solid #dce6fc;background:#f3f7ff;color:var(--blue);padding:9px 12px;border-radius:8px;font-size:.875rem;white-space:nowrap;min-height:40px}.add-button:hover{background:#e4edff}.panel-footer{padding:16px 24px;background:#fbfcfe;border-top:1px solid var(--line);font-size:.8125rem;color:var(--muted);display:flex;gap:8px;line-height:1.6}.info-icon{border:1px solid #a4afc1;border-radius:50%;width:15px;height:15px;flex-shrink:0;display:grid;place-items:center;font-size:.6875rem;margin-top:3px}.empty-history{padding:30px 24px 38px;text-align:center;color:var(--muted);font-size:.875rem;border-top:1px solid var(--line)}.empty-history strong{display:block;color:#67778f;font-weight:500;margin-bottom:6px}.empty-history p{font-size:.8125rem}.history-item{border-top:1px solid var(--line);padding:17px 24px;display:grid;grid-template-columns:1fr auto;gap:8px;font-size:.875rem}.history-item strong{font-weight:600}.history-item .amount{color:var(--blue);font-size:1rem;font-weight:650}.history-detail{font-size:.8125rem;color:var(--muted);margin-top:6px;line-height:1.5;overflow-wrap:anywhere}.page-footer{display:flex;justify-content:space-between;gap:16px;font-size:.75rem;color:#8a95a8;line-height:1.7;margin-top:30px}.error-banner,.form-error{background:#fff0f2;color:var(--red);font-size:.875rem;padding:12px 14px;line-height:1.6;border-radius:8px}.error-banner{margin-bottom:20px}.form-error{margin:14px 0}.login-wrap{max-width:980px;margin:64px auto;display:grid;grid-template-columns:1fr 1fr;gap:90px;align-items:center}.login-intro h1{font-size:3.75rem;font-weight:650;line-height:1.25;letter-spacing:-.06em;margin:20px 0}.login-intro p{color:var(--muted);line-height:1.9;font-size:1rem}.login-rule{margin-top:42px;display:flex;gap:14px;align-items:center;font-size:.9375rem;color:#586880}.rule-icon{font-size:1.6rem;display:grid;place-items:center;width:44px;height:44px;background:#e7edfa;border-radius:12px;color:var(--blue)}.login-rule small{display:block;color:var(--muted);margin-top:5px}.login-card{padding:36px;background:white;border:1px solid var(--line);border-radius:20px;box-shadow:0 12px 40px #1c325208}.login-card h2{font-size:1.5rem;margin-bottom:12px}.login-card>.muted{margin-bottom:28px}.login-card label,dialog label{display:block;font-size:.875rem;font-weight:550;margin:20px 0 9px}input{width:100%;border:1px solid #d8e0ec;border-radius:9px;padding:12px;color:var(--ink);background:#fff;min-height:46px}input::placeholder{color:#a0aabd}.password-wrap{position:relative}.password-wrap input{padding-right:60px}.password-wrap button{position:absolute;right:6px;top:6px}.otp-input{letter-spacing:.1em;font-variant-numeric:tabular-nums}.wide{width:100%;margin-top:24px}.login-foot{font-size:.75rem;color:#8d98aa;text-align:center;margin-top:18px;line-height:1.6}.initial-loading{padding:100px 20px;text-align:center;color:var(--muted)}.spinner{display:inline-block;width:25px;height:25px;border:2px solid #dce4f5;border-top-color:var(--blue);border-radius:50%;animation:spin .8s linear infinite;margin-bottom:16px}@keyframes spin{to{transform:rotate(360deg)}}dialog{width:min(480px,calc(100vw - 32px));border:1px solid var(--line);border-radius:20px;padding:28px;color:var(--ink);box-shadow:0 20px 90px #0b183940;max-height:calc(100dvh - 40px);overflow:auto}dialog::backdrop{background:#12233c65;backdrop-filter:blur(3px)}.dialog-heading{display:flex;justify-content:space-between;align-items:flex-start}.dialog-heading h2{font-size:1.5rem}.icon-button{border:0;background:#f2f4f8;border-radius:8px;min-width:34px;min-height:34px;font-size:1.4rem;line-height:1;color:var(--muted)}.grant-account{display:flex;align-items:center;gap:12px;margin-top:24px;padding:15px;background:#f7f9fc;border:1px solid var(--line);border-radius:12px}.grant-account strong{font-size:.9375rem}.grant-account small{display:block;color:var(--muted);margin-top:5px}.amount-wrap{position:relative}.amount-wrap input{font-size:1.5rem;font-variant-numeric:tabular-nums;padding-right:55px}.amount-wrap>span{position:absolute;right:17px;top:20px;font-size:.875rem;color:var(--muted)}.presets{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin-top:12px}.presets button{padding:9px 0;border:1px solid var(--line);background:white;border-radius:7px;color:#536078;font-size:.8125rem;min-height:38px}.presets button:hover,.presets button.selected{border-color:#8daeff;background:var(--blue-light);color:var(--blue)}.optional{font-weight:400;color:var(--muted);font-size:.8125rem;margin-left:4px}.grant-preview{margin:20px 0;background:#f6f8fc;border-radius:10px;padding:16px;font-size:.8125rem;color:var(--muted)}.grant-preview>div{display:flex;justify-content:space-between;gap:12px;margin-bottom:12px}.grant-preview strong{color:var(--ink);font-weight:600;text-align:right}.grant-preview p{padding-top:10px;border-top:1px solid #e2e8f2;font-size:.75rem;line-height:1.6}.dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}#toast{position:fixed;bottom:28px;left:50%;transform:translateX(-50%);max-width:calc(100vw - 32px);background:#163a8c;color:white;padding:14px 22px;border-radius:12px;font-size:.875rem;box-shadow:0 8px 30px #14233d30;z-index:10;line-height:1.5}
@media(max-width:1000px){.account-columns,.account-row{grid-template-columns:1fr 1.3fr 1fr .7fr 94px;gap:14px}.refresh-area{flex-direction:column;align-items:flex-end}.login-wrap{gap:40px}.summary-number>span{font-size:2rem}.reset-date{font-size:1.6rem}.summary-card{padding:20px}}
@media(max-width:740px){.topbar{height:64px;padding:0 20px}.brand-note{display:none}.top-actions{gap:8px}.host{font-size:.75rem}main{padding:28px 16px}.page-heading{align-items:flex-start}.page-heading h1{font-size:1.75rem}.refresh-area>.muted{display:none}.refresh-area button{padding:9px 12px}.summary-grid{grid-template-columns:1fr 1fr;gap:12px;margin-bottom:20px}.summary-card{padding:18px}.summary-number>span{font-size:1.8rem}.summary-foot{font-size:.75rem;flex-wrap:wrap;justify-content:flex-start;gap:6px}.reset-card{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:18px}.reset-date{font-size:1.125rem;margin:0}.reset-card .summary-foot{justify-content:flex-end}.reset-card .days-badge{display:none}.panel-heading{padding:20px}.panel-heading p{font-size:.8125rem}.panel-heading .unit-label{display:none}.account-columns{display:none}.account-row{padding:20px;grid-template-columns:1fr auto;gap:18px;border-top:1px solid var(--line);border-bottom:0}.account-identity{grid-column:1;grid-row:1}.account-row>.status-cell{grid-column:2;grid-row:1;justify-self:end}.usage-cell{grid-row:2;grid-column:1/-1}.capacity{grid-row:3;grid-column:1}.capacity strong{font-size:.875rem}.capacity small{display:inline;margin-left:10px}.account-row>.add-button{grid-column:2;grid-row:3}.panel-footer{padding:14px 20px;font-size:.75rem}.page-footer{flex-direction:column;gap:8px;margin-top:20px}.login-wrap{display:block;max-width:420px;margin:20px auto}.login-intro{display:none}.login-card{padding:28px 24px}.login-card>.muted{margin-bottom:22px}dialog{padding:22px}.summary-label{font-size:.8125rem}.history-item{padding:16px 20px}.reset-card .summary-foot{font-size:.75rem}.account-row progress{height:7px}}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}

.status.global_exhausted { color: #a32828; background: #fff0f0; }

.account-actions{display:flex;flex-direction:column;gap:6px;align-items:stretch}.reset-button{font-size:.75rem;color:#9b3d47;white-space:nowrap}@media(max-width:740px){.account-actions{grid-column:2;grid-row:3}}
