.pto-workbench-shell,
.workbench-frame {
  --pto-workbench-shell-gutter: 10px;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.pto-workbench-shell__panes,
.workbench-frame-split {
  min-width: 0;
  min-height: 0;
  flex: 1 1 auto;
  display: flex;
  align-items: stretch;
  gap: 0;
  overflow: hidden;
}

.pto-workbench-shell__panes[data-split-direction="vertical"],
.workbench-frame-split[data-split-direction="vertical"] {
  flex-direction: column;
}

.pto-workbench-shell__pane,
.workbench-pane {
  min-width: 0;
  min-height: 0;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.pto-workbench-shell__pane-body,
.workbench-pane-body {
  min-width: 0;
  min-height: 0;
  flex: 1 1 auto;
  overflow: auto;
}

.pto-workbench-shell__split-gutter {
  flex: 0 0 var(--pto-workbench-shell-gutter, 10px);
  position: relative;
  min-width: var(--pto-workbench-shell-gutter, 10px);
  cursor: col-resize;
  touch-action: none;
  outline: none;
  background: transparent;
}

.pto-workbench-shell__split-gutter[data-split-direction="vertical"] {
  width: 100%;
  min-width: 0;
  min-height: var(--pto-workbench-shell-gutter, 10px);
  cursor: row-resize;
}

.pto-workbench-shell__split-gutter::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3px;
  height: 44px;
  border-radius: var(--radius-pill, 999px);
  transform: translate(-50%, -50%);
  background: color-mix(in srgb, var(--foreground-muted, rgba(255, 255, 255, 0.42)) 46%, transparent);
  transition:
    background var(--duration-fast, 100ms) var(--easing-default, ease),
    width var(--duration-fast, 100ms) var(--easing-default, ease),
    height var(--duration-fast, 100ms) var(--easing-default, ease);
}

.pto-workbench-shell__split-gutter[data-split-direction="vertical"]::before {
  width: 44px;
  height: 3px;
}

.pto-workbench-shell__split-gutter:hover::before,
.pto-workbench-shell__split-gutter:focus-visible::before,
body.pto-is-pane-resizing .pto-workbench-shell__split-gutter::before {
  background: color-mix(in srgb, var(--foreground-secondary, rgba(255, 255, 255, 0.62)) 72%, transparent);
}

.pto-workbench-shell__split-gutter:focus-visible {
  box-shadow: 0 0 0 2px var(--focus-ring, rgba(67, 105, 239, 0.42));
}

body.pto-is-pane-resizing,
body.pto-is-pane-resizing * {
  user-select: none;
}

body.pto-is-pane-resizing[data-pto-resize-direction="horizontal"],
body.pto-is-pane-resizing[data-pto-resize-direction="horizontal"] * {
  cursor: col-resize !important;
}

body.pto-is-pane-resizing[data-pto-resize-direction="vertical"],
body.pto-is-pane-resizing[data-pto-resize-direction="vertical"] * {
  cursor: row-resize !important;
}
