.qsyj-site-header {
  position: relative;
  z-index: 50;
  background: var(--qsyj-green-900);
  border: 0;
}

.qsyj-header-main,
.qsyj-primary-nav,
.qsyj-life-nav-scroll {
  width: min(calc(100% - 48px), 1180px);
  margin-inline: auto;
}

.qsyj-header-main {
  min-height: 78px;
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 48px auto 48px;
  gap: 14px;
  align-items: center;
  position: relative;
}

.qsyj-header-logo img,
.qsyj-header-logo .custom-logo {
  width: auto;
  max-height: 48px;
}

.qsyj-header-search {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
}

.qsyj-search-icon {
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--qsyj-green-950);
  font-size: 23px;
  line-height: 1;
  cursor: pointer;
}

.qsyj-header-search input,
.qsyj-search-submit {
  display: none;
}

.qsyj-header-search.is-open {
  position: absolute;
  right: 196px;
  width: min(520px, calc(100% - 260px));
  border-radius: 999px;
  justify-content: flex-start;
  gap: 8px;
  padding: 0 7px 0 12px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, .2);
}

.qsyj-header-search.is-open .qsyj-search-icon {
  width: 34px;
  height: 42px;
  flex: 0 0 34px;
}

.qsyj-header-search.is-open input {
  display: block;
  min-width: 0;
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 16px;
}

.qsyj-header-search.is-open .qsyj-search-submit {
  display: block;
  min-height: 36px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: var(--qsyj-green-900);
  color: #fff;
  font-size: 14px;
}

.qsyj-join-button {
  min-height: 46px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  border-radius: 11px;
  background: var(--qsyj-gold);
  color: #173f31;
  font-weight: 700;
  white-space: nowrap;
}

.qsyj-more-toggle {
  width: 48px;
  height: 54px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  cursor: pointer;
}

.qsyj-more-toggle span {
  font-size: 21px;
  line-height: 1;
}

.qsyj-more-toggle small {
  font-size: 12px;
}

.qsyj-primary-nav {
  display: block;
}

.qsyj-nav-list {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
  background: #fff;
  white-space: nowrap;
}

.qsyj-nav-list li,
.qsyj-life-nav-scroll a {
  min-width: 0;
  text-align: center;
}

.qsyj-nav-list a {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-size: 16px;
  font-weight: 650;
}

.qsyj-nav-list a:hover,
.qsyj-nav-list .current-menu-item > a {
  color: var(--qsyj-green-900);
}

.qsyj-nav-list li:first-child a {
  color: var(--qsyj-green-900);
}

.qsyj-nav-list li:first-child a::after {
  content: "";
  position: absolute;
  left: 34%;
  right: 34%;
  bottom: 9px;
  height: 3px;
  border-radius: 999px;
  background: var(--qsyj-green-900);
}

.qsyj-primary-nav,
.qsyj-life-nav {
  background: #fff;
}

.qsyj-life-nav {
  border-top: 1px solid #eeeae0;
  border-bottom: 1px solid #eeeae0;
}

.qsyj-life-nav-scroll {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0;
  padding: 0;
  white-space: nowrap;
}

.qsyj-life-nav a {
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-size: 16px;
  font-weight: 650;
}

.qsyj-life-nav a.is-active {
  color: var(--qsyj-green-900);
}

.qsyj-life-nav a.is-active::after {
  content: "";
  position: absolute;
  left: 34%;
  right: 34%;
  bottom: 8px;
  height: 3px;
  border-radius: 999px;
  background: var(--qsyj-green-900);
}

.qsyj-mobile-more {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, .38);
}

.qsyj-mobile-more-panel {
  width: min(86vw, 380px);
  height: 100%;
  margin-left: auto;
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  overflow: auto;
  background: #fff;
}

.qsyj-mobile-more-panel a {
  padding: 13px;
  border-bottom: 1px solid var(--qsyj-border);
  font-size: 18px;
}

.qsyj-more-close {
  align-self: flex-end;
  border: 0;
  background: none;
  font-size: 34px;
}

@media (max-width: 820px) {
  .qsyj-header-main {
    width: 100%;
    min-height: 82px;
    padding: 13px 12px;
    grid-template-columns: minmax(104px, 1fr) 46px auto 38px;
    gap: 7px;
  }

  .qsyj-header-logo {
    min-width: 0;
  }

  .qsyj-header-logo img,
  .qsyj-header-logo .custom-logo {
    max-width: 128px;
    max-height: 43px;
    object-fit: contain;
  }

  .qsyj-header-search,
  .qsyj-search-icon {
    width: 46px;
    height: 46px;
  }

  .qsyj-header-search.is-open {
    left: 12px;
    right: 12px;
    top: 68px;
    width: auto;
    z-index: 20;
  }

  .qsyj-join-button {
    min-height: 46px;
    padding: 0 11px;
    font-size: 15px;
  }

  .qsyj-more-toggle {
    width: 38px;
    height: 52px;
  }

  .qsyj-primary-nav {
    display: none;
  }

  .qsyj-life-nav {
    border: 0;
    border-radius: 20px 20px 0 0;
    overflow: hidden;
  }

  .qsyj-life-nav-scroll {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    gap: 25px;
    padding: 13px 15px 14px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }

  .qsyj-life-nav-scroll::-webkit-scrollbar {
    display: none;
  }

  .qsyj-life-nav a {
    min-height: 32px;
    flex: 0 0 auto;
    font-size: 17px;
    font-weight: 700;
  }

  .qsyj-life-nav a.is-active::after {
    left: 0;
    right: 0;
    bottom: -4px;
  }
}

@media (max-width: 380px) {
  .qsyj-header-main {
    grid-template-columns: minmax(96px, 1fr) 43px auto 35px;
    gap: 5px;
    padding-inline: 10px;
  }

  .qsyj-header-logo img,
  .qsyj-header-logo .custom-logo {
    max-width: 116px;
  }

  .qsyj-header-search,
  .qsyj-search-icon {
    width: 43px;
    height: 43px;
  }

  .qsyj-join-button {
    min-height: 43px;
    padding: 0 8px;
    font-size: 14px;
  }

  .qsyj-life-nav-scroll {
    gap: 22px;
  }
}
