/* ==========================================================================
   One Horizon — Navigation (horizon-nav-ux)
   Loaded only when a step file is present. Every rule targets markup that a
   step prints (.hznux-*, [data-hznux-*], #vs-nav-more), so this file alone
   changes nothing. Ship changes under a NEW file name (nav-ux.2.css) and bump
   HZNUX_CSS: the caches ignore ?ver=.

   House rules followed here: dark glass, cyan as an accent only; light theme
   via html[data-horizon-theme="light"]; targets 44px or taller; no control
   that appears only on hover; visible keyboard focus; nothing changes size
   after first paint; no backdrop-filter.
   ========================================================================== */

.hznux-guide,
.hznux-pills,
.hznux-help,
.hznux-signin-help,
.hznux-lesson-tour,
.hznux-more {
	--nx-ink: rgba(255, 255, 255, 0.92);
	--nx-ink-2: rgba(255, 255, 255, 0.68);
	--nx-line: rgba(255, 255, 255, 0.14);
	--nx-fill: rgba(255, 255, 255, 0.045);
	--nx-fill-2: rgba(255, 255, 255, 0.085);
	--nx-accent: #06d6f7;
	--nx-accent-ink: #8ae6ff;
}
html[data-horizon-theme="light"] .hznux-guide,
html[data-horizon-theme="light"] .hznux-pills,
html[data-horizon-theme="light"] .hznux-help,
html[data-horizon-theme="light"] .hznux-signin-help,
html[data-horizon-theme="light"] .hznux-lesson-tour {
	--nx-ink: #23201a;
	--nx-ink-2: rgba(35, 32, 26, 0.7);
	--nx-line: rgba(35, 32, 26, 0.16);
	--nx-fill: rgba(35, 32, 26, 0.035);
	--nx-fill-2: rgba(35, 32, 26, 0.07);
	--nx-accent: #0a7d95;
	--nx-accent-ink: #0a6478;
}

/* --------------------------------------------------------------------------
   The guidance entry: "Have Visor walk me through this" / "Visor can call you"
   One component, the same on every surface.
   -------------------------------------------------------------------------- */
.hznux-guide {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 8px 10px;
	margin: 0 0 12px;
	padding: 0;
}
.hznux-guide__lead {
	margin-right: auto;
	font-size: 15px;
	line-height: 1.4;
	color: var(--nx-ink-2);
}
html body .hznux-guide__btn {
	-webkit-appearance: none;
	appearance: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	box-sizing: border-box;
	min-height: 44px;
	margin: 0;
	padding: 0 18px;
	border: 1px solid var(--nx-line);
	border-radius: 999px;
	background: var(--nx-fill);
	color: var(--nx-ink);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: 0.005em;
	text-align: left;
	text-transform: none;
	text-decoration: none;
	white-space: normal;
	cursor: pointer;
	box-shadow: none;
	transition: background-color 0.18s ease, border-color 0.18s ease;
}
html body .hznux-guide__btn svg {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	color: var(--nx-accent);
	stroke: currentColor;
}
html body .hznux-guide__btn:hover {
	background: var(--nx-fill-2);
	border-color: var(--nx-accent);
	color: var(--nx-ink);
	transform: none;
}
html body .hznux-guide__btn:focus-visible {
	outline: 2px solid var(--nx-accent) !important;
	outline-offset: 3px !important;
}
html body .hznux-guide__btn:active { background: var(--nx-fill-2); }

/* Expert dashboard: the entry sits just above its panel, at the right, in line
   with the panel's inner edge (24px card padding). */
.hsd-panel > .hznux-guide { margin: 4px 24px 10px; }
/* Client dashboard: directly under the tab strip. */
.hcd-wrap .hznux-guide,
.hcd-tabs + .hznux-guide { margin: 14px 2px 6px; }
/* Lesson sidebar: full width, under the session card. */
#mpcs-sidebar .hznux-guide { justify-content: stretch; margin: 12px 16px 4px; }
#mpcs-sidebar .hznux-guide .hznux-guide__btn { width: 100%; justify-content: flex-start; border-radius: 14px; padding: 10px 14px; }

