:root{font-family:Inter,"Segoe UI","Microsoft YaHei",sans-serif;color:#172033;background:#f3f6fb;font-synthesis:none;--primary:#3157d5;--primary-dark:#2545b2;--border:#dfe5ef;--muted:#68758b;--surface:#fff;--danger:#b42318}*{box-sizing:border-box}html,body{width:100%;height:100%;margin:0}body{overflow:hidden}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}[hidden]{display:none!important}.muted{color:var(--muted)}.login-page{min-height:100%;display:grid;place-items:center;padding:24px;background:radial-gradient(circle at 15% 15%,#dce7ff,transparent 40%),radial-gradient(circle at 85% 80%,#e5ddf9,transparent 35%),#f5f7fc}.login-card{width:min(430px,100%);padding:42px;background:#fff;border:1px solid #e5eaf3;border-radius:24px;box-shadow:0 24px 70px #263f7818}.brand-mark{display:grid;place-items:center;width:52px;height:52px;border-radius:16px;background:linear-gradient(135deg,#4169df,#623eb5);color:#fff;font-weight:800;letter-spacing:-1px}.brand-mark.small{width:34px;height:34px;border-radius:10px;font-size:13px}.eyebrow{margin:24px 0 5px;color:var(--primary);font-size:11px;font-weight:800;letter-spacing:2px}.login-card h1{margin:0;font-size:29px}.login-card>.muted{margin:10px 0 28px}.stack-form{display:grid;gap:17px}label{display:grid;gap:7px;font-size:13px;font-weight:650;color:#354159}label small{font-weight:400;color:var(--muted);line-height:1.5}input,select,textarea{width:100%;border:1px solid #ccd5e3;border-radius:9px;background:#fff;color:#172033;padding:10px 12px;outline:none}input:focus,select:focus,textarea:focus{border-color:#6684e2;box-shadow:0 0 0 3px #3157d515}textarea{resize:vertical;font-family:Consolas,monospace;font-size:12px}.primary,.ghost,.add-site,.icon-button,.dialog-close,.status-close{border:0;border-radius:8px;padding:9px 14px;font-weight:650}.primary{background:var(--primary);color:#fff}.primary:hover{background:var(--primary-dark)}.ghost{background:#fff;color:#3d4b63;border:1px solid var(--border)}.ghost:hover{background:#f5f7fb}.full-width{width:100%;padding:12px}.security-note{margin:20px 0 0;color:var(--muted);font-size:12px;line-height:1.7}.form-error{min-height:18px;margin:0;color:var(--danger);font-size:12px}.portal-shell{height:100%;display:flex;flex-direction:column}.app-header{height:58px;flex:0 0 58px;display:flex;align-items:center;justify-content:space-between;padding:0 20px;background:#fff;border-bottom:1px solid var(--border);z-index:2}.app-brand,.header-actions,.site-heading,.toolbar-actions,.sidebar-heading,.dialog-header,.dialog-footer{display:flex;align-items:center}.app-brand{gap:11px}.header-actions{gap:10px;font-size:13px}.workspace{display:flex;flex:1;min-height:0}.sidebar{width:248px;flex:0 0 248px;display:flex;flex-direction:column;background:#fff;border-right:1px solid var(--border);padding:18px 12px}.sidebar-heading{justify-content:space-between;padding:0 8px 12px;color:#59667b;font-size:12px;font-weight:750}.icon-button,.dialog-close,.status-close{background:transparent;color:#5f6d84;padding:5px 8px}.site-nav{display:grid;gap:5px;overflow-y:auto}.nav-item{display:grid;grid-template-columns:34px 1fr;gap:10px;align-items:center;width:100%;padding:11px 10px;text-align:left;border:1px solid transparent;border-radius:10px;background:transparent;color:#344158}.nav-item:hover{background:#f4f6fb}.nav-item.active{background:#eaf0ff;border-color:#d6e0ff;color:#2447b5}.nav-icon{display:grid;place-items:center;width:34px;height:34px;background:#edf1f8;border-radius:9px;font-size:15px}.nav-item.active .nav-icon{background:#d4dfff}.nav-copy{display:grid;gap:3px;min-width:0}.nav-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:700;font-size:13px}.nav-meta{font-size:11px;color:var(--muted)}.add-site{margin-top:12px;background:transparent;border:1px dashed #bdc9da;color:#506078}.add-site:hover{background:#f6f8fc}.sidebar-note{margin:auto 8px 0;padding-top:20px;color:#8a95a7;font-size:11px;line-height:1.6}.content-area{flex:1;min-width:0;min-height:0;display:flex;flex-direction:column;padding:16px 18px 18px}.content-toolbar{min-height:46px;display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.site-heading{gap:10px;min-width:0}.site-heading h1{margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:19px}.toolbar-actions{gap:8px;flex-shrink:0}.toolbar-actions button{font-size:12px}.badge{display:inline-flex;align-items:center;border-radius:99px;padding:4px 9px;background:#e9eef9;color:#52617a;font-size:11px;white-space:nowrap}.badge.shared{background:#e8f5ed;color:#187244}.status{position:relative;display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px;padding:9px 12px;border:1px solid #cbd9f4;border-radius:9px;background:#eef4ff;color:#34517e;font-size:12px;line-height:1.5}#statusText{flex:1}.status-action{flex-shrink:0;border:1px solid currentColor;border-radius:7px;padding:5px 9px;background:#ffffffc9;color:inherit;font-size:11px;font-weight:700}.status.success{background:#ecf8f0;border-color:#c7e7d2;color:#216e42}.status.error{background:#fff1f0;border-color:#f2cbc7;color:#9e2d24}.status-close{font-size:18px;line-height:1}.frame-host{position:relative;flex:1;min-height:0;overflow:hidden;background:#fff;border:1px solid #dbe2ed;border-radius:12px;box-shadow:0 5px 18px #233a6410}.site-frame{position:absolute;inset:0;width:100%;height:100%;border:0;background:#fff}.empty-state{height:100%;display:grid;place-content:center;text-align:center;color:var(--muted);padding:30px}.empty-state h2{margin:8px 0;color:#344159;font-size:20px}.empty-state p{margin:0;font-size:13px}.empty-icon{font-size:45px;color:#8295c8}.dialog{width:min(620px,calc(100vw - 32px));max-height:calc(100vh - 48px);padding:24px;border:1px solid #dfe5ef;border-radius:16px;box-shadow:0 25px 80px #17264c40;color:#172033}.dialog::backdrop{background:#14203a80;backdrop-filter:blur(2px)}.wide-dialog{width:min(850px,calc(100vw - 32px))}.dialog-header{justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:20px}.dialog-header h2{margin:0 0 6px;font-size:20px}.dialog-header p{margin:0;font-size:12px}.dialog-close{font-size:24px;line-height:1}.dialog-footer{justify-content:flex-end;gap:10px;margin-top:20px}.settings-list{display:grid;gap:10px;max-height:55vh;overflow:auto}.settings-empty{padding:30px;text-align:center;color:var(--muted);border:1px dashed var(--border);border-radius:10px}.settings-row{display:grid;grid-template-columns:1fr auto;gap:14px;padding:14px;border:1px solid var(--border);border-radius:11px}.settings-row h3{margin:0 0 5px;font-size:14px}.settings-row p{margin:0 0 6px;color:var(--muted);font-size:12px;word-break:break-all}.settings-meta{display:flex;gap:7px;flex-wrap:wrap}.settings-actions{display:flex;align-items:center;gap:5px;flex-wrap:wrap;justify-content:flex-end}.settings-actions button{padding:6px 9px;font-size:12px}.danger{color:var(--danger)}.site-form{display:grid;gap:16px}.form-grid{display:grid;gap:14px}.two-columns{grid-template-columns:1fr 1fr}.checkbox-label{display:flex;align-items:center;align-self:end;min-height:42px;gap:9px}.checkbox-label input{width:auto}.nested-section{display:grid;gap:15px;padding:16px;background:#f6f8fc;border:1px solid #e2e8f1;border-radius:11px}.nested-section h3{margin:0;font-size:14px}.credential-frame{position:fixed;width:2px;height:2px;left:-10000px;top:-10000px;border:0}.mobile-only{display:none}@media(max-width:800px){.sidebar{width:196px;flex-basis:196px}.header-actions .muted{display:none}.content-area{padding:10px}.toolbar-actions{gap:4px}.toolbar-actions button{padding:8px}.two-columns{grid-template-columns:1fr}.site-heading h1{font-size:16px}}@media(max-width:600px){.workspace{flex-direction:column}.sidebar{width:100%;flex:0 0 auto;padding:8px;border-right:0;border-bottom:1px solid var(--border)}.sidebar-heading,.sidebar-note,.add-site{display:none}.site-nav{display:flex;overflow-x:auto}.nav-item{flex:0 0 160px;padding:7px}.content-toolbar{align-items:flex-start}.site-heading{display:grid;gap:5px}.toolbar-actions{flex-wrap:wrap;justify-content:flex-end}.app-header{padding:0 10px}.app-brand strong{font-size:13px}.header-actions button{padding:7px;font-size:11px}.login-card{padding:30px 24px}.dialog{padding:18px}.settings-row{grid-template-columns:1fr}.settings-actions{justify-content:flex-start}}
