/* Мягкая блокировка горизонтального скролла */
html, body {
  max-width: 100%;
  overflow-x: hidden;
  position: relative;
}

/* Вспомогательные классы */
.mobile-hide {
  display: inline-flex;
}

@media (max-width: 768px) {
  .mobile-hide {
    display: none !important;
  }
}

/* Мобильное меню и адаптивность */

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1001;
}

.mobile-menu-btn span {
  display: block;
  width: 25px;
  height: 2px;
  background-color: #fff;
  margin: 5px 0;
  transition: 0.3s;
}

/* Навигация в шапке (десктопная) */
@media (max-width: 991px) {
  .Header-module__hBw1pG__nav {
    display: none !important;
  }
  
  .mobile-menu-btn {
    display: block;
  }

  .Header-module__hBw1pG__actions {
     margin-left: auto;
     margin-right: 10px;
  }
  
  /* Скрываем кнопку в шапке на мобильных, чтобы не теснила логотип */
  .Header-module__hBw1pG__actions button {
    display: none !important;
  }
}

/* Мобильное выпадающее меню */
.mobile-nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100vh;
  background-image: linear-gradient(rgba(0,0,0,0.85), rgba(0,0,0,0.85)), url('/img/mobile_menu_bg.png');
  background-size: cover;
  background-position: center;
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  visibility: hidden;
}

.mobile-nav::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at center, transparent 0%, rgba(0,0,0,0.5) 100%);
  pointer-events: none;
}

.mobile-nav.active {
  right: 0;
  visibility: visible;
}

.mobile-nav a {
  font-size: 1.8rem;
  color: #fff;
  text-decoration: none;
  margin: 20px 0;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 3px;
  transition: 0.3s;
  opacity: 0;
  transform: translateY(20px);
  position: relative;
  z-index: 2;
}

.mobile-nav.active a {
  opacity: 1;
  transform: translateY(0);
}

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

.mobile-nav a:hover {
  color: #d4af37;
  text-shadow: 0 0 15px rgba(212, 175, 55, 0.5);
}

/* Анимация бургера */
.mobile-menu-btn.active span:nth-child(1) {
  transform: rotate(-45deg) translate(-5px, 6px);
}
.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
}
.mobile-menu-btn.active span:nth-child(3) {
  transform: rotate(45deg) translate(-5px, -6px);
}

/* РЕДИЗАЙН HERO НА ГЛАВНОЙ (СИММЕТРИЯ + ГАЛОЧКИ) */
.home-hero-v2 {
  position: relative;
  text-align: center;
  background-image: url('/img/home_hero_v3.png');
  background-position: center;
  background-size: cover;
  align-items: center;
  min-height: 85vh;
  padding: 240px 0 180px; 
  display: flex !important;
  justify-content: center;
  overflow: hidden;
  background-attachment: fixed;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.85) 100%);
  z-index: 1;
}

.home-hero-v2 .container {
  position: relative;
  z-index: 3; /* Поднимаем контент выше всех оверлеев */
  width: 100%;
}

/* МЯГКИЙ ПЕРЕХОД К СЛЕДУЮЩЕМУ БЛОКУ */
.home-hero-v2::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 30%; /* Градиент на нижние 30% блока */
  background: linear-gradient(to bottom, transparent 0%, #050505 100%);
  z-index: 2;
  pointer-events: none;
}

.home-hero-v2 .page-module___8aEwW__heroContent {
  margin: 0 auto; /* ЦЕНТРИРУЕМ ВЕСЬ БЛОК */
  max-width: 900px; /* Увеличиваем ширину */
  text-align: center;
}

.home-hero-v2 .page-module___8aEwW__heroTitle {
  margin: 0 auto 24px;
  text-align: center;
  font-size: 3.5rem; 
  color: #fff;
  font-weight: 300; 
  line-height: 1.15;
}

