Indent with tabs, align with spaces: this is what smart-indent helps you with.
Whenever you press Enter, smart-indent will make sure the new line will match the indentation and alignment of the previous line.
The above shows HTML and JS examples, but it should work with any file type.