/* Цены (views/constructor/tablePrice.php). Виды: table (таблица; на телефоне — карточки строк), pricelist (название … цена), tariffs (карточки тарифов). */
.cb-tablePrice {--cb-tablePrice-zebra: rgba(22, 35, 45, .025)}
.cb-tone--dark .cb-tablePrice {--cb-tablePrice-zebra: rgba(255, 255, 255, .035)}

/* ---- Таблица ---- */
.cb-tablePrice__wrap {overflow: hidden; background: var(--cb-card-bg); border: 1px solid var(--cb-card-border); border-radius: var(--cb-radius); box-shadow: var(--cb-card-shadow)}
.cb-tablePrice__table {width: 100%; margin: 0; border-collapse: collapse; color: var(--cb-fg); font-size: 16px; line-height: 1.45}
.cb-tablePrice__table th, .cb-tablePrice__table td {padding: 16px 20px; border: 0; border-bottom: 1px solid var(--cb-line); text-align: center; vertical-align: middle; overflow-wrap: anywhere}
.cb-tablePrice__table thead th {padding-block: 14px; background: var(--cb-accent-soft); color: var(--cb-heading); font-size: 13px; font-weight: 700; letter-spacing: .06em; line-height: 1.35; text-transform: uppercase}
.cb-tablePrice__table tr > :first-child {text-align: left}
@media (min-width: 768px) {
    .cb-tablePrice__table tr > :first-child {padding-left: clamp(20px, 2.4vw, 32px)}
    .cb-tablePrice__table tr > :last-child {padding-right: clamp(20px, 2.4vw, 32px)}
}
.cb-tablePrice__table tbody th {color: var(--cb-heading); font-weight: 600}
.cb-tablePrice__table tbody tr:nth-child(even) > * {background: var(--cb-tablePrice-zebra)}
.cb-tablePrice__table tbody tr:last-child > * {border-bottom: 0}
.cb-tablePrice__table tbody tr > * {transition: background var(--cb-transition)}
.cb-tablePrice__table tbody tr:hover > * {background: var(--cb-accent-soft)}
.cb-tablePrice__table td.cb-tablePrice__price {color: var(--cb-heading); font-size: 17px; font-weight: 700; white-space: nowrap}
.cb-tablePrice__table tr > .cb-tablePrice__price:last-child {text-align: right}
.cb-tablePrice__table .cb-tablePrice__order {width: 1%; text-align: right; white-space: nowrap}
.cb-tablePrice__order .cb-btn {min-height: 40px; padding: 0 20px}
.cb-tablePrice__order .cb-btn:hover {transform: none}

/* ---- Примечание ---- */
.cb .cb-tablePrice__note {max-width: 820px; margin: 18px 0 0; color: var(--cb-fg); font-size: 14px; line-height: 1.55}
.cb .cb-tablePrice__note--center {margin-inline: auto; text-align: center}

/* ---- Прайс-лист ---- */
.cb-tablePrice__groups {display: grid; gap: clamp(16px, 2vw, 28px); max-width: 880px}
.cb-title--center ~ .cb-tablePrice__groups {margin-inline: auto}
.cb-tablePrice__groups--multi {grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none}
.cb-tablePrice__group {padding: clamp(22px, 2.6vw, 34px); background: var(--cb-card-bg); border: 1px solid var(--cb-card-border); border-radius: var(--cb-radius); box-shadow: var(--cb-card-shadow)}
.cb .cb-tablePrice__group-name {margin: 0 0 12px; color: var(--cb-heading); font-size: 20px; font-weight: 700; line-height: 1.3}
.cb-tablePrice__lines {margin: 0; padding: 0; list-style: none}
.cb-tablePrice__line {padding: 12px 0; border-bottom: 1px solid var(--cb-line)}
.cb-tablePrice__line:last-child {padding-bottom: 0; border-bottom: 0}
.cb-tablePrice__line-row {display: flex; align-items: flex-end; gap: 10px; line-height: 1.5}
.cb-tablePrice__line-name {flex: 0 1 auto; min-width: 0; color: var(--cb-heading); font-weight: 500}
.cb-tablePrice__dots {flex: 1 0 24px; min-width: 24px; margin-bottom: .42em; border-bottom: 2px dotted var(--cb-line)}
.cb-tone--light .cb-tablePrice__dots {border-bottom-color: rgba(22, 35, 45, .28)}
.cb-tablePrice__line-price {flex: 0 0 auto; max-width: 55%; color: var(--cb-heading); font-weight: 700; text-align: right}
.cb .cb-tablePrice__line-note {margin: 2px 0 0; color: var(--cb-fg); font-size: 14px; line-height: 1.45}

