body {
    margin: 0;
    font-family: 'Segoe UI', sans-serif;
    background: #f8f5f0;
}

.gallery-section {
    display: flex;
    min-height: 100vh;
    padding-top: 90px;
}

/* SIDEBAR */
.gallery-sidebar {
    width: 250px;
    background: #CBB28B;
    padding: 40px 20px;
    color: white;
}

.gallery-sidebar ul {
    list-style: none;
    padding: 0;
}

.gallery-sidebar li {
    padding: 12px;
    cursor: pointer;
    border-radius: 10px;
    margin-bottom: 10px;
}

.gallery-sidebar li.active {
    background: rgba(255,255,255,0.3);
}

/* GRID */
.gallery-content {
    flex: 1;
    padding: 40px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.gallery-item {
    height: 180px;
    overflow: hidden;
    border-radius: 12px;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* LIGHTBOX */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.9);
    display: none;
    align-items: center;
    justify-content: center;
}

.lightbox img {
    max-width: 70%;
    max-height: 60%;
}

.close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 35px;
    color: white;
    cursor: pointer;
}

.nav {
    position: absolute;
    top: 50%;
    font-size: 40px;
    color: white;
    cursor: pointer;
}

.prev { left: 20px; }
.next { right: 20px; }

/* RESPONSIVE */
@media(max-width:768px){
    .gallery-section {
        flex-direction: column;
    }

    .gallery-sidebar {
        width: 100%;
    }

    .gallery-grid {
        grid-template-columns: repeat(2,1fr);
    }
}

.lightbox {
    z-index: 999999; /* по-голям от header */
}

.lightbox .close {
    z-index: 1000000;
}