/* ===== BASKET STYLES ===== */

/* Заголовок страницы */
.basket-page-title {
    color: #005C67;
        align-self: flex-start;
    text-align: left;
    font-family: "PT Astra Serif", serif;
    font-size: 48px;
    font-style: italic;
    font-weight: 700;
    line-height: 25.6px;
    margin: 0 0 70px 0;
}

/* Разделитель после товаров */
.basket-divider {
    background: #000;
    height: 1px;
    margin-top: 70px;
}

/* ===== БЛОК ИТОГО ===== */
.basket-checkout-container {
    padding-top: 60px;
}

.basket-checkout-section-inner {
    display: flex;
    flex-direction: column;
    gap: 60px;
    margin-bottom: 70px;
}

/* Скрываем купоны */
.basket-coupon-section,
.basket-coupon-alert-section {
    display: none;
}

/* Скрываем блок "Итого" с весом */
.basket-checkout-block-total {
    display: none;
}

/* Блок с ценами — строка: Итого слева, цена справа */
.basket-checkout-block-total-price {
    width: 100%;
}

.basket-checkout-block-total-price-inner {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.basket-checkout-block-total-price-inner::before {
    content: var(--basket-total-text);
    color: #000;
    font-family: "PT Astra Serif", serif;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.2;
    font-style: italic;
    text-transform: uppercase;
}

.basket-coupon-block-total-price-current {
    color: #222322;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 32px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 1.12px;
    font-variant-numeric: lining-nums proportional-nums;
}

.basket-coupon-block-total-price-old,
.basket-coupon-block-total-price-difference {
    display: none;
}

/* Кнопка */
.basket-checkout-block-btn {
    text-align: right;
}

.basket-btn-checkout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 24px;
    border-radius: 4px;
    border: 1px solid #005C67;
    background: #005C67;
    color: #FFFFFF;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.12px;
    text-decoration: none;
    text-align: center;
    white-space: nowrap;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.basket-btn-checkout:hover {
    border: 1px solid #F6881B;
    background: transparent;
    color: #222322;
    text-decoration: none;
}

.basket-btn-checkout:active {
    border: 1px solid #F6881B;
    background: #F6881B;
    color: #FFF;
    text-decoration: none;
}

.basket-btn-checkout.disabled {
    opacity: 0.5;
    pointer-events: none;
    cursor: not-allowed;
}

.basket-items-list-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 15px;
    margin: -15px 0;
    table-layout: fixed;
}

/* Ширины колонок */
.basket-items-list-item-descriptions {
    width: auto;
}

.basket-items-list-item-price {
    width: 270px;
}

.basket-item-property-custom-value {
    color: #222322;
    font-family: "tt-commons-pro";
    font-size: 20px;
    font-style: normal;
    font-weight: 300;
    line-height: 25.6px;
}


.basket-items-list-item-action {
    width: 406px;
}

.basket-items-list-item-container {
    transition: background-color 0.3s ease;
}

.basket-items-list-item-container:hover {
    background: #FFFAF5;
}

/* Бордер через ячейки */
.basket-items-list-item-container td {
    border-top: 1px solid transparent;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease, background-color 0.3s ease;
}

.basket-items-list-item-container td:first-child {
    border-left: 1px solid transparent;
    border-radius: 12px 0 0 12px;
}

.basket-items-list-item-container td:last-child {
    border-right: 1px solid transparent;
    border-radius: 0 12px 12px 0;
}

/* Hover — фон */
.basket-items-list-item-container:hover td {
    background: #FFFAF5;
}

/* Active — бордер */
.basket-items-list-item-container:active td {
    border-top-color: rgba(246, 136, 27, 0.31);
    border-bottom-color: rgba(246, 136, 27, 0.31);
}

.basket-items-list-item-container:active td:first-child {
    border-left-color: rgba(246, 136, 27, 0.31);
}

.basket-items-list-item-container:active td:last-child {
    border-right-color: rgba(246, 136, 27, 0.31);
}

/* ===== ОСНОВНАЯ ЯЧЕЙКА С ТОВАРОМ ===== */
.basket-items-list-item-descriptions {
    padding: 20px 15px 20px 20px;
}

