Choose the element that is trapped within the div

I've hit a roadblock with this issue that I just can't seem to figure out. I was working on a practice project creating a Netflix-like webpage, and the select element in the footer containing languages is stuck and won't budge. Here's my code:

footer div #selectft {
  position: relative;
  display: block;
  padding: 12px 26px;
  background: transparent;
  color: #999;
  border: 1px solid #333;
  margin: 25px 0;
  column-gap: 50px;
  border-left: 140px;
}

footer p,
div nav {
  margin-left: 140px;
  display: inline-grid;
  column-gap: 50px;
  width: 15%;
  justify-items: start;
}

footer a {
  color: #737373;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

footer p {
  margin-bottom: 25px;
}

footer nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

footer nav ul li {
  margin-bottom: 16px;
  font-size: 13px;
}

footer .bottom-text {
  color: #737373;
}
<footer>
  <p>Questions? Contact us.</p>
  <div>

    <nav>
      <ul>
        <li><a href="">FAQ</a></li>
        <li><a href="">Account</a></li>
        <li><a href="">Privacy</a></li>
        <li><a href="">Speed Test</a></li>
      </ul>
    </nav>

    <select id="selectft">
      <option value="english">English</option>
      <option value="serbian">Serbian</option>
    </select>

    <p>Netflix Montenegro</p>
  </div>
</footer>

One thing to note: there are four <nav> elements in the footer, I removed 3 to keep the post clean. Thanks

I expected the select element to align under the nav elements, but it seems to be stuck at the left edge and won't budge no matter what CSS tags I try.

Answer №1

It appears that you intended to adjust the margin-left property rather than the border-left property

header section #menusect {
    position: static;
    display: inline-block;
    padding: 10px 20px;
    background: transparent;
    color: #666;
    border: 2px solid #555;
    margin: 15px 0;
    column-gap: 40px;
    margin-left: 120px;
}

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Images positioned next to each other appear distorted when adjusting for different screen sizes

I have been struggling with this issue for quite some time and I just can't seem to get it right. My goal is to display two images side by side with a gap between them. The problem arises when the browser is resized, as the gap disappears and the im ...

How to incorporate a JavaScript file into a Handlebars template

I am having trouble receiving calls to my JavaScript file. What could be the issue? Using MVC. Here is the code in view file, file.hbs: <div class="container"> <h2 onClick="test()">Title</h2> {{>list}} </div> <script sr ...

How do I ensure that my font size completely fills the space in a justified layout using CSS?

Is there a way to style my text to match the appearance in the image shown using CSS? ...

Tips for adding additional rows or cells to a table with jQuery

Similar Questions: How to Add Table Rows with jQuery Adding Rows Dynamically using jQuery. I am currently working with a table that contains one row and five editable cells for user input. My goal is to implement an "Add Row" feature using jQuery ...

The functionality of opening a new tab when clicking on a link image is not functioning correctly on Mozilla, whereas it

Check out my code below: <a target="_blank" href="#" onclick="window.open('https://www.google.com','_blank');"> <img src="#{request.contextPath}/resources/img/landing-page/terdaftar-kominfo.png" /> </a> ...

The issue of the footer kicking out of place in the HTML layout was successfully resolved after

I am in the process of creating a simple footer that will always stay at the bottom of the page. The content on the page will not exceed the screen size, eliminating the need for scrolling. (There are a total of 5 HTML pages, and I want the footer and head ...

Incorporate row numbering feature into jQuery DataTables

Is there a way to have jQuery datatables generate a row number column in the first column, similar to a datagrid in VB? This is what I'm aiming for: If you have any insights on how this can be achieved, please share! ...

Leveraging ajax for showcasing page content in a floating div container

I am in need of creating a button on my page that, when clicked, will display a floating div above the page and load another internal page. I believe this can be achieved using Ajax, but I have no experience with it and don't know where to start. Her ...

Unlock the power of automatic code reloading in Rails with these simple steps

Looking for a way to implement 'hot code reloading' in a development Rails application? Let's say you're working on a Rails project and make changes to a stylesheet. Currently, you have to refresh the page using cmd-r or by clicking th ...

Placing a component within a .jsx file instead of utilizing a .css file for positioning

Seeking a way to position a component within a .jsx-file, rather than a .css-file, to accommodate multiple instances of the same component performing various tasks on different parts of the page. Avoiding duplication of files with minor CSS class changes, ...

The issue with displaying Fontawesome icons using @import in CSS-in-JS was not resolved

I recently changed how I was importing Fontawesome icons: src/App.css @import "@fortawesome/fontawesome-free/css/all.css";` After shifting the @import to CSS-in-Js using emotion: src/App.js // JS: const imports = css` @import "@fortawes ...

Struggling with certain CSS design elements

I'm encountering some CSS styling issues. The button in my form remains perfectly positioned when I resize the window, but the inputs are moving around. Why is this happening? Also, when a button is pushed, a h2 element with a little arrow needs to b ...

Ways to link two PHP scripts

My code snippet below aims to select a location from a dropdown menu and generate a pie chart based on data fetched from a PostgreSQL database. However, I am facing an issue where the pie chart displays all column values instead of only the selected locati ...

The input field is failing to show up on the screen

I have been working on my React app and experimenting with how to dynamically display input elements based on different screen sizes. To achieve this, I implemented the use of window.innerWidth as shown in the code snippet below: <div className='Tr ...

What is a better method for aligning an image in the middle of a floated container?

Is there a better way to center an image within a floated div without using an extra p tag? I currently have the image inside a p tag and center the p, but it annoys me having that extra tag. Any suggestions on how to center the image itself? Thanks! Below ...

How to Use Absolute Positioning in Bootstrap 3.0 to Position Child Divs

I have a div block that needs to always be displayed at the bottom of the section, regardless of whether the section above is empty. The inner div should stay at the bottom of the section, as shown in the attached image. This is my current code: <div ...

CSS regression testing through version control systems and continuous integration

Is there a tool that integrates with CI systems and VCS like Git to automatically assign regression test results to individual commits? Ideally, this tool would provide a concise summary on a main page showing passed/failed numbers for each commit, with th ...

Adjust the font size based on the dimensions of the container

I'm currently working on a script that dynamically sets the font-size based on the container's dimensions and the length of the text. This is what I have implemented so far. window.onload = function () { var defaultDimensions = 300; ...

Place the span element above the div container

I recently created some social media buttons with share counters, but I'm facing an issue where the counter data appears inside the buttons rather than on top of them. Has anyone encountered this problem before? Is there a way to display the numbe ...

Adapt the CSS based on different screen sizes

I am currently developing a mobile application using angularjs and the ionic framework. My application is intended for both tablet and mobile versions. I have encountered an issue where I cannot use the same CSS for both the tablet and mobile versions. Is ...