Kazakhstan elects new leader as hundreds arrested in protests