* { box-sizing: border-box; }
html, body, #root {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100vh;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  -webkit-font-smoothing: antialiased;
}
/* 后台侧边导航：深色 + 顶部双 Tab（功能导航/系统设置）+ 分组手风琴 */
.admin-sider {
  width: 224px;
  min-width: 224px;
  height: 100vh;
  position: sticky;
  top: 0;
  background: #1d2129;
  display: flex;
  flex-direction: column;
  color: #c9ced9;
  overflow: hidden;
}

.as-brand {
  height: 58px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 18px;
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  letter-spacing: .5px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.as-brand .as-logo {
  width: 28px; height: 28px; border-radius: 8px;
  background: linear-gradient(135deg,#3b82f6,#2563eb);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; color: #fff;
}

/* 顶部双 Tab */
.as-tabs {
  display: flex;
  gap: 8px;
  padding: 12px 12px 4px;
}
.as-tabs button {
  flex: 1;
  height: 38px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: #9aa1af;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.as-tabs button:hover { color: #e5e8ef; }
.as-tabs button.active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 4px 12px rgba(37,99,235,.35);
}

/* 菜单滚动区 */
.as-menu {
  flex: 1;
  overflow-y: auto;
  padding: 8px 10px 16px;
}
.as-menu::-webkit-scrollbar { width: 6px; }
.as-menu::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 3px; }

.as-group { margin-bottom: 2px; }
.as-group-head {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  padding: 0 10px;
  border-radius: 8px;
  cursor: pointer;
  color: #e5e8ef;
  font-size: 14px;
  font-weight: 600;
  user-select: none;
}
.as-group-head:hover { background: rgba(255,255,255,.05); }
.as-group-head .as-g-icon {
  font-size: 16px; color: #aab2c0; display: flex;
}
.as-group-head .as-g-title { flex: 1; }
.as-group-head .as-g-arrow {
  font-size: 10px; color: #747c8c; transition: transform .2s;
}
.as-group.open .as-g-arrow { transform: rotate(90deg); }

.as-group-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 6px;
  padding: 4px 6px 8px;
}
.as-item {
  display: flex;
  align-items: center;
  height: 34px;
  padding: 0 9px;
  border-radius: 8px;
  color: #aab2c0;
  font-size: 12.5px;
  cursor: pointer;
  position: relative;
  white-space: nowrap;
  overflow: hidden;
}
.as-item:hover { background: rgba(255,255,255,.05); color: #e5e8ef; }
.as-item.active {
  background: #2563eb;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(37,99,235,.3);
}
.as-item .as-badge {
  margin-left: auto;
  min-width: 19px; height: 19px; padding: 0 5px;
  border-radius: 10px;
  background: #ef4444;
  color: #fff; font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
/* 仅 1 个子项时占满整行（如工作台） */
.as-group-body:has(.as-item:only-child) { grid-template-columns: 1fr; }

/* 系统设置（平铺，带图标） */
.as-sys-item {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  padding: 0 12px;
  border-radius: 8px;
  color: #aab2c0; font-size: 13.5px; cursor: pointer;
}
.as-sys-item:hover { background: rgba(255,255,255,.05); color: #e5e8ef; }
.as-sys-item .as-sys-icon { font-size: 16px; display:flex; }
.as-sys-item.active { background: #2563eb; color: #fff; font-weight: 600;
  box-shadow: 0 3px 10px rgba(37,99,235,.3); }
