*, *:before, *:after {
  box-sizing: border-box;
}

:root {
  --bg: #efefef; --bg-t: #efefef00; --text: #222222; --link: #012fd5; --highlight: #7f1909; 
}

.dark {
  --bg:#222222; --bg-t: #22222200; --text:#efefef; --link:#47daff; --highlight:#ffb999; 
}

::selection {
  color: var(--bg);
  background: var(--text);
}

::-webkit-scrollbar {
  width: 25px;
}

::-webkit-scrollbar-track {
  background: var(--bg); 
}

::-webkit-scrollbar-track:vertical {
  border-left: 1px solid var(--text); 
}

::-webkit-scrollbar-track:horizontal {
  border-top: 1px solid var(--text);
}

::-webkit-scrollbar-corner {
  background: var(--bg); 
  border-top: 1px solid var(--text);
  border-left: 1px solid var(--text); 
}
 
::-webkit-scrollbar-thumb {
  background: var(--text);
  margin: -1px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--bg);
  border: 1px solid var(--text);
}

::-webkit-scrollbar-thumb:vertical:hover {
  border-right: none;
}

::-webkit-scrollbar-thumb:horizontal:hover {
  border-bottom: none;
}

::-webkit-scrollbar {
  width: 25px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-track:vertical {
  border-left: 1px solid var(--text);
}

::-webkit-scrollbar-track:horizontal {
  border-top: 1px solid var(--text);
}

::-webkit-scrollbar-corner {
  background: var(--bg);
  border-top: 1px solid var(--text);
  border-left: 1px solid var(--text);
}

::-webkit-scrollbar-thumb {
  background: var(--text);
  margin: -1px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--bg);
  border: 1px solid var(--text);
}

::-webkit-scrollbar-thumb:vertical:hover {
  border-right: none;
}

::-webkit-scrollbar-thumb:horizontal:hover {
  border-bottom: none;
}

html {
  font-family: 'Telegraf', 'Work Sans', sans-serif;
  scroll-behavior: smooth;
  overflow: hidden;
  height: 100%;
  background: var(--bg);
  color: var(--text);
}

body {
  -webkit-text-size-adjust: 100%;
  overflow-y: hidden;
  max-height: 100%;
}

h1 {
  color: var(--text);
  font-weight: 600;
  font-size: 6.5rem;
  line-height: 0.9em;
  margin-bottom: 0.15em;
}

h2 {
  font-family: 'Migra', 'Gilda Display', 'Times New Roman', display;
  font-weight: 300;
  font-size: 5rem;
  line-height: 0.9em;
  margin-bottom: 0.15em;
}

h2.contact {
  font-family: 'Telegraf', 'Work Sans', sans-serif;
}

h3 {
  font-weight: 100;
  font-size: 3rem;
}

p {
  font-family: 'Telegraf', 'Work Sans', sans-serif;
  font-size: 1.2em;
  line-height: 1.5;
  margin-bottom: 1.2em;
}

.work-content-tags {
  position: absolute;
  top: 0;
  right: 0;
}

.loader:not(.loaded) p.work-content-text:before {
  width: 0px;
  transition: 0.5s cubic-bezier(.2,1,.25,1);
}

p.work-content-text {
  position: relative;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  max-width: min(45vw, 65ch);
  text-align: left;
}

p.work-content-text:before {
  content: '';
  position: absolute;

  top: 0;
  left: 0;

  height: 1px;
  width: 100%;

  background: var(--text);
  transition: 1.4s cubic-bezier(.2,1,.25,1);
}

.margin-top-var-home {
  margin-top: -2rem;
}

.work-content-inner h3 {
  text-align: right;
}

.block {
  display: block;
}

a {
  color: var(--text);
  text-decoration: none;
  position: relative;
}

.ext-link:before {
  content: '>';
  position: absolute;
  right: 0px;
  transform: translateX(150%);
}

.fancy-link {
  color: var(--highlight);
}

.fancy-link:hover {
  cursor: pointer;
}

.fancy-link.visited:hover:after {
  width: 100%;
}

.fancy-link:after {
  background: var(--highlight);
}

.fancy-link.visited:after {
  width: 100%;
}

section {
  margin: 0 10vw;
  padding-top: 10vh;
}

.landing {
  position: relative;
  padding-top: 0;
  min-height: var(--height);
  display: grid;
  grid-template-columns: 1fr;
  justify-content: left;
  align-items: center
}

footer {
  position: relative;
  padding: 3% 5vw;
  margin-top: 10vh;
  border-top: 1px solid var(--text);
}

.vertical-landing {
  position: relative;
  margin: 0;
}

.link-centered {
  width: 100%;
}

main {
  overflow: visible;
}

.work-landing { 
  display: flex;
  flex-flow: column nowrap;
  align-items: flex-start;
  padding-top: 30vh;
  padding-bottom: 30%;
}

