/* ==========================================================================
   mpf-header-footer.css — 公告条 / Kadence Header / 导航 / 图标 / Footer
   说明：Kadence 免费版 Header/Footer Builder 以后台配置为主，本文件做品牌皮肤兜底；
   类名以 G7 实测为准，采用宽松多选择器分组，必要处 !important 压过主题调色板（B-2 #16）。
   ========================================================================== */

/* ---------- 顶部公告条（Kadence Top Bar） ---------- */
#topbar, .site-top-bar, .top-bar, .site-header-top {
  background: var(--mpf-ink) !important;
  color: var(--mpf-white) !important;
  font-size: 13.5px;
  font-weight: 500;
}
#topbar a, .site-top-bar a, .top-bar a { color: var(--mpf-white) !important; }
#topbar .topbar-inner-wrap, .site-top-bar .topbar-inner-wrap { padding: 8px 0; }
.mpf-announce { text-align: center; letter-spacing: .01em; }
.mpf-announce strong { color: var(--mpf-sun); font-weight: 700; }

/* ---------- 主 Header ---------- */
#masthead.site-header, .site-header, .header-main {
  background: var(--mpf-white) !important;
  border-bottom: 1px solid var(--mpf-line);
  box-shadow: var(--mpf-shadow-sm);
}
.site-header-row-container-inner .site-header-row { background: var(--mpf-white) !important; }
.site-branding { display: flex; align-items: center; }
.custom-logo, .site-logo img { max-height: 52px; width: auto; }
.site-title, .site-title a {
  font-family: var(--mpf-font) !important;
  font-weight: 800 !important;
  color: var(--mpf-ink) !important;
  font-size: 22px !important;
  letter-spacing: -.01em;
}
.site-description { color: var(--mpf-ink-500); font-size: 12px; }

/* 主导航 */
#primary-menu, .primary-menu-container ul, .header-main .menu {
  display: flex; gap: 6px; align-items: center;
}
#primary-menu .menu-item > a,
.primary-menu-container .menu-item > a,
.header-main .menu > li > a {
  font-family: var(--mpf-font) !important;
  font-weight: 600 !important;
  font-size: 15px !important;
  color: var(--mpf-ink) !important;
  padding: 10px 14px !important;
  border-radius: var(--mpf-radius-pill);
  transition: color .15s ease, background .15s ease;
}
#primary-menu .menu-item > a:hover,
.primary-menu-container .menu-item > a:hover,
.header-main .menu > li > a:hover {
  color: var(--mpf-coral-deep) !important;
  background: var(--mpf-cream);
}
#primary-menu .current-menu-item > a,
.primary-menu-container .current-menu-item > a {
  color: var(--mpf-coral-deep) !important;
}
/* 下拉菜单 */
#primary-menu .sub-menu, .primary-menu-container .sub-menu {
  background: var(--mpf-white);
  border: 1px solid var(--mpf-line);
  border-radius: var(--mpf-radius-md);
  box-shadow: var(--mpf-shadow-md);
  padding: 8px;
  min-width: 200px;
}
#primary-menu .sub-menu a { color: var(--mpf-ink-700) !important; padding: 9px 12px !important; border-radius: 8px; }
#primary-menu .sub-menu a:hover { background: var(--mpf-cream); color: var(--mpf-coral-deep) !important; }

/* Header 图标按钮（搜索/账户/心愿/购物车） */
.header-actions, .header-action, .site-header-cart, .kadence-header-account,
.search-toggle, .header-search-toggle {
  display: inline-flex; align-items: center; gap: 4px;
}
.header-action a, .header-action button, .search-toggle,
.kadence-header-account a, .site-header-cart .cart-contents {
  width: 42px; height: 42px; display: inline-flex; align-items: center; justify-content: center;
  color: var(--mpf-ink) !important; background: transparent !important; border: none !important;
  border-radius: 50%; position: relative;
}
.header-action a:hover, .search-toggle:hover, .kadence-header-account a:hover, .site-header-cart .cart-contents:hover {
  background: var(--mpf-cream) !important; color: var(--mpf-coral-deep) !important;
}
.header-action svg, .search-toggle svg, .kadence-header-account svg, .site-header-cart svg { width: 21px; height: 21px; }
/* 购物车角标 */
.site-header-cart .count, .cart-contents .count, .header-cart-count {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--mpf-coral) !important; color: var(--mpf-ink) !important;
  border-radius: var(--mpf-radius-pill); font-size: 11px; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center; line-height: 1;
}

/* 移动汉堡 */
.mobile-toggle, .menu-toggle, .kadence-mobile-toggle {
  background: transparent !important; border: none !important; color: var(--mpf-ink) !important;
  width: 44px; height: 44px; border-radius: var(--mpf-radius-md);
}
.mobile-toggle:hover { background: var(--mpf-cream); }

/* ---------- Footer ---------- */
footer.site-footer, #colophon, .site-footer {
  background: var(--mpf-ink) !important;
  color: rgba(255, 255, 255, .78) !important;
  margin-top: 72px;
}
.site-footer-primary, .footer-inner-wrap, .footer-widget-area { padding: 64px 0 32px; }
.site-footer h2, .site-footer h3, .site-footer h4, .footer-widget-title {
  color: var(--mpf-white) !important; font-size: 15px !important; font-weight: 700 !important;
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: 18px;
}
.site-footer a { color: rgba(255, 255, 255, .78) !important; font-size: 14.5px; line-height: 2.1; }
.site-footer a:hover { color: var(--mpf-coral) !important; }
.site-footer .widget ul { list-style: none; padding: 0; margin: 0; }
.site-footer .footer-brand p { color: rgba(255, 255, 255, .72); font-size: 14.5px; line-height: 1.7; max-width: 320px; }
.site-footer .custom-logo { max-height: 46px; filter: brightness(0) invert(1); }

/* Footer 订阅 */
.mpf-footer-newsletter { display: flex; gap: 8px; margin-top: 16px; max-width: 360px; }
.mpf-footer-newsletter input {
  flex: 1; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .22);
  color: #fff; border-radius: var(--mpf-radius-md); padding: 12px 14px; font-size: 14px;
}
.mpf-footer-newsletter input::placeholder { color: rgba(255, 255, 255, .55); }
.mpf-footer-newsletter .button { white-space: nowrap; }

/* 支付图标 */
.mpf-pay-icons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.mpf-pay-icons span {
  background: #fff; color: var(--mpf-ink); font-size: 11px; font-weight: 800; letter-spacing: .04em;
  padding: 5px 10px; border-radius: 6px;
}
.site-footer-bottom, .footer-bottom, .site-footer-copyright {
  border-top: 1px solid rgba(255, 255, 255, .12);
  padding: 22px 0; font-size: 13px; color: rgba(255, 255, 255, .6);
}
.site-footer-bottom a { color: rgba(255, 255, 255, .78) !important; }

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .site-footer-primary, .footer-inner-wrap { padding: 44px 0 24px; }
  .mpf-footer-newsletter { flex-direction: column; }
  .mpf-footer-newsletter .button { width: 100%; }
}
