/*** setup ***/
body { font:12px/1.5 Verdana,sans-serif; background:#092e20; color: white;}
#bd { background:#487858; }
#doc { padding-top:16px; }

/*** links ***/
a img {border: none;}
a {text-decoration: none;}
a:hover { color:#ffe761; }
a:link, a:visited { color:#ffc757; }
h2 a, h3 a, h4 a { text-decoration:none !important; }
#bd a:hover { background-color:#E0FFB8; color:#234f32; text-decoration:none; }
#bd a:link, #bd a:visited { color:#ab5603; }

/*** nav ***/
div.nav { margin: 0; font-size: 11px; text-align: right; color: #487858;}
#hd div.nav { margin-top: -27px; }
#ft div.nav { margin-bottom: -18px; }

#hd h1 a { color: white; }

#global-nav { position:absolute; top:5px; padding:7px 0; color:#263E2B;}
#global-nav a:link, #global-nav a:visited {color:#487858;}
#global-nav a {padding:0 4px;}
#global-nav a.about {padding-left:0;}
#global-nav:hover {color:#fff;}
#global-nav:hover a:link, #global-nav:hover a:visited  { color:#ffc757; }


/*** content ***/
#chapter-body { position: relative; }
#yui-main div.yui-b { margin: 0 0 0 20px; background: white; color: black; padding: 0.3em 2em 1em 2em; }
dd { margin-left:15px; }
h1 { font-size:218%; margin-top:0.6em; margin-bottom:.4em; line-height:1.1em; }
h1,h2,h3,h4 { margin-top:1.4em; font-family:"Trebuchet MS",sans-serif; font-weight:normal; }
h2#chapter-title { font-size: 218%; line-height:1.2em; margin-bottom: 0.8em; }
h2#chapter-subtitle { font-size: 140%; margin-top:-1.2em !important; margin-bottom:1.6em; margin-left:.2em; color:#487858; }
h3 { font-size:150%; margin-bottom:.6em; line-height:1.2em; color:#092e20; }
h4 { font-size:125%; font-weight:bold; margin-bottom:.2em; color:#487858; }
h5 { font-size:1em; font-weight:bold; margin-top:1.5em; margin-bottom:3px; }
div.figure { text-align: center; }
div.figure p.caption { font-size:1em; margin-top:0; margin-bottom:1.5em; color: #555;}
hr { color:#ccc; background-color:#ccc; height:1px; border:0; }
p, ul, dl { margin-top:.6em; margin-bottom:1em; padding-bottom: 0.1em;}
#chapter-body img { max-width: 50em; margin-left: auto; margin-right: auto; display: block; }
table { color:#000; margin-bottom: 1em; width: 100%; }
table.docutils td p { margin-top:0; margin-bottom:.5em; }
table.docutils td, table.docutils th { border-bottom:1px solid #dfdfdf; padding:4px 2px;}
table.docutils thead th { border-bottom:2px solid #dfdfdf; text-align:left; font-weight: bold; white-space: nowrap; }
table.docutils thead th p { margin: 0; padding: 0; }
table.docutils { border-collapse:collapse; }
caption { font-size:1em; font-weight:bold; margin-top:0.5em; margin-bottom:0.5em; margin-left: 2px; text-align: center; }
blockquote { padding: 0 1em; margin: 1em 0; font:125%/1.2em "Trebuchet MS", sans-serif; color:#234f32; border-left:2px solid #94da3a; } 
strong { font-weight: bold; }
em { font-style: italic; }
ins { font-weight: bold; text-decoration: none; }

/*** one-off for chapter 7 ***/
#chapter-body #cn0 strong { font-size:150%; margin-bottom:.6em; line-height:1.2em; color:#092e20; }

/*** messages ***/
div.newer-version, div.message {color:#092e20; background: #FAFBD1 url(images/error.png) no-repeat 10px 50%; padding:3px 2px 5px 35px; font-size:13px; margin-top:1.5em;}

/*** lists ***/
ul { padding-left:30px; }
ol { padding-left:30px; }
ol.arabic { list-style-type: decimal; }
ul li { list-style-type:square; margin-bottom:.4em; }
ol li { margin-bottom: .4em; }
ul ul { padding-left:1.2em; }
ul ul ul { padding-left:1em; }
ul.linklist, ul.toc { padding-left:0; }
ul.toc ul { margin-left:.6em; }
ul.toc ul li { list-style-type:square; }
ul.toc ul ul li { list-style-type:disc; }
ul.linklist li, ul.toc li { list-style-type:none; }
dt { font-weight:bold; margin-top:.5em; font-size:1.1em; }
dd { margin-bottom:.8em; }
ol.toc { margin-bottom: 2em; }
ol.toc li { font-size:125%; padding: .5em; line-height:1.2em; clear: right; }
ol.toc li.b { background-color: #E0FFB8; }
ol.toc li a:hover { background-color: transparent !important; text-decoration: underline !important; }
ol.toc span.release-date { color:#487858; float: right; font-size: 85%; padding-right: .5em; }
ol.toc span.comment-count { font-size: 75%; color: #999; }
/*** code blocks ***/
.literal { white-space:nowrap; }
.literal, .literal-block { color:#234f32; }
.sidebar .literal { color:white; background:transparent; font-size:11px; }
h4 .literal { color: #234f32; font-size: 13px; }
pre, .literal-block { font-size:medium; background:#E0FFB8; border:1px solid #94da3a; border-width:1px 0; margin: 1em 0; padding: .3em .4em; overflow: hidden; }
dt .literal, table .literal { background:none; }

/*** notes & admonitions ***/
.note, .admonition { padding:.8em 1em .8em; margin: 1em 0; border:1px solid #94da3a; }
.admonition-title { font-weight:bold; margin-top:0 !important; margin-bottom:0 !important;}
.admonition .last { margin-bottom:0 !important; }
.admonition-philosophy { padding-left:65px; background:url(http://media.djangoproject.com/img/doc/icons/docicons-philosophy.gif) .8em .8em no-repeat;}
.note, .admonition { padding-left:65px; background:url(http://media.djangoproject.com/img/doc/icons/docicons-note.gif) .8em .8em no-repeat;}
.admonition-behind-the-scenes { padding-left:65px; background:url(http://media.djangoproject.com/img/doc/icons/docicons-behindscenes.gif) .8em .8em no-repeat;}

/*** comment stuff ***/
.cn { position: relative; }
#comments { padding: 0; border: 1px #092e20 solid; left: 300; top:0; position: absolute;  z-index: 10; background-color: #E0FFB8; width: 600px; height: 400px; color: black; overflow: hidden; display: none; text-align: left; }
#comment-tabs { padding: 6px; }
#comments .ft { height:50px; overflow:hidden; padding: 6px; }
#comments .tabset .hd li a { background-color: #487858; color:white; }
#comments .tabset .hd li.on em { color: #092e20; }
#comments .yui-ext-tabbody { font-size: 90%; background-color: white; border: 1px #999 solid; border-top: none; height: 285px; overflow: auto; padding: 1em; }
#comments div.tab input { width: 100%; }
#comments div.tab input#id_name { width: 70%; }
#comments div.tab input#id_remember_me { width: auto; }
#comments div.tab label { font-weight: bold; display: block; color: #487858; }
#comments div.tab textarea { width: 100%; height: 100px; }
#comments div.tab p { margin-bottom: 0; }
#comments div.tab span.actions { float: right; margin-top: -15px; }
#comments div.tab span.thanks { color: black; font-weight: bold; color: #F7C754; position: relative;}
#comments-close { margin-left:5px;margin-right:15px; }
#comments-head .close { position: absolute; top: 3px; right: 4px; height: 13px; width: 17px; margin:0; padding: 0; overflow: hidden; text-indent:-999px; background: url(images/close.png) no-repeat top left;}
#comments-head { background-color: #487858; color: white; padding: 2px 4px; font-weight: bold; margin: 0 0 6px 0; position: relative;}
#comments-message { font-size: 90%; padding-left: 20px; float:left; clear:none; width:270px; }
#comments-message.loading { background: url(images/loading.gif) no-repeat center left; }
#comments-message.error { background: url(images/error.png) no-repeat center left; color: red; font-weight: bold; }
#comments-submit-wrapper { float:right; clear:none;white-space:nowrap; width: 150px; text-align: right;}
#comments-submit-wrapper input { font-size: 11px; }
#highlight-floater { position: absolute; z-index: 5; background: #487858; top:0; left:0; width:100%; height: 10px; visibility: hidden; border-top: 1px black solid; border-bottom: 1px black solid; border-left: 20px black solid;}

/*** comment box resizer ***/
#comments .yresizable-handle-east { background-image: url(yui-ext/images/sizer/e-handle-dark.gif); border: 0px; }
#comments .yresizable-handle-south { background-image: url(yui-ext/images/sizer/s-handle-dark.gif); border: 0px; }
#comments .yresizable-handle-southeast { background-image: url(yui-ext/images/sizer/se-handle-dark.gif); border: 0px; }

/*** comment list tab ***/
#comment-tabs div.tab ol { padding: 0; margin: 0; font-size: 90%; }
#comment-tabs div.tab dl { margin-bottom: 0; }
#comment-tabs div.tab li { border-bottom: 1px #E0FFB8 solid; }
#comment-tabs div.tab li span.meta { font-weight:normal; color: #487858; font-size: 90%; }
#comment-tabs div.tab a:hover { background-color:#E0FFB8; color:#234f32; text-decoration:none; }
#comment-tabs div.tab a:link, #comment-tabs div.tab a:visited { color:#ab5603; }

/*** comment indicator ***/
div.comment-indicator { position: absolute; width: 20px; z-index: 999; text-align: center; color: black; font-size: 11px; left: -44px; top: 0; }
li.cn div.comment-indicator { left: -74px; }
div.admonition div.comment-indicator { left: -45px; }
blockquote div.comment-indicator { left: -46px; }
ul ul li.cn div.comment-indicator { left: -88px; }
div.comment-indicator:hover { background-color: #406b4e; }
div.comment-indicator span { position: absolute; top: -10px; left: -10px; width: 25px; height: 25px; }
div.comment-indicator:hover span { background-image: url(images/comment-hover.png); }
div.has-comments > span, div.has-comments:hover > span { background-image: url(images/comment-active.png); }

/*** help tab ***/
#comment-tabs-help h4 { margin-top: 0; }
#comment-tabs-help p.image { text-align: center; }
#comment-tabs-help img { padding: 4px; border: 1px #999 solid; }

/*** forms ***/
#chapter-body form label { display: block; font-weight: bold; margin-top: 1.5em; margin-bottom: 0;}
#chapter-body form label span { font-weight: normal; color: #555; }
#chapter-body form input, #chapter-body form textarea, #chapter-body form select { width: 100%; padding: 1px; }
#chapter-body form p { margin: 0; }
#chapter-body form p.submit { text-align: right; }
#chapter-body form p.submit input { width: 10em; font-size: 1.5em; }
#chapter-body form p.errors { margin: 0; padding: 0; font-weight: bold; color: red; }

/*** errata pages ***/
div.errata p.reported-by { font-size: 90%; color: #555; }
div.errata p { margin-bottom: 0; }
div.errata { border-bottom:1px solid #dfdfdf; padding-bottom: 0.5em; }
div.last { border-bottom: 0px none; }
#chapter-title span { font-size: 70%; }

/*** footer ***/
#ft { color:#487858; font-size:90%; padding-bottom: 2em; }

/*** IE hacks ***/
* pre { width: 100%; }
* div.has-comments span { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src="http://media.djangobook.com/images/comment-active.png", sizingMethod="scale"); }
* #comments div.tab input { width: 95%; }

#adsense_right
{
    position: absolute;
    right: 58px; 
    top: 1.0in;
    width: 160px;
    z-index: 2;
}
#adsense_right1
{
    position: absolute;
    right: 58px; 
    top: 45.0in;
    width: 160px;
    z-index: 2;
}