NEFTA, Tunisia — The Dunes Electroniques dance festival opens to the mellow beats of one of Tunisia’s biggest up-and-coming DJs on a stage planted in the middle of the Sahara.

It is a surreal sight. The festival setting is cocooned by sand dunes, and the backstage area is the film set for the town of Mos Espa on the fictional planet of Tatooine.

The “Star Wars” films used southern Tunisia as their dusty backdrop, borrowing heavily from traditional Berber fashion and architecture. Of course, Mos Espa is a made-up name. Tunisians call the place where the festival is being held Ong Jemal (“neck of the camel”), near the villages of Nefta and Tozeur, which lie on the edge of the vast Chott el-Gharsa salt lake.

But some in the local crowd embrace the “Star Wars” theme, donning Darth Vader masks or sporting Princess Leia hair. Some dancers opt for selfie sticks to wave in the air; others brandish lightsabers.

At first glance, it could be a dance festival anywhere in the world, but it’s distinctively Tunisian. Hipsters from the capital dance alongside locals wearing traditional burnooses, the long brown wool cloaks well known to “Star Wars” fans, over their jeans. The clash of modern with the old at the unusual event strikes a chord with some of the cultural shifts, economic issues and political transitions that Tunisia is facing in tumultuous times.