/* styles.css - Мебельная фабрика "Баньян" (финальная версия с логотипом слева в футере) */
/* Все акцентные цвета: #5A3D30 */
/* Хедер: увеличен на 20%, лого и текст крупнее, текст "мебельная фабрика" в две строки */
/* Футер: чёрный фон, белый текст, белые иконки. Один логотип (logo2.png) высотой 80px, выровнен по левому краю */
/* Заголовки секций: чёрный */
/* Карточки направлений: БЕЗ АНИМАЦИЙ, только курсор-pointer */
/* Кружочки этапов работы: ПОЛНОСТЬЮ СТАТИЧНЫЕ, без подсветки и трансформаций */
/* Видео: слайдер с 3 видимыми клипами (десктоп), адаптация под 2 и 1 */
/* Библиотека: фото увеличены в 1,5 раза (2 ряда по 3), отступ от хедера, якорный отступ */

/* ===== ОБЩИЕ СТИЛИ ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --container-width: 1410px;
    --container-padding: 30px;
    --font-default: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --bg-body: #ffffff;
    --color-text: #000000;
    --color-white: #ffffff;
    --color-black: #000000;
    --primary-color: #5A3D30;
    --primary-dark: #4a3327;
    --secondary-color: #000000;
    --accent-color: #e9c46a;
    --light-color: #f9f9f9;
    --dark-color: #000000;
    --gray-dark: #333333;
    --text-light: #666666;
    --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.15);
}

body {
    font-family: var(--font-default);
    font-size: 15px;
    line-height: 1.5;
    color: var(--color-text);
    background-color: var(--bg-body);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

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

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    border: 0;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* ===== КНОПКИ ===== */
.btn {
    display: inline-block;
    padding: 14px 35px;
    background-color: var(--primary-color);
    color: var(--color-white);
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    overflow: hidden;
    font-size: 16px;
    box-shadow: 0 4px 12px rgba(90, 61, 48, 0.2);
}

.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(90, 61, 48, 0.3);
}

.btn:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* ===== СЕКЦИИ ===== */
.section {
    padding: 120px 0;
    scroll-margin-top: 100px;
}

.section-header {
    text-align: center;
    margin-bottom: 70px;
}

.section-header h1 {
    font-size: clamp(1.6rem, 4vw, 3rem);
    color: var(--secondary-color);
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    position: relative;
    padding-bottom: 25px;
}

.section-header h1::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.section-header h1 i {
    color: var(--primary-color);
    font-size: 2.8rem;
}

.section-description {
    font-size: 1.3rem;
    color: var(--text-light);
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ===== ХЕДЕР (УВЕЛИЧЕН НА 20%) ===== */
header {
    background-color: #000000;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    padding: 19px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: padding 0.3s ease, background-color 0.3s ease;
}

/* Эффект при скролле */
header.header-scrolled {
    padding: 8px 0;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    position: relative;
}

/* Левая группа: логотип + текст */
.header-left {
    display: flex;
    align-items: center;
}

.logo-wrapper {
    display: flex;
    align-items: center;
    position: relative;
    padding: 5px 0;
    z-index: 1;
    transform: translateX(-10px);
}

.logo-link {
    display: block;
    position: relative;
    padding: 2px 0;
}

.logo-link::before {
    content: '';
    position: absolute;
    top: -8px;
    left: -12px;
    right: -12px;
    bottom: -8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.logo-link:hover::before,
.logo-link:focus-visible::before {
    opacity: 1;
}

.logo {
    height: 58px;
    width: auto;
    max-width: 173px;
    display: block;
    filter: brightness(0) invert(1);
    transition: transform 0.3s var(--transition), filter 0.3s ease;
    transform-origin: left center;
    position: relative;
    z-index: 2;
}

.logo:hover,
.logo:focus-visible {
    transform: scale(1.03);
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.3));
}

.logo2 {
    height: 40px;
    width: auto;
    max-width: 120px;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
    transition: transform 0.3s var(--transition), filter 0.3s ease;
    transform-origin: left center;
    position: relative;
    z-index: 2;
}

.logo2:hover,
.logo2:focus-visible {
    transform: scale(1.03);
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.3));
}

/* Текст справа от логотипа — две строки */
.header-brand-text {
    font-family: 'PT Serif', serif;
    font-weight: 700;
    font-size: 25px;
    color: #ffffff;
    margin-left: 0px;
    line-height: 1.2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex-shrink: 1;
}

.header-brand-text span {
    display: block;
}

.main-nav {
    display: flex;
}

#navMenu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 0;
    position: relative;
    transition: color 0.3s ease, transform 0.2s ease;
    white-space: nowrap;
    letter-spacing: 0.3px;
}

.nav-link:hover,
.nav-link:focus-visible {
    color: white;
    transform: translateY(-1px);
}

.nav-link.active {
    color: white;
    font-weight: 600;
}

.contact-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white !important;
    padding: 10px 22px;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s var(--transition);
    display: inline-block;
    box-shadow: 0 4px 15px rgba(90, 61, 48, 0.25);
    position: relative;
    overflow: hidden;
    border: none;
    cursor: pointer;
    font-size: 14px;
}

