/*
 * Wishlist: the heart on the card and the «Обране» page grid.
 * The header heart and its count are the theme's markup and live in its CSS.
 */

/* Bottom-right of the photo, a white disc with a line heart. */
.gsl-fav {
	position: absolute;
	right: 8px;
	bottom: 8px;
	z-index: 3;
	width: 30px;
	height: 30px;
	/* The theme's touch rule pins every button to 44px; the disc stays a
	   30px circle and the pseudo below keeps the 44px tap area instead. */
	min-height: 30px !important;
	aspect-ratio: 1;
	padding: 0;
	line-height: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 0;
	border-radius: 50%;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--muted);
	box-shadow: 0 1px 6px color-mix(in srgb, var(--wp--preset--color--ink) 18%, transparent);
	cursor: pointer;
	transition: transform 0.12s, color 0.12s;
}

.gsl-fav::after {
	content: "";
	position: absolute;
	inset: -7px;
	border-radius: 50%;
}

.gsl-fav:hover {
	color: var(--wp--preset--color--gold-text);
	transform: scale(1.08);
}

.gsl-fav.is-on {
	color: var(--wp--preset--color--gold-text);
}

.gsl-fav.is-on svg {
	fill: var(--wp--preset--color--gold);
	stroke: var(--wp--preset--color--gold-text);
}

/* ---------------------------------------------------------------- page ---- */
/* Картки сіткою, як у каталозі, а не рядками (28.09.2026): обране
   перебирають очима, а очі шукають фото. Згори — «Усе в кошик · сума». */
.gsl-wishlist {
	margin-block: var(--wp--preset--spacing--40);
}

.gsl-wishlist__bar {
	margin: 0 0 12px;
}

.gsl-wishlist__all {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 48px;
	padding: 0 20px;
	border: 0;
	border-radius: var(--wp--custom--radius--small);
	background: var(--wp--preset--color--gold);
	color: var(--wp--preset--color--ink);
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.gsl-wishlist__all:hover {
	background: var(--wp--preset--color--gold-hover);
}

.gsl-wishlist__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

@media (min-width: 783px) {
	.gsl-wishlist__bar {
		max-width: 360px;
	}

	.gsl-wishlist__grid {
		grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
		gap: 14px;
	}
}

.gsl-wishlist__note {
	margin: 12px 0 0;
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--small);
}

.gsl-wishlist__none {
	padding: 28px 20px;
	border-radius: var(--wp--custom--radius--medium);
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--brand-action);
	text-align: center;
}

.gsl-wishlist__nonetitle {
	margin: 10px 0 6px;
	color: var(--wp--preset--color--ink);
	font-size: var(--wp--preset--font-size--medium);
	font-weight: 700;
}

.gsl-wishlist__nonetext {
	margin: 0 auto 16px;
	max-width: 30rem;
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--base);
	line-height: 1.45;
}

.gsl-wishlist__shop {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0 26px;
	border-radius: var(--wp--custom--radius--small);
	background: var(--wp--preset--color--brand-action);
	color: var(--wp--preset--color--base);
	font-weight: 700;
	text-decoration: none;
}

.gsl-wishlist__shop:hover {
	background: var(--wp--preset--color--brand-text);
	color: var(--wp--preset--color--base);
}

.gsl-wl {
	position: relative;
	display: flex;
	flex-direction: column;
	margin: 0;
	border-radius: var(--wp--custom--radius--medium);
	background: var(--wp--preset--color--base);
	box-shadow: 0 2px 10px color-mix(in srgb, var(--wp--preset--color--ink) 8%, transparent);
	overflow: hidden;
}

.gsl-wl__link {
	display: flex;
	flex-direction: column;
	color: var(--wp--preset--color--contrast);
	text-decoration: none;
}

.gsl-wl__img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1;
	object-fit: cover;
	background: var(--wp--preset--color--surface);
}

.gsl-wl__name {
	display: -webkit-box;
	min-height: 2.6em;
	margin: 8px 10px 0;
	overflow: hidden;
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.3;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.gsl-wl__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 6px;
	margin-top: auto;
	padding: 8px 10px 10px;
}

.gsl-wl__price {
	color: var(--wp--preset--color--ink);
	font-size: var(--wp--preset--font-size--medium);
	font-weight: 700;
	white-space: nowrap;
}

.gsl-wl__cart {
	display: inline-flex;
	flex: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: var(--wp--custom--radius--small);
	background: var(--wp--preset--color--gold);
	color: var(--wp--preset--color--ink);
}

.gsl-wl__cart:hover {
	background: var(--wp--preset--color--gold-hover);
}

.gsl-wl__cart--word {
	width: auto;
	padding: 0 10px;
	background: var(--wp--preset--color--brand-wash);
	color: var(--wp--preset--color--brand-text);
	font-size: var(--wp--preset--font-size--label);
	font-weight: 700;
	text-decoration: none;
}

.gsl-wl__cart--word:hover {
	background: var(--wp--preset--color--brand-light);
}

.gsl-wl__gone {
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	line-height: 1.2;
}

.gsl-wl--gone .gsl-wl__img {
	opacity: 0.45;
}

/* Серце в картці обраного — угорі праворуч, де його шукають, щоб прибрати. */
.gsl-fav.gsl-fav--wl {
	top: 8px;
	bottom: auto;
}

/* ---------------------------------------------------------- product page ---- */
/* In the buy form beside the button, on every width (concept 2, owner
   17.09.2026): the theme lays the form out as a grid and names this cell
   «heart». Relative, not static: the base rule's ::after tap zone is
   absolute and would otherwise size itself against the page. */
.gsl-fav--deal {
	grid-area: heart;
	position: relative;
	/* The card heart is pinned bottom-right; here those offsets would shift
	   a relative box 8px up and left. */
	right: auto;
	bottom: auto;
	flex: none;
	width: 50px;
	height: 50px;
	min-height: 50px !important;
	border: 1px solid var(--wp--preset--color--border-strong);
	border-radius: var(--wp--custom--radius--small);
	box-shadow: none;
	color: var(--wp--preset--color--ink);
}

.gsl-fav--deal svg {
	width: 22px;
	height: 22px;
}

.gsl-fav--deal:hover {
	transform: none;
	background: var(--wp--preset--color--brand-wash);
}
