-
-
Save fovoc/412345656b5033bdd2b1d79e3afc8ad6 to your computer and use it in GitHub Desktop.
Double Line Subtitles
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<article> | |
<h1>Main Title</h1> | |
<p class="subtitle fancy"><span>A fancy subtitle</span></p> | |
</article> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import url(https://fonts.googleapis.com/css?family=Cinzel+Decorative:400,900); | |
body { | |
font-family: 'Cinzel Decorative', cursive; | |
background: black; | |
background-size: cover; | |
color: white; | |
} | |
h1 { | |
font-size: 3em; | |
text-align: center; | |
} | |
article { | |
max-width: 600px; | |
overflow: hidden; | |
margin: 0 auto 50px; | |
} | |
.subtitle { | |
margin: 0 0 2em 0; | |
} | |
.fancy { | |
line-height: 0.5; | |
text-align: center; | |
} | |
.fancy span { | |
display: inline-block; | |
position: relative; | |
} | |
.fancy span:before, | |
.fancy span:after { | |
content: ""; | |
position: absolute; | |
height: 5px; | |
border-bottom: 1px solid white; | |
border-top: 1px solid white; | |
top: 0; | |
width: 600px; | |
} | |
.fancy span:before { | |
right: 100%; | |
margin-right: 15px; | |
} | |
.fancy span:after { | |
left: 100%; | |
margin-left: 15px; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment