(Courtesy Through the 4th Wall)

“A Dream Within a Dream” is one of the Capital Fringe Festival’s site-specific projects, and this visually smart, absorbing project unfolds over two floors of an empty building called the Union Stylus a few doors west of Fort Fringe. It’s a sort of haunted house and a scavenger hunt as a small audience of no more than 10 is guided from station to station, listening to lunatic ravings and hunting for clues about Edgar Allan Poe’s last wishes.

It’s billed as “immersive transmedia theater,” and during one of Friday night’s performances it got a little too immersive for one viewer. The audience member intervened, trying to stop an actor playing a demented man from burying a still-living woman behind a wall.

That’s a gloss on “The Cask of Amontillado,” and the hour-long experience makes references to lots of Poe — “The Raven,” “The Pit and the Pendulum” and more. But literature isn’t the hook. “Dream Within a Dream” is all about atmospherics — the actors in very good period costumes, weaving among the onlookers; the bobby on the stairwell who may pull you aside for a brief, intense interrogation, the spooky music and the terrific, surreal visual design.

The director-creators are Nasreen Alkhateeb, Jennifer Schwed and Doug Bradshaw, and their attention to detail is impressive. The cavernous spaces on both floors are dimly lighted to create an ominous hollow effect, yet each small gallery area — a writer’s den here, a dank cellar there — is meticulously rendered, sometimes with video projected on the walls.

You can lose the story amid all this mood; at times the melancholy rants really are incoherent. But you may not notice or care much, especially after the mystery is solved. The intensity of being nose to nose with the compelling performers playing Poe (Ian Rogers) and Poe’s wife (Bette Cassatt) — to name just two of the figures who artfully put their woe in your face — is immersive indeed.

“A Dream Within a Dream” will be performed 11 more times Wednesday through July 26. Visit capitalfringe.org.