improve UI to work properly with the sidebar and on mobile devices