/* ==========================================================================
   SHEENEFFECT — header redesign (obh), 2026-12-04
   结构参考 ourbellacosmetics.com：单行栅格「logo | navigation | icons」，
   菜单 hover 下划线展开、带 chevron 的下拉、滚动后加投影。
   字体与页脚(.obf-footer)一致：正文无衬线栈 / 15px。
   须在 assets/css/style.css、ses-locale.css、ses-brand.css 之后加载。
   ========================================================================== */

/* ---------- 0. 变量 ---------- */
.obh {
	--obh-font: "Helvetica Neue", "Segoe UI", "PingFang SC", system-ui, sans-serif;
	--obh-ink: rgb(25, 23, 25);
	--obh-ink-72: rgba(25, 23, 25, .72);
	--obh-line: rgb(231, 223, 226);
	--obh-bg: rgb(252, 251, 249);
	--obh-h: 76px;
}

/* ---------- 1. 公告条 ---------- */
/* style.css 里有 `.promo-bar{background:var(--rose)!important}`，必须同级加 important 才能覆盖 */
.promo-bar.promo-bar--ourbella {
	height: 38px;
	background: rgb(58, 18, 32) !important;
	/* flex 容器：让 track 在视口内水平居中 */
	display: flex;
	justify-content: center;
	/* 跑马灯 track 铺满并超出视口，必须裁剪，否则撑出全站横向滚动条 */
	overflow: hidden;
}
.promo-bar--ourbella .promo-bar__track {
	height: 38px;
	/* 视觉居中：track 至少占满视口并水平居中，使 marquee 相对屏幕中央对称进出 */
	min-width: 100%;
	justify-content: center;
}
.promo-bar--ourbella .promo-bar__track span {
	font-family: var(--obh-font, "Helvetica Neue", "Segoe UI", "PingFang SC", system-ui, sans-serif);
	font-size: 12px;
	font-weight: 500;
	letter-spacing: .06em;
	gap: 2.4rem;
	padding: 0 1.2rem;
	color: rgba(255, 255, 255, .92);
	/* 垂直居中对齐 */
	align-items: center;
	justify-content: center;
}
.promo-bar--ourbella .promo-bar__track .d { background: rgba(243, 184, 207, .55); }
.promo-bar--ourbella a { color: #f3b8cf; text-underline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
	.promo-bar--ourbella .promo-bar__track { animation: none; justify-content: center; }
}

/* ---------- 2. 头部容器 ---------- */
.site-header.obh {
	position: sticky;
	top: 0;
	z-index: 50;
	background: var(--obh-bg);
	color: var(--obh-ink);
	box-shadow: none;
	border-bottom: 1px solid var(--obh-line);
	font-family: var(--obh-font);
	transition: box-shadow .25s ease;
}
.site-header.obh.is-scrolled { box-shadow: 0 4px 18px rgba(25, 23, 25, .1); }
/* ses-ux.js 注入的免邮进度条由上方 sticky 规则接管 */

.obh__bar {
	display: grid;
	/* 第三列用 max-content，保证图标组永远拿到完整宽度，不被 1fr 压到溢出 */
	grid-template-columns: minmax(0, 1fr) minmax(0, fit-content(66%)) max-content;
	grid-template-areas: "logo nav tools";
	align-items: center;
	column-gap: 24px;
	max-width: 1440px;
	min-height: var(--obh-h);
	/* 全宽栅格：抵消 .container 的 width:calc(100%-32px) 居中，参考站头部是近满幅的 */
	width: 100%;
	max-width: none;
	padding: 0 clamp(16px, 3vw, 44px);
}

/* ses-ux.js 免邮进度条：sticky 定位在头部上沿，铺满整行，不挤进栅格 */
.obh > #free-ship-bar {
	position: sticky;
	top: 0;
	z-index: 2;
	width: 100%;
	margin: 0;
}
/* 公告条被移出文档流后由免邮条补位，头部自身 sticky 吸顶 */
.obh { padding-top: 0; }

