where did the idea for kingdom hearts come from
It began with a discussion between Shinji Hashimoto and Hironobu Sakaguchi about "Super Mario 64".
Kingdom Hearts
The initial idea for "Kingdom Hearts" began with a discussion between Shinji Hashimoto and Hironobu Sakaguchi about "Super Mario 64". 
wiki:5919999
Kingdom Hearts [SEP] History
The initial idea for "Kingdom Hearts" began with a discussion between Shinji Hashimoto and Hironobu Sakaguchi about "Super Mario 64". They were planning to make a game with freedom of movement in three dimensions like "Super Mario 64" but lamented that only characters as popular as Disney's could rival a "Mario" game. Tetsuya Nomura, overhearing their conversation, volunteered to lead the project and the two producers agreed to let him direct. A chance meeting between Hashimoto and a Disney executive in an elevator—Square and Disney had previously worked in the same building in Japan—allowed Hashimoto to pitch the idea directly to Disney.