Hi there Madinewala,
Thanks for joining us in Apple Support Communities! We understand the display of your iPhone 12 Pro Max is dimming unexpectedly although you have Auto-Brightness turned off in Settings > Accessibility > Display & Text Size. We're glad you're here, and we can provide some guidance.
When this happens, your iPhone may be getting too warm.
"If your device gets too warm
If the interior temperature of the device exceeds the normal operating range, the device will protect its internal components by attempting to regulate its temperature. If this happens, you might notice these changes:
- Charging, including wireless charging, slows or stops.
- The display dims or goes black.
- Cellular radios enter a low-power state. The signal might weaken during this time.
- The camera flash is temporarily disabled.
- Performance slows with graphics-intensive or augmented-reality apps or features."
Have a look at this support article to learn more:
Keeping iPhone, iPad, and iPod touch within acceptable operating temperatures
We hope this information is helpful. Don’t hesitate to let us know if you have any more questions.
Take care.