Whether your game is fantasy or historical, when you need a defensive base a good starting-point is an actual historical castle style. Here is one of the fairly early styles, the shell keep - basically you build a solid circular or square structure with a space in the middle, and defend yourself from all directions at once.
This shell keep castle is presented in clear detail, in a style familiar from the 'castle plans' I collected from every castle I visited all over England and Wales as a child (even before I took up role-playing I loved castles and boy, have those plans come in useful since!). Suggestions for how various rooms in the castle might be used are given, and there's plenty of scope to develop from there.
Possibly best suited to low-fantasy, as if both defenders and assailants have access to lots of high-powered magic, flying creatures and so on, the way in which you defend yourself is going to change from the historical build a solid wall, hide behind it and fire arrows at those who'd attack you model to something quite different. Even so, if your enemies come mounted on dragons or giant eagles, why not spread a stout net over the central open area to stop them landing? You can fire offensive spells through arrow slits just as well as arrows... and so on, and this is a delightful starting point in developing your own castles and ways to defend them.
Good descriptive detail too in the accompanying text about the history, design and construction of this type of castle: it's not just a set of floorplans, but a considered introduction to this type of castle.