* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
/* room_container */
.room-container {
position: relative;
min-height: 100vh;
background-color: #2a8d96;
}
#room-header {
position: absolute;
top: 8%;
left: 50%;
width: 40%;
transform: translateX(-50%);
text-align: center;
background-color: white;
border-radius: 15px;
}
#room-header tr:nth-child(1) th {
font-size: 18px;
font-weight: bold;
padding: 10px 0;
}
#room-header tr:nth-child(2) td {
font-size: 18px;
padding: 15px 0;
}
#player-list {
position: absolute;
display: flex;
justify-content: center;
width: 70%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
.list-item {
width: 21%;
text-align: center;
background-color: #fff;
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
padding: 20px;
border-radius: 8px;
margin: 0 15px;
}
.list-item img {
width: 70%;
height: 70%;
border-radius: 50%;
object-fit: cover;
margin-bottom: 10px;
}
.player-name {
font-size: 24px;
color: #333;
margin-bottom: 10px;
}
.readiness-status {
font-size: 16px;
color: #777;
margin-bottom: 10px;
}
.status-label {
font-weight: bold;
}
.status-value {
margin-left: 5px;
color: #4CAF50;
}
/* buttons */
.buttons {
position: absolute;
left: 50%;
bottom: 10%;
transform: translateX(-50%);
}
#start-button, #leave-button, #ready-button {
background-color: #007bff;
border: none;
color: white;
padding: 15px 32px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 16px;
margin: 4px 2px;
cursor: pointer;
transition-duration: 0.4s;
border-radius: 12px;
box-shadow: 0 4px #999;
}
#start-button:hover, #leave-button:hover, #ready-button:hover {
background-color: #4CAF50;
color: white;
}
#start-button:active, #leave-button:active, #ready-button:active {
background-color: #3e8e41;
box-shadow: 0 2px #666;
transform: translateY(4px);
}
.game-container {
overflow: hidden;
position: relative;
width: 100%;
min-height: 100vh;
background-image: url("/static/images/flat_background0.png");
}
.south {
position: absolute;
width: 55%;
left: 50%;
bottom: 0;
transform: translateX(-50%);
}
.south ul {
list-style: none;
}
.south .info {
position: relative;
display: flex;
text-align: center;
justify-content: center;
margin-bottom: 1%;
}
.south .info span {
width: 20%;
font-weight: bold;
}
.south .info .active {
position: absolute;
top: -100%;
color: red;
}
.south .hand {
display: flex;
width: 50%;
margin: 0 auto;
justify-content: center;
}
.south .hand li {
width: 35%;
margin: 0 10px;
}
.south .hand li img,
.south .discard li img {
width: 100%;
}
.south .discard li {
position: absolute;
width: 12%;
}
.south .discard li:nth-child(1) {
top: 0;
right: 15%;
}
.south .discard li:nth-child(2) {
top: 8%;
right: 12%;
}
.south .discard li:nth-child(3) {
top: 16%;
right: 9%;
}
.south .discard li:nth-child(4) {
top: 24%;
right: 6%;
}
.south .discard li:nth-child(5) {
top: 32%;
right: 3%;
}
.south .discard li:nth-child(6) {
top: 40%;
right: 0%;
}
.south .hand li:hover {
transform: translateY(-10px);
z-index: 100;
}
.south .discard li:hover {
transform: scale(1.5);
z-index: 100;
}
/* player 2 */
.north {
position: absolute;
width: 55%;
top: 0;
left: 50%;
transform: translateX(-50%);
}
.north ul {
list-style: none;
}
.north .info {
position: absolute;
display: flex;
width: 100%;
top: 105%;
text-align: center;
justify-content: center;
}
.north .info span {
width: 20%;
font-weight: bold;
}
.north .info .active {
position: absolute;
top: 105%;
color: red;
}
.north .hand {
display: flex;
width: 50%;
margin: 0 auto;
justify-content: center;
}
.north .hand li {
width: 35%;
margin: 0 10px;
transform: rotate(-180deg);
}
.north .hand li img,
.north .discard li img {
width: 100%;
}
.north .discard li {
position: absolute;
width: 12%;
}
.north .discard li:nth-child(1) {
top: 0;
left: 3%;
}
.north .discard li:nth-child(2) {
top: 8%;
left: 6%;
}
.north .discard li:nth-child(3) {
top: 16%;
left: 9%;
}
.north .discard li:nth-child(4) {
top: 24%;
left: 12%;
}
.north .discard li:nth-child(5) {
top: 32%;
left: 15%;
}
.north .discard li:nth-child(6) {
top: 40%;
left: 18%;
}
.north .hand li:hover {
transform: rotate(-180deg) translateY(-10px);
z-index: 100;
}
.north .discard li:hover {
transform: scale(1.5);
z-index: 100;
}
/* player 3 */
.west {
position: absolute;
width: 55%;
top: 33%;
left: -20.5%;
transform: rotate(90deg);
}
.west ul {
list-style: none;
}
.west .hand {
display: flex;
width: 50%;
margin: 0 auto;
justify-content: center;
}
.west .hand li {
width: 35%;
margin: 0 10px;
}
.west .hand li img,
.west .discard li img {
width: 100%;
}
.west .discard li {
position: absolute;
width: 12%;
transform: rotate(-90deg);
}
.west .discard li:nth-child(1) {
top: 33%;
left: 78%;
}
.west .discard li:nth-child(2) {
top: 14%;
left: 75%;
}
.west .discard li:nth-child(3) {
top: -5%;
left: 72%;
}
.west .hand li:hover {
transform: translateY(-10px);
z-index: 100;
}
.west .discard li:hover {
transform: rotate(-90deg) scale(1.5);
z-index: 100;
}
/* player_4 */
.east {
position: absolute;
width: 55%;
top: 36%;
left: 93%;
transform: translateX(-50%) rotate(-90deg);
}
.east ul {
list-style: none;
}
.east .hand {
display: flex;
width: 50%;
margin: 0 auto;
justify-content: center;
}
.east .hand li {
width: 35%;
margin: 0 10px;
}
.east .hand li img,
.east .discard li img {
width: 100%;
}
.east .discard li {
position: absolute;
width: 12%;
transform: rotate(90deg);
}
.east .discard li:nth-child(1) {
top: -3%;
left: 72%;
}
.east .discard li:nth-child(2) {
top: 16%;
left: 75%;
}
.east .discard li:nth-child(3) {
top: 35%;
left: 78%;
}
.east .hand li:hover {
transform: translateY(-10px);
z-index: 100;
}
.east .discard li:hover {
transform: rotate(90deg) scale(1.5);
z-index: 100;
}
.west .info, .east .info {
position: absolute;
display: flex;
width: 100%;
text-align: center;
justify-content: center;
top: -15%;
}
.west .info span, .east .info span {
width: 20%;
font-weight: bold;
}
.west .info .active, .east .info .active {
color: red;
}
/* deck */
.deck {
position: absolute;
width: 8%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
.deck img {
width: 100%;
transform: rotate(-90deg);
}
.outOfPlay {
display: flex;
justify-content: center;
position: absolute;
top: 50%;
left: 8%;
transform: translate(-50%, -50%);
width: 8%;
flex-direction: column;
align-items: center;
}
.cards {
list-style: none;
display: flex;
flex-direction: column;
align-items: center;
}
.cards li {
margin: 8px;
}
.cards li img {
width: 100%;
}
.cards li:hover {
transform: scale(1.5);
}
#displayArea {
position: absolute;
display: none;
width: 25%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
height: 18%;
background-color: #f1f1f1;
border-radius: 10px;
padding: 20px;
text-align: center;
z-index: 30;
}
#next-button {
display: inline-block;
width: 35%;
margin-top: 30px;
padding: 10px 20px;
border-radius: 5px;
outline: none;
background-color:#007bff
}