
html{overflow-y:scroll;} /*  always have scroll bar */

/* ============== Basics ============== */
body {
	font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
	font-size:1em;
	line-height:1.4;
}
/*
p,pre,dd {
	margin:1.4em 0; /* this should match line-height for "rhythm" on page. */
}  */
dd p {
	margin-top: 0; /* fix float problem */
}
h1, h2, h3, h4, h5, h6, .serif { /* word-spacing: 0.1em; if bold  */
	font-family: Georgia, Times, "Times New Roman", serif;
}
main h1{font-size:1.7em;margin:0;} /* margin:0.82em 0;  */ /* h1 is flush at top of container */
h2{font-size:1.3em;margin:1.07em 0 0;} /* margin:1.07em 0; */
h3{font-size:1.1em;margin:1.27em 0 0;} /* margin:1.27em 0; */
h4{font-size:1em;margin:1.4em 0 0;} /* margin:1.4em 0; */
h5{font-size:0.83em;margin:1.68em 0 0;} /* margin:1.68em 0; */
h6{font-size:0.67em;margin:2.09em 0 0;} /* margin:2.09em 0; */
menu,ol,ul{padding:0 0 0 2.5em;} /* 40px divided by 16 */
abbr {letter-spacing: 0.1em;}

/* for two levels of nested quotations */
q {quotes: '“' '”' '‘' '’';}
 /* extra content definitions for pre-2011 WebKit */
q:before {content: '“'; content: open-quote;}
q:after {content: '”'; content: close-quote;}
q q:before {content: '‘'; content: open-quote;}
q q:after {content: '’'; content: close-quote;}
  /* q in blockquote */
blockquote q:before {content: '‘'; content: open-quote;}
blockquote q:after {content: '’'; content: close-quote;}
blockquote q q:before {content: '“'; content: open-quote;}
blockquote q q:after {content: '”'; content: close-quote;}
  /* blockquote hanging opening quote */
blockquote:before {display: block; height: 0; content: "“"; margin-left: -.6em; font: italic 400%/1 Cochin,Georgia,"Times New Roman",serif; color: #999;} /*original had margin-left: -.95em; */

/* ============== Primary LAYOUT ============== */
/* box for layout elements -- can use padding and borders.
Remember MARGINS are OUTSIDE the box width */
#site, 
main nav, 
#gallery, 
#core, 
main aside,
body footer ul.utility,
body footer ul.utility li a {
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
}
img { 
  box-sizing: content-box;
	max-width: 100%; /* images will shrink to fit their container width 
	(but border and padding are included in this width)
	, but will not get bigger than their full size */
  height: auto !important;
}
#site {
  position: relative;
  margin: 0 auto;
  max-width: 1000px;
}
main {
	padding: 0 2% 2%; 
}
/* top margin (padding) controlled by #breadcrumb above */

main #core  {
	width: 100%;
	position: relative;
}

main aside {

} 
main footer {
	border-top: 1px solid #bbb;
}

/* ============== banner Header, primary Nav, breadcrumbs ============== */
#breadcrumb {
	padding: 0.5em 2% 1em;
	font-size: 0.8em; /* 0.9em  */
}
#banner { 
	position: relative;
}
#banner form {
	padding: 0.6em;
}
#banner input[type="search"] {
	width: 12em; 
}
#banner h1 {
	margin: 0;
 	padding: 0 0 0.2em 0.5em;
	line-height: 1.2;
}
nav#primary {
	font-size: 0.9em;
	letter-spacing: 0.1em;
	border: 1px solid #bbb; /* bottom border and right increased 1 px from li */
}
nav#primary ul {
	line-height: 2; 
	margin: 0;
	padding: 0;
  display: flex;
  flex-flow: row wrap;
}
nav#primary li {
  flex: auto; /* distributes extra space inside of items, makes it look okay when responsive */
	border: 0 solid #bbb;
	border-right-width: 1px;
	border-bottom-width: 1px;
}

nav#primary a  {
	display: block; /* need this for the line-height to take effect, also they fill the LI item space */
	padding: 0 1em;
}
nav#primary .home a {
  padding-right: 1.5em; /* previously was = width: 21px; */
}

