public
Created

CSS for popup with arrow.

  • Download Gist
gistfile1.css
CSS
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
.popup {
position: relative;
font-size: 12px;
 
width: 300px;
 
background-color: #28C0F7;
color: white;
 
padding: 15px;
margin-left: 15px;
 
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
-o-border-radius: 10px;
-ms-border-radius: 10px;
-khtml-border-radius: 10px;
border-radius: 10px;
 
-moz-box-shadow: rgba(0, 0, 0, 0.8) 0 0 5px 0;
-webkit-box-shadow: rgba(0, 0, 0, 0.8) 0 0 5px 0;
-o-box-shadow: rgba(0, 0, 0, 0.8) 0 0 5px 0;
box-shadow: rgba(0, 0, 0, 0.8) 0 0 5px 0;
}
 
h5 {
margin: 0;
font-size: 120%;
}
 
.popup .arrow {
position: absolute;
 
-moz-transform: rotate(45deg);
-webkit-transform: rotate(45deg);
-o-transform: rotate(45deg);
transform: rotate(45deg);
 
width: 30px;
height: 30px;
 
background-color: #28C0F7;
}
 
.left-arrow .arrow {
left: -12px;
top: 20px;
 
-moz-box-shadow: rgba(0, 0, 0, 0.8) -3px 3px 5px -3px;
-webkit-box-shadow: rgba(0, 0, 0, 0.8) -3px 3px 5px -3px;
-o-box-shadow: rgba(0, 0, 0, 0.8) -3px 3px 5px -3px;
box-shadow: rgba(0, 0, 0, 0.8) -3px 3px 5px -3px;
}
.right-arrow .arrow {
right: -12px;
top: 20px;
 
-moz-box-shadow: rgba(0, 0, 0, 0.8) 3px -3px 5px -3px;
-webkit-box-shadow: rgba(0, 0, 0, 0.8) 3px -3px 5px -3px;
-o-box-shadow: rgba(0, 0, 0, 0.8) 3px -3px 5px -3px;
box-shadow: rgba(0, 0, 0, 0.8) 3px -3px 5px -3px;
}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.