Eu estou fazendo um programa com código de html , css e javascript, eu estou com problema na parte de css, pois eu tou querendo mudar a cor do botão ou o código input type="button" value="somar" mas não consigo, como se faça afinal? para entender melhor vou inserir os dados!
<!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Somando Números</title>
</head>
<body>
<h1>Somando Valores</h1>
<input type="number" name="txn1" id="txn1">
<input type="number" name="txn2" id="txn2">
<input type="button" value="somar" onclick="somar()">
<div id="res">Resultado</div>
</body>
</html>
body {
text-align: center;
}
h1 {
color: blue;
}
function somar() {
var tn1 = document.getElementById('txtn1')
var tn2 = document.getElementById('txtn2')
var res = document.getElementById('res')
var n1 = number(tn1.value)
var n2 = number(tn2.value)
var s = n1 + n2
res.innerHTML = `A soma entre ${n1} e ${n2} é igual a ${s}`
}