cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

Quick-add: + add another resource

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.

            
              <script src="https://s.codepen.io/assets/libs/prefixfree.min.js"></script>
<center>
  <h2 class="lbl">Hover photo and click "Contact" label</h2>
</center>
<section class="profile">
	<!--	<input type="radio" id="contactBtn" name="otherBtn">
		<input type="radio" id="infoBtn" name="otherBtn">-->
		<label class="otherLabel contactLabel"  onclick="contactClick(this)">Contact</label>
		<label class="otherLabel infoLabel" onclick="infoClick(this)">Info</label>

		<figure>
			<div class="front">
				<img src="https://pbs.twimg.com/profile_images/425933007283683328/CB8hDpdS_bigger.png" alt="">
			</div>
			<div class="back">
				<a href="https://twitter.com/ozgursagiroglu">
					<img src="http://cdn1.iconfinder.com/data/icons/somacro___dpi_social_media_icons_by_vervex-dfjq/128/twitter.png">
					<span>Twitter</span>
				</a>
			</div>
		</figure>
		<article class="info">
			<header class="name">Abhay Makadia</header>
			<h5 class="job">Front & Back End Developer</h5>
			<ul class="stats">
				<li><label>Tweets</label>1,954</li>
				<li><label>Following</label>264</li>
				<li><label>Followers</label>141</li>
			</ul>
		</article>
		<article class="contact">
			<ul>
				<li>
					<label><img src="http://cdn01.androidauthority.com/wp-content/uploads/2012/08/gmail-logo.jpg">Email</label>
					<a href="mailto:abhay.makadia@gmail.com">abhay.makadia@gmail.com</a>
				</li>
				<li>
					<label><img src="https://fbstatic-a.akamaihd.net/rsrc.php/yP/r/Ivn-CVe5TGK.ico">Facebook</label>
					<a href="https://www.facebook.com/MADLogics">/osagiroglu</a>
				</li>
				<li>
					<label><img src="https://si0.twimg.com/favicons/favicon.ico">Twitter</label>
					<a href="https://twitter.com/Abhay_Makadia">@Abhay_Makadia</a></li>
				<li>
					<label><img src="http://s.wordpress.org/about/images/wpmini-blue.png">Wordpress</label>
					<a href="http://designpicker.blogspot.in">designpicker.blogspot.in</a>
				</li>
				<li>
					<label><img src="https://github.com/favicon.ico">Github</label>
					<a href="https://github.com/">/</a>
				</li>
			</ul>
		</article>
            
          
!
            
              html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font: inherit;
  font-size: 100%;
  vertical-align: baseline;
}

html {
  line-height: 1;
}

