body {
  --background: #333;
}

h1 {
  margin: 0 0 20px 0;
  line-height: 1.2;
  text-transform: uppercase; 
  font-size: 5em;
  text-shadow: 4px 4px rgba(var(--green), .5);
}

h2 {
  font-size: 4em;
}

ul {
  list-style: square;
  font-size: 2em;
  margin: auto;
  text-align: left;
}
li {
  margin-bottom: 1em;
}

a {
  font-family: "Source Sans Pro", Helvetica, sans-serif;
  font-size: inherit;
  color: white;
}

iframe {
  width: 100%; 
  min-height: 80vh; 
  border: none;
}



svg.title {
  transform: rotate(.5turn);
  transform-origin: bottom;
  animation: spin 3s ease-out forwards;
  width: 80%;
  fill: rgb(var(--green));
}

@keyframes spin {
  to { transform: rotate(1turn) }
}

.mask {
  overflow: hidden;
  width: 90%;
  margin: auto;
}

.twitter {
  font-size: 3em;
  position: fixed;
  right: 15px;
  bottom: 10px;
  opacity: .6;
}

.browser-internals {
  width: 80%;
  height: 80%;
  margin: auto;
  border: 4px solid white;
  padding: 1.5em 2em;
  position: relative;
}
.browser-internals legend {
  font-size: 2em;
  padding: .25em;
}
.browser-internals .browser-bits {
  display: flex;
  align-items: center;
  justify-content: space-around;
  flex-wrap: wrap;
  height: 90%;
}
.browser-internals img {
  width: 20%;
  margin: 0 4.5vmin;
  padding: .75em;
}
.browser-internals task-source {
  margin: 0 5vmin;
  padding: .75em;
}
.browser-internals .html {
  margin: 1em;
  padding: .75em;
}
.browser-internals .html::before {
  content: '</>';
  display: block;
  color: rgb(var(--green));
  font-size: 8em;
  font-family: var(--code-font);
  font-weight: bold;
}
.browser-internals .html::after {
  content: 'HTML & CSS';
  font-size: 2em;
}
.browser-internals.web-apis .browser-bits *:not(#engine), .engine #engine.highlighted {
  animation: pink-background-flash 1s cubic-bezier(0.555, 0.140, 0.390, 1.040) forwards;
}
.browser-internals.web-apis .browser-bits #web-apis {
  animation: none;
}
@keyframes pink-background-flash {
  50% {
    background-color: rgba(var(--pink), 1);
  }
  to {
    background-color: rgba(var(--pink), .75);
  }
}
#web-apis, #engines {
  font-size: 5em;
  background-color: rgb(var(--pink));
  box-shadow: 4px 4px 4px rgba(3, 3, 3, 0.4);
  position: absolute;
  transition: opacity .5s;
  padding: .5em;
  animation: none;
}
#web-apis {
  right: 20%;
  bottom: 40%;
}
#engines {
  right: 5%;
  bottom: 30%;
}

.libuv {
  position: absolute;
  bottom: 0;
  right: 0;
  color: rgb(var(--pink));
  font-family: var(--code-font);
  font-size: 5em;
}

.engine-logos {
  display: flex;
  align-items: center;
}
.engine-logos img {
  width: 33%;
}

