/*
  formulas5.css (C) 2011-2015 by Corrado Cantelmi, version 0.16 [2015-10-26]

  Original location of this file:
    http://www.webalice.it/corrado.cantelmi/html/formulas/formulas5.css

  A complete explanation for these classes is found:
    http://www.webalice.it/corrado.cantelmi/html/formulas/How_to_Write_Formulas_in_HTML5_and_CSS.html

  These classes are font-independent and browser independent.
  ----------- [[[They are specific for HTML5]]] -----------

  Here is a short "how-to":
  - Avoid splitting an inline
    formula on two lines:         <span class="inlineformula">...your...formula...here...</span>
                      or:         <div  class="inlineformula">...your...formula...here...</div>
                                     PARENT element of <div class="inlineformula"> MUST BE A <div>
  - Write both superscript and
    subscript beside a variable:  variable<table class=supsub><tr><td>sup<br>sub</table>
  - Write a fraction inline:      <table class=frac><tr><td>numerator<br>&#x2013;&#x2013;&#x2013;<br>denominator</table>
  - Write a limit inline:         <table class=limittable><tr><td><span class=normalsize>lim</span><br>limit</table>&nbsp;function
  - Write a summation, a product
    or an integral inline:        <table class=big><tr><td>end<br><span class=bigmiddle>operator</span><br>start</table>rest
  - Write a combination inline:   <table class=comb><tr><td class=bigmiddle>(<td class=bincoef>things<br>taken<td class=bigmiddle>)</table>
  - Force the display of
    Unicode character:            <span class=unicode>unicode_chars</span>
  - Write a stand-alone formula
    with its reference number:    <table class=numfor><tr><td class=numforleft>your_formula</td><td class=numforright>ref.number</td></table>
  - Write a stand-alone formula
    with the <pre>:               <pre class=preformula>
                                      your
                                          formula
                                                  here
                                  </pre>
*/


.inlineformula, .inlineformula .supsub, .inlineformula .big, .inlineformula .frac {   /* Used to avoid the inline formulas wrapped across lines */
	white-space: nowrap;    /* OK for Opera 10-11, Firefox 3-4, IE8, Chrome 13, Safari for iPad */
	display:     inline;
}

/* generic class (two/three vertical cells) for inline polynomials */
.supsub, .frac, .limittable, .big, .comb,
.inlineformula .supsub, .inlineformula .frac, .inlineformula .limittable, .inlineformula .big, .inlineformula .comb { 
	border-collapse: collapse;
	margin:          0 0.1em 0 0.05em;
	font-size:       80%;
	position:        relative;
	bottom:          -0.6em;
	line-height:      1.1em;
	display:         inline-table;
	text-indent:     0em;           /* Needed by Chrome which inherits any indentation from the parent <p> */
}

.bigmiddle {
	font-size:  250%;               /* SIGMA, PI, integral sign must be much greater than other chars */
	line-height: 1.2em;
}

.big {
	top : 1.8em;
	text-align:   center;
	bottom:      -2em;
}

.comb {                           /* used for "combinations" */
	text-align:   center;
	top : 1em;
	line-height: 1.2em;
}

.bincoef {                        /* used for the binary coefficients inside the big ( and ) */
	padding-top: 0.3em;
	line-height: 1.5em;
}

.frac {                           /* centered text and different positioning for inline fractions
                                     using multiple &#x2013; chars for the fraction line*/
	text-align:   center;
	line-height:  0.9em;    /* line-height can't be less than 0.9, otherwise descending letters (gpqy) in the denominator can be cut (IE) */
	bottom:      -1.0em;
	top:          1.3em;
}

.limittable {                     /* class (two vertical cells) for "lim" over "x->0" */
	text-align:  center;
	top: 1.2em;
}

.normalsize {
	font-size:  125%;               /* the 'lim' word should be at 100%; this compensates for the 80% in "supsub" */
}

.supsub td {
	padding:   0;
}

.numfor {                         /* Used for centered formulas with the reference number on the right */
	text-indent:   0em;
	width: 95%;
	border-collapse: collapse;
}

.numfor td {
	padding: 0 0 0 0;
}

.numforleft {                     /* Used for "numfor" left cell */
	width: 95%;
	text-align: center;
	vertical-align: middle;
}

.numfor pre, .preformula {         /* Used for "numfor" left cell (if "PRE" is used) */
	line-height: 0.7em;
}

.numforright {                    /* Used for "numfor" right cell (formula reference number) */
	text-align: right;
	vertical-align: middle;
}

.unicode {                        /* Used to force displaying Unicode chars  */
	font-family: "arial unicode ms", arial, AppleGothic;
}


