-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle.css
More file actions
128 lines (103 loc) · 2.11 KB
/
style.css
File metadata and controls
128 lines (103 loc) · 2.11 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
:root {
--t-speed: 0.5s;
}
body {
background-color: white;
padding: 0;
margin: 0;
}
.toggle {
position: relative;
display: inline-block;
width: 200px;
height: 100px;
}
input {
opacity: 0;
width: 0;
height: 0;
padding: 0;
margin: 0;
}
svg * {
transition: var(--t-speed);
}
svg {
width: 100px;
}
svg > .sun > .spoke {
fill: rgb(255, 230, 0);
}
svg > .sun > .core {
fill: rgb(255, 230, 0);
}
svg > .sun > .crescent {
fill: #faff00;
}
svg .background {
fill: url(#sky-gradient);
}
svg > .night-sky > * {
opacity: 0;
}
svg > .night-sky > .constellations > * {
fill-opacity: 0;
}
input:checked + svg > .sun {
transform: translate(100px);
transition: var(--t-speed);
}
input:checked + svg > .sun > circle {
fill: white;
transition: var(--t-speed);
}
input:checked + svg > .sun > .crescent {
fill: #5200ff;
}
input:checked + svg > .sun > .spoke {
opacity: 0;
transition: calc(var(--t-speed) / 2);
}
input:checked + svg > .background {
fill: url(#sky-gradient);
}
input:checked + svg > .clouds > .cloud {
/* fill: #282828; */
fill: #474747;
transition: var(--t-speed);
transform: translate(-100px, 20px);
}
input:checked + svg > .clouds > .cloud-three {
opacity: 0;
}
input:checked + svg > .night-sky > * {
opacity: 1;
}
input:checked + svg > .night-sky > .constellations > .orion {
opacity: 1;
stroke-dasharray: 158.3125;
stroke-dashoffset: 158.3125;
animation: orion calc(var(--t-speed) * 3) linear forwards;
}
input:checked + svg > .night-sky > .constellations > .dipper {
opacity: 1;
stroke-dasharray: 106.28192138671875;
stroke-dashoffset: 106.28192138671875;
animation: dipper calc(var(--t-speed) * 4) linear forwards;
}
@keyframes orion {
to {
stroke-dashoffset: 0;
}
}
@keyframes dipper {
to {
stroke-dashoffset: 0;
}
}
input:checked ~ svg > defs > linearGradient > .sky-gradient-begin {
stop-color: #282828;
}
input:checked ~ svg > defs > linearGradient > .sky-gradient-end {
stop-color: #000000;
}