.autopiter-live-placeholder { width: 100%; min-width: 0; }
.autopiter-live-loading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 10px 0;
    padding: 14px 16px;
    background: #f0f7fc;
    border: 1px solid #cfe3f2;
    border-radius: 8px;
    color: #145e92;
    font-size: 15px;
    line-height: 1.4;
}
.autopiter-live-loading svg { width: 36px; height: 36px; flex: 0 0 36px; overflow: visible; }
.autopiter-live-loading .search-glass { transform-origin: center; animation: autopiter-search 1.4s ease-in-out infinite; }
.autopiter-live-loading .search-dots { animation: autopiter-dots 1.4s ease-in-out infinite; }
.autopiter-live-message { margin: 10px 0; padding: 10px 12px; line-height: 1.45; }
.autopiter-live-offers .item-name { overflow-wrap: anywhere; }
.has-product-results .catalog-detail-item-table .autopiter-live-offers .delivery-status .not-in-stock::after { content: none; }
@keyframes autopiter-search {
    0%, 100% { transform: translate(-2px, 0); }
    50% { transform: translate(3px, -2px); }
}
@keyframes autopiter-dots {
    0%, 100% { opacity: .35; }
    50% { opacity: 1; }
}
@media (max-width: 767px) {
    .autopiter-live-loading { padding: 12px; gap: 10px; font-size: 14px; }
    .autopiter-live-offers { width: 100%; max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .autopiter-live-loading .search-glass,
    .autopiter-live-loading .search-dots { animation: none; }
}

.autopiter-live-placeholder { container-type: inline-size; container-name: autopiter-offer; }
/* Keep the site's six-column mobile card mapping; desktop overrides are scoped. */
@media (min-width: 768px) {
    .catalog-detail-item-table table.autopiter-live-offers {
        width: 100%;
        max-width: 100%;
        table-layout: auto;
        border-collapse: collapse;
        margin-bottom: 0;
    }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th {
        padding: 10px 4px;
        border: 0;
        border-bottom: 1px solid #cbdfea;
        background: #e4f1f9;
        color: #24597d;
        font-size: 12px;
        font-weight: 500;
        line-height: 1.35;
        text-align: center;
        vertical-align: middle;
    }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:first-child {
        width: 30%;
        padding-left: 12px;
        text-align: left;
    }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:nth-child(2) { width: 9%; }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:nth-child(3) { width: 11%; }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:nth-child(4) { width: 21%; }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:nth-child(5) { width: 20%; text-align: right; }
    .catalog-detail-item-table table.autopiter-live-offers thead tr th:nth-child(6) { width: 9%; padding: 0; }
    .catalog-detail-item-table table.autopiter-live-offers tbody {
        border: 0;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody tr.first td {
        padding: 9px 12px;
        border: 0;
        border-left: 3px solid #1469a9;
        border-bottom: 1px solid #e0ebf3;
        background: #f3f8fc;
        text-align: left;
    }
    .catalog-detail-item-table table.autopiter-live-offers .category-name {
        color: #1469a9;
        font-size: 14px;
        font-weight: 600;
    }
    .catalog-detail-item-table table.autopiter-live-offers .articul-name {
        color: #708598;
        font-size: 12px;
        line-height: 1.5;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td {
        width: auto;
        height: auto;
        padding: 14px 4px;
        border: 0;
        border-bottom: 1px solid #e0ebf3;
        color: #164d78;
        font-size: 14px;
        line-height: 1.4;
        text-align: center;
        vertical-align: middle;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:first-child {
        padding-left: 12px;
        border-left: 3px solid #1469a9;
        color: #0067b5;
        text-align: left;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(2) {
        font-size: 15px;
        font-weight: 600;
        overflow-wrap: anywhere;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(3) { white-space: nowrap; }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td.sort_price {
        color: #163f62;
        font-size: 17px;
        font-weight: 700;
        font-variant-numeric: tabular-nums;
        white-space: nowrap;
        text-align: right;
    }
    .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(6) { padding-right: 0; padding-left: 0; }
    .catalog-detail-item-table table.autopiter-live-offers .delivery-status {
        margin: 0;
        line-height: 1.35;
    }
    .catalog-detail-item-table table.autopiter-live-offers .delivery-status .not-in-stock {
        font-size: 15px;
        font-weight: 700;
        white-space: nowrap;
    }
    .catalog-detail-item-table table.autopiter-live-offers .btn.btn-cart {
        width: 32px;
        height: 32px;
        border-radius: 8px;
        border-color: #b5d3eb;
    }
    .catalog-detail-item-table table.autopiter-live-offers .btn.btn-cart:focus-visible {
        outline: 2px solid #0067b5;
        outline-offset: 2px;
    }
}
/* A desktop catalog panel can be narrower than a phone beside the diagram. */
@media (min-width: 768px) {
    @container autopiter-offer (max-width: 500px) {
        .catalog-detail-item-table table.autopiter-live-offers,
        .catalog-detail-item-table table.autopiter-live-offers tbody {
            display: block;
            width: 100%;
        }
        .catalog-detail-item-table table.autopiter-live-offers thead { display: none; }
        .catalog-detail-item-table table.autopiter-live-offers tbody tr.first { display: block; }
        .catalog-detail-item-table table.autopiter-live-offers tbody tr.first td {
            display: block;
            width: 100%;
            box-sizing: border-box;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 12px;
            padding: 14px 12px;
            border: 1px solid #e0ebf3;
            border-left: 3px solid #1469a9;
            border-top: 0;
            border-radius: 0 0 8px 8px;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td {
            display: block;
            width: auto;
            min-width: 0;
            padding: 0;
            border: 0;
            text-align: left;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:first-child {
            grid-column: 1 / -1;
            padding: 0;
            border: 0;
            font-size: 15px;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(2)::before,
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(3)::before {
            display: block;
            margin-bottom: 3px;
            color: #708598;
            font-size: 11px;
            font-weight: 400;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(2)::before { content: 'Количество, шт.'; }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(3)::before { content: 'Склад'; }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(4) { grid-column: 1 / -1; }
        .catalog-detail-item-table table.autopiter-live-offers .delivery-status {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: flex-start;
            gap: 4px 8px;
            text-align: left;
        }
        .catalog-detail-item-table table.autopiter-live-offers .delivery-status br { display: none; }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td.sort_price {
            grid-column: 1 / -1;
            font-size: 20px;
            text-align: left;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td.sort_price::after {
            content: ' ₽';
            font-size: 16px;
            font-weight: 600;
        }
        .catalog-detail-item-table table.autopiter-live-offers tbody.list tr td:nth-child(6) { grid-column: 1 / -1; }
        .catalog-detail-item-table table.autopiter-live-offers .btn.btn-cart {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            width: 100%;
            height: 38px;
        }
        .catalog-detail-item-table table.autopiter-live-offers .btn.btn-cart::before { margin-top: 0; }
        .catalog-detail-item-table table.autopiter-live-offers .btn.btn-cart::after {
            content: 'В корзину';
            font-size: 13px;
        }
    }
}
.autopiter-live-cart-heading {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
