Once, a manga editor saw a note one of his creators had written that said "Grudge vs Ring was a cool movie", and he essentially said "go off on that". That's how we got DanDaDan.
A mangaka wanted to make a horror battle manga. Since there was already a lot of fighting manga, he decided to focus on competitive games instead. That's how we got Yu-Gi-Oh.
A mangaka wanted to make a death game series, but there was a gap in the market for casual romcoms instead. He then merged the two ideas together and had two tsunderes in mind games for romantic affection. That's how we got Kaguya-Sama.
There is no method to making good ideas. It's blind luck, flexibility and creativity, coupled with skill in executing whatever slapdash ideas you have.