Refactored Levels.js