/**
 * Sadaat Traders — Blocksy header skin.
 *
 * The structure remains 100% Blocksy Header Builder. These rules only style
 * Blocksy's documented header wrapper, rows, elements and the two small
 * shortcodes used inside free HTML header elements.
 */

#header {
	--theme-icon-color: var(--st-ink);
	--theme-icon-hover-color: var(--st-green-600);
	--theme-link-initial-color: var(--st-ink);
	--theme-link-hover-color: var(--st-green-600);
	position: relative;
	z-index: 30;
}

#header .site-branding img {
	width: auto;
	max-height: 64px;
	object-fit: contain;
}

/* --------------------------------------------------------------------------
   Top announcement row
   -------------------------------------------------------------------------- */

#header [data-row="top"] {
	background-color: var(--st-green-800);
	color: var(--st-white);
	font-family: var(--st-font-body);
}

#header [data-row="top"] > .ct-container {
	min-height: 36px;
}

/* Blocksy's HTML element wrapper is .ct-header-text (the internal element
   ID is "text"). .ct-header-html is kept as a forward-compatible alias. */
#header [data-row="top"] .ct-header-html,
#header [data-row="top"] .ct-header-text,
#header [data-row="top"] [data-items="primary"] {
	width: 100%;
}

#header [data-row="middle"] .ct-header-text {
	width: 100%;
	min-width: 0;
}

.st-topbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--st-space-4);
	width: 100%;
	color: var(--st-white);
	font-size: var(--st-fs-xs);
	line-height: 1.45;
}

.st-topbar__points {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0;
	margin: 0;
	padding: 0;
	list-style: none;
}

.st-topbar__points li {
	display: inline-flex;
	align-items: center;
	white-space: nowrap;
}

.st-topbar__points li + li::before {
	content: "";
	width: 1px;
	height: 12px;
	margin-inline: 0.75rem;
	background-color: rgba(255, 255, 255, 0.28);
}

.st-topbar__contact {
	display: flex;
	align-items: center;
	gap: 1rem;
	flex: 0 0 auto;
}

.st-topbar__contact a {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	color: var(--st-white);
	font-weight: var(--st-fw-medium);
	text-decoration: none;
	white-space: nowrap;
}

.st-topbar__contact a:hover {
	color: var(--st-green-100);
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.st-topbar__contact a::before {
	content: "";
	width: 14px;
	height: 14px;
	flex: 0 0 14px;
	background-color: currentColor;
	-webkit-mask: var(--st-topbar-icon) center / contain no-repeat;
	mask: var(--st-topbar-icon) center / contain no-repeat;
}

.st-topbar__phone {
	--st-topbar-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.9v3a2 2 0 0 1-2.2 2 19.8 19.8 0 0 1-8.6-3.1 19.5 19.5 0 0 1-6-6A19.8 19.8 0 0 1 2.1 4.2 2 2 0 0 1 4.1 2h3a2 2 0 0 1 2 1.7c.1 1 .4 2 .7 2.9a2 2 0 0 1-.5 2.1L8 10a16 16 0 0 0 6 6l1.3-1.3a2 2 0 0 1 2.1-.5c.9.3 1.9.6 2.9.7a2 2 0 0 1 1.7 2Z'/%3E%3C/svg%3E");
}

.st-topbar__whatsapp {
	--st-topbar-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M17.5 14.4c-.3-.2-1.8-.9-2.1-1-.3-.1-.5-.2-.7.1-.2.3-.8 1-.9 1.2-.2.2-.3.2-.6.1-.3-.2-1.3-.5-2.5-1.5-.9-.8-1.5-1.8-1.7-2.1-.2-.3 0-.5.1-.6l.5-.6c.2-.2.2-.3.3-.5.1-.2.1-.4 0-.5l-.9-2.1c-.2-.5-.5-.5-.7-.5h-.6c-.2 0-.6.1-.9.4-.3.3-1.1 1.1-1.1 2.7s1.2 3.2 1.4 3.4c.2.2 2.4 3.7 5.8 5 .8.3 1.2.4 1.6.4.7 0 2.3-.9 2.6-1.8.3-.9.3-1.7.2-1.8-.1-.2-.2-.3-.5-.5Z'/%3E%3Cpath d='M12 2a10 10 0 0 0-8.6 15.1L2 22l5-1.3A10 10 0 1 0 12 2Zm0 18.2c-1.5 0-2.9-.4-4.1-1.1l-.3-.2-3 .8.8-2.9-.2-.3A8.2 8.2 0 1 1 12 20.2Z'/%3E%3C/svg%3E");
}

.st-topbar__email {
	--st-topbar-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='4' width='20' height='16' rx='2'/%3E%3Cpath d='m22 7-10 6L2 7'/%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   Main header row
   -------------------------------------------------------------------------- */

#header [data-row="middle"] {
	background-color: var(--st-white);
	border-bottom: 1px solid var(--st-border);
}

#header [data-row="middle"] > .ct-container {
	min-height: 84px;
}

