SCSS

by Michael Lajlev

HTML

<div class="wrap">
  <h1>Phonenumber</h1>
  <div id="input">
    <input type="text" id='input--phone' name="" placeholder="enter you phonenumber">    
  </div>

  <button id="btn">Continue</button>
</div>

SCSS

html,
body {
  height: 100%;
  font-size: 16px;
}

* {
  box-sizing: border-box; 
}

.wrap {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 375px;
  margin: 0 auto;
  background: deeppink;
  padding: 2em 2em 8em;
}

h1 {
  margin-bottom: 2em;
}

#input {
  flex: 1;
  
  .keyboard--expanded {
    flex: 0;
  }
  
  input {
   width: 100%;
   display: block;
   height: 2.2em;
   font-size: 100%;
  }
}

#btn {
  width: 100%;
  display: block;
  font-size: 100%;
  margin-top: 2em;
}

JavaScript

$('#input--phone').is(":focus"){
  $('#input').addClass('keyboard--expanded');
	console.log('test');
}