The source of all of Catherine's emotional problems is clearly set forth by Catherine herself in Ch.9 when she tells Nelly Dean,
My great miseries in this world have been Heathcliff's miseries, and I watched and felt each from the beginning: my great thought in living is himself. If all else perished, and he remained, I should still continue to be; and if all else remained, and he were annihilated, the universe would turn to a mighty stranger: I should not seem a part of it. - My love for Linton is like the foliage in the woods: time will change it, I'm well aware, as winter changes the trees. My love for Heathcliff resembles the eternal rocks beneath: a source of little visible delight, but necessary. Nelly, I AM Heathcliff! He's always, always in my mind: not as a pleasure, any more than I am always a pleasure to myself, but as my own being.
The elder Catherine is deeply and passionately attached to Heathcliff her brother by adoption, so there is no question of her ever getting married to him.
Her marriage to Edgar only makes her yearn for him all the more. So, it was only inevitable that soon there should be a climactic showdown in Ch.11 between Edgar and Heathcliff. The consequence of this confrontation was that Catherine decides to exasperate both Heathcliff and Linton by locking herself up in her room:
Well, if I cannot keep Heathcliff for my friend - if Edgar will be mean and jealous, I'll try to break their hearts by breaking my own. That will be a prompt way of finishing all, when I am pushed to extremity! [Ch.11]
In Ch.12 we learn that she's been in the room for almost five days:
How long is it since I shut myself in here?' she asked, suddenly reviving.
'It was Monday evening,' I [Nelly Dean] replied, 'and this is Thursday night, or rather Friday morning, at present.'
A little later, in the same chapter Nelly Dean informs Dr.Kenneth the family physician of Catherine's illness:
it commenced in a quarrel. She was struck during a tempest of passion with a kind of fit. That's her account, at least: for she flew off in the height of it, and locked herself up. Afterwards, she refused to eat, and now she alternately raves and remains in a half dream; knowing those about her, but having her mind filled with all sorts of strange ideas and illusions.'
Both Catherine's body and mind are in a state of limbo. She is unhappily trapped between Edgar and Heathcliff and doesn't know how to escape. To top it all, there's no one to whom she can can turn to for help or sympathy. Even in her delirious state her only thought is to be united with Heathcliff, and overcoming all attempts by Nelly Dean to prevent her from opening the window she opens it and leaning out into the frosty night she cries out:
But, Heathcliff, if I dare you now, will you venture? If you do, I'll keep you. I'll not lie there by myself: they may bury me twelve feet deep, and throw the church down over me, but I won't rest till you are with me. I never will!'
From being a normal, cheerful young lady Catherine has been transformed into a manic depressive because of her magnificent incestuous obsession - Heahtcliff.