/* Shared website chrome. Page content styles remain in each page stylesheet. */
.site-shell {
  --home-font-family: 'MiSans VF', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  font-family: var(--home-font-family);
}
.site-shell button,
.site-shell input,
.site-shell select,
.site-shell textarea,
.site-shell .font-sans {
  font-family: var(--home-font-family);
}
/* Clickable controls share an explicit affordance across public pages. */
.site-shell a[href],
.site-shell button,
.site-shell [role='button'],
.site-shell [role='tab'],
.site-shell summary,
.site-shell select,
.site-shell label[for],
.site-shell input[type='button'],
.site-shell input[type='submit'],
.site-shell input[type='reset'],
.site-shell input[type='checkbox'],
.site-shell input[type='radio'],
.site-shell input[type='range'],
.site-shell input[type='file'],
.site-shell [data-country-close] {
  cursor: pointer;
}
.site-shell button:disabled,
.site-shell input:disabled,
.site-shell select:disabled,
.site-shell [aria-disabled='true'] {
  cursor: not-allowed;
}
.site-shell :focus-visible {
  outline: 2px solid #0d6bdd;
  outline-offset: 5px;
}
.site-shell #auth-panel #sms-phone:focus-visible,
.site-shell #auth-panel #sms-code:focus-visible {
  outline: none;
}

