Native rich-text CSS namespaces
Internal XHTML style sheets support CSS namespace declarations and qualified element and attribute selectors through the existing native rich-text decoder
<body xmlns="http://www.w3.org/1999/xhtml" xmlns:meta="urn:review">
<style>
@namespace h "http://www.w3.org/1999/xhtml";
@namespace review "urn:review";
h|span[review|status="ready"] { color: #204080; font-weight: bold }
</style>
<p><span meta:status="ready">Approved</span></p>
</body>
CSS prefixes identify namespace URIs independently of XML prefixes, so review|status in the example matches meta:status because both prefixes resolve to urn:review
Prefix names are case-sensitive and accept ordinary CSS identifier escapes; namespace URI values accept quoted strings and quoted or unquoted url() syntax
Comments inside an unquoted url token remain literal URI characters; whitespace surrounding the unquoted URI is excluded from the value
The last valid declaration for a prefix wins within its style element; the last default declaration wins independently, and bindings do not leak into another style element
Place declarations before style rules and recognised non-import at-rules; an unknown ignored at-rule does not close the declaration region
Qualified names and default namespaces
h|span matches a local span name in the URI declared for h, *|span accepts any namespace, and |span requires no namespace
h|* matches any element name in the declared URI; the decoder continues to consume the existing supported XHTML element profile
A default declaration such as @namespace "urn:review"; restricts unqualified element selectors and ordinary compounds with an implicit universal selector
An empty default URI selects elements with no namespace; the literal URI "*" is an ordinary URI and is distinct from the wildcard prefix in *|span
Attribute selectors support declared prefixes, wildcard prefixes and explicit empty prefixes; unprefixed attributes remain in no namespace regardless of the default element namespace
XML namespace declarations do not count as ordinary attributes; namespace resolution follows the attribute's own element scope and respects local prefix shadowing, including the built-in xml prefix
Functional selectors
The subject compound inside :is(), :where() and :not() omits the default namespace restriction when it has no explicit type or universal selector
An explicit universal selector retains that restriction; earlier ancestor compounds, relative :has() arguments and of filters in positional selectors retain ordinary namespace matching
An undeclared CSS prefix invalidates its selector; forgiving is/where lists can retain other valid branches, whilst strict selector groups keep their existing whole-group invalidation rules
Saved output and resource limits
Computed styles feed saved RV and actual widget appearances through native Pascal, Windows jobs and V1 callbacks, and Linux JSON and V1 callbacks
Existing importance, specificity, source ordering and property inheritance rules continue to apply after namespace matching
Namespace declaration storage shares MaxNodes, namespace scanning shares MaxTotalCodeUnits, and inherited attribute namespace lookup charges bounded matching and scan work
Cancellation and budget failures preserve the prior decoder output and committed import state; callers may retry with the original input and normal limits
External style sheets, conditional media rules, additional state pseudo classes and explicit scoping roots, tables and general CSS layout remain active work
Native rich-text style sheets · Native form-data interchange