refactor shadow overlay