/* ==========================================================================
   Reading Progress
   ========================================================================== */

.reading-progress {
  background: $white;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba($primary, .1);
  position: relative;
  width: 255px;
}

.reading-progress ul {
  list-style: none;
  padding-left: 0;
}

.reading-progress li {
  counter-increment: articles;
}

.reading-progress a {
  display: block;
  padding: 12px 12px 12px 60px;
  position: relative;
}

.reading-progress a::before,
.reading-progress a::after {
  position: absolute;
}

.docs .reading-progress li a:not([class]),
.docs .reading-progress p a:not([class]) {
  border-bottom: 0 dashed rgba($primary, .4);

  &:hover {
    border-bottom: 0 dashed $accent;
  }
}

.reading-progress a::before {
  background: transparent;
  border-radius: 50%;
  bottom: auto;
  box-shadow: 0 2px 8px rgba($primary, .2);
  color: rgba($primary, .4);
  content: counter(articles);
  font-family: $font-primary;
  font-size: 12px;
  font-weight: 400;
  height: 36px;
  left: 12px;
  line-height: 36px;
  text-align: center;
  top: 12px;
  transform: none;
  transition: background-color .3s, color .3s;
  width: 36px;
}

.reading-progress a.reading .reading-title {
  color: $accent;
}

.reading-progress a.reading svg {
  display: block;
}

.reading-progress a.reading::before {
  background-color: $white;
  color: rgba($primary, .8);
}

.reading-progress a.read .reading-title {
  color: rgba($primary, .6);
  text-decoration: line-through;
}

.reading-progress a.reading.read svg {
  display: none;
}

.reading-progress a.read::before {
  background-color: $gray-lighter;
  color: lighten($gray-base, 70%);
}

.reading-progress a.reading:not(.read)::before {
  color: $accent;
}

.reading-progress li:last-of-type a::after {
  display: none;
}

.reading-title {
  color: rgba($primary, .6);
  display: block;
  font-family: $font-primary;
  font-size: 14px;
  font-weight: 400;
  line-height: 24px;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color .3s;
  white-space: normal;
}

.reading-subtitle {
  color: rgba($primary, .4);
  font-size: 10px;
}

.reading-progress svg {
  bottom: auto;
  display: none;
  height: 38px;
  left: 11px;
  position: absolute;
  stroke: $accent;
  top: 11px;
  transform: none;
  width: 38px;
}
