-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle.css
More file actions
390 lines (370 loc) · 9.09 KB
/
style.css
File metadata and controls
390 lines (370 loc) · 9.09 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
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
/* Font import */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&display=swap');
:root{
/* Color & Gradient Variables */
--clr-white: #FFF;
--clr-black: #000;
--clr-grey-950: #08070B;
--clr-grey-900: #14131B;
--clr-grey-850: #18171F;
--clr-grey-800: #24232C;
--clr-grey-700: #54535B;
--clr-grey-600: #817D92;
--clr-grey-200: #E6E5EA;
--clr-green-200: #A4FFAF;
--clr-yellow-300: #F8CD65;
--clr-orange-400: #FB7C58;
--clr-red-500: #F64A4A;
--gradient-1: linear-gradient(#14131B, #08070B);
/* Spacing Variables */
--spacing-100: .5rem;
--spacing-200: 1rem;
--spacing-300: 1.5rem;
--spacing-400: 2rem;
--spacing-700: 3.5rem;
--spacing-1000: 5rem;
--spacing-1300: 6.5rem;
--spacing-1600: 8rem;
--spacing-2000: 10rem;
--spacing-2200:11rem;
--spacing-2300: 11.5rem;
}
/* CSS Reset */
*, *::before, *::after{
box-sizing: border-box;
margin: 0;
padding:0;
}
/* General Styles, MOBILE FIRST */
body{
background: var(--gradient-1);
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
min-height: 100dvh;
font-family: 'JetBrains Mono', monospace;
color: var(--clr-grey-200);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
main{
display: flex;
flex-direction: column;
gap: var(--spacing-200);
width: 100%;
max-width: 21.4375rem;
margin: var(--spacing-200);
}
/* Password container */
main h1{
color: var(--clr-grey-600);
font-size: 1rem;
line-height: 1.25rem;
text-align: center;
}
.password-container{
display: flex;
justify-content: space-between;
align-items: center;
background-color: var(--clr-grey-800);
padding: var(--spacing-200);
}
#password{
background-color: transparent;
color: var(--clr-grey-200);
font-family: 'JetBrains Mono', monospace;
width: 100%;
border: 0;
font-size: 1.5rem;
font-weight: 700;
line-height: 2rem;
}
#password.disabled{
-webkit-text-fill-color: var(--clr-grey-700);
}
.copy-container{
display: flex;
align-items: center;
gap: var(--spacing-200);
}
#copied-text{
font-size: 1rem;
font-weight: 700;
line-height: 1.25rem;
text-transform: uppercase;
color: var(--clr-green-200);
}
#icon-copy{
scale: .8;
color: var(--clr-green-200);
transition: color .5s ease-in-out;
}
#icon-copy:hover{
color: var(--clr-white);
cursor: pointer;
}
.hidden{
display: none;
}
/* Password settings Form*/
#pass-form{
background-color: var(--clr-grey-800);
padding: var(--spacing-200);
display: flex;
flex-direction: column;
gap: var(--spacing-400);
}
.character-length .label{
display: flex;
justify-content: space-between;
align-items: center;
}
.character-length{
font-weight: 700;
line-height: 1.25rem;
display: flex;
flex-direction: column;
gap: var(--spacing-200);
}
#length-number{
color: var(--clr-green-200);
font-size: 1.5rem;
line-height: 2rem;
position: relative;
right: .9375rem;
}
#character-length-range{
width: 100%;
appearance: none;
height: .5rem;
background: var(--clr-grey-850);
}
/* Range Input: Slider Thumb Styles for Webkit */
#character-length-range::-webkit-slider-thumb{
-webkit-appearance: none;
box-sizing: content-box;
width: 1.6em;
height: 1.6em;
background: var(--clr-grey-200);
border-radius: 50%;
border: .2em transparent solid;
cursor: pointer;
transition: all .3s ease-in-out;
}
#character-length-range::-webkit-slider-thumb:hover,
#character-length-range::-webkit-slider-thumb:active{
background: var(--clr-grey-850);
border: .2em var(--clr-green-200) solid;
}
/* Range Input: Slider Thumb Styles for Mozilla */
#character-length-range::-moz-range-thumb{
appearance: none;
box-sizing: content-box;
width: 1.6em;
height: 1.6em;
background: var(--clr-grey-200);
border-radius: 50%;
border: .2em transparent solid;
cursor: pointer;
transition: all .3s ease-in-out;
}
#character-length-range::-moz-range-thumb:hover,
#character-length-range::-moz-range-thumb:active{
background: var(--clr-grey-850);
border: .2em var(--clr-green-200) solid;
}
/* Checkbox Styles */
#checkboxes-group{
display: flex;
flex-direction: column;
gap: var(--spacing-200);
font-weight: 700;
line-height: 1.25rem;
}
#checkboxes-group div{
display: flex;
gap: var(--spacing-200);
align-items: center;
}
input[type="checkbox"] {
-webkit-appearance: none;
appearance: none;
background-color: var(--clr-grey-800);
margin: 0;
font: inherit;
border: .125em var(--clr-grey-200) solid;
width: 1.25em;
height: 1.25em;
display: inline-block;
position: relative;
cursor: pointer;
transition: all .2s ease-in-out;
}
input[type="checkbox"]:hover {
border: .125em var(--clr-green-200) solid;
}
input[type="checkbox"]:checked{
background-color: var(--clr-green-200);
border: .125em var(--clr-green-200) solid;
}
input[type="checkbox"]:checked::before {
content: '';
background: url('/assets/images/icon-check.svg') no-repeat center/cover;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 0.7em;
height: 0.7em;
}
/* Strength Indicator Container and states */
.strength-container{
background-color: var(--clr-grey-850);
padding: .875rem var(--spacing-200);
display: flex;
justify-content: space-between;
align-items: center;
}
.strength-container p{
font-weight: 700;
line-height: 1.25rem;
text-transform: uppercase;
color: var(--clr-grey-600);
}
.strength-indicator{
display: flex;
align-items: center;
gap: var(--spacing-200);
}
#strength-word{
font-size: 1.125rem;
line-height: 1.5rem;
color: var(--clr-grey-200);
}
#strength-visual{
display: flex;
gap: var(--spacing-100);
}
#strength-visual div{
width: .625em;
height: 1.75em;
border: .125em var(--clr-grey-200) solid;
}
/* Too-Weak Strength Indicator */
#strength-visual.too-weak > #rect-1{
background-color: var(--clr-red-500);
border-color: var(--clr-red-500);
}
/* Weak Strength Indicator */
#strength-visual.weak > #rect-1,
#strength-visual.weak > #rect-2{
background-color: var(--clr-orange-400);
border-color: var(--clr-orange-400);
}
/* Medium Strength Indicator */
#strength-visual.medium > #rect-1,
#strength-visual.medium > #rect-2,
#strength-visual.medium > #rect-3{
background-color: var(--clr-yellow-300);
border-color: var(--clr-yellow-300);
}
/* Strong Strength Indicator */
#strength-visual.strong > #rect-1,
#strength-visual.strong > #rect-2,
#strength-visual.strong > #rect-3,
#strength-visual.strong > #rect-4{
background-color: var(--clr-green-200);
border-color: var(--clr-green-200);
}
/* Generate Button Styles */
#pass-form button{
padding: var(--spacing-200) var(--spacing-1300);
margin-top: -1rem;
border-radius: 0;
border: .125em solid transparent; /* Borde transparente inicial */
background-color: var(--clr-green-200);
font-family: 'JetBrains Mono', monospace;
font-size: 1rem;
font-weight: 700;
line-height: 1.25rem;
text-transform: uppercase;
transition: all .3s ease-in-out;
box-sizing: border-box;
}
#pass-form button:hover{
background-color: transparent;
color: var(--clr-green-200);
border: .125em var(--clr-green-200) solid;
cursor: pointer;
}
#pass-form button:hover svg{
fill: var(--clr-green-200);
}
/* Tablet and desktop Breakpoint */
@media (min-width: 40.625rem){
main{
width: 100%;
max-width: 33.75rem;
}
/* Password Container */
main h1{
font-size: 1.5rem;
line-height: 2rem;
margin-bottom: .5rem;
}
.password-container{
padding: var(--spacing-200) var(--spacing-400);
}
#password{
font-size: 2rem;
line-height: 2.625rem;
}
#copied-text{
font-size: 1.125rem;
line-height: 1.5rem;
}
#icon-copy{
scale: 1;
}
/* Password Settings Form */
#pass-form{
padding: var(--spacing-300) var(--spacing-400);
}
.character-length{
font-size: 1.125rem;
line-height: 1.5rem;
}
#length-number{
font-size: 2rem;
line-height: 2.625rem;
}
/* Checkbox Styles */
#checkboxes-group{
font-size: 1.125rem;
line-height: 1.5rem;
}
#checkboxes-group div{
gap: var(--spacing-300);
}
/* Strength Indicator Container and states */
.strength-container{
padding: var(--spacing-200) var(--spacing-400);
}
.strength-container p{
font-size: 1.125rem;
line-height: 1.5rem;
}
#strength-word{
font-size: 1.5rem;
line-height: 2rem;
}
/* Generate Button Styles */
#pass-form button{
padding: var(--spacing-300) var(--spacing-2200);
font-size: 1.125rem;
line-height: 1.5rem;
margin-top: 0;
margin-bottom: .7rem;
}
}