/* Dedicated small-screen layout. Desktop rules remain untouched. */
@media (max-width: 979px) {
  html, body { min-width: 0 !important; width: 100% !important; }
  body { --site-width: 100%; --scrollbar-width: 0px; }
  #SITE_CONTAINER, #main_MF, #site-root, #masterPage, #PAGES_CONTAINER,
  #SITE_PAGES, #SITE_PAGES_TRANSITION_GROUP, main .wH18kY, main .JJb9Mt,
  main .wixui-page, main .theme-vars {
    min-width: 0 !important; width: 100% !important; max-width: 100%;
  }
  #SITE_HEADER { height: 92px !important; min-height: 92px !important; }
  .header-inner { height: 88px; padding: 12px 20px; gap: 12px; }
  .header-inner > a { flex: 0 1 250px; min-width: 0; }
  .header-inner > a img { width: 100%; height: auto; max-height: 64px; object-fit: contain; object-position: left; }
  .menu-toggle { flex: 0 0 74px; width: 74px; height: 48px; transform: none; }
  #site-menu { inset: 0; padding: 100px 24px 32px; gap: 4px; height: 100%; height: 100dvh; overscroll-behavior: contain; }
  #site-menu a { font-size: clamp(22px, 5vw, 32px); line-height: 1.25; padding: 12px 0; max-width: 100%; overflow-wrap: anywhere; flex-shrink: 0; }
  .menu-close { top: 24px; right: 22px; width: 44px; height: 44px; }
  [id^=comp-] { scroll-margin-top: 110px; }

  /* Remove desktop positioning from layout nodes, never from image contents. */
  main section, main .wixui-column-strip, main .wixui-column,
  main [data-mesh-id], main [id^=comp-] {
    min-width: 0 !important; max-width: 100%; left: auto !important;
    right: auto !important; margin-left: 0 !important; box-sizing: border-box;
  }
  main section, main .wixui-column, main [data-mesh-id] { width: 100% !important; }
  main section, main .wixui-column { height: auto !important; }
  main .mobile-stack {
    display: flex !important; flex-direction: column; gap: 16px;
    min-height: 0 !important; height: auto !important; padding: 0;
  }
  main .mobile-stack > * {
    position: relative !important; grid-area: auto !important; align-self: auto !important;
    margin: 0 !important; inset: auto !important; width: auto !important;
    min-width: 0 !important; height: auto !important;
  }
  main .mobile-stack > [data-mesh-id*="-wedge-"] { display: none !important; }
  main .mobile-outer { gap: 0; }
  main [data-testid=richTextElement] { width: 100% !important; height: auto !important; overflow-wrap: anywhere; }
  main [data-testid=richTextElement] :is(h1,h1 span) { font-size: clamp(32px, 6vw, 44px) !important; line-height: 1.13 !important; }
  main [data-testid=richTextElement] :is(h2,h2 span) { font-size: clamp(28px, 5vw, 36px) !important; line-height: 1.18 !important; }
  main [data-testid=richTextElement] :is(h5,h5 span) { font-size: clamp(19px, 3.5vw, 25px) !important; line-height: 1.45 !important; }
  main [data-testid=richTextElement] :is(p,p span,li,li span) { font-size: 17px !important; line-height: 1.5 !important; }
  main [data-testid=richTextElement] p[style*="margin-left"] { margin-left: 16px !important; }
  main .mobile-page-grid {
    display: grid !important; grid-template-columns: repeat(2,minmax(0,1fr));
    column-gap: 20px; row-gap: 26px; padding: 0 24px 44px;
  }
  main .mobile-page-grid > * { grid-column: 1 / -1 !important; }
  main .mobile-page-grid > .mobile-icon-card { grid-column: auto !important; }
  main .mobile-page-grid > [data-testid=richTextElement] { margin-top: 24px !important; margin-bottom: 6px !important; }
  main .mobile-page-grid > section { width: calc(100% + 48px) !important; max-width: none; margin-left: -24px !important; }
  main .mobile-hero { position: relative; padding: 44px 24px 48px; gap: 24px; isolation: isolate; }
  main .mobile-hero > :is(.wixui-image,[data-mesh-id$="-rotated-wrapper"]) { position: absolute !important; width: 100% !important; height: 160px !important; top: 70px !important; left: 0 !important; opacity: .2; z-index: 0; pointer-events: none; }
  main .mobile-hero > [data-testid=richTextElement] { z-index: 1; }
  main .mobile-hero [data-mesh-id$="-rotated-wrapper"] > * { width: 100% !important; height: 160px !important; transform: none !important; }
  main .mobile-hero img { width: 100%; height: 160px; object-fit: cover !important; }
  main .mobile-band { padding: 44px 24px; background: #ff7c1e; }
  main .mobile-band .mobile-outer { gap: 32px; }
  main .mobile-band > div > div > .mobile-stack { gap: 28px; }
  main .mobile-icon-layout { align-items: center; gap: 14px; padding: 12px 0 8px; }
  main .mobile-icon-layout > .wixui-image { width: 44px !important; height: 44px !important; flex: 0 0 44px; max-width: 44px; }
  main .mobile-icon-layout img { width: 44px !important; height: 44px !important; }
  main .mobile-icon-layout [data-testid=richTextElement] :is(p,p span) { font-size: 16px !important; line-height: 1.4 !important; }
  main .mobile-bullet { display: grid !important; grid-template-columns: 24px minmax(0,1fr); gap: 6px 12px; }
  main .mobile-bullet > * { grid-column: 2 !important; }
  main .mobile-bullet > :first-child { grid-column: 1 !important; grid-row: 1 / span 2 !important; width: 24px !important; height: 32px !important; align-self: start !important; }
  main .mobile-bullet svg { display: block; width: 24px; height: 32px; }
  main .mobile-bullet > :first-child > .wixui-vector-image { width: 24px !important; height: 32px !important; }
  main [aria-label=ABOUT], main [aria-label=SERVICES], main [aria-label=TECHNOLOGIES], main [aria-label=CLIENTS], main [aria-label=CONTACT] { display: none; }
  main #comp-mdym40j6, main .pro-gallery-parent-container, main .pro-gallery, main .pro-gallery-inline-styles { width: 100% !important; height: auto !important; min-height: 0 !important; }
  .client-gallery { width: 100%; height: auto; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px 18px; }
  .client-gallery img { width: 100%; min-width: 0; height: 110px; }
  #SITE_FOOTER { min-width: 0 !important; width: 100%; }
  #SITE_FOOTER [data-mesh-id$=gridContainer] { display: flex !important; flex-direction: column; gap: 8px; padding: 24px; align-items: center; box-sizing: border-box; width: 100%; }
  #SITE_FOOTER [data-mesh-id$=gridContainer] > * { position: static !important; margin: 0 !important; width: auto !important; height: auto !important; }
  #SITE_FOOTER a { display: inline-block; padding: 12px 4px; }
  #SITE_FOOTER p { text-align: center !important; }
  /* Smaller motion amplitudes keep the icons within their cards. */
  #comp-metz99a1 { --motion-bounce-factor: .22 !important; }
  :is(#comp-metz89bl,#comp-metz904w) { --motion-wiggle-factor: .5 !important; --motion-translate-y-18: -5px !important; }
}
@media (min-width: 600px) and (max-width: 979px) {
  main .mobile-page-grid { grid-template-columns: repeat(4,minmax(0,1fr)); }
  .client-gallery { grid-template-columns: repeat(3,minmax(0,1fr)); }
  main .mobile-band, main .mobile-hero { padding-left: 40px; padding-right: 40px; }
}
@media (max-width: 359px) {
  .header-inner { padding-left: 14px; padding-right: 14px; gap: 8px; }
  main .mobile-page-grid { column-gap: 14px; padding-left: 18px; padding-right: 18px; }
  main .mobile-page-grid > section { width: calc(100% + 36px) !important; margin-left: -18px !important; }
  main .mobile-band, main .mobile-hero { padding-left: 18px; padding-right: 18px; }
}
@media (max-width: 979px) and (max-height: 500px) {
  #SITE_HEADER { position: relative !important; }
  #site-menu { padding-top: 72px; }
  #site-menu a { padding-top: 8px; padding-bottom: 8px; }
}
