/*!
 * Preboot v2 Docs
 * Styles for presenting Preboot features and benefits.
 */


//
// Dependencies
//

@import "normalize.less";
@import "preboot.less";
@import "pygments.less";


//
// Docs
//


html,
body {
  background-color: #fff;
}
body {
  padding: 0;
  font-family: "Maven Pro", "Helvetica Neue", Helvetica, sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
  color: #555;
}

// Bangin' links
a {
  color: @link-color;
  text-decoration: none;
  &:hover {
    color: @link-color-hover;
    text-decoration: underline;
  }
}

// Typography
h1, h2, h3, h4, h5, h6 {
  margin: 30px 0 10px;
  font-weight: bold;
  line-height: 1.2;
  color: #333;
}
h1 {
  font-size: 48px;
}
h2 {
  font-size: 36px;
}
h3 {
  font-size: 24px;
  a, a:hover {
    color: inherit;
  }
}
h4 {
  font-size: 18px;
  margin-bottom: 0;
}

p {
  margin: 0 0 15px;
}
.lead {
  font-size: 18px;
  line-height: 1.25;
  color: @black-40;
}

ol,
ul {
  margin: 0 0 15px 25px;
  padding: 0;
}
.list-unstyled {
  margin-left: 0;
  li {
    display: block;
  }
}

// Inline and block code styles
code,
pre {
  padding: 0 3px 2px;
  color: #333;
  border-radius: 4px;
}

// Inline code
code {
  padding: 2px 4px;
  font-size: 90%;
  color: #c7254e;
  background-color: #f9f2f4;
  white-space: nowrap;
}

// Blocks of code
pre {
  display: block;
  padding: 15px;
  margin: 0 0 20px;
  line-height: 1.4;
  word-break: break-all;
  word-wrap: break-word;
  white-space: pre;
  white-space: pre-wrap;
  background-color: #f5f5f5;
  border: 1px solid rgba(0,0,0,.15);
  border-radius: 4px;

  // Account for some code outputs that place code tags in pre tags
  code {
    padding: 0;
    color: inherit;
    white-space: pre;
    white-space: pre-wrap;
    background-color: transparent;
    border: 0;
  }
}

// Pygments
.highlight {
  padding: 14px;
  margin-bottom: 20px;
  line-height: 20px; // Pygments hates unitless line-height for some reason
  background-color: #f7f7f9;
  border: 1px solid #e1e1e8;
  border-radius: 4px;
  // For some reason, line numbers aren't rendering when pushed to gh-pages
  // box-shadow: inset 45px 0 0 #fbfbfc, inset 46px 0 0 #ececf0;
}
.highlight pre {
  padding: 0;
  margin-bottom: 0;
  font-size: 16px;
  background-color: transparent;
  border: 0;
}
.highlight pre .lineno {
  display: inline-block;
  width: 20px;
  padding-right: 5px;
  margin-right: 10px;
  text-align: right;
  color: #bebec5;
}

// Super simple grid
.row { .make-row(); }
.grid-4 { .make-column(4); }


// Neato divider between headers and content
.header-divider {
  margin-top: 60px;
}
.header-divider:after {
  display: block;
  content: "";
  width: 25%;
  height: 4px;
  margin: 20px 0 26px;
  background-color: #555;
  border: 0;
  opacity: .5;
}

// Shift content over for the side panel
.container {
  padding-left: 20px;
  padding-right: 20px;
  max-width: 760px;
}

// Side panel
.masthead {
  color: #fff;
  text-shadow: 0 1px 1px rgba(0,0,0,.3);
  #gradient > .vertical(darken(saturate(#7a43b6, 10%), 15%), darken(#08b5fb, 5%));
}
.masthead-inner {
  padding: 30px;
}
.masthead h1 {
  margin-top: 0;
  color: #fff;
  letter-spacing: -1px;
}
.masthead .header-divider:after {
  width: 50%;
  background-color: #fff;
  box-shadow: 0 1px 1px rgba(0,0,0,.3);
  opacity: 1;
}
.masthead .list-unstyled {
  font-size: 85%;
  margin-top: 0;
  margin-bottom: 20px;
}
.masthead .social-buttons {
  margin-bottom: 0;
}
.masthead a {
  font-weight: bold;
  color: #fff;
  &:hover {
    text-decoration: none;
    text-shadow: 0 0 8px rgba(255,255,255,.5);
  }
}

// Table of contents
.toc {
  margin-left: 0;
}
.toc li {
  display: block;
}
.toc a {
  display: block;
  margin-left: -10px;
  padding: 4px 10px;
  &:hover {
    text-decoration: none;
    background-color: #f5f5f5;
    border-radius: 3px;
  }
}

// Colors
.color-swatches {
  margin: 0 -5px 20px;
  .clearfix();
}
.color-swatch {
  float: left;
  width: 80px;
  height: 80px;
  margin: 5px 2px;

  &.black-10 { background-color: @black-10; }
  &.black-20 { background-color: @black-20; }
  &.black-30 { background-color: @black-30; }
  &.black-40 { background-color: @black-40; }
  &.black-50 { background-color: @black-50; }
  &.black-60 { background-color: @black-60; }
  &.black-70 { background-color: @black-70; }
  &.black-80 { background-color: @black-80; }
  &.black-90 { background-color: @black-90; }

  &.brand-primary { background-color: @brand-primary;}
  &.brand-success { background-color: @brand-success;}
  &.brand-warning { background-color: @brand-warning;}
  &.brand-danger  { background-color: @brand-danger;}
  &.brand-info    { background-color: @brand-info;}
}

// Buttons
.btn {
  display: block;
  margin-bottom: 5px;
  padding: 15px 20px;
  font-weight: bold;
  line-height: 1;
  color: #7a43b6;
  text-align: center;
  letter-spacing: -1px;
  background-color: #fff;
  border: 1px solid #ccc;
  border-radius: 5px;

  &:hover,
  &:active {
    color: #fff;
    text-decoration: none;
    background-color: #7a43b6;
    border-color: #7a43b6;
  }

  &:active {
    box-shadow: inset 0 3px 6px rgba(0,0,0,.3);
    border-color: darken(#7a43b6, 10%);
  }
}


// Responsive
@media screen and (min-width: 820px) {
  body {
    font-size: 18px;
  }
  .highlight {
    line-height: 25px;
  }
  .lead {
    font-size: 24px;
  }

  .btn {
    display: inline-block;
    margin-bottom: 0;
  }

  // Push over the container contents to make room
  .container {
    margin-left: 30%;
    margin-right: 10%;
    padding-left: 0;
    padding-right: 0;
  }
  // The fixins
  .masthead {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 5;
    width: 25%;
    background-attachment: fixed;
  }
  // Generate a super slick shadow for depth
  .masthead:after {
    position: absolute;
    top: -20px;
    right: 0;
    bottom: -20px;
    left: -10px;
    z-index: 10;
    display: block;
    content: " ";
    box-shadow: inset -5px 0 25px rgba(0,0,0,.3);
  }
  // Doc the text to the bottom
  .masthead-inner {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 15;
  }
}

// Larger responsive
@media screen and (min-width: 1100px) {
  .masthead h1 {
    font-size: 60px;
  }
}
