Men can wear anything except short pants.
They can wear ties and t-shirts.(is accepted , no problem)
Women must obey Islamic dress-code and hijab in Iran however it is not very strict for tourists. You are free to wear clothes in light colors or any color you like. Hair should be covered.it is usual If part of the hair is out of the cover. Wearing scarf or shawl is common. covering Body by loose clothes is essential . Feet can be bare while Arms and legs shall be covered.
Only at the holy shrines wearing chador is needed and it will be given at the entrance.