/* Administrator-controlled website promotion modal. */
html {
	overflow-x: clip;
}

body {
	overflow-x: clip;
}

.jd-site-popup {
	position: fixed;
	inset: 0;
	z-index: 10050;
	display: grid;
	place-items: center;
	padding: 24px;
	background: rgba(18, 20, 28, 0.72);
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.18s ease, visibility 0.18s ease;
}

.jd-site-popup[hidden] {
	display: none;
}

.jd-site-popup.is-open {
	opacity: 1;
	visibility: visible;
}

.jd-site-popup__dialog {
	position: relative;
	width: min(560px, calc(100vw - 48px));
	max-width: 100%;
	transform: translateY(14px) scale(0.98);
	transition: transform 0.18s ease;
}

.jd-site-popup__panel {
	width: 100%;
	max-width: 100%;
	max-height: calc(100vh - 48px);
	max-height: calc(100dvh - 48px);
	overflow-x: hidden;
	overflow-y: auto;
	border-radius: 22px;
	background: #fff;
	box-shadow: 0 28px 90px rgba(0, 0, 0, 0.36);
}

.jd-site-popup.is-open .jd-site-popup__dialog {
	transform: translateY(0) scale(1);
}

.jd-site-popup__close {
	position: absolute;
	top: -18px;
	right: -18px;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #1a1713;
	color: #fff;
	box-shadow: 0 8px 26px rgba(0, 0, 0, 0.42);
	cursor: pointer;
	transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.jd-site-popup__close svg {
	position: relative;
	z-index: 1;
	width: 20px;
	height: 20px;
}

.jd-site-popup__close:hover {
	background: var(--jd-accent, #d94d20);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
	transform: scale(1.06);
}

.jd-site-popup__close:focus-visible {
	background: var(--jd-accent, #d94d20);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
	transform: scale(1.06);
}

.jd-site-popup__action:focus-visible {
	outline: 2px solid #1a1713;
	outline-offset: 3px;
}

.jd-site-popup__image {
	margin: 0;
	background: #f4f1eb;
}

.jd-site-popup__image img {
	display: block;
	width: 100%;
	max-width: 100%;
	max-height: min(52vh, 480px);
	height: auto;
	object-fit: contain;
}

.jd-site-popup__body {
	padding: 28px 30px 32px;
	text-align: center;
}

.jd-site-popup__panel--text-only .jd-site-popup__body {
	padding-top: 28px;
}

.jd-site-popup__description {
	margin: 0;
	font-size: 18px;
	line-height: 1.6;
	color: #332f29;
	overflow-wrap: anywhere;
}

.jd-site-popup__action {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	margin-top: 22px;
	padding: 12px 24px;
	border-radius: 999px;
	background: var(--jd-accent, #d94d20);
	color: #fff;
	font-weight: 800;
	text-decoration: none;
	max-width: 100%;
	white-space: normal;
	text-align: center;
}

.jd-site-popup__action:hover {
	color: #fff;
	filter: brightness(0.92);
}

body.jd-popup-open {
	overflow-x: clip;
	overflow-y: hidden;
}

@media (max-width: 600px) {
	.jd-site-popup {
		padding: 16px;
	}

	.jd-site-popup__dialog {
		width: 100%;
	}

	.jd-site-popup__panel {
		max-height: calc(100vh - 32px);
		max-height: calc(100dvh - 32px);
		border-radius: 18px;
	}

	.jd-site-popup__image img {
		max-height: min(42dvh, 360px);
	}

	.jd-site-popup__body {
		padding: 20px 18px 22px;
	}

	.jd-site-popup__panel--text-only .jd-site-popup__body {
		padding-top: 64px;
	}

	.jd-site-popup__close {
		top: 8px;
		right: 8px;
		width: 44px;
		height: 44px;
		background: #1a1713;
		box-shadow: 0 7px 20px rgba(0, 0, 0, 0.38);
	}

	.jd-site-popup__description {
		font-size: 16px;
		line-height: 1.5;
		overflow-wrap: anywhere;
	}

	.jd-site-popup__action {
		width: 100%;
		min-height: 48px;
	}
}

@media (max-width: 600px) and (max-height: 700px) {
	.jd-site-popup__image img {
		max-height: 32dvh;
	}

	.jd-site-popup__body {
		padding: 16px 18px 18px;
	}

	.jd-site-popup__panel--text-only .jd-site-popup__body {
		padding-top: 60px;
	}

	.jd-site-popup__action {
		margin-top: 14px;
	}
}

@media (max-height: 500px) and (orientation: landscape) {
	.jd-site-popup {
		padding: 16px;
	}

	.jd-site-popup__dialog {
		width: min(560px, calc(100vw - 32px));
	}

	.jd-site-popup__panel {
		max-height: calc(100vh - 32px);
		max-height: calc(100dvh - 32px);
		border-radius: 18px;
	}

	.jd-site-popup__close {
		top: 8px;
		right: 8px;
		width: 44px;
		height: 44px;
		background: #1a1713;
		box-shadow: 0 7px 20px rgba(0, 0, 0, 0.38);
	}

	.jd-site-popup__image img {
		max-height: 26dvh;
	}

	.jd-site-popup__body {
		padding: 16px 18px 18px;
	}

	.jd-site-popup__panel--text-only .jd-site-popup__body {
		padding-top: 60px;
	}

	.jd-site-popup__description {
		font-size: 16px;
		line-height: 1.5;
	}

	.jd-site-popup__action {
		width: 100%;
		min-height: 48px;
		margin-top: 14px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.jd-site-popup,
	.jd-site-popup__dialog {
		transition: none;
	}
}
