While not usually applied to everyday white collar workers, you seem to be hinting at what is called "moral injury"
Typically associated with the military and with healthcare professionals who go into their fields with good intentions, but then have to sacrifice on those for various (typically capitalistic or even arbitrary) reasons.