@import "tokens.css";

/* Base Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
}

/* Accessibility: Focus visible */
:focus-visible {
  outline: 2px solid var(--border-focus);
  outline-offset: 2px;
}

/* Typography Defaults */
h1, h2, h3, h4 {
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.25;
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

p {
  color: var(--text-secondary);
  font-size: var(--text-base);
}

/* Form Controls & Inputs */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}

label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-secondary);
}

input[type="text"],
input[type="password"],
input[type="email"] {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-family: inherit;
  color: var(--text-primary);
  background-color: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus {
  border-color: var(--border-focus);
  outline: none;
  box-shadow: 0 0 0 1px var(--border-focus);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3) var(--space-5);
  font-size: var(--text-sm);
  font-weight: 500;
  font-family: inherit;
  border-radius: var(--radius-md);
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color var(--transition-fast), border-color var(--transition-fast), transform 50ms;
  text-decoration: none;
  user-select: none;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background-color: var(--accent-primary);
  color: var(--accent-text);
}

.btn-primary:hover {
  background-color: var(--accent-primary-hover);
}

.btn-secondary {
  background-color: var(--bg-surface-elevated);
  color: var(--text-primary);
  border-color: var(--border-subtle);
}

.btn-secondary:hover {
  background-color: var(--border-strong);
}

.btn-danger {
  background-color: var(--danger-surface);
  color: var(--danger-primary);
  border-color: var(--danger-primary);
}

.btn-danger:hover {
  background-color: var(--danger-primary);
  color: #fff;
}

.btn-icon {
  padding: var(--space-2);
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-secondary);
  border: none;
}

.btn-icon:hover {
  color: var(--text-primary);
  background: var(--bg-surface-elevated);
}

.btn-sm {
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  border-radius: var(--radius-sm);
}

/* Authentication Screen */
.auth-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: var(--space-4);
  background: radial-gradient(circle at top, #1c2333 0%, var(--bg-primary) 70%);
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
}

.auth-header {
  text-align: center;
  margin-bottom: var(--space-6);
}

.auth-logo {
  font-size: var(--text-3xl);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.auth-subtitle {
  color: var(--text-muted);
  font-size: var(--text-sm);
}

.auth-tabs {
  display: flex;
  background: var(--bg-input);
  padding: var(--space-1);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-5);
  border: 1px solid var(--border-subtle);
}

.auth-tab {
  flex: 1;
  text-align: center;
  padding: var(--space-2) var(--space-3);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-secondary);
  border: none;
  background: transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.auth-tab.active {
  color: var(--text-primary);
  background: var(--bg-surface-elevated);
  box-shadow: var(--shadow-sm);
}

.alert-banner {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
  display: none;
}

.alert-error {
  display: block;
  background: var(--danger-surface);
  color: var(--danger-primary);
  border: 1px solid var(--danger-primary);
}

.alert-success {
  display: block;
  background: var(--success-surface);
  color: var(--success-primary);
  border: 1px solid var(--success-primary);
}

/* App Header & Navigation Bar */
.app-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  background-color: rgba(24, 27, 36, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-4);
  z-index: 1000;
  user-select: none;
}

.header-left {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.app-title {
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.board-name-badge {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  background: var(--bg-surface-elevated);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

/* Board Switcher & Dropdown */
.board-switcher-container {
  position: relative;
  display: flex;
  align-items: center;
}

.board-switcher-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 5px 12px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: background 150ms ease, border-color 150ms ease;
  max-width: 260px;
  user-select: none;
}

.board-switcher-btn:hover {
  background: var(--border-strong);
  border-color: var(--border-focus);
}

.board-switcher-btn:focus-visible {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.4);
}

.board-title-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 170px;
}

.board-icon {
  color: var(--text-secondary);
  flex-shrink: 0;
}

.chevron-icon {
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 150ms ease;
}

.board-switcher-btn[aria-expanded="true"] .chevron-icon {
  transform: rotate(180deg);
}

.header-new-board-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.board-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 340px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: 1500;
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  animation: dropdownFadeIn 120ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes dropdownFadeIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.board-dropdown-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-1) var(--space-1) var(--space-2) var(--space-1);
}

.board-dropdown-title {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.board-dropdown-search {
  padding: 0 0 var(--space-1) 0;
}

.board-dropdown-search input {
  width: 100%;
  padding: 7px 10px;
  font-size: var(--text-sm);
  font-family: inherit;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background-color: var(--bg-input);
  color: var(--text-primary);
  transition: border-color 150ms;
}

.board-dropdown-search input:focus {
  border-color: var(--border-focus);
  outline: none;
  box-shadow: 0 0 0 1px var(--border-focus);
}

.board-dropdown-list {
  max-height: 280px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding-right: 2px;
}

.board-dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease;
  border: 1px solid transparent;
  text-decoration: none;
  color: var(--text-primary);
  background: transparent;
  width: 100%;
  text-align: left;
  font-family: inherit;
  user-select: none;
}

