File for FMLA/ADA accommodations. You need to qualify for FMLA, but there is no minimum hours needed to file for protection under the ADA. Don’t “work it out with your manager”. Go straight to HR and file for the accommodation. Be generous with yourself. Make sure in the paperwork you file for unspecified time/days off.
Then, when you feel crappy and need to leave early or call in, email your supervisor and make sure you say “I’m taking FMLA time” or “I’m taking an FMLA day.” Or “protected time” or whatever. BCC yourself on these emails
Then if and when they try to fire you for excessive absences, you have plenty of documentation that your time off was federally protected time. You will get money out of it, I promise. Might not be millions, or hundreds of thousands, but it’ll be some money.