Mitigating Domain Shift in Federated Learning via Intra- and Inter-Domain Prototypes