/* ========================================
   MedXFactor Native Header - Desktop
   ======================================== */

.mxf-site-header {
	position: relative;
	z-index: 1000;
	width: 100%;
	height: 74px;
	background: var(--mxf-header-bg);
	overflow: visible;
}

.mxf-header-inner {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr) 190px minmax(0, 1fr);
	align-items: center;
	width: min(var(--mxf-container), calc(100% - 48px));
	height: 74px;
	margin: 0 auto;
	overflow: visible;
}

.mxf-header-nav,
.mxf-header-right-zone {
	min-width: 0;
}

.mxf-header-nav--left {
	justify-self: start;
}

.mxf-header-right-zone {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 58px;
}

.mxf-header-menu {
	display: flex;
	align-items: center;
	flex-wrap: nowrap;
	list-style: none;
	margin: 0;
	padding: 0;
}

.mxf-header-menu--left {
	gap: 49px;
}

.mxf-header-menu--right {
	gap: 52px;
}

.mxf-header-menu > li {
	position: relative;
	flex: 0 0 auto;
	margin: 0;
	padding: 0;
}

.mxf-header-menu > li > a {
	position: relative;
	display: inline-flex;
	align-items: center;
	height: 74px;
	padding: 0;
	color: #101010;
	font-family: var(--mxf-font-body);
	font-size: 15px;
	font-weight: 400;
	line-height: 1;
	letter-spacing: 0.01em;
	text-decoration: none;
	white-space: nowrap;
	transition: color 160ms ease;
}

.mxf-header-menu > li > a:hover,
.mxf-header-menu > li > a:focus-visible {
	color: var(--mxf-primary);
}

.mxf-header-menu > .current-menu-item > a,
.mxf-header-menu > .current_page_item > a,
.mxf-header-menu > .current_page_parent > a,
.mxf-header-menu > .current-menu-ancestor > a,
.mxf-header-menu > .current-post-ancestor > a {
	color: #101010;
}

.mxf-header-menu > .current-menu-item > a::after,
.mxf-header-menu > .current_page_item > a::after,
.mxf-header-menu > .current_page_parent > a::after,
.mxf-header-menu > .current-menu-ancestor > a::after,
.mxf-header-menu > .current-post-ancestor > a::after {
	content: "";
	position: absolute;
	left: 50%;
	bottom: 18px;
	width: 48px;
	height: 3px;
	transform: translateX(-50%);
	background: var(--mxf-primary);
	border-radius: var(--mxf-radius-pill);
	box-shadow: 0 2px 4px rgb(0 83 246 / 24%);
}

.mxf-header-brand {
	position: relative;
	align-self: stretch;
	width: 190px;
	z-index: 5;
}

/*
 * Compact neutral plate directly underneath the centered logo.
 * It intentionally uses the same fill as the header and has no stroke: only
 * the portion hanging below the header edge is visible over the hero artwork.
 */
.mxf-header-brand-geometry {
	position: absolute;
	left: 50%;
	top: 50px;
	z-index: 2;
	display: block;
	width: 290px;
	height: 100px;
	transform: translateX(-50%);
	overflow: visible;
	pointer-events: none;
}

.mxf-header-brand-geometry__shape {
	fill: var(--mxf-header-bg);
	stroke: none;
}

.mxf-header-brand-link {
	position: absolute;
	left: 50%;
	top: 43px;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 150px;
	min-height: 61px;
	transform: translateX(-50%);
	text-decoration: none;
}

.mxf-header-logo {
	display: block;
	width: 120px;
	max-width: 120px;
	height: auto;
}

.mxf-logo-text {
	color: var(--mxf-primary);
	font-size: 20px;
	font-weight: 700;
	white-space: nowrap;
}

.mxf-header-cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 146px;
	height: 36px;
	padding: 0 22px;
	border-radius: var(--mxf-radius-pill);
	background: var(--mxf-primary);
	color: var(--mxf-white);
	font-family: var(--mxf-font-body);
	font-size: 14px;
	font-weight: 500;
	line-height: 1;
	text-decoration: none;
	white-space: nowrap;
	transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.mxf-header-cta:hover,
