/**
 * Netsa Tool front-end popup modal.
 */

.wptools-popup-root {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	box-sizing: border-box;
}

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

.wptools-popup-overlay {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.55);
}

.wptools-popup-dialog {
	position: relative;
	z-index: 1;
	display: grid;
	width: min(920px, 100%);
	max-height: min(90vh, 640px);
	background: #fff;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 24px 64px rgba(15, 23, 42, 0.28);
}

.wptools-popup--two_column {
	grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
}

.wptools-popup--one_column {
	grid-template-columns: 1fr;
	width: min(520px, 100%);
}

.wptools-popup--one_column .wptools-popup-media {
	min-height: 0;
	max-height: 240px;
}

.wptools-popup--one_column .wptools-popup-media--empty {
	display: none;
}

.wptools-popup-close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 999px;
	background: #fff;
	color: #1d2327;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

.wptools-popup-close:hover,
.wptools-popup-close:focus {
	background: #f3f4f6;
	outline: none;
}

.wptools-popup-media {
	background: linear-gradient(160deg, #fff7db 0%, #ffe8a3 55%, #fff 100%);
	min-height: 220px;
	display: flex;
	align-items: stretch;
	justify-content: center;
	overflow: hidden;
}

.wptools-popup-media__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.wptools-popup-body {
	padding: 28px 28px 24px;
	display: flex;
	flex-direction: column;
	gap: 16px;
	overflow: auto;
}

.wptools-popup-content {
	color: #1d2327;
	font-size: 15px;
	line-height: 1.55;
}

.wptools-popup-content > *:first-child {
	margin-top: 0;
}

.wptools-popup-content > *:last-child {
	margin-bottom: 0;
}

.wptools-popup-cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	align-self: stretch;
	min-height: 48px;
	padding: 12px 22px;
	border-radius: 999px;
	background: #ffd200;
	color: #111;
	font-weight: 700;
	text-decoration: none;
	text-align: center;
	letter-spacing: 0.02em;
	transition: filter 0.15s ease, transform 0.15s ease;
}

.wptools-popup-cta:hover,
.wptools-popup-cta:focus {
	filter: brightness(0.96);
	color: #111;
	outline: none;
}

@media (max-width: 720px) {
	.wptools-popup--two_column {
		grid-template-columns: 1fr;
		max-height: 92vh;
	}

	.wptools-popup--one_column {
		max-height: 92vh;
	}

	.wptools-popup-media {
		min-height: 160px;
		max-height: 200px;
	}

	.wptools-popup--one_column .wptools-popup-media {
		min-height: 0;
	}

	.wptools-popup-body {
		padding: 20px 18px 18px;
	}
}
