.ep-gift-promotions {
	display: grid;
	gap: 8px;
	margin: 0;
	max-width: none;
	width: 100%;
}

.ep-gift-promo {
	align-items: center;
	background: #f2faf7;
	border: 1px solid #b9e4d5;
	border-radius: 12px;
	color: #15201c;
	cursor: pointer;
	display: flex;
	gap: 10px;
	min-height: 52px;
	overflow: hidden;
	padding: 8px 12px;
	position: relative;
	text-align: left;
	width: 100%;
}

.ep-gift-promo:hover {
	border-color: var(--wd-primary-color, #34d399);
}

.ep-gift-promo--random {
	background: #fff;
	border-color: #d9dedc;
	min-height: 72px;
	padding: 11px 16px;
}

.ep-gift-promo--random:hover {
	background: #f8fcfa;
}

.ep-gift-promo--random .ep-gift-promo__copy {
	gap: 1px;
}

.ep-gift-promo--random .ep-gift-promo__copy small {
	color: #6b7470;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .04em;
	text-transform: uppercase;
}

.ep-gift-promo--random .ep-gift-promo__copy strong {
	font-size: 15px;
	line-height: 1.25;
}

.ep-gift-promo--random .ep-gift-promo__copy span {
	color: #6d37db;
	font-size: 12px;
	font-weight: 700;
}

.ep-gift-promo__gift-icon,
.ep-gift-dialog__gift-icon {
	background: #f0eaff;
	border: 2px solid #7442df;
	border-radius: 8px;
	box-sizing: border-box;
	display: block;
	flex: 0 0 auto;
	height: 38px;
	position: relative;
	width: 42px;
}

.ep-gift-promo__gift-icon::before,
.ep-gift-dialog__gift-icon::before {
	background: #7442df;
	content: "";
	height: 100%;
	left: 50%;
	position: absolute;
	top: 0;
	transform: translateX(-50%);
	width: 5px;
}

.ep-gift-promo__gift-icon::after,
.ep-gift-dialog__gift-icon::after {
	background: #f0eaff;
	border: 2px solid #7442df;
	border-radius: 6px;
	box-sizing: border-box;
	content: "";
	height: 10px;
	left: -5px;
	position: absolute;
	top: 7px;
	width: 48px;
}

.ep-gift-promo:focus-visible,
.ep-gift-dialog button:focus-visible {
	outline: 2px solid #15201c;
	outline-offset: 2px;
}

.ep-gift-promo--banner,
button.ep-gift-promo--banner {
	background: #fff !important;
	border: 0;
	border-radius: 10px;
	box-shadow: none !important;
	display: block;
	margin-inline: 0;
	min-height: 0;
	overflow: visible;
	padding: 0 !important;
	transform: scale(1);
	transition: transform 180ms ease;
	width: 100%;
}

.ep-gift-promo__banner {
	aspect-ratio: 1280 / 427;
	border-radius: inherit;
	display: block;
	height: auto;
	overflow: visible;
	width: 100%;
}

.ep-gift-promo__banner img {
	box-shadow: none !important;
	display: block;
	height: auto !important;
	margin: 0;
	max-height: none !important;
	max-width: 100%;
	object-fit: fill;
	object-position: center;
	transform: none;
	width: 100% !important;
}

.ep-gift-promo--banner:hover,
.ep-gift-promo--banner:focus-visible {
	transform: scale(1.012);
}

.ep-gift-promo--banner .ep-gift-promo__copy {
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	height: 1px;
	overflow: hidden;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

.ep-gift-promo__copy {
	display: grid;
	min-width: 0;
}

.ep-gift-promo__copy strong,
.ep-gift-promo__copy small {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ep-gift-promo__copy small {
	color: #64706b;
	font-size: 12px;
}

.ep-gift-promo__arrow {
	border-right: 2px solid currentColor;
	border-top: 2px solid currentColor;
	height: 9px;
	margin-left: auto;
	transform: rotate(45deg);
	width: 9px;
}

.ep-gift-dialog[hidden] {
	display: none;
}

.ep-gift-dialog {
	inset: 0;
	isolation: isolate;
	position: fixed !important;
	z-index: 2147483000 !important;
}

.ep-gift-dialog__backdrop {
	background: rgba(8, 15, 13, 0.58);
	inset: 0;
	opacity: 1;
	position: absolute;
	transition: opacity 220ms ease;
	z-index: 0;
}

.ep-gift-dialog__panel {
	background: #fff;
	border: 1px solid #dce4e1;
	border-radius: 18px;
	box-shadow: 0 24px 70px rgba(0, 0, 0, 0.2);
	left: 50%;
	max-height: min(780px, calc(100vh - 40px));
	max-width: 540px;
	opacity: 1;
	overflow: auto;
	position: absolute;
	top: 50%;
	transform: translate(-50%, -50%) scale(1);
	transition: opacity 220ms ease, transform 240ms cubic-bezier(.2, .8, .2, 1);
	width: calc(100% - 32px);
	z-index: 1;
}

.ep-gift-dialog[data-state="opening"] .ep-gift-dialog__backdrop,
.ep-gift-dialog[data-state="closing"] .ep-gift-dialog__backdrop {
	opacity: 0;
}

.ep-gift-dialog[data-state="opening"] .ep-gift-dialog__panel,
.ep-gift-dialog[data-state="closing"] .ep-gift-dialog__panel {
	opacity: 0;
	transform: translate(-50%, calc(-50% + 18px)) scale(.965);
}

.ep-gift-dialog__panel > header {
	align-items: center;
	border-bottom: 1px solid #dde4e1;
	display: flex;
	gap: 16px;
	justify-content: space-between;
	padding: 18px 22px;
}

.ep-gift-dialog__panel h2 {
	font-size: 21px;
	line-height: 1.25;
	margin: 0;
}

.ep-gift-dialog__panel header button {
	align-items: center;
	background: #f1f5f3;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	display: flex;
	font-size: 24px;
	height: 44px;
	justify-content: center;
	width: 44px;
}

.ep-gift-dialog__body {
	display: grid;
	gap: 16px;
	padding: 20px 22px 22px;
}

.ep-gift-dialog__gift {
	align-items: center;
	background: #f2faf7;
	border: 1px solid #d8eee6;
	border-radius: 14px;
	display: flex;
	gap: 14px;
	padding: 14px;
}

.ep-gift-dialog__gift-image {
	background: #fff;
	border-radius: 10px;
	display: block;
	flex: 0 0 82px;
	height: 82px;
	object-fit: contain;
	width: 82px;
}

.ep-gift-dialog__gift-icon {
	height: 62px;
	margin: 8px 14px;
	width: 68px;
}

.ep-gift-dialog__gift div {
	display: grid;
	gap: 3px;
}

.ep-gift-dialog__gift span {
	color: #65716c;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.ep-gift-dialog__gift b,
.ep-gift-dialog__content strong {
	color: #079669;
}

.ep-gift-dialog__content h3 {
	font-size: 20px;
	margin-bottom: 10px;
}

.ep-gift-dialog__content {
	color: #46524d;
	font-size: 15px;
	line-height: 1.55;
}

.ep-gift-dialog__content p {
	margin-block: 0;
}

.ep-gift-dialog__content > :first-child {
	margin-top: 0;
}

.ep-gift-dialog__content > :last-child {
	margin-bottom: 0;
}

.ep-gift-dialog__conditions {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 8px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.ep-gift-dialog__conditions li {
	background: #f5f8f7;
	border-radius: 10px;
	display: grid;
	gap: 2px;
	min-width: 0;
	padding: 11px 10px;
}

.ep-gift-dialog__conditions strong {
	color: #15201c;
	font-size: 13px;
	line-height: 1.25;
}

.ep-gift-dialog__conditions li > span {
	color: #6b7470;
	font-size: 11px;
	line-height: 1.3;
}

.ep-gift-dialog[data-state="open"] .ep-gift-dialog__gift {
	animation: ep-gift-dialog-card-in 360ms cubic-bezier(.2, .8, .2, 1) 60ms both;
}

.ep-gift-dialog[data-state="open"] .ep-gift-dialog__content,
.ep-gift-dialog[data-state="open"] .ep-gift-dialog__conditions {
	animation: ep-gift-dialog-content-in 340ms ease 110ms both;
}

@keyframes ep-gift-dialog-card-in {
	from { opacity: 0; transform: translateY(8px); }
	to { opacity: 1; transform: translateY(0); }
}

@keyframes ep-gift-dialog-content-in {
	from { opacity: 0; transform: translateY(6px); }
	to { opacity: 1; transform: translateY(0); }
}

.ep-gift-dialog-open {
	overflow: hidden;
}

.ep-promo-gift__free {
	color: #079669;
	font-style: normal;
	font-weight: 800;
	letter-spacing: 0.02em;
}

.ep-promo-gift__quantity {
	color: #26312d;
	font-size: 13px;
	font-weight: 600;
	white-space: nowrap;
}

.ep-promo-gift-item {
	animation: ep-promo-gift-reveal 520ms cubic-bezier(.2, .8, .2, 1) both;
	background: #f5fbf8;
}

.ep-promo-gift-item > td,
.ep-promo-gift-item .product-info,
.ep-promo-gift-item .wd-entities-title {
	background: #f5fbf8;
}

.ep-promo-gift-item > td:first-child {
	border-radius: 12px 0 0 12px;
}

.ep-promo-gift-item > td:last-child {
	border-radius: 0 12px 12px 0;
}

.ep-promo-gift__visual {
	align-items: center;
	background: transparent;
	border: 0;
	border-radius: 0;
	display: inline-flex;
	height: 56px;
	justify-content: center;
	position: relative;
	vertical-align: middle;
	width: 56px;
}

.ep-promo-gift__visual::before {
	background: radial-gradient(circle, rgba(116, 66, 223, .12), transparent 68%);
	content: "";
	height: 60px;
	position: absolute;
	width: 60px;
}

.ep-promo-gift__image {
	background: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	display: block;
	height: 54px !important;
	max-height: none !important;
	max-width: none !important;
	object-fit: contain;
	position: relative;
	transform-origin: 50% 70%;
	width: 54px !important;
	z-index: 1;
}

.ep-promo-gift__identity {
	align-items: center;
	display: inline-flex;
	max-width: 100%;
	line-height: 1.25;
	white-space: nowrap;
}

.ep-promo-gift__badge {
	background: #e6f8f1;
	border-radius: 999px;
	color: #078661;
	display: inline-flex;
	font-size: 10px;
	font-weight: 800;
	letter-spacing: .04em;
	margin: 0;
	padding: 3px 7px;
	text-transform: uppercase;
	white-space: nowrap;
}

.ep-promo-gift__name {
	color: #26312d;
	display: inline-block;
	font-size: 14px;
	font-weight: 400;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ep-promo-gift__name strong {
	font-weight: 700;
}

.ep-promo-gift-item .variation {
	display: none;
}

/* Full cart: one quiet row, without a second card around the gift image. */
.woocommerce-cart-form .ep-promo-gift-item > td {
	padding-bottom: 10px;
	padding-top: 10px;
}

.woocommerce-cart-form .ep-promo-gift-item .product-thumbnail > a,
.woocommerce-cart-form .ep-promo-gift-item .product-thumbnail .ep-promo-gift__visual {
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	padding: 0 !important;
}

.woocommerce-cart-form .ep-promo-gift-item .ep-promo-gift__identity {
	flex-wrap: nowrap;
}

.woocommerce-cart-form .ep-promo-gift-item .ep-promo-gift__name {
	line-height: 1.3;
}

/* Keep the final cart column away from the card edge as one aligned unit. */
@media (min-width: 768px) {
	body.woocommerce-cart .woocommerce-cart-form th.product-subtotal,
	body.woocommerce-cart .woocommerce-cart-form td.product-subtotal {
		box-sizing: border-box;
		padding-inline-end: 20px;
	}
}

/* Checkout: the gift is informational and must not compete with cart items. */
.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod {
	min-height: 54px;
	padding-bottom: 7px;
	padding-top: 7px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod-img {
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	flex: 0 0 38px;
	margin-inline-end: 7px;
	padding: 0 !important;
	width: 38px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__visual {
	height: 38px;
	width: 38px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__image {
	height: 36px !important;
	width: 36px !important;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod-cont {
	align-items: center;
	gap: 8px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod-title {
	min-width: 0;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__identity {
	display: flex;
	flex-wrap: nowrap;
	gap: 6px;
	overflow: hidden;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__badge {
	font-size: 7.5px;
	padding: 2px 5px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__name {
	font-size: 12px;
	font-weight: 650;
	line-height: 1.25;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .ep-promo-gift__quantity--checkout {
	display: block;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.4;
	margin-top: 2px;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod-total {
	flex: 0 0 auto;
}

.woocommerce-checkout-review-order-table .ep-promo-gift-item .wd-checkout-prod-total .ep-promo-gift__free {
	font-size: 14px;
	line-height: .98;
}

/* WoodMart AJAX mini-cart: keep the gift visible without creating a large card. */
.cart-widget-side .ep-promo-gift-item,
.woocommerce-mini-cart .ep-promo-gift-item {
	min-height: 70px;
	padding-bottom: 8px;
	padding-top: 8px;
}

/* The child-theme mini-cart rows are intentionally roomy; the generated gift
 * is a compact informational line and does not need the full product height. */
.cart-widget-side .woocommerce-mini-cart > .mini_cart_item.ep-promo-gift-item {
	min-height: 82px;
	padding-bottom: 8px;
	padding-top: 8px;
}

.cart-widget-side .ep-promo-gift-item .cart-item-image,
.woocommerce-mini-cart .ep-promo-gift-item .cart-item-image {
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	flex-basis: 42px;
	padding: 0 !important;
	width: 42px;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__visual,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__visual {
	height: 42px;
	width: 42px;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__image,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__image {
	height: 40px !important;
	width: 40px !important;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__identity,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__identity {
	display: flex;
	gap: 4px 6px;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__badge,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__badge {
	font-size: 8px;
	padding: 3px 6px;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__name,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__name {
	font-size: 12px;
}

.cart-widget-side .ep-promo-gift-item .cart-info,
.woocommerce-mini-cart .ep-promo-gift-item .cart-info {
	min-width: 0;
}

.cart-widget-side .ep-promo-gift-item .ep-promo-gift__mini-summary,
.woocommerce-mini-cart .ep-promo-gift-item .ep-promo-gift__mini-summary {
	color: #6f7a76;
	display: block;
	font-size: 11px;
	line-height: 1.3;
	margin-top: 3px;
}

@keyframes ep-promo-gift-reveal {
	0% {
		opacity: 0;
		transform: translateY(8px) scale(.985);
	}
	65% {
		box-shadow: 0 0 0 5px rgba(52, 211, 153, .14);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(52, 211, 153, 0);
		opacity: 1;
		transform: none;
	}
}

.ep-promo-gift-item .ep-promo-gift__visual > img {
	animation: ep-promo-gift-bounce 900ms cubic-bezier(.2, .8, .2, 1) 120ms both;
}

@keyframes ep-promo-gift-bounce {
	0% { opacity: 0; transform: translateY(10px) scale(.72) rotate(-7deg); }
	55% { opacity: 1; transform: translateY(-3px) scale(1.08) rotate(3deg); }
	75% { transform: translateY(1px) scale(.97) rotate(-1deg); }
	100% { opacity: 1; transform: none; }
}

.ep-promo-order-gift {
	color: #079669;
	margin-top: 4px;
}

@media (max-width: 767px) {
	.elementor-element-epopen02 .ep-opening-promo__mobile-line {
		display: block;
	}

	.ep-gift-dialog__panel {
		border-radius: 18px 18px 0 0;
		bottom: 0;
		left: 0;
		max-height: 90vh;
		top: auto;
		transform: translateY(0) scale(1);
		width: 100%;
	}

	.ep-gift-dialog[data-state="opening"] .ep-gift-dialog__panel,
	.ep-gift-dialog[data-state="closing"] .ep-gift-dialog__panel {
		transform: translateY(24px) scale(.985);
	}

	.ep-gift-dialog__body {
		gap: 14px;
		padding: 16px;
	}

	.ep-gift-dialog__panel > header {
		padding: 14px 16px;
	}

	.ep-gift-dialog__panel h2 {
		font-size: 20px;
	}

	.ep-gift-promo--random {
		min-height: 66px;
		padding: 9px 12px;
	}

	.ep-gift-dialog__gift-icon {
		height: 52px;
		margin: 8px;
		width: 56px;
	}

	.ep-gift-dialog__conditions {
		grid-template-columns: 1fr;
	}

	.ep-gift-dialog__conditions li {
		align-items: center;
		grid-template-columns: minmax(95px, auto) 1fr;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ep-gift-promo--banner,
	.ep-gift-dialog__backdrop,
	.ep-gift-dialog__panel,
	.ep-gift-dialog[data-state="open"] .ep-gift-dialog__gift,
	.ep-gift-dialog[data-state="open"] .ep-gift-dialog__content,
	.ep-gift-dialog[data-state="open"] .ep-gift-dialog__conditions,
	.ep-promo-gift-item,
	.ep-promo-gift-item .ep-promo-gift__visual > img {
		animation: none;
		transition: none;
	}
}
