Yume's sudden realization looks kinda random and all of sudden, but I think if we deepdive a bit, maybe it will make a bit more sense.
First thing to mention is that she doesn't seem angry or upset when she sees Sakura infront of her like she usually would.
That's probably because in Chapter 27 page 13, Yume says that the girls can befriend Sakura if they want, and that if they do they can still be friends with Yume. As she says: "I want to become a better person. I'm going to change. I won't act like that anymore.", implying that she softens up on Sakura a little bit, doesn't care about her that much anymore and just doesn't want to be reminded of her too much.. Looks like she's also saying that she also wants to stop being a controlling freak that tells her friends what to do and who to hate, but she still acts like one in Chapter 28 and 32 so... I guess she didn't try to change this part of her.💀
But anyway, that explains why she didn't look mad when seeing Sakura in front of her, and probably because of the complicated feelings she was experiencing at that moment. I mean, girlie almost died and then she sees her ex that she loves and hates the most, it's a lot to take in especially after their dialogue that happens next.
After Yume saw Sakura smiling at a random guy, she lived with the thought that Sakura betrayed her (just like she thought would happen in Chapter 26.5 page 13) and that for sure caused her to think that Sakura didn't kept the promise, but she gets proven wrong at page 14 this Chapter. Then she realizes that she was wrong, and that Sakura kept the promise although Yume bullied through all those years. She realizes that Sakura didn't "betray" her after all, and that she was the one who started all this, started making Sakura's life painful and forcing her to tolerate the pain although it hurts and she loves Yume.
When Sakura shows Yume the scar she left on her, she then remembers all the details of that day when she hurt Sakura for the first time. She remembers how she cried and felt bad for hurting Sakura, never wanting to do that and experiencing that feeling ever again. Well, she does hurt Sakura the whole manga but she doesn't feel bad when she does it anymore, because she was thinking it was "justified" and she "deserved" it since Sakura "betrayed" her (what she didn't), and when Yume realizes that Sakura didn't betray her, then she feels bad for Sakura and realizes her mistake.
She also didn't see Sakura crying in a very long time now, so that explains her words when she thinks that she never wanted to see Sakura sad (page 17 this Chapter) although in Chapter 34 she could be seen wanting to see Sakura like this. It's because the realization hit. Finally understanding what she had done and that reason why she suffers is her herself, and also her feelings like jealousy and possessiveness that she didn't work on and that escalated to this toxic level because of her.
After the hallucination ends, she now accepts the fact that she was seeing Sakura in Aoi the whole time (I wonder why dawg💀💀). She already knew it at Chapter 11 page 29, probably at Chapter 12 page 12 since this scene is really familiar to the scene when Sakura asked Yume to sit down with her and then just didn't say anything in chapter 10, at Chapter 18 page 32,33 and 34, at Chapter 19 page 9, 10 and 11 and at Chapter 19 page 18 (for those who don't want to look it's basically all the moments where Yume sees Sakura in Aoi/when Aoi reminds her of Sakura). Not sure if Chapter 26 page 24 and 25 count but just in case.
Yume understands that she has fallen in love with Aoi just because he resembles Sakura, and maybe that it's time to accept reality and her real feelings. Even if it was all just a hallucination, Yume still understood how much damage she has done to Sakura and that she actually doesn't know if Sakura kept her promise or not. So instead of assuming and miscommunicating, she goes to talk to her and apologize to her directly.
That'll be interesting because she won't be talking to Sakura but to Aoi since he's in her body... I just hope that they will return to their original bodies and face their problems instead of running away from them. Samamiya promised us a happy ending for this manga after all.