refactor background