/* ============================================================
   Sticky Header Widget – Styles
   ============================================================ */

/* ---------- wrapper: full-width, pinned to top ---------- */
.sh-wrapper {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	z-index: 99999;
	pointer-events: none;
}

/* When WordPress admin bar is present */
.admin-bar .sh-wrapper {
	top: 32px;
}

@media screen and (max-width: 782px) {
	.admin-bar .sh-wrapper {
		top: 46px;
	}
}

.elementor-editor-active .sh-wrapper {
	z-index: 10;
	position: relative;
}

.sh-placeholder {
	width: 100%;
	height: var(--sh-placeholder-height, 70px);
}

/* ---------- bar ---------- */
.sh-bar {
	display: flex;
	align-items: center;
	background-color: transparent;
	box-shadow: none !important;
	transition: all 300ms ease;
	pointer-events: auto;
}

/* ---------- Logo ---------- */
.sh-logo {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	text-decoration: none;
}

.sh-logo img {
	display: block;
	object-fit: contain;
}

/* dark / light logo swap */
.sh-bar:not(.is-sticky) .sh-logo-dark  { display: none; }
.sh-bar:not(.is-sticky) .sh-logo-light { display: block; }
.sh-bar.is-sticky .sh-logo-dark  { display: block; }
.sh-bar.is-sticky .sh-logo-light { display: none; }

/* single logo – always visible */
.sh-logo-only { display: block; }

