In the famous "quasi-static" isothermal process, total entropy of the system (the gas) is unchanged when the system returns to the original state. In a single isothermal event (one compression or one expansion)
heat must flow since work is done and
internal energy remains constant. If heat flows, then entropy changes (

).
The "grains of sand" isothermal process is reversible, meaning you can add one grain at a time, the gas will compress, work is done one the gas,heat will flow out, entropy of system and universe will both change; then you can reverse the process: remove one grain at a time, work is done by the gas, heat flows into the gas, entropy of system and universe return to its previous state.
So one "event" is not in it self a reversible process, but rather some processes can be reversed.
Again, not in the real world: the grains of sand would have to be stored at the height at which they are put on/taken off, otherwise outside work would be necessary; furthermore, perfect frictionless machines would be required to move the grains from their storage potisions to the piston. Nothing is truly reversible: another restatement of the 2nd Law.