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