Try bringing up the Force Quit window from the Apple menu (or with Command-Option-Esc on the keyboard). Is this where you tried to force quit Mail before? If Mail is listed, select it and try a Force Quit.
If the Mac does not shut down because it is stalled during the log out process, press and hold down the Power Button to force a shutdown. Then press and release to start up again.