:root{
  --shell-rail:#10233d;
  --shell-rail-hover:#1a3558;
  --shell-accent:#13a391;
  --shell-accent-strong:#087c70;
  --shell-accent-soft:#e8f7f4;
  --shell-context:#f8fafc;
  --shell-border:#e3e9ef;
  --shell-canvas:#f3f6f8;
}

.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.layout{display:grid;grid-template-columns:72px 258px minmax(0,1fr);min-height:100vh;background:var(--shell-canvas)}

.app-rail{position:sticky;top:0;z-index:42;display:flex;flex-direction:column;align-items:center;height:100vh;padding:14px 10px;background:var(--shell-rail);color:#fff;border-right:1px solid rgba(255,255,255,.06)}
.rail-brand{display:grid;place-items:center;width:44px;height:44px;margin-bottom:20px;border-radius:13px;background:linear-gradient(145deg,#20b8a4,#0b8275);color:#fff;font-size:14px;font-weight:850;letter-spacing:.02em;box-shadow:0 9px 24px rgba(4,20,37,.34)}
.rail-nav{display:flex;flex-direction:column;align-items:center;gap:7px;width:100%;overflow:visible!important;padding:0!important}
.rail-link{position:relative;display:grid;place-items:center;width:44px;height:44px;padding:0!important;margin:0!important;border-radius:12px!important;color:#9fb2c9!important;transition:background .16s ease,color .16s ease,transform .16s ease}
.rail-link:hover{color:#fff!important;background:var(--shell-rail-hover)!important;transform:translateY(-1px)}
.rail-link.active{color:#fff!important;background:var(--shell-accent)!important;box-shadow:0 8px 22px rgba(19,163,145,.25)}
.rail-link .nav-icon{width:20px;height:20px}
.rail-link::after,.rail-user::after{position:absolute;left:54px;top:50%;z-index:60;display:block;padding:7px 10px;border-radius:8px;background:#0a1728;color:#fff;content:attr(data-label);font-size:12px;font-weight:650;line-height:1;white-space:nowrap;opacity:0;pointer-events:none;transform:translate(5px,-50%);transition:opacity .15s ease,transform .15s ease;box-shadow:0 8px 24px rgba(0,0,0,.18)}
.rail-link:hover::after,.rail-user:hover::after{opacity:1;transform:translate(0,-50%)}
.rail-badge{position:absolute;top:2px;right:0;display:none;align-items:center;justify-content:center;min-width:18px;height:18px;padding:0 4px;border:2px solid var(--shell-rail);border-radius:99px;background:#ff765f;color:#fff;font-size:9px;font-weight:850;line-height:1}
.rail-badge:not(:empty){display:block}
.rail-spacer{flex:1}
.rail-user{position:relative;display:grid;place-items:center;width:38px;height:38px;border:1px solid rgba(255,255,255,.16);border-radius:12px;background:#213b5c;color:#fff;font-size:13px;font-weight:800}

.sidebar{position:sticky;top:0;z-index:36;display:flex;flex-direction:column;height:100vh;padding:0;background:var(--shell-context);color:#223047;border-right:1px solid var(--shell-border);box-shadow:none}
.context-brand{display:flex;align-items:center;min-height:73px;padding:14px 18px;border-bottom:1px solid var(--shell-border)}
.context-brand .brand{flex:1;margin:0;padding:0;color:#17263d}
.context-brand .brand strong{font-size:15px;letter-spacing:-.01em}
.context-brand .brand small{margin-top:2px;color:#7b8796;font-size:10px}
.context-close{display:none;width:34px;height:34px;padding:0;border:0;border-radius:9px;background:#edf1f4;color:#4f5e70;cursor:pointer}
.context-heading{padding:20px 20px 12px}
.context-heading span,.context-heading strong{display:block}
.context-heading span{margin-bottom:5px;color:#8a96a5;font-size:10px;font-weight:750;letter-spacing:.11em;text-transform:uppercase}
.context-heading strong{color:#15263e;font-size:19px;letter-spacing:-.025em}
.compact-nav{display:block;flex:1;overflow:auto;padding:0 12px 20px!important;scrollbar-width:thin}
.mobile-primary-links{display:none}
.nav-section-label{margin:17px 10px 6px;color:#929dab;font-size:9px;font-weight:800;letter-spacing:.12em;text-transform:uppercase}
.sidebar nav a{display:flex;align-items:center;gap:10px;margin:2px 0;padding:8px 10px;border-radius:9px;color:#536174;font-size:12.5px;font-weight:580;line-height:1.25;transition:background .15s ease,color .15s ease}
.sidebar nav a:hover{background:#edf2f5;color:#16263d}
.sidebar nav a.active{background:var(--shell-accent-soft);color:var(--shell-accent-strong);box-shadow:inset 3px 0 0 var(--shell-accent);font-weight:720}
.sidebar nav a.active .badge{background:#fff;color:var(--shell-accent-strong)}
.sidebar .nav-icon{width:17px;height:17px}
.sidebar-footer{min-height:67px;margin:0;padding:12px 18px;border-top:1px solid var(--shell-border);background:#fff}
.sidebar-footer strong{color:#27364b;font-size:12.5px}
.sidebar-footer small{color:#8994a1;font-size:10px}
.sidebar-footer .icon-button{background:#edf2f4;color:#4b596b}

.main{min-width:0;background:var(--shell-canvas)}
.topbar{position:sticky;top:0;z-index:30;display:flex;align-items:center;gap:14px;min-height:73px;padding:12px 26px;background:rgba(255,255,255,.96);border-bottom:1px solid var(--shell-border);box-shadow:0 1px 8px rgba(24,43,68,.025);backdrop-filter:blur(12px)}
.topbar-heading{min-width:0}
.topbar-kicker{display:block;margin-bottom:2px;color:#8a96a5;font-size:9px;font-weight:800;letter-spacing:.1em;text-transform:uppercase}
.topbar h1{margin:0;color:#14243a;font-size:21px;line-height:1.18;letter-spacing:-.025em}
.topbar p{max-width:760px;margin:3px 0 0;color:#758191;font-size:11.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.top-actions{display:flex;align-items:center;gap:8px;margin-left:auto}
.top-actions .btn{min-height:36px}
.notification-center-toggle{border:1px solid #dfe6eb;background:#fff!important;color:#344255!important}
.mobile-menu{display:none;place-items:center;flex:0 0 auto;width:38px;height:38px;padding:0;border:1px solid #dce4e9;border-radius:10px;background:#fff;color:#314158;cursor:pointer}
.mobile-menu .nav-icon{width:19px;height:19px}
.shell-overlay{display:none}
.content{width:100%;max-width:1880px;margin:0 auto;padding:22px 26px 48px}
.demo-banner,.flash{margin:16px 26px 0}

@media(max-width:1180px){
  .layout{grid-template-columns:68px 228px minmax(0,1fr)}
  .app-rail{padding-right:8px;padding-left:8px}
  .rail-link::after,.rail-user::after{left:50px}
  .sidebar nav a{font-size:12px}
  .content{padding-right:20px;padding-left:20px}
  .topbar{padding-right:20px;padding-left:20px}
}

@media(max-width:850px){
  .layout{display:block;min-height:100vh}
  .app-rail{position:fixed;top:auto;right:0;bottom:0;left:0;z-index:55;display:flex;flex-direction:row;width:100%;height:60px;padding:7px 10px max(7px,env(safe-area-inset-bottom));border-top:1px solid rgba(255,255,255,.08);border-right:0}
  .rail-brand,.rail-spacer,.rail-user{display:none}
  .rail-nav{flex-direction:row;justify-content:space-around;gap:3px;width:100%;height:46px}
  .rail-link{width:42px;height:42px}
  .rail-link::after{display:none}
  .sidebar{position:fixed;top:0;bottom:0;left:-288px;z-index:70;width:min(282px,88vw);height:100vh;transition:left .2s ease;box-shadow:18px 0 45px rgba(15,31,51,.18)}
  .sidebar.open{left:0}
  .context-close{display:grid;place-items:center}
  .mobile-primary-links{display:block}
  .shell-overlay{position:fixed;inset:0;z-index:65;display:block;border:0;background:rgba(9,22,38,.42);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .2s ease,visibility .2s ease}
  .shell-overlay.open{opacity:1;visibility:visible;pointer-events:auto}
  .main{min-height:100vh;padding-bottom:60px}
  .mobile-menu{display:grid}
  .topbar{min-height:66px;padding:10px 14px}
  .topbar-kicker{display:none}
  .topbar h1{font-size:18px}
  .topbar p{max-width:45vw;font-size:10.5px}
  .top-actions{display:flex;margin-left:auto}
  .top-actions>.btn,.top-actions>form,.top-actions>a{display:none}
  .notification-center-toggle{width:38px;min-width:38px;padding:0}
  .notification-center-toggle span:not(.notification-total){display:none}
  .content{padding:16px 14px 38px}
  .demo-banner,.flash{margin:12px 14px 0}
}

@media(max-width:480px){
  .topbar p{display:none}
  .topbar{gap:10px}
  .content{padding-right:10px;padding-left:10px}
}
