-1
I’m trying to play sites to study some html and css, I have the following code:
* {
margin: 0;
padding: 0;
}
#back {
background-image: url("back2.png");
background-size: cover;
}
body, html {
width: 100%;
height: 100%;
font-family: Arial, Tahoma, sans-serif;
}
#div_princ {
background-color: white;
width: 350px;
height: 100%;
position: relative;
}
#icon {
position: absolute;
top: 15px;
left: 15px;
}
#loguin {
position: absolute;
top: 150px;
left: 35px;
align-items: center;
}
.caixas_input {
font-size: 10px;
margin: 10px 10px;
padding-top: 15px;
padding-left: 15px;
padding-bottom: 15px;
background-color:#dcdde1;
border-radius: 5px;
width: 250px;
border: transparent;
}
input:focus {
box-shadow: 0 0 0 0;
outline: 0;
border-style: solid;
border-color: black;
}
::placeholder{
color: #a8a8a8;
font-weight: bold;
font-size: 12px;
}
#manter_login {
position: absolute;
top: 160px;
left: 10px;
}
input[type=checkbox]{
display:none; /* Esconde os inputs */
}
label {
cursor: pointer;
}
input[type="checkbox"] + label:before {
border: 1px transparent;
content: "\00a0"; /** \\ 00a0, é um código hexadecimal para um espaço sem quebra **/
display: inline-block;
font: 16px/1em sans-serif;
height: 16px;
margin: 0 .25em 0 0;
padding:0;
vertical-align: top;
width: 16px;
border-radius:4px;
background-color: #dcdde1;
}
input[type="checkbox"]:checked + label:before {
background: #e74c3c;
color: #FFF;
content: "\2713";
text-align: center;
}
#rodape {
color: #a8a8a8;
position: absolute;
top: 400px;
}
a{
text-decoration: none;
font-size: 12px;
color: #a8a8a8;
font-weight: bold;
}
a:hover {
color: black;
}
<html>
<head>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body id="back">
<div id="div_princ">
<div id="icon">
<input type="image" src="icone.jpg">
</div>
<div id="loguin">
<h3>Insira Sua conta Riot</h3>
<form>
<label for="Loguin"></label>
<input type="Loguin" placeholder="NOME DE USUARIO" class="caixas_input " required>
<label for="Password"></label>
<input type="password" placeholder="SENHA" class="caixas_input " required>
<br>
<div id="manter_login">
<input type="checkbox" class="checkbox" id="manterlogin">
<label for="manterlogin">
<span style="color:#a8a8a8; font-weight: bold;">
Manter Loguin
</span>
</label>
</div>
<div id="rodape">
<a href="https://signup.br.leagueoflegends.com/pt/signup/index#/">CRIAR CONTA</a> <br>
<a href="https://recovery.riotgames.com/pt-br?region=BR1">NÃO CONSEGUE CRIAR CONTA ?</a> <br>
<a>V9.0.0</a>
</div>
</form>
</div>
</div>
</body>
</html>
I want to put a button like this :
that when you have the mouse on it looks like this :
how can I do this ?
for me the 2 are equal... however, to change the style with the mouse over the element, use the pseudoclass
: hover
. See in your code the link examplea:hover
– Ricardo Pontual
how would it be to place the arrow?
– Lucas Gomes
this image is from an example I took on the net
– Lucas Gomes
If the body is unique on the page, it makes no sense to put a
id
in it.– Sam
Dude from what I understand you are trying to change the color of the button when you hover over or click, there is an effect called Hover in css, take a look at this link https://www.w3schools.com/howto/howto_css_animate_buttons.asp
– RM08