/* ============== MAIN HEADER ============== */

main header {
	line-height:1.2;
}
/* inline-block elements do not have their adjacent margins collapse */
#gallery {
	margin: 0;
/* 	margin-right: -3%; subtract the margin from parent Header */
  display: flex;
  flex-flow: row wrap;
}
#gallery img {
	display: block;
	/* max-width: 98%; images with margin-right of 2% will not push out of their narrow container. */
	height: auto !important;
	margin: 0 1.5% 1em 0;
}
#gallery > :last-child {
    margin-right: 0;
}

#taxon main  header h1 {
	font-size: 1.6em; /* a bit smaller for taxon names */
	line-height: 0.93em; /* a bit closer  */
}
#taxon main  header h2 {
	font-size: 1.2em; /* a bit smaller for synonyms */
	line-height: 0.93em; /* a bit closer  */
}
h1 span.author {
    font-size: 0.8em;
}


/* ============== MAIN NAV (secondary navigation left column) ============== */
main nav {
	margin: 0.3em 0 0 0;
	/* max-width: 16em; otherwise anchors stretch across entire width */
}
main nav ul {
	margin: 0;
	padding: 0;
}
main nav li {
padding-left: 5px;
}
main nav li.guide {
/* padding-left: 10px; */
padding-left: 0;
}
main nav li.guide a {
font-weight:700;
padding-left: 15px;
border: solid #bbb;
border-width: 1px 0 1px 0;
background: #eee;
}
main nav li.guide,
main nav li.depth-1 {
	border-right: 1px solid #bbb;
}
main nav li.depth-1 a {
font-weight:700;
}
main nav li.depth-2 a {
font-weight:500;
}
main nav li.hasChildren {
background-image:url(arrow.gif);
background-position:3px 12px;  /* 6px 11px */
background-repeat:no-repeat;
background-size:6px 9px;
}
main nav li.isOpen {
background-image:url(arrowdn.gif);
background-position:1px 14px;  /* 4px 14px */
background-repeat:no-repeat;
background-size:9px 6px;
}
main nav li a,
main nav li span {
display:block;
padding:5px 5px 5px 10px;
}

main nav .isActive {
	color: #222;
	border-bottom: 3px solid #bbb; /* ACA97C */
}


/* ============== MAIN CONTENT ============== */


li.current .genus, 
li.current .epithet {
	font-size: 1.1em;
}

.page-author {
  font-size: 90%;
}
.gonext {
  
}

/* ============== MAIN ASIDE ============== */

/* aside {max-width: 200px;} see media queries*/

aside img.map{
	margin-bottom: 1em;
}


/* ============== page Footer ============== */
#pagefoot {
	margin: 0 2% 0 3%;
	font-size: 0.9em;
}
footer ul.utility {
  list-style: none;
	border: 1px solid #bbb; /* bottom border and right increased 1 px from li */
	line-height: 2;
	margin: 1% 0 3% 0;
	padding: 0;
  display: flex;
  flex-flow: row wrap;
}
footer ul.utility li {
  flex: auto; /* distributes extra space inside of items, makes it look okay when responsive */
	border: 0 solid #bbb;
	border-right-width: 1px;
	border-bottom-width: 1px;
}  
footer ul.utility a  {
	display: block;
	padding: 0 1em;
}


.back-to-top {
	position: fixed;
	bottom: 2em;
	right: 0px;
	text-decoration: none;
	color: #000;
	background: #eee;/*fallback, IE8 etc*/
	background-color: rgba(235, 235, 235, 0.60);
	font-size: 0.8em;
	padding: 1em;
	display: none;
}
.back-to-top:hover { 
	background: #ddd;/*fallback, IE8 etc*/
	background-color: rgba(215, 215, 215, 0.80);
}


/* ============== Specific page styles ============== */

/* Taxon page - Definition lists */