/* ---------- Mobile center text (hidden on desktop) ---------- */
.sh-mobile-text {
	display: none;
	flex: 1 1 auto;
	min-width: 0;
	text-align: center;
	padding: 0 12px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.3;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* ---------- Navigation ---------- */
.sh-nav {
	display: flex;
	align-items: center;
	list-style: none;
	margin: 0;
	margin-left: auto;
	padding: 0;
	flex-shrink: 1;
	min-width: 0;
}

/* ---- Nav item wrapper ---- */
.sh-nav-item {
	position: relative;
}

.sh-nav-link {
	display: inline-flex;
	align-items: center;
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	letter-spacing: 0.02em;
	transition: color 300ms ease;
	white-space: nowrap;
	padding: 8px 0;
}

/* arrow indicator for items with dropdown */
.sh-nav-item.has-dropdown > .sh-nav-link::after {
	display: none;
}

.sh-nav-arrow {
	display: inline-block;
	margin-left: 5px;
	vertical-align: middle;
	transition: transform 300ms ease;
}

.sh-nav-item.has-dropdown:hover > .sh-nav-link .sh-nav-arrow {
	transform: rotate(180deg);
}

.sh-nav-item.has-dropdown.is-mobile-open > .sh-nav-link .sh-nav-arrow {
	transform: rotate(180deg);
}

/* ---- Dropdown panel ---- */
.sh-dropdown {
	position: absolute;
	top: 100%;
	left: -20px;
	width: auto;
	min-width: auto;
	white-space: nowrap;
	background: #ffffff;
	border-radius: 0 0 8px 8px;
	padding: 8px 0;
	opacity: 0;
	visibility: hidden;
	transition: opacity 250ms ease, visibility 250ms ease, transform 250ms ease;
	transform: translateY(6px);
	z-index: 100;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.sh-nav-item.has-dropdown:hover > .sh-dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

/* ---- Dropdown links ---- */
.sh-dropdown-link {
	display: block;
	padding: 10px 24px;
	color: #333333;
	text-decoration: none;
	font-size: 14px;
	font-weight: 400;
	white-space: nowrap;
	transition: background-color 200ms ease, color 200ms ease;
}

.sh-dropdown-link:hover,
.sh-dropdown-link.is-active {
	color: #3b5998;
	background-color: #f7f8fc;
}

/* ---- Placeholder ---- */
.sh-nav-placeholder {
	font-size: 13px;
	opacity: 0.6;
}

.sh-bar:not(.is-sticky) .sh-nav-placeholder { color: #ffffff; }
.sh-bar.is-sticky .sh-nav-placeholder { color: #999999; }

/* ---------- Right area ---------- */
.sh-right {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-shrink: 0;
}

/* ---------- CTA button ---------- */
.sh-cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	line-height: 1;
	cursor: pointer;
	transition: background-color 300ms ease, color 300ms ease;
	white-space: nowrap;
}

.sh-cta i,
.sh-cta svg {
	font-size: inherit;
	width: 1em;
	height: 1em;
}

/* ---------- Right icon buttons ---------- */
.sh-icons {
	display: flex;
	align-items: center;
	gap: 8px;
}

.sh-icon-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	transition: color 300ms ease, opacity 300ms ease;
	width: 32px;
	height: 32px;
	border-radius: 50%;
}

.sh-icon-btn:hover {
	opacity: 0.7;
}

.sh-icon-btn i,
.sh-icon-btn svg {
	width: var(--icon-size, 20px);
	height: var(--icon-size, 20px);
	transition: color 300ms ease, fill 300ms ease;
}

.sh-icon-btn svg path {
	fill: #ffffff !important;
	transition: fill 300ms ease;
}

.sh-bar.is-sticky .sh-icon-btn svg path {
	fill: #333333 !important;
}

/* ---------- Search (inline expand) ---------- */
.sh-search-wrap {
	display: flex;
	align-items: center;
}

.sh-search-form {
	display: flex;
	align-items: center;
	height: 36px;
	width: 32px;
	border-radius: 4px;
	overflow: hidden;
	background: transparent;
	border: 1px solid transparent;
	box-shadow: none;
	transition: width 400ms cubic-bezier(0.4, 0, 0.2, 1),
	            background 300ms ease,
	            border-color 300ms ease,
	            box-shadow 300ms ease;
}

.sh-search-wrap.is-open .sh-search-form {
	width: 280px;
	background: #ffffff;
	border-color: #d0d0d0;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.sh-bar:not(.is-sticky) .sh-search-wrap.is-open .sh-search-form {
	background: rgba(255, 255, 255, 0.15);
	border-color: rgba(255, 255, 255, 0.3);
}

.sh-search-input {
	width: 0;
	flex: 0 0 0;
	border: none;
	outline: none;
	background: transparent;
	font-size: 14px;
	color: #333;
	height: 100%;
	min-width: 0;
	padding: 0;
	opacity: 0;
	transition: flex 400ms cubic-bezier(0.4, 0, 0.2, 1),
	            opacity 300ms ease,
	            padding 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

.sh-search-wrap.is-open .sh-search-input {
	flex: 1 1 auto;
	width: auto;
	opacity: 1;
	padding: 0 0 0 14px;
}

.sh-bar:not(.is-sticky) .sh-search-input {
	color: #fff;
}

.sh-bar:not(.is-sticky) .sh-search-input::placeholder {
	color: rgba(255, 255, 255, 0.6);
}

.sh-search-trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: none;
	border: none;
	cursor: pointer;
	width: 32px;
	height: 100%;
	flex-shrink: 0;
}

.sh-search-trigger i,
.sh-search-trigger svg {
	width: var(--search-icon-size, 20px);
	height: var(--search-icon-size, 20px);
	transition: fill 300ms ease, color 300ms ease;
}

.sh-search-trigger svg path {
	fill: #ffffff !important;
	transition: fill 300ms ease;
}

.sh-bar.is-sticky .sh-search-trigger svg path {
	fill: #333333 !important;
}

/* ---------- Language switcher dropdown ---------- */
.sh-lang-wrap {
	position: relative;
	display: flex;
	align-items: center;
}

.sh-lang-trigger {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	cursor: pointer;
}

.sh-lang-trigger > i,
.sh-lang-trigger > svg {
	width: var(--lang-icon-size, 20px) !important;
	height: var(--lang-icon-size, 20px) !important;
}

.sh-lang-trigger svg path {
	fill: #ffffff !important;
	transition: fill 300ms ease;
}

.sh-bar.is-sticky .sh-lang-trigger svg path {
	fill: #333333 !important;
}

.sh-lang-arrow {
	display: inline-flex;
	align-items: center;
	transition: transform 300ms ease;
}

.sh-lang-arrow i,
.sh-lang-arrow svg {
	width: 10px;
	height: 10px;
}

.sh-lang-arrow svg path {
	fill: #ffffff !important;
	transition: fill 300ms ease;
}

.sh-bar.is-sticky .sh-lang-arrow svg path {
	fill: #333333 !important;
}

.sh-lang-wrap.is-open .sh-lang-arrow {
	transform: rotate(180deg);
}

.sh-lang-dropdown {
	position: absolute;
	top: calc(100% + 8px);
	right: 0;
	min-width: 120px;
	background: #ffffff;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
	padding: 6px 0;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-8px);
	transition: opacity 250ms ease,
	            visibility 250ms ease,
	            transform 250ms ease;
	z-index: 1000;
}

.sh-lang-wrap.is-open .sh-lang-dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.sh-lang-item {
	display: block;
	padding: 8px 16px;
	font-size: 14px;
	color: #333;
	text-decoration: none;
	white-space: nowrap;
	transition: background 200ms ease;
}

.sh-lang-item:hover {
	background: rgba(91, 106, 191, 0.08);
	color: #5b6abf;
}

.sh-lang-item.is-active {
	font-weight: 600;
	color: #5b6abf;
}

/* ---------- Sticky state ---------- */
.sh-bar.is-sticky {
	background-color: #ffffff;
	box-shadow: none !important;
}

.sh-bar.is-solid-initial {
	box-shadow: none !important;
}

/* ---------- Hamburger (mobile) ---------- */
.sh-hamburger {
	display: none;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	gap: 5px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 6px;
	z-index: 10;
	pointer-events: auto;
}

.sh-hamburger span {
	display: block;
	width: 22px;
	height: 2px;
	background-color: #ffffff;
	border-radius: 2px;
	transition: transform 300ms ease, opacity 300ms ease, background-color 300ms ease;
}

.sh-bar.is-sticky .sh-hamburger span {
	background-color: #333333;
}

/* hamburger open animation */
.sh-hamburger.is-open span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}
.sh-hamburger.is-open span:nth-child(2) {
	opacity: 0;
}
.sh-hamburger.is-open span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Mobile Responsive ---------- */
@media (max-width: 768px) {
	.sh-bar {
		justify-content: space-between;
		padding-left: 15px !important;
		padding-right: 15px !important;
	}

	/* Layout order: logo | center text | (language + hamburger) */
	.sh-logo {
		order: 1;
	}

	.sh-mobile-text {
		display: block;
		order: 2;
	}

	/* Right area: show only the language switcher */
	.sh-right {
		display: flex;
		order: 3;
		gap: 0;
		margin-left: 0;
	}

	.sh-right .sh-cta {
		display: none;
	}

	.sh-icons {
		display: flex;
		margin-left: 0 !important;
	}

	.sh-icons .sh-search-wrap,
	.sh-icons .sh-icon-btn {
		display: none;
	}

	.sh-icons .sh-lang-wrap {
		display: flex;
	}

	.sh-hamburger {
		display: flex;
		order: 4;
		margin-left: 8px;
	}

	.sh-nav {
		position: fixed;
		top: 0;
		left: 0;
		width: 280px;
		height: 100vh;
		flex-direction: column;
		justify-content: flex-start;
		align-items: flex-start;
		gap: 0 !important;
		margin-left: 0;
		background-color: #fff;
		transform: translateX(-100%);
		transition: transform 300ms ease;
		z-index: 999999;
		overflow-y: auto;
		padding: 70px 0 30px;
		box-shadow: 2px 0 12px rgba(0, 0, 0, 0.1);
		opacity: 1;
		visibility: visible;
		pointer-events: auto;
	}

	.sh-nav.is-open {
		transform: translateX(0);
	}

	.sh-nav .sh-nav-item {
		width: 100%;
		text-align: left;
	}

	.sh-nav .sh-nav-link {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 14px 24px;
		font-size: 15px;
		color: #333 !important;
		border-bottom: 1px solid #f0f0f0;
	}

	.sh-nav .sh-nav-link .sh-nav-arrow {
		margin-left: auto;
		flex-shrink: 0;
	}

	.sh-nav .sh-nav-link:hover,
	.sh-nav .sh-nav-link.is-active {
		color: #3b5998 !important;
		background: #f7f8fc;
	}

	.sh-nav .sh-dropdown {
		position: static !important;
		transform: none !important;
		min-width: auto !important;
		background: #f9f9f9 !important;
		border-radius: 0 !important;
		padding: 0 !important;
		opacity: 1 !important;
		visibility: visible !important;
		box-shadow: none !important;
		display: none;
		width: 100%;
		left: auto !important;
		top: auto !important;
	}

	.sh-nav .sh-nav-item.has-dropdown.is-mobile-open > .sh-dropdown {
		display: block;
	}

	.sh-nav .sh-dropdown-link {
		font-size: 14px;
		padding: 12px 24px 12px 40px;
		color: #555 !important;
		border-bottom: 1px solid #f0f0f0;
		white-space: normal;
	}

	.sh-nav .sh-dropdown-link:hover,
	.sh-nav .sh-dropdown-link.is-active {
		color: #3b5998 !important;
		background: #eef0f7;
	}
}

