/* Modern refresh (non-destructive): typography, spacing, cards, buttons, hero */
/* Variant: "auto-sport" — контрастный, динамичный, с акцентами красного */

:root {
  --radius-sm: 0.8rem;
  --radius-md: 1.2rem;
  --radius-lg: 1.6rem;
  --shadow-1: 0 0.6rem 2.2rem rgba(20, 24, 29, 0.08);
  --shadow-2: 0 1.2rem 3.2rem rgba(20, 24, 29, 0.12);
  --border-soft: rgba(20, 24, 29, 0.08);
  --bg-soft: #f3f4f6;
  --accent-red: #ff1236;
  --accent-red-dark: #c90022;
  --accent-orange: #ff6a00;
  --bg: #111;
  --card: #1c1c1c;
  --item: #222;
  --border: #2e2e2e;
  --accent: #FF4D00;
  --text: #f0ede8;
  --muted: #666;
  --gold: #FFB547;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Manrope, Gilroy, system-ui, -apple-system, "Segoe UI", Roboto,
    Arial, sans-serif;
  line-height: 1.55;
  background: var(--bg-soft);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Container: keep existing paddings, add max width + centering */
.container,
.article-content,
.page--promo__container {
  /* max-width: 132rem; */
  width: 100%;
  margin-right: auto;
  margin-left: auto;
}

/* Headings: a bit tighter + cleaner */
.h1,
h1,
.h2,
h2 {
  letter-spacing: -0.02em;
}

/* Buttons: спорт-акцент, лёгкий градиент и объём */
.btn {
  border-radius: var(--radius-md);
  background-image: linear-gradient(
    90deg,
    var(--accent-red) 0%,
    var(--accent-orange) 100%
  );
  box-shadow: 0 0.3rem 1.2rem rgba(235, 0, 40, 0.18);
  transition: transform 0.18s ease, box-shadow 0.18s ease,
    background-color 0.18s ease, opacity 0.18s ease;
}

@media (hover: hover) and (pointer: fine) {
  .btn:hover {
    background-image: linear-gradient(
      90deg,
      #ff3350 0%,
      #ff7a1a 100%
    );
    box-shadow: 0 0.8rem 2.4rem rgba(235, 0, 40, 0.22);
    opacity: 1;
    transform: translateY(-1px);
  }
}

.btn:active {
  transform: translateY(0);
  box-shadow: 0 0.4rem 1.6rem rgba(235, 0, 40, 0.18);
}

/* Hero: more спортивный, контрастный фон вокруг авто */
.hero {
  position: relative;
  /* Убираем overflow: hidden чтобы поиск не обрезался */
  overflow: visible;
  display: flex;
  align-items: center;
  min-height: 600px;
}
/* Красная полоса с градиентом на стыке блока и картинки */
.hero__diagonal-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #ff122a 0%, #830b18 80%, #63010b4d 10%);
  clip-path: polygon(65% 0, calc(65% + 8px) 0, calc(50% + 2px) 100%, 50% 100%);
  z-index: 2;
  pointer-events: none;
  filter: drop-shadow(0 0 8px rgba(255, 18, 42, 0.6));
}
.hero__inner {
  padding-top: 5.5rem;
  padding-bottom: 4.5rem;
  background-size: 38%;
}

@media (min-width: 48rem) {
  .hero__inner {
    padding-top: 7.5rem;
    padding-bottom: 6.5rem;
    background-size: 42%;
    background-position: 92% 60%;
  }
}

.hero__title {
  text-wrap: balance;
  font-weight: 700;
}

.hero__desc {
  opacity: 0.92;
}

@media (min-width: 48rem) {
  .hero__title::after {
    content: "";
    display: block;
    width: 7.2rem;
    height: 0.32rem;
    margin-top: 1.8rem;
    border-radius: 999px;
    background-image: linear-gradient(
      90deg,
      var(--accent-red) 0%,
      var(--accent-orange) 100%
    );
  }
}

.page--home__hero {
  position: relative;
  overflow: hidden;
}

