/**
 * Header CSS — log-core
 * Covers: site header, mobile search bar, mobile nav panel.
 */

/* Marquee plugin JS sets body padding-top:50px; correct to exact marquee height.
   overflow-x:clip instead of hidden — hidden breaks position:sticky by making body the scroll container */
body {
	padding-top: 36px !important;
	overflow-x: clip !important;
}

/* ── Site Header ──────────────────────────────────────────── */
header.log-site-header {
	background: var(--paper-50);
	position: sticky;
	top: 36px;
	/* marquee bar height */
	z-index: 200;
	border-bottom: 1px solid var(--line);
	transition: box-shadow .35s var(--ease);
}

header.log-site-header.scrolled {
	box-shadow: var(--shadow-md);
}

.log-nav-row {
	display: flex;
	align-items: center;
	height: 84px;
	padding: 0 48px;
	transition: height .35s var(--ease);
}

header.log-site-header.scrolled .log-nav-row {
	height: 64px;
}

/* Logo */
.log-site-logo {
	display: flex;
	align-items: center;
	gap: 12px;
	font-family: var(--display);
	font-size: 25px;
	font-weight: 700;
	color: var(--ink-900);
	transition: font-size .35s var(--ease);
	flex-shrink: 0;
	min-width: 160px;
	text-decoration: none;
}

header.log-site-header.scrolled .log-site-logo {
	font-size: 21px;
}

.log-logo-mark {
	width: 44px;
	height: 44px;
	border-radius: 13px;
	background: linear-gradient(150deg, var(--sage-600), var(--plum-800));
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--sage-400);
	box-shadow: var(--shadow-sm);
	flex-shrink: 0;
	transition: width .35s, height .35s;
}

header.log-site-header.scrolled .log-logo-mark {
	width: 36px;
	height: 36px;
}

