I've been experimenting with getting text to display on the right side of my stylized list. Initially, I set fixed widths for both the ul and div elements, but encountered issues with margins that persisted even after setting them to 0px (I double-checked in Chrome's inspect element tool). If there's a better way to position the text next to the list without causing any additional problems, I'd appreciate some guidance. Additionally, I'm curious about why the margins are behaving unexpectedly.
<div class="bar">
<div class="nav">
<h1><a href="#" id="JETS">Lorem Ipsum<br>Lorem Ipsum</a></h1>
<ul class="nav">
<li class="active"><a href="#" id="ML1">Lorem</a></li>
<li><a href="#" id="ML2">Lorem</a></li>
<li><a href="#" id="ML3">Lorem</a></li>
<li><a href="#" id="ML4">Lorem</a></li>
<li><a href="#" id="ML5">Lorem</a></li>
</ul>
</div>
</div>
<div class="Lmenu">
<ul class="Lmenu">
<ul id="Lmenu1">
<li><a href="#" class="majorL">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<br>
</ul>
<ul id="Lmenu2">
<li><a href="#" class="majorL">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<br>
</ul>
<ul id="Lmenu3">
<li><a href="#" class="majorL">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<br>
</ul>
<ul id="Lmenu4">
<li><a href="#" class="majorL">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<li><a href="#">Lorem Ipsum</a></li>
<br>
</ul>
</ul>
</div>
<h2>The desired text should align to the top-right
</h2>
<div id="foot">
</div>
Here's a snippet of my CSS styling (please excuse any lack of organization):
// CSS rules go here...
Despite attempting to float elements as suggested by others, it ended up disrupting another section of my website that wasn't initially visible. Here are links to demonstrate:
I'm seeking a solution that doesn't compromise other parts of the layout. Feel free to ask for any additional details if needed.