/* ---- Тарифы ---- */
.cb-tablePrice__tariffs {margin: 0; padding: 0; list-style: none; align-items: stretch}
.cb-tablePrice__tariffs--single {max-width: 440px}
.cb-title--center ~ .cb-tablePrice__tariffs--single {margin-inline: auto}
.cb-tablePrice__tariff {padding: clamp(26px, 2.6vw, 36px) clamp(22px, 2.4vw, 32px)}
.cb-tablePrice__tariff.is-featured {border: 2px solid var(--cb-accent); box-shadow: var(--cb-shadow-hover)}
.cb-tone--dark .cb-tablePrice__tariff.is-featured {background: rgba(255, 255, 255, .1); box-shadow: none}
.cb-tablePrice__badge {position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%); margin: 0; padding: 6px 14px; border-radius: 999px; background: var(--cb-btn-bg); color: var(--cb-btn-fg); font-size: 12px; font-weight: 700; letter-spacing: .08em; line-height: 1.2; text-transform: uppercase; white-space: nowrap}
.cb .cb-tablePrice__tariff-name {margin: 0; color: var(--cb-heading); font-size: 20px; font-weight: 700; line-height: 1.3}
.cb .cb-tablePrice__tariff-price {display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin: 16px 0 0; color: var(--cb-fg); font-size: 15px}
.cb-tablePrice__tariff-price b {color: var(--cb-heading); font-size: clamp(30px, 2.8vw, 40px); font-weight: 800; line-height: 1.05; letter-spacing: -.02em}
.cb .cb-tablePrice__tariff-text {margin: 12px 0 0; color: var(--cb-fg); font-size: 15px; line-height: 1.55}
.cb .cb-tablePrice__features {display: grid; gap: 10px; margin: 22px 0 0; padding: 22px 0 0; border-top: 1px solid var(--cb-line); list-style: none}
.cb-tablePrice__features li {position: relative; padding-left: 30px; color: var(--cb-fg); font-size: 15px; line-height: 1.45}
.cb-tablePrice__features li::before {content: ""; position: absolute; left: 0; top: .08em; width: 20px; height: 20px; border-radius: 50%; background: var(--cb-accent-soft)}
.cb-tablePrice__features li::after {content: ""; position: absolute; left: 4px; top: calc(.08em + 4px); width: 12px; height: 12px; background: var(--cb-accent); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M1.5 6.2 4.6 9.2 10.5 2.8' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M1.5 6.2 4.6 9.2 10.5 2.8' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat}
.cb-tablePrice__tariff.is-featured .cb-tablePrice__features li::before {background: var(--cb-accent)}
.cb-tablePrice__tariff.is-featured .cb-tablePrice__features li::after {background: var(--cb-bg, #fff)}
.cb-tablePrice__tariff-action {margin-top: auto; padding-top: 28px}

@media (min-width: 992px) {
    .cb-tablePrice__tariff.is-featured {margin-block: -12px; padding-block: calc(clamp(26px, 2.6vw, 36px) + 12px)}
    .cb-tablePrice__tariffs:has(.is-featured) {padding-block: 12px}
}
@media (max-width: 991px) {
    .cb-tablePrice__groups--multi {grid-template-columns: 1fr; max-width: 880px}
    .cb-title--center ~ .cb-tablePrice__groups--multi {margin-inline: auto}
    .cb-tablePrice__table th, .cb-tablePrice__table td {padding-inline: 14px}
}

/* ---- Телефон: строка таблицы — карточка, ячейки с подписями колонок ---- */
@media (max-width: 767px) {
    .cb-tablePrice__wrap {overflow: visible; background: none; border: 0; border-radius: 0; box-shadow: none}
    .cb-tablePrice__table, .cb-tablePrice__table tbody, .cb-tablePrice__table tr, .cb-tablePrice__table th, .cb-tablePrice__table td {display: block; width: auto}
    .cb-tablePrice__table thead {position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap}
    .cb-tablePrice__table tbody {display: grid; gap: 12px}
    .cb-tablePrice__table tbody tr {padding: 18px 18px 16px; background: var(--cb-card-bg); border: 1px solid var(--cb-card-border); border-radius: var(--cb-radius); box-shadow: var(--cb-card-shadow)}
    .cb-tablePrice__table tbody tr > *, .cb-tablePrice__table tbody tr:nth-child(even) > *, .cb-tablePrice__table tbody tr:hover > * {padding: 8px 0; border: 0; background: none; text-align: left}
    .cb-tablePrice__table tbody tr > :first-child {padding: 0 0 10px; border-bottom: 1px solid var(--cb-line); font-size: 17px; font-weight: 700; line-height: 1.35}
    .cb-tablePrice__table tbody td {display: flex; justify-content: space-between; align-items: baseline; gap: 16px; color: var(--cb-heading); text-align: right}
    .cb-tablePrice__table tbody td + td:not(.cb-tablePrice__order) {border-top: 1px dashed var(--cb-line)}
    .cb-tablePrice__table tbody tr > :first-child + td {padding-top: 10px}
    .cb-tablePrice__table tbody td::before {content: attr(data-label); flex: 0 1 auto; color: var(--cb-fg); font-size: 14px; font-weight: 400; text-align: left}
    .cb-tablePrice__table tbody td.is-empty {display: none}
    .cb-tablePrice__table td.cb-tablePrice__price {white-space: normal}
    .cb-tablePrice__table tbody td.cb-tablePrice__order {display: block; width: auto; padding: 12px 0 0; white-space: normal}
    .cb-tablePrice__table tbody td.cb-tablePrice__order::before {content: none}
    .cb-tablePrice__order .cb-btn {width: 100%; min-height: 46px}
    .cb-tablePrice__table--nohead tbody td::before {content: none}
    .cb-tablePrice__table--nohead tbody td {justify-content: flex-end}
}
@media (max-width: 575px) {
    .cb-tablePrice__line-row {gap: 8px}
    .cb-tablePrice__line-price {max-width: 48%}
    .cb-tablePrice__group {padding: 20px 18px}
}
@media print {
    .cb-tablePrice__order {display: none}
}
