/* Gallery Section */
#gallery {
    padding: 5rem 0;
    background-color: #0f172a;
    color: #ffffff;
    position: relative;
}

#gallery h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    text-align: center;
    color: #ffffff;
}

#gallery .section-subtitle {
    color: #94a3b8;
    text-align: center;
    max-width: 600px;
    margin: 0 auto 4rem;
}

/* Image Grid */
#imageGrid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 1rem;
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    aspect-ratio: 1;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-card {
    position: relative;
    width: 100%;
    height: 100%;
}

.gallery-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    font-size: 0.9rem;
    margin: 0;
    font-weight: 500;
}

#imageGrid .card-body {
    padding: 1rem 0;
}

#imageGrid .card-text {
    color: #94a3b8;
    font-size: 0.9rem;
    margin: 0;
}

/* Lightbox Customization */
.lb-outerContainer {
    border-radius: 10px;
    overflow: hidden;
}

.lb-data .lb-caption {
    font-size: 1rem;
    color: #ffffff;
    text-align: center;
}

.lb-nav a.lb-prev,
.lb-nav a.lb-next {
    opacity: 0.8;
}

.lb-nav a.lb-prev:hover,
.lb-nav a.lb-next:hover {
    opacity: 1;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    #portfolioCarousel .carousel-item img {
        height: 350px;
    }
    
    #imageGrid .card-img-top {
        height: 200px;
    }
}

@media (max-width: 576px) {
    #portfolioCarousel .carousel-item img {
        height: 250px;
    }
    
    #imageGrid .card-img-top {
        height: 180px;
    }
    
    #portfolio h2 {
        font-size: 2rem;
    }
    
    #portfolio .section-subtitle {
        font-size: 1rem;
    }
}
