Anladığım kadarıyla bu kod yapısı mevcut sizde
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
</head>
<body>
<div id="anakatman">
<div class="altkatman">
<ul>
<li>
s
</li>
</ul>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.5.1.min.js" type="text/javascript"></script>
</body>
</html>
Bu kod ile li'ye erişebiliyorum.
$("#anakatman .altkatman li").css("background", "red")