/**
 * PB Exit Pop-up - frontend modal styles.
 */

.pb-exit-popup-overlay {
	position: fixed;
	inset: 0;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	display: none;
	align-items: center;
	justify-content: center;
	background: rgba(15, 23, 42, 0.6);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
	z-index: 999999;
	padding: 20px;
	box-sizing: border-box;
	opacity: 0;
	transition: opacity 0.25s ease;
}

.pb-exit-popup-overlay.pb-visible {
	display: flex;
	opacity: 1;
}

.pb-exit-popup-modal {
	position: relative;
	background: #ffffff;
	color: #1f2937;
	width: 100%;
	max-width: 520px;
	max-height: 90vh;
	overflow-y: auto;
	border-radius: 14px;
	box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
	padding: 40px 36px 36px;
	box-sizing: border-box;
	transform: translateY(12px) scale(0.98);
	transition: transform 0.25s ease;
	animation: pbExitPopIn 0.3s ease forwards;
}

@keyframes pbExitPopIn {
	from {
		transform: translateY(12px) scale(0.98);
		opacity: 0.6;
	}
	to {
		transform: translateY(0) scale(1);
		opacity: 1;
	}
}

.pb-exit-popup-close {
	position: absolute;
	top: 12px;
	right: 12px;
	width: 36px;
	height: 36px;
	line-height: 1;
	font-size: 26px;
	color: #6b7280;
	background: #f3f4f6;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s ease, color 0.2s ease;
	padding: 0;
}

.pb-exit-popup-close:hover,
.pb-exit-popup-close:focus {
	background: #e5e7eb;
	color: #111827;
	outline: none;
}

.pb-exit-popup-content {
	font-size: 16px;
	line-height: 1.6;
}

.pb-exit-popup-content h1,
.pb-exit-popup-content h2,
.pb-exit-popup-content h3 {
	margin-top: 0;
	color: #111827;
}

.pb-exit-popup-content p {
	margin: 0 0 1em;
}

.pb-exit-popup-content img {
	max-width: 100%;
	height: auto;
}

/* CTA button rendered by the [pb_exit_button] shortcode. */
.pb-exit-popup-btn {
	display: inline-block;
	background: #16a34a;
	color: #ffffff;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.2;
	padding: 14px 26px;
	margin-top: 8px;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	text-decoration: none;
	transition: background 0.2s ease, transform 0.1s ease;
}

.pb-exit-popup-btn:hover,
.pb-exit-popup-btn:focus {
	background: #15803d;
	color: #ffffff;
	outline: none;
}

.pb-exit-popup-btn:active {
	transform: translateY(1px);
}

.pb-exit-popup-btn.pb-loading {
	opacity: 0.7;
	cursor: wait;
}

.pb-exit-popup-btn.pb-loading::after {
	content: "";
	display: inline-block;
	width: 14px;
	height: 14px;
	margin-left: 8px;
	vertical-align: -2px;
	border: 2px solid rgba(255, 255, 255, 0.5);
	border-top-color: #ffffff;
	border-radius: 50%;
	animation: pbExitSpin 0.7s linear infinite;
}

@keyframes pbExitSpin {
	to {
		transform: rotate(360deg);
	}
}

body.pb-exit-popup-open {
	overflow: hidden;
}

@media (max-width: 600px) {
	.pb-exit-popup-modal {
		padding: 34px 22px 26px;
		max-width: 100%;
	}
}
