/***************************************************************************************
* Typography
***************************************************************************************/

// Global

html {
  font-size: $font-size-base;
}

body {
  font-weight: 300;
  font-size: 1em; /* equivalent to 14px */
  line-height: $line-height-base; /* equivalent to 22.75px */
  -webkit-font-smoothing: antialiased;
}

body, caption, th, td, input, textarea, select, option, legend, fieldset, h1, h2, h3, h4, h5, h6 {
  font-size-adjust: 0.5; //http://caniuse.com/#search=font-size-adjust
}
p {
  line-height: 1.425;
}

// Links

a:hover, a:active, a:focus {
  text-decoration:none;
}

// Headings

h1,h2,h3,h4,h5,h6 {
  font-weight: $headings-font-weight;
  font-family: $headings-font-family;
}

h1 {
  font-size: 2em; /* 2x body copy size = 28px */
  line-height: 1.25; /* 43.75 / 28.4375px */
}
h2 {
  font-size: 1.625em; /* 1.625x body copy size = 22.75px */
  line-height: 1.15384615; /* 32.3076922px / 26.249999912px */
}
h3 {
  font-size: 1.375em; /* 1.375x body copy size = 19.25px */
  line-height: 1.13636364; /* 23.86363644px / 21.87500007px */
}
h4 {
  font-size: 1.125em; /* 1.125x body copy size = 20.25px */
  line-height: 1.11111111; /* 17.499999982px */
}

h1.subheading, h2.subheading, h3.subheading, h4.subheading {
  font-size: 1.125em; /* 1.125x body copy size = 20.25px */
  line-height: 1.11111111; /* 17.499999982px */
}


@media (min-width: $screen-xs-min) {
  //480px
  h1 {
    font-size: 2.5em; /* 2.5x body copy size = 35px */
    line-height: 1.125;
  }
  h2 {
    font-size: 2em; /* 2x body copy size = 28px */
    line-height: 1.25;
  }
  h3 {
    font-size: 1.5em; /* 1.5x body copy size = 21px */
    line-height: 1.25;
  }
  h4 {
    line-height: 1.22222222; /* 19.249999965px */
  }
  h1.subheading, h2.subheading, h3.subheading, h4.subheading {
    font-size: 1.225em; /* 1.225x body copy size = 20.25px */
    line-height: 1.11111111; /* 17.499999982px */
  }
}
@media (min-width: $screen-sm-min) {
  //768px
  h1 {
    font-size: 3em; /* 3x body copy size = 42px */
    line-height: 1.05;
  }
  h2 {
    font-size: 2.25em; /* 2.25x body copy size = 31.5px */
    line-height: 1.25;
  }
  h3 {
    font-size: 1.75em; /* 1.75x body copy size = 24.5px */
    line-height: 1.25;
  }
}

.page-header {
  font-weight: normal;
  margin-top: 0;
  @media print {
    border: none;
  }
}
.subheading {
  font-weight: 400;
  color: #777;
  margin-top: -$line-height-computed * 1.364;
  border-bottom: 1px solid $gray-lighter;
  background: #fff;
  padding-bottom: 5px;
  @media print {
    border: none;
  }
}
.subheading.inpage {
  border: none;
}
.small-heading {
  font-size: $font-size-h4 * $subheading-ratio;
  text-transform: uppercase;
  font-weight: normal;
  letter-spacing: 1px;

  &.bold {
    font-weight: bold;
  }
}

// Brand

.brand-font {
  font-family: $brand-font-family;
  text-transform: uppercase;
  font-weight: 900;
  letter-spacing: -1px;
  @media (min-width: $screen-sm-min) {
    letter-spacing: -1.8px;
  }
}

.text-ellipsis {
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  display: block;
}


// Blockquote
blockquote {
  font-size: 1.25em;
  /* 17.5px / 14px */
  line-height: 1.25;
}

@media (min-width: $screen-xs-min) {
  blockquote {
    font-size: 1.5em;
    /* 21px / 14px = */
    line-height: 1.45833333;
  }
}

.text-secondary {
  color: $brand-secondary;
}
