Government as a social contract and rule of law