/* popover.css — 浮动选区工具栏（桌面端/手机端共享） */

.selection-popover {
  position: absolute;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  background: var(--bg-1);
  border-radius: 9999px;
  box-shadow: var(--shadow-md);
  animation: popoverIn 150ms ease-out;
}

@keyframes popoverIn {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

.selection-popover__btn {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  border-radius: var(--radius-sm);
  color: var(--text-1);
  cursor: pointer;
  font-size: 14px;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.selection-popover__btn:hover {
  background: var(--bg-3);
}

.selection-popover__btn--active {
  color: var(--primary);
}

.selection-popover__divider {
  width: 1px;
  height: 16px;
  background: var(--line-1);
  margin: 0 4px;
}

/* selection-handle — 选区拖拽把手（手机端专用） */
.selection-handle {
  position: fixed;
  z-index: 208;
  width: 24px;
  height: 24px;
  display: none;
  cursor: grab;
  touch-action: none;
  user-select: none;
  color: var(--primary);
  pointer-events: auto;
}

.selection-handle--visible {
  display: block;
}

.selection-handle--dragging {
  cursor: grabbing;
}

.selection-handle--left .selection-handle__icon {
  transform: scaleX(-1);
}

.selection-handle__icon {
  width: 100%;
  height: 100%;
  display: block;
}
