/* Хедър, USP лента, търсене, дроуър, попъп. Макет: header-*.html, nachalna-drawer-*.html, nachalna-popup-*.html. */

/* Sticky: при скрол USP лентата (36px) излиза нагоре, хедърът остава (Начална.dc.html: sticky; top:-36px). */
.sm-top {
	position: sticky;
	top: -36px;
	z-index: 50;
	font-family: var(--sm-font);
	color: var(--sm-ink);
}

.admin-bar .sm-top {
	top: -4px; /* 32px admin bar - 36px USP */
}

@media (max-width: 782px) {
	.admin-bar .sm-top {
		top: 10px; /* 46px admin bar - 36px USP */
	}
}

@media (max-width: 600px) {
	.admin-bar .sm-top {
		top: -36px; /* admin bar-ът тук не е fixed */
	}
}

/* ---------- USP лента ---------- */
.sm-usp {
	height: 36px;
	background: var(--sm-surface);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 13px;
	color: var(--sm-ink);
	padding: 0 16px;
}

.sm-usp__track {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 28px;
}

.sm-usp__item {
	display: flex;
	align-items: center;
	gap: 8px;
}

.sm-usp__dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--sm-mint);
}

.sm-usp__sep {
	color: #CFCFCF;
}

/* ---------- Хедър ---------- */
.sm-header {
	background: #FFFFFF;
	box-shadow: 0 1px 8px rgba(0, 0, 0, .08);
	position: relative;
	z-index: 2;
}

.sm-header__bar--desktop {
	max-width: var(--sm-container);
	margin: 0 auto;
	height: 72px;
	display: flex;
	align-items: center;
	gap: 24px;
	padding: 0 20px;
	box-sizing: border-box;
}

.sm-header__bar--mobile {
	display: none;
}

.sm-header__logo {
	display: flex;
	align-items: center;
	flex: none;
	height: 44px;
}

.sm-drawer-toggle {
	flex: none;
	display: flex;
	align-items: center;
	gap: 8px;
	height: 40px;
	padding: 0 14px;
	background: #FFFFFF;
	border: 1px solid var(--sm-ink);
	border-radius: var(--sm-radius);
	font: 600 14px var(--sm-font);
	color: var(--sm-ink);
	cursor: pointer;
}

.sm-drawer-toggle:hover {
	background: var(--sm-surface);
}

.sm-hnav {
	flex: none;
}

.sm-hnav__list {
	display: flex;
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 14px;
	font-weight: 600;
}

.sm-hnav__list a {
	display: block;
	padding: 6px 0;
	border-bottom: 2px solid transparent;
}

.sm-hnav__list a:hover,
.sm-hnav__list .current-menu-item > a {
	border-bottom-color: var(--sm-accent);
}

.sm-header__spacer {
	flex: 1;
}

.sm-header__icons {
	display: flex;
	gap: 6px;
	flex: none;
}

.sm-header__icon {
	width: 56px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 3px;
	font-size: 11px;
	position: relative;
}

.sm-cart-count {
	position: absolute;
	top: -6px;
	right: 8px;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	box-sizing: border-box;
	border-radius: 9px;
	background: var(--sm-accent);
	color: var(--sm-ink);
	font-size: 11px;
	font-weight: 800;
	display: flex;
	align-items: center;
	justify-content: center;
}

.sm-cart-count.is-empty {
	display: none;
}

/* ---------- Търсене (FiboSearch или резервната форма) - долна линия, 320px ---------- */
.sm-search {
	display: flex;
	align-items: center;
	border-bottom: 1px solid var(--sm-ink);
	height: 36px;
	position: relative;
}

.sm-search--header {
	width: 320px;
	flex: 0 1 320px;
	min-width: 0;
}

.sm-search--drawer {
	height: 40px;
}

.sm-search .dgwt-wcas-search-wrapp {
	width: 100%;
	min-width: 0;
	max-width: none;
	margin: 0;
	color: var(--sm-ink);
}

.sm-search.sm-search .dgwt-wcas-sf-wrapp {
	background: transparent;
	padding: 0;
	border-radius: 0;
}

.sm-search.sm-search .dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input,
.sm-search__input {
	display: block;
	width: 100%;
	height: 36px;
	margin: 0;
	padding: 0 30px 0 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	outline: 0;
	font: 400 14px var(--sm-font);
	line-height: normal;
	color: var(--sm-ink);
	-webkit-appearance: none;
	appearance: none;
}

