Cities like Rome, Athens, Pergamon and Antioch were all built just off the coast with their own port city counterparts (Ostia/Portus, Piraeus, Elaea and Seleucia Pieria respectively). Why? Why didn't their port cities overshadow them once they became established centers of trade?
A lot of that has to do with things like safety and access to resources. While a port city can be convenient for trade, it also gave invaders an avenue to attack you from. Given that piracy was quite common in the ancient world, having your main economic centers further inland added a extra layer of security. As for a inland city like Rome, it could offer many advantages. Rome was situated slightly east of the Apennines on the southern side of Tiber's main crossing. This protected Rome's northern and eastern sides from invasions and enabled Romans to tax trade up and down the Italian peninsula. To add to this, the Romans had a salt marsh. Now salt may sound like a mundane resource today, but it was worth its weight in gold back then. So overall, the area around Rome had everything it needed for a safe and self-sustaining city.