/* ---------- 3. 品牌字标（左） ---------- */
.obh .obh__logo {
	grid-area: logo;
	justify-self: start;
	min-width: 0;
}
.obh .obh__logo img { height: 30px; }

/* ---------- 4. 汉堡（移动端） ---------- */
.obh__burger {
	grid-area: burger;
	display: none;
	width: 40px;
	height: 40px;
	margin-left: -8px;
	align-items: center;
	justify-content: center;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--obh-ink);
	cursor: pointer;
	transition: background .18s ease;
}
.obh__burger:hover,
.obh__burger[aria-expanded="true"] { background: rgba(25, 23, 25, .06); }

/* ---------- 5. 主菜单（中） ---------- */
.obh__nav { grid-area: nav; justify-self: center; min-width: 0; }
.obh__menu,
.obh__sub-list {
	display: flex;
	list-style: none;
	margin: 0;
	padding: 0;
}
.obh__item { position: relative; }
.obh__link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 24px clamp(7px, 1vw, 14px);
	font-family: var(--obh-font);
	font-size: 15px;
	font-weight: 500;
	line-height: 1.4;
	letter-spacing: .01em;
	color: var(--obh-ink);
	text-decoration: none;
	white-space: nowrap;
	-webkit-tap-highlight-color: transparent;
}
/* 下划线：默认 0 宽，hover / 当前页从左向右展开（参考站 reversed-link） */
.obh__label {
	padding-bottom: 3px;
	background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
	transition: background-size .3s cubic-bezier(.25, .46, .45, .94);
}
.obh__link:hover .obh__label,
.obh__link:focus-visible .obh__label,
.obh__item.is-current > .obh__link .obh__label,
.obh__item.is-open > .obh__link .obh__label {
	background-size: 100% 1px;
}
.obh__link:focus-visible { outline: 2px solid var(--obh-ink); outline-offset: -4px; border-radius: 4px; }
.obh__chev { flex: 0 0 auto; margin-top: 1px; opacity: .7; transition: transform .2s ease, opacity .2s ease; }
.obh__item:hover > .obh__link .obh__chev,
.obh__item.is-open > .obh__link .obh__chev { transform: rotate(180deg); opacity: 1; }

/* ---------- 6. 下拉面板 ---------- */
.obh__sub {
	position: absolute;
	left: 50%;
	top: 100%;
	z-index: 60;
	min-width: 250px;
	padding: 12px 0;
	background: #fff;
	border: 1px solid var(--obh-line);
	box-shadow: 0 18px 36px -14px rgba(25, 23, 25, .22);
	opacity: 0;
	visibility: hidden;
	transform: translate(-50%, 8px);
	transition: opacity .18s ease, transform .18s ease, visibility .18s;
	pointer-events: none;
}
.obh__item:hover > .obh__sub,
.obh__item:focus-within > .obh__sub,
.obh__item.is-open > .obh__sub {
	opacity: 1;
	visibility: visible;
	transform: translate(-50%, 0);
	pointer-events: auto;
}
.obh__sub-list { flex-direction: column; }
.obh__sub-list a {
	display: block;
	padding: 9px 24px;
	font-family: var(--obh-font);
	font-size: 15px;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: .01em;
	color: var(--obh-ink-72);
	text-decoration: none;
	white-space: nowrap;
	transition: color .15s ease, background .15s ease;
}
.obh__sub-list a:hover,
.obh__sub-list a:focus-visible { color: var(--obh-ink); background: rgba(25, 23, 25, .045); }
.obh__sub-list a:focus-visible { outline: 2px solid var(--obh-ink); outline-offset: -2px; }
@media (prefers-reduced-motion: reduce) {
	.obh__sub { transition: none; transform: translate(-50%, 0); }
	.obh__label { transition: none; }
}

