/* ─────────────────────────────────────────────────────────────────────────
   Responsive overrides for the builder export (MotoMetrics redesign, Dec 2026).

   Pages use inline styles with no breakpoints, so the breakpoints live here
   and win with !important. Hooks for the new design are the mm-* classes on
   the pages; the generic grid rule still collapses any other inline grid.

   NOTE: re-add the <link rel="stylesheet" href="responsive.css"> to every
   page <head> after a builder re-export (see README post-export checklist).
   brand.css is linked from each page's <helmet> and travels with the export.
   ───────────────────────────────────────────────────────────────────────── */

/* Tablet: two-column splits stack, text first, product frame second */
@media (max-width: 960px) {
  .mm-split { grid-template-columns: minmax(0, 1fr) !important; gap: 48px !important; }
  .mm-split > .mm-split-media { order: 2 !important; }
}

@media (max-width: 760px) {
  /* Collapse every inline grid to one column. Matches the source style string
     ("display:grid") and the runtime's re-serialized form ("display: grid"). */
  [style*="display:grid"],
  [style*="display: grid"] { grid-template-columns: minmax(0, 1fr) !important; }

  /* Grid columns default to min-width:auto, so a wide child (the embedded _ds
     product widgets) would push the column past the viewport. */
  [style*="display:grid"] > *,
  [style*="display: grid"] > * { min-width: 0 !important; }

  h1 { font-size: clamp(40px, 11.5vw, 56px) !important; line-height: 1 !important; }
  h2 { font-size: clamp(30px, 8vw, 40px) !important; line-height: 1.06 !important; }

  .mm-wrap { padding-left: 20px !important; padding-right: 20px !important; }
  .mm-section { padding-top: 80px !important; padding-bottom: 80px !important; }
  .mm-card { padding: 24px !important; }

  /* Nav keeps the logo and Book a demo; the rest is reachable from the footer */
  .mm-nav { padding-left: 20px !important; padding-right: 20px !important; }
  .mm-nav-links,
  .mm-nav-signin { display: none !important; }

  /* Home hero: shorter data field, product frame still starts below the core */
  .mm-hero { padding-top: 64px !important; }
  .mm-hero-field { height: 300px !important; }
  .mm-hero-stage { margin-top: -96px !important; }
}