.sm-search--drawer.sm-search .dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input,
.sm-search--drawer .sm-search__input {
	height: 40px;
}

.sm-search.sm-search .dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp input[type=search].dgwt-wcas-search-input::placeholder,
.sm-search__input::placeholder {
	color: #757575;
	font-style: normal;
	font-weight: 400;
	opacity: 1;
}

.sm-search.sm-search .dgwt-wcas-search-wrapp .dgwt-wcas-sf-wrapp button.dgwt-wcas-search-submit {
	position: absolute;
	top: 0;
	bottom: 0;
	right: 0;
	left: auto;
	width: 22px;
	min-width: 22px;
	height: 22px;
	min-height: 22px;
	margin: auto 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 22 22' fill='none' stroke='%231F1F1F' stroke-width='1.5'%3E%3Ccircle cx='10' cy='10' r='6.5'/%3E%3Cpath d='M15 15l4.5 4.5'/%3E%3C/svg%3E") center / 22px 22px no-repeat;
	box-shadow: none;
	opacity: 1;
	pointer-events: auto;
	animation: none;
	cursor: pointer;
}

.sm-search .dgwt-wcas-search-submit::before,
.sm-search .dgwt-wcas-search-submit svg {
	display: none;
}

.sm-search .dgwt-wcas-preloader {
	right: 28px;
}

.sm-search__form {
	display: flex;
	align-items: center;
	width: 100%;
	position: relative;
}

.sm-search__submit {
	position: absolute;
	top: 0;
	bottom: 0;
	right: 0;
	width: 22px;
	height: 22px;
	margin: auto 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--sm-ink);
	cursor: pointer;
}

.sm-search__submit .sm-icon {
	display: block;
}

/* ---------- Дроуър ---------- */
.sm-overlay {
	position: fixed;
	inset: 0;
	background: rgba(31, 31, 31, .45);
	z-index: 90;
	opacity: 0;
	pointer-events: none;
	transition: opacity .25s;
}

.sm-drawer {
	position: fixed;
	top: 0;
	left: 0;
	bottom: 0;
	width: 360px;
	max-width: 100%;
	background: #FFFFFF;
	z-index: 91;
	transform: translateX(-105%);
	transition: transform .3s cubic-bezier(.2, .7, .2, 1), visibility .3s;
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	font-family: var(--sm-font);
	color: var(--sm-ink);
	visibility: hidden;
}

.sm-drawer-open .sm-overlay {
	opacity: 1;
	pointer-events: auto;
}

.sm-drawer-open .sm-drawer {
	transform: translateX(0);
	visibility: visible;
}

.sm-drawer__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 16px 14px 20px;
	border-bottom: 1px solid var(--sm-line);
}

.sm-drawer__close,
.sm-popup__close {
	width: 44px;
	height: 44px;
	border: 0;
	background: transparent;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	color: var(--sm-ink);
	padding: 0;
}

.sm-drawer__search {
	padding: 16px 20px 8px;
}

.sm-drawer__nav {
	flex: 1;
	overflow: auto;
	padding: 8px 0;
}

.sm-dmenu,
.sm-dmenu__sub,
.sm-dmenu__sub3 {
	list-style: none;
	margin: 0;
}

.sm-dmenu {
	padding: 0;
}

.sm-dmenu__item {
	border-bottom: 1px solid var(--sm-line);
}

.sm-dmenu__row {
	width: 100%;
	height: 52px;
	padding: 0 20px;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: space-between;
	border: 0;
	background: transparent;
	font: 700 15px var(--sm-font);
	color: var(--sm-ink);
	cursor: pointer;
	text-align: left;
}

.sm-dmenu__label {
	display: flex;
	align-items: center;
	gap: 10px;
}

.sm-dmenu__dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: transparent;
	flex: none;
}

.sm-dmenu__item.is-open .sm-dmenu__dot {
	background: var(--sm-accent);
}

.sm-dmenu__row .sm-icon {
	flex: none;
	transition: transform .2s;
}

.sm-dmenu__item.is-open .sm-dmenu__row .sm-icon {
	transform: rotate(90deg);
}

.sm-dmenu__row--link .sm-icon {
	opacity: .35;
}

.sm-dmenu__sub {
	padding: 0 20px 14px 36px;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2px 12px;
}

.sm-dmenu__sub[hidden] {
	display: none;
}

.sm-dmenu__sub a {
	display: block;
	font-size: 14px;
	padding: 7px 0;
	color: var(--sm-ink);
}

