To eliminate spacing around the title text, simply include margin: 0
in the .titletext
class because the default CSS settings for paragraph elements are:
p {
display: block;
margin-top: 1em;
margin-bottom: 1em;
margin-left: 0;
margin-right: 0;
}
Therefore, the updated .titletext
class would appear as follows:
.titletext {
text-align:center;
font-family:'Open Sans Condensed', sans-serif;
font-weight:100;
color:white;
white-space:nowrap;
font-size:200%;
margin: 0; /*Add margin 0*/
}
body {
height:97.54%;
width:98.8%;
background-image:url('http://robinsunnepostcard.com/wp-content/uploads/2013/10/Robinsunne-11-OC-13-e.jpg');
}
#nw {
background-image:url('clevelandnight.jpg');
position:absolute;
height:50%;
width:49%;
background-size:cover;
border-radius:10px;
}
#ne {
background-image:url('news2.jpg');
position:absolute;
background-size:cover;
height:50%;
width:49.4%;
left:50%;
border-radius:10px;
}
#sw {
background-image:url('drinks1.jpg');
position:absolute;
background-size:cover;
height:46.5%;
width:49%;
top:52.15%;
border-radius:10px;
}
#se {
background-image:url('clevelandday.jpg');
position:absolute;
background-size:cover;
height:46.5%;
width:49.4%;
left:50%;
top:52.15%;
border-radius:10px;
}
.titletext {
text-align:center;
font-family:'Open Sans Condensed', sans-serif;
font-weight:100;
color:white;
white-space:nowrap;
font-size:200%;
margin: 0;
}
<body>
<div id='nw'>
<p class='titletext'>Nightlife</p>
</div>
<div id='ne'>
<p class='titletext'>News</p>
</div>
<div id='sw'>
<p class='titletext'>Food & Drink</p>
</div>
<div id='se'>
<p class='titletext'>Events</p>
</div>
</body>