.page--home__hero::after {
  content: "";
  position: absolute;
  left: -10%;
  right: 35%;
  bottom: -5.5rem;
  height: 6rem;
  background: linear-gradient(
    120deg,
    rgba(255, 18, 54, 0.9) 0%,
    rgba(255, 18, 54, 0) 70%
  );
  opacity: 0.9;
  pointer-events: none;
  z-index: 2;
}

@media (max-width: 47.98rem) {
  .page--home__hero::after {
    left: -20%;
    right: 10%;
    bottom: -4.5rem;
    height: 4.5rem;
  }
}

/* Search: softer radius + shadow */
.main-search__form {
  height: 5.6rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
  overflow: hidden;
}

.main-search__input {
  border-radius: 0;
}

.main-search button {
  border-radius: 0;
}

.main-search__result {
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  box-shadow: var(--shadow-2);
  backdrop-filter: blur(6px);
}

/* Section subtitles: cleaner spacing */
.page--home__subtitle {
  padding: 3.5rem 0 2.5rem;
}

@media (min-width: 48rem) {
  .page--home__subtitle {
    padding: 7rem 0 3.5rem;
  }
}

/* Brands slider: turn logos into cards */
.home-slider-brands .swiper-slide a {
  display: grid;
  place-content: center;
  height: 7.6rem;
  width: 12rem;
  background: var(--color-white);
  border: 0.1rem solid var(--border-soft);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-1);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

@media (hover: hover) and (pointer: fine) {
  .home-slider-brands .swiper-slide a:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-2);
    opacity: 1;
  }
}

/* Service cards: lighter borders + modern shadow */
.service-card__box {
  border-radius: var(--radius-md);
  border: 0.1rem solid var(--border-soft);
  box-shadow: var(--shadow-1);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

@media (hover: hover) and (pointer: fine) {
  .service-card:hover .service-card__box {
    box-shadow: var(--shadow-2);
    transform: translateY(-2px);
  }
}

.service-card__name strong {
  color: rgba(116, 135, 134, 0.9);
}

/* Promo cards */
.promo-item {
  border-radius: var(--radius-md);
  border: 0.1rem solid var(--border-soft);
  box-shadow: var(--shadow-1);
}

@media (hover: hover) and (pointer: fine) {
  .promo-item:hover {
    box-shadow: var(--shadow-2);
    transform: translateY(-2px);
    opacity: 1;
  }
}

.promo-item__image {
  border-bottom: 0.1rem solid rgba(255, 255, 255, 0.06);
}

/* Review cards */
.review-card {
  border-radius: var(--radius-md);
  border: 0.1rem solid var(--border-soft);
  box-shadow: var(--shadow-1);
}

/* Gallery cards (added earlier) */
.home-gallery__item {
  border-radius: var(--radius-md);
  border: 0.1rem solid var(--border-soft);
  box-shadow: var(--shadow-1);
}

/* Small polish: reduce global link fade for UI elements */
@media (min-width: 62rem) {
  .promo-item:hover,
  .service-card__link:hover,
  .home-slider-brands .swiper-slide a:hover {
    opacity: 1 !important;
  }
}


/* Общий стиль блоков отзывов */
.page--home__reviews {
  background-color: #f4f4f4; /* светлый фон для отделения */
  padding: 2rem;
  border-radius: 1rem;
  font-family: 'Montserrat', sans-serif;
}

/* Заголовки и разделители */
.reviews-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}
.reviews-header h2 {
  font-size: 2rem;
  font-weight: 700;
  color: #222;
}
.reviews-place__logo {
  width: 50px;
  height: 50px;
  margin-right: 15px;
}
.reviews-place__logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.reviews-place__title {
  font-size: 1.3rem;
  font-weight: 600;
  color: #333;
}

