No, ramayana and mahabharata are mythical stories but Bhagavad-Gita is a religious guide book that promotes casteism, patriarchy and pretty other shitty and outdated beliefs.
Bhagavad Gita: Chapter 9, Verse 32 मां हि पार्थ व्यपाश्रित्य येऽपि स्यु: पापयोनय: | स्त्रियो वैश्यास्तथा शूद्रास्तेऽपि यान्ति परां गतिम् || 32||
Translation: All those who take refuge in Me, even those of lower birth like Women, shudras, whom society scorns, will attain the supreme destination.
( The gita website has altered it's meaning to "regardless of caste, gender, race, language" to make it less bigoted , despite the original translation mentioning " pāpa yonayaḥ—of low birth; striyaḥ—women" right in the same page).
https://www.holy-bhagavad-gita.org/chapter/9/verse/32#
There's a huge difference between stories of some heroic mythical figures and religious scriptures/ Krishna directly promoting casteism and calling women and some castes as "lower birth".
There are countless such bigoted verses in bhagwad that condones that varna system and patriarchy.