.board-dropdown-item:hover {
  background-color: var(--bg-surface-elevated);
}

.board-dropdown-item:focus-visible {
  outline: none;
  border-color: var(--border-focus);
  background-color: var(--bg-surface-elevated);
}

.board-dropdown-item.active {
  background-color: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.3);
}

.board-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
  flex: 1;
}

.board-item-title {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.board-dropdown-item.active .board-item-title {
  color: var(--accent-primary);
  font-weight: 600;
}

.board-item-meta {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.board-item-active-icon {
  color: var(--accent-primary);
  flex-shrink: 0;
  margin-left: 8px;
}

.board-dropdown-empty {
  padding: var(--space-4) var(--space-2);
  text-align: center;
  color: var(--text-muted);
  font-size: var(--text-sm);
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(10, 12, 16, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  animation: modalBackdropFadeIn 150ms ease-out;
}

@keyframes modalBackdropFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-card {
  width: 100%;
  max-width: 440px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
  animation: modalScaleIn 150ms cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-card-lg {
  max-width: 680px;
}

/* Auth Notices */
.auth-notice {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--text-xs);
  line-height: 1.5;
  margin-bottom: var(--space-4);
}

.notice-info {
  background-color: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #93c5fd;
}

.notice-warning {
  background-color: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #fcd34d;
}

/* Admin Button in Header */
.header-admin-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-color: rgba(59, 130, 246, 0.4);
  color: #93c5fd;
  background-color: rgba(59, 130, 246, 0.08);
}

.header-admin-btn:hover {
  background-color: rgba(59, 130, 246, 0.18);
  border-color: var(--accent-primary);
  color: #fff;
}

/* Admin Tabs */
.admin-tabs {
  display: flex;
  gap: var(--space-2);
  border-bottom: 1px solid var(--border-subtle);
  margin-top: var(--space-3);
  margin-bottom: var(--space-5);
}

.admin-tab {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: var(--space-2) var(--space-4);
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 150ms ease;
  margin-bottom: -1px;
}

.admin-tab:hover {
  color: var(--text-primary);
}

.admin-tab.active {
  color: var(--accent-primary);
  border-bottom-color: var(--accent-primary);
  font-weight: 600;
}

/* Admin Settings Card */
.admin-setting-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4);
  background-color: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-3);
}

.admin-setting-info {
  flex: 1;
}

.admin-setting-title {
  display: block;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.admin-setting-desc {
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

.setting-save-status {
  font-size: var(--text-xs);
  color: var(--success-primary);
  margin-top: var(--space-2);
  padding-left: var(--space-1);
}

/* Switch Toggle Component */
.switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: var(--border-strong);
  transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 24px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--accent-primary);
}

input:focus-visible + .slider {
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.4);
}

input:checked + .slider:before {
  transform: translateX(20px);
}

/* Admin Users Toolbar & Table */
.admin-users-toolbar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}

.admin-search-input {
  flex: 1;
  padding: 6px 12px;
  font-size: var(--text-xs);
  font-family: inherit;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background-color: var(--bg-input);
  color: var(--text-primary);
}

.admin-search-input:focus {
  outline: none;
  border-color: var(--border-focus);
}

.admin-users-table-container {
  max-height: 340px;
  overflow-y: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface-elevated);
}

.admin-users-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-xs);
  text-align: left;
}

.admin-users-table th {
  padding: 8px 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.05em;
  background-color: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 2;
}

.admin-users-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
  vertical-align: middle;
}

.admin-users-table tr:last-child td {
  border-bottom: none;
}

.admin-users-table tr:hover td {
  background-color: rgba(255, 255, 255, 0.02);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
}

.badge-admin {
  background-color: rgba(139, 92, 246, 0.15);
  color: #c4b5fd;
  border: 1px solid rgba(139, 92, 246, 0.3);
}

.badge-member {
  background-color: rgba(100, 116, 139, 0.15);
  color: #94a3b8;
  border: 1px solid rgba(100, 116, 139, 0.3);
}

.badge-active {
  background-color: rgba(16, 185, 129, 0.12);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.badge-banned {
  background-color: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.badge-you {
  font-size: 10px;
  color: var(--text-muted);
  margin-left: 4px;
  font-weight: normal;
}

.btn-danger-outline {
  background: transparent;
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.4);
  padding: 3px 8px;
  font-size: 11px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-family: inherit;
  transition: all 120ms;
}

.btn-danger-outline:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.15);
  border-color: #ef4444;
}

