But it’s not that what the setting Optimised charging it learns so the phone won’t sit at 100%
Optimised charging learns your charging routine to charge to 80%, and then top up to 100% just before you usually disconnect from power. Hence its not sitting at 100% for a long period of time, which damages the battery (as per my comment above).
However, the issue is you need to have a set charging routine for the system to 'learn' it. If you plug your phone in at different times the system wont learn your routine, and hence cannot apply optimised charging.
In addition, even if you have that set routine. the system needs to learn it first. So while its leaning it will just be charging to 100% and sit there all night, until it's learnt that's your routine and can apply optimised charging.
Either way, I simply charge as and when needed - up to anything between 80-100% and then remove it from charging. I never leave it plugged in overnight. Im not overly concerned enough to set it to 80% limit entirely. I just don't let it sit at 100% on charge for too long. Otherwise I want to get full use from my phone rather then worry about battery health all the time. All because you want to maintain the phone for someone else to use when you're the one that paid the full price for it.
Every time I have sold an iPhone in the past, I've very rarely been asked what the battery health is. Even if I am, I have found it doesn't hit resale value very much at all. Maybe I've just got lucky with sales, I dunno. But to me its not important enough to matter. I'll enjoy the phone I paid a hefty amount for!
Used my 13 Pro Max for 2 years. Charged as and when I needed to using my routine above, so not overnight, and just removing anywhere between 80-100%.
Oh and I only use wired charging, wireless charging creates unnecessary extra heat, which is also bad for batteries.
My 13PM was at 94% when I gave it away 2 weeks back. That's after 2 years usage! That's pretty good going - good enough not to worry and stress about!