Yosemite gray screen no startup keys working
Disconnect everything from the Mac and then power it off.

Perform recovery according to these steps.


http://support.apple.com/en-us/HT4718


If that fails, then you may need support from Apple to determine the version of OS X that shipped with the Mac so you can restore that and start over/restore from a backup once the hardware is known to work. Or it needs a repair for hardware issues.