.nyxos-popup[hidden] {
	display: none;
}

.nyxos-popup {
	--nyxos-popup-radius: 18px;
	font-family: var(--nyxos-popup-font, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: grid;
	place-items: center;
	padding: 20px;
}

.nyxos-popup__scrim {
	position: absolute;
	inset: 0;
	background: var(--nyxos-popup-overlay, #111827);
	opacity: var(--nyxos-popup-opacity, .62);
}

.nyxos-popup--blur .nyxos-popup__scrim {
	backdrop-filter: blur(7px);
	-webkit-backdrop-filter: blur(7px);
}

.nyxos-popup__panel {
	position: relative;
	width: min(100%, 520px);
	max-height: min(720px, calc(100vh - 40px));
	overflow: auto;
	background: var(--nyxos-popup-bg, #fff);
	border-radius: var(--nyxos-popup-radius);
	box-shadow: 0 24px 80px rgba(15, 23, 42, .24);
	color: #172033;
}

.nyxos-popup__panel--image-side {
	display: grid;
	grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
	width: min(100%, 820px);
}

.nyxos-popup__panel--image-top,
.nyxos-popup__panel--image-bottom {
	display: flex;
	flex-direction: column;
}

.nyxos-popup__panel--image-bottom .nyxos-popup__image {
	order: 2;
}

.nyxos-popup__panel--image-bottom .nyxos-popup__content {
	order: 1;
}

.nyxos-popup__panel--side-right .nyxos-popup__image {
	grid-column: 2;
	grid-row: 1;
}

.nyxos-popup__panel--side-right .nyxos-popup__content {
	grid-column: 1;
	grid-row: 1;
}

.nyxos-popup__content,
.nyxos-popup__custom {
	padding: clamp(24px, 5vw, 42px);
}

.nyxos-popup__image {
	display: block;
	width: 100%;
	height: auto;
	max-height: 300px;
	object-fit: cover;
}

.nyxos-popup__panel--horizontal .nyxos-popup__image {
	aspect-ratio: 16 / 9;
	max-height: none;
}

.nyxos-popup__panel--vertical .nyxos-popup__image {
	aspect-ratio: 4 / 5;
	max-width: 320px;
	max-height: none;
	margin-inline: auto;
}

.nyxos-popup__panel--contain .nyxos-popup__image {
	object-fit: contain;
	background: #f1f5f9;
}

.nyxos-popup__panel--image-side .nyxos-popup__image {
	height: 100%;
	max-height: 100%;
}

.nyxos-popup__title {
	margin: 0 40px 12px 0;
	font-size: clamp(1.45rem, 4vw, 2rem);
	line-height: 1.15;
}

.nyxos-popup__description {
	margin: 0 0 24px;
	color: #526071;
	line-height: 1.55;
}

.nyxos-popup__close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 1;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(148, 163, 184, .16);
	color: inherit;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.nyxos-popup__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 10px 18px;
	border: 0;
	border-radius: 10px;
	background: var(--nyxos-popup-accent, #2563eb);
	color: #fff;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.nyxos-popup__form {
	display: grid;
	gap: 12px;
	margin-top: 24px;
}

.nyxos-popup__form label {
	display: grid;
	gap: 5px;
	font-size: .875rem;
	font-weight: 600;
}

.nyxos-popup__form .nyxos-popup__consent {
	display: grid;
	grid-template-columns: 18px minmax(0, 1fr);
	align-items: start;
	gap: 8px;
	font-weight: 400;
	line-height: 1.45;
}

.nyxos-popup__form .nyxos-popup__consent input {
	width: 16px;
	height: 16px;
	min-height: 16px;
	max-height: 16px;
	padding: 0;
	margin: 2px 0 0;
}

.nyxos-popup__consent a {
	color: var(--nyxos-popup-accent, #2563eb);
}

.nyxos-popup__consent-links {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 12px;
	margin: -4px 0 0 26px;
	font-size: .875rem;
}

.nyxos-popup__consent-links a {
	color: var(--nyxos-popup-accent, #2563eb);
}

.nyxos-popup__form input {
	box-sizing: border-box;
	width: 100%;
	min-height: 42px;
	padding: 9px 11px;
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	font: inherit;
}

.nyxos-popup__form-status {
	margin: 0;
	font-size: .875rem;
}

html.nyxos-popup-open {
	overflow: hidden;
}

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

	.nyxos-popup__panel {
		max-height: calc(100vh - 24px);
	}

	.nyxos-popup__panel--image-side {
		display: flex;
		flex-direction: column;
	}

	.nyxos-popup__panel--mobile-bottom .nyxos-popup__image {
		order: 2;
	}

	.nyxos-popup__panel--mobile-top .nyxos-popup__image {
		order: 0;
	}

	.nyxos-popup__panel--mobile-top .nyxos-popup__content,
	.nyxos-popup__panel--mobile-bottom .nyxos-popup__content {
		order: 1;
	}

	.nyxos-popup__panel--image-side .nyxos-popup__image {
		height: auto;
		max-height: 300px;
	}

	.nyxos-popup__panel--vertical .nyxos-popup__image {
		max-width: 240px;
	}
}