/* ---------- 7. 右侧图标组 ---------- */
.obh__tools {
	grid-area: tools;
	justify-self: end;
	display: flex;
	align-items: center;
	gap: 2px;
	min-width: 0;
}
/* 图标按钮：统一 40px 圆形点击区、细线图标、无边框 */
.obh .icon-btn {
	width: 40px;
	height: 40px;
	flex: 0 0 40px;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--obh-ink);
	box-shadow: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background .18s ease, color .18s ease;
}
.obh .icon-btn:hover,
.obh .icon-btn[aria-expanded="true"] {
	background: rgba(25, 23, 25, .06);
	color: var(--obh-ink);
	border: 0;
}
.obh .icon-btn svg { display: block; }
.obh .icon-btn:focus-visible { outline: 2px solid var(--obh-ink); outline-offset: 2px; }

/* 购物袋角标 */
.obh .cart-count {
	top: 3px;
	right: 1px;
	min-width: 17px;
	height: 17px;
	padding: 0 4px;
	border: 2px solid var(--obh-bg);
	border-radius: 9px;
	background: var(--obh-ink);
	font-family: var(--obh-font);
	font-size: 10px;
	font-weight: 600;
	line-height: 13px;
	letter-spacing: 0;
}
.obh .cart-count.is-empty { display: none; }

/* 语言/货币按钮：与图标组同形（覆盖 ses-locale.css 的描边药丸） */
.obh .ses-locale { font-family: var(--obh-font); }
.obh .ses-locale__btn {
	gap: 6px;
	height: 40px;
	padding: 0 10px;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--obh-ink);
	font-family: var(--obh-font);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .04em;
	white-space: nowrap;
	transition: background .18s ease, color .18s ease;
	box-shadow: none;
}
.obh .ses-locale__btn:hover,
.obh .ses-locale__btn[aria-expanded="true"] {
	border: 0;
	background: rgba(25, 23, 25, .06);
	color: var(--obh-ink);
	box-shadow: none;
}
.obh .ses-locale__btn:focus-visible { outline: 2px solid var(--obh-ink); outline-offset: 2px; }
.obh .ses-locale__panel { font-family: var(--obh-font); }

/* ---------- 8. 搜索面板（点放大镜下拉） ---------- */
.obh__search {
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	z-index: 55;
	padding: 22px 0 26px;
	background: #fff;
	border-bottom: 1px solid var(--obh-line);
	box-shadow: 0 26px 44px -28px rgba(25, 23, 25, .28);
	opacity: 0;
	visibility: hidden;
	transform: translateY(-8px);
	transition: opacity .2s ease, transform .2s ease, visibility .2s;
}
.obh__search.is-open {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.obh__search-form {
	display: flex;
	align-items: center;
	gap: 14px;
	max-width: 1100px;
}
.obh__search-form input {
	flex: 1;
	min-width: 0;
	height: 52px;
	padding: 0 2px;
	border: 0;
	border-bottom: 1px solid var(--obh-line);
	border-radius: 0;
	background: transparent;
	color: var(--obh-ink);
	font-family: var(--obh-font);
	font-size: 18px;
	font-weight: 400;
	line-height: 1.4;
	letter-spacing: .01em;
	outline: none;
	transition: border-color .18s ease;
	-webkit-appearance: none;
	appearance: none;
}
.obh__search-form input::-webkit-search-cancel-button { -webkit-appearance: none; }
.obh__search-form input::placeholder { color: rgba(25, 23, 25, .42); }
.obh__search-form input:focus { border-color: var(--obh-ink); }
.obh__search-go {
	flex: 0 0 auto;
	height: 48px;
	padding: 0 26px;
	border: 1px solid var(--obh-ink);
	border-radius: 999px;
	background: var(--obh-ink);
	color: #fff;
	font-family: var(--obh-font);
	font-size: 15px;
	font-weight: 500;
	letter-spacing: .01em;
	line-height: 1;
	cursor: pointer;
	transition: background .18s ease, color .18s ease;
}
.obh__search-go:hover { background: transparent; color: var(--obh-ink); }
.obh__search-close {
	flex: 0 0 40px;
	width: 40px;
	height: 40px;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--obh-ink);
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	transition: background .18s ease;
}
.obh__search-close:hover { background: rgba(25, 23, 25, .06); }

