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


Babel includes JSX processing.

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


Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.


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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.


                <div class="container">
  <div class="popup">
    <div class="popup-content">
      <h2 class="popup-title">Awesome!</h2>
      <p class="popup-body">You just found my pastel gradient button.<br> Now, let's see what else it does. :P </p>
      <a href="#0" class="popup-button">Hover me</a>


                @import url('');

// Colors
$blue: #32325d;
$gray: #F5F6FA;
$dark-gray: #6b7c93;
$white: #fff;
$border-rounded: 6px;

// Mobile first
*::after { 
  box-sizing: border-box;

// Styling 
html {
  background-color: $gray;
body {
  padding: 1rem 0.5rem;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-family: 'Raleway',Sans-serif;

// Flexbox container
.container {
  display: flex;
  -webkit-display: box;
  -moz-display: box;
  -ms-display: flexbox;
  -webkit-display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-content: center;
  padding: 6%;
  margin: 0;

// Popup UI
.popup {
  display: flex;
  align-content: center;
  justify-content: center;
  background-color: $white;
  border-radius: $border-rounded;
  padding: 3rem 2rem;
  box-shadow: 0 10px 40px -14px rgba(0,0,0,0.25);
  text-align: center;
// Popup Texts & button
  .popup-content {
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;

  .popup-title {
    color: $blue;
    font-size: 1.8em;
    line-height: 1.5em;
    font-weight: 900;
    margin-top: 0;

  .popup-body {
    font-size: 1.1em;
    line-height: 1.6em;
    color: $dark-gray;
    font-weight: 500;
    margin-bottom: 2.1em;
  //Button Link
  .popup-button {
    display: block;
    text-align: center;
    text-decoration: none;
    font-weight: 800;
    font-size: 1em;
    text-transform: uppercase;
    color: $white;
    //Button shape & animation
    border-radius: $border-rounded;
    margin: 10px;
    padding: 1em 3em;
    background-size: 200% auto;
    color: white;
    box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);
    background-image: linear-gradient(to right, #895cf2 0%, #ffabf4 50%, #895cf2 100%);
    transition: 0.5s;
    &:hover {
      background-position: right center;