There’s one aspect about the energy use of warm water that this article glosses over: warm water is particularly easy to store. Heat is also a byproduct of many industrial processes- reusing and storing that heat or warming up your boiler at peak energy production time is an efficient way to make use of “waste” energy. This significantly reduces the effective energy usage of any warm water usage.
There’s also ways to efficiently turn electricity into heat - heat pumps for example. These “produce” around 3-4 joule of usable heat per joule of electric energy. Just using a heat pump instead of an electric heater cuts the mentioned energy costs to a quarter.