Site layout problems when logged in due to admin bar

This is really just a CSS question. The admin bar does its best to do this for all sites by giving a top margin to the <html> element:

margin-top: 28px !important;

But if the theme uses certain positioning methods, that rule won’t have the desired effect, which is what is happening in your case.

From what you’ve said, this might fix the issue:

body { position:relative; }

Also, WordPress adds an .admin-bar class to the <body> if you’re using body_class(), so you could use that as a selector to fix the issue:

.admin-bar #my-logo { top: 28px; }

Either way, this is a CSS issue and not a PHP one. The actual CSS solution is off-topic for this site, so I’ll leave you hear and you can figure it out.