/* Emojis Tool Styles */

/* Emoji Tab Styles - Optimized for Performance */
.emoji-tab {
    background: #f3f4f6;
    color: #6b7280;
    border: 1px solid #e5e7eb;
}

.emoji-tab:hover {
    background: #e5e7eb;
    color: #4b5563;
    border-color: #d1d5db;
}

.emoji-tab.active {
    background: #6366f1;
    color: white;
    border-color: #6366f1;
}

.emoji-tab.active:hover {
    background: #5b5ad3;
}

/* Emoji Grid Styles - Optimized for Performance */
.emoji-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    font-size: 28px;
    cursor: pointer;
    border-radius: 8px;
    position: relative;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    user-select: none;
}

.emoji-item:hover {
    background: #6366f1;
    border-color: #6366f1;
}

.emoji-item:active,
.emoji-item.copied {
    background: #5b5ad3;
}

/* Emoji Tooltip - REMOVED FOR PERFORMANCE */

/* Responsive Emoji Grid */
@media (max-width: 640px) {
    #emojiGrid {
        grid-template-columns: repeat(6, 1fr);
    }

    .emoji-item {
        width: 40px;
        height: 40px;
        font-size: 24px;
    }
}

@media (min-width: 641px) and (max-width: 768px) {
    #emojiGrid {
        grid-template-columns: repeat(8, 1fr);
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    #emojiGrid {
        grid-template-columns: repeat(12, 1fr);
    }
}

@media (min-width: 1025px) and (max-width: 1280px) {
    #emojiGrid {
        grid-template-columns: repeat(16, 1fr);
    }
}

@media (min-width: 1281px) {
    #emojiGrid {
        grid-template-columns: repeat(20, 1fr);
    }
}

/* Fade-in Animation - REMOVED */

/* Search Input Enhancements */
#emojiSearch {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 2px solid #e5e7eb;
}

#emojiSearch:focus {
    background: white;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

#emojiSearch::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

/* Clear Search Button */
#clearSearch:hover {
    color: #ef4444;
}

/* Status Bar Styles */
#statusBar {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    border: 1px solid #93c5fd;
}

/* Loading Animation - REMOVED */

/* Copy Notification Styles */
#copyNotification {
    /* Animation removed */
}

/* Button Hover Effects - SIMPLIFIED FOR PERFORMANCE */
button:not(.emoji-item):not(.emoji-tab):hover {
    opacity: 0.9;
}

/* Gradient Button Styles */
.bg-gradient-to-r.from-indigo-500 {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
}

.bg-gradient-to-r.from-indigo-500:hover {
    background: linear-gradient(135deg, #5b5ad3 0%, #7c3aed 100%);
}

/* Empty State Styles */
#emptyState {
    /* Animation removed */
}

#emptyState .text-6xl {
    /* Animation removed */
}

/* Header Animation */
.bg-gradient-to-r.from-indigo-600 {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #ec4899 100%);
    position: relative;
    overflow: hidden;
}

.bg-gradient-to-r.from-indigo-600::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Animated Background Elements */
.animate-bounce {
    animation: bounce 2s infinite;
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5b5ad3 0%, #7c3aed 100%);
}

/* Focus Styles for Accessibility */
button:focus,
input:focus {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .emoji-item {
        border: 2px solid;
    }

    .emoji-tab {
        border: 2px solid;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .emoji-item:hover {
        transform: none;
    }
}

/* Print Styles */
@media print {
    .emoji-item {
        break-inside: avoid;
    }

    #copyNotification,
    button,
    #statusBar {
        display: none;
    }
}
