I've had a talk with Kyla and Aidan and I've been allowed to post some things about the chain of command and here's how it works. I've heard stuff about rank confusion.
Commanding Officer-Obviously the boss, the CEO, the head cheese. No one can outrank him/her. For example if Lillian was a commander the next available rank would be lieutenant commander etc. If she was a Commodore then the next rank for the XO would be Captain.
Executive Officer-The level below CO is the XO who may take over the ship when the CO is wounded, deceased or indisposed for mission reasons.
Second Officer-The Second Officer or 2XO is a department head that has a secondary function of being called upon to the the stand in XO or CO should they become unable to perform their duties. They do not have special powers of authority, for example a second officer isn't considered higher than other department heads. Only when their powers of 2XO are called upon when the CO/XO are indisposed do they have any kind of power beyond their department.
Notes to remember-
Retired ranks are not retained after retirement. For all intents and purposes they are CIVILIANS. They do not have any authority or say unless prompted by the CO and/or XO. Obviously our CMO is a retired general but his level of authority does not extend beyond his departmental duties. For example he has the full say of all medical happens on board the ship but outside medical situations an ensign or even a crewman (subject to debate) would have the ability to order him to complete tasks. Should he refuse an order he could be arrested and subject to court martial.
Taylor is ranked at Lieutenant Colonel (Commander) and Gabe at Lieutenant Commander, however should something befall Lillian and Marlo it would be Gabe that would take over as CO and Taylor as XO as he has the next highest rank of any officer not slated for Second Officer.