Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

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

Packages

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.

Behavior

Auto Save

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.

HTML

              
                <div class="wrapper-card">
    <div class="card">
        <div class="card-title">
            <h3>Basic</h3>
            <h4>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</h4>
        </div>
        <div class="card-price">
            <h1>
                <sup>&dollar;</sup>
                12
                <small>month</small>
            </h1>
        </div>
        <div class="card-description">
            <ul>
                <li>Lorem ipsum dolor sit amet</li>
                <li>Pellentesque hendrerit</li>
                <li>Aliquam at orci aliquam</li>
                <li>Praesent non sapien laoreet</li>
            </ul>
        </div>
        <div class="card-action">
            <button type="button">Get Basic</button>
        </div>
    </div>
    <div class="card popular">
        <div class="card-ribbon">
            <span>most popular</span>
        </div>
        <div class="card-title">
            <h3>Pro</h3>
            <h4>Maecenas ut justo molestie, pharetra arcu ac, mollis est.</h4>
        </div>
        <div class="card-price">
            <h1>
                <sup>&dollar;</sup>
                15
                <small>month</small>
            </h1>
        </div>
        <div class="card-description">
            <ul>
                <li>Lorem ipsum dolor sit amet</li>
                <li>Pellentesque hendrerit</li>
                <li>Aliquam at orci aliquam</li>
                <li>Praesent non sapien laoreet</li>
            </ul>
        </div>
        <div class="card-action">
            <button type="button">Get Pro</button>
        </div>
    </div>
    <div class="card">
        <div class="card-title">
            <h3>Premium</h3>
            <h4>Duis quis sem auctor, convallis felis vitae, placerat sapien.</h4>
        </div>
        <div class="card-price">
            <h1>
                <sup>&dollar;</sup>
                20
                <small>month</small>
            </h1>
        </div>
        <div class="card-description">
            <ul>
                <li>Lorem ipsum dolor sit amet</li>
                <li>Pellentesque hendrerit</li>
                <li>Aliquam at orci aliquam</li>
                <li>Praesent non sapien laoreet</li>
            </ul>
        </div>
        <div class="card-action">
            <button type="button">Get Premium</button>
        </div>
    </div>
</div>
              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Lato:700);

body {
    font-family: 'lato', sans-serif;
    -webkit-font-smoothing: antialiased;
    background: linear-gradient(35deg, #84fab0, #8fd3f4);
    padding: 0;
    margin: 0;
    height: 100vh;
}

.wrapper-card {
    display: flex;
    flex-wrap: nowrap;
    margin: 40px auto;
    width: 77%;
}
.card {
    background: #fff;
    border-radius: 3px;
    box-shadow: 0 1px 1px rgba(0,0,0,0);
    flex: 1;
    margin: 8px;
    padding: 30px;
    position: relative;
    text-align: center;
    transition: all 0.5s ease-in-out;
    &.popular {
        margin-top: -10px;
        margin-bottom: -10px; 
        .card-title {
            h3 {
                color: #3498db;
                font-size: 22px;
            }
        }
        .card-price {
            margin: 50px;
            h1 {
                color: #3498db;
                font-size: 60px;
            }
        }
        .card-action {
            button {
                background-color: #3498db;
                border-radius: 80px;
                color: #fff;
                font-size: 17px;
                margin-top: -15px;
                padding: 15px;
                height: 80px;
                &:hover {
                    background-color: darken(#3498db,7);
                    font-size: 23px;
                }
            }
        }
    }
    &:hover {
        box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    }
}
.card-ribbon {
    position: absolute;
    overflow: hidden;
    top: -10px;
    left: -10px;
    width: 114px;
    height: 112px;
    span {
        position: absolute;
        display: block;
        width: 160px;
        padding: 10px 0;
        background-color: #3498db;
        box-shadow: 0 5px 5px rgba(0,0,0,0.2);
        color: #fff;
        font-size: 13px;
        text-transform: uppercase;
        text-align: center;
        left: -35px;
        top: 25px;
        transform: rotate(-45deg);
    }
    &::before,
    &::after {
        position: absolute;
        z-index: -1;
        content: '';
        display: block;
        border: 5px solid #2980b9;
        border-top-color: transparent;
        border-left-color: transparent;
    }
    &::before {
        top: 0;
        right: 0; 
    }
    &::after {
        bottom: 0;
        left: 0;
    }
}

.card-title {
    h3 {
        color: rgba(0,0,0,0.3);
        font-size: 15px;
        text-transform: uppercase;
    }
    h4 {
        color: rgba(0,0,0,0.6);
    }
}
.card-price {
    margin: 60px 0;
    h1 {
        font-size: 46px;
        sup{
            font-size: 15px;
            display: inline-block;
            margin-left: -20px;
            width: 10px;
        }
        small {
            color: rgba(0,0,0,0.3);
            display: block;
            font-size: 11px;
            text-transform: uppercase;
        }
    }
}
.card-description {
    ul {
        display: block;
        list-style: none;
        margin: 60px 0;
        padding: 0;
    }
    li {
        color: rgba(0,0,0,0.6);
        font-size: 15px;
        margin: 0 0 15px;
        &::before {
            content: "\2714";
            padding: 0 5px 0 0;
            color: rgba(0,0,0,0.15);
        }
    }
}
.card-action {
    button {
        background: transparent;
        border: 2px solid #3498db;
        border-radius: 30px;
        color: #3498db;
        cursor: pointer;
        display: block;
        font-size: 15px;
        font-weight: bold;
        padding: 20px;
        width: 100%;
        height: 60px;
        text-transform: uppercase;
        transition: all 0.3s ease-in-out;
        &:hover {
            background-color: #3498db;
            box-shadow: 0 2px 4px darken(#3498db,20);
            color: #fff;
            font-size: 17px;
        }
    }
}

              
            
!

JS

              
                
              
            
!
999px

Console