/* Site header — theme-native (no Codevz / WPBakery classes) 22222 */

:root {
	--postmba-header-blue: #285bbb;
	--postmba-header-gold: #ccb892;
	--postmba-header-gold-hover: #f0dfbe;
	--postmba-header-text: #424f59;
	--postmba-header-muted: #444444;
	--postmba-header-max: 1280px;
	--postmba-header-contact-gap: 1.15rem;
	--postmba-header-actions-gap: 2rem;
}

.site-header {
	position: relative;
	z-index: 100;
	direction: rtl;
	font-family: var(--postmba-font-sans);
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	max-width: var(--postmba-header-max);
	margin: 0 auto;
	width: 100%;
	box-sizing: border-box;
}

.site-header a {
	text-decoration: none;
	border: 0;
}

.site-header ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Logo */
.site-header__logo a {
	display: block;
	line-height: 0;
}

.site-header__logo img {
	display: block;
	height: auto;
	max-width: 100%;
	width: 216px;
}

.site-header__mobile-bar .site-header__logo img {
	width: 200px;
}

/* —— Desktop top bar —— */
.site-header__bar {
	background: #fff;
	position: relative;
}

.site-header__bar .site-header__top {
	padding: 22px 40px;
	flex-wrap: wrap;
	align-items: center;
}

.site-header__top-actions {
	display: flex;
	align-items: stretch;
	gap: var(--postmba-header-actions-gap);
	flex-wrap: wrap;
	justify-content: flex-end;
}

.site-header__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	align-self: stretch;
	gap: 0.55rem;
	color: #fff !important;
	font-weight: 700;
	font-size: 15px;
	line-height: 1.3;
	min-height: 3.2em;
	background-color: var(--postmba-header-gold);
	padding: 0 1.75rem;
	border-radius: 6px;
	transition:
		background-color 0.25s ease,
		transform 0.25s ease,
		box-shadow 0.25s ease;
	white-space: nowrap;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
}

.site-header__cta-icon {
	font-size: 0.85em;
	line-height: 1;
	transition: transform 0.3s ease;
}

.site-header__cta:hover {
	background-color: #b8a47a;
	color: #fff !important;
	box-shadow: 0 4px 14px rgba(204, 184, 146, 0.45);
	transform: translateY(-1px);
}

.site-header__cta:hover .site-header__cta-icon {
	transform: rotate(90deg);
}

.site-header__contact {
	display: flex;
	align-items: center;
	gap: var(--postmba-header-contact-gap);
	color: inherit;
	max-width: 440px;
}

.site-header__contact-icon {
	flex-shrink: 0;
	color: var(--postmba-header-gold);
	font-size: 38px;
	line-height: 1;
	width: 1em;
	text-align: center;
}

.site-header__contact-body {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 0.4rem;
	line-height: 1.45;
	font-size: 15px;
	color: var(--postmba-header-muted);
	min-height: 3.2em;
}

.site-header__contact-line {
	display: block;
	white-space: nowrap;
}

.site-header__contact-line strong {
	color: var(--postmba-header-text);
	font-weight: 700;
	margin-inline-end: 0.25em;
}

.site-header__phones {
	color: var(--postmba-header-blue);
	font-weight: 700;
	display: inline-block;
}

/* —— Desktop nav bar —— */
.site-header__nav-row {
	background: var(--postmba-header-blue);
	position: relative;
}

.site-header__nav-row .site-header__nav-bar {
	padding: 0 24px;
	min-height: 52px;
}

.site-header__nav {
	flex: 1;
	min-width: 0;
	overflow: visible;
}

.site-header__menu {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: 0;
	margin: 0;
}

.site-header__menu > .menu-item {
	position: relative;
	flex-shrink: 0;
}