.home-hero-v2 .page-module___8aEwW__heroSubtitle {
  margin: 0 auto 40px; /* ЦЕНТРИРУЕМ ОПИСАНИЕ */
  text-align: center;
  max-width: 650px;
  color: var(--text-secondary);
  font-size: 1.25rem;
  line-height: 1.6;
}

/* КРАСИВЫЕ ГАЛОЧКИ */
.hero-features-v2 {
  display: flex;
  justify-content: center;
  gap: 24px; /* Уменьшил с 32 */
  margin-bottom: 50px;
  flex-wrap: nowrap; /* Запрещаем перенос на десктопе */
}

.hero-feature-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 0.95rem; /* Уменьшил с 1.05 */
  font-weight: 500;
  white-space: nowrap; /* Текст внутри не переносим */
}

.feature-check {
  color: #c8a97e; /* var(--accent-color) */
  font-size: 1.3rem;
  font-weight: 900;
  text-shadow: 0 0 10px rgba(200, 169, 126, 0.4);
}

.home-hero-v2 .page-module___8aEwW__heroActions {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.home-hero-v2 .btn-primary,
.home-hero-v2 .btn-outline {
  padding: 16px 32px;
  font-size: .85rem;
  min-width: 220px;
  justify-content: center;
}

/* Глобальные стили кнопок */
.btn-primary, .btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
  border-radius: 4px;
}

/* Кнопки в блоке контактов */
.contact-socials {
  display: flex;
  flex-wrap: wrap; 
  gap: 12px;
  margin-top: 20px;
}

.contact-socials .btn-outline {
  flex: 1;
  min-width: 150px;
  padding: 14px 20px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  gap: 10px;
}

.contact-socials .btn-outline:hover {
  background: rgba(255,255,255,0.1);
  border-color: #d4af37;
  color: #d4af37;
}

/* Иконки для кнопок (SVG через маску для премиального вида) */
.contact-socials .btn-outline::before {
  content: "";
  display: block;
  width: 20px;
  height: 20px;
  background-color: currentColor;
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}

