design rework, minor bug fixes