who ruled india before mughals