]> git.0d.be Git - chloro.git/blob - chloro/phyll/static/css/style.scss
874cd9b5d59f61003f411e8d29ddefb4a875bc40
[chloro.git] / chloro / phyll / static / css / style.scss
1 @charset "UTF-8";
2
3 $text-color: #222;
4 $link-color: #0000ee;
5 $visited-link-color: #551a8b;
6
7 @import "opensans";
8
9 body {
10         font-family: "Open Sans", sans-serif;
11         background: white;
12         color: $text-color;
13         font-size: 100%;
14 }
15
16 a {
17         color: $link-color;
18         text-decoration: none;
19         border-bottom: 0.1em dotted $link-color;
20         &:visited {
21                 color: $visited-link-color;
22                 border-color: $visited-link-color;
23         }
24         &:hover {
25                 border-bottom-style: solid;
26         }
27 }
28
29 header {
30         display: inline-block;
31         h1 {
32                 font-weight: normal;
33                 text-transform: uppercase;
34                 margin: 1em 0 0 1em;
35                 padding: 0 0.5em;
36                 color: lighten($text-color, 20%);
37                 background: #fafaff;
38                 display: inline-block;
39                 a {
40                         border: none;
41                 }
42         }
43         transform: rotate(-2deg);
44         position: relative;
45         z-index: 2;
46 }
47
48 div.actions {
49         position: absolute;
50         top: 0.5rem;
51         left: 1rem;
52         z-index: 100;
53         a {
54                 margin-right: 1rem;
55         }
56 }
57
58 main, footer {
59         margin: 0 4em;
60         padding: 1em;
61         max-width: 70em;
62 }
63
64 main {
65         position: relative;
66         background: #fafaff;
67         min-height: 70vh;
68         clip-path: polygon(0px 0px, 96.35% -24px, 101.99% 7.86%, 100.61% 103.56%, 10% 100%, 0% 100%, 0px 0px);
69 }
70
71 .home {
72         nav a {
73                 text-transform: uppercase;
74                 display: inline-block;
75                 text-decoration: none;
76                 font-size: 500%;
77                 font-weight: bold;
78                 padding-top: 0.5em;
79                 line-height: 50%;
80                 width: 100%;
81                 span {
82                         font-size: 30%;
83                 }
84                 margin-bottom: 1rem;
85                 &.divers {
86                         width: 49%;
87                 }
88                 &.vrac {
89                         width: 49%;
90                         text-align: right;
91                         float: right;
92                 }
93         }
94         .latest {
95                 margin-top: 2em;
96                 h2 {
97                         margin: 0;
98                         font-size: 400%;
99                         font-weight: bold;
100                         text-transform: uppercase;
101                 }
102                 .meta {
103                         padding-top: 0.5rem;
104                         padding-left: 0.5rem;
105                         color: lighten($text-color, 40%);
106                 }
107         }
108 }
109
110 .post {
111         max-width: 50em;
112         div.figure {
113                 text-align: center;
114                 margin: 1em 0;
115                 img {
116                         border: 1px solid gray;
117                         padding: 3px;
118                         max-width: 90%;
119                         max-height: 70vh;
120                 }
121                 .caption {
122                         margin-top: 0;
123                         font-style: italic;
124                 }
125         }
126         p {
127                 line-height: 160%;
128         }
129         code,
130         pre.screen {
131                 background: #111;
132                 color: white;
133                 padding: 2px;
134         }
135         div.meta {
136                 margin-top: 3em;
137                 color: lighten($text-color, 40%);
138         }
139         div.note {
140                 background: #fbf7c1;;
141                 padding: 0.2em 0.5em 0.2em 2em;
142                 p {
143                         margin: 0.5em 0;
144                 }
145         }
146         blockquote {
147                 background: #eeeefd;
148                 padding: 0.1em 1em;
149                 clip-path: polygon(0px 0px, 94.27% 2px, 99.63% 2.65%, 98.39% 97.48%, 10% 100%, 0% 100%, 0px 0px);
150         }
151 }
152
153 .post-list {
154         ul, li {
155                 margin: 0;
156                 padding: 0;
157                 list-style: none;
158                 display: inline-block;
159         }
160         li.unpublished {
161                 opacity: 0.5;
162         }
163         a {
164                 text-transform: uppercase;
165                 display: inline-block;
166                 text-decoration: none;
167                 font-size: 200%;
168                 font-weight: bold;
169                 padding-top: 0.5em;
170                 margin-right: 1em;
171                 span {
172                         font-size: 60%;
173                 }
174         }
175 }
176
177 .older.post-list {
178         margin: 5em 0 2em 0;
179         padding: 1em 0;
180         border-top: 0.1em dotted $link-color;
181         border-bottom: 0.1em dotted $link-color;
182         line-height: 200%;
183         li {
184                 display: inline;
185                 a {
186                         padding-top: 0;
187                         display: inline;
188                         font-size: 120%;
189                 }
190         }
191 }
192
193 footer {
194         p {
195                 text-align: right;
196                 font-size: 100%;
197         }
198 }
199
200 div[contenteditable=true]:focus-within {
201         outline: 1px solid gray;
202         outline-offset: 3px;
203 }
204
205 .inline-style-popup,
206 .block-style-popup {
207         background: white;
208         box-shadow: 0 0 5px #666;
209         input {
210                 display: none;
211                 padding: 3px;
212                 border: 1px inset #ccc;
213                 background: white;
214                 width: 0px;
215                 transition: width ease 2s;
216                 &.shown {
217                         display: inline-block;
218                         width: 400px;
219                 }
220         }
221         button {
222                 padding: 0 0.5em;
223                 height: 2em;
224                 text-align: center;
225                 background: #eee;
226                 border: 0px;
227                 &:hover {
228                         background: #ccc;
229                 }
230                 &[data-action=createLink] {
231                         color: blue;
232                         text-decoration: underline;
233                 }
234                 &.on {
235                         background: #444;
236                         color: white;
237                 }
238         }
239         &.inline-style-popup button {
240                 width: 2em;
241                 padding: 0;
242         }
243         &.block-style-popup {
244                 &.selected button {
245                         display: none;
246                         &.on {
247                                 display: block;
248                         }
249                 }
250         }
251 }
252
253 button#save {
254         position: sticky;
255         bottom: 10px;
256 }
257
258 main.post {
259         [contenteditable=true] div.figure {
260                 cursor: pointer;
261         }
262         div.figure {
263                 text-align: center;
264                 line-height: initial;
265                 span.empty::before {
266                         min-height: 50px;
267                         margin: 0 auto;
268                         display: block;
269                         width: 90%;
270                         background: #eee;
271                         padding: 1rem;
272                         font-size: 200px;
273                         content: "(image)";
274                         color: #aaa;
275                 }
276         }
277 }