/* Mobile navigation and touch targets. No business state is duplicated. */
.header-main>.menu-toggle { display: none; }
.catalog-layout { row-gap: 0; }
.catalog-layout>.woocommerce-products-header { grid-column: 2; grid-row: 1; }
.catalog-layout>.catalog-sidebar { grid-column: 1; grid-row: 1 / span 2; }
.catalog-layout>.catalog-results { grid-column: 2; grid-row: 2; }
.bidu-menu-dialog:not([open]) { display: none; }
.bidu-menu-dialog {
  position: fixed; inset: 0 auto 0 0; margin: 0; width: min(88vw, 360px);
  height: 100%; height: 100dvh; max-height: none; max-width: none;
  padding: 20px; border: 0; background: #fff; color: var(--bidu-ink);
  overflow-y: auto; overscroll-behavior: contain;
}
.bidu-menu-dialog::backdrop { background: #18202480; }
.bidu-menu-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.bidu-menu-heading h2 { font-size: 1.25rem; line-height: 1.3; margin: 0; }
.bidu-menu-close { min-width: 44px; min-height: 44px; padding: 8px 12px; border: 1px solid var(--bidu-line); border-radius: 6px; background: #fff; color: var(--bidu-ink); font-size: 1rem; }
.bidu-menu-close:hover { color: var(--bidu-accent); border-color: var(--bidu-accent); }
.js .bidu-menu-dialog #site-navigation { display: block; }
html.bidu-menu-open,html.bidu-menu-open body { overflow: hidden; }
.bidu-catalog-reset { min-height: 44px; }
@media(max-width:680px) {
  .header-main { grid-template-columns: 44px minmax(0,1fr) auto; gap: 0 12px; padding-bottom: 12px; }
  .header-main>.site-brand { grid-column: 1 / 3; grid-row: 1; height: 64px; }
  .bidu-menu-ready .header-main>.site-brand { grid-column: 2; }
  .site-brand .custom-logo { width: 80px; max-height: 58px; }
  .bidu-menu-ready .header-main>.menu-toggle { display: flex; grid-column: 1; grid-row: 1; width: 44px; height: 44px; padding: 10px; justify-content: center; }
  .header-main>.menu-toggle .bidu-icon { width: 24px; height: 24px; }
  .header-main>.header-actions { grid-column: 3; grid-row: 1; gap: 8px; }
  .header-actions .header-account { width: 44px; height: 44px; padding: 10px; justify-content: center; }
  .header-actions .header-account span { display: none; }
  .header-actions .header-quote { width: 44px; height: 44px; }
  .product-search input[type=search] { height: 48px; font-size: 16px; padding: 10px 54px 10px 13px; }
  .product-search button { width: 44px; height: 44px; top: 2px; right: 2px; }
  .bidu-menu-ready .nav-strip { display: none; }
  /* Without dialog support or JavaScript, the original navigation remains visible. */
  .js #site-navigation:not(.is-open) { display: block; }
  .nav-inner .nav-catalog { position: static; min-height: 44px; font-size: 14px; }
  .primary-menu { padding: 0; }
  .primary-menu a { display: flex; align-items: center; min-height: 48px; padding: 12px 0; font-size: 16px; overflow-wrap: anywhere; }
  .primary-menu .sub-menu a { min-height: 44px; font-size: 14px; }
  .bidu-menu-dialog .primary-menu li { border-color: var(--bidu-line); }
  .department-grid { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 140px; gap: 12px; overflow-x: auto; padding: 4px 4px 12px; scroll-snap-type: x proximity; scroll-padding-inline: 4px; overscroll-behavior-x: contain; }
  .department-item,.department-item:last-child:nth-child(odd) { grid-column: auto; min-height: 136px; flex-direction: column; justify-content: flex-start; padding: 14px 10px; gap: 10px; font-size: 14px; line-height: 1.35; text-align: center; scroll-snap-align: start; }
  .department-symbol,.department-symbol .bidu-department-icon { width: 48px; height: 48px; }
  .department-item>span:nth-child(2) { overflow-wrap: anywhere; }
  .department-item:focus-visible { outline-offset: -3px; }
  .section-heading>a { min-height: 44px; font-size: 13px; align-items: center; justify-content: flex-end; flex-shrink: 0; max-width: 40%; white-space: normal; text-align: right; }
  .department-section .section-heading>a { min-height: 44px; font-size: 12px; align-items: center; }
  .woocommerce ul.products li.product .bidu-product-detail { min-height: 44px; }
  .catalog-layout>.woocommerce-products-header { margin-bottom: 20px; }
  .catalog-sidebar { margin-bottom: 18px; }
  .filter-panel { padding: 6px 14px; }
  .filter-panel summary { min-height: 44px; font-size: 16px; }
  .filter-panel label { font-size: 14px; }
  .filter-panel select { min-height: 48px; padding: 10px; font-size: 16px; }
  .woocommerce .filter-panel .button { min-height: 48px; font-size: 16px; }
  .clear-filters { display: flex; align-items: center; justify-content: center; min-height: 44px; font-size: 14px; }
  .filter-hint { font-size: 12px; }
  .woocommerce .woocommerce-result-count { float: none; max-width: none; font-size: 12px; margin: 0 0 10px; }
  .woocommerce .woocommerce-ordering { float: none; width: 100%; max-width: none; margin: 0 0 20px; }
  .woocommerce .woocommerce-ordering select { width: 100%; min-height: 48px; font-size: 16px; padding: 10px; }
  .woocommerce nav.woocommerce-pagination ul li a,.woocommerce nav.woocommerce-pagination ul li span { min-width: 44px; width: auto; height: 44px; padding: 6px; }
  .bidu-catalog-reset { min-height: 44px; font-size: 14px; }
  .woocommerce form.login input.input-text,.woocommerce form.register input.input-text,.woocommerce form.lost_reset_password input.input-text { min-height: 48px; font-size: 16px; }
  .woocommerce form .password-input input.input-text { padding-inline-end: 52px; }
  .woocommerce form .password-input .show-password-input { top: 2px; right: 2px; width: 44px; height: 44px; padding: 10px; display: flex; align-items: center; justify-content: center; }
  .woocommerce form .password-input .show-password-input::after { margin: 0; }
}
