// Code
//
// The `<code>` element represents a fragment of computer code. <br />
// The `<var>` element represents a variable. <br />The `<samp>` element
// represents (sample) output from a program or computing system. <br />
// The `<kbd>` element represents user input (typically keyboard input.)
//
// markup: code.twig
//
// Weight: 3
//
// Style guide: base.code


// Inline and block code styles
code,
kbd,
pre,
samp {
  font-size: 1em;
}

// Inline code
code, kbd {
  padding: 2px 4px;
  font-size: 90%;
}

// User input typically entered via keyboard
kbd kbd {
  padding: 0;
  font-size: 100%;
  font-weight: bold;
  box-shadow: none;
}

// Blocks of code
pre {
  display: block;
  padding: (($line-height-computed - 1) / 2);
  margin: 0 0 ($line-height-computed / 2);
  font-size: ($font-size-base - 1); // 14px to 13px
  line-height: 1.625rem;
  word-break: break-all;
  word-wrap: break-word;

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