/* Desktop top-level links — match legacy #menu_header_3 */
.site-header__nav-row .site-header__menu > .menu-item > a {
	position: relative;
	display: block;
	z-index: 1;
	padding: 12px;
	margin: 0;
	color: rgba(255, 255, 255, 0.7);
	font-weight: 700;
	font-size: 16px;
	letter-spacing: 0;
	white-space: nowrap;
	background: none;
	border: 0;
	transition: color 0.2s ease;
}

.site-header__nav-row .site-header__menu > .menu-item > a > span {
	position: relative;
	z-index: 1;
}

/*
 * Unroll tick — legacy cz_menu_fx_unroll + #menu_header_3 overrides:
 * white 3×10px bar at bottom center, scaleY 0 → 1.
 */
.site-header__nav-row .site-header__menu > .menu-item > a::before {
	content: '';
	display: block;
	position: absolute;
	z-index: 0;
	bottom: 0;
	left: calc(50% - 1px);
	width: 3px;
	height: 10px;
	background-color: #fff;
	transform-origin: 100%;
	transform: scale(1, 0);
	transition: transform 0.3s cubic-bezier(1, 0, 0, 1);
	backface-visibility: hidden;
	pointer-events: none;
}

.site-header__nav-row .site-header__menu > .menu-item > a:hover,
.site-header__nav-row .site-header__menu > .menu-item:hover > a,
.site-header__nav-row .site-header__menu > .postmba-nav__item--current > a,
.site-header__nav-row .site-header__menu > .current-menu-item > a,
.site-header__nav-row .site-header__menu > .current_page_item > a,
.site-header__nav-row .site-header__menu > .current-menu-parent > a,
.site-header__nav-row .site-header__menu > .current-menu-ancestor > a {
	color: #fff;
}

.site-header__nav-row .site-header__menu > .menu-item > a:hover::before,
.site-header__nav-row .site-header__menu > .menu-item:hover > a::before,
.site-header__nav-row .site-header__menu > .postmba-nav__item--current > a::before,
.site-header__nav-row .site-header__menu > .current-menu-item > a::before,
.site-header__nav-row .site-header__menu > .current_page_item > a::before,
.site-header__nav-row .site-header__menu > .current-menu-parent > a::before,
.site-header__nav-row .site-header__menu > .current-menu-ancestor > a::before {
	transform: scale(1);
}

/* مشاوره و ثبت‌نام — gold accent (legacy #menu-header_3-1608) */
.site-header__nav-row .site-header__menu > .postmba-nav__item--accent > a {
	color: var(--postmba-header-gold) !important;
}

.site-header__nav-row .site-header__menu > .postmba-nav__item--accent > a:hover {
	color: var(--postmba-header-gold-hover) !important;
}

.postmba-nav__indicator {
	display: inline-block;
	position: relative;
	width: 1em;
	height: 1em;
	margin: 0 4px 0 0;
	font-size: 0.75em;
	line-height: 1em;
	text-align: center;
	vertical-align: middle;
	opacity: 0.9;
}

.site-header__nav-row .site-header__menu > .menu-item > a .postmba-nav__indicator {
	transition: transform 0.2s ease;
}

.site-header__nav-row .site-header__menu > .menu-item:hover > a .postmba-nav__indicator,
.site-header__nav-row .site-header__menu > .menu-item:focus-within > a .postmba-nav__indicator {
	transform: translateY(1px);
}

/* Overflow “more” (legacy cz-extra-menus) */
.site-header__more > a {
	min-width: 2.5em;
	text-align: center;
}

.site-header__more > a .postmba-nav__more-icon {
	font-size: 1em;
	line-height: 1;
	margin: 0;
	vertical-align: middle;
}

.site-header__more[hidden] {
	display: none !important;
}

/* Desktop dropdowns — legacy submenu + cz_submenu_fx_moveup */
@keyframes postmba-menu-move-up {
	0% {
		transform: translateY(10px);
	}
	100% {
		transform: translateY(0);
	}
}

