/* FMM Mobile Nav — brand: ink #1a1a1a / red #c61818 / white / light #f4f6f9.
   Visibility (show <=1024px, hide above) + old-header hide is handled by the
   critical inline CSS printed in wp_head; this file is pure presentation. */

/* ── Fixed top bar ── */
.fmm-mnav-bar {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	height: 60px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 16px;
	background: #fff;
	border-bottom: 1px solid #ececec;
	box-shadow: 0 1px 8px rgba(0, 0, 0, .06);
	z-index: 9998;
}
.fmm-mnav-logo {
	display: flex;
	align-items: center;
	max-height: 42px;
	overflow: hidden;
	text-decoration: none;
	color: #1a1a1a;
	font-weight: 700;
	font-size: 1.05rem;
}
.fmm-mnav-logo img,
.fmm-mnav-logo .custom-logo {
	max-height: 42px;
	width: auto;
	height: auto;
	display: block;
}
.fmm-mnav-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	margin: 0;
	border: none;
	background: transparent;
	color: #1a1a1a;
	cursor: pointer;
	border-radius: 8px;
	transition: color .16s, background .16s;
}
.fmm-mnav-toggle:hover,
.fmm-mnav-toggle:focus-visible { color: #c61818; background: #f4f6f9; }

/* ── Overlay + drawer ── */
.fmm-mnav-overlay {
	position: fixed;
	inset: 0;
	background: rgba(15, 15, 15, .5);
	opacity: 0;
	visibility: hidden;
	transition: opacity .25s ease, visibility .25s ease;
	z-index: 100000;
}
.fmm-mnav-drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	width: 86%;
	max-width: 360px;
	display: flex;
	flex-direction: column;
	background: #fff;
	transform: translateX(100%);
	transition: transform .28s cubic-bezier(.4, 0, .2, 1);
	box-shadow: -8px 0 40px rgba(0, 0, 0, .22);
	z-index: 100001;
}
.fmm-mnav-root.is-open .fmm-mnav-overlay { opacity: 1; visibility: visible; }
.fmm-mnav-root.is-open .fmm-mnav-drawer { transform: translateX(0); }

/* ── Drawer top (profile / title + close) ── */
.fmm-mnav-drawer__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 14px 16px;
	min-height: 64px;
	background: #1a1a1a;
	color: #fff;
}
.fmm-mnav-profile { display: flex; align-items: center; gap: 11px; min-width: 0; }
.fmm-mnav-profile__avatar {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	object-fit: cover;
	border: 2px solid #c61818;
	flex-shrink: 0;
}
.fmm-mnav-profile__meta { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.fmm-mnav-profile__name {
	font-size: .95rem;
	font-weight: 700;
	color: #fff;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.fmm-mnav-profile__role {
	font-size: .62rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .08em;
	color: #e74c3c;
	margin-top: 2px;
}
.fmm-mnav-drawer__title { font-size: 1rem; font-weight: 700; color: #fff; }
.fmm-mnav-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border: none;
	background: transparent;
	color: #fff;
	cursor: pointer;
	border-radius: 8px;
	flex-shrink: 0;
	transition: background .16s;
}
.fmm-mnav-close:hover { background: rgba(255, 255, 255, .12); }

/* ── Scrollable body ── */
.fmm-mnav-scroll {
	flex: 1;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
	padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 20px);
}

/* ── Main menu ── */
.fmm-mnav-menu { list-style: none; margin: 0; padding: 0; }
.fmm-mnav-menu__item { border-bottom: 1px solid #f0f0f0; }
.fmm-mnav-link {
	display: flex;
	align-items: center;
	gap: 12px;
	width: 100%;
	padding: 15px 18px;
	font: inherit;
	font-size: 1rem;
	font-weight: 600;
	color: #1a1a1a;
	text-decoration: none;
	text-align: left;
	background: transparent;
	border: none;
	cursor: pointer;
	transition: color .14s, background .14s;
}
.fmm-mnav-link__label { flex: 1; }
.fmm-mnav-link:hover,
.fmm-mnav-link:focus-visible { color: #c61818; background: #fafafa; }
.fmm-mnav-accordion { justify-content: space-between; }
.fmm-mnav-chevron { display: inline-flex; color: #9aa0aa; transition: transform .22s ease, color .14s; }

/* ── Submenu accordion ── */
.fmm-mnav-submenu {
	list-style: none;
	margin: 0;
	padding: 0;
	max-height: 0;
	overflow: hidden;
	background: #f4f6f9;
	transition: max-height .28s ease;
}
.fmm-mnav-menu__item.is-expanded > .fmm-mnav-submenu { max-height: 340px; }
.fmm-mnav-menu__item.is-expanded > .fmm-mnav-accordion .fmm-mnav-chevron { transform: rotate(90deg); color: #c61818; }
.fmm-mnav-link--sub {
	padding: 13px 18px 13px 32px;
	font-size: .94rem;
	font-weight: 500;
	color: #3a3a3a;
}

/* ── Sections (account + language) ── */
.fmm-mnav-section { padding: 16px 18px 4px; }
.fmm-mnav-section__title {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
	font-size: .7rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .09em;
	color: #9aa0aa;
}
.fmm-mnav-section__ico svg { width: 16px; height: 16px; }
.fmm-mnav-account { list-style: none; margin: 0; padding: 0; }
.fmm-mnav-link--icon { padding: 12px 0; font-size: .95rem; font-weight: 500; }
.fmm-mnav-link--icon:hover { background: transparent; }
.fmm-mnav-link__ico { display: inline-flex; color: #8a93a3; flex-shrink: 0; transition: color .14s; }
.fmm-mnav-link--icon:hover .fmm-mnav-link__ico { color: #c61818; }
.fmm-mnav-link--logout { color: #c0392b; }
.fmm-mnav-link--logout .fmm-mnav-link__ico { color: #d98178; }
.fmm-mnav-link--logout:hover { color: #a93226; }

/* ── Language pills ── */
.fmm-mnav-langs { display: flex; gap: 8px; }
.fmm-mnav-lang {
	flex: 1;
	text-align: center;
	padding: 11px 0;
	border: 1.5px solid #e0e0e0;
	border-radius: 10px;
	font-size: .9rem;
	font-weight: 700;
	color: #1a1a1a;
	text-decoration: none;
	transition: background .16s, border-color .16s, color .16s;
}
.fmm-mnav-lang:hover { border-color: #1a1a1a; }
.fmm-mnav-lang.is-active { background: #c61818; border-color: #c61818; color: #fff; }

/* ── Body scroll lock when drawer open ── */
body.fmm-mnav-locked { overflow: hidden; }

/* ── RTL ── */
[dir="rtl"] .fmm-mnav-drawer {
	right: auto;
	left: 0;
	transform: translateX(-100%);
	box-shadow: 8px 0 40px rgba(0, 0, 0, .22);
}
[dir="rtl"] .fmm-mnav-root.is-open .fmm-mnav-drawer { transform: translateX(0); }
[dir="rtl"] .fmm-mnav-link { text-align: right; }
[dir="rtl"] .fmm-mnav-link--sub { padding: 13px 32px 13px 18px; }
[dir="rtl"] .fmm-mnav-chevron { transform: rotate(180deg); }
[dir="rtl"] .fmm-mnav-menu__item.is-expanded > .fmm-mnav-accordion .fmm-mnav-chevron { transform: rotate(90deg); }
