/* Functional colors are independent of Elementor's decorative brand token. */
:root {
	--mtc-action: #1f6895;
	--mtc-link: var(--mtc-action);
	--mtc-link-visited: var(--mtc-link);
	--mtc-focus: #111111;
}

/* Approved functional blue: leave the logo and large brand headings intact. */
body .elementor-33 .elementor-element-66348cd,
body .elementor-widget-button {
	--e-global-color-primary: var(--mtc-action);
}

body .cust-btn-container .cust-btn,
body .group-cards .btn-simple,
body .group-cards--links li a:hover {
	background-color: var(--mtc-action);
	border-color: var(--mtc-action);
}

body .group-cards .btn-simple:hover {
	background-color: #ffffff;
	color: var(--mtc-action);
}

body :is(.img-text-block a, .btn-default, .sqs-block-button-element--medium, .sqs-block-button-element) {
	color: var(--mtc-action);
	border-color: var(--mtc-action);
}

body :is(.img-text-block a, .btn-default):hover {
	background-color: var(--mtc-action);
	color: #ffffff;
}

body :is(.sqs-block-button-element--medium, .sqs-block-button-element) {
	background-color: var(--mtc-action);
	color: #ffffff;
}

body :is(.sqs-block-button-element--medium, .sqs-block-button-element):hover {
	background-color: #ffffff;
	color: var(--mtc-action);
}

/* These small labels need the normal-text contrast ratio in every state. */
body #nav-wrapper .jet-mega-menu-mega-container :is(h4, h6, .h4, .h6),
body #jupiterx-main :is(.elementor-widget-text-editor, .elementor-widget-theme-post-content, .tribe-events-single-event-description) :is(h4, h5, h6, .h4, .h5, .h6),
body.single-tribe_events #jupiterx-main p[data-mtc-heading],
body.single-post #jupiterx-main .hse-body-wrapper-table :is(h2, h3, h4, h5, h6),
body :is(.elementor-element-1daff44, .elementor-element-ae6808c, .elementor-element-805648e) .elementor-heading-title,
body .elementor-element-ed420c1 .e-n-tab-title[aria-selected="true"],
body .elementor-element-ed420c1 .e-n-tab-title[aria-selected="true"] .e-n-tab-title-text,
body :is(.elementor-element-df23897, .elementor-element-f115b1d, .elementor-element-f37ceff),
body .elementor-element-19363e5 .jet-listing-dynamic-field__content,
body #jupiterx-main :is(h4, h5, h6, .h4, .h5, .h6) [style*="#2d86bd" i],
body.single-post #jupiterx-main [style*="color: #2d86bd" i],
body.single-post #jupiterx-main [style*="color:#2d86bd" i],
body .elementor-4627 .elementor-element-d5431de .jet-toggle__control .jet-toggle__label-text {
	color: var(--mtc-action) !important;
}

body.single-post .wp-block-button__link.has-vivid-cyan-blue-background-color {
	background-color: var(--mtc-action) !important;
}

/* White functional glyphs need a visible background, unlike decorative art. */
body #nav-wrapper .hide-label-desktop .jet-mega-menu-item__icon svg > circle {
	fill: #707070;
}

/* Profile metadata is ordinary text, rather than miniature brand headings. */
body.single-team .elementor-644 .mtc-profile-label {
	color: #020202;
}

/*
 * Text links on the site's light content surfaces. Explicit component scope
 * keeps white links over photography and the shared footer readable. The
 * important declarations override legacy inline colors and page-builder CSS.
 */
body :is(
	#jupiterx-main .elementor-widget-text-editor a[href],
	#jupiterx-main .elementor-widget-theme-post-content a[href],
	#jupiterx-main .elementor-widget-heading a[href],
	#jupiterx-main .elementor-post__title a[href],
	#jupiterx-main .elementor-post__read-more[href],
	#jupiterx-main .elementor-widget-raven-post-meta a[href],
	#jupiterx-main .jet-listing-dynamic-field__content a[href],
	#jupiterx-main .entry-content a[href],
	#jupiterx-main :is(.tribe-events-content, .tribe-events-back, .tribe-events-event-meta, .elementor-widget-icon-list) a[href],
	.mtc-iop-preview a[href],
	.mtc-webinars a[href]
):not(:where(
	[role="button"], .elementor-button, .raven-button, .btn,
	.wp-block-button__link, .wp-element-button, .mtc-card--linked,
	.btn-default, .btn-simple, .cust-btn, .sqs-block-button-element,
	.sqs-block-button-element--medium, .img-text-block a,
	.mtc-iop-button, .mtc-hero__cta, .mtc-upcoming-ce__cta,
	.team-card-container a,
	.hero-image-container a, .elementor-widget-theme-site-logo a,
	.elementor-widget-image a, .elementor-icon, .elementor-social-icon,
	.mtc-link-on-dark a, [data-mtc-link-on-dark] a
)) {
	color: var(--mtc-link) !important;
	text-decoration-line: underline !important;
	text-decoration-thickness: 0.08em;
	text-underline-offset: 0.18em;
	text-decoration-skip-ink: auto;
}

