/* ==========================================================================
   LCA Header rebuild (2026)
   Scoped under body.lca-header-2026. Parent theme sets html{font-size:62.5%},
   so this file uses px — never bare rem. Loads after style.css, so equal-
   specificity rules here win; a few legacy rules need explicit overrides.
   ========================================================================== */

.lca-header-2026 {
	--lca-navy: #0b2a4a;
	--lca-navy-deep: #081f38;
	--lca-red: #c8102e;
	--lca-ink: #1a2230;
	--lca-muted: #5b6573;
	--lca-line: #e6eaf0;
	--lca-hover: #f5f8fc;
	--lca-font: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---- Kill legacy artefacts ---------------------------------------------- */
.lca-header-2026 .header-bar,
.lca-header-2026 .alert-bar,
.lca-header-2026 .sfm-navicon-button,
.lca-header-2026 .sfm-sidebar { display: none !important; }

/* ---- Dark navy bar across the very top of the site ---------------------- */
.lca-header-2026 .site-header::before {
	content: "";
	display: block;
	height: 8px;
	background: linear-gradient(90deg, var(--lca-navy-deep) 0%, var(--lca-navy) 60%, #123a63 100%);
}

/* ---- Header shell (override legacy min-height/padding) ------------------ */
.lca-header-2026 .site-header {
	background: #fff;
	min-height: 0;
	border-bottom: 1px solid var(--lca-line);
	box-shadow: 0 2px 10px -6px rgba(9, 20, 34, 0.12);
	position: relative;
	z-index: 90;
}
.lca-header-2026 .site-header > .wrap {
	display: flex;
	align-items: center;
	gap: 28px;
	min-height: 84px;
	padding: 0;
	position: relative;   /* dropdowns anchor to the header row, not the item */
}
@media (max-width: 960px) {
	.lca-header-2026 .site-header > .wrap { padding: 0 16px; gap: 14px; }
}

/* ---- Logo / title-area (override legacy float/width) -------------------- */
.lca-header-2026 .title-area {
	float: none;
	flex: 0 0 auto;
	margin: 0;
	padding: 0;
	width: auto;
	max-width: 320px;
}
.lca-header-2026 .site-title {
	margin: 0;
	font-family: var(--lca-font);
	font-size: 22px;
	line-height: 1.12;
	font-weight: 800;
	letter-spacing: -0.01em;
}
.lca-header-2026 .site-title a,
.lca-header-2026 .site-title a:focus {
	color: var(--lca-navy);
	text-decoration: none;
}
.lca-header-2026 .site-title a:hover { color: var(--lca-red); }
.lca-header-2026 .site-description {
	margin: 2px 0 0;
	font-family: var(--lca-font);
	font-size: 12.5px;
	font-weight: 500;
	font-style: italic;
	color: var(--lca-muted);
	line-height: 1.3;
}
.lca-header-2026 .title-area .custom-logo-link { display: inline-block; }
.lca-header-2026 .title-area .custom-logo { max-height: 60px; width: auto; height: auto; }

/* Genesis "header-image" mode: the logo is a CSS background on the
   site-title link with its text indented away. The legacy rule relied on
   .title-area{width:360px}, which the flex layout above removes — so size
   it explicitly here, and serve the logo from THIS site, not live. */
.lca-header-2026.header-image .title-area {
	flex: 0 0 310px;
	width: 310px;
	max-width: 310px;
}
.lca-header-2026.header-image .site-title > a {
	display: block;
	float: none;
	width: 100%;
	min-height: 76px;
	background: url("/wp-content/uploads/2026/05/LCA-logo_Horizontal-2-Colour.png") no-repeat left center;
	background-size: contain;
}
.lca-header-2026.header-image .site-description { display: none; }
@media (max-width: 700px) {
	/* allow the logo to shrink so the icon cluster never overflows */
	.lca-header-2026.header-image .title-area { flex: 0 1 230px; width: 230px; min-width: 150px; }
	.lca-header-2026.header-image .site-title > a { min-height: 54px; }
}
@media (max-width: 400px) {
	.lca-header-2026.header-image .title-area { flex-basis: 175px; width: 175px; min-width: 130px; }
	.lca-header-2026.header-image .site-title > a { min-height: 48px; }
}

/* ---- Right cluster: nav (left-aligned) + search (far right) ------------- */
.lca-header-2026 .header-widget-area,
.lca-header-2026 .site-header .widget-area {
	float: none;
	flex: 1 1 auto;
	align-self: stretch;           /* nav items reach the header's bottom edge */
	display: flex;
	align-items: center;
	justify-content: flex-start;   /* menu items sit next to the logo */
	gap: 8px;
	width: auto;
	max-width: none;
	margin: 0;
	text-align: left;
	font-family: var(--lca-font);
}
/* search icon pinned to the far right of the row */
.lca-header-2026 .site-header .lca-search-toggle { margin-left: auto; }

/* ---- Primary nav (desktop) ---------------------------------------------- */
.lca-header-2026 .lca-nav { display: flex; align-self: stretch; }
.lca-header-2026 .lca-nav__drawer-head { display: none; }
.lca-header-2026 .lca-nav__menu {
	display: flex;
	align-items: stretch;
	height: 100%;
	gap: 2px;
	margin: 0;
	padding: 0;
	list-style: none;
}
.lca-header-2026 .lca-nav__menu .menu-item {
	margin: 0;
	padding: 0;
	list-style: none;
}
.lca-header-2026 .lca-nav__menu > .menu-item { display: flex; }
.lca-header-2026 .lca-nav__menu a {
	display: flex;
	align-items: center;
	gap: 7px;
	padding: 12px 15px;
	font-family: var(--lca-font);
	font-size: 14.5px;
	font-weight: 600;
	line-height: 1.2;
	color: var(--lca-ink);
	text-decoration: none;
	border-radius: 9px;
	white-space: nowrap;
	border: 0;
	transition: color 0.15s ease, background-color 0.15s ease;
}
.lca-header-2026 .lca-nav__menu > .menu-item > a {
	text-transform: uppercase;
	letter-spacing: 0.03em;
	font-size: 13.5px;
	font-weight: 700;
	border-radius: 0;   /* full-height items: square hover highlight */
}
.lca-header-2026 .lca-nav__menu a:hover,
.lca-header-2026 .lca-nav__menu a:focus-visible,
.lca-header-2026 .lca-nav__menu .menu-item.is-open > a {
	color: var(--lca-red);
	background: var(--lca-hover);
	outline: none;
}
.lca-header-2026 .lca-nav__menu .current-menu-item > a,
.lca-header-2026 .lca-nav__menu .current-menu-ancestor > a {
	color: var(--lca-red);
}

/* Dropdown caret on parents */
.lca-header-2026 .lca-nav__menu .menu-item-has-children > a::after {
	content: "";
	flex: 0 0 auto;
	width: 7px;
	height: 7px;
	margin-top: -3px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform 0.15s ease;
	opacity: 0.55;
}
.lca-header-2026 .lca-nav__menu .menu-item-has-children:hover > a::after,
.lca-header-2026 .lca-nav__menu .menu-item-has-children.is-open > a::after { opacity: 1; }

/* ---- Sub-menus (desktop dropdown) ---------------------------------------
   Top-level .menu-item is unpositioned, so the absolute sub-menu anchors to
   the header row (.site-header > .wrap, position:relative): top:100% lands
   flush with the bottom of the header. Horizontal placement comes from the
   item's static position, keeping each dropdown under its parent item. ---- */
.lca-header-2026 .lca-nav__menu .sub-menu {
	position: absolute;
	top: 100%;
	min-width: 270px;
	margin: 0;
	padding: 8px;
	list-style: none;
	background: #fff;
	border: 1px solid var(--lca-line);
	border-top: 3px solid var(--lca-red);
	border-radius: 0 0 14px 14px;
	box-shadow: 0 24px 48px -16px rgba(9, 20, 34, 0.32);
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
	z-index: 95;
}
.lca-header-2026 .lca-nav__menu .menu-item:hover > .sub-menu,
.lca-header-2026 .lca-nav__menu .menu-item:focus-within > .sub-menu,
.lca-header-2026 .lca-nav__menu .menu-item.is-open > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.lca-header-2026 .lca-nav__menu .sub-menu .menu-item { padding: 0; }
.lca-header-2026 .lca-nav__menu .sub-menu a {
	display: block;
	padding: 10px 14px;
	font-size: 14px;
	font-weight: 500;
	text-transform: none;
	letter-spacing: 0;
	color: var(--lca-ink);
	border-radius: 8px;
	white-space: normal;
	line-height: 1.35;
}
.lca-header-2026 .lca-nav__menu .sub-menu a:hover,
.lca-header-2026 .lca-nav__menu .sub-menu a:focus-visible {
	color: var(--lca-red);
	background: var(--lca-hover);
}

/* ---- Account / quick-links dropdown (person icon) ------------------------ */
.lca-header-2026 .lca-account {
	position: relative;
	flex: 0 0 auto;
}
.lca-header-2026 .lca-account__toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	padding: 0;
	color: var(--lca-navy);
	background: transparent;
	border: 1.5px solid var(--lca-line);
	border-radius: 999px;
	cursor: pointer;
	transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease, transform 0.12s ease;
}
.lca-header-2026 .lca-account__toggle:hover,
.lca-header-2026 .lca-account__toggle:focus-visible,
.lca-header-2026 .lca-account.is-open .lca-account__toggle {
	color: var(--lca-red);
	background: var(--lca-hover);
	border-color: var(--lca-red);
	outline: none;
}
.lca-header-2026 .lca-account__toggle:active { transform: scale(0.96); }

.lca-header-2026 .lca-account__menu {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	min-width: 200px;
	padding: 8px;
	background: #fff;
	border: 1px solid var(--lca-line);
	border-top: 3px solid var(--lca-red);
	border-radius: 0 0 14px 14px;
	box-shadow: 0 24px 48px -16px rgba(9, 20, 34, 0.32);
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
	z-index: 96;
}
.lca-header-2026 .lca-account.is-open .lca-account__menu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.lca-header-2026 .lca-account__menu a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 11px 14px;
	font-family: var(--lca-font);
	font-size: 14px;
	font-weight: 600;
	color: var(--lca-ink);
	text-decoration: none;
	border: 0;
	border-radius: 8px;
	white-space: nowrap;
	transition: color 0.13s ease, background-color 0.13s ease;
}
.lca-header-2026 .lca-account__menu a:hover,
.lca-header-2026 .lca-account__menu a:focus-visible {
	color: var(--lca-red);
	background: var(--lca-hover);
	outline: none;
}
.lca-header-2026 .lca-account__menu a svg { opacity: 0.45; flex: 0 0 auto; }
.lca-header-2026 .lca-account__menu a:hover svg { opacity: 1; }

