/* ===== FONTS ===== */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@200..800&display=swap');

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Основные цвета из Figma */
    --primary: #173980;
    --primary-dark: #0e2a60;
    --primary-light: #2a4a9e;
    --white: #FFFFFF;
    --gray-light: #D9D9D9;
    --gray-bg: rgba(217, 217, 217, 0.91);
    --primary-overlay: rgba(23, 57, 128, 0.9);
    --primary-soft: rgba(23, 57, 128, 0.71);
    --beige-bg: rgba(232, 227, 227, 0.91);
    --white-transparent: rgba(255, 255, 255, 0.58);
    
    /* Дополнительные переменные */
    --dark: #1a1a2e;
    --gray: #4a5568;
    --font-main: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --container-width: 90%;
    --transition: all 0.3s ease;
}

body {
    font-family: var(--font-main);
    color: var(--dark);
    line-height: 1.6;
    background-color: var(--white);
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Улучшенные стили для заголовков на мобилках */
@media (max-width: 768px) {
    .hero__title {
        font-size: 2rem;
        line-height: 1.3;
        margin-bottom: 16px;
    }
    
    .hero__subtitle {
        font-size: 1rem;
        line-height: 1.4;
        margin-bottom: 12px;
    }
    
    .hero__description {
        font-size: 0.9rem;
        line-height: 1.5;
        margin-bottom: 24px;
    }
}

@media (max-width: 480px) {
    .hero__title {
        font-size: 1.6rem;
        line-height: 1.3;
    }
    
    .hero__subtitle {
        font-size: 0.9rem;
    }
    
    .hero__description {
        font-size: 0.85rem;
    }
}

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

section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 48px;
    color: var(--primary);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary);
    margin: 16px auto 0;
    border-radius: 2px;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: inherit;
}

.btn--primary {
    background-color: var(--primary);
    color: var(--white);
}

.btn--primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--primary-soft);
}

.btn--full {
    width: 100%;
}

/* ===== LOGO ===== */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: var(--transition);
    flex-shrink: 0;
}

.logo:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.logo__img {
    display: block;
    height: 50px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    transition: var(--transition);
}

/* ===== HEADER ===== */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    padding: 16px 0;
}

.header__wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 32px;
}

.nav {
    display: flex;
    gap: 32px;
}

.nav a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav a:hover {
    color: var(--primary);
}

.header__phone {
    text-decoration: none;
    color: var(--primary);
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    white-space: nowrap;
}

.header__phone:hover {
    color: var(--primary-dark);
    transform: translateY(-1px);
}

/* ===== BURGER MENU ===== */
.burger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
    position: relative;
    width: 40px;
    height: 40px;
    transition: all 0.3s ease;
}

/* Три полоски бургера */
.burger span {
    display: block;
    position: absolute;
    width: 25px;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
    transition: all 0.3s ease;
    left: 7.5px;
}

.burger span:nth-child(1) {
    top: 12px;
}

.burger span:nth-child(2) {
    top: 19px;
}

.burger span:nth-child(3) {
    top: 26px;
}

/* Анимация при наведении */
.burger:hover span {
    background: var(--primary-dark);
}

.burger:hover {
    transform: scale(1.05);
}

/* Анимация при открытом меню (бургер превращается в крестик) */
.burger.active span:nth-child(1) {
    top: 19px;
    transform: rotate(45deg);
}

.burger.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

.burger.active span:nth-child(3) {
    top: 19px;
    transform: rotate(-45deg);
}

/* Анимация пульсации при клике */
.burger:active {
    transform: scale(0.95);
}

/* ===== НАВИГАЦИЯ ===== */
.nav {
    display: flex;
    gap: 32px;
}

.nav a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

/* Анимация подчеркивания для ссылок */
.nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav a:hover::after {
    width: 100%;
}

.nav a:hover {
    color: var(--primary);
}

/* ===== АДАПТИВ ДЛЯ БУРГЕРА ===== */
@media (max-width: 768px) {
    .burger {
        display: block;
    }

    .nav {
        display: flex;
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 320px;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        padding: 80px 32px 32px;
        gap: 24px;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.1);
        transition: right 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
        z-index: 1000;
        overflow-y: auto;
    }

    .nav.active {
        right: 0;
    }

    .nav a {
        font-size: 1.1rem;
        padding: 12px 0;
        opacity: 0;
        transform: translateX(30px);
        transition: all 0.3s ease;
    }

    /* Анимация появления ссылок по очереди */
    .nav.active a {
        opacity: 1;
        transform: translateX(0);
    }

    .nav.active a:nth-child(1) { transition-delay: 0.1s; }
    .nav.active a:nth-child(2) { transition-delay: 0.15s; }
    .nav.active a:nth-child(3) { transition-delay: 0.2s; }
    .nav.active a:nth-child(4) { transition-delay: 0.25s; }
    .nav.active a:nth-child(5) { transition-delay: 0.3s; }

    /* Анимация подчеркивания в мобильном меню */
    .nav a::after {
        bottom: 8px;
        left: 0;
        height: 2px;
    }

    .header__phone {
        display: none;
    }
}

/* Анимация оверлея (затемнение фона при открытом меню) */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    backdrop-filter: blur(3px);
}

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

/* Для планшетов */
@media (min-width: 769px) and (max-width: 1024px) {
    .nav {
        gap: 20px;
    }
    
    .nav a {
        font-size: 0.95rem;
    }
    
    .header__phone {
        font-size: 0.95rem;
    }
}
/* ===== HERO WITH VIDEO ===== */
.hero {
    position: relative;
    padding-top: 140px;
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center; /* Добавлено: центрирование по горизонтали */
    overflow: hidden;
    color: var(--white);
    text-align: center; /* Добавлено: выравнивание текста по центру */
}

/* Видео обертка */
.hero__video-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

/* Само видео */
.hero__video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translateX(-50%) translateY(-50%);
    object-fit: cover;
}

/* Затемнение поверх видео */
.hero__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(23, 57, 128, 0.6) 0%, rgba(14, 42, 96, 0.7) 100%);
    z-index: 1;
}

/* Контент поверх видео */
.hero__content {
    position: relative;
    z-index: 2;
    max-width: 800px; /* Увеличено для лучшего центрирования */
    margin: 0 auto; /* Добавлено: центрирование блока */
    color: var(--white);
    text-align: center; /* Добавлено: выравнивание текста по центру */
}

