Whitespace, comments and colour shortened
Input
/* card styles */
.card {
color : #aabbcc ;
margin : 0.5em ;
}Output
.card{color:#abc;margin:.5em}The comment and whitespace are gone, the hex shortened, and the leading zero dropped.
Minifying CSS removes everything a browser does not need: whitespace, comments, the final semicolon in each block, and redundant leading zeros. A few safe value optimisations are applied on top, such as shortening six-digit hex colours that can be written in three.
Every transformation here is one that cannot change rendering. More aggressive tools merge rules and reorder declarations, which is where minification occasionally breaks a stylesheet.
Each example below is executed against this tool by the test suite, so what you see is what the tool actually produces.
Input
/* card styles */
.card {
color : #aabbcc ;
margin : 0.5em ;
}Output
.card{color:#abc;margin:.5em}The comment and whitespace are gone, the hex shortened, and the leading zero dropped.
The details that decide whether a conversion is correct, and where information can be lost without any error being raised.