/* =======================
   Основные переменные и шрифты
   ======================= */
:root {
    --primary-color: #101010;      /* Основной цвет фона */
    --secondary-color: #282828;    /* Вторичный цвет (блоки, кнопки) */
    --contrast-color: #D5D800;     /* Контрастный цвет (акценты, границы) */
    --white-color: #FFFFFF;        /* Белый цвет для текста */
}

/* Импорт Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+Display:ital,wght@0,100..900;1,100..900&display=swap'); /* Импорт шрифта Noto Serif Display */

/* Кастомные шрифты */
@font-face {
    font-family: 'Cal Sans'; /* Имя кастомного шрифта */
    src: url('./fonts/CalSans-Regular.ttf'); /* Путь к файлу шрифта */
    font-weight: 400; /* Толщина */
    font-style: normal; /* Стиль */
}
@font-face {
    font-family: 'Poiret One';
    src: url('./fonts/PoiretOne-Regular.ttf');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'Raleway';
    src: url('./fonts/Raleway-VariableFont_wght.ttf');
    font-weight: 100 900;
    font-style: normal;
}

/* =======================
   Базовые стили body
   ======================= */
body {
    overflow-x: hidden;                    /* Отключаем горизонтальный скролл */
    background-color: var(--primary-color);/* Цвет фона */
    font-family: Playfair, sans-serif;     /* Основной шрифт */
    color: var(--white-color);             /* Цвет текста */
    margin: 0;                             /* Убираем внешние отступы */
    padding: 0;                            /* Убираем внутренние отступы */
}

/* =======================
   Header (шапка сайта)
   ======================= */
header {
    background: rgba(10, 10, 10, 0.95);    /* Полупрозрачный фон */
    display: flex;                         /* Flex-контейнер */
    flex-direction: column;                /* Колонка */
    justify-content: space-between;        /* Равномерно между элементами */
    align-items: center;                   /* Центрируем по горизонтали */
    position: fixed;                       /* Фиксированная шапка */
    z-index: 1000;                         /* Поверх других элементов */
    width: 100%;                           /* На всю ширину */
    transition: all 0.3s ease-in-out;      /* Плавные переходы */
    box-sizing: border-box;                /* Включаем бордеры в размеры */
}

.header-top {
    display: flex;                         /* Flex-контейнер */
    justify-content: space-between;        /* Пространство между элементами */
    align-items: flex-start;               /* Выровнять по верху */
    width: 100%;                           /* На всю ширину */
    border-bottom: 1px solid #474747;      /* Разделительная линия */
    padding: 25px 0;                       /* Внутренние отступы сверху/снизу */
    box-sizing: border-box;                /* Включаем бордеры в размеры */
}

.logo {
    padding-left: 80px;                    /* Отступ слева */
    display: flex;                         /* Flex-контейнер */
    justify-content: center;               /* Центрируем по горизонтали */
    align-items: center;                   /* Центрируем по вертикали */
    font-family: Cal Sans;                 /* Кастомный шрифт */
    font-size: 40px;                       /* Размер шрифта */
    color: var(--contrast-color);          /* Цвет логотипа */
    text-decoration: none;                 /* Без подчеркивания */
    cursor: pointer;                       /* Курсор-рука */
}

.header-bottom {
    display: flex;                         /* Flex-контейнер */
    justify-content: center;               /* Центрируем по горизонтали */
    align-items: center;                   /* Центрируем по вертикали */
    width: 100%;                           /* На всю ширину */
    padding: 10px 0;                       /* Внутренние отступы сверху/снизу */
    box-sizing: border-box;                /* Включаем бордеры в размеры */
}

.menu {
    max-width: 1000px;                     /* Максимальная ширина */
    width: 100%;                           /* На всю ширину */
    display: flex;                         /* Flex-контейнер */
    justify-content: space-around;         /* Равномерно между элементами */
    align-items: center;                   /* Центрируем по вертикали */
    gap: 20px;                             /* Промежуток между пунктами */
    font-family: Poiret One;               /* Кастомный шрифт */
}

.menu a {
    text-decoration: none;                 /* Без подчеркивания */
    color: var(--white-color);             /* Цвет текста */
    font-size: 20px;                       /* Размер шрифта */
    transition: all 0.3s ease-in-out;      /* Плавные переходы */
    position: relative;                    /* Для псевдоэлемента подчеркивания */
}
/* Подчеркивание при наведении */
.menu a::after {
    content: '';                           /* Пустое содержимое */
    position: absolute;                    /* Абсолютное позиционирование */
    left: 0;                               /* Слева */
    bottom: -3px;                          /* Чуть ниже текста */
    width: 0;                              /* Начальная ширина */
    height: 1px;                           /* Толщина линии */
    background-color: var(--white-color);  /* Цвет линии */
    transition: width 0.3s;                /* Плавное появление */
}
.menu a:hover::after {
    width: 100%;                           /* При наведении линия на всю ширину */
}

/* =======================
   Burger menu (мобильное меню)
   ======================= */