body :is(
	#jupiterx-main .elementor-widget-text-editor a[href],
	#jupiterx-main .elementor-widget-theme-post-content a[href],
	#jupiterx-main .elementor-widget-heading a[href],
	#jupiterx-main .elementor-post__title a[href],
	#jupiterx-main .elementor-post__read-more[href],
	#jupiterx-main .elementor-widget-raven-post-meta a[href],
	#jupiterx-main .jet-listing-dynamic-field__content a[href],
	#jupiterx-main .entry-content a[href],
	#jupiterx-main :is(.tribe-events-content, .tribe-events-back, .tribe-events-event-meta, .elementor-widget-icon-list) a[href],
	.mtc-iop-preview a[href],
	.mtc-webinars a[href]
):not(:where(
	[role="button"], .elementor-button, .raven-button, .btn,
	.wp-block-button__link, .wp-element-button, .mtc-card--linked,
	.btn-default, .btn-simple, .cust-btn, .sqs-block-button-element,
	.sqs-block-button-element--medium, .img-text-block a,
	.mtc-iop-button, .mtc-hero__cta, .mtc-upcoming-ce__cta,
	.team-card-container a,
	.hero-image-container a, .elementor-widget-theme-site-logo a,
	.elementor-widget-image a, .elementor-icon, .elementor-social-icon,
	.mtc-link-on-dark a, [data-mtc-link-on-dark] a
)):visited {
	color: var(--mtc-link-visited) !important;
}

/* Colored spans in imported text must follow their link's state. */
body #jupiterx-main .elementor-widget-icon-list a[href] .elementor-icon-list-text {
	color: inherit !important;
}
body #jupiterx-main :is(.elementor-widget-text-editor, .elementor-widget-theme-post-content) a[href]:not(:where([role="button"], .elementor-button, .raven-button, .btn, .wp-block-button__link, .wp-element-button, .btn-default, .btn-simple, .cust-btn, .sqs-block-button-element, .sqs-block-button-element--medium, .img-text-block a, .team-card-container a, .hero-image-container a, .mtc-link-on-dark a, [data-mtc-link-on-dark] a)) :is(span, strong, em, b, i, font) {
	color: inherit !important;
}

/* In a linked card, only its title and action need link styling. */
body .mtc-webinars .mtc-card--linked :is(.mtc-card__title, .mtc-card__watch) {
	color: var(--mtc-link) !important;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

body .mtc-webinars .mtc-card--linked:visited :is(.mtc-card__title, .mtc-card__watch) {
	color: var(--mtc-link-visited) !important;
}

body .mtc-webinars .mtc-card__watch {
	border-bottom: 0;
}

/* Navigation keeps its normal dark text; active/hover states use brand blue. */
body #nav-wrapper a:not(.elementor-button):is(:hover, :focus-visible, [aria-current="page"]),
body .elementor-widget-nav-menu a:is(:hover, :focus-visible, .elementor-item-active) {
	color: var(--mtc-link) !important;
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

body #nav-wrapper .elementor-button {
	color: #ffffff !important;
	fill: #ffffff !important;
}

body .group-cards--links a {
	color: var(--mtc-action);
}

body .group-cards--links a:hover {
	color: #ffffff;
}

/* Readable fallback until the text-shaped blur has valid layout measurements. */
body.home .hero-image-container::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgb(0 0 0 / 60%);
	z-index: 1;
	pointer-events: none;
}

body.home .hero-image-container > .mtc-hero-text-shade {
	position: absolute;
	inset: 0;
	z-index: 1;
	display: none;
	width: 100%;
	height: 100%;
	overflow: hidden;
	pointer-events: none;
}

