Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div class="fullscreen">
  <div class="container">
    <div class="card card_1">
      <div class="date">
        11 June 2018
                <span class="tv_ico"><img src="http://www.cartaodental.com/nbase/image/pc.svg"></span>
      </div>
      <div class="content">
        <div class="title">
          La Casa de Papel
        </div>
        <div class="text">
          The most watch series in 2018, dont you miss any episode on Netflix!
        </div>
      </div>
      <div class="sinopse">
                  
          <iframe id="ytplayer" type="text/html" data-video="https://www.youtube.com/embed/ZAXA1DV4dtI?autoplay=1&autohide=2&border=0&wmode=opaque&enablejsapi=1&modestbranding=1&controls=0&showinfo=1&mute=1"
  src="" frameborder="0" autoplay allowfullscreen></iframe>
        
        <div class="content-sinopse">          
          <div class="title">Series Synopsis</div>
          <div class="text">Lorem ipsum dolor sit amet, consectetur adipiscing elit. In in hendrerit nulla, sed congue lorem. Phasellus sollicitudin tortor dui, id scelerisque ipsum ultrices vitae. Cras sed laoreet odio, vel ornare enim. Quisque porta quam at augue posuere, id luctus velit ullamcorper. Aenean sapien ligula, malesuada in mollis eu, vestibulum ut quam.
          </div>
        </div>
        <div class="view series_lacasa"> Watch Full Series </div>
      </div>
    </div>
    <div class="card card_2">
 <div class="date">
        16 April 2019
                <span class="tv_ico"><img src="http://www.cartaodental.com/nbase/image/pc.svg"></span>
      </div>
      <div class="content">
        <div class="title">
          Game Of Thrones
        </div>
        <div class="text">
          For alot of people the best series ever created, the most proud son of HBO!
        </div>
      </div>
      <div class="sinopse">
        
          <iframe id="ytplayer" type="text/html" data-video="https://www.youtube.com/embed/giYeaKsXnsI?autoplay=1&autohide=2&border=0&wmode=opaque&enablejsapi=1&modestbranding=1&controls=0&showinfo=1&mute=1"
  src="" frameborder="0" autoplay allowfullscreen></iframe>
        
        <div class="content-sinopse">
          <div class="title">Series Synopsis</div>
          <div class="text">Lorem ipsum dolor sit amet, consectetur adipiscing elit. In in hendrerit nulla, sed congue lorem. Phasellus sollicitudin tortor dui, id scelerisque ipsum ultrices vitae. Cras sed laoreet odio, vel ornare enim. Quisque porta quam at augue posuere, id luctus velit ullamcorper. Aenean sapien ligula, malesuada in mollis eu, vestibulum ut quam.
          </div>
        </div>
        <div class="view series_got"> Watch Full Series </div>
      </div>
    </div>
    <div class="card card_3">
 <div class="date">
        22 October 2018
                <span class="tv_ico"><img src="http://www.cartaodental.com/nbase/image/pc.svg"></span>
      </div>
      <div class="content">
        <div class="title">
          Vikings
        </div>
        <div class="text">
          One of the best series about Vikings and their way of living dont miss it!
        </div>
      </div>
      <div class="sinopse">
          
          <iframe class="vikings" data-video="https://www.youtube.com/embed/9GgxinPwAGc?autoplay=1&autohide=2&border=0&wmode=opaque&enablejsapi=1&modestbranding=1&controls=0&showinfo=1&mute=1" id="ytplayer" type="text/html"
  src="" frameborder="0" autoplay allowfullscreen></iframe>
        
        <div class="content-sinopse">
          <div class="title">Series Synopsis</div>
          <div class="text">Lorem ipsum dolor sit amet, consectetur adipiscing elit. In in hendrerit nulla, sed congue lorem. Phasellus sollicitudin tortor dui, id scelerisque ipsum ultrices vitae. Cras sed laoreet odio, vel ornare enim. Quisque porta quam at augue posuere, id luctus velit ullamcorper. Aenean sapien ligula, malesuada in mollis eu, vestibulum ut quam.
          </div>
        </div>
        <div class="view series_vikings"> Watch Full Series </div>
      </div>
    </div>
  </div>