.hero__title {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 24px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero__subtitle {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 16px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero__description {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 32px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

/* Кнопка с полупрозрачным фоном */
.hero .btn--primary {
    display: inline-block; /* Убеждаемся, что кнопка inline-block для центрирования */
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid var(--white);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.hero .btn--primary:hover {
    background-color: var(--white);
    color: var(--primary);
    border-color: var(--white);
    transform: translateY(-2px);
}

/* Адаптив для мобильных устройств */
@media (max-width: 768px) {
    .hero {
        padding-top: 100px;
        min-height: auto;
        text-align: center;
    }
    
    .hero__content {
        max-width: 90%;
        padding: 0 16px;
    }
    
    .hero__title {
        font-size: 2rem;
        margin-bottom: 16px;
    }
    
    .hero__subtitle {
        font-size: 1rem;
        margin-bottom: 12px;
    }
    
    .hero__description {
        font-size: 0.9rem;
        margin-bottom: 24px;
    }
}

@media (max-width: 480px) {
    .hero {
        padding-top: 80px;
    }
    
    .hero__title {
        font-size: 1.6rem;
    }
    
    .hero__subtitle {
        font-size: 0.9rem;
    }
    
    .hero__description {
        font-size: 0.85rem;
    }
}

/* ===== SECTION BACKGROUNDS SYSTEM ===== */
/* Базовый класс для фона секций */
.section-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    transition: opacity 0.3s ease;
}

/* Каждая секция должна иметь relative позиционирование */
.about,
.stats,
.services,
.advantages,
.works,
.form-section,
.contacts {
    position: relative;
    overflow: hidden;
}

/* Контент поверх фона */
.about .container,
.stats .container,
.services .container,
.advantages .container,
.works .container,
.form-section .container,
.contacts .container {
    position: relative;
    z-index: 2;
}

/* ===== STATS ===== */
.stats {
    /* Убираем градиент, оставляем только фон */
    background-color: var(--primary);
    padding: 60px 0;
    position: relative;
}

.stats__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
    text-align: center;
    position: relative;
    z-index: 2;
}

.stat-card {
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card__number {
    font-size: 3rem;
    font-weight: 800;
    color: var(--white);
}

.stat-card__label {
    font-size: 1rem;
    color: var(--white-transparent);
    margin-top: 8px;
}

/* ===== ABOUT ===== */
.about {
    background-color: transparent;
    position: relative;
}

.about__content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    background: var(--beige-bg);
    padding: 48px;
    border-radius: 24px;
    transition: var(--transition);
    position: relative;
    z-index: 2;
}



.about__text {
    font-size: 1.125rem;
    color: var(--dark);
    line-height: 1.8;
}

/* ===== SERVICES WITH IMAGES ===== */
.services {
    background-color: transparent;
    position: relative;
}

.services__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 32px;
    position: relative;
    z-index: 2;
}

.service-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--gray-light);
}



/* Контейнер для изображения */
.service-card__image {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
}

/* Само изображение */
.service-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}



/* Оверлей с затемнением при наведении */
.service-card__image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(23, 57, 128, 0.3) 0%, rgba(14, 42, 96, 0.4) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-card:hover .service-card__image::after {
    opacity: 1;
}

/* Контент карточки */
.service-card__content {
    padding: 24px;
}

.service-card__title {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--primary);
    transition: var(--transition);
}

.service-card:hover .service-card__title {
    color: var(--primary-dark);
}

.service-card__description {
    color: var(--gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ===== АДАПТИВ ДЛЯ КАРТИНОК УСЛУГ ===== */

/* Планшеты (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .services__grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 24px;
    }
    
    .service-card__image {
        height: 200px;
    }
    
    .service-card__content {
        padding: 20px;
    }
    
    .service-card__title {
        font-size: 1.2rem;
    }
    
    .service-card__description {
        font-size: 0.9rem;
    }
}

/* Мобильные устройства (до 768px) */
@media (max-width: 768px) {
    .services__grid {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 0 16px;
    }
    
    .service-card {
        max-width: 100%;
        margin: 0 auto;
    }
    
    .service-card__image {
        height: 200px;
    }
    
    .service-card__content {
        padding: 18px;
    }
    
    .service-card__title {
        font-size: 1.15rem;
        margin-bottom: 10px;
    }
    
    .service-card__description {
        font-size: 0.9rem;
        line-height: 1.5;
    }
}

/* Маленькие телефоны (до 480px) */
@media (max-width: 480px) {
    .services__grid {
        gap: 20px;
        padding: 0 12px;
    }
    
    .service-card {
        border-radius: 16px;
    }
    
    .service-card__image {
        height: 160px;
    }
    
    .service-card__content {
        padding: 16px;
    }
    
    .service-card__title {
        font-size: 1.05rem;
        margin-bottom: 8px;
    }
    
    .service-card__description {
        font-size: 0.85rem;
        line-height: 1.45;
    }
}

/* Очень маленькие телефоны (до 360px) */
@media (max-width: 360px) {
    .service-card__image {
        height: 140px;
    }
    
    .service-card__content {
        padding: 14px;
    }
    
    .service-card__title {
        font-size: 1rem;
    }
    
    .service-card__description {
        font-size: 0.8rem;
    }
}

/* Для устройств с Retina экраном */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .service-card__image img {
        image-rendering: crisp-edges;
    }
}

/* Для устройств, где пользователь предпочитает уменьшенную анимацию */
@media (prefers-reduced-motion: reduce) {
    .service-card__image img {
        transition: none;
    }
    
    .service-card:hover .service-card__image img {
        transform: none;
    }
    
    .service-card {
        transition: none;
    }
}

/* Для экранов с альбомной ориентацией на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    .services__grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 16px;
    }
    
    .service-card__image {
        height: 150px;
    }
    
    .service-card__content {
        padding: 12px;
    }
    
    .service-card__title {
        font-size: 1rem;
    }
    
    .service-card__description {
        font-size: 0.8rem;
    }
}

/* Загрузка изображений с эффектом скелетона */
.service-card__image {
    position: relative;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Убираем анимацию скелетона после загрузки изображения */
.service-card__image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-card__image img.loaded {
    opacity: 1;
}

.service-card__image img.loaded ~ .service-card__image {
    animation: none;
    background: none;
}

/* ===== ADVANTAGES ===== */

.advantages {
    background-color: transparent;
    position: relative;
}

.advantages__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Фиксированно 3 колонки для десктопа */
    gap: 30px;
}

.advantage-card {
    background: var(--white);
    padding: 32px 24px;
    border-radius: 20px;
    transition: var(--transition);
    border: 1px solid var(--gray-light);
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.advantage-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 28px var(--primary-soft);
    border-color: var(--primary);
}

/* Круглая обертка для иконки */
.advantage-card__icon-wrapper {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(23, 57, 128, 0.3);
}

.advantage-card:hover .advantage-card__icon-wrapper {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(23, 57, 128, 0.4);
}

/* Само изображение иконки */
.advantage-card__icon-img {
    width: 55px;
    height: 55px;
    object-fit: contain;
    filter: brightness(0) invert(1); /* Делает иконку белой */
}

.advantage-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--primary);
}