body.home:not([data-hero-demo]) .hero-image-container[data-mtc-hero-shading="focused"]::before {
	background: none !important;
}

body.home:not([data-hero-demo]) .hero-image-container[data-mtc-hero-shading="focused"] > .mtc-hero-text-shade {
	display: block;
}

body.home .hero-image-container > .e-con-inner > .e-con {
	z-index: 2;
}

body .elementor-448 .elementor-element-16d362e9::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgb(0 0 0 / 60%);
	pointer-events: none;
}

.mtc-video-motion-toggle {
	position: absolute;
	bottom: 16px;
	left: 24px;
	z-index: 3;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid rgb(255 255 255 / 65%);
	border-radius: 50%;
	background: rgb(17 17 17 / 75%);
	color: #ffffff;
	cursor: pointer;
}

.mtc-video-motion-toggle:hover {
	background: #111111;
	color: #ffffff;
}

.mtc-video-motion-toggle svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
	pointer-events: none;
}

.mtc-video-motion-toggle[data-state="playing"] .mtc-video-play-icon,
.mtc-video-motion-toggle[data-state="paused"] .mtc-video-pause-icon {
	display: none;
}

/* A dark ring plus a white separator remains visible on light and dark areas. */
body :is(a[href], button, input, select, textarea, [tabindex]):focus-visible {
	outline: 3px solid var(--mtc-focus) !important;
	outline-offset: 3px !important;
	box-shadow: 0 0 0 3px #ffffff !important;
}

@media (forced-colors: active) {
	body :is(a[href], button, input, select, textarea, [tabindex]):focus-visible {
		outline-color: Highlight !important;
		box-shadow: none !important;
	}
}

/* Let event details grow vertically instead of wrapping into offscreen columns. */
body.single-tribe_events .elementor-738 .side-column {
	height: auto;
	max-height: none;
	flex-wrap: nowrap;
}

/* Long email addresses and URLs in imported articles must wrap as text. */
body #jupiterx-main :is(.elementor-widget-theme-post-content, .elementor-widget-text-editor, .elementor-heading-title, .entry-content) {
	overflow-wrap: anywhere;
}

body.single-post #jupiterx-main .elementor-widget-theme-post-content form {
	min-width: 0;
	max-width: 100%;
}

body.single-post #jupiterx-main .elementor-widget-theme-post-content form input {
	max-width: 100%;
}

/* These are email-layout tables, not data tables requiring a wide grid. */
body.single-post #jupiterx-main :is(table[role="presentation"], table[role="none"], table.hse-body-wrapper-table) {
	width: 100% !important;
	max-width: 100%;
	min-width: 0 !important;
	table-layout: fixed;
	height: auto !important;
}

body #jupiterx-main .elementor-widget-loop-carousel .swiper-pagination {
	width: 100%;
	left: 0;
}

@media (max-width: 767px) {
	/* Elementor displays a still fallback instead of this background video. */
	.mtc-video-motion-toggle {
		display: none;
	}

	body.single-post #jupiterx-main [class*="hse-"] {
		min-width: 0 !important;
		max-width: 100% !important;
	}

	/* The decorative 1.3x scale enlarged the title beyond the screen edges. */
	body .elementor-4627 .elementor-element.elementor-element-119fad37.e-con {
		--e-con-transform-scale: 1;
	}
}
/* Original group testimonials as scalable text instead of numbered images. */
.mtc-group-testimonials { width: 100%; color: #222; }
.elementor-widget-button .elementor-button { max-width: 100%; box-sizing: border-box; }
.elementor-button-content-wrapper { min-width: 0; }
.elementor-button-text { min-width: 0; overflow-wrap: anywhere; }
.mtc-testimonial-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.mtc-testimonial-grid figure { margin: 0; padding: 28px; background: #f3f7fa; border-top: 4px solid #1f6895; }
.mtc-testimonial-grid blockquote { margin: 0 0 20px; padding: 0; border: 0; font-size: 18px; line-height: 1.6; color: #222; }
.mtc-testimonial-grid figcaption { font-weight: 600; color: #1f6895; }
@media (max-width: 767px) {
	.mtc-testimonial-grid { grid-template-columns: minmax(0, 1fr); }
	.mtc-testimonial-grid figure { padding: 20px; }
}
