/**
 * Preluence News — mobile menu engine.
 *
 * The nested "view stack" used inside the drawer: one screen per level with a
 * back button, so deep menus stay readable on a phone.
 */

.pn-mnav {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.pn-mnav__search .search-form {
	margin: 0;
}

.pn-mnav__stack {
	position: relative;
	min-height: 0;
}

.pn-mnav__view {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	animation: pn-mnav-in 0.22s var(--pn-ease, ease) both;
}

.pn-mnav__view[hidden] {
	display: none;
}

@keyframes pn-mnav-in {

	from {
		opacity: 0;
		transform: translateX(6%);
	}
}

.pn-mnav__back {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	align-self: flex-start;
	padding: 0.35rem 0.5rem;
	border: 0;
	background: none;
	color: var(--pn-link);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	border-radius: 4px;
}

.pn-mnav__back svg {
	width: 16px;
	height: 16px;
	transform: rotate(180deg);
}

.pn-mnav__back:hover,
.pn-mnav__back:focus-visible {
	background: color-mix(in srgb, currentColor 10%, transparent);
}

.pn-mnav__title {
	margin: 0;
	font-family: var(--pn-font-ui, sans-serif);
	font-size: 0.76rem;
	font-weight: 700;
	letter-spacing: 0.09em;
	text-transform: uppercase;
	opacity: 0.6;
}

.pn-mnav__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.pn-mnav__item {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	border-block-end: 1px solid color-mix(in srgb, currentColor 10%, transparent);
}

.pn-mnav__link {
	flex: 1 1 auto;
	min-width: 0;
	padding: 0.7rem 0.25rem;
	color: inherit;
	text-decoration: none;
	overflow-wrap: anywhere;
}

.pn-mnav__link:hover,
.pn-mnav__link:focus-visible {
	color: var(--pn-link);
}

/* Touch-friendly 44px targets. */
.pn-mnav__more {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border: 0;
	background: none;
	color: inherit;
	cursor: pointer;
	border-radius: 50%;
}

.pn-mnav__more svg {
	width: 16px;
	height: 16px;
	transform: rotate(-90deg);
	transition: transform 0.2s var(--pn-ease, ease);
}

.pn-mnav__more:hover,
.pn-mnav__more:focus-visible {
	background: color-mix(in srgb, currentColor 10%, transparent);
}

.pn-mnav__view[data-depth="1"] .pn-mnav__title {
	color: var(--pn-menu-accent, var(--pn-accent));
}

/* Featured block inside the mobile menu */
.pn-mnav__featured .pn-mega__side {
	flex: none;
	padding-inline-start: 0;
	border-inline-start: 0;
	border-block-start: 1px solid color-mix(in srgb, currentColor 12%, transparent);
	padding-block-start: 0.75rem;
}

.pn-mnav__featured .pn-mega-card {
	display: flex;
	gap: 0.6rem;
	align-items: center;
}

.pn-mnav__featured .pn-mega-card__media {
	width: 84px;
	min-width: 84px;
	aspect-ratio: 4 / 3;
}

/* Full-screen variant */
.pn-mnav--fullscreen .pn-mnav__view {
	gap: 0.5rem;
}

/* Items that opt out of the accordion show their children inline. */
.pn-mnav__item.pn-menu-flat-mobile .pn-mnav__more {
	display: none;
}

@media (prefers-reduced-motion: reduce) {

	.pn-mnav__view {
		animation: none;
	}

	.pn-mnav__more svg {
		transition: none;
	}
}
