Refactoring the structure and theme