.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.2), 
        transparent);
    transition: left 0.7s ease;
}

.contact-btn:hover,
.contact-btn:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(90, 61, 48, 0.4);
    background: linear-gradient(135deg, var(--primary-dark), #3e2b21);
}

.contact-btn:hover::before,
.contact-btn:focus-visible::before {
    left: 100%;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.3s ease, transform 0.2s ease;
    position: relative;
    z-index: 1001;
}

.mobile-menu-btn:hover,
.mobile-menu-btn:focus-visible {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    backdrop-filter: blur(3px);
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ===== ГЕРОЙ ===== */
#home {
    padding-top: 0;
    margin-top: 0;
}

.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    max-height: 1200px;
    overflow: hidden;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.4));
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    color: var(--color-white);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    backdrop-filter: blur(2px);
}

.hero-content h1 {
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    margin-bottom: 30px;
    line-height: 1.2;
    max-width: 1000px;
    text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7);
}

.hero-content .year {
    color: var(--accent-color);
    font-weight: 800;
    font-size: 4rem;
}

.hero-content p {
    font-size: 1.4rem;
    max-width: 800px;
    margin-bottom: 50px;
    opacity: 0.95;
    line-height: 1.7;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.hero-brand {
    font-family: 'PT Serif', serif;
    font-weight: 700;
    color: inherit;
}

.hero-buttons {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 40px;
}

.hero-btn {
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.25);
    font-size: 1.2rem;
    padding: 18px 35px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
    font-weight: 600;
    color: white;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.hero-btn:hover,
.hero-btn:focus-visible {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

/* ===== О ФАБРИКЕ ===== */
.about-factory {
    background-color: var(--light-color);
    padding: 100px 0;
}

.factory-header {
    text-align: center;
    margin-bottom: 60px;
}

.factory-header h2 {
    font-size: clamp(1.6rem, 4vw, 2.8rem);
    color: var(--secondary-color);
    margin-bottom: 25px;
    position: relative;
    display: inline-block;
    font-family: 'PT Serif', serif;
    font-weight: 700;
}

.factory-header h2::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.factory-brand {
    /* наследуется от h2 */
}

.factory-description {
    font-size: 1.3rem;
    color: var(--text-light);
    max-width: 800px;
    margin: 40px auto 0;
    line-height: 1.7;
    font-style: italic;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
}

.factory-cards {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.factory-card {
    flex: 1;
    min-width: 300px;
    max-width: 380px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s var(--transition), box-shadow 0.4s var(--transition);
    background-color: var(--color-white);
}

.factory-card:hover,
.factory-card:focus-within {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.factory-imgwrapper {
    width: 100%;
    height: 400px;
    overflow: hidden;
}

.factory-imgwrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--transition);
}

.factory-card:hover .factory-imgwrapper img,
.factory-card:focus-within .factory-imgwrapper img {
    transform: scale(1.05);
}

/* ===== НАШИ НАПРАВЛЕНИЯ (БЕЗ АНИМАЦИЙ) ===== */
.advantages-cafmebel {
    background-color: #f9f9f9;
    padding: 100px 0;
}

.advantages-cafmebel h2 {
    font-size: clamp(1.6rem, 4vw, 2.8rem);
    color: var(--secondary-color);
    margin-bottom: 70px;
    text-align: center;
    position: relative;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.advantages-cafmebel h2::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.adv-cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.adv-card {
    background: var(--color-white);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    display: block;
    width: 100%;
    max-width: 350px;
    text-decoration: none;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    padding-bottom: 30px;
    cursor: pointer;
    transition: none;
}

.adv-imgwrapper {
    width: 100%;
    height: 350px;
    position: relative;
    overflow: hidden;
    border-radius: 20px 20px 0 0;
}

.adv-bgimg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 20px 20px 0 0;
    transition: none;
}

.adv-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
    border-radius: 20px 20px 0 0;
    transition: none;
}

.adv-img-title {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    text-align: center;
    width: 90%;
}

.adv-img-title h3 {
    font-size: 2.3rem;
    color: var(--color-white);
    margin: 0;
    font-weight: 700;
    letter-spacing: -0.3px;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
    line-height: 1.2;
    transition: none;
}

.adv-content {
    padding: 30px 25px 20px;
    text-align: center;
}

.adv-content p {
    color: var(--text-light);
    line-height: 1.6;
    font-size: 1.25rem;
    margin: 0;
}

/* ===== ЭТАПЫ РАБОТ (ПОЛНОСТЬЮ СТАТИЧНЫЕ, БЕЗ АНИМАЦИЙ) ===== */
.work-advantages {
    background-color: #f9f9f9;
    padding: 120px 0;
}

.work-steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 60px 30px;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.work-step {
    text-align: center;
    position: relative;
}

.work-step-circle {
    width: 220px;
    height: 220px;
    margin: 0 auto 30px;
    position: relative;
}

.work-step-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 8px solid var(--color-white);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.work-step-content h3 {
    font-size: 1.4rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
    line-height: 1.4;
    font-weight: 600;
    min-height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Стрелки (десктоп) */
@media (min-width: 1200px) {
    .work-step:nth-child(1)::after,
    .work-step:nth-child(2)::after,
    .work-step:nth-child(3)::after,
    .work-step:nth-child(5)::after,
    .work-step:nth-child(6)::after,
    .work-step:nth-child(7)::after {
        content: '';
        position: absolute;
        top: 110px;
        right: -45px;
        width: 60px;
        height: 3px;
        background-color: var(--primary-color);
    }
    
    .work-step:nth-child(1)::before,
    .work-step:nth-child(2)::before,
    .work-step:nth-child(3)::before,
    .work-step:nth-child(5)::before,
    .work-step:nth-child(6)::before,
    .work-step:nth-child(7)::before {
        content: '';
        position: absolute;
        top: 103px;
        right: -45px;
        width: 15px;
        height: 15px;
        border-right: 3px solid var(--primary-color);
        border-top: 3px solid var(--primary-color);
        transform: rotate(45deg);
        z-index: 2;
    }
}

/* ===== ВИДЕО-СЛАЙДЕР (3 ВИДИМЫХ НА ДЕСКТОПЕ) ===== */
.video-section {
    background-color: var(--color-white);
}

.video-section h2 {
    font-size: clamp(1.6rem, 4vw, 2.8rem);
    color: var(--secondary-color);
    margin-bottom: 25px;
    text-align: center;
    position: relative;
    text-transform: none;
    font-family: 'PT Serif', serif;
}

.video-section h2::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.video-description {
    max-width: 850px;
    margin: 0 auto 70px;
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.3rem;
    text-align: center;
}

.video-slider {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 50px;
}

.slider-wrapper {
    overflow: hidden;
    border-radius: 18px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.slider-track {
    display: flex;
    transition: transform 0.4s ease-in-out;
}

.slider-item {
    flex: 0 0 calc(100% / 3);
    padding: 0 5px;
    box-sizing: border-box;
}

.slider-item iframe {
    width: 100%;
    height: auto;
    aspect-ratio: 363 / 714;
    display: block;
    border: none;
    background-color: #000;
    border-radius: 18px;
}

.slider-prev,
.slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s var(--transition);
    box-shadow: 0 4px 12px rgba(90, 61, 48, 0.3);
    z-index: 10;
}

.slider-prev {
    left: -10px;
}

.slider-next {
    right: -10px;
}

.slider-prev:hover,
.slider-next:hover {
    background: var(--primary-dark);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 8px 20px rgba(90, 61, 48, 0.5);
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.slider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(90, 61, 48, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background: var(--primary-color);
    transform: scale(1.3);
}

/* ===== БИБЛИОТЕКА (ФОТО 2 РЯДА ПО 3 + ЯКОРНЫЙ ОТСТУП) ===== */
.library-section {
    background-color: #fff;
    padding: 100px 0;
    margin-top: 80px;
}

.library-section h2,
.library-section h1 {
    font-size: 2.8rem;
    color: var(--secondary-color);
    margin-bottom: 25px;
    text-align: center;
    position: relative;
}

.library-section h2::after,
.library-section h1::after {
    display: none;
}

.library-description {
    max-width: 800px;
    margin: 0 auto 70px;
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.3rem;
    text-align: center;
}

.library-albums {
    display: flex;
    flex-direction: column;
    gap: 80px;
    max-width: 1200px;
    margin: 0 auto;
}

.album {
    background: var(--light-color);
    border-radius: 30px;
    padding: 40px 30px;
    box-shadow: var(--shadow-sm);
    scroll-margin-top: 100px;
}

.album h3 {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 15px;
    font-family: 'PT Serif', serif;
    font-weight: 700;
}

.album h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.album-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.album-gallery img {
    width: 100%;
    height: 360px;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
}

.album-gallery img:hover {
    box-shadow: var(--shadow-md);
}

/* ===== КОНТАКТЫ ===== */
.section-contact {
    background-color: var(--color-white);
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    height: 600px;
    border-radius: 18px;
    overflow: hidden;
    margin: 70px 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Левая колонка с фото */
.contact-info-image {
    background-color: var(--gray-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
}

.contact-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Правая колонка с картой */
.contact-map {
    height: 100%;
    background-color: #000;
}

.contact-map iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* ===== ФОРМЫ ===== */
.form-group {
    margin-bottom: 30px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 20px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 1.1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    font-family: inherit;
    background-color: #fafafa;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 4px rgba(90, 61, 48, 0.1);
    background-color: var(--color-white);
}

.form-group textarea {
    resize: vertical;
    min-height: 180px;
    line-height: 1.6;
}

.honeypot {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
    height: 0;
    width: 0;
}

/* ===== КНОПКА «НАВЕРХ» ===== */
.scroll-top-btn {
    position: fixed;
    bottom: 120px;
    right: 35px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--color-white);
    border: none;
    border-radius: 50%;
    font-size: 1.8rem;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(90, 61, 48, 0.4);
    z-index: 998;
    transition: all 0.3s var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.scroll-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top-btn:hover,
.scroll-top-btn:focus-visible {
    background: linear-gradient(135deg, var(--primary-dark), #3e2b21);
    transform: translateY(-8px) scale(1.15);
    box-shadow: 0 15px 35px rgba(90, 61, 48, 0.5);
}

/* ===== ПЛАВАЮЩАЯ КНОПКА ===== */
.floating-contact-btn {
    position: fixed;
    bottom: 35px;
    right: 35px;
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--color-white);
    border: none;
    border-radius: 50%;
    font-size: 2rem;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(90, 61, 48, 0.5);
    z-index: 999;
    transition: all 0.3s var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 10px 30px rgba(90, 61, 48, 0.5); }
    50% { box-shadow: 0 15px 40px rgba(90, 61, 48, 0.7); }
    100% { box-shadow: 0 10px 30px rgba(90, 61, 48, 0.5); }
}

.floating-contact-btn:hover,
.floating-contact-btn:focus-visible {
    background: linear-gradient(135deg, var(--primary-dark), #3e2b21);
    transform: scale(1.15) rotate(10deg);
    box-shadow: 0 20px 45px rgba(90, 61, 48, 0.6);
}

/* ===== МОДАЛЬНОЕ ОКНО (очень прозрачное, крестик вверху справа) ===== */
.contact-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); 
    z-index: 1001;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 25px;
    backdrop-filter: blur(1px);            /* минимальное размытие */
}

.contact-modal.active {
    display: flex;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; backdrop-filter: blur(0); }
    to { opacity: 1; backdrop-filter: blur(1px); }
}

.contact-modal-content {
    background: rgba(255, 255, 255, 0.85); /* полупрозрачный белый */
    backdrop-filter: blur(3px);
    border-radius: 25px;
    width: 100%;
    max-width: 550px;
    padding: 55px 55px 55px;
    position: relative;
    animation: modalSlideIn 0.4s var(--transition);
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
}

/* Усиленная тень для текста, чтобы он оставался читаемым */
.contact-modal-content h3,
.contact-modal-content p,
.contact-modal-content label {
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.8);
}

@keyframes modalSlideIn {
    from { opacity: 0; transform: translateY(-60px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-light);
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease, background-color 0.3s ease;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    z-index: 10;
}

.close-modal:hover,
.close-modal:focus-visible {
    color: #e76f51;
    background-color: rgba(0, 0, 0, 0.05);
    transform: rotate(90deg);
}

/* Увеличенный заголовок модального окна */
.contact-modal-content h3 {
    color: var(--secondary-color);
    margin-bottom: 35px;
    font-size: 2.5rem;
    text-align: center;
    position: relative;
    padding-bottom: 20px;
}

.contact-modal-content h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

/* Улучшенный блок контактной информации */
.modal-contact-info {
    margin-top: 45px;
    padding-top: 35px;
    border-top: 1px solid #e0e0e0;
}

.modal-contact-title {
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 25px;
    font-size: 1.4rem;
    letter-spacing: 0.3px;
}

.modal-contact-info p {
    margin-bottom: 20px;
    color: var(--color-text);
    display: flex;
    align-items: center;
    gap: 18px;
    font-size: 1.2rem;
    line-height: 1.5;
}

.modal-contact-info i {
    color: var(--primary-color);
    width: 28px;
    font-size: 1.5rem;
    text-align: center;
    flex-shrink: 0;
}

.modal-contact-info strong {
    font-weight: 600;
    width: 130px;
    flex-shrink: 0;
    white-space: nowrap;
    text-align: left;
}

.modal-contact-info .content {
    flex: 1;
    text-align: left;
    white-space: nowrap;
}

.modal-contact-info p:nth-of-type(3) .content {
    white-space: normal;
}

/* Мобильные адаптации */
@media (max-width: 768px) {
    .contact-modal-content {
        padding: 40px 20px 40px;
    }
    .close-modal {
        top: 10px;
        right: 10px;
        width: 50px;
        height: 50px;
        font-size: 2rem;
    }
    .modal-contact-info p {
        align-items: flex-start;
        gap: 15px;
    }
    .modal-contact-info i {
        margin-top: 0.3rem;
        width: 24px;
        font-size: 1.3rem;
    }
    .modal-contact-info strong {
        white-space: normal;
        width: 90px;
        line-height: 1.4;
    }
    .modal-contact-info .content {
        margin-left: 15px;
    }
    .modal-contact-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .contact-modal-content {
        padding: 30px 15px 30px;
    }
    .close-modal {
        top: 8px;
        right: 8px;
        width: 44px;
        height: 44px;
        font-size: 1.8rem;
    }
    .modal-contact-info strong {
        width: 70px;
    }
    .modal-contact-info p {
        gap: 12px;
    }
    .modal-contact-info i {
        width: 22px;
        font-size: 1.2rem;
        margin-top: 0.25rem;
    }
    .modal-contact-info .content {
        margin-left: 10px;
    }
    .modal-contact-title {
        font-size: 1.2rem;
    }
}

/* ===== ПОДВАЛ ===== */
footer {
    background-color: #000000;
    color: var(--color-white);
    padding: 90px 0 50px;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 60px;
    margin-bottom: 70px;
}

.footer-logo-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin-bottom: 25px;
}

.footer-logo-container img {
    max-width: 100%;
    height: auto;
    width: auto;
    max-height: 180px;
    object-fit: contain;
}

.footer-about p {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.7;
    margin-bottom: 35px;
    font-size: 1.1rem;
}

.social-links {
    display: flex;
    gap: 18px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.12);
    border-radius: 50%;
    color: var(--color-white);
    font-size: 1.5rem;
    transition: transform 0.3s var(--transition), background-color 0.3s ease, box-shadow 0.3s ease;
}

