The attitude indicator is very important for any sort of instrument flying, so it must be accurate at all times regardless of the plane's movements.
I presume that the indicator would be connnected to a gyroscope. However, gyroscopes drift, and a drifting attitude indicator would be pretty useless. Of course, you might have a reset button, but safely using it would require a visual reference to a horizon, which obviously you don't have during IFR flight.
Another idea might be to periodically reset the indicator based on gravity --- many model aircraft use this something like this approach to drive an attitude calculation; however, during coordinated turns, the gravity vector is indistinguishable from the vector during level flight. If a plane continually turns in a coordinated way, such an attitude indicator would be confused in exactly the same way that a human would be, resulting in bad things like the autopilot doing a graveyard spiral. A gravity sensor + accelerometer wouldn't be able to detect the difference between a gradual turn into a steeper and steeper coordinated spiral and simply a gradual gyroscope drift while remaining in level flight.
How are attitude indicators kept from drifting?