/* 3D-блок в карточке товара (bs-product-3d.php): блоки — фото 500 px слева, описание справа (было 800 из 1100 и всё в одну колонку) */
@media (min-width: 992px) {
	body.bsp3d-card div.product { flex: 1 1 100% !important; width: 100% !important; max-width: 1100px !important; }
	body.bsp3d-card .product-container { flex-wrap: nowrap !important; gap: 40px; align-items: flex-start; }
	body.bsp3d-card .product-images { flex: 0 0 500px !important; width: 500px !important; max-width: 500px !important; }
	body.bsp3d-card .product-info { flex: 1 1 auto !important; width: auto !important; min-width: 0; }
}
/* одна колонка (планшет, узкое окно): тема сжимала фото до ~265 px — даём до 500 */
@media (min-width: 600px) and (max-width: 991px) {
	body.bsp3d-card .product-images { width: 100% !important; max-width: 500px !important; flex: 0 0 auto !important; }
}
.woocommerce-product-gallery .flex-viewport, .woocommerce-product-gallery__wrapper { position: relative; }
.bsp3d-open { position: relative; order: 1; align-self: flex-start; margin: 12px 0 0; display: inline-flex; align-items: center; gap: 9px; padding: 8px 16px 8px 8px !important; border: 0 !important; border-radius: 999px !important; background: #eaa200 !important; color: #1a1a1a !important; font: 800 14px/1 PreviewFont, Manrope, sans-serif !important; box-shadow: 0 6px 18px rgba(60,40,0,.25); cursor: pointer; }
.bsp3d-open:hover, .bsp3d-open:focus { background: #f2b21a !important; color: #1a1a1a !important; }
.bsp3d-open b { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #1a1a1a; color: #eaa200; font-size: 11px; }
.flex-control-thumbs li.bsp3d-thumb { display: grid !important; place-items: center; background: #1a1a1a; border-radius: 6px; cursor: pointer; color: #eaa200; font: 800 15px/1 PreviewFont, Manrope, sans-serif; }
.bsp3d { container-type: size; position: absolute; inset: 0; z-index: 7; background: radial-gradient(ellipse at 50% 46%, #fff 0, #fffaf0 55%, #f3e7cc 100%); border: 2px solid #eaa200; overflow: hidden; }
.bsp3d[hidden] { display: none; }
.bsp3d canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; opacity: 0; transition: opacity .35s; }
.bsp3d.is-ready canvas { opacity: 1; }
.bsp3d canvas:active { cursor: grabbing; }
.bsp3d__cap { position: absolute; right: 16px; top: 16px; text-align: right; font: 800 17px/1.2 PreviewFont, Manrope, sans-serif; color: #1a1a1a; pointer-events: none; }
.bsp3d__cap small { display: block; margin-top: 3px; font-weight: 600; font-size: 13px; color: #6f6758; }
.bsp3d__logo { position: absolute; left: 14px; top: 14px; width: 170px; height: auto; pointer-events: none; }
.bsp3d__bar { position: absolute; left: 12px; right: 12px; bottom: 12px; display: flex; align-items: center; gap: 8px; }
.bsp3d__bar button { padding: 8px 14px !important; border-radius: 999px !important; border: 1.5px solid #1a1a1a !important; background: #fff !important; color: #1a1a1a !important; font: 700 13px/1 PreviewFont, Manrope, sans-serif !important; cursor: pointer; white-space: nowrap; }
.bsp3d__bar button:hover { border-color: #eaa200 !important; }
.bsp3d__or { display: inline-flex; }
.bsp3d__or button { border-radius: 0 !important; }
.bsp3d__or button:first-child { border-radius: 999px 0 0 999px !important; border-right-width: 0 !important; }
.bsp3d__or button:last-child { border-radius: 0 999px 999px 0 !important; }
.bsp3d__or button[aria-pressed="true"] { background: #1a1a1a !important; color: #eaa200 !important; }
.bsp3d__hint { flex: 1; text-align: center; font: 600 12px/1.2 PreviewFont, Manrope, sans-serif; color: #8a8070; pointer-events: none; }
/* мелкая раскладка — по ширине самого окна 3D, а не экрана */
@container (max-width: 420px) {
	.bsp3d__logo { width: 120px; left: 10px; top: 10px; }
	.bsp3d__bar button { padding: 7px 11px !important; font-size: 12px !important; }
	.bsp3d__cap { font-size: 14px; right: 12px; top: 12px; } .bsp3d__cap small { font-size: 11px; }
	.bsp3d__hint { font-size: 11px; }
}
@container (max-width: 330px) {
	.bsp3d__logo { width: 92px; } .bsp3d__hint { display: none; } .bsp3d__cap { font-size: 13px; }
}
@media (max-width: 480px) { .bsp3d-open { font-size: 13px !important; } }
/* миниатюры — всегда в одну строку (07.10: с паспортом и «3D» их стало 9 и девятая уходила вниз); больше — сжимаются */
body.bsp3d-card .flex-control-thumbs { flex-wrap: nowrap !important; gap: 6px !important; }
body.bsp3d-card .flex-control-thumbs li { flex: 1 1 0 !important; min-width: 0 !important; max-width: 50px; width: auto !important; }
