* {
  box-sizing: border-box;
}

.seo-tariffs {
  font-family: 'Open Sans', sans-serif;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

/* Шапка */
.header-block {
  text-align: center;
  margin-bottom: 40px;
}
.header-block h2 {
  font-size: 32px;
  color: #333;
  margin: 0 0 10px;
}
.subtitle {
  font-size: 18px;
  color: #666;
}

/* 4 колонки тарифов (десктоп) */
.tariffs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
  margin-bottom: 40px;
  /* Чтобы карточки были одинаковой высоты */
  align-items: stretch;
}
.tariff-column {
  position: relative;
}
.tariff-card {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  /* Важно: высота 100% + растягивание родителя */
  height: 100%;
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.tariff-card:hover {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}
.highlighted .tariff-card {
  border: 2px solid #F8B69D;
}
.popular-badge {
  position: absolute;
  top: -10px;
  right: 10px;
  background: #F8B69D;
  color: #fff;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
}
.price {
  font-size: 24px;
  font-weight: bold;
  color: #333;
  margin: 15px 0 5px;
}
.price span {
  font-size: 14px;
  font-weight: normal;
  color: #666;
}

/* Карточки одинакового размера */
.tariff-card .description {
  flex-grow: 1;
}

/* Таблица сравнения тарифов (десктоп) */
.features-comparison {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 30px;
}
.comparison-header {
  display: grid;
  /* Выравниваем все 5 колонок поровну */
  grid-template-columns: repeat(5, 1fr);
  background: #f5f5f5;
  font-weight: bold;
}
.comparison-row {
  display: grid;
  /* То же самое для «тела» */
  grid-template-columns: repeat(5, 1fr);
  border-bottom: 1px solid #eee;
}
.section-title {
  background: #f9f9f9;
  font-weight: bold;
}
.feature-name,
.feature-value {
  padding: 12px 15px;
  border-right: 1px solid #eee;
  text-align: center; /* Если нужно, чтобы все ячейки были по центру */
}
/* Если же нужно, чтобы названия слева, а значения — по центру, 
   уберите text-align: center; из feature-name и верните так:
.feature-name {
  text-align: left;
}
.feature-value {
  text-align: center;
}
*/

/* Кнопки заказа (десктоп) */
.order-buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
}
.order-btn {
  padding: 12px;
  border: 1px solid #F8B69D;
  background: #fff;
  color: #F8B69D;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.order-btn.highlighted {
  background: #F8B69D;
  color: #fff;
}
.order-btn:hover,
.order-btn:active {
  background: #F8B69D;
  color: #fff;
}

/* Скрытый пул работ для мобильных (в карточке) */
.mobile-works-list {
  display: none;
  margin-top: 15px;
  border-top: 1px solid #eee;
  padding-top: 10px;
}
.mobile-works-list.open {
  display: block;
}

