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