Custom CSS different on dekstop and mobile

First, the second screenshot seems the “desktop view” on mobile to me.
Second, I’m not sure what code are you using but yes, CSS classes on mobile may be different from desktop.