* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #0d0d0d;
    background-image: 
        radial-gradient(circle at 100% 0%, rgba(255, 107, 107, 0.1), transparent 30%),
        radial-gradient(circle at 0% 100%, rgba(78, 205, 196, 0.1), transparent 30%);
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Enhanced Homepage Header */
header {
    text-align: center;
    margin-bottom: 50px;
    padding: 60px 0;
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 300px;
    height: 4px;
    background: linear-gradient(90deg, transparent, #ff6b6b, #4ecdc4, transparent);
    filter: blur(2px);
    animation: headerGlow 3s ease-in-out infinite;
}

@keyframes headerGlow {
    0%, 100% { opacity: 0.6; transform: translateX(-50%) scaleX(1); }
    50% { opacity: 1; transform: translateX(-50%) scaleX(1.2); }
}

header::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255, 107, 107, 0.03) 0%, transparent 70%);
    pointer-events: none;
}

h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 40px;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4, #ff9500, #ff6b6b);
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 8s ease-in-out infinite;
    letter-spacing: -0.03em;
    text-shadow: 0 0 60px rgba(255, 107, 107, 0.4);
    position: relative;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.search-container {
    display: flex;
    max-width: 800px;
    margin: 0 auto;
    gap: 20px;
    position: relative;
    padding: 0 20px;
}

.search-bar {
    flex: 1;
    padding: 20px 30px;
    padding-left: 55px;
    font-size: 18px;
    border: 2px solid rgba(255, 255, 255, 0.08);
    border-radius: 60px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    color: #ffffff;
    backdrop-filter: blur(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 15px 50px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 0 0 1px rgba(255, 107, 107, 0.05);
    position: relative;
    overflow: hidden;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.search-bar::before {
    content: '🔍';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.search-bar:focus {
    outline: none;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
    border-color: rgba(255, 107, 107, 0.4);
    box-shadow: 
        0 0 40px rgba(255, 107, 107, 0.2),
        0 20px 60px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 0 3px rgba(255, 107, 107, 0.1);
    transform: translateY(-4px) scale(1.01);
}

.search-bar:focus::before {
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

.search-bar::placeholder {
    color: rgba(255, 255, 255, 0.5);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: 0.4px;
}

.search-bar:hover {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.search-button {
    padding: 25px 28px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8787 30%, #4ecdc4 70%, #5ed3ca 100%);
    background-size: 150% 150%;
    color: white;
    cursor: pointer;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 10px 30px rgba(255, 107, 107, 0.4),
        0 5px 20px rgba(78, 205, 196, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
    animation: gradientRotate 4s ease-in-out infinite;
}

@keyframes gradientRotate {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.search-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-button::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg) translateX(-100%);
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-button:hover::before {
    width: 120px;
    height: 120px;
}

.search-button:hover::after {
    transform: rotate(45deg) translateX(100%);
}

.search-button:hover {
    transform: scale(1.1);
    box-shadow: 
        0 15px 40px rgba(255, 107, 107, 0.6),
        0 8px 30px rgba(78, 205, 196, 0.4),
        inset 0 2px 0 rgba(255, 255, 255, 0.3);
}

.search-button:active {
    transform: scale(0.95);
    box-shadow: 
        0 8px 20px rgba(255, 107, 107, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.tabs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 60px;
    flex-wrap: wrap;
    padding: 12px 20px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    backdrop-filter: blur(30px);
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 
        0 15px 50px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 1px rgba(255, 107, 107, 0.08);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 60px;
    position: relative;
    overflow: hidden;
}

.tabs::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.08), rgba(78, 205, 196, 0.08), transparent);
    animation: tabsGlow 6s linear infinite;
}

@keyframes tabsGlow {
    0% { left: -100%; }
    100% { left: 100%; }
}

.tab-button {
    padding: 16px 28px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    color: rgba(255, 255, 255, 0.85);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.3px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
    text-transform: none;
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    z-index: 1;
}

.tab-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.tab-button::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4);
    transform: translateX(-50%);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 2px;
}

.tab-button:hover::before {
    left: 100%;
}

.tab-button:hover {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.06));
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(255, 107, 107, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    color: #ffffff;
}

.tab-button:hover::after {
    width: 80%;
}

.tab-button.active {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.25), rgba(78, 205, 196, 0.2));
    border: 1px solid rgba(255, 107, 107, 0.4);
    color: #ffffff;
    box-shadow: 
        0 8px 30px rgba(255, 107, 107, 0.3), 
        0 4px 20px rgba(78, 205, 196, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 0 0 1px rgba(255, 107, 107, 0.1);
    transform: translateY(-2px) scale(1.05);
    font-weight: 700;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.tab-button.active::after {
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #ffffff, rgba(255, 255, 255, 0.8));
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.gif-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    min-height: 400px;
    padding: 20px 0;
}

.gif-placeholder {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 40px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(20px);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 1px rgba(255, 107, 107, 0.1);
}

.gif-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.1), rgba(78, 205, 196, 0.1), transparent);
    transition: left 1.2s ease;
    z-index: 1;
}