.site-header__nav-row .sub-menu {
	display: none;
	position: absolute;
	top: 100%;
	right: -20px;
	left: auto;
	z-index: 200;
	width: 500px;
	max-width: min(500px, calc(100vw - 32px));
	margin-top: 1px;
	padding: 16px 0;
	background: #fff;
	border-radius: 5px;
	box-shadow: 0 15px 60px rgba(0, 0, 0, 0.15);
	text-align: right;
	animation: postmba-menu-move-up 0.4s cubic-bezier(0.18, 0.89, 0.33, 1.27);
}

.site-header__nav-row .menu-item:hover > .sub-menu,
.site-header__nav-row .menu-item:focus-within > .sub-menu,
.site-header__nav-row .menu-item.is-open > .sub-menu {
	display: block;
}

.site-header__nav-row .sub-menu .menu-item {
	position: relative;
}

.site-header__nav-row .sub-menu a {
	position: relative;
	display: block;
	padding: 8px 24px;
	color: rgba(0, 0, 0, 0.75);
	font-size: 16px;
	font-weight: 400;
	line-height: 1.35;
	white-space: normal;
	text-align: right;
	transition:
		color 0.2s ease,
		font-weight 0.2s ease,
		padding 0.2s ease;
}

.site-header__nav-row .sub-menu a:hover,
.site-header__nav-row .sub-menu .menu-item:hover > a,
.site-header__nav-row .sub-menu .postmba-nav__item--current > a,
.site-header__nav-row .sub-menu .current-menu-item > a,
.site-header__nav-row .sub-menu .current_page_item > a {
	color: var(--postmba-header-blue);
	font-weight: 700;
	padding-right: 30px;
	padding-left: 30px;
}

/* Nested flyout (RTL: open toward page center) */
.site-header__nav-row .sub-menu .sub-menu {
	top: 0;
	right: 100%;
	left: auto;
	margin-top: -15px;
	animation: none;
}

.site-header__nav-row .sub-menu .sub-menu.is-reverse {
	right: auto;
	left: 100%;
}

.site-header__nav-row .sub-menu .menu-item-has-children > a,
.site-header__nav-row .sub-menu .menu-item:has(> .sub-menu) > a {
	padding-left: 36px;
}

.site-header__nav-row .sub-menu .postmba-nav__indicator {
	position: absolute;
	left: 10px;
	top: 50%;
	width: 1em;
	margin: 0;
	transform: translateY(-50%) rotate(180deg);
	transition: left 0.2s ease-out, color 0.2s ease;
}

.site-header__nav-row .sub-menu .menu-item:hover > a .postmba-nav__indicator {
	left: 7px;
	color: var(--postmba-header-blue);
}

/* Social */
.site-header__social {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	flex-shrink: 0;
	padding: 8px 0;
}

.site-header__social-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 4px;
	color: #fff;
	background: rgba(255, 255, 255, 0.12);
	transition: background-color 0.2s ease, transform 0.2s ease;
	font-size: 16px;
	line-height: 1;
}

.site-header__social-link:hover {
	background: rgba(255, 255, 255, 0.28);
	transform: translateY(-1px);
}

.site-header__social-link span {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	border: 0;
}

/* Hide nav-row social on desktop (legacy layout) */
@media (min-width: 769px) {
	.site-header__nav-row .site-header__social {
		display: none;
	}
}

/* —— Mobile bar —— */
.site-header__mobile-bar {
	display: none;
	background: #fff;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
	position: relative;
	z-index: 1;
}

.site-header__mobile-bar .site-header__mobile {
	padding: 12px 16px;
}

.site-header__toggle {
	appearance: none;
	border: 0;
	cursor: pointer;
	width: 40px;
	height: 40px;
	padding: 5px;
	border-radius: 5px;
	background: var(--postmba-header-blue);
	color: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 18px;
	line-height: 1;
}

/* —— Offcanvas —— */
.site-header__offcanvas {
	position: fixed;
	inset: 0;
	z-index: 1000;
	pointer-events: none;
}

