/* ===== 移动端顶栏：统一显示效果 ===== */
@media (max-width: 768px) {
  /* 顶栏整体 */
  .sidebar {
    width: 100%;
    height: 56px;
    padding: 0 8px;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
  }
  /* 左侧 Logo 区：仅显示 Logo */
  .sidebar-header {
    flex-shrink: 0;
    padding: 0 4px;
    justify-content: center;
    gap: 6px;
  }
  .sidebar-header .logo { width: 40px; height: 40px; font-size: 20px; }
  .sidebar-header h2 { display: none; }
  /* 中间菜单：可左右滑动 */
  .sidebar-nav {
    flex: 1;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 0 6px;
    gap: 2px;
  }
  .sidebar-nav::-webkit-scrollbar { display: none; }
  .nav-item-wrap { flex-shrink: 0; position: relative; display: flex; align-items: center; }
  .nav-item-wrap.open .arrow { transform: rotate(180deg); }
  .nav-item { padding: 8px 12px; font-size: 13px; white-space: nowrap; }
  /* 子菜单默认隐藏（防止 hover 闪现）；带 .show 的面板才显示 */
  .nav-dropdown:not(.show) { display: none !important; }
  .nav-dropdown.show { display: block; }
  /* 右侧用户区：仅显示头像 */
  .sidebar-footer {
    flex-shrink: 0;
    padding: 0 4px;
    gap: 6px;
  }
  .sidebar-footer .user-avatar { width: 32px; height: 32px; font-size: 13px; }
  .sidebar-footer .user-info { display: none; }
  /* 子菜单：全宽下拉面板，避免被滚动容器裁剪 */
  .nav-dropdown {
    position: fixed;
    top: 56px;
    left: 8px;
    right: 8px;
    min-width: 0;
    max-height: 65vh;
    overflow-y: auto;
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
    padding: 6px;
  }
  .nav-dropdown .nav-sub-item { padding: 12px 16px; font-size: 14px; }
}
