CSS :not(selector) 선택기를 사용하여 지정된 요소가 아닌 모든 요소의 스타일을 지정합니다. 다음 코드를 실행하여 :not 선택기를 구현할 수 있습니다.
예시
<!DOCTYPE html>
<html>
<head>
<style>
p {
color: red;
}
:not(p) {
color: blue;
}
</style>
</head>
<body>
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<p>This is a paragraph.</p>
<p>This is another paragraph.</p>
</body>
</html>