﻿/* Reusable CTA promo: side card + wide banner */

.ml-cta-promo {
	position: relative;
	overflow: hidden;
	box-sizing: border-box;
}

.ml-cta-promo *,
.ml-cta-promo *::before,
.ml-cta-promo *::after {
	box-sizing: border-box;
}

.ml-cta-promo__copy {
	position: relative;
	z-index: 2;
}

.ml-cta-promo__title {
	margin: 0;
	font-family: inherit;
	font-weight: 700;
}

.ml-cta-promo__description p {
	margin: 0;
}

.ml-cta-promo__button {
	position: relative;
	z-index: 4;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: #fff !important;
	font-size: 18px;
	font-weight: 700;
	line-height: 24px;
	text-decoration: none !important;
	transition: filter 0.2s ease, transform 0.2s ease;
}

.ml-cta-promo__button:hover,
.ml-cta-promo__button:focus-visible {
	filter: brightness(1.1);
	transform: translateY(-1px);
	color: #fff !important;
	text-decoration: none !important;
}

/* Side / card variant */

.ml-cta-promo--side {
	display: flex;
	flex: 0 0 auto;
	flex-direction: column;
	gap: 20px;
	padding: 24px;
	border-radius: 16px;
	background: linear-gradient(#010e27 0%, #062a65 133.43%);
	color: #fff;
}

.ml-cta-promo--side .ml-cta-promo__copy {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 20px;
}

.ml-cta-promo--side .ml-cta-promo__title {
	position: relative;
	z-index: 2;
	/* Clears the artwork, which takes the right 45% of the card. */
	max-width: 54%;
	margin: 0;
	hyphens: auto;
	color: #fff;
	font-size: 28px;
	font-weight: 700;
	line-height: 32px;
}

.ml-cta-promo--side .ml-cta-promo__description {
	color: #fff;
	font-size: 16px;
	font-weight: 500;
	line-height: 24px;
}

.ml-cta-promo__list {
	display: grid;
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ml-cta-promo__item {
	position: relative;
	margin: 0;
	padding-left: 24px;
	color: #fff;
	font-size: 14px;
	font-weight: 500;
	line-height: 20px;
}

.ml-cta-promo__item::before {
	position: absolute;
	top: 2px;
	left: 0;
	width: 16px;
	height: 16px;
	background: url(../images/glossary/cta-check.svg) center / contain no-repeat;
	content: "";
}

.ml-cta-promo__side-art {
	position: absolute;
	z-index: 1;
	top: 16px;
	right: 3%;
	width: 42%;
	height: auto;
	pointer-events: none;
}

.ml-cta-promo--side .ml-cta-promo__button {
	width: 100%;
	min-height: 52px;
	margin-top: auto;
	padding: 12px 40px;
	border-radius: 8px;
	background: linear-gradient(90deg, #9747ff 0%, #0165fe 100%);
}

/* Wide / banner
 * Default = compact (blog column ~774px).
 * @container >= 900px = larger full-width / glossary variant.
 */

.ml-cta-promo-scope {
	width: 100%;
	container-type: inline-size;
	container-name: ml-cta;
}

.ml-cta-promo--wide {
	display: flex;
	width: 100%;
	min-height: 240px;
	align-items: center;
	justify-content: center;
	padding: 24px;
	border-radius: 24px;
	background:
		radial-gradient(ellipse at 0% 100%, rgba(150, 71, 219, 0.12) 0%, rgba(150, 71, 219, 0) 55%),
		radial-gradient(ellipse at 100% 100%, rgba(0, 95, 249, 0.12) 0%, rgba(0, 95, 249, 0) 55%),
		#f4f7ff;
}

.ml-cta-promo--wide .ml-cta-promo__copy {
	display: flex;
	width: min(100%, 360px);
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
	padding: 0;
	text-align: center;
}

.ml-cta-promo--wide .ml-cta-promo__title {
	margin: 0;
	color: transparent;
	font-size: 28px;
	font-weight: 700;
	line-height: 32px;
	background: linear-gradient(256deg, #005ff9 0%, #9647db 100%);
	background-clip: text;
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
}

.ml-cta-promo--wide .ml-cta-promo__description {
	color: #333;
	font-size: 16px;
	font-weight: 500;
	line-height: 24px;
}

.ml-cta-promo--wide .ml-cta-promo__description p {
	margin: 0;
	color: inherit;
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
}

.ml-cta-promo__wide-art {
	position: absolute;
	z-index: 1;
	bottom: 0;
	width: auto;
	max-width: none;
	height: 240px;
	object-fit: contain;
	object-position: bottom;
	pointer-events: none;
}

.ml-cta-promo__wide-art--left {
	left: 0;
	object-position: left center;
}

.ml-cta-promo__wide-art--right {
	right: 0;
	left: auto;
	object-position: right center;
}

/* Phones swap the two side artworks for one image under the copy. */
.ml-cta-promo__wide-mobile-art {
	display: none;
}

.ml-cta-promo--wide .ml-cta-promo__button {
	min-height: 40px;
	padding: 8px 20px;
	border-radius: 8px;
	background: linear-gradient(90deg, #9747ff 0%, #005ff9 100%);
	font-size: 18px;
	font-weight: 600;
	line-height: 24px;
}

@container ml-cta (min-width: 900px) {
	.ml-cta-promo--wide {
		min-height: 300px;
		padding: 24px 20px;
		border-radius: 32px;
	}

	.ml-cta-promo--wide .ml-cta-promo__copy {
		width: min(100%, 430px);
		gap: 16px;
	}

	.ml-cta-promo--wide .ml-cta-promo__title {
		font-size: 36px;
		line-height: 40px;
	}

	.ml-cta-promo--wide .ml-cta-promo__description {
		font-size: 20px;
		line-height: 28px;
	}

	.ml-cta-promo--wide .ml-cta-promo__button {
		min-height: 52px;
		padding: 12px 32px;
		border-radius: 12px;
		font-size: 20px;
		line-height: 24px;
	}

	.ml-cta-promo__wide-art {
		height: 300px;
	}
}

/* Pattern banner variant: brand bg + geometric line art, centered copy */

.ml-cta-promo--pattern {
	display: flex;
	width: 100%;
	min-height: 280px;
	align-items: center;
	justify-content: center;
	padding: 40px 24px;
	border-radius: 24px;
	background-color: #e8f0fd;
	background-image: url(../images/glossary/cta-banner-pattern.png);
	background-position: center;
	background-size: cover;
	background-repeat: no-repeat;
}

.ml-cta-promo--pattern .ml-cta-promo__copy {
	display: flex;
	width: min(100%, 680px);
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 24px;
	padding: 0;
	text-align: center;
}

.ml-cta-promo--pattern .ml-cta-promo__title {
	margin: 0;
	color: var(--color-text, #101828);
	font-size: 28px;
	font-weight: 700;
	line-height: 36px;
}

.ml-cta-promo--pattern .ml-cta-promo__title strong,
.ml-cta-promo--pattern .ml-cta-promo__title b {
	color: inherit;
	font-weight: 700;
}

.ml-cta-promo--pattern .ml-cta-promo__description {
	color: #333;
	font-size: 16px;
	font-weight: 500;
	line-height: 24px;
}

.ml-cta-promo--pattern .ml-cta-promo__description p {
	margin: 0;
	color: inherit;
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
}

.ml-cta-promo--pattern .ml-cta-promo__button {
	min-height: 56px;
	padding: 16px 40px;
	border-radius: 12px;
	background: var(--color-primary, #005ff9);
	box-shadow: 0 10px 24px rgba(0, 95, 249, 0.22);
	font-size: 20px;
	font-weight: 600;
	line-height: 24px;
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.ml-cta-promo--pattern .ml-cta-promo__button:hover,
.ml-cta-promo--pattern .ml-cta-promo__button:focus-visible {
	background: var(--color-primary-hover, #0056e2);
	filter: none;
}

@container ml-cta (min-width: 900px) {
	.ml-cta-promo--pattern {
		padding: 48px 40px;
	}

	.ml-cta-promo--pattern .ml-cta-promo__title {
		font-size: 36px;
		line-height: 44px;
	}
}

/* Beat parent content styles (blog / entry-content) */

.entry-content .ml-cta-promo-scope,
.ml-blog-post__content .ml-cta-promo-scope,
.ml-cta-promo-block .ml-cta-promo-scope {
	margin: 40px 0;
}

.entry-content .ml-cta-promo-scope--wide,
.ml-blog-post__content .ml-cta-promo-scope--wide,
.ml-single-glossary .ml-cta-promo-scope--wide,
.ml-cta-promo-block .ml-cta-promo-scope--wide,
.entry-content .ml-cta-promo-scope--pattern,
.ml-blog-post__content .ml-cta-promo-scope--pattern,
.ml-single-glossary .ml-cta-promo-scope--pattern,
.ml-cta-promo-block .ml-cta-promo-scope--pattern {
	margin: 48px 0;
}

.entry-content .ml-cta-promo__title,
.ml-blog-post__content .ml-cta-promo__title,
.ml-cta-promo-block .ml-cta-promo__title {
	margin: 0;
}

.entry-content .ml-cta-promo--wide .ml-cta-promo__title,
.ml-blog-post__content .ml-cta-promo--wide .ml-cta-promo__title,
.ml-cta-promo-block .ml-cta-promo--wide .ml-cta-promo__title {
	margin: 0;
	color: transparent;
	font-size: 28px;
	font-weight: 700;
	line-height: 32px;
	background: linear-gradient(256deg, #005ff9 0%, #9647db 100%);
	background-clip: text;
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
}

@container ml-cta (min-width: 900px) {

	.entry-content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-blog-post__content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-cta-promo-block .ml-cta-promo--wide .ml-cta-promo__title {
		font-size: 36px;
		line-height: 40px;
	}
}

.entry-content .ml-cta-promo__button,
.ml-blog-post__content .ml-cta-promo__button,
.ml-cta-promo-block .ml-cta-promo__button {
	color: #fff !important;
	text-decoration: none !important;
}

.entry-content .ml-cta-promo__description p,
.ml-blog-post__content .ml-cta-promo__description p,
.ml-cta-promo-block .ml-cta-promo__description p {
	margin: 0;
}

@media (max-width: 1050px) {
	.ml-cta-promo--side {
		padding-inline: 20px;
	}

	.ml-cta-promo--side .ml-cta-promo__title {
		font-size: 24px;
		line-height: 28px;
	}
}

@media (max-width: 600px) {
	.ml-cta-promo--side {
		gap: 16px;
		padding: 20px;
	}

	.ml-cta-promo--side .ml-cta-promo__copy {
		gap: 16px;
	}

	.ml-cta-promo--side .ml-cta-promo__title {
		max-width: 140px;
		font-size: 20px;
		line-height: 24px;
	}

	.ml-cta-promo--side .ml-cta-promo__description {
		font-size: 14px;
		line-height: 20px;
	}

	.ml-cta-promo__item {
		font-size: 12px;
		line-height: 16px;
	}

	.ml-cta-promo--side .ml-cta-promo__button {
		min-height: 44px;
		padding: 12px 24px;
		font-size: 16px;
		line-height: 20px;
	}

	.ml-cta-promo--wide {
		height: auto;
		min-height: 0;
		flex-direction: column;
		align-items: center;
		gap: 24px;
		padding: 28px 16px 0;
		border-radius: 20px;
	}

	.entry-content .ml-cta-promo-scope--wide,
	.ml-blog-post__content .ml-cta-promo-scope--wide,
	.ml-single-glossary .ml-cta-promo-scope--wide,
	.ml-cta-promo-block .ml-cta-promo-scope--wide,
	.entry-content .ml-cta-promo-scope--pattern,
	.ml-blog-post__content .ml-cta-promo-scope--pattern,
	.ml-single-glossary .ml-cta-promo-scope--pattern,
	.ml-cta-promo-block .ml-cta-promo-scope--pattern {
		margin: 40px 0;
	}

	.ml-cta-promo--wide .ml-cta-promo__copy {
		width: min(100%, 320px);
		gap: 12px;
		padding: 0;
	}

	.ml-cta-promo--wide .ml-cta-promo__title,
	.entry-content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-blog-post__content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-cta-promo-block .ml-cta-promo--wide .ml-cta-promo__title {
		font-size: 22px;
		line-height: 28px;
	}

	.ml-cta-promo--wide .ml-cta-promo__description {
		font-size: 14px;
		line-height: 20px;
	}

	.ml-cta-promo--wide .ml-cta-promo__button {
		min-height: 40px;
		padding: 8px 20px;
		font-size: 16px;
		line-height: 20px;
	}

	.ml-cta-promo__wide-art {
		display: none;
	}

	.ml-cta-promo__wide-mobile-art {
		position: relative;
		z-index: 1;
		display: block;
		width: 100%;
		max-width: 400px;
		height: auto;
		pointer-events: none;
	}

	.ml-cta-promo--pattern {
		padding: 32px 20px;
	}

	.ml-cta-promo--pattern .ml-cta-promo__title {
		font-size: 22px;
		line-height: 28px;
	}

	.ml-cta-promo--pattern .ml-cta-promo__button {
		min-height: 44px;
		padding: 12px 24px;
		font-size: 16px;
		line-height: 20px;
	}
}

@media (max-width: 380px) {
	.ml-cta-promo--wide .ml-cta-promo__title,
	.entry-content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-blog-post__content .ml-cta-promo--wide .ml-cta-promo__title,
	.ml-cta-promo-block .ml-cta-promo--wide .ml-cta-promo__title {
		font-size: 20px;
		line-height: 24px;
	}
}