.social-links a:hover,
.social-links a:focus-visible {
    background-color: var(--primary-color);
    transform: translateY(-6px) scale(1.15);
    box-shadow: 0 10px 20px rgba(90, 61, 48, 0.3);
}

.footer-links h4,
.footer-contact h4 {
    font-size: 1.7rem;
    margin-bottom: 35px;
    color: var(--color-white);
    position: relative;
    padding-bottom: 15px;
}

.footer-links h4::after,
.footer-contact h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 18px;
    transition: transform 0.3s ease, color 0.3s ease;
    padding: 6px 0;
    font-size: 1.1rem;
}

.footer-links a:hover,
.footer-links a:focus-visible {
    color: var(--primary-color);
    transform: translateX(12px);
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 25px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    line-height: 1.6;
    font-size: 1.1rem;
}

.footer-contact i {
    color: #ffffff;
    margin-top: 3px;
    font-size: 1.3rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 45px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
}

/* ===== АДАПТИВНОСТЬ ===== */
@media (max-width: 1200px) {
    /* clamp автоматически подстраивается */
    .contact-container { height: 500px; }
    .adv-cards { max-width: 1000px; gap: 30px; }
    .adv-card { max-width: calc(33.333% - 30px); }
    .adv-imgwrapper, .adv-bgimg { height: 400px; }
    .factory-card { min-width: calc(33.333% - 25px); }
    .work-steps-grid { grid-template-columns: repeat(3, 1fr); }
    .work-step-circle { width: 200px; height: 200px; }
    .album-gallery {
        grid-template-columns: repeat(3, 1fr);
    }
    .album-gallery img {
        height: 360px;
    }
}

