Refactor static pages with layout