Custom CSS should always be added after main CSS.

Also fix issue with "undefined" IDs.