@media (max-width: 992px) {
    .contact-container { grid-template-columns: 1fr; height: auto; }
    .contact-info-image { height: 400px; }
    .contact-map { height: 450px; }
    
    .logo { height: 35px; max-width: 105px; }
    .logo2 { height: 35px; max-width: 105px; }
    .logo-wrapper { transform: translateX(-4px); padding: 4px 0; }
    header { padding: 6px 0; }
    #home { margin-top: 0; }
    .header-brand-text {
        font-size: 16px;
        margin-left: 5px;
    }

    .adv-cards { max-width: 700px; }
    .adv-card { max-width: calc(50% - 30px); }
    .adv-imgwrapper, .adv-bgimg { height: 250px; }
    .adv-img-title h3 { font-size: 1.9rem; }
    .factory-cards { max-width: 700px; }
    .factory-card { min-width: calc(50% - 25px); max-width: calc(50% - 25px); }
    .factory-imgwrapper { height: 400px; }
    /* clamp handles */
    .work-steps-grid { grid-template-columns: repeat(2, 1fr); }
    .work-step-circle { width: 200px; height: 200px; }
    .work-step-content h3 { font-size: 1.3rem; min-height: 60px; }
    .work-step::after, .work-step::before { display: none !important; }
    
    .album-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
    .album-gallery img {
        height: 300px;
    }
    .album h3 {
        font-size: 1.8rem;
    }
    .album {
        scroll-margin-top: 75px;
    }

    .slider-item {
        flex: 0 0 calc(100% / 2);
    }
    .video-slider {
        padding: 0 45px;
    }
}

