/* AV Credit — adapted from the supplied Stitch master design, 2026-10-18.
   Presentation only: real routes, permissions, balances and form submissions remain authoritative. */
:root{--primary:#635bff;--primary-soft:#f0efff;--ink:#0a2540;--muted:#425466;--line:#e2e8f0;--sidebar-width:256px;--aventis-cobalt:#635bff;--aventis-cobalt-soft:#f0efff;--aventis-cobalt-line:#ddd9ff}
html body{background:#f6f9fc;color:#0a2540;font-family:Inter,system-ui,-apple-system,sans-serif;font-size:14px;line-height:1.5}
.app-shell[data-workspace]{--workspace-accent:#635bff;--workspace-soft:#f0efff;--workspace-line:#ddd9ff}
.app-shell .main{background:#f6f9fc}
.app-shell .topbar{height:64px;background:#fff;border-bottom:1px solid #e2e8f0}
.app-shell .content{max-width:1600px;margin:0 auto;padding:28px 32px 48px}
.app-shell .sidebar{background:#fff;border-color:#e2e8f0}
.app-shell .brand-wrap{min-height:80px}.brand-home .brand-symbol{color:#635bff}
.app-shell .side-nav a{min-height:48px;border-radius:8px;font-size:13px}
.app-shell .side-nav a.active{background:#f0efff;color:#4f46e5}
.app-shell .side-nav .nav-icon{background:#f0efff;color:#635bff}
.app-shell .sidebar-footer{border-top:1px solid #e2e8f0}
.app-shell .top-avatar,.app-shell .user-avatar{background:#f0efff;color:#4f46e5}
.app-shell .page-heading-row{background:transparent;border:0;padding:0;margin-bottom:20px}
.app-shell .page-heading{font-size:20px;font-weight:600;color:#0a2540}
.app-shell :is(h1,h2,h3){color:#0a2540}
.app-shell :is(.panel,.premium-panel,.monitor-panel,.work-panel,.work-card,.workspace-panel,.workspace-app){background:#fff;border:1px solid #e2e8f0;border-radius:12px;box-shadow:0 2px 8px rgb(10 37 64 / 3%)}
.app-shell .content :is(.monitor-panel,.work-panel){padding:24px}
.app-shell :is(.btn,button[type=submit],.monitor-workspace .btn){min-height:48px;padding:11px 16px;border-radius:8px;font-size:13px;font-weight:600;display:inline-flex;align-items:center;justify-content:center;gap:8px}
.app-shell :is(.btn.primary,.btn-primary,button.primary){background:#635bff;border-color:#635bff;color:#fff}
.app-shell :is(.btn.primary,.btn-primary,button.primary):hover{background:#4f46e5;border-color:#4f46e5}
.app-shell :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea){min-height:48px;border-radius:8px;border-color:#e2e8f0;font-size:14px;max-width:100%;box-sizing:border-box}
.app-shell :is(input[type=checkbox],input[type=radio]){accent-color:#635bff}
.app-shell :is(a,button,input,select,textarea):focus-visible{outline:3px solid #635bff;outline-offset:3px}
.app-shell :is(.monitor-navigation,.monitor-tabs){overflow-x:auto;flex-wrap:nowrap}
.app-shell :is(.monitor-navigation,.monitor-tabs) a{min-height:48px;display:inline-flex;align-items:center;white-space:nowrap;padding:8px 12px}
.app-shell :is(table,.numeric,.monitor-kpis strong){font-variant-numeric:tabular-nums}
.app-shell .monitor-table{overflow-x:auto;max-width:100%}
.app-shell .monitor-table th{background:#f6f9fc;color:#425466;font-size:12px}
.app-shell .monitor-table :is(th,td){padding:14px 16px}
.app-shell .monitor-table th:first-child{position:sticky;left:0;z-index:1}
.app-shell .monitor-kpis{gap:16px}
.app-shell .monitor-kpis>div{background:#fff;border:1px solid #e2e8f0;border-radius:12px;padding:20px}
.app-shell .monitor-kpis strong{font-size:32px;font-weight:700;letter-spacing:-.8px}
.app-shell .workspace-head{padding:24px;background:#fff;border:1px solid #e2e8f0;border-radius:12px}
.app-shell .workspace-head h1{font-size:24px;letter-spacing:-.5px}
.app-shell .workspace-eyebrow{color:#635bff;font-size:11px}
.app-shell .workspace-apps{gap:16px;grid-template-columns:repeat(auto-fit,minmax(245px,1fr))}
.app-shell .workspace-app{padding:24px;min-height:192px}
.app-shell .workspace-app-icon{width:48px;height:48px;background:#f0efff;color:#635bff;border-radius:12px}
.app-shell .workspace-app h2{font-size:15px}.app-shell .workspace-app p{font-size:13px;color:#425466}
.app-shell .workspace-app-open{color:#4f46e5;font-size:12px}
.app-shell .workspace-app:hover{border-color:#635bff;box-shadow:0 6px 20px rgb(99 91 255 / 9%)}
.app-shell .workspace-meta span{background:#f0efff;color:#4f46e5}
.message.error,.app-shell .errorlist{color:#991b1b}.message.error{background:#fef2f2;border-color:#fecaca}
.message.warning{background:#fffbeb;color:#92400e;border-color:#fde68a}
.message.success{background:#ecfdf5;color:#065f46;border-color:#a7f3d0}
.stitch-mobile-nav{display:none}
@media(max-width:900px){
 .app-shell .content{padding:20px 16px calc(112px + env(safe-area-inset-bottom,0px))}
 .app-shell .topbar{padding:0 16px;gap:12px}
 .app-shell .top-user>div:last-child{display:none}
 .app-shell .content :is(.monitor-panel,.work-panel){padding:16px}
 .app-shell .monitor-kpis strong{font-size:24px}
 .app-shell .workspace-head{padding:16px}.app-shell .workspace-head h1{font-size:20px;overflow-wrap:anywhere}
 .app-shell .workspace-apps{grid-template-columns:repeat(2,minmax(0,1fr))}
 .app-shell .workspace-app{min-height:184px;padding:16px}
 .js-shell .mobile-menu,.js-shell .sidebar-close{width:48px;height:48px;flex-basis:48px}
 .stitch-mobile-nav{position:fixed;inset:auto 0 0;z-index:40;display:flex;align-items:stretch;justify-content:space-around;background:#fff;border-top:1px solid #e2e8f0;min-height:64px;padding:0 8px env(safe-area-inset-bottom,0px)}
 .stitch-mobile-nav a{display:flex;flex:1;min-width:0;min-height:64px;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:6px 4px;color:#425466;text-decoration:none;font-size:11px;text-align:center;line-height:1.3}
 .stitch-mobile-nav a[aria-current=page]{color:#4f46e5;background:#f0efff;border-radius:8px}
 .stitch-mobile-nav svg{width:22px;height:22px}
 body.menu-open .stitch-mobile-nav{visibility:hidden}
}
@media(max-width:420px){.app-shell .workspace-apps{grid-template-columns:minmax(0,1fr)}.app-shell .global-search{min-width:0}.app-shell .global-search input{width:100%;min-width:0}}
@media(prefers-reduced-motion:reduce){.app-shell *{scroll-behavior:auto;transition:none!important}}
@media print{.stitch-mobile-nav{display:none!important}.app-shell .main{background:#fff}.app-shell .content{padding:0}.app-shell .monitor-table{overflow:visible}}

.stitch-mobile-brand{display:none}
@media(max-width:900px){.app-shell .topbar{height:auto;min-height:112px;flex-wrap:wrap;padding-top:8px;padding-bottom:8px;gap:4px 12px}.stitch-mobile-brand{display:flex;flex:1;min-width:0;flex-direction:column;text-decoration:none}.stitch-mobile-brand span{color:#635bff;font-size:11px;font-weight:700;letter-spacing:.08em}.stitch-mobile-brand strong{color:#0a2540;font-size:15px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.app-shell .global-search{order:4;flex-basis:100%;max-width:none}.app-shell .top-user{margin-left:auto}}
/* Explicit rail foregrounds override legacy dark-navigation selectors. */
.app-shell .sidebar .side-nav a{color:#425466}
.app-shell .sidebar .side-nav a:hover,.app-shell .sidebar .side-nav a.active{color:#4f46e5;background:#f0efff}
.app-shell .sidebar .brand-home,.app-shell .sidebar .brand,.app-shell .sidebar .sidebar-user strong{color:#0a2540}
.app-shell .sidebar .brand-sub,.app-shell .sidebar .sidebar-user span,.app-shell .sidebar .app-version,.app-shell .sidebar .logout-button{color:#425466}
body.login-page{background:#f6f9fc}.login-page .login-card{background:#fff;border:1px solid #e2e8f0;border-radius:16px;box-shadow:0 8px 32px rgb(10 37 64 / 6%)}
.login-page .login-card .btn.primary{background:#635bff;border-color:#635bff;min-height:48px;border-radius:8px;color:#fff}.login-page .login-card input{min-height:48px;border-radius:8px}.login-page .login-card .brand-mark{background:#635bff;color:#fff}