.site-shell #site-nav.marketing-nav {
  position: fixed;
  inset: 0 0 auto;
  height: 64px;
  z-index: 50;
  color: #fff;
  background: transparent;
  transition:
    background 0.25s,
    color 0.25s;
}
.site-shell #site-nav.marketing-nav:hover,
.site-shell #site-nav.marketing-nav:focus-within,
.site-shell #site-nav.marketing-nav.is-scrolled {
  color: #222;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid #eee;
}
.site-shell[data-auth-page='login'] #site-nav.marketing-nav {
  background: #fff;
}
.site-shell #site-nav .marketing-nav-inner {
  max-width: 1376px;
  padding: 0 32px;
  height: 64px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 64px;
}
.site-shell #site-nav.marketing-nav #header-logo {
  width: auto;
  height: 24px;
  filter: brightness(0) invert(1);
}
.site-shell #site-nav.marketing-nav:hover #header-logo,
.site-shell #site-nav.marketing-nav:focus-within #header-logo,
.site-shell #site-nav.marketing-nav.is-scrolled #header-logo {
  filter: brightness(0);
}
.site-shell #site-nav .marketing-nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  white-space: nowrap;
  height: 100%;
  font-size: 14px;
  font-weight: 400;
}
.site-shell #site-nav .marketing-nav-links > a {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  font-weight: 400;
}
.site-shell #site-nav .marketing-nav-links > a[aria-current='page'] {
  font-weight: 600;
}
.site-shell #site-nav .marketing-nav-links > a[aria-current='page']::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 16px;
  height: 2px;
  transform: translateX(-50%);
  background: currentColor;
}
.site-shell #site-nav #mobile-dropdown a {
  position: relative;
  font-weight: 400;
}
.site-shell #site-nav #mobile-dropdown a[aria-current='page'] {
  font-weight: 600;
}
.site-shell #site-nav #mobile-dropdown a[aria-current='page']::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 16px;
  height: 2px;
  background: currentColor;
}
.site-shell #site-nav.marketing-nav .nav-dark-text,
.site-shell #site-nav.marketing-nav .marketing-region {
  color: inherit;
}
.site-shell #site-nav.marketing-nav a:hover {
  opacity: 0.76;
}
.site-shell #site-nav .marketing-nav-tools {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
  white-space: nowrap;
}
.site-shell #site-nav .marketing-buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 112px;
  height: 36px;
  padding: 0 18px;
  background: #1683ff;
  box-shadow: none;
  border-radius: 6px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  transition:
    background-color 0.2s,
    box-shadow 0.2s;
}
.site-shell #site-nav .marketing-buy:hover {
  opacity: 1 !important;
  background: #258bff;
  box-shadow: none;
}
.site-shell #site-nav .marketing-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 36px;
  border: 0;
  padding: 0;
  background: transparent;
}
.site-shell #site-nav .marketing-icon svg {
  width: 24px;
  height: 24px;
}
.site-shell #site-nav .marketing-region {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  font-size: 12px;
  font-weight: 500;
}
.site-shell #site-nav .marketing-region svg {
  width: 20px;
  height: 20px;
}
.site-shell #site-nav.marketing-nav #account-menu-wrapper {
  margin: 0;
}
.site-shell #site-nav.marketing-nav #account-nav-link {
  height: 36px;
  width: 28px;
  padding: 0;
  border-radius: 0;
}
.site-shell #site-nav.marketing-nav #account-nav-link img {
  width: 24px;
  height: 24px;
  filter: brightness(0) invert(1);
}
.site-shell #site-nav.marketing-nav:hover #account-nav-link img,
.site-shell #site-nav.marketing-nav:focus-within #account-nav-link img,
.site-shell #site-nav.marketing-nav.is-scrolled #account-nav-link img {
  filter: brightness(0);
}
.site-shell #site-nav.marketing-nav #account-dropdown {
  color: #222;
}
.site-shell #site-nav.marketing-nav #mobile-dropdown {
  color: #222;
}
.site-shell .marketing-search {
  position: fixed;
  top: 80px;
  width: min(720px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 0;
  border: 0;
  border-radius: 8px;
  color: #222;
  background: #fff;
  box-shadow: 0 24px 80px #0003;
}
.site-shell .marketing-search::backdrop {
  background: #0006;
  backdrop-filter: blur(5px);
}
.site-shell .marketing-search-body {
  padding: 32px;
}
.site-shell .marketing-search-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 22px;
}
.site-shell .marketing-search-heading button {
  width: 40px;
  height: 40px;
  font-size: 30px;
}
.site-shell .marketing-search input {
  width: 100%;
  border: 0;
  border-bottom: 1px solid #bbb;
  padding: 16px 0;
  font-size: 24px;
  margin-bottom: 16px;
}
.site-shell .marketing-search-results a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
}
.site-shell .marketing-search-results a:hover {
  color: #0d6bdd;
}
@media (max-width: 1200px) {
  .site-shell #site-nav .marketing-nav-inner {
    gap: 32px;
  }
  .site-shell #site-nav .marketing-nav-links {
    gap: 24px;
  }
  .site-shell #site-nav .marketing-nav-tools {
    gap: 12px;
  }
  .site-shell #site-nav .marketing-region {
    font-size: 11px;
  }
}
@media (max-width: 1023px) {
  .site-shell #site-nav .marketing-nav-links {
    display: none;
  }
  .site-shell #site-nav .marketing-nav-inner {
    padding: 0 24px;
  }
  .site-shell #site-nav .marketing-nav-tools {
    gap: 20px;
  }
}
@media (max-width: 640px) {
  .site-shell #site-nav.marketing-nav,
  .site-shell #site-nav .marketing-nav-inner {
    height: 56px;
  }
  .site-shell #site-nav .marketing-nav-inner {
    padding: 0 20px;
    gap: 12px;
  }
  .site-shell #site-nav.marketing-nav #header-logo {
    height: 20px;
  }
  .site-shell #site-nav .marketing-nav-tools {
    gap: 12px;
  }
  .site-shell #site-nav .marketing-buy {
    min-width: 80px;
    height: 32px;
    padding: 0 10px;
    font-size: 12px;
  }
  .site-shell #site-nav .marketing-region {
    width: 24px;
    height: 32px;
    justify-content: center;
  }
  .site-shell #site-nav .marketing-region #lang-toggle-label {
    display: none;
  }
  .site-shell #site-nav .marketing-region svg {
    flex-shrink: 0;
  }
  .site-shell #site-nav.marketing-nav #account-menu-wrapper {
    display: none;
  }
  .site-shell #site-nav.marketing-nav #mobile-menu-btn {
    margin-left: 0;
  }
  .site-shell .marketing-search-body {
    padding: 24px;
  }
}
@media (max-width: 640px) {
  .site-shell #site-nav .marketing-nav-inner {
    padding-inline: 16px;
    gap: 8px;
  }
  .site-shell #site-nav .marketing-nav-tools {
    gap: 8px;
  }
  .site-shell #site-nav.marketing-nav #header-logo {
    height: 18px;
  }
  .site-shell #site-nav.marketing-nav #account-menu-wrapper {
    display: block;
  }
  .site-shell #site-nav.marketing-nav #account-nav-link,
  .site-shell #site-nav .marketing-icon {
    width: 22px;
  }
  .site-shell #site-nav.marketing-nav #account-nav-link img,
  .site-shell #site-nav .marketing-icon svg {
    width: 20px;
    height: 20px;
  }
  .site-shell #site-nav .marketing-region {
    width: 20px;
  }
  .site-shell #site-nav .marketing-buy {
    min-width: 72px;
    padding-inline: 8px;
  }
  .site-shell #site-nav.marketing-nav #mobile-menu-btn svg {
    width: 20px;
  }
}
@media (max-width: 360px) {
  .site-shell #site-nav .marketing-nav-tools {
    gap: 5px;
  }
  .site-shell #site-nav .marketing-buy {
    min-width: 64px;
    padding-inline: 5px;
  }
  .site-shell #site-nav .marketing-nav-inner {
    padding-inline: 12px;
  }
}
.site-shell .marketing-search {
  max-height: calc(100vh - 112px);
  max-height: calc(100dvh - 112px);
  overflow-y: auto;
}

