Added some css for pagination
Extracted pagination to partial template
Removed some redundant code from papers view
Dynamically add 'active' class on links