107 lines
1.4 KiB
CSS
107 lines
1.4 KiB
CSS
body {
|
|
height: 100vh;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.grid {
|
|
width: 420px;
|
|
height: 420px;
|
|
padding: 5px;
|
|
margin: 5px;
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
background-color: darkturquoise;
|
|
}
|
|
|
|
.grid span {
|
|
width: 40px;
|
|
height: 40px;
|
|
margin: 1px;
|
|
background-color: #eee;
|
|
position: relative;
|
|
}
|
|
|
|
.grid span.hot {
|
|
background-color: darkturquoise;
|
|
}
|
|
|
|
.ship {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
flex-direction: row;
|
|
z-index: 10;
|
|
position: relative;
|
|
margin: -1px;
|
|
}
|
|
|
|
.ship.vertical {
|
|
flex-direction: column;
|
|
}
|
|
|
|
.carrier {
|
|
width: 210px;
|
|
height: 40px;
|
|
}
|
|
|
|
.carrier.vertical {
|
|
width: 40px;
|
|
height: 210px;
|
|
}
|
|
|
|
.battleship {
|
|
width: 168px;
|
|
height: 40px;
|
|
}
|
|
|
|
.battleship.vertical {
|
|
width: 40px;
|
|
height: 168px;
|
|
}
|
|
|
|
.cruiser,
|
|
.submarine {
|
|
width: 126px;
|
|
height: 40px;
|
|
}
|
|
|
|
.cruiser.vertical,
|
|
.submarine.vertical {
|
|
width: 40px;
|
|
height: 126px;
|
|
}
|
|
|
|
.destroyer {
|
|
width: 84px;
|
|
height: 40px;
|
|
}
|
|
|
|
.destroyer.vertical {
|
|
width: 40px;
|
|
height: 84px;
|
|
}
|
|
|
|
.ship span {
|
|
width: 40px;
|
|
height: 40px;
|
|
background-color: darkcyan;
|
|
}
|
|
|
|
.ship .head {
|
|
border-radius: 20px 0 0 20px;
|
|
}
|
|
|
|
.ship .tail {
|
|
border-radius: 0 10px 10px 0;
|
|
}
|
|
|
|
.ship.vertical .head {
|
|
border-radius: 20px 20px 0 0;
|
|
}
|
|
|
|
.ship.vertical .tail {
|
|
border-radius: 0 0 10px 10px;
|
|
}
|