President Hassan Rouhani, who came to office in 2013 partly on the votes of young, middle-class women, knows that in the summer, hundreds or even thousands will be arrested by the morality police for “bad hijab”, a slack interpretation of the official dress code requiring women to cover their hair and figure even as temperatures push 40 degrees.