cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

Quick-add: + add another resource

Code Indentation

     

Save Automatically?

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.

            
              <figure>
  <div class="blur-img bg-img" style="background-image:url(https://drive.google.com/uc?export=view&id=0B_koKn2rKOkLbWRGcFNwT0hGa28);"></div>
  <figcaption>
    <h2>Normal Blurred Image</h2>
    <p>With inline background-image property.</p>
  </figcaption>
</figure>
<figure>
  <div class="blur-img bg-img fix" style="background-image:url(https://drive.google.com/uc?export=view&id=0B_koKn2rKOkLbWRGcFNwT0hGa28);"></div>
  <figcaption>
    <h2>Sharpen Blurred Edges</h2>
    <p>With inline background-image property.</p>
  </figcaption>
</figure>
<figure>
  <img src="https://drive.google.com/uc?export=view&id=0B_koKn2rKOkLbWRGcFNwT0hGa28" class="blur-img img-tag" />
  <figcaption>
    <h2>Normal Blurred Image</h2>
    <p>With img tag.</p>
  </figcaption>
</figure>
<figure>
  <img src="https://drive.google.com/uc?export=view&id=0B_koKn2rKOkLbWRGcFNwT0hGa28" class="blur-img img-tag fix" />
  <figcaption>
    <h2>Sharpen Blurred Edges</h2>
    <p>With img tag.</p>
  </figcaption>
</figure>
            
          
!
            
              // ******************************
// Normalize (ignore me!)
// ******************************
@import "compass";
@import "compass/css3";
@import url(//fonts.googleapis.com/css?family=Lato:300);
$fonts:Lato,Arial,"Hiragino Kaku Gothic Pro W3",Meiryo,sans-serif;
$bg_color:#fff;
$font_color:#666;
$link_color:#666;
$link_hover_color:#888;

*, *:before, *:after{
  box-sizing:border-box;
  padding:0;
  margin:0;
}
body{
  font-family:$fonts;
  background-color:$bg_color;
  color: $font_color;
  text-align: center;
  font-size:14px;
  a, a:visited{
    color: $link_color;
    text-decoration:none;
  }
  a:hover{
    color: $link_hover_color;
  }
}
// ******************************
// End of Normalize
// ******************************

figure {
  position:relative;
  overflow:hidden;
  display:inline-block;
  width:46vw;
  height:28vw;
  margin-top:2vw;
  &:nth-child(2n+1){
    margin-right:2vw;
  }
  
  .blur-img{
    position:absolute;
    top:0;
    right:0;
    bottom:0;
    left:0;
    @include filter(blur(10px));
    &.bg-img{
      background-position:center;
      background-size:cover;
    }
    &.img-tag{
      width:100%;
      &.fix{
        width:calc(100% + 20px);
      }
    }
    &.fix{
      margin:-10px;
    }
  }

  figcaption {
    position:relative;
    display:table-cell;
    vertical-align:middle;
    width:46vw;
    height:28vw;
    color:#fff;
    text-shadow:0 2px 8px rgba(#000,.52);

    h2 {
      font-size:28px;
      margin-bottom:2vw;
    }
  }
}
            
          
!
999px
Loading ..................

Console