.site-shell #site-nav .marketing-buy {
  gap: 6px;
}
.site-shell #site-nav .marketing-buy svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.site-shell #site-footer {
  border-top: 1px solid #ededf0;
  padding: 64px 0 28px;
  background: #fff;
  color: #76767f;
  font-size: 14px;
  line-height: 22px;
  font-weight: 400;
}
.site-shell #site-footer > div {
  max-width: 1376px;
  padding: 0 32px;
}
.site-shell #site-footer .site-footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  align-items: start;
  gap: 48px 80px;
  margin: 0 0 16px;
}
.site-shell #site-footer .site-footer-brand {
  grid-column: 1;
  grid-row: 2;
  align-self: end;
}
.site-shell #site-footer #footer-logo {
  height: 24px;
  filter: brightness(0);
}
.site-shell #site-footer .site-footer-links {
  grid-column: 1;
  grid-row: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px 48px;
  margin: 0;
  font-size: 14px;
  line-height: 22px;
  font-weight: 400;
  color: #76767f;
}
.site-shell #site-footer .site-footer-links a {
  width: fit-content;
  letter-spacing: normal;
}
.site-shell #site-footer a:hover {
  color: #262629;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.site-shell #site-footer .site-footer-social {
  grid-column: 2;
  grid-row: 2;
  align-self: end;
  justify-self: end;
  gap: 16px;
}
.site-shell #site-footer .site-footer-social a {
  width: 24px;
  height: 24px;
  border-radius: 0;
}
.site-shell #site-footer .site-footer-social a > div {
  width: 20px;
  height: 20px;
}
.site-shell #site-footer .site-footer-social a img {
  filter: grayscale(1) brightness(0);
  opacity: 0.5;
}
.site-shell #site-footer .site-footer-social a:hover img {
  opacity: 1;
}
.site-shell #site-footer .site-footer-main + div {
  height: 1px;
  margin: 0 0 16px;
  background: #ededf0;
}
.site-shell #site-footer .site-footer-legal {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  color: #a1a1ad;
  font-size: 12px;
  line-height: 20px;
  font-weight: 400;
}
.site-shell #site-footer .site-footer-policy {
  order: -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 0;
  margin: 0;
  color: #76767f;
  font-size: 13px;
}
.site-shell #site-footer .site-footer-policy > * {
  margin: 0;
}
.site-shell #site-footer .site-footer-policy > * + *::before {
  content: '|';
  margin: 0 12px;
  color: #b5b5bd;
}
.site-shell #site-footer .site-footer-follow {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}
.site-shell #site-footer .site-footer-follow h3 {
  margin: 0;
  color: #262629;
  font-size: 14px;
  line-height: 22px;
  font-weight: 600;
}
.site-shell #site-footer .site-footer-follow-description {
  margin: 12px 0 20px;
  color: #76767f;
  font-size: 13px;
  line-height: 1.7;
}
.site-shell #site-footer .site-footer-qr {
  display: block;
  width: 112px;
  height: 112px;
  padding: 7px;
  border: 1px solid #f0f0f3;
  border-radius: 8px;
  background: #fff;
}
.site-shell #site-footer .site-footer-qr img {
  display: block;
  width: 96px;
  height: 96px;
  max-width: none;
  object-fit: contain;
}
.site-shell #site-footer .site-footer-follow-scan {
  margin: 12px 0 0;
  color: #76767f;
  font-size: 12px;
  line-height: 20px;
}
@media (min-width: 768px) and (max-width: 1023px) {
  .site-shell #site-footer .site-footer-main {
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 32px 48px;
  }
  .site-shell #site-footer .site-footer-brand {
    grid-column: 1;
  }
  .site-shell #site-footer .site-footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 767px) {
  .site-shell #site-footer {
    padding: 40px 0 24px;
  }
  .site-shell #site-footer > div {
    padding: 0 20px;
  }
  .site-shell #site-footer .site-footer-main {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 24px;
  }
  .site-shell #site-footer .site-footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 24px;
  }
  .site-shell #site-footer .site-footer-social {
    justify-self: start;
    gap: 20px;
  }
}

