/* Desktop styles (≥1024px) ─────────────────────────────────────────────────── */
@media (min-width: 1024px) {
  .nexus-shell {
    --topbar-h: 40px;
    --statusbar-h: 28px;
    --sidebar-left-w: 220px;
    --sidebar-right-w: 0px;
  }

  /* Collapsed left sidebar → icon-only mode */
  .nexus-sidebar-left.icon-only {
    --sidebar-left-w: 48px;
  }
  .nexus-shell:has(.nexus-sidebar-left.icon-only) {
    grid-template-columns: 48px 1fr var(--sidebar-right-w, 0px);
  }
  .nexus-sidebar-left.icon-only .sidebar-logo-text,
  .nexus-sidebar-left.icon-only .sidebar-nav-item span,
  .nexus-sidebar-left.icon-only .sidebar-badge,
  .nexus-sidebar-left.icon-only .sidebar-nav-divider {
    display: none;
  }
  .nexus-sidebar-left.icon-only .sidebar-nav-item {
    justify-content: center;
    padding: 8px 0;
  }
  .nexus-sidebar-left.icon-only .sidebar-logo {
    justify-content: center;
    padding: 12px 8px;
  }

  /* Right sidebar visible */
  .nexus-shell.right-sidebar-visible {
    --sidebar-right-w: 260px;
    grid-template-columns: var(--sidebar-left-w, 220px) 1fr 260px;
  }

  /* Statusbar height */
  .nexus-statusbar { height: var(--statusbar-h); }
  .nexus-topbar { height: var(--topbar-h); }

  /* Hover-reveal sidebar */
  .nexus-sidebar-left.hover-reveal {
    position: fixed;
    left: 0;
    top: var(--topbar-h, 40px);
    bottom: var(--statusbar-h, 28px);
    transform: translateX(-100%);
    transition: transform 180ms ease;
    box-shadow: var(--shadow-xl);
    z-index: 200;
  }
  .nexus-sidebar-left.hover-reveal:hover,
  .nexus-sidebar-left.hover-reveal.pinned {
    transform: translateX(0);
  }

  /* Right-click context menu always available */
  .context-menu-trigger { cursor: context-menu; }

  /* Drag handles */
  [draggable="true"] { cursor: grab; }
  [draggable="true"]:active { cursor: grabbing; }

  /* Tooltips */
  [data-tooltip]::after { bottom: calc(100% + 6px); }

  /* Split pane resize handle */
  .resize-handle {
    width: 4px;
    background: transparent;
    cursor: ew-resize;
    flex-shrink: 0;
    transition: background 150ms ease;
  }
  .resize-handle:hover { background: var(--accent); }

  /* Wide layout tweaks */
  @media (min-width: 1440px) {
    .nexus-shell {
      --sidebar-left-w: 240px;
    }
  }
}
