/* ═══════════════════════════════════════════════════════════
   SECTION NAVIGATION — Icon Bar + Sub-Nav + Flyouts
   ═══════════════════════════════════════════════════════════ */

/* ─── L1: Section Icon Bar ─────────────────────────────── */
.pb-section-nav {
	background: #2c3e5a;
	position: relative;
	z-index: 90;
}

.pb-section-nav__inner {
	max-width: var(--pb-site-container-width, 1400px);
	margin: 0 auto;
	padding: 0 var(--pb-site-container-padding, 2rem);
	display: flex;
	align-items: center;
	gap: 2px;
}

.pb-section-nav__item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 10px 18px;
	border-radius: 8px;
	color: rgba(255,255,255,0.7);
	font-size: 14px;
	font-weight: 500;
	letter-spacing: 0.01em;
	transition: all 0.2s ease;
	position: relative;
	cursor: pointer;
	background: none;
	border: none;
	font-family: inherit;
	white-space: nowrap;
}

.pb-section-nav__item:hover {
	color: #fff;
	background: rgba(255,255,255,0.08);
}

/* Active state — pill background + accent underline */
.pb-section-nav__item.is-active {
	color: var(--section-color, #fff);
	background: rgba(255,255,255,0.1);
}

.pb-section-nav__item.is-active::after {
	content: '';
	position: absolute;
	bottom: -1px;
	left: 12px;
	right: 12px;
	height: 3px;
	border-radius: 3px 3px 0 0;
	background: var(--section-color, #fff);
}

/* Icon */
.pb-section-nav__icon {
	width: 22px;
	height: 22px;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.pb-section-nav__icon svg {
	width: 20px;
	height: 20px;
}


/* ─── L2: Sub-Nav Bar ──────────────────────────────────── */
.pb-subnav {
	display: none;
	border-top: 3px solid var(--section-color, #ccc);
	background: #fff;
	box-shadow: 0 1px 0 rgba(0,0,0,0.08), 0 2px 8px rgba(0,0,0,0.06);
	position: relative;
	z-index: 89;
	font-family: 'Montserrat', sans-serif;
	max-width: var(--pb-site-container-width, 1400px);
	margin-left: auto;
	margin-right: auto;
}

.pb-subnav.is-visible {
	display: block;
}

.pb-subnav__inner {
	max-width: var(--pb-site-container-width, 1400px);
	margin: 0 auto;
	padding: 0 var(--pb-site-container-padding, 2rem);
	display: flex;
	align-items: center;
	gap: 0;
	height: 42px;
	overflow: visible;
}


/* First item left edge aligns with logo and container padding */
.pb-subnav__inner > :first-child {
	margin-left: 0;
}

/* ─── Sub-Nav Groups ──────────────────────────────────── */
.pb-subnav__group {
	display: flex;
	align-items: center;
	gap: 0;
	position: relative;
}

/* Separator between groups */
.pb-subnav__group + .pb-subnav__group::before {
	content: '';
	width: 1px;
	height: 20px;
	background: #ddd;
	margin: 0 4px;
	flex-shrink: 0;
}


/* ─── Sub-Nav Links ────────────────────────────────────── */
.pb-subnav__link {
	display: flex;
	align-items: center;
	gap: 4px;
	padding: 8px 14px;
	color: #333;
	text-decoration: none;
	font-size: 13px;
	font-weight: 600;
	line-height: normal;
	border-radius: 6px;
	transition: all 0.15s;
	white-space: nowrap;
	position: relative;
}

.pb-subnav__link:hover {
	background: #f5f5f5;
	color: #222;
}

/* Parent indicator (has flyout) — small chevron */
.pb-subnav__link--parent::after {
	content: '';
	width: 0;
	height: 0;
	border-left: 3.5px solid transparent;
	border-right: 3.5px solid transparent;
	border-top: 4px solid currentColor;
	opacity: 0.5;
	margin-left: 2px;
}

/* CTA link — right-aligned, darker section color for readability */
.pb-subnav__link--cta {
	font-weight: 600;
	margin-left: auto;
	color: color-mix(in oklch, var(--section-color, #555) 70%, black);
}

.pb-subnav__link--cta:hover {
	background: transparent;
	color: color-mix(in oklch, var(--section-color, #333) 50%, black);
}


/* ─── Highlight Styles (applied to the label link itself) ─ */

/* Bold — heavier font weight */
.pb-subnav__link--bold,
.pb-subnav__flyout-link--bold {
	font-weight: 700;
}

/* Gold — brand amber color */
.pb-subnav__link--gold {
	color: #b8860b;
}
.pb-subnav__link--gold:hover {
	color: #8b6508;
}
.pb-subnav__flyout-link--gold {
	color: #b8860b;
}

/* Pill — colored background pill on the link */
.pb-subnav__link--pill {
	background: #e53e3e;
	color: #fff;
	font-weight: 600;
	border-radius: 8px;
	padding: 6px 14px;
}
.pb-subnav__link--pill:hover {
	background: #c53030;
	color: #fff;
}

/* Underline — gold accent underline */
.pb-subnav__link--underline {
	border-bottom: 2px solid #d4a017;
	border-radius: 0;
	padding-bottom: 6px;
}

/* Flyout highlight styles */
.pb-subnav__flyout-link--pill {
	background: #fef2f2;
	color: #c53030;
	font-weight: 600;
	border-radius: 4px;
	margin: 2px 6px;
	padding: 6px 10px;
}
.pb-subnav__flyout-link--underline {
	border-bottom: 1px solid #d4a017;
}


/* ─── L3: Flyout Dropdown ──────────────────────────────── */
.pb-subnav__flyout-wrap {
	position: relative;
}

.pb-subnav__flyout {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 240px;
	background: #fff;
	border: 1px solid #e8e8e8;
	border-radius: 8px;
	box-shadow: 0 8px 24px rgba(0,0,0,0.12);
	padding: 6px 0;
	z-index: 110;
	margin-top: 4px;
}

/* Invisible bridge covers the gap between trigger and flyout */
.pb-subnav__flyout::before {
	content: '';
	position: absolute;
	top: -10px;
	left: 0;
	right: 0;
	height: 10px;
}

.pb-subnav__flyout-wrap:hover .pb-subnav__flyout {
	display: block;
}

.pb-subnav__flyout-link {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 8px 16px;
	color: #444;
	text-decoration: none;
	font-size: 13px;
	font-weight: 400;
	transition: background 0.12s;
}

.pb-subnav__flyout-link:hover {
	background: #f5f5f5;
	color: #111;
}

/* ─── Mega Menu Panel (multi-column flyout) ───────────── */
.pb-subnav__flyout-wrap--mega {
	position: relative;
}

.pb-subnav__mega {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	background: #fff;
	border: 1px solid #e2e2e2;
	border-top: 3px solid var(--section-color, #888);
	border-radius: 0 8px 8px 8px;
	box-shadow: 0 8px 24px rgba(0,0,0,0.10);
	padding: 20px 28px 24px;
	z-index: 110;
	margin-top: 4px;
	grid-template-columns: repeat(var(--mega-cols, 2), minmax(200px, max-content));
	gap: 4px 8px;
}

/* Invisible bridge */
.pb-subnav__mega::before {
	content: '';
	position: absolute;
	top: -10px;
	left: 0;
	right: 0;
	height: 10px;
}

.pb-subnav__flyout-wrap--mega:hover .pb-subnav__mega {
	display: grid;
}

.pb-subnav__mega-col {
	display: flex;
	flex-direction: column;
	min-width: 200px;
}

/* Vertical separator between columns */
.pb-subnav__mega-col + .pb-subnav__mega-col {
	border-left: 1px solid #eee;
	padding-left: 40px;
}

.pb-subnav__mega-title {
	display: block;
	padding: 4px 0 8px;
	color: color-mix(in oklch, var(--section-color, #333) 70%, black);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	text-decoration: none;
	border-bottom: 2px solid color-mix(in oklch, var(--section-color, #ddd) 40%, transparent);
	margin-bottom: 6px;
}
.pb-subnav__mega-title:hover {
	color: color-mix(in oklch, var(--section-color, #222) 85%, black);
}

/* Mega title highlight styles */
.pb-subnav__mega-title--bold { font-weight: 800; }
.pb-subnav__mega-title--gold { color: #b8860b; }
.pb-subnav__mega-title--pill {
	background: #e53e3e;
	color: #fff;
	padding: 4px 10px;
	border-radius: 4px;
	border-bottom: none;
}

.pb-subnav__mega-link {
	display: block;
	padding: 6px 8px;
	color: #555;
	text-decoration: none;
	font-size: 13px;
	font-weight: 400;
	border-radius: 4px;
	transition: all 0.12s;
	white-space: nowrap;
}
.pb-subnav__mega-link:hover {
	background: color-mix(in oklch, var(--section-color, #f5f5f5) 12%, white);
	color: #111;
}

/* Mega link highlight styles */
.pb-subnav__mega-link--bold { font-weight: 700; }
.pb-subnav__mega-link--gold { color: #b8860b; }
.pb-subnav__mega-link--pill {
	background: #fef2f2;
	color: #c53030;
	font-weight: 600;
	padding: 4px 8px;
	border-radius: 4px;
}


/* ─── Section Mega Panels (icon-hover preview) ─────────── */
.pb-section-mega {
	display: none;
	position: absolute;
	top: 72px; /* Small gap below primary bar */
	left: 2rem; /* JS overrides to centre under icon */
	width: fit-content;
	max-width: calc(100% - 2 * var(--pb-site-container-padding, 2rem));
	z-index: 95; /* Above sub-nav (89), below header controls */
	background: #fff;
	border: 1px solid #e2e2e2;
	border-top: 3px solid var(--section-color, #ccc);
	border-radius: 0 0 12px 12px;
	box-shadow: 0 12px 36px rgba(0,0,0,0.15);
	font-family: 'Montserrat', sans-serif;
}

.pb-section-mega.is-visible {
	display: block;
}

.pb-section-mega__inner {
	padding: 20px 24px 16px;
}

.pb-section-mega__grid {
	display: flex;
	gap: 4px 0;
}

.pb-section-mega__col {
	display: flex;
	flex-direction: column;
	flex: 1 1 0;
	padding: 0 12px;
	min-width: 140px;
}

/* Vertical separator between columns */
.pb-section-mega__col + .pb-section-mega__col {
	border-left: 1px solid #eee;
}

.pb-section-mega__title {
	display: block;
	padding: 4px 0 6px;
	color: color-mix(in oklch, var(--section-color, #333) 70%, black);
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	text-decoration: none;
	border-bottom: 2px solid color-mix(in oklch, var(--section-color, #ddd) 40%, transparent);
	margin-bottom: 4px;
}

.pb-section-mega__title:hover {
	color: color-mix(in oklch, var(--section-color, #222) 85%, black);
}

/* Highlight modifiers for titles */
.pb-section-mega__title--bold { font-weight: 800; }
.pb-section-mega__title--gold { color: #b8860b; }
.pb-section-mega__title--pill {
	background: #e53e3e;
	color: #fff;
	padding: 4px 10px;
	border-radius: 4px;
	border-bottom: none;
}

.pb-section-mega__link {
	display: block;
	padding: 4px 0;
	color: #555;
	text-decoration: none;
	font-size: 13px;
	font-weight: 400;
	border-radius: 4px;
	transition: color 0.12s;
}

.pb-section-mega__link:hover {
	color: color-mix(in oklch, var(--section-color, #111) 80%, black);
}

/* Highlight modifiers for links */
.pb-section-mega__link--bold { font-weight: 700; }
.pb-section-mega__link--gold { color: #b8860b; }
.pb-section-mega__link--pill {
	background: #fef2f2;
	color: #c53030;
	font-weight: 600;
	padding: 4px 8px;
	border-radius: 4px;
}
.pb-section-mega__link--underline {
	border-bottom: 1px solid #d4a017;
	border-radius: 0;
}

/* CTA footer bar */
.pb-section-mega__footer {
	border-top: 1px solid #eee;
	margin-top: 12px;
	padding-top: 10px;
	display: flex;
	gap: 24px;
}

.pb-section-mega__cta {
	color: color-mix(in oklch, var(--section-color, #555) 70%, black);
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
	transition: color 0.12s;
}

.pb-section-mega__cta:hover {
	color: color-mix(in oklch, var(--section-color, #333) 50%, black);
}


/* ─── Short Labels (mobile-friendly names) ────────────── */
.pb-section-nav__label .label-short { display: none; }
@media (max-width: 1024px) {
	.pb-section-nav__label .label-full { display: none; }
	.pb-section-nav__label .label-short { display: inline; }
}


/* ─── Responsive ───────────────────────────────────────── */
@media (max-width: 1024px) {
	.pb-section-nav__item {
		padding: 8px 12px;
		font-size: 13px;
	}

	.pb-subnav__inner {
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}

	.pb-subnav__inner::-webkit-scrollbar {
		display: none;
	}
}

/* Muted nav items (coming soon tools) */
.pb-section-mega__link--muted,
.pb-subnav__flyout-link--muted {
	opacity: 0.4;
	cursor: default;
	pointer-events: none;
}

@media (max-width: 1024px) {
	/* Hide mega panels on tablet/mobile */
	.pb-section-mega {
		display: none !important;
	}
}

@media (max-width: 768px) {
	/* Hide section nav and subnav on mobile — mobile uses drawer */
	.pb-section-nav,
	.pb-subnav {
		display: none !important;
	}
}
