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