.link-centered .landing-copy {
  margin-bottom: 20rem;
}

.work-links {
  width: 100%;
}

.click-to-toggle {
  margin-bottom: 1rem;
}

.scroll-indicator {
  margin-bottom: 1rem;
}

details {
  outline: none;
  border: none;
  width: 100%;
}

summary {
  outline: none;
  border: none;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

details .work:after {
  content: '';
  position: absolute;

  bottom: 0;
  left: 0;

  width: 0;
  height: 2px;

  background: var(--text);
  transition: 1.1s cubic-bezier(.1,1,.15,0.9);
}

details.align-right .work:after {
  left: auto;
  right: 0;
}

details.align-center .work:after {
  left: 50%;
}

details:hover {
  cursor: pointer;
}

details:hover .work:after {
  width: 3ch;
  cursor: pointer;
}

details.align-center:hover .work:after {
  left: 50%;
}  

@media (min-width: 1000px) {
  details.align-center:hover .work:after {
    left: calc(50% - 1.5ch);
  }  
}
details:active .work:after {
  width: 100%;
}

details.align-center:active .work:after {
  left: 0;
}

details[open="true"] .work:after {
  width: 100%;
}

details[open="true"]:hover .work:after {
  width: 100%;
}

details[open="true"].align-center .work:after {
  left: 0;
}

.work {
  position: relative;
  width: 100%;
}

.align-right {
  text-align: right;
}

.align-center {
  text-align: center;
}

.work-content-outer {
  overflow: hidden;
  height: 0;
}

.work-content-inner {
  position: relative;
  padding: 1rem 0;
  max-width: 100%;
  transform: translateY(-150%);
}

.work-content-loaded {
  transform: none;
}

.contact-shell {
  text-align: right;
}

.contact {
  margin-left: 2ch;
}

.preloader {
  position: fixed;
  height: var(--height);
  width: 100vw;
  background: var(--bg);
  z-index: 1000;
}

.preloader.hide {
  height: 0px;
}

.sail {
  position: fixed;
  height: var(--height);
  width: 1px;
  left: 50vw;
  background: var(--text);
  z-index: 1001;
}

.sail-next {
  bottom: calc(-1 * var(--height) - 1px);
}

.sail-prev {
  top: calc(-1 * var(--height) - 1px);
}

header, footer {
  border: none;
  background: var(--bg);

  padding: 3% 10vw;

  position: fixed;
  top: 0;
  left: 0;

  width: 100%;
}

header:after {
  content: '';
  position: absolute;
  bottom: -35px;
  left: 0;
  height: 35px;
  width: 100%;
  
  background: -moz-linear-gradient(top, var(--bg) 0%, var(--bg-t) 100%); /* FF3.6-15 */
  background: -webkit-linear-gradient(top, var(--bg) 0%,var(--bg-t) 100%); /* Chrome10-25,Safari5.1-6 */
  background: linear-gradient(to bottom, var(--bg) 0%,var(--bg-t) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
}

footer:before {
  content: '';
  position: absolute;
  top: -35px;
  left: 0;
  height: 35px;
  width: 100%;

  background: -moz-linear-gradient(top, var(--bg-t) 0%, var(--bg) 100%); /* FF3.6-15 */
  background: -webkit-linear-gradient(top, var(--bg-t) 0%,var(--bg) 100%); /* Chrome10-25,Safari5.1-6 */
  background: linear-gradient(to bottom, var(--bg-t) 0%,var(--bg) 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
}

.menubtn {
  display: none;
}

svg {
  fill: var(--text);
  stroke: var(--text);
  stroke-width: 2px;
}

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

footer {
  display: flex;
  justify-content: space-between;

  top: auto;
  bottom: 0;
}

.links .shell {
  display: flex;
  flex-flow: row nowrap;
}

a {
  position: relative;
}

.links a {
  margin: 0 1ch;
}

a:after {
  content: '';
  position: absolute;

  bottom: 0;
  left: 0;

  width: 0;
  height: 2px;

  background: var(--text);
  transition: 1.1s cubic-bezier(.1,1,.15,0.9);
}

a.active:after {
  width: 100%;
}

.links:active a.active:after {
  width: 0;
}

.links:active a.active:active:after {
  width: 100%;
}

a:not(.active):hover:after {
  width: 3ch;
}

.contact a:hover:after {
  width: 0.6ch;
}

a:not(.active):active:after {
  width: 100%;
}

.small-line-height {
  margin-top: -0.4em;
}

a.no-left-margin {
  margin-left: 0;
}

a.no-right-margin {
  margin-right: 0;
}

.landing-paragraph {
  font-size: 1.3rem;
}

.align-right {
  margin-left: auto;
}

.align-center {
  margin-left: auto;
  margin-right: auto;
}

.intersecter {
  position: fixed;
  bottom: 30vh;
  height: 1px;
  width: 100vw;
  background: red;
}

@media (min-width: 1000px) {
  .loader:not(.intersect).loaded .shell:not(.hover-el) .outer, .loader:not(.intersect).loaded .shell:not(.hover-el) .inner {
    transform: none;
  }

  .anim-hover:hover .hover-el.shell .inner, .anim-hover:hover .hover-el.shell .outer {
    transform: none;
  }

  .anim-hover:not(:hover) .hover-el.shell .outer {
    transition-delay: 0s;
  }
}

@media (max-width: 1000px) {
  .loader:not(.intersect).loaded .shell .outer, .loader:not(.intersect).loaded .shell .inner {
    transform: none;
  }

  .loader:not(.intersect) .hover-el.shell .outer {
    transition-delay: 0s;
  }
}

.shell .outer:nth-child(1) {
  transition-delay: 0;
}
.shell .outer:nth-child(2) {
  transition-delay: .05s;
}
.shell .outer:nth-child(3) {
  transition-delay: .1s;
}
.shell .outer:nth-child(4) {
  transition-delay: .15s;
}
.shell .outer:nth-child(5) {
  transition-delay: .2s;
}
.shell .outer:nth-child(6) {
  transition-delay: .25s;
}
.shell .outer:nth-child(7) {
  transition-delay: .3s;
}
.shell .outer:nth-child(8) {
  transition-delay: .35s;
}
.shell .outer:nth-child(9) {
  transition-delay: .4s;
}
.shell .outer:nth-child(10) {
  transition-delay: .45s;
}

.shell {
  display: inline-block;
  overflow: hidden;
  width: 100%;
}

.outer {
  display: inline-block;
  overflow: hidden;
  transform: translateY(150%);
}

.outer.br {
  display: block;
}

.inner {
  display: inline-block;
  transform: translateY(-110%);
  display: flex;
  align-items: center;
  width: 100%;
}

h1 {
  font-family: 'Migra', 'Gilda Display', 'Times New Roman', display;
  font-style: normal;
  font-weight: 100;
}

h1 .outer {
  height: 1.1em;
}

h1 .inner {
  padding: 0 5px;
  height: 1.1em;
}

.marquee {
  display: inline-block;
  position: relative;

  width: 60vw;
  height: 1.1em;

  overflow: hidden;
}

.marquee span {
  position: absolute;
}

.transitioned {
  transform: none;
}

.ease {
  transition: 1.7s cubic-bezier(.2,1,.25,1);
  transition-property: transform, height;
}

@media (max-width: 1000px) {
  html {
    font-size: 12px;
  }

  main.ease {
    transition: none;
  }

  h1 {
    font-size: 5rem;
  }
  
  .h1-shell {
    transform-origin: bottom left;
    transform: scale(1.25) translateX(-1%) translateY(3%);
  }

  h2 {
    font-size: 3rem;
  }

  .margin-top-var-home {
    margin-top: -1rem;
  }

  section, section.prose {
    margin: 0 5vw;
  }

  header, footer {
    padding: 0;

    height: 10vh;
    width: 100vw;

    z-index: 999;
  }

  footer {
    align-items: center;
    z-index: 998;
  }

  .menubtn {
    display: flex;
    flex-flow: column nowrap;
    position: fixed;

    right: 15px;
    top: 15px;

    height: 50px;
    width: 50px;

    padding-top: 0;
    font-size: 5rem;

    z-index: 100;
    overflow: hidden;
  }

  header:not(.hide) .menubtn span {
    transform: translateY(0px);
  }

  .menubtn span {
    height: 50px;
    width: 50px;

    display: grid;
    place-content: center;

    margin-top: -0.5px;
    
    transform: translateY(-50px);
  }

  .nav-container {
    position: absolute;
    left: 0;
    top: 0;

    height: var(--height);
    width: 100vw;

    overflow: hidden;

    font-size: 3rem;
    flex-flow: column nowrap;

    justify-content: space-around;
    transform: translateZ(1px);
  }

  .nav {
    position: absolute;
    left: 0;
    top: 0;

    height: var(--height);
    width: 100vw;
    
    padding: 5% 5vw;

    flex-flow: column nowrap;
    justify-content: space-around;

    background: var(--bg);    
  }

  header.hide .nav-container {
    height: 0px;
    justify-content: flex-end;
    transform: translateZ(1px);
  }

  header.hide .nav {
    pointer-events: none;
  }

  .links .shell {
    flex-flow: column nowrap;
  }

  .links a {
    margin: 0;
  }

  .links a:after {
    content: none;
  }

  .link-centered .landing-copy {
    margin-bottom: 13rem;
  }

  h1 {
    font-size: 3.5rem;
  }

  h3 {
    font-size: 2.5rem;
  }

  details:hover .work:after {
    width: 0;
    cursor: pointer;
  }

  .work-content-tags {
    position: relative;
  }

  p.work-content-text {
    max-width: 100%;
  }

  footer {
    padding: 3% 5vw;
  }
}