.advantage-card__description {
    color: var(--gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Адаптив для планшетов (768px - 1024px) - 2 карточки в строке */
@media (max-width: 1024px) {
    .advantages__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

/* Адаптив для мобильных устройств (до 768px) - 1 карточка в строке */
@media (max-width: 768px) {
    .advantages__grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .advantage-card {
        padding: 24px 20px;
    }
    
    .advantage-card__icon-wrapper {
        width: 80px;
        height: 80px;
        margin-bottom: 16px;
    }
    
    .advantage-card__icon-img {
        width: 45px;
        height: 45px;
    }
    
    .advantage-card__title {
        font-size: 1.2rem;
    }
}

/* Для очень маленьких экранов (до 480px) */
@media (max-width: 480px) {
    .advantage-card {
        padding: 20px 16px;
    }
    
    .advantage-card__icon-wrapper {
        width: 70px;
        height: 70px;
    }
    
    .advantage-card__icon-img {
        width: 38px;
        height: 38px;
    }
    
    .advantage-card__title {
        font-size: 1.05rem;
    }
    
    .advantage-card__description {
        font-size: 0.85rem;
    }
}

/* ===== WORKS ===== */
/* ===== СЛАЙД-ШОУ ДЛЯ ВЫПОЛНЕННЫХ РАБОТ ===== */

.works {
    background-color: transparent;
    position: relative;
    padding: 80px 0;
}

.works-subtitle {
    text-align: center;
    color: var(--gray);
    font-size: 1.1rem;
    margin-bottom: 50px;
    position: relative;
    z-index: 2;
}

.works-slider {
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 60px;
}

.works-slider-container {
    overflow: hidden;
    border-radius: 16px;
}

.works-slider-track {
    display: flex;
    gap: 24px;
    transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.work-slide {
    flex: 0 0 calc(33.333% - 16px);
    min-width: 0;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
}

.work-slide__image {
    width: 100%;
    height: 320px;
    overflow: hidden;
}

.work-slide__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.work-slide:hover .work-slide__image img {
    transform: scale(1.05);
}

/* Стрелки навигации */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    color: var(--primary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.slider-arrow-prev {
    left: -25px;  /* стрелка левее на 25px */
}

.slider-arrow-next {
    right: -25px; /* стрелка правее на 25px */
}

.slider-arrow:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-50%) scale(1.05);
}

/* Точки навигации */
.slider-dots-container {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.slider-dot {
    width: 10px;
    height: 10px;
    background: var(--gray-light);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-dot.active {
    background: var(--primary);
    width: 30px;
    border-radius: 5px;
}

.slider-dot:hover {
    background: var(--primary);
    opacity: 0.7;
}

/* ===== АДАПТИВ ДЛЯ КАРУСЕЛИ ===== */

/* Планшеты (768px - 1200px) */
@media (max-width: 1200px) {
    .work-slide {
        flex: 0 0 calc(50% - 12px);
    }
    
    .work-slide__image {
        height: 300px;
    }
    
    .works-slider {
        padding: 0 50px;
    }
    
    .slider-arrow {
        width: 44px;
        height: 44px;
    }
    
    /* ДОБАВИТЬ ПОЗИЦИОНИРОВАНИЕ СТРЕЛОК */
    .slider-arrow-prev {
        left: -20px;
    }
    
    .slider-arrow-next {
        right: -20px;
    }
}

/* Мобильные устройства (до 768px) */
@media (max-width: 768px) {
    .works {
        padding: 60px 0;
    }
    
    .works-slider {
        padding: 0 40px;
    }
    
    .work-slide {
        flex: 0 0 100%;
    }
    
    .work-slide__image {
        height: 280px;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
    }
    
    .slider-arrow svg {
        width: 20px;
        height: 20px;
    }
    
    /* ДОБАВИТЬ ПОЗИЦИОНИРОВАНИЕ СТРЕЛОК */
    .slider-arrow-prev {
        left: -15px;
    }
    
    .slider-arrow-next {
        right: -15px;
    }
    
    .slider-dots-container {
        gap: 10px;
        margin-top: 30px;
    }
    
    .slider-dot {
        width: 8px;
        height: 8px;
    }
    
    .slider-dot.active {
        width: 25px;
    }
}

/* Маленькие телефоны (до 480px) */
@media (max-width: 480px) {
    .works {
        padding: 50px 0;
    }
    
    .works-slider {
        padding: 0 30px;
    }
    
    .work-slide__image {
        height: 240px;
    }
    
    .slider-arrow {
        width: 36px;
        height: 36px;
    }
    
    .slider-arrow svg {
        width: 18px;
        height: 18px;
    }
    
    /* ДОБАВИТЬ ПОЗИЦИОНИРОВАНИЕ СТРЕЛОК */
    .slider-arrow-prev {
        left: -12px;
    }
    
    .slider-arrow-next {
        right: -12px;
    }
    
    .slider-dots-container {
        gap: 8px;
        margin-top: 25px;
    }
    
    .slider-dot {
        width: 8px;
        height: 8px;
    }
    
    .slider-dot.active {
        width: 20px;
    }
}

/* Очень маленькие телефоны (до 360px) */
@media (max-width: 360px) {
    .works-slider {
        padding: 0 25px;
    }
    
    .work-slide__image {
        height: 200px;
    }
    
    .slider-arrow {
        width: 32px;
        height: 32px;
    }
    
    .slider-arrow svg {
        width: 16px;
        height: 16px;
    }
    
    /* ДОБАВИТЬ ПОЗИЦИОНИРОВАНИЕ СТРЕЛОК */
    .slider-arrow-prev {
        left: -10px;
    }
    
    .slider-arrow-next {
        right: -10px;
    }
}

/* Альбомная ориентация на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    .work-slide__image {
        height: 200px;
    }
    
    .works-slider {
        padding: 0 50px;
    }
    
    /* ДОБАВИТЬ ПОЗИЦИОНИРОВАНИЕ СТРЕЛОК */
    .slider-arrow-prev {
        left: -15px;
    }
    
    .slider-arrow-next {
        right: -15px;
    }
}


/* ===== МОДАЛЬНОЕ ОКНО ДЛЯ ФОТО ===== */
.modal-photo {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.modal-photo.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-photo__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(8px);
}

.modal-photo__container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    z-index: 1;
}

.modal-photo__image {
    max-width: 90vw;
    max-height: 85vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    cursor: pointer;
}

/* Крестик закрытия */
.modal-photo__close {
    position: absolute;
    top: -50px;
    right: 0;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: rgba(255, 255, 255, 0.8);
    z-index: 10;
}

.modal-photo__close:hover {
    color: var(--white);
    transform: scale(1.1);
}

.modal-photo__close svg {
    width: 28px;
    height: 28px;
}

/* Минималистичные стрелки навигации */
.modal-photo__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
}

.modal-photo__nav:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-50%) scale(1.1);
}

