You probably started writing in a text document instead of a script document. A text document is unformatted, much like a new file in a regular word processor.
If you go to the Production menu and everything's grayed out, then you're in a text document.
Go to File > Export. Save the file as a text only file, and then open the text file up (File > Open). You'll be prompted to open as a Text or Script document. Choose Script.