123

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <div class="grid">
  <div class="grid-item sideheader-first">
    <b>Dolorsit Amet</b> Lorem ipsum
  </div>
  <div class="grid-item sideheader-last">s. XX</div>
  <div class="grid-item headline">
    <h1>Lorem ipsum <span>dolor</span> sit amet.</h1></div>
  <div class="grid-item ingress">
    <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Leo urna molestie at elementum eu facilisis sed odio. Eget felis eget nunc lobortis mattis aliquam faucibus purus in. Consectetur libero id faucibus nisl tincidunt eget. At varius vel pharetra vel turpis.</p>
    <span class="author">
      <p>Written by: Rebecca Löfgren <br />
      Image source: Unsplash</p>   
     </span>
  </div>
  <div class="grid-item column-first">
    <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Leo urna molestie at elementum eu facilisis sed odio. Eget felis eget nunc lobortis mattis aliquam faucibus purus in. Consectetur libero id faucibus nisl tincidunt eget. At varius vel pharetra vel turpis. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Leo urna molestie at elementum eu facilisis sed odio. Eget felis eget nunc lobortis mattis aliquam faucibus purus in. Consectetur libero id faucibus nisl tincidunt eget. At varius vel pharetra vel turpis.</p>
  </div>
  <div class="grid-item column-second">
    <p>Metus aliquam eleifend mi in nulla posuere. Faucibus nisl tincidunt eget nullam non. Leo a diam sollicitudin tempor id. In nulla posuere sollicitudin aliquam ultrices sagittis orci a scelerisque. Nisi vitae suscipit tellus mauris a diam maecenas sed enim. Cursus mattis molestie a iaculis at erat pellentesque. Dui sapien eget mi proin sed libero enim sed. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Leo urna molestie at elementum eu facilisis sed odio. Eget felis eget nunc lobortis mattis aliquam faucibus purus in. Consectetur libero id faucibus nisl tincidunt eget. At varius vel pharetra vel turpis.</p>
  </div>
  <div class="grid-item image"></div>
  <div class="grid-item column-third">
    <p>Morbi blandit cursus risus at ultrices. Ridiculus mus mauris vitae ultricies leo. At imperdiet dui accumsan sit amet. Scelerisque in dictum non consectetur. Vel risus commodo viverra maecenas accumsan lacus vel facilisis volutpat.</p>
  </div>
  <div class="grid-item footer"></div>
</div>
            
          
!
            
              .grid {
  display: grid;
  grid-template-columns: [first] 1fr [second] 1fr [third] 1fr [fourth] 1fr [fifth] 1fr [sixth] 1fr; 
  grid-template-rows: [firstrow] auto [secondrow] auto [third] auto [fourth] auto [fifth] auto [sixth] auto;
  grid-gap: 10px 20px;
  grid-template-areas: 
   "sideheader-first sideheader-first sideheader sideheader sideheader-last sideheader-last"
  "headline headline headline image image image"
   "ingress ingress ingress image image image"
    "colfirst colfirst colsec colsec quote quote"
  "footer footer footer footer footer footer";
  margin: 20px auto;
  padding: 20px;
  max-width: 900px;
  box-shadow: 1px 1px 10px rgba(0,0,0,0.1);
}

.sideheader-first {
  grid-area: sideheader-first;
  align-self: end;
}
.sideheader-last {
  grid-area: sideheader-last;
  grid-column-end: sixth-end;
  align-self: end;
  text-align: right;
}

.headline {
  grid-area: headline;
}

.image {
  grid-area: image;
  background-image: url(https://images.unsplash.com/photo-1493770348161-369560ae357d?dpr=1&auto=compress,format&fit=crop&w=2100&h=&q=80&cs=tinysrgb&crop=);
  background-size: cover;
  height: 100%;
  min-height: 200px;
  width: 100%;
  grid-column-end: sixth-end;

}
.ingress {
  grid-area: ingress;
  padding: 30px 0px 50px;
}

.ingress p {
  font-size: 17px !important;
  font-style: italic;
  font-family: "playfair display" !important;
  line-height: 1.6em;
  text-align: center;
}

.author p {
  font-style: normal;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 12px !important;
  margin-top: 30px;
}
.column-first {
  grid-area: colfirst;
  text-align: justify;
}
.column-first:first-letter {
  font-size: 70px;
  line-height: 15px;
  padding: 10px;
  float: left;
  width: 40px;
  height: 30px;
  padding-top: 25px;
  display: block;
}
.column-second {
  grid-area: colsec;
  text-align: justify;
}
.column-third {
  grid-area: quote;
}

.column-third p {
  font-style: italic;
  font-size: 20px !important;
  font-family: "playfair display";
}
.grid-item{
  height: auto;
  width: 100%;
  font-family: "crimson text";
  font-size: 14px;
}

h1 {
  font-family: "playfair display";
  font-size: 4em;
  font-weight: 100;
  font-style: italic;
  line-height: 1em;
  text-align: center;
  margin-bottom: 0px !important;
  margin-top: 70px;
}

h1 span {
  font-style: normal;
  font-size: 3em !important;
  display: block;
  color: pink;
}

.footer {
  border-bottom:4px double black;
  grid-area: footer;
  grid-row-start: sixth-end;
}

@media (max-width: 900px) {
  .grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: 
     "sideheader-first sideheader-last"
      "image image"
      "headline headline"
      "ingress ingress"
      "colfirst colfirst"
      "quote quote"
      "colsec colsec"
      "footer footer";
}
  
  .grid-item {
    grid-column-end: unset-end;
  }

}

@media (max-width: 400px) {
  h1 {
    font-size: 3em;
    margin-top: 20px;
  }
  h1 span {
    font-size: 2em !important;
  }
  .ingress {
    padding: 0px;
  }
  .column-third {
    text-align: center;
  }
}
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.

Console