.gif-placeholder:hover::before {
    left: 100%;
}

.gif-placeholder:hover {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
    border-color: rgba(255, 107, 107, 0.4);
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 30px 80px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 107, 107, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.gif-placeholder.drag-over {
    background: linear-gradient(145deg, rgba(255, 107, 107, 0.15), rgba(78, 205, 196, 0.15));
    border-color: #ff6b6b;
    transform: scale(1.02);
    box-shadow: 
        0 30px 80px rgba(255, 107, 107, 0.3),
        0 0 0 2px rgba(255, 107, 107, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.gif-placeholder p {
    font-size: 20px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 15px;
    text-align: center;
    position: relative;
    z-index: 2;
    letter-spacing: 0.5px;
    max-width: 400px;
    line-height: 1.5;
}

.gif-placeholder p::before {
    content: "🎭";
    display: block;
    font-size: 48px;
    margin-bottom: 20px;
    animation: bounceGlow 2s ease-in-out infinite;
}

@keyframes bounceGlow {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 10px rgba(255, 107, 107, 0.3));
    }
    50% {
        transform: scale(1.1);
        filter: drop-shadow(0 0 20px rgba(255, 107, 107, 0.6));
    }
}

.gif-placeholder::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ff6b6b, #4ecdc4, transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.gif-placeholder:hover::after {
    opacity: 1;
}

.gif-item {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    aspect-ratio: 16/10;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.gif-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: opacity 0.3s ease;
}

.gif-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: #ff6b6b;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    z-index: 2;
}

@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

.gif-item.loaded .gif-loading {
    display: none !important;
}

.gif-item.loaded img {
    opacity: 1;
}

.gif-grid-picker {
    flex: 1;
    padding: 35px 45px;
    overflow-y: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 35px;
    align-content: start;
    background: 
        linear-gradient(145deg, rgba(255, 255, 255, 0.01), rgba(255, 255, 255, 0.005)),
        radial-gradient(circle at 20% 20%, rgba(255, 107, 107, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(78, 205, 196, 0.05) 0%, transparent 50%);
    background-size: 100% 100%, 600px 600px, 600px 600px;
}

.chat-gif-item {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.12);
    aspect-ratio: 16/10;
    position: relative;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    transform: translateY(0);
}

.chat-gif-item::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, 
        rgba(255, 107, 107, 0.1) 0%, 
        rgba(78, 205, 196, 0.1) 50%, 
        rgba(255, 107, 107, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.chat-gif-item::after {
    content: '✨ Share';
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.8), 
        rgba(30, 30, 30, 0.9));
    color: white;
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    letter-spacing: 0.5px;
}

.chat-gif-item:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: rgba(255, 107, 107, 0.4);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 107, 107, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.chat-gif-item:hover::before {
    opacity: 1;
}

.chat-gif-item:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.chat-gif-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    filter: brightness(1) contrast(1);
}

.chat-gif-item:hover img {
    transform: scale(1.08);
    filter: brightness(1.1) contrast(1.1);
}

