Kegley scores 31 in loss at Madonna