It _is_ complicated. It's so complicated that (i) there are discussions on the internet about whether 15% or 20% or 25% is fair, and (ii) there are many specialised 'tip calculator' apps.
When I walk into a restaurant, how much should I be expecting to pay for 'meets expectation' service? Is this a % of the bill, or a $ amount related to the amount of time I'm being served (a proxy for the amount of service I get)? Whatever your answer, are you confident that most other patrons of said restaurant would agree with your recommendation?