All problems with changing CSS will only happen when using automated processes.
calibre
conversions are the main offender -- as an end-use program it wil flatten
all CSS for normalizing, carefully nuking all semantic meaning... as it is designed to do.
Sigil will auto-clean sometimes, when it feels uncomfortable with the code. When opening a text file, and when switching to/from Book View, it will Tidy your files. Tidy is overeager, it also hates b/i tags.
calibre
editor will only do so when using the Beautify or Fix HTML buttons, and it is advisable to use Check Book instead of Fix, and before Beautify. Nevertheless, only the actions crucial to parsing the book as valid (X)HTML+CSS will be taken. Your styles will NEVER be renamed.