/* TransparentRx header — scoped to .trx-header. Source: Header.dc.html. Single breakpoint: 960px. */
.trx-header {
	--trx-blue: #1D3A8C;
	--trx-green: #12833C;
	--trx-border: #E7EAEF;
	--trx-hover-bg: #F4F7FA;
	--trx-muted: #5B6673;
	position: relative;
	font-family: "Nunito Sans", system-ui, sans-serif;
	-webkit-font-smoothing: antialiased;
}
.trx-header *, .trx-header *::before, .trx-header *::after { box-sizing: border-box; }
.trx-header a { text-decoration: none; }
.trx-header a:focus-visible, .trx-header button:focus-visible {
	outline: 3px solid var(--trx-green);
	outline-offset: 3px;
	border-radius: 4px;
}

/* Desktop nav */
.trx-nav {
	display: flex;
	align-items: center;
	gap: clamp(16px, 2.8vw, 46px);
	font-size: 16.5px;
	font-weight: 600;
	white-space: nowrap;
}
.trx-header .trx-nav__link { color: var(--trx-blue); display: flex; align-items: center; gap: 7px; }
.trx-header .trx-nav__link:hover,
.trx-header .trx-nav__item:focus-within > .trx-nav__link { color: var(--trx-green); }
.trx-caret { font-size: 11px; }
.trx-nav__item { position: relative; }

.trx-sub {
	display: none;
	position: absolute;
	top: 100%;
	left: -18px;
	padding-top: 22px; /* hover bridge between link and panel */
	z-index: 50;
}
.trx-nav__item.has-sub:hover > .trx-sub,
.trx-nav__item.has-sub:focus-within > .trx-sub { display: block; }
.trx-nav__item.has-sub.is-closed > .trx-sub { display: none; } /* Escape pressed */

.trx-sub__panel {
	background: #fff;
	border: 1px solid var(--trx-border);
	border-radius: 10px;
	box-shadow: 0 18px 40px rgba(29, 58, 140, 0.14);
	padding: 12px;
	min-width: 300px;
	display: flex;
	flex-direction: column;
	font-weight: 600;
	white-space: normal;
}
.trx-nav > .trx-nav__item:nth-child(1) .trx-sub__panel { min-width: 320px; }
.trx-nav > .trx-nav__item:nth-child(3) .trx-sub__panel { min-width: 280px; }
.trx-header .trx-sub__link {
	display: block;
	color: var(--trx-blue);
	padding: 12px 16px;
	border-radius: 7px;
	font-size: 16px;
}
.trx-header .trx-sub__link:hover,
.trx-header .trx-sub__link:focus-visible { background: var(--trx-hover-bg); color: var(--trx-green); }
.trx-sub__group { margin-top: 8px; padding-top: 10px; border-top: 1px solid #EDF0F4; }
.trx-header .trx-sub__link--group { font-weight: 700; }
.trx-header .trx-sub__link--child { color: var(--trx-muted); padding: 9px 16px 9px 30px; font-size: 15.5px; }
.trx-header .trx-sub__link--child:hover,
.trx-header .trx-sub__link--child:focus-visible { color: var(--trx-green); }

/* Mobile */
.trx-header button.trx-toggle {
	display: none; /* shown below 960px */
	appearance: none;
	-webkit-appearance: none;
	width: auto;
	height: auto;
	min-height: 0;
	margin: 0;
	border: 1.5px solid #D8DDE5;
	border-radius: 6px;
	background: #fff;
	box-shadow: none;
	padding: 11px 14px;
	font-family: "Nunito Sans", sans-serif;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: normal;
	text-transform: none;
	text-align: left;
	color: var(--trx-blue);
	cursor: pointer;
	align-items: center;
	justify-content: flex-start;
	gap: 9px;
}
.trx-header button.trx-toggle:hover { background: #fff; color: var(--trx-blue); border-color: #D8DDE5; }
.trx-toggle__bars { display: flex; flex-direction: column; gap: 3px; }
.trx-toggle__bars span { display: block; width: 17px; height: 2px; background: var(--trx-blue); }

.trx-mobile {
	display: none;
	/* Full-width panel directly under the header bar; --trx-mobile-top is set by JS. */
	position: fixed;
	top: var(--trx-mobile-top, 80px);
	left: 0;
	right: 0;
	z-index: 9999;
	max-height: calc(100vh - var(--trx-mobile-top, 80px));
	max-height: calc(100dvh - var(--trx-mobile-top, 80px)); /* excludes mobile browser bars */
	overflow-y: auto;
	overscroll-behavior: contain; /* don't scroll the page behind */
	-webkit-overflow-scrolling: touch;
	border-top: 1px solid var(--trx-border);
	border-bottom: 1px solid var(--trx-border);
	padding: 18px clamp(20px, 4vw, 40px) 26px;
	flex-direction: column;
	gap: 4px;
	background: #fff;
}
.trx-header .trx-mobile__link {
	color: var(--trx-blue);
	font-size: 17px;
	font-weight: 600;
	padding: 12px 0;
	border-bottom: 1px solid #F1F3F6;
}
.trx-header .trx-mobile__link:hover { color: var(--trx-green); }

/* Mobile accordion (nested items from the desktop menu). */
.trx-mobile__row { display: flex; align-items: stretch; border-bottom: 1px solid #F1F3F6; }
.trx-header .trx-mobile__row .trx-mobile__link { flex: 1 1 auto; border-bottom: 0; }
.trx-header button.trx-mobile__expand {
	flex: 0 0 auto;
	width: 48px;
	background: none;
	border: 0;
	border-radius: 0;
	padding: 0;
	color: var(--trx-blue);
	cursor: pointer;
}
.trx-header button.trx-mobile__expand:hover,
.trx-header button.trx-mobile__expand:focus-visible { background: none; color: var(--trx-green); }
.trx-mobile__expand .trx-caret { display: inline-block; transition: transform .2s; }
.trx-mobile__expand[aria-expanded="true"] .trx-caret { transform: rotate(180deg); }
.trx-mobile__sub { padding-left: 16px; border-left: 2px solid #EDF0F4; margin-bottom: 4px; }
.trx-mobile__sub { display: flex; flex-direction: column; gap: 4px; }
.trx-mobile__sub[hidden] { display: none; }
.trx-header .trx-mobile__sub .trx-mobile__link { font-size: 16px; font-weight: 400; }
.trx-header .trx-mobile__sub--d2 .trx-mobile__link { font-size: 15.5px; color: var(--trx-muted); }

@media (max-width: 959.98px) {
	.trx-nav { display: none; }
	.trx-header button.trx-toggle { display: inline-flex; }
	.trx-mobile:not([hidden]) { display: flex; }
}

/* Lock page scroll while the mobile menu is open (class set by JS). */
html.trx-menu-open { overflow: hidden; }

/* Below 960px: push the Menu button to the right edge of the header row.
   Scoped to the site's header section (.header-sec); overrides the narrow
   per-breakpoint column widths set in Elementor. */
@media (max-width: 959.98px) {
	.header-sec .logo,
	.header-sec .btn-col { flex: 0 0 auto; width: auto !important; }
	.header-sec .menu-col { flex: 1 1 auto; width: auto !important; min-width: 0; }
	.header-sec .menu-col > .elementor-column-wrap > .elementor-widget-wrap,
	.header-sec .menu-col > .elementor-widget-wrap { justify-content: flex-end; }
	.header-sec .menu-col .elementor-widget-shortcode { width: 100%; }
	.trx-header { display: flex; justify-content: flex-end; }
}
