/* sidebar.css — brand, navigation list, role switcher.
 *
 * A macOS source list: a translucent panel separated from the content by a
 * hairline rather than a shaded edge, and rows that are rounded pills the
 * selection fills, not stripes across the full width. */
.sidebar{width:250px;flex:0 0 auto;background:var(--glass-strong);-webkit-backdrop-filter:var(--blur);backdrop-filter:var(--blur);border-right:1px solid var(--line);display:flex;flex-direction:column;position:sticky;top:0;height:100vh;transition:width var(--t-slow)}
.app.collapsed .sidebar{width:66px}
.app.collapsed .sidebar .label,.app.collapsed .sidebar .eyebrow,.app.collapsed .sidebar .badge,.app.collapsed .sidebar .nav-group{display:none}
/* Collapsed to a rail the rows are square, so the glyph sits in the middle of
   the pill instead of being pushed left by padding meant for a label. */
.app.collapsed .nav-item,.app.collapsed .role-item{justify-content:center;padding-left:0;padding-right:0}

.brand{height:60px;display:flex;align-items:center;gap:11px;padding:0 16px;flex:0 0 auto}
.brand .mark{width:28px;height:28px;border-radius:var(--r-sm);background:var(--accent);color:var(--on-accent);display:flex;align-items:center;justify-content:center;font-size:13px;font-weight:700;flex:0 0 auto;box-shadow:var(--btn-glow)}
.brand .name{font-size:15px;font-weight:600;letter-spacing:-.02em;white-space:nowrap}

.nav{padding:8px 10px 16px;display:flex;flex-direction:column;gap:2px;flex:1;overflow-y:auto}
/* Section headings in a source list are small, spaced and quiet — a label for
   the group, never a heading competing with the rows under it. */
.eyebrow{padding:6px 10px 8px;font-size:11px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted)}
.nav-group{padding:16px 10px 6px;font-size:11px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted-2)}
.nav-group:first-of-type{padding-top:2px}

.nav-item{position:relative;overflow:hidden;display:flex;align-items:center;gap:11px;padding:8px 11px;border:0;border-radius:var(--r-md);cursor:pointer;text-align:left;background:transparent;color:var(--nav-ink);font-weight:500;font-size:13.5px;letter-spacing:-.01em;width:100%}
.nav-item:hover{background:var(--hover)}
.nav-item:active{transform:scale(.975)}
.nav-item.active{background:var(--accent-soft);color:var(--accent);font-weight:600}
.nav-item.active .ico{opacity:1}
/* The selected row already reads as selected from its fill; the marker is a
   short accent capsule at the leading edge, the way a sidebar shows which item
   the content column belongs to. */
.nav-item .bar{position:absolute;left:0;top:50%;width:3px;height:0;background:var(--accent);border-radius:0 var(--r-pill) var(--r-pill) 0;transform:translateY(-50%);opacity:0;transition:height var(--t-slow),opacity var(--t)}
.nav-item.active .bar{height:16px;opacity:1}
.nav-item .ico{width:18px;height:18px;flex:0 0 auto;display:flex;align-items:center;justify-content:center;opacity:.8}
.nav-item .label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* The count rides as a pill on the right of the row, matching the badge shape
   used everywhere else rather than inventing a second one. */
.nav-item .badge{margin-left:auto;background:var(--accent-badge);color:var(--accent);font-size:11.5px;font-weight:600;padding:1px 8px;border-radius:var(--r-pill);font-variant-numeric:tabular-nums}

.roles{padding:12px 10px 14px;border-top:1px solid var(--line-mid);flex:0 0 auto}
.role-item{display:flex;align-items:center;gap:11px;padding:8px 11px;border:0;border-radius:var(--r-md);cursor:pointer;text-align:left;width:100%;font-size:13px;letter-spacing:-.01em;background:transparent;color:var(--ink-3);font-weight:500}
.role-item:hover{background:var(--hover)}
.role-item:active{transform:scale(.975)}
.role-item.active{background:var(--hover);color:var(--ink);font-weight:600}
.role-item .chip{width:20px;height:20px;flex:0 0 auto;display:flex;align-items:center;justify-content:center;font-size:11px;font-weight:600;border-radius:var(--r-xs);background:var(--line-mid);color:var(--ink-3);transition:background-color var(--t),color var(--t)}
.role-item.active .chip{background:var(--accent);color:var(--on-accent)}