.mxf-header-cta:focus-visible {
	background: #0049d9;
	color: #fff;
	transform: translateY(-1px);
	box-shadow: 0 8px 18px rgb(0 83 246 / 18%);
}

/* Basic dropdown support. Mobile-specific navigation will be added later. */
.mxf-header-menu .sub-menu {
	position: absolute;
	top: calc(100% - 6px);
	left: 0;
	z-index: 20;
	display: none;
	min-width: 210px;
	margin: 0;
	padding: 10px;
	list-style: none;
	background: #fff;
	border: 1px solid rgb(0 83 246 / 8%);
	border-radius: 14px;
	box-shadow: 0 14px 35px rgb(12 51 104 / 12%);
}

.mxf-header-menu li:hover > .sub-menu,
.mxf-header-menu li:focus-within > .sub-menu {
	display: block;
}

.mxf-header-menu .sub-menu a {
	display: block;
	padding: 10px 12px;
	color: var(--mxf-text);
	font-size: 14px;
	text-decoration: none;
	white-space: nowrap;
}

/* Keep desktop layout usable on narrower desktop widths until mobile work begins. */
@media (max-width: 1180px) {
	.mxf-header-inner {
		width: calc(100% - 32px);
		grid-template-columns: minmax(0, 1fr) 150px minmax(0, 1fr);
	}

	.mxf-header-menu--left,
	.mxf-header-menu--right {
		gap: 24px;
	}

	.mxf-header-right-zone {
		gap: 24px;
	}

	.mxf-header-brand {
		width: 150px;
	}

	.mxf-header-brand-geometry {
		top: 64px;
		width: 178px;
		height: 40px;
	}
}

@media (max-width: 767px) {
	.mxf-header-brand-geometry {
		top: 64px;
		width: 160px;
		height: 36px;
	}
}

/* ==========================================
   Header refinement
   ========================================== */

.mxf-header {
    font-family: var(--mxf-font-family);
}

.mxf-header a {
    font-family: inherit;
}

.mxf-header-left a,
.mxf-header-right a {
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
}

.mxf-demo-button,
.mxf-demo-button a {
    font-family: inherit;
    font-weight: 500;
}

.mxf-header-center img {
    width: 120px;
    height: auto;
}
/* ==========================================
   Services Mega Menu
   ========================================== */

.mxf-services-trigger-item > a::after {
	content: "";
	position: absolute;
	left: 50%;
	bottom: 18px;
	width: 48px;
	height: 3px;
	transform: translateX(-50%) scaleX(0);
	transform-origin: center;
	background: var(--mxf-primary);
	border-radius: var(--mxf-radius-pill);
	box-shadow: 0 2px 4px rgb(0 83 246 / 24%);
	opacity: 0;
	transition: transform 160ms ease, opacity 160ms ease;
}

.mxf-services-trigger-item:hover > a::after,
.mxf-services-trigger-item:focus-within > a::after,
.mxf-services-trigger-item.is-mega-open > a::after,
.mxf-services-trigger-item.current-menu-item > a::after,
.mxf-services-trigger-item.current_page_item > a::after,
.mxf-services-trigger-item.current-menu-ancestor > a::after {
	transform: translateX(-50%) scaleX(1);
	opacity: 1;
}

.mxf-services-mega {
	position: absolute;
	top: 74px;
	left: 50%;
	z-index: 80;
	width: min(1210px, calc(100vw - 64px));
	transform: translate(-50%, -10px);
	visibility: hidden;
	opacity: 0;
	pointer-events: none;
	transition: opacity 170ms ease, transform 170ms ease, visibility 0s linear 170ms;
}

.mxf-services-mega.is-open {
	transform: translate(-50%, 0);
	visibility: visible;
	opacity: 1;
	pointer-events: auto;
	transition-delay: 0s;
}

