/* Emirates Elements: EG Marquee. Colors, sizes and spacing are set by the widget's style controls. */

.ee-mq {
	--ee-mq-duration: 40s;
	box-sizing: border-box;
	width: 100%;
	overflow: hidden;
}

.ee-mq--fade {
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--ee-mq-fade, 8%), #000 calc(100% - var(--ee-mq-fade, 8%)), transparent);
	mask-image: linear-gradient(90deg, transparent, #000 var(--ee-mq-fade, 8%), #000 calc(100% - var(--ee-mq-fade, 8%)), transparent);
}

.ee-mq__track {
	display: flex;
	direction: ltr; /* The scroll direction must not flip on right-to-left pages. */
	width: max-content;
	min-width: 100%;
}

/* Two identical groups, each sliding by its own width, give a loop with no jump. */
.ee-mq__group {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	min-width: 100vw;
	justify-content: space-around;
	animation: ee-mq-left var(--ee-mq-duration) linear infinite;
}

.ee-mq--right .ee-mq__group {
	animation-name: ee-mq-right;
}

.ee-mq--pause:hover .ee-mq__group,
.ee-mq--pause:focus-within .ee-mq__group {
	animation-play-state: paused;
}

.ee-mq__item {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	white-space: nowrap;
}

.ee-mq__content {
	display: inline-flex;
	align-items: center;
	color: inherit;
	text-decoration: none;
}

a.ee-mq__content:hover,
a.ee-mq__content:focus-visible {
	text-decoration: underline;
}

.ee-mq__icon {
	display: inline-flex;
	align-items: center;
	line-height: 1;
}

.ee-mq__icon svg {
	fill: currentColor;
}

.ee-mq__text {
	direction: initial;
	unicode-bidi: plaintext;
}

@keyframes ee-mq-left {
	to {
		transform: translateX(-100%);
	}
}

@keyframes ee-mq-right {
	from {
		transform: translateX(-100%);
	}

	to {
		transform: translateX(0);
	}
}

/* Reduced motion: no scrolling; show the whole message as a wrapped, centred line. */
@media (prefers-reduced-motion: reduce) {
	.ee-mq__track {
		width: 100%;
	}

	.ee-mq__group {
		flex-wrap: wrap;
		justify-content: center;
		min-width: 0;
		width: 100%;
		padding: 0 16px;
		box-sizing: border-box;
		animation: none;
	}

	.ee-mq__group[aria-hidden="true"] {
		display: none;
	}

	.ee-mq__item {
		white-space: normal;
		padding-right: 0 !important;
	}

	.ee-mq__sep {
		display: none;
	}

	.ee-mq--fade {
		-webkit-mask-image: none;
		mask-image: none;
	}
}