/* ---------- 9. 移动端抽屉（与菜单同字体、同层级） ---------- */
.obh-drawer .obh-drawer__brand {
	font-family: var(--obh-font, "Helvetica Neue", "Segoe UI", "PingFang SC", system-ui, sans-serif);
	font-size: 22px;
	font-weight: 700;
	letter-spacing: .06em;
	line-height: 1.1;
	background: none;
	-webkit-background-clip: border-box;
	background-clip: border-box;
	-webkit-text-fill-color: var(--obh-ink, #191719);
	color: var(--obh-ink, #191719);
	text-decoration: none;
}
.obh-drawer .obh-drawer__brand span {
	font-family: inherit;
	font-size: 10px;
	font-weight: 500;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--obh-ink-72, rgba(25, 23, 25, .72));
	-webkit-text-fill-color: var(--obh-ink-72, rgba(25, 23, 25, .72));
}
.obh-drawer .obh-drawer__nav { margin: 28px 0 22px; }
.obh-drawer .obh-drawer__nav > a {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px 2px;
	border-bottom: 1px solid var(--obh-line, #e7dfe2);
	font-family: var(--obh-font, "Helvetica Neue", "Segoe UI", "PingFang SC", system-ui, sans-serif);
	font-size: 17px;
	font-weight: 500;
	line-height: 1.3;
	letter-spacing: .01em;
	color: var(--obh-ink, #191719);
	text-decoration: none;
}
.obh-drawer .obh-drawer__nav > a:hover { color: var(--obh-ink, #191719); padding-left: 6px; }
.obh-drawer .obh-drawer__nav > a.obh-drawer__acct { color: var(--rose, #c94f7c); }
.obh-drawer .obh-drawer__sub {
	list-style: none;
	margin: 0;
	padding: 2px 0 8px 16px;
	border-bottom: 1px solid var(--obh-line, #e7dfe2);
}
.obh-drawer .obh-drawer__sub a {
	display: block;
	padding: 7px 2px;
	font-family: var(--obh-font, "Helvetica Neue", "Segoe UI", "PingFang SC", system-ui, sans-serif);
	font-size: 14.5px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--obh-ink-72, rgba(25, 23, 25, .72));
	text-decoration: none;
}
.obh-drawer .obh-drawer__sub a:hover { color: var(--obh-ink, #191719); }

body.obh-locked { overflow: hidden; }

/* ---------- 10. 响应式 ---------- */
@media (min-width: 1180px) and (max-width: 1439px) {
	.obh .obh__logo img { height: 24px; }
	.obh .ses-locale__caret { display: none; }
}
/* 1180 以下：汉堡 | 居中字标 | 图标组，菜单进抽屉 */
@media (max-width: 1179px) {
	.obh__bar {
		/* 图标组列用 max-content，避免被 1fr 压窄导致购物袋按钮溢出视口 */
		grid-template-columns: minmax(3rem, 1fr) auto max-content;
		grid-template-areas: "burger logo tools";
		column-gap: 10px;
		min-height: 64px;
	}
	.obh__burger { display: inline-flex; }
	.obh .obh__logo { justify-self: center; }
	.obh .obh__logo img { height: 26px; }
	.obh__nav { display: none; }
	.obh__tools { gap: 0; }
}
@media (max-width: 760px) {
	.obh__tools .ses-locale--header { display: none; }
}
@media (max-width: 480px) {
	.obh__bar { min-height: 56px; }
	.obh .obh__logo img { height: 20px; }
	.obh__tools .obh__account { display: none; }
	.obh__search { padding: 16px 0 20px; }
	.obh__search-form { gap: 8px; }
	.obh__search-form input { font-size: 16px; height: 46px; }
	.obh__search-go { height: 42px; padding: 0 18px; font-size: 14px; }
}
