They will ask how long you are staying in Mexico. If it is seven days or less, you won't have to pay the tourism tax. If you're staying longer than seven days, you'll be directed to a window where you can pay this tax, which is approximately $30 USD and allows you to stay in Mexico up to 180 days.