This and a couple other comments in this thread point to an aspect of Star Trek’s world building that hasn’t sat right with me for a long time. It’s supposed to be an utopianistic, egalitarian future. There’s no scarcity or need on Earth so everyone is supposed to be here because they want to be, out of a love of exploration and scientific advancement. So why is there such a disparity in treatment based on rank? Why does an ensign get stuck with a bunk in a hallway while Captain Picard gets a cushy executive suite? O'Brien at least had real quarters to raise his family in, but they were a comparative closet next to the bachelor Captain's. Doesn't seem right to me.
All to say that, in my mind, if an ensign needs to stick to a manner of dress, so should an officer of rank. They're all part of the same fleet and deserving of the same respect.
Why does an ensign get stuck with a bunk in a hallway
Because space is the final frontier, there just isn't enough on a ship.
But actually I found the bunk in a hallway stuff weird. The ship at any given time is full of civilians, children, people preparing to colonize new worlds, etc. It seemed clear to me that everyone/every family had a nice little apartment they lived in.
I know this was different in the Lower Decks animated show, but was this true in live action?
I also think we see Ro Laren's quarters at some point and she has standard quarters.
The interior space inside a Galaxy class is immense. A standard US aircraft carrier has a crew of some 3000 sailors. It is utterly dwarfed by the Enterprise-D. Forget the official crew manifest. The real world designers thought too small. 642m in length, 463m wide, 195 height, and 42 decks total. That saucer section alone could house 10k people easy, and probably 50k in an emergency. With only 3k aboard, they all ought to have a respectable living quarters to themselves.