/* This stylesheet implements some common typographic conventions used
 * in ordinary prose, particularly novels and short stories. These
 * conventions are equally applicable to web, electronic book, and
 * printed material. It should always be the first stylesheet loaded
 * so these can be overridden by later styles for a particular
 * situation.
 * 
 * Some of these duplicate browser defaults but give hooks
 * for the publication designer to decide otherwise. The author should
 * specify what things are and let the publications designer decide
 * how they should look.
 * 
 * Font faces and page design for printed matter are covered in
 * other stylesheets.
 */

body { font-family: bodytextfont, serif;
       font-style:  normal;
       max-width: 40em;
       padding-left: 2%;
       padding-right: 2%;
}
       
@media only screen and (min-width: 600px) and (max-width: 1000px) {
    body {
        padding-left: 10%;
        padding-right: 10%;
    }
}

@media only screen and (min-width: 1000px) {
    body {
        padding-left: 25%;
        padding-right: 25%;
    }
}
    
/* Center the main text block on the display and set a reasonable 
 * maximum width. Align titles to the text block.
 */ 

p {  text-align: justify; }
   
/*h1 { max-width: 40em; }*/

/* Italics are the default way of denoting emphasis, but emphasis
 * can be done in a myriad of ways other than italics (e.g. small-caps,
 * different letter spacing, a sans-serif font in serif text, a change
 * in font size, and many other ways).
 */
em { font-family: emphasisfont, bodytextfont, serif;
     font-style:  italic; }
     
/* Convention requires things like ship/aircraft names, words or short
 * phrases in another language, book/magazine titles &c. to always be 
 * set in italics regardless of what method is used for emphasis
 */

/* "Alternate voice" such as a person's thoughts, narrator's interjection,
 * or something like that */
.altvoice { font-family: altvoicefont, bodytextfont, serif;
            font-style: italic; }
/* Vessel/aircraft names */
.vesname { font-family: vesnamefont, bodytextfont, serif;
           font-style: italic; }
/* Alternate language. e.g. novel is in English but a character
 * greets someone in French.
 */
.altlang { font-family: altlangfont, bodytextfont, serif;
           font-style: italic; }
/* Publication title. Book, magazine, newspaper, etc.
 */
.pubtitle { font-family: pubtitlefont, bodytextfont, serif;
            font-style: italic; }

           
/* An epigraph is a very short passage, quote, or excerpt from a poem
   which provides context or sets the mood. A common use is at the
   beginning of a chapter. Though there are many ways of styling an
   epigraph, a common styling is to use a right-aligned paragraph, less
   than full width, with padding above and below. This is a default
   setup.
*/

.epigraph {
    text-align: right;
    font-family: bodytextfont, serif;
    font-size: smaller;
    font-style: italic;
    padding-top: 3em;
    padding-bottom: 3em;
    margin-left: 30%;
    margin-right: 5%;
}
   
/* Indent only paragraphs which follow other paragraphs. */
p { margin-bottom: 0;}
p + p { text-indent: 1.0em;
        margin-top: 0 }
/* However, sometimes we want a paragraph to stand out on its own
 * to suggest surprise or for some other reason. The following paragraph,
 * then should have no indent. */
p.standout {
    text-indent: 0.0em;
    margin-top: 1.0em;
    margin-bottom: 1.0em; }
p.standout + p { 
    text-indent: 0.0em;
    margin-bottom: 0.0em; }
  
/* Ensure first paragraph after headers, thematic breaks, etc.
   are NOT indented and have a little extra space above them.
   This might be redundant to above but it can't hurt. */
h1 + p, h2 + p, div + p { margin-top: 1.0em;
                          text-indent: 0.0em }
  
/* Don't indent captions. */
p.caption {text-indent: 0}

/* Thematic breaks (by spacing or inserted image). */

.thematicbreak { text-indent: 0;
                 text-align: center;
                 margin-top: 1em; }

/* dialogue is something spoken by a character or characters
   and displayed in a block style, not inline. 
   The paragraphs (lines) are given extra space between them
   and every paragraph is enclosed in quotation marks.
*/
div.dialogue > p { margin-top: 1.5em;
                   margin-left: 3.0em;
                   margin-right: 6.0em;
                   margin-bottom: 1.5em;
                   text-indent: -0.5em;
                   }

div.dialogue p::before { content: open-quote; }
div.dialogue p::after { content: close-quote; }

/* Note: for European-style designation of dialogue,
   replace open-quote with "\2015 " and don't use the 
   p::after at all. \2015 is a "long dash" or "quotation
   dash" "but some fonts do not make that character any
   different from an em-dash which is \2014 and might not
   have a character for that value at all. In that case, 
   use the em-dash.
*/


/* A monologue is something spoken by a single character
 * but is long enough to require multiple paragraphs.
 */
div.monologue { margin-left: 3.0em;
                margin-right: 6.0em;
                text-indent: 1.5em;
                margin-top: 0em;
                }
div.monologue > p:first-child {margin-top: 1.5em;
                             text-indent: -0.5em; }
/* We have to cheat a bit here and force the use of open quote
   and close quote characters to get around user-agent behavior.
   This is for "AP Stylebook" styling wherein every paragraph
   in an extended quotation/monologue begins with a quotation
   mark and only the final paragraph has a closing quotation
   mark. For alternate styling where only the first paragraph
   begins with a quotation mark and only the final paragraph
   ends ith a quotation mark, use the second form below.
*/
div.monologue p::before { content: "\201c"; }
div.monologue p:last-child::after { content: "\201d"; }

/* div.monologue p:first-child::before { content: open-quote; }
   div.monologue p:last-child::after { content: close-quote; }
*/

