/* ==========================================================================
   Site header - utility bar + sticky navigation bar
   ========================================================================== */

.site-header {
	position: relative;
	z-index: 500;
}

/* --------------------------------------------------------------------------
   Utility bar
   -------------------------------------------------------------------------- */

.topbar {
	background: #f3eee3;
	padding: 4px 24px;
}

.topbar__inner {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

.topbar__note {
	flex: 0 1 auto;
	max-width: none;
	min-width: 0;
}

.topbar__note p {
	margin: 0;
	font-family: var(--fda-font-ui);
	font-size: 13.5px;
	font-weight: 400;
	line-height: 24px;
	letter-spacing: 0.5px;
	color: #152641;
	text-align: center;
	white-space: nowrap;
}

.topbar__contact {
	flex: 0 1 auto;
	max-width: none;
	min-width: 0;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
}

.topbar__contact::before {
	content: "|";
	margin: 0 12px 0 0;
	color: rgba(21, 38, 65, 0.3);
}

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

.contact-list__item {
	display: flex;
	align-items: center;
	margin: 0;
	line-height: 24px;
}

.contact-list__item + .contact-list__item::before {
	content: "|";
	margin: 0 12px;
	color: rgba(21, 38, 65, 0.3);
}

.contact-list__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 19px;
	height: 15px;
}

.contact-list__icon .fda-icon {
	width: 15px;
	height: 15px;
	fill: #152641;
	margin-right: 3.75px;
	transition: fill var(--fda-speed);
}

.contact-list__text {
	padding-left: 5px;
	font-family: var(--fda-font-ui);
	font-size: 13.5px;
	font-weight: 400;
	line-height: 24px;
	letter-spacing: 0.5px;
	color: #152641;
	text-decoration: none;
	white-space: nowrap;
	transition: color var(--fda-speed);
}

.contact-list__text:hover,
.contact-list__text:focus {
	color: #892943;
}

/* Account links live in the utility bar. */
.topbar__auth {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0;
	width: auto;
	white-space: nowrap;
}

.topbar__rule {
	display: inline-flex;
	margin: 0 10px;
	color: rgba(21, 38, 65, 0.3);
}

.topbar__rule::before {
	content: "|";
}

.topbar__signin {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 0;
	font-family: var(--fda-font-ui);
	font-size: 13.5px;
	font-weight: 600;
	line-height: 24px;
	color: #152641;
	text-decoration: none;
	border-radius: 5px;
	transition: color var(--fda-speed);
}

.topbar__signin .fda-icon {
	width: 16px;
	height: 16px;
	fill: currentColor;
}

.topbar__signin-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 24px;
}

.topbar__signin:hover,
.topbar__signin:focus {
	color: #892943;
}

.topbar__register {
	font-weight: 700;
}

/* --------------------------------------------------------------------------
   Navigation bar
   -------------------------------------------------------------------------- */

.navbar {
	position: sticky;
	top: 0;
	z-index: 400;
	background: #ffffff;
	padding: 10px 3vw;
	border-bottom: 1px solid #e8e0cf;
	box-shadow: 0 1px 10px 0 rgba(21, 38, 65, 0.08);
}

.navbar__inner {
	display: flex;
	flex-direction: row;
	align-items: center;
	gap: 0;
}

/* Brand plus compact primary navigation. */
.brand {
	flex: 0 0 auto;
	min-width: 0;
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: flex-start;
	text-decoration: none;
	align-self: stretch;
}

.brand__name {
	font-family: var(--fda-font-ui);
	font-size: 29px;
	font-weight: 600;
	line-height: 29px;
	color: #152641;
	white-space: nowrap;
}

/* The logo carries the .custom-logo class but may be rendered outside the
   .brand wrapper by lazy-load / image-optimizer plugins, so target it
   globally and override the plugin's inline width/height attributes. */
img.custom-logo,
.brand img,
.brand .custom-logo {
	max-height: 28px !important;
	width: auto !important;
	height: auto !important;
	max-width: 220px !important;
}

.navbar__nav {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-self: stretch;
	margin-left: auto;
}

/* --------------------------------------------------------------------------
   Menu
   -------------------------------------------------------------------------- */

.nav-menu {
	display: flex;
	flex-direction: row;
	justify-content: flex-end;
	align-items: stretch;
	list-style: none;
	margin: 0;
	padding: 0;
}

.nav-menu__item {
	position: relative;
	display: flex;
	align-items: stretch;
}

.nav-menu__link,
.nav-menu__sublink {
	display: flex;
	align-items: center;
	gap: 5px;
	padding: 10px 14px;
	font-family: var(--fda-font-display);
	font-size: 13px;
	font-weight: 500;
	line-height: 18px;
	color: var(--fda-ink);
	fill: var(--fda-ink);
	text-decoration: none;
	white-space: nowrap;
	transition: color 0.3s, background-color 0.3s;
}

.nav-menu__link:hover,
.nav-menu__link:focus,
.nav-menu__link.is-active,
.nav-menu__item:hover > .nav-menu__link {
	color: var(--fda-red);
	fill: var(--fda-red);
}

.nav-menu__caret {
	display: inline-flex;
	align-items: center;
}

.nav-menu__caret .fda-icon {
	width: 14px;
	height: 14px;
	fill: currentColor;
}

.nav-menu__toggle {
	display: none;
}

/* Dropdown ---------------------------------------------------------------- */

.nav-menu__submenu {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 60;
	min-width: 260px;
	margin: 0;
	padding: 0;
	list-style: none;
	background: #ffffff;
	box-shadow: 0 10px 30px rgba(21, 38, 65, 0.18);
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity 0.2s var(--fda-ease), transform 0.2s var(--fda-ease), visibility 0.2s;
}

