Out of status doesn't mean an automatic 3 or 10 year bar anymore. You are not accruing unlawful presence until a judge or immigration agency says so. In 2020, a court issued a permanent injunction (https://www.uscis.gov/sites/default/files/document/injunctions/Guilford-College-v.-Nielsen-summary-judgment-permanent-injunction.pdf) against the 2018 rule, instructing the USCIS to go back to the 2009 Guidance (https://www.uscis.gov/sites/default/files/document/memos/revision_redesign_AFM.PDF).
However, we heard from a lawyer that if you are out of status and go back, you still risk not being able to get back to the US because the issuance of a visa is at the discretion of the embassy.