MQTT meets Modem failure

Hi everyone, my Arduino devices with MQTT would fail to communicate with my Raspberry Pi which act as a MQTT broker when my modem provided by our ISP fails.

I am using a Hitron CGN3ROG modem provided by our ISP. I use this modem as a router as well. My switch connects to the modem and I have a WAP connect to the switch. My Arduinos connect to the WAP and my Pi connect to the switch.

The modem would fail to have access to Internet and requires a restart (re-plug) once a while. It also fails when the Internet outage happens. When this happens, my Arduino would not be able to communicate with each other using MQTT protocol. My Arduinos are using DHCP assigned ip(by my modem which has router functions) and my Pi uses static IP. When the modem(router) fails, I can use my laptop to access my MQTT broker (Pi) but I won't be able to receive any message from my Arduino. How can I fix it?

Since the MQTT communication happens in local network, whether or not the modem fails, I still want my Arduino to be able to communicate with each other. Would static IP on my Arduino fix this issue? What are the options to fix this issue?

Does your Arduino contact the Pi by name or by IP? If it's by name and your DNS server is the modem or at least via the modem, I can see why it might fail.

I'd expect failure if your Arduino needs to get an IP for either itself or DNS resolution but once it has them, I don't see why it needs the modem to be up to continue to talk to the Pi as long as they're on the same segment. What are the IP addresses of Arduino and Pi when the failure occurs?

Also, it's simple enough to give the Arduino a static address. Why not just try it and turn the modem off?

Additionally, if the failure is frequent, maybe give the Arduino the ability to cycle the power on the modem.