/* ZD GROUP - responsive overrides, loaded last (after the theme CSS).
   Added after rendering the site in headless Edge at 390x844 / 1440x900:
   the sub-nav bar, the About image row and the contact card all clipped on the
   right because of hard-coded widths and flex items that could not shrink. */

@media (max-width: 991px) {
  html, body { overflow-x: hidden; }
  img { max-width: 100%; height: auto; }

  /* sub-navigation bars wrap instead of running off the right edge */
  .n-nav { display: flex; flex-wrap: wrap; justify-content: center; }
  .n-nav a { margin: 4px 6px; }

  /* the top-bar menu block is a fixed 400px wide - let it shrink */
  .pcNav_u1_2R { width: auto; max-width: 100%; }

  /* flex rows: allow children to shrink, otherwise long text cannot wrap */
  .n-con .list .item,
  .n-con .list .item > div,
  .n-con .item > div { min-width: 0; }

  .n-con p, .f-top p { white-space: normal !important; }

  /* fixed-height flex groups stack */
  .n-about .con3 .g_w2 { flex-wrap: wrap; }
  .g_w2 { padding-left: 15px; padding-right: 15px; }

  /* long copy must wrap rather than bleed out of the viewport */
  .f-top p, .n-con p, .i_contact_a em, .i_contact_a span, .n-con {
    word-break: break-word; overflow-wrap: anywhere;
  }

  .pcNav-l img, .logo img { max-height: 44px; height: auto; width: auto; }
  .mynavBody h3 img { max-height: 40px; height: auto; width: auto; }
}

@media (max-width: 767px) {
  .f-top p, .n-con p { font-size: 13px; line-height: 1.7; }
  .i_contact_a em, .i_contact_a span { font-size: 12px; }
  table { display: block; overflow-x: auto; max-width: 100%; }
  .i_ban_con h1, .i_ban_con h2, .i_ban_con .tit { font-size: 30px; line-height: 1.35; }
  .n-nav a { font-size: 13px; padding: 6px 10px; }

  /* About page: the picture row is built from 700px-wide images side by side */
  .n-about .con2-img { display: block; }
  .n-about .con2-img img,
  .n-about .con1-b img,
  .n-about .con1-top img { width: 100% !important; max-width: 100% !important; height: auto !important; }
  .n-about .con1-b .text,
  .n-about .con3 .con-r { width: 100% !important; max-width: 100% !important; }

  /* form / dialog blocks that were wider than a phone */
  .i-pro-info, .product-d-form-l, .product-d-form-item textarea, .modal-dialog { width: 100% !important; max-width: 100% !important; }

  .pcNav-l img, .logo img { max-height: 40px; }
}