.basket-items-list-item-descriptions-inner {
    display: flex;
    align-items: flex-start;
    gap: 35px;
    position: relative;
}

/* ===== ФОТО ТОВАРА ===== */
.basket-item-block-image {
    position: relative;
    width: 170px;
    height: 170px;
    flex-shrink: 0;
}

.basket-item-image-link {
    display: block;
    width: 100%;
    height: 100%;
}

.basket-item-image {
    width: 170px;
    height: 170px;
    object-fit: cover;
    -webkit-mask-image: url("/local/templates/my/images/masks/news-mask.svg");
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: cover;
    mask-image: url("/local/templates/my/images/masks/news-mask.svg");
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: cover;
}

/* ===== ИЗБРАННОЕ (СЕРДЕЧКО) ===== */
.basket-item-favorite {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 22px;
    height: 20px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    z-index: 5;
    color: #fff;
    display: block;
    transition: color 0.25s ease, transform 0.25s ease;
}

.basket-item-favorite-icon {
    display: block;
    transition: transform 0.25s ease;
}

.basket-item-favorite-icon svg {
    width: 22px;
    height: 20px;
    display: block;
    fill: currentColor;
}

.basket-item-favorite:not(.is-active):hover {
    color: #E61734;
}

.basket-item-favorite.is-active {
    color: #E61734;
}

.basket-item-favorite:not(.is-active):hover .basket-item-favorite-icon {
    transform: scale(1.15);
}

/* ===== ЯРЛЫК СКИДКИ ===== */
.basket-item-discount {
    position: absolute;
    bottom: 4px;
    right: 10px;
    z-index: 5;
    width: 80px;
    height: 48px;
    background: url("/local/templates/my/images/background/oldpricesprite.png") no-repeat center;
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px 5px 16px 22px;
    box-sizing: border-box;
    color: #005C67;
    font-family: "Alegreya SC", serif;
    font-size: 18px;
    font-style: normal;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    font-variant-numeric: lining-nums proportional-nums;
    white-space: nowrap;
}

/* ===== БЛОК ИНФОРМАЦИИ О ТОВАРЕ ===== */
.basket-item-block-info {
    flex: 1;
    max-width: 680px;
    min-width: 0;
}

.basket-item-info-name {
    margin: 0 0 25px 0;
    font-family: "PT Astra Serif", serif;
    font-size: 24px;
    font-style: italic;
    font-weight: 700;
    line-height: 120%;
    color: #000;
}

.basket-item-info-name-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.25s ease;
}

.basket-item-info-name-link:hover {
    color: #005C67;
}

/* Описание товара */
.basket-item-description {
    font-family: "tt-commons-pro", sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    color: #666;
    margin-bottom: 15px;
}

/* Свойства товара */
.basket-item-block-properties {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
}

.basket-item-property {
    display: flex;
    gap: 5px;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 14px;
    font-weight: 300;
    line-height: 1.4;
    color: #666;
}

.basket-item-property-name {
    color: #999;
}

.basket-item-property-value {
    color: #222;
}

/* ===== ЯЧЕЙКА ЦЕНЫ ===== */
.basket-items-list-item-price {
    padding: 20px 15px;
    padding-right: 20px;
    vertical-align: middle;
}