#header [data-row="middle"][data-column-set="3"] > .ct-container {
	grid-template-columns: auto minmax(260px, 1fr) auto;
	align-items: center;
	column-gap: clamp(1rem, 2.5vw, 2rem);
}

#header [data-row="middle"] [data-column="middle"],
#header [data-row="middle"] [data-column="middle"] > [data-items] {
	width: 100%;
	min-width: 0;
}

#header .ct-account-item,
#header .ct-cart-item {
	font-family: var(--st-font-body);
	font-size: var(--st-fs-sm);
	font-weight: var(--st-fw-semibold);
}

#header .ct-header-cart .ct-cart-item {
	min-width: 44px;
	min-height: 44px;
	justify-content: center;
}

/* Desktop Search and My Account targets: 44x44 without changing the
   15px icons or the middle-row alignment. */
#header [data-device="desktop"] .ct-header-search,
#header [data-device="desktop"] .ct-account-item {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
	padding: 0;
	flex: 0 0 auto;
}

/* Inline product search (shortcode inside a Blocksy HTML element). */
.st-header-search {
	width: 100%;
	max-width: 720px;
	margin-inline: auto;
}

.st-header-search__form {
	display: flex;
	align-items: stretch;
	width: 100%;
	min-height: 46px;
	overflow: hidden;
	border: 1px solid var(--st-border-strong);
	border-radius: var(--st-radius-sm);
	background-color: var(--st-white);
	transition:
		border-color var(--st-transition),
		box-shadow var(--st-transition);
}

.st-header-search__form:focus-within {
	border-color: var(--st-green-600);
	box-shadow: var(--st-focus-ring);
}

.st-header-search .search-field {
	flex: 1 1 auto;
	min-width: 0;
	min-height: 44px;
	padding: 0.6rem 1rem;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--st-ink);
	font-family: var(--st-font-body);
	font-size: var(--st-fs-sm);
	outline: none;
}

.st-header-search .search-field::placeholder {
	color: #69736e;
	opacity: 1;
}

.st-header-search .search-submit {
	position: relative;
	flex: 0 0 52px;
	width: 52px;
	min-height: 44px;
	border: 0;
	border-radius: 0;
	background-color: var(--st-green-700);
	color: var(--st-white);
	cursor: pointer;
	transition: background-color var(--st-transition);
}

.st-header-search .search-submit::before {
	content: "";
	position: absolute;
	inset: 0;
	width: 20px;
	height: 20px;
	margin: auto;
	background-color: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-4-4'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-4-4'/%3E%3C/svg%3E") center / contain no-repeat;
}

.st-header-search .search-submit:hover {
	background-color: var(--st-green-600);
}


/* --------------------------------------------------------------------------
   Category row and header call to action
   -------------------------------------------------------------------------- */

#header [data-row="bottom"] {
	background-color: var(--st-white);
	border-bottom: 1px solid var(--st-border);
}

#header [data-row="bottom"] > .ct-container {
	min-height: 56px;
}

#header [data-row="bottom"] .menu-container .menu > li > .ct-menu-link {
	color: var(--st-ink);
	font-family: var(--st-font-body);
	font-size: var(--st-fs-sm);
	font-weight: var(--st-fw-semibold);
}

