/* OPTIK61 A1 — окно быстрого заказа модели из плитки (javascript/optik61/dp-panel.js). Общее для каталога, поиска,
   главной и избранного. Телефон и планшет (≤ 991 px) — нижний лист во всю ширину; ПК — модальное окно в две колонки:
   слева фото и сведения о модели, справа диоптрии с количеством и итог.
   Окно живёт в <body>, вне корня страницы (.o61-cat, .o61h, .o61-k), поэтому сброс кнопок и ссылок — свой.
   Слой 1300 — выше нижней панели (85), баннера cookie (90), тостов (130) и мини-корзины (200): «В корзину» ничем не
   перекрыта. Движение — transform и opacity, всем (prefers-reduced-motion не глушим — правило студии). */

:where(.o61-qo) button { font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; cursor: pointer; border-radius: 0; height: auto; }
:where(.o61-qo) a { text-decoration: none; }
:where(.o61-qo) p, :where(.o61-qo) figure, :where(.o61-qo) h2 { margin: 0; }
.o61-qo *, .o61-qo *::before, .o61-qo *::after { box-sizing: border-box; }
.o61-qo svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- плитка: модель уже в корзине (Вадим 12.11) ----------
   Кнопка «Выбрать диоптрии» плиток каталога, поиска, главной и избранного становится «✓ В корзине · N шт.» зелёным —
   видно при прокрутке, что модель уже выбирали. Нажатие по-прежнему открывает окно (можно добавить ещё).
   Класс повторён: правило должно перебить вторичный вид .is-ask страниц (0,3,0 / 0,4,0 с :hover), а этот файл грузится раньше. */
