/* Professional Gallery Slider */

.gallery-slider-container {
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-main-image {
    position: relative;
    width: 100%;
    height: 600px;
    background: var(--dark-card);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    margin-bottom: 20px;
}

.light-mode .gallery-main-image {
    background: #fff;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

#mainGalleryImg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95), rgba(0, 0, 0, 0.7), transparent);
    padding: 50px 30px 25px;
    color: white;
}

.gallery-caption h4 {
    font-size: 1.8rem;
    margin: 0;
    font-weight: 700;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
    line-height: 1.4;
    background: linear-gradient(135deg, #ffc107, #ff9800);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gallery-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border: none;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    z-index: 10;
}

.gallery-nav-btn:hover {
    background: var(--accent-blue);
    transform: translateY(-50%) scale(1.1);
}

.gallery-nav-btn.prev {
    right: 20px;
}

.gallery-nav-btn.next {
    left: 20px;
}

body[dir="ltr"] .gallery-nav-btn.prev {
    left: 20px;
    right: auto;
}

body[dir="ltr"] .gallery-nav-btn.next {
    right: 20px;
    left: auto;
}

.gallery-controls {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    padding: 10px 20px;
    border-radius: 50px;
    z-index: 10;
}

body[dir="ltr"] .gallery-controls {
    right: auto;
    left: 20px;
}

.gallery-control-btn {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 5px 10px;
}

.gallery-control-btn:hover {
    color: var(--accent-gold);
    transform: scale(1.2);
}

.gallery-counter {
    color: white;
    font-weight: 600;
    font-size: 1rem;
}

/* Thumbnails */
.gallery-thumbnails {
    display: none;
}

.thumbnail-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.thumbnail-item:hover img {
    transform: scale(1.1);
}

.thumbnail-item.active {
    border-color: var(--accent-blue);
    box-shadow: 0 0 20px rgba(0, 102, 204, 0.5);
}

.thumbnail-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.thumbnail-item:hover::after {
    opacity: 1;
}

.thumbnail-item.active::after {
    opacity: 0;
}

/* Responsive */
@media (max-width: 992px) {
    .gallery-main-image {
        height: 450px;
    }
    
    .gallery-thumbnails {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
    
    .thumbnail-item {
        height: 80px;
    }
    
    .gallery-caption {
        padding: 40px 25px 20px;
    }
    
    .gallery-caption h4 {
        font-size: 1.4rem;
    }
}

@media (max-width: 768px) {
    .gallery-main-image {
        height: 350px;
        border-radius: 15px;
    }
    
    .gallery-nav-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .gallery-nav-btn.prev {
        right: 10px;
    }
    
    .gallery-nav-btn.next {
        left: 10px;
    }
    
    body[dir="ltr"] .gallery-nav-btn.prev {
        left: 10px;
        right: auto;
    }
    
    body[dir="ltr"] .gallery-nav-btn.next {
        right: 10px;
        left: auto;
    }
    
    .gallery-controls {
        top: 10px;
        right: 10px;
        padding: 8px 15px;
        gap: 10px;
    }
    
    body[dir="ltr"] .gallery-controls {
        right: auto;
        left: 10px;
    }
    
    .gallery-control-btn {
        font-size: 1rem;
    }
    
    .gallery-counter {
        font-size: 0.9rem;
    }
    
    .gallery-thumbnails {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .thumbnail-item {
        height: 70px;
    }
    
    .gallery-caption {
        padding: 30px 20px 15px;
    }
    
    .gallery-caption h4 {
        font-size: 1.1rem;
        line-height: 1.3;
    }
}

@media (max-width: 480px) {
    .gallery-main-image {
        height: 280px;
        border-radius: 12px;
    }
    
    .gallery-thumbnails {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .thumbnail-item {
        height: 60px;
    }
    
    .gallery-nav-btn {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .gallery-caption {
        padding: 25px 15px 12px;
    }
    
    .gallery-caption h4 {
        font-size: 0.85rem;
        line-height: 1.3;
    }
}

/* Animation for image change */
@keyframes fadeInImage {
    from {
        opacity: 0;
        transform: scale(1.1);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-main-image img.fade-in {
    animation: fadeInImage 0.5s ease;
}
