title: Height doesn't properly work on IOS (iphone)
body: <p>I've created <a href="https://codepen.io/salman15/project/live/DWbWpo/" rel="noreferrer">this</a> website on codepen. While trying to make it responsive for all platforms I ran into a problem. It appears a single div covers the whole page (only on IOS) and not all heights are working properly (meaning nothing fits).</p>
  
  <p>I've been at it for days and still have no clue, why all the heights and rules don't apply on IOS.</p>
  
  <p>I've tried removing the <code>video-section</code> which reveals most of the page except the <code>eind</code> section which is just a blank white.</p>
  
  <p>I've tried adding <code>max-height</code> which does reveal some of the other content, but it also seems as if the page can't get any taller on <code>IOS</code> so I'm still limited to a space to work with. Also it doesn't seem a proper solution.</p>
  
  <p>I've tried changing the <code>position</code> but with no avail.</p>
  
  <p>It just seems as if the heights don't properly work on IOS</p>
  
  <p>Can anyone help me figure out why this is happening? </p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>var $animation_elements = $('.animation-element');
  var $window = $(window);
  
  function check_if_in_view() {
    var window_height = $window.height();
    var window_top_position = $window.scrollTop();
    var window_bottom_position = (window_top_position + window_height);
  
    $.each($animation_elements, function() {
      var $element = $(this);
      var element_height = $element.outerHeight();
      var element_top_position = $element.offset().top;
      var element_bottom_position = (element_top_position + element_height);
  
      //check to see if this current container is within viewport
      if ((element_bottom_position &gt;= window_top_position) &amp;&amp;
        (element_top_position &lt;= window_bottom_position)) {
        $element.addClass('in-view');
      } else {
        $element.removeClass('in-view');
      }
    });
  }
  
  $window.on('scroll resize', check_if_in_view);
  $window.trigger('scroll');
  
  var controller = new ScrollMagic();
  
   var ctrl = new ScrollMagic.Controller({
       globalSceneOptions: {
           triggerHook: 'onLeave'
       }
   });
  
  //Enter section-1
  new ScrollMagic.Scene({
    triggerElement: "#coming-soon",
    duration: "100%"
  })
    .setTween(TweenMax.to("#image-1", 1, { top: "0%" }))
    .addTo(ctrl);
  
  new ScrollMagic.Scene({
    triggerElement: "#coming-soon",
    duration: "100%"
  })
    .setTween(TweenMax.to(".sign-up-banner", 1, { top: "0%" }))
    .addTo(ctrl);
  
  new ScrollMagic.Scene({
    triggerElement: "#coming-soon",
    duration: "100%"
  })
    .setTween(TweenMax.to("#text-1", 1, { top: "0%" }))
    .addTo(ctrl);
  
  //Leave section-1
  
  new ScrollMagic.Scene({
    triggerElement: "#introductie-1",
    duration: "100%"
  })
    .setTween(TweenMax.to("#image-1", 1, { top: "40%", opacity:-1 }))
    .addTo(ctrl);
  
  new ScrollMagic.Scene({
    triggerElement: "#introductie-1",
    duration: "100%"
  })
    .setTween(TweenMax.to("#text-1", 1, { top: "-50%", opacity:0 }))
    .addTo(ctrl);
  
  //leave seaction-2
  
  new ScrollMagic.Scene({
    triggerElement: "#introductie-2",
    duration: "100%"
  })
    .setTween(TweenMax.to("#image-2", 1, { top: "-40%", opacity:0 }))
    .addTo(ctrl);
  
  new ScrollMagic.Scene({
    triggerElement: "#introductie-2",
    duration: "100%"
  })
    .setTween(TweenMax.to("#text-2", 1, { top: "-50%", opacity:0 }))
    .addTo(ctrl);
  
  new ScrollMagic.Scene({
    triggerElement: "#introductie-2",
    duration: "100%"
  })
    .setTween(TweenMax.to("#release", 1, {opacity:1 }))
    .addTo(ctrl);</code></pre>
  <pre class="snippet-code-css lang-css prettyprint-override"><code>@import url("https://fonts.googleapis.com/css?family=Raleway:200");
  * {
    font-family: "Raleway", sans-serif;
    font-size: 14px;
    font-weight: 100 !important;
  }
  
  input {
    -webkit-appearance: none;
  }
  
  html,
  body,
  section {
    padding: 0px;
    margin: 0px;
    height: 100%;
    width: 100%;
    color: #666;
  }
  
  p,
  h1,
  h2,
  h3,
  h4 {
    margin: 0px;
  }
  
  ul {
    list-style-type: none;
  }
  
  ul li {
    display: inline-block;
    margin: 50px 25px;
  }
  
  ul li .fa {
    font-size: 5em;
    transition: all 1s ease;
  }
  
  a:link {
    text-decoration: none;
  }
  
  a:visited {
    text-decoration: none;
  }
  
  a:hover {
    text-decoration: none;
  }
  
  a:active {
    text-decoration: none;
  }
  
  a {
    color: #666;
  }
  
  .desktop-only {
    display: initial;
  }
  
  .align-center {
    position: absolute !important;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    -ms-transform: translate(-50%, -50%);
    -webkit-transform: translate(-50%, -50%);
  }
  
  .mobile-only {
    display: none;
  }
  
  .icon {
    background-color: antiquewhite;
    border-radius: 50%;
    width: 150px;
    height: 150px;
    margin: 20px auto;
  }
  
  .fa-icon {
    font-size: 5em !important;
    padding: 40px;
  }
  
  .nederland-icon {
    width: 40%;
    padding: 40px;
  }
  
  #mc_embed_signup form {
    position: absolute !important;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    /* (x, y)  =&gt; position */
    -ms-transform: translate(-50%, -50%);
    /* IE 9 */
    -webkit-transform: translate(-50%, -50%);
    /* Chrome, Safari, Opera */
    padding-left: 0px !important;
  }
  
  .sign-up-banner {
    z-index: 2;
    position: relative;
    top: -50%;
    color: white;
    height: 50%;
    background-color: #f3c17e;
  }
  
  .sign-up-banner input::placeholder {
    color: white;
  }
  
  .sign-up-banner #mc_embed_signup .mc-field-group input {
    border-bottom: 2px solid #ffffff !important;
  }
  
  .sign-up-banner #mc_embed_signup {
    background: #fff0;
  }
  
  .sign-up-banner #mc_embed_signup .mc-field-group input {
    background-color: #ffffff00;
    color: white;
  }
  
  .sign-up-banner #mc_embed_signup #mc-embedded-subscribe-form div.mce_inline_error {
    background-color: rgba(255, 255, 255, 0);
  }
  
  .video-section {
    z-index: 3;
    overflow: hidden;
    position: relative;
    top: 0px;
    background-color: black;
    max-height: 100%;
    max-height: 100vh;
  }
  
  .video-section video {
    width: 100%;
  }
  
  #coming-soon {
    display: table;
    position: absolute;
    height: 100%;
    width: 100%;
    top: 0px;
    color: white !important;
    z-index: 3;
    max-height: 100%;
    max-height: 100vh;
  }
  
  .coming-soon h1 {
    font-size: 52px;
  }
  
  .introductie {
    position: relative;
    z-index: 1;
  }
  
  #introductie-1 {
    height: 100%;
  }
  
  #introductie-1 #image-1 {
    overflow: hidden;
    width: 25%;
    margin: 90px auto;
    max-height: 70%;
  }
  
  #introductie-1 .text-container {
    width: 500px;
    margin: 180px auto;
    color: #666;
  }
  
  #introductie-1 .text-container h1 {
    font-size: 2em;
    margin-bottom: 40px;
  }
  
  #introductie-1 .text-container p {
    font-size: 1.4em;
  }
  
  #introductie-2 {
    height: 100%;
  }
  
  #introductie-2 h1 {
    font-size: 2em;
    margin-bottom: 40px;
  }
  
  #introductie-2 p {
    font-size: 1.4em;
  }
  
  #introductie-2 .text-container {
    width: 60%;
    text-align: center;
    margin: 0 auto;
  }
  
  #introductie-2 #text-2 {
    position: relative;
  }
  
  #introductie-2 #image-2 {
    overflow: hidden;
    width: 60%;
    margin: 90px auto;
    position: relative;
  }
  
  #introductie-2 #image-2 img {
    width: 100%;
  }
  
  .left,
  .right {
    width: 50%;
  }
  
  .left {
    float: left;
  }
  
  .right {
    float: right;
  }
  
  #image-1 {
    position: absolute;
    top: -70%;
    left: 10%;
  }
  
  #text-1 {
    top: 40%;
    right: 10%;
    position: absolute;
  }
  
  .center-container {
    display: table-cell;
    vertical-align: middle;
  }
  
  .center {
    margin-left: auto;
    margin-right: auto;
    width: 80%;
  }
  
  .center-text {
    text-align: center;
    overflow: hidden;
  }
  
  #eind {
    position: relative;
  }
  
  #release {
    opacity: 0;
  }
  
  #disclaimer {
    position: relative;
    left: 48%;
    bottom: 10px;
  }
  
  .fa-facebook:hover {
    color: #3b5998;
  }
  
  .fa-instagram:hover {
    color: #fbad50;
  }
  
  #eind ul {
    padding: 0px;
  }
  
  #eind p {
    margin-bottom: 100px;
  }
  
  .button {
    background-color: #faebd7 !important;
    color: #666 !important;
  }
  
  #mc_embed_signup {
    width: 40%;
    margin: 0 auto;
  }
  
  #mc_embed_signup .mc-field-group input {
    border: 0px !important;
    border-radius: 0px !important;
    border-bottom: 2px solid #666666 !important;
  }
  
  #mc_embed_signup #mc-embedded-subscribe-form input.mce_inline_error {
    border: 0px !important;
    border-radius: 0px !important;
    border-bottom: 2px solid #e85c41 !important;
  }
  
  #mc_embed_signup_scroll {
    text-align: center;
  }
  
  textarea:focus,
  input:focus {
    outline: none;
  }
  
  #mc_embed_signup h2 {
    margin-bottom: 10% !important;
  }
  
  .clear {
    width: 150px;
    margin: 0 auto;
    margin-top: 5%;
  }
  
  .clear #mc-embedded-subscribe {
    border-radius: 0px !important;
    width: 150px !important;
    margin: 0 auto !important;
    height: 50px !important;
  }
  
  /*animation element*/
  
  .animation-element {
    position: relative;
  }
  
  /*bounce up animation for the subject*/
  
  .bounce-up {
    opacity: 0;
    -moz-transition: all 700ms ease-out;
    -webkit-transition: all 700ms ease-out;
    -o-transition: all 700ms ease-out;
    transition: all 700ms ease-out;
    -moz-transform: translate3d(0px, 200px, 0px);
    -webkit-transform: translate3d(0px, 200px, 0px);
    -o-transform: translate(0px, 200px);
    -ms-transform: translate(0px, 200px);
    transform: translate3d(0px, 200, 0px);
    -webkit-backface-visibility: hidden;
    -moz-backface-visibility: hidden;
    backface-visibility: hidden;
  }
  
  .bounce-up.in-view {
    opacity: 1;
    -moz-transform: translate3d(0px, 0px, 0px);
    -webkit-transform: translate3d(0px, 0px, 0px);
    -o-transform: translate(0px, 0px);
    -ms-transform: translate(0px, 0px);
    transform: translate3d(0px, 0px, 0px);
  }
  
  @media (max-width: 1440px) {
    #disclaimer {
      position: relative;
      left: 48%;
      bottom: 10px;
    }
  }
  
  @media (max-width: 1024px) {
    #image-1 img {
      position: relative;
      left: -244px;
    }
  }
  
  @media (max-width: 768px) {
    .video {
      margin-top: 30%;
    }
    #introductie-1 .text-container {
      width: 280px;
    }
    #image-1-container #image-1 {
      width: 35%;
    }
    #mc_embed_signup {
      width: 60%;
    }
  }
  
  @media (max-width: 430px) {
    .sign-up-banner {
      position: sticky;
      top: 0px !important;
      max-height: 325px;
    }
    .desktop-only {
      display: none;
    }
    #disclaimer {
      left: 42%;
    }
    .mobile-only {
      display: inherit;
    }
    .coming-soon h1 {
      font-size: 45px;
    }
    .sign-up-banner {
      height: 60%;
    }
    #introductie-1 {
      height: 250%;
    }
    #introductie-2 {
      max-height: 500px;
      height: 200%;
    }
    #release {
      opacity: 1;
    }
    .left,
    .right {
      width: 100%;
    }
    #introduction-1-container {
      height: 100%;
    }
    #introductie-1 #image-1 {
      display: none;
    }
    #introductie-2 #image-2 {
      display: none;
    }
    #introductie-2 .text-container {
      width: 80%;
      text-align: center;
      margin: 0 auto;
    }
    #introductie-1 .text-container {
      position: initial;
      width: 80%;
      margin: 0 auto;
      text-align: center;
      margin-top: 40px;
    }
    #coming-soon h1 {
      font-size: 24px;
    }
    #introductie-1 .text-container p {
      font-size: 1.2em;
    }
    #introductie-2 p {
      font-size: 1.2em;
    }
    .video {
      margin-top: 60%;
    }
    .social-media ul {
      padding: 0px;
    }
    #mc_embed_signup {
      width: 100%;
      margin: 0 auto;
    }
    #text-1 {
      opacity: 1 !important;
    }
    #text-2 {
      position: initial !important;
      opacity: 1 !important;
    }
    #eind {
      height: 120%;
      max-height: 1000px;
    }
    .eind-block {
      position: relative;
    }
    .fa-balance-scale {
      padding: 40px 34px;
    }
  }
  
  @media (max-width: 320px) {
    #coming-soon h1 {
      font-size: 24px;
    }
    #introductie-1 .text-container p {
      font-size: 1.2em;
    }
    #introductie-2 p {
      font-size: 1.2em;
    }
    .video {
      margin-top: 60%;
    }
    .social-media ul {
      padding: 0px;
    }
    #mc_embed_signup {
      width: 100%;
      margin: 0 auto;
    }
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
    &lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /&gt;
    &lt;meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1.0" /&gt;
    
    &lt;title&gt;Volks&lt;/title&gt;
    &lt;link rel="stylesheet" href="styles/index.processed.css"&gt;
    &lt;script src="https://use.fontawesome.com/39f17a3ca2.js"&gt;&lt;/script&gt;
  
  &lt;/head&gt;
  &lt;body&gt;
    &lt;section class="video-section"&gt;
     &lt;div class="video"&gt;
      &lt;video loop autoplay id="video-background" muted playsinline&gt;
        &lt;source src="http://rapio.nl/videos/teaser.mp4" type="video/mp4"&gt;
      &lt;/video&gt;
     &lt;/div&gt;
    &lt;/section&gt; 
  
    &lt;section id="coming-soon"&gt;
        &lt;div class="align-center center-text coming-soon"&gt;
          &lt;h1 class=""&gt;Binnenkort verkrijgbaar.&lt;/h1&gt;
        &lt;/div&gt;
    &lt;/section&gt;
    &lt;section class="sign-up-banner"&gt;
  
  
          &lt;!-- Begin MailChimp Signup Form --&gt;
          &lt;link href="//cdn-images.mailchimp.com/embedcode/classic-10_7.css" rel="stylesheet" type="text/css"&gt;
          &lt;style type="text/css"&gt;
            #mc_embed_signup {
              background: #fff;
              clear: left;
              font: 14px Helvetica, Arial, sans-serif;
            }
            /* Add your own MailChimp form style overrides in your site stylesheet or in this style block.
                We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */
          &lt;/style&gt;
          &lt;div id="mc_embed_signup"&gt;
            &lt;form action="https://volksphone.us17.list-manage.com/subscribe/post?u=e0b25e148103e039f3ed554d1&amp;amp;id=bbad48d887" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate&gt;
              &lt;div id="mc_embed_signup_scroll"&gt;
                &lt;h2&gt;Ontvang een notificatie bij de bekendmaking van onze crowdfundings-campagne.&lt;/h2&gt;
                &lt;div class="mc-field-group"&gt;
                  &lt;input type="email" placeholder="Emailadres" name="EMAIL" class="required email" id="mce-EMAIL"&gt;
                &lt;/div&gt;
                &lt;div class="response" id="mce-error-response" style="display:none"&gt;&lt;/div&gt;
                &lt;div class="response" id="mce-success-response" style="display:none"&gt;&lt;/div&gt;
              &lt;/div&gt;
              &lt;div style="position: absolute; left: -5000px;" aria-hidden="true"&gt;&lt;input type="text" name="b_e0b25e148103e039f3ed554d1_bbad48d887" tabindex="-1" value=""&gt;&lt;/div&gt;
              &lt;div class="clear"&gt;&lt;input type="submit" value="verzend" name="subscribe" id="mc-embedded-subscribe" class="button"&gt;&lt;/div&gt;
          &lt;/form&gt;
        &lt;/div&gt;
        &lt;script type='text/javascript' src='//s3.amazonaws.com/downloads.mailchimp.com/js/mc-validate.js'&gt;&lt;/script&gt;
        &lt;script type='text/javascript'&gt;
          (function($) {
            window.fnames = new Array();
            window.ftypes = new Array();
            fnames[0] = "EMAIL";
            ftypes[0] = "email";
            fnames[1] = "FNAME";
            ftypes[1] = "text";
            fnames[2] = "LNAME";
            ftypes[2] = "text";
            fnames[3] = "BIRTHDAY";
            ftypes[3] = "birthday";
          })(jQuery);
          var $mcj = jQuery.noConflict(true);
        &lt;/script&gt;
        &lt;!--End mc_embed_signup--&gt;
      
  
    &lt;/section&gt;
    &lt;section class="introductie" id="introductie-1"&gt;
      &lt;div class="container" id="introduction-1-container"&gt;
        &lt;div class="left" id="image-1-container"&gt;
          &lt;div class="image-container " id="image-1"&gt;
            &lt;img src="media/image-1.jpg"&gt;
          &lt;/div&gt;
        &lt;/div&gt;
        &lt;div class="right"&gt;
          &lt;div class="text-container" id="text-1"&gt;
            &lt;div class="icon  mobile-only"&gt;&lt;img class="nederland-icon" src="media/nederland_icoon.png"&gt;&lt;/div&gt;
            &lt;h1&gt;Van Nederlandse Bodem&lt;/h1&gt;
            &lt;p&gt;Volks is een Amsterdamse startup achter de eerste Nederlandse high-end smartphone. Maak kennis met onze technologie, je zult verrast zijn.&lt;/p&gt;&lt;br&gt;&lt;br&gt;
            &lt;div class="icon  mobile-only"&gt;&lt;i class="fa fa-balance-scale mobile-only fa-icon" aria-hidden="true"&gt;&lt;/i&gt;&lt;/div&gt;
                  &lt;h1&gt;Balans tussen prijs en kwaliteit&lt;/h1&gt;
            &lt;p class="mobile-only"&gt;Wanneer had je voor het laatst een smartphone in je handen? Precies, nu.&lt;/p&gt;&lt;p&gt;Wanneer had je voor het laatst een smartphone in je handen? Precies, nu.&lt;/p&gt;&lt;p&gt;Er is een overvloed aan smartphones. Helaas betaal je nog steeds de hoogste prijs, of iets minder maar ontbreekt goede ondersteuning en kwaliteit. Volks wilt een balans bieden tussen een eerlijke prijs, goede customer support en topkwaliteit.  
  &lt;/p&gt;&lt;br&gt;&lt;br&gt;
        &lt;div class="icon mobile-only"&gt;&lt;i class="fa fa-users fa-icon" aria-hidden="true"&gt;&lt;/i&gt;&lt;/div&gt;
        &lt;h1 class=" mobile-only"&gt;En nu voor iedereen&lt;/h1&gt;
        &lt;p class=" mobile-only"&gt;Het is bijna zover. Binnenkort start de crowdfunding-campagne en hier hebben we jouw hulp hard bij nodig. Tijdens deze campagne kom je in de gelegenheid een pre-order te plaatsen. Slechts een gelimiteerd aantal Volks toestellen zijn beschikbaar tijdens de voorverkoop. 
  &lt;/p&gt;
          &lt;/div&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/section&gt;
    &lt;section class="introdcutie desktop-only" id="introductie-2"&gt;
      &lt;div class="text-container" id="text-2"&gt;
        &lt;div class="icon mobile-only"&gt;&lt;i class="fa fa-users fa-icon" aria-hidden="true"&gt;&lt;/i&gt;&lt;/div&gt;
        &lt;h1&gt;En nu voor iedereen&lt;/h1&gt;
        &lt;p&gt;Het is bijna zover. Binnenkort start de crowdfunding-campagne en hier hebben we jouw hulp hard bij nodig. Tijdens deze campagne kom je in de gelegenheid een pre-order te plaatsen. Slechts een gelimiteerd aantal Volks toestellen zijn beschikbaar tijdens de voorverkoop. 
  &lt;/p&gt;
      &lt;/div&gt;
      &lt;div class="image-container " id="image-2"&gt;
        &lt;img src="media/image-2.png"&gt;
      &lt;/div&gt;
  
      
    &lt;/section&gt;
    &lt;section id="eind"&gt;
        &lt;div class="align-center center-text coming-soon eind-block"&gt;
          &lt;p&gt;Meer info over de datum en technische specificaties volgt binnenkort op onze Facebookpagina.&lt;/p&gt;
          &lt;h1 class=""&gt;Volks&lt;i class="fa fa-copyright" aria-hidden="true" style="font-size:15px;"&gt;&lt;/i&gt; &lt;br&gt; December 2017&lt;/h1&gt;
          &lt;div class="social-media"&gt;
            &lt;ul&gt;
              &lt;li&gt;
                &lt;a href=""&gt;&lt;i class="fa fa-facebook" aria-hidden="true"&gt;&lt;/i&gt;&lt;/a&gt;
              &lt;/li&gt;
              &lt;li&gt;
                &lt;a href=""&gt;&lt;i class="fa fa-instagram" aria-hidden="true"&gt;&lt;/i&gt;&lt;/a&gt;
              &lt;/li&gt;
            &lt;/ul&gt;
          &lt;/div&gt;
      &lt;/div&gt;
    &lt;/section&gt;
    &lt;a id="disclaimer" href="disclaimer.html"&gt;disclaimer&lt;/a&gt;
    &lt;!-- ==== scripts ==== --&gt;
    &lt;script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'&gt;&lt;/script&gt;
    &lt;script src='https://cdnjs.cloudflare.com/ajax/libs/gsap/1.16.0/TweenMax.min.js'&gt;&lt;/script&gt;
    &lt;script src='https://cdnjs.cloudflare.com/ajax/libs/ScrollMagic/2.0.3/ScrollMagic.js'&gt;&lt;/script&gt;
    &lt;script src='https://cdnjs.cloudflare.com/ajax/libs/ScrollMagic/2.0.3/plugins/animation.gsap.min.js'&gt;&lt;/script&gt;
    &lt;script src='https://cdnjs.cloudflare.com/ajax/libs/ScrollMagic/2.0.2/plugins/debug.addIndicators.min.js'&gt;&lt;/script&gt;
    &lt;!-- ==== CUSTOM JS ==== --&gt;
    &lt;script src="scripts/index.js"&gt;&lt;/script&gt;
  &lt;/body&gt;
  &lt;/html&gt;</code></pre>
  </div>
  </div>
  </p>