-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
168 lines (149 loc) · 2.87 KB
/
style.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
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: Verdana, Geneva, Tahoma, sans-serif;
}
body {
width: 100%;
height: 100vh;
background: linear-gradient(to right bottom, #109bba, #557c93);
color: #fff;
display: grid;
place-items: center;
}
.container {
width: 80%;
max-width: 850px;
padding: 30px;
text-align: center;
display: none;
}
.container h1 {
font-size: 36px;
margin-bottom: 40px;
text-decoration: underline;
text-underline-offset: 8px;
}
.container .question {
font-size: 26px;
margin-top: 20px;
}
.container .choices {
margin-top: 20px;
}
.choice {
font-size: 20px;
background-color: #eee;
color: #000;
margin: 10px auto;
padding: 10px;
border-radius: 5px;
text-align: left;
width: 60%;
cursor: pointer;
opacity: 0;
transform: translateY(50%);
animation: fade-in 0.5s ease forwards;
}
.choice:hover{
background-color: #ddd;
}
.choice.selected{
background-color: #007bff;
color: #fff;
}
.btn{
width: 60%;
font-size: 20px;
font-weight: 600;
padding: 12px 20px;
margin: 20px auto 0 auto;
background-color: #2a0064;
color: #fff;
border: none;
border-radius: 5px;
cursor: pointer;
}
.btn:hover{
background-color: #2a0064;
}
.scoreCard{
font-size: 24px;
margin-top: 20px;
}
.alert{
background-color: #d70d14;
border-radius: 5px;
width: 100%;
padding: 12px;
position: absolute;
top: 0;
display: none;
}
.startBtn{
width: 15%;
padding-block: 20px;
text-align: center;
border-radius: 50px 50px 50px 50px;
}
.timer{
position: absolute;
top: 20px;
right: 50%;
width: 72px;
height: 72px;
border-radius: 50%;
background-color: #f00;
border: 2px solid #f00;
font-size: 24px;
font-weight: 600;
padding: 12px;
display: flex;
justify-content: center;
align-items: center;
animation: pulse 1s ease-in-out infinite;
}
/* Adding Animation to Timer */
@keyframes pulse{
0%{
transform: scale(1);
}
50%{
transform: scale(1.2);
}
100%{
transform: scale(1);
}
}
/* Adding Animation to choices */
@keyframes fade-in{
0%{
opacity: 0;
transform: translateY(50%);
}
100%{
opacity: 1;
transform: translateY(0);
}
}
@media screen and (max-width:900px){
.container {
width: 100%;
margin-top: 50px;
}
.container h1{
font-size: 24px;
}
.container .question{
font-size: 22px;
}
.timer{
width: 50px;
height: 50px;
font-size: 20px;
}
.startBtn{
width: 50%;
}
}