-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
142 lines (131 loc) · 2.91 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
139
140
141
142
html.light {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
--content: black;
--background: white;
--accent: rgb(54, 54, 127);
--next-content: rgb(225, 225, 255);
--next-background: rgb(10, 10, 10);
--next-accent: rgb(127, 127, 200);
}
html.dark {
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
--content: rgb(225, 225, 255);
--background: rgb(10, 10, 10);
--accent: rgb(127, 127, 200);
--next-content: black;
--next-background: white;
--next-accent: rgb(54, 54, 127);
}
html {
background-color: var(--background);
color: var(--content);
}
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
margin: 0;
}
nav {
display: flex;
flex-direction: row;
justify-content: space-between;
padding: 0em 1em;
padding-top: .5em;
background: var(--accent);
position: sticky;
top: 0;
z-index: 1;
}
nav a {
color: var(--background);
text-decoration: none;
padding: .25em 1em;
padding-bottom: .5em;
transition-property: background-color, color, box-shadow;
transition-duration: .5s;
transition-timing-function: ease-in-out;
border-radius: .5em .5em 0 0;
}
html {
scroll-behavior: smooth;
font-size: 1.25rem;
height: 100%;
}
body {
min-height: 100%;
overflow: auto;
}
@media (max-width: 900px) {
nav {
flex-direction: column;
justify-content: flex-start;
max-height: calc(2em + 20px);
transition-property: max-height;
transition-duration: .5s;
transition-timing-function: ease-in-out;
overflow: hidden;
margin-top: 0;
padding-top: 0;
}
nav a {
padding: .5em 1em;
text-align: center;
margin: 10px;
border-radius: 1em;
}
html {
font-size: 1.5rem;
}
}
/* if reduced motion: */
@media (prefers-reduced-motion: reduce) and (max-width: 900px) {
nav {
transition-duration: 0s;
}
}
nav a.current {
color: var(--content);
background-color: var(--background);
box-shadow: 0 0 .2em .1em var(--background);
}
nav a:hover {
background-color: var(--background);
color: var(--content);
}
nav a:active {
box-shadow: 0 0 .2em .1em var(--background);
}
.content {
padding: 1em;
}
h1 {
margin: .5em 0;
}
a {
color: var(--accent);
}
.bookmark-link {
padding-left: .25em;
text-decoration: none;
}
.bookmark-link:hover {
text-decoration: underline;
}
.content {
position: relative;
}
.change-theme {
padding-left: .25em;
text-decoration: none;
background-color: var(--next-background);
color: var(--next-content);
border: var(--next-accent);
padding: .5em;
box-shadow: 0 0 .25em .25em var(--next-accent);
font: inherit;
font-size: .8em;
font-weight: 700;
position: sticky;
z-index: 2;
top: 4em;
left: 80%;
}