Troian Bellisario, Keegan Allen Troian Bellisario, Keegan Allen

Pretty Little Liars is getting dark — well, darker than usual — for a special black-and-white, noir-inspired episode.

After the stunning revelation that Ezra Fitz (Ian Harding) is the man in Alison's journal, a pill-popping Spencer (Troian Bellisario) spirals into a dream-like state where she, her friends and her enemies are transported to a 1940s crime-solving flick. From the hair, makeup, wardrobe and vernacular to the personality and even social issues, the episode's writer and director Joseph Dougherty was tasked with making the episode accurate, interesting, beautiful and most importantly for the fans, plot-advancing.

First Look: Pretty Little Liars goes Noir

"When we knew we were going to do this, one of the big issues we discussed was how free-standing can it be?"  Dougherty tells "We didn't want to do an episode and at the end of it you hadn't moved the story forward. So the idea was to actually take the experience Spencer was having as the thing that allowed her to put together the puzzle piece and that allowed her to go to the next step. So the black-and-white part of her brain allows her to figure out an essential clue."

Which shows have jumped the shark?

To create the look, Dougherty says modern technology was on their side.

"We had to make color choices that looked good when turned into gray," he says. "Larry [Reibman], our director of photography, lit the show in a very different way with a lot more shadows, although we've always been a shadowy show — that's why ABC Family asked us to do this. We also had an advantage over the people who made film noir [back then] in that we have digital cameras, so there's a video feed and we were able to turn the video feed into black and white, so we were seeing the real images as we were shooting."

Watch an exclusive sneak peek of the episode below:

Pretty Little Liars airs on Tuesdays at 8/7c on ABC Family. Check back after the episode airs for our postmortem with Dougherty!