/* Unified footer. Markup is synchronized from index.html by scripts/sync-footer.py. */
footer.footer-modern.site-footer-current {
  box-sizing: border-box; position: relative; z-index: 1; width: 100%; max-width: none;
  margin: 0; padding: 68px 10% 30px; border: 0; border-radius: 0;
  background: #0b0d12; color: #fff; box-shadow: none; text-align: left; backdrop-filter: none;
}
.site-footer-current *, .site-footer-current *::before, .site-footer-current *::after { box-sizing: border-box; }
.site-footer-current .footer-main { display: grid; grid-template-columns: minmax(280px,.82fr) minmax(0,1.72fr); align-items: start; gap: clamp(64px,8vw,140px); min-height: 300px; }
.site-footer-current .footer-brand { max-width: 420px; margin: 0; text-align: left; }
.site-footer-current .footer-logo { display: block; width: 280px; max-width: 100%; height: auto; margin: 0 0 28px; filter: brightness(0) invert(1); }
.site-footer-current .footer-brand > p { display: block; margin: 0; }
.site-footer-current .footer-brand > p span { display: block; color: #a5adbd; font-size: 15px; font-weight: 600; line-height: 1.5; }
.site-footer-current .footer-brand > p small { display: block; margin-top: 7px; color: #7f8798; font-size: 13px; line-height: 1.55; }
.site-footer-current .footer-nav { display: grid; align-content: start; padding-top: 2px; }
.site-footer-current .footer-nav > div { display: flex; flex-direction: column; align-items: flex-start; gap: 13px; text-align: left; }
.site-footer-current .footer-nav b { margin-bottom: 6px; color: #7d8492; font-size: 13px; font-weight: 520; line-height: 1.4; }
.site-footer-current .footer-nav a { color: #d6dae5; font-size: 13px; line-height: 1.55; text-decoration: none; }
.site-footer-current .footer-nav a:hover { color: #6f8cff; }
.site-footer-current .wechat-follow.qr-pair { --footer-qr-size: 110px; display: grid; grid-template-columns: repeat(2, 132px); align-items: stretch !important; gap: 12px; width: max-content; max-width: 100%; margin-top: 24px; }
.site-footer-current .qr-pair .wechat-qr { position: relative; left: auto; bottom: auto; display: grid; grid-template-rows: var(--footer-qr-size) 1fr; align-content: start; width: 100%; height: 100%; padding: 10px; border: 1px solid rgba(255,255,255,.12); border-radius: 12px; opacity: 1; visibility: visible; transform: none; }
/* Both image structures use the same square: the advisor has a .qr-code wrapper. */
.site-footer-current .qr-pair .wechat-qr > .qr-code,
.site-footer-current .qr-pair .wechat-qr > img,
.site-footer-current .qr-pair .wechat-qr .qr-code > img:first-child { display: block; width: var(--footer-qr-size); height: var(--footer-qr-size); max-width: 100%; object-fit: contain; }
.site-footer-current .qr-pair .wechat-qr span { display: block; padding-top: 6px; color: #344054; font-size: 12px; line-height: 1.5; white-space: normal; text-align: center; }
.site-footer-current .footer-legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; width: 100%; margin: 0; padding: 20px 0 0; border-top: 1px solid rgba(255,255,255,.1); color: #7f8798; background: transparent; text-align: left; font-size: 12px; }
.site-footer-current .footer-legal > div { display: flex; flex-wrap: wrap; gap: 20px; }
.site-footer-current .footer-legal > span,
.site-footer-current .footer-legal > div { flex: 0 1 auto; min-width: 0; }
/* 版权行只在空格处换行，公司名不在字中间断开 */
.site-footer-current .footer-legal > span:first-child { word-break: keep-all; overflow-wrap: anywhere; }
.site-footer-current .footer-legal > div:last-child { margin-left: auto; justify-content: flex-end; text-align: right; }
.site-footer-current .footer-legal a { color: #9aa3b4; text-decoration: none; }
.site-footer-current .footer-legal a:hover { color: #fff; }
.site-footer-current a:focus-visible { outline: 2px solid #99a6fa; outline-offset: 4px; }
@media (max-width: 700px) {
  footer.footer-modern.site-footer-current { padding: 42px 24px 24px; }
  .site-footer-current .footer-main { min-height: 0; }
  .site-footer-current .footer-logo { width: 240px; }
  .site-footer-current .wechat-follow.qr-pair { --footer-qr-size: 96px; grid-template-columns: repeat(2, 118px); }
  .site-footer-current .footer-legal { align-items: flex-start; flex-direction: column; }
}

/* Keep essential navigation in three columns; override legacy footer grids. */
.site-footer-current .footer-main { padding-bottom: 12px; }
.site-footer-current .footer-nav.footer-nav-current {
  grid-template-columns: repeat(3, minmax(0, max-content)) !important;
  justify-content: space-between;
  gap: 32px clamp(32px, 5vw, 96px) !important;
  min-width: 0;
  max-width: none;
  overflow: visible;
}
.site-footer-current .footer-nav-current > div { min-width: 0; }
.site-footer-current .footer-nav-current a { overflow-wrap: anywhere; }

@media (max-width: 1100px) {
  .site-footer-current .footer-main { grid-template-columns: minmax(0, 1fr); gap: 44px; }
}
@media (max-width: 700px) {
  .site-footer-current .footer-nav.footer-nav-current { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; justify-content: stretch; gap: 32px 24px !important; }
}

/* Footer links are 19-20px of text on phones, under the 24px minimum target.
   Padding grows the tappable box and a matching negative margin cancels its
   effect on layout, so the rows keep their spacing and nothing moves. */
@media (max-width: 700px) {
  .site-footer-current .footer-nav a {
    padding-block: 6px;
    margin-block: -6px;
  }
  .site-footer-current .footer-legal a {
    padding-block: 6px;
    margin-block: -6px;
  }
}

/* 页脚第二层：左侧安全与合规认证，右侧商务合作邮箱，同一行居中对齐（2026-09-18 重排：
   原来认证挂在品牌栏下方把左栏拉长，邮箱单独悬在导航右下角） */
.site-footer-current .footer-main { min-height: 0; padding-bottom: 0; }
.site-footer-current .footer-meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 48px; margin: 48px 0 0; padding: 0 0 28px; }
.site-footer-current .footer-cert { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 0; }
.site-footer-current .footer-cert > p { margin: 0; color: #7d8492; font-size: 13px; line-height: 1.5; white-space: nowrap; }
.site-footer-current .footer-cert-list { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 0; padding: 0; list-style: none; }
.site-footer-current .footer-cert-list li { margin: 0; padding: 0; }
.site-footer-current .footer-cert-list img { display: block; width: auto; height: 48px; max-width: 48px; object-fit: contain; }
.site-footer-current .footer-meta .footer-contact-email { color: #d6dae5; font-size: 14px; line-height: 1.5; text-decoration: none; white-space: nowrap; }
.site-footer-current .footer-meta .footer-contact-email .footer-contact-label { color: #7d8492; }
.site-footer-current .footer-meta .footer-contact-email:hover { color: #6f8cff; }
@media (max-width: 700px) {
  .site-footer-current .footer-meta { flex-direction: column; align-items: flex-start; gap: 24px; margin-top: 40px; padding-bottom: 24px; }
  .site-footer-current .footer-cert { flex-direction: column; align-items: flex-start; gap: 12px; }
  .site-footer-current .footer-cert-list { gap: 8px; }
  .site-footer-current .footer-cert-list img { height: 42px; max-width: 42px; }
  .site-footer-current .footer-meta .footer-contact-email { white-space: normal; overflow-wrap: anywhere; padding-block: 6px; margin-block: -6px; }
  .site-footer-current .footer-legal > div:last-child { margin-left: 0; justify-content: flex-start; text-align: left; }
}
