Baylor overcame a five-run deficit to secure a thrilling 9-7 win over Kansas, salvaging the final game of their road series.