/* Sketch Canvas + Webcam Capture Modal Overlays
 * Ported from scitex-cloud global-ai-chat/15-sketch-canvas.css */

/* ============================================================
   Sketch Canvas Modal Overlay
   ============================================================ */

.scitex-sketch-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.scitex-sketch-panel {
  background: var(--bg-surface, #161b22);
  border: 1px solid var(--border-default, #30363d);
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 90vw;
  max-height: 90vh;
  width: 900px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

/* -- Toolbar ------------------------------------------------- */

.scitex-sketch-toolbar {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  flex-wrap: wrap;
}

.scitex-sketch-tool,
.scitex-sketch-width {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--border-default, #30363d);
  border-radius: 6px;
  background: var(--bg-secondary, #0d1117);
  color: var(--text-secondary, #8b949e);
  font-size: 0.75rem;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}

.scitex-sketch-tool:hover,
.scitex-sketch-width:hover {
  background: var(--bg-muted, #21262d);
  color: var(--text-primary, #e6edfa);
}

.scitex-sketch-tool.active,
.scitex-sketch-width.active {
  background: var(--color-accent-fg, #58a6ff);
  color: #fff;
  border-color: var(--color-accent-fg, #58a6ff);
}

.scitex-sketch-sep {
  width: 1px;
  height: 1.25rem;
  background: var(--border-default, #30363d);
  margin: 0 0.25rem;
}

/* Color swatches */
.scitex-sketch-color {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  transition: border-color 0.15s;
}

.scitex-sketch-color:hover {
  border-color: rgba(255, 255, 255, 0.4);
}

.scitex-sketch-color.active {
  border-color: var(--color-accent-fg, #58a6ff);
  box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.3);
}

/* -- Canvas -------------------------------------------------- */

.scitex-sketch-canvas {
  width: 100%;
  height: auto;
  border: 1px solid var(--border-default, #30363d);
  border-radius: 8px;
  cursor: crosshair;
  background: #1a1a2e;
}

/* -- Action buttons ------------------------------------------ */

.scitex-sketch-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.scitex-sketch-btn {
  padding: 0.375rem 0.875rem;
  border: 1px solid var(--border-default, #30363d);
  border-radius: 6px;
  background: var(--bg-secondary, #0d1117);
  color: var(--text-secondary, #8b949e);
  font-size: 0.8125rem;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}

.scitex-sketch-btn:hover {
  background: var(--bg-muted, #21262d);
  color: var(--text-primary, #e6edfa);
}

.scitex-sketch-btn-primary {
  background: var(--color-accent-fg, #58a6ff);
  color: #fff;
  border-color: var(--color-accent-fg, #58a6ff);
}

.scitex-sketch-btn-primary:hover {
  background: #4c8ee0;
}

/* ============================================================
   Webcam Capture Modal Overlay
   ============================================================ */

.scitex-webcam-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

.scitex-webcam-panel {
  background: var(--bg-surface, #161b22);
  border: 1px solid var(--border-default, #30363d);
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 640px;
  width: 95vw;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.scitex-webcam-video {
  width: 100%;
  border-radius: 8px;
  background: #000;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.scitex-webcam-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
}

.scitex-webcam-capture-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 3px solid #fff;
  background: transparent;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.scitex-webcam-capture-btn:hover {
  background: rgba(255, 255, 255, 0.15);
}

.scitex-webcam-capture-btn:active {
  background: rgba(255, 255, 255, 0.3);
}