/* ИЗМЕНЕНО: теперь текст отображается на мобильных */
@media (max-width: 768px) {
    .header-brand-text {
        display: flex;
        flex-direction: row;    /* В одну строку */
        align-items: center;
        gap: 5px;
        font-size: 19px;
        margin-left: 5px;
    }
    .header-brand-text span {
        display: inline;
    }
    .mobile-menu-btn { display: flex; }

    /* Мы на карте — иконка и текст в одну строку по центру */
    .section-header h1 {
        flex-direction: column;
        gap: 10px;
    }
    .section-header h1 i {
        font-size: 2rem;
    }
    
    .main-nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        height: 100vh;
        background: #000000;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
        padding: 40px 20px;
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.3);
    }
    
    .main-nav.active { left: 0; }
    
    #navMenu {
        flex-direction: column;
        gap: 25px;
        text-align: center;
        width: 100%;
    }
    
    .nav-link {
        font-size: 18px;
        padding: 15px 0;
        width: 100%;
        display: block;
    }
    
    .nav-link.active::after {
        display: none;
    }
    
    .contact-btn {
        margin-top: 20px;
        padding: 10px 22px;
        font-size: 15px;
    }

    .logo { height: 45px; max-width: 135px; }
    .logo2 { height: 30px; max-width: 90px; }
    .logo-wrapper { transform: translateX(-2px); padding: 3px 0; }
    header { padding: 5px 0; }
    #home { margin-top: 0; }

    .hero { height: 70vh; min-height: 500px; }
    .hero-content h1 { margin-bottom: 20px; }
    .hero-content p { font-size: clamp(0.95rem, 2.5vw, 1.4rem); margin-bottom: 30px; }
    .hero-buttons { flex-direction: column; align-items: center; gap: 18px; }
    .hero-btn { width: 100%; max-width: 320px; justify-content: center; padding: 16px 25px; font-size: 1.1rem; }
    .section { padding: 90px 0; scroll-margin-top: 70px; }
    .floating-contact-btn { width: 60px; height: 60px; font-size: 1.6rem; bottom: 25px; right: 25px; }
    .scroll-top-btn { bottom: 95px; right: 25px; width: 50px; height: 50px; font-size: 1.5rem; }
    .notification { max-width: calc(100% - 40px); right: 20px; left: 20px; top: 25px; padding: 20px 25px; }
    
    .adv-cards { flex-direction: column; align-items: center; gap: 30px; }
    .adv-card { max-width: 100%; width: 100%; max-width: 350px; }
    .adv-imgwrapper, .adv-bgimg { height: 300px; }
    .advantages-cafmebel h2 { margin-bottom: 50px; }
    .adv-content { padding: 25px 20px 20px; }
    .adv-img-title h3 { font-size: 2.2rem; }
    .about-factory { padding: 80px 0; }
    /* clamp handles */
    .factory-description { font-size: 1.1rem; padding: 0 20px; }
    .factory-cards { flex-direction: column; align-items: center; }
    .factory-card { min-width: 100%; max-width: 350px; }
    .factory-imgwrapper { height: 400px; }
    .work-advantages { padding: 80px 0; }
    .work-steps-grid { grid-template-columns: 1fr; gap: 50px; max-width: 400px; margin-top: 0; }
    .work-step-circle { width: 160px; height: 160px; }
    .work-step-content h3 { min-height: auto; margin-bottom: 10px; }
    .contact-container { border-radius: 15px; }
    .contact-info-image { height: 350px; }
    .contact-map { height: 400px; }
    .work-step::after, .work-step::before { display: none !important; }

    .library-section {
        padding: 80px 0;
        margin-top: 45px;
    }
    .album {
        scroll-margin-top: 65px;
    }
    .album-gallery {
        grid-template-columns: 1fr;
    }
    .album-gallery img {
        height: 300px;
    }
    .album h3 {
        font-size: 1.6rem;
    }

    .slider-item {
        flex: 0 0 100%;
    }
    .video-slider {
        padding: 0 35px;
    }
    .slider-prev {
        left: -5px;
    }
    .slider-next {
        right: -5px;
    }

    .footer-logo-container {
        align-items: center;
    }
    .footer-about p {
        text-align: center;
    }
    .social-links {
        justify-content: center;
    }
}

