bugfixes and styling fixes