Repository navigation
Expand file tree
/
Copy pathstyle.css
More file actions
154 lines (140 loc) · 2.95 KB
/
Copy pathstyle.css
File metadata and controls
154 lines (140 loc) · 2.95 KB
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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
/* style.css — arcade console language */
:root {
--bg: #0a0a12;
--panel: #12121e;
--line: #232338;
--text: #e8e8f0;
--dim: #8888a0;
--accent: #ffd34d;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
height: 100%;
background: var(--bg);
color: var(--text);
font-family: 'Courier New', Courier, 'Lucida Console', monospace;
overscroll-behavior: none;
}
/* ---------- layout ---------- */
body {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100dvh;
gap: 12px;
padding: 16px;
}
/* ---------- canvas ---------- */
#game {
display: block;
border: 1px solid var(--line);
border-radius: 8px;
background: #06060f;
image-rendering: pixelated;
/* prevent browser pan/zoom interfering with canvas touches */
touch-action: none;
}
/* ---------- touch bar ---------- */
#touch {
display: none; /* hidden on desktop */
width: 100%;
max-width: 800px;
position: fixed;
bottom: 0;
left: 50%;
transform: translateX(-50%);
background: var(--panel);
border-top: 1px solid var(--line);
padding: 8px 12px;
padding-bottom: max(8px, env(safe-area-inset-bottom));
/* two clusters: movement left, actions right */
flex-direction: row;
justify-content: space-between;
align-items: center;
gap: 8px;
}
/* left cluster: ◀ ▶ */
#touch-left {
display: flex;
gap: 6px;
}
/* right cluster: JMP ATK DGE */
#touch-right {
display: flex;
gap: 6px;
align-items: center;
}
/* base button */
#touch button {
position: relative;
top: 0;
min-height: 56px;
min-width: 56px;
background: var(--panel);
border: 1px solid var(--line);
border-radius: 6px;
color: var(--text);
font-family: inherit;
font-size: 13px;
font-weight: bold;
letter-spacing: 0.05em;
cursor: pointer;
user-select: none;
-webkit-tap-highlight-color: transparent;
touch-action: none;
box-shadow: 0 3px 0 #06060c;
transition: color 0.08s, background 0.08s;
}
#touch button:active,
#touch button.pressed {
top: 3px;
box-shadow: none;
color: var(--accent);
}
/* ATK — primary: gold-filled, largest */
#btn-atk {
min-height: 64px;
min-width: 68px;
background: var(--accent);
color: #0a0a12;
border-color: var(--accent);
font-size: 15px;
box-shadow: 0 4px 0 #b89400;
}
#btn-atk:active,
#btn-atk.pressed {
top: 4px;
box-shadow: none;
background: #ffe580;
color: #0a0a12;
}
/* DGE — gold outline */
#btn-dodge {
background: transparent;
border: 2px solid var(--accent);
color: var(--accent);
}
#btn-dodge:active,
#btn-dodge.pressed {
background: rgba(255,211,77,0.15);
color: var(--accent);
}
/* ---------- mobile ---------- */
@media (max-width: 768px) {
body {
justify-content: flex-start;
padding: 8px 0 0;
}
#game {
width: 100%;
height: auto;
aspect-ratio: 800 / 450;
border-radius: 0;
border-left: none;
border-right: none;
}
#touch {
display: flex;
}
}