</div>

<div class="fullserie">
  <div class="close"><img src="http://www.cartaodental.com/nbase/image/close.svg"></div>  

  <div class="episodes">
    <div class="episode episode_1" data-lacasa="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616580.jpg" data-got="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-43195.jpg" data-vikings="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-504732.png">

    </div>
    <div class="episode episode_2" data-lacasa="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616580.jpg" data-got="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-43195.jpg" data-vikings="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-504732.png">

    </div>
    <div class="episode episode_3" data-lacasa="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616580.jpg" data-got="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-43195.jpg" data-vikings="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-504732.png">

    </div>
     <div class="episode episode_4" data-lacasa="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616580.jpg" data-got="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-43195.jpg" data-vikings="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-504732.png">

    </div>
     <div class="episode episode_5" data-lacasa="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616580.jpg" data-got="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-43195.jpg" data-vikings="https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-504732.png">

    </div>
  </div>

</div>
              
            
!

CSS

              
                *{
  box-sizing:border-box;
}
body{
  overflow-x:hidden;
  margin:0;
  padding:0;
  font-family:'Sunflower';
}

.fullscreen {
  width:100vw;
  height:100vh;
  background:#ffcc11;
  .container {
    padding:15px;
    max-width:1200px;
    margin:auto;
    height:100%;
    display:flex;
    align-items:center;
    justify-content:space-between;
    .card {
      overflow:hidden;
      width:30%;
      height:70%;
      background:#fff;
      box-shadow:1px 22px 44px rgba(0,0,0,.19);
      transition:0.6s;
      border-radius:2px;
      position:relative;
      display:flex; 
      &:hover {
        transform:translateY(-15px);
        box-shadow:1px 12px 34px rgba(0,0,0,.31);
        .sinopse{
          opacity:1;
          transition-delay:0.4s;
          .view{
            opacity:1;
            transform:translateY(0%);
            transition:0.6s;
            transition-delay:1s;
          }
          .content-sinopse {
            .text{
              transform:translateY(0);
              transition-delay:0.6s;
            }
            .title {
              transform:translateY(0);
              transition-delay:0.2s;
            }
          }
        }
        .date{
          transform:translateY(-100%);
          opacity:0;
        }
        .content{
            transform:translateY(100%);
            opacity:0;
        }
      }
      .date{
        position:absolute;
        top:25px;
        right:25px;
        color:#fff;
        font-weight:300;
        font-size:14px;
        transition:0.8s;
        .tv_ico {
          img {
            width:12px;
            vertical-align:baseline;
            margin-left:6px;
          }
        }
      }
      .content{
        transition:0.8s;
        display:flex;
        flex-wrap:wrap;
        align-self:flex-end;
        padding:25px 25px 50px 25px;
        .title{
          width:100%;
          color:#fff;
          font-size:44px;
          font-weight:700;
          line-height:50px;
          margin-bottom:12px;
        }
        .text{
          width:100%;
          color:#fff;
          font-size:16px;
          font-weight:300;
        }
      }
      .sinopse {
        width:100%;
        height:100%;
        position:absolute;
        top:0;
        left:0;
        padding:25px 25px 50px 25px;
        background:rgba(0,0,0,.78);
        color:#fff;
        font-weight:300;
        opacity:0;
        transition:0.8s;
        display:flex;
        align-items:flex-end;
        flex-wrap:wrap;
        iframe {
          position: absolute;
          top: 0;
          width: 100%;
          margin-left: -30px;
          height: 260px;
        }
        .view {
          position:absolute;
          bottom:15px;
          right:25px;
          color:#fff;
          font-size:14px;
          border-bottom:1px solid #fff;
          opacity:0;
          transform:translateY(100%);
          transition:0.6s;
          cursor:pointer;
        }
        .content-sinopse{
          .title{
            color:rgba(255,255,255,.6);
            font-size:22px;
            font-weight:700;
            margin-bottom:12px;
            transform:translateY(-100%);
            transition:0.6s;
          }
          .text{
            transform:translateY(100%);
            transition:0.6s;
            color:rgba(255,255,255,.6);
            font-weight:300;
            font-size:14px;
          }
        }
      }
      &_1 {
  background:url('https://w.wallhaven.cc/full/j8/wallhaven-j8gqyq.jpg') no-repeat center/cover;
      }
      &_2 {
  background:url('https://w.wallhaven.cc/full/5d/wallhaven-5dpo51.jpg') no-repeat 45%/cover;
      }
      &_3 {
        background:linear-gradient(to bottom, rgba(0,0,0,.75),rgba(0,0,0,0), rgba(0,0,0,.88)),url('https://w.wallhaven.cc/full/43/wallhaven-43y676.jpg') no-repeat center/cover;
      }
    }
  }
}