/* ---- Mobile toggle (hamburger, hidden on desktop) ------------------------ */
.lca-header-2026 .lca-nav-toggle {
	display: none;
	align-items: center;
	gap: 9px;
	padding: 10px 13px;
	font-family: var(--lca-font);
	font-size: 14px;
	font-weight: 700;
	color: var(--lca-navy);
	background: transparent;
	border: 1.5px solid var(--lca-line);
	border-radius: 999px;
	cursor: pointer;
	transition: border-color 0.15s ease, color 0.15s ease;
}
.lca-header-2026 .lca-nav-toggle:hover,
.lca-header-2026 .lca-nav-toggle:focus-visible { color: var(--lca-red); border-color: var(--lca-red); outline: none; }
.lca-header-2026 .lca-nav-toggle__bars { position: relative; width: 20px; height: 14px; flex: 0 0 auto; }
.lca-header-2026 .lca-nav-toggle__bars span {
	position: absolute;
	left: 0;
	width: 100%;
	height: 2px;
	background: currentColor;
	border-radius: 2px;
	transition: transform 0.2s ease, opacity 0.2s ease, top 0.2s ease;
}
.lca-header-2026 .lca-nav-toggle__bars span:nth-child(1) { top: 0; }
.lca-header-2026 .lca-nav-toggle__bars span:nth-child(2) { top: 6px; }
.lca-header-2026 .lca-nav-toggle__bars span:nth-child(3) { top: 12px; }
.lca-header-2026 .lca-nav-toggle[aria-expanded="true"] .lca-nav-toggle__bars span:nth-child(1) { top: 6px; transform: rotate(45deg); }
.lca-header-2026 .lca-nav-toggle[aria-expanded="true"] .lca-nav-toggle__bars span:nth-child(2) { opacity: 0; }
.lca-header-2026 .lca-nav-toggle[aria-expanded="true"] .lca-nav-toggle__bars span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

