Catalyzes the conversion of sedoheptulose 7-phosphate to demethyl-4-deoxygadusol (DDG) (PubMed:20813918, PubMed:22741921). Involved in the synthesis of the mycosporine-like amino acid shinorine, a natural sunscreen compound that protects the cell against UV radiation (PubMed:20813918). D-sedoheptulose 7-phosphate = (R)-demethyl-4-deoxygadusol + H(+) + H2O + phosphate kcat is 5.0 min(-1). Belongs to the sugar phosphate cyclases superfamily. DDGS family.