/* ===== Site Header ===== */
.header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	z-index: 1000;
	height: var(--header-height);
	min-height: var(--header-height);
	background: var(--header-surface);
	border-bottom: 1px solid var(--header-divider);
	transition: box-shadow var(--duration-base) var(--ease-smooth), border-color var(--duration-base) var(--ease-smooth);
}

.header.is-scrolled,
.header.is-compact {
	background: var(--header-surface);
	border-color: rgba(17, 17, 17, 0.1);
	box-shadow: 0 8px 30px rgba(17, 17, 17, 0.07);
}

.navbar {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: var(--header-tier-gap);
	min-height: var(--header-height);
	height: 100%;
	padding-block: var(--header-padding-top) var(--header-padding-bottom);
}

.navbar-main {
	width: 100%;
	min-width: 0;
	display: grid;
	grid-template-columns: minmax(140px, 230px) minmax(260px, 560px) auto;
	align-items: center;
	gap: clamp(14px, 2.4vw, 28px);
}

.logo,
.brand-logo {
	display: inline-flex;
	align-items: center;
	justify-self: start;
	min-width: 0;
	max-width: 100%;
}

.brand-logo--header {
	--brand-logo-font-size: clamp(1rem, 1.02vw, 1.15rem);
	--brand-logo-tracking: 0.22em;
}

.header-search {
	position: relative;
	min-width: 0;
	display: flex;
	align-items: center;
	width: min(100%, 560px);
	justify-self: center;
	height: 42px;
	border: 1px solid var(--color-border-strong);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.44);
	transition: border-color var(--duration-base) var(--ease-smooth), box-shadow var(--duration-base) var(--ease-smooth);
}

.header-search:focus-within {
	border-color: #111111;
	box-shadow: 0 10px 28px rgba(17, 17, 17, 0.08);
}

.header-search-input {
	width: 100%;
	height: 100%;
	min-width: 0;
	padding: 0 84px 0 15px;
	border: 0;
	outline: 0;
	background: transparent;
	color: var(--color-ink);
	font-size: 0.94rem;
	font-weight: var(--font-weight-medium);
}

.header-search-input::placeholder {
	color: #8b8b8b;
	font-weight: var(--font-weight-regular);
}

.header-search-clear,
.header-search-button {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	display: grid;
	place-items: center;
}

.header-search-clear {
	right: 52px;
	width: 30px;
	height: 30px;
	border-radius: var(--radius-pill);
	color: #8c8c8c;
}

.header-search-button {
	right: 6px;
	width: 36px;
	height: 32px;
	border-radius: 9px;
	background: rgba(17, 17, 17, 0.055);
	color: var(--color-ink);
}

.header-search-clear-icon,
.header-search-button-icon {
	display: block;
	pointer-events: none;
	user-select: none;
}

.header-search-clear-icon {
	width: 16px;
	height: 16px;
}

.header-search-button-icon {
	width: 20px;
	height: 20px;
	object-fit: contain;
	opacity: 0.92;
}

.header-actions,
.nav-icons {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	min-width: 0;
}

.header-action,
.cart-icon {
	position: relative;
	display: inline-grid;
	place-items: center;
	width: var(--tap-size);
	height: var(--tap-size);
	min-width: var(--tap-size);
	border-radius: var(--radius-pill);
	background: transparent;
	color: var(--color-ink);
}

.cart-icon {
	border-radius: 0;
}

.header-action-icon {
	display: block;
	width: 22px;
	height: 22px;
	object-fit: contain;
	pointer-events: none;
	user-select: none;
}

.cart-icon .header-action-icon {
	width: 23px;
	height: 23px;
	filter: none;
}

.cart-count,
.header-action-count {
	position: absolute;
	top: 2px;
	right: 1px;
	display: grid;
	place-items: center;
	min-width: 18px;
	height: 18px;
	padding-inline: 4px;
	border-radius: var(--radius-pill);
	background: var(--color-danger);
	color: #ffffff;
	font-size: 0.68rem;
	font-weight: var(--font-weight-semibold);
	line-height: 1;
	border: 2px solid #ffffff;
}


.cart-count[hidden],
html:not(.is-google-authenticated) .cart-count {
	display: none !important;
}

