:root{color-scheme:light;--accent:#f59e0b;--accent-hover:#dd8703;--accent-soft:#fff4d6;--page:#f3f4f6;--panel:#fff;--panel-soft:#f8f9fb;--border:#e4e7ec;--border-soft:#edf0f4;--text:#303747;--muted:#858c9b;--sidebar:#15171c;--sidebar-surface:#202329;--sidebar-text:#c5ccd8;--sidebar-muted:#8d95a6;--danger:#dc2626;--success:#059669;--shadow:0 18px 44px rgba(61,67,84,.08);--nav-height:54px;--sidebar-width:260px;font-family:Arial,Helvetica,sans-serif}
*{box-sizing:border-box}html,body{min-height:100%;margin:0}body{background:var(--page);color:var(--text);font-size:14px}.hidden{display:none!important}button,input,select,textarea{font:inherit}button{cursor:pointer}.eyebrow{margin:0;color:var(--accent);font-size:11px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}.muted{color:var(--muted)}
.auth-layout{display:grid;min-height:100vh;grid-template-columns:minmax(360px,42%) 1fr;background:var(--panel)}.auth-brand{display:flex;flex-direction:column;justify-content:space-between;padding:52px;background:linear-gradient(145deg,#15171c 0%,#23262d 65%,#342e22 100%);color:#fff}.auth-logo,.auth-mobile-logo{display:flex;align-items:center;gap:10px;font-weight:900;letter-spacing:.05em}.auth-logo span,.auth-mobile-logo span,.brand>span{display:inline-flex;width:34px;height:34px;align-items:center;justify-content:center;border-radius:8px;background:var(--accent);color:#fff;font-size:20px}.auth-brand-copy{max-width:520px}.auth-brand-copy h1{margin:10px 0 16px;font-size:44px;line-height:1.08}.auth-brand-copy>p:last-child{color:#c5ccd8;font-size:17px;line-height:1.6}.auth-brand>small{color:#858c9b;font-weight:700}.auth-panel{display:flex;align-items:center;justify-content:center;padding:32px}.auth-card{width:min(100%,440px)}.auth-mobile-logo{display:none;margin-bottom:28px}.auth-tabs{display:flex;gap:5px;margin-bottom:32px;padding:4px;border-radius:9px;background:#f2f3f5}.auth-tab{flex:1;border:0;border-radius:7px;background:transparent;color:var(--muted);font-size:12px;font-weight:800;padding:10px}.auth-tab.active{background:#fff;color:var(--accent);box-shadow:0 3px 12px rgba(30,35,45,.08)}.auth-form{display:grid;gap:18px}.auth-form h2{margin:4px 0 0;font-size:28px}.form-intro{margin:8px 0 0;color:var(--muted);line-height:1.5}
.field{display:grid;gap:7px}.field>span{color:#606878;font-size:11px;font-weight:900;text-transform:uppercase}.field em{color:var(--danger);font-style:normal}.field small{color:var(--muted);font-size:11px}.field input,.field select,.field textarea{width:100%;min-width:0;height:42px;border:1px solid var(--border);border-radius:8px;background:var(--panel-soft);color:var(--text);outline:0;padding:0 12px}.field textarea{height:86px;padding-top:11px;resize:vertical}.field input:focus,.field select:focus,.field textarea:focus{border-color:var(--accent);background:var(--panel);box-shadow:0 0 0 3px rgba(245,158,11,.13)}.btn{display:inline-flex;min-height:40px;align-items:center;justify-content:center;gap:8px;border:1px solid var(--border);border-radius:8px;background:var(--panel);color:var(--text);font-size:13px;font-weight:800;padding:0 14px;transition:.16s}.btn:hover{border-color:var(--accent);color:var(--accent);transform:translateY(-1px)}.btn-primary{border-color:var(--accent);background:var(--accent);color:#fff;box-shadow:0 10px 22px rgba(245,158,11,.2)}.btn-primary:hover{background:var(--accent-hover);color:#fff}.btn-danger{color:var(--danger)}.btn-block{width:100%;min-height:44px}.qr-code{margin:auto;border:8px solid #fff;border-radius:8px}.secret-code{padding:12px;border-radius:8px;background:#202329;color:#ffd56b;text-align:center;overflow-wrap:anywhere}
.erp-shell{min-height:100vh}.topbar{position:fixed;inset:0 0 auto;z-index:90;display:flex;min-height:var(--nav-height);align-items:center;justify-content:space-between;border-bottom:1px solid #dbe1ea;background:#fff;box-shadow:0 10px 28px rgba(31,41,55,.08)}.topbar-start,.topbar-actions{display:flex;min-width:0;align-items:center}.brand{display:flex;width:176px;height:var(--nav-height);align-items:center;justify-content:center;gap:9px;color:#232733;letter-spacing:.04em}.brand>span{width:29px;height:29px;font-size:17px}.topbar-icon,.topbar-action{height:var(--nav-height);border:0;border-left:1px solid #edf0f5;background:transparent;color:#3d4658;font-weight:800}.topbar-icon{width:48px;font-size:17px}.mobile-menu{display:none}.topbar-icon:hover,.topbar-action:hover{background:var(--accent-soft);color:var(--accent)}.company-identity{display:flex;max-width:340px;min-height:38px;align-items:center;gap:9px;margin-left:12px;padding:5px 12px 5px 8px;overflow:hidden;border:1px solid #e4e9f1;border-radius:8px;background:linear-gradient(#fff,#f8fafc);color:var(--text);text-align:left}.company-symbol{display:inline-flex;width:25px;height:25px;align-items:center;justify-content:center;border-radius:7px;background:var(--accent-soft);color:var(--accent)}.company-identity>span:last-child{display:grid;min-width:0}.company-identity small{color:var(--muted);font-size:9px;font-weight:800;text-transform:uppercase}.company-identity strong{overflow:hidden;font-size:12px;text-overflow:ellipsis;white-space:nowrap}.topbar-actions{align-self:stretch}.topbar-action{display:flex;align-items:center;gap:7px;padding:0 13px}.topbar-action span{color:var(--accent)}.topbar-action b{max-width:210px;overflow:hidden;font-size:12px;text-overflow:ellipsis;white-space:nowrap}.exit-action,.exit-action span{color:var(--danger)}
.sidebar{position:fixed;top:var(--nav-height);bottom:0;left:0;z-index:80;display:flex;width:var(--sidebar-width);flex-direction:column;overflow:hidden;border-right:1px solid rgba(255,255,255,.07);background:var(--sidebar);box-shadow:18px 0 34px rgba(15,17,22,.16);color:var(--sidebar-text);transition:transform .2s}.sidebar-search{display:flex;min-height:40px;align-items:center;margin:14px;border:1px solid rgba(255,255,255,.09);border-radius:8px;background:var(--sidebar-surface);color:var(--sidebar-muted)}.sidebar-search>span{width:36px;text-align:center;font-size:20px}.sidebar-search input{width:100%;height:38px;border:0;background:transparent;color:#fff;font-size:13px;font-weight:700;outline:0}.sidebar-search input::placeholder{color:var(--sidebar-muted)}.sidebar-menu{flex:1;overflow-y:auto;padding:0 10px}.menu-home,.menu-parent,.menu-link{display:flex;width:100%;min-height:40px;align-items:center;gap:10px;border:0;border-radius:8px;background:transparent;color:var(--sidebar-text);font-size:13px;font-weight:800;text-align:left;text-decoration:none;padding:9px 10px}.menu-home:hover,.menu-parent:hover,.menu-link:hover,.menu-link.active{background:rgba(245,158,11,.13);color:#fff}.menu-icon{display:inline-flex;width:28px;height:28px;flex:0 0 28px;align-items:center;justify-content:center;border-radius:8px;background:rgba(255,255,255,.07);color:var(--accent)}.menu-group{margin:12px 10px 5px;color:var(--sidebar-muted);font-size:10px;font-weight:900;text-transform:uppercase}.menu-branch{margin:3px 0}.menu-parent:after{content:'›';margin-left:auto;color:var(--sidebar-muted);transition:transform .16s}.menu-branch.open>.menu-parent:after{transform:rotate(90deg)}.menu-children{display:none;margin:3px 0 7px 23px;padding-left:10px;border-left:1px solid rgba(245,158,11,.3)}.menu-branch.open>.menu-children{display:block}.menu-link{min-height:34px;color:#aeb6c5;font-size:12px;font-weight:700;padding:7px 9px}.menu-link:before{content:'';width:5px;height:5px;border-radius:50%;background:#ffd166}.sidebar-meta{display:flex;justify-content:space-between;margin:12px 14px 16px;padding:11px;border:1px solid rgba(255,255,255,.07);border-radius:8px;background:rgba(255,255,255,.03);color:var(--sidebar-muted);font-size:10px;font-weight:900}.sidebar-meta strong{color:#7dd3a7}.sidebar-scrim{display:none}.page-wrapper{min-height:100vh;margin-left:var(--sidebar-width);padding-top:var(--nav-height);transition:margin-left .2s}.module-main{height:calc(100vh - var(--nav-height));overflow:auto;background:var(--page);padding:14px}.sidebar-hidden .sidebar{transform:translateX(-100%)}.sidebar-hidden .page-wrapper{margin-left:0}
.menu-node{margin:3px 0}.menu-node>.menu-children{display:none}.menu-node.open>.menu-children{display:block}.menu-node.open>.menu-parent:after{transform:rotate(90deg)}.menu-root-button{text-transform:uppercase}.menu-level-two{margin:3px 0 7px 18px;padding:4px 0 4px 9px;border-left:1px solid rgba(245,158,11,.3);border-radius:0}.menu-subbranch{margin:1px 0}.menu-subparent{min-height:35px;color:#aeb6c5;font-size:12px;padding:7px 9px}.menu-level-three{margin:1px 0 5px 10px;padding-left:9px;border-left:1px solid rgba(255,255,255,.09)}.menu-level-three .menu-link{min-height:32px;padding:6px 9px}.menu-link:before{content:none}.menu-bullet{width:5px;height:5px;flex:0 0 5px;border-radius:50%;background:#ffd166}.menu-link .menu-bullet{width:4px;height:4px;flex-basis:4px;background:var(--sidebar-muted)}
.maintainer{display:flex;height:100%;min-height:0;flex-direction:column}.maint-panel{display:flex;flex:1;min-height:0;flex-direction:column;overflow:hidden;border:1px solid var(--border-soft);border-radius:9px;background:var(--panel);box-shadow:var(--shadow)}.maint-head{display:flex;align-items:center;justify-content:space-between;gap:16px;border-bottom:1px solid var(--border-soft);background:var(--panel-soft);padding:17px 18px}.maint-heading{display:flex;min-width:0;align-items:center;gap:12px}.maint-head-icon{display:inline-flex;width:42px;height:42px;flex:0 0 42px;align-items:center;justify-content:center;border-radius:8px;background:var(--accent-soft);color:var(--accent);font-size:19px}.maint-heading h1{margin:3px 0 0;font-size:19px}.maint-actions{display:flex;align-items:center;gap:8px}.table-wrap{flex:1;min-height:0;overflow:auto}.maint-table{width:100%;min-width:760px;border-collapse:collapse}.maint-table th{position:sticky;top:0;z-index:2;border-bottom:1px solid var(--border-soft);background:#f3f4f6;color:var(--muted);font-size:11px;font-weight:900;padding:13px 18px;text-align:left;text-transform:uppercase}.maint-table td{border-bottom:1px solid var(--border-soft);color:var(--text);font-size:13px;font-weight:700;padding:14px 18px;vertical-align:middle}.maint-table th:last-child,.maint-table td:last-child{text-align:right}.maint-table tbody tr:hover{background:var(--panel-soft)}.record{display:flex;min-width:0;align-items:center;gap:11px}.avatar{display:inline-flex;width:38px;height:38px;flex:0 0 38px;align-items:center;justify-content:center;border-radius:8px;background:var(--accent-soft);color:var(--accent);font-size:12px;font-weight:900}.record-copy{min-width:0}.record-copy strong,.record-copy small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.record-copy strong{font-weight:900}.record-copy small{margin-top:4px;color:var(--muted);font-size:12px}.tag,.status{display:inline-flex;min-height:28px;align-items:center;border-radius:999px;font-size:12px;font-weight:900;padding:6px 10px}.tag{background:var(--panel-soft);color:var(--muted)}.status-active{background:rgba(16,185,129,.12);color:var(--success)}.status-inactive{background:rgba(220,38,38,.1);color:var(--danger)}.row-actions{display:flex;justify-content:flex-end;gap:7px}.row-actions button{display:inline-flex;width:34px;height:34px;align-items:center;justify-content:center;border:1px solid var(--border);border-radius:8px;background:var(--panel);color:var(--muted);font-weight:900}.row-actions button:hover{border-color:var(--accent);color:var(--accent)}.row-actions .danger:hover{border-color:var(--danger);color:var(--danger)}.maint-footer{display:flex;align-items:center;justify-content:space-between;gap:14px;border-top:1px solid var(--border-soft);background:var(--panel-soft);color:var(--muted);font-size:12px;font-weight:800;padding:12px 18px}.empty{padding:40px!important;color:var(--muted)!important;text-align:center!important}
.modal{max-width:none;max-height:none;border:0;background:transparent;color:var(--text);padding:0}.modal::backdrop{background:rgba(15,23,42,.54);backdrop-filter:blur(2px)}.modal-box{width:min(92vw,600px);overflow:hidden;border-radius:10px;background:var(--panel);box-shadow:0 25px 75px rgba(15,23,42,.25)}.tenant-box{width:min(92vw,560px)}.modal-header{display:flex;align-items:center;justify-content:space-between;gap:16px;border-bottom:1px solid var(--border);background:var(--panel-soft);padding:16px 19px}.modal-header h2{margin:3px 0 0;font-size:19px}.icon-btn{display:inline-flex;width:34px;height:34px;align-items:center;justify-content:center;border:1px solid var(--border);border-radius:8px;background:var(--panel);color:var(--muted);font-size:22px}.modal-body{padding:20px}.modal-copy{margin:0 0 16px;color:var(--muted)}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.field-wide,.form-grid>.btn,.form-grid>.permissions-grid{grid-column:1/-1}.form-grid>.btn{justify-self:end;min-width:130px}.tenant-list{display:grid;gap:8px}.tenant-option{display:flex;width:100%;align-items:center;gap:12px;border:1px solid var(--border);border-radius:8px;background:var(--panel);color:var(--text);padding:12px;text-align:left}.tenant-option:hover{border-color:var(--accent);background:var(--accent-soft)}.tenant-option .company-symbol{flex:0 0 32px;width:32px;height:32px}.tenant-option span:last-child{display:grid}.tenant-option small{margin-top:3px;color:var(--muted)}.separator{display:flex;align-items:center;gap:10px;margin:20px 0;color:var(--muted);font-size:10px;font-weight:900;text-transform:uppercase}.separator:before,.separator:after{content:'';height:1px;flex:1;background:var(--border)}.permissions-grid{display:grid;max-height:240px;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;overflow:auto;padding:3px}.permissions-actions{display:flex;flex-wrap:wrap;gap:8px}.permissions-grid.permissions-list{grid-template-columns:minmax(0,1fr)}.check-field{display:flex;align-items:center;gap:8px;border:1px solid var(--border-soft);border-radius:7px;padding:9px;color:var(--text);font-size:12px}.check-field input{accent-color:var(--accent)}
.toast{position:fixed;top:68px;right:16px;z-index:200;max-width:390px;border-radius:9px;background:#059669;color:#fff;box-shadow:0 18px 45px rgba(15,23,42,.2);font-weight:800;padding:14px 17px}.toast.error{background:#dc2626}.onboarding{display:flex;min-height:100%;align-items:center;justify-content:center;padding:20px}.onboarding-card{width:min(100%,650px);overflow:hidden;border:1px solid var(--border);border-radius:10px;background:var(--panel);box-shadow:var(--shadow)}.onboarding-head{display:flex;align-items:center;gap:13px;border-bottom:1px solid var(--border);background:var(--panel-soft);padding:20px}.onboarding-head h1{margin:3px 0 0;font-size:23px}.onboarding-body{padding:24px}.onboarding-body>p{margin:0 0 22px;color:var(--muted);line-height:1.6}
.dark{color-scheme:dark;--page:#1f2229;--panel:#252932;--panel-soft:#20242d;--border:#3a404c;--border-soft:#343944;--text:#e5e7eb;--muted:#aeb6c5;--accent-soft:rgba(245,158,11,.15);--shadow:0 18px 44px rgba(0,0,0,.24)}.dark .topbar{border-color:#292d36;background:#17191f}.dark .brand,.dark .topbar-icon,.dark .topbar-action{color:#d9dee8}.dark .company-identity{border-color:#343944;background:#20242d;color:#fff}.dark .maint-table th{background:#20242d}.dark .auth-panel,.dark .auth-card{background:#1f2229}.dark .auth-tabs{background:#20242d}.dark .auth-tab.active{background:#2a2e37}
@media(max-width:1000px){.topbar-action b{display:none}.company-identity{max-width:250px}.auth-brand{padding:38px}.auth-brand-copy h1{font-size:36px}}
@media(max-width:767px){:root{--nav-height:54px}.auth-layout{display:block}.auth-brand{display:none}.auth-panel{min-height:100vh;padding:22px}.auth-mobile-logo{display:flex}.mobile-menu{display:block}.brand{width:auto;min-width:140px}.topbar-start{flex:1}.topbar-start>#sidebar-toggle{display:none}.company-identity{flex:1;max-width:none;margin-right:7px}.company-identity small{display:none}.topbar-actions{position:fixed;top:54px;left:0;right:0;height:44px;border-top:1px solid var(--border);background:var(--panel)}.topbar-action{height:44px;flex:1;justify-content:center}.sidebar{top:98px;transform:translateX(-100%)}.mobile-sidebar-open .sidebar{transform:translateX(0)}.sidebar-scrim{position:fixed;inset:98px 0 0;z-index:70;border:0;background:rgba(15,23,42,.45)}.mobile-sidebar-open .sidebar-scrim{display:block}.page-wrapper,.sidebar-hidden .page-wrapper{margin-left:0;padding-top:98px}.module-main{height:calc(100vh - 98px);padding:8px}.maint-head{align-items:flex-start;padding:14px}.maint-actions{flex-wrap:wrap}.maint-actions .btn span{display:none}.maint-footer{align-items:flex-start;flex-direction:column}.form-grid{grid-template-columns:1fr}.field-wide,.form-grid>.btn,.form-grid>.permissions-grid{grid-column:auto}.permissions-grid{grid-template-columns:1fr}.user-action{display:none}}

.onboarding{flex-wrap:wrap;gap:24px;align-content:center;align-items:flex-start}.tenant-access-card{margin-top:24px;padding:20px;border:1px solid var(--border);border-radius:10px;background:var(--panel-soft)}.tenant-access-card h3{margin:0 0 12px}.access-request-status{margin:0;color:var(--muted);line-height:1.6}.access-request-status:empty{display:none}
