/* ============================================================
   LUNA GLAMPING — gallery.css
   Grid masonry + lightbox
   ============================================================ */

.lg-gallery-section {
    padding: var(--lg-space-20) 0;
    background: var(--lg-white);
    overflow: hidden;
}

.lg-gallery-section .lg-container {
    margin-bottom: var(--lg-space-10);
}

/* ── Grid ── */
.lg-gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 200px;
    gap: 6px;
    max-width: var(--lg-container);
    margin-inline: auto;
    padding-inline: var(--lg-space-6);
}

/* ── Item ── */
.lg-gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: var(--lg-radius);
    cursor: zoom-in;
    background: var(--lg-mist);
    border: none;
    padding: 0;
    display: block;
}

.lg-gallery-item--wide {
    grid-column: span 2;
}

.lg-gallery-item__img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform var(--lg-transition-slow), filter var(--lg-transition);
}

/* Placeholdere colorate până la imagini reale */
.lg-gallery-item__img--1 {
    background-color: #1a3010;
    background-image: radial-gradient(ellipse at 30% 50%, rgba(60, 100, 30, 0.8) 0%, transparent 70%),
                      radial-gradient(ellipse at 80% 30%, rgba(20, 50, 10, 0.6) 0%, transparent 60%);
}
.lg-gallery-item__img--2 {
    background-color: #2c1f10;
    background-image: radial-gradient(ellipse at 50% 40%, rgba(100, 70, 30, 0.7) 0%, transparent 70%);
}
.lg-gallery-item__img--3 {
    background-color: #0d2030;
    background-image: radial-gradient(ellipse at 40% 60%, rgba(30, 80, 120, 0.6) 0%, transparent 70%),
                      radial-gradient(ellipse at 70% 30%, rgba(10, 50, 80, 0.5) 0%, transparent 60%);
}
.lg-gallery-item__img--4 {
    background-color: #1a1005;
    background-image: radial-gradient(ellipse at 50% 70%, rgba(200, 100, 20, 0.6) 0%, transparent 60%);
}
.lg-gallery-item__img--5 {
    background-color: #0a1a20;
    background-image: radial-gradient(ellipse at 30% 40%, rgba(30, 80, 110, 0.5) 0%, transparent 65%);
}
.lg-gallery-item__img--6 {
    background-color: #1f1008;
    background-image: radial-gradient(ellipse at 60% 50%, rgba(150, 80, 20, 0.5) 0%, transparent 65%);
}
.lg-gallery-item__img--7 {
    background-color: #101a08;
    background-image: radial-gradient(ellipse at 50% 50%, rgba(40, 90, 20, 0.6) 0%, transparent 70%),
                      linear-gradient(to bottom, rgba(10, 30, 5, 0.3) 0%, transparent 50%);
}
.lg-gallery-item__img--8 {
    background-color: #1a2030;
    background-image: radial-gradient(ellipse at 40% 50%, rgba(50, 90, 150, 0.5) 0%, transparent 65%);
}

/* Label placeholder */
.lg-gallery-item__img::after {
    content: '';
    position: absolute;
    inset: 0;
    background: inherit;
}

/* Hover */
.lg-gallery-item:hover .lg-gallery-item__img {
    transform: scale(1.06);
    filter: brightness(0.85);
}

/* Overlay iconiță zoom */
.lg-gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(28, 28, 28, 0);
    transition: background var(--lg-transition);
    border-radius: inherit;
}

.lg-gallery-item:hover::after {
    background: rgba(28, 28, 28, 0.2);
}

/* ── Lightbox ── */
.lg-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(10, 10, 8, 0.96);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--lg-space-4);
}

.lg-lightbox[hidden] { display: none; }

.lg-lightbox__stage {
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lg-lightbox__image {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: var(--lg-radius);
    box-shadow: 0 32px 100px rgba(0,0,0,0.7);
}

.lg-lightbox__close,
.lg-lightbox__prev,
.lg-lightbox__next {
    position: fixed;
    background: rgba(250, 247, 242, 0.08);
    color: var(--lg-cream);
    border: 1px solid rgba(250, 247, 242, 0.15);
    border-radius: 50%;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: background var(--lg-transition-fast);
    backdrop-filter: blur(4px);
}

.lg-lightbox__close:hover,
.lg-lightbox__prev:hover,
.lg-lightbox__next:hover {
    background: rgba(250, 247, 242, 0.16);
}

.lg-lightbox__close { top: var(--lg-space-6); right: var(--lg-space-6); font-size: 26px; }
.lg-lightbox__prev  { left: var(--lg-space-4); top: 50%; transform: translateY(-50%); }
.lg-lightbox__next  { right: var(--lg-space-4); top: 50%; transform: translateY(-50%); }

/* ── Tablet+ ── */
@media (min-width: 640px) {
    .lg-gallery-grid {
        grid-template-columns: repeat(3, 1fr);
        grid-auto-rows: 220px;
        gap: 8px;
    }
    .lg-lightbox__prev { left: var(--lg-space-8); }
    .lg-lightbox__next { right: var(--lg-space-8); }
}

@media (min-width: 1024px) {
    .lg-gallery-grid {
        grid-template-columns: repeat(4, 1fr);
        grid-auto-rows: 240px;
    }

    .lg-gallery-item--wide {
        grid-column: span 2;
    }
}