.log-logo-mark svg {
	width: 21px;
	height: 21px;
	stroke: currentColor;
	fill: none;
	stroke-width: 2.2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.log-site-logo b {
	color: var(--plum-700);
}

.log-site-logo.has-image {
	min-width: 0;
}

.log-site-logo.has-image .custom-logo-link {
	display: flex;
	align-items: center;
}

.log-site-logo.has-image img {
	height: 175px;
	width: auto;
	max-width: 100%;
	transition: height .35s var(--ease);
}

header.log-site-header.scrolled .log-site-logo.has-image img {
	height: 175px;
}

/* Desktop Nav */
nav.log-main-links {
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 1;
}

nav.log-main-links ul {
	display: flex;
	align-items: center;
	gap: 24px;
	list-style: none;
	margin: 0;
	padding: 0;
}

nav.log-main-links ul li {
	margin: 0;
	padding: 0;
}

nav.log-main-links a {
	font-size: 13px;
	font-weight: 700;
	letter-spacing: .06em;
	color: var(--ink-700);
	text-transform: uppercase;
	position: relative;
	padding: 6px 0;
	transition: color .25s var(--ease);
	text-decoration: none;
}

nav.log-main-links a::after {
	content: '';
	position: absolute;
	left: 0;
	bottom: 0;
	height: 2px;
	width: 0;
	background: var(--sage-600);
	transition: width .3s var(--ease);
}

nav.log-main-links a:hover,
nav.log-main-links li.current-menu-item>a {
	color: var(--plum-700);
}

nav.log-main-links a:hover::after,
nav.log-main-links li.current-menu-item>a::after {
	width: 100%;
}

/* Head Actions */
.log-head-actions {
	display: flex;
	align-items: center;
	gap: 14px;
	min-width: 160px;
	justify-content: flex-end;
}

/* Desktop search */
.log-header-search-wrap {
	display: flex;
	align-items: center;
	background: var(--paper);
	border: 2px solid var(--plum-500);
	border-radius: var(--r-pill);
	overflow: visible;
	transition: border-color .3s var(--ease), box-shadow .3s var(--ease);
	box-shadow: 0 2px 8px rgba(31, 14, 28, .05);
}

.log-header-search-wrap:focus-within {
	border-color: var(--plum-700);
	box-shadow: 0 0 0 3px rgba(122, 31, 110, .12), 0 2px 12px rgba(122, 31, 110, .1);
}

.log-hs-icon-pill {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	flex-shrink: 0;
	color: var(--plum-700);
}

.log-hs-icon-pill svg {
	width: 16px;
	height: 16px;
	stroke: currentColor;
	fill: none;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.log-header-search-wrap input {
	border: none;
	background: none;
	font-family: var(--body);
	font-size: 13px;
	font-weight: 500;
	color: var(--ink-900);
	padding: 9px 14px 9px 0;
	width: 200px;
	outline: none;
}

.log-header-search-wrap input::placeholder {
	color: var(--gray-400);
}

/* Cart button */
.log-cart-btn {
	position: relative;
	width: 42px;
	height: 42px;
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--ink-700);
	background: var(--paper);
	transition: background .25s, transform .25s;
	text-decoration: none;
}

.log-cart-btn:hover {
	background: var(--blush-100);
	transform: translateY(-1px);
}

.log-cart-btn svg {
	width: 19px;
	height: 19px;
	stroke: currentColor;
	fill: none;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.log-cart-badge {
	position: absolute;
	top: -5px;
	right: -5px;
	background: var(--plum-700);
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 2px solid var(--paper-50);
	transition: transform .25s var(--ease);
	line-height: 1;
}

.log-cart-badge[data-count="0"] {
	display: none;
}

/* Burger */
.log-burger {
	display: none;
	width: 42px;
	height: 42px;
	border-radius: 12px;
	align-items: center;
	justify-content: center;
	background: var(--paper);
	border: none;
	cursor: pointer;
	color: var(--ink-700);
}

.log-burger svg {
	width: 20px;
	height: 20px;
	stroke: currentColor;
	fill: none;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* Mobile search bar */
.log-mobile-search-bar {
	display: none;
	padding: 10px 16px 12px;
	background: var(--paper-50);
	border-bottom: 1px solid var(--line);
}

.log-mobile-search-inner {
	display: flex;
	align-items: center;
	gap: 10px;
	background: var(--paper);
	border: 1.5px solid var(--line);
	border-radius: var(--r-pill);
	padding: 0 16px;
	transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}

.log-mobile-search-inner:focus-within {
	border-color: var(--plum-700);
	box-shadow: 0 0 0 3px rgba(122, 31, 110, .1);
}

.log-mobile-search-inner .ms-icon {
	width: 16px;
	height: 16px;
	color: var(--plum-700);
	flex-shrink: 0;
	stroke: currentColor;
	fill: none;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.log-mobile-search-inner input {
	flex: 1;
	border: none;
	background: none;
	font-family: var(--body);
	font-size: 14px;
	font-weight: 500;
	color: var(--ink-900);
	padding: 12px 0;
	outline: none;
}

.log-mobile-search-inner input::placeholder {
	color: var(--gray-400);
}

/* Mobile nav panel */
.log-mobile-panel {
	display: none;
	flex-direction: column;
	gap: 4px;
	background: var(--white);
	border-top: 1px solid var(--line);
	padding: 14px 24px 20px;
}

/* wp_nav_menu() always wraps each link in <li> even with no container/ul —
   the reference mockup hardcodes plain <a> tags with no <li>, so it never
   needed this reset. Without it, browsers show a bullet marker on <li>
   regardless of list-style on an ancestor. */
.log-mobile-panel li {
	list-style: none;
	margin: 0;
	padding: 0;
}

.log-mobile-panel a {
	display: block;
	padding: 12px 4px;
	font-weight: 700;
	font-size: 13px;
	letter-spacing: .05em;
	text-transform: uppercase;
	color: var(--ink-700);
	border-bottom: 1px solid var(--line);
	text-decoration: none;
}

/* WP applies .current-menu-item to the <li>, not the <a> — the old
   ".log-mobile-panel a.current-menu-item" selector could never match. */
.log-mobile-panel li.current-menu-item>a,
.log-mobile-panel a:hover {
	color: var(--plum-700);
}

.log-mobile-panel.open {
	display: flex;
}

/* Responsive
   1300px (not 900px) — 7 nav items + logo + search + cart don't fit in one
   row below ~1200-1280px; the <ul> wraps to a 2nd line and overlaps the
   search box (e.g. on 13" MacBook-class viewports). Raised so laptop/small-
   desktop widths get the working mobile nav instead of a broken squeezed one. */
@media (max-width: 1300px) {
	nav.log-main-links {
		display: none;
	}

	.log-burger {
		display: flex;
	}

	.log-mobile-search-bar {
		display: block;
	}

	.log-header-search-wrap {
		display: none !important;
	}

	.log-head-actions {
		margin-left: auto;
	}

	.log-nav-row {
		padding-left: 20px;
		padding-right: 20px;
	}

	/* Marquee height varies on mobile (text wraps, or plugin's own close
	   button removes it) — track the real height via JS instead of the
	   hardcoded 36px used on desktop. See log-header.js ResizeObserver. */
	body {
		padding-top: var(--marquee-h, 36px) !important;
	}

	header.log-site-header {
		top: var(--marquee-h, 36px);
	}
}

/* WP admin bar (32px) + marquee (36px) = 68px when logged in */
.admin-bar header.log-site-header {
	top: 68px;
}