Just starting out in web development and struggling with this issue. Any assistance would be much appreciated!
When resizing the window, the fixed div moves outside of its container instead of resizing. The navigation bar on the website I'm working on is set as the fixed section within the main container.
Your help is greatly appreciated. Thank you!
<div class="container">
<div class="fixed"></div>
</div>
.container {
border: 1px solid;
max-width: 600px;
width: 100%;
min-height: 1600px;
}
.fixed {
max-width: 600px;
width: 100%;
height: 50px;
border: 1px solid green;
position: fixed;
}