refactored, new layout, removed functions