.site-header {
  position: fixed;
  z-index: 30;
  inset: 0 0 auto;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--page-gutter);
  border-bottom: 1px solid rgba(244, 247, 255, 0.07);
  background: linear-gradient(to bottom, rgba(6, 0, 18, 0.9), rgba(6, 0, 18, 0.12));
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: inherit;
  text-decoration: none;
}

.brand__icon {
  width: 2rem;
  height: 2rem;
}

.brand__lockup {
  display: grid;
  gap: 0.14rem;
}

.brand__wordmark {
  display: block;
  width: 5.2rem;
  height: auto;
}

.brand__cn {
  color: rgba(244, 247, 255, 0.58);
  font-family: "PingFang SC", "Hiragino Sans GB", sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.28em;
}

.site-nav,
.future-links,
.language-switch {
  display: flex;
  align-items: center;
}

.site-nav {
  gap: clamp(1.25rem, 3vw, 3.2rem);
}

.mobile-menu-toggle {
  display: none;
}

.future-links {
  gap: clamp(1rem, 2vw, 2rem);
  font-family: Menlo, Monaco, Consolas, monospace;
  font-size: 0.66rem;
  letter-spacing: 0.16em;
}

.future-links > a,
.future-links > span,
.product-menu__toggle {
  position: relative;
  padding: 0.45rem 0;
  color: rgba(244, 247, 255, 0.42);
  text-decoration: none;
  transition: color 180ms ease;
}

.future-links > a::after,
.product-menu__toggle::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: var(--electric-cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

.future-links > a[aria-current="page"],
.product-menu__toggle[aria-current="page"] {
  color: var(--ion-white);
}

.future-links > a[aria-current="page"]::after,
.product-menu__toggle[aria-current="page"]::after,
.future-links > a:hover::after,
.future-links > a:focus-visible::after,
.product-menu__toggle:hover::after,
.product-menu__toggle:focus-visible::after {
  transform: scaleX(1);
}

.future-links > a:hover,
.future-links > a:focus-visible,
.product-menu__toggle:hover,
.product-menu__toggle:focus-visible {
  color: var(--ion-white);
  outline: none;
}

.future-links > span[aria-disabled="true"]::after {
  content: "SOON";
  position: absolute;
  top: -0.3rem;
  right: 0;
  color: rgba(141, 152, 180, 0.5);
  font-size: 0.42rem;
  letter-spacing: 0.12em;
  transform: translateY(-35%);
}

.product-menu {
  position: relative;
}

.product-menu__toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 0;
  background: transparent;
  font: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

.product-menu__toggle i {
  width: 0.35rem;
  height: 0.35rem;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: translateY(-0.1rem) rotate(45deg);
  transition: transform 220ms ease;
}

.product-menu[data-product-menu-open="true"] .product-menu__toggle i {
  transform: translateY(0.08rem) rotate(225deg);
}

.product-menu__panel {
  position: absolute;
  z-index: 4;
  top: calc(100% + 0.7rem);
  right: -1.15rem;
  display: grid;
  width: 13rem;
  padding: 0.55rem;
  border: 0;
  border-radius: 0.7rem;
  background: transparent;
  -webkit-backdrop-filter: blur(9px) saturate(135%);
  backdrop-filter: blur(9px) saturate(135%);
  box-shadow: 0 1.2rem 3rem rgba(0, 0, 0, 0.34);
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, -0.55rem, 0);
  transition:
    opacity 160ms ease,
    transform 260ms cubic-bezier(0.22, 1, 0.36, 1);
}

.product-menu__panel::before {
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 0.75rem;
}

.product-menu__panel > a,
.product-menu__panel > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  min-height: 2.55rem;
  padding: 0.65rem 0.72rem;
  color: rgba(244, 247, 255, 0.74);
  text-decoration: none;
}

.product-menu__panel > a {
  position: relative;
  border: 0;
}

