/* Sunday Smart Personalization — frontend styles. Kept intentionally tiny.
   No fixed pixel widths on mobile; everything uses max-width + internal
   scroll so the page body never overflows horizontally. */

.ssp-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	box-sizing: border-box;
}

.ssp-overlay.ssp-position-top {
	align-items: flex-start;
	padding-top: 24px;
}

.ssp-overlay.ssp-position-bottom-right {
	align-items: flex-end;
	justify-content: flex-end;
}

.ssp-overlay.ssp-position-bottom-left {
	align-items: flex-end;
	justify-content: flex-start;
}

.ssp-popup {
	position: relative;
	background: #fff;
	border-radius: 8px;
	padding: 24px;
	box-sizing: border-box;
	max-width: 92vw;
	max-height: 88vh;
	overflow-y: auto;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
}

.ssp-popup.ssp-width-small { width: 360px; }
.ssp-popup.ssp-width-medium { width: 480px; }
.ssp-popup.ssp-width-large { width: 640px; }

.ssp-popup.ssp-align-left { text-align: left; }
.ssp-popup.ssp-align-center { text-align: center; }
.ssp-popup.ssp-align-right { text-align: right; }

.ssp-popup-title {
	margin: 0 0 8px;
	font-size: 20px;
	line-height: 1.3;
}

.ssp-popup-description {
	margin: 0 0 16px;
	font-size: 14px;
	line-height: 1.5;
}

.ssp-popup-image {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
	margin-bottom: 16px;
}

.ssp-popup-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ssp-cta-btn {
	display: inline-block;
	padding: 10px 18px;
	border-radius: 6px;
	background: #2271b1;
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
}

.ssp-cta-btn.ssp-cta-secondary {
	background: transparent;
	color: #2271b1;
	border: 1px solid #2271b1;
}

.ssp-close-btn {
	position: absolute;
	top: 6px;
	right: 6px;
	width: 44px;
	height: 44px;
	min-width: 44px;
	min-height: 44px;
	border: none;
	background: transparent;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	color: #444;
}

.ssp-close-btn:hover,
.ssp-close-btn:focus {
	color: #000;
}

/* Banner */

.ssp-banner {
	position: fixed;
	left: 0;
	right: 0;
	z-index: 999998;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 44px 12px 16px;
	box-sizing: border-box;
	color: #fff;
	font-size: 14px;
}

.ssp-banner-top { top: 0; }
.ssp-banner-bottom { bottom: 0; }
.ssp-banner-inline { position: relative; }

.ssp-banner-image {
	max-height: 32px;
	width: auto;
}

.ssp-banner-text {
	flex: 1 1 auto;
}

body.ssp-banner-top-active { padding-top: 52px; }
body.ssp-banner-bottom-active { padding-bottom: 52px; }

/* Iframe popup */

.ssp-iframe-popup {
	width: 100%;
	max-width: 720px;
	display: flex;
	flex-direction: column;
}

.ssp-iframe-popup.ssp-width-small { max-width: 400px; }
.ssp-iframe-popup.ssp-width-medium { max-width: 600px; }
.ssp-iframe-popup.ssp-width-large { max-width: 800px; }
.ssp-iframe-popup.ssp-width-full { max-width: 96vw; }

.ssp-iframe {
	width: 100%;
	flex: 1 1 auto;
	border: 0;
	min-height: 300px;
}

.ssp-iframe-loading {
	text-align: center;
	padding: 32px 0;
}

.ssp-iframe-fallback {
	margin-top: 12px;
	text-align: center;
}

.ssp-hidden {
	display: none !important;
}

/* Built-in consent prompt */

.ssp-consent-bar {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 999997;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	padding: 14px 16px;
	background: #1d2327;
	color: #fff;
	font-size: 13px;
}

.ssp-consent-text {
	flex: 1 1 240px;
}

.ssp-consent-accept,
.ssp-consent-decline {
	padding: 8px 16px;
	border-radius: 4px;
	border: 1px solid #fff;
	background: transparent;
	color: #fff;
	cursor: pointer;
	font-size: 13px;
	min-height: 36px;
}

.ssp-consent-accept {
	background: #2271b1;
	border-color: #2271b1;
}

@media (max-width: 480px) {
	.ssp-popup { padding: 18px; }
	.ssp-popup.ssp-width-small,
	.ssp-popup.ssp-width-medium,
	.ssp-popup.ssp-width-large { width: 100%; }
}