.contact-socials a[href*="wa.me"]::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M380.9 97.1C339 55.1 283.2 32 223.9 32c-122.4 0-222 99.6-222 222 0 39.1 10.2 77.3 29.6 111L0 480l117.7-30.9c32.4 17.7 68.9 27 106.1 27h.1c122.3 0 224.1-99.6 224.1-222 0-59.3-25.2-115-67.1-157zm-157 341.6c-33.2 0-65.7-8.9-94-25.7l-6.7-4-69.8 18.3L72 359.2l-4.4-7c-18.5-29.4-28.2-63.3-28.2-98.2 0-101.7 82.8-184.5 184.6-184.5 49.3 0 95.6 19.2 130.4 54.1 34.8 34.9 56.2 81.2 56.1 130.5 0 101.8-84.9 184.6-186.6 184.6zm101.2-138.2c-5.5-2.8-32.8-16.2-37.9-18-5.1-1.9-8.8-2.8-12.5 2.8-3.7 5.6-14.3 18-17.6 21.8-3.2 3.7-6.5 4.2-12 1.4-5.5-2.8-23.2-8.5-44.2-27.1-16.4-14.6-27.4-32.7-30.6-38.1-3.2-5.6-.3-8.6 2.5-11.4 2.5-2.5 5.5-6.5 8.3-9.7 2.8-3.2 3.7-5.5 5.5-9.2 1.9-3.7 1-6.9-.5-9.7-1.4-2.8-12.5-30.1-17.1-41.2-4.5-10.8-9.1-9.3-12.5-9.5-3.2-.2-6.9-.2-10.6-.2-3.7 0-9.7 1.4-14.8 6.9-5.1 5.6-19.4 19-19.4 46.3 0 27.3 19.9 53.7 22.6 57.4 2.8 3.7 39.1 59.7 94.8 83.8 13.2 5.7 23.5 9.2 31.6 11.8 13.3 4.2 25.4 3.6 35 2.2 10.7-1.6 32.8-13.4 37.4-26.4 4.6-13 4.6-24.1 3.2-26.4-1.3-2.5-5-3.9-10.5-6.6z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M380.9 97.1C339 55.1 283.2 32 223.9 32c-122.4 0-222 99.6-222 222 0 39.1 10.2 77.3 29.6 111L0 480l117.7-30.9c32.4 17.7 68.9 27 106.1 27h.1c122.3 0 224.1-99.6 224.1-222 0-59.3-25.2-115-67.1-157zm-157 341.6c-33.2 0-65.7-8.9-94-25.7l-6.7-4-69.8 18.3L72 359.2l-4.4-7c-18.5-29.4-28.2-63.3-28.2-98.2 0-101.7 82.8-184.5 184.6-184.5 49.3 0 95.6 19.2 130.4 54.1 34.8 34.9 56.2 81.2 56.1 130.5 0 101.8-84.9 184.6-186.6 184.6zm101.2-138.2c-5.5-2.8-32.8-16.2-37.9-18-5.1-1.9-8.8-2.8-12.5 2.8-3.7 5.6-14.3 18-17.6 21.8-3.2 3.7-6.5 4.2-12 1.4-5.5-2.8-23.2-8.5-44.2-27.1-16.4-14.6-27.4-32.7-30.6-38.1-3.2-5.6-.3-8.6 2.5-11.4 2.5-2.5 5.5-6.5 8.3-9.7 2.8-3.2 3.7-5.5 5.5-9.2 1.9-3.7 1-6.9-.5-9.7-1.4-2.8-12.5-30.1-17.1-41.2-4.5-10.8-9.1-9.3-12.5-9.5-3.2-.2-6.9-.2-10.6-.2-3.7 0-9.7 1.4-14.8 6.9-5.1 5.6-19.4 19-19.4 46.3 0 27.3 19.9 53.7 22.6 57.4 2.8 3.7 39.1 59.7 94.8 83.8 13.2 5.7 23.5 9.2 31.6 11.8 13.3 4.2 25.4 3.6 35 2.2 10.7-1.6 32.8-13.4 37.4-26.4 4.6-13 4.6-24.1 3.2-26.4-1.3-2.5-5-3.9-10.5-6.6z'/%3E%3C/svg%3E");
}

.contact-socials a[href*="t.me"]::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M446.7 98.6l-67.6 318.8c-5.1 22.5-18.4 28.1-37.3 17.5l-103-75.9-49.7 47.8c-5.5 5.5-10.1 10.1-20.7 10.1l7.4-104.9 190.9-172.5c8.3-7.4-1.8-11.5-12.9-4.1L117.8 284 16.2 252.2c-22.1-6.9-22.5-22.1 4.6-32.7L418.2 66.4c18.4-6.9 34.5 4.1 28.5 32.2z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath d='M446.7 98.6l-67.6 318.8c-5.1 22.5-18.4 28.1-37.3 17.5l-103-75.9-49.7 47.8c-5.5 5.5-10.1 10.1-20.7 10.1l7.4-104.9 190.9-172.5c8.3-7.4-1.8-11.5-12.9-4.1L117.8 284 16.2 252.2c-22.1-6.9-22.5-22.1 4.6-32.7L418.2 66.4c18.4-6.9 34.5 4.1 28.5 32.2z'/%3E%3C/svg%3E");
}

