Roysth Castle is one of the least known castles in a country renowned for historic fortresses.
While other medieval ruins are frequented by visitors, the only people with the chance to view this A-listed building are staff employed at Rosyth Dockyard and associated businesses.
The castle, which features a well preserved 15th century tower house, was gradually absorbed from 1903 onwards by the neighbouring naval base.
As a result, the castle is not officially open to visitors - except for occasional tours - and has largely faded from view.
But until the turn of the 20th century it was one of the most prominent landmarks on the Fife coast.
There was once more than 2,000 castles across Scotland, but few of them stood long enough, or enjoyed prominent locations, to become international tourist attractions like Edinburgh and Stirling.
“For a relatively small country we are very fortunate to have so many fine castles to visit, and inevitably some are better known and more celebrated than others,” said Stephen Duncan, tourism and commercial director at Historic Environment Scotland.
“Although many people will be aware of the likes of the iconic Caerlaverock Castle in Dumfries; the unique Corgarff Castle in Aberdeenshire; or the foreboding Hermitage Castle near Hawick - with its bloody history, some will be unaware of the existence of these incredible sites. These are just a few examples, but there are many more.”
Rosyth Castle was built around 1450 by Sir David Stewart, who took the title Lord Rosyth after being granted the local barony by James I in 1428.
The L-shaped tower house was constructed on a rocky outcrop in the Forth, with a causeway linking it to the mainland. An unusually tall barmkin - the Scots word for a defensive enclosure - was also built, suggesting the Stewarts were not expecting a trouble-free existence.
A crest in the courtyard, dated 1561, displays the initials MR - or Maria Regina - suggests upgrades were made in time for a visit from Mary, Queen of Scots.
When Mary was forced to abdicate in favour of her infant son James in 1567, the Stewarts of Rosyth supported the new regime, led by the Earl of Moray as regent. But Blackness Castle - on the south bank of the Forth - was held for the deposed queen.
The garrison at Blackness frequently sent raiding parties along the firth, attacking Rosyth in 1572, before surrendering a year later.
The Stewarts sold Rosyth in 1711 and it eventually passed to John Hope, Earl of Hopetoun, whose estate stood on the opposite bank of the Forth, before the navy took charge in 1903.
At least Roysth still stands largely intact.
Yester Castle, near Gifford in East Lothian, has almost completely disintegrated at ground level. But its few visitors are drawn to the ruin for what lies beneath.
Under the fragments of the 13th century stone keep lies the ‘Goblin Ha’ - a subterranean chamber with an impressive vaulted roof.
Local legend dictates the hall was built with supernatural help. While its true purpose was likely more prosaic, it remains a fascinating medieval curio.
Most castles have been used for a variety of purposes, but few have a back story as varied as Corgarff.
The 16th century tower house in rural Aberdeenshire was built by the powerful Forbes family.
It played a key role in both the 1715 and 1745 Jacobite risings, which partly explained why it was converted into barracks for Government troops.
As the threat of the Jacobites faded, soldiers from Corgarff focused their attentions on the illegal whisky distilling - a booming industry in the early 1800s.
Unlike the ruins at Yester and the hidden Roysth tower, Corgarff is owned by Historic Environment Scotland and is easily accessible to visitors.