The OP was just minutes away from being off-loaded and left behind {if the flight was overbooked or there were standby passengers):
Arrival at Gate
You must be at the gate and ready to board the aircraft:
15 minutes prior to scheduled departure for flights departing from points -within- the U.S., Puerto Rico, and Virgin Islands
30 minutes prior to scheduled departure for flights departing from points -outside- the U.S., Puerto Rico, and Virgin Islands, i.e., Canada, Mexico, Europe, Asia, Central/South America, Caribbean, Bahamas, Bermuda
https://www.aa.com/i18n/customer-ser...ooter?#checkin
Looks like a good learning opportunity. Want an upgrade? Get to the gate early. You don't ever want to miss your name being paged by a gate agent.