.site-shell #site-footer .site-footer-links a {
  display: inline-block;
  flex-basis: auto;
  text-align: left;
}
.site-shell #site-footer .site-footer-social {
  width: auto;
  padding-top: 0;
  border-top: 0;
}
.site-shell #site-footer .site-footer-main + div {
  display: block;
}
.site-shell #site-footer .site-footer-policy {
  flex-direction: row;
  justify-content: flex-start;
}
.site-shell #site-footer #icp-info {
  flex-basis: auto;
}
.site-shell #site-nav .marketing-cart-link {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  position: relative;
}
.site-shell #site-nav .marketing-cart-link #cart-count {
  position: static;
  background: #0d6bdd;
}
.site-shell:not([data-site-page='index']) #header-placeholder {
  min-height: 64px;
}
@media (max-width: 640px) {
  .site-shell:not([data-site-page='index']) #header-placeholder {
    min-height: 56px;
  }
}
/* 嵌入标记早于客户端接管生效，避免预渲染的官网导航占位短暂留白。 */
html.app-mode .site-shell #header-placeholder {
  display: none;
  min-height: 0;
}

@media (max-width: 767px) {
  .site-shell #site-footer .site-footer-follow {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    grid-template-rows: auto auto 1fr;
    column-gap: 24px;
    row-gap: 8px;
    align-items: start;
  }
  .site-shell #site-footer .site-footer-follow h3 {
    grid-column: 2;
    grid-row: 1;
  }
  .site-shell #site-footer .site-footer-follow-description {
    grid-column: 2;
    grid-row: 2;
    margin: 0;
  }
  .site-shell #site-footer .site-footer-qr {
    grid-column: 1;
    grid-row: 1 / 4;
  }
  .site-shell #site-footer .site-footer-follow-scan {
    grid-column: 2;
    grid-row: 3;
    margin: 0;
  }
}
@media (max-width: 359px) {
  .site-shell #site-footer .site-footer-follow {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .site-shell #site-footer .site-footer-follow h3,
  .site-shell #site-footer .site-footer-follow-description,
  .site-shell #site-footer .site-footer-qr,
  .site-shell #site-footer .site-footer-follow-scan {
    grid-column: auto;
    grid-row: auto;
  }
}

.site-shell #site-footer .site-footer-group h3 {
  margin: 0;
  color: #262629;
  font-size: 14px;
  line-height: 22px;
  font-weight: 600;
}
.site-shell #site-footer .site-footer-group ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}
.site-shell #site-footer .site-footer-group li {
  min-width: 0;
  line-height: 22px;
}
.site-shell #site-footer .site-footer-placeholder {
  display: inline-block;
  color: #76767f;
}
@media (max-width: 767px) {
  .site-shell #site-footer .site-footer-links {
    grid-column: 1;
    grid-row: 1;
    gap: 32px 24px;
  }
  .site-shell #site-footer .site-footer-follow {
    grid-column: 1;
    grid-row: 2;
  }
  .site-shell #site-footer .site-footer-brand {
    grid-column: 1;
    grid-row: 3;
  }
  .site-shell #site-footer .site-footer-social {
    grid-column: 1;
    grid-row: 4;
  }
}

