Inspired by http://dribbble.com/shots/975425-Flat-UI-login
A Pen by Marco Biedermann on CodePen.
<html lang="en-US"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Login</title> | |
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Open+Sans:400,700"> | |
<!--[if lt IE 9]> | |
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script> | |
<![endif]--> | |
</head> | |
<body> | |
<div id="login"> | |
<form action="javascript:void(0);" method="get"> | |
<fieldset class="clearfix"> | |
<p><span class="fontawesome-user"></span><input type="text" value="Username" onBlur="if(this.value == '') this.value = 'Username'" onFocus="if(this.value == 'Username') this.value = ''" required></p> <!-- JS because of IE support; better: placeholder="Username" --> | |
<p><span class="fontawesome-lock"></span><input type="password" value="Password" onBlur="if(this.value == '') this.value = 'Password'" onFocus="if(this.value == 'Password') this.value = ''" required></p> <!-- JS because of IE support; better: placeholder="Password" --> | |
<p><input type="submit" value="Sign In"></p> | |
</fieldset> | |
</form> | |
<p>Not a member? <a href="#">Sign up now</a><span class="fontawesome-arrow-right"></span></p> | |
</div> <!-- end login --> | |
</body> | |
</html> |
Inspired by http://dribbble.com/shots/975425-Flat-UI-login
A Pen by Marco Biedermann on CodePen.
@charset "utf-8"; | |
/* CSS Document */ | |
/* ---------- FONTAWESOME ---------- */ | |
/* ---------- http://fortawesome.github.com/Font-Awesome/ ---------- */ | |
/* ---------- http://weloveiconfonts.com/ ---------- */ | |
@import url(http://weloveiconfonts.com/api/?family=fontawesome); | |
/* ---------- ERIC MEYER'S RESET CSS ---------- */ | |
/* ---------- http://meyerweb.com/eric/tools/css/reset/ ---------- */ | |
@import url(http://meyerweb.com/eric/tools/css/reset/reset.css); | |
/* ---------- FONTAWESOME ---------- */ | |
[class*="fontawesome-"]:before { | |
font-family: 'FontAwesome', sans-serif; | |
} | |
/* ---------- GENERAL ---------- */ | |
body { | |
background: #2c3338; | |
color: #606468; | |
font: 87.5%/1.5em 'Open Sans', sans-serif; | |
margin: 0; | |
} | |
a { | |
color: #eee; | |
text-decoration: none; | |
} | |
a:hover { | |
text-decoration: underline; | |
} | |
input { | |
border: none; | |
font-family: 'Open Sans', Arial, sans-serif; | |
font-size: 14px; | |
line-height: 1.5em; | |
padding: 0; | |
-webkit-appearance: none; | |
} | |
p { | |
line-height: 1.5em; | |
} | |
.clearfix { *zoom: 1; } /* For IE 6/7 */ | |
.clearfix:before, .clearfix:after { | |
display: table; | |
content: ""; | |
} | |
.clearfix:after { clear: both; } | |
/* ---------- LOGIN ---------- */ | |
#login { | |
margin: 50px auto; | |
width: 280px; | |
} | |
#login form span { | |
background-color: #363b41; | |
border-radius: 3px 0px 0px 3px; | |
color: #606468; | |
display: block; | |
float: left; | |
height: 50px; | |
line-height: 50px; | |
text-align: center; | |
width: 50px; | |
} | |
#login form input { | |
height: 50px; | |
} | |
#login form input[type="text"], input[type="password"] { | |
background-color: #3b4148; | |
border-radius: 0px 3px 3px 0px; | |
color: #606468; | |
margin-bottom: 1em; | |
padding: 0 16px; | |
width: 198px; | |
} | |
#login form input[type="submit"] { | |
border-radius: 3px; | |
-moz-border-radius: 3px; | |
-webkit-border-radius: 3px; | |
background-color: #ea4c88; | |
color: #eee; | |
font-weight: bold; | |
margin-bottom: 2em; | |
text-transform: uppercase; | |
width: 280px; | |
} | |
#login form input[type="submit"]:hover { | |
background-color: #d44179; | |
} | |
#login > p { | |
text-align: center; | |
} | |
#login > p span { | |
padding-left: 5px; | |
} |