// | -------------------------------------------------------------
// | Lists
// | -------------------------------------------------------------

@use 'breakpoint' as *;

ul:not([class]),
ol:not([class]) {
  margin-left: 1rem;

  ul,
  ol {
    padding: 0.5rem 1rem 0;
  }

  li {
    margin-bottom: 0.5rem;
  }
}

ul:not([class]) {
  > li::marker {
    display: block;
    color: var(--primary-800);
  }
}

ol.incremented {
  counter-reset: item;

  ol {
    counter-reset: item;
  }

  ol,
  ul {
    margin: 0.75rem 0 0 1rem;
  }

  li {
    display: block;
    margin-bottom: 0.5rem;

    @include breakpoint(medium) {
      margin-bottom: 0.75rem;
    }

    &::before {
      content: counters(item, '.') '. ';
      counter-increment: item;
    }

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

    p {
      display: inline;
    }
  }

  ul {
    li::before {
      content: '';
    }
  }
}