.modal-photo__prev {
    left: -100px;
}

.modal-photo__next {
    right: -100px;
}

.modal-photo__nav svg {
    width: 36px;
    height: 36px;
}

/* ===== АДАПТИВ ДЛЯ МОДАЛЬНОГО ОКНА ===== */



/* Планшеты и маленькие десктопы */
@media (max-width: 1024px) {
    .modal-photo__nav {
        width: 44px;
        height: 44px;
    }
    
    .modal-photo__nav svg {
        width: 28px;
        height: 28px;
    }
    
    .modal-photo__prev {
        left: -60px;
    }
    
    .modal-photo__next {
        right: -60px;
    }
    
    .modal-photo__close {
        width: 38px;
        height: 38px;
        top: -45px;
        right: -5px;
    }
    
    .modal-photo__close svg {
        width: 24px;
        height: 24px;
    }
}

/* Мобильные устройства */
@media (max-width: 768px) {
    .modal-photo__nav {
        width: 40px;
        height: 40px;
    }
    
    .modal-photo__nav svg {
        width: 26px;
        height: 26px;
    }
    
    .modal-photo__prev {
        left: -45px;
    }
    
    .modal-photo__next {
        right: -45px;
    }
    
    .modal-photo__close {
        width: 36px;
        height: 36px;
        top: -42px;
        right: -5px;
    }
    
    .modal-photo__close svg {
        width: 22px;
        height: 22px;
    }
}

/* Маленькие телефоны */
@media (max-width: 480px) {
    .modal-photo__nav {
        width: 36px;
        height: 36px;
        background: rgba(0, 0, 0, 0.4);
        border-radius: 50%;
    }
    
    .modal-photo__nav svg {
        width: 22px;
        height: 22px;
    }
    
    .modal-photo__prev {
        left: -35px;
    }
    
    .modal-photo__next {
        right: -35px;
    }
    
    .modal-photo__close {
        width: 34px;
        height: 34px;
        top: -38px;
        right: 0;
    }
    
    .modal-photo__close svg {
        width: 20px;
        height: 20px;
    }
}

/* Очень маленькие телефоны (до 360px) */
@media (max-width: 360px) {
    .modal-photo__nav {
        width: 32px;
        height: 32px;
    }
    
    .modal-photo__nav svg {
        width: 20px;
        height: 20px;
    }
    
    .modal-photo__prev {
        left: -30px;
    }
    
    .modal-photo__next {
        right: -30px;
    }
    
    .modal-photo__close {
        width: 32px;
        height: 32px;
        top: -35px;
    }
    
    .modal-photo__close svg {
        width: 18px;
        height: 18px;
    }
}

/* Альбомная ориентация на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    .modal-photo__nav {
        width: 38px;
        height: 38px;
    }
    
    .modal-photo__nav svg {
        width: 24px;
        height: 24px;
    }
    
    .modal-photo__prev {
        left: -50px;
    }
    
    .modal-photo__next {
        right: -50px;
    }
    
    .modal-photo__close {
        width: 34px;
        height: 34px;
        top: -40px;
    }
    
    .modal-photo__close svg {
        width: 20px;
        height: 20px;
    }
}

/* Для устройств с сенсорным экраном */
@media (hover: none) and (pointer: coarse) {
    .modal-photo__nav {
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
    }
    
    .modal-photo__prev {
        left: -25px;
    }
    
    .modal-photo__next {
        right: -25px;
    }
    
    .modal-photo__close {
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
        border-radius: 50%;
        width: 36px;
        height: 36px;
        right: 0;
    }
}

/* ===== FORM SECTION ===== */
.form-section {
    background-color: transparent;
    position: relative;
}

.form-section__subtitle {
    text-align: center;
    color: var(--gray);
    margin-bottom: 40px;
    position: relative;
    z-index: 2;
}

.request-form {
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: 40px;
    border-radius: 24px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--gray-light);
    transition: var(--transition);
    position: relative;
    z-index: 2;
    box-sizing: border-box;
    width: 100%;
    overflow-x: hidden;
}


.form-group {
    margin-bottom: 24px;
    width: 100%;
    box-sizing: border-box;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark);
    font-size: 0.95rem;
}

.required {
    color: #e74c3c;
    font-size: 1.1rem;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--gray-light);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--white);
    box-sizing: border-box;
    display: block;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-soft);
}

.form-input.error,
.form-textarea.error {
    border-color: #e74c3c;
    background-color: rgba(231, 76, 60, 0.05);
}

.form-input.success,
.form-textarea.success {
    border-color: #27ae60;
}

.error-message {
    color: #e74c3c;
    font-size: 0.8rem;
    margin-top: 5px;
    display: none;
}

