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

.site-popup {
	position: fixed;
	inset: 0;
	z-index: 5000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.site-popup__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.84);
	backdrop-filter: blur(3px);
}

.site-popup__dialog {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	width: min(900px, 92vw);
	max-height: calc(100vh - 48px);
	box-sizing: border-box;
	padding: 12px 12px 18px;
	background: rgba(15, 16, 19, 0.98);
	border: 1px solid rgba(211, 130, 55, 0.68);
	border-radius: 8px;
	box-shadow: 0 28px 80px rgba(0, 0, 0, 0.78), inset 0 0 34px rgba(211, 130, 55, 0.06);
}

.site-popup__dialog:focus {
	outline: 2px solid #d38237;
	outline-offset: 3px;
}

.site-popup__close {
	position: absolute;
	top: -17px;
	right: -17px;
	z-index: 2;
	width: 42px;
	height: 42px;
	padding: 0;
	color: #fff;
	font: 31px/38px Arial, sans-serif;
	background: #171719;
	border: 1px solid #d38237;
	border-radius: 50%;
	box-shadow: 0 5px 18px rgba(0, 0, 0, 0.6);
	cursor: pointer;
}

.site-popup__close:hover,
.site-popup__close:focus {
	color: #f7b877;
	background: #242124;
	outline: none;
}

.site-popup__image-link {
	display: block;
	max-width: 100%;
	line-height: 0;
}

.site-popup__image {
	display: block;
	max-width: 100%;
	max-height: calc(100vh - 130px);
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 4px;
}

.site-popup__dismiss {
	min-height: 40px;
	margin-top: 14px;
	padding: 9px 20px;
	color: #c9b8a5;
	font-size: 14px;
	font-weight: 700;
	line-height: 20px;
	text-align: center;
	background: transparent;
	border: 1px solid rgba(201, 184, 165, 0.45);
	border-radius: 3px;
	cursor: pointer;
}

.site-popup__dismiss:hover,
.site-popup__dismiss:focus {
	color: #fff;
	border-color: #d38237;
	outline: none;
}

body.site-popup-open {
	overflow: hidden;
}

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

	.site-popup__dialog {
		width: 96vw;
		max-height: calc(100vh - 28px);
		padding: 8px 8px 14px;
	}

	.site-popup__image {
		max-height: calc(100vh - 105px);
	}

	.site-popup__close {
		top: -11px;
		right: -8px;
	}
}