#header [data-row="bottom"] .menu-container .menu > li > .ct-menu-link:hover,
#header [data-row="bottom"] .menu-container .menu > li.current-menu-item > .ct-menu-link {
	color: var(--st-green-600);
}

/* Optional: make the first category-menu item ("Shop All") read as a button.
   The same effect appears when that item is first in the desktop menu. */
#header [data-row="bottom"] .menu-container .menu > li:first-child > .ct-menu-link {
	display: inline-flex;
	align-items: center;
	min-height: 36px;
	padding: 0.35rem 0.9rem;
	border-radius: var(--st-radius-sm);
	background-color: var(--st-green-700);
	color: var(--st-white);
}

#header [data-row="bottom"] .menu-container .menu > li:first-child > .ct-menu-link:hover {
	background-color: var(--st-green-600);
	color: var(--st-white);
}

#header .ct-header-cta .ct-button,
#header .ct-header-cta .ct-button-ghost {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding-inline: 1.1rem;
	border-radius: var(--st-radius-sm);
	font-family: var(--st-font-body);
	font-size: var(--st-fs-sm);
	font-weight: var(--st-fw-semibold);
	text-decoration: none;
	transition:
		background-color var(--st-transition),
		border-color var(--st-transition),
		color var(--st-transition);
}

#header .ct-header-cta .ct-button {
	border: 1px solid var(--st-green-700);
	background-color: var(--st-green-700);
	color: var(--st-white);
}

#header .ct-header-cta .ct-button:hover {
	border-color: var(--st-green-600);
	background-color: var(--st-green-600);
	color: var(--st-white);
}

#header .ct-header-cta .ct-button-ghost {
	border: 1px solid var(--st-green-700);
	background-color: transparent;
	color: var(--st-green-700);
}

#header .ct-header-cta .ct-button-ghost:hover {
	background-color: var(--st-green-100);
	color: var(--st-green-800);
}

/* --------------------------------------------------------------------------
   Responsive header
   -------------------------------------------------------------------------- */

@media (max-width: 1100px) {
	.st-topbar__points li:nth-child(3) {
		display: none;
	}
}

@media (max-width: 960px) {
	#header [data-row="middle"][data-column-set="3"] > .ct-container {
		grid-template-columns: auto minmax(200px, 1fr) auto;
	}

	.st-topbar__contact a[href^="mailto:"] {
		display: none;
	}
}

@media (max-width: 781px) {
	#header [data-device="mobile"] [data-row] > .ct-container {
		min-height: 64px;
	}

	/* Keep the logo centered while giving the menu and search separate tap targets. */
	#header [data-device="mobile"] [data-row="middle"][data-column-set="3"] > .ct-container {
		grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
		column-gap: 8px;
	}

	#header [data-device="mobile"] [data-row="middle"] [data-column="start"][data-placements="2"] {
		grid-template-columns: max-content max-content;
		justify-content: start;
		column-gap: 6px;
	}

	#header [data-device="mobile"] [data-column="start"] .ct-header-trigger,
	#header [data-device="mobile"] [data-column="start"] .ct-header-search {
		margin-inline: 0;
	}

	#header [data-device="mobile"] .site-branding img {
		max-height: 42px;
	}

	#header [data-device="mobile"] .ct-header-search,
	#header [data-device="mobile"] .ct-header-trigger,
	#header [data-device="mobile"] .ct-header-cart .ct-cart-item {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		min-width: 44px;
		min-height: 44px;
	}

	#header [data-device="mobile"] [data-items="primary"] {
		gap: 0.25rem;
	}

	#header [data-device="mobile"] [data-row="top"] {
		display: none;
	}

	.st-topbar {
		font-size: var(--st-fs-2xs);
	}

	.st-topbar__points li:nth-child(2) {
		display: none;
	}

	.st-header-search {
		max-width: none;
	}
}

/* Off-canvas touch targets. */
#offcanvas .ct-menu-link,
#offcanvas .ct-header-cta a {
	display: flex;
	align-items: center;
	min-height: 44px;
}

@media (prefers-reduced-motion: reduce) {
	.st-header-search .search-submit,
	#header .ct-header-cta .ct-button,
	#header .ct-header-cta .ct-button-ghost {
		transition: none;
	}
}