.mxf-services-mega__panel {
	display: grid;
	grid-template-columns: 1.05fr 1fr 0.96fr;
	gap: 0;
	width: 100%;
	min-height: 510px;
	padding: 28px 30px 28px 36px;
	background: rgb(255 255 255 / 97%);
	border: 1px solid rgb(15 70 140 / 7%);
	border-radius: 20px;
	box-shadow: 0 28px 65px rgb(25 67 107 / 18%);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	font-family: var(--mxf-font-body);
	color: #163c75;
}

.mxf-services-mega h2,
.mxf-services-mega h3,
.mxf-services-mega p,
.mxf-services-mega a,
.mxf-services-mega strong {
	font-family: var(--mxf-font-body);
}

.mxf-services-mega__intro,
.mxf-services-mega__column {
	min-width: 0;
}

.mxf-services-mega__intro {
	display: flex;
	flex-direction: column;
	padding: 14px 30px 12px 0;
}

.mxf-services-mega__column {
	padding: 0 20px 0 28px;
	border-left: 1px solid #d9e7f2;
}

.mxf-services-mega__column:last-child {
	padding-right: 0;
}

.mxf-services-mega__eyebrow {
	margin-bottom: 18px;
	color: #1e7be8;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: 0.055em;
}

.mxf-services-mega__intro h2 {
	max-width: 360px;
	margin: 0 0 17px;
	color: #08265c;
	font-size: clamp(23px, 1.7vw, 28px);
	font-weight: 750;
	line-height: 1.18;
	letter-spacing: -0.025em;
}

.mxf-services-mega__intro-copy {
	max-width: 380px;
	margin: 0;
	color: #4f6685;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.55;
}

