/*
 * Опис товару.
 * Figma: Inter, 14/20, Gray_02/90 — #424242.
 */

.product-page .product-description__text {
    display: block;
    margin: 0;

    color: #424242;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;

    white-space: normal;
    overflow-wrap: anywhere;
}

.product-page .product-description__text > :first-child {
    margin-top: 0;
}

.product-page .product-description__text > :last-child {
    margin-bottom: 0;
}

.product-page .product-description__text p {
    margin: 0 0 16px;

    color: #424242;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;

    white-space: pre-line;
    overflow-wrap: anywhere;
}

.product-page .product-description__text h4 {
    margin: 16px 0;

    color: #424242;

    font-size: 14px;
    font-weight: 700;
    line-height: 20px;

    overflow-wrap: anywhere;
}

.product-page .product-description__text ul {
    display: block;

    margin: 0 0 16px;
    padding-left: 20px;

    list-style: disc outside;
}

.product-page .product-description__text li {
    display: list-item;

    margin: 0;
    padding: 0;

    color: #424242;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;

    overflow-wrap: anywhere;
}

.product-page .product-description__text li + li {
    margin-top: 8px;
}

/*
 * JavaScript керує висотою опису.
 */

.product-page .product-description__content.is-enhanced
.product-description__text {
    overflow: hidden;
}

/*
 * Таблиця характеристик.
 */

.product-page .product-specifications th,
.product-page .product-specifications td {
    color: #424242;

    font-size: 14px;
    line-height: 20px;
}

.product-page .product-specifications th,
.product-page .product-specifications tbody
> tr:first-child > th {
    font-weight: 700;
}

.product-page .product-specifications td {
    font-weight: 400;
}

/*
 * Вкладки.
 */

.product-page .product-tabs__button {
    color: #424242;

    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
}

.product-page .product-tabs__button[aria-selected="true"] {
    color: #424242;
    border-bottom-color: #0093ee;
}

/*
 * Панель купівлі.
 */

.product-page .product-buy-button,
.product-page .product-installation__button {
    font-weight: 500;
}

.product-page .product-gallery__badge {
    font-weight: 500;
}

.product-page .product-conditions h3 {
    color: #000000;

    font-size: 16px;
    font-weight: 700;
    line-height: 24px;
}

.product-page .product-conditions p {
    color: #0a0a0a;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
}

.product-page .product-assurances h3 {
    color: #9e9e9e;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
}

.product-page .product-assurances p {
    color: #0a0a0a;

    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
}

/*
 * Наведення на вкладки.
 */

@media (hover: hover) and (pointer: fine) {
    .product-page .product-tabs__button:hover {
        color: #ee6a00;
        border-bottom-color: #0093ee;
    }
}

/*
 * Плашки схожих товарів на десктопі.
 */

@media (min-width: 768px) {
    .product-page .product-related__list
    .sv-product-card__badge {
        font-size: 16px;
        font-weight: 500;
        line-height: 24px;
    }
}

/*
 * Мобільна версія.
 */

@media (max-width: 767px) {
    /*
     * Інформація:
     * заголовок → код → назва → галерея.
     */

    .product-page .product-information {
        row-gap: 8px;
    }

    .product-page .product-heading {
        flex-direction: column;
        align-items: stretch;
        gap: 24px;
    }

    .product-page .product-sku {
        order: -1;
        justify-content: flex-start;
        max-width: 100%;
    }

    /*
     * Ціни окремим рядком.
     * Кнопка та значки нижче.
     */

    .product-page .product-purchase {
        column-gap: 24px;
        row-gap: 24px;
    }

    .product-page .product-prices {
        flex: 0 0 100%;

        width: 100%;
        min-width: 0;
    }

    .product-page .product-buy-form {
        flex: 0 0 auto;
    }

    .product-page .product-summary__actions {
        flex: 0 0 auto;
    }

    /*
     * Відступи секцій за мобільним макетом.
     */

    .product-page .product-description,
    .product-page .product-related {
        margin-top: 24px;
    }

    .product-page .product-description {
        row-gap: 10px;
    }

    .product-page .product-related {
        row-gap: 24px;
    }

    .product-page .product-tabs {
        margin-bottom: 24px;
    }

    /*
     * Характеристики:
     * назва зверху, значення нижче.
     */

    .product-page .product-specifications {
        display: block;

        width: 100%;
        min-width: 0;
        max-width: 100%;

        table-layout: auto;
    }

    .product-page .product-specifications colgroup {
        display: none;
    }

    .product-page .product-specifications tbody {
        display: block;

        width: 100%;
        min-width: 0;
    }

    .product-page .product-specifications tbody > tr {
        display: grid;
        grid-template-columns: minmax(0, 1fr);

        width: 100%;
        min-width: 0;

        margin: 0;
        padding: 0;

        border: 0;
    }

    .product-page .product-specifications th,
    .product-page .product-specifications td {
        display: block;
        box-sizing: border-box;

        width: 100%;
        min-width: 0;
        max-width: 100%;

        margin: 0;
        padding: 14px 0;

        border: 0;

        text-align: left;
        overflow-wrap: anywhere;
    }

    .product-page .product-specifications th {
        font-weight: 700;
    }

    .product-page .product-specifications td {
        border-bottom: 1px solid #f5f5f5;

        font-weight: 400;
        white-space: pre-line;
    }

    .product-page .product-specifications tbody
    > tr:last-child > td {
        border-bottom: 0;
    }

    /*
     * Схожі товари.
     */

    .product-page .product-related__list {
        display: grid;

        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: min(296px, 100%);

        align-items: stretch;
        gap: 16px;

        min-width: 0;
        max-width: 100%;

        margin: 0;
        padding: 0 0 12px;

        overflow-x: auto;

        scroll-snap-type: x proximity;
        scroll-padding-inline: 0;

        overscroll-behavior-x: contain;

        scrollbar-width: thin;
        scrollbar-color: #0093ee #e8f6ff;
    }

    .product-page .product-related__list > li {
        display: flex;

        min-width: 0;

        scroll-snap-align: start;
    }

    .product-page .product-related__list .sv-product-card {
        width: 100%;
        min-width: 0;
        min-height: 450px;
        height: 100%;
    }

    .product-page .product-related__list::-webkit-scrollbar {
        height: 4px;
    }

    .product-page .product-related__list::-webkit-scrollbar-track {
        border-radius: 4px;
        background: #e8f6ff;
    }

    .product-page .product-related__list::-webkit-scrollbar-thumb {
        border-radius: 4px;
        background: #0093ee;
    }
}