fix up layout issues. simplify height/width calc