.fullserie {
  background-color: #333;
  -webkit-clip-path: circle(0% at 0 100%);
  clip-path: circle(0% at 0 100%);
  min-height:550px;
  width:100vw;
  height:100vh;
  position:fixed;
  top:0;
  left:0;
  transition:.6s;
  &.active {
    background-color: #333;
    transition:.6s;
    transition-delay:0.45s;
    -webkit-clip-path: circle(270% at 220px 88%);
    clip-path: circle(270% at 220px 88%);
  }
  .close {
    position:absolute;
    right:5px;
    top:5px;
    height:50px;
    width:50px;
    display:flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
    img {
      width:22px;
    }
  }
  .episodes {
    display:grid;
    grid-template-columns:repeat(auto-fill, minmax(260px, 1fr));
    grid-template-rows:repeat(4, minmax(230px, auto));
    grid-gap:30px;
    grid-auto-flow:dense;
    grid-auto-rows:minmax(260px, auto);
    width:100%;
    height:100%;
    padding:60px 60px 120px 60px;
    .episode {
   background:red;
    }
  }
}

@media(min-width:580px) and (max-width:992px){
  .fullscreen {
    height:auto;
    .container {
      flex-wrap:wrap;
      justify-content:space-evenly;
      
      .card {
        overflow:hidden;
        width:45%;
        height:400px;
        background:#fff;
        box-shadow:1px 22px 44px rgba(0,0,0,.19);
        transition:0.6s;
        border-radius:2px;
        position:relative;
        display:flex;
        margin-bottom:10%;
        &:nth-child(-n+2){
          margin-top:10%;
        }
        .content{
          .title{
            width:100%;
            color:#fff;
            font-size:28px;
            font-weight:700;
            line-height:36px;
            margin-bottom:12px;
          }
          .text{
            width:100%;
            color:#fff;
            font-size:14px;
            font-weight:300;
          }
        }
        .sinopse {
          width:100%;
          height:100%;
          position:absolute;
          top:0;
          left:0;
          padding:25px 25px 50px 25px;
          background:rgba(0,0,0,.78);
          color:#fff;
          font-weight:300;
          opacity:0;
          transition:0.8s;
          display:flex;
          align-items:flex-end;
          flex-wrap:wrap;
          iframe {
            position: absolute;
            top: 0;
            width: 100%;
            margin-left: -30px;
            height: 260px;
          }
          .view {
            position:absolute;
            bottom:15px;
            right:25px;
            color:#fff;
            font-size:14px;
            border-bottom:1px solid #fff;
            opacity:0;
            transform:translateY(100%);
            transition:0.6s;
            cursor:pointer;
          }
          .content-sinopse{
            .title{
              color:rgba(255,255,255,.6);
              font-size:22px;
              font-weight:700;
              margin-bottom:12px;
              transform:translateY(-100%);
              transition:0.6s;
            }
            .text{
              transform:translateY(100%);
              transition:0.6s;
              color:rgba(255,255,255,.6);
              font-weight:300;
              font-size:14px;
            }
          }
        }
        &_1 {
          background:url('https://w.wallhaven.cc/full/j8/wallhaven-j8gqyq.jpg') no-repeat center/cover;
        }
        &_2 {
          background:linear-gradient(to bottom, rgba(0,0,0,0),rgba(0,0,0,0), rgba(0,0,0,.98)),url('https://w.wallhaven.cc/full/5d/wallhaven-5dpo51.jpg') no-repeat 45%/cover;
        }
        &_3 {
          background:linear-gradient(to bottom, rgba(0,0,0,.75),rgba(0,0,0,0), rgba(0,0,0,.88)),url('https://w.wallhaven.cc/full/43/wallhaven-43y676.jpg') no-repeat center/cover;
        }
      }
    }
  }
}


