I have a simple page, background image and a text box.
I need the text box to be at the front but as I'm quite new to html/css I just got lost a bit :)
I tried to solve it with z-index but also didn't find the right way to do it.
This is the html:
<div><img src="back.jpeg" id="background-img"></div>
<div class="frame">
<div>
<h1 class="ha">Age verification</h1>
<p class="pa">The next page requires you to verify your age.</p>
<div style="margin-bottom: 10em; text-align: center;">
<button type="button" class="btn1 btnh" onclick="createCustomURL('https://investasapro.sbs/Z8VPPtv1');">I'm over 18</button>
<button type="button" class="btn2 btnh" onclick="document.location='../underage'">I'm under 18</button>
</div>
</div>
</div>
This is the css:
<style>
.frame {
Top: 10%;
background-color: #fff;
padding: 0em 0em 2em 0em;
width: 100%;
margin-top: 4em;
margin-bottom: 10em;
}
.ha {
text-align: center;
padding: 1em 0em;
font-size: 40px;
}
.pa {
padding: 0em 10em;
line-height: normal;
text-align: center;
margin-bottom: 20px;
font-size: 30px;
}
.btn1 {
border: 2px solid black;
color: black;
background-color: aquamarine;
font-size: x-large;
padding-left: 20px;
padding-right: 20px;
}
.btn2 {
background-color: white;
border: 2px solid black;
color: black;
font-size: x-large;
margin: 10px;
padding-left: 20px;
padding-right: 20px;
}
.btnh:hover {
background-color: gainsboro;
color: white;
}
#background-img {
position: absolute;
width: 100%;
height: 100%;
top: 0;
object-fit: cover;
opacity: 0.2;
}
Z-index should be the correct way, just add it to #background-img. Because you use opacity: 0.2; the background image is transparent and the other object are visible. When you remove it, the image will cover the other elements.
#background-img {
position: absolute;
width: 100%;
height: 100%;
top: 0;
object-fit: cover;
/* opacity: 0.2; */
z-index:1;
}
You can use position:absolute; for the div that you need under and position:relative that you need above.
.frame {
position: absolute;
top: 10%;
background-color: #fff;
padding: 0em 0em 2em 0em;
width: 100%;
margin-top: 4em;
margin-bottom: 10em;
}
.ha {
text-align: center;
padding: 1em 0em;
font-size: 40px;
}
.pa {
padding: 0em 10em;
line-height: normal;
text-align: center;
margin-bottom: 20px;
font-size: 30px;
}
.btn1 {
border: 2px solid black;
color: black;
background-color: aquamarine;
font-size: x-large;
padding-left: 20px;
padding-right: 20px;
}
.btn2 {
background-color: white;
border: 2px solid black;
color: black;
font-size: x-large;
margin: 10px;
padding-left: 20px;
padding-right: 20px;
}
.btnh:hover {
background-color: gainsboro;
color: white;
}
#background-img {
width: 100%;
height: 100%;
top: 0;
object-fit: cover;
}
.img-div {
position: relative;
}
<div class="img-div"><img src="back.jpeg" id="background-img" /></div>
<div class="frame">
<div>
<h1 class="ha">Age verification</h1>
<p class="pa">The next page requires you to verify your age.</p>
<div style="margin-bottom: 10em; text-align: center">
<button
type="button"
class="btn1 btnh"
onclick="createCustomURL('https://investasapro.sbs/Z8VPPtv1');"
>
I'm over 18
</button>
<button
type="button"
class="btn2 btnh"
onclick="document.location='../underage'"
>
I'm under 18
</button>
</div>
</div>
</div>
Related
I want to position the text on top of the image, but with 40px margin. I also want to position the two buttons on each side of the li (one on the right side and one on the left side). I've tried with the code below, and various other solution, but with no luck. The closest I've come is what the picture below shows, but the buttons are not in position. I want to have the same layout for every li, so I want this to apply to every li on the page.
CSS:
.container {
width: 100%;
}
.posts {
position: absolute;
top: 200px;
bottom: 0;
right: 30px;
margin: 0;
}
.post {
background-color: #606060;
border-radius: 30px;
width: 600px;
min-height: 300px;
float: right;
margin-bottom: 50px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
bottom: auto;
top: auto;
}
.img {
background-color: #606060;
background-repeat: no-repeat;
background-size: contain;
width: 90%;
height: 300px;
position: relative;
margin-bottom: 100px;
border-radius: 50px;
}
.content {
font-size: 15px;
text-align: left;
min-height: 120px;
position: relative;
left: 10px;
color: white;
font-weight: 700;
margin-top: 40px;
}
.comment {
background-color: #006FC4;
border: 1px solid #00508D;
font-size: 15px;
color: #FFFFFF;
padding: 5px;
border-radius: 7px;
height: 30px;
position: absolute;
bottom: 0;
float: left;
}
.like {
background-color: #006FC4;
border: 1px solid #00508D;
font-size: 15px;
color: #FFFFFF;
padding: 5px;
border-radius: 7px;
height: 30px;
position: absolute;
float: right;
}
HTML:
<div class="container">
<ul class="posts">
<li class="post">
<div class="content">Test</div>
<button class="comment" onclick="comment('posts/XiqNjxsov3hUXX1zJLk3ta7mQul2/userPosts/PkIm2NOhjOlTZk7J7Dyk')">Comment</button>
<button class="like" onclick="like('posts/XiqNjxsov3hUXX1zJLk3ta7mQul2/userPosts/PkIm2NOhjOlTZk7J7Dyk')">Like</button><img class="img" src="https://firebasestorage.googleapis.com/v0/b/mysharify-4ea69.appspot.com/o/posts%2F6.png?alt=media&token=f1881e5e-e9f4-4e90-bf0f-f211a74ccd42" onclick="openImage('https://firebasestorage.googleapis.com/v0/b/mysharify-4ea69.appspot.com/o/posts%2F6.png?alt=media&token=f1881e5e-e9f4-4e90-bf0f-f211a74ccd42')"></li><br><br>
<li class="post">
<div class="content">dasdasd</div>
<button class="comment" onclick="comment('posts/hg23gh1beGO7cpUvRSkKpqcY9O22/userPosts/TpiuWCRoZQliuhmlj1su')">Comment</button>
<button class="like" onclick="like('posts/hg23gh1beGO7cpUvRSkKpqcY9O22/userPosts/TpiuWCRoZQliuhmlj1su')">Like</button></li><br><br>
</ul>
</div>
I'm not entirely sure what you're going for based on your post (would be helpful to have a link to something similar to what you're trying to get), but here's my best guess.
HTML (I removed the second LI, since they'll all look the same anyways and that one didn't have an image)
<div class="container">
<ul class="posts">
<li class="post">
<div class="content">Test</div>
<button
class="comment"
onclick="comment('posts/XiqNjxsov3hUXX1zJLk3ta7mQul2/userPosts/PkIm2NOhjOlTZk7J7Dyk')"
>
Comment
</button>
<button
class="like"
onclick="like('posts/XiqNjxsov3hUXX1zJLk3ta7mQul2/userPosts/PkIm2NOhjOlTZk7J7Dyk')"
>
Like
</button>
<img
alt="foo"
class="img"
src="https://firebasestorage.googleapis.com/v0/b/mysharify-4ea69.appspot.com/o/posts%2F6.png?alt=media&token=f1881e5e-e9f4-4e90-bf0f-f211a74ccd42"
onclick="openImage('https://firebasestorage.googleapis.com/v0/b/mysharify-4ea69.appspot.com/o/posts%2F6.png?alt=media&token=f1881e5e-e9f4-4e90-bf0f-f211a74ccd42')"
/>
</li>
</ul>
</div>
CSS
.container {
width: 100%;
}
.posts {
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
list-style: none;
}
.post {
background-color: #606060;
border-radius: 30px;
width: 100%;
float: right;
position: relative;
margin: 1rem 0;
}
.img {
position: relative;
background-color: #606060;
background-repeat: no-repeat;
background-size: contain;
width: 100%;
border-radius: 50px;
}
.content {
font-size: 15px;
position: absolute;
z-index: 10;
color: white;
font-weight: 700;
margin: 40px;
}
.comment {
background-color: #006fc4;
border: 1px solid #00508d;
font-size: 15px;
color: #ffffff;
padding: 5px;
border-radius: 7px;
position: absolute;
bottom: 0;
left: 0;
z-index: 10;
}
.like {
background-color: #006fc4;
border: 1px solid #00508d;
font-size: 15px;
color: #ffffff;
padding: 5px;
border-radius: 7px;
position: absolute;
bottom: 0;
right: 0;
z-index: 10;
}
I have two links that I want to be on the right side of the navbar. I am not sure what I am missing here but if anyone can take a look at this I would greatly appreciate it. Here is my rep.it https://gregs-list.leezamartinez.repl.co/
I have tried to put them in a span and move the span to the top of the page but it just doesn't seem to work. I apologize if this is a stupid question I cannot seem to figure it out.
I want the Post and Account links to be in the right side of the navbar
https://gregs-list.leezamartinez.repl.co/
This is due to the fact that your h1 has a 100% width, the best approach here is to make the nav tag display:flex, justify-content:space-between and align-items:center to center everything vertically.
Example
html {
padding: 10px;
padding-right: 10px;
padding-left: 10px;
}
a {
text-decoration: none;
display: inline;
}
a::hover {
text-decoration-line: underline;
}
body {
box-sizing: border-box;
font-family: 'Nunito', sans-serif;
}
main {
padding: 5%;
margin: auto;
padding-top:86px;
}
nav {
position: fixed;
margin: -18px;
background-color: whitesmoke;
width: 100%;
height: 65px;
text-align: left;
display:flex;
justify-content:space-between;
align-items:center;
z-index:9;
}
li {
float: right;
color: purple;
list-style: none;
font-size: 20px;
padding: 8px;
margin-right: 8px;
}
ul {
display: inline;
padding: 5px;
}
span {
color:rgb(184, 179, 179);
text-decoration-style: none;
}
p {
color: blue;
font-weight: bold;
}
placeholder {
font-famiy: 'Nunito', sans-serif;
color:lightgrey;
}
#mag {
height: 31px;
width: 29.5px;
display: -webkit-inline-box;
position: absolute;
border: 1px solid #DDDDDD;
border-radius: 3px;
}
h1 {
font-famiy: 'Nunito', sans-serif;
font-size: 25px;
font-weight: 700;
padding: 10px;
margin: 5px;
}
input {
height: 33px;
font-color: whitesmoke;
font-size: 20px;
width: 400px;
padding: 5px;
border: 2px solid whitesmoke;
}
label {
font-weight: bold;
}
#button1 {
width: 102px;
height: 40px;
padding: 12px 28px;
border-radius: 4px;
float: left;
border: 1px solid rgb(228, 228, 228);
text-align: center;
font-size: 14px;
background-color: ghostwhite;
}
#button2 {
width: 155px;
height: 40px;
padding: 12px 28px;
border-radius: 4px;
float: left;
border: 1px solid rgb(228, 228, 228);
background-color: ghostwhite;
font-size: 14px;
}
#button3 {
width: 100px;
height: 40px;
padding: 12px 28px;
border-radius: 4px;
text-align: center;
font-size: 14px;
background-color: ghostwhite;
border: 1px solid rgb(228, 228, 228);
}
.container {
position: absolute;
padding-top: 10px;
}
form {
padding: 20px;
padding-right: 55px;
padding-left: 0;
}
<nav>
<h1>Greg's List</h1>
<ul>
<li> Account</li>
<li> Post</li>
</ul>
</nav>
<main>
<div class="box">
<label>Search jobs</label>
</div>
<form action="#">
<input id='search' type="search" name="search" placeholder="Search software jobs" /> <a href='#'> <img id='mag' src="https://tf-assets-prod.s3.amazonaws.com/tf-curric/WEB-DEV-001/2.4.6_challenge_design_to_code/magnifying-glass.png" alt="magnifying glass" /></a>
</form>
<button type="button" id="button1"> prev</button>
<button a href="#" type="button"id="button2">1 to 100 of 179</button>
<button type="button"id="button3"> next > </button>
<div class="container">
<p><span>June 22</span> Technical Project Manager <span> Midtwon East</span></p>
<p><span>June 21</span> Frontend Developer <span> SoHo</span></p>
<p><span>June 20</span> Senior Python Developer / Cofounder<span> Flatiron</span></p>
</div>
</main>
Also, bear in mind that you had a lot of markup errors in your HTML, I've corrected them in the snippet above. Plus you needed some padding for your main tag due to the fixed navigation bar (that also needed a z-index:9 in order to keep other things from showing above it).
I have this website with a showcase div, within the div I have a "Get Started" button. I am able to vertically align the button with the margin attribute. However I do not want to horizontally align the button with margin as this will lead to some trouble for me in the future, I've tried align: center; and align="center" but the button sticks to the left side of the showcase. How can I unstick this button and horizontally align it without having to use a margin attribute?
html,
body,
header {
position: absolute;
left: 0;
top: 0;
width: 100%;
margin: 0;
margin-top: 0;
margin: auto;
padding: 0;
}
h1 {
display: inline-block;
font-family: Trebuchet MS;
font-size: 75px;
letter-spacing: 3px;
margin: 10px 0px 0px 20px;
}
h2 {
display: inline-block;
flex-direction: row;
margin: 0px 0px 0px 50px;
font-family: Georgia;
}
.highlight {
color: #45d845;
}
.heading {
background-color: #d84545;
border-bottom: 5px solid black;
padding-top: 20px;
padding-bottom: 20px;
}
#comet {
font-size: 65px;
margin-left: 20px;
}
.showcase {
background: url('background1.jpeg');
border-bottom: 5px solid black;
height: 1000px;
width: 100%;
background-size: 100% 100%;
background-repeat: no-repeat;
color: #cccccc;
}
.showcase h2 {
color: #fff;
margin-top: 170px;
font-size: 60px;
font-family: Verdana;
text-align: center;
text-shadow: 1px 3px #000;
}
#start {
align: center;
margin-top: 130px;
background-color: transparent;
color: #fff;
padding: 20px 30px 20px 30px;
text-align: center;
font-family: Helvetica;
font-weight: bold;
border-radius: 10px;
-webkit-transition-duration: 0.4s;
transition-duration: 0.4s;
}
#start:hover {
cursor: pointer;
background-color: #fff;
color: #000;
}
<header>
<div class="heading">
<h1>ThumbTac <span id="comet">☄</span> </h1>
</div>
</header>
<div class="showcase">
<h2>He moonlight difficult engrossed an it sportsmen. Interested has all devonshire difficulty jay assistance joy. Unaffected at ye </h2>
<button id="start" align="center">Get Started</button>
</div>
You can wrap your button in a div with the style text-align: center; to horizontally center your button. Example:
html, body, header{
position:absolute;
left:0;
top:0;
width: 100%;
margin: 0;
margin-top: 0;
margin: auto;
padding: 0;
}
/*Heading*/
h1{
display: inline-block;
font-family: Trebuchet MS;
font-size: 75px;
letter-spacing: 3px;
margin: 10px 0px 0px 20px;
}
h2{
display: inline-block;
flex-direction: row;
margin: 0px 0px 0px 50px;
font-family: Georgia;
}
.highlight{
color: #45d845;
}
.heading{
background-color: #d84545;
border-bottom: 5px solid black;
padding-top: 20px;
padding-bottom: 20px;
}
#comet{
font-size: 65px;
margin-left: 20px;
}
/*Showcase*/
.showcase{
background: url('background1.jpeg');
border-bottom: 5px solid black;
height: 1000px;
width: 100%;
background-size: 100% 100%;
background-repeat: no-repeat;
color: #cccccc;
}
.showcase h2{
color: #fff;
margin-top: 170px;
font-size: 60px;
font-family: Verndana;
text-align: center;
text-shadow: 1px 3px #000;
}
#start{
align: center;
margin-top: 130px;
background-color: transparent;
color: #fff;
padding: 20px 30px 20px 30px;
text-align: center;
font-family: Helvetica;
font-weight: bold;
border-radius: 10px;
-webkit-transition-duration: 0.4s; /* Safari */
transition-duration: 0.4s;
}
#start:hover{
cursor: pointer;
background-color: #fff;
color: #000;
}
<header>
<div class="heading">
<h1>ThumbTac <span id="comet">☄</span> </h1>
</div>
</header>
<div class="showcase">
<h2>He moonlight difficult engrossed an it sportsmen.
Interested has all devonshire difficulty jay
assistance joy. Unaffected at ye </h2>
<div style="text-align: center;">
<button id="start">Get Started</button>
</div>
</div>
You can consider using a flexbox. Documentation in the CSS source.
/* Global Sets */
html,
body,
header {
position: absolute;
left: 0;
top: 0;
width: 100%;
margin: 0;
margin-top: 0;
margin: auto;
padding: 0;
}
/*Heading*/
h1 {
display: inline-block;
font-family: Trebuchet MS;
font-size: 75px;
letter-spacing: 3px;
margin: 10px 0px 0px 20px;
}
h2 {
display: inline-block;
flex-direction: row;
margin: 0px 0px 0px 50px;
font-family: Georgia;
}
.highlight {
color: #45d845;
}
.heading {
background-color: #d84545;
border-bottom: 5px solid black;
padding-top: 20px;
padding-bottom: 20px;
}
#comet {
font-size: 65px;
margin-left: 20px;
}
/*Showcase*/
.showcase {
background: url('background1.jpeg');
border-bottom: 5px solid black;
height: 1000px;
width: 100%;
background-size: 100% 100%;
background-repeat: no-repeat;
color: #cccccc;
display: flex; /* Added */
flex-direction: column; /* Added */
align-items: center; /* Added, horizonal alignment */
}
.showcase h2 {
color: #fff;
margin-top: 170px;
font-size: 60px;
font-family: Verndana;
text-shadow: 1px 3px #000;
text-align: center;
}
#start {
/* align: center; Not valid CSS */
margin-top: 130px;
background-color: transparent;
color: #fff;
padding: 20px 30px 20px 30px;
/* text-align: center; No longer required */
font-family: Helvetica;
font-weight: bold;
border-radius: 10px;
-webkit-transition-duration: 0.4s;
/* Safari */
transition-duration: 0.4s;
}
#start:hover {
cursor: pointer;
background-color: #fff;
color: #000;
}
<header>
<div class="heading">
<h1>ThumbTac <span id="comet">☄</span> </h1>
</div>
</header>
<div class="showcase">
<h2>He moonlight difficult engrossed an it sportsmen. Interested has all devonshire difficulty jay assistance joy. Unaffected at ye </h2>
<button id="start" align="center">Get Started</button>
</div>
Could anybody help me and have a look at my HTML page, and explain to me if this is a correct semantic way to set-up a HTML page?
I need to learn to build a webpage with as less divs as possible, but you can use them if you want to style something specific right? like I used them in this context.
So are there any any flaws in my HTML code?
.main-club-bar-music-festival {
overflow: auto;
}
.main-club-bar-music-festival h3 {
margin: 0;
}
.img-club-air {
position: relative;
}
.img-club-air img {
width: 100%;
}
.img-club-air a:first-child {
position: absolute;
margin: 10px;
width: 60px;
right: 0;
bottom: 0;
z-index: 1;
}
.img-club-air h2 {
position: absolute;
bottom: 0;
font-size: 20px;
width: 100%;
padding: 10px;
color: white;
font-family: "LemonMilk"
}
#paragraph-p {
padding: 20px;
margin: 0;
}
.rent-a-bike {
width: 200px;
margin: 20px auto;
text-align: center;
background-color: #eb6c74;
}
.rent-a-bike p {
margin: 0;
padding: 10px;
color: white;
text-transform: capitalize;
transform: translateX(-5%);
overflow: hidden;
}
.rent-a-bike img {
margin-top: 10px;
margin-left: 5px;
height: 38px;
float: left;
}
.show-me-the-way {
width: 200px;
margin: 20px auto;
text-align: center;
background-color: #eb6c74;
}
.show-me-the-way p {
margin: 0;
padding: 10px;
color: white;
text-transform: capitalize;
}
.show-me-the-way img {
height: 38px;
float: left;
}
.info-block {
background-color: #eb6c74;
color: white;
padding: 10px 20px;
text-transform: uppercase;
font-family: "NeueHaasGrotesk Light";
}
.address-club {
overflow: auto;
margin-bottom: 16px;
}
.address-club p {
padding: 10px 20px 0 20px;
margin-bottom: 0;
}
.address-club img {
height: 40px;
margin-left: 10px;
float: left;
margin-right: 10px;
}
.address-club a {
line-height: 40PX;
display: block;
color: #3b3b3b;
text-decoration: underline;
}
.address-club a[target=_blank] {
padding-left: 20px;
color: #0000EE;
}
.padding-info-club {
padding: 20px;
}
.regular-info-left {
float: left;
width: 49.5%;
text-align: center;
color: white;
}
.regular-info-left p:nth-child(1) {
margin: 0;
}
.regular-info-left p:nth-child(2) {
margin: 2px 0;
}
.regular-info-left p:nth-child(3) {
margin: 2px 0;
}
.regular-info-left p {
background-color: #3b3b3b;
height: 50px;
line-height: 50px;
text-transform: uppercase;
}
.regular-info-right {
float: right;
width: 49.5%;
text-align: center;
color: white;
}
.regular-info-right p:nth-child(1) {
margin: 0;
}
.regular-info-right p:nth-child(2) {
margin: 2px 0;
}
.regular-info-right p:nth-child(3) {
margin: 2px 0;
}
.regular-info-right p {
background-color: #3b3b3b;
height: 50px;
line-height: 50px;
text-transform: uppercase;
}
#overflow-regular-info {
overflow: auto;
}
.info-feedback-on-page {
margin: 10px 0;
border-top: 1px solid #eb6c74;
border-bottom: 1px solid #eb6c74;
padding: 0px 0px 10px 20px;
}
.info-feedback-on-page button {
border-radius: 40%;
background-color: transparent;
margin-right: 10px;
}
#button-yes {
background-color: white;
border-radius: 28px;
border: 2px solid #44c767;
color: #44c767;
font-size: 15px;
padding: 10px 25px;
outline: 0;
}
#button-yes:active {
position: relative;
top: 2px;
outline: 0;
}
#button-no {
background-color: white;
border-radius: 28px;
border: 2px solid #e35656;
color: #e35656;
font-size: 15px;
padding: 10px 25px;
outline: 0;
}
#button-no:active {
position: relative;
top: 2px;
outline: 0;
}
<main class="main-club-bar-music-festival">
<div class="img-club-air">
<img src="img/favorite-icon-add.svg" alt="add to favourites">
<img src="img/club-panama.jpg" alt="Club Panama">
<h2>panama</h2>
</div>
<h3 class="info-block">regular info</h3>
<section id="overflow-regular-info">
<div class="regular-info-left">
<p>dancing</p>
<p>go out with mates</p>
<p>expensive</p>
</div>
<div class="regular-info-right">
<p>edm</p>
<p>locals/foreigners</p>
<p>groups</p>
</div>
</section>
<p id="paragraph-p">Panama chose a bit of a peculiar spot to open a nightclub. Located outside the city centre, Panama created a diversified nightclub. The nightclub holds a lot of parties varying from electronic tp 80's and 90s parties. Panama also houses HappyHappyJoyJoy, an asian shared dining restaurant</p>
<div class="rent-a-bike">
<a href="http://www.ov-fiets.nl/huurlocaties?locatie=amsterdam&POST_AUTOCOMPLETE=%2Fhuurlocaties.xml" target="_blank">
<img src="img/bicycle-icon.svg" alt="OV-Bicycle">
<p>rent ov-bike
<br>€ 3,85,-/24 hour</p>
</a>
</div>
<div class="show-me-the-way">
<a href="">
<img src="img/location-icon.svg" alt="your location to destination">
<p>show me the way</p>
</a>
</div>
<h3 class="info-block">average price for a drink</h3>
<p class="padding-info-club">- € 2,30,-</p>
<h3 class="info-block">entrance</h3>
<p class="padding-info-club">- € 5,00,-</p>
<h3 class="info-block">address</h3>
<div class="address-club">
<p>Panama
<br> Oostelijke Handelskade 4
</p>
www.panama.nl
020 311 86 86<img src="img/phone-icon.svg" alt="call-icon">
</div>
<h3 class="info-block">opening hours</h3>
<p class="padding-info-club">Fr - Su: 21:00 - 05:00pm</p>
<div class="info-feedback-on-page">
<p>Was this information usefull for you as an international student?</p>
<button id="button-yes">yes</button>
<button id="button-no">no</button>
</div>
</main>
How can I put the arrow in the button box? Any suggestions about the code would be appreciated.
HTML:
<!--Header-->
<div class="mainHeader header">
<h1>
LET US MAKE YOUR AWESOME IDEA HAPPENN
</h1>
<div class="button">
<p class="">
WATCH VIDEO
</p><img src="playbutton.png">
</div>
</div>
CSS:
.button {
width: 250px;
height: 46px;
border: solid white 2px;
margin: 0 auto;
z-index: 2;
position: relative;
top: 70%;
}
.button p {
text-align: center;
font-size: 20px;
font-family: 'Teko', sans-serif;
color: white;
position: relative;
bottom: 20%;
}
http://codepen.io/anon/pen/RPpQPV
body{
background: #000;
}
button {
width: 250px;
height: 46px;
margin: 0 auto;
background: none;
border: solid white 2px;
z-index: 2;
position: relative;
text-align: center;
font-size: 20px;
font-family: 'Teko', sans-serif;
color: white;
}
<button>
WATCH SHOWREEL
<img src="http://iconizer.net/files/Splashyfish/orig/arrow_medium_down.png">
</button>