.error-message.show {
    display: block;
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

/* Адаптив для формы */
@media (max-width: 768px) {
    .request-form {
        padding: 24px;
        margin: 0 16px;
        width: calc(100% - 32px);
        max-width: none;
    }
    
    .form-input,
    .form-textarea {
        padding: 12px 14px;
        font-size: 0.95rem;
    }
    
    .form-group {
        margin-bottom: 18px;
    }
}

@media (max-width: 480px) {
    .request-form {
        padding: 20px;
        margin: 0 12px;
        width: calc(100% - 24px);
    }
    
    .form-input,
    .form-textarea {
        padding: 10px 12px;
        font-size: 0.9rem;
    }
    
    .form-group label {
        font-size: 0.85rem;
    }
}

/* ===== CONTACTS ===== */
.contacts {
    background-color: var(--primary);
    position: relative;
}

.contacts .section-title {
    color: var(--white);
}

.contacts .section-title::after {
    background: var(--white);
}

.contacts__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    position: relative;
    z-index: 2;
}

/* Контактные элементы с иконками */
.contact-item {
    display: flex;
    gap: 20px;
    margin-bottom: 32px;
    background: var(--primary-overlay);
    padding: 20px 24px;
    border-radius: 16px;
    backdrop-filter: blur(10px);
    transition: var(--transition);
    align-items: center;
}

.contact-item:hover {
    transform: translateX(8px);
    background: rgba(23, 57, 128, 0.95);
}

/* Круглая обертка для иконки */
.contact-item__icon-wrapper {
    width: 60px;
    height: 60px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.contact-item:hover .contact-item__icon-wrapper {
    transform: scale(1.05);
    background: var(--secondary);
}

/* Само изображение иконки */
.contact-item__icon-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    transition: var(--transition);
}

.contact-item:hover .contact-item__icon-img {
    filter: brightness(0) invert(1);
}

/* Контент с текстом */
.contact-item__content {
    flex: 1;
}

.contact-item__content h4 {
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--white);
    font-size: 1.1rem;
}

.contact-item__content p,
.contact-item__content a {
    color: var(--white-transparent);
    text-decoration: none;
    line-height: 1.5;
    font-size: 0.95rem;
}

.contact-item__content a:hover {
    color: var(--white);
}

/* Карта */
.map-placeholder {
    background: var(--gray-light);
    border-radius: 16px;
    overflow: hidden;
    height: 100%;
    min-height: 350px;
    transition: var(--transition);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}



.map-placeholder iframe {
    width: 100%;
    height: 100%;
    min-height: 350px;
}

/* Адаптив для контактов */
@media (max-width: 768px) {
    .contacts__grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .contact-item {
        padding: 16px 20px;
        gap: 16px;
    }
    
    .contact-item__icon-wrapper {
        width: 50px;
        height: 50px;
    }
    
    .contact-item__icon-img {
        width: 28px;
        height: 28px;
    }
    
    .contact-item__content h4 {
        font-size: 1rem;
    }
    
    .contact-item__content p,
    .contact-item__content a {
        font-size: 0.85rem;
    }
    
    .map-placeholder {
        min-height: 280px;
    }
    
    .map-placeholder iframe {
        min-height: 280px;
    }
}

@media (max-width: 480px) {
    .contact-item {
        padding: 14px 16px;
        gap: 12px;
    }
    
    .contact-item__icon-wrapper {
        width: 45px;
        height: 45px;
    }
    
    .contact-item__icon-img {
        width: 24px;
        height: 24px;
    }
}



/* ===== FOOTER ===== */
.footer {
    background: var(--primary-dark);
    color: var(--white);
    padding: 48px 0 24px;
}

.footer__content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

.footer__logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.footer__logo span {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--white);
}

.footer__logo p {
    margin-top: 8px;
    font-size: 0.875rem;
    color: var(--white-transparent);
}

.footer__nav {
    display: flex;
    gap: 24px;
}

.footer__nav a {
    color: var(--white-transparent);
    text-decoration: none;
    transition: var(--transition);
}

.footer__nav a:hover {
    color: var(--white);
    transform: translateY(-2px);
}