/* ИЗМЕНЕНО: дополнительная корректировка для очень маленьких экранов */
@media (max-width: 480px) {
    .header-brand-text {
        flex-direction: row;
        align-items: center;
        gap: 4px;
        font-size: 17px;
        margin-left: 3px;
    }
    .header-brand-text span { display: inline; }
    .logo { height: 40px; max-width: 120px; }
    .logo2 { height: 26px; max-width: 78px; }
    .logo-wrapper { transform: translateX(-1px); padding: 2px 0; }
    header { padding: 4px 0; }
    #home { margin-top: 0; }

    .container { padding: 0 20px; }
    /* clamp handles font-size */
    /* clamp handles font-size */
    /* clamp handles */
    .btn { padding: 12px 25px; font-size: 15px; }
    .notification { padding: 18px; top: 20px; right: 20px; left: 20px; max-width: calc(100% - 40px); }
    .notification-content { font-size: 14px; gap: 12px; }
    .floating-contact-btn { width: 55px; height: 55px; font-size: 1.4rem; bottom: 20px; right: 20px; }
    .scroll-top-btn { bottom: 85px; right: 20px; width: 45px; height: 45px; font-size: 1.3rem; }
    .section { padding: 80px 0; }
    .footer-logo { font-size: 2.5rem; }
    .adv-imgwrapper, .adv-bgimg { height: 250px; }
    .contact-info-image { height: 300px; }
    .contact-map { height: 350px; }
    .work-step-circle { width: 140px; height: 140px; }
    
    .library-section {
        margin-top: 40px;
    }
    .album {
        scroll-margin-top: 55px;
    }
    .album-gallery img {
        height: 270px;
    }

    .slider-prev,
    .slider-next {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .footer-logo-container {
        align-items: center;
    }
    .footer-about p {
        text-align: center;
    }
    .social-links {
        justify-content: center;
    }
}/* Галерея работ */
.gallery-section {
    background-color: #fff;
    padding: 100px 0;
    margin-top: 80px;
}
.gallery-section h1 {
    font-size: 2.8rem;
    text-align: center;
    margin-bottom: 25px;
    position: relative;
    font-weight: 700;
    letter-spacing: -0.5px;
}
.gallery-section h1::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}
.gallery-description {
    max-width: 800px;
    margin: 0 auto 70px;
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.3rem;
    text-align: center;
}
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    margin-bottom: 50px;
}
.gallery-item {
    overflow: hidden;
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background-color: #f5f5f5;
}
.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}
.gallery-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}
.gallery-item:hover img {
    transform: scale(1.03);
}
.gallery-load-more {
    text-align: center;
}
.load-more-btn {
    padding: 14px 40px;
    font-size: 1.1rem;
}
@media (max-width: 1200px) {
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
@media (max-width: 992px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 768px) {
    .gallery-section {
        padding: 80px 0;
        margin-top: 60px;
    }
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .gallery-item img {
        height: 260px;
    }
}

/* ========== LIBRARY — ДРУГИЕ ПРОЕКТЫ ========== */

    /* ===== HERO-БАННЕР «ДРУГИЕ ПРОЕКТЫ» ===== */
    .op-hero {
        position: relative;
        width: 100%;
        min-height: 480px;
        background-image: url('image/other-projects-bg.jpg');
        background-size: cover;
        background-position: center;
        background-attachment: fixed;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .op-hero-overlay {
        position: absolute;
        inset: 0;
        background: rgba(0, 0, 0, 0.58);
    }
    .op-hero-content {
        position: relative;
        z-index: 1;
        text-align: center;
        padding: 60px 24px;
        max-width: 700px;
    }
    .op-hero-content h2 {
        color: #fff;
        font-size: clamp(2rem, 5vw, 3.2rem);
        margin: 0 0 16px;
        text-shadow: 0 2px 12px rgba(0,0,0,0.5);
        font-family: 'PT Serif', serif;
    }
    .op-hero-content p {
        color: rgba(255,255,255,0.88);
        font-size: clamp(1rem, 2.5vw, 1.2rem);
        line-height: 1.6;
        margin: 0 0 36px;
        text-shadow: 0 1px 8px rgba(0,0,0,0.4);
    }
    .op-toggle-btn {
        font-size: 1.2rem !important;
        padding: 18px 52px !important;
        display: inline-flex;
        align-items: center;
        gap: 12px;
        letter-spacing: 0.04em;
        border-radius: 4px;
        transition: transform 0.15s, opacity 0.15s;
    }
    .op-toggle-btn:active { transform: scale(0.97); }
    .other-gallery-wrap {
        background: #111;
        padding: 40px 0 60px;
    }
    .other-gallery-wrap[hidden] { display: none; }
    #otherGalleryGrid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
    #otherGalleryGrid .gallery-item {
        border-radius: 5px;
        overflow: hidden;
        cursor: pointer;
        position: relative;
        aspect-ratio: 4/3;
        background: #222;
    }
    #otherGalleryGrid .gallery-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform 0.3s, filter 0.3s;
    }
    #otherGalleryGrid .gallery-item:hover img {
        transform: scale(1.06);
        filter: brightness(0.78);
    }
    #otherGalleryGrid .gallery-item::after {
        content: '\f00e';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        position: absolute;
        inset: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2rem;
        color: #fff;
        opacity: 0;
        transition: opacity 0.3s;
        pointer-events: none;
    }
    #otherGalleryGrid .gallery-item:hover::after { opacity: 1; }
    .op-lightbox {
        position: fixed;
        inset: 0;
        z-index: 9999;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .op-lightbox[hidden] { display: none; }
    .op-lightbox-backdrop {
        position: absolute;
        inset: 0;
        background: rgba(0,0,0,0.85);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }
    .op-lb-img-wrap {
        position: relative;
        z-index: 2;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .op-lb-img-wrap img {
        max-width: 88vw;
        max-height: 82vh;
        border-radius: 8px;
        box-shadow: 0 8px 48px rgba(0,0,0,0.7);
        object-fit: contain;
        display: block;
        user-select: none;
        -webkit-user-drag: none;
    }
    .op-lb-close {
        position: absolute;
        top: 18px; right: 22px;
        z-index: 3;
        background: rgba(255,255,255,0.15);
        border: none;
        color: #fff;
        font-size: 1.5rem;
        width: 50px; height: 50px;
        border-radius: 50%;
        cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        transition: background 0.2s;
        backdrop-filter: blur(4px);
    }
    .op-lb-close:hover { background: rgba(255,255,255,0.3); }
    .op-lb-arrow {
        position: absolute;
        top: 50%; transform: translateY(-50%);
        z-index: 3;
        background: rgba(255,255,255,0.15);
        border: none;
        color: #fff;
        font-size: 1.6rem;
        width: 56px; height: 56px;
        border-radius: 50%;
        cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        transition: background 0.2s;
        backdrop-filter: blur(4px);
    }
    .op-lb-arrow:hover { background: rgba(255,255,255,0.3); }
    .op-lb-prev { left: 20px; }
    .op-lb-next { right: 20px; }
    .op-lb-arrow:active { transform: translateY(-50%) scale(0.93); }
    .op-lb-counter {
        position: absolute;
        bottom: 20px; left: 50%; transform: translateX(-50%);
        z-index: 3;
        color: rgba(255,255,255,0.85);
        font-size: 0.95rem;
        background: rgba(0,0,0,0.45);
        padding: 5px 16px;
        border-radius: 20px;
        backdrop-filter: blur(4px);
        white-space: nowrap;
    }
    @media (max-width: 768px) {
        .op-hero { min-height: 380px; background-attachment: scroll; }
        .op-hero-content { padding: 48px 20px; }
        .op-toggle-btn { font-size: 1rem !important; padding: 15px 28px !important; width: 100%; justify-content: center; }
        #otherGalleryGrid { grid-template-columns: repeat(2, 1fr); gap: 7px; }
        .other-gallery-wrap { padding: 24px 0 40px; }
    }
    @media (max-width: 480px) {
        .op-lb-arrow { width: 42px; height: 42px; font-size: 1.1rem; }
        .op-lb-prev { left: 8px; }
        .op-lb-next { right: 8px; }
        .op-lb-close { top: 10px; right: 10px; width: 42px; height: 42px; }
        .op-lb-img-wrap img { max-width: 96vw; max-height: 76vh; }
    }
    
/* ========== НАВИГАЦИЯ НА ВИДЕО ========== */
.video-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 40px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, transparent 100%);
}
.video-nav-left {
    display: flex;
    align-items: center;
    gap: 14px;
}
.video-nav-logo { display: flex; align-items: center; }
.video-nav-logo-img {
    height: 68px;
    width: auto;
    max-width: 208px;
    display: block;
}
.video-nav-brand {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 23px;
    color: #fff;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    line-height: 1.2;
    display: flex;
    flex-direction: column;
}
/* Десктоп: nav ссылки прямо в строке */
.video-nav .main-nav {
    position: static;
    width: auto;
    height: auto;
    background: transparent;
    display: flex;
    padding: 0;
    box-shadow: none;
    transform: none;
    left: auto;
}
.video-nav .main-nav .nav-link {
    font-size: 14px !important;
}
.video-nav .main-nav ul {
    display: flex;
    flex-direction: row;
    gap: 28px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.video-nav-burger {
    display: none;
    background: none;
    border: none;
    color: #5A3D30;
    font-size: 26px;
    cursor: pointer;
    padding: 8px;
    z-index: 1002;
}

/* Мобильная версия */
@media (max-width: 768px) {
    .video-nav {
        padding: 12px 20px;
    }
    .video-nav .main-nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        height: 100vh;
        background: #000;
        flex-direction: column;
        padding: 80px 30px 30px;
        transition: left 0.3s ease;
        z-index: 1001;
    }
    .video-nav .main-nav.active {
        left: 0;
    }
    .video-nav .main-nav ul {
        flex-direction: column;
        gap: 20px;
    }
    .video-nav-burger { display: flex; align-items: center; justify-content: center; }
    .video-nav-brand { font-size: 17px; }
    .video-nav-logo-img { height: 52px; }
}