@media (max-width: 600px) {
	.hznux-guide { justify-content: stretch; }
	.hznux-guide .hznux-guide__btn { flex: 1 1 100%; justify-content: flex-start; border-radius: 14px; padding: 10px 14px; }
}

/* --------------------------------------------------------------------------
   Course page pill row
   -------------------------------------------------------------------------- */
/* Step A: the back link leads the row, at the left; the rest stay right. */
.mpcs-course-action-buttons > .hznux-pill-back { margin-right: auto !important; }
html body .mpcs-course-action-buttons .hznux-pill-back {
	display: inline-flex !important;
	align-items: center;
	gap: 6px;
}
html body .mpcs-course-action-buttons .hznux-pill-back svg {
	flex: 0 0 auto;
	width: 14px;
	height: 14px;
	margin-left: -4px;
}
/* Step C: two groups. Places to go on the left, tools on the right. */
.mpcs-course-action-buttons > .hznux-pills {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 12px;
	margin: 0;
	padding: 0;
	min-width: 0;
}
.mpcs-course-action-buttons > .hznux-pills--nav { margin-right: auto; }
.mpcs-course-action-buttons > .hznux-pills--tools { justify-content: flex-end; }
html body .mpcs-course-action-buttons .resource-btn:focus-visible,
html body .mpcs-course-action-buttons .hznux-pills .resource-btn:focus-visible {
	outline: 2px solid var(--nx-accent, #06d6f7) !important;
	outline-offset: 3px !important;
}
@media (pointer: coarse) {
	html body .mpcs-course-action-buttons .hznux-pills .resource-btn,
	html body .mpcs-course-action-buttons .hznux-pill-back {
		min-height: 44px !important;
		display: inline-flex !important;
		align-items: center !important;
	}
}
/* Phones: slightly narrower pills so the three places share one line. */
@media (max-width: 480px) {
	.mpcs-course-action-buttons > .hznux-pills { gap: 8px; }
	html body.hzlms.single-mpcs-course .mpcs-course-action-buttons .hznux-pills a.resource-btn,
	html body.hzlms.single-mpcs-course .mpcs-course-action-buttons .hznux-pills button.resource-btn {
		padding-left: 14px !important;
		padding-right: 14px !important;
	}
}

/* --------------------------------------------------------------------------
   Lesson sidebar link tiles. "My account" is longer than "Home" was; a little
   less air keeps the three tiles on one line at the widths where they were on
   one line before, so the sidebar keeps its height and the lesson list does
   not move.
   -------------------------------------------------------------------------- */
html body.hzlms-lesson #mpcs-sidebar .all-action-buttons .mpcs-sidebar-resources.hznux-links a.tile {
	margin: 8px 3px !important;
	padding: 10px 16px !important;
}

/* --------------------------------------------------------------------------
   Lesson sidebar: the Tour button, quiet, at the foot of the sidebar
   -------------------------------------------------------------------------- */
.hznux-lesson-tour { margin: 8px 16px 20px; padding: 0; }
html body .hznux-quiet-btn {
	-webkit-appearance: none;
	appearance: none;
	display: flex;
	align-items: center;
	gap: 9px;
	box-sizing: border-box;
	width: 100%;
	min-height: 44px;
	margin: 0;
	padding: 10px 14px;
	border: 1px solid var(--nx-line);
	border-radius: 14px;
	background: transparent;
	color: var(--nx-ink-2);
	font-size: 15px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: 0.005em;
	text-align: left;
	text-transform: none;
	cursor: pointer;
	box-shadow: none;
	transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}
html body .hznux-quiet-btn svg { flex: 0 0 auto; width: 18px; height: 18px; color: var(--nx-accent); }
html body .hznux-quiet-btn:hover { background: var(--nx-fill); border-color: var(--nx-accent); color: var(--nx-ink); transform: none; }
html body .hznux-quiet-btn:focus-visible { outline: 2px solid var(--nx-accent) !important; outline-offset: 3px !important; }

