/* =====================================================================
   Витрина: «− [кол-во] +» у товара, который уже в корзине (assets/js/ab_cart_qty.js, AbCartQty).
   Стиль подбора (макет «Умный поиск»): поле #1B1B1B, рамка #313131, радиус 12, цифра Benzin Medium 12 по центру.
   Лежит поверх слота кнопки «В корзину» - в том же месте и того же размера; содержимое слота под ним невидимо, но держит размер.
   ===================================================================== */
.ab-cq-on { position: relative; }
.ab-cq-on > :not(.ab-cq) { visibility: hidden !important; }

.ab-cq { position: absolute; inset: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 4px; min-width: 96px; padding: 0 3px; box-sizing: border-box;
    background: #1B1B1B; border: 1px solid #313131; border-radius: 12px; color: var(--white, #F8FAF9);
    font-family: var(--font-primary), 'Segoe UI', Arial, sans-serif; font-size: 12px; font-weight: 500; line-height: 1; letter-spacing: 0; text-align: center; cursor: default; }
.ab-cq__b { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 32px; height: calc(100% - 6px); max-height: 32px; margin: 0; padding: 0;
    border: 0; border-radius: 9px; background: none; color: inherit; font: inherit; cursor: pointer; transition: background .15s, opacity .15s; -webkit-tap-highlight-color: transparent; }
@media (hover: hover) {
    .ab-cq__b:hover { background: #313131; }
}
.ab-cq__b:focus { outline: none; }
.ab-cq__b:focus-visible { outline: 1px solid var(--white, #F8FAF9); outline-offset: 0; }/* активное состояние витрины - белая обводка 1px */
.ab-cq__b[aria-disabled="true"] { opacity: .35; }
.ab-cq__b svg { display: block; width: 14px; height: 14px; }
/* цифра: строка по центру, у Benzin буквы ниже середины - 2px снизу поднимают на 1px (как у кнопок подбора) */
.ab-cq__n { flex: 1; min-width: 16px; padding-bottom: 2px; overflow: hidden; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ab-cq.is-busy .ab-cq__b { opacity: .45; cursor: progress; }
/* подсказка: больше нет в наличии, ошибка */
.ab-cq__tip { position: absolute; z-index: 5; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); max-width: 240px; padding: 6px 10px; border-radius: 8px;
    background: var(--white, #F8FAF9); color: #1B1B1B; font-size: 10px; font-weight: 400; line-height: 15px; white-space: nowrap; pointer-events: none;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .35); animation: abCqTip .15s ease-out; }
@keyframes abCqTip { from { opacity: 0; transform: translate(-50%, 3px); } to { opacity: 1; transform: translateX(-50%); } }

/* страница цен: кнопка «В корзину» ниже (30px) и с радиусом 6 - степпер такой же; поле количества строки, пока товар в корзине, не нужно */
.ps-cartslot.ab-cq-on { min-width: 100px; }/* на узком экране кнопка - только значок 40px: степперу нужно место под цифру */
.ps-cartslot .ab-cq { border-radius: 6px; }
.ps-cartslot .ab-cq__b { height: calc(100% - 4px); border-radius: 4px; }
.ps-orow:has(.ab-cq-on) .ps-c-qty > * { visibility: hidden; }

@media (pointer: coarse) {
    .ab-cq__b { width: 36px; }
}
@media (prefers-reduced-motion: reduce) {
    .ab-cq__tip { animation: none; }
}