.sm-dmenu__sub3 {
	padding: 0 0 4px 10px;
}

.sm-dmenu__sub3 a {
	font-size: 13px;
	padding: 4px 0;
	color: var(--sm-muted);
}

.sm-drawer__foot {
	padding: 16px 20px;
	background: var(--sm-surface);
	font-size: 13px;
	display: flex;
	flex-wrap: wrap;
	gap: 6px 10px;
	align-items: center;
}

.sm-drawer__q {
	font-weight: 600;
}

.sm-drawer__phone {
	font-weight: 800;
}

.sm-drawer__sep {
	color: var(--sm-muted);
}

.sm-drawer__ext {
	text-decoration: underline;
}

/* ---------- Попъп HELLO10 ---------- */
.sm-popup {
	position: fixed;
	inset: 0;
	z-index: 95;
	background: rgba(31, 31, 31, .45);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	opacity: 0;
	pointer-events: none;
	visibility: hidden;
	transition: opacity .25s, visibility .25s;
	font-family: var(--sm-font);
	color: var(--sm-ink);
}

.sm-popup.is-open {
	opacity: 1;
	pointer-events: auto;
	visibility: visible;
}

.sm-popup__box {
	position: relative;
	width: 100%;
	max-width: 400px;
	background: #FFFFFF;
	border-radius: var(--sm-radius);
	padding: 36px 28px 28px;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 12px;
	box-sizing: border-box;
	outline: 0;
}

.sm-popup__close {
	position: absolute;
	top: 8px;
	right: 8px;
}

.sm-popup__kicker {
	font-size: 13px;
	font-weight: 700;
	color: var(--sm-muted);
	letter-spacing: .04em;
}

.sm-popup__title {
	margin: 0;
	font-size: 28px;
	font-weight: 800;
	line-height: 1.15;
}

.sm-popup__text {
	margin: 0;
	font-size: 15px;
	line-height: 1.5;
	color: var(--sm-muted);
}

.sm-popup__code {
	margin: 6px 0;
	height: 44px;
	padding: 0 22px;
	border: 1.5px dashed var(--sm-accent);
	border-radius: var(--sm-radius);
	display: flex;
	align-items: center;
	font-size: 20px;
	font-weight: 800;
	letter-spacing: .12em;
}

.sm-popup__form {
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.sm-popup__form .sm-input,
.sm-popup__form .sm-btn {
	width: 100%;
	box-sizing: border-box;
}

.sm-popup__dismiss {
	border: 0;
	background: transparent;
	font: 400 13px var(--sm-font);
	color: var(--sm-muted);
	text-decoration: underline;
	cursor: pointer;
	padding: 6px;
}

/* ---------- 768-1279: desktop клонът, флуидно (нищо не прелива) ---------- */
@media (max-width: 1099px) {
	.sm-hnav {
		display: none;
	}
}

/* ---------- Мобилно (390px клонът) ---------- */
@media (max-width: 767px) {
	.sm-usp__track {
		width: 100%;
		gap: 0;
		justify-content: flex-start;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scrollbar-width: none;
	}

	.sm-usp__track::-webkit-scrollbar {
		display: none;
	}

	.sm-usp__item {
		flex: 0 0 100%;
		min-width: 0;
		justify-content: center;
		scroll-snap-align: center;
	}

	.sm-usp__text {
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.sm-usp__sep,
	.sm-usp__dot {
		display: none;
	}

	.sm-header__bar--desktop {
		display: none;
	}

	.sm-header__bar--mobile {
		height: 60px;
		display: grid;
		grid-template-columns: 1fr auto 1fr;
		align-items: center;
		padding: 0 8px;
	}

	.sm-header__bar--mobile .sm-header__logo {
		height: auto;
		display: flex;
	}

	.sm-drawer-toggle--icon,
	.sm-header__micon {
		width: 44px;
		height: 44px;
		border: 0;
		background: transparent;
		display: flex;
		align-items: center;
		justify-content: center;
		color: var(--sm-ink);
		cursor: pointer;
		padding: 0;
		position: relative;
		border-radius: 0;
	}

	.sm-drawer-toggle--icon:hover {
		background: transparent;
	}

	.sm-header__micons {
		display: flex;
		justify-content: flex-end;
	}

	.sm-header__micon .sm-cart-count {
		top: 4px;
		right: 4px;
		min-width: 16px;
		height: 16px;
		padding: 0 4px;
		border-radius: 8px;
		font-size: 10px;
	}

	.sm-drawer {
		width: 340px;
	}
}
