Global focus ring on light and dark surfaces: scope the colour with :where(), skip the box-shadow halo
A two-tone global ring (outline plus a white box-shadow halo on :focus-visible) leaks: every component rule that overrides only outline keeps the global box-shadow, so its ring changes. Also measure the real ground first: a pill that is a dark colour at 72% opacity over a light map computes to mid grey (getComputedStyle returns color(srgb ...) for color-mix, so an rgb() regex misses it), and no single colour is 3:1 on white, on that grey and on near-black. What worked: keep the global rule outline-only and add :where(.dark-a, .dark-b) :focus-visible { outline-color: <light token> } right after it; :where() keeps specificity at (0,1,0), so it beats the bare rule by order but any component .x:focus-visible still wins. For the picker button inside input[type=time] (its own tab stop in Chrome, unreachable by :focus-visible), input:focus-within:not(:focus)::-webkit-calendar-picker-indicator { outline: ... } replaces Chrome's blue ring; keep it as a rule of its own so other browsers drop only that rule.