-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
109 lines (97 loc) · 1.87 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Tic-Tac-Toe</title>
<style>
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}
body {
margin: 0;
height: 100vh;
width: 100%;
background-color: #1e1e1e;
display: flex;
align-items: center;
justify-content: center;
gap: 10px;
flex-direction: row;
}
.info {
width: 12rem;
height: 500px;
display: flex;
flex-direction: column;
justify-content: space-between;
text-align: center;
gap: 12px;
}
h3 {
font-size: 1.5rem;
color: #e0e0e0;
margin-top: 80%;
}
button {
padding: 10px;
font-size: 1.2rem;
cursor: pointer;
background-color: #007bff;
border: none;
border-radius: 5px;
color: #fff;
transition: background-color 0.3s ease;
}
button:hover {
background-color: #0056b3;
}
canvas {
background-color: #1a1919e5;
border: 2px solid #4d4d4dce;
border-radius: 5px;
}
/* Media Queries */
@media (max-width: 600px) {
body {
width: 100%;
display: block;
padding: 10px;
flex-direction: column;
}
canvas {
display: block;
margin: 0 auto;
width: 95%;
height: auto;
max-width: 100%;
}
button {
width: 8rem;
}
h3 {
font-size: 18px;
margin-top: 0;
}
.info {
height: auto;
flex-direction: row;
padding: 10px;
width: 100%;
align-items: center;
justify-content: space-between;
}
}
</style>
</head>
<body>
<canvas id="gameCanvas" width="500" height="500"></canvas>
<div class="info">
<h3 id="Result"></h3>
<button class="restartBtn">Restart</button>
</div>
<script src="./src/main.js" type="module" defer></script>
</body>
</html>