@media(min-width:320px) and (max-width:580px){
  .fullscreen {
    height:auto;
    .container {
      flex-wrap:wrap;
      .card {
      overflow:hidden;
      width:90%;
      height:400px;
      background:#fff;
      box-shadow:1px 22px 44px rgba(0,0,0,.19);
      transition:0.6s;
      border-radius:2px;
      position:relative;
      display:flex;
        margin-bottom:10%;
        .content{
          .title{
            width:100%;
            color:#fff;
            font-size:28px;
            font-weight:700;
            line-height:36px;
            margin-bottom:12px;
          }
          .text{
            width:100%;
            color:#fff;
            font-size:14px;
            font-weight:300;
          }
        }
        .sinopse {
          width:100%;
          height:100%;
          position:absolute;
          top:0;
          left:0;
          padding:25px 25px 50px 25px;
          background:rgba(0,0,0,.78);
          color:#fff;
          font-weight:300;
          opacity:0;
          transition:0.8s;
          display:flex;
          align-items:flex-end;
          flex-wrap:wrap;
          iframe {
            position: absolute;
            top: 0;
            width: 100%;
            margin-left: -30px;
            height: 260px;
          }
          .view {
            position:absolute;
            bottom:15px;
            right:25px;
            color:#fff;
            font-size:14px;
            border-bottom:1px solid #fff;
            opacity:0;
            transform:translateY(100%);
            transition:0.6s;
            cursor:pointer;
          }
          .content-sinopse{
            pointer-events:none;
            .title{
              color:rgba(255,255,255,.6);
              font-size:22px;
              font-weight:700;
              margin-bottom:12px;
              transform:translateY(-100%);
              transition:0.6s;
            }
            .text{
              pointer-events:none;
              transform:translateY(100%);
              transition:0.6s;
              color:rgba(255,255,255,.6);
              font-weight:300;
              font-size:14px;
            }
          }
        }
        &_1 {
          background:url('https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-616574.jpg') no-repeat center/cover;
        }
        &_2 {
          background:url('https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-539333.png') no-repeat 45%/cover;
        }
        &_3 {
          background:linear-gradient(to bottom, rgba(0,0,0,.75),rgba(0,0,0,0), rgba(0,0,0,.88)),url('https://wallpapers.wallhaven.cc/wallpapers/full/wallhaven-5379.png') no-repeat center/cover;
        }
      }
    }
  }
}
              
            
!

JS

              
                $(".card").hover(function() {
  var vSrc =  $(this).find('iframe').data('video');
  var video = $(this).find('iframe');
  video.attr('src',vSrc);
  setTimeout(function(){ player.unMute(); }, 1000);
},
function() {
  $(this).find('iframe').attr('src','');
});

$('.view').click(function(){
  var el = $(this);
  
  if(el.hasClass('series_lacasa') == true){
    $('.episodes .episode').each(function(){
      var toShow = $(this).data('lacasa');
      $(this).css('background','url('+toShow+') no-repeat center/cover');
    });
  } else if (el.hasClass('series_got') == true) {
    $('.episodes .episode').each(function(){
      var toShow = $(this).data('got');
      $(this).css('background','url('+toShow+') no-repeat center/cover');
    });
  }  else if (el.hasClass('series_vikings') == true) {
    $('.episodes .episode').each(function(){
      var toShow = $(this).data('vikings');
      $(this).css('background','url('+toShow+') no-repeat center/cover');
    });
  }
    
  $('.fullserie').addClass('active');
});

$('.fullserie .close').click(function(){
  $('.fullserie').removeClass('active');
});
              
            
!
999px

Console