Creation of main page and subpages laypout