.header-shimmer {
  width: 100%;
  --shimmer-border-radius: 0;
  position: relative;
  top: 0px;
  background-color: #fff;
  z-index: var(--sl-z-index-tooltip);
}

/* nav-bar-container 的 sticky 样式 */
#nav-bar-container.sticky {
  position: fixed !important;
  top: 0px !important;
  left: 0px !important;
  right: 0px !important;
  box-shadow: rgb(0 0 0 / 14%) 0px 4px 5px 0px,
    rgb(0 0 0 / 12%) 0px 1px 10px 0px, rgb(0 0 0 / 20%) 0px 2px 4px -1px;
  z-index: var(--sl-z-index-tooltip);
}

.nav_bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: var(--layout-width);
  height: 84px;
  margin: auto;
  transition: box-shadow 0.2s ease-in-out 0s;
  position: relative;
}

.nav-buttons-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 36px;
  padding-left: 20px;
}

.home-logo-link {
  display: flex;
  align-items: center;
  width: 200px;
  margin-inline-end: 24px;
  cursor: pointer;
}

.home-logo-link img {
  width: 27px;
  height: 27px;
  margin-right: 9px;
}

.home-logo-link span {
  font-weight: 700;
  color: #000;
  font-size: 16px;
}

.shop_tab {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  height: 38px;
  color: #999999;
}

.tab_btn_group {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  --padding-btn: 20px;
}

.tab_item {
  display: flex;
  align-items: center;
  padding: 0 var(--padding-btn);
  height: 100%;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
  width: 68px;
  box-sizing: border-box;
  transition: color 0.3s;
}

.tab_item.active {
  color: #2c85cf;
}

.indicator {
  position: absolute;
  height: auto;
  bottom: 0px;
  width: 28px !important;
  translate: 0px;
  border-top: solid 2px #005fb8;
  margin-inline-start: var(--padding-btn);
  /* transition: 300ms transform ease, 300ms width ease; */
}

.right-elements {
  display: flex;
  align-items: center;
  height: 36px;
  justify-content: flex-end;
  flex: 1;
  padding-right: 20px;
}

.shop_search {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  height: 32px;
  flex: 1;
  max-width: 600px;
}

.search_input {
  display: flex;
  align-items: center;
  position: relative;
  height: 100%;
  border: 1px solid rgba(180, 180, 180, 0.5);
  border-radius: 4px;
  padding: 0 3px 0 35px;
  flex: 1;
  box-sizing: border-box;
  background-color: #fff;
  transition: border-color 0.3s;
}

.search_input.active {
  border-color: var(--theme-primary-element-color) !important;
  border-bottom-width: 1px !important;
}

.search_input:hover {
  border: 1px solid #999999;
}

.search_input input {
  flex: 1;
  margin-right: 2px;
  font-size: 12px;
  border: none;
  background-color: transparent;
  outline-style: none;
  width: 100%;
}

.search_input .search {
  position: absolute;
  top: 50%;
  left: 17px;
  width: 12px;
  height: auto;
  transform: translateY(-50%);
  pointer-events: none;
}

.search_input .del {
  position: absolute;
  top: 50%;
  right: 8px;
  width: 10px;
  height: auto;
  transform: translateY(-50%);
  cursor: pointer;
  display: none;
}

.search_input .del:hover {
  opacity: 0.7;
}

.search_box {
  position: absolute;
  top: 31px;
  left: 0;
  z-index: var(--sl-z-index-dropdown);
  width: 100%;
  background: var(--sl-panel-background-color);
  border: solid var(--sl-panel-border-width) var(--sl-panel-border-color);
  border-radius: var(--sl-border-radius-medium);
  overflow: unset;
  overscroll-behavior: none;
  max-height: 400px;
  box-shadow: 0px 2px 6px 0px rgba(24, 89, 142, 0.15);
}

.search_item {
  position: relative;
  display: flex;
  align-items: center;
  font-size: 14px;
  color: #333;
  padding: 8px 12px;
  transition: background-color 0.2s;
  user-select: none;
  white-space: nowrap;
  cursor: pointer;
}

.search_item:hover {
  background-color: #f4f4f5;
}

.search_item img {
  width: auto;
  height: 10px;
  margin-inline-end: 2px;
  aspect-ratio: auto 20 / 20;
  background: rgba(211, 211, 211, 0.5);
  margin: 0 6px 0 8px;
}

.his_title {
  font-weight: bold;
  font-size: 14px;
  padding: 10px 0;
}

.his_item {
  justify-content: space-between;
  padding-right: 30px;
}

.his_item .item_l {
  display: flex;
  align-items: center;
}

.icon_btn {
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
}

.icon_btn:hover {
  opacity: 0.7;
}

.icon_btn svg {
  width: 14px;
  height: 14px;
}

.result-search-icon {
  width: 18px;
  height: 18px;
  margin: 0 6px 0 10px;
}

.close_box {
  margin-left: 10px;
  cursor: pointer;
  color: var(--theme-primary-element-color);
  font-size: 14px;
  padding: 0 8px;
}

.close_box:hover {
  opacity: 0.7;
}

.cancel-text {
  color: var(--theme-primary-element-color);
}

.down_button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 130px;
  height: 38px;
  background: #E7F3FF;
  border-radius: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.3s;
  --svg-color: #005FB8;
  margin-left: 20px;
}

.down_button:hover {
  background-color: #005FB8;
  --svg-color: #fff;
}

.down_button svg {
  transform: translateY(1px);
  fill: var(--svg-color);
}

.down_button span {
  margin-left: 4px;
  color: var(--svg-color);
  font-size: 14px;
}

.mobile-button-container {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 100%;
  cursor: pointer;
  margin-left: 10px;
}

.mobile-button-container img {
  width: 20px;
  height: 20px;
}

.mobile-tabs {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
}

/* 响应式 */
@media (max-width: 1101px) {
  .shop_search {
    display: none !important;
  }
  .mobile-button-container {
    display: flex !important;
  }
  .down_button {
    display: none !important;
  }
}

@media (max-width: 837px) {
  .nav-buttons-container .shop_tab {
    display: none;
  }
  .nav_bar {
    height: 130px;
    align-items: flex-start;
    padding-top: 22px;
    box-sizing: border-box;
  }
  .mobile-tabs {
    display: block !important;
  }
}

@media (max-width: 430px) {
  .home-logo-link {
    width: 160px;
  }
}

@media (max-width: 380px) {
  .home-logo-link {
    width: 140px;
  }
}

@media (max-width: 360px) {
  .home-logo-link {
    width: 130px;
  }
}

.header-shimmer.focus .nav_bar {
  height: 84px;
}

.header-shimmer.focus .nav_bar .shop_search {
  display: flex !important;
}

.header-shimmer.focus .nav_bar .mobile-button-container {
  display: none !important;
}

.header-shimmer.focus .nav_bar .down_button {
  display: none !important;
}

@media (max-width: 837px) {
  .header-shimmer.focus .nav_bar .nav-buttons-container {
    display: none;
  }
  .header-shimmer.focus .nav_bar .mobile-button-container {
    display: none !important;
  }
  .header-shimmer.focus .nav_bar .down_button {
    display: none !important;
  }
}
