Civitavecchia's about 50 milles from Rome. We just took a train into Rome and back, about 10 euros (I think the ship's coach was more like £50), got off at St Peter's (because after that the gtrain meanders round the city a bit before getting to the main station), went round that, had a pizza for lunch, strolled round the Colosseum and returned (in good time for sailing). Schedules and fares are available online and the station's about a 10 minute walk from the port
http://www.bahn.com/i/view/GBR/en/index.shtml
(Yes, it's German, but it covers everywhere)