/* Shared floating service contact panel. */
.site-shell .site-support {
  position: fixed;
  z-index: 60;
  right: 28px;
  bottom: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  color: #262629;
  font-size: 14px;
  line-height: 1.6;
}
.site-shell .site-support-trigger {
  position: relative;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  overflow: hidden;
  border: 1px solid #eeeef1;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 20px #00000012;
}
.site-shell .site-support-trigger > img {
  position: absolute;
  top: -1px;
  left: 50%;
  width: 60px;
  min-width: 60px;
  max-width: none;
  height: 60px;
  transform: translateX(-50%);
  object-fit: contain;
}
.site-shell .site-support-trigger > svg {
  width: 24px;
  height: 24px;
}
.site-shell .site-support-panel {
  position: absolute;
  right: 0;
  bottom: 56px;
  width: 310px;
  max-width: calc(100vw - 40px);
  max-height: calc(100vh - 128px);
  max-height: calc(100dvh - 128px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 20px 24px 24px;
  border: 1px solid #f1f1f4;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 36px #00000014;
}
.site-shell .site-support-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}
.site-shell .site-support-heading h2 {
  margin: 0;
  font-size: 14px;
  line-height: 24px;
  font-weight: 600;
}
.site-shell .site-support-close {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-right: -8px;
  border: 0;
  background: transparent;
  color: #76767f;
  font-size: 24px;
  line-height: 1;
}
.site-shell .site-support-item {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 12px;
  padding: 18px 0;
}
.site-shell .site-support-item + .site-support-item {
  border-top: 1px solid #ededf0;
}
.site-shell .site-support-item:last-child {
  padding-bottom: 0;
}
.site-shell .site-support-item > svg {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}
.site-shell .site-support-item h3 {
  margin: 0 0 6px;
  font-size: 14px;
  line-height: 22px;
  font-weight: 600;
}
.site-shell .site-support-contact {
  color: #0d6bdd;
  font-size: 14px;
  line-height: 24px;
  overflow-wrap: anywhere;
}
.site-shell .site-support-contact:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.site-shell .site-support-qr {
  display: block;
  width: 128px;
  height: 128px;
  padding: 7px;
  margin-top: 12px;
  border: 1px solid #ededf0;
  border-radius: 8px;
  background: #fff;
}
.site-shell .site-support-qr img {
  display: block;
  width: 112px;
  height: 112px;
  max-width: none;
  object-fit: contain;
}
.site-shell .site-support-item p {
  margin: 10px 0 0;
  font-size: 12px;
  line-height: 20px;
  color: #76767f;
}
@media (max-width: 640px) {
  .site-shell .site-support {
    right: 16px;
    bottom: 16px;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }
  .site-shell .site-support-trigger {
    width: 40px;
    height: 40px;
  }
  .site-shell .site-support-trigger > img {
    width: 60px;
    min-width: 60px;
    height: 60px;
  }
  .site-shell .site-support-panel {
    bottom: 56px;
    max-width: calc(100vw - 32px);
  }
}

/* Keep the 16px gap between avatar and panel inside the hover region. */
.site-shell .site-support.is-open::before {
  content: '';
  position: absolute;
  right: 0;
  bottom: 40px;
  width: 310px;
  max-width: calc(100vw - 32px);
  height: 16px;
}

.site-shell .site-back-top {
  position: fixed;
  z-index: 59;
  right: 28px;
  bottom: 84px;
  bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid #eeeef1;
  border-radius: 50%;
  background: #fff;
  color: #262629;
  box-shadow: 0 4px 20px #00000012;
  transition: background-color 0.2s;
}
.site-shell .site-back-top:hover {
  background: #f7f8fa;
}
.site-shell .site-back-top svg {
  width: 20px;
  height: 20px;
}
@media (max-width: 640px) {
  .site-shell .site-back-top {
    right: 16px;
    bottom: 76px;
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
  }
}

/* Keep edge social QR popovers within the footer on tablet and narrow screens. */
.site-shell #site-footer .site-footer-social > .group:first-child > .absolute {
  left: 0;
  right: auto;
}
.site-shell #site-footer .site-footer-social > .group:last-child > .absolute {
  left: auto;
  right: 0;
}
