-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
138 lines (119 loc) · 2.64 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
* {
margin: 0;
padding: 0;
user-select: none;
box-sizing: border-box;
}
body {
background: black;
}
:root {
--blade-lightness: 50%;
--blade-color: 353;
}
.content {
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
width: 100%;
height: 100vh;
overflow: hidden;
text-align: center ;
}
.content h2 {
visibility: hidden;
position: absolute;
color: white;
}
.maulsaber {
margin-top: 50vh;
grid-column: 1 / -1;
position: relative;
transform: rotate(90deg);
}
/* #lightsaber2 {
transform: rotate(180deg);
} */
#on-off, #on-off2 {
position: absolute;
width: 0;
height: 0;
}
.lightsaber2 {
transform: rotate(180deg);
}
/* Рукоятка */
.handle {
cursor: pointer;
display: block;
width: 14px;
height: 125px;
border-radius: 0 0 4px 4px;
border: white 0.5px solid;
background-image: linear-gradient(
black 0 10px,
silver 0 14px,
silver 0 15px,
black 0 20px,
silver 0 22px,
black 0 25px,
silver 0 27px,
black 0 30px,
silver 0 32px,
black 0 35px,
silver 0 37px,
black 0 40px,
silver 0 42px,
black 0 45px,
silver 0 47px,
black 0 50px,
silver 0 60px,
black 60px 100px,
black 50px 100%
);
}
/* Лезвие */
.blade, .blade2 {
position: absolute;
background: white;
height: 350%;
width: 100%;
bottom: 100%;
border-radius: 1vw 100vw 0 0;
box-shadow: inset 0 0 4px
hsl(var(--blade-color) 100% var(--blade-lightness) / 1),
0 0 1em hsl(var(--blade-color) 100% var(--blade-lightness) / 0.8),
0 0 1.5em hsl(var(--blade-color) 100% var(--blade-lightness) / 0.7),
0 0 2em hsl(var(--blade-color) 100% var(--blade-lightness) / 0.5),
0 0 3em hsl(var(--blade-color) 100% var(--blade-lightness) / 0.3),
0 0 5em hsl(var(--blade-color) 100% var(--blade-lightness) / 0.2);
transition: transform 100ms ease-out;
transform-origin: bottom;
transition: 0.5s;
}
.blade::before, .blade2::before {
content: "";
position: absolute;
top: 0;
bottom: 0;
right: 0;
left: 0;
background: white;
border-radius: inherit;
z-index: 10;
}
/* Включение/Выключение меча */
#on-off:not(:checked) + .blade, #on-off2:not(:checked) + .blade2 {
transform: scaleY(0);
transition: 1s;
}
#on-off:checked + .blade, #on-off2:checked + .blade2 {
transform: scaleY(1);
}
@media screen and (min-width: 300px) and (max-width: 800px) {
.maulsaber {
margin-top: 0;
transform: rotate(0deg);
}
}