/* Redwd Styles */

@font-face {
    font-family: 'TT Hoves';
    src: local('TT Hoves Regular'), local('TT-Hoves-Regular'),
        url('../fonts/TTHoves-Regular.woff2') format('woff2'),
        url('../fonts/TTHoves-Regular.woff') format('woff'),
        url('../fonts/TTHoves-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
  }

  @font-face {
    font-family: 'TT Hoves';
    src: local('TT Hoves Medium'), local('TT-Hoves-Medium'),
        url('../fonts/TTHoves-Medium.woff2') format('woff2'),
        url('../fonts/TTHoves-Medium.woff') format('woff'),
        url('../fonts/TTHoves-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
  }

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'TT Hoves', sans-serif;
  color: #333333;
  background-color: #ffffff;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* HEADER */
.header {
  padding: 24px 0;
}

header {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 10;
  background: transparent; /* или убрать background-color вовсе */
}

.header__container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.header__logo {
  font-size: 24px;
  font-weight: bold;
  color: #8b0000;
}

.header__nav {
  flex: 1;
  display: flex;
  justify-content: center;
}

.header__menu {
  list-style: none;
  display: flex;
  gap: 40px;
}

.header__menu li a {
  font-size: 16px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.header__menu li a:hover {
  color: #8b0000;
}

.header__btn {
  padding: 16px 24px;
  background-color: #ffffff;
  color: #DD0400;
  border-radius: 30px;
  font-size: 16px;
  transition: background 0.3s ease;
}

.header__btn:hover {
  background-color: #a30000;
  color: #ffffff;
}

.burger {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: #1e1e1e;
}

/* Мобильный вид */
@media (max-width: 768px) {
  .burger {
    display: flex;
  }

  .header__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    z-index: 10;
    padding: 20px;
  }

  .header__nav.open {
    display: block;
  }

  .header__menu {
    flex-direction: column;
    gap: 16px;
  }

  .header__btn {
    display: none;
  }

  .header__container {
    padding: 0 16px;
  }

  .header__logo {
    flex: 1;
  }

  .burger {
    margin-left: auto;
  }

  .header__btn {
    display: none;
  }

}

/* HERO */
.hero {
  position: relative;
  padding: 180px 0 196px 0;
  text-align: center;
  background-image:
    url('../images/bottom_left.png'),
    url('../images/bottom_left_shadow.png'),
    url('../images/top_right.png'),
    linear-gradient(49.48deg, #F5F5F5 16.62%, #FFDFDF 73.9%);
    
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat;
  background-size: auto, auto, auto, cover;
  background-position: bottom left, bottom left, top right, center;
}

.hero__title {
  font-family: 'TT Hoves';
  font-weight: 500;
  font-size: 56px;
  color: #333;
  margin-bottom: 20px;
  line-height: 1.2;
}

.hero__text {
  font-family: 'TT Hoves';
  font-weight: 400;
  font-size: 30px;
  margin-bottom: 40px;
  color: #33333373;
}

.hero__cta {
  display: inline-block;
  width: 304px;
  height: 56px;
  padding: 14px 36px;
  background-color: #DD0400;
  color: #fff;
  border-radius: 30px;
  font-size: 16px;
  transition: background 0.3s ease;
  font-family: TT Hoves;
  font-weight: 500;
  font-style: Medium;
  line-height: 28px;
  letter-spacing: -1%;
}

.hero__cta:hover {
  background-color: #a30000;
}

.hero__link {
  display: block;
  font-size: 14px;
  text-decoration: underline;
  margin-top: 16px;
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .hero__title {
    font-size: 36px;
  }

  .hero__text {
    font-size: 18px;
  }
}

@media (max-width: 440px) {

  .hero__container {
    padding-bottom: 50px;
  }

  .hero {
    padding: 60px 20px;
  }

  .hero__title {
    padding-top: 100px;
    font-size: 36px;
  }

  .hero__text {
    font-size: 16px;
  }

  .hero__cta {
    font-size: 14px;
    padding: 12px 24px;
  }
}

/* FEATURES  */

.features {
  margin-top: -60px;
  padding: 80px 0 0 0;
  background-color: #ffffff;
  border-top-left-radius: 80px;
  border-top-right-radius: 80px;
  z-index: 2;
  position: relative;
}

.features__container {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  justify-content: space-between;
  border-bottom: 1px solid #e5e5e5;
  padding-bottom: 80px;
}

.feature-card {
  flex: 1;
  min-width: 280px;
  max-width: 32%; /* 3 в ряд + gap */
  height: 290px;
  position: relative;
  background-color: #f4f6f8;
  border-radius: 20px;
  padding: 24px;
  overflow: hidden;
}

.feature-card__icon {
  position: relative;
  /*position: absolute;*/
  float: right;
  height: auto;
  z-index: 1;
}

.feature-card__icon img {
  width: 140px;
}

.feature-card__text {
  position: relative;
  /*position: absolute;*/
  z-index: 2;
  font-size: 24px;
  line-height: 1.4;
  font-family: 'TT Hoves', sans-serif;
  padding-top: 170px; 
}

.feature-card__text.first-container {
  padding-top: 130px; 
}

@media (max-width: 768px) {
  .features__container {
    flex-direction: column;
    gap: 20px;
  }

  .feature-card {
    flex-direction: row;
  }

  .feature-card__text {
    max-width: 100%;
  }
}

@media (max-width: 440px) {
  .feature-card {
    flex-direction: column;
    text-align: center;
    align-items: center;
    max-width: 100%;
  }

  .feature-card__content {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    width: 100%;
  }

  .feature-card__icon img {
    width: 85px;
    margin-top: 12px;
  }

  .feature-card__text.first-container {
      padding: 10px 0 10px 10px;
  }

  .feature-card__text {
      padding: 10px;
  }

  .feature-card__text > p {
    font-size: 22px;
    text-align: left;
  }
}

/* SERVICES */

.services {
  padding: 80px 0;
  background-color: #fff;
  border-bottom: none;
}

.services .container {
  border-bottom: 1px solid #e5e5e5;
  padding-bottom: 80px;
}

.services__title {
  font-size: 52px;
  font-weight: normal;
  margin-bottom: 40px;
  color: #1e1e1e;
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.service-card {
  background-color: #f4f6f8;
  border-radius: 20px;
  padding: 32px 20px;
  text-align: left;
  transition: transform 0.3s ease;
}

.service-card:hover {
  transform: translateY(-4px);
}

.service-card img {
  max-width: 100%;
  width: 100%;
  height: auto;
  margin-bottom: 16px;
  border-radius: 20px;
}

.service-card p {
  font-size: 36px;
  color: #333333;
}

/* Адаптив */

@media (max-width: 600px) {

  .services__grid {
    max-width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px; /* лучше использовать gap вместо паддинга */
  }

  .services__title {
    text-align: center;
  }

  .service-card p {
    font-size: 16px;
    color: #333333;
  }
}

@media (max-width: 728px) {

  .service-card p {
    font-size: 16px;
    color: #333333;
  }
}

/* WORKFLOW */

.workflow {
  padding: 0 0 80px 0;
  background-color: #fff;
}

.workflow__row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  border-bottom: 1px solid #e5e5e5;
  padding-bottom: 80px;
}

.workflow__item {
  background-color: #f4f6f8;
  border-radius: 24px;
  padding: 32px;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  aspect-ratio: 1 / 1;
}

.workflow__item--title {
  background: none;
  padding: 0;
  border-radius: 0;
  display: flex;
  align-items: center;
  font-size: 20px;
  font-weight: 500;
  color: #1e1e1e;
  aspect-ratio: auto;
  font-size: 36px;
  text-align: left;
}

.workflow__item.workflow__item--title > p {
  font-size: 34px;
}

.workflow__step {
  width: 80px;
  height: 80px;
  background-color: #fff;
  color: #DD0400;
  font-weight: bold;
  font-size: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  clip-path: polygon(
    50% 0%, 100% 25%, 100% 75%,
    50% 100%, 0% 75%, 0% 25%
  );
  border-radius: 6px; /* псевдо-скругление */
  transition: all 0.3s ease;
}

.workflow__item p {
  font-size: 24px;
  font-weight: 400;
  color: #333333;
  line-height: 1.1;
}

.workflow__item p > span {
  font-weight: 500;
}


/* Адаптив */
@media (max-width: 992px) {
  .workflow__row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .workflow__row {
    grid-template-columns: 1fr;
  }

  .workflow__item--title {
    font-size: 18px;
    justify-content: center;
    text-align: center;
    margin-bottom: 12px;
  }

  .workflow__item {
    aspect-ratio: auto;
  }
}

/* PARTNERS */

.partners {
  padding: 0 0 80px 0;
  background-color: #fff;
}

.partners > .container {
  padding-bottom: 80px;
  border-bottom: 1px solid #e5e5e5;
}

.partners__title {
  font-size: 52px;
  font-weight: normal;
  margin-bottom: 40px;
  color: #333333;
}

.partners__slider {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 10px;
}

.partner-card {
  flex: 0 0 auto;
  width: 200px;
  height: 100px;
  background-color: #F2F4F7;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  scroll-snap-align: start;
  transition: background 0.3s;
}

.partner-card img {
  max-width: 80%;
  max-height: 60%;
  filter: grayscale(100%);
  transition: filter 0.3s ease;
}

.partner-card:hover img {
  filter: none;
}

/* Scrollbar hide on mobile */
.partners__slider::-webkit-scrollbar {
  display: none;
}

.partners__slider {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}

/* Удаляем flex-wrap и overflow-x: hidden на десктопе */
@media (min-width: 992px) {
  .partners__slider {
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .partner-card {
    width: calc((100% - 72px) / 4);
    aspect-ratio: 2 / 1;
  }
}

/* CONTACT FORM */

.contact-form {
  background: #ffffff;
  padding: 0 0 80px 0;
  position: relative;
}

.contact-form__wrap {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  align-items: stretch; 
}

.contact-form__text {
  flex: 1;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  justify-content: space-between; /* ← вместо маржинов */
}

.contact-form__text h2 {
  color: #1e1e1e;
  margin-bottom: 16px;
  align-items: flex-start;
  font-family: TT Hoves;
  font-weight: 400;
  font-style: Regular;
  font-size: 36px;
  line-height: 40px;
  letter-spacing: -1%;
}

.contact-form__text p {
  color: #7a7a7a;
  align-items: flex-end;
  font-family: TT Hoves;
  font-weight: 400;
  font-style: Regular;
  font-size: 20px;
  leading-trim: NONE;
  line-height: 120%;
  letter-spacing: -1%;
  vertical-align: bottom;
  max-width: 380px;
}

.contact-form__fields {
  flex: 1;
  min-width: 300px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* стандартное поведение */
  gap: 16px;
}

.contact-form__fields input {
  padding: 16px;
  border-radius: 40px;
  border: none;
  background: #f0f2f5;
  font-size: 16px;
}

.contact-form__fields button {
  padding: 16px;
  border-radius: 40px;
  background: red;
  color: #fff;
  font-weight: bold;
  border: none;
  cursor: pointer;
  font-size: 16px;
}

.contact-form__fields .checkbox {
  display: flex;
  align-items: center;
  font-size: 14px;
  color: #5a5a5a;
  gap: 8px;
}

.contacts {
  background: #ffecec;
  /*background: linear-gradient(to bottom, #fff, #ffecec);
  background: linear-gradient(49.48deg, #F5F5F5 16.62%, #FFDFDF 73.9%);*/
  padding: 120px 0 40px 0;
  position: relative;
  z-index: 1;
}

.contacts__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
}

.contact-card {
  background: #fff;
  border-radius: 40px;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  font-size: 26px;
  font-weight: 400;
}

.contact-card img {
  width: auto;
  height: 48px;
  margin-bottom: 40px;
}

/* Адаптив */
@media (max-width: 768px) {
  .contact-form__wrap {
    flex-direction: column;
  }

  .contacts__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px; 
  }

  .contact-card {
    font-size: 15px;
    padding: 24px 16px;
  }

  .contact-card img {
    width: auto;
    height: 40px;
    margin-bottom: 20px;
  }
}

/* YMAP */

.ymap {
  background: #ffffff;
  border-bottom-left-radius: 60px;
  border-bottom-right-radius: 60px;
  padding: 0 0 80px 0;
  position: relative;
  z-index: 2;
  margin-bottom: -60px;
}

.ymap__wrap {
  display: flex;
  gap: 30px;
  flex-direction: column;
}

.ymap__title {
  font-size: 52px;
  font-weight: normal;
  margin-bottom: 0;
  color: #333333;
}

/* FOOTER */
.footer {
  background: #ffecec;
  padding: 24px 0;
  border-top: 1px solid #ddd;
  position: relative;
}

.footer__content {
  position: relative; /* добавь это */
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  font-size: 14px;
}

/*.footer__links {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}*/

.footer__links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
  margin: 0 auto; /* центрируем на десктопе */
}


.footer__links a {
  color: #333;
  text-decoration: none;
}

.scroll-top {
  position: absolute;
  right: 16px;
  bottom: -16px;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: none;
  background: #fff;
  font-size: 18px;
  cursor: pointer;
  box-shadow: 0 0 4px rgba(0,0,0,0.1);
}


/* Адаптив */
@media (max-width: 768px) {
  .footer__content {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    text-align: left;
    position: relative;
  }

  .footer__links {
    order: -1;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    margin: 0; /* убираем авто-центрирование */
    gap:10px;
  }

  .footer__links a {
    display: block;
  }

  .footer__left {
    align-self: flex-start;
  }

  .scroll-top {
    position: absolute;
    right: 16px;
    bottom: 16px;
    margin: 0;
  }
}

/* Модальное окно */
.modal {
    display: none; /* Скрыто по умолчанию */
    position: fixed; /* Фиксированное позиционирование */
    z-index: 1000; /* Поверх всего */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto; /* Включить прокрутку, если содержимое слишком велико */
    background-color: rgba(0, 0, 0, 0.5); /* Полупрозрачный фон */
    display: flex; /* Для центрирования контента */
    justify-content: center; /* Центрирование по горизонтали */
    align-items: center; /* Центрирование по вертикали */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

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

.modal__overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    cursor: pointer; /* Делаем оверлей кликабельным для закрытия */
}

.modal__content {
    background-color: #fff;
    padding: 40px; /* Увеличил паддинг для лучшего вида */
    border-radius: 10px;
    position: relative;
    max-width: 450px; /* Ограничить ширину */
    width: 90%; /* Адаптивная ширина */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    transform: translateY(20px); /* Начальное смещение для анимации */
    transition: transform 0.3s ease, opacity 0.3s ease;
    z-index: 1001; /* Выше оверлея */
}

.modal.active .modal__content {
    transform: translateY(0); /* Возвращаем на место при активности */
}

.modal__close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
    padding: 0;
}

