/* CSS Document */

.poetry-wrapper {
    max-width: 1200px;
    width: 95%;


}

.poetry-layout {
    display: grid;
    grid-template-columns: 50% 50%;
    gap: 30px;
    align-items: start;
}

/* POEM ON THE LEFT */

.poem-text {
    min-width: 0;
    padding: 5px;
    color: #102e46;
    font-family: 'Tinos', Georgia, serif;
}

.poem-text h1 {
    margin: 0 0 25px;
    font-size: 42px;
    line-height: 1.2;
    color: #102e46;
}

.poem-text h1::after {
    content: "";
    display: block;
    width: 130px;
    height: 8px;
    margin-top: 14px;
    background: #e87516;
    border-radius: 50%;
}

.poem-text .poem {
    font-size: 19px;
    line-height: 1.65;
}

.poem-text .poem-signature {
    margin-top: 25px;
    font-size: 17px;
    font-style: italic;
}

/* PHOTOS ON THE RIGHT */

.poetry-gallery {
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 16px;
}

.poetry-gallery .gallery-item {
    position: relative;
    display: block;
    width: 100%;

    padding: 0;
    overflow: hidden;
    border: 4px solid #fff;
    background: #ddd;
    box-shadow: 0 3px 10px rgba(0,0,0,.2);
    cursor: pointer;
}

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

.poetry-gallery .gallery-item:hover img {
    transform: scale(1.06);
}

.gallery-zoom {
    position: absolute;
    right: 12px;
    bottom: 12px;
    color: white;
    font-size: 27px;
    text-shadow: 0 2px 5px black;
}

/* LIGHTBOX */

.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    padding: 55px 70px;
    background: rgba(10, 20, 28, .96);
    align-items: center;
    justify-content: center;
}

.lightbox.show {
    display: flex;
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90%;
    max-height: 90%;
}

.lightbox-content img {
    display: block;
    max-width: 100%;
    max-height: 78vh;
    object-fit: contain;
    border: 4px solid white;
    box-shadow: 0 5px 30px rgba(0,0,0,.5);
}

.lightbox-caption {
    margin-top: 12px;
    color: #fff3dc;
    font-family: 'Tinos', Georgia, serif;
    font-size: 19px;
    text-align: center;
}

.lightbox-button {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    color: white;
    background: #e84424;
    font-size: 20px;
    cursor: pointer;
    transition: background .2s;
}

.lightbox-button:hover {
    color: #102e46;
    background: #ffd23f;
}

.lightbox-close {
    top: 20px;
    right: 25px;
}

.lightbox-prev {
    left: 20px;
    top: 50%;
}

.lightbox-next {
    right: 20px;
    top: 50%;
}

.lightbox-counter {
    position: absolute;
    bottom: 18px;
    color: white;
    font-family: 'Tinos', Georgia, serif;
    font-size: 16px;
}

/* MOBILE */

@media (max-width: 800px) {
    .poetry-wrapper {
        padding: 25px;
    }

    .poetry-layout {
        grid-template-columns: 1fr;
    }

    .poem-text h1 {
        font-size: 34px;
    }

    .poetry-gallery .gallery-item {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .poetry-wrapper {
        padding: 18px;
    }

    .poetry-gallery {
        grid-template-columns: 1fr;
    }

    .poetry-gallery .gallery-item {
        height: 240px;
    }

    .lightbox {
        padding: 50px 15px;
    }

    .lightbox-prev {
        left: 8px;
    }

    .lightbox-next {
        right: 8px;
    }
}