.basket-item-block-price {
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.basket-item-price-old-text {
    color: #C3C7C3;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 32px;
    font-weight: 500;
    line-height: 22.4px;
    letter-spacing: 1.12px;
    text-decoration: line-through;
    font-variant-numeric: lining-nums proportional-nums;
}

.basket-item-price-current-text {
    color: #222322;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 32px;
    font-weight: 500;
    line-height: 22.4px;
    letter-spacing: 1.12px;
    text-transform: uppercase;
    font-variant-numeric: lining-nums proportional-nums;
}

.basket-item-price-title {
    display: none;
}

/* ===== ЯЧЕЙКА ДЕЙСТВИЙ (УДАЛИТЬ) ===== */
.basket-items-list-item-action {
    padding: 20px 160px 20px 0;
    vertical-align: middle;
    text-align: right;
}

.basket-item-actions-remove {
    display: inline-block;
    color: var(--color-grey-7, #111);
    text-align: center;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: 120%;
    text-decoration-line: underline;
    text-decoration-style: solid;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    transition: color 0.25s ease;
}

.basket-item-actions-remove:hover {
    color: #005C67;
}

.basket-item-actions-remove:active {
    text-decoration-line: none;
}

/* ===== СОСТОЯНИЕ "УДАЛЕНО" (ВОССТАНОВИТЬ) ===== */
.basket-items-list-item-container-expend {
    background: #FFFAF5;
}

.basket-items-list-item-container-expend td {
    background: #FFFAF5;
}

.basket-items-list-item-removed-container {
    display: flex;
    align-items: center;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
    color: #222;
}

/* Контейнер кнопок восстановить/удалить */
.basket-items-list-item-restore-actions {
    display: inline-flex;
    align-items: center;
    gap: 20px;
    white-space: nowrap;
}

.basket-item-restore-link {
    color: #005C67;
    text-decoration: underline;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 120%;
    transition: color 0.25s ease;
}

.basket-item-restore-link:hover {
    color: #F6881B;
}

/* Кнопка закрытия (окончательное удаление) */
.basket-items-list-item-clear-btn {
    display: inline-block;
    color: var(--color-grey-7, #111);
    text-align: center;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: 120%;
    text-decoration-line: underline;
    text-decoration-style: solid;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    transition: color 0.25s ease;
}

.basket-items-list-item-clear-btn::before {
    content: var(--basket-delete-text);
}

.basket-items-list-item-clear-btn:hover {
    color: #005C67;
}

.basket-items-list-item-clear-btn:active {
    text-decoration-line: none;
}

/* ===== ЛЕЙБЛЫ И СКИДКИ НА ФОТО ===== */
.basket-item-label-text {
    position: absolute;
    z-index: 3;
}

.basket-item-label-ring {
    position: absolute;
    z-index: 3;
    background: #E61734;
    color: #fff;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 4px;
}

/* Позиционирование лейблов */
.basket-item-label-left { left: 10px; }
.basket-item-label-right { right: 10px; }
.basket-item-label-center { left: 50%; transform: translateX(-50%); }
.basket-item-label-top { top: 10px; }
.basket-item-label-middle { top: 50%; transform: translateY(-50%); }
.basket-item-label-bottom { bottom: 10px; }

/* ===== ПРЕДУПРЕЖДЕНИЯ ===== */
.basket-items-list-item-warning-container {
    margin-top: 10px;
}

.basket-items-list-item-warning-container .alert {
    margin-bottom: 0;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 14px;
}

/* ===== ОВЕРЛЕЙ ЗАГРУЗКИ ===== */
.basket-items-list-item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    z-index: 10;
}

/* ===== SKU СВОЙСТВА ===== */
.basket-item-property-scu-image,
.basket-item-property-scu-text {
    margin-top: 10px;
}

.basket-item-scu-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.basket-item-scu-item {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    transition: border-color 0.25s ease;
}

.basket-item-scu-item:hover {
    border-color: #005C67;
}

.basket-item-scu-item.selected {
    border-color: #005C67;
    background: rgba(0, 92, 103, 0.1);
}

.basket-item-scu-item.not-available {
    opacity: 0.5;
    cursor: not-allowed;
}

.basket-item-scu-item-inner {
    display: block;
    font-family: "tt-commons-pro", sans-serif;
    font-size: 13px;
}

/* Для изображений SKU */
.basket-item-property-scu-image .basket-item-scu-item-inner {
    width: 30px;
    height: 30px;
    background-size: cover;
    background-position: center;
    border-radius: 2px;
}

/* ===== ПОХОЖИЕ ТОВАРЫ ===== */
.basket-items-list-item-double {
    margin-top: 10px;
}

.basket-items-list-item-double-anchor {
    color: #005C67;
    text-decoration: underline;
}

.basket-items-list-item-double-anchor:hover {
    color: #F6881B;
}

/* ===== EMPTY CART ===== */

.bx-sbb-empty-cart-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0px 10px 50px 10px;
    text-align: center;
}

.bx-sbb-empty-cart-text {
    color: #000;
    font-family: "PT Astra Serif", serif;
    font-size: 36px;
    font-style: italic;
    font-weight: 700;
    line-height: 120%;
    margin-bottom: 20px;
}

.bx-sbb-empty-cart-desc {
    color: #000;
    font-family: "PT Astra Serif", serif;
    font-size: 20px;
    font-weight: 700;
    font-style: italic;
    line-height: 140%;
}

/* ===== LINK STYLES ===== */

.bx-sbb-empty-cart-desc a {
    color: #000;
    text-decoration: underline;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

/* hover */
.bx-sbb-empty-cart-desc a:hover {
    text-decoration: underline;
    color: #005C67;
}

/* active */
.bx-sbb-empty-cart-desc a:active {
    text-decoration: none;
    color: #005C67;
}

/* ===== ORDER LIST (Мои книги) — RESPONSIVE ===== */

/* 1400px — сжимаем action, цена минимум 300px */
/* ===== ОБЩИЕ МЕДИА (корзина + order-list) ===== */

/* 1400px */
@media (max-width: 1400px) {
    .basket-items-list-item-action {
        width: 250px;
        padding-right: 20px;
    }

    .basket-items-list-item-price {
        width: 300px;
    }
}

/* 1200px */
@media (max-width: 1200px) {
    .basket-items-list-table {
        table-layout: auto;
    }

    .basket-items-list-item-action {
        width: auto;
        padding-right: 20px;
        white-space: nowrap;
    }

    .basket-items-list-item-price {
        width: auto;
        white-space: nowrap;
    }
}

/* 1024px */
@media (max-width: 1024px) {

    .bx-sbb-empty-cart-container {

    padding: 0 0 50px 0;

}
    .basket-items-list-table,
    .basket-items-list-table tbody,
    .basket-items-list-table tr,
    .basket-items-list-table td {
        display: block;
        width: 100%;
    }

    .basket-items-list-table {
        border-spacing: 0;
    }

    .basket-items-list-item-container {
        padding: 20px;
        margin-bottom: 15px;
        border: 1px solid #eee;
        border-radius: 12px;
    }

    .basket-items-list-item-container:hover {
        background: #FFFAF5;
        border-color: rgba(246, 136, 27, 0.31);
    }

    .basket-items-list-item-container td {
        border: none !important;
        border-radius: 0 !important;
        background: transparent !important;
    }

    .basket-items-list-item-descriptions {
        padding: 0;
    }

    .basket-items-list-item-descriptions-inner {
        display: flex;
        align-items: flex-start;
        gap: 20px;
    }

    .basket-item-block-image {
        width: 170px;
        height: 170px;
        flex-shrink: 0;
    }

    .basket-item-image {
        width: 170px;
        height: 170px;
    }

    .basket-item-block-info {
        min-width: 0;
        flex: 1;
    }

    .basket-items-list-item-price {
        width: auto;
        padding: 16px 0 0 190px;
        text-align: left;
    }

    .basket-items-list-item-action {
        width: auto;
        padding: 15px 0 0 190px;
        text-align: left;
    }

    .basket-page-title {
        font-size: 48px;
        margin-bottom: 50px;
    }

    .basket-divider {
        margin-top: 40px;
    }

    /* order-list отличия */
    .order-list-page .basket-items-list-item-action {
        padding-top: 25px;
    }
}

/* 580px */
@media (max-width: 580px) {

        .basket-products-slider .products-slider__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .basket-coupon-block-total-price-current {
    font-size: 24px;
}

    .basket-checkout-block-total-price-inner::before {

    font-size: 18px;

}
    /* Общие */
    .basket-item-property-custom-value {
        font-size: 12px;
    }

    .basket-item-favorite {
        top: 8px;
        right: 8px;
        width: 18px;
        height: 16px;
    }

    .basket-item-favorite-icon svg {
        width: 18px;
        height: 16px;
    }


    .basket-item-discount {
        width: 60px;
        height: 36px;
        padding: 13px 4px 12px 16px;
        font-size: 14px;
        letter-spacing: 0.6px;
        bottom: 3px;
        right: 7px;
    }

    .basket-item-price-old-text,.basket-item-price-current-text {
        font-size: 24px;
    }

    .basket-page-title {
        font-size: 24px;
        margin-bottom: 30px;
    }

    .basket-items-list-item-container {
        padding: 16px;
    }

    .basket-item-block-image {
        width: 120px;
        height: 120px;
    }

    .basket-item-image {
        width: 120px;
        height: 120px;
    }

    .basket-items-list-item-descriptions-inner {
        gap: 16px;
    }

    .basket-items-list-item-price {
        padding-left: 140px;
    }

    .basket-items-list-item-action {
        padding-left: 140px;
    }

    .basket-item-info-name {
        font-size: 16px;
        margin-bottom: 8px;
    }

            .basket-items-list-item-removed-text {
        font-size: 16px;
    }

    .basket-divider {
        margin-top: 30px;
    }

    .basket-checkout-section-inner {
        gap: 40px;
        margin-bottom: 50px;
    }

    .basket-btn-checkout {
        width: 100%;
    }

    .basket-checkout-block-btn {
        text-align: center;
    }

    .bx-sbb-empty-cart-text {
        font-size: 24px;
    }

    .bx-sbb-empty-cart-desc {
        font-size: 16px;
    }

    /* order-list отличия */
    .order-list-page .basket-page-title {
        text-align: center;
    }

    .order-list-page .basket-items-list-item-descriptions-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .order-list-page .basket-item-block-image {
        width: 140px;
        height: 140px;
        align-self: center;
    }

    .order-list-page .basket-item-image {
        width: 140px;
        height: 140px;
    }

    .order-list-page .basket-item-block-info {
        max-width: 100%;
        text-align: center;
    }

    .order-list-page .basket-item-info-name {
        text-align: center;
    }

    .order-list-page .basket-item-block-properties {
        justify-content: center;
    }

    .order-list-page .basket-item-description {
        text-align: center;
        font-size: 14px;
    }

    .order-list-page .basket-items-list-item-price {
        padding-left: 0;
        text-align: center;
    }

    .order-list-page .basket-item-block-price {
        justify-content: center;
    }

    .order-list-page .basket-item-price-current-text,
    .order-list-page .basket-item-price-old-text {
        font-size: 32px;
    }

    .order-list-page .basket-items-list-item-action {
        padding-left: 0;
        text-align: center;
    }

    .order-list-page .order-listen-group {
        justify-content: center;
    }

    .order-list-page .basket-divider {
        margin-top: 70px;
    }
}

/* 420px */
@media (max-width: 420px) {
    .basket-item-block-image {
        width: 100px;
        height: 100px;
    }

    .basket-item-image {
        width: 100px;
        height: 100px;
    }

    .basket-items-list-item-price {
        padding-left: 120px;
    }

    .basket-items-list-item-action {
        padding-left: 120px;
    }
}

/* 360px */
@media (max-width: 360px) {

        .basket-item-discount {
        width: 44px;
        height: 26px;
        padding: 9px 2px 8px 12px;
        font-size: 12px;
        letter-spacing: 0.4px;
        bottom: 2px;
        right: 4px;
    }
    .basket-items-list-item-container {
        padding: 12px;
    }

    .basket-item-block-image {
        width: 80px;
        height: 80px;
    }

    .basket-item-image {
        width: 80px;
        height: 80px;
    }

    .basket-items-list-item-price {
        padding-left: 100px;
    }

    .basket-items-list-item-action {
        padding-left: 100px;
    }

    .basket-item-info-name {
        font-size: 16px;
    }

    .basket-items-list-item-descriptions-inner {
        gap: 12px;
    }

    /* order-list */
    .order-list-page .basket-item-block-image {
        width: 120px;
        height: 120px;
    }

    .order-list-page .basket-item-image {
        width: 120px;
        height: 120px;
    }
}
