I just installed and re-installed IntelliJ. Every Java file is coming up RED. I checked the JDK; it is at 1.6.##. The maven clean install build worked just fine
If you're still getting this error, even after you've tried all the other suggestions on this question, you have checked all your JDK, Maven settings, invalidated cache, synchronized your workspace and restarted, but things still aren't working for you, then go to your project directory and delete the entire .idea folder. Restart your IntelliJ; all the files under .idea will be created freshly which reflects the current situation.
At least, this worked for me.