:root{
  --sidebar-w: 248px;
  --brand: #ff902f;
  --brand-2: #3d5ee1;
  --ink: #1f2937;
  --muted: #6b7280;
  --bg: #f6f7fb;
}
*{box-sizing:border-box}
body{background:var(--bg);color:var(--ink);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif}

/* Topbar */
.topbar{background:#fff;position:sticky;top:0;z-index:1030;height:60px}
.avatar-circle{width:38px;height:38px;border-radius:50%;background:var(--brand-2);color:#fff;
  display:inline-flex;align-items:center;justify-content:center;font-weight:700}

/* Layout */
.layout{display:flex;min-height:calc(100vh - 60px)}
.sidebar{width:var(--sidebar-w);background:#fff;border-right:1px solid #eceef3;
  position:sticky;top:60px;height:calc(100vh - 60px);flex:0 0 var(--sidebar-w);
  display:flex;flex-direction:column}
.sidebar-nav{flex:1;min-height:0;overflow-y:auto;padding:10px 0}
.sidebar-nav::-webkit-scrollbar{width:7px}
.sidebar-nav::-webkit-scrollbar-thumb{background:#d7dbe6;border-radius:4px}
.content{flex:1;min-width:0}

/* group heading toggle */
.nav-group-toggle{width:calc(100% - 20px);margin:4px 10px;border:0;background:transparent;
  display:flex;align-items:center;justify-content:space-between;gap:.5rem;
  padding:.55rem .85rem;border-radius:8px;color:#374151;font-weight:600;font-size:.82rem;
  text-transform:uppercase;letter-spacing:.03em;cursor:pointer}
.nav-group-toggle:hover{background:#f1f3f9}
.nav-group-toggle .ng-left{display:flex;align-items:center;gap:.55rem}
.nav-group-toggle .ng-caret{transition:transform .18s ease;font-size:.8rem}
.nav-group.open > .nav-group-toggle .ng-caret{transform:rotate(180deg)}
.nav-group-items{display:none;padding:2px 0 6px}
.nav-group.open > .nav-group-items{display:block}

.sidebar .nav-link{color:#4b5563;border-radius:8px;margin:2px 10px;padding:.55rem .85rem;
  display:flex;align-items:center;gap:.65rem;font-weight:500;text-decoration:none}
.nav-group-items .nav-link{margin-left:18px}
.sidebar .nav-link.solo{font-weight:600}
.sidebar .nav-link i{font-size:1.05rem}
.sidebar .nav-link:hover{background:#f1f3f9;color:var(--brand-2)}
.sidebar .nav-link.active{background:var(--brand-2);color:#fff}
.sidebar-footer{border-top:1px solid #eef0f5}

/* Cards / stats */
.card{border:none;border-radius:14px;box-shadow:0 1px 3px rgba(16,24,40,.06)}
.stat-card .icon{width:48px;height:48px;border-radius:12px;display:inline-flex;
  align-items:center;justify-content:center;font-size:1.3rem;color:#fff}
.stat-card h3{font-weight:700;margin:0}
.bg-soft-blue{background:#3d5ee1}
.bg-soft-green{background:#22c55e}
.bg-soft-orange{background:#ff902f}
.bg-soft-red{background:#ef4444}

.badge-status{font-weight:600}
.table>:not(caption)>*>*{padding:.7rem .75rem}
.page-title{font-weight:700}

/* Login */
.login-wrap{min-height:100vh;display:flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#3d5ee1,#7b8ff0)}
.login-card{width:100%;max-width:400px;border-radius:16px}

/* Mobile */
@media (max-width: 991.98px){
  .sidebar{position:fixed;left:0;top:60px;z-index:1029;transform:translateX(-100%);
    transition:transform .2s ease}
  .sidebar.open{transform:translateX(0)}
}
.stat-link{transition:transform .12s ease, box-shadow .12s ease; cursor:pointer}
.stat-link:hover{transform:translateY(-2px); box-shadow:0 8px 20px rgba(2,6,23,.08)}
