medieval castle at the foot of the mountains