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 id="login-container">
    <div class="card">
        <div class="card-content">
            <div class="login-side card-front flex-column-list">
                <div class="main-title-container col-md-12 text-center">
                    Cool Login
                </div>

                <form class="container-default-padding">
                    <div class="input-group">
                        <span class="input-group-addon" id="username-addon"><i class="fa fa-user"></i></span>
                        <input id="username" type="text" class="form-control" name="username" placeholder="Username" required/>
                    </div>

                    <div class="input-group">
                        <span class="input-group-addon" id="password-addon"><i class="fa fa-lock"></i></span>
                        <input id="password" type="password" class="form-control" name="password" placeholder="Password" required />
                    </div>

                    <div class="form-group no-margin">
                        <button type="submit" class="btn btn-primary pull-right">
                            <span>Login</span>
                        </button>
                    </div>
                </form>

                <div class="col-md-12 container-default-padding text-center">
                    <a class="flip-card">Have you forgotten your password?</a>
                </div>
            </div>

            <div class="recover-password-side card-back flex-column-list">
                <div class="main-title-container col-md-12 container-default-padding text-center">
                    Cool Login
                </div>

                <form name="recoverAccountForm" class="container-default-padding" novalidate>
                    <div class="col-md-12 no-padding">
                        <label class="text-secondary-dark text-font-weight">Enter your email and we will send you a new password for your account</label>
                    </div>
                    <div class="input-group">
                        <span class="input-group-addon" id="email-addon"><i class="fa fa-envelope"></i></span>
                        <input id="email" type="text" class="form-control" name="email" placeholder="Email" required/>
                    </div>

                    <div class="form-group no-margin">
                        <button type="submit" class="btn btn-primary pull-right">
                            Send
                        </button>
                    </div>
                </form>

                <div class="col-md-12 container-default-padding text-center">
                    <a class="flip-card">Try to login again!</a>
                </div>
            </div>
        </div>
    </div>
</div>
              
            
!

CSS

              
                /** CONTAINER **/
