/* =========================================================
   PHPP – style2.css (Layout Authority)
   Fixes:
   - Header never transparent
   - No spacer/clone band beneath header
   - Start medium grey, shrink on scroll
   - Hamburger before wrap
   ========================================================= */

:root {
	--phpp-header-bg:  #242a2f;
	--phpp-header-bg2: #1f2428;
	--phpp-header-pad: 18px;
	--phpp-header-pad-scrolled: 8px;
}

/* Header is sticky; no clone spacer used */
#header.phpp-header {
	position: sticky !important;
	top: 0 !important;
	z-index: 9999 !important;
}

/* Force background on all layers Canvas may use */
#header.phpp-header,
#header.phpp-header #header-wrap,
#header.phpp-header #header-wrap::before,
#header.phpp-header #header-wrap::after {
	background: linear-gradient(180deg, var(--phpp-header-bg), var(--phpp-header-bg2)) !important;
	opacity: 1 !important;
}

#header.phpp-header #header-wrap,
#header.phpp-header #header-wrap::before,
#header.phpp-header #header-wrap::after {
	backdrop-filter: none !important;
	-webkit-backdrop-filter: none !important;
}

/* Header height */
#header.phpp-header #header-wrap {
	position: relative !important;
	padding: var(--phpp-header-pad) 0 !important;
	transition: padding 160ms ease, box-shadow 160ms ease;
}

body.phpp-scrolled #header.phpp-header #header-wrap {
	padding: var(--phpp-header-pad-scrolled) 0 !important;
}

body.phpp-scrolled #header.phpp-header {
	box-shadow: 0 10px 30px rgba(0,0,0,0.35) !important;
}

/* Remove any Canvas clone spacing if present elsewhere */
.header-wrap-clone { display: none !important; }

/* Prevent “extra band” from first section top spacing on pages */
#content .content-wrap {
	padding-top: 0 !important;
}

/* Tagline */
.phpp-tagline {
	opacity: .7;
	font-weight: 600;
	font-size: .95rem;
	color: rgba(255,255,255,.7);
	white-space: nowrap;
}

/* Header row never wraps */
.phpp-header-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: nowrap;
}

/* =========================================================
   MENU
   ========================================================= */

.primary-menu,
.primary-menu ul,
.primary-menu li,
.primary-menu .menu-item {
	float: none !important;
	width: auto !important;
}

.primary-menu .menu-container {
	display: flex;
	align-items: center;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.primary-menu .menu-link {
	display: block;
	text-decoration: none;
	white-space: nowrap;
}

.primary-menu .menu-item.current > .menu-link div {
	font-weight: 800;
}

/* Trigger base */
#primary-menu-trigger {
	display: none;
	align-items: center;
	justify-content: center;
	background: transparent;
	border: 0;
	padding: 6px;
	margin: 0;
	cursor: pointer;
	line-height: 0;
}

#primary-menu-trigger .svg-trigger { width: 34px; height: 34px; }
#primary-menu-trigger .svg-trigger path {
	stroke: #ffffff;
	stroke-width: 6;
	fill: none;
}

/* Breakpoint: hamburger before wrap */
@media (min-width: 1051px) {
	#primary-menu-trigger { display: none !important; }
	.primary-menu { display: block !important; position: static !important; }
	.primary-menu .menu-container { flex-wrap: nowrap !important; }
}

@media (max-width: 1050px) {
	#primary-menu-trigger { display: flex !important; margin-left: auto; }

	.primary-menu {
		display: none !important;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		z-index: 5000;
		padding: 10px 0;
		background: linear-gradient(180deg, var(--phpp-header-bg), var(--phpp-header-bg2)) !important;
		border-top: 1px solid rgba(255,255,255,0.08);
	}

	body.phpp-menu-open .primary-menu,
	body.primary-menu-open .primary-menu { display: block !important; }

	.primary-menu .menu-container {
		flex-direction: column;
		align-items: stretch;
		gap: 0;
	}

	.primary-menu .menu-link {
		padding: 14px 18px;
		border-bottom: 1px solid rgba(255,255,255,0.08);
	}
}