.burger {
    filter: invert(1);                     /* Инверсия цвета иконки */
    display: none;                         /* По умолчанию скрыто */
    width: 30px;                           /* Размер иконки */
    height: 30px;
}
.burger img {
    width: 100%;                           /* На всю ширину контейнера */
    height: 100%;
    object-fit: cover;                     /* Обрезка по размеру */
}

/* Навигационное меню (выезжающее слева) */
nav {
    display: none;                         /* По умолчанию скрыто */
    justify-content: center;               /* Центрируем по горизонтали */
    align-items: center;                   /* Центрируем по вертикали */
    flex-direction: column;                /* Колонка */
    position: fixed;                       /* Фиксированное позиционирование */
    top: 0;                                /* Сверху */
    left: -210px;                          /* Скрыто за левым краем */
    width: 200px;                          /* Ширина меню */
    height: 110vh;                         /* Высота чуть больше экрана */
    background-color: var(--primary-color);/* Цвет фона */
    box-shadow: #474747 0 0 10px;          /* Тень */
    z-index: 1000;                         /* Поверх других элементов */
    transition: all 0.2s ease-in-out;      /* Плавное появление */
}
nav h2 {
    text-align: center;                    /* Центрируем текст */
    font-family: Raleway;                  /* Кастомный шрифт */
    font-size: 30px;                       /* Размер шрифта */
    font-weight: 600;                      /* Жирный */
    color: var(--white-color);             /* Цвет текста */
    margin: 100px 0 50px 0;                /* Отступы сверху и снизу */
}
nav a {
    color: var(--white-color);             /* Цвет ссылок */
    text-decoration: none;                 /* Без подчеркивания */
    font-size: 20px;                       /* Размер шрифта */
    font-family: Raleway;                  /* Кастомный шрифт */
    font-weight: 400;                      /* Обычный вес */
    margin-bottom: 20px;                   /* Отступ снизу */
}

/* =======================
   Main Banner (главный баннер)
   ======================= */
.main-banner {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    height: 750px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.main-banner video {
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
    filter: brightness(0.3);   /* Затемнение видео */
}

.main-banner-content {
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    padding: 20px 0;
    z-index: 1;
}

.main-banner h1 {
    box-sizing: border-box;
    text-align: center;
    max-width: 800px;
    font-size: 40px;
    margin: 150px 15px;
}
.main-banner span {
    color: var(--contrast-color);
}
.main-banner a {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    font-size: 25px;
    font-family: Poiret One;
    gap: 10px;
    text-decoration: none;
    color: var(--white-color);
}
.main-banner a img {
    gap: 10px;
}
.main-banner a:hover {
    cursor: pointer;
    text-decoration: none;
    position: relative;
    transform: scale(1.05);
    transition: all 0.2s ease-in-out;
}

/* =======================
   Stats line (статистика)
   ======================= */
.stats-line {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    background: linear-gradient(to right, #c2c500 0%, #8D8F00 20%, #c2c500 50%, #7E8000 80%, #c2c500 100%);
    gap: 20px;
    padding: 0;
}
.stats-line h2 {
    max-width: 300px;
    text-align: center;
    font-family: Poiret One;
}

/* =======================
   Google Play Promo (промо приложения)
   ======================= */
.app-promo {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    margin-top: 15px;
    border-radius: 15px;
    padding: 10px 10px;
    width: auto;
    animation: fadeInUp 1s ease-out;
    box-shadow: #101010;
}
.app-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.play-icon {
    width: 60px;
    height: auto;
    margin-right: 20px;
    transition: transform 0.3s ease;
}
.promo-text {
    font-size: 18px;
    color: #fff;
    font-weight: bold;
    transition: color 0.3s ease;
}
.app-link:hover .play-icon {
    transform: scale(1.1);
}
.app-link:hover .promo-text {
    color: #ffd700;
}

/* Анимация появления */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =======================
   Car types (категории авто)
   ======================= */
.car-types {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    padding: 0 0 60px 0;
    border-bottom: 3px solid var(--contrast-color);
}
.car-types h1 {
    text-align: center;
    font-size: 30px;
    font-family: Poiret One;
    margin: 50px 0 30px 0;
}
.car-types-carousel-wrapper {
    width: 100%;
    position: relative;
    overflow: hidden;
}
.car-types-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
    transition: transform 0.4s cubic-bezier(.4,0,.2,1);
    will-change: transform;
}
.car-type {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 200px;
    height: 300px;
    background-color: var(--secondary-color);
    border: 1px solid var(--contrast-color);
    border-radius: 10px;
    padding: 0;
    box-sizing: border-box;
}
.car-img {
    padding: 10px;
    width: 180px;
    height: 100px;
}
.car-type img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}
.car-types-container .car-type h2 {
    text-align: center;
    font-family: Poiret One;
    font-size: 20px;
    color: var(--white-color);
}
.car-types-container .car-type a {
    text-decoration: none;
    cursor: pointer;
    color: var(--white-color);
    font-size: 16px;
    font-family: Raleway;
    border: 1px solid var(--contrast-color);
    border-radius: 5px;
    padding: 10px 15px;
    background-color: var(--secondary-color);
    transition: all 0.2s ease-in-out;
}
.car-types-container .car-type a:hover {
    background-color: var(--white-color);
    color: var(--primary-color);
}
.learn-more-button {
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    color: var(--white-color);
    font-size: 20px;
    font-family: Raleway;
    border: 1px solid var(--contrast-color);
    border-radius: 5px;
    padding: 15px 15px;
    background-color: var(--secondary-color);
    transition: all 0.2s ease-in-out;
}
.learn-more-button:hover {
    background-color: var(--white-color);
    color: var(--primary-color);
}

