Div com desfoque
by Felype Rennan
HTML
<div id="bg">
<div id="search-container">
<div id="search-bg"></div>
<div id="search">
<h2>Olá internet!</h2>
<h5><a href="http://jordanhollinger.com/2014/01/29/css-gaussian-blur-behind-a-translucent-box/">#Partiu »</a></h5>
</div>
</div>
</div>
CSS
#bg, #search-bg {
background-image: url('http://previews.123rf.com/images/luckybusiness/luckybusiness1406/luckybusiness140600109/29055989-Office-supplies-gadgets-on-wooden-table-top-view-Stock-Photo-desk.jpg');
background-repeat: no-repeat;
background-size: 1080px auto;
}
#bg {
background-position: center top;
padding: 70px 90px 120px 90px;
}
#search-container {
position: relative;
}
#search-bg {
/* Absolutely position it, but stretch it to all four corners, then put it just behind #search's z-index */
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
z-index: 99;
/* Pull the background 70px higher to the same place as #bg's */
background-position: center -70px;
-webkit-filter: blur(4px);
filter: url('/media/blur.svg#blur');
filter: blur(10px);
}
#search {
/* Put this on top of the blurred layer */
position: relative;
z-index: 100;
padding: 20px;
background: rgb(34,34,34); /* for IE */
background: rgba(34,34,34,0.35);
}
@media (max-width: 600px ) {
#bg { padding: 10px; }
#search-bg { background-position: center -10px; }
}
#search h2, #search h5, #search h5 a { text-align: center; color: #fefefe; font-weight: normal; }
#search h2 { margin-bottom: 50px }
#search h5 { margin-top: 70px }