Garments mentioned in the Quran are for covering the ‘awrah and for adornment
Question

Are the garments mentioned in the Holy Quran, in Soorat al-A‘raaf, garments to cover the ‘awrah or garments for beauty and adornment?
Praise be to Allah.Allah, may He be exalted, says (interpretation of the meaning):
“O children of Adam, We have bestowed upon you clothing to conceal your private parts and as adornment. But the clothing of righteousness - that is best. That is from the signs of Allah that perhaps they will remember.
O children of Adam, let not Satan tempt you as he removed your parents from Paradise, stripping them of their clothing to show them their private parts. Indeed, he sees you, he and his tribe, from where you do not see them. Indeed, We have made the devils allies to those who do not believe”
[al-A‘raaf 7:26-27].
The garments or clothing mentioned in these verses include garments that cover the ‘awrah, as well as fine garments that are used for the purpose of adornment and beautification.
In this verse, Allah, may He be glorified, says: “O children of Adam, We have bestowed upon you” by Our utmost grace, clothing to cover your ‘awrah, and other, fine, clothing to adorn and beautify yourselves for one another.
And the garment of fear of Allah (righteousness) is better for you than any other garment, because it protects you from the punishment of Allah.
That which We have bestowed upon the children of Adam – of whatever type it is – is one of the signs of Allah that bears witness to His might, His grace and His mercy, so that they might pay heed and refrain from disobeying Him.
The call to the children of Adam is repeated, because of the importance of the advice and of those to whom the advice is addressed.
What is meant is: O children of Adam, do not let the Shaytaan cause you to fall into trials and tribulations by means of his whispers which make that which is ugly seem beautiful, and make that which is beautiful seem ugly, as a result of which you will be deprived of Paradise and admitted to Hell. So beware lest he tempt you with his whispers and you will be punished as a result…
… as he tempted your parents, Adam and Hawwa’, and caused them to be sent out of Paradise because of their following him, after he caused them to be stripped of their clothing so that they would see one another’s private parts.
Uncovering of ‘awrahs (private parts) is something shameful for human beings, and undermines their humanity and dignity.
“Indeed, he sees you, he and his tribe, from where you do not see them”. The tribe is the group, and what is meant by the tribe of Iblees is his troops among the jinn. This sentence gives the reason for the prohibition on being tempted by the Shaytaan, and emphasizes the warning against him. For if the enemy is able to reach you from where you do not see him, it is worth your while to be extra cautious about him, for the Shaytaan flows through the son of Adam like blood, so beware of his hidden plots and the plots of his tribe, so that you will not fall into their traps.
“Indeed, We have made the devils allies to those who do not believe”: We have made the devils leaders of those who do not believe in Allah and His Messenger, and they take it upon themselves to tempt them and mislead them, because of their determination not to follow their reasoning and to corrupt the sound nature with which their Lord created them.
End quote from at-Tafseer al-Waseet (3/1402).
As-Sa‘di said in at-Tafseer (285):
When Allah sent Adam, his wife and their descendents down to the earth, He told them how their stay on earth would be, and that He had ordained that they should live a life there that was to be followed by death, a life that would be filled with trials and tests; they would stay there, and messengers would be sent to them and books would be revealed, until death came to them, whereupon they would be buried in the earth. Then after that would come the resurrection, when Allah would raise them up and bring them forth from the earth to the real, eternal realm.
Then He reminded them of what He had made available to them of clothing that is essential and clothing that is worn for the purpose of beautification. The same applies to all things, such as food, drink, mounts, spouses and so on. Allah has made available to His slaves that which is essential and more. He explains that this is not to be pursued for its own sake; rather Allah has sent it down to help them to worship and obey Him. Hence He says: “But the clothing of righteousness - that is best”. That is, better than physical clothing, for the garment of piety lasts and does not wear out or vanish; it is the beauty of the heart and soul.
As for outward clothing, its purpose is to cover the ‘awrah sometimes, or to be an adornment for the wearer, and it has no other benefit beyond that.
Moreover, if a person cannot obtain this clothing, all that results from that is the uncovering of his ‘awrah, which does not harm him if he cannot help it. But if there is no garment of piety, then his inner ‘awrah becomes uncovered, which results in disgrace and shame.
“That is from the signs of Allah that perhaps they will remember”} that is, what is mentioned concerning clothing is so that you may be reminded of that which benefits you or harms you, by way of an analogy between outward garments and the inner garment of piety.
And Allah, may He be exalted, says, warning the children of Adam lest the Shaytaan do to them what he did to their parents:
“O children of Adam, let not Satan tempt you” by making sin fair-seeming to you and calling you to it and encouraging you to commit it, lest you give in to him
“as he removed your parents from Paradise” and brought them down from a high status to a lower one. He wants to do the same to you, and he will spare no effort to tempt you if he can. So you must be mindful and take precautions, equip yourselves so that you will be ready to combat him, and do not be heedless of situations where he may ambush you.
For he is constantly watching you, and “he sees you, he and his tribe, from where you do not see them. Indeed, We have made the devils allies to those who do not believe”, for lack of faith inevitably leads to the formation of alliances between man and the Shaytaan. “Indeed, there is for him no authority over those who have believed and rely upon their Lord. His authority is only over those who take him as an ally and those who through him associate others with Allah” [an-Nahl 16:99-100].
And Allah knows best.