* {
   box-sizing: border-box;
}

@font-face {
  font-family: 'Macha';
  font-style: normal;
  font-weight: 400;
  src: local('Macha Book'),
		  local('Macha-Book'),
		  url('/fonts/macha-bk.woff2') format('woff2'),
		  url('/fonts/macha-bk.woff') format('woff'),
		  url('/fonts/Macha-Bk.otf') format('opentype');
  text-rendering: optimizeLegibility;
}

body {
   font: 18px/26px Macha, Lato, Georgia, Helvetica, Helvetica Neue, Arial;
   font-style: normal;
   font-variant: normal;
   font-weight: 400;
   line-height: 1.5em;

   background-color: #fafafa;
}

/* Images and figures. Because of broken Squarespace export, some of our images are within figure sections, but some are
just dropped into articles, wrapped in <a> elements. So we need to have styles for both kinds. */

img {
   max-width: 100%;
}

h1,h2,h3,h4,h5,h6 {
   line-height: 1.4em;
   /*font-style: normal;*/
   /*font-weight: 400;*/
   /*color: #0093AE;*/
   color: #007C9B;
   /* lighter: #0093AE darker: #007C9B */
   /* lighter: #FCFCFC darker: #D8DEE3 */
}

h1+h2 {
   padding-top: 2em;
}

header > div.title {
   font-weight: bold;
   font-size: 1.4em;
   margin: 0;
}

div.header-container {
   background-color: rgb(47, 53, 63);
   color: #FCFCFC;
   padding-top: 0.5em;
   padding-bottom: 0.5em;
}

header {
/*   border-bottom: solid 1px #ccc;*/
   width: 100%;
   padding-left: 2em;
   padding-right: 2em;
   display: flex;
   justify-content: space-between;
   align-items: center;
   color: #D8DEE3;
}

header a, header a:visited {
   text-decoration: none;
   color: #D8DEE3;
}

header a:hover {
   text-decoration: none;
   color: #FCFCFC;
}

header nav {
   text-transform: uppercase;
   font-weight: bold;
}


header nav ul {
   display: flex;
   justify-content: space-between;
   align-items: center;
}

header nav ul li {
   padding-left: 1em;
   padding-right: 1em;
   margin-bottom: 0;
}


h1.tagline {
   font-size: 2.2em;
   text-align: center;
   padding-top: 1.4em;
   margin-bottom: 0;
}

h2.tagline {
   text-transform: uppercase;
   font-variant: small-caps;
   font-size: 1.3em;
   text-align: center;
   margin-top: 0;
   padding-top: 0;
   padding-bottom: 3.5em;
   color: #222;
}


a, a:visited {
   color: #007C9B;
}

a:hover {
   color: #0093AE;
}

/* This image CSS juggling is necessary, because some images are in <figure>, and some are just placed inside articles. */
article img {
   width: 45%;
   float: right;
   clear: right;
   margin: 1em;
   margin-bottom: 2em;
}

article figure img {
   width: auto;
   float: none;
   margin: 0;
}

article figure {
   width: 45%;
   float: right;
   clear: right;
   margin: 1em;
   margin-bottom: 2em;
}

article figure.fullwidth {
   width: auto;
   float: none;
   clear: both;
   margin-left: 0;
   margin-right: 0;
}

figcaption {
   font-size: 0.8em;
   clear: both;
   line-height: 1.4em;
   margin-top: 0.4em;
}

footer {
   clear: both;
   text-align: center;
   font-size: 0.8em;
}

code {
   font-size: 0.9rem;
   /* color: #c02050; */
   background-color: #ececec;
   /*     border: 1px solid #e8e8e8;*/
   border-radius: 3px;
}

pre {
   font-family: monospace;
   white-space: pre-wrap;
   word-wrap: break-word;
   background: #ececec;
   margin-left: 1em;
   line-height: 1.2rem;
   background-color: #ececec;
}

pre code {
   color: #202020;
}

.main aside {
   padding: 0.2em;
}

article h1 {
   margin-top: 1.3em;
   margin-bottom: 1.3em;
}

article h2 {
   margin-top: 1.3em;
}

aside ul {
   list-style-type: none;
   padding: 0;
}

aside li {
   margin-bottom: 0.8em;
   line-height: 1.4em;
}

aside h4 {
   margin-top: 3.4em;
}

span.date {
   font-size: 0.8em;
   color: #aaa;
}

p.date {
   margin-top: 0;
}

li {
   margin-bottom: 0.4em;
}

section.blog-index > article {
   clear: both;
   margin-bottom: 4em;
}

section.blog-index > article h1 {
   margin-bottom: 0;
}

section.blog-index > article h1 a {
   text-decoration: none;
}

section.blog-index > article h1 a:hover {
   text-decoration: underline;
}

p.archive-link {
   float: right;
   clear: both;
}

.blog-archive h2 {
   margin: 0;
}

.blog-archive h2 + hr {
   margin-top: 0;
}

.blog-archive h1 {
   margin-top: 1.3em;
   margin-bottom: 1.3em;
}

div.comment {
   font-size:0.9em;
   line-height: 1.3em;
   margin-bottom: 2.5em;
   border-left: 1px solid gray;
   padding-left: 1em;
}

div.comment > p {
   word-break: break-all;
}

div.comment > span.comment.date {
   float: right;
}

.clearing {
   clear: both;
}

hr.clearing {
   margin-top: 10em;
}

i.icon {
   display: inline-block;
   width: 1em;
}

i.icon svg {
  max-width: 100%;
  max-height: 100%;
  height: 1em;
}

i.icon svg path {
  /* see https://css-tricks.com/cascading-svg-fill-color/ */
  fill: currentColor;
}

div.contact {
   display: flex;
   justify-content: space-between;
}

ul.contact {
   padding-left: 1em;
}

ul.contact li {
   list-style-type: none;
   margin: 0;
}

div.partsbox-logo {
   display: inline-block;
}

div.partsbox-logo svg {
  max-width: 100%;
  max-height: 100%;
}