#login-container {
    position: relative;
    float: left;
    width: 100%;
    height: 100vh;

    background: transparent; /* For browsers that do not support gradients */
    background: -webkit-radial-gradient(circle, #c4d9b2 -10%, #ebf2e5 60%, transparent 90%); /* Safari 5.1-6.0 */
    background: -o-radial-gradient(circle, #c4d9b2 -10%, #ebf2e5 60%, transparent 90%); /* For Opera 11.6-12.0 */
    background: -moz-radial-gradient(circle, #c4d9b2 -10%, #ebf2e5 60%, transparent 90%); /* For Firefox 3.6-15 */
    background: radial-gradient(circle, #c4d9b2 -10%, #ebf2e5 60%, transparent 90%); /* Standard syntax */
    perspective: 600px;
    -webkit-perspective: 600px;
    -moz-perspective: 600px;
    -o-perspective: 600px;
    -ms-perspective: 600px;
}
/** CONTAINER **/

/** CARD **/
.card {
    width: 375px;
    height: 450px;
    margin: 0 auto;
    margin-top: calc(50vh - 225px);
    transform-style: preserve-3d;
    transition: transform 1s;
    transform-origin: center center;
    background: transparent;
    border: none;
}

.card .card-content {
    position:relative;
    width: 100%;
    height: 100%;

    background: #609831; /* For browsers that do not support gradients */
    background: -webkit-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Safari 5.1-6*/
    background: -o-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Opera 11.1-12*/
    background: -moz-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Fx 3.6-15*/
    background: linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Standard*/

    transition: 0.5s ease-out;
    -webkit-transition: 0.5s ease-out;
    -moz-transition: 0.5s ease-out;
    -o-transition: 0.5s ease-out;
    -ms-transition: 0.5s ease-out;
    transform-style: preserve-3d;
    -webkit-transform-style: preserve-3d;
    -moz-transform-style: preserve-3d;
    -o-transform-style: preserve-3d;
    -ms-transform-style: preserve-3d;

    /* content backface is visible so that static content still appears */
    backface-visibility: visible;
    -webkit-backface-visibility: visible;
    -moz-backface-visibility: visible;
    -o-backface-visibility: visible;
    -ms-backface-visibility: visible;
}

.card.flipped .card-content {
    transform: rotateY(180deg);
    -webkit-transform: rotateY(180deg);
    -moz-transform: rotateY(180deg);
    -o-transform: rotateY(180deg);
    -ms-transform: rotateY(180deg);
}

.card .card-content .card-front,
.card .card-content .card-back {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    padding: 20px;
    border: 2px solid #4c7927;
}

.card.flipped .card-content .card-front,
.card .card-content .card-back {
    /* Backface visibility works great for all but IE. As such, we mark the backface visible in IE and manage visibility ourselves */
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    -moz-backface-visibility: hidden;
    -o-backface-visibility: hidden;
    -ms-backface-visibility: visible;
    position: absolute;
}

.card .card-content .card-front,
.card.flipped .card-content .card-front {
    transform: rotateY(0deg);
    -webkit-transform: rotateY(0deg);
    -moz-transform: rotateY(0deg);
    -o-transform: rotateY(0deg);
    -ms-transform: rotateY(0deg);
}

.card .card-content .card-back,
.card.flipped .card-content .card-back {
    transform: rotateY(-180deg);
    -webkit-transform: rotateY(-180deg);
    -moz-transform: rotateY(-180deg);
    -o-transform: rotateY(-180deg);
    -ms-transform: rotateY(-180deg);
}

.card .card-content .card-front,
.card.flipped .card-content .card-back {
    /* IE Hack. Halfway through the card flip, set visibility. Keep other browsers visible throughout the card flip. */
    animation: stayvisible 0.5s both;
    -webkit-animation: stayvisible 0.5s both;
    -moz-animation: stayvisible 0.5s both;
    -o-animation: stayvisible 0.5s both;
    -ms-animation: donothing 0.5s;
    -ms-transition: visibility 0s linear 0.17s;
    visibility: visible;
}
.card.flipped .card-content .card-front,
.card .card-content .card-back {
    /* IE Hack. Halfway through the card flip, set visibility. Keep other browsers visible throughout the card flip. */
    animation: stayvisible 0.5s both;
    -webkit-animation: stayvisible 0.5s both;
    -moz-animation: stayvisible 0.5s both;
    -o-animation: stayvisible 0.5s both;
    -ms-animation: donothing 0.5s;
    -ms-transition: visibility 0s linear 0.17s;
    visibility: hidden;

    background: #609831; /* For browsers that do not support gradients */
    background: -webkit-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Safari 5.1-6*/
    background: -o-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Opera 11.1-12*/
    background: -moz-linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Fx 3.6-15*/
    background: linear-gradient(-60deg, #609831 -50%, #ebf2e5 150%); /*Standard*/
}
@keyframes stayvisible { from { visibility: visible; } to { visibility: visible; } }
@-webkit-keyframes stayvisible { from { visibility: visible; } to { visibility: visible; } }
@-moz-keyframes stayvisible { from { visibility: visible; } to { visibility: visible; } }
@-o-keyframes stayvisible { from { visibility: visible; } to { visibility: visible; } }
@-ms-keyframes donothing { 0% { } 100% { } }
/** CARD **/

/** LOGIN SIDE **/
#login-container .login-side { }

.main-title-container{ }

.input-group {
    margin-bottom: 10px;
}

.input-group-addon {
    width: 40px;
    border: 1px solid #4c7927;
    background-color: #4c7927;
    color: #ebf2e5;
    font-weight: bold;
    text-align: center;
    margin-right: -1px;
}

.input-group-addon + input {
    border: 1px solid #4c7927;
}

.help-block {
    position: relative;
    float: left;
    color: red;
    width: 250px;
    max-width: 250px;
}

.flip-card {
    cursor: pointer;
    color: #3f1e60!important;
    font-weight: bold;
}

.main-title-container {
    color: #3f1e60!important;
    font-weight: bold;
    font-size: 36px;
    font-family: Verdana, Geneva, sans-serif;
}

.text-secondary-dark{
  color: #4c7927;
}

.spin-animation {
    -webkit-animation:spin 4s linear infinite;
    -moz-animation:spin 4s linear infinite;
    animation:spin 4s linear infinite;
}
/** LOGIN SIDE **/

/** RECOVER PASSWORD SIDE **/

/** RECOVER PASSWORD SIDE **/

.flex-column-list {
  display: flex;
  flex-flow: column wrap;
  justify-content: between;
}

.flex-column-list > div:first-of-type {
  flex: 1 0 auto!important;
}

.flex-column-list > form {
  flex: 1 0 auto!important;
}

.flex-column-list > div:last-of-type {
  flex: 0 0 auto!important;
}

.pull-right {
  float: right;
}

.btn-primary {
  background-color: #3f1e60;
  border-color: #3f1e60;
  cursor: pointer;
}

.btn-primary:hover {
    background-color: #654a7f;
    border-color: #654a7f;
}

.no-padding {
  padding: 0;
}
              
            
!

JS

              
                $(function() {
  $(".flip-card").on("click", function() {
    $(".card").toggleClass("flipped");
  });
});
              
            
!
999px

Console