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.

            
              <div class="maxcontainer">
  <div class="thebutton progressive">
    <div class="box bloomtech-box">

      <div class="bloomtech">
        <span>This is a Headline Button</span>
      </div>
      <div class="bloomtech-image">
        <img src="http://uibuttons.com/images/tech1.jpg">
      </div>
    </div>
    <div class="desccontainer">
      <a class="desc left" target="_blank" href="http://uibuttons.com/">uibuttons</a>
      <a class="desc right" target="_blank" href="#">Code</a>
    </div>
  </div>

  <div class="thebutton info">
    <div class="boxinformation">
      <h1>Bloomberg Technology</h1>
      <p>There's some sneaky little tricks to this seemingly simple text background.</p>
      <p>First of all, the white space on the right is NOT natural. They've secretly used a drop shadow. Secondly, Firefox requires CSS property that I've never seen before for this to even work. The “box-decoration-break: clone;” ...WTF? Learn more about it <a target="_blank" href="https://css-tricks.com/almanac/properties/b/box-decoration-break/">here</a>.
        <p>Thanks
          <a target="_blank" href="http://www.bloomberg.com/technology">Bloomberg Technology</a>.
        </p>
    </div>

  </div>

</div>
            
          
!
            
              /*** Container ****/

.box.bloomtech-box {
  background-image: linear-gradient(to bottom, rgba(255, 255, 255, 0), #FFF), url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAGCAYAAADgzO9IAAAAG0lEQVQYV2NkYGAwZmBgOMuABhjRBWB8ekgAAJFvAQfdnkk1AAAAAElFTkSuQmCC), url(http://uibuttons.com/images/tech-homepage-background-b985eb14ee.svg);
  background-size: 100% 100px, auto, auto;
  background-repeat: no-repeat, repeat, no-repeat;
  background-position: bottom, top, center top;
}


/*** Button Code ****/

.bloomtech {
  position: absolute;
  color: rgb(38, 38, 38);
  font-size: 46px;
  line-height: 55px;
  font-family: 'Roboto', sans-serif;
  font-weight: 900;
  display: block;
  width: 70%;
  top: 40%;
  transform: translateY(-60%);
  z-index: 100;
}

.bloomtech span {
  background-color: #fff;
  display: inline;
  transition: all .2s ease-out;
  box-shadow: .625rem 0 0 #FFF;
  box-decoration-break: clone;
}

.bloomtech-box:hover .bloomtech span {
  color: #fff;
  background-color: #00C88A;
  box-shadow: .625rem 0 0 #00C88A;
}

.bloomtech-image {
  position: absolute;
  width: 70%;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
}

.bloomtech-image img {
  width: 100%;
}


/*** Foundation Code ****/

body {
  background-color: #f4f4f4;
  font-family: "Roboto", sans-serif;
}

a {
  text-decoration: none;
}

.maxcontainer {
  width: 100%;
  max-width: 1100px;
  margin: auto;
  overflow: auto;
}

@media screen and (min-width: 750px) {
  .maxcontainer {
    padding: 0;
  }
}

.thebutton {
  float: left;
  width: 95%;
  margin: 2.5% 2.5% 0 2.5%;
  position: relative;
  border-radius: 2px;
  overflow: hidden;
  -webkit-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.1);
  -moz-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.1);
  box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0.1);
}

@media screen and (min-width: 750px) {
  .thebutton {
    width: 47.5%;
    margin: 2.5% 1.25% 0 1.25%;
  }
}

.box {
  overflow: hidden;
  width: 100%;
  margin: auto;
  height: 0;
  position: relative;
  padding-bottom: 70%;
}

@media screen and (min-width: 650px) {
  .box {}
}

.desccontainer {
  position: relative;
  width: 100%;
  background: rgba(255, 255, 255, 1);
  float: left;
}

.desc {
  float: left;
  font-size: 11px;
  font-weight: 900;
  padding: 10px 0;
  letter-spacing: .25px;
  text-align: center;
  color: #bcbcbc;
  opacity: 1;
  z-index: 2000;
  background: rgba(255, 255, 255, 1);
  transition: all .1s ease-in-out;
  -o-transition: all .1s ease-in-out;
  -moz-transition: all .1s ease-in-out;
  -webkit-transition: all .1s ease-in-out;
}

.desc.left {
  width: 49.7%;
  margin-right: .3%;
  -webkit-box-shadow: 1px 0px 0px 0px rgba(235, 235, 235, 1);
  -moz-box-shadow: 1px 0px 0px 0px rgba(235, 235, 235, 1);
  box-shadow: 1px 0px 0px 0px rgba(235, 235, 235, 1);
}

.desc.right {
  width: 50%;
}

.boxinformation {
  background: none;
  color: #000;
  font-weight: 200;
  width: 100%;
  margin: auto;
  position: relative;
}

.boxinformation a {
  color: #000;
  opacity: .4;
  font-weight: bold;
  text-decoration: underline;
}

.boxinformation a:hover {
  opacity: 1;
}

.thebutton.info {
  -webkit-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0);
  -moz-box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0);
  box-shadow: 0px 0px 3px 0px rgba(0, 0, 0, 0);
}
            
          
!
999px
Loading ..................

Console