I'm trying to draw a line using CSS and show text/image in the middle of the line.
.featured-images {
color: #666666;
border: 2px solid #333333;
}
<p class="featured-images">Featured</p>
This is what I want to do:
and
Wrap the text inside a span and use a :pseudo-element for the line.
Position the line(:pseudo-element) behind the span using z-index: -1, so that you could move around the text without having to worry about the line.
.featured-images {
position: relative;
color: #666666;
border: 2px solid #333333;
padding: 0 10px 0 30px;
}
.featured-images span {
color: #666666;
background: white;
padding: 0 10px;
}
.featured-images:after {
content: '';
position: absolute;
width: 100%;
height: 2px;
background: #666666;
left: 0;
top: 50%;
transform: translateY(-50%);
z-index: -1;
}
<p class="featured-images"><span>Featured</span></p>
Replicating the following:
You could use repeating-linear-gradient to do this.
body {
background: #E7EAE3;
}
.featured-images {
position: relative;
color: #666666;
padding: 0 10px 0 30px;
overflow: hidden;
}
.featured-images span {
color: #517575;
background: white;
padding: 0 10px;
}
.featured-images:after {
content: '';
position: absolute;
width: 120%;
height: 100%;
background: -webkit-repeating-linear-gradient(180deg, #463A3A 10px, #F2F2F2 10px, #F2F2F2 11px, #463A3A 11px, #463A3A 20px) repeat-x;
background: -moz-repeating-linear-gradient(180deg, #463A3A 10px, #F2F2F2 10px, #F2F2F2 11px, #463A3A 11px, #463A3A 20px) repeat-x;
background-size: 10px 31px;
margin-left: -30px;
transform: skew(-45deg);
left: 0;
z-index: -1;
}
<p class="featured-images"><span>Featured</span>
</p>
Using image instead of text.
.featured-images {
position: relative;
color: #666666;
border: 2px solid #333333;
padding: 0 10px 0 30px;
}
.featured-images span {
display: block;
width: 80px;
height: 13px;
background: url(http://lorempixel.com/80/13) no-repeat white 10px 0;
padding: 0 10px;
}
.featured-images:after {
content: '';
position: absolute;
width: 100%;
height: 2px;
background: #666666;
left: 0;
top: 50%;
transform: translateY(-50%);
z-index: -1;
}
<p class="featured-images"><span></span></p>
Something like this? JSFiddle
CSS:
.featured-images {
color: #666666;
}
p span {
margin:0;padding: 0 10px;
background: #FFFFFF;
display: inline-block;
}
p {
padding-left: 20px;
position: relative;
z-index: 2;
}
p:after {
content: "";
position: absolute;
top: 50%;
left: 0;
right: 0;
border-top: solid 1px #666666;
z-index: -1;
}
Demo 1
:root{padding: 40px}
p{
position: relative;
margin:40px auto;padding:0 10px;
background:white;
display:inline-block;
}
p:before,p:after{
content:"";
position:absolute;
z-index:-1;
right:0
}
p:before{
top:-4px;
left: -24px;
height: 24px;
width: 480px;
border:solid 1px #666666
}
p:after{
top: 50%;
width: 466px;
left: -16px;
border-top: solid 1px #666666
}
<p class="featured-images">Featured</p>
Use Pseudo element
:root{padding: 40px}
p{
position: relative;
margin:40px auto;padding:0 10px;
background:white;
display:inline-block;
}
p:before,p:after{
content:"";
position:absolute;
z-index:-1;
left:-14px;
right:0;
width: 480px
}
p:before{
top:-4px;
height: 24px;
border:solid 1px #666666
}
p:after{
top:50%;
border-top:solid 1px #666666
}
<p class="featured-images">Featured</p>
Demo 2
p{
position: relative;
margin:0;padding:0 10px;
background:white;
display:inline-block;
}
p:after{
content:"";
position:absolute;
top:50%;
left:-14px;
right:0;
width: 100vw;
border-top:solid 1px #666666;
z-index:-1;
}
<p class="featured-images">Featured</p>
Update
:root{padding: 40px}
p{
position: relative;
margin:40px auto;padding:0 10px;
background:white;
display:inline-block;
}
p:before,p:after{
content:"";
position:absolute;
z-index:-1;
right:0
}
p:before{
top:-4px;
left: -24px;
height: 24px;
width: 480px;
border:solid 1px #666666;
background-color: gray;
background-image: repeating-linear-gradient(-45deg, transparent, transparent 2px, rgba(255,255,255,.5) 2px, rgba(255,255,255,.5) 6px)
}
}
p:after{
top: 50%;
width: 466px;
left: -16px;
border-top: solid 1px #666666
}
<p class="featured-images">Featured</p>
Result http://jsfiddle.net/p8jdzqvL/embedded/result/
<div style="height: 2px; background-color: black; text-align: center">
<span style="background-color: white; position: relative; top: -0.5em;">
Stay Connected
</span>
</div>
Related
can you help me to make like this div:
My Code:
body{
display: flex;
justify-content: center;
}
#talkbubble {
width: 160px;
height: 80px;
background: #bc0a14;
position: relative;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
border-radius: 10px;
}
#talkbubble:before {
content: "";
position: absolute;
right: 100%;
top: 26px;
width: 0;
height: 0;
border-top: 13px solid transparent;
border-right: 26px solid #bc0a14;
border-bottom: 13px solid transparent;
}
#talkbubble:after {
content: "";
position: absolute;
left: 100%;
top: 26px;
width: 0;
height: 0;
border-top: 13px solid transparent;
border-left: 26px solid #bc0a14;
border-bottom: 13px solid transparent;
}
<div id="talkbubble"></div>
I want to create this div with the same style in the image
here is an idea with pseudo element and radial-gradient. I used CSS variable to easily adjust the shape but it's not mandatory
.box {
width: 100px;
height: 50px;
margin:0 var(--w,20px);
display:inline-block;
border-radius: 15px;
background: var(--c,red);
position: relative;
}
.box:before,
.box:after {
content: "";
position: absolute;
top: 0;
bottom: 0;
width: var(--w,20px);
right:calc(100% - 2px);
background:
radial-gradient(107% 100% at top left,transparent 96%,var(--c,red) 100%) top,
radial-gradient(107% 100% at bottom left,transparent 96%,var(--c,red) 100%) bottom;
background-size:100% 50.1%;
background-repeat:no-repeat;
}
.box:after {
left:calc(100% - 2px);
right:auto;
transform:scaleX(-1);
}
<div class="box"></div>
<div class="box" style="--c:blue;--w:30px;"></div>
<div class="box" style="--c:purple;--w:10px;height:60px"></div>
please try this code:
body{
display: flex;
justify-content: center;
}
#talkbubble {
width: 180px;
height: 54px;
background: #bc0a14;
position: relative;
-moz-border-radius: 20px;
-webkit-border-radius: 20px;
border-radius: 24px;
}
#talkbubble:before {
content: "";
position: absolute;
right: 99%;
top: 17px;
width: 0px;
height: 1px;
border-top: 9px solid transparent;
border-right: 10px solid #bc0a14;
border-bottom: 9px solid transparent;
}
#talkbubble:after {
content: "";
position: absolute;
left: 99%;
top: 17px;
width: 0;
height: 1px;
border-top: 9px solid transparent;
border-left: 10px solid #bc0a14;
border-bottom: 9px solid transparent;
}
<div id="talkbubble"></div>
I have to code a shape(below image) in HTML
And below is the code what I tried so far:
body {
font: 13px Verdana;
}
h3 {
height: 100px;
background: #72bbab;
border-radius: 50px 10px 10px 50px;
display: flex;
margin-top: 50px;
position: relative;
line-height: 100px;
color: #ffffff;
font-size: 13px;
font-weight: normal;
}
h3 i {
width: 130px;
height: 130px;
transform: translateY(-15px);
background: #71bbab;
border-radius: 50%;
position: relative;
margin-right: 20px;
}
h3:before {
content: "";
position: absolute;
border: 1px dashed #fff;
top: 5px;
bottom: 5px;
left: 20px;
right: 2px;
border-radius: 10px;
}
h3 i:before {
content: "";
position: absolute;
top: 5px;
bottom: 5px;
left: 5px;
right: 5px;
border: 1px dashed #fff;
border-radius: 50%;
}
<h3><i></i>Text</h3>
Now the issue is I am not able to remove dashed border of circle from right side. I tried border-top:0 and border-right:0 but didn't work.
Thanks in advance
Note: Don't want to use any king of image
If you need to get the output by keeping same HTML mark-up then you have to use many pseudo selectors, CSS calc() function to calculate h2 tag width and many such properties to get output using CSS.
You have too even use position and z-index to hide circle border backside of h2 tag. And using margin you could arrange the remaining, so at one point whole diagram connects.
body {
font: 13px Verdana;
}
h3{
background:#72bbab;
width:calc(100% - 95px);
height:85px;
margin-left:95px;
margin-top:21px;
display:flex;
justify-content:flex-start;
align-items:center;
border-top-right-radius:10px;
border-bottom-right-radius:10px;
padding-left:20px;
box-sizing:border-box;
color:#fff;
}
h3 i{
width:120px;
height:120px;
background:#72bbab;
border-radius:50%;
display:inline-block;
top:2px;
left:2px;
position:absolute;
z-index:-1;
overflow:hidden;
}
h3 i:before{
content:"";
width:100px;
height:100px;
border:2px dashed #fff;
position:absolute;
top:8px;
left:8px;
border-radius:50%;
}
h3:before{
content:"";
width:calc(100% - 120px);
height:65px;
border:2px dashed #fff;
position:absolute;
right:15px;
border-top-right-radius:10px;
border-bottom-right-radius:10px;
}
h3:after{
content:"";
width:3px;
height:68px;
background:#72bbab;
position:absolute;
top:28px;
margin-left:-61px;
}
<h3><i></i>Text</h3>
See if this helps.
https://jsfiddle.net/induprakash/8ofLjqxm/
I added a higher z-index to rectangle border.
body {
font: 13px Verdana;
}
h3 {
height: 100px;
background: #72bbab;
border-radius: 50px 10px 10px 50px;
display: flex;
margin-top: 50px;
position: relative;
line-height: 100px;
color: #ffffff;
font-size: 13px;
font-weight: normal;
}
h3 i {
width: 130px;
height: 130px;
transform: translateY(-15px);
background: #71bbab;
border-radius: 50%;
position: relative;
margin-right: 20px;
}
h3:before {
content: "";
position: absolute;
border: 1px dashed #fff;
top: 5px;
bottom: 5px;
left: 105px;
z-index: 10;
right: 2px;
border-radius: 0px;
border-left: 0;
}
h3 i:before {
content: "";
position: absolute;
top: 5px;
bottom: 5px;
left: 5px;
right: 5px;
border: 1px dashed #fff;
border-radius: 50%;
border-right : 1px solid #72bbab;
}
Try this one, its running as per your image. I have tried a simple and different approach.
JSFiddle Link - https://jsfiddle.net/deepak104080/uwx873x1/
.circle {
width:130px;
height:130px;
border-radius:65px;
position:absolute;
z-index:100;
background:#71bbab;
margin:0px;
padding:0px;
}
.innercircle {
width:110px;
height:110px;
border-radius:55px;
position:absolute;
top:9px;
left:9px;
z-index:100;
background:#71bbab;
border: 1px dashed #fff;
}
.tab {
height: 100px;
position:absolute;
margin-top:15px;
margin-left:105px;
z-index:1000;
width:350px;
background:#71bbab;
border-top-right-radius:10px;
border-bottom-right-radius:10px;
}
.innertab {
height: 78px;
position:absolute;
margin-top:10px;
margin-left:0px;
z-index:1000;
width:340px;
background:#71bbab;
border-top-right-radius:10px;
border-bottom-right-radius:10px;
border-top: 1px dashed #fff;
border-bottom: 1px dashed #fff;
border-right: 1px dashed #fff;
}
<div>
<div class="circle">
<div class="innercircle">
</div>
</div>
<div class="tab">
<div class="innertab">
</div>
</div>
</div>
Use the ::after pseudo for h3 element.
h3:after {
z-index: 9999;
position:absolute;
max-width: 100%;
width: 100px;
height: 87px;
background: #71bbab;
content: '';
left: 35px;
margin-top: 6px;
}
https://jsfiddle.net/apyupfwo/
I need to add borders to this "shape". It's kinda difficult because the shape is made with the after and before pseudo-elements. I can't find the right way.
What I need to achieve:
The code I have so far:
https://jsfiddle.net/jimmyadaro/xfcjfz3d/
#octagon {
width: 300px;
height: 200px;
background: red;
position: relative;
-webkit-box-sizing: content-box;
-moz-box-sizing: content-box;
box-sizing: content-box;
display: block;
}
#octagon:before,
#octagon:after {
content: "";
position: absolute;
left: 0;
right: 0;
}
#octagon:before {
top: 0;
border-bottom: 30px solid red;
border-left: 30px solid #fff;
border-right: 30px solid #fff;
}
#octagon:after {
bottom: 0;
border-top: 30px solid red;
border-left: 30px solid #fff;
border-right: 30px solid #fff;
}
<div id="octagon"></div>
I tried with shadows and outlines without success.
Thanks for reading.
Note: I'll use a solid background color, if that matters.
Here's my solution. No solid background color is required. This may or may not suit your actual use case.
JSFiddle
#octagon {
display: flex;
justify-content: center;
align-items: center;
width: 300px;
height: 200px;
overflow: hidden;
position: relative;
}
#octagon:before,
#octagon:after {
content: "";
display: block;
width: 300px;
padding-top: 100%;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%) rotate(45deg);
z-index: -1;
}
#octagon:before {
background: red;
}
#octagon:after {
background:
linear-gradient(
45deg,
#0e0 calc(50% - 150px + 10px), transparent 0,
transparent calc(50% + 150px - 10px), #0e0 0%),
linear-gradient(
-45deg,
#0e0 calc(50% - 100px + 10px), transparent 0,
transparent calc(50% + 100px - 10px), #0e0 0);
box-shadow: 0 0 0 10px #0e0 inset;
}
<div id="octagon">Hello World!</div>
Well, this is the only way I could think of approaching it in pure CSS:
JSfiddle here: https://jsfiddle.net/xfcjfz3d/7/
body {
background:#fff;
}
#octagon {
position:relative;
width: 300px;
height: 200px;
background: green;
position: relative;
-webkit-box-sizing: content-box;
-moz-box-sizing: content-box;
box-sizing: content-box;
display: block;
}
#octagon:before,
#octagon:after {
content: "";
position: absolute;
left: 0;
right: 0;
}
#octagon:before {
top: 0;
border-bottom: 30px solid green;
border-left: 30px solid #fff;
border-right: 30px solid #fff;
}
#octagon:after {
bottom: 0;
border-top: 30px solid green;
border-left: 30px solid #fff;
border-right: 30px solid #fff;
}
.tall {
position:absolute;
background:red;
width:230px;
height:190px;
left:35px;
top:5px;
z-index:1;
}
.wide {
position:absolute;
background:red;
width:290px;
height:130px;
left:5px;
top:35px;
z-index:1;
}
.corner {
position:absolute;
background:red;
width:45px;
height:43px;
z-index:1;
transform: rotate(45deg);
}
.topleft {
left:14px;
top:14px;
}
.topright {
//background:black;
left:241px;
top:13px;
}
.bottomleft {
background:red;
left:13px;
top:143px;
}
.bottomright {
background:red;
left:241px;
top:143px;
}
<div id="octagon">
<div class="tall"></div>
<div class="wide"></div>
<div class="corner topleft"></div>
<div class="corner topright"></div>
<div class="corner bottomleft"></div>
<div class="corner bottomright"></div>
</div>
I have the following CSS code:
#wrapper{
height:500px;
background: url('http://i.imgur.com/f1uCUEJ.jpg');
}
#menu:before{
width:500px;
height:60px;
background: rgba(255,255,255,0.6);
content: "";
position: fixed;
top:0;
left: 0;
border-radius: 0 0 10px 0;
}
#menu{
position: fixed;
top:60px;
left: 0;
background: rgba(255,255,255,0.6);
height: 300px;
width: 60px;
border-radius: 0 0 10px 0;
}
#circle{
position: fixed;
width:150px;
height:150px;
border-radius: 150px;
background: #000;
top: 10px;
left: 10px;
}
#circle2{
position: fixed;
width:120px;
height:120px;
border-radius: 120px;
background: #fff;
top: 25px;
left: 25px;
}
#circle3{
position: fixed;
width:90px;
height:90px;
border-radius: 90px;
background: #000;
top: 40px;
left: 40px;
}
#circle4{
position: fixed;
top: 54px;
left: 54px;
}
.btn{
border: none;
display: block;
margin: 1px;
background: #fff;
width:60px;
height: 30px;
font-weight: 700;
font-size: 17px;
}
#plus{
border-radius: 30px 30px 0 0;
}
#minus{
border-radius: 0 0 30px 30px;
}
And following HTML code:
<div id="wrapper">
<div id="menu"></div>
<div id="circle">
<div id="circle2">
<div id="circle3">
<div id="circle4">
<button id="plus" class="btn">+</button>
<button id="minus" class="btn">-</button>
</div>
</div>
</div>
</div>
</div>
Could you help me to understand how I can achieve solution, which will make "transparent" black circles and I could see only image? If I make now this black color as - background: rgba(0,0,0,0). I can see "menu" bars and I'd like to not see them.
There's following link with example: http://jsfiddle.net/88Uxw/122/
Is this what you are looking for? FIDDLE
Basically instead of using circles with background one inside the other, make the black color with border and set the "white" ones to not have any background:
#circle{
position: fixed;
width:150px;
height:150px;
border-radius: 150px;
border: 15px solid #000;
box-sizing: border-box;
top: 10px;
left: 10px;
}
#circle2{
position: fixed;
width:120px;
height:120px;
border-radius: 120px;
top: 25px;
left: 25px;
}
#circle3{
position: fixed;
width:90px;
height:90px;
border-radius: 90px;
border: 15px solid #000;
box-sizing: border-box;
top: 40px;
left: 40px;
}
#circle4{
position: fixed;
top: 54px;
left: 54px;
}
.btn{
border: none;
display: block;
margin: 1px;
background: transparent;
width:60px;
height: 30px;
font-weight: 700;
font-size: 17px;
border-bottom:1px solid #000;
}
Don't forget to add box-sizing: border-box; to keep the border inside you fixed size container.
Thanks to #Alvaro Menéndez I was able to do what I wanted to do. That's solution for my problem:
HTML:
<div id="wrapper">
<div id="wrap">
<div id="shape"></div>
</div>
<div id="wrap2">
<div id="shape2"></div>
</div>
<div id="shape3">
<button id="plus" class="btn">+</button>
<button id="minus" class="btn">-</button>
</div>
<div id="left-menu"></div>
<div id="top-menu"></div>
</div>
CSS:
#shape {
width:200px;
height:200px;
position:fixed;
overflow:hidden;
top: 0;
left: 0;
}
#shape:before {
content:" ";
position:absolute;
width:100%;
height:100%;
left:15%; top:15%;
border-radius:50%;
box-shadow:0 0px 0 250px rgba(255,255,255,0.6);
}
#left-menu{
background: rgba(255,255,255,0.6);
width: 59px;
height: 200px;
position: fixed;
top:200px;
left: 0;
}
#top-menu{
position: fixed;
top: 0;
left: 200px;
background: rgba(255,255,255,0.6);
width: 300px;
height: 59px;
}
#shape2 {
width: 140px;
height: 140px;
position: fixed;
top: 60px;
left: 60px;
}
#shape2:before {
content: " ";
position: absolute;
width: 100%;
height: 100%;
border-radius: 50%;
box-shadow: 0 0px 0 20px rgba(255,255,255,0.6);
}
#shape3{
position: fixed;
top: 69px;
left: 69px;
}
.btn{
border: none;
display: block;
margin: 1px;
background: rgba(255,255,255,0.6);
width:120px;
height: 60px;
font-weight: 700;
font-size: 17px;
}
.btn:hover{
background: #fff;
}
#plus{
border-radius: 100px 100px 0 0;
}
#minus{
border-radius: 0 0 100px 100px;
}
And working example: https://jsfiddle.net/L9aeu4o3/
I'm trying to achieve this (triangle at the bottom) in CSS and I'm starting to think it's not possible.
Update: got it working - but I do hope there is a better way:
Layering 4 CSS triangles ontop of eachother using :before :after
Code: http://jsfiddle.net/dtbaker/5fhL1odg/1/
The closest I was able to get is this (using a combination of css triangles that overlap eachother).
Code so far:
http://jsfiddle.net/dtbaker/gk47ggc1/1/
<div class="blog">
<div class="blog_date">
<span class="month">Sep</span>
<span class="day">30th</span>
<span class="year">2014</span>
<div></div>
</div>
</div>
div.blog .blog_date {
z-index: 10;
top: 10px;
left: 11px;
position: absolute;
width:56px;
float:right;
text-align:center;
color:#4b443a;
background: #f8f4e9;
border-top: 2px solid #edebdf;
border-left: 2px solid #edebdf;
border-right: 2px solid #edebdf;
}
div.blog .blog_date:before {
content: '';
position: absolute;
top:-5px;
right:-5px;
left:-5px;
bottom:-5px;
border-top:1px solid #e8e6da;
border-left:1px solid #e8e6da;
border-right:1px solid #e8e6da;
}
div.blog .blog_date div{
width: 0;
height: 0;
border-style: solid;
border-width: 12px 33px 0 33px;
border-color: #e8e6da transparent transparent transparent;
position: absolute;
bottom: -16px;
z-index: 5;
left:-5px;
}
div.blog .blog_date div:before {
width: 0;
height: 0;
border-style: solid;
border-width: 10px 30px 0 30px;
border-color: #FFF transparent transparent transparent;
position: absolute;
top: -11px;
content: '';
left: -30px;
z-index: 3;
}
div.blog .blog_date div:after {
width: 0;
height: 0;
border-style: solid;
border-width: 12px 30px 0 30px;
border-color: #f8f4e9 transparent transparent transparent;
position: absolute;
top: -15px;
content: '';
left: -30px;
z-index: 4;
}
div.blog .blog_date span {
display:block;
width:100%;
}
div.blog .blog_date span.month {
font-size:13px;
height:16px;
margin-top:5px;
}
div.blog .blog_date span.day {
font-size:18px;
height:20px;
color:#c9a976;
}
div.blog .blog_date span.year {
font-size:13px;
height:16px;
}
It would be very easy via an image, but if some wiz out there can figure this out I would be very grateful.
Thanks!
I haven't tried it but maybe you can draw the line to form the border of the triangle and play with rotations? Probably won't work on every browser though.
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
-o-transform: rotate(45deg);
-ms-transform: rotate(45deg);
transform: rotate(45deg);
Update: got it working - but I do hope there is a better way:
Layering 4 CSS triangles ontop of eachother using :before :after
Code: http://jsfiddle.net/dtbaker/5fhL1odg/1/
div.blog .blog_date {
z-index: 10;
left: 11px;
position: absolute;
width:56px;
float:right;
text-align:center;
color:#4b443a;
background: #f8f4e9;
border-top: 2px solid #edebdf;
border-left: 2px solid #edebdf;
border-right: 2px solid #edebdf;
}
div.blog .blog_date:before {
content: '';
position: absolute;
top:-5px;
right:-5px;
left:-5px;
bottom:-2px;
border-top:1px solid #e8e6da;
border-left:1px solid #e8e6da;
border-right:1px solid #e8e6da;
}
div.blog .blog_date:after {
/* 1px outer border */
width: 0;
height: 0;
border-style: solid;
border-width: 12px 33px 0 33px;
border-color: #e8e6da transparent transparent transparent;
position: absolute;
bottom: -14px;
z-index: 2;
left:-5px;
content: '';
}
div.blog .blog_date div{
/* white separator/overlay */
width: 0;
height: 0;
border-style: solid;
border-width: 12px 33px 0 33px;
border-color: #FFF transparent transparent transparent;
position: absolute;
content: '';
z-index: 4;
bottom: -13px;
left: -5px;
}
div.blog .blog_date div:before {
/* 2px inner border */
width: 0;
height: 0;
border-style: solid;
border-width: 11px 30px 0 30px;
border-color: #edebdf transparent transparent transparent;
position: absolute;
content: '';
z-index: 3;
top: -13px;
left: -30px;
}
div.blog .blog_date div:after {
/* inner triangle */
width: 0;
height: 0;
border-style: solid;
border-width: 11px 29px 0 29px;
border-color: #f8f4e9 transparent transparent transparent;
position: absolute;
top: -14px;
content: '';
left: -29px;
z-index: 5;
}
div.blog .blog_date span {
display:block;
width:100%;
}
div.blog .blog_date span.month {
font-size:13px;
height:16px;
margin-top:5px;
}
div.blog .blog_date span.day {
font-size:18px;
height:20px;
color:#c9a976;
}
div.blog .blog_date span.year {
font-size:13px;
height:16px;
}
Try this
.blog_date{
font-family: Times New Roman; /*nearly similar to required font */
width: 100px;
}
div.blog .blog_date span.month {
float: left; /*added*/
font-size: 32px;/*changed*/
height: auto; /*changed*/
margin-top: 5px;
}
div.blog .blog_date span.day {
color: #c9a976;
float: left; /*added*/
font-size: 34px;/*changed*/
font-weight: bold;
height: auto;/*changed*/
}
div.blog .blog_date span.year {
float: left; /*added*/
font-size: 32px;/*changed*/
height: auto;/*changed*/
}
hope this help you.