html { 
  margin: 0;
  font: 10pt/1.26 "Gill Sans", sans-serif;
}

body { 
  margin: 0 0 0 13%;
}

h2, h3, h4, h5, h6 { 
  font-family: "Gill Sans", sans-serif;
  margin: 2em 0 0.5em 0;
  page-break-after: avoid;
} 

/*h1 { 
	page-break-before: always;
  padding: 2em 0 2em 0;
  margin: 0;
  font-size: 2.4em;
  font-weight: 900;
}*/

h2 { 
  font-size: 1.2em;
  text-transform: uppercase;
  font-weight: bold;
}

h3 { 
  font-size: 1em;
  font-weight: bold;
}

q::before {
  content: "\201C";
}

q::after {
  content: "\201D";
}


pre {  margin: 1em 1.3em; color: #600; }
/*

"Dive Into Python 3" stylesheet

Copyright (c) 2009, Mark Pilgrim, All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice,
  this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
  this list of conditions and the following disclaimer in the documentation
  and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.


Classname Legend

.w = "widgets"  = wrapper block for hide/open/download links dynamically inserted into code listings
.b = "block"    = internal block dynamically inserted into code listings
.d = "download" = download link for code listings
.p = "prompt"   = command-line or interactive shell prompt within code listings
.q = "quote"    = quote at beginning of each chapter
.f = "fancy"    = first paragraph of each chapter (gets a fancy drop-cap)
.c = "centered" = centered footer text (also clears floats)

.note = "note/caution/important"   = indented block for tips/gotchas/language comparisons
.baa  = "best available ampersand" = wrapper block for ampersands
.nav  = "navigation"               = prev/next navigation links (not breadcrumbs)


Acknowledgements & Inspirations

"The Elements of Typographic Style Applied to the Web" ... http://webtypography.net/toc/
"Setting Type on the Web to a Baseline Grid" ............. http://www.alistapart.com/articles/settingtypeontheweb
"Compose to a Vertical Rhythm" ........................... http://24ways.org/2006/compose-to-a-vertical-rhythm
"Use the Best Available Ampersand" ....................... http://simplebits.com/notebook/2008/08/14/ampersands.html
"Unicode Support in HTML, Fonts, and Web Browsers" ....... http://alanwood.net/unicode/
*/

/* The portions of this stylesheet _not_ derived from Pilgrim's come from
 * http://www.alistapart.com/articles/boom or my own fevered imagination. ;-)
*/

/* typography */
body,.w a{font:medium 'Gill Sans MT','Gill Sans',Corbel,Helvetica,Jara,'Nimbus Sans L',sans-serif;line-height:1.75;word-spacing:0.1em}
pre,kbd,samp,code,var{font-family:Consolas,'Andale Mono',Monaco,'Liberation Mono','Bitstream Vera Sans Mono','DejaVu Sans Mono',monospace;font-size:medium;line-height:1.75;word-spacing:0}
span{font:medium 'Arial Unicode MS',FreeSerif,OpenSymbol,'DejaVu Sans',sans-serif}
pre span{font-family:'Arial Unicode MS','DejaVu Sans',FreeSerif,OpenSymbol,sans-serif}
.baa{font:oblique large Constantia,Baskerville,Palatino,'Palatino Linotype','URW Palladio L',serif}
abbr{font-variant:small-caps;text-transform:lowercase;letter-spacing:0.1em}
.q{text-align:right;font-style:oblique}
.q span{font-size:large}
.note{margin:3.5em 4.94em}
.note span{display:block;float:left;font-size:xx-large;line-height:0.875;margin:0 0.22em 0 -1.22em;color:steelblue}
.c,pre,.w,.w a,.d{line-height:2.154}
.f:first-letter{float:left;color:lightblue;padding:0.11em 4px 0 0;font:normal 4em/0.68 serif}
p {margin:1.75em 0;font-size:medium} 
/*p,ul,ol{margin:1.75em 0;font-size:medium} */

/* basics */
html{background:#fff;color:#222}
body{margin:1.75em 28px}
.c{clear:both;text-align:center;margin:2.154em 0}
form div,#level{float:right}
/* Hide TODOs .todo{color:#ddd} */
.todo{display: none}


/* code blocks */
pre{white-space:pre-wrap;padding-left:2.154em;border-left:1px solid #ddd}
.w{float:left}
.c,.w,.w a,.d{font-size:small}
.b,ol,p,blockquote,h1,h2,h3{clear:left}
pre a,.w a{padding:0.4375em 0}
.w a{text-decoration:underline}
kbd,mark{font-weight:bold}
mark{display:inline-block;width:100%;background:#ff8}
.p{color:#667}

/* overrides */
li ol,.q{margin:0}
pre a,.w a,pre a:hover{border:0}

/* Sidebars */

blockquote.callout h5:before {
  font-size: xx-large;
  content: '\21F0 \00a0 ';
}  
blockquote.tip p:first-child:before {
  font-size: xx-large;
  content: '\272A \00a0 ';
}  

blockquote.tip > ul > li {
  margin-top: 0px;
  margin-bottom: 0px;
  padding-top: 0px;
  padding-bottom: 0px;
}  
blockquote.tip > ul {
  margin-top: 0px;
  margin-bottom: 0px;
  padding-top: 0px;
  padding-bottom: 0px;
}  

blockquote.tip > p {
  margin-bottom: 0px;
  padding-bottom: 0px;
}  


/* headers and pullquotes */
h2,h3,h4,h5,h6,aside{font-family:"Book Antiqua",Palatino,Georgia,serif}
h2,h3,h4{font-variant:small-caps}
h2{letter-spacing:-1px}
h1 code{font-size:xx-large}
h2,h2 code{font-size:x-large}
h3,h3 code{font-size:large}
h4, h5, h6{font-size: medium}

dt.compact {
    margin: 0;
    padding-right: 1px;
    font-weight: bold;
    float:left;
    clear:left;
}
dd.compact {
    display:inline;
}
img {
  display: block;
  margin: 0 auto;
}  
h1 {
  text-align: center;
  font-family:"Book Antiqua",Palatino,Georgia,serif;
  font-variant:small-caps;
  letter-spacing:-1px;
  font-size:xx-large;
}
h2,h3,h4 {
  margin-top: 0;
  padding-top: 0;
}  
a {text-decoration:none;}
a:link {color: steelblue; border-bottom: 1px dotted;}
a:visited {color: darkorchid; border-bottom: 1px dotted; }
a:hover {color: steelblue; border-bottom:1px solid;}
table {
  margin-left: auto;
  margin-right: auto;
}  

/* Initially we hide footnotes. A JavaScript function is then run to render
 * them at the bottom of the page, replacing their previous location with a
 * link to their new location. Having done this, the JavaScript sets span.fn
 * _display_ to 'inline', thus avoiding the footnotes initially appearing in 
 * their original position prior to being moved. 
 *
 * This is imperfect because it hides footnotes from users with CSS enabled
 * and JS disabled, but it will do for now.
 */ 
span.fn {
	display: none;
}

span.fn a:link {
	vertical-align: super;
  color: black;
  font-weight: bold;
  font-size: 100%;
  padding-left: 1px;
  border: none;
}

#footnotes {
	border-top: 1px solid #ccc;
	margin: 20px 0 20px 0;
	padding: 10px 0 0 0;
}

#footnotes div.footnote {
	margin: 0 0 5px 0;
}

@media screen, handheld {
  html { margin: 1em; font: 14px "Gill Sans", "Gill Sans MT", "DejaVu Sans", sans-serif; }
  h1 { margin-bottom: 0.5em }
  div.frontcover, div.backcover, div.halftitlepage, div.titlepage, div.imprint, 
  div.dedication, div.foreword, div.toc, div.index { display: none }
}
/* previous/next navigation links */

.nav a{text-decoration:none;border:0;display:block}
.nav a:first-child{float:left}
.nav a:last-child{float:right}
/*.nav span{font-size:1000%;line-height:1;margin:0;text-shadow:gainsboro 3px 3px 3px} */
p {margin: 1em 0}
#disqus_thread {
	border-top: 1px solid #ccc;
	margin: 20px 0 20px 0;
	padding: 10px 0 0 0;
}
#formats a {
  text-size: larger;
  font-weight: bold;
}  
div.comments > h2 { text-align: center }
div.comments img { float: left; margin-right: 2%; border: none; }
div.comments article { display: block; clear: both; margin-left: 5%; }
div.comments article > p { border-left: 1px dashed black; padding-left: 1% }
div.comments > p:last-child { text-align: center }
