// Footnote
//
// The fine print. Use for legal text, disclaimers, references, or help text. Use `.js-footnote-toggle`
// and `.js-footnote-hidden` to create toggleable content. See `footnote.js` for implementation.
//
// Markup:
//   <h4>Legal text example:</h4>
//   <p class="footnote">By clicking submit, you agree to <a href="#">sell your soul</a> to the lorem ipsum dolor sit amet.</p>
//   <h4>Source footnote example:</h4>
//   <div class="footnote">
//     <h4 class="js-footnote-toggle">Sources</h4>
//     <ul class="js-footnote-hidden">
//       <li><sup>1</sup> Clark, Barry. "A Treatise on The Motherland", British Royal Archives, 2009.</li>
//       <li><sup>2</sup> Lorch, Julie. "Coffee Sure Is Great", Royal Academy of Coffee, 2010.</li>
//     </ul>
//   </div>
//
// Styleguide Footnote
.footnote {
  font-size: $font-small;
  color: $med-gray;

  p {
    font-size: $font-small;
    color: $med-gray;
    margin: 0;
  }

  .heading, h1, h2, h3, h4, h5, h6 {
    color: $med-gray;
  }

  sup {
    top: -0.7em;
    display: inline-block;
    min-width: ($base-spacing / 4);
    text-align: right;
  }

  // Fix issue where superscript followed by Markdown
  // content does not wrap correctly
  li p {
    display: inline;
  }

  // Add some spacing between source items in lists
  li + li {
    margin-top: ($base-spacing / 2);
  }

  a {
    color: $med-gray;
    text-decoration: underline;

    &:hover {
      color: lighten($med-gray, $color-tint);
    }

    &:active {
      color: darken($med-gray, $color-tint);
    }
  }
}
