/* global styles */
* {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
}
body {
  background-color: #fcfcfc;
  line-height: 1.5em;
}
/* notification */
.notifications {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 1000;
  margin-top: 1em;
}
.notification.error {
  background-color: #555555;
  color: white;
  margin: 1em;
  margin-top: 0;
  padding: 1em;
}
/* admin overlay and edit header */
.admin-header {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
}
.admin-header,
.edit .toolbar {
  line-height: 1em;
  padding: .5em;
}
.admin-header,
.edit .toolbar {
  /* Force a fixed height, which is what is *should* be but in case it
       gets out of sync. 1em + .5em +.5em = 16 + 8 + 8 = 32 */
  /* height: 32px; */
}
.admin-header a,
.edit .toolbar a {
  margin-right: 1em;
}
.admin-header a:nth-of-type(1),
.edit .toolbar a:nth-of-type(1) {
  margin-left: 1em;
}
.link-underline-none {
  background-image: none;
}
.link-underline {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
.figure-label {
  text-align: center;
  font-size: .9em;
  line-height: 1.5em;
  font-style: italic;
  width: 500px;
  margin: 0 auto;
}
.bare-link {
  background-image: none;
}
.bare-link:hover {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
/* variables */
.sansserifFace {
  font-family: "adelle-sans", sans-serif;
}
.serifFace {
  font-family: palatino, georgia, serif;
}
/* mixins */
.page-width {
  width: 700px;
  margin: 0 auto;
}
@media screen and (max-width: 900px) {
  .page-width {
    width: auto;
    margin-left: 1em;
    margin-right: 1em;
  }
}
/* global styles */
body {
  font-family: "adelle-sans", sans-serif;
  font-size: 20px;
  background-color: white;
  color: #393939;
  line-height: 1.5em;
}
main {
  /* We want to do special things with images going off the page, but
       never show horizontal scrollbars */
  overflow-x: hidden;
}
.main-wrapper,
.footer-wrapper {
  width: 700px;
  margin: 0 auto;
}
.main-wrapper {
  margin-top: 4em;
  margin-bottom: 4em;
}
.post h1 {
  margin-bottom: 6px;
}
.post .date {
  font-size: 16px;
  font-family: "adelle-sans", sans-serif;
}
.list.post-list {
  margin-top: 1.5em;
}
.list.post-list li {
  margin: .5em 0;
  line-height: 1em;
}
.list.post-list a {
  background-image: none;
}
.list.post-list a:hover {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
.list.post-list .date {
  color: #9a9a9a;
  font-size: 16px;
  font-family: "adelle-sans", sans-serif;
}
.additional-footer {
  border-top: 1px solid #f0f0f0;
}
.additional-footer-inner-ugh {
  width: 700px;
  margin: 0 auto;
}
@media screen and (max-width: 900px) {
  .additional-footer-inner-ugh {
    width: auto;
    margin-left: 1em;
    margin-right: 1em;
  }
}
/* code highlighting */
pre code.hljs {
  font-family: monaco, "courier new";
  font-size: 16px;
  border-radius: 6px;
  overflow: auto;
  padding: 1em 1.5em;
  line-height: 1.3em;
  margin: 0;
}
pre {
  overflow: auto;
  border: 0;
  padding: 0;
}
code {
  font-size: .9em;
  white-space: nowrap;
}
pre {
  font-size: 16px;
  margin: 0;
}
pre code {
  color: #93a1a1;
  background-color: #f6f8fa !important;
  white-space: pre;
  font-size: 1em;
}
pre code .quoted {
  color: #586e75;
}
/* base element styles */
h1,
h2,
h3,
h4 {
  font-family: "adelle-sans", sans-serif;
  font-weight: bold;
  color: #464646;
}
h1 a,
h2 a,
h3 a,
h4 a {
  color: #464646;
}
h1 {
  font-size: 33px;
  line-height: 1em;
}
h2 {
  font-size: 27px;
  line-height: 1em;
}
h3 {
  font-size: 23px;
  line-height: 1em;
}
h4 {
  font-size: 20px;
  line-height: 1em;
}
a,
a:active {
  color: #393939;
  text-decoration: none;
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
h1 a,
h2 a,
h3 a,
h4 a {
  background-image: none;
}
h1 a:hover,
h2 a:hover,
h3 a:hover,
h4 a:hover {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
p {
  margin: 1em 0;
}
button {
  font-size: 18px;
}
/* generic styles */
.light {
  color: white;
}
.light a,
.light a:active {
  color: white;
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
.right-link {
  text-align: right;
}
.right-link a::after {
  content: " \2192";
}
/* admin customizations */
.admin-header,
.edit .toolbar {
  background-color: #66bb6a;
  color: white;
  font-size: 16px;
  font-family: "adelle-sans", sans-serif;
}
.admin-header a,
.edit a {
  color: #ffffff;
}
.edit-main a {
  background-image: none;
}
/* header */
header .links {
  overflow: hidden;
  float: left;
}
header {
  border-bottom: 1px solid #f0f0f0;
  overflow: hidden;
}
header ul {
  list-style: none;
  padding: 0;
  margin: .35em 0;
  overflow: hidden;
}
header ul li {
  margin: 0;
  float: left;
  margin-right: 1em;
}
header .links,
header .search {
  text-transform: uppercase;
  font-size: .75em;
  font-family: "adelle-sans", sans-serif;
  vertical-align: middle;
}
header .links a {
  transition: color .25s;
  background-image: none;
}
header .links a:hover {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
  color: #fb8c00;
}
header.collapse .header-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}
header.collapse,
header.collapse .links a {
  color: white;
}
header.collapse .links a:hover {
  color: #ffb74d;
}
header a.home {
  float: left;
  display: block;
  width: 40px;
  margin-left: .5em;
  margin-top: .25em;
  font-weight: bold;
  text-align: center;
  font-size: 1.35em;
  font-family: palatino, georgia, serif;
  background-image: none;
}
header a.home:hover {
  background-image: none;
}
.has-bg-image header {
  border: 0;
}
/* footer */
footer {
  border-top: 1px solid #f0f0f0;
}
footer .footer-text {
  font-family: "adelle-sans", sans-serif;
  font-size: 16px;
  color: #9a9a9a;
  text-align: center;
}
footer .footer-text a {
  color: #747474;
}
/* responsive */
@media screen and (max-width: 900px) {
  .main-wrapper,
  .footer-wrapper {
    width: auto;
    margin: 2em 1em;
  }
  .post-page .header-text.has-bg-image {
    /* Offset the standard margin. */
    /* WTF why do I need !important ??? */
    margin-top: -2em !important;
  }
}
@media screen and (max-width: 500px) {
  .main-wrapper,
  .footer-wrapper {
    margin: 1em;
  }
  .post-page .header-text.has-bg-image {
    margin-top: -1em !important;
  }
}
.post-list {
  margin-top: 4em;
}
.post-list > div {
  margin: 3em 0;
}
/* index page */
.index .intro {
  background: url(/img/intro-bg.png);
  padding: 1px;
  font-family: "adelle-sans", sans-serif;
  font-size: 1.1em;
}
.index .intro > div {
  width: 700px;
  margin: 0 auto;
  margin-top: 250px;
  margin-bottom: 1em;
}
@media screen and (max-width: 900px) {
  .index .intro > div {
    width: auto;
    margin-left: 1em;
    margin-right: 1em;
  }
}
@media screen and (max-width: 500px) {
  .index .intro > div {
    margin-top: 100px;
  }
}
.index .static-content,
.index .posts {
  width: 700px;
  margin: 0 auto;
}
@media screen and (max-width: 900px) {
  .index .static-content,
  .index .posts {
    width: auto;
    margin-left: 1em;
    margin-right: 1em;
  }
}
.index section {
  margin-top: 4em;
}
.index .attribute {
  color: #9a9a9a;
  font-size: 16px;
  padding: 1em 0;
  text-align: center;
  font-family: "adelle-sans", sans-serif;
}
.index .attribute a {
  color: #747474;
}
.index ul.demos {
  list-style: none;
  text-align: center;
  overflow: hidden;
  padding: 0;
  margin-bottom: 4em;
}
.index ul.demos li {
  float: left;
  overflow: hidden;
  margin-right: 1.5em;
}
.index ul.demos a {
  position: relative;
  display: block;
  width: 192px;
  height: 120px;
  color: white;
  background-image: none;
  margin: 0;
  padding: 0;
}
.index ul.demos a img {
  position: absolute;
  top: 0;
  left: 0;
}
.index ul.demos a p {
  margin: 0;
  width: 192px;
  height: 120px;
  position: absolute;
  top: 0;
  left: 0;
  transition: opacity .45s;
  padding: .5em;
  background-color: rgba(0, 0, 0, 0.4);
  opacity: 0;
}
.index ul.demos a:hover p {
  opacity: 1;
}
/* post page */
main {
  position: relative;
  padding-top: 1px;
}
.post-page header {
  max-height: 300px;
  overflow: hidden;
}
.post-page header img {
  width: 100%;
  display: block;
}
.post-page .header-text.has-bg-image {
  /* Offset the standard margin */
  margin-top: -4em;
  margin-bottom: 2em;
  padding-bottom: 2em;
  height: 300px;
  /* Align all the text at the bottom */
  display: -webkit-flex;
  -webkit-justify-content: flex-end;
  -webkit-flex-direction: column;
  display: flex;
  justify-content: flex-end;
  flex-direction: column;
}
.post-page .header-text.has-bg-image,
.post-page .header-text.has-bg-image h1 {
  color: white;
}
.post-page article img {
  max-width: 100%;
  margin: 0 auto;
  display: block;
}
.post-page .full-img {
  position: absolute;
  top: 0;
  left: 0;
  height: 300px;
  overflow: hidden;
  z-index: -1;
}
.post-page .full-img .overlay {
  position: absolute;
  left: 0;
  right: 0;
  background-color: rgba(20, 20, 20, 0.5);
  height: 300px;
  width: 100%;
}
.post-page .full-img.undersized {
  left: calc((100% - 1200px) / 2);
}
.post-page .full-img.oversized {
  width: 100%;
}
.post-page .full-img.oversized img {
  width: 100%;
}
.post-page .intro-img {
  max-height: 350px;
  overflow: hidden;
  margin-bottom: 1.5em;
}
.post-page .intro-img img {
  width: 100%;
}
.post-page article p {
  margin: 30px 0;
}
.post-page article h2,
.post-page article h3,
.post-page article h4 {
  position: relative;
  padding-left: 1.25em;
  margin-left: -1.25em;
}
.post-page article h2 .text-anchor,
.post-page article h3 .text-anchor,
.post-page article h4 .text-anchor {
  display: none;
}
.post-page article h2:hover .text-anchor,
.post-page article h3:hover .text-anchor,
.post-page article h4:hover .text-anchor {
  display: block;
}
.post-page article p,
.post-page article li {
  position: relative;
}
.post-page article .text-anchor {
  display: block;
  position: absolute;
  top: -1px;
  left: 0;
  font-weight: normal;
  color: #b0b0b0;
  font-size: 1.2em;
}
.post-page article .text-anchor:hover {
  background-image: none;
}
.post-page article h2,
.post-page article h3,
.post-page article h4 {
  margin-top: 2em;
}
.post-page .meta {
  margin: 1em 0;
  overflow: hidden;
  height: 1.25em;
}
.post-page .tags {
  font-family: "adelle-sans", sans-serif;
  font-size: 16px;
  color: #9a9a9a;
}
.post-page .tags a {
  background-image: none;
  color: #9a9a9a;
  margin-right: .5em;
}
.post-page .tags a:hover {
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.6) 50%);
  background-repeat: repeat-x;
  background-size: 2px 2px;
  background-position: 0 95%;
}
.post-page .tags a:hover {
  color: #747474;
}
.post-page .comments {
  float: left;
  font-size: 16px;
  font-family: "adelle-sans", sans-serif;
  color: #9a9a9a;
  line-height: 1.5em;
}
.post-page .comments a {
  color: #747474;
}
.post-page .social > div {
  float: right;
  padding-top: 2px;
  margin-left: .5em;
}
.post-page .readnext {
  clear: both;
  margin: 4em 0;
}
.post-page .readnext h3 {
  color: #9a9a9a;
  margin-bottom: 0;
}
.notification.error {
  background-color: #ffcdd2;
  color: #d32f2f;
  font-size: 16px;
  line-height: 1em;
  box-shadow: 0 0 1px black;
  font-family: "adelle-sans", sans-serif;
}
#dev-mode {
  position: absolute;
  top: 2em;
  left: 1em;
  font-family: "adelle-sans", sans-serif;
  color: tomato;
  margin-top: .25em;
}
.contracting {
  float: right;
  margin-top: .35em;
  margin-right: 1em;
  font-family: "adelle-sans", sans-serif;
  font-size: .8em;
}
.red-link {
  color: tomato;
  background-image: none;
  text-decoration: underline;
}
header .search {
  float: right;
  margin: .35em;
  margin-right: 1em;
}
@media screen and (max-width: 750px) {
  header .search {
    display: none;
  }
}
header .search input {
  font-size: .9em;
}
header .search input {
  width: 15em;
}
main .search input {
  width: calc(70%);
  font-size: 1em;
}
/* post-specific hacks (fix these later) */
#Stop-Writing-JavaScript-Compilers--Make-Macros-Instead header .links a {
  color: inherit;
}
#Stop-Writing-JavaScript-Compilers--Make-Macros-Instead header .links a:hover {
  color: #fb8c00;
}
#Removing-User-Interface-Complexity--or-Why-React-is-Awesome article .text-anchor {
  left: .25em;
}
