I had a rough patch for the last couple of months due to a toxic boss whose technical incompetence, manipulative and narcissistic attitude was affecting my motivation and efficiency at work. I approached my manager for help, someone whom I'm trusted completely and confided everything. We shared great rapport and relationship at work. However her efforts to understand the situation and effectively address it failed miserably due to her limited technical experience in that domain and lack of managerial experience. My boss is a narcissistic person and expert at manipulating the situation with words. She was unable to see through the vague, confusing and useless BS peddled by my boss in the meetings. There was no substance and value to what he was saying, yet she couldn't see through it.

Very soon the gas lighting started and my manager began siding with my boss, corner me in the meetings and treat me as if I'm incompetent. She was trying to save her own skin and hide her ineffeciency to understand and address the issue. She started treating me differently, started ignoring me and eventually fired me recently after two agonizing months of workplace bullying when the company I worked for announced staff reduction due to weak business.

I was delighted to leave that toxic boss and team which was causing me soo much anxiety and stress, but the betrayal of my manager is something that's bothering me soo much. I trusted her completely, thought she would genuinely help me but she too turned out to be opportunistic as well. She made me trust her, gave me the confidence to confide everything to her and betrayed me at the right moment so that she can look good to her superiors. She spun a narrative to the management and to me as well that I'm not a good fit, as the discovery of truth would have exposed her incompetence as well. I feel more pained by her breach of trust and confidence, than from losing the job.  I feel very embarrassed for being fooled into trusting her, and for being very honest and dedicated at work. Any advice to how to let go, move past the thoughts of betrayal and shame?