/* Основные стили */
.tab-content-new {
  padding: 4.1875rem 7.5rem 13rem;
}

.tab-content-new__factors-wrapper {
  margin-top: 1.5rem;
}

.tab-content__factors-new {
  margin: 0;
  padding: 0;
  list-style-type: none;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6%;
}

.tab-content__factor-new {
  width: 30%;
  min-height: 8.75rem;
}

.tab-content-new__text-wrapper {
  min-height: 17rem;
}

/* Навигация вкладок */
.tab-new__nav {
  display: flex;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  z-index: 2;
}

/* Кнопки вкладок - базовые стили */
.tab-new__btn {
  /* Заменяем width на flex-basis для гибкости */
  flex: 0 1 clamp(5rem, 10.4vw, 10.4rem);
  height: clamp(5rem, 10.4vw, 10.4rem);
  min-width: 0; /* Разрешаем сжатие */
  border: 1px solid rgba(57, 51, 48, 0.2);
  background: none;
  position: relative;
  z-index: 1;
  color: #fff;
  font-weight: 400;
  font-size: clamp(0.7rem, 1vw, 1rem);
  line-height: clamp(1.2rem, 2vw, 2rem);
  padding: clamp(0.5rem, 1.25vw, 1.25rem) 0;
  display: flex;
  align-items: center;
  text-align: left;
  outline: none;
  transition: flex 1.25s ease; /* Анимируем flex */
  overflow: hidden;
  justify-content: center;
}

/* Текст кнопки (скрыт по умолчанию) */
.tab-new__btn-text {
  overflow: hidden;
  clip-path: inset(0 100% 0 0);
  transition: clip-path 0.25s ease;
  width: auto;
  max-width: 0;
  color: #393330;
  display: flex;
  max-height: 75px;
  white-space: pre;
}

.tab-new__nav:hover 
.tab-new__btn:not(:hover).active 
.tab-new__btn-text {
  clip-path: inset(0 100% 0 0);
  transition: clip-path 0.25s ease;
  max-width: 0;
  max-height: 75px;
}

.tab-new__btn.active .tab-new__btn-text,
.tab-new__btn:hover .tab-new__btn-text {
  clip-path: inset(0 0 0 0);
  transition: clip-path 1.25s ease, max-width 1.25s ease;
  max-width: 250px;
  max-height: 75px;
}

.tab-new__nav:hover 
.tab-new__btn:not(:hover).active {
  flex-grow: 0;
}

.tab-new__btn:hover {
  flex-grow: 3;
  flex-shrink: 0;
}

.tab-new__btn.active,
.tab-new__nav:hover .tab-new__btn:hover.active {
  flex-grow: 3;
  border: none;
  border-bottom: 0.5rem solid #f04923;
  flex-shrink: 0;
}

.tab-new__btn:hover .tab-new__btn-icon {
  flex-grow: 0;
  flex-shrink: 0;
}

/* Иконки кнопок */
.tab-new__btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex-shrink: 0;
}

.tab-new__btn-icon svg {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  min-width: 50px;
  min-height: 50px;
  object-fit: contain;
}

/* Контейнер описания */
.tab-description-new__text {
  min-height: calc(5 * 1.5em);
}

/* Нижний список */
.tabs-new__bottom-list {
  margin: 0;
  padding: 0;
  list-style: none;
  position: relative;
  z-index: 1;
  background-color: #E4E2E2;
}

.tabs-new__bottom-item {
  background-color: #E4E2E2;
}

/* Кнопки слайдера */
.tab-slider-buttons {
  display: flex;
  z-index: 1;
  margin-top: auto;
  margin-left: auto;
  align-self: flex-end;
}

/* Список действий */
.actions_new {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}

/* Анимация */
@keyframes clip {
  to {
    clip-path: polygon(0 0%, 100% 0, 100% 100%, 0% 100%);
  }
}

/* Адаптив для больших экранов */
@media (min-width: 1441px) {
  .tab-content-new {
    padding: 4.375rem 7.1875rem 13rem;
    max-width: 56.25rem;
  }
}

/* Адаптив для планшетов и ноутбуков */
@media (max-width: 1200px) {
  .tab-content-new {
    padding: 4rem 5rem 13rem;
  }
}

/* Адаптив для планшетов (990px и меньше) */
@media (max-width: 990px) {
  .tab-content__factor-new {
    width: 45%;
    min-height: 8.75rem;
  }

  .tab-content-new {
    padding: 3.4375rem 4rem 11rem;
  }
  
  .tab-new__btn {
    flex: unset;
    display: unset;
    width: clamp(8rem, 16.4vw, 16.4rem);
    height: clamp(8rem, 16.4vw, 16.4rem);
    padding: clamp(0.3rem, 0.8vw, 0.3rem) clamp(0.8rem, 2.5vw, 0.8rem);
  }
  
  .tab-new__btn-text {
    display: none !important;
  }
  
  .tab-slider-buttons {
    display: none !important;
  }
}

/* Адаптив для мобильных устройств */
@media (max-width: 640px) {
  .tab-new__btn {
    flex: unset;
    display: unset;
    width: clamp(8rem, 16.4vw, 16.4rem);
    height: clamp(5rem, 16.4vw, 16.4rem);
    padding: clamp(0.3rem, 0.8vw, 0.3rem) clamp(0.8rem, 2.5vw, 0.8rem);
  }

  .tab-content-new {
    padding: 2.75rem 1.875rem 4rem;
  }
  
  .tab-content-new__text-wrapper {
    min-height: 17rem;
  }
}

/* Адаптив для маленьких мобильных устройств */
@media (max-width: 375px) {

  .tab-content-new {
    padding: 2.75rem 1.875rem 4rem;
  }
}