Your overall flowchart is workable.
The hard part is to make two amp-hour meters, which let you have internal access to an internal overflow pin.
I made a homebrew amp-hour meter. I installed an inline current-sensing wire (consisting of several inches of 12 gauge copper wire). This generates a small voltage across the ends.
I amplify it with an op amp to a range of 0 to 6 volts. Then input it to a voltage-to-frequency converter built around a second op amp.
The pulses go to a 4020 IC ( 14 stage counter). This divides down the pulses. (An alternate chip might be a 4040 or 4060.)
The resulting output pulse increments an LED display showing amp-hours (or milli-amp-hours).
I spent a lot of time experimenting to find:
#1: A suitable frequency range coming from the V-F converter, and
#2: the proper divisor pin on the 4020,
in order to obtain correct readings from the LED display in accord with the amount of amp-hours going through my sensor wire.
My reset signal came from a manual push button. You'll need to reset manually, or use a light sensor to detect sunrise, or else use a realtime clock.
A micro-controller should make the job much easier. The hard job is to obtain a current sense and amplify it to a volt range which can be used by the ADC unit.
As for the relays, there are several ratings to pay attention to.
One is for what voltage and current is needed through the coil. Normally the less of each, the better. If your controller output cannot provide specified V and A, then you'll need to boost it with a pass transistor.
The other rating is volts and amps across the relay contacts. The amount you state can be handled by relays costing under 10 dollars mail order.
Consider getting latching relays. This type doesn't need to be continually energized.With ordinary relays you'll have to provide several volts at tens of milliamps all day long.
Instead a latching relay is pulse-on-pulse-off. Consumes minimal energy. Your controller should have no trouble providing such operation.