.btn-danger-outline:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-success-outline {
  background: transparent;
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
  padding: 3px 8px;
  font-size: 11px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-family: inherit;
  transition: all 120ms;
}

.btn-success-outline:hover {
  background: rgba(16, 185, 129, 0.15);
  border-color: #10b981;
}

@keyframes modalScaleIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-2);
}

.modal-title {
  font-size: var(--text-xl);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 0;
}

.modal-close-btn {
  color: var(--text-muted);
  padding: var(--space-1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  color: var(--text-primary);
}

.modal-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

.header-center {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.header-right {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.collaborators-cluster {
  display: flex;
  align-items: center;
  padding-right: var(--space-2);
}

.user-avatar {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);
  font-weight: 600;
  color: #fff;
  border: 2px solid var(--bg-surface);
  margin-left: -8px;
  box-shadow: var(--shadow-sm);
  text-transform: uppercase;
}

.user-avatar:first-child {
  margin-left: 0;
}

.connection-status {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--warning-primary);
}

.status-dot.connected {
  background-color: var(--success-primary);
}

.status-dot.disconnected {
  background-color: var(--danger-primary);
}

/* Canvas Container & Grid */
.canvas-viewport {
  position: absolute;
  top: 56px;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;
  background-color: var(--bg-canvas);
  touch-action: none;
}

.canvas-grid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  background-image: radial-gradient(circle, var(--border-strong) 1px, transparent 1px);
  background-size: 32px 32px;
  opacity: 0.6;
}

.canvas-world {
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: 0 0;
  will-change: transform;
}

/* Board Elements */
.board-element {
  position: absolute;
  top: 0;
  left: 0;
  cursor: grab;
  user-select: none;
  touch-action: none;
}

.board-element:active {
  cursor: grabbing;
}

.element-content {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  transition: box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.element-content img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.element-text {
  padding: var(--space-4);
  font-size: var(--text-base);
  color: var(--text-primary);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

/* Selection & Focus */
.board-element.selected .element-content {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 2px var(--border-focus), var(--shadow-lg);
}

.board-element.selected .resize-handle {
  display: block;
}

/* Resize Handles */
.resize-handle {
  display: none;
  position: absolute;
  width: 12px;
  height: 12px;
  background-color: #fff;
  border: 2px solid var(--border-focus);
  border-radius: var(--radius-sm);
  z-index: 10;
}

.handle-nw { top: -6px; left: -6px; cursor: nwse-resize; }
.handle-ne { top: -6px; right: -6px; cursor: nesw-resize; }
.handle-se { bottom: -6px; right: -6px; cursor: nwse-resize; }
.handle-sw { bottom: -6px; left: -6px; cursor: nesw-resize; }

/* Real-Time Locking Styles */
.board-element.locked-by-other {
  cursor: not-allowed;
  pointer-events: auto;
}

.board-element.locked-by-other .element-content {
  border-color: var(--lock-color, #f59e0b) !important;
  box-shadow: 0 0 0 2px var(--lock-color, #f59e0b), var(--shadow-lg) !important;
}

.element-lock-badge {
  display: none;
  position: absolute;
  top: -24px;
  left: 0;
  font-size: var(--text-xs);
  font-weight: 600;
  color: #fff;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  pointer-events: none;
  box-shadow: var(--shadow-sm);
}

/* Floating Viewport Controls */
.viewport-controls {
  position: fixed;
  bottom: var(--space-4);
  right: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-1);
  background-color: rgba(24, 27, 36, 0.9);
  backdrop-filter: blur(12px);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-lg);
  z-index: 900;
  user-select: none;
}

.zoom-badge {
  font-size: var(--text-xs);
  font-family: var(--font-mono);
  color: var(--text-secondary);
  min-width: 48px;
  text-align: center;
}

/* Floating Action Toolbar */
.action-toolbar {
  position: fixed;
  bottom: var(--space-4);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  background-color: rgba(24, 27, 36, 0.9);
  backdrop-filter: blur(12px);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-lg);
  z-index: 900;
  user-select: none;
}

.toolbar-divider {
  width: 1px;
  height: 20px;
  background: var(--border-subtle);
}

/* Drag-and-Drop Overlay */
.drop-overlay {
  display: none;
  position: absolute;
  inset: 0;
  background-color: rgba(59, 130, 246, 0.1);
  border: 2px dashed var(--accent-primary);
  z-index: 950;
  pointer-events: none;
  align-items: center;
  justify-content: center;
}

.drop-overlay.active {
  display: flex;
}

.drop-message {
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--accent-text);
  background: rgba(24, 27, 36, 0.95);
  padding: var(--space-4) var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--accent-primary);
  box-shadow: var(--shadow-lg);
}