/* Кнопка "Развернуть список работ" (только для мобильных) */
.toggle-works-btn {
  display: none;
  margin-top: 12px;
  padding: 10px 15px;
  background: #F8B69D;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}
.toggle-works-btn:hover,
.toggle-works-btn:active {
  background: #F8B69D;
}

/* Кнопка заказа для мобильных, перенесённая в карточку */
.order-btn-mobile {
  display: none;
  margin-top: 12px;
  padding: 10px 15px;
  border: 1px solid #F8B69D;
  background: #fff;
  color: #F8B69D;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.order-btn-mobile:hover,
.order-btn-mobile:active {
  background: #F8B69D;
  color: #fff;
}

/* ---- Адаптив для мобильных (≤ 768px) ---- */
@media (max-width: 768px) {
  /* Тарифы в один столбец */
  .tariffs-grid {
    grid-template-columns: 1fr;
  }

  /* Скрываем общую таблицу сравнений и глобальные кнопки заказа */
  .features-comparison,
  .order-buttons {
    display: none;
  }

  /* Показываем кнопку "Развернуть список работ" и мобильную кнопку заказа */
  .toggle-works-btn,
  .order-btn-mobile {
    display: inline-block;
  }

  /* Делаем пул работ в виде «таблицы» из двух колонок */
  .mobile-works-list ul {
    display: table;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
  }
  .mobile-works-list li {
    display: table-row;
  }
  .mobile-works-list li span {
    display: table-cell;
    padding: 5px 0;
    vertical-align: middle;
  }
  .mobile-works-list li span.status {
    text-align: right;
  }

  /* Уменьшаем размеры шрифтов для мобильных */
  .header-block h2 {
    font-size: 24px;
  }
  .subtitle {
    font-size: 16px;
  }
  .tariff-card h3 {
    font-size: 20px;
  }
  .tariff-card .description {
    font-size: 14px;
  }
  .price {
    font-size: 20px;
  }
  .price span {
    font-size: 12px;
  }
  .toggle-works-btn,
  .order-btn-mobile,
  .mobile-works-list li,
  .order-btn {
    font-size: 14px;
  }
}

/* Класс для заголовков таблицы (если действительно нужен отдельно) */
.header-cell {
  text-align: center;
}




.tags-cloud-container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
  width: 100%;
  overflow: hidden; /* Обрезаем все, что выходит за пределы контейнера */
}

.tags-cloud {
  display: flex;
  gap: 10px; /* Уменьшаем отступы между тегами */
  transition: transform 0.3s ease;
  width: max-content;  /* Ширина контейнера зависит от контента */
}

.tag {
  background-color: #2a2c35;  /* Темный цвет фона */
  color: white;  /* Белый цвет текста */
  font-weight: bold;  /* Жирный текст */
  padding: 10px 15px;  /* Уменьшаем отступы */
  border-radius: 30px;
  text-decoration: none;
  font-size: 14px;  /* Уменьшаем размер шрифта на мобильных */
  white-space: nowrap;  /* Для предотвращения переноса текста */
  flex: 0 0 auto; /* Не растягиваем теги */
  display: none; /* Скрываем все теги по умолчанию */
}

.tag.active {
  display: inline-block; /* Показываем только активный тег */
}

/* Стиль для стрелок */
.tags-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: #F8B69D;  /* Цвет фона стрелок */
  color: black;  /* Черный цвет стрелок */
  border: none;
  padding: 10px;
  cursor: pointer;
  font-size: 24px;
  z-index: 1;
}

.left-arrow {
  left: 10px;  /* Отступ слева */
}

.right-arrow {
  right: 10px;  /* Отступ справа */
}

/* Стрелки скрыты на десктопе */
@media (min-width: 769px) {
  .tags-arrow {
    display: none;
  }

  .tags-cloud {
    width: auto;  /* Убираем ограничение ширины для десктопа */
    justify-content: center;  /* Центрируем теги */
  }

  .tag {
    display: inline-block; /* Показываем все теги на десктопе */
  }
}

/* Мобильная версия */
@media (max-width: 768px) {
  .tags-cloud {
    display: flex;
    gap: 10px;
    transform: translateX(0);  /* Начальная позиция */
    width: 100%;  /* Ширина контейнера тегов для мобильных устройств */
    justify-content: center;
    overflow: hidden;  /* Прячем все, что выходит за пределы */
  }

  /* Показ только одного тега на экране */
  .tag {
    width: auto;  /* Один тег на экране */
    text-align: center;
    padding: 10px 15px;  /* Уменьшаем отступы */
    font-size: 12px;  /* Уменьшаем размер шрифта для мобильных устройств */
    flex: 0 0 auto;
    max-width: 95%; /* Ограничиваем максимальную ширину тега */
    box-sizing: border-box;
  }

  /* Уменьшаем размер стрелок на мобильных устройствах */
  .tags-arrow {
    font-size: 18px;  /* Уменьшаем размер стрелок для мобильных */
    padding: 8px;
  }

  /* Обеспечиваем, чтобы стрелки не выходили за пределы экрана */
  .left-arrow,
  .right-arrow {
    z-index: 2;
  }

  .right-arrow {
    right: 20px;  /* Сделать отступ справа, чтобы она не выходила за экран */
  }
}

/* Стили для наведения на теги */
.tag:hover {
  background-color: #F8B69D;  /* Цвет фона при наведении */
  color: black;  /* Цвет текста при наведении */
}