/
washwithstyle.css
175 lines (171 loc) · 3.1 KB
/
washwithstyle.css
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
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
:root {
--colourLight: #d8d9e2;
--colourShade: #8192b5;
--colourYellow: #eab624;
--colourPurple: #982b90;
--colourBlue: #10499f;
}
* {
font-family: sans-serif;
font-size: 4.5vmin;
user-select: none;
}
@media screen and (min-width: 640px) {
* {
font-size: 2.65vmin;
}
/*
Alternate narrow keyboard layout
#keyboard {
width: auto;
border-radius: 2.2em 2.2em 0 0;
padding: 0.8em;
}
*/
}
body {
background-color: var(--colourBlue);
}
button {
background-color: var(--colourLight);
font-weight: bold;
border: none;
border-radius: 0.3em;
transition: box-shadow 0.2s;
}
button:active:hover {
background-color: var(--colourShade);
box-shadow: 0.02em 0.02em 0.15em var(--colourShade);
}
@media not all and (hover: none) {
button:hover {
box-shadow: 0.07em 0.07em 0.3em var(--colourShade);
}
}
/* @media (pointer: coarse) */
button:focus {
outline: none;
}
.container {
display: flex;
flex-direction: row;
justify-content: center;
}
.spine {
display: flex;
flex-direction: column;
align-items: center;
width: 100vw;
height: 100vh;
}
.spine > * {
display: block;
margin: 0;
padding: 0.5rem 0;
width: 100%;
text-align: center;
}
.row {
margin-bottom: 0.3em;
}
#title {
font-size: 0.8em;
color: var(--colourLight);
}
#title img {
height: 1em;
margin: 0 -0.1em -0.25em;
}
#notification-request {
background-color: var(--colourYellow);
}
@import url('https://fonts.googleapis.com/css?family=Source+Code+Pro');
#display {
padding-bottom: 0.5em;
}
#display,
#display span {
font-size: 1.8em;
background-color: var(--colourLight);
font-family: 'Source Code Pro', monospace;
}
#display-context::before {
content: '█';
animation: blink 1.5s steps(2, start) infinite;
margin-left: -1.55ch;
color: var(--colourLight);
mix-blend-mode: difference;
}
@keyframes blink {
to {
visibility: hidden;
}
}
#keyboard {
margin-top: auto;
background-color: var(--colourLight);
}
#keyboard button {
font-size: 1.8em;
margin: 0.1em;
padding: 0.4em;
width: 2em;
border-radius: 50%;
}
#enter {
color: var(--colourLight);
background-color: var(--colourPurple);
}
#levels {
min-height: 2em;
overflow-y: scroll;
overflow-x: hidden;
-ms-overflow-style: none;
scrollbar-width: none;
font-size: 1.2em;
padding: 0;
color: var(--colourLight);
transition: height var(--shortAnimDuration);
}
::-webkit-scrollbar {
display: none;
}
#levels p {
margin: 0.4em 0;
animation: appear var(--shortAnimDuration);
transition: font-size var(--shortAnimDuration),
font-weight var(--shortAnimDuration), position var(--shortAnimDuration);
overflow: hidden;
white-space: nowrap;
}
#levels p:first-child {
font-size: 1.6em;
font-weight: bold;
}
#levels span {
font-size: 1em;
}
@keyframes appear {
from {
transform: scale(0);
}
to {
transform: scale(1);
}
}
#levels p.smooth {
transition: margin var(--shortAnimDuration);
}
#levels p.imminent {
animation: imminent 2s linear none infinite alternate;
}
@keyframes imminent {
0%,
30% {
color: inherit;
}
50%,
100% {
color: var(--colourYellow);
}
}