]> git.plutz.net Git - confetti/blob - style.css
avoid space character in empty first name/middle name field; try to parse FN if N...
[confetti] / style.css
1 * {
2   position: relative;
3   box-sizing: border-box;
4   max-width: 100%;
5   font-family: sans-serif;
6   font-weight: normal;
7   font-size: initial;
8   font-style: normal;
9   text-decoration: none;
10   line-height: 1.5em;
11   color: inherit; background: transparent;
12   padding: 0; margin: 0;
13   border: none;
14 }
15
16 body {
17   color: #000; background-color: #FFF;
18 }
19
20 /* ======= GENERIC HTML STYLES =======*/
21
22 p { margin-bottom: 1em; }
23
24 a {
25   text-decoration: underline;
26   font-style: italic;
27   color: #068;
28 }
29
30 i, em { font-style: italic; }
31 b, strong { font-weight: bolder; }
32 ul, ol { margin-left: 1.125em; }
33 table th { font-weight: bold; }
34
35 h1, h2, h3 {
36   font-weight: bold;
37   margin-top: 1em;
38   margin-bottom: .5em;
39 }
40
41 h1:first-child, h2:first-child, h3:first-child,
42 p + h1, p + h2, p + h3 {
43   margin-top: 0;
44 }
45
46 h4, h5, h6, form legend {
47   font-weight: bolder;
48   margin-bottom: .25em;
49 }
50
51 h1 { font-size: 1.5em; }
52 h2 { font-size: 1.125em; }
53
54 select, input, button, textarea,
55 .control a {
56   display: inline-block;
57   background-color: #FFF;
58   border: 1pt solid;
59   padding: .25em .75em;
60   vertical-align: text-bottom;
61 }
62 .control a {
63   color: inherit;
64   font-style: normal;
65   text-decoration: none;
66 }
67
68 select { padding: .375em 0; }
69
70 input[type=radio], input[type=checkbox] {
71   vertical-align: baseline;
72 }
73 input[type=number] { text-align: right; padding-right: 0; }
74
75 button, input[type=button],
76 .control a {
77   box-shadow: .125em .125em .25em;
78   cursor: pointer;
79 }
80 input[type=radio], input[type=checkbox],
81 input[type=radio] + label, input[type=checkbox] + label {
82   cursor: pointer;
83 }
84
85 label { margin-right: .75em; }
86 input + label {
87   margin-left: .375em;
88 }
89
90 /* ====== COMMON ELEMENTS ======*/
91
92 body > ul.menu {
93   display: block;
94   height: 1.75em;
95   margin: 0; -padding: 0 .5em;
96   list-style: none;
97   color: #CCC;
98   background-color: #444;
99   box-shadow: inset 0 -.25em .25em #000;
100   overflow: hidden;
101   z-index: 3;
102 }
103
104 body > .menu li {
105   display: inline-block;
106 }
107 body > .menu a {
108   color: inherit;
109   padding: .5em 3em;
110   box-shadow: inset 0 0 .5em #000;
111 }
112 body.cards > .menu a[href="/cards/"],
113 body.courses > .menu a[href="/courses/"] {
114   color: #000;
115   background-color: #FFF;
116   box-shadow: none;
117 }
118
119 /* =========== FILTER AND SEARCH Headers ========= */
120
121 form.categories,
122 form.search, form.sort, form.filter, form.newcard, form.newcourses {
123   margin-top: 1em; padding: 0 1em;
124   z-index: 1;
125 }
126 form.filter > h1 { display: none; }
127
128 form.filter fieldset { margin-top: .5em; }
129 form.filter fieldset.item + fieldset.item legend { display: none; }
130 form.filter fieldset.item input[type=radio] { display: none; }
131 form.filter fieldset.item input[type=radio] + label {
132   display: table-cell;
133   padding: .5em 1em;
134   background-color: #EEE;
135   border-style: solid;
136   border-width: .5pt .25pt 0 .25pt;
137   white-space: normal;
138 }
139 form.filter fieldset.item input[type=radio] + label:first-of-type {
140   border-left: 1pt solid;
141 }
142 form.filter fieldset.item input[type=radio]:checked + label {
143   position: relative;
144   background-color: #FFF;
145   box-shadow: .125em -.125em .125em #888;
146   z-index: 1;
147 }
148 form.filter fieldset.item input[type=text],
149 form.filter fieldset.item fieldset.categories {
150   position: relative;
151   display: block;
152   width: 100%;
153   margin-top: -1pt;
154   padding: .25em .75em;
155   border: 1pt solid;
156   box-shadow: .125em .125em .25em #888;
157 }
158 form.filter fieldset.item fieldset.categories { display: none; }
159 form.filter fieldset.item input[value=CATEGORIES]:checked + label + input[type=text] { display: none; }
160 form.filter fieldset.item input[value=CATEGORIES]:checked + label + input[type=text] + fieldset.categories { display: block; }
161
162 form.filter fieldset.order legend {
163   float: left; margin-right: 1em;
164 }
165
166 form.filter fieldset label,
167 form.filter fieldset a { white-space: pre;}
168 form.filter button[type=submit] {
169   margin-top: .5em; margin-bottom: .5em;
170 }
171
172 body.courses form .order { display: inline-block; margin-right: 2em;}
173
174
175 /* ============ LIST ITEMS, Generic ============= */
176
177 body > form,
178 div.card,
179 div.course {
180   position: relative;
181   width: 98%; width: calc(100% - 2em);
182   margin-left: auto; margin-right: auto;
183   margin-bottom: 1em;
184   box-shadow: .125em .125em .25em;
185   z-index: 1;
186 }
187
188 /* HACK: put anchor point 10em above card and highlight target element */
189     div:target { box-shadow: none; z-index: 0; }
190     div:target:before {
191       content: '';
192       display: block;
193       margin-top: -10em;
194       height: 10em;
195       visibility: hidden;
196     }
197     div:target:after {
198       content: '';
199       display: block;
200       position: absolute;
201       left: 0; right: 0;
202       top: 10em; bottom: 0;
203       box-shadow: .125em .125em .25em;
204       animation: highlight 4s;
205       z-index: -1;
206     }
207     @keyframes highlight { from { background-color: #FF0; } to { background-color: transparent; } }
208 /**/
209
210 div .section, form .section {
211   display: block;
212   vertical-align: top;
213   padding: 0 1em;
214   overflow: hidden;
215   word-break: break-word;
216 }
217
218 div .section :last-child, form .section :last-child {
219   margin-bottom: 1em;
220 }
221
222 div .section h2, form .section h2,
223 div .section h3, form .section h3 { 
224   border-bottom: 1pt solid #EEE;
225 }
226 div .control, form .control {
227   background-color: #EEE;
228   padding: .25em;
229   text-align: right;
230 }
231
232 @media(min-width: 60em) {
233   div .section, form .section {
234     display: table-cell;
235     width: calc(100% / 10);
236   }
237   div .section :last-child { margin-bottom: 0; }
238   div .control, form .control {
239     background-color: transparent;
240   }
241   div .section:nth-of-type(2n) {
242     background-color: #EEE;
243   }
244 }
245 @media(min-width: 80em) {
246   div .control, form .control {
247     display: table-cell;
248     width: calc(100% / 10);
249   }
250   div .control .item, form .control .item {
251     display: block;
252     margin-bottom: .25em;
253   }
254 }
255
256 div .section .item, form .section .item,
257 form .section.attendance > label {
258   display: block;
259   width: 100%;
260 }
261
262 div .section .item.NOTE {
263   white-space: pre-wrap;
264 }
265
266 form .section .item {
267   margin-bottom: .25em;
268 }
269
270 form .section button[value^=addfield] {
271   font-size: .75em;
272   margin-top: .5em; padding: 0 .375em;
273 }
274
275 /* HACK: "responsive" Delete Button above each field */
276     form input.delete { display: none; }
277     form input.delete + label {
278       float: right;
279       font-size: .75em;
280       line-height: 1;
281       max-width: 1.75em; height: 1.125em; overflow: hidden;
282       color: #FBB; background-color: #444;
283       margin: 0; padding: .125em .5em 0 .5em;
284       border-radius: 4pt 4pt 0 0;
285       transition: max-width .3s;
286     }
287     form input.delete + label:before  { content: '\274c '; margin-right: .5em; }
288     form input.delete + label:hover   { max-width: 10em; }
289     -form input.delete + label:hover:before { content: ''; }
290     -form input.delete + label:hover:after  { content: ' \274c'; }
291     form input.delete:checked + label,
292     form input.delete:checked + label + * {
293       display: none;
294     }
295 /**/
296
297
298 /* ====== right hand Control Buttons on list items ====== */
299
300 form .control {
301   position: relative;
302   padding-left: 11em;
303   padding-top: 1.5em;
304 }
305 form .control .item {
306   display: inline-block;
307   margin-bottom: .25em;
308   vertical-align: text-bottom;
309 }
310
311 /* Combined Select/Submit Box */
312     form .control .item.newfield { box-shadow: .125em .125em .25em; }
313     form .control .item.newfield select { margin-right: -1pt; }
314     form .control .item.newfield button { box-shadow: none; }
315 /**/
316
317 /* HACK: Delete Checkbox before delete Button */
318     form .control .item.delete {
319       position: absolute;
320       bottom: .375em; left: .25em; width: auto;
321       padding-bottom: calc(2.25em + 2pt);
322     }
323     
324     form .control .item.delete input + label + button {
325       display: none;
326       position: absolute;
327       bottom: 0; width: 100%;
328       color: #800;
329       background-color: #FEE;
330       z-index: 1;
331     }
332     form .control .item.delete:after {
333       content: attr(label);
334       display: block;
335       position: absolute;
336       bottom: 0; width: 100%;
337       text-align: center;
338       color: #BAA;
339       padding: .25em 0;
340       border: 1pt solid;
341       box-shadow: .125em .125em .25em;
342     }
343     form .control .item.delete input:checked + label + button { display: block; }
344 /**/
345
346 @media(min-width: 80em) {
347   form .control { padding: .25em; min-height: 16em; }
348   form .control .item { width: 100%; }
349   form .control .item.newfield select { width: calc(100% - 2.5em); }
350   form .control .item.delete { bottom: .125em; right: .25em; }
351 }
352
353 /* ======= LIST ITEMS, Courses ======= */
354
355 form.course .dtstart input[name=DTS_YEAR],
356 form.course .dtstart select[name=DTS_MONTH] { width: calc(50% - 1.25em); }
357 form.course .dtstart input[name=DTS_YEAR] { margin-right: -.375em; }
358 form.course .dtstart table { width: 100%; margin: 1em 0; }
359 form.course .dtstart table td { text-align: right; -border: .5pt solid; }
360 form.course .dtstart table input[type=radio] { display: none; }
361 form.course .dtstart table input[type=radio] + label {
362   display: block;
363   width: 100%;
364   margin: 0; padding: 0 3pt;
365 }
366 form.course .dtstart table input[type=radio]:checked + label {
367   font-weight: bold;
368   padding: 0 2pt;
369   box-shadow: .125em .125em .25em;
370 }
371
372 form.course .dtstart label.DTSTIME {
373   display: inline-block;
374   font-weight: bold;
375   margin: 0;
376   width: calc(100% - 7.875em);
377 }
378 form.course .dtstart input[name=DTS_HOUR],
379 form.course .dtstart input[name=DTS_MINUTE] {
380   vertical-align: baseline;
381   width: 3.5em;
382   margin-bottom: 0;
383 }
384
385 form.course .recur .item { white-space: nowrap; }
386 form.course .recur .item > * { margin-bottom: 0; vertical-align: baseline; }
387 form.course .recur input[name=RRULE_INTERVAL],
388 form.course .recur input[name=RRULE_COUNT],
389 form.course .recur input[name=RRULE_UMONTH],
390 form.course .recur input[name=RRULE_UDAY] { width: 3.5em; }
391 form.course .recur input[name=RRULE_UYEAR] { width: 4.5em; }
392 form.course .recur input[name=RRULE_UYEAR],
393 form.course .recur input[name=RRULE_UMONTH],
394 form.course .recur input[name=RRULE_UDAY] {
395   margin-right: -.375em;
396 }
397
398 form.course .attendance div.attendance {
399   max-height: 16em;
400   overflow-y: scroll;
401 }
402 form.course .attendance label {
403   display: inline-block;
404   max-width: calc(100% - 2em);
405   vertical-align: top;
406   margin-bottom: 0;
407 }
408 form.course .attendance input { margin-top: .375em; }
409
410 /* ======== Categories Page ======== */
411
412 body.categories form ul { list-style: none; margin: 0; }
413
414 form.categories li {
415   display: inline-block;
416   background-color: #EEE;
417   margin-right: .5em; margin-bottom: .5em;
418   padding-left: .5em;
419   box-shadow: .125em .125em .25em;
420 }
421 form.categories li button[name=remove] {
422   font-size: .75em;
423   width: 2.5em;
424   background-color: #FBB;
425   overflow: hidden;
426   white-space: pre;
427 }
428 form.categories li button[name=remove]:before {
429   content: '\274C ';
430   margin-right: 3em;
431 }
432
433 form.categories li:last-child { padding-left: 0 }
434
435 body.categories form.namelist ul.namelist > li:nth-of-type(2n + 1) { background-color: #EEE; }
436 body.categories form.namelist ul.namelist > li h2,
437 body.categories form.namelist ul.namelist > li ul {
438   display: inline-block;
439 }
440 body.categories form.namelist ul.namelist > li h2 {
441   width: 20%;
442   min-width: 10em;
443 }
444 body.categories form.namelist ul.namelist > li ul li {
445   display: inline-block;
446 }