/* Okno "Dodano do koszyka": na telefonie arkusz od dołu z przyciemnionym tłem, na
   komputerze okienko 400 px pod nagłówkiem, bez tła. Wartości w px, bo html ma na
   tej stronie font-size 10px. */
.dl-added-backdrop {
	position: fixed;
	inset: 0;
	z-index: 1150;
	background: rgba(0, 0, 0, 0.6);
	touch-action: none;
}

.dl-added {
	position: fixed;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 1160;
	box-sizing: border-box;
	max-height: calc(100dvh - 16px);
	padding: 20px 16px calc(12px + env(safe-area-inset-bottom, 0px));
	overflow-y: auto;
	overscroll-behavior: contain;
	border-top: 1px solid var(--gold-30);
	border-radius: 16px 16px 0 0;
	background: var(--black-card);
	box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.45);
	color: var(--white);
	font-size: 15px;
	line-height: 1.35;
}

.dl-added:focus {
	outline: 0;
}

.dl-added__head {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 17px;
	font-weight: 600;
	line-height: 1.3;
}

.dl-added__check {
	display: grid;
	flex: 0 0 26px;
	place-items: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: var(--gold);
	color: var(--black);
}

.dl-added__check svg {
	width: 15px;
	height: 15px;
}

.dl-added__title {
	flex: 1 1 auto;
	min-width: 0;
}

.dl-added__close {
	all: unset;
	box-sizing: border-box;
	display: grid;
	flex: 0 0 40px;
	place-items: center;
	width: 40px;
	height: 40px;
	margin: -8px -8px -8px auto;
	border-radius: 50%;
	color: var(--gray-light);
	cursor: pointer;
	transition: background-color 0.2s var(--ease, ease), color 0.2s var(--ease, ease);
}

.dl-added__close svg {
	width: 20px;
	height: 20px;
}

.dl-added__close:hover {
	background: var(--white-10);
	color: var(--white);
}

.dl-added__close:focus-visible,
.dl-added__continue:focus-visible,
.dl-added__go:focus-visible {
	outline: 2px solid var(--gold);
	outline-offset: 2px;
}

.dl-added__item {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 16px 0;
	padding: 10px;
	border-radius: var(--radius, 6px);
	background: var(--black-light);
}

.dl-added__item img {
	flex: 0 0 56px;
	width: 56px;
	height: 56px;
	border-radius: 4px;
	background: var(--white);
	object-fit: cover;
}

.dl-added__text {
	min-width: 0;
}

.dl-added__name {
	color: var(--white);
	font-size: 15px;
	line-height: 1.35;
}

.dl-added__price {
	margin-top: 2px;
	color: var(--gold);
	font-size: 15px;
	font-weight: 700;
}

.dl-added__actions {
	display: grid;
	gap: 4px;
}

.dl-added__head + .dl-added__actions {
	margin-top: 16px;
}

.dl-added__go {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 12px 24px;
	border: 2px solid var(--gold);
	border-radius: var(--radius, 6px);
	background: var(--gold);
	color: var(--black);
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 0.08em;
	line-height: 1.25;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	transition: background-color 0.35s var(--ease, ease), border-color 0.35s var(--ease, ease);
}

.dl-added__go:hover {
	border-color: var(--gold-light);
	background: var(--gold-light);
	color: var(--black);
}

.dl-added__continue {
	all: unset;
	box-sizing: border-box;
	justify-self: center;
	min-height: 44px;
	padding: 0 12px;
	color: var(--gray-light);
	font-size: 15px;
	line-height: 44px;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

.dl-added__continue:hover {
	color: var(--white);
}

@media (min-width: 768px) {
	.dl-added-backdrop {
		display: none;
	}

	.dl-added {
		top: calc(var(--header-h, 80px) + 16px);
		right: 24px;
		bottom: auto;
		left: auto;
		width: 400px;
		max-height: calc(100dvh - var(--header-h, 80px) - 32px);
		padding: 16px;
		border: 1px solid var(--gold-30);
		border-radius: 12px;
		box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
	}

	.dl-added__go {
		min-height: 52px;
	}
}

html.dl-added-lock,
html.dl-added-lock body {
	overflow: hidden;
}

html.dl-added-pending .woocommerce-message:has(> .wc-forward),
body .woocommerce-message.dl-added-source {
	display: none !important;
}

html.dl-added-ready .added_to_cart.wc-forward {
	display: none !important;
}

@media (prefers-reduced-motion: no-preference) {
	.dl-added-backdrop {
		animation: dl-added-fade-in 0.2s ease-out both;
	}

	.dl-added {
		animation: dl-added-sheet-in 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
	}

	.dl-added-backdrop.is-closing {
		animation: dl-added-fade-out 0.2s ease-in both;
	}

	.dl-added.is-closing {
		animation: dl-added-sheet-out 0.2s cubic-bezier(0.4, 0, 1, 1) both;
	}

	@media (min-width: 768px) {
		.dl-added {
			animation-name: dl-added-pop-in;
			animation-duration: 0.22s;
		}

		.dl-added.is-closing {
			animation-name: dl-added-pop-out;
			animation-duration: 0.16s;
		}
	}
}

@keyframes dl-added-fade-in {
	from { opacity: 0; }
}

@keyframes dl-added-fade-out {
	to { opacity: 0; }
}

@keyframes dl-added-sheet-in {
	from { transform: translateY(100%); }
}

@keyframes dl-added-sheet-out {
	to { transform: translateY(100%); }
}

@keyframes dl-added-pop-in {
	from {
		opacity: 0;
		transform: translateY(-8px) scale(0.98);
	}
}

@keyframes dl-added-pop-out {
	to {
		opacity: 0;
		transform: translateY(-8px) scale(0.98);
	}
}