ol, ul {
  list-style: none;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

caption, th, td {
  text-align: left;
  font-weight: normal;
  vertical-align: middle;
}

q, blockquote {
  quotes: none;
}
q:before, q:after, blockquote:before, blockquote:after {
  content: "";
  content: none;
}

a img {
  border: none;
}

article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section, summary {
  display: block;
}

.lbl {
  font-size: 25px;
  margin-top: 15px;
}

body {
  font: 12px Arial, Helvetica, sans-serif;
  background: #e0e0e0;
  overflow: hidden;
}

.profile {
  width: 350px;
  height: 120px;
  margin: -50px -200px;
  position: absolute;
  top: 50%;
  left: 50%;
}
.profile figure, .profile figure img, .profile figure .back, .profile figure .front, .profile figure .back span {
  width: 90px;
  height: 90px;
  -webkit-border-radius: 500px;
  -moz-border-radius: 500px;
  -ms-border-radius: 500px;
  -o-border-radius: 500px;
  border-radius: 500px;
}
.profile figure {
  position: absolute;
  z-index: 3;
  left: -50px;
  top: 10px;
  background: #e0e0e0;
  padding: 5px;
  border-right: solid 1px #bdc6e7;
}
.profile figure img {
  -webkit-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
  -moz-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
  box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
}
.profile figure .front, .profile figure .back {
  position: absolute;
  top: 5px;
  left: 5px;
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  -ms-backface-visibility: hidden;
  -o-backface-visibility: hidden;
  backface-visibility: hidden;
  -webkit-transition: all 500ms;
  -moz-transition: all 500ms;
  -o-transition: all 500ms;
  transition: all 500ms;
}
.profile figure .front {
  z-index: 1;
}
.profile figure .back {
  -webkit-transform: rotateX(180deg);
  -moz-transform: rotateX(180deg);
  -ms-transform: rotateX(180deg);
  -o-transform: rotateX(180deg);
  transform: rotateX(180deg);
}
.profile figure .back span {
  position: absolute;
  top: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.3);
  z-index: 2;
  text-align: center;
  color: #ffffff;
  line-height: 88px;
  font-size: 20px;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5);
}
.profile figure .back span:active {
  -webkit-box-shadow: 0 0 25px 20px rgba(0, 0, 0, 0.1) inset;
  -moz-box-shadow: 0 0 25px 20px rgba(0, 0, 0, 0.1) inset;
  box-shadow: 0 0 25px 20px rgba(0, 0, 0, 0.1) inset;
}
.profile figure:hover .front {
  -webkit-transform: rotateX(180deg);
  -moz-transform: rotateX(180deg);
  -ms-transform: rotateX(180deg);
  -o-transform: rotateX(180deg);
  transform: rotateX(180deg);
}
.profile figure:hover .back {
  -webkit-transform: rotateX(0deg);
  -moz-transform: rotateX(0deg);
  -ms-transform: rotateX(0deg);
  -o-transform: rotateX(0deg);
  transform: rotateX(0deg);
}
.profile article {
  position: absolute;
  padding: 5px 10px 5px 60px;
  background: #fff;
  -webkit-box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.2), 0 0 2px rgba(0, 0, 0, 0.1) inset;
  -moz-box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.2), 0 0 2px rgba(0, 0, 0, 0.1) inset;
  box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.2), 0 0 2px rgba(0, 0, 0, 0.1) inset;
  width: 280px;
  height: 115px;
}
.profile .info {
  z-index: 2;
}
.profile .info .name {
  font-size: 23px;
  margin-bottom: 5px;
  color: #36c;
}
.profile .info .job {
  font-size: 13px;
  color: #505050;
}
.profile .info .stats {
  width: 280px;
  height: 50px;
  margin-top: 10px;
  padding-top: 6px;
  border-top: solid 1px #ddd;
}
.profile .info .stats li {
  float: left;
  font-size: 22px;
  width: 33.3%;
  color: #353535;
}
.profile .info .stats li label {
  font-size: 13px;
  display: block;
  color: #757575;
}
.profile .contact {
  top: 10px;
  left: 10px;
}
.profile .contact ul {
  margin-top: 5px;
}
.profile .contact li {
  margin-bottom: 8px;
  clear: both;
}
.profile .contact li label {
  width: 90px;
  float: left;
  display: block;
  line-height: 17px;
}
.profile .contact li label img {
  width: 16px;
  height: 16px;
  margin-right: 5px;
  float: left;
}
.profile .contact li label:after {
  content: ":";
}
.profile .contact li a {
  color: #36c;
  text-decoration: none;
}
.profile .contact li a:hover {
  text-decoration: underline;
}
.profile .otherLabel {
  position: absolute;
  z-index: 5;
  right: -15px;
  top: -5px;
  cursor: pointer;
  background: #1e78e8;
  padding: 2px 5px;
  color: #ffffff;
}
.profile .otherLabel.infoLabel {
  display: none;
}
.profile input[type=radio] {
  filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=0);
  opacity: 0;
  position: absolute;
  top: -9999px;
  left: -9999px;
}

.hideClick {
  animation: second 500ms both ease;
}
.showClick {
  animation: first 500ms both ease;
}


@keyframes second {
  0% {
    z-index: 1;
    top: 10px;
    left: 10px;
  }

  50% {
    top: 150px;
    left: 10px;
  }

  100% {
    top: 0;
    left: 0px;
    z-index: 2;
  }
}

@keyframes first {
  from {
    top: 0;
    left: 0;
    z-index: 2;
  }

  to {
    top: 10px;
    left: 10px;
    z-index: 1;
  }
}

            
          
!
            
              /*https://codepen.io/MariamMassadeh/pen/Abuzw*/

function infoClick(field)
{ 
  
   $(".contact").removeClass("showClick");
 $(".contact").addClass("hideClick");
  $(".infoLabel").slideToggle();
  $(".contactLabel").slideToggle();
  $(".info").addClass("showClick");

}
function contactClick(field) 
{
  
   $(".info").removeClass("showClick");
   $(".info").addClass("hideClick");
  $(".infoLabel").slideToggle();
  $(".contactLabel").slideToggle();
  $(".contact").addClass("showClick"); 
}
            
          
!
999px
Close

Asset uploading is a PRO feature.

As a PRO member, you can drag-and-drop upload files here to use as resources. Images, Libraries, JSON data... anything you want. You can even edit them anytime, like any other code on CodePen.

Go PRO

Loading ..................

Console