<p>The default color of the html element is black. The default colour of the body and of a paragraph is inherited. This
<a href="http://example.com">link</a> would normally take on the default link or visited color, but has been styled to inherit the color from the paragraph.</p>
嘗試這樣的事情:
如果
text-decoration
不起作用,請將其變更為:!important
規則會覆寫text-decoration
屬性的所有其他樣式。您可以在此處閱讀更多相關資訊。繼承值:
...將導致元素呈現其父級的顏色(我認為這就是您正在尋找的)。
現場示範如下: