App structure refactor