#taxon dl {
	margin: 0.5em 0; /* normalize.css = 1em 0  */
}
#taxon dt {
  font-weight: bold;
	display: block;
	color: #333;
	padding: 0 0.6em 0 0;
	margin: 0;
}
#taxon dd {
	display: block;
	margin: 0 0 0.5em 1em;
	padding: 0;
}
#taxon dd p {
/*	margin: 0;  */
}
#taxon ul.synonyms {
	list-style-type: none;
	margin: 0;
	padding: 0;
}
#taxon ul.synonyms ul {
	padding-left: 3%;
}

/* Sitemap */
#sitemap ul{list-style-type:disc;} /* Kingdom */
#sitemap ul ul{list-style-type:circle;margin-bottom:0px;} /* Phylum */
#sitemap ul ul ul{list-style-type:square;margin-bottom:0px;} /* Class */
#sitemap ul ul ul ul{list-style-type:disc;margin-bottom:0px;} /* Order */
#sitemap ul ul ul ul ul{list-style-type:circle;margin-bottom:0px;} /* Family */
#sitemap ul ul ul ul ul ul{list-style-type:square;margin-bottom:0px;} /* Genus */
#sitemap ul ul ul ul ul ul ul{list-style-type:decimal-leading-zero;margin-bottom:0px;} /* Species */
/*
ol ol{list-style-type:lower-alpha;margin-bottom:0px;}
ol ol ol{list-style-type:lower-roman;margin-bottom:0px;}
 */



/* ============== Media queries ==============  */
/* 
http://css-tricks.com/why-ems/
http://blog.cloudfour.com/the-ems-have-it-proportional-media-queries-ftw/
 */

@media screen and (max-width: 640px) { /* NOTE = a MAX-width */
/* from Kirby site -- test this, Rocky says text size is perfect on his phone */
  html { font-size: 90%; }
	footer .pagecite { display: none; visibility: hidden; }
}

@media only screen and (max-width: 484px) {
  .back-to-top {bottom:1em;font-size:0.7em;}
}

/* ========= Mobile FIRST======== */

/* phone styles [no @media rule] */

/*  code may change if this actual image changes size  */
aside img.chicago{
	max-width: 320px;  /* 22em; about 317px */
  width: 100%; /* height is automatic */
}


@media screen and (min-width: 485px) {
/* start of medium tablet styles - and larger devices */
  #banner {
    display: flex;
    flex-flow: row wrap;
    justify-content: space-between;
  }
  #banner form {
    
	}
	#banner h1 {
    order: -1;
    padding: 0.2em 0 0.2em 1.5em;
  }
  #gallery img {
    width: 48%;
  }
}

@media screen and (min-width: 770px) {
/* start of large tablet styles - and larger devices */

  #gallery img {
    width: 32%;
  }


  #gallery {
    grid-area: gallery;
  }
  #mainhead {
    grid-area: header;
    text-align: center;
  }
  #core {
    grid-area: section;
  }
  #mainaside {
    grid-area: aside;
  }
  #mainfoot {
    grid-area: footer;
  }
  #mainnav {
    grid-area: nav;
  }

  main {
    display: grid;
    grid-template-columns: 220px auto;
    grid-template-rows: auto;
    grid-template-areas: 
      "gallery gallery"
      "header header"
      "nav section"
      "aside aside"
      "footer footer";
    grid-column-gap: 20px;
    grid-row-gap: 10px;
  }

}


@media screen and (min-width: 900px) {/* adjust this to where Grid 3 columns starts working */
/* start of desktop styles == 992px */

  #mainhead {
    text-align: left;
  }
  
    main {
      display: grid;
      grid-template-columns: 220px auto 200px;
      grid-template-rows: auto;
      grid-template-areas: 
        "gallery gallery gallery"
        "nav header header"
        "nav section aside"
        "nav footer aside";
      grid-column-gap: 20px;
      grid-row-gap: 10px;
    }
    aside.maps img {
      display: block;
      margin-left: auto;
      margin-right: auto;
    }

}



/* Run these MAX-width in this descending order */
@media screen and (max-width: 55em) { /* 880px - this width depends on content length in menu
  nav#primary li,
  body footer ul.utility li {
	border-bottom-width: 1px;
  }
} */


