# Scoping proximity

When scoped rules clash, the closer scope wins.

## What is **scoping proximity**?

**Scoping proximity** means that when two `@scope` rules clash, the one whose scope root is closer to the element wins.

```css
@scope (.light) { p { color: black; } }
@scope (.dark)  { p { color: white; } }
/* a p inside .dark inside .light is white: .dark is closer */
```

Level: Freelancer · [More CSS terms at this level](https://www.ask-codey.com/glossary/subjects/css/freelancer)

Updated: September 27, 2026

Source: https://www.ask-codey.com/glossary/scoping-proximity