.centred {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.big-text {
  font-size: 6em;
}
.inverse {
  background-color: white;
  color: var(--background);
}
.uninverse {
  border: 4px solid white;
  color: white;
}
.inverse, .uninverse {
  padding: .5em 1em;
  width: 10ch;
}

.list-and-image {
  display: flex;
  font-size: 2em;
  align-items: center;
  justify-content: space-around;
  margin: 1em;
}
.list-and-image img {
  margin-left: 2em;
  max-width: 33%
}

.columns {
  display: flex;
  align-items: center;
}
.arrow-right, .arrow-down {
  font-size: 10em;
  font-family: 'Courier New', 'Courier New', Courier, monospace;
  font-weight: bold;
  padding-top: 200px;
  -webkit-text-stroke: 8px black;
}
.arrow-right {
  transform: rotate(.25turn);
}
.arrow-down {
  transform: rotate(.5turn);
  padding-top: .5em;
  color: rgb(var(--green));
  -webkit-text-stroke: 8px rgb(var(--pink));
  margin: -.25em;
}
.task {
  background-color: white;
  border: 10px solid black;
  flex-shrink: 0;
  display: flex;
  overflow: hidden;
  color: black;
  width: 200px;
  height: 280px;
}
.task::before {
  content: '{}';
  font-family: 'Courier New', Courier, monospace;
  font-weight: bold;
  overflow: hidden;
  font-size: 10em;
  margin: auto;
}

.vertical {
  display: flex;
  flex-direction: column;
}
.vertical .task {
  transform: scale(.7);
  opacity: 0;
  transition: opacity .5s 1.5s;
}
.script-task.highlighted {
  --highlight-colour: rgb(var(--pink));
}
.script-task.highlighted .click-task {
  background-color: var(--background);
}
.click-task.highlighted {
  --highlight-colour: rgb(var(--green));
}
.script-task, .click-task {
  background-size: 400% 400%;
  background-image: radial-gradient(circle at left, var(--highlight-colour), var(--highlight-colour) 50%, transparent 50%);
  background-position: bottom right;
  transition: background-position 3s;
}
.highlighted.script-task, .highlighted.click-task {
  background-position: top left;
}

.border {
  border: 4px solid white;
  box-shadow: 3px 3px 6px rgba(0, 0, 0, .5);
}
.shadow {
  box-shadow: 4px 4px 8px rgba(0, 0, 0, .75);
}

.heading-card {
  background-color: rgba(0, 0, 0, .3);
  display: inline;
  border-radius: 10px;
  padding: .5em;
  box-shadow: 2px 2px 3px rgba(0, 0, 0, .5);
}
.heading-card.reverse {
  background-color: rgba(255, 255, 255, .8);
  color: black;
}

.about-me {
  background-color: rgba(0, 0, 0, .3);
  display: flex;
  border-radius: 10px;
  padding: .5em;
  box-shadow: 2px 2px 3px rgba(0, 0, 0, .5);
}
.shine-logo {
  background: linear-gradient(to left, white 50%, transparent);
  display: flex;
  align-items: center;
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
  margin: -.5em;
  padding-left: 8em;
}

.spec-text {
  font-size: 3em;
  text-align: left;
}

.yoshi {
  position: fixed;
  bottom: 0;
  width: 40vw;
}
.web-workers::before {
  background: url('web-worker.jpg');
  margin: -10px;
}

.loops {
  display: flex;
  height: 100vh;
}
fieldset.web-workers {
  width: 45%;
  height: 60%;
  border: 4px solid white;
  margin: 0 auto;
  display: flex;
}
fieldset.web-workers legend {
  font-size: 2em;
  padding: 0 1em;
}
fieldset.web-workers iframe {
  margin-top: -20%;
}

.communication {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}
.communication fieldset {
  border: 4px solid white;
  position: relative;
}
.communication legend {
  font-size: 1.5em;
  padding: 0 1em;
}
.worker {
  display: flex;
  align-self: flex-start;
}
.web-workers button {
  font-size: 1em;
  padding: .5em;
  background: transparent;
  border: 3px solid white;
  color: white;
  border-radius: 5px;
  cursor: pointer;
  margin: auto;
  margin-top: -10vh;
  z-index: 2;
}
.web-workers button:hover {
  color: var(--background);
  background: white;
}
.web-workers button:active, .web-workers button:focus {
  outline: 0;
} 
.communication #response {
  position: absolute;
  right: 0;
  bottom: 0;
  background: rgb(var(--green));
  color: white;
  font-size: 4em;
  -webkit-text-stroke: 1px var(--background);
}

.sharing-or-not {
  display: flex;
  align-items: center;
}
.sharing-or-not img {
  width: 45%;
  margin: 40px;
  transition: transform .5s !important;
}
.offscreen {
  transform: translateX(100vw);
}
.offscreen.fragment.visible {
  transform: none;
}

.dino-animation {
  width: 100%;
  min-height: 66vh;
  border: none;
}
.opener-link {
  display: block;
  text-align: left;
  font-size: 2em;
  text-decoration: none;
  padding: .5em;
}

pre code {
  font-size: 2em;
  text-align: left;
}

pre code.hljs {
  background-color: transparent;
}

#naive-animation::before {
  content: 'while (x < screen.width) { box.style.x = calculateX(); box.style.y = calculateY(); }';
  font-size: 1em;
  text-align: left;
  padding: 2em;
}

.quote {
  font-size: 3em;
  font-family: Arial, Helvetica, sans-serif;
  width: 75%;
  position: relative;
}
.quote::before, .quote::after {
  position: absolute;
  font-size: 2em;
  color: rgb(var(--quote-colour));
}
.quote::before {
  content: '\201c';
  left: -.27em;
  top: -.2em;
}
.quote::after {
  content: '\201d';
}

.manual-task {
  position: absolute; 
  right: 12px; 
  top: -80px; 
  bottom: 12px; 
  height: auto; 
  transition: top 10s linear;
  width: 150px;
}
.manual-task::before {
  font-size: 8em;
}
.timer-animation {
  transition: transform steps(12, end) 3s, filter .3s;
}
.timer-animation.go {
  transform: rotate(1turn);
}