A new kind of energy appears, and we call that ENTROPY with the symbol S.
S is not a positive form of energy, like heat or electricity that is helpfull for men.
No, the entropy is in fact a kind of negative energy, lost energy.
S is connected to disorder. Every system has a certain amount of disorder: the better organised the system, the less entropy is in it (like in cristals).
As soon as you dissolves such a cristal in water, the whole order gets lost. All ions of the cristal are loose, are freely swimming, the disorder of the system has increased: the entropy S increases.
All this on cost of the useful forms of energy; you cannot ignore this process. The entropy must be included, in one way or another, in the total amount of system energy.