/* === Header === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background-color: var(--color-bg-white);
  z-index: 1000;
  transition: box-shadow var(--transition-normal);
}

.header--scrolled {
  box-shadow: var(--shadow-header);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.header__logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.header__logo img {
  height: 36px;
}

/* Header Left - Logo & Navigation */
.header__left {
  display: flex;
  align-items: center;
  gap: 24px;
}

/* Navigation */
.header__nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav__item {
  position: relative;
  display: flex;
  align-items: center;
  padding: 8px 16px;
  font-size: var(--font-size-base);
  color: var(--color-text-base);
  font-weight: bold;
  cursor: pointer;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.nav__item:hover,
.nav__item--active {
  color: var(--color-primary);
}

/* .nav__item--active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 2px;
  background-color: var(--color-primary);
  border-radius: 1px;
} */

.nav__item--products {
  position: relative;
}

.nav__item--products .nav__arrow {
  width: 12px;
  height: 12px;
  margin-left: 4px;
  transition: transform var(--transition-fast);
}

.nav__item--products:hover .nav__arrow {
  transform: rotate(180deg);
}

/* Header Right */
.header__right {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-shrink: 0;
}

.header__phone {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--color-text-base);
  font-weight: bold;
  font-size: 16px;
}

.header__phone img {
  width: 16px;
  height: 16px;
}

/* === Mega Menu === */
.mega-menu {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  /* transform: translateX(-50%); */
  width: 100%;
  background-color: var(--color-bg-white);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 32px 40px;
  opacity: 0;
  visibility: hidden;
  /* transition: all var(--transition-normal); */
  z-index: 999;
}

.mega-menu--visible {
  opacity: 1;
  visibility: visible;
}

.mega-menu__inner {
  width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.mega-menu__column {
  min-width: 0;
}

.mega-menu__title {
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--color-text-primary);
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--color-border-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mega-menu__list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mega-menu__link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: var(--font-size-sm);
  color: var(--color-text-base);
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.mega-menu__link:hover {
  color: var(--color-primary);
}

.mega-menu__link img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* Header placeholder to prevent content jump */
.header-placeholder {
  height: var(--header-height);
}

/* Head Menu Styles */
.head-menu {
  /* display: flex;
  align-items: center;
  gap: 40px;
  flex: 1; */
}
.head-menu:nth-of-type(3) {
  margin-top: 23px;
}
.head-menu .menu-item {
  cursor: pointer;
}
.head-menu .menu-item .menu-title {
  /* border-bottom: 2px solid #fff;
  transition: all 0.2s ease-in-out; */
  font-size: 14px;
  padding-bottom: 10px;
  color: #333;
  font-weight: bold;
  padding-left: 10px;
  display: flex;
  align-items: center;
}
.head-menu .menu-item .menu-title img {
  margin-left: 5px;
}

.head-menu .menu-item .item-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 20px;
}

.head-menu .menu-item .item-wrap {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
}

/* .head-menu .sub-menu-wrap {
  position: absolute;
  top: 80px;
  left: 0;
  right: 0;
  background-color: #fff;
  box-shadow: 0 5px 5px -3px rgba(0, 0, 0, 0.2);
} */

.head-menu .sub-menu {
  background-color: #fff;
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  z-index: 1000;
}

.head-menu .sub-menu .sub-menu-item {
  margin-bottom: 10px;
  box-sizing: border-box;
}

.head-menu .sub-menu .sub-menu-title {
  padding-left: 10px;
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 700;
}

.head-menu .sub-menu .leaf-item-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
}

.head-menu .sub-menu .leaf-item-wrap > div:first-of-type {
  width: 40px;
  height: 40px;
}
.head-menu .sub-menu .leaf-item-wrap:hover {
  background-color: #F7F8FA;
  border-radius: 4px;
}
.head-menu .sub-menu .leaf-item-title {
  font-size: 14px;
  font-weight: bold;
  color: var(--color-text-base);
}
.head-menu .sub-menu .leaf-item-wrap:hover .leaf-item-title {
  color: #2d8cf0;
}

.head-menu .sub-menu .leaf-item-wrap .description {
  color: #999;
  font-size: 12px;
  font-weight: 400;
}

/* Tag样式 */
.head-menu .sub-menu .leaf-item-wrap .title-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 280px;
}
.head-menu .sub-menu .leaf-item-wrap .tag {
  width: 50px;
  height: 16px;
  border-radius: 2px;
  font-size: 10px;
  font-weight: 400;
  display: flex;
  align-items: center;
  justify-content: center;
}
.head-menu .sub-menu .leaf-item-wrap .tag.green{
  background: rgba(25, 190, 107, 0.2);
  color: #00D457;
}
.head-menu .sub-menu .leaf-item-wrap .tag.orange{
  background: rgba(255, 115, 0, 0.2);
  color: #FF7300;
}
.head-menu .sub-menu .leaf-item-wrap .tag.blue{
  background: rgba(24, 144, 255, 0.2);
  color: #1890FF;
}

.hasLogo {
  position: relative;
  cursor: pointer;
  height: 72px;
}
.hasLogo .user-wrap {
  display: flex;
  align-items: center;
  height: 72px;
}
.hasLogo:hover .operateList {
  display: block;
}

.hasLogo dl dt:nth-child(1) {
  font-size: 14px !important;
  margin-bottom: 6px !important;
}

.operateList {
  width: 200px;
  background: #fff;
  position: absolute;
  top: 66px;
  box-shadow: 0 -6px 0 0 #fff, 0 2px 8px 0 rgba(200, 201, 204, .5);
  padding: 4px 10px;
  box-sizing: border-box;
  display: none;
}

.operateList ul {
  font-size: 14px;
  color: #656e73;
}

.operateList ul li {
  padding: 0 20px;
  line-height: 44px;
  cursor: pointer;
  border-bottom: 1px #eee solid;
}

.operateList ul li a {
  color: inherit
}

.operateList ul li:last-child {
  border: none;
}

.operateList ul li:hover {
  color: #1890FF;
}

#userLogout > a:first-child {
  margin-right: 10px;
}
.leaf-class-box{
  display: flex;
  align-items: center;
}

.leaf-hot{
  margin-left: 5px;
}
.user-wrap img {
  margin-right: 10px;
  border-radius: 50%;
}