/* Responsive adjustments for better spacing */
@media (max-width: 768px) {
    .gif-grid-picker {
        gap: 25px;
        padding: 25px 30px;
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
    
    .chat-gif-item {
        border-radius: 15px;
    }
}

@media (max-width: 480px) {
    .gif-grid-picker {
        gap: 20px;
        padding: 20px;
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    
    .chat-gif-item {
        border-radius: 12px;
    }
    
    .chat-gif-item:hover {
        transform: translateY(-5px) scale(1.01);
    }
}

.upload-button {
    padding: 15px 30px;
    margin-top: 15px;
    border: none;
    border-radius: 25px;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.upload-button:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.5);
}

.upload-section {
    grid-column: 1 / -1;
    margin-bottom: 25px;
}

.gif-actions {
    position: absolute;
    top: 15px;
    right: 15px;
    display: none;
    gap: 10px;
    z-index: 2;
}

.gif-item:hover .gif-actions {
    display: flex;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.action-button {
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.8);
    border: none;
    border-radius: 20px;
    color: white;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.action-button:hover {
    background: rgba(255, 107, 107, 0.9);
    transform: scale(1.1);
}

.url-input-container {
    display: flex;
    gap: 15px;
    margin: 0 auto 50px;
    max-width: 600px;
    position: relative;
}

.url-input {
    flex: 1;
    padding: 18px 25px;
    font-size: 16px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    color: #ffffff;
    backdrop-filter: blur(25px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.url-input:focus {
    outline: none;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.06));
    border-color: rgba(78, 205, 196, 0.6);
    box-shadow: 
        0 0 30px rgba(78, 205, 196, 0.4),
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(78, 205, 196, 0.3),
        inset 0 2px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-2px) scale(1.02);
}

.url-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
    font-size: 15px;
    font-weight: 400;
    letter-spacing: 0.4px;
}