/* =======================
   Managers (карусель менеджеров)
   ======================= */
    .section-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      width: 75vw;
      margin: 0 auto 10px;
    }
    .section-header h2 { font-size: 24px; }
    .controls { display: flex; align-items: center; }
    .dot, .arrow {
      cursor: pointer;
      background: #222;
      border: none;
      margin: 0 5px;
      width: 12px;
      height: 12px;
      border-radius: 50%;
      transition: background 0.3s;
    }
    .dot.active { background: #c2c500; }
    .arrow {
      width: 30px;
      height: 30px;
      font-size: 18px;
      color: #c2c500;
      line-height: 30px;
      text-align: center;
    }
    .carousel-wrapper {
      position: relative;
      width: 75vw;
      margin: 0 auto;
      overflow: hidden;
    }
    .carousel-track {
      display: flex;
      transition: transform 0.8s ease-in-out;
      /* Добавлено для предотвращения "просвечивания" последней карточки */
      width: calc(100% * 7 / 3); /* 7 карточек, 3 на страницу */
      align-items: stretch; /* Все карточки по высоте самой высокой */
    }
    .manager-card {
      flex: 0 0 31.25%;
      box-sizing: border-box;
      border-radius: 25px;
      margin: 20px 10px 5px 10px;
      text-align: center;
      /* height: 60vh;  -- убрано фиксированную высоту */
      height: auto; /* Высота по контенту */
      display: flex;
      flex-direction: column;
      overflow: hidden;
      transition: box-shadow 0.3s, transform 0.3s;
      align-items: stretch; /* Растягиваем по высоте */
    }
    .manager-card:hover {
      box-shadow: 0 0 25px #c2c500;
      transform: translateY(-5px);
    }
    .manager-photo-wrapper {
      flex: 0 0 auto;
      display: flex;
      align-items: stretch;
      justify-content: stretch;
      width: 100%;
      height: 320px;
      min-height: 220px;
      max-height: 400px;
      margin: 0;
      padding: 0;
      display: flex;
      align-items: flex-start; /* строго от верха */
      justify-content: flex-start;
      border-radius: 25px 25px 0 0;
      overflow: hidden;
    }
    .manager-photo {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: top; /* всегда от верхнего края */
      border-radius: 25px 25px 0 0;
      display: block;
      transition: transform 0.3s;
    }
    .manager-name { font-size: 18px; font-weight: bold; }
    .manager-exp { font-size: 14px; margin-bottom: 10px; }
    .badge {
      display: inline-block;
      padding: 4px 8px;
      border-radius: 5px;
      margin: 3px 3px 15px 3px;
      font-size: 12px;
      color: #fff;
    }
    .badge.Autobaza { background: #d08700; }
    .badge.AutoBazaPrigon { background: #268a33; }
    .badge.AutoBazaPlus { background: #0a0dca; }
    .manager-desc {
        font-family: 'Noto Serif Display', serif;
      font-size: 17px;
      line-height: 1.4;
      margin: 10px;
      padding: 0 10px;
      /* overflow-y: auto;  -- убрано */
      /* max-height: 100px; -- убрано */
      height: auto;
    }
    .contact-button {
      margin: 10px auto;
      padding: 10px 20px;
      background-color: #c2c500;
      color: rgb(227, 23, 23);
      text-decoration: none;
      border-radius: 8px;
      font-weight: bold;
      transition: background 0.3s;
      display: inline-block;
    }
    .contact-button:hover { background-color: #dad820; }
    .progress-bar {
      width: 75vw;
      max-width: 75vw;
      height: 4px;
      background: transparent;
      margin: 20px auto;
      display: flex;
      justify-content: space-between;
      gap: 6px;
    }
    .progress-segment {
      flex: 1 1 0;
      background-color: #222;
      cursor: pointer;
      position: relative;
      transition: background-color 0.3s;
      border-radius: 2px;
      margin: 0;
      height: 100%;
    }
    .progress-segment:hover { background-color: #c2c500; }
    .progress-indicator {
      position: absolute;
      top: 0; left: 0;
      height: 100%; width: 100%;
      background-color: #c2c500;
      opacity: 0;
      transition: opacity 0.3s;
      border-radius: 25px;
    }
    .progress-segment.active .progress-indicator { opacity: 1; }
    /* --- Мобильная адаптация --- */
    @media (max-width: 950px) {
      .carousel-wrapper, .section-header, .progress-bar {
        width: 90vw;                          /* 90% ширины окна */
        max-width: 90vw;
        margin: 1vw auto;
        padding: 0;
      }
      .carousel-track {
        width: 90vw;
        max-width: 90vw;
        min-width: 90vw;
        gap: 0;
        align-items: stretch; /* Все карточки по высоте самой высокой */
      }
      .manager-card {
        flex: 0 0 90vw;
        max-width: 100vw;
        width: 100vw;
        min-height: unset; /* убрано */
        height: auto; /* Высота по контенту */
        border-radius: 18px;
        border: 3px solid #c2c500;
        margin: 0 auto 10px auto;
        box-shadow: none !important;
        transform: none !important;
        transition: none !important;
        align-items: stretch; /* Растягиваем по высоте */
        padding: 0 0 20px 0;
      }
      .manager-photo-wrapper {
        width: 100%;
        height: auto;
        min-height: 200px;
        max-height: 55vh;
        margin: 0;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 18px 18px 0 0;
        overflow: hidden;
      }
      .manager-photo {
        width: 100%;
        height: 100%;
        min-height: 180px;
        object-fit: contain;
        border-radius: 18px 18px 0 0;
      }
      .manager-name,
      .manager-exp,
      .badge,
      .manager-desc,
      .contact-button {
        width: 100%;
        max-width: 300px;
        margin-left: auto;
        margin-right: auto;
        text-align: center;
        box-sizing: border-box;
      }
      .progress-bar {
        width: 90vw;
        max-width: 90vw;
        margin: 2vh auto 0 auto;
        gap: 4px;
        height: 6px;
        padding: 0 2vw;
      }
      .dot, .arrow {
        min-width: 32px;
        min-height: 32px;
      }
      .dot { width: 12px; height: 12px; }
      .arrow {
        width: 32px;
        height: 32px;
        font-size: 18px;
        line-height: 32px;
        margin-bottom: 2vh;
      }
      .section-header h2 { font-size: 17px; margin-bottom: 2vh; }
    }
    @media (max-width: 600px) {
      .manager-card { border-width: 2px; }
    }
    @media (max-width: 420px) {
      .manager-card { min-height: 75vh; height: 75vh; }
    }
    @media (max-width: 375px) {
      .manager-card { min-height: 85vh; height: 85vh; }
    }
    @media (min-width: 951px) {
      .carousel-wrapper {
        width: 100%;
        max-width: 100%;
        min-width: 100%;
        margin: 0 auto;
        overflow: hidden;
      }
      .carousel-track {
        width: 100%;
        max-width: 100%;
        min-width: 100%;
        display: flex;
        gap: 4%;
        transition: transform 0.8s ease-in-out;
        align-items: stretch; /* Все карточки по высоте самой высокой */
      }
      .manager-card {
        flex: 0 0 30%;
        max-width: 28%;
        width: 28%;
        min-width: 28%;
        box-sizing: border-box;
        margin: 1vw 1vw 1vw 1vw;
        transition: box-shadow 0.3s, transform 0.3s;
        height: auto; /* Высота по контенту */
        align-items: stretch; /* Растягиваем по высоте */
      }
      .manager-photo-wrapper {
        width: cover; /* на всю ширину карточки */
        /* height: 320px;
        min-height: 220px;
        max-height: 400px; */
        height: auto; /* убираем фиксированную высоту */
        aspect-ratio: 3/2; /* или 3/2, подберите нужное соотношение */
        margin: 0;
        padding: 0;
        display: flex;
        align-items: stretch;
        justify-content: stretch;
        border-radius: 25px 25px 0 0;
        overflow: hidden;
      }
      .manager-photo {
        width: 100%;
        height: 100%;
        object-fit: contain; /* показываем фото полностью */
        object-position: top;
        border-radius: 25px 25px 0 0;
        display: block;
        transition: transform 0.3s;
      }
    }


/* =======================
   Reviews (отзывы)
   ======================= */
/* Контейнер отзывов */
#header_review {
    display: flex;
    justify-content: center;
    align-items: center;
}

.reviews {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 10px 0px 10px;
  overflow: hidden; /* Скрывает выходящий за пределы контент */
  width: 100vw;
  box-sizing: border-box;
  border-bottom: 3px solid var(--contrast-color);
  height: 60vh; /* Высота блока отзывов 60% окна */
}
.marquee-row {
  display: flex;
  flex-direction: column; /* Вертикальное направление */
  overflow: hidden;
  margin-bottom: 0;
  height: 60vh; /* Высота ряда отзывов 60% окна */
  width: 250px;
  justify-content: flex-start;
  margin-left: 0;
  margin-right: 0;
  position: relative; /* Для позиционирования анимации */}
/* Один ряд с бегущей строкой */
.marquee-row {
      display: flex;
      flex-direction: column; /* Вертикальное направление */
      overflow: hidden;
      margin-bottom: 0;
      height: 60vh; /* Половина высоты окна */
      width: 250px;
      justify-content: flex-start;
      margin-left: 0;
      margin-right: 0;
      position: relative; /* Для позиционирования анимации */}
    /* Трек для анимации отзывов */
    .marquee-track {
      display: flex;
      flex-direction: column; /* Вертикально */
      gap: 20px;
      width: 100%;
      animation: scroll-up 60s linear infinite; /* Анимация движения вверх */
    }
    /* Средний ряд: ускоренная анимация и обратное направление */
    .marquee-row.medium .marquee-track {
      animation-duration: 55s; /* Быстрее */
      animation-direction: reverse; /* В обратную сторону */
    }
    /* Быстрый ряд: ещё быстрее */
    .marquee-row.fast .marquee-track {
      animation-duration: 45s;
    }
    /* Карточка отзыва */
    .review_part {
      background: #1a1a1a;
      padding: 20px;
      border-radius: 10px;
      width: 190px;
      min-height: 50px;
      flex-shrink: 0; /* Не сжимается */
      display: flex;
      flex-direction: column;
      align-items: center;
      text-align: center;
      font-size: 14px; /* Размер шрифта для отзывов */
      border: 1px solid #D5D800;
    }
    /* Аватар пользователя */
    .review_part img {
      width: 80px;
      height: 30px;
      border-radius: 25%; /* Круглый аватар */
      margin-bottom: 10px;
      object-fit: unset; /* Обрезка по размеру */
    }
    /* Ссылка "Просмотр" */
    .review_part a {
      color: #c2c500;
      text-decoration: none;
      margin-top: 10px;
      display: inline-block;
    }
    /* Вертикальная анимация */
    @keyframes scroll-up {
      0% { transform: translateY(0); }
      100% { transform: translateY(-50%); }
    }
/* =======================
   Form (форма обратной связи)
   ======================= */
#contact {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    padding: 20px 0 60px 0;
    border-bottom: 3px solid var(--contrast-color);
}
#contact h1 {
    text-align: center;
    font-family: Poiret One;
    font-size: 40px;
    color: var(--white-color);
}
form {
    width: 250px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    padding: 20px 20px;
    border: 1px solid var(--contrast-color);
    border-radius: 10px;
}
.form-group {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}
.form-group label {
    text-align: left;
    align-self: flex-start;
    font-family: Noto Serif;
    font-size: 16px;
    color: var(--white-color);
}
.form-group input {
    width: 100%;
    height: 20px;
    border: 1px solid var(--contrast-color);
    border-radius: 5px;
    padding: 5px 5px 5px 24px; /* уменьшен левый отступ */
    color: black;
    transition: border-color 0.2s;
}
form button {
    margin-top: 10px;
    max-width: 150px;
    width: 100%;
    height: 40px;
    border: 1px solid var(--contrast-color);
    border-radius: 5px;
    padding: 5px;
    background-color: var(--secondary-color);
    color: var(--white-color);
    font-size: 18px;
    font-family: Raleway;
    transition: all 0.2s ease-in-out;
}
form button:hover {
    background-color: var(--white-color);
    color: var(--primary-color);
}

/* =======================
   Footer (подвал сайта)
   ======================= */
footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    padding: 20px 0;
    border-top: 3px solid var(--contrast-color);
    background-color: black;
    color: var(--white-color);
    font-family: Noto Serif;
}
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 0px;
}
.footer-logo {
    font-size: 24px;
    font-family: Cal Sans;
    color: var(--contrast-color);
    margin: 0 20px;
}
.footer-menu {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin: 15px;
    align-self: flex-end;
}
.footer-menu a {
    text-decoration: none;
    color: var(--white-color);
    font-size: 16px;
    transition: color 0.3s ease-in-out;
}
.footer-menu a:hover {
    color: var(--contrast-color);
}
.footer-bottom {
    text-align: center;
    font-size: 14px;
    color: var(--white-color);
}

/* =======================
   Контакты (карточки контактов)
   ======================= */
.contacts-section {
    text-align: center;
    padding: 60px 20px;
    background: #111;
    animation: fadeIn 1s ease-out both;
}
.contacts-title {
    font-size: 36px;
    color: #fff;
    margin-bottom: 40px;
    animation: slideDown 0.8s ease-out both;
}
.contacts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 10px;
}
.contact-card {
    background: #1c1c1c;
    border-radius: 20px;
    padding: 20px;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #D5D800;
    text-decoration: none;
    animation: zoomIn 0.5s ease-in-out both;
}
.contact-card:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px #D5D80066;
}
.contact-card img {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    object-fit: contain;
}
.contact-card img.telegram_logo {
    width: 65px !important;
    height: 65px !important;
    margin-bottom: 10px !important;
    margin-top: -7px !important;
}
#email_logo, #call_logo {
    width: 80px;
    height: 80px;
    margin-top: -15px;
    margin-bottom: 0;
    object-fit: contain;
}
#car_logo {
    width: 125%;
    height: 130%;
    margin-top: -26%;
    margin-bottom: -17%;
    object-fit: contain;
}
#tiktok_logo{
    margin-top: 3px;
    margin-bottom: 15px;
}