.site-header__offcanvas.is-open {
	pointer-events: auto;
}

.site-header__offcanvas[hidden] {
	display: none;
}

.site-header__offcanvas-backdrop {
	position: absolute;
	inset: 0;
	z-index: 0;
	border: 0;
	padding: 0;
	margin: 0;
	background: rgba(17, 17, 17, 0.45);
	cursor: pointer;
	opacity: 0;
	transition: opacity 0.25s ease;
}

.site-header__offcanvas.is-open .site-header__offcanvas-backdrop {
	opacity: 1;
}

.site-header__offcanvas-panel {
	position: absolute;
	top: 0;
	bottom: 0;
	inset-inline-start: 0;
	z-index: 1;
	width: min(340px, 88vw);
	background: #fff;
	box-shadow: 0 0 24px rgba(0, 0, 0, 0.15);
	/* Header is RTL — slide in from inline-start (right). */
	transform: translateX(100%);
	transition: transform 0.28s ease;
	overflow-y: auto;
	padding: 1.25rem 1rem 2rem;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	gap: 1rem;
	pointer-events: auto;
}

html[dir='ltr'] .site-header__offcanvas-panel,
body.ltr .site-header__offcanvas-panel {
	transform: translateX(-100%);
}

.site-header__offcanvas.is-open .site-header__offcanvas-panel {
	transform: translateX(0);
}

.site-header__offcanvas-close {
	align-self: flex-start;
	appearance: none;
	border: 0;
	background: transparent;
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
	color: var(--postmba-header-text);
	padding: 0.25rem 0.5rem;
}

.site-header__menu--offcanvas {
	display: flex;
	flex-direction: column;
	align-items: stretch;
}

.site-header__menu--offcanvas .menu-item > a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 8px;
	color: var(--postmba-header-text);
	font-weight: 600;
	font-size: 15px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06);
	transition: color 0.2s ease, background-color 0.2s ease, padding-inline-start 0.2s ease;
}

.site-header__menu--offcanvas .menu-item > a:hover {
	color: var(--postmba-header-blue);
	background: #f0f4fa;
	padding-inline-start: 14px;
}

.site-header__menu--offcanvas .menu-item.is-open > a {
	color: var(--postmba-header-blue);
}

.site-header__menu--offcanvas .sub-menu {
	display: none;
	padding-inline-start: 0.75rem;
	background: #f7f8fa;
}

.site-header__menu--offcanvas .menu-item.is-open > .sub-menu {
	display: block;
}

.site-header__menu--offcanvas .menu-item.is-open > a .postmba-nav__indicator {
	transform: rotate(180deg);
}

.site-header__menu--offcanvas .sub-menu .postmba-nav__indicator {
	position: static;
	left: auto;
	top: auto;
	transform: none;
	margin-inline-start: 0.35em;
}

.site-header__social--offcanvas {
	padding: 0.5rem 0;
	justify-content: flex-start;
}

.site-header__social--offcanvas .site-header__social-link {
	background: var(--postmba-header-blue);
	width: 40px;
	height: 40px;
	font-size: 18px;
}

body.site-header-offcanvas-open {
	overflow: hidden;
}

/* —— Breakpoints —— */
@media screen and (max-width: 1024px) {
	.site-header__bar .site-header__top {
		padding: 18px 20px;
	}

	.site-header__top-actions {
		gap: 1.25rem;
	}

	.site-header__contact {
		max-width: 280px;
		gap: 0.85rem;
	}

	.site-header__contact-body {
		font-size: 13px;
	}

	.site-header__contact-icon {
		font-size: 32px;
	}
}

@media screen and (max-width: 768px) {
	.site-header__bar,
	.site-header__nav-row {
		display: none !important;
	}

	.site-header__mobile-bar {
		display: block !important;
	}
}

@media screen and (min-width: 769px) {
	.site-header__offcanvas {
		display: none !important;
	}
}
