interactionsRauno
Gradient Text Selection
MUST
MUST: For gradient text (`background-clip: text`), unset the gradient in `::selection` — otherwise the selection highlight renders it unreadable.
Gradient text should unset the gradient on ::selection state for readability
.gradient-text::selection { -webkit-text-fill-color: #fff; background: var(--accent); }Bad
Good
Why it matters
When users select gradient text, the gradient effect combined with the selection highlight makes the text unreadable. Override ::selection to use a solid color and unset -webkit-text-fill-color so selected text remains legible.
References