これを達成する必要があります: 赤いボックスにカーソルを合わせると紫色のボックスが消え、オレンジ色のボックスにカーソルを合わせると青色のボックスが消え、黄色のボックスにカーソルを合わせると緑色のボックスが消えます。私はそれを行うことができましたが、逆も行う必要がありますが、試したことはすべてうまくいきませんでした。誰でも私を助けることができますか?
<html>
<head>
<title>Boxes</title>
<style type"text/css">
div {
width:70px;
height:90px;
border:3px solid #000;
}
.t1 {
background: red;
top: 50px;
left: 15px;
position: absolute;
}
.t1:hover + .t6{
background: red;
top: 50px;
left: 15px;
z-index: 1;
position: absolute;
visibility: invisible;
}
.t2 {
position: absolute;
background:orange;
top: 100px;
left: 60px;
}
.t2:hover + .t5 {
position: absolute;
background:orange;
top: 100px;
left: 60px;
z-index: 1;
visibility: invisible;
}
.t3 {
background:yellow;
top: 150px;
left: 110px;
position: absolute;
}
.t3:hover + .t4 {
background:yellow;
top: 150px;
left: 110px;
position: absolute;
visibility: invisible;
z-index: 1;
}
.t4 {
background:green;
top: 200px;
left: 160px;
position: absolute;
}
.t5 {
background:blue;
top: 250px;
left: 210px;
position: absolute;
z-index: 1;
}
.t6 {
background:purple;
top: 300px;
left: 260px;
position: absolute;
z-index: 2;
}
<!--backwards-->
</style>
</head>
<body>
<div class="t1"></div>
<div class="t6"></div>
<div class="t2"></div>
<div class="t5"></div>
<div class="t3"></div>
<div class="t4"></div>
</body>