.url-input:hover {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.04));
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.add-url-button {
    padding: 18px 35px;
    border: none;
    border-radius: 50px;
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    color: white;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 8px 25px rgba(78, 205, 196, 0.4),
        0 0 0 1px rgba(78, 205, 196, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-family: 'Poppins', sans-serif;
}

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

.add-url-button:hover::before {
    left: 100%;
}

.add-url-button:hover:not(:disabled) {
    background: linear-gradient(135deg, #5ed3ca, #4ecdc4);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 12px 35px rgba(78, 205, 196, 0.6),
        0 0 0 2px rgba(78, 205, 196, 0.4),
        inset 0 2px 0 rgba(255, 255, 255, 0.3);
}

.add-url-button:disabled {
    background: linear-gradient(135deg, #666, #888);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
    box-shadow: 0 4px 15px rgba(100, 100, 100, 0.2);
}

.add-url-button:active:not(:disabled) {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 
        0 6px 20px rgba(78, 205, 196, 0.5),
        0 0 0 1px rgba(78, 205, 196, 0.3);
}

/* Add loading state for the button */
.add-url-button.loading {
    background: linear-gradient(135deg, #666, #888);
    cursor: not-allowed;
    position: relative;
    overflow: hidden;
}

.add-url-button.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.add-url-button.loading span {
    opacity: 0;
}

.broken-gif-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    border-radius: 20px;
}

.broken-robot {
    width: 60px;
    height: 60px;
    opacity: 0.8;
    filter: grayscale(100%);
}

.broken-gif-overlay p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    text-align: center;
    margin: 0;
    padding: 0 20px;
}

/* Custom Context Menu */
.context-menu {
    position: fixed;
    z-index: 10001;
    width: 200px;
    background: rgba(25, 25, 25, 0.9);
    backdrop-filter: blur(15px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: none;
    padding: 8px;
    font-size: 15px;
}

.context-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.context-menu li {
    padding: 12px 20px;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.context-menu li:hover {
    background: rgba(255, 107, 107, 0.8);
    color: #ffffff;
    transform: translateX(5px);
}

.favorite-button {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: scale(0.7) rotate(-10deg);
    z-index: 3;
    backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.favorite-button svg {
    width: 22px;
    height: 22px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.favorite-button:hover {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.9), rgba(255, 193, 7, 0.9));
    color: #000;
    transform: scale(1.15) rotate(12deg);
    box-shadow: 
        0 8px 25px rgba(255, 215, 0, 0.4),
        0 0 20px rgba(255, 215, 0, 0.3);
    border-color: rgba(255, 215, 0, 0.6);
}

.favorite-button:hover svg {
    transform: scale(1.1) rotate(-12deg);
}

.gif-item:hover .favorite-button {
    opacity: 1;
    transform: scale(1) rotate(0deg);
    animation: bounceIn 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3) rotate(-45deg);
    }
    50% {
        opacity: 1;
        transform: scale(1.1) rotate(5deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

.favorite-button.favorited {
    opacity: 1;
    color: #ffd700;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2), rgba(255, 193, 7, 0.3));
    border-color: rgba(255, 215, 0, 0.5);
    box-shadow: 
        0 0 20px rgba(255, 215, 0, 0.3),
        inset 0 2px 0 rgba(255, 255, 255, 0.2);
    animation: favoritePulse 2s ease-in-out infinite;
}

@keyframes favoritePulse {
    0%, 100% {
        box-shadow: 
            0 0 20px rgba(255, 215, 0, 0.3),
            inset 0 2px 0 rgba(255, 255, 255, 0.2);
    }
    50% {
        box-shadow: 
            0 0 30px rgba(255, 215, 0, 0.5),
            inset 0 2px 0 rgba(255, 255, 255, 0.3);
    }
}

.favorite-button.favorited:hover {
    color: #ffd700;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.3), rgba(255, 193, 7, 0.4));
    transform: scale(1.2) rotate(-8deg);
}

.favorite-button.favorited svg {
    fill: #ffd700;
    filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.6));
}

.delete-button {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 40px;
    height: 40px;
    background: rgba(255, 59, 48, 0.8);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    z-index: 3;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: scale(0.7) rotate(10deg);
    backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(255, 59, 48, 0.4);
    border: 2px solid rgba(255, 59, 48, 0.3);
}

.delete-button svg {
    width: 20px;
    height: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.delete-button:hover {
    background: linear-gradient(135deg, #ff3b30, #ff6b6b);
    transform: scale(1.2) rotate(-8deg);
    box-shadow: 
        0 8px 25px rgba(255, 59, 48, 0.6),
        0 0 20px rgba(255, 59, 48, 0.4);
    border-color: rgba(255, 59, 48, 0.8);
}

.delete-button:hover svg {
    transform: scale(1.1) rotate(8deg);
}

.gif-item:hover .delete-button {
    opacity: 1;
    transform: scale(1) rotate(0deg);
    animation: bounceInLeft 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55) 0.1s both;
}

@keyframes bounceInLeft {
    0% {
        opacity: 0;
        transform: scale(0.3) rotate(45deg) translateX(-50px);
    }
    50% {
        opacity: 1;
        transform: scale(1.1) rotate(-5deg) translateX(5px);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg) translateX(0);
    }
}

.delete-button:active {
    transform: scale(0.9) rotate(0deg);
    transition: transform 0.1s ease;
}

.favorite-button:active {
    transform: scale(0.9) rotate(0deg);
    transition: transform 0.1s ease;
}

/* Enhanced Modal styles with better animations */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(15px);
    animation: modalFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

@keyframes modalFadeIn {
    from { 
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to { 
        opacity: 1;
        backdrop-filter: blur(15px);
    }
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: default;
}

.modal-content img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease;
}

.modal-content:hover img {
    transform: scale(1.01);
}

.modal-info {
    margin-top: 30px;
    text-align: center;
    opacity: 0;
    animation: slideUp 0.4s ease 0.2s forwards;
}

.modal-uploader {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
    gap: 12px;
}

.modal-uploader img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    object-fit: cover;
}

.modal-uploader span {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.close-button {
    position: absolute;
    top: -60px;
    right: 0;
    color: #ffffff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1001;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: none;
    backdrop-filter: none;
}

.close-button:hover {
    color: #ff6b6b;
    transform: scale(1.1);
    background: none;
}

/* Enhanced Update Log Modal Styles */
.update-log-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(13, 13, 13, 0.95), rgba(0, 0, 0, 0.9));
    backdrop-filter: blur(20px);
    animation: modalSlideIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9);
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        transform: scale(1);
        backdrop-filter: blur(20px);
    }
}

.update-log-content {
    position: relative;
    background: linear-gradient(145deg, rgba(13, 13, 13, 0.98), rgba(20, 20, 20, 0.95));
    margin: 30px auto;
    padding: 50px;
    border-radius: 25px;
    max-width: 900px;
    max-height: 95vh;
    overflow-y: auto;
    box-shadow: 
        0 25px 80px rgba(0, 0, 0, 0.7),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    animation: contentSlideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.1s both;
}