.mxf-services-mega__cta {
	position: relative;
	display: grid;
	grid-template-columns: 64px 1fr;
	gap: 15px;
	align-items: start;
	margin-top: auto;
	min-height: 176px;
	padding: 22px 58px 20px 18px;
	background: linear-gradient(135deg, #eff8ff 0%, #e2f2ff 100%);
	border: 1px solid #d1eaff;
	border-radius: 15px;
	color: #153c78;
	text-decoration: none;
	transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.mxf-services-mega__cta:hover,
.mxf-services-mega__cta:focus-visible {
	color: #153c78;
	transform: translateY(-1px);
	border-color: #9bcfff;
	box-shadow: 0 12px 25px rgb(23 111 214 / 10%);
}

.mxf-services-mega__cta-icon {
	display: grid;
	place-items: center;
	width: 64px;
	height: 64px;
	border-radius: 13px;
	background: #d5ecff;
	color: #0757f8;
}

.mxf-services-mega__cta-icon svg {
	width: 38px;
	height: 38px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.1;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.mxf-services-mega__cta-copy {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
}

.mxf-services-mega__cta-copy strong {
	color: #113e80;
	font-size: 18px;
	font-weight: 700;
	line-height: 1.25;
}

.mxf-services-mega__cta-copy > span {
	color: #526b8e;
	font-size: 14px;
	line-height: 1.45;
}

.mxf-services-mega__cta-arrow,
.mxf-services-mega__service-arrow {
	display: grid;
	place-items: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: #1281ed;
	color: #fff;
}

.mxf-services-mega__cta-arrow {
	position: absolute;
	right: 17px;
	bottom: 17px;
}

.mxf-services-mega__cta-arrow svg,
.mxf-services-mega__service-arrow svg {
	width: 21px;
	height: 21px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.mxf-services-mega__service {
	position: relative;
	display: grid;
	grid-template-columns: 46px minmax(0, 1fr);
	gap: 14px;
	padding: 14px 4px 17px;
	border-bottom: 1px solid #dce8f1;
}

.mxf-services-mega__service:last-child {
	border-bottom: 0;
}

.mxf-services-mega__service-icon {
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding-top: 1px;
	color: #0645b8;
}

.mxf-services-mega__service-icon svg {
	width: 37px;
	height: 37px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.35;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.mxf-services-mega__service-title {
	display: inline-flex;
	margin: 0 0 4px;
	color: #0e3b7d;
	font-size: 17px;
	font-weight: 720;
	line-height: 1.25;
	text-decoration: none;
}

.mxf-services-mega__service-title:hover,
.mxf-services-mega__service-title:focus-visible {
	color: var(--mxf-primary);
}

.mxf-services-mega__service-content p {
	margin: 0;
	color: #657a97;
	font-size: 14px;
	line-height: 1.38;
}

.mxf-services-mega__children {
	display: flex;
	flex-direction: column;
	gap: 7px;
	margin: 7px 0 0;
	padding: 0;
	list-style: none;
}

.mxf-services-mega__children li {
	margin: 0;
	padding: 0;
}

.mxf-services-mega__children a {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: #4c6689;
	font-size: 14px;
	font-weight: 450;
	line-height: 1.25;
	text-decoration: none;
}

.mxf-services-mega__children a:hover,
.mxf-services-mega__children a:focus-visible {
	color: var(--mxf-primary);
}

.mxf-services-mega__chevron {
	display: inline-flex;
	color: #35659d;
}

.mxf-services-mega__chevron svg {
	width: 14px;
	height: 14px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.mxf-services-mega__service--highlight {
	grid-template-columns: 46px minmax(0, 1fr) 42px;
	margin-top: 8px;
	padding: 17px 12px 16px;
	background: linear-gradient(135deg, #eef9ff 0%, #dff2ff 100%);
	border: 1px solid #82c8ff;
	border-radius: 15px;
}

.mxf-services-mega__service--highlight .mxf-services-mega__service-title {
	color: #0e6fcc;
}

.mxf-services-mega__service-arrow {
	align-self: start;
	width: 34px;
	height: 34px;
	text-decoration: none;
}

@media (max-width: 1180px) {
	.mxf-services-mega {
		width: calc(100vw - 32px);
	}

	.mxf-services-mega__panel {
		grid-template-columns: 0.95fr 1fr 1fr;
		padding: 24px 22px;
	}

	.mxf-services-mega__intro {
		padding-right: 20px;
	}

	.mxf-services-mega__column {
		padding-left: 20px;
		padding-right: 14px;
	}

	.mxf-services-mega__service-title {
		font-size: 15px;
	}

	.mxf-services-mega__service-content p,
	.mxf-services-mega__children a {
		font-size: 13px;
	}
}

@media (max-width: 900px) {
	.mxf-services-mega {
		top: 70px;
		width: calc(100vw - 24px);
		max-height: calc(100vh - 86px);
		overflow-y: auto;
		overscroll-behavior: contain;
	}

	.mxf-services-mega__panel {
		grid-template-columns: 1fr 1fr;
		min-height: 0;
		padding: 22px;
		border-radius: 18px;
	}

	.mxf-services-mega__intro {
		grid-column: 1 / -1;
		padding: 0 0 22px;
		border-bottom: 1px solid #d9e7f2;
	}

	.mxf-services-mega__intro h2,
	.mxf-services-mega__intro-copy {
		max-width: none;
	}

	.mxf-services-mega__cta {
		margin-top: 20px;
		min-height: 142px;
	}

	.mxf-services-mega__column {
		padding: 16px 14px 0 0;
		border-left: 0;
	}

	.mxf-services-mega__column + .mxf-services-mega__column {
		padding-right: 0;
		padding-left: 18px;
		border-left: 1px solid #d9e7f2;
	}
}

@media (max-width: 620px) {
	.mxf-services-mega__panel {
		display: block;
		padding: 18px 16px;
	}

	.mxf-services-mega__column,
	.mxf-services-mega__column + .mxf-services-mega__column {
		padding: 12px 0 0;
		border-left: 0;
	}

	.mxf-services-mega__column + .mxf-services-mega__column {
		border-top: 1px solid #d9e7f2;
	}

	.mxf-services-mega__cta {
		grid-template-columns: 52px 1fr;
		min-height: 132px;
		padding-left: 14px;
	}

	.mxf-services-mega__cta-icon {
		width: 52px;
		height: 52px;
	}
}
