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.

            
              <section class="container">
  <div class="row">
    <article class="col">
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla commodo, diam ut tincidunt molestie, justo nulla pretium nulla, et condimentum nisl nulla in sapien. Vivamus dignissim vestibulum viverra. Quisque dolor ante, eleifend ut laoreet in, accumsan id dui. </p>
    </article><!--.col--> 
        <article class="col">
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla commodo, diam ut tincidunt molestie, justo nulla pretium nulla, et condimentum nisl nulla in sapien. Vivamus dignissim vestibulum viverra. Quisque dolor ante, eleifend ut laoreet in, accumsan id dui. </p>
    </article><!--.col--> 
        <article class="col">
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla commodo, diam ut tincidunt molestie, justo nulla pretium nulla, et condimentum nisl nulla in sapien. Vivamus dignissim vestibulum viverra. Quisque dolor ante, eleifend ut laoreet in, accumsan id dui. </p>
    </article><!--.col--> 
        <article class="col">
      <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla commodo, diam ut tincidunt molestie, justo nulla pretium nulla, et condimentum nisl nulla in sapien. Vivamus dignissim vestibulum viverra. Quisque dolor ante, eleifend ut laoreet in, accumsan id dui. </p>
    </article><!--.col--> 
    <div class="fancy"><h1>Retina Display</h1></div>
  </div>
</div>
            
          
!
            
              /* apply a natural box layout model to all elements, but allowing components to change */
html {
  box-sizing: border-box;
}
*, *:before, *:after {
  box-sizing: inherit;
}

/*Base CSS*/
body{font-family: 'Droid Serif';background:#B0B0B0;}
.fancy{display:none;}

.col {
  float:left;
  margin:1%;
  width:46%; 
  border-radius:8px;
  background-color:#5b7ea2;
  padding: 20px;
  color:#fff;
}

.col:nth-child(even){
  background-color:#002c58;
}
.col p{margin:0;}


/* -----------------------  Phone below 600px ---------------------*/
@media screen and (max-width:600px){
  body{padding:20px;}
  .col {
    float:none;
    width:100%;
    margin: 5% 0;
  }
}

/* ----------------------- Ranged Query ---------------------*/

@media screen and (max-width: 800px) and (min-width:601px){
  .col:nth-child(odd){
  background-color:green;
}
}




/* -----------------------  Desktop Above 800px ---------------------*/

@media screen and (min-width: 801px){
  .col{ 
  float:left;
  margin:1%;
  width:23%; 
  }


/*retina specific --- https://goo.gl/Pgu6y */

@media
only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and (   min--moz-device-pixel-ratio: 2),
only screen and (     -o-min-device-pixel-ratio: 2/1),
only screen and (        min-device-pixel-ratio: 2),
only screen and (                min-resolution: 192dpi),
only screen and (                min-resolution: 2dppx) 
{ 
.fancy{display:block; text-align:center}
}

  








            
          
!
999px
Loading ..................

Console

Open Chat