/* ===== НАСТРОЙКА ФОНОВ ДЛЯ КАЖДОЙ СЕКЦИИ ===== */
/* Фон для секции "О компании" */
.about__bg {
    background-image: url('../images/about.jpg');
    opacity: 0.1;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции статистики */
/*.stats__bg {
    background-image: url('../images/stat.png');
    opacity: 0.25;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции услуг */
.services__bg {
    background-image: url('../images/usl.png');
    opacity: 0.15;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции выполненных работ */
.works__bg {
    background-image: url('../images/rab.jpeg');
    opacity: 0.2;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции контактов */
.contacts__bg {
    background-image: url('../images/kontakt.png');
    opacity: 0.2;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции преимуществ (если нужен) */
/* .advantages__bg {
    background-image: url('../images/advantages-bg.jpg');
    opacity: 0.15;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Фон для секции формы (если нужен) */
/*.form__bg {
    background-image: url('../images/form-bg.jpg');
    opacity: 0.12;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* ===== ДОПОЛНИТЕЛЬНЫЕ ЭФФЕКТЫ ДЛЯ ФОНОВ ===== */
/* Параллакс эффект для фонов */
@media (min-width: 768px) {
    .about__bg,
    .stats__bg,
    .services__bg,
    .advantages__bg,
    .works__bg,
    .form__bg,
    .contacts__bg {
        background-attachment: fixed;
    }
}

/* Адаптив для мобильных устройств */
@media (max-width: 768px) {
    .section-bg {
        opacity: 0.12;
    }
    
    /* Отключаем параллакс на мобилках */
    .about__bg,
    .stats__bg,
    .services__bg,
    .advantages__bg,
    .works__bg,
    .form__bg,
    .contacts__bg {
        background-attachment: scroll;
    }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .hero__title {
        font-size: 2.8rem;
    }
    
    .stats__grid {
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }
    
    .section-title::after {
        width: 60px;
    }

    .logo__img {
        height: 40px;
        max-width: 150px;
    }

    .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        border-top: 1px solid var(--gray-light);
    }

    .nav.active {
        display: flex;
    }

    .burger {
        display: block;
    }

    .header__phone {
        display: none;
    }

    .hero {
        padding-top: 100px;
        min-height: auto;
    }

    .hero__title {
        font-size: 2rem;
    }
    
    .hero__subtitle {
        font-size: 1.1rem;
    }
    
    .hero__description {
        font-size: 1rem;
    }

    .stats__grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .stat-card__number {
        font-size: 2.5rem;
    }

    .about__content {
        padding: 24px;
    }

    .contacts__grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .contact-item {
        padding: 16px;
    }

    .footer__content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer__logo {
        align-items: center;
    }

    .footer__nav {
        flex-direction: column;
        gap: 12px;
        align-items: center;
    }

    section {
        padding: 60px 0;
    }
    
    .request-form {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero__title {
        font-size: 1.75rem;
    }
    
    .services__grid {
        grid-template-columns: 1fr;
    }
    
    .advantages__grid {
        grid-template-columns: 1fr;
    }
    
    .works__grid {
        grid-template-columns: 1fr;
    }
    
    .logo__img {
        height: 35px;
        max-width: 120px;
    }
}

/* ===== ДОПОЛНИТЕЛЬНЫЕ ЭФФЕКТЫ ===== */
html {
    scroll-behavior: smooth;
}

button:focus,
a:focus {
    outline: none;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--gray-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}





/* ===== АДАПТИВ ДЛЯ ФОНОВ И ВИДЕО ===== */

/* Улучшение для видео на мобильных устройствах */
@media (max-width: 768px) {
    /* Видео фон - оптимизация для мобильных */
    .hero__video {
        min-width: auto;
        min-height: 100%;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    
    /* Уменьшаем затемнение видео на мобилках */
    .hero__overlay {
        background: linear-gradient(135deg, rgba(23, 57, 128, 0.7) 0%, rgba(14, 42, 96, 0.8) 100%);
    }
    
    /* Фоновые изображения секций - оптимизация */
    .section-bg {
        background-attachment: scroll !important;
        background-size: cover;
        background-position: center;
    }
    
    /* Уменьшаем прозрачность фонов на мобилках для лучшей читаемости */
    .about__bg { opacity: 0.08; }
    .services__bg { opacity: 0.1; }
    .works__bg { opacity: 0.12; }
    .contacts__bg { opacity: 0.15; }
}



/* Для планшетов (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .hero__video {
        min-width: 100%;
        min-height: 100%;
        width: auto;
        height: auto;
    }
    
    .section-bg {
        background-attachment: scroll;
    }
}



/* Для устройств с альбомной ориентацией на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    .hero {
        min-height: 120vh;
        padding-top: 100px;
    }
    
    .hero__title {
        font-size: 1.8rem;
    }
    
    .hero__subtitle {
        font-size: 1rem;
    }
    
    .hero__description {
        font-size: 0.9rem;
    }
}

/* Для очень больших экранов (4K и выше) */
@media (min-width: 1920px) {
    .hero__video {
        min-width: 100%;
        min-height: 100%;
        width: 100%;
        height: auto;
    }
    
    .container {
        max-width: 1440px;
    }
    
    .hero__title {
        font-size: 4rem;
    }
}

/* Для устройств, где пользователь предпочитает уменьшенную анимацию */
@media (prefers-reduced-motion: reduce) {
    .hero__video {
        animation: none;
    }
    
    .section-bg {
        background-attachment: scroll !important;
    }
    
    * {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* Для браузеров, которые не поддерживают видео фон */
.no-video .hero__video-wrapper {
    background: var(--primary-dark);
}

.no-video .hero__video {
    display: none;
}

/* Улучшение производительности для фонов с fixed */
@media (max-width: 1024px) {
    .about__bg,
    .stats__bg,
    .services__bg,
    .advantages__bg,
    .works__bg,
    .form__bg,
    .contacts__bg {
        background-attachment: scroll !important;
        transform: translateZ(0);
        will-change: auto;
    }
}

/* Плавное появление фонов при загрузке */
.section-bg {
    animation: bgFadeIn 0.5s ease-out;
}

@keyframes bgFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: var(--target-opacity, 0.15);
    }
}

/* Оптимизация для видео на слабых устройствах */
@media (max-width: 768px) and (pointer: coarse) {
    .hero__video {
        transform: none;
        top: 0;
        left: 0;
        min-width: 100%;
        min-height: 100%;
        object-fit: cover;
    }
    
    /* Уменьшаем качество видео для экономии ресурсов */
    .hero__video {
        filter: blur(0px);
    }
}

/* ===== АДАПТИВ ДЛЯ ТЕКСТА ===== */

/* Базовые настройки текста для мобильных */
@media (max-width: 768px) {
    body {
        font-size: 15px;
        line-height: 1.5;
    }
    
    /* Заголовки секций */
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 32px;
    }
    
    .section-title::after {
        width: 60px;
        height: 3px;
        margin-top: 12px;
    }
    
    /* Текст в секции "О компании" */
    .about__text {
        font-size: 1rem;
        line-height: 1.6;
    }
    
    /* Карточки услуг */
    .service-card__title {
        font-size: 1.2rem;
    }
    
    .service-card__description {
        font-size: 0.9rem;
    }
    
    /* Карточки преимуществ */
    .advantage-card__title {
        font-size: 1.15rem;
    }
    
    .advantage-card__description {
        font-size: 0.9rem;
    }
    
    /* Карточки работ */
    .work-card__title {
        font-size: 0.95rem;
        padding: 12px;
    }
    
    /* Форма */
    .form-section__subtitle {
        font-size: 0.95rem;
        margin-bottom: 30px;
        padding: 0 16px;
    }
    
    .form-group label {
        font-size: 0.9rem;
    }
    
    /* Контакты */
    .contact-item__content h4 {
        font-size: 1rem;
    }
    
    .contact-item__content p,
    .contact-item__content a {
        font-size: 0.85rem;
    }
    
    /* Подвал */
    .footer__logo span {
        font-size: 1.1rem;
    }
    
    .footer__logo p {
        font-size: 0.75rem;
    }
    
    .footer__nav a {
        font-size: 0.9rem;
    }
}

/* Для очень маленьких экранов (до 480px) */
@media (max-width: 480px) {
    body {
        font-size: 14px;
    }
    
    /* Заголовки */
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 24px;
    }
    
    .section-title::after {
        width: 50px;
        height: 3px;
        margin-top: 10px;
    }
    
    /* Текст в секции "О компании" */
    .about__text {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    /* Карточки услуг */
    .service-card__title {
        font-size: 1.1rem;
    }
    
    .service-card__description {
        font-size: 0.85rem;
    }
    
    /* Карточки преимуществ */
    .advantage-card__title {
        font-size: 1.05rem;
    }
    
    .advantage-card__description {
        font-size: 0.85rem;
    }
    
    /* Форма */
    .form-section__subtitle {
        font-size: 0.85rem;
    }
    
    .form-group label {
        font-size: 0.85rem;
    }
    
    .form-input,
    .form-textarea {
        font-size: 0.85rem;
        padding: 10px 12px;
    }
    
    /* Контакты */
    .contact-item__content h4 {
        font-size: 0.95rem;
    }
    
    .contact-item__content p,
    .contact-item__content a {
        font-size: 0.8rem;
    }
    
    /* Кнопки */
    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
    
    /* Навигация */
    .nav a {
        font-size: 1rem;
    }
    
    .header__phone {
        font-size: 0.9rem;
    }
}

/* Для планшетов (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    body {
        font-size: 16px;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
    
    .about__text {
        font-size: 1rem;
    }
    
    .service-card__title {
        font-size: 1.2rem;
    }
    
    .advantage-card__title {
        font-size: 1.2rem;
    }
}

/* Для больших экранов (от 1400px) */
@media (min-width: 1400px) {
    body {
        font-size: 18px;
    }
    
    .section-title {
        font-size: 3rem;
        margin-bottom: 56px;
    }
    
    .about__text {
        font-size: 1.2rem;
    }
    
    .service-card__title {
        font-size: 1.4rem;
    }
    
    .service-card__description {
        font-size: 1rem;
    }
    
    .advantage-card__title {
        font-size: 1.35rem;
    }
    
    .advantage-card__description {
        font-size: 1rem;
    }
}

/* Для экранов с высокой плотностью пикселей (Retina) */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
    
    .section-title {
        font-weight: 700;
    }
}

/* Для устройств с альбомной ориентацией на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    .section-title {
        font-size: 1.6rem;
        margin-bottom: 20px;
    }
    
    .about__text {
        font-size: 0.9rem;
    }
    
    .service-card__title {
        font-size: 1rem;
    }
    
    .advantage-card__title {
        font-size: 1rem;
    }
}

/* Улучшение читаемости текста на темном фоне */
.hero__title,
.hero__subtitle,
.hero__description,
.contacts .contact-item__content h4,
.contacts .contact-item__content p,
.contacts .contact-item__content a,
.stats .stat-card__label {
    text-rendering: optimizeLegibility;
}

/* Для пользователей, которые предпочитают увеличенный шрифт */
@media (prefers-reduced-motion: no-preference) {
    html {
        font-size: 100%;
    }
}

/* Для пользователей с ограниченными возможностями - увеличенный шрифт */
@media (prefers-contrast: more) {
    body {
        font-weight: 500;
    }
    
    .hero__title,
    .hero__subtitle,
    .hero__description {
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    }
}

/* ===== OVERLAY ДЛЯ БУРГЕР МЕНЮ ===== */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    backdrop-filter: blur(3px);
}

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

/* ===== УВЕДОМЛЕНИЯ ДЛЯ ФОРМЫ ===== */
.notification {
    position: fixed;
    bottom: 30px;
    right: 30px;
    max-width: 350px;
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 10000;
    overflow: hidden;
}

.notification.show {
    transform: translateX(0);
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
}

.notification-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.notification-message {
    font-size: 0.9rem;
    color: var(--dark);
    line-height: 1.4;
}

.notification-success {
    border-left: 4px solid #27ae60;
}

.notification-error {
    border-left: 4px solid #e74c3c;
}

/* Адаптив для уведомлений */
@media (max-width: 768px) {
    .notification {
        bottom: 20px;
        right: 20px;
        left: 20px;
        max-width: none;
    }
    
    .notification-content {
        padding: 14px 16px;
    }
    
    .notification-message {
        font-size: 0.85rem;
    }
}

/* ===== HEADER CONTACTS ===== */
.header__contacts {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0px;
}

.header__phone {
    text-decoration: none;
    color: var(--primary);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
    white-space: nowrap;
}

.header__phone:hover {
    color: var(--primary-dark);
    transform: translateY(-1px);
}

.header__email {
    text-decoration: none;
    color: var(--gray);
    font-weight: 500;
    font-size: 0.85rem;
    transition: var(--transition);
    white-space: nowrap;
}

.header__email:hover {
    color: var(--primary);
    transform: translateY(-1px);
}

/* Адаптив для мобильных устройств */
@media (max-width: 768px) {
    .header__contacts {
        display: none; 
    }
    
    
   /* .header__contacts {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 16px;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
        z-index: 999;
    }
    */
}

/* ===== HERO DIVIDER ===== */

.hero__divider {
    width: 100%;  
    max-width: 1000px;  
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
    border: none;
    margin: 20px auto 25px;
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
    .hero__divider {
        width: 100%;  
        max-width: 200px;  
        height: 2px;
        margin: 15px auto 20px;
    }
}

/* ===== КАРТА ===== */
.contacts__map {
    position: relative;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    height: 400px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

#map {
    width: 100%;
    height: 400px;
    border-radius: 16px;
    transition: var(--transition);
}

/* Затемнение при загрузке карты */
#map::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary) 100%);
    opacity: 0.1;
    pointer-events: none;
    z-index: 1;
}

/* Кнопка "Как добраться" под картой (на случай, если не используете API) */
.btn-route {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    margin-top: 16px;
    padding: 14px 24px;
    background: var(--white);
    border: none;
    border-radius: 12px;
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-route:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.btn-route svg {
    transition: var(--transition);
}

.btn-route:hover svg {
    fill: var(--white);
}

/* ===== АДАПТИВ ДЛЯ КАРТЫ ===== */

/* Планшеты */
@media (max-width: 1024px) {
    #map {
        height: 350px;
    }
}

/* Мобильные устройства */
@media (max-width: 768px) {
    .contacts__map {
        border-radius: 12px;
    }
    
    #map {
        height: 280px;
        border-radius: 12px;
    }
    
    .btn-route {
        padding: 12px 20px;
        font-size: 0.9rem;
        margin-top: 12px;
        border-radius: 10px;
    }
    
    .btn-route svg {
        width: 18px;
        height: 18px;
    }
}