.modal__close:hover,
.modal__close:focus {
    color: #333;
    text-decoration: none;
}

.modal__header {
    text-align: center;
    margin-bottom: 30px;
}

.modal__header h3 {
    font-size: 28px;
    color: #333;
    margin-bottom: 10px;
}

.modal__header p {
    font-size: 16px;
    color: #666;
}

/* Стили для полей формы внутри модального окна (переопределяем или используем существующие) */
.modal__form input[type="tel"],
.modal__form input[type="text"] {
    width: 100%;
    padding: 15px 20px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    box-sizing: border-box; /* Важно для корректной ширины */
}

.modal__form button[type="submit"] {
    width: 100%;
    padding: 15px 20px;
    background-color: #e04b2b; /* Цвет вашей кнопки */
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.modal__form button[type="submit"]:hover {
    background-color: #c93a20; /* Темнее при наведении */
}

.modal__form .checkbox {
    display: flex;
    align-items: center;
    margin-top: 20px;
    font-size: 14px;
    color: #666;
}

.modal__form .checkbox input[type="checkbox"] {
    margin-right: 10px;
    transform: scale(1.2); /* Увеличить размер чекбокса */
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .modal__content {
        padding: 30px 20px;
        max-width: 90%;
    }
    .modal__header h3 {
        font-size: 24px;
    }
    .modal__header p {
        font-size: 14px;
    }
}