/* ==========================================================================
   Mobile: off-canvas drawer
   ========================================================================== */
@media (max-width: 1100px) {
	.lca-header-2026 .lca-nav-toggle { display: inline-flex; order: 4; }
	.lca-header-2026 .site-header .lca-search-toggle { order: 2; margin-left: auto; }
	.lca-header-2026 .lca-account { order: 3; }

	.lca-header-2026 .lca-nav {
		display: block;
		position: fixed;
		top: 0;
		right: 0;
		bottom: 0;
		left: auto;
		width: min(360px, 88vw);
		height: 100%;
		background: #fff;
		box-shadow: -16px 0 48px -14px rgba(9, 20, 34, 0.4);
		transform: translateX(102%);
		transition: transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1);
		overflow-y: auto;
		-webkit-overflow-scrolling: touch;
		z-index: 100010;
		padding: 0 0 32px;
	}
	.lca-header-2026 .lca-nav.is-open { transform: translateX(0); }

	body.lca-nav-open { overflow: hidden; }
	body.lca-nav-open::after {
		content: "";
		position: fixed;
		inset: 0;
		background: rgba(9, 20, 34, 0.55);
		backdrop-filter: blur(2px);
		z-index: 100005;
	}

	/* Drawer header */
	.lca-header-2026 .lca-nav__drawer-head {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 16px 18px;
		background: var(--lca-navy);
		color: #fff;
		position: sticky;
		top: 0;
		z-index: 2;
	}
	.lca-header-2026 .lca-nav__drawer-title {
		font-family: var(--lca-font);
		font-size: 15px;
		font-weight: 700;
		text-transform: uppercase;
		letter-spacing: 0.08em;
	}
	.lca-header-2026 .lca-nav__close {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 38px;
		height: 38px;
		padding: 0;
		color: #fff;
		background: rgba(255, 255, 255, 0.12);
		border: 0;
		border-radius: 999px;
		cursor: pointer;
		transition: background-color 0.15s ease;
	}
	.lca-header-2026 .lca-nav__close:hover,
	.lca-header-2026 .lca-nav__close:focus-visible { background: var(--lca-red); outline: none; }

	/* Drawer menu list */
	.lca-header-2026 .lca-nav__menu {
		display: block;
		height: auto;
		padding: 8px 12px 0;
	}
	.lca-header-2026 .lca-nav__menu .menu-item,
	.lca-header-2026 .lca-nav__menu > .menu-item {
		display: block;
		position: static;
		border-bottom: 1px solid var(--lca-line);
	}
	.lca-header-2026 .lca-nav__menu .menu-item:last-child { border-bottom: 0; }
	.lca-header-2026 .lca-nav__menu a {
		display: flex;
		padding: 15px 10px;
		border-radius: 0;
		white-space: normal;
		font-size: 15px;
	}
	.lca-header-2026 .lca-nav__menu > .menu-item > a { font-size: 15px; }
	.lca-header-2026 .lca-nav__menu .current-menu-item > a,
	.lca-header-2026 .lca-nav__menu .current-menu-ancestor > a { color: var(--lca-red); }

	/* Accordion sub-menus */
	.lca-header-2026 .lca-nav__menu .sub-menu {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		min-width: 0;
		padding: 0;
		margin: 0;
		background: #f8fafd;
		border-radius: 10px;
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.28s ease, margin 0.28s ease;
	}
	.lca-header-2026 .lca-nav__menu .sub-menu::before { display: none; }
	.lca-header-2026 .lca-nav__menu .menu-item.is-open > .sub-menu {
		max-height: 1600px;
		margin: 0 0 12px;
	}
	.lca-header-2026 .lca-nav__menu .sub-menu .menu-item { border-bottom: 0; padding: 0; }
	.lca-header-2026 .lca-nav__menu .sub-menu a {
		padding: 12px 16px;
		font-size: 14px;
		color: var(--lca-muted);
	}
	.lca-header-2026 .lca-nav__menu .sub-menu a:hover { color: var(--lca-red); background: transparent; }
	.lca-header-2026 .lca-nav__menu .menu-item-has-children > a::after { margin-left: auto; margin-top: 0; }
	.lca-header-2026 .lca-nav__menu .menu-item-has-children.is-open > a::after { transform: rotate(225deg); }
}

@media (min-width: 1101px) {
	.lca-header-2026 .lca-nav { position: static; transform: none; }
	/* account dropdown also opens flush with the header bottom */
	.lca-header-2026 .lca-account { position: static; }
	.lca-header-2026 .lca-account__menu { top: 100%; }
}

/* Small screens: icon-only hamburger so nothing hangs off the edge */
@media (max-width: 700px) {
	.lca-header-2026 .lca-nav-toggle {
		width: 42px;
		height: 42px;
		padding: 0;
		justify-content: center;
		gap: 0;
	}
	.lca-header-2026 .lca-nav-toggle__label {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
		clip-path: inset(50%);
	}
	.lca-header-2026 .header-widget-area,
	.lca-header-2026 .site-header .widget-area { gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
	.lca-header-2026 .lca-nav,
	.lca-header-2026 .lca-nav__menu .sub-menu { transition: none; }
}
