added portal sass functions, various theme cms fixes according to spreadsheet