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