.topbar {
  height: 56px;
  background: #040000;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-width: 1440px;
  padding: 0 max(120px, calc((100vw - 1440px) / 2 + 120px));
  position: relative;
  overflow: visible;
  z-index: 2;
}

.topbar::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1440px;
  transform: translateX(-50%);
  background: url("./doc/icon/backup.png") center / 100% 100% no-repeat;
  pointer-events: none;
  z-index: 0;
}

.brand,
.nav {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  white-space: nowrap;
}

.nav {
  position: absolute;
  top: 19px;
  right: max(120px, calc((100vw - 1440px) / 2 + 120px));
  gap: 0;
  font-size: 12px;
  color: #fff;
}

.topnav-text {
  display: flex;
  align-items: center;
  gap: 0;
  height: 18px;
}

.divider {
  width: 1px;
  height: 10px;
  margin: 0 20px;
  background: #fff;
}

.nav-link {
  width: 48px;
  height: 18px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--source-han-sans, "Source Han Sans"), "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
  line-height: 18px;
  text-transform: capitalize;
  text-decoration: none;
  cursor: pointer;
}

.nav-link:hover {
  color: #fff;
}

body.is-english .nav-link {
  width: auto;
  min-width: 48px;
}

.lang-wrap {
  position: relative;
  height: 18px;
  display: flex;
  align-items: center;
  z-index: 20;
}

.lang-trigger {
  width: auto;
  height: 18px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 2px;
  font-family: var(--source-han-sans, "Source Han Sans"), "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
  line-height: 18px;
  text-transform: capitalize;
  cursor: pointer;
}

.lang-trigger-label {
  width: 48px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 48px;
  line-height: 18px;
}

.lang-trigger-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.lang-trigger-icon img {
  width: 16px;
  height: 16px;
  display: block;
}

body.is-english .nav-link,
body.is-english .lang-trigger,
body.is-english .lang-trigger-label {
  font-family: var(--source-han-sans, "Source Han Sans"), "PingFang SC", "Microsoft YaHei", sans-serif;
}

@media (max-width: 1280px) and (max-device-width: 1280px) {
  .topbar {
    padding: 0 32px;
  }

  .nav {
    right: 32px;
  }
}

@media (max-width: 760px) and (max-device-width: 760px) {
  .topbar {
    height: auto;
    min-height: 48px;
    padding: 0 12px;
  }

  .nav {
    position: relative;
    top: auto;
    right: auto;
    gap: 0;
  }

  .lang-menu {
    right: 0;
  }
}
