/**
 * River Visual 3D Engine - Animations
 * Semua CSS animations untuk UI components
 * Port dari ModelViewerBACKUP.jsx
 */

/* Fade In Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Slide In From Left */
@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Slide In From Right */
@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Slide In From Bottom */
@keyframes slideInFromBottom {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Slide Up */
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Toast Slide In */
@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }

  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Pulse Animation (untuk recording indicator) */
@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

/* Pulse Glow (untuk outline/selection) */
@keyframes pulseGlow {

  0%,
  100% {
    opacity: 0.8;
  }

  50% {
    opacity: 0.4;
  }
}

/* Spin Animation (untuk loading) */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* Bounce Animation */
@keyframes bounce {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

/* Scale In */
@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Flash (untuk keyframe indicator) */
@keyframes flash {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(1.2);
  }
}

/* Shimmer (untuk loading skeleton) */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }

  100% {
    background-position: 1000px 0;
  }
}

/* Gradient Shift (untuk background) */
@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

/* Progress Bar Fill */
@keyframes progressBarFill {
  from {
    width: 0%;
  }

  to {
    width: 100%;
  }
}

/* Fade Out */
@keyframes fadeOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

/* Shake Animation (untuk error) */
@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  10%,
  30%,
  50%,
  70%,
  90% {
    transform: translateX(-5px);
  }

  20%,
  40%,
  60%,
  80% {
    transform: translateX(5px);
  }
}

/* Glow Animation */
@keyframes glow {

  0%,
  100% {
    box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
  }

  50% {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.8);
  }
}

/* Rotate Slow (untuk icons) */
@keyframes rotateSlow {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* Heartbeat */
@keyframes heartbeat {

  0%,
  100% {
    transform: scale(1);
  }

  10%,
  30% {
    transform: scale(1.05);
  }

  20%,
  40% {
    transform: scale(1);
  }
}

/* Flash Pulse (untuk camera keyframe - new) */
@keyframes flashPulse {

  0%,
  100% {
    transform: translate(-50%, -50%) rotate(45deg) scale(1);
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.6);
  }

  50% {
    transform: translate(-50%, -50%) rotate(45deg) scale(1.6);
    box-shadow: 0 0 20px rgba(139, 92, 246, 1);
  }
}

/* Update Pulse (untuk selected keyframe update) */
@keyframes updatePulse {

  0%,
  100% {
    transform: translate(-50%, -50%) rotate(45deg) scale(1.4);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.9);
  }

  50% {
    transform: translate(-50%, -50%) rotate(45deg) scale(1.8);
    box-shadow: 0 0 24px rgba(245, 158, 11, 1);
  }
}

/* Slide In From Top (untuk UV edit overlay) */
@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Delete Fade Out (untuk keyframe deletion animation) */
@keyframes deleteFadeOut {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) rotate(45deg) scale(1.4);
  }

  50% {
    transform: translate(-50%, -50%) rotate(225deg) scale(0.3);
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(405deg) scale(0);
  }
}

/* Slide Up From Bottom (untuk mobile panel) */
@keyframes slideUpFromBottom {
  from {
    transform: translateY(100%);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Slide Down To Bottom (untuk mobile panel close) - ULTRA-SMOOTH */
@keyframes slideDownToBottom {
  from {
    transform: translateY(0);
    opacity: 1;
  }

  to {
    transform: translateY(100%);
    opacity: 0;
  }
}

/* Slide Down To Bottom - Desktop version (untuk smooth close) */
@keyframes slideDownToBottomDesktop {
  from {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
  }

  to {
    transform: translateX(-50%) translateY(20px);
    opacity: 0;
  }
}

/* Slide Out To Left (untuk desktop panel close) */
@keyframes slideOutToLeft {
  from {
    transform: translateX(0);
    opacity: 1;
  }

  to {
    transform: translateX(-20px);
    opacity: 0;
  }
}

/* Slide Out To Right (untuk desktop panel close) */
@keyframes slideOutToRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }

  to {
    transform: translateX(20px);
    opacity: 0;
  }
}.loading-progress-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #1a1a1f 0%, #2d2d35 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    z-index: 9999;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.loading-progress-container {
    text-align: center;
    max-width: 500px;
    width: 90%;
    padding: 40px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.loading-spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 30px;
    border: 4px solid rgba(0, 212, 255, 0.1);
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-info {
    margin-top: 20px;
}

.loading-title {
    font-size: 24px;
    font-weight: 600;
    color: white;
    margin: 0 0 8px 0;
    font-family: 'Inter', -apple-system, sans-serif;
}

.loading-asset-name {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 0 24px 0;
    font-family: 'Inter', -apple-system, sans-serif;
}