/* ========== iOS TOUCH FIX ========== */
/* На iOS кнопки иногда не реагируют на tap без этих правил */
button,
.btn,
.nav-link,
.video-nav-burger,
.floating-contact-btn,
.scroll-top-btn,
.close-modal,
.mobile-menu-btn {
    -webkit-tap-highlight-color: rgba(0,0,0,0);
    -webkit-touch-callout: none;
    touch-action: manipulation;
    cursor: pointer;
}

/* video-nav-burger — увеличиваем зону касания, только на мобильном */
.video-nav-burger {
    min-width: 48px;
    min-height: 48px;
    display: none;
}
@media (max-width: 768px) {
    .video-nav-burger {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* floating-contact-btn — z-index выше всего */
.floating-contact-btn {
    z-index: 1050 !important;
    touch-action: manipulation;
}

/* 320px — очень маленькие экраны */
@media (max-width: 375px) {
    #home .hero-content {
        padding-top: 130px !important;
        padding-bottom: 20px !important;
        justify-content: flex-start !important;
        gap: 8px;
    }
    .hero { min-height: 100vh; }
    .hero-content h1 { margin-bottom: 6px; }
    .hero-content p { margin-bottom: 16px; font-size: 0.9rem; }
    .hero-btn { padding: 12px 20px !important; font-size: 0.95rem !important; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@media (max-width: 768px) {
    .btn, .nav-link, .footer-nav-link, .mobile-menu-btn,
    .floating-contact-btn, .scroll-top-btn,
    .close-modal, .slider-prev, .slider-next {
        min-height: 44px; min-width: 44px;
    }
    .adv-card:hover { transform: none !important; }
    .gallery-item:hover { transform: none !important; }
    .gallery-item:hover img { transform: none !important; }
    .btn:hover { transform: none !important; }
    .nav-link:hover { transform: none !important; }
}
