*{box-sizing:border-box}body{margin:0;font-family:Arial,sans-serif;background:#f4f7fb;color:#1f2937}a{color:#2563eb;text-decoration:none}#root{min-height:100vh}.portal,.container{max-width:1440px;margin:0 auto;padding:24px}.split-layout{display:grid;grid-template-columns:minmax(360px,1fr) minmax(0,1.7fr);gap:16px;align-items:start}.left-panel,.right-panel{display:flex;flex-direction:column;gap:16px}.hero{background:linear-gradient(120deg,#0f172a,#1d4ed8);color:#fff;border-radius:10px;padding:24px}.hero-actions{display:flex;gap:10px;margin-top:16px}.primary-link,.ghost-link{display:inline-flex;align-items:center;justify-content:center;height:38px;border-radius:6px;padding:0 16px}.primary-link{background:#fff;color:#1d4ed8;font-weight:700}.ghost-link{border:1px solid rgba(255,255,255,.6);color:#fff}.card{background:#fff;border:1px solid #e5e7eb;border-radius:8px;padding:16px;margin-bottom:16px}.card h3{margin-top:0}.nav-card{position:sticky;top:16px}.muted{color:#6b7280;margin-top:-6px}.tree-panel{position:sticky;top:16px}.tree-group{margin-bottom:8px}.tree-toggle{width:100%;text-align:left;background:#eef2ff;color:#1f2937;border:1px solid #dbeafe;display:flex;align-items:center;gap:8px;font-weight:600;height:auto;padding:10px 12px;line-height:1.25}.tree-toggle strong{flex:1 1 auto;min-width:0;white-space:normal;overflow-wrap:anywhere}.tree-items{list-style:none;margin:8px 0 0;padding:0 0 0 12px}.tree-item{width:100%;text-align:left;background:#fff;color:#111827;border:1px solid #e5e7eb;margin-bottom:8px;display:flex;align-items:flex-start;gap:8px;height:auto;padding:10px 12px;line-height:1.25}.tree-title{flex:1 1 auto;min-width:0;white-space:normal;overflow-wrap:anywhere;word-break:break-word}.tree-item.active{background:#eff6ff;border-color:#93c5fd}.method{font-size:12px;padding:2px 6px;border-radius:4px;font-weight:700}.method-get{background:#dcfce7;color:#166534}.method-post{background:#dbeafe;color:#1d4ed8}.method-delete{background:#fee2e2;color:#b91c1c}.internal-entry{margin-top:12px;border-top:1px dashed #cbd5e1;padding-top:12px}.doc-head{display:flex;justify-content:space-between;align-items:center}.doc-path{font-family:Consolas,monospace;background:#f8fafc;border:1px solid #e2e8f0;border-radius:6px;padding:8px 10px}.json-block{margin:0;background:#0f172a;color:#e2e8f0;padding:12px;border-radius:8px;overflow-x:auto}.json-block.doc-code{width:100%;max-width:980px;margin-left:auto;margin-right:auto}.json-block.code-wrap{white-space:pre-wrap;overflow-wrap:anywhere}.entry-btn{display:block;width:100%;margin-bottom:10px;padding:10px 12px;border:1px solid #cbd5e1;border-radius:6px;background:#f8fafc;color:#1f2937}.compact-list{margin:0;padding-left:20px}.auth-wrap{min-height:calc(100vh - 60px);display:flex;align-items:center;justify-content:center}.auth-card{width:640px;max-width:90vw}.row,.grid{display:grid;gap:10px}.row{grid-template-columns:1fr 120px}.grid{grid-template-columns:repeat(4,1fr)}.admin-login-grid{display:grid;grid-template-columns:1fr 1fr 120px;gap:10px}input,button{height:38px;border-radius:6px;border:1px solid #cbd5e1;padding:0 10px}button{background:#2563eb;color:#fff;border:none;cursor:pointer}button:disabled{background:#94a3b8;cursor:not-allowed}table{width:100%;border-collapse:collapse;margin-top:12px}th,td{padding:10px;border-bottom:1px solid #e5e7eb;text-align:left}.actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}td.actions{min-width:320px}td.actions button{height:32px;padding:0 12px}.message{color:#b91c1c;font-weight:600}.header-row{display:flex;justify-content:space-between;align-items:center}.sub-text{color:#6b7280;margin-top:-6px;margin-bottom:16px}.footer{border-top:1px solid #dbe3f0;padding:10px 24px 20px;text-align:center}.auth-page{min-height:calc(100vh - 60px);display:flex;align-items:center;justify-content:center;padding:32px 24px;background:radial-gradient(900px 500px at 10% 10%,rgba(37,99,235,.2),transparent 55%),radial-gradient(900px 500px at 90% 90%,rgba(15,23,42,.1),transparent 55%),#f4f7fb}.auth-shell{width:min(980px,100%);display:grid;grid-template-columns:1fr 1fr;border-radius:14px;overflow:hidden;border:1px solid rgba(148,163,184,.35);box-shadow:0 18px 44px #0f172a1f;background:#fff}.auth-brand{padding:34px 32px;color:#ffffffeb;background:linear-gradient(135deg,#0f172a,#1d4ed8)}.auth-admin .auth-brand{background:linear-gradient(135deg,#111827,#2563eb)}.auth-partner .auth-brand{background:linear-gradient(135deg,#0f172a,#0ea5e9)}.brand-badge{display:inline-flex;align-items:center;gap:8px;height:30px;padding:0 12px;border-radius:999px;background:#ffffff1f;border:1px solid rgba(255,255,255,.24);font-weight:700;letter-spacing:.4px}.auth-brand h1{margin:16px 0 10px;font-size:28px;line-height:1.2}.brand-subtitle{margin:0 0 16px;color:#ffffffd9;line-height:1.6}.brand-list{margin:0;padding-left:18px;color:#ffffffd9;line-height:1.8}.auth-form.card{margin:0;border:0;border-radius:0;padding:32px}.auth-form h2{margin:0 0 8px;font-size:20px}.auth-form-grid{display:grid;gap:12px;margin-top:14px}.field label{display:block;font-weight:700;font-size:13px;margin-bottom:8px;color:#0f172a}.field input{width:100%}.password-wrap{display:grid;grid-template-columns:1fr auto;gap:10px;align-items:center}.icon-btn{height:38px;padding:0 12px;border-radius:8px;border:1px solid #cbd5e1;background:#f8fafc;color:#0f172a;font-weight:700;cursor:pointer}.primary-btn{width:100%;height:42px;border-radius:10px;font-weight:800}.alert{margin-top:14px;border-radius:10px;padding:10px 12px;border:1px solid transparent;font-weight:700}.alert-error{color:#991b1b;background:#fef2f2;border-color:#fecaca}.stats-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.stat{border:1px solid #e5e7eb;background:#f8fafc;border-radius:10px;padding:12px}.stat-label{color:#64748b;font-weight:700;font-size:13px}.stat-value{margin-top:6px;font-size:22px;font-weight:900;color:#0f172a}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background:#0f172a8c;display:flex;align-items:center;justify-content:center;padding:22px;z-index:50}.modal.card{width:min(560px,100%);border-radius:12px;box-shadow:0 22px 60px #0f172a59}.modal.card.modal-wide{width:min(760px,100%)}.modal.card.modal-xwide{width:min(1200px,96vw);max-height:92vh;overflow:hidden}.modal-xwide .modal-body{overflow:auto;max-height:calc(92vh - 72px)}.modal-xwide .table-scroll{max-height:min(62vh,640px);overflow:auto}.log-row-toggle{width:40px;text-align:center}.log-toggle-btn{width:28px;height:28px;padding:0;border:1px solid #cbd5e1;border-radius:6px;background:#fff;color:#0f172a;font-size:14px;line-height:1;cursor:pointer}.log-row-expanded td{background:#f8fafc}.log-detail-row td{background:#f1f5f9;padding:0;border-top:none}.log-detail-panel{padding:12px 14px 14px;display:grid;gap:12px}.log-detail-block h4{margin:0 0 8px;font-size:13px;color:#334155}.log-detail-pre{max-height:220px;overflow:auto;font-size:12px;line-height:1.45}.table-scroll{overflow-x:auto}.modal-head{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:4px 0 10px}.modal-head h2{margin:0;font-size:18px}.modal-body{display:grid;gap:12px}.check-row{display:flex;align-items:center;gap:10px}.check-row input{height:16px;width:16px;padding:0}.check-row label{font-weight:700;color:#0f172a;font-size:13px}.modal-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:6px}.ghost-btn{background:#f1f5f9;color:#0f172a;border:1px solid #cbd5e1}.code-row{display:flex;align-items:center;gap:10px}.code-row code{display:inline-block;padding:4px 8px;border-radius:8px;border:1px solid #e2e8f0;background:#f8fafc;font-family:Consolas,monospace;word-break:break-all}.copy-btn{height:32px;padding:0 10px;border-radius:8px;border:1px solid #cbd5e1;background:#fff;color:#0f172a;font-weight:800;cursor:pointer}.usage-head{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap}.usage-chart{width:100%;overflow:hidden;border:1px solid #e2e8f0;border-radius:8px;background:#fff;padding:10px}.usage-chart svg{display:block;width:100%;height:auto}.quota-grid{display:grid;grid-template-columns:repeat(4,minmax(160px,1fr));gap:12px;margin-top:10px}.quota-control-grid{grid-template-columns:repeat(auto-fit,minmax(220px,280px));justify-content:start}.quota-control-item{display:flex;flex-direction:column;gap:10px}.quota-control-actions button{height:32px;padding:0 10px;border-radius:8px;font-size:12px}.quota-item{border:1px solid #e2e8f0;background:#f8fafc;border-radius:12px;padding:12px}.quota-item-on{border-color:#22c55e59;background:#22c55e0f}.quota-item-off{border-color:#ef44444d;background:#ef44440f}.quota-status-row{margin-top:-4px;margin-bottom:8px}.quota-status{display:inline-flex;align-items:center;height:22px;padding:0 8px;border-radius:999px;font-weight:800;font-size:12px;border:1px solid transparent}.quota-status-on{color:#166534;background:#22c55e24;border-color:#22c55e40}.quota-status-off{color:#991b1b;background:#ef444424;border-color:#ef444433}.quota-title{font-size:13px;color:#334155;font-weight:800;margin-bottom:8px}.quota-item-head{display:flex;align-items:center;justify-content:space-between;gap:10px}.quota-item-head .quota-title{margin-bottom:0}.switch{position:relative;display:inline-block;width:44px;height:24px;flex:0 0 auto}.switch input{opacity:0;width:0;height:0}.switch-slider{position:absolute;cursor:pointer;top:0;right:0;bottom:0;left:0;background:#cbd5e1;transition:background .2s ease;border-radius:999px;border:1px solid rgba(15,23,42,.12)}.switch-slider:before{position:absolute;content:"";height:18px;width:18px;left:3px;top:50%;transform:translateY(-50%);background:#fff;transition:transform .2s ease;border-radius:999px;box-shadow:0 1px 2px #0f172a2e}.switch input:checked+.switch-slider{background:#22c55e}.switch input:checked+.switch-slider:before{transform:translate(20px,-50%)}.switch input:disabled+.switch-slider{cursor:not-allowed;opacity:.6}.quota-metrics{display:flex;flex-direction:column;gap:6px}.quota-metric{display:flex;justify-content:space-between;align-items:baseline;gap:10px;font-size:12px;color:#475569}.quota-metric strong{font-size:14px;color:#0f172a}@media (max-width: 960px){.split-layout,.quota-grid{grid-template-columns:1fr}.nav-card,.tree-panel{position:static}.auth-shell{grid-template-columns:1fr}.auth-brand{padding:26px 22px}.auth-form.card{padding:22px}.stats-grid{grid-template-columns:1fr}}
