Fixed code and improved styles