.cpc-root,
.cpc-embed-placeholder,
.cpc-noscript {
	--cpc-bg: #fff;
	--cpc-text: #172033;
	--cpc-primary: #2563eb;
	--cpc-primary-text: #fff;
	--cpc-secondary: #eef2ff;
	--cpc-secondary-text: #172033;
	--cpc-overlay: #111827;
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.cpc-root *,
.cpc-root *::before,
.cpc-root *::after,
.cpc-embed-placeholder *,
.cpc-embed-placeholder *::before,
.cpc-embed-placeholder *::after {
	box-sizing: border-box;
}

.cpc-root [hidden],
.cpc-embed-placeholder[hidden],
.cpc-blocked-frame {
	display: none !important;
}

.cpc-banner {
	position: fixed;
	z-index: 2147482000;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	width: 100%;
	max-height: min(90vh, 720px);
	overflow: auto;
	padding: 22px clamp(18px, 4vw, 54px);
	color: var(--cpc-text);
	background: var(--cpc-bg);
	border: 1px solid #d1d5db;
	border-color: color-mix(in srgb, var(--cpc-text) 16%, transparent);
	box-shadow: 0 -8px 30px rgba(15, 23, 42, .15);
	line-height: 1.55;
	direction: inherit;
}

.cpc-position-bottom .cpc-banner {
	left: 0;
	bottom: 0;
}

.cpc-position-top .cpc-banner {
	left: 0;
	top: 0;
	box-shadow: 0 8px 30px rgba(15, 23, 42, .15);
}

body.admin-bar .cpc-position-top .cpc-banner {
	top: 32px;
}

.cpc-position-bottom-left .cpc-banner,
.cpc-position-bottom-right .cpc-banner {
	bottom: 20px;
	width: min(430px, calc(100vw - 32px));
	padding: 24px;
	align-items: stretch;
	flex-direction: column;
	border-radius: 14px;
	box-shadow: 0 20px 55px rgba(15, 23, 42, .24);
}

.cpc-position-bottom-left .cpc-banner {
	left: 20px;
}

.cpc-position-bottom-right .cpc-banner {
	right: 20px;
}

.cpc-position-center .cpc-banner {
	top: 50%;
	left: 50%;
	width: min(590px, calc(100vw - 32px));
	padding: clamp(22px, 4vw, 34px);
	align-items: stretch;
	flex-direction: column;
	transform: translate(-50%, -50%);
	border-radius: 16px;
	box-shadow: 0 25px 70px rgba(0, 0, 0, .34);
}

.cpc-position-center.cpc-banner-visible::before {
	content: "";
	position: fixed;
	inset: 0;
	z-index: 2147481900;
	background: var(--cpc-overlay);
	opacity: .7;
}

.cpc-banner-copy {
	max-width: 850px;
}

.cpc-title {
	margin: 0 0 8px;
	padding: 0;
	color: var(--cpc-text);
	font-size: clamp(20px, 2vw, 25px);
	font-weight: 700;
	line-height: 1.25;
}

.cpc-copy {
	color: var(--cpc-text);
	font-size: 15px;
}

.cpc-copy p {
	margin: 0 0 10px;
}

.cpc-copy p:last-child {
	margin-bottom: 0;
}

.cpc-policy-link {
	display: inline-block;
	margin-top: 8px;
	color: var(--cpc-primary);
	font-size: 14px;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.cpc-banner-actions,
.cpc-modal-actions {
	display: flex;
	flex: 0 0 auto;
	flex-wrap: wrap;
	gap: 9px;
}

.cpc-banner-actions {
	justify-content: flex-end;
	max-width: 480px;
}

.cpc-button,
.cpc-floating-button,
.cpc-shortcode-button,
.cpc-shortcode-link,
.cpc-embed-button,
.cpc-close {
	appearance: none;
	font: inherit;
	cursor: pointer;
}

.cpc-button {
	min-height: 42px;
	padding: 10px 16px;
	border: 2px solid transparent;
	border-radius: 7px;
	font-size: 14px;
	font-weight: 650;
	line-height: 1.2;
	transition: transform .15s ease, filter .15s ease;
}

.cpc-button:hover {
	filter: brightness(.96);
}

.cpc-button:active {
	transform: translateY(1px);
}

.cpc-button-primary {
	color: var(--cpc-primary-text);
	background: var(--cpc-primary);
}

.cpc-button-secondary {
	color: var(--cpc-secondary-text);
	background: var(--cpc-secondary);
	border-color: #cbd5e1;
	border-color: color-mix(in srgb, var(--cpc-secondary-text) 20%, transparent);
}

.cpc-button-link {
	color: var(--cpc-text);
	background: transparent;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.cpc-button:focus-visible,
.cpc-policy-link:focus-visible,
.cpc-close:focus-visible,
.cpc-floating-button:focus-visible,
.cpc-shortcode-button:focus-visible,
.cpc-shortcode-link:focus-visible,
.cpc-embed-button:focus-visible,
.cpc-switch input:focus-visible + .cpc-switch-track {
	outline: 3px solid #60a5fa;
	outline-color: color-mix(in srgb, var(--cpc-primary) 55%, white);
	outline-offset: 3px;
}

.cpc-gpc-notice {
	margin: 10px 0 0;
	padding: 9px 11px;
	color: #713f12;
	background: #fef3c7;
	border-radius: 6px;
	font-size: 13px;
}

.cpc-modal {
	position: fixed;
	inset: 0;
	z-index: 2147483000;
	display: grid;
	place-items: center;
	padding: 18px;
	color: var(--cpc-text);
}

.cpc-modal-overlay {
	position: absolute;
	inset: 0;
	background: var(--cpc-overlay);
	opacity: .72;
}

.cpc-modal-panel {
	position: relative;
	width: min(680px, 100%);
	max-height: min(90vh, 820px);
	overflow: auto;
	padding: clamp(20px, 4vw, 32px);
	background: var(--cpc-bg);
	border-radius: 15px;
	box-shadow: 0 25px 70px rgba(0, 0, 0, .35);
	line-height: 1.5;
}

.cpc-modal-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
}

.cpc-close {
	display: grid;
	flex: 0 0 38px;
	place-items: center;
	width: 38px;
	height: 38px;
	padding: 0;
	color: var(--cpc-text);
	background: var(--cpc-secondary);
	border: 0;
	border-radius: 50%;
	font-size: 27px;
	line-height: 1;
}

.cpc-category-list {
	margin: 22px 0;
	border-top: 1px solid #d1d5db;
	border-top-color: color-mix(in srgb, var(--cpc-text) 14%, transparent);
}

.cpc-category {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	padding: 17px 0;
	border-bottom: 1px solid #d1d5db;
	border-bottom-color: color-mix(in srgb, var(--cpc-text) 14%, transparent);
}

.cpc-category-title {
	display: block;
	margin-bottom: 4px;
	font-size: 16px;
	font-weight: 700;
}

.cpc-category p {
	margin: 0;
	font-size: 13px;
	opacity: .82;
}

.cpc-switch {
	position: relative;
	display: inline-flex;
	flex: 0 0 auto;
	width: 48px;
	height: 27px;
	cursor: pointer;
}

.cpc-switch input {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
}

.cpc-switch-track {
	position: absolute;
	inset: 0;
	background: #94a3b8;
	border-radius: 999px;
	transition: background .16s ease;
}

.cpc-switch-track::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 21px;
	height: 21px;
	background: #fff;
	border-radius: 50%;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
	transition: transform .16s ease;
}

.cpc-switch input:checked + .cpc-switch-track {
	background: var(--cpc-primary);
}

.cpc-switch input:checked + .cpc-switch-track::after {
	transform: translateX(21px);
}

[dir="rtl"] .cpc-switch-track::after {
	left: auto;
	right: 3px;
}

[dir="rtl"] .cpc-switch input:checked + .cpc-switch-track::after {
	transform: translateX(-21px);
}

.cpc-switch input:disabled + .cpc-switch-track {
	opacity: .72;
	cursor: not-allowed;
}

.cpc-floating-button {
	position: fixed;
	right: 18px;
	bottom: 18px;
	z-index: 2147481800;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 13px;
	color: var(--cpc-primary-text);
	background: var(--cpc-primary);
	border: 0;
	border-radius: 999px;
	box-shadow: 0 8px 25px rgba(15, 23, 42, .24);
	font-size: 13px;
	font-weight: 650;
}

.cpc-floating-button-left {
	right: auto;
	left: 18px;
}

.cpc-shortcode-button,
.cpc-shortcode-link {
	color: inherit;
}

.cpc-shortcode-button {
	padding: .55em .85em;
	background: transparent;
	border: 1px solid currentColor;
	border-radius: 5px;
}

.cpc-shortcode-link {
	padding: 0;
	background: transparent;
	border: 0;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.cpc-embed-placeholder {
	display: grid;
	place-items: center;
	width: 100%;
	min-height: 240px;
	padding: 28px;
	color: var(--cpc-text, #172033);
	background:
		linear-gradient(135deg, rgba(37, 99, 235, .08), rgba(99, 102, 241, .13)),
		var(--cpc-bg, #fff);
	border: 1px dashed rgba(71, 85, 105, .48);
	border-radius: 10px;
	text-align: center;
}

.cpc-embed-inner {
	max-width: 520px;
}

.cpc-embed-icon {
	display: grid;
	place-items: center;
	width: 48px;
	height: 48px;
	margin: 0 auto 12px;
	color: var(--cpc-primary, #2563eb);
	background: rgba(255, 255, 255, .8);
	border-radius: 50%;
	font-size: 22px;
}

.cpc-embed-placeholder h3 {
	margin: 0 0 7px;
	font-size: 18px;
}

.cpc-embed-placeholder p {
	margin: 0 0 15px;
	font-size: 14px;
}

.cpc-embed-provider {
	display: block;
	margin-top: 4px;
	font-size: 12px;
	opacity: .7;
}

.cpc-embed-button {
	padding: 10px 15px;
	color: var(--cpc-primary-text, #fff);
	background: var(--cpc-primary, #2563eb);
	border: 0;
	border-radius: 6px;
	font-weight: 650;
}

.cpc-noscript {
	padding: 12px 18px;
	color: #713f12;
	background: #fef3c7;
	font-size: 14px;
	text-align: center;
}

.cpc-noscript a {
	margin-left: 8px;
	color: inherit;
	text-decoration: underline;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

body.cpc-modal-open {
	overflow: hidden;
}

@media (max-width: 782px) {
	body.admin-bar .cpc-position-top .cpc-banner {
		top: 46px;
	}

	.cpc-banner {
		align-items: stretch;
		flex-direction: column;
		gap: 15px;
		padding: 18px;
	}

	.cpc-position-bottom-left .cpc-banner,
	.cpc-position-bottom-right .cpc-banner {
		right: 12px;
		bottom: 12px;
		left: 12px;
		width: auto;
	}

	.cpc-banner-actions {
		display: grid;
		grid-template-columns: 1fr;
		max-width: none;
	}

	.cpc-button {
		width: 100%;
	}

	.cpc-modal-actions {
		display: grid;
	}

	.cpc-category {
		gap: 14px;
	}

	.cpc-floating-label {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cpc-root *,
	.cpc-root *::before,
	.cpc-root *::after {
		scroll-behavior: auto !important;
		transition: none !important;
	}
}
