/* nav-consistency.css
 * Normalize top navigation typography early in <head> to avoid per-page size jumps.
 */

@media screen {
  :root {
    --cp-nav-font-family: 'Noto Sans TC', 'Microsoft JhengHei', 'PingFang TC', 'Heiti TC', sans-serif;
    --cp-nav-font-size: 0.95rem;
    --cp-nav-font-size-mobile: 0.92rem;
    --cp-nav-badge-font-size: 0.76rem;
    --cp-nav-line-height: 1.35;
  }

  body > nav,
  body > nav *,
  body > nav ul,
  body > nav li,
  body > nav a,
  body > nav button,
  body > nav span {
    font-family: var(--cp-nav-font-family) !important;
    text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
  }

  body > nav ul li a,
  body > nav .hamburger-text,
  body > nav .user-info,
  body > nav .user-info a,
  body > nav .user-info span,
  body > nav .select-wrapper {
    font-size: var(--cp-nav-font-size) !important;
    line-height: var(--cp-nav-line-height) !important;
    font-weight: 500;
    letter-spacing: 0.01em;
  }

  body > nav .user-info,
  body > nav .user-info a,
  body > nav .user-info span {
    font-weight: 700;
  }

  body > nav #cartBadge {
    font-size: var(--cp-nav-badge-font-size) !important;
    line-height: 1 !important;
  }

  @media (max-width: 768px) {
    body > nav ul li a,
    body > nav .hamburger-text,
    body > nav .user-info,
    body > nav .user-info a,
    body > nav .user-info span {
      font-size: var(--cp-nav-font-size-mobile) !important;
    }
  }
}
