* Adjust galleries CSS to provide a larger thumbnail view where space is available
* General code cleanup and minor refactoring