styling fixes, cleaned global namespace