Optimise galleries on mobile and tablets

* Remove unnecessary hacks for galleries
* Apply a hack that is mobile specific to improve rendering on browsers
that support media queries and are less than half the tablet viewport width

Bug: 70684
Change-Id: I6b56a0f6f041aa629c01c3f858862b747808c483
Merge "Optimise galleries on mobile and tablets"