/* Universal navigation drawer: the top links live only inside this right-side panel on every viewport. */
.nav-drawer-scrim {
	position: fixed;
	top: var(--header-height-live, var(--header-height));
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 998;
	background: rgba(17, 17, 17, 0.26);
	visibility: hidden;
	opacity: 0;
	pointer-events: none;
	transition: opacity 220ms var(--ease-smooth), visibility 0s linear 220ms;
}

.nav-drawer-scrim.active {
	visibility: visible;
	opacity: 1;
	pointer-events: auto;
	transition: opacity 220ms var(--ease-smooth), visibility 0s;
}

.header-menu,
.nav-links {
	position: fixed;
	top: var(--header-height-live, var(--header-height));
	right: 0;
	bottom: 0;
	z-index: 999;
	display: grid;
	grid-template-columns: 1fr;
	align-content: start;
	gap: 0;
	width: min(86vw, 390px);
	max-width: 100%;
	height: calc(100dvh - var(--header-height-live, var(--header-height)));
	min-height: 0;
	padding: 18px 0 max(28px, env(safe-area-inset-bottom));
	overflow-x: hidden;
	overflow-y: auto;
	overscroll-behavior: contain;
	border-left: 1px solid var(--header-divider);
	background: var(--header-surface-solid);
	box-shadow: -18px 0 46px rgba(17, 17, 17, 0.12);
	visibility: hidden;
	opacity: 1;
	pointer-events: none;
	transform: translate3d(100%, 0, 0);
	transition: transform 260ms var(--ease-smooth), visibility 0s linear 260ms;
	contain: layout paint;
}

.nav-links.active {
	visibility: visible;
	pointer-events: auto;
	transform: translate3d(0, 0, 0);
	transition: transform 260ms var(--ease-smooth), visibility 0s;
}

.nav-links li {
	width: 100%;
	list-style: none;
}

.nav-links a {
	position: relative;
	white-space: normal;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	min-height: 58px;
	padding: 0 clamp(22px, 5vw, 34px);
	border-bottom: 1px solid rgba(17, 17, 17, 0.065);
	color: var(--color-ink);
	font-size: 0.92rem;
	font-weight: var(--font-weight-semibold);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	transition: background-color var(--duration-base) var(--ease-smooth), color var(--duration-base) var(--ease-smooth), padding-left var(--duration-base) var(--ease-smooth);
}

.nav-links a::after {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	width: 3px;
	height: 20px;
	border-radius: 0 var(--radius-pill) var(--radius-pill) 0;
	background: #111111;
	opacity: 0;
	transform: translateY(-50%);
	transition: opacity var(--duration-base) var(--ease-smooth);
}

.nav-links a:focus-visible {
	color: #111111;
}

.nav-links a:focus-visible::after,
.nav-links a[aria-current="page"]::after {
	opacity: 1;
}

.mobile-menu-toggle {
	position: relative;
	display: inline-grid;
}

.mobile-menu-toggle i {
	display: none;
}

.mobile-menu-toggle::before,
.mobile-menu-toggle::after {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	width: 18px;
	height: 2px;
	border-radius: var(--radius-pill);
	background: currentColor;
	transition: transform var(--duration-base) var(--ease-smooth), box-shadow var(--duration-base) var(--ease-smooth);
}

.mobile-menu-toggle::before {
	transform: translate(-50%, -6px);
	box-shadow: 0 6px 0 currentColor;
}

.mobile-menu-toggle::after {
	transform: translate(-50%, 6px);
}

.mobile-menu-toggle.active::before {
	transform: translate(-50%, 0) rotate(45deg);
	box-shadow: 0 0 0 currentColor;
}

.mobile-menu-toggle.active::after {
	transform: translate(-50%, 0) rotate(-45deg);
}


@media (hover: hover) and (pointer: fine) {
	.nav-links a:hover {
		color: #111111;
		background: rgba(17, 17, 17, 0.035);
		padding-left: clamp(26px, 5.4vw, 38px);
	}

	.nav-links a:hover::after {
		opacity: 1;
	}
}

/* Google-gated header controls: search and wishlist remain unavailable until Google login is active. */
.header-member-control[hidden],
html:not(.is-member-authenticated) .header-member-control[data-auth-gated="member"] {
	display: none !important;
}


.header[data-global-shell="header"] {
	isolation: isolate;
}
