body{
    background-color: black;
    color: white;
    font-family: "Playfair Display", serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-size: 1.125rem;
    width: 100vw;
    display: flex;
    justify-content: center;
}

@font-face {
    font-family: 'Izvod';
    src: url('../fonts/Izvod.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

#header{
    text-align: center;
    #logo {
        font-family: 'Izvod', Arial, sans-serif;
        font-size: 60px;
    }
    #contacts{
        font-family: "Helvetica", serif;
        font-size: 36px;
        display: flex;
        justify-content: center;
        gap: 20px;

        #vk{
            a{
                color: #436EAB;
            }
        }
        #tg{
            a{
                color: #27a7e7;
            }
        }
        a{
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }
        .contact-icon{
            width: 28px;
            height: 28px;
            vertical-align: middle;
        }
    }
}



#wrapper{
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 80vw;
}

#photo{
    display: flex;
    justify-content: center;

    img{
        display: block;
        width: 100%;
        height: auto;
    }
}

h1{
    text-align: center;
}

/* Галереи работ */
#portfolio {
    width: 100%;
    margin: 2rem 0;
}

#portfolio .galleries {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

#portfolio .gallery h2 {
    font-size: 1.1rem;
    font-weight: 500;
    text-align: center;
    margin: 0 0 1rem;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.9);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    width: 100%;
}

.gallery-grid img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    display: block;
    border-radius: 6px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.gallery-grid img {
    cursor: pointer;
}

.gallery-grid img:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

/* Лайтбокс для увеличения фото */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.92);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    cursor: pointer;
}

.lightbox-content {
    position: relative;
    z-index: 1;
    max-width: 95vw;
    max-height: 95vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 95vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    pointer-events: none;
}

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-size: 1.75rem;
    line-height: 1;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.2s;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.25);
}

.gallery-black img {
    filter: grayscale(100%);
}

.gallery-black img:hover {
    filter: grayscale(80%);
}

@media (max-width: 700px) {
    #portfolio .galleries {
        grid-template-columns: 1fr;
    }
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .gallery-grid img:nth-child(10) {
        display: none;
    }
}

/* Слайдер отзывов — показываем 3 отзыва */
#reviews {
    width: 100%;
    margin: 2rem 0;
}

.reviews-slider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    position: relative;
}

.reviews-slider-viewport {
    flex: 1;
    overflow: hidden;
    width: 100%;
}

.reviews-track {
    display: flex;
    transition: transform 0.4s ease-out;
    will-change: transform;
}

.review-slide {
    flex: 0 0 33.333%;
    min-width: 33.333%;
    padding: 1rem 0.75rem;
    box-sizing: border-box;
}

.review-box {
    height: 100%;
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    display: flex;
    flex-direction: row;
    gap: 1rem;
    align-items: center;
}

.review-work {
    width: 100px;
    min-width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}

.review-box p {
    margin: 0;
    flex: 1;
    min-width: 0;
    font-size: 0.95rem;
    line-height: 1.5;
}

.slider-btn {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s;
    line-height: 1;
    padding: 0;
}

.slider-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.6);
}

.slider-btn:active {
    background: rgba(255, 255, 255, 0.2);
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.slider-dots .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.slider-dots .dot:hover {
    background: rgba(255, 255, 255, 0.5);
}

.slider-dots .dot.active {
    background: white;
    transform: scale(1.2);
}

@media (max-width: 900px) {
    .review-slide {
        flex: 0 0 100%;
        min-width: 100%;
    }
    .reviews-slider .slider-btn {
        position: absolute;
        z-index: 2;
    }
    .slider-prev { left: 0; }
    .slider-next { right: 0; }
}


@media (max-width: 550px) {
    #contacts {
        gap: 10px;
        flex-direction: column;
    }
    .review-box{
        flex-direction: column;
    }
}
