// # Icons
// SVG and activity icons. A few things to note about SVGs:
//
// - Use these class options on your SVG. Only size them in your CSS if absolutely necessary.
// - The color of the SVG will inherit the parent's `color`.
// - Note: To use this icons make sure that the SVG source sprite
// is placed immediately after the `<body>`, like so:

//[c]
//     <svg xmlns="http://www.w3.org/2000/svg" style="display: none;">
//         <symbol id="collapse" viewBox="0 0 14 15">
//           <title>collapse</title>
//           <path d="M0 0h14v3H0zM5 15v-3H1.97L7 7l5.028 5H9v3h5V5H0v10z"/>
//         </symbol>
//         ... additional symbol entries here...
//     </svg>
//[/c]

// ## Activity Icons

// <div class="example html">
//     <ul class="lego-block-list-group">
//       <li>
//         <div class="lego-media">
//           <span class="icon-status--active lego-media__img flush--top"></span>
//           <div class="lego-media__body">
//             <p>This is the active item.</p>
//           </div>
//         </div>
//       </li>
//       <li>
//         <div class="lego-media">
//           <span class="icon-status--good-news lego-media__img flush--top"></span>
//           <div class="lego-media__body">
//             <p>This is good.</p>
//           </div>
//         </div>
//       </li>
//       <li>
//         <div class="lego-media">
//           <span class="icon-status--bad-news lego-media__img flush--top"></span>
//           <div class="lego-media__body">
//             <p>This is probably not good.</p>
//           </div>
//         </div>
//       </li>
//       <li>
//         <div class="lego-media">
//           <span class="icon-status--empty lego-media__img flush--top"></span>
//           <div class="lego-media__body">
//             <p>This is not active but holds the space if needed.</p>
//           </div>
//         </div>
//       </li>
//     </ul>
// </div>


// ## SVG Icons
// Click to copy.
//
// <ul id="icon-examples">icon examples are generated by javascript</ul>

.#{$namespace}icon {
  width: 16px;
  height: 16px;
  display: inline-block;
  fill: currentColor;

  &--small {
    width: 12px;
    height: 12px;
  }

  &--large {
    width: 32px;
    height: 32px;
  }
  // This is a vertical alignment fix when used to the right of `.#{$namespace}icon`.

  + [class^="#{$namespace}-arrow-inline"] {
    vertical-align: super;
  }
}


// Fix for icons inside buttons with text.

.#{$namespace}button .#{$namespace}icon {
  vertical-align: sub;
}

// Fix for icons inside tabs.

.#{$namespace}tabs-nav__item .#{$namespace}icon {
  vertical-align: sub;
}

// ## Activity Icons
// Used for showing the status item.

.icon-status {

  &--active,
  &--bad-news,
  &--good-news,
  &--empty {
    &::before {
      content: '';
      border-radius: map-fetch($border-radius, full);
      display: inline-block;
      width: 10px;
      height: 10px;
    }
  }

  &--active::before {
    background: map-fetch($color, ui brand);
  }

  &--bad-news::before {
    background: map-fetch($color, ui bad-news);
  }

  &--good-news::before {
    background: map-fetch($color, ui good-news);
  }
}
