// Mixin to maintain an elements aspect ratio, even as it scales.
@mixin aspect-ratio($width: 16, $height: 9) {
  position: relative;

  &::before {
    content: '';
    display: block;
    padding-top: ($height / $width) * 100%;
    width: 100%;
  }

  > * {
    bottom: 0;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
  }
}
