Skip to content

Instantly share code, notes, and snippets.

@estrattonbailey
Last active July 16, 2018 13:56
Show Gist options
  • Save estrattonbailey/4540d802e004751313b8a65c3419d94e to your computer and use it in GitHub Desktop.
Save estrattonbailey/4540d802e004751313b8a65c3419d94e to your computer and use it in GitHub Desktop.
Global Styles
/**
* Variables
*/
:root {
/* colors */
--black: #000;
--gray1: #555;
--gray2: #aaa;
--gray3: #ddd;
--white: #fff;
--red: #ff0000;
/* transitions */
--fast: 300ms;
--slow: 600ms;
--ease: ease-in-out;
}
/**
* Breakpoints
*/
@custom-media --xs (min-width: 25em); /* 400 */
@custom-media --s (min-width: 37.5em); /* 600 */
@custom-media --m (min-width: 56.25em); /* 900 */
@custom-media --ml (min-width: 65.63em); /* 1050 */
@custom-media --l (min-width: 75em); /* 1200 */
@custom-media --xl (min-width: 81.25em); /* 1300 */
/**
* Colors
*/
.c-black {
color: var(--black);
}
.bg-black {
background-color: var(--black);
}
.c-white {
color: var(--white);
}
.bg-white {
background-color: var(--white);
}
/**
* Typography
*/
html, body {
font-size: 100%;
font-weight: 400;
color: var(--black);
-webkit-font-smoothing: antialiased; /* do no change */
}
.sans {
font-family: sans-serif;
}
.serif {
font-family: serif;
}
.h0 {
font-size: 3rem;
@media (--m) {
font-size: 5rem;
}
}
h1, .h1 {
font-size: 3rem;
@media (--m) {
font-size: 4rem;
}
}
h1 {
line-height: 1.1;
}
h2, .h2 {
font-size: 2rem;
@media (--m) {
font-size: 3rem;
}
}
h2 {
line-height: 1.3;
}
h3, .h3 {
font-size: 1.5rem;
@media (--m) {
font-size: 2rem;
}
}
h3 {
line-height: 1.5;
}
h4, .h4 {
font-size: 1rem;
@media (--m) {
font-size: 1.5rem;
}
}
h4 {
line-height: 1.5;
}
h5, .h5 {
font-size: 1rem;
}
h5 {
line-height: 1.6;
}
h6, .h6 {
font-size: 0.875rem;
}
h6 {
line-height: 1.6;
}
p, .p {
font-size: 1rem;
}
p {
line-height: 1.7;
}
small, .small {
font-size: 0.75em;
}
a {
color: inherit; /* do no change */
text-decoration: none; /* do no change */
}
strong, .b {
font-weight: bold; /* do no change */
}
em, .i {
font-style: italic; /* do no change */
}
.caps {
text-transform: uppercase; /* do no change */
}
.fw-light {
font-weight: 300;
}
.fw-medium {
font-weight: 500;
}
.fw-bold {
font-weight: 700;
}
/**
* Specialty text styles
*/
.underline {
color: var(--black);
&:hover {
}
}
.underline--red {
color: var(--red);
&:hover {
}
}
/**
* WYSIWYG Overrides
*/
.wysiwyg {
h1 {
@media (--m) {
font-size: 3.5rem;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment