.mmpo-overlay {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	background: rgba( 0, 0, 0, var( --mmpo-overlay, 0.55 ) );
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.25s ease;
}

.mmpo-overlay[hidden] {
	display: none;
}

.mmpo-overlay.mmpo-visible {
	opacity: 1;
	visibility: visible;
}

.mmpo-popup {
	position: relative;
	width: 100%;
	max-width: 440px;
	background: #fff;
	border-radius: 20px 20px 0 0;
	box-shadow: 0 -8px 30px rgba( 0, 0, 0, 0.25 );
	overflow: hidden;
	transform: translateY(100%);
	transition: transform 0.3s cubic-bezier( 0.32, 0.72, 0, 1 );
	font-family: inherit;
	color: var( --mmpo-text, #1a1a2e );
}

.mmpo-overlay.mmpo-visible .mmpo-popup {
	transform: translateY(0);
}

.mmpo-close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	width: 30px;
	height: 30px;
	border: none;
	border-radius: 50%;
	background: rgba( 255, 255, 255, 0.9 );
	box-shadow: 0 1px 4px rgba( 0, 0, 0, 0.2 );
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	color: #333;
}

.mmpo-close:hover {
	background: #fff;
}

.mmpo-image {
	width: 100%;
	height: 180px;
	background-size: cover;
	background-position: center;
}

.mmpo-body {
	padding: 22px 22px 26px;
	text-align: center;
}

.mmpo-headline {
	margin: 0 0 8px;
	font-size: 22px;
	font-weight: 700;
	line-height: 1.25;
}

.mmpo-subheading {
	margin: 0 0 18px;
	font-size: 14px;
	line-height: 1.5;
	color: rgba( 26, 26, 46, 0.75 );
}

.mmpo-field-row {
	display: flex;
	gap: 8px;
	margin-bottom: 12px;
}

.mmpo-country {
	flex: 0 0 auto;
	max-width: 108px;
	padding: 0 8px;
	border: 1px solid #d8d8de;
	border-radius: 8px;
	background: #fff;
	font-size: 14px;
	height: 46px;
}

.mmpo-phone {
	flex: 1 1 auto;
	min-width: 0;
	height: 46px;
	padding: 0 14px;
	border: 1px solid #d8d8de;
	border-radius: 8px;
	font-size: 15px;
}

.mmpo-phone:focus,
.mmpo-country:focus {
	outline: none;
	border-color: var( --mmpo-accent, #1a1a2e );
}

.mmpo-error {
	margin: -4px 0 10px;
	font-size: 12px;
	color: #c0392b;
	text-align: left;
}

.mmpo-submit,
.mmpo-announcement-btn {
	display: block;
	width: 100%;
	height: 48px;
	line-height: 48px;
	border: none;
	border-radius: 8px;
	background: var( --mmpo-accent, #1a1a2e );
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.02em;
	cursor: pointer;
	text-decoration: none;
	text-align: center;
	box-sizing: border-box;
}

.mmpo-submit:hover,
.mmpo-announcement-btn:hover {
	opacity: 0.92;
	color: #fff;
}

.mmpo-submit:disabled {
	opacity: 0.6;
	cursor: default;
}

.mmpo-consent,
.mmpo-footer-text {
	margin: 12px 0 0;
	font-size: 11px;
	color: rgba( 26, 26, 46, 0.55 );
}

.mmpo-state-success .mmpo-headline {
	margin-bottom: 16px;
}

.mmpo-code-box {
	display: flex;
	align-items: center;
	justify-content: space-between;
	border: 1px dashed var( --mmpo-accent, #1a1a2e );
	border-radius: 8px;
	padding: 12px 16px;
	background: rgba( 0, 0, 0, 0.02 );
}

.mmpo-code {
	font-size: 18px;
	font-weight: 700;
	letter-spacing: 0.06em;
}

.mmpo-copy {
	border: 1px solid var( --mmpo-accent, #1a1a2e );
	background: transparent;
	color: var( --mmpo-accent, #1a1a2e );
	border-radius: 6px;
	padding: 6px 12px;
	font-size: 12px;
	font-weight: 600;
	cursor: pointer;
}

.mmpo-copy.mmpo-copied {
	background: var( --mmpo-accent, #1a1a2e );
	color: #fff;
}

/* Desktop: centered modal instead of a bottom sheet */
@media ( min-width: 783px ) {
	.mmpo-overlay {
		align-items: center;
	}

	.mmpo-popup {
		max-width: 480px;
		border-radius: 16px;
		transform: translateY(16px) scale( 0.98 );
		opacity: 0;
		transition: transform 0.25s ease, opacity 0.25s ease;
	}

	.mmpo-overlay.mmpo-visible .mmpo-popup {
		transform: translateY(0) scale(1);
		opacity: 1;
	}

	.mmpo-image {
		height: 200px;
	}

	.mmpo-body {
		padding: 28px 32px 32px;
	}
}
