/*! Paparoni — вікно товару: кнопка «Закрити», свайп, місце під шапкою · © 2026 Seganiko — https://seganiko.com */

/* ── Кнопка «Закрити» (27.11.2026): об'ємна червона кулька з бортиком, як кнопки «Обрати».
   Натискається вся кулька й трохи довкола (раніше реагував лише хрестик 25px у центрі). ── */
#yith-quick-view-modal .yith-wcqv-head {
	box-sizing: border-box;
	width: 42px;
	height: 42px;
	padding: 0;
	border-radius: 50%;
	background: linear-gradient(180deg, #ff4b64 0%, #fb1c3b 55%, #e50f2e 100%);
	box-shadow: 0 4px 0 #a3001b, 0 10px 18px -6px rgba(163, 0, 27, .6);
	transition: transform .12s cubic-bezier(.2, .8, .2, 1), box-shadow .12s cubic-bezier(.2, .8, .2, 1);
	-webkit-tap-highlight-color: transparent;
}
/* відблиск зверху — щоб кулька читалась як кнопка */
#yith-quick-view-modal .yith-wcqv-head::before {
	content: '';
	position: absolute;
	left: 22%;
	top: 8%;
	width: 56%;
	height: 34%;
	border-radius: 50%;
	background: linear-gradient(180deg, rgba(255, 255, 255, .5), rgba(255, 255, 255, 0));
	pointer-events: none;
}
#yith-quick-view-modal .yith-wcqv-head a.yith-quick-view-close {
	position: absolute;
	inset: -8px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: auto;
	height: auto;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	color: #fff;
	opacity: 1;
	-webkit-tap-highlight-color: transparent;
}
#yith-quick-view-modal .yith-wcqv-head a.yith-quick-view-close::before { display: none; }
#yith-quick-view-modal .yith-wcqv-head a.yith-quick-view-close svg {
	width: 24px;
	height: 24px;
	stroke-width: 2.6;
	filter: drop-shadow(0 1px 0 rgba(110, 0, 18, .35));
}
#yith-quick-view-modal .yith-wcqv-head:active {
	transform: translateY(3px);
	box-shadow: 0 1px 0 #a3001b, 0 4px 8px -4px rgba(163, 0, 27, .5);
}
@media (hover: hover) {
	#yith-quick-view-modal .yith-wcqv-head:hover {
		transform: translateY(-1px);
		box-shadow: 0 5px 0 #a3001b, 0 14px 22px -8px rgba(163, 0, 27, .6);
	}
	#yith-quick-view-modal .yith-wcqv-head:active {
		transform: translateY(3px);
		box-shadow: 0 1px 0 #a3001b, 0 4px 8px -4px rgba(163, 0, 27, .5);
	}
}
#yith-quick-view-modal .yith-wcqv-head a.yith-quick-view-close:focus-visible { outline: 2px solid #fff; outline-offset: -6px; }

/* ── Телефон/планшет: вікно на весь екран під шапкою сайту.
   Тема ставила вікно на фіксовані 52px від верху. Коли зверху банер «Заклад працює з 12:00»
   і сторінка не прогорнута, шапка опускається нижче й лягала поверх вікна разом із хрестиком.
   Тепер верх вікна = низ шапки (рахує ppc-qv.js у змінну --ppqv-top). ── */
@media screen and (max-width: 768px) {
	html.yith-quick-view-is-open #yith-quick-view-modal {
		top: var(--ppqv-top, 52px) !important;
		height: calc(100% - var(--ppqv-top, 52px)) !important;
	}
	html #yith-quick-view-modal .yith-wcqv-head {
		top: calc(var(--ppqv-top, 52px) + 14px) !important;
		right: 14px !important;
	}
}

/* Під час свайпу вікно їде за пальцем — без анімацій теми (у YITH transition: all .3s). */
#yith-quick-view-modal.ppqv-drag { transition: none !important; box-shadow: -14px 0 28px -6px rgba(22, 25, 34, .28); }
#yith-quick-view-modal.ppqv-anim { transition: left .22s cubic-bezier(.2, .8, .2, 1), right .22s cubic-bezier(.2, .8, .2, 1) !important; }

@media (prefers-reduced-motion: reduce) {
	#yith-quick-view-modal .yith-wcqv-head { transition: none; }
	#yith-quick-view-modal.ppqv-anim { transition: none !important; }
}
