/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #0a0a0f;
}

::-webkit-scrollbar-thumb {
    background: #2a2a3f;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3a3a4f;
}

/* Selection Color */
::selection {
    background: rgba(99, 102, 241, 0.3);
    color: white;
}

/* Smooth transitions */
* {
    transition-property: background-color, border-color, color, fill, stroke;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
}

/* Canvas styling */
canvas {
    image-rendering: -moz-crisp-edges;
    image-rendering: -webkit-crisp-edges;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
}

/* Glassmorphism utilities */
.glass {
    background: rgba(19, 19, 31, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Animation utilities */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(99, 102, 241, 0.5);
    }
}

.glow-effect {
    animation: pulse-glow 3s infinite;
}

/* Text gradient animation */
.animated-gradient-text {
    background: linear-gradient(to right, #6366f1, #8b5cf6, #ec4899, #6366f1);
    background-size: 300% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-shift 8s ease infinite;
}

@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Hover lift effect */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Custom range input styling */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    cursor: pointer;
}

input[type="range"]::-webkit-slider-track {
    background: rgba(255, 255, 255, 0.1);
    height: 4px;
    border-radius: 2px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    background: #6366f1;
    height: 16px;
    width: 16px;
    border-radius: 50%;
    margin-top: -6px;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
}

input[type="range"]::-webkit-slider-thumb:hover {
    background: #818cf8;
    transform: scale(1.1);
}

/* File upload zone drag state */
.drag-active {
    border-color: #6366f1 !important;
    background: rgba(99, 102, 241, 0.1) !important;
}

/* Loading shimmer effect */
.shimmer {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.05) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Responsive typography */
@media (max-width: 640px) {
    .text-responsive-hero {
        font-size: 2.5rem;
        line-height: 1.2;
    }
}

/* Focus visible styles */
:focus-visible {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}

/* Button press effect */
button:active {
    transform: scale(0.98);
}

/* Prevent text selection on UI elements */
.no-select {
    user-select: none;
    -webkit-user-select: none;
}

/* Smooth scrolling for the whole page */
html {
    scroll-behavior: smooth;
}

/* Hide scrollbar for clean UI elements */
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}