/* --- Анимации --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideDown {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}


/* =======================
   Privacy Policy (политика конфиденциальности)
   ======================= */
    .privacy-wrapper {
            margin: 180px auto 40px auto;
            padding: 40px 32px 32px 32px;
            background: #181818;
            border-radius: 18px;
            box-shadow: 0 4px 32px 0 rgba(0,0,0,0.18);
            max-width: 800px;
            color: #fff;
            font-family: 'Raleway', 'Noto Serif', Arial, sans-serif;
            font-size: 18px;
            line-height: 1.7;
        }
        .privacy-wrapper h1 {
            text-align: center;
            color: #D5D800;
            font-size: 2.2em;
            margin-bottom: 32px;
            margin-left: 0;
        }
        .privacy-wrapper h2 {
            color: #D5D800;
            font-size: 1.3em;
            margin-top: 32px;
            margin-bottom: 12px;
            font-weight: 600;
        }
        .privacy-wrapper ul {
            margin: 0 0 18px 18px;
            padding-left: 18px;
        }
        .privacy-wrapper li {
            margin-bottom: 7px;
        }
        .privacy-wrapper p {
            margin: 10px 0;
        }
        .privacy-wrapper a {
            color: #D5D800;
            text-decoration: underline;
            word-break: break-all;
        }
        .privacy-wrapper strong {
            color: #D5D800;
            font-weight: 600;
        }
        @media (max-width: 900px) {
            .privacy-wrapper {
                margin: 120px 5vw 30px 5vw;
                padding: 20px 5vw;
                font-size: 16px;
            }
        }
        @media (max-width: 600px) {
            .privacy-wrapper {
                margin: 25% 2vw 20px 2vw;
                padding: 10px 2vw;
                font-size: 15px;
            }
            .privacy-wrapper h1 {
                font-size: 1.2em;
            }
            .privacy-wrapper h2 {
                font-size: 1em;
            }
        }
        @media (max-width: 500px) {
         .privacy-wrapper {
                margin: 30% 2vw 20px 2vw;
            }   
        }
        @media (max-width: 450px) {
         .privacy-wrapper {
                margin: 40% 2vw 20px 2vw;
            }   
        }
        @media (max-width: 375px) {
         .privacy-wrapper {
                margin: 45% 2vw 20px 2vw;
            }   
        }
        @media (max-width: 320px) {
         .privacy-wrapper {
                margin: 50% 2vw 20px 2vw;
            }   
        }