/* Маленькие телефоны */
@media (max-width: 480px) {
    #map {
        height: 240px;
    }
    
    .btn-route {
        padding: 10px 16px;
        font-size: 0.85rem;
    }
}

/* Альбомная ориентация на мобилках */
@media (max-width: 896px) and (orientation: landscape) {
    #map {
        height: 200px;
    }
}

/* Для устройств с сенсорным экраном - увеличиваем зону нажатия */
@media (hover: none) and (pointer: coarse) {
    .btn-route {
        padding: 14px 20px;
    }
}

/* Плавное появление карты при загрузке */
#map {
    animation: mapFadeIn 0.5s ease-out;
}

@keyframes mapFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== АДАПТИВ ДЛЯ НОУТБУКОВ (1025px - 1280px) ===== */
@media (min-width: 1025px) and (max-width: 1280px) {
    .container {
        padding: 0 20px;
    }
    
    section {
        padding: 70px 0;
    }
    
    .section-title {
        font-size: 2.2rem;
        margin-bottom: 40px;
    }
    
    /* Герой */
    .hero {
        padding-top: 120px;
        min-height: 85vh;
    }
    
    .hero__title {
        font-size: 3rem;
    }
    
    .hero__subtitle {
        font-size: 1.15rem;
    }
    
    .hero__description {
        font-size: 1rem;
    }
    
    /* Статистика */
    .stats__grid {
        gap: 40px;
    }
    
    .stat-card__number {
        font-size: 2.8rem;
    }
    
    /* Услуги */
    .services__grid {
        gap: 24px;
    }
    
    .service-card__image {
        height: 220px;
    }
    
    .service-card__title {
        font-size: 1.25rem;
    }
    
    /* Преимущества */
    .advantages__grid {
        gap: 24px;
    }
    
    .advantage-card {
        padding: 28px 20px;
    }
    
    .advantage-card__icon-wrapper {
        width: 90px;
        height: 90px;
    }
    
    .advantage-card__icon-img {
        width: 50px;
        height: 50px;
    }
    
    .advantage-card__title {
        font-size: 1.2rem;
    }
    
    /* Слайдер */
    .work-slide__image {
        height: 280px;
    }
    
    .slider-arrow-prev {
        left: -15px;
    }
    
    .slider-arrow-next {
        right: -15px;
    }
    
    /* Форма */
    .request-form {
        padding: 36px;
    }
    
    /* Контакты */
    .contacts__grid {
        gap: 40px;
    }
    
    .contact-item {
        padding: 16px 20px;
    }
    
    /* Подвал */
    .footer {
        padding: 40px 0 20px;
    }
}



