/* Styl Lightboxa */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.lightbox-content {
    position: relative;
    max-width: 80%;
    max-height: 80%;
    text-align: center;
}

#lightbox-img {
    max-width: 100%;
    max-height: 70vh;
    border: 3px solid white;
    border-radius: 4px;
}

#lightbox-caption {
    color: white;
    margin-top: 15px;
    background: rgba(0, 0, 0, 0.5);
    padding: 15px;
    border-radius: 8px;
}

#lightbox-title {
    margin: 0 0 5px 0;
    color: #fff;
    font-size: 1.5rem;
}

#lightbox-desc {
    margin: 0;
    color: #ccc;
    font-size: 1rem;
}

/* Przyciski */
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 40px;
    cursor: pointer;
}

/* Kontener trzymający strzałki i tekst w jednej linii */
.caption-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    max-width: 900px;
    /* Możesz dopasować do szerokości zdjęcia */
    margin: 0 auto;
}

/* Styl tekstu w środku */
.caption-text {
    flex: 1;
    /* Tekst zajmie całą dostępną przestrzeń między strzałkami */
    text-align: center;
}

/* Styl strzałek */
.lightbox-prev,
.lightbox-next {
    position: static;
    /* Usuwamy stare pozycjonowanie */
    transform: none;
    background: rgba(255, 255, 255, 0.1);
    /* Delikatne tło */
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-size: 30px;
    cursor: pointer;
    padding: 10px 20px;
    border-radius: 8px;
    transition: 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Na małych ekranach */
@media (max-width: 480px) {

    .lightbox-prev,
    .lightbox-next {
        padding: 5px 15px;
        font-size: 24px;
    }

    #lightbox-title {
        font-size: 1.2rem;
    }
}