/* =======================
   Media Queries (адаптив)
   ======================= */
    
   /* --- 950px: адаптация карусели авто --- */
    @media (max-width: 950px) {
    .car-types-carousel-wrapper {
        overflow: hidden;
        width: 100vw;
        max-width: none;
        margin: 0 auto;
        position: relative;
    }
    .car-types-container {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 0;
        margin: 0;
        padding: 0;
        box-sizing: border-box;
        transition: transform 0.4s cubic-bezier(.4,0,.2,1);
        will-change: transform;
        overflow: hidden;
        align-items: stretch;
        width: auto;
        max-width: none;
        min-width: 0;
    }
    .car-type {
        width: 80vw;
        min-width: 80vw;
        max-width: 80vw;
        height: 48vh; /* уменьшено на 20% от 60vh */
        max-height: 48vh;
        border-radius: 16px;
        border: 1% solid #D5D800;
        flex-shrink: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        background-color: var(--secondary-color);
        box-sizing: border-box;
        text-align: center;
        margin-left: 0;
        margin-right: 0;
    }
}

/* --- 320px: экстремально маленькие экраны --- */
@media (max-width: 320px) {
    .google_play{
        flex-direction: column;
        align-items: center; 
        height: 50px;
        width: 50px;
    }
    
    .contacts-section {
        padding: 5px 0;
    }
    .contacts-title {
        font-size: 11px;
        margin-bottom: 6px;
    }
    .contacts-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0;
        padding: 0 4px;
    }
    .contact-card {
        width: 95%;
        min-width: 0;
        margin: 0;
        padding: 6px 2px;
        border-radius: 8px;
        font-size: 10px;
        box-sizing: border-box;
    }
    .contact-card img {
        width: 18px;
        height: 18px;
        margin-bottom: 2px;
    }
    #tel_text {
        font-size: 12px;
    }
    #email_logo {
        width: 70% !important;
        height: 70% !important;
        margin-top: -2px;
    }
    #car_logo {
        width: 120%;
        height: 120%;
        margin-top: -20% !important;
        margin-bottom: -18% !important;
    }
    #tiktok_logo {
        width: 50%;
        height: 50%;
        margin-top: 5% !important;
        margin-bottom: 12% !important;
    }
    #privacy_logo {
        width: 40%;
        height: 40%;
        margin-top: 5% !important;
        margin-bottom: 12% !important;
    }
}