.o61-btn.is-incart.is-incart.is-incart { background: var(--ok-600); color: #fff; box-shadow: none; transition: background-color .2s var(--ease), transform .16s var(--ease); }
.o61-btn.is-incart.is-incart.is-incart:hover, .o61-btn.is-incart.is-incart.is-incart:focus { background: #0F7440; color: #fff; }
.o61-btn.is-incart.is-incart.is-incart:active { transform: scale(.98); }
.o61-btn.is-incart > span { animation: o61-incart-in .32s cubic-bezier(.2, .8, .2, 1); }
.o61-incart__i { display: inline-block; width: 15px; height: 15px; margin-right: 5px; vertical-align: -2px; fill: none; stroke: currentColor; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.o61-incart__n { font-variant-numeric: tabular-nums; }
@keyframes o61-incart-in { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }
/* узкая плитка телефона: «✓ В корзине · 12» — «шт.» остаётся в aria-label */
@media (max-width: 420px) { .o61-incart__u { display: none; } }

/* ---------- общий каркас ---------- */
.o61-qo { position: fixed; z-index: 1300; display: flex; flex-direction: column; background: #fff; overflow: hidden; font: 400 14px/1.4 var(--f-ui); color: var(--ink-900); text-align: left; -webkit-tap-highlight-color: transparent; }
.o61-qo-bg { position: fixed; inset: 0; z-index: 1290; background: rgba(6, 18, 41, .58); opacity: 0; pointer-events: none; transition: opacity .3s var(--ease); }
.o61-qo-bg.is-on { opacity: 1; pointer-events: auto; }
html.o61-qo-on, html.o61-qo-on body { overscroll-behavior: none; }
/* перелёт фото в корзину (motion.js) стартует от плитки под фоном и летит к закрытой окном панели — при открытом окне его
   не показываем: окно само отвечает зелёной кнопкой и строкой «Добавили…», после закрытия — тост и плитка «в корзине» */
html.o61-qo-on .o61-mo-fly, html.o61-qo-on .o61-mo-dock { display: none !important; }

.o61-qo__x { position: absolute; z-index: 4; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .94); color: var(--navy-900); box-shadow: 0 6px 16px -6px rgba(6, 18, 41, .35); transition: transform .18s var(--ease), background-color .18s var(--ease); }
.o61-qo__x:hover { transform: rotate(90deg); background: #fff; }
.o61-qo__x svg { width: 18px; height: 18px; stroke-width: 2.2; }
.o61-qo__grip { display: none; }
.o61-qo__top { display: none; }

.o61-qo__scroll { min-height: 0; }

/* ---------- фото: листается свайпом, точками и стрелками ---------- */
.o61-qo__media { position: relative; aspect-ratio: 4 / 3; background: #EEF1F6; overflow: hidden; }
.o61-qo__track { display: flex; width: 100%; height: 100%; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; outline: none; }
.o61-qo__track::-webkit-scrollbar { display: none; }
.o61-qo__slide { flex: 0 0 100%; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.o61-qo__slide img { display: block; width: 100%; height: 100%; object-fit: cover; }
.o61-qo__slide[data-fit="contain"] { background: #fff; }
.o61-qo__slide[data-fit="contain"] img { object-fit: contain; }
.o61-qo__slide.is-none { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--ink-500); font-size: 14px; }
.o61-qo__noimg { width: 56px; height: 56px; color: var(--ink-400); fill: none; stroke: currentColor; stroke-width: 1.3; }
.o61-qo.is-on .o61-qo__slide:first-child img { animation: o61-qo-photo .7s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes o61-qo-photo { from { opacity: .4; transform: scale(1.06); } to { opacity: 1; transform: none; } }
/* опознавательный элемент сайта — риска диоптрийной линейки по нижнему краю фото */
.o61-qo__media::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: 0; height: 7px; pointer-events: none; background: repeating-linear-gradient(90deg, rgba(10, 27, 61, .28) 0 1px, transparent 1px 8px); -webkit-mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent); mask: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent); }
.o61-qo__dots { position: absolute; left: 0; right: 0; bottom: 14px; display: flex; justify-content: center; gap: 6px; z-index: 2; }
.o61-qo__dots button { width: 8px; height: 8px; border-radius: 4px; background: rgba(10, 27, 61, .25); transition: width .25s var(--ease), background-color .25s var(--ease); }
.o61-qo__dots button[aria-current="true"] { width: 22px; background: var(--navy-900); }
.o61-qo__nav { position: absolute; top: 50%; z-index: 2; width: 40px; height: 40px; margin-top: -20px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .92); color: var(--navy-900); box-shadow: var(--sh-2); opacity: 0; transition: opacity .2s var(--ease), transform .2s var(--ease); }
.o61-qo__nav svg { width: 18px; height: 18px; }
.o61-qo__nav.is-prev { left: 12px; transform: translateX(-6px); }
.o61-qo__nav.is-next { right: 12px; transform: translateX(6px); }
.o61-qo__media:hover .o61-qo__nav, .o61-qo__nav:focus-visible { opacity: 1; transform: none; }
@media (hover: none) { .o61-qo__nav { display: none; } }

/* ---------- сведения о модели ---------- */
.o61-qo__info { padding: 16px 16px 4px; display: grid; gap: 4px; justify-items: start; }
.o61-qo__art { font: 700 12.5px/1.2 var(--f-ui); letter-spacing: .02em; color: var(--gold-600); } /* без капса: код модели «0765 v2» не должен становиться «V2» */
.o61-qo__name { font: 800 20px/1.2 var(--f-head); letter-spacing: -.01em; color: var(--ink-900); text-wrap: balance; }
.o61-qo__meta { font-size: 13px; color: var(--ink-500); }
.o61-qo__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 6px; margin-top: 6px; font-size: 14px; color: var(--ink-700); }
.o61-qo__price b { font: 800 24px/1 var(--f-head); color: var(--navy-900); letter-spacing: -.01em; }
.o61-qo__price small { font-size: 13px; color: var(--ink-500); }
.o61-qo__have { display: inline-flex; align-items: center; gap: 6px; margin-left: 6px; height: 26px; padding: 0 10px; border-radius: 13px; background: var(--ok-100); color: var(--ok-600); font: 600 12.5px/1 var(--f-ui); white-space: nowrap; align-self: center; }
.o61-qo__have i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.o61-qo__have.is-no { background: var(--bg-soft); color: var(--ink-500); }
.o61-qo__facts { display: grid; gap: 0; margin: 14px 0 0; width: 100%; max-width: 380px; font-size: 13.5px; }
.o61-qo__facts div { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-top: 1px dashed var(--line-2); }
.o61-qo__facts dt { color: var(--ink-500); font-weight: 400; }
.o61-qo__facts dd { margin: 0; color: var(--ink-900); font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.o61-qo--sheet .o61-qo__facts { display: none; }
.o61-qo__more { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; font: 700 14px/1.2 var(--f-ui); color: var(--blue-600); }
.o61-qo__more svg { width: 16px; height: 16px; transition: transform .18s var(--ease); }
.o61-qo__more:hover { color: var(--blue-600); text-decoration: underline; text-underline-offset: 3px; }
.o61-qo__more:hover svg { transform: translateX(3px); }
/* 12.11, Вадим: «Подробнее о модели» — под ценой и наличием, до диоптрий, обычной ссылкой; название — тоже ссылка */
.o61-qo__name a { color: inherit; text-decoration: none; }
.o61-qo__name a:hover { color: var(--blue-600); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
.o61-qo__name a:focus-visible, .o61-qo__more:focus-visible { outline: 2px solid var(--blue-500, #3D73E6); outline-offset: 2px; border-radius: 6px; }
.o61-qo--sheet .o61-qo__more.is-side { margin-top: 2px; }

/* ---------- диоптрии ---------- */
.o61-qo__pick { padding: 4px 16px 16px; }
.o61-qo__cap { font: 700 12px/1.2 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-500); margin: 0; padding: 14px 16px 4px; }

/* шкала модели: каждая риска — диоптрия, над риской растёт заказ (как шкала в первом экране карточки) */
/* нижний отступ 18 px: подпись «0» висит под осью (bottom −14 px) и прилипала к вкладкам «Плюс/Минус» (QA 12.11) */
.o61-qo__axis { position: relative; height: 46px; margin: 0 6px 18px; }
.o61-qo__axp { position: absolute; inset: 0; }
.o61-qo__axp::before { content: ""; position: absolute; left: 0; right: 0; bottom: 14px; height: 1px; background: var(--line-2); }
.o61-qo__tk { position: absolute; bottom: 14px; width: 12px; margin-left: -6px; height: 32px; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; cursor: pointer; }
.o61-qo__tk::after { content: ""; width: 1.5px; height: 6px; background: var(--ink-400); border-radius: 1px; }
.o61-qo__tk.is-half::after { height: 9px; }
.o61-qo__tk.is-int::after { height: 12px; background: var(--ink-700); }
.o61-qo__tk.is-out::after { background: var(--no-500); }
.o61-qo__tk i { position: absolute; bottom: 13px; width: 5px; height: 20px; border-radius: 3px 3px 1px 1px; background: linear-gradient(180deg, var(--gold-300), var(--gold-500)); transform: scaleY(0); transform-origin: 50% 100%; transition: transform .35s cubic-bezier(.2, .8, .2, 1); }
.o61-qo__tk.is-on::after { background: var(--navy-900); }
.o61-qo__ax0 { position: absolute; bottom: 4px; top: 6px; width: 0; border-left: 1px dashed var(--ink-400); }
.o61-qo__ax0 span, .o61-qo__axl { position: absolute; bottom: -4px; font: 700 11px/1 var(--f-head); color: var(--ink-500); font-variant-numeric: tabular-nums; }
.o61-qo__ax0 span { left: 0; transform: translateX(-50%); bottom: -14px; background: #fff; padding: 0 3px; }
.o61-qo__axl.is-lo { left: -6px; }
.o61-qo__axl.is-hi { right: -6px; }

.o61-qo__tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 4px; border-radius: 12px; background: var(--bg-soft); margin-bottom: 10px; }
.o61-qo__tabs[hidden] { display: none; }
.o61-qo__tabs button { position: relative; height: 42px; border-radius: 9px; display: flex; align-items: center; justify-content: center; gap: 6px; font: 700 14px/1 var(--f-ui); color: var(--ink-700); white-space: nowrap; transition: background-color .18s var(--ease), color .18s var(--ease), box-shadow .18s var(--ease); }
.o61-qo__tabs button i { font: 800 16px/1 var(--f-head); font-style: normal; color: var(--blue-600); }
.o61-qo__tabs button small { font: 600 12px/1 var(--f-ui); color: var(--ink-500); }
/* «Плюс / Для близи · 19 из 21» — две строки в прежней форме вкладки (Вадим 12.11) */
.o61-qo__tabt { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 3px; min-width: 0; line-height: 1; text-align: left; }
.o61-qo__tabt small { max-width: 100%; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.o61-qo__tabs button[aria-selected="true"] .o61-qo__tabt small { color: var(--ink-700); }
.o61-qo__tabs button[aria-selected="true"] { background: #fff; color: var(--ink-900); box-shadow: var(--sh-2); }
.o61-qo__tabs em { position: absolute; top: -8px; right: 6px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--g-gold); color: var(--navy-950); font: 800 12px/22px var(--f-head); font-style: normal; text-align: center; box-shadow: var(--sh-1); }

.o61-qo__tools { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.o61-qo__tool { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border-radius: 18px; border: 1.5px solid var(--line-2); background: #fff; font: 600 13px/1 var(--f-ui); color: var(--ink-900); white-space: nowrap; transition: border-color .16s var(--ease), background-color .16s var(--ease), transform .16s var(--ease); }
.o61-qo__tool:hover { border-color: var(--blue-600); }
.o61-qo__tool:active { transform: scale(.97); }
.o61-qo__tool svg { width: 15px; height: 15px; }
.o61-qo__tool span { color: var(--ink-500); font-weight: 600; }
.o61-qo__tool.is-gold { border-color: #E9D7A6; background: #FFF8E6; }
.o61-qo__tool.is-gold svg { color: var(--gold-600); fill: var(--gold-400); stroke: var(--gold-600); stroke-width: 1.4; }
/* «Очистить»: круглая кнопка в конце ряда, место занято всегда — появление не переносит её в новый ряд (клиент Вадима 16.11) */
.o61-qo__tool.is-clear { width: 36px; padding: 0; justify-content: center; margin-left: auto; color: var(--ink-700); visibility: hidden; opacity: 0; transform: scale(.8); transition: opacity .18s var(--ease), transform .18s var(--ease), border-color .16s var(--ease), visibility 0s linear .18s; }
.o61-qo__tool.is-clear.is-on { visibility: visible; opacity: 1; transform: none; transition: opacity .18s var(--ease), transform .18s var(--ease), border-color .16s var(--ease), visibility 0s; }
.o61-qo__tool.is-clear:hover { border-color: var(--err-600); color: var(--err-600); }

.o61-qo__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.o61-qo__c { position: relative; display: flex; align-items: center; height: 54px; border: 1.5px solid var(--line-2); border-radius: 12px; background: #fff; overflow: hidden; transition: border-color .16s var(--ease), background-color .16s var(--ease), box-shadow .16s var(--ease); }
.o61-qo__d { flex: 1 1 auto; min-width: 0; height: 100%; padding: 0 2px 0 11px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 3px; text-align: left; }
.o61-qo__d b { font: 800 15.5px/1 var(--f-head); letter-spacing: -.01em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.o61-qo__d small { font: 600 11.5px/1 var(--f-ui); color: var(--gold-600); white-space: nowrap; }
.o61-qo__stp { flex: none; display: flex; align-items: center; height: 100%; padding-right: 3px; }
.o61-qo__stp button { width: 34px; height: 42px; border-radius: 9px; display: grid; place-items: center; color: var(--navy-900); transition: background-color .14s var(--ease), color .14s var(--ease); }
.o61-qo__stp button svg { width: 17px; height: 17px; stroke-width: 2.2; }
.o61-qo__stp button:hover { background: var(--bg-soft); color: var(--blue-600); }
.o61-qo__stp button:disabled { color: var(--no-500); cursor: default; background: none; }
.o61-qo__stp input { width: 32px; height: 42px; padding: 0; border: 0; border-radius: 8px; background: none; text-align: center; font: 700 16px/1 var(--f-ui); color: var(--ink-900); font-variant-numeric: tabular-nums; outline: none; box-shadow: none; -moz-appearance: textfield; appearance: textfield; }
.o61-qo__stp input::placeholder { color: var(--ink-400); font-weight: 500; opacity: 1; }
.o61-qo__stp input:focus { background: var(--blue-50); }
.o61-qo__stp input::-webkit-inner-spin-button, .o61-qo__stp input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.o61-qo__bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: linear-gradient(90deg, var(--gold-400), var(--gold-500)); transform: scaleX(0); transform-origin: 0 50%; transition: transform .35s cubic-bezier(.2, .8, .2, 1); pointer-events: none; }
.o61-qo__c:hover { border-color: #AFC3EE; }
.o61-qo__c.is-dear { border-color: #E9D7A6; background: #FFFBF0; }
.o61-qo__c.is-on { border-color: var(--navy-900); background: var(--blue-50); box-shadow: 0 6px 14px -10px rgba(10, 27, 61, .6); }
.o61-qo__c.is-on .o61-qo__d b { color: var(--navy-900); }
.o61-qo__c.is-on input { color: var(--navy-900); font-weight: 800; }
.o61-qo__c.is-out { border-style: dashed; border-color: var(--line); background: repeating-linear-gradient(135deg, #fff 0 6px, var(--bg-soft) 6px 8px); }
.o61-qo__c.is-out .o61-qo__d b { color: var(--ink-400); }
.o61-qo__no { flex: none; padding-right: 12px; font-size: 12px; color: var(--ink-500); text-align: right; line-height: 1.15; }
.o61-qo__grid.is-in .o61-qo__c { animation: o61-qo-in .34s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(min(var(--i, 0), 24) * 16ms); }
/* отклик ячейки идёт после правила появления и сильнее его — иначе «pop» не перезапускается */
.o61-qo__grid .o61-qo__c.is-pop { animation: o61-qo-pop .28s cubic-bezier(.2, .8, .2, 1); animation-delay: var(--dl, 0ms); }
@keyframes o61-qo-pop { 0% { transform: scale(.97); } 55% { transform: scale(1.025); } 100% { transform: none; } }
.o61-qo__grid .o61-qo__c.is-flash { animation: o61-qo-flash .9s var(--ease); }
@keyframes o61-qo-flash { 0%, 100% { box-shadow: 0 0 0 0 rgba(29, 87, 219, 0); } 30% { box-shadow: 0 0 0 4px rgba(29, 87, 219, .35); } }
@keyframes o61-qo-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.o61-qo__sk { height: 54px; border-radius: 12px; background: var(--bg-soft); animation: o61-qo-sk 1s ease-in-out infinite alternate; }
.o61-qo__sk:nth-child(2n) { animation-delay: .15s; }
.o61-qo__sk:nth-child(3n) { animation-delay: .3s; }
@keyframes o61-qo-sk { from { opacity: .45; } to { opacity: 1; } }
.o61-qo__err { grid-column: 1 / -1; font-size: 14px; color: var(--ink-700); }
.o61-qo__err a { color: var(--blue-600); font-weight: 600; }

/* товар без диоптрий: одно количество */
.o61-qo__one { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 6px 10px 14px; border: 1.5px solid var(--line-2); border-radius: 14px; }
.o61-qo__onel { font: 700 15px/1.2 var(--f-ui); }
.o61-qo__one .o61-qo__stp button { width: 44px; height: 44px; }
.o61-qo__one .o61-qo__stp input { width: 52px; height: 44px; font-size: 18px; }

/* ---------- итог и «В корзину» ---------- */
.o61-qo__foot { flex: none; display: grid; gap: 8px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -12px 24px -20px rgba(6, 18, 41, .45); }
.o61-qo__sum { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; min-height: 22px; font-size: 14px; color: var(--ink-700); }
.o61-qo__sum b { font: 800 21px/1 var(--f-head); color: var(--navy-900); white-space: nowrap; letter-spacing: -.01em; }
.o61-qo__sum.is-zero span { color: var(--ink-500); }
.o61-qo__sum.is-tick b { animation: o61-qo-tick .3s cubic-bezier(.2, .8, .2, 1); }
@keyframes o61-qo-tick { from { opacity: .3; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.o61-qo__msg { padding: 9px 12px; border-radius: 10px; font-size: 13.5px; line-height: 1.4; background: var(--bg-soft); color: var(--ink-900); }
.o61-qo__msg a { color: var(--blue-600); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; white-space: nowrap; }
.o61-qo__msg.is-ok { background: var(--ok-100); color: #0D5E33; }
.o61-qo__msg.is-warn { background: #FFF6DE; color: #6B4A08; }
.o61-qo__msg.is-err { background: var(--err-100); color: #8E2323; }
.o61-qo__msg.is-info { background: var(--blue-50); color: var(--navy-900); }
.o61-qo__note { display: block; margin-top: 3px; }
.o61-qo__buy { width: 100%; --h: 52px; font-size: 16px; font-weight: 700; border-radius: 14px; }
.o61-qo .o61-qo__buy[disabled]:not(.is-loading):not(.is-done) { opacity: 1; background: #B9C9EE; box-shadow: none; }
.o61-qo .o61-qo__buy.is-done { opacity: 1; background: var(--ok-600); color: #fff; box-shadow: none; }
.o61-qo__buy.is-done .o61-ico { animation: o61-qo-tick .3s cubic-bezier(.2, .8, .2, 1); }
.o61-qo__foot.is-shake { animation: o61-qo-shake .36s var(--ease); }
@keyframes o61-qo-shake { 20% { transform: translateX(-5px); } 45% { transform: translateX(5px); } 70% { transform: translateX(-3px); } 100% { transform: none; } }

/* ---------- телефон и планшет: нижний лист ---------- */
.o61-qo--sheet { left: 0; right: 0; bottom: 0; max-height: calc(100vh - 56px); max-height: calc(100dvh - 56px); border-radius: 22px 22px 0 0; box-shadow: 0 -24px 60px -12px rgba(6, 18, 41, .45); transform: translateY(100%); transition: transform .38s cubic-bezier(.2, .8, .2, 1); will-change: transform; }
.o61-qo--sheet.is-on { transform: none; }
.o61-qo--sheet.is-off { transform: translateY(100%); transition-duration: .26s; }
.o61-qo--sheet .o61-qo__scroll { flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.o61-qo--sheet .o61-qo__grip { display: block; position: absolute; z-index: 4; top: 8px; left: 50%; width: 44px; height: 5px; margin-left: -22px; border-radius: 3px; background: rgba(10, 27, 61, .3); box-shadow: 0 0 0 3px rgba(255, 255, 255, .55); }
/* width: 100% — иначе aspect-ratio при упоре в max-height сужал фото (375×667: 356 px, белая полоса справа, QA 12.11) */
.o61-qo--sheet .o61-qo__media { width: 100%; max-height: 40vh; }
.o61-qo--sheet .o61-qo__top { display: flex; flex-direction: column; justify-content: center; gap: 2px; position: absolute; z-index: 3; top: 0; left: 0; right: 0; height: 64px; padding: 8px 64px 0 16px; background: #fff; box-shadow: 0 10px 20px -16px rgba(6, 18, 41, .5); border-radius: 22px 22px 0 0; opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity .2s var(--ease), transform .2s var(--ease); }
.o61-qo--sheet .o61-qo__top b { font: 800 16px/1.2 var(--f-head); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.o61-qo--sheet .o61-qo__top span { font-size: 12.5px; color: var(--ink-500); }
.o61-qo--sheet.is-scrolled .o61-qo__top { opacity: 1; transform: none; }
.o61-qo--sheet.is-scrolled .o61-qo__x { box-shadow: none; background: var(--bg-soft); }
@media (min-width: 600px) and (max-width: 991px) {
  /* планшет: лист уже, по центру; фото не выше трети экрана */
  .o61-qo--sheet { left: 50%; right: auto; width: 600px; margin-left: -300px; }
  .o61-qo--sheet .o61-qo__media { max-height: 34vh; aspect-ratio: 16 / 9; }
  .o61-qo__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 360px) and (max-width: 599px) {
  /* телефон: зона тапа «−/+» не уже 40 px (QA 11.11), поле количества чуть уже */
  .o61-qo__stp button { width: 40px; }
  .o61-qo__stp input { width: 28px; }
  .o61-qo__d { padding-left: 9px; }
}
@media (max-width: 359px) {
  .o61-qo__stp button { width: 30px; }
  .o61-qo__stp input { width: 28px; }
  .o61-qo__d { padding-left: 8px; }
  .o61-qo__d b { font-size: 14.5px; }
}

/* ---------- ПК: модальное окно в две колонки ---------- */
.o61-qo--modal { top: 50%; left: 50%; width: min(1000px, calc(100vw - 48px)); height: min(700px, calc(100vh - 48px)); border-radius: 24px; box-shadow: 0 40px 90px -30px rgba(6, 18, 41, .6), 0 0 0 1px rgba(6, 18, 41, .06); display: grid; grid-template-columns: minmax(0, 46fr) minmax(0, 54fr); grid-template-rows: 64px auto minmax(0, 1fr) auto; grid-template-areas: "media cap" "media pick" "info pick" "info foot"; opacity: 0; transform: translate(-50%, -48%) scale(.97); transition: opacity .24s var(--ease), transform .32s cubic-bezier(.2, .8, .2, 1); }
.o61-qo--modal.is-on { opacity: 1; transform: translate(-50%, -50%); }
.o61-qo--modal.is-off { opacity: 0; transform: translate(-50%, -48%) scale(.98); transition-duration: .18s; }
.o61-qo--modal .o61-qo__scroll { display: contents; }
.o61-qo--modal .o61-qo__media { grid-area: media; }
.o61-qo--modal .o61-qo__info { grid-area: info; align-content: start; padding: 22px 28px 24px; background: var(--bg-soft); overflow: auto; gap: 6px; }
.o61-qo--modal .o61-qo__name { font-size: 25px; }
.o61-qo--modal .o61-qo__price { margin-top: 10px; }
.o61-qo--modal .o61-qo__price b { font-size: 31px; }
.o61-qo--modal .o61-qo__have { margin-left: 0; flex-basis: auto; }
.o61-qo--modal .o61-qo__more.is-side { display: inline-flex; margin-top: 12px; height: 44px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--line-2); background: #fff; }
.o61-qo--modal .o61-qo__more.is-side:hover { border-color: var(--blue-600); text-decoration: none; }
.o61-qo--modal .o61-qo__pick { grid-area: pick; overflow-y: auto; padding: 4px 28px 16px; scrollbar-width: thin; }
.o61-qo--modal .o61-qo__cap { grid-area: cap; align-self: end; padding: 0 72px 10px 28px; }
.o61-qo--modal .o61-qo__tools { margin-bottom: 12px; }
.o61-qo--modal .o61-qo__grid { grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); }
.o61-qo--modal .o61-qo__foot { grid-area: foot; padding: 14px 28px 20px; box-shadow: none; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 16px; }
.o61-qo--modal .o61-qo__sum { flex-direction: column; align-items: flex-start; gap: 4px; }
.o61-qo--modal .o61-qo__msg { grid-column: 1 / -1; grid-row: 1; }
.o61-qo--modal .o61-qo__buy { width: auto; min-width: 230px; }
.o61-qo--modal .o61-qo__x { background: var(--bg-soft); box-shadow: none; top: 16px; right: 16px; }
.o61-qo--modal .o61-qo__x:hover { background: var(--line); }
.o61-qo--modal .o61-qo__one { margin-top: 6px; }
/* товар без диоптрий: окно ниже и уже — фото слева во всю высоту, справа название, цена, количество и кнопка */
.o61-qo--modal.is-simple { width: min(820px, calc(100vw - 48px)); height: auto; max-height: calc(100vh - 48px); grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: auto auto 1fr; grid-template-areas: "media info" "media pick" "media foot"; }
.o61-qo--modal.is-simple .o61-qo__media { aspect-ratio: auto; min-height: 340px; }
.o61-qo--modal.is-simple .o61-qo__info { background: none; padding: 30px 28px 6px; overflow: visible; }
.o61-qo--modal.is-simple .o61-qo__pick { overflow: visible; padding: 10px 28px 16px; }
.o61-qo--modal.is-simple .o61-qo__foot { align-self: end; border-top: 1px solid var(--line); }
.o61-qo--modal.is-simple .o61-qo__name { padding-right: 40px; }
