while () { s/(background-color:#)(?:[0-9a-f]{6}|[0-9a-f]{3})/$1ffffff/i; print; }