-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
79 lines (70 loc) · 1.41 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
* {
margin: 0px;
padding: 0px;
box-sizing: border-box;
font-size: 30px;
font-family: 'Times New Roman';
}
body {
height: 100vh;
width: 100vw;
display: flex;
align-items: start;
justify-content: center;
}
.clock {
border: 25px dashed white;
border-radius: 50%;
height: 500px;
width: 500px;
margin-top: 10vh;
background-color: yellow;
background-position: center;
background-size: cover;
position: relative;
display: flex;
align-items: center;
justify-content: center;
}
.number {
transform: rotate(calc(30deg * var(--n)));
position: absolute;
text-align: center;
inset: 20px;
}
.number b {
transform: rotate(calc(-30deg * var(--n)));
display: inline-block;
}
.centre {
border-radius: 50%;
height: 25px;
width: 25px;
background-color: black;
position: absolute;
z-index: 1;
}
.second, .minute, .hour {
--rotate: 0;
position: absolute;
left: 50%;
bottom: 50%;
transform: translate(-50%) rotate(calc(var(--rotate) * 1deg));
transform-origin: bottom;
border-radius: 50%;
}
.second {
height: 225px;
width: 5px;
background-color: red;
}
.minute {
height: 200px;
width: 10px;
background-color: blue;
}
.hour {
height: 125px;
width: 15px;
background-color: green;
}