source: public/css/custom.css@ 0985524

Last change on this file since 0985524 was 0985524, checked in by Mikhail Kirillov <w96k@…>, on Jan 15, 2020 at 4:34:25 PM

Fix table of contents for mobile view

  • Property mode set to 100644
File size: 2.7 KB
Line 
1body {
2 padding: 1em;
3}
4
5article {
6 max-width: calc(80ch + 4em);
7 border-radius: 0.em;
8 margin: 0 var(--universal-padding);
9 padding: 1em;
10 background: #fefefe;
11 box-shadow: 0 1px 3px rgba(0,0,0,.1);
12 position: relative;
13}
14
15article h1:first-child,
16article h2:first-child,
17article h3:first-child,
18article h4:first-child,
19article h5:first-child,
20article h6:first-child {
21 margin-top: 0;
22 padding: 0;
23}
24
25.navbar {
26 background: #fefefe;
27 border: 0;
28}
29
30.navbar .button {
31 background: #fefefe;
32 text-transform: none;
33}
34
35/* 16:9 */
36.video {
37 padding-top: 56.25%;
38 position: relative;
39 width: calc(100% - 1em);
40}
41
42iframe {
43 width: 100%;
44 min-height: 445px;
45 top: 0;
46 left: 0;
47 bottom: 0;
48 right: 0;
49}
50
51.cover {
52 margin: 0.5em 0;
53 border: 1px solid rgba(0,0,0,.3);
54 border-radius: 0.1em;
55}
56
57#youmu {
58 position: relative;
59 top: 1em;
60 margin-bottom: -0.5em;
61 max-width: 400px;
62 filter: drop-shadow(0 12px 4px rgba(0,0,0,.25));
63}
64
65#preamble {
66 max-width: calc(80ch + 6em);
67 margin: var(--universal-margin);
68 box-shadow: 0 1px 3px rgba(0,0,0,.1);
69}
70
71#postamble {
72 margin: var(--universal-margin);
73 max-width: calc(80ch + 6em);
74}
75
76#meta {
77 text-align: right;
78}
79
80#copyright {
81 text-align: center;
82}
83
84@media screen and (max-width: 768px) {
85 #postamble, #meta {
86 text-align: center;
87 }
88}
89
90hr {
91 background: rgba(0,0,0,.05) !important;
92 height: 0.5rem !important;
93 margin: 1px !important;
94}
95
96@media screen and (max-width: 120ch) {
97 #table-of-contents {
98 display: none !important;
99 }
100}
101
102#table-of-contents {
103 display: block;
104 z-index: 1050;
105 font-size: 12pt;
106 position: fixed;
107 right: calc(var(--universal-margin));
108 top: calc(var(--universal-margin) + 0.5em);
109 background: #fefefe;
110 line-height: 12pt;
111 box-shadow: 0 1px 3px rgba(0,0,0,.1);
112 border: none;
113 max-height: calc(100% - 2 * (var(--universal-margin) + 0.5em) - 9.6em);
114 overflow: auto;
115}
116
117#table-of-contents * {
118 padding: none;
119}
120
121#table-of-contents h2 {
122 font-size: 13pt;
123 border: 0;
124 font-weight: 400;
125 padding: .05em .5em;
126}
127
128#text-table-of-contents ul {
129 margin: 0 0 0 1em;
130}
131
132#text-table-of-contents > ul {
133 margin: 0 1em 0 2em;
134}
135
136#text-table-of-contents ul li {
137 font-size: 11pt;
138 width: 100%;
139}
140
141#table-of-contents #text-table-of-contents {
142 display: block;
143 text-align: left;
144 max-width: 40ch;
145}
146
147#table-of-contents li {
148 clear:both
149}
150
151.licenses {
152 margin-top: 0.75em !important;
153}
154
155.licenses a:not(:first-child) {
156 margin-left: 0.5em;
157}
158
159.inline li {
160 display: inline-flex;
161}
162
163table th, table td {
164 padding: var(--universal-padding);
165}
166
167dl {
168 padding: 0 var(--universal-padding);
169}
170
171nav * {
172 padding: 0.1em 0;
173}
Note: See TracBrowser for help on using the repository browser.