/* Sidebar Sections and their drag grips. The drag look itself is pointer-drag.css (shared); this file maps the app theme onto its tokens
   and styles only what is the sidebar's own. */
#left-sidebar { --paper: var(--surface); --blue: var(--accent); --ink: var(--text); --ink-3: var(--text-dim); --pl-r: 8px; --pd-shadow: 0 12px 30px var(--menu-shadow-color); --sec-bar-bg: color-mix(in srgb, var(--text) 7%, transparent); }
.pd-lifted.sidebar-section > .sidebar-section-entries { display: none !important; }
.pd-lifted.team-entry-wrapper .team-nested-members { display: none !important; }
.pd-lifted .nlc-grip { opacity: 1; }
.pd-lifted .session-menu-btn { display: none; }
.nlc-grip { touch-action: none; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 16px; height: 30px; display: flex; align-items: center; justify-content: center; padding: 0; border: 0; border-radius: 5px; background: transparent; color: var(--ink-3); cursor: grab; opacity: 0; transition: opacity .12s ease-out, background-color .12s ease-out, color .12s ease-out; }
.nlc-grip svg { width: 8px; height: 13px; }
.team-entry:hover .nlc-grip, .session-entry:hover > .nlc-grip, .sidebar-section-header:hover .nlc-grip, .nlc-grip:focus-visible { opacity: 1; }
.nlc-grip:hover, .nlc-grip:focus-visible { color: var(--ink); background: var(--menu-item-hover-bg); }
.nlc-grip:active { cursor: grabbing; }
.nlc-grip:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.sidebar-section-header .nlc-grip { position: static; transform: none; width: 22px; height: 22px; flex: none; border-radius: 6px; }
.section-header-action { display: flex; align-items: center; gap: var(--space-1); width: auto; }
@media (hover: none) { .nlc-grip { opacity: .75; width: 20px; } }
/* A person's own section is a rounded card inside its group (Group Chats or Agents). Its handle and its "..." menu show on hover, or when tabbed to,
   and stay visible on touch screens. The group header's tint must not reach the card, so these rules are one step more specific than the group's own. */
.nlc-sec { margin: var(--space-2) var(--space-2) var(--space-3); border: 1px solid var(--border); border-radius: 10px; background: transparent; overflow: hidden; }
.sidebar-section .nlc-sec > .sidebar-section-header { background: transparent; padding: var(--space-2) var(--space-2) var(--space-2) var(--space-3); color: var(--k-fg-022); }
.nlc-sec .section-header-main { text-transform: none; letter-spacing: 0; min-width: 0; }
.nlc-sec .section-arrow { color: var(--ink-3); }
.nlc-sec-name { font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.nlc-sec .section-count { font-size: 11px; letter-spacing: 0; color: var(--ink-3); }
.nlc-sec > .sidebar-section-entries { border-top: 1px solid var(--border); }
.nlc-sec > .sidebar-section-entries > .session-entry:last-child { border-bottom: 0; }
.nlc-sec.is-collapsed > .sidebar-section-entries { display: none; }
.nlc-sec-empty { display: none; padding: var(--space-4) var(--space-3); font-size: 12px; line-height: 1.4; text-align: center; color: var(--ink-3); }
.nlc-sec.is-empty > .sidebar-section-entries > .nlc-sec-empty { display: block; }
.sidebar-section .nlc-sec .nlc-sec-menu { opacity: 0; width: 22px; height: 22px; border-radius: 6px; color: var(--ink-3); transition: opacity .12s ease-out, background-color .12s ease-out; }
.nlc-sec .sidebar-section-header:hover .nlc-sec-menu, .nlc-sec .nlc-sec-menu:focus-visible, .nlc-sec .nlc-sec-menu[aria-expanded="true"] { opacity: 1; }
.sidebar-section .nlc-sec .nlc-sec-menu:hover { color: var(--ink); background: var(--menu-item-hover-bg); }
@media (hover: none) { .sidebar-section .nlc-sec .nlc-sec-menu { opacity: .75; } }
.nlc-hidden-add { display: none; }
.nlc-grp-menu { width: 22px; height: 22px; border-radius: 6px; }
.nlc-sec-input { width: 100%; min-width: 0; box-sizing: border-box; padding: var(--space-1) var(--space-2); border: 1px solid var(--blue); border-radius: 5px; background: var(--bg); color: var(--ink); font: inherit; font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: none; outline: 0; }
.pd-lifted.nlc-sec { background: var(--paper); }
/* the "..." menu (a section's Rename and Delete, a group's New ... and New section) */
.nlc-menu { position: fixed; z-index: 2000; min-width: 160px; padding: var(--space-1) 0; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 4px 16px var(--k-fx-041, rgba(0,0,0,.4)); }
.nlc-menu button { display: flex; align-items: center; gap: var(--space-2); width: 100%; padding: var(--space-2) var(--space-4); border: 0; background: none; color: var(--text); font: inherit; font-size: 0.8rem; text-align: left; white-space: nowrap; cursor: pointer; }
.nlc-menu button:hover, .nlc-menu button:focus-visible { background: var(--k-bg-015, var(--menu-item-hover-bg)); outline: 0; }
.nlc-menu button.danger { color: var(--danger); }
@media (prefers-reduced-motion: reduce) { .nlc-grip, .nlc-sec-menu { transition: none; } }
