.sui-m-card {
  position: relative;
  color: $sui-color-brand-denim;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  border-radius: $sui-border-radius-lg;
  box-shadow: $sui-shadow-100;
  background: $sui-color-brand-denim-100;
  overflow: hidden;
  transition: all 0.2s $sui-curve-easeInOutCubic;

  & > * {
    @include suiTransformFix();
    // Fix ie11 bug
    max-width: 100%;
  }

  &:hover &__actions,
  &:focus &__actions {
    opacity: 1;
  }

  &__actions {
    opacity: .4;
    position: absolute;
    top: $sui-space-md;
    right: $sui-space-md;
    transition: .2s;

    & > * {
      font-size: $sui-font-size-ms;
    }
  }

  &__actions ~ &__content > :first-child {
    margin-right: $sui-size-md;
  }

  &__content {
    flex: auto;
    display: flex;
    flex-direction: column;
    color: inherit;
    padding: $sui-space-md;
    text-decoration: none;

    & > * + * {
      margin-top: $sui-space-xs;
    }
  }

  &__category {
    color: $sui-color-text-light;
    text-transform: uppercase;
    font-size: $sui-font-size-sm;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;

    .sui-a-icon {
      font-size: $sui-font-size-ms;
    }
  }

  &__title {
    font-size: $sui-font-size-ml;
    transition: .2s;
    margin-bottom: 0;
    font-weight: normal;
  }

  &__details {
    & > :first-child {
      margin-top: 0;
    }

    & > :last-child {
      margin-bottom: 0;
    }

    p {
      font-size: $sui-font-size-ms;
    }
  }

  &__footer {
    position: relative;
    padding: $sui-space-sm $sui-space-md;
    text-decoration: none;
    color: inherit;
    transition: .2s;

    & > * {
      position: relative;
    }

    & > :first-child {
      margin-top: 0;
    }

    & > :last-child {
      margin-bottom: 0;
    }
  }

  &__content &__footer {
    margin: $sui-space-md*-1 - $sui-size-border;
    margin-top: auto;
    padding-top: $sui-space-md + $sui-space-sm;
  }

  &__content ~ &__footer {
    margin-top: -$sui-border-radius-sm;
    border-top: $sui-size-border solid $sui-color-border-light;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
  }

  // -------------------------
  //    Links
  // -------------------------
  @at-root {
    a#{&}:hover &__title,
    a#{&}:focus &__title,
    a#{&}__content:hover &__title,
    a#{&}__content:focus &__title {
      color: $sui-color-primary;
    }

    a#{&}:hover &__content,
    a#{&}:focus &__content,
    a#{&}__content:hover,
    a#{&}__content:focus {
      background: $sui-color-brand-denim-200;
    }

    a#{&}__footer:hover,
    a#{&}__footer:focus,
    button#{&}__footer:hover,
    button#{&}__footer:focus {
      background: $sui-color-brand-denim-200;
    }
  }
  // -------------------------
  //    Buttons
  // -------------------------
  @at-root {
    div[role=button],
    div[role=button] {
      cursor: pointer;
    }

    div[role=button]:hover,
    div[role=button]:focus {
      transform: translateY(rem(-3));
    }

    div[role=button]:active,
    div[role=button]#{&}.as--active {
      box-shadow: 0 0 0 rem(2) rgba($sui-color-primary, .25), $sui-shadow-300;
      transform: translateY(rem(-2));
    }

    div[role=button] &__content:hover &__title,
    div[role=button] &__content:focus &__title,
    div[role=button]#{&}.as--active &__content &__title {
      color: $sui-color-primary;
    }

    div[role=button]:active &__content,
    div[role=button]:focus &__content {
      background: $sui-color-brand-denim-200;
    }
  }
}