/* Стиль оценки */
.reviews-rating {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.reviews-rating__total {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.reviews-rating__grade {
  font-size: 2.5rem;
  font-weight: 700;
  color: #ffb400; /* яркий цвет оценки (можно поменять) */
}
.reviews-rating__stars {
  display: flex;
}
.reviews-rating__cap {
  font-size: 0.9rem;
  color: #555;
}
.reviews-rating__action-title {
  font-size: 1rem;
  font-weight: 600;
}
.reviews-rating__action-starts {
  margin-top: 0.5rem;
}

/* Отзывы — карточки */
.review-card {
  background: #fff;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  padding: 20px;
  margin-bottom: 20px;
  transition: transform 0.3s, box-shadow 0.3s;
}
.review-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

/* Логотип и имя */
.review-card__header {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}
.review-card__logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.review-card__title {
  flex: 1;
}
.review-card__name {
  font-weight: 600;
  font-size: 1.8rem;
  color: #222;
}
.review-card__date {
  font-size: 1.5rem;
  color: #999;
}
.review-card__stars-desktop {
  margin-left: auto;
  display: none; /* скрыть на мобильных, показать на десктопе */
}
@media(max-width: 768px) {
  /* Мобильный стиль */
  .reviews-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .review-card__stars-desktop {
    display: none;
  }
  .review-card__stars-mobile {
    display: block;
  }
}

/* Стиль отзывов (текста) */
.review-card__content {
  font-size: 1.5rem;
  line-height: 1.5;
  color: #7b7b7b;
}
.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  min-height: 600px;
}
/* Контейнер для фото на заднем плане */
.hero__image-layer {
  position: absolute;
  top: 0;
  right: 0;
  width: 50%;
  height: 100%;
  background-image: url('../img/pics/backgrounds/team.jpg');
  background-size: cover;
  background-position: center right;
  z-index: 1;
}
.hero__content-layer {
  position: relative;
  width: 100%;
  height: 100%;
}
.hero__inner {
  min-height: 600px;
  padding-top: 5.5rem;
  padding-bottom: 4.5rem;
  position: relative;
  z-index: 4; /* Выше чем полоса и картинка */
}
@media (max-width: 1100px) {
  .hero__image-layer {
    display: none;
  }
  .hero__content-layer {
    clip-path: none;
  }
  .hero__back-cut {
    clip-path: none !important;
  }
  .hero__content-layer::after {
    display: none;
  }
}
/* Поиск - выходит за пределы темного блока */
.main-search {
  position: relative;
  width: 140%; /* Выходит на 40% за пределы контейнера */
  max-width: 800px;
  z-index: 10; /* Поверх всего */
  clip-path: none;
}

.main-search__form {
  display: flex;
  height: 5.6rem;
  border-radius: var(--radius-md);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.main-search__input {
  flex: 1;
  border: none;
  padding: 0 2rem;
  font-size: 1.6rem;
  outline: none;
  background: #fff;
}

.main-search button {
  width: 5.6rem;
  border: none;
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.main-search button:hover {
  background: #f5f5f5;
}

.main-search button svg {
  width: 2rem;
  height: 2rem;
  fill: #e31e24;
}

.main-search__result {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(6px);
  max-height: 300px;
  overflow-y: auto;
  margin-top: 0.5rem;
  z-index: 100;
}

/* Адаптивность */
@media (max-width: 1100px) {
  .hero {
    overflow: hidden; /* Возвращаем для мобильных */
  }
  
  .hero__diagonal-line {
    display: none;
  }
  
  .hero__image-layer {
    display: none;
  }
  
  .hero__content-layer {
    clip-path: none;
  }
  
  .main-search {
    width: 100%;
    max-width: 100%;
  }
}

@media (min-width: 48rem) {
  .hero__inner {
    padding-top: 7.5rem;
    padding-bottom: 6.5rem;
  }
}
.hero__back-cut {
  width: 100%;
  height: 100%;
  background: radial-gradient(
      1100px 420px at 15% 25%,
      rgba(255, 18, 54, 0.24),
      rgba(255, 18, 54, 0) 60%
    ),
    linear-gradient(100deg, #070708 0%, #1b1a1b 40%, #262427 100%);
  clip-path: polygon(0 0, 65% 0, 50% 100%, 0% 100%);
  position: absolute;
  z-index: 2;
}

