added sorting functionality
css looks almost like original