/* Navigation buttons */
.nav-buttons {
    display: flex;
    gap: 0.5rem;
}

.nav-btn {
    padding: 0.5rem 1rem;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
    white-space: nowrap;
}

.nav-btn:hover {
    background-color: #2980b9;
}

/* Gallery container */
.gallery-container {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

.gallery-item {
    position: relative;
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    background-color: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    background-color: #f0f0f0;
}

.image-caption {
    padding: 0.75rem;
    text-align: center;
    background-color: white;
    color: #333;
    font-size: 0.9rem;
    border-top: 1px solid #eee;
}

.no-images {
    text-align: center;
    padding: 4rem 2rem;
    color: #666;
}

.no-images p {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.lightbox-img {
    max-width: 90%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-caption {
    color: white;
    font-size: 1.2rem;
    margin-top: 1rem;
    text-align: center;
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 40px;
    font-size: 40px;
    color: white;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: #ccc;
}

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    font-size: 30px;
    padding: 1rem 1.5rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border-radius: 4px;
}

.nav-arrow:hover {
    background-color: rgba(255, 255, 255, 0.4);
}

.nav-arrow.prev {
    left: 20px;
}

.nav-arrow.next {
    right: 20px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .gallery-container {
        padding: 1rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }

    .gallery-item img {
        height: 150px;
    }

    .image-caption {
        font-size: 0.8rem;
        padding: 0.5rem;
    }

    .lightbox-img {
        max-width: 95%;
        max-height: 70vh;
    }

    .close-btn {
        top: 10px;
        right: 15px;
        font-size: 30px;
    }

    .nav-arrow {
        font-size: 20px;
        padding: 0.5rem 1rem;
    }

    .nav-arrow.prev {
        left: 10px;
    }

    .nav-arrow.next {
        right: 10px;
    }

    .nav-btn {
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 0.75rem;
    }

    .gallery-item img {
        height: 120px;
    }
}
