fe9a6b2f2a233b4f515de59a06067afa1089accb
[sheet.git] / base.css
1 /* general */
2
3 body {
4         background: #FFF;
5         color: #000;
6         font-size: 90%;
7         text-align: center;
8 }
9 a, a:visited {
10         color: #000;
11         text-decoration: underline;
12 }
13 a:active, a:hover {
14         color: #00F;
15         text-decoration: none;
16 }
17
18 /* common sections */
19
20 h1, h2 {
21         font-size: 200%;
22         margin: 0;
23 }
24 h2, caption {
25         font-size: 110%;
26         font-weight: bold;
27 }
28 caption {
29         margin: 1ex;
30 }
31
32 hr {
33         clear: both;
34         visibility: hidden;
35         height: 2ex;
36         margin: 0;
37 }
38
39 .section ul {
40         margin-bottom: 1ex;
41 }
42 .section h2 {
43         margin: 0 1ex;
44         clear: both;
45 }
46 .section table {
47         float: left;
48         position: relative; /* prevents buggy hovering in table if caption present in gecko */
49         margin: 1ex 1ex 2ex;
50 }
51 .section .section {
52         float: left;
53 }
54 #charset .section table {
55         margin: -0.5ex 0 1ex; /* headers provide sufficient spacing already */
56 }
57
58 p {
59         margin: 1ex 0 1em;
60 }
61 p.aside {
62         font-size: 80%;
63 }
64 p.footer {
65         margin: 1em 0 0;
66         clear: both;
67 }
68 .help + .footer {
69         margin: 0;
70 }
71
72 .error {
73         background: #F00;
74         background: rgba(255, 0, 0, .8);
75         color: #FFF;
76         border: 2px solid #000;
77         border-width: 2px 0;
78         padding: 1em;
79         margin: 2ex auto;
80         clear: both;
81 }
82
83 ul {
84         margin: 0;
85         padding: 0;
86         list-style: none;
87 }
88
89 #source pre {
90         display: inline-block;
91         text-align: left;
92 }
93
94 h2 small {
95         position: absolute; /* side note; do not influence alignment */
96         margin-left: 1em;
97 }
98
99 dl > dt {
100         float: left;
101         width: 50%;
102         text-align: right;
103 }
104 dl > dd {
105         text-align: left;
106         padding-left: 1em;
107         overflow: hidden;
108 }
109
110 /* "keyboard" (list of keys) */
111
112 #rows {margin-top: -5ex} /* top (esc) row fits besides header */
113 .row2 {margin-left: 7em} /* row offsets relative to ~6em key width */
114 .row3 {margin-left: 8em}
115 .row4 {margin-left: 10em} /* should actually align to next key on row0 */
116         /* ...however rows>=1 are shifted a bit, to make space */
117
118 table.keys tr {
119         clear: both; /* start new row (screen row) */
120         display: block;
121 }
122 table.keys tbody {
123         /* start new row block (keyboard row) */
124         clear: both;
125         padding-top: 1ex;
126         display: block;
127 }
128
129 table.keys th,
130 h3      {display: none} /* semantic details (non-css/js) */
131 .keys .mode {display: none} /* initially hidden (only show interactively (js)) */
132
133 table.keys {
134         display: block;
135         width: 82.5em; /*       12 * (2px + 1px + 6.2em + 1px + 2px) + 8em*/
136 //      padding-right: 72px;
137         border-spacing: 0;
138         border-collapse: collapse;
139 }
140 table.keys > * {
141         margin-right: -72px;
142 }
143
144 /* individual keys */
145
146 dl.legend dt,
147 .keys td {
148         float: left;
149         width: 6.2em;
150         line-height: 2.25ex; /* a little terser (seems to be gecko's default anyway) */
151         height: 4.5ex; /* 2 lines */
152         overflow: hidden;
153         margin: 0 2px -1px;
154         padding: 0;
155         text-align: center;
156         border: 1px solid #000;
157         border-radius: 4px;
158         -moz-border-radius: 4px;
159         text-transform-variation: text;
160 }
161 .keys td b {
162         float: left;
163         font-size: 200%;
164         line-height: 2.5ex; /* inherits otherwise */
165         padding-left: 2px;
166 }
167 .keys .row0 td { /* omni-present esc */
168         width: 8.5em;
169 }
170
171 /* fine tuning of special occurrences */
172
173 .keys td b[title] { /* mnemonic hover */
174         cursor: help;
175 }
176 .keys td[onclick]:hover { /* link */
177         cursor: pointer;
178 }
179 .keys td a { /* key link */
180         color: inherit;
181         text-decoration: none;
182         display: block;
183         height: 100%;
184 }
185
186 .keys .meta td b,
187 .keys .ctrl td b,
188 .keys .lead td b { /* char with ctrl or leading key */
189         font-size: 100%; /* space is too limited for 2+ double-sized chars */
190         line-height: 5ex; /* keep double height though */
191 }
192 .keys .meta td b small,
193 .keys .ctrl td b small { /* meta key indicator */
194         font-size: 70%;
195         font-weight: normal; /* nice and subtle */
196 }
197
198 /* tables */
199
200 table {
201         border-collapse: collapse;
202 }
203 th, td {
204         border-color: #778;
205         border: 1px solid #888;
206         background: #DDD;
207 }
208 thead th, td {
209         text-align: center;
210 }
211
212 /* character table */
213
214 .glyphs thead th, .glyphs td {
215         width: 1.6em; /* regular interval */
216 }
217 .glyphs tbody td {
218         font-size: 112%;
219 }
220 .glyphs.big tbody td {
221         font-size: 200%;
222 }
223 .glyphs .glyphs {
224         margin: 0.5ex 0;
225 }
226 .glyphs .glyphs td {
227         font-size: 100%;
228 }
229
230 /* table headers */
231
232 th,
233 tfoot td,
234 thead td {
235         border: 0;
236         background: transparent;
237 }
238 .glyphs thead td {
239         width: auto; /* no glyph cells in header */
240 }
241 th {
242         padding: 0 0.2em;
243 }
244 .diinfo th {
245         font-size: 50%; /* mostly insignificant here */
246         font-weight: normal;
247 }
248 .diinfo tbody th {
249         text-align: right; /* variable width so keep near cells */
250         padding: 0 0.5em;
251 }
252 .cat {
253         font-size: 70%;
254         text-transform: uppercase;
255 }
256 tfoot .cat th {
257         border-top: 1px solid #888;
258 }
259
260 /* colour map */
261
262 table.color td {
263         border: 1px solid #555;
264         font-weight: normal;
265         padding: 0 8px;
266 }
267 table.color td samp {
268         margin: 0 -8px 0 8px;
269         font-family: inherit;
270         float: right;
271 }
272 table.color td samp ~ samp {
273 }
274 table.color td samp small {
275         font: 100% monospace;
276         padding: 0 .5ex;
277 }
278
279 /* digraphs map */
280
281 table.dimap {
282         table-layout: fixed; /* prevent resizing, notably in msie6 */
283 }
284 .dimap thead th, .dimap td {
285         /* below-maximum size (but still average enough to be regular) so we can fit more */
286         width: 1.2em; /* msie only looks at the first row */
287         min-width: 1em; /* prevents gecko from restricting to page width */
288 }
289 .dimap th {
290         text-align: center; /* row headers are also glyph-sized */
291 }
292
293 .mapped tbody, .mapped colgroup,
294 .dimap tbody, .dimap colgroup {
295         border: 2px double #888; /* major character group grid */
296 }
297 .mapped tbody,
298 .dimap tbody {
299         border-width: 2px 0; /* horizontal group dividers */
300 }
301 .mapped colgroup,
302 .dimap colgroup {
303         border-width: 0 2px; /* vertical divides */
304 }
305
306 /* digraph selection */
307
308 .diinfo {
309         -moz-column-width: 24em;
310         -webkit-column-width: 24em;
311         column-width: 24em;
312 }
313 .diinfo > div {
314         overflow: hidden;
315         column-break-inside: avoid;
316         -webkit-column-break-inside: avoid;
317         position: relative; z-index: 1; /* webkit bug */
318 }
319
320 /* glyph cell overlay (digraph labels) */
321
322 .glyphs.dilabel td {
323         padding: 0;
324         padding-bottom: 1.1ex; /* reserve space for label */
325         vertical-align: bottom;
326 }
327 .glyphs small {
328         font-size: 50%;
329         display: block;
330         margin-top: 0.2ex;
331         margin-bottom: -2.2ex; /* take cell padding */
332 }
333 .glyphs small.digraph {
334         background: #000;
335         color: #FFF;
336         opacity: 0.3;
337 }
338 .glyphs small.value {
339         background: #600;
340         color: #FFF;
341         opacity: 0.3;
342 }
343
344 /* character properties */
345
346 .X  {background: #FFF} /* unidentified */
347 #digraphs .Xa {color: #0A0} /* ascii */
348 #digraphs .Xl {color: #070} /* latin1 */
349 #digraphs .u-prop {color: #D00} /* proposed */
350 #digraphs .u-prop.ex {color: #D88; color: rgba(221, 0, 0, .5)} /* unofficial proposal */
351
352 .Lm, .Mc, .Me, .Zl, .Zp {background: #F00} /* unstyled */
353 .X > span               {background: #898; background: rgba(0, 0, 0, .25)} /* invisible contents */
354
355 /* letter scripts */
356 .Armenian,
357 .Greek    {background: #FFE8CF}
358 .Cyrillic {background: #FFDDA8}
359 .Latin    {background: #FFB}
360 .Aramaic,
361 .Hebrew   {background: #FFD}
362 .Arabic   {background: #EFE}
363 .African  {background: #DED}
364 .Brahmic  {background: #FBB} /* same as number */
365 .Khmer    {background: #FBA}
366 .Hangul,
367 .Syllabic {background: #DEA}
368 .Katakana {background: #DFA}
369 .Hiragana {background: #DFC}
370 .Bopomofo {background: #BFC}
371 .Han      {background: #CFD}
372 .Alpha    {background: #ADA} /* other scripts */
373
374 /* other categories */
375 .Nd, .Nl, .No         {background: #FDD} /* number */
376 .Sc                   {background: #FCD} /* currency */
377 .Sm                   {background: #ECE} /* math */
378 .So                   {background: #DCF} /* symbol */
379 .Pd, .Po, .Pc         {background: #CDF} /* punctuation */
380 .Ps, .Pe, .Pi, .Pf    {background: #BEF} /* quote */
381 .Lm, .Sk              {background: #CEE} /* spacing modifier */
382 .Mn                   {background: #ACC} /* modifier */
383 .Cc, .Cf {color: #666; background: #BBB} /* control */
384 .Zs                   {background: #ACB} /* space */
385 .Co, .Xi.Co           {background: #DCC} /* private */
386 .Xi, .Cs              {background: #CCC} /* invalid */
387 .Xd                   {color: #844} /* deprecated */
388 .Xr                   {color: #888} /* reserved (digraph reverse or proposal) */
389 .dimap .Xr            {background: #EEE} /* reversed digraph */
390 .ccmap .Xr {opacity:.4}
391
392 /* support levels */
393 .l1 {background: #FDD} /* no, unsupported, other */
394 .l2 {background: #FED} /* partial, restricted, unofficial */
395         /* default u-prop, u-bmp */
396 .l3 {background: #FFD} /* almost, imperfect, common */
397         /* default u-di, u-lat1 */
398 .l4 {background: #EFD} /* yes, supported, ubiquitous, native */
399         /* default u-ascii */
400 .l5 {background: #DFD} /* complete, perfect */
401 .l0 {background: #EEE} /* unknown, omitted */
402 .ex {     color: #888; color: rgba(0, 0, 0, .5)} /* experimental, disfavoured */
403 .u-invalid {background: #BBB} /* invalid, impossible */
404
405 .p0         {opacity: .6}
406 .p0.p       {opacity: 1}
407 .p::after   {content: '!'; color: #F00}
408 .p4::after  {color: #C00}
409 .p3::after  {color: #A00}
410 .p2::after  {color: #800}
411 .p1::after,
412 .p0::after  {color: #000}
413 .p09::after {opacity: .9}
414 .p08::after {opacity: .8}
415 .p07::after {opacity: .7}
416 .p06::after {opacity: .6}
417 .p05::after {opacity: .5}
418 .p04::after {opacity: .4}
419 .p03::after {opacity: .3}
420 .p02::after {opacity: .2}
421 .p01::after {opacity: .1}
422 .p00::after {display: none}
423
424 /* code syntax */
425 .sy-comment    { color: #888 }
426 .sy-constant   { color: #008 }
427 .sy-type,
428 .sy-identifier { color: #804 }
429 .sy-statement  { }
430 .sy-preProc    { }
431 .sy-special    { color: #408 }
432 .sy-error      { font-weight: bold; background-color: #F00; color: #FFF }
433 .sy-todo       { background-color: #FF0 }
434
435 /* hover effects */
436 .u-di,
437 .X:hover {cursor: help}
438 .X:hover > span                            {background: #FFF} /* whitespace marker */
439 .Greek:hover, .Armenian:hover              {background: #FA8}
440 .Cyrillic:hover                            {background: #FB7}
441 .Latin:hover                               {background: #EE4}
442 .Hebrew:hover, .Aramaic:hover              {background: #FFA}
443 .Arabic:hover                              {background: #CFD}
444 .African:hover                             {background: #BDB}
445 .Syllabic:hover, .Hangul:hover             {background: #CE6}
446 .Katakana:hover                            {background: #BF7}
447 .Hiragana:hover                            {background: #AF8}
448 .Bopomofo:hover                            {background: #8FA}
449 .Brahmic:hover                             {background: #F77}
450 .Khmer:hover                               {background: #F87}
451 .Han:hover                                 {background: #5EB}
452 .Alpha:hover                               {background: #5C5}
453 .Nd:hover, .Nl:hover, .No:hover            {background: #F99} /* number */
454 .Sc:hover                                  {background: #F8C} /* currency */
455 .Sm:hover                                  {background: #F8F} /* math */
456 .So:hover                                  {background: #A8F} /* symbol */
457 .Pd:hover, .Po:hover, .Pc:hover            {background: #8AF} /* punctuation */
458 .Ps:hover, .Pe:hover, .Pi:hover, .Pf:hover {background: #8DF} /* quote */
459 .Lm:hover, .Sk:hover                       {background: #BFF} /* spacing modifier */
460 .Mn:hover                                  {background: #CDE} /* modifier */
461 .Zs:hover                                  {background: #CED} /* space */
462 .Cc:hover, .Cf:hover                       {background: #DDD} /* control */
463 .Co:hover                                  {background: #A77} /* private */
464 .Xr:hover                                  {background: #FFF} /* reserved */
465 .Xi:hover                                  {background: #DDD} /* invalid */
466 .Xa:hover {outline: 1px solid #0F0} /* ascii */
467 .Xl:hover {outline: 1px solid #0C0} /* latin1 */
468 .u-prop:hover {outline: 1px solid #F00} /* proposed */
469 .l0:hover                                  {background: #888}
470 .l1:hover                                  {background: #F88}
471 .l2:hover                                  {background: #FC8}
472 .l3:hover                                  {background: #FF8}
473 .l4:hover                                  {background: #CF8}
474 .l5:hover                                  {background: #8F8}
475
476 /* key type colorization */
477
478 .c-sa,
479 .g1 {background: #BFE} /* cyan: info */
480 .c-na,
481 .g2 {background: #BFB} /* green: motion */
482 .g3 {background: #DFA} /* greenish: jump (g2+) */
483 .c-af,
484 .g4 {background: #FFA} /* yellow: command */
485 .c-eu,
486 .g5 {background: #FDA} /* orangish: open (g6-) */
487 .g6 {background: #FCA} /* orange: insert */
488 .c-as,
489 .g7 {background: #FCC} /* red: mode */
490 .c-an,
491 .g8 {background: #ECE} /* purple: visual (g7+) */
492 .c-oc,
493 .g9 {background: #CCF} /* blue: prefix */
494
495 .c-sa:hover,
496 .g1 a:hover, .g1[onclick]:hover {background: #5ED}
497 .c-na:hover,
498 .g2 a:hover, .g2[onclick]:hover {background: #7E7}
499 .g3 a:hover, .g3[onclick]:hover {background: #CE6}
500 .c-af:hover,
501 .g4 a:hover, .g4[onclick]:hover {background: #EE4}
502 .c-eu:hover,
503 .g5 a:hover, .g5[onclick]:hover {background: #FA6}
504 .g6 a:hover, .g6[onclick]:hover {background: #F97}
505 .c-as:hover,
506 .g7 a:hover, .g7[onclick]:hover {background: #F88}
507 .c-an:hover,
508 .g8 a:hover, .g8[onclick]:hover {background: #D9D}
509 .c-oc:hover,
510 .g9 a:hover, .g9[onclick]:hover {background: #99F}
511
512 .no {
513         background: #EEE; /* unassigned */
514 }
515 .keys td.ni {
516         border: 0;
517         padding: 1px; /* same size as borderlessless keys */
518         background: none;
519 }
520
521 dl.legend dt.more,
522 .keys td.more b {
523         text-shadow: #F20 0 0 0.1em;
524 }
525 dl.legend dt.more:hover,
526 .keys td.more:hover b {
527         text-shadow: #F20 0 0 0.5em, #FC0 0 0 0.2em;
528 }
529 dl.legend dt.ext,
530 .keys td.ext {
531         border-style: dashed;
532 }
533 dl.legend dt.new,
534 .keys td.new {
535         opacity: .6;
536 }
537
538 /* l/r help columns */
539
540 .help {
541         display: table;
542         width: 100%;
543 }
544 .help > * {
545         display: table-cell;
546         width: 20%;
547         vertical-align: top;
548 }
549
550 .left dl.legend {
551         margin-left: 6.4em; /* a bit over 6.2em to allow for borders+padding (border-sizing would work too) */
552 }
553 .left dl.legend dt {
554         margin-left: -6.4em; /* msie<=6 multiply this by two for some reason */
555         float: left;
556         clear: left;
557 }
558 .left dl.legend dd {
559         float: left; /* align next to dt (except msie<=7 does just the opposite) */
560 }
561 .right dl.legend {
562         margin-right: 6.4em;
563 }
564 .right dl.legend dt {
565         margin-right: -6.4em;
566         float: right;
567         clear: right;
568 }
569 .right dl.legend dd {
570         float: right;
571 }
572 .right {
573         text-align: right;
574 }
575
576 /* help/legend */
577
578 dl.legend dt {
579         margin: 0 0 1px; /* distinct keys */
580         height: auto; /* not key-height */
581         padding: 2px 0;
582 }
583 dl.legend dd {
584         margin: 3px 0.4em 0; /* align text (add dt border+padding height) */
585         padding: 0;
586 }
587
588 dl.legend-options dt {
589         background: #CCC;
590 }
591
592 ul.legend-set {
593         clear: right;
594         padding-top: 1ex;
595 }
596 ul.legend-set li {
597         margin: 6px 0; /* similar to dl legends */
598 }
599
600 .legend {
601         margin-top: 1em;
602 }
603 .legend table {
604         width: 100%;
605 }
606 .legend td {
607         padding: 0 0.2em;
608 }
609
610 /* page-specific */
611
612 #browser td > a {
613         text-decoration: none;
614 }
615 #browser td > a:active,
616 #browser td > a:hover {
617         text-decoration: underline;
618 }
619 #browser tr .aside {
620         font-size: 80%;
621         overflow: hidden;
622         height: 0;
623         -webkit-transition: all 1s ease-in;
624         -o-transition: all 1s ease-in;
625         -moz-transition: all 1s ease-in;
626         transition: height 1s ease-in;
627 }
628 #browser tr .aside p {
629         margin: 1ex 0;
630 }
631 #browser tr.target .aside,
632 #browser tr:target .aside {
633         height: auto;
634 }
635 #browser td.X {
636         white-space: nowrap; /* some browsers break on dashes */
637 }
638
639 #browser tr:target > td:first-of-type,
640 #browser tr.focus > td:first-of-type {
641         background: inherit;
642 }
643 #browser tr.focus > td {
644         border-bottom-color: #000;
645 }
646
647 form.aside {
648         position: absolute;
649         top: 3ex;
650         right: 1em;
651 }
652
653 /* printing hints */
654
655 @page {
656         size: landscape;
657         margin: 0;
658 }
659
660 @media print {
661         ul.legend-set {display: none} /* current options only relevant on dynamic media */
662 }
663