/**
 * Header / 导航
 */

.hy-header {
	position: sticky;
	top: 0;
	z-index: 900;
	background: #fff;
	box-shadow: 0 1px 0 var(--hy-border);
}

/* ---------- 行情速览条 ---------- */

.hy-ticker {
	background: var(--hy-navy);
	color: #fff;
	font-size: 13px;
}

.hy-ticker__inner {
	display: flex;
	align-items: center;
	gap: 28px;
	padding-top: 7px;
	padding-bottom: 7px;
	overflow-x: auto;
	white-space: nowrap;
}

.hy-ticker__item b {
	font-weight: 600;
	margin-right: 6px;
	color: var(--hy-gold-light);
}

.hy-ticker__item [data-role="change"] {
	margin-left: 6px;
	font-style: normal;
}

.hy-ticker__demo {
	margin-left: auto;
	font-size: 12px;
	color: rgba(255, 255, 255, 0.55);
	border: 1px solid rgba(255, 255, 255, 0.25);
	border-radius: 999px;
	padding: 1px 10px;
}

/* ---------- 主导航 ---------- */

.hy-navbar__inner {
	display: flex;
	align-items: center;
	gap: 32px;
	height: 72px;
}

.hy-brand {
	flex-shrink: 0;
}

.hy-brand__link {
	display: flex;
	align-items: center;
	gap: 12px;
	color: var(--hy-navy);
}

.hy-brand__mark {
	color: var(--hy-gold);
}

.hy-brand__text {
	display: flex;
	flex-direction: column;
	line-height: 1.2;
}

.hy-brand__name {
	font-size: 20px;
	font-weight: 700;
	letter-spacing: 0.04em;
}

.hy-brand__en {
	font-size: 11px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--hy-text-2);
}

.hy-nav {
	flex: 1;
	min-width: 0;
}

.hy-menu {
	display: flex;
	align-items: center;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.hy-menu > .hy-menu-item > a {
	display: block;
	padding: 26px 13px;
	font-size: 15px;
	font-weight: 600;
	color: var(--hy-navy);
	position: relative;
}

.hy-menu > .hy-menu-item > a::after {
	content: "";
	position: absolute;
	left: 13px;
	right: 13px;
	bottom: 18px;
	height: 2px;
	background: var(--hy-gold);
	transform: scaleX(0);
	transition: transform 0.2s ease;
}

.hy-menu > .hy-menu-item:hover > a::after,
.hy-menu > .hy-menu-item.current-menu-item > a::after {
	transform: scaleX(1);
}

/* 下拉菜单 */

.hy-menu-item.menu-item-has-children {
	position: relative;
}

.hy-submenu {
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 190px;
	margin: 0;
	padding: 8px 0;
	list-style: none;
	background: #fff;
	border: 1px solid var(--hy-border);
	border-radius: var(--hy-radius);
	box-shadow: var(--hy-shadow-lg);
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: all 0.2s ease;
	z-index: 100;
}

.hy-menu-item.menu-item-has-children:hover > .hy-submenu,
.hy-menu-item.menu-item-has-children:focus-within > .hy-submenu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.hy-submenu a {
	display: block;
	padding: 9px 20px;
	font-size: 14px;
	color: var(--hy-text);
}

.hy-submenu a:hover {
	background: var(--hy-bg-tint);
	color: var(--hy-gold);
}

/* 右侧操作 */

.hy-navbar__actions {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-shrink: 0;
}

/* 汉堡按钮（移动端显示） */

.hy-nav-toggle {
	display: none;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 42px;
	height: 42px;
	padding: 9px;
	border: 1px solid var(--hy-border);
	border-radius: 8px;
	background: #fff;
	cursor: pointer;
}

.hy-nav-toggle span {
	display: block;
	height: 2px;
	width: 100%;
	background: var(--hy-navy);
	border-radius: 2px;
	transition: transform 0.25s ease, opacity 0.2s ease;
}

.hy-nav-toggle.is-open span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

.hy-nav-toggle.is-open span:nth-child(2) {
	opacity: 0;
}

.hy-nav-toggle.is-open span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}