/* ФИКСЫ СТРАНИЦЫ КОНТАКТОВ НА МОБИЛЬНЫХ */
@media (max-width: 768px) {
  .page-module__f6hyja__infoCard,
  .page-module__f6hyja__formCard {
    padding: 24px 16px !important; /* Еще чуть меньше отступы */
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-module__f6hyja__infoCard h2,
  .page-module__f6hyja__formCard h2 {
    font-size: 1.5rem !important; /* Уменьшаем заголовки */
    margin-bottom: 24px !important;
  }

  .page-module__f6hyja__grid {
    gap: 16px !important;
  }

  .page-module__f6hyja__title {
    font-size: 2.2rem !important;
  }

  .page-module__f6hyja__subtitle {
    font-size: 1.1rem !important;
  }

  /* Исправление формы в контактах */
  .page-module__f6hyja__form {
    width: 100% !important;
  }
  
  .page-module__f6hyja__input,
  .page-module__f6hyja__textarea {
    width: 100% !important;
    box-sizing: border-box !important;
    font-size: 16px !important; /* Предотвращаем зум на iOS */
  }
}

/* Глобальные фиксы мобильной адаптивности */
@media (max-width: 991px) {
  .home-hero-v2 {
    padding: 140px 0 80px;
    background-attachment: scroll;
    min-height: 60vh;
  }
  
  .home-hero-v2 .page-module___8aEwW__heroTitle {
    font-size: 2rem;
  }

  .hero-features-v2 {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-bottom: 30px;
  }

  .home-hero-v2 .page-module___8aEwW__heroActions {
    flex-direction: column;
    align-items: center;
    width: 100%;
  }
  
  .home-hero-v2 .btn-primary,
  .home-hero-v2 .btn-outline {
    width: 100%;
    max-width: 320px;
    min-width: unset;
  }
}

/* Фиксы для шапки на мобильных */
@media (max-width: 480px) {
  .Header-module__hBw1pG__logo {
    font-size: 1rem !important; /* Еще чуть меньше */
  }
  
  .Header-module__hBw1pG__logo span {
    display: inline !important;
  }
}

@media (max-width: 360px) {
  /* Экстремально маленькие экраны */
  .Header-module__hBw1pG__logo {
    font-size: 0.9rem !important;
  }
  
  .contact-socials .btn-outline {
    min-width: 100%; /* На совсем узких — по одной кнопке в ряд */
  }
}

/* СЛАЙДЕР В КАРТОЧКАХ АВТОПАРКА И НА СТРАНИЦАХ МАШИН */
.ImageSlider-module__UkK7rG__slider {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 4px;
  background: #1a1a1a;
}

/* Ограничиваем пропорции только для карточек каталога */
.page-module__7udarW__carCard .ImageSlider-module__UkK7rG__slider {
  aspect-ratio: 16 / 10;
}

.ImageSlider-module__UkK7rG__imageContainer {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.ImageSlider-module__UkK7rG__image {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover !important; /* Гарантируем отсутствие растягивания */
}

/* Навигация (точки) */
.ImageSlider-module__UkK7rG__dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 10;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* Показываем точки при наведении */
.page-module__7udarW__carCard:hover .ImageSlider-module__UkK7rG__dots,
.ImageSlider-module__UkK7rG__slider:hover .ImageSlider-module__UkK7rG__dots {
  opacity: 1;
}

.ImageSlider-module__UkK7rG__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: all 0.3s ease;
  display: block; /* Вместо span в некоторых местах */
}

.ImageSlider-module__UkK7rG__dot:hover {
  background: rgba(255, 255, 255, 0.8);
}

.ImageSlider-module__UkK7rG__activeDot {
  background: #ffffff !important;
  transform: scale(1.2);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

/* Навигационные стрелки (Стандарт v-class) */
.ImageSlider-module__UkK7rG__navBtn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  background-color: rgba(0, 0, 0, 0.4);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 20;
  opacity: 0;
  transition: all 0.3s ease;
  display: flex !important;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.ImageSlider-module__UkK7rG__slider:hover .ImageSlider-module__UkK7rG__navBtn,
.page-module__7udarW__carCard:hover .ImageSlider-module__UkK7rG__navBtn {
  opacity: 1;
}

.ImageSlider-module__UkK7rG__prevBtn { left: 10px; }
.ImageSlider-module__UkK7rG__nextBtn { right: 10px; }

.ImageSlider-module__UkK7rG__navBtn:hover {
  background-color: rgba(212, 175, 55, 0.8); /* Золотой */
  color: #fff;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
  .ImageSlider-module__UkK7rG__dots,
  .ImageSlider-module__UkK7rG__navBtn {
    opacity: 1; /* Всегда видны на мобильных */
    height: 32px;
  }
}

@media (max-width: 768px) {
  .Header-module__hBw1pG__phone {
    display: none !important;
  }
}

/* --- ФИНАЛЬНАЯ ПОЛИРОВКА ШАПКИ V2 --- */

.Header-module__hBw1pG__header {
  z-index: 1000 !important;
  background: transparent !important; /* Полная прозрачность */
  backdrop-filter: none !important; /* Убираем блюр, раз пользователь хочет как было */
  border-bottom: none !important; /* Убираем полоску */
  transition: background 0.3s ease;
  position: fixed !important; /* Чтобы она всегда была наверху экрана при прокрутке */
  width: 100%;
  top: 0;
}

.Header-module__hBw1pG__headerContainer {
  display: flex !important;
  align-items: center;
  height: 90px;
  justify-content: flex-start !important; /* Группируем элементы */
  gap: 0 !important;
}

.header-logo-img {
  height: 60px;
  width: auto;
  display: block;
}

.header-logo-link {
  display: flex !important;
  margin-right: 25px;
}

.Header-module__hBw1pG__logo {
  font-size: 1.6rem !important;
  font-weight: 600 !important;
  letter-spacing: 1px !important;
  color: #fff !important;
  text-decoration: none;
  white-space: nowrap;
  margin-right: 80px !important; /* Отступ от названия до меню */
}

/* МЕНЮ БЛИЖЕ К ЦЕНТРУ */
.Header-module__hBw1pG__nav {
  display: flex !important;
  gap: 30px;
  margin-left: auto !important;
  margin-right: auto !important; /* Центрируем меню между названием и телефоном */
}

.Header-module__hBw1pG__actions {
  display: flex !important;
  margin-left: 0 !important;
}

.Header-module__hBw1pG__phone {
  white-space: nowrap;
}

/* БУРГЕР */
.mobile-menu-btn {
  display: none;
  width: 40px;
  height: 40px;
  background: transparent !important;
  border: none !important;
  position: relative;
  z-index: 2000;
}

.mobile-menu-btn span {
  display: block;
  width: 28px;
  height: 2px;
  background: #fff !important;
  position: absolute;
  left: 6px;
  transition: 0.3s ease-in-out;
}

.mobile-menu-btn span:nth-child(1) { top: 14px; }
.mobile-menu-btn span:nth-child(2) { top: 21px; }
.mobile-menu-btn span:nth-child(3) { top: 28px; }

/* АНИМАЦИЯ X */
.mobile-menu-btn.active span:nth-child(1) {
  top: 21px;
  transform: rotate(45deg);
}
.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
  transform: translateX(-10px);
}
.mobile-menu-btn.active span:nth-child(3) {
  top: 21px;
  transform: rotate(-45deg);
}

/* МОБИЛЬНАЯ ВЕРСИЯ */
@media (max-width: 1024px) {
  .Header-module__hBw1pG__headerContainer {
    display: grid !important;
    grid-template-columns: 1fr 2fr 1fr; /* Больше места под название */
    height: 80px;
    align-items: center !important; /* ВЫРАВНИВАНИЕ ПО ВЕРТИКАЛИ */
  }

  .header-logo-link {
    justify-content: flex-start;
    margin: 0;
  }

  .Header-module__hBw1pG__logo {
    justify-content: center !important;
    display: flex !important;
    align-items: center !important;
    width: 100%;
    margin: 0 !important;
    font-size: 1.2rem !important;
    text-align: center;
  }

  .Header-module__hBw1pG__nav, 
  .Header-module__hBw1pG__actions {
    display: none !important;
  }

  .mobile-menu-btn {
    display: flex !important;
    justify-content: center;
    align-items: center;
    margin-left: auto;
  }

  .header-logo-img {
    height: 45px;
  }
}

@media (max-width: 480px) {
  .Header-module__hBw1pG__logo {
    font-size: 1rem !important;
  }
}

/* Исправление X в мобильном меню */
.mobile-nav {
  z-index: 1500 !important;
}
