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