Put input is below the label

0

How to make this input stay below the label.

.passo {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  line-height: 30px;
  text-align: center;
  color: #fff;
  background: #29b2fe;
  margin-right: 15px;
}

.input {

}
<div class="container">
  <div class="row row-margem">
    <h1 class="h2">Iniciando</h1>
  </div>

  <form action="">
    <div class="row">
      <span class="passo">1</span><label class="h3">Crie uma conta</label><br>
      <input id="email" class="input">
    </div>

  </form>

</div>
    
asked by anonymous 28.07.2017 / 21:26

3 answers

1

If what you need is for it to be on the bottom line you can add <br> after <label>

.passo {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  line-height: 30px;
  text-align: center;
  color: #fff;
  background: #29b2fe;
  margin-right: 15px;
}

.input {}
<div class="container">
  <div class="row">
    <span class="passo">1</span><label class="h3">Crie uma conta</label><br>
    <input id="email" class="input">
  </div>
</div>
    
28.07.2017 / 21:33
1

try to use the : before pseudoelement to force a line break

.passo {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  line-height: 30px;
  text-align: center;
  color: #fff;
  background: #29b2fe;
  margin-right: 15px;
}

input:before {
  content: '\a';
  white-space: pre;
}
<div class="container">
  <div class="row">
    <span class="passo">1</span><label class="h3">Crie uma conta</label><br>
    <input id="email" class="input">
  </div>
</div>
    
28.07.2017 / 21:44
1

Now I understand rs, just change the display property of the element. Learn more about display.

.input {
  display: block;
}
<div class="container">
      <div class="row">
        <span class="passo">1</span><label class="h3"> Crie uma conta</label><br>
        <input id="email" class="input">
      </div>
    </div>

If it works here and your page does not, some other CSS is influencing it. Inspect the elements to try to find the cause of the problem.

    
28.07.2017 / 21:34