/* --- 450px: уменьшение карточек контактов --- */
@media (max-width: 450px) {
    .contacts-section {
        padding: 30px 2px;
    }
    .contacts-title {
        font-size: 22px;
        margin-bottom: 20px;
    }
    .contacts-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px;
        padding: 0 1px;
    }
    .contact-card {
        padding: 10px;
        border-radius: 12px;
        font-size: 13px;
        box-sizing: border-box;
        display: flex;
    }
    .contact-card img {
        width: 32px;
        height: 32px;
        margin-bottom: 6px;
    }
    #email_logo {
        width: 60%;
        height: 60%;
        margin-top: -8px;
    }
    #privacy_logo {
        width: 40%;
        height: 40%;
        margin-top: 5%;
    }
    .contact-card #tiktok_logo , .contact-card #car_logo  {
        height: 120px; /* подбери вручную, например 120-130px */
        overflow: hidden;
    }

    #tiktok_logo {
        width: 30%;
        height: 30%;
        margin-top: -20% !important;
        margin-bottom: -10% !important;
    }
    #car_logo {
        width: 100%;
        height: 100%;
        margin-top: -18% !important;
        margin-bottom: -10% !important;
    }
    #TikTok  {
        padding: 0;
        margin: 0;
    }
    #Sell_Auto {
        padding: 0;
        margin: 0;
    }


}

