Code to switch from jQuery UI tabs to accordion and back - responsive.