WARNING: The following article contains spoilers for Season 6, Episode 7 of The 100, "Nevermind," which premiered Tuesday on The CW.

One of the biggest twists in Season 6 of The 100 is that the spirit of Josephine, a deceased Prime and member of the ruling class of the alien world Sanctum,  is possessing the body of Clarke Griffin. After learning of Clarke's fate, her friends and allies wrote her off as dead, and entered a tenuous alliance with the Primes for peaceful coexistence on the planet. However, the previous episode concluded with the bombshell cliffhanger that Clarke's psyche had survived somewhere buried deep within her body's mind, a revelation that predominantly dominates the latest episode of The CW post-apocalyptic series.

RELATED: The 100: War Is Coming for Sanctum

Taking place almost entirely within the confines of her mind, Clarke's subconsciousness walks through the history of the series, encountering familiar faces and settings while changing her attire and overall appearance to match each of the time periods, recognizable to longtime fans. However, a conversation with the malevolent artificial intelligence program A.L.I.E. from seasons past reveals that Clarke's psyche survived due to the intact cybernetic implant embedded and active in the back of Clarke's neck, her mind and memories stored into the chip.

A.L.I.E. reminds Clarke that she had freed her mother and Raven from the A.I.'s control through the use of an electromagnetic pulse and then surgically removing the inert chip, but that the chip within Clarke was never subjected to the same procedure. Despite their antagonistic history, in a surprisingly prescient and reconciliatory move, A.L.I.E. suggests hiding the memory of the chip and the process to destroy it further within the recesses of Clarke's mind should someone attempt to discover how to completely purge Clarke's mind from her own body.

The 100 -- Nevermind

Almost on cue, Josephine -- in her original body -- projects her psyche into Clarke's mindspace and the two begin battling for control. Sensing Clarke is hiding a crucial memory from her, Josephine reveals that if Clarke dies in the mindspace, her consciousness similarly dies for good and, with Josephine able to resurrect herself endlessly as long as she's asleep, the resulting confrontation feels like an effective riff on Nightmare on Elm Street with the surreal confrontation entirely within the confines of one's own mind.

RELATED: The 100: Richard Harmon Talks Murphy's Surprising Season 6 Arc

In the end, Clarke capitulates to Josephine when their neverending battle revisits the site where Clarke had killed her boyfriend Finn, a murder in Season 2 that continues to haunt her years later. After learning that her best friend Bellamy had cut a deal with the Primes to prevent further bloodshed, Clarke surrenders the memory of the EMP to Josephine, seemingly ending the fight for good until one last familiar face in the late Monty Green reminds her never to give up.

To regain control of her own body, Clarke turns the tables and sneaks into Josephine's mind, learning of the invading psyche's own deepest regrets and fears from her memories. With Josephine awake and armed with the knowledge of how to purge Clarke's subconscious for good, Clarke manages to gain subtle control of her body and use Morse Code to signal to Bellamy that she's still alive.

RELATED: The 100: [SPOILER]'s Betrayal Is a Bid for Peace

Knowing that his friend isn't as dead as he believed, both Bellamy and Clarke will have to race against Josephine and the Primes if they want to ensure that Clarke's survival is permanent.

The 100 airs on The CW Tuesdays at 9 pm ET/PT. The series stars Eliza Taylor, Paige Turco, Marie Avgeropoulos, Bob Morley, Henry Ian Cusick, Lindsey Morgan, Richard Harmon and Tasya Teles.