/* --------------------------------------------------------------------------
   Help page for members and client accounts
   -------------------------------------------------------------------------- */
.hznux-help {
	box-sizing: border-box;
	max-width: 760px;
	margin: 0 auto;
	padding: 40px 20px 80px;
	color: var(--nx-ink);
}
.hznux-help__eyebrow {
	margin: 0 0 10px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--nx-accent);
}
html body .hznux-help .hznux-help__title {
	margin: 0 0 12px;
	font-size: 34px;
	line-height: 1.15;
	color: var(--nx-ink);
}
.hznux-help__intro {
	margin: 0 0 18px;
	font-size: 17px;
	line-height: 1.55;
	color: var(--nx-ink-2);
}
.hznux-help__ask { margin: 0 0 28px; }
.hznux-help__list { border-top: 1px solid var(--nx-line); }
.hznux-help__item { padding: 20px 0; border-bottom: 1px solid var(--nx-line); }
html body .hznux-help .hznux-help__item h2 {
	margin: 0 0 6px;
	font-size: 19px;
	line-height: 1.3;
	color: var(--nx-ink);
}
.hznux-help__item p {
	margin: 0;
	font-size: 17px;
	line-height: 1.6;
	color: var(--nx-ink-2);
}
.hznux-help__item p strong { color: var(--nx-ink); font-weight: 600; }
.hznux-help__contact { margin: 24px 0 0; font-size: 17px; line-height: 1.6; color: var(--nx-ink-2); }
.hznux-help__contact a { color: var(--nx-accent-ink); text-decoration: underline; text-underline-offset: 3px; }
.hznux-help__contact a:focus-visible { outline: 2px solid var(--nx-accent) !important; outline-offset: 3px !important; border-radius: 3px; }

/* --------------------------------------------------------------------------
   Sign-in form: "Need help signing in?"
   -------------------------------------------------------------------------- */
.hznux-signin-help {
	margin: 18px 0 0;
	padding: 0;
	border-top: 1px solid var(--nx-line);
	text-align: left;
	color: var(--nx-ink-2);
}
.hznux-signin-help > summary {
	display: block;
	list-style: none;
	min-height: 44px;
	padding: 12px 0;
	box-sizing: border-box;
	font-size: 15px;
	font-weight: 600;
	line-height: 20px;
	text-align: center;
	color: var(--nx-accent-ink);
	cursor: pointer;
}
.hznux-signin-help > summary::-webkit-details-marker { display: none; }
.hznux-signin-help > summary::after { content: " +"; }
.hznux-signin-help[open] > summary::after { content: " \2212"; }
.hznux-signin-help > summary:focus-visible { outline: 2px solid var(--nx-accent) !important; outline-offset: 2px !important; border-radius: 6px; }
html body .hznux-signin-help ol {
	margin: 4px 0 16px;
	padding: 0 0 0 22px;
	list-style: decimal;
}
html body .hznux-signin-help li {
	margin: 0 0 10px;
	font-size: 15px;
	line-height: 1.55;
	color: var(--nx-ink-2);
}
.hznux-signin-help li strong { color: var(--nx-ink); font-weight: 600; }
.hznux-signin-help li a { color: var(--nx-accent-ink); text-decoration: underline; text-underline-offset: 3px; }
.hznux-signin-help .hznux-guide__btn { width: 100%; }

/* --------------------------------------------------------------------------
   Keyboard focus, restated with id anchors. The lesson, sign-in and account
   pages reset outlines with !important at high specificity (measured: the
   plain class rules above lost on the More rows, the lesson Tour button and
   the sign-in disclosure), so these few rules carry an id.
   -------------------------------------------------------------------------- */
#vs-nav-more .hznux-more__row:focus-visible,
#vs-nav-more .hznux-more__btn:focus-visible {
	outline: 2px solid rgba(6, 214, 247, 0.85) !important;
	outline-offset: -2px !important;
}
#ht-launch-lesson-page.hznux-quiet-btn:focus-visible,
#mpcs-sidebar .hznux-guide__btn:focus-visible,
#hznux-signin-help .hznux-guide__btn:focus-visible {
	outline: 2px solid var(--nx-accent) !important;
	outline-offset: 3px !important;
}
#hznux-signin-help > summary:focus-visible {
	outline: 2px solid var(--nx-accent) !important;
	outline-offset: 2px !important;
	border-radius: 6px;
}

