-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnav-bar.css
106 lines (102 loc) · 1.84 KB
/
nav-bar.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
:target {
scroll-margin-top: calc(50px + 1rem);
}
.nav-bar {
position: fixed;
z-index: 10000;
left: 0;
top: 0;
right: 0;
height: 50px;
background-color: #034C6B;
}
.nav-bar .img-link {
margin-left: 0.5rem;
}
.nav-bar img {
height: 90%;
box-shadow: none;
position: relative;
top: 50%;
transform: translateY(-50%);
padding-top: 3px;
}
.nav-bar .nav-items li a {
color: white;
display: block;
padding: 10px 20px;
text-decoration: none;
}
.nav-bar ul {
margin: 0;
padding: 0;
list-style: none;
overflow: hidden;
background-color: #034C6B;
}
.nav-bar .nav-items {
clear: both;
max-height: 0;
transition: max-height .2s ease-out;
}
.nav-bar .menu-icon {
cursor: pointer;
float: right;
padding: 12px 20px;
position: relative;
user-select: none;
font-size: 1.5rem;
color: #fff
}
.nav-bar #menu-btn {
display: none;
}
.nav-bar #menu-btn:checked ~ .nav-items {
max-height: 240px;
}
/* 48em = 768px */
@media (min-width: 48em) {
.nav-bar li {
float: left;
}
.nav-bar .nav-items {
clear: none;
float: right;
max-height: none;
}
.nav-bar .menu-icon {
display: none;
}
}
body {
height: 100%;
}
.tocSwitch {
position: fixed;
top: 55px;
right: 5px;
text-decoration: none;
font-size: 1.5rem;
z-index: 1001;
}
@media screen and (min-width: 768px) {
.tocSwitch {
display: none;
}
#toc {
display: block !important;
padding-top: 50px !important;
}
}
@media screen and (max-width: 768px) {
body #header #toc {
position: fixed;
background-color: rgba(255, 255, 255);
z-index: 1000;
top: 50px;
width: 100%;
margin-top: 0 !important;
overflow-y: auto;
bottom: 0;
}
}