/* --- 600px: сетка контактов --- */
@media (max-width: 600px) {
    .contacts-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 16px;
        padding: 0 2px;
    }
}

/* --- 700px: мобильное меню, адаптация блоков --- */
@media (max-width: 700px) {
    .contacts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
        padding: 0 2px;
    }
    .header-top {
        flex-direction: column;
        align-items: center;
    }
    .logo {
        padding: 0;
    }
    .menu {
        display: none;
    }
    .burger {
        display: block;
    }
    nav {
        display: flex;
    }
    .main-banner h1 {
        font-size: 30px;
    }
    .stats-line {
        flex-direction: column;
        align-items: center;
        background: var(--primary-color);
        border-bottom: 2px solid var(--contrast-color);
        padding: 20px 0;
    }
    .stats-line h2 {
        font-size: 18px;
        max-width: 200px;
    }
    /* УДАЛИТЬ или закомментировать эти строки, чтобы не ломать горизонтальную карусель: */
    /* .car-types-container {
        flex-direction: column;
        align-items: center;
    }
    .car-types-container .car-type {
        width: 90%;
        max-width: 300px;
    } */
    .managers h1 {
        font-size: 30px;
    }
    .review {
        max-width: 300px;
        max-height: 80px;
    }
    .review-photo {
        width: 70px;
        height: 70px;
    }
    .review-text {
        max-width: 200px;
    }
    .review-text h3 {
        font-size: 16px;
    }
    .review-text p {
        font-size: 12px;
    }
    #contact h1 {
        font-size: 30px;
    }
}

/* --- 900px: уменьшение шрифта статистики --- */
@media (max-width: 900px) {
    .stats-line h2 {
        font-size: 20px;
        max-width: 280px;
    }
    .contacts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
        padding: 0 2px;
    }
    
}

/* --- 950px: менеджеры в колонку --- */
@media (max-width: 950px) {
    .manager1, .manager2, .manager3 {
        flex-direction: column;
        align-items: center;
    }
    .manager2 {
        flex-direction: column-reverse;
    }
    #manager a {
        align-self: center;
    }
    .manager1-text, .manager2-text, .manager3-text {
        max-width: 100%;
        margin: 0 15px;
    }
}

/* --- Мобильная адаптация: только 1 ряд отзывов --- */
@media (max-width: 700px) {
  .reviews {
    flex-direction: column;
    align-items: center;
    height: 60vh;
  }
  .marquee-row.medium,
  .marquee-row.fast {
    display: none !important;
  }
  .marquee-row.slow {
    width: 90vw;
    max-width: 90vw;
    min-width: 90vw;
    height: 60vh;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto; /* разрешаем события */
  }
  .marquee-track {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: auto; /* разрешаем события */
  }
  .review_part {
    margin-left: auto;
    margin-right: auto;
    pointer-events: auto; /* разрешаем события */
  }
  .review_part a {
    pointer-events: auto !important; /* обязательно разрешаем клики по ссылке */
    z-index: 1;
    position: relative;
  }
}

/* =======================
   Auto Baza (авто baza)
   ======================= */
.auto-baza {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 60px 20px;
    background: #101010;
    border-bottom: 3px solid var(--contrast-color);
}
.auto-baza h1 {
    font-size: 36px;
    color: var(--white-color);
    margin-bottom: 40px;
    text-align: center;
    font-family: Poiret One;
}
.auto-bаза p {
    font-size: 18px;
    color: var(--white-color);
    margin-bottom: 30px;
    text-align: center;
    max-width: 800px;
}
.auto-bаза .car-types {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 10px;
}
.auto-bаза .car-type {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 220px;
    height: 320px;
    background-color: var(--secondary-color);
    border: 1px solid var(--contrast-color);
    border-radius: 10px;
    padding: 0;
    box-sizing: border-box;
}
.auto-bаза .car-img {
    padding: 10px;
    width: 200px;
    height: 120px;
}
.auto-bаза .car-type img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}
.auto-bаза .car-types-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
    transition: transform 0.4s cubic-bezier(.4,0,.2,1);
    will-change: transform;
}
.auto-bаzа .car-types-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 10px;
    gap: 8px;
}
.auto-bаза .car-types-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ccc;
    display: inline-block;
    margin: 0 3px;
    cursor: pointer;
}
.auto-baza .car-types-dot.active {
    background: #c2c500;
}
.auto-baza .car-types-controls .arrow {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #c2c500;
    padding: 0 8px;
}
@media (min-width: 951px) {
    .car-types-controls {
        display: none !important;
    }
}

