Are there any files which are NOT restored from a Time Machine backup but taken from the recovery partition? I'll get a replacement Mac soon, so I'll have to restore from a backup. Apart from the home directory and the applications, does Time Machine also backup the usually hidden Unix folders like /etc, /usr and so on? 

I've got a few programs and config files in there and I'd like my new Mac to be in exactly the same state as the current one, in terms of software. Can I rely on Time Machine to backup/restore everything without exception, or would I have to use something like Carbon Copy Cloner instead?
As long as you haven't excluded something manually from the backup it will backup everything, except some cache and log files.
I do also have custom programs in /opt, /usr/bin,... and everything still worked after restoring the system from my Time Machine backup.

There is a good collection of Time Machine FAQ on the web you may like to consult.