/* Liminality Universal Explorer · Architectural Theme Tokens */
:root {
  --paper: #f5f4ef;
  --card: #ebe9e1;
  --badge: #dfdcce;
  --line: #d1cdc0;
  --ink: #0e0d0a;
  --muted: #6b6960;
  --font-sans: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Space Mono', monospace;
}

.dark {
  --paper: #0e0d0a;
  --card: #181714;
  --badge: #24221d;
  --line: #33302a;
  --ink: #f5f4ef;
  --muted: #9c988d;
}

body {
  background-color: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
}

.mono { font-family: var(--font-mono); }

.border-line { border-color: var(--line); }
.bg-paper { background-color: var(--paper); }
.bg-card { background-color: var(--card); }
.bg-badge { background-color: var(--badge); }
.text-ink { color: var(--ink); }
.text-muted { color: var(--muted); }

/* Dropzone Hover Pulse */
.dropzone-active {
  border-color: var(--ink) !important;
  background-color: var(--badge) !important;
}

/* Tab & Pill Controls */
.view-btn.is-active {
  background-color: var(--ink);
  color: var(--paper);
  font-weight: 600;
}

/* Floating AI Action Launcher */
.floating-ai-launcher {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 9999px;
  background-color: var(--ink);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  z-index: 45;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.floating-ai-launcher:hover {
  transform: scale(1.05);
}
.floating-ai-launcher.hidden {
  display: none !important;
}

/* Studio AI Dock Layout */
.studio-ai-dock {
  background: var(--card);
  border-left: 1px solid var(--line);
  width: 400px;
  min-width: 320px;
  max-width: 600px;
  height: 100%;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  z-index: 25;
  flex-shrink: 0;
  transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.18s ease-out;
}

.studio-ai-dock.collapsed {
  width: 0px !important;
  min-width: 0px !important;
  max-width: 0px !important;
  opacity: 0 !important;
  overflow: hidden !important;
  border-left: none !important;
  pointer-events: none !important;
}

/* Resize Handles */
.ai-resize-handle {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 6px;
  cursor: ew-resize;
  background: transparent;
  z-index: 30;
  transition: background-color 0.15s ease;
}
.ai-resize-handle:hover,
.ai-resize-handle.active {
  background-color: var(--ink);
  opacity: 0.25;
}

#sidebarResizer {
  cursor: col-resize;
}
#sidebarResizer:hover .divider-hairline {
  background-color: var(--ink);
}

/* Scanline Animation for AI HUD */
@keyframes hudScan {
  0% { transform: translateY(0); opacity: 0.2; }
  50% { opacity: 0.7; }
  100% { transform: translateY(380px); opacity: 0.1; }
}

.hud-scanline {
  animation: hudScan 2.4s ease-in-out infinite;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}
