RIXS Shows Why Li-rich Batteries Fade