/* --------------------------------------------------------------------------
   Keyboard focus in the menu (rail and bar). The account pages reset outlines
   with !important in many places, so the focus ring here has to insist.
   -------------------------------------------------------------------------- */
.visor-sidebar.hznux-bar .vs-item a:focus-visible,
.visor-sidebar.hznux-bar .vs-signout:focus-visible,
.visor-sidebar.hznux-bar .vs-toggle:focus-visible,
.visor-sidebar.hznux-bar .vs-logo:focus-visible {
	outline: 2px solid rgba(6, 214, 247, 0.85) !important;
	outline-offset: -3px !important;
	border-radius: 10px;
}
/* The desktop rail turns to paper in the light theme; the small-screen bar
   stays dark in both themes. */
@media (min-width: 1025px) {
	html[data-horizon-theme="light"] .visor-sidebar.hznux-bar .vs-item a:focus-visible,
	html[data-horizon-theme="light"] .visor-sidebar.hznux-bar .vs-signout:focus-visible,
	html[data-horizon-theme="light"] .visor-sidebar.hznux-bar .vs-toggle:focus-visible,
	html[data-horizon-theme="light"] .visor-sidebar.hznux-bar .vs-logo:focus-visible {
		outline-color: #0a7d95 !important;
	}
}

/* --------------------------------------------------------------------------
   Phone and tablet bar (1024px and under): four places and "More".
   The desktop rail is not touched; there the More slot does not exist.
   -------------------------------------------------------------------------- */
.visor-sidebar .hznux-more { display: none; list-style: none; margin: 0; padding: 0; }