/* --- Мобильная адаптация --- */
@media (max-width: 950px) {
    .auto-bаза .car-types-carousel-wrapper {
        overflow: hidden;
        width: 100vw;
        max-width: 100vw;
        margin: 0 auto;
        position: relative;
    }
    .auto-baza .car-types-container {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        width: 100vw;
        max-width: 100vw;
        min-width: 100vw;
        gap: 0;
        margin: 0;
        padding: 0;
        box-sizing: border-box;
        transition: transform 0.4s cubic-bezier(.4,0,.2,1);
        will-change: transform;
        overflow: hidden;
    }
    .auto-baza .car-type {
        min-width: 100vw;
        max-width: 100vw;
        width: 100vw;
        box-sizing: border-box;
        margin: 0;
        border-radius: 0;
        flex-shrink: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    .auto-baza .car-img {
        width: 90vw;
        max-width: 90vw;
        min-width: 90vw;
        height: 120px;
        padding: 10px 0;
    }
    .auto-baza .car-types-controls {
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 10px;
        gap: 8px;
    }
    .auto-baza .car-types-dot {
        width: 10px;
        height: 10px;
        border-radius: 50%;
        background: #ccc;
        display: inline-block;
        margin: 0 3px;
        cursor: pointer;
    }
    .auto-baza .car-types-dot.active {
        background: #c2c500;
    }
    .auto-baza .car-types-controls .arrow {
        background: none;
        border: none;
        font-size: 24px;
        cursor: pointer;
        color: #c2c500;
        padding: 0 8px;
    }
}

/* --- Прогресс-бар для типов автомобилей: только мобильная адаптация --- */
@media (max-width: 950px) {
    .car-types-progress-bar {
        width: 90vw;
        max-width: 90vw;
        margin: 18px auto 0 auto;
        gap: 4px;
        height: 6px;
        padding: 0 2vw;
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: relative;
        z-index: 2;
    }
    .car-types-progress-bar .progress-segment {
        flex: 1 1 0;
        background-color: #222;
        cursor: pointer;
        position: relative;
        transition: background-color 0.3s;
        border-radius: 2px;
        margin: 0;
        height: 100%;
        min-width: 18px;
        max-width: 60px;
    }
    .car-types-progress-bar .progress-segment:hover { background-color: #c2c500; }
    .car-types-progress-bar .progress-indicator {
        position: absolute;
        top: 0; left: 0;
        height: 100%; width: 100%;
        background-color: #c2c500;
        opacity: 0;
        transition: opacity 0.3s;
        border-radius: 25px;
    }
    .car-types-progress-bar .progress-segment.active .progress-indicator { opacity: 1; }
}
@media (min-width: 951px) {
    .car-types-progress-bar {
        display: none !important;
    }
}

/* --- Исправление прогресс-бара менеджеров для мобильной версии --- */
@media (max-width: 950px) {
  .progress-bar {
    width: 90vw;
    max-width: 90vw;
    margin: 2vh auto 0 auto;
    gap: 4px;
    height: 6px;
    padding: 0 2vw;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
  }
  .progress-bar .progress-segment {
    flex: 1 1 0;
    background-color: #222;
    cursor: pointer;
    position: relative;
    transition: background-color 0.3s;
    border-radius: 2px;
    margin: 0;
    height: 100%;
    min-width: 18px;
    max-width: 60px;
  }
  .progress-bar .progress-segment:hover { background-color: #c2c500; }
  .progress-bar .progress-indicator {
    position: absolute;
    top: 0; left: 0;
    height: 100%; width: 100%;
    background-color: #c2c500;
    opacity: 0;
    transition: opacity 0.3s;
    border-radius: 25px;
  }
  .progress-bar .progress-segment.active .progress-indicator { opacity: 1; }
}

/* --- Кружок вокруг блока управления менеджерами (адаптивно для мобильных и планшетов) --- */
@media (max-width: 950px) {
    .controls {
        margin-top: 2vw;
    }
}

/* --- Обводка блока управления кнопками (адаптивно для всех экранов) --- */
@media (min-width: 951px) {
  .section-header .controls {
    margin-top: 1vw;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 22px;
    box-shadow: 0 0 0 3px #c2c500;
    padding: 6px 22px;
    min-width: 0;
    min-height: 0;
    width: auto;
    height: auto;
    gap: 10px;
    z-index: 2;
    position: relative;
  }
}