.product-menu__panel > a::after {
  content: "";
  position: absolute;
  right: 0.72rem;
  bottom: 0.35rem;
  left: 0.72rem;
  height: 1px;
  background: var(--electric-cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

.product-menu__panel > a:hover,
.product-menu__panel > a:focus-visible {
  color: var(--ion-white);
  outline: none;
}

.product-menu__panel > a:hover::after,
.product-menu__panel > a:focus-visible::after,
.product-menu__panel > a[aria-current="page"]::after {
  transform: scaleX(1);
}

.product-menu__panel > a span::before {
  content: "";
  display: inline-block;
  width: 0.34rem;
  height: 0.34rem;
  margin-right: 0.5rem;
  border-radius: 50%;
  background: var(--bio-green);
  box-shadow: 0 0 0.7rem rgba(22, 242, 179, 0.5);
}

.product-menu__panel > span[aria-disabled="true"] {
  color: rgba(141, 152, 180, 0.3);
  cursor: not-allowed;
}

.product-menu__panel small {
  color: rgba(141, 152, 180, 0.48);
  font-size: 0.43rem;
  letter-spacing: 0.1em;
}

.product-menu__panel > a small {
  color: rgba(22, 242, 179, 0.65);
}

.product-menu[data-product-menu-open="true"] .product-menu__panel {
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0);
}

.language-switch {
  font-family: Menlo, Monaco, Consolas, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
}

.language-switch button {
  position: relative;
  padding: 0.35rem 0;
  border: 0;
  background: transparent;
  color: rgba(244, 247, 255, 0.68);
  cursor: pointer;
}

.language-switch button::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: var(--electric-cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

.language-switch button:hover::after,
.language-switch button:focus-visible::after {
  transform: scaleX(1);
}

.site-footer {
  position: fixed;
  z-index: 20;
  right: var(--page-gutter);
  bottom: 1.5rem;
  left: var(--page-gutter);
  display: flex;
  justify-content: space-between;
  color: rgba(244, 247, 255, 0.36);
  font-family: Menlo, Monaco, Consolas, monospace;
  font-size: 0.56rem;
  letter-spacing: 0.14em;
  pointer-events: none;
}

.site-footer__end--touch {
  display: none;
}

@media (max-width: 760px) {
  .brand__icon {
    width: 1.72rem;
    height: 1.72rem;
  }

  .brand__wordmark {
    width: 4.65rem;
  }

  .future-links {
    font-size: 0.59rem;
  }

  .mobile-menu-toggle {
    position: relative;
    z-index: 2;
    display: inline-flex;
    width: 2.35rem;
    height: 2.35rem;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.32rem;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--ion-white);
    cursor: pointer;
  }

  .mobile-menu-toggle__line {
    display: block;
    width: 1.2rem;
    height: 1px;
    background: currentColor;
    transition:
      opacity 180ms ease,
      transform 280ms cubic-bezier(0.22, 1, 0.36, 1);
  }

  .site-nav {
    position: fixed;
    z-index: 1;
    top: calc(var(--header-height) - 0.05rem);
    right: var(--page-gutter);
    display: flex;
    width: min(14rem, calc(100vw - 2 * var(--page-gutter)));
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 0;
    border-radius: 1rem;
    background: transparent;
    -webkit-backdrop-filter: blur(12px) saturate(135%);
    backdrop-filter: blur(12px) saturate(135%);
    opacity: 0;
    pointer-events: none;
    transform: translate3d(0, -0.75rem, 0);
    transition:
      opacity 180ms ease,
      transform 320ms cubic-bezier(0.22, 1, 0.36, 1);
  }

  .future-links {
    flex-direction: column;
    align-items: stretch;
    gap: 0.8rem;
  }

  .future-links > a,
  .future-links > span,
  .product-menu__toggle {
    padding: 0.6rem 0;
  }

  .product-menu,
  .product-menu__toggle {
    width: 100%;
  }

  .product-menu__toggle {
    justify-content: space-between;
  }

  .product-menu__panel {
    position: static;
    width: 100%;
    max-height: 0;
    margin-top: 0;
    padding: 0 0.45rem;
    overflow: hidden;
    border-width: 0;
    box-shadow: none;
    opacity: 0;
    transform: none;
    transition:
      max-height 320ms cubic-bezier(0.22, 1, 0.36, 1),
      margin-top 220ms ease,
      padding 220ms ease,
      opacity 160ms ease;
  }

  .product-menu__panel > a,
  .product-menu__panel > span {
    min-height: 2.2rem;
    padding: 0.4rem;
  }

  .product-menu__panel > a::after {
    right: 0.4rem;
    bottom: 0.18rem;
    left: 0.4rem;
  }

  .product-menu__panel::before {
    display: none;
  }

  .product-menu[data-product-menu-open="true"] .product-menu__panel {
    max-height: 10rem;
    margin-top: 0;
    padding: 0.12rem 0.3rem 0.24rem;
  }

  .language-switch {
    justify-content: flex-end;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(244, 247, 255, 0.1);
  }

  html[data-menu-open="true"] .site-nav {
    opacity: 1;
    pointer-events: auto;
    transform: translate3d(0, 0, 0);
  }

  html[data-menu-open="true"] .mobile-menu-toggle__line:nth-child(1) {
    transform: translateY(0.41rem) rotate(45deg);
  }

  html[data-menu-open="true"] .mobile-menu-toggle__line:nth-child(2) {
    opacity: 0;
  }

  html[data-menu-open="true"] .mobile-menu-toggle__line:nth-child(3) {
    transform: translateY(-0.41rem) rotate(-45deg);
  }

  .site-footer {
    bottom: 1rem;
    font-size: 0.48rem;
  }

  .site-footer__start {
    display: none;
  }

  .site-footer__end {
    margin-left: auto;
  }

  .site-footer__end--desktop {
    display: none;
  }

  .site-footer__end--touch {
    display: inline;
  }
}

@media (min-width: 761px) and (max-height: 620px) {
  .brand__icon {
    width: 1.7rem;
    height: 1.7rem;
  }

  .brand__wordmark {
    width: 4.6rem;
  }

  .brand__cn {
    font-size: 0.48rem;
  }

  .future-links,
  .language-switch {
    font-size: 0.58rem;
  }

  .site-footer {
    bottom: 0.7rem;
    font-size: 0.52rem;
  }
}

@media (max-width: 760px) and (max-height: 560px) and (orientation: landscape) {
  .site-header {
    padding-inline: var(--page-gutter);
  }

  .brand {
    gap: 0.48rem;
  }

  .brand__icon {
    width: 1.45rem;
    height: 1.45rem;
  }

  .brand__wordmark {
    width: 4.2rem;
  }

  .brand__cn {
    display: none;
  }

  .site-footer {
    bottom: 0.42rem;
    font-size: 0.48rem;
  }
}

@media (max-width: 420px) and (orientation: portrait) {
  .brand__cn {
    display: none;
  }
}
