.sidebar {
  position: fixed; inset: 8px auto 8px 8px; z-index: 20; width: 56px;
  display: flex; flex-direction: column; gap: 18px; padding: 5px;
  background: transparent; border: 1px solid transparent; border-radius: var(--radius-sheet); overflow: hidden;
}
.brand { display: grid; place-items: center; width: 44px; height: 40px; flex-shrink: 0; border-radius: var(--radius); }
.brand img { width: 32px; height: 32px; object-fit: contain; }
.brand:hover { opacity: .8; }
.sidebar-content { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.nav-item { position: relative; display: grid; place-items: center; width: 44px; min-height: 42px; padding: 0; margin-bottom: 3px; border-radius: var(--radius-control); color: var(--muted); }
.nav-item > .icon { justify-self: center; width: 18px; height: 18px; }
.nav-item:hover { background: #e2e7e3; color: var(--ink); }
/* The current page is marked with an ink tab on the rail edge, not only a tint. */
.nav-item.active, .nav-item.selected { background: var(--paper); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.nav-item.active::before, .nav-item.selected::before { content: ''; position: absolute; left: -5px; top: 10px; bottom: 10px; width: 3px; border-radius: 0 2px 2px 0; background: var(--ink); }
.sidebar-companies { display: flex; flex-direction: column; flex: 1; min-height: 0; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.sidebar-companies > button { flex-shrink: 0; }
.company-nav { min-height: 0; overflow: hidden auto; scrollbar-width: thin; }
.company-nav-item .company-avatar { justify-self: center; }
.sidebar-bottom { flex-shrink: 0; padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--line); }
@media (max-width: 760px) {
  .sidebar { inset: 6px auto 6px 4px; width: 48px; gap: 14px; padding: 1px; }
  .brand img { width: 30px; height: 30px; }
  .nav-item.active::before, .nav-item.selected::before { left: -1px; }
}
