.gallery-page {
    background-color: #f4f4f4;
    padding: 120px 0 60px;
}
.header-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 0 20px;
    gap: 40px;
}
.header-text h1 {
    font-size: 2.5rem;
    font-weight: 800;
    flex: 1;
    line-height: 1.1;
    margin: 0;
}
.header-text p {
    flex: 1;
    color: #666;
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.5;
}
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    grid-auto-rows: auto;
    grid-auto-flow: dense;
    gap: 15px;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}
.gallery img {
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    object-fit: cover;
    border-radius: 4px;
    display: block;
    cursor: pointer;
    image-rendering: auto;
    transition: transform 0.3s ease, filter 0.3s ease;
    border: 1px solid #008ac9;
}
.gallery img:nth-child(3n) {
    grid-column: span 2;
}
.gallery img:nth-child(5n) {
    aspect-ratio: auto;
}
#lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
#lightbox img {
    max-width: 85%;
    max-height: 85%;
    border-radius: 4px;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: 2px solid rgba(255,255,255,0.1);
}
#lightbox img.show {
    transform: scale(1);
}
#close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 3rem;
    color: white;
    cursor: pointer;
    background: none;
    border: none;
    z-index: 2100;
}
#lightbox .nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem;
    color: white;
    cursor: pointer;
    background: none;
    border: none;
    padding: 20px;
    transition: color 0.3s;
}
#lightbox .nav:hover {
    color: #008ac9;
}
#lightbox .prev {
    left: 10px;
}
#lightbox .next {
    right: 10px;
}
@media (max-width: 768px) {
    .header-text {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(100%, 1fr));
        grid-auto-rows: auto;
    }
    .gallery img:nth-child(3n), .gallery img:nth-child(5n) {
        grid-column: span 1;
        grid-row: span 1;
    }
}
