/* Custom styles for the chord progression generator */

.slider {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 5px;
    background: #4a5568;
    outline: none;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.slider:hover {
    opacity: 1;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #f4d03f;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}

.slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #f4d03f;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}

.slider::-moz-range-thumb:hover {
    transform: scale(1.1);
}

/* Custom scrollbar for history and favorites */
.max-h-64::-webkit-scrollbar {
    width: 6px;
}

.max-h-64::-webkit-scrollbar-track {
    background: #2d3748;
    border-radius: 3px;
}

.max-h-64::-webkit-scrollbar-thumb {
    background: #4a5568;
    border-radius: 3px;
}

.max-h-64::-webkit-scrollbar-thumb:hover {
    background: #718096;
}

/* Subtle animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bg-gray-800 {
    animation: fadeIn 0.3s ease-out;
}

/* Button hover effects */
button {
    position: relative;
    overflow: hidden;
}

button:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

button:hover:before {
    left: 100%;
}

/* Chord grid hover effects */
.grid > div:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(244, 208, 63, 0.3);
}

/* Loading states */
.generating {
    animation: pulse 1.5s ease-in-out infinite alternate;
}

@keyframes pulse {
    from {
        opacity: 1;
    }
    to {
        opacity: 0.5;
    }
}

/* Responsive design improvements */
@media (max-width: 768px) {
    .grid-cols-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    
    .text-2xl {
        font-size: 1.5rem;
    }
    
    .space-x-4 > * + * {
        margin-left: 0.5rem;
    }
}

/* Focus states for accessibility */
button:focus,
select:focus,
input:focus {
    outline: 2px solid #f4d03f;
    outline-offset: 2px;
}

/* Custom select styling */
select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    background-size: 1.2em;
}

/* Genre tab active state */
.bg-gold {
    box-shadow: 0 0 20px rgba(244, 208, 63, 0.5);
}

/* Subtle background pattern */
.bg-dark {
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(244, 208, 63, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(147, 51, 234, 0.05) 0%, transparent 50%);
}