/* Прайс-лист (генерируется tools/build_price.py) */

.price_list_new .section_heading {
  margin-bottom: 40px;
}

/* Вкладки категорий */
.tab_nav.price_tabs {
  margin: 0;
  gap: 8px;
  flex-wrap: wrap;
}
.tab_nav.price_tabs > li {
  padding: 0;
  flex: 1 1 auto;
}
.tab_nav.price_tabs button {
  width: 100%;
  padding: 14px 20px;
  font-size: 13px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.price_tab_content.tab-content {
  margin-top: 24px;
  padding: 40px;
  border: 1px solid var(--bs-border-color-translucent);
}

/* Таблица */
.price_table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--bs-font-heading);
}
.price_table thead th {
  padding: 0 16px 18px;
  font-size: 13px;
  font-weight: 700;
  line-height: 18px;
  text-transform: uppercase;
  text-align: right;
  vertical-align: bottom;
  color: var(--bs-body-color);
  border-bottom: 2px solid var(--bs-primary);
}
.price_table thead th:first-child {
  padding-left: 0;
  text-align: left;
}
.price_table thead th:last-child {
  padding-right: 0;
}
.price_class_size {
  display: block;
  font-size: 11px;
  font-weight: 500;
  opacity: 0.6;
}

.price_table tbody tr {
  border-bottom: 1px solid var(--bs-border-color-translucent);
  transition: background-color 0.2s ease;
}
.price_table tbody tr:not(.price_group):hover {
  background-color: rgba(209, 101, 39, 0.07);
}
.price_table tbody th,
.price_table tbody td {
  padding: 14px 16px;
  vertical-align: middle;
}
.price_table tbody th:first-child {
  padding-left: 0;
}
.price_table tbody td:last-child {
  padding-right: 0;
}

.price_name {
  font-size: 18px;
  font-weight: 600;
  line-height: 24px;
  text-align: left;
}
.price_sub {
  display: block;
  font-family: var(--bs-font-body);
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  opacity: 0.65;
}

.price_value {
  text-align: right;
  white-space: nowrap;
  width: 17%;
}
.price_value .sale_price {
  font-size: 20px;
  font-weight: 700;
  line-height: 28px;
  color: var(--bs-primary);
}
.price_value sub {
  bottom: 0;
  font-size: 14px;
  font-weight: 400;
  opacity: 0.75;
}
.price_note {
  display: block;
  font-family: var(--bs-font-body);
  font-size: 12px;
  line-height: 16px;
  opacity: 0.6;
}

.price_table .price_group th {
  padding: 28px 0 12px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bs-primary);
}
.price_table tbody .price_group:first-child th {
  padding-top: 18px;
}

.price_footnote {
  margin: 20px 0 0;
  font-size: 15px;
  opacity: 0.7;
}
.price_cta {
  margin-top: 30px;
}

/* Планшеты */
@media screen and (max-width: 991px) {
  .price_tab_content.tab-content {
    padding: 30px 24px;
  }
  .price_name {
    font-size: 16px;
  }
  .price_value .sale_price {
    font-size: 18px;
  }
  .price_table thead th,
  .price_table tbody th,
  .price_table tbody td {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* Телефоны: строки превращаются в карточки */
@media screen and (max-width: 767px) {
  /* вкладки — одна строка с горизонтальной прокруткой */
  .tab_nav.price_tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }
  .tab_nav.price_tabs::-webkit-scrollbar {
    display: none;
  }
  .tab_nav.price_tabs > li {
    flex: 0 0 auto;
    scroll-snap-align: start;
  }
  .tab_nav.price_tabs button {
    padding: 11px 16px;
    font-size: 12px;
  }
  .price_tab_content.tab-content {
    padding: 8px 16px 16px;
  }
  .price_table,
  .price_table tbody,
  .price_table tr,
  .price_table th,
  .price_table td {
    display: block;
    width: 100%;
  }
  .price_table thead {
    display: none;
  }
  .price_table tbody tr {
    padding: 14px 0;
  }
  .price_table tbody th,
  .price_table tbody td {
    padding: 0;
  }
  .price_name {
    margin-bottom: 6px;
  }
  .price_value {
    display: flex !important;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 3px 0 !important;
    text-align: right;
    white-space: normal;
  }
  .price_value::before {
    content: attr(data-label);
    font-family: var(--bs-font-body);
    font-size: 14px;
    opacity: 0.7;
    text-align: left;
  }
  .price_amount {
    flex: 0 0 auto;
  }
  .price_value .price_note {
    display: inline;
    margin-left: 4px;
  }
  .price_table_single .price_value::before,
  .price_value.price_all::before {
    content: none;
  }
  /* одна цена — в строку с названием, справа */
  .price_table_single tbody tr:not(.price_group) {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
  }
  .price_table_single .price_name {
    width: auto;
    margin-bottom: 0;
  }
  .price_table_single .price_value {
    width: auto;
    flex: 0 0 auto;
  }
  .price_table .price_group th {
    padding: 22px 0 4px !important;
  }
}
