/* Only the classified Guests-menu CTA; Astra retains menu/layout ownership. */
.h5project-guest-header #masthead .h5project-start-trial {
	display: flex;
	align-items: center;
	align-self: center;
	min-width: 0;
	margin-inline-start: 12px;
}
.h5project-guest-header #masthead .h5project-start-trial > a.menu-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: auto;
	max-width: 100%;
	min-height: 44px;
	height: auto;
	padding: 10px 18px;
	border: 1px solid #185cce;
	border-radius: 9px;
	background-color: #185cce;
	background-image: none;
	color: #fff;
	font-weight: 700;
	line-height: 1.25;
	text-align: center;
	text-decoration: none;
	white-space: normal;
	box-shadow: none;
	transform: scale(1);
	transition:
		transform 220ms ease,
		background-color 150ms ease,
		border-color 150ms ease,
		box-shadow 220ms ease;
}
.h5project-guest-header #masthead .h5project-start-trial > a.menu-link:hover {
	transform: scale(1.045);
	border-color: #124ba9;
	background-color: #124ba9;
	color: #fff;
	box-shadow: 0 8px 20px rgba(24, 92, 206, 0.28);
}

.h5project-guest-header #masthead .h5project-start-trial > a.menu-link:focus-visible {
	outline: 3px solid #102f5a;
	outline-offset: 3px;
	box-shadow: 0 0 0 2px #fff;
	color: #fff;
}
.h5project-guest-header #masthead .h5project-start-trial > a.menu-link:active {
	transform: scale(0.985);
	border-color: #0d3b88;
	background-color: #0d3b88;
	color: #fff;
}
/* Reclaim desktop space without changing shared/authenticated layout. */
@media (min-width: 922px) {
	.h5project-guest-header #masthead .site-primary-header-wrap .ast-builder-grid-row {
		grid-template-columns: max-content 0 minmax(0, 1fr) !important;
		padding-inline: clamp(18px, 2.5vw, 40px);
		column-gap: 20px;
	}

	.h5project-guest-header #masthead .site-header-primary-section-right {
		justify-content: flex-end;
		min-width: 0;
	}

	.h5project-guest-header #masthead .h5project-start-trial {
		margin-inline-start: 8px;
	}
}
/* Match Astra's existing 922px desktop/mobile switch. */
@media (max-width: 921.9px) {
	.h5project-guest-header #masthead .h5project-start-trial {
		display: block;
		align-self: stretch;
		margin: 12px 20px 16px;
	}
	.h5project-guest-header #masthead .h5project-start-trial > a.menu-link {
		display: flex;
		width: 100%;
		min-height: 48px;
	}
}
@media (prefers-reduced-motion: reduce) {
	.h5project-guest-header #masthead .h5project-start-trial > a.menu-link {
		transition: none;
	}
}

/* ===============================
   GUEST HEADER — DROPDOWN POLISH
   =============================== */

.h5project-guest-header .main-header-menu .menu-item-has-children {
	position: relative;
}

.h5project-guest-header .main-header-menu .sub-menu,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu {
	background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
	border: 1px solid #dbe7f3;
	border-radius: 16px;
	box-shadow: 0 14px 34px rgba(15, 23, 42, 0.14);
	padding: 10px;
	min-width: 220px;
	margin-top: 6px;
	overflow: visible;
}

/*
 * Invisible hover bridge between the Info item and submenu.
 * This prevents the submenu closing while the pointer crosses the gap.
 */
.h5project-guest-header .main-header-menu .sub-menu::before,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu::before {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: -8px;
	height: 8px;
	background: transparent;
}

/* Remove Astra's flat separators */
.h5project-guest-header .main-header-menu .sub-menu li,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu li {
	border: 0 !important;
}

/* Dropdown links */
.h5project-guest-header .main-header-menu .sub-menu a,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu a {
	display: block;
	color: #0b3a75;
	font-weight: 600;
	padding: 12px 16px;
	border-radius: 12px;
	line-height: 1.35;
	transition:
		background-color 0.2s ease,
		color 0.2s ease,
		transform 0.2s ease;
}

/* Hover / focus */
.h5project-guest-header .main-header-menu .sub-menu a:hover,
.h5project-guest-header .main-header-menu .sub-menu a:focus,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu a:hover,
.h5project-guest-header.ast-desktop .main-header-menu .sub-menu a:focus {
	background: #eef5ff;
	color: #1d5fd0;
	transform: translateX(2px);
	text-decoration: none;
}

/* Parent menu item */
.h5project-guest-header .main-header-menu .menu-item-has-children > a,
.h5project-guest-header.ast-desktop .main-header-menu .menu-item-has-children > a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* Dropdown arrow */
.h5project-guest-header .main-header-menu .menu-item-has-children > a .ast-icon,
.h5project-guest-header.ast-desktop .main-header-menu .menu-item-has-children > a .ast-icon {
	transition: transform 0.2s ease;
}

.h5project-guest-header .main-header-menu .menu-item-has-children:hover > a .ast-icon,
.h5project-guest-header.ast-desktop .main-header-menu .menu-item-has-children:hover > a .ast-icon {
	transform: rotate(180deg);
}
