/* Gallery Page Styles */

/* Gallery Hero Section */
.gallery-hero {
    position: relative;
    min-height: 50vh;
    display: flex;
    align-items: center;
    margin-top: 80px;
}

.gallery-hero-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 0;
}

.gallery-hero-title {
    font-size: var(--font-size-hero);
    font-weight: 900;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.gallery-hero-subtitle {
    font-size: var(--font-size-large);
    color: var(--text-secondary);
    margin-bottom: 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Gallery Tabs Section */
.gallery-tabs-section {
    background: var(--background-card);
    padding: 30px 0;
    border-bottom: 1px solid var(--border-color);
}

.gallery-tabs {
    justify-content: center;
    border-bottom: none;
    margin-bottom: 0;
}

/* Gallery Grid */
.gallery-section {
    padding: 60px 0;
    background: var(--background-dark);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.gallery-item {
    opacity: 1;
    transform: scale(1);
    transition: var(--transition-medium);
}

.gallery-card {
    position: relative;
    background: var(--background-card);
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: var(--transition-medium);
    cursor: pointer;
}

.gallery-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
}

.gallery-image {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
}

.gallery-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--background-darker), var(--background-card));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    border-bottom: 1px solid var(--border-color);
}

.placeholder-icon {
    font-size: 48px;
    opacity: 0.7;
    filter: grayscale(1);
    transition: var(--transition-fast);
}

.gallery-card:hover .placeholder-icon {
    filter: grayscale(0);
    transform: scale(1.1);
}

.placeholder-text {
    color: var(--text-secondary);
    font-size: var(--font-size-base);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    padding: 30px 20px 20px;
    transform: translateY(100%);
    transition: var(--transition-medium);
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.gallery-card:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-info {
    flex: 1;
}

.gallery-title {
    color: var(--text-primary);
    font-size: var(--font-size-large);
    font-weight: 700;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.gallery-description {
    color: var(--text-secondary);
    font-size: var(--font-size-small);
    margin: 0;
}

.gallery-zoom {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--background-dark);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: var(--transition-fast);
    margin-left: 15px;
    flex-shrink: 0;
}

.gallery-zoom:hover {
    background: var(--text-primary);
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(0, 255, 136, 0.5);
}

/* Load More Button */
.gallery-load-more {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Gallery Stats */
.gallery-stats {
    background: var(--background-card);
    padding: 60px 0;
    border-top: 1px solid var(--border-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    text-align: center;
}

/* Gallery CTA */
.gallery-cta {
    background: linear-gradient(135deg, var(--background-darker) 0%, var(--background-dark) 100%);
    padding: 80px 0;
    position: relative;
}

.gallery-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 255, 136, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 136, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
    animation: gridMove 15s linear infinite;
}

/* Filter Animation */
@keyframes filterFade {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-item[data-category] {
    animation: filterFade 0.5s ease-out;
}

/* Hover Effects */
.gallery-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(0, 255, 136, 0.1), transparent);
    opacity: 0;
    transition: var(--transition-fast);
    z-index: 1;
}

.gallery-card:hover::before {
    opacity: 1;
    animation: shimmer 1s ease-in-out;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .gallery-hero-title {
        font-size: 32px;
    }
    
    .gallery-hero-subtitle {
        font-size: var(--font-size-base);
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .gallery-tabs {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .nav-tab {
        padding: 10px 15px;
        font-size: var(--font-size-small);
    }
    
    .gallery-overlay {
        position: static;
        transform: none;
        background: rgba(0, 0, 0, 0.8);
        padding: 20px;
    }
    
    .gallery-title {
        font-size: var(--font-size-base);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

@media (max-width: 480px) {
    .gallery-hero {
        min-height: 40vh;
    }
    
    .gallery-hero-content {
        padding: 40px 0;
    }
    
    .gallery-section {
        padding: 40px 0;
    }
    
    .gallery-grid {
        margin-bottom: 40px;
    }
    
    .gallery-card {
        margin: 0 -5px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .gallery-cta {
        padding: 60px 0;
    }
}


.gallery-loading {
            display: none;
            text-align: center;
            padding: 40px;
        }
        
        .gallery-loading.active {
            display: block;
        }
        
        .loading-spinner {
            display: inline-block;
            width: 40px;
            height: 40px;
            border: 3px solid #f3f3f3;
            border-top: 3px solid #007bff;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }
        
        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }
        
        .gallery-error {
            display: none;
            text-align: center;
            padding: 40px;
            color: #dc3545;
        }
        
        .gallery-error.active {
            display: block;
        }
        
        .gallery-image img {
            width: 100%;
            height: 250px;
            object-fit: cover;
            border-radius: 8px;
            transition: transform 0.3s ease;
        }
        
        .gallery-image:hover img {
            transform: scale(1.05);
        }
        
        .gallery-placeholder {
            width: 100%;
            height: 250px;
            background: linear-gradient(45deg, #f0f0f0, #e0e0e0);
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            border-radius: 8px;
            color: #666;
        }
        
        .lightbox {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.9);
            z-index: 1000;
            justify-content: center;
            align-items: center;
        }
        
        .lightbox.active {
            display: flex;
        }
        
        .lightbox-content {
            max-width: 90%;
            max-height: 90%;
            position: relative;
        }
        
        .lightbox-image {
            width: 100%;
            height: auto;
            max-width: 100%;
            max-height: 100%;
            object-fit: contain;
        }
        
        .lightbox-close {
            position: absolute;
            top: -40px;
            right: 0;
            background: none;
            border: none;
            color: white;
            font-size: 30px;
            cursor: pointer;
            padding: 0;
            width: 40px;
            height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        
        .lightbox-info {
            position: absolute;
            bottom: -80px;
            left: 0;
            right: 0;
            color: white;
            text-align: center;
        }
        
        .lightbox-title {
            font-size: 18px;
            font-weight: bold;
            margin-bottom: 5px;
        }
        
        .lightbox-description {
            font-size: 14px;
            opacity: 0.8;
        }
        
        .gallery-item {
            opacity: 0;
            transform: translateY(20px);
            animation: fadeInUp 0.5s ease forwards;
        }
        
        @keyframes fadeInUp {
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }
        
        .category-counter {
            background: #007bff;
            color: white;
            padding: 2px 8px;
            border-radius: 12px;
            font-size: 12px;
            margin-left: 5px;
        }
        
        .no-images {
            text-align: center;
            padding: 60px 20px;
            color: #666;
        }
        
        .no-images h3 {
            margin-bottom: 10px;
            color: #999;
        }