.footer-nav-toggle { display: none; }
.footer-contact .footer-contact-link { display: inline-flex; gap: .6rem; align-items: flex-start; min-width: 0; }
.footer-contact-link span { overflow-wrap: anywhere; }

@media (max-width: 767px) {
  body.footer-navigation-visible .mobile-bar { display: none; }
  /* 页脚收起固定联络栏后，仅保留设备安全区；比较清单仍保留自己的空间。 */
  body.footer-navigation-visible:not(.has-compare-bar) { padding-bottom: env(safe-area-inset-bottom, 0px); }
  .footer-main .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 0; padding-block: 2.25rem; }
  .footer-brand { padding-bottom: 1.5rem; }
  .footer-nav-section { border-bottom: 1px solid rgba(255,255,255,.16); }
  .footer-nav-section.is-collapsible h4 { margin: 0; }
  .footer-nav-section.is-collapsible .footer-column-title { display: none; }
  .footer-nav-section.is-collapsible .footer-nav-toggle { display: flex; align-items: center; justify-content: space-between; gap: 1rem; width: 100%; min-height: 52px; padding: .9rem 0; border: 0; background: transparent; color: inherit; font: inherit; letter-spacing: inherit; text-transform: inherit; text-align: start; cursor: pointer; }
  .footer-nav-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
  .footer-nav-toggle svg { width: 18px; height: 18px; transition: transform .18s ease; }
  .footer-nav-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
  .footer-nav-section ul { padding-bottom: 1rem; }
  .footer-nav-section ul[hidden] { display: none; }
  .footer-contact-section { margin-top: 1.75rem; }
}

@media (prefers-reduced-motion: reduce) {
  .footer-nav-toggle svg { transition: none; }
}

/* 宽屏延用原来的单行排列；手机和平板为语言留出单独一行。 */
.footer-languages { display: contents; }

@media (max-width: 1023px) {
  .footer-nav-section li a { display: flex; align-items: center; min-height: 44px; }
  .footer-main .footer-nav-section li, .footer-main .footer-contact li:has(.footer-contact-link) { margin-bottom: 0; }
  .footer-contact .footer-contact-link { align-items: center; min-height: 44px; }
  .footer-contact .footer-contact-link svg { margin-top: 0; }
  .footer-main .footer-bottom .container { flex-direction: column; align-items: flex-start; gap: .25rem; }
  .footer-main .footer-bottom .links { column-gap: .65rem; row-gap: 0; }
  .footer-bottom .links :is(a, button) { display: inline-flex; align-items: center; min-height: 44px; }
  .footer-bottom .footer-languages { display: flex; flex-basis: 100%; flex-wrap: wrap; gap: .25rem; }
  .footer-languages a { min-width: 44px; justify-content: center; }
  .footer-languages a[aria-current] { text-decoration: underline; text-underline-offset: .3em; }
}

/* 平板的联系方式接在导航栏下方，让长地址使用整行。 */
@media (min-width: 768px) and (max-width: 1023px) {
  .footer-contact-section { grid-column: 1 / -1; }
}
