-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdark_mode.css
126 lines (108 loc) · 2.1 KB
/
dark_mode.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
@import url(https://fonts.googleapis.com/css?family=Lato:400,400italic,700|Sansita+One);
:root {
--primary-color: #302AE6;
--secondary-color: #536390;
--font-color: #424242;
--bg-color: #fff;
--heading-color: #292922;
}
[data-theme="dark"] {
--primary-color: #9A97F3;
--secondary-color: #818cab;
--font-color: #e1e1ff;
--bg-color: #161625;
--heading-color: #818cab;
}
body {
font-family: "Lato", sans-serif;
background-color: var(--bg-color);
color: var(--font-color);
max-width: 90%;
margin: 0 auto;
font-size: calc(1rem + 0.25vh);
}
h1 {
color: var(--heading-color);
font-family: "Sansita One", serif;
font-size: 2rem;
margin-bottom: 1vh;
}
p {
font-size: 1.1rem;
line-height: 1.6rem;
}
a {
color: var(--primary-color);
text-decoration: none;
border-bottom: 3px solid transparent;
font-weight: bold;
&:hover, &:focus {
border-bottom: 3px solid currentColor;
}
}
section {
max-width: 68%;
margin: 0 auto;
}
.post-meta {
font-size: 1rem;
font-style: italic;
display: block;
margin-bottom: 4vh;
color: var(--secondary-color);
}
nav {
display: flex;
justify-content: flex-end;
padding: 20px 0;
}
/*slider switch css */
.theme-switch-wrapper {
display: flex;
align-items: center;
em {
margin-left: 10px;
font-size: 1rem;
}
}
.theme-switch {
display: inline-block;
height: 34px;
position: relative;
width: 60px;
}
.theme-switch input {
display:none;
}
.slider {
background-color: #ccc;
bottom: 0;
cursor: pointer;
left: 0;
position: absolute;
right: 0;
top: 0;
transition: .4s;
}
.slider:before {
background-color: #fff;
bottom: 4px;
content: "";
height: 26px;
left: 4px;
position: absolute;
transition: .4s;
width: 26px;
}
input:checked + .slider {
background-color: #66bb6a;
}
input:checked + .slider:before {
transform: translateX(26px);
}
.slider.round {
border-radius: 34px;
}
.slider.round:before {
border-radius: 50%;
}