So, assuming that you are going to do Wales without a car - I suggest > Holyhead to Bangor by train - (nothing much in Bangor). Then local bus to Caernarfon for 1 night. See King Ed’s Castle. Next day - one way trip on Welsh Highland Railway through Snowdonia National Park to Porthmadog - stay 2 nights. Next day visit Portmeirion (Italian style village) which is about 4 miles from Porthmadog.
On leaving Porthmadog to head south, I suggest that you could use the Cambrian Coast Railway - which is very scenic. (This is a normal railway unlike the Welsh Highland which is privately run). If the weather is good, Barmouth &/or Aberdovey is quite a nice place(s) to stop for a break - but check when the next train is due. If you like narrow gauge stream railways - check out the Tal-Y-Llyn which starts at Tywyn which is between Barmouth & Aberdovey. Of course, if you do all that, then you would probably need to spend a night say at Aberdovey. (Towyn is not particularly attractive).
Anyway, the railway heads east through the mountains from Aberdovey to Shrewsbury (well worth a look) in England. From here, you could take the slow Heart of Wales Line down to Swansea. Latest word is that this line is not going to get better trains so be prepared for a basic train with no air con on a journey of about 4 hours. Alternatively, take the fast ‘Marches Line’ which more or less follows the England - Wales border and has more frequent trains and they are air conditioned. (On this route, Ludlow is worth a look to see Ye Olde England’. Note that some of the Holyhead to Cardiff express trains won't stop at Ludlow but most of the ones from Manchester to south west Wales do).
When staying in Cardiff you have 4 very different castles within 7 miles of the centre = Cardiff, Castell Coch, Caerphilly and St. Fagans - which includes gardens and buildings of historical significance from all over Wales. St.Fagans alone would take up most of a day. Also consider taking a train east from Cardiff to Chepstow to see the Castle and then a local bus up the Wye Valley to see Tintern Abbey (ruin).
For travel check out travelling.info &/or travelinecymru. (Cymru is Wales in Welsh - just to confuse the foreigners).
For trains - www.nationalrail.co.uk
It would be best to pre-book in advance a specific train from Cardiff to Paddington or maybe Reading for Heathrow by bus link. (I am not sure if this can be done all on 1 ticket). The cheapest advance fares get loaded in normal times about 11 weeks out. Pay on the day can be expensive.
Google the things I have mentioned. Even doing this, you are still missing out a lot of Wales.
Stena Line have just announced a new direct ferry from Belfast to Holyhead.
Also consider the Traws Cymru long distance bus services across Wales. For trains - check out the Transport for Wales website.
Please note that you can’t take photos from the ‘normal’ trains as they do not have windows that open and the glass is tinted.