@media (max-width: 1024px) {
	/* Items that live behind More, the Tour item the Tour script adds, and the
	   footer slot (Sign out) leave the bar. All remain in the page for the
	   desktop rail. */
	.visor-sidebar.hznux-bar .vs-list > .vs-item.hznux-over,
	.visor-sidebar.hznux-bar .vs-list > .ht-nav-item,
	.visor-sidebar.hznux-bar .vs-footer { display: none !important; }

	/* Readable labels: 11.5px, never cut with an ellipsis. */
	.visor-sidebar.hznux-bar .vs-item .vs-label,
	.visor-sidebar.hznux-bar .hznux-more__btn .vs-label {
		font-size: 11.5px;
		line-height: 1.15;
		letter-spacing: 0;
		overflow: visible;
		text-overflow: clip;
	}
	.visor-sidebar.hznux-bar .vs-item .vs-icon,
	.visor-sidebar.hznux-bar .hznux-more__btn .vs-icon { font-size: 19px; }

	.visor-sidebar.hznux-bar .hznux-more {
		position: relative;
		display: block;
		flex: 1 1 0;
		min-width: 0;
	}
	.visor-sidebar.hznux-bar .hznux-more__d { display: block; height: 100%; }
	.visor-sidebar.hznux-bar .hznux-more__btn {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 4px;
		box-sizing: border-box;
		width: 100%;
		height: 60px;
		padding: 0 3px;
		border-radius: 16px;
		list-style: none;
		color: rgba(255, 255, 255, 0.66);
		cursor: pointer;
		-webkit-user-select: none;
		user-select: none;
	}
	.visor-sidebar.hznux-bar .hznux-more__btn::-webkit-details-marker { display: none; }
	.visor-sidebar.hznux-bar .hznux-more__btn::marker { content: ""; }
	.visor-sidebar.hznux-bar .hznux-more__btn .vs-icon {
		position: static;
		display: flex;
		align-items: center;
		justify-content: center;
		width: 24px;
		height: 24px;
		transform: none;
		line-height: 1;
		color: rgba(255, 255, 255, 0.66);
	}
	.visor-sidebar.hznux-bar .hznux-more__btn .vs-label {
		position: static;
		transform: none;
		max-width: 100%;
		opacity: 1;
		font-weight: 600;
		color: rgba(255, 255, 255, 0.6);
		white-space: nowrap;
	}
	.visor-sidebar.hznux-bar .hznux-more__d[open] > .hznux-more__btn .vs-icon { color: #2fe0ff; }
	.visor-sidebar.hznux-bar .hznux-more__d[open] > .hznux-more__btn .vs-label { color: rgba(255, 255, 255, 0.96); }
	.visor-sidebar.hznux-bar .hznux-more__btn:focus-visible {
		outline: 2px solid rgba(6, 214, 247, 0.85) !important;
		outline-offset: -4px !important;
	}

	/* The sheet opens above the bar. Solid dark glass, no blur. */
	.visor-sidebar.hznux-bar .hznux-more__sheet {
		position: absolute;
		right: 0;
		bottom: calc(100% + 14px);
		box-sizing: border-box;
		width: 248px;
		max-width: calc(100vw - 24px);
		padding: 8px;
		border: 1px solid rgba(6, 214, 247, 0.18);
		border-radius: 20px;
		background: rgb(13, 16, 22);
		box-shadow: 0 18px 44px rgba(0, 0, 0, 0.6);
		z-index: 6;
	}
	html body .visor-sidebar.hznux-bar .hznux-more__row {
		-webkit-appearance: none;
		appearance: none;
		display: flex;
		align-items: center;
		gap: 14px;
		box-sizing: border-box;
		width: 100%;
		min-height: 50px;
		height: auto;
		margin: 0;
		padding: 0 14px;
		border: 0;
		border-radius: 13px !important;
		background: transparent;
		color: rgba(255, 255, 255, 0.9);
		font-size: 16px;
		font-weight: 500;
		line-height: 1.25;
		letter-spacing: 0 !important;
		text-align: left;
		text-decoration: none;
		text-transform: none;
		cursor: pointer;
		box-shadow: none;
	}
	html body .visor-sidebar.hznux-bar .hznux-more__row[hidden] { display: none; }
	html body .visor-sidebar.hznux-bar .hznux-more__row:hover,
	html body .visor-sidebar.hznux-bar .hznux-more__row:active { background: rgba(255, 255, 255, 0.07); color: #fff; transform: none; }
	html body .visor-sidebar.hznux-bar .hznux-more__row:focus-visible { outline: 2px solid rgba(6, 214, 247, 0.85) !important; outline-offset: -2px !important; }
	html body .visor-sidebar.hznux-bar .hznux-more__row[aria-current="page"] { background: rgba(6, 214, 247, 0.1); }
	.visor-sidebar.hznux-bar .hznux-more__icon {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		flex: 0 0 24px;
		width: 24px;
		height: 24px;
		font-size: 17px;
		color: rgba(255, 255, 255, 0.66);
	}
	.visor-sidebar.hznux-bar .hznux-more__icon svg { width: 20px; height: 20px; }
	.visor-sidebar.hznux-bar .hznux-more__row--out { margin-top: 6px; border-top: 1px solid rgba(255, 255, 255, 0.08); border-radius: 0 0 13px 13px !important; padding-top: 2px; }

	/* The floating Light/Dark chip is replaced by the row in More (only once
	   the script has confirmed the bar is in place). */
	html.hznux-c body #hz-theme-toggle.hz-tt-mobilechip { display: none !important; }

	/* The Visor button floats exactly where the sheet opens (and paints above
	   the bar, which lives in a lower stacking layer). It steps aside while
	   the sheet is open. */
	html.hznux-more-open body #visor-orb { visibility: hidden !important; }
}

@media (max-width: 1024px) and (prefers-reduced-motion: no-preference) {
	.visor-sidebar.hznux-bar .hznux-more__d[open] > .hznux-more__sheet { animation: hznuxSheetIn 0.2s cubic-bezier(0.16, 1, 0.3, 1) both; }
}
@keyframes hznuxSheetIn {
	from { opacity: 0; transform: translateY(8px); }
	to { opacity: 1; transform: none; }
}