.nav-menu__item--parent:hover > .nav-menu__submenu,
.nav-menu__item--parent:focus-within > .nav-menu__submenu,
.nav-menu__item--parent.is-open > .nav-menu__submenu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.nav-menu__submenu .nav-menu__item {
	display: block;
}

.nav-menu__sublink {
	display: block;
	padding: 10px 16px;
	white-space: normal;
	color: #152641;
	fill: #152641;
}

.nav-menu__sublink:hover,
.nav-menu__sublink:focus,
.nav-menu__sublink.is-active {
	background: #f6f4ee;
	color: #892943;
}

/* Burger ------------------------------------------------------------------ */

.nav-toggle {
	display: none;
	margin-left: auto;
	padding: 8px 12px;
	border: 1px solid #e8e0cf;
	border-radius: 3px;
	background: transparent;
	color: #152641;
	cursor: pointer;
	line-height: 0;
}

.nav-toggle .fda-icon {
	width: 22px;
	height: 22px;
	fill: #152641;
}

.nav-toggle__close {
	display: none;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__open {
	display: none;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__close {
	display: block;
}

/* --------------------------------------------------------------------------
   Tablet and below - collapse the menu behind the burger
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
	.navbar__inner {
		flex-wrap: wrap;
		align-items: center;
	}

	.brand {
		flex: 1 1 auto;
		order: 1;
	}

	.nav-toggle {
		display: block;
		order: 2;
	}

	.navbar__nav {
		order: 9;
		flex: 1 0 100%;
		display: none;
		padding-top: 10px;
	}

	.navbar__nav.is-open {
		display: block;
	}

	.nav-menu {
		flex-direction: column;
		align-items: stretch;
	}

	.nav-menu__item {
		display: block;
		border-top: 1px solid #e2dfd9;
	}

	.nav-menu__link {
		padding: 11px 4px;
	}

	.nav-menu__caret {
		display: none;
	}

	.nav-menu__toggle {
		display: flex;
		position: absolute;
		top: 4px;
		right: 0;
		align-items: center;
		justify-content: center;
		width: 44px;
		height: 40px;
		padding: 0;
		border: 0;
		background: transparent;
		cursor: pointer;
	}

	.nav-menu__toggle .fda-icon {
		width: 14px;
		height: 14px;
		fill: #152641;
		transition: transform 0.2s var(--fda-ease);
	}

	.nav-menu__toggle[aria-expanded="true"] .fda-icon {
		transform: rotate(180deg);
	}

	.nav-menu__submenu {
		position: static;
		min-width: 0;
		box-shadow: none;
		opacity: 1;
		visibility: visible;
		transform: none;
		display: none;
		background: #ffffff;
	}

	.nav-menu__item--parent.is-open > .nav-menu__submenu {
		display: block;
	}

	.nav-menu__sublink {
		padding: 11px 18px;
	}
}

/* --------------------------------------------------------------------------
   Phones
   -------------------------------------------------------------------------- */

@media (max-width: 767px) {
	.topbar {
		padding: 6px 16px;
	}

	.topbar__inner {
		flex-direction: column;
		gap: 4px;
	}

	.topbar__note,
	.topbar__contact {
		flex: 1 1 100%;
		max-width: 100%;
	}

	.topbar__note p {
		text-align: center;
		line-height: 20px;
		letter-spacing: 0;
		white-space: normal;
	}

	.topbar__contact {
		flex-direction: row;
		flex-wrap: wrap;
		justify-content: center;
		align-items: center;
		width: 100%;
		gap: 3px;
	}

	.topbar__contact::before {
		display: none;
	}

	.contact-list {
		flex-wrap: nowrap;
		justify-content: center;
		gap: 3px;
		margin: 0;
	}

	.contact-list__item {
		margin: 0;
		line-height: 20px;
	}

	.contact-list__item + .contact-list__item::before {
		margin: 0 3px 0 0;
	}

	.contact-list__icon {
		width: 15px;
		height: 14px;
	}

	.contact-list__icon .fda-icon {
		width: 13px;
		height: 13px;
		margin-right: 0;
	}

	.contact-list__text {
		padding-left: 3px;
		font-size: 13.5px;
		line-height: 20px;
		letter-spacing: 0;
		white-space: nowrap;
	}

	.topbar__auth {
		display: flex;
		align-items: center;
		width: auto;
		padding: 0;
	}

	.topbar__rule {
		display: inline-flex;
		margin: 0 3px;
		color: rgba(21, 38, 65, 0.3);
	}

	.topbar__rule::before {
		content: "|";
	}

	.topbar__signin {
		gap: 3px;
		font-size: 13.5px;
		line-height: 20px;
		letter-spacing: 0;
		color: #152641;
		white-space: nowrap;
	}

	.topbar__signin-icon {
		width: 13px;
		height: 20px;
	}

	.topbar__signin .fda-icon {
		width: 13px;
		height: 13px;
	}

	.navbar {
		padding: 1% 3%;
	}

	.brand {
		flex: 0 1 70%;
	}

	.brand__name {
		font-size: 29px;
	}

	img.custom-logo,
	.brand img,
	.brand .custom-logo {
		max-height: 26px !important;
		max-width: 180px !important;
	}
}

/* --------------------------------------------------------------------------
   Desktop - larger preheader and primary nav type
   -------------------------------------------------------------------------- */

@media (min-width: 1025px) {
	.topbar__note p,
	.contact-list__text,
	.topbar__signin {
		font-size: 13px;
		font-weight: 400;
	}

	.nav-menu__link {
		font-size: 14px;
	}
}