@keyframes contentSlideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close-log-button {
    position: absolute;
    top: 25px;
    right: 25px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 32px;
    font-weight: 300;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.close-log-button:hover {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
    border-color: rgba(255, 107, 107, 0.3);
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.2);
}

.update-container {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

.update-container .header {
    text-align: center;
    margin-bottom: 50px;
    padding: 30px 0;
    position: relative;
}

.update-container .header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ff6b6b, #4ecdc4, transparent);
    border-radius: 2px;
}

.update-container .header h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4, #ff9500, #ff6b6b);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientFlow 8s ease-in-out infinite;
    text-shadow: 0 0 40px rgba(255, 107, 107, 0.3);
}

@keyframes gradientFlow {
    0%, 100% { background-position: 0% 50%; }
    25% { background-position: 100% 50%; }
    50% { background-position: 50% 100%; }
    75% { background-position: 0% 100%; }
}

.version-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
    border-radius: 20px;
    padding: 35px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(30px);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.version-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.05), transparent);
    transition: left 0.8s ease;
}

.version-card:hover::before {
    left: 100%;
}

.version-card:hover {
    transform: translateY(-8px) scale(1.01);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    border-color: rgba(255, 107, 107, 0.2);
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 107, 107, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.version-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.version-badge {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4, #ff9500);
    background-size: 200% 200%;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 700;
    font-size: 14px;
    white-space: nowrap;
    animation: badgeGlow 4s ease-in-out infinite;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

@keyframes badgeGlow {
    0%, 100% { 
        background-position: 0% 50%;
        box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    }
    50% { 
        background-position: 100% 50%;
        box-shadow: 0 4px 20px rgba(78, 205, 196, 0.4);
    }
}

.version-date {
    color: rgba(255, 255, 255, 0.7);
    font-size: 15px;
    font-weight: 500;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.version-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ffffff, rgba(255, 255, 255, 0.8));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-list {
    list-style: none;
    padding: 0;
    display: grid;
    gap: 15px;
}

.feature-list li {
    padding: 15px 20px;
    padding-left: 50px;
    position: relative;
    color: rgba(255, 255, 255, 0.9);
    font-size: 15px;
    line-height: 1.7;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    border-left: 3px solid transparent;
    background-image: linear-gradient(rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.02)), 
                     linear-gradient(135deg, #ff6b6b, #4ecdc4);
    background-origin: border-box;
    background-clip: content-box, border-box;
    transition: all 0.3s ease;
}

.feature-list li::before {
    content: "✨";
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {
    0%, 100% { transform: translateY(-50%) scale(1); }
    50% { transform: translateY(-50%) scale(1.2) rotate(10deg); }
}

.feature-list li:hover {
    transform: translateX(8px);
    background: rgba(255, 255, 255, 0.04);
    color: #ffffff;
}

.feature-list li strong {
    color: #ff6b6b;
    font-weight: 700;
    text-shadow: 0 0 10px rgba(255, 107, 107, 0.3);
}

.tag {
    display: inline-block;
    padding: 6px 14px;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2), rgba(78, 205, 196, 0.2));
    border-radius: 20px;
    font-size: 12px;
    color: #ffffff;
    margin: 3px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 500;
    transition: all 0.3s ease;
}

.tag:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.3), rgba(78, 205, 196, 0.3));
    box-shadow: 0 2px 10px rgba(255, 107, 107, 0.2);
}

.update-summary {
    background: rgba(255, 107, 107, 0.1);
    border: 1px solid rgba(255, 107, 107, 0.2);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 25px;
    font-size: 16px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.feature-category {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.feature-category h5 {
    color: #4ecdc4;
    font-size: 1.1rem;
    margin-bottom: 15px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.technical-details {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.technical-details h5 {
    color: #ff6b6b;
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.tech-item {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.tech-item strong {
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    display: block;
    margin-bottom: 8px;
}

.tech-item p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    line-height: 1.4;
    margin: 0;
}

/* Loading animation */
@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    background-color: #0d0d0d;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}