.progress-bar-wrapper {
    margin-top: 20px;
}

.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #00d4ff 0%, #0099ff 100%);
    border-radius: 10px;
    transition: width 0.3s ease;
    position: relative;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.5);
}

.progress-bar-glow {
    position: absolute;
    top: 0;
    right: 0;
    width: 60px;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3));
    animation: shimmer 2s infinite;
}

@keyframes shimmer {

    0%,
    100% {
        transform: translateX(0);
        opacity: 0;
    }

    50% {
        transform: translateX(-60px);
        opacity: 1;
    }
}

.progress-stats {
    display: flex;
    justify-content: space-between;
    margin-top: 12px;
    font-family: 'Inter', -apple-system, monospace;
}

.progress-percent {
    font-size: 16px;
    font-weight: 600;
    color: #00d4ff;
}

.progress-size {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

/* Responsive */
@media (max-width: 600px) {
    .loading-progress-container {
        padding: 30px 20px;
    }

    .loading-title {
        font-size: 20px;
    }

    .progress-stats {
        font-size: 12px;
    }
}.virtual-canvas-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.virtual-canvas-container {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    /* Max constraints - Aspect ratio handled via inline style */
    max-width: 80vw;
    max-height: 70vh;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.vc-canvas {
    width: 100%;
    height: 100%;
    display: block;
    cursor: grab;
}

.vc-canvas:active {
    cursor: grabbing;
}

.vc-grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.2;
    background-image:
        linear-gradient(#fff 1px, transparent 1px),
        linear-gradient(90deg, #fff 1px, transparent 1px);
    background-size: 33.33% 33.33%;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.vc-controls {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    background: #2a2a2a;
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid #444;
}

.vc-btn {
    background: transparent;
    border: none;
    color: #ccc;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

.vc-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.vc-btn.active {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-weight: 500;
}

.vc-btn-primary {
    background: #3b82f6;
    color: white;
}

.vc-btn-primary:hover {
    background: #2563eb;
}

.vc-btn-danger {
    color: #ef4444;
}

.vc-btn-danger:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* Color Picker Styles */
.vc-color-picker-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    overflow: hidden;
    border-radius: 50%;
    border: 2px solid #555;
    cursor: pointer;
    transition: border-color 0.2s;
    background: #000;
}

.vc-color-picker-wrapper:hover {
    border-color: #fff;
}

.vc-color-input {
    width: 150%;
    height: 150%;
    border: none;
    padding: 0;
    margin: -25%;
    cursor: pointer;
    background: none;
}/* Global styles for River Visual 3D Engine */

:root {
  /* Professional Studio - Dark Mode */
  --bg-primary: #121212;
  --bg-secondary: #1e1e1e;
  --bg-tertiary: #27272a;
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --text-on-accent: #ffffff;
  --accent-primary: #3b82f6;
  --accent-secondary: #8b5cf6;
  --accent-surface: rgba(59, 130, 246, 0.15);
  --border-color: #27272a;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --radius: 8px;
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);

  /* Panel Styles - More solid, less glass */
  --panel-glass-bg: #18181b;
  --panel-glass-elevated-bg: #27272a;
  --panel-border-soft: #27272a;
  --panel-border-strong: #3f3f46;
  --panel-divider: #27272a;

  /* Interactive Elements */
  --list-item-past-bg: #27272a;
  --list-item-future-bg: #18181b;
  --button-ghost-bg: transparent;
  --button-ghost-bg-hover: #27272a;
  --button-ghost-text-disabled: #52525b;
  --control-overlay-bg: rgba(0, 0, 0, 0.75);
  --badge-bg: #27272a;
  --track-bg: #27272a;
  --input-bg: #09090b;
  --input-bg-focus: #09090b;
  --input-border: #27272a;
  --input-border-focus: #3b82f6;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow: hidden;
  transition: background 0.3s ease, color 0.3s ease;
}

[data-theme='light'] {
  /* Soft Studio - Light Mode (Eye Comfort) */
  --bg-primary: #f8f9fa;
  /* Softer off-white background */
  --bg-secondary: #ffffff;
  /* Panels become white to pop against bg */
  --bg-tertiary: #f3f4f6;
  --text-primary: #1f2937;
  /* Dark Grey instead of harsh black */
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --text-on-accent: #ffffff;
  --accent-primary: #3b82f6;
  --accent-secondary: #8b5cf6;
  --accent-surface: rgba(59, 130, 246, 0.08);
  /* More subtle accent surface */
  --border-color: #e5e7eb;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  /* Softer shadows */

  /* Panel Styles - Soft & Clean */
  --panel-glass-bg: #ffffff;
  --panel-glass-elevated-bg: #ffffff;
  --panel-border-soft: #e5e7eb;
  --panel-border-strong: #d1d5db;
  --panel-divider: #f3f4f6;

  /* Interactive Elements */
  --list-item-past-bg: #f3f4f6;
  --list-item-future-bg: #ffffff;
  --button-ghost-bg: transparent;
  --button-ghost-bg-hover: #f3f4f6;
  --button-ghost-text-disabled: #d1d5db;
  --control-overlay-bg: rgba(255, 255, 255, 0.85);
  /* Slightly less opaque */
  --badge-bg: #f3f4f6;
  --track-bg: #e5e7eb;
  --input-bg: #f9fafb;
  /* Very subtle grey for inputs */
  --input-bg-focus: #ffffff;
  --input-border: #e5e7eb;
  --input-border-focus: #3b82f6;
}

/* ========================================
   THEME INLINE STYLE OVERRIDES
   ======================================== */
[data-theme='light'] [style*="linear-gradient(135deg, rgba(20, 20, 30"] {
  background: var(--panel-glass-bg) !important;
  color: var(--text-primary) !important;
  border-color: var(--panel-border-soft) !important;
}

[data-theme='light'] [style*="linear-gradient(135deg, rgba(20, 20, 30, 0.95)"] {
  background: var(--panel-glass-elevated-bg) !important;
  color: var(--text-primary) !important;
  border-color: var(--panel-border-strong) !important;
}

[data-theme='light'] [style*="background-color: rgba(0, 0, 0, 0.6)"],
[data-theme='light'] [style*="backgroundColor: rgba(0, 0, 0, 0.6)"] {
  background-color: var(--control-overlay-bg) !important;
  color: var(--text-primary) !important;
}

[data-theme='light'] [style*="border: 0.5px solid rgba(255, 255, 255, 0.18)"],
[data-theme='light'] [style*="border:0.5px solid rgba(255, 255, 255, 0.18)"],
[data-theme='light'] [style*="border: 1px solid rgba(255, 255, 255, 0.18)"] {
  border-color: var(--panel-border-soft) !important;
}

[data-theme='light'] [style*="borderTop: 0.5px solid rgba(255, 255, 255, 0.25)"],
[data-theme='light'] [style*="border-top: 0.5px solid rgba(255, 255, 255, 0.25)"] {
  border-top: 1px solid var(--panel-border-strong) !important;
}

[data-theme='light'] [style*="border-bottom: 1px solid rgba(255, 255, 255, 0.1)"],
[data-theme='light'] [style*="borderBottom: 1px solid rgba(255, 255, 255, 0.1)"] {
  border-bottom: 1px solid var(--panel-divider) !important;
}

[data-theme='light'] [style*="background-color: rgba(255, 255, 255, 0.05)"] {
  background-color: var(--list-item-past-bg) !important;
}

[data-theme='light'] [style*="background-color: rgba(255, 255, 255, 0.02)"] {
  background-color: var(--list-item-future-bg) !important;
}

[data-theme='light'] [style*="backgroundColor: #1e1e23"],
[data-theme='light'] [style*="background-color: #1e1e23"] {
  background-color: var(--input-bg) !important;
  color: var(--text-primary) !important;
  border-color: var(--input-border) !important;
}

[data-theme='light'] [style*="backgroundColor: #252530"],
[data-theme='light'] [style*="background-color: #252530"] {
  background-color: var(--input-bg-focus) !important;
}

/* Accent button text */
button[style*="background: linear-gradient(135deg, rgba(59, 130, 246"],
button[style*="background:linear-gradient(135deg, rgba(59, 130, 246"],
button[style*="background: linear-gradient(135deg, rgba(16, 185, 129"],
button[style*="background:linear-gradient(135deg, rgba(16, 185, 129"],
button[style*="background-color: #3b82f6"],
button[style*="backgroundColor: #3b82f6"],
button[style*="background-color: #10b981"],
button[style*="backgroundColor: #10b981"],
button[style*="background-color: #ef4444"],
button[style*="backgroundColor: #ef4444"],
button[style*="background-color: #f59e0b"],
button[style*="backgroundColor: #f59e0b"],
button[style*="background-color: #8b5cf6"],
button[style*="backgroundColor: #8b5cf6"] {
  color: var(--text-on-accent) !important;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Button base styles */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  outline: none;
  transition: var(--transition);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Input base styles */
input,
select,
textarea {
  font-family: inherit;
  background: var(--input-bg);
  color: var(--text-primary);
  border: 1px solid var(--input-border);
  border-radius: var(--radius);
  padding: 8px 12px;
  transition: var(--transition);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--input-border-focus);
  background: var(--input-bg-focus);
}

/* Utility classes */
.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.items-center {
  align-items: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-2 {
  gap: 0.5rem;
}

.gap-4 {
  gap: 1rem;
}

.p-4 {
  padding: 1rem;
}

.mt-2 {
  margin-top: 0.5rem;
}

.mt-4 {
  margin-top: 1rem;
}

/* Panel styles */
.floating-panel {
  position: absolute;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  max-height: 80vh;
  overflow-y: auto;
  z-index: 100;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  cursor: move;
  user-select: none;
}

.panel-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.panel-close {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: transparent;
  color: var(--text-secondary);
  transition: var(--transition);
}

.panel-close:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.panel-content {
  padding: 16px;
}

/* Toast notification */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 12px 16px;
  box-shadow: var(--shadow);
  z-index: 9999;
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
    transform: translateX(400px);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.toast.success {
  border-left: 4px solid #10b981;
}

.toast.error {
  border-left: 4px solid #ef4444;
}

.toast.info {
  border-left: 4px solid var(--accent-primary);
}

/* Loading overlay */
.loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(26, 26, 31, 0.8);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ========================================
   ADDITIONAL ANIMATIONS FROM ORIGINAL
   ======================================== */

/* Pulse animation */
@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

/* Slide & Fade Animations */
@keyframes slideInFromLeft {
  0% {
    opacity: 0;
    transform: translateX(-40px);
  }

  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromRight {
  0% {
    opacity: 0;
    transform: translateX(40px);
  }

  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromBottom {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(40px);
  }

  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes slideInFromTop {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Toast Notification Animation - Slide from Top */
@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translate(-50%, -30px);
  }

  100% {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

@keyframes toastSlideOut {
  0% {
    opacity: 1;
    transform: translate(-50%, 0);
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -20px);
  }
}

/* Flash Effect for Keyframe Capture */
@keyframes flashPulse {

  0%,
  100% {
    box-shadow: 0 0 8px rgba(139, 92, 246, 0.6);
    transform: translate(-50%, -50%) rotate(45deg) scale(1);
  }

  50% {
    box-shadow: 0 0 30px rgba(16, 185, 129, 1), 0 0 50px rgba(16, 185, 129, 0.6);
    transform: translate(-50%, -50%) rotate(45deg) scale(1.8);
  }
}

/* Update Pulse Effect */
@keyframes updatePulse {

  0%,
  100% {
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.9);
    transform: translate(-50%, -50%) rotate(45deg) scale(1.4);
  }

  50% {
    box-shadow: 0 0 25px rgba(245, 158, 11, 1), 0 0 40px rgba(245, 158, 11, 0.7);
    transform: translate(-50%, -50%) rotate(45deg) scale(1.7);
  }
}

/* Delete Fade Out */
@keyframes deleteFadeOut {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) rotate(45deg) scale(1.4);
  }

  50% {
    transform: translate(-50%, -50%) rotate(225deg) scale(0.3);
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(405deg) scale(0);
  }
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

@keyframes fadeOut {
  0% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

@keyframes scaleIn {
  0% {
    opacity: 0;
    transform: scale(0.95);
  }

  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Loading Screen Animations */
@keyframes pulse-glow {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.7;
    transform: scale(1.05);
  }
}

@keyframes blurFadeInOut {
  0% {
    opacity: 0;
    filter: blur(10px);
  }

  50% {
    opacity: 1;
    filter: blur(0px);
  }

  100% {
    opacity: 0;
    filter: blur(10px);
  }
}

@keyframes blurFadeIn {
  0% {
    opacity: 0;
    filter: blur(8px);
    transform: translateY(10px);
  }

  100% {
    opacity: 1;
    filter: blur(0px);
    transform: translateY(0);
  }
}

/* Mobile-friendly scrolling */
* {
  -webkit-overflow-scrolling: touch;
}

/* Better touch target sizes for mobile */
@media (max-width: 768px) {
  button:not([style*="border-radius: 50%"]) {
    min-height: 40px;
    touch-action: manipulation;
  }

  input[type="range"] {
    height: 36px;
    touch-action: manipulation;
  }

  select {
    min-height: 40px;
    font-size: 14px;
    touch-action: manipulation;
  }

  input[type="number"],
  input[type="text"] {
    min-height: 36px;
    font-size: 14px;
    touch-action: manipulation;
  }

  /* Prevent zoom on input focus on iOS */
  input,
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* Smooth slide-in animation for mobile panel */
@keyframes slideUp {
  from {
    transform: translateY(100%);
  }

  to {
    transform: translateY(0);
  }
}