@media (min-width: 1000px) and (max-width: 1920px) {
    .container {
        max-width: 1200px;
    }
    
    section {
        padding: 50px 0;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 32px;
    }
    
    /* ===== ШАПКА И НАВИГАЦИЯ ===== */
    .header {
        padding: 12px 0;
    }
    
    .logo__img {
        height: 35px;
        max-width: 150px;
    }
    
    .nav {
        gap: 24px;
    }
    
    .nav a {
        font-size: 0.95rem;
    }
    
    .header__phone {
        font-size: 0.95rem;
    }
    
    .header__contacts {
        gap: 2px;
    }
    
    .header__email {
        font-size: 0.75rem;
    }
    
    /* ===== ГЕРОЙ ===== */
    .hero {
        padding-top: 110px;
        min-height: 85vh;
    }
    
    .hero__title {
        font-size: 2.5rem;
    }
    
    .hero__subtitle {
        font-size: 1rem;
    }
    
    .hero__description {
        font-size: 0.95rem;
    }
    
    /* ===== СТАТИСТИКА ===== */
    .stats {
        padding: 50px 0;
    }
    
    .stats__grid {
        gap: 30px;
    }
    
    .stat-card__number {
        font-size: 2.5rem;
    }
    
    .stat-card__label {
        font-size: 0.9rem;
    }
    
    /* ===== О КОМПАНИИ ===== */
    .about__content {
        padding: 36px;
    }
    
    .about__text {
        font-size: 1rem;
    }
    
    /* ===== УСЛУГИ ===== */
    .services__grid {
        gap: 20px;
    }
    
    .service-card__image {
        height: 180px;
    }
    
    .service-card__title {
        font-size: 1.15rem;
    }
    
    .service-card__content {
        padding: 18px;
    }
    
    .service-card__description {
        font-size: 0.85rem;
    }
    
    /* ===== ПРЕИМУЩЕСТВА ===== */
    .advantages__grid {
        gap: 20px;
    }
    
    .advantage-card {
        padding: 24px 16px;
    }
    
    .advantage-card__icon-wrapper {
        width: 80px;
        height: 80px;
        margin-bottom: 16px;
    }
    
    .advantage-card__icon-img {
        width: 42px;
        height: 42px;
    }
    
    .advantage-card__title {
        font-size: 1.15rem;
        margin-bottom: 10px;
    }
    
    .advantage-card__description {
        font-size: 0.85rem;
    }
    
    /* ===== СЛАЙДЕР ===== */
    .works {
        padding: 60px 0;
    }
    
    .works-slider {
        padding: 0 50px;
    }
    
    .work-slide__image {
        height: 250px;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
    }
    
    .slider-arrow-prev {
        left: -15px;
    }
    
    .slider-arrow-next {
        right: -15px;
    }
    
    .slider-dots-container {
        margin-top: 30px;
    }
    
    /* ===== ФОРМА ===== */
    .form-section {
        padding: 60px 0;
    }
    
    .form-section__subtitle {
        font-size: 0.95rem;
        margin-bottom: 30px;
    }
    
    .request-form {
        padding: 28px;
    }
    
    .form-group {
        margin-bottom: 18px;
    }
    
    .form-group label {
        font-size: 0.85rem;
    }
    
    .form-input,
    .form-textarea {
        padding: 12px 14px;
        font-size: 0.9rem;
    }
    
    /* ===== КОНТАКТЫ ===== */
    .contacts {
        padding: 60px 0;
    }
    
    .contacts__grid {
        gap: 30px;
    }
    
    .contact-item {
        padding: 12px 16px;
        gap: 14px;
    }
    
    .contact-item__icon-wrapper {
        width: 50px;
        height: 50px;
    }
    
    .contact-item__icon-img {
        width: 26px;
        height: 26px;
    }
    
    .contact-item__content h4 {
        font-size: 1rem;
    }
    
    .contact-item__content p,
    .contact-item__content a {
        font-size: 0.85rem;
    }
    
    .map-placeholder {
        min-height: 300px;
    }
    
    /* ===== ПОДВАЛ ===== */
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer__logo span {
        font-size: 1.1rem;
    }
    
    .footer__logo p {
        font-size: 0.75rem;
    }
    
    .footer__nav {
        gap: 20px;
    }
    
    .footer__nav a {
        font-size: 0.85rem;
    }
}