/* ==========================================================================
   proizvodstvo.html (ru/en/de) — страница «Наше производство».
   Свои классы .pr-*, старый .features-stanok на странице больше не
   используется. Цвета/шрифты — из styles.css: #4e4e4e текст,
   #66c6ba фирменный бирюзовый, Roboto Light/Thin/Regular.
   ========================================================================== */

.pr-page {
    color: #4e4e4e;
    font: 18px/1.55 'Roboto Light', sans-serif;
}
.pr-page img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* ---------- Шапка ---------- */
.pr-hero {
    padding: 50px 0 40px;
}
.pr-hero .block-title {
    margin: 0 0 30px;
}
.pr-mosaic {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 12px;
    height: 440px;
}
/* одно фото во всю ширину (здание на proizvodstvo.html) */
.pr-mosaic.pr-mosaic-single {
    display: block;
    height: auto;
}
.pr-mosaic.pr-mosaic-single img {
    display: block;
    height: auto;
    aspect-ratio: 16 / 9;
}
.pr-mosaic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}
.pr-lead {
    max-width: 900px;
    margin: 30px 0 0;
    font-size: 19px;
}
.pr-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 28px 0 0;
    padding: 0;
    list-style: none;
}
.pr-nav a {
    display: inline-block;
    padding: 9px 18px;
    border: 1px solid #66c6ba;
    border-radius: 20px;
    color: #4e4e4e;
    font: 15px 'Roboto Regular', sans-serif;
    text-decoration: none;
    transition: background .2s, color .2s;
}
.pr-nav a:hover {
    background: #66c6ba;
    color: #fff;
}

/* ---------- Заголовок группы (01 Металлообработка …) ---------- */
.pr-group {
    background: #f6f8f8;
    border-top: 1px solid #EBEBEC;
    border-bottom: 1px solid #EBEBEC;
    padding: 34px 0;
}
.pr-group .container {
    display: flex;
    align-items: baseline;
    gap: 20px;
}
.pr-group-num {
    font: 48px 'Roboto Thin', sans-serif;
    color: #66c6ba;
}
.pr-group .block-title {
    font-size: 40px;
    margin: 0;
}

/* ---------- Секция станка / участка ---------- */
.pr-section {
    padding: 50px 0;
    border-bottom: 1px solid #EBEBEC;
}
.pr-section:last-child {
    border-bottom: 0;
}
.pr-title {
    margin: 0 0 14px;
    font: 28px/1.25 'Roboto Regular', sans-serif;
    color: #4e4e4e;
}
.pr-title:after {
    content: "";
    display: block;
    width: 48px;
    height: 3px;
    margin-top: 14px;
    background: #66c6ba;
}
.pr-text {
    margin: 0;
    max-width: 900px;
}

/* Секция с галереей: текст сверху, галерея под ним */
.pr-section .pr-gallery {
    margin-top: 28px;
}
.pr-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.pr-gallery.pr-n2 {
    grid-template-columns: repeat(2, 1fr);
}
.pr-gallery img {
    width: 100%;
    height: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: 6px;
    cursor: zoom-in;
    transition: opacity .2s;
}
.pr-gallery img:hover {
    opacity: .88;
}

/* Секция с одним фото: фото и текст в две колонки, через раз меняются местами */
.pr-split .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}
.pr-split .pr-photo img {
    width: 100%;
    max-height: 440px;
    object-fit: cover;
    border-radius: 6px;
    cursor: zoom-in;
}
.pr-split.pr-flip .pr-photo {
    order: 2;
}
/* Станок + две мини-фото справа (SCK460) */
.pr-photo-duo {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
    height: 440px;
}
.pr-split .pr-photo-duo img {
    height: 100%;
    max-height: none;
}
.pr-photo-duo img:first-child {
    grid-row: span 2;
}

/* ---------- Просмотр фото крупно ---------- */
.pr-lb {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(20, 24, 26, .92);
}
.pr-lb.is-open {
    display: flex;
}
.pr-lb img {
    max-width: 92vw;
    max-height: 88vh;
    border-radius: 4px;
}
.pr-lb button {
    position: absolute;
    border: 0;
    background: none;
    color: #fff;
    font: 44px/1 Arial, sans-serif;
    cursor: pointer;
    padding: 10px 16px;
    opacity: .8;
}
.pr-lb button:hover {
    opacity: 1;
}
.pr-lb-x {
    top: 10px;
    right: 14px;
}
.pr-lb-prev {
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
}
.pr-lb-next {
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}

/* ---------- Мобильный ---------- */
@media (max-width: 860px) {
    .pr-page {
        font-size: 16px;
    }
    .pr-hero {
        padding: 24px 0 24px;
    }
    .pr-hero .block-title {
        margin-bottom: 18px;
    }
    .pr-mosaic {
        height: auto;
        grid-template-columns: 1fr;
        gap: 8px;
    }
    .pr-mosaic img {
        aspect-ratio: 3 / 2;
    }
    .pr-lead {
        margin-top: 18px;
        font-size: 16px;
    }
    .pr-nav {
        gap: 8px;
        margin-top: 18px;
    }
    .pr-nav a {
        padding: 7px 14px;
        font-size: 14px;
    }
    .pr-group {
        padding: 20px 0;
    }
    .pr-group .container {
        gap: 12px;
    }
    .pr-group-num {
        font-size: 30px;
    }
    .pr-group .block-title {
        font-size: 26px !important;
    }
    .pr-section {
        padding: 28px 0;
    }
    .pr-title {
        font-size: 21px;
    }
    .pr-title:after {
        margin-top: 10px;
    }
    .pr-section .pr-gallery {
        margin-top: 18px;
    }
    .pr-gallery,
    .pr-gallery.pr-n2 {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
    /* нечётное число фото — первое на всю ширину, чтобы не было дырки */
    .pr-gallery img:first-child:nth-last-child(2n+1) {
        grid-column: span 2;
    }
    .pr-split .container {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    .pr-split .pr-photo,
    .pr-split.pr-flip .pr-photo {
        order: 2;
    }
    .pr-split .pr-photo img {
        max-height: 360px;
    }
    .pr-photo-duo {
        height: auto;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto;
        gap: 8px;
    }
    .pr-split .pr-photo-duo img {
        height: auto;
        aspect-ratio: 3 / 2;
    }
    .pr-photo-duo img:first-child {
        grid-row: auto;
        grid-column: span 2;
        aspect-ratio: 4 / 3;
    }
    .pr-lb button {
        font-size: 34px;
    }
}
