updated styles and cleaned up code