/* styles.css */

@font-face {
  font-family: "soehne";
  src: url("fonts/soehne-book.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "soehne";
  src: url("fonts/soehne-bold.woff2") format("woff2");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "soehne";
  src: url("fonts/soehne-light.woff2") format("woff2");
  font-weight: lighter;
  font-style: normal;
}

body,
html {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: black;

  font-family: "soehne", sans-serif;
  font-weight: bold;
  color: white;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

a {
  color: white;
  text-decoration: none;
}

p {
  line-height: 1.3em;
}

em {
  font-variant: italic;
}

.l0 {
  z-index: 0;
}

.l1 {
  z-index: 1;
}

.l2 {
  z-index: 2;
}
.l3 {
  z-index: 3;
}
.l4 {
  z-index: 4;
}

.menu {
  opacity: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  position: absolute;
  bottom: 20px;
  left: 20px;
  right: 20px;
  transition: all 1s linear;
  filter: blur(1px);
}

.show-ui .menu {
  filter: blur(0px);
  opacity: 1;
  transition: all 150ms linear;
}

.menu-item {
  text-transform: uppercase;
  cursor: pointer;
}

#btn-about {
  margin-left: auto;
}

.progress {
  /*background-color: red;*/
  cursor: col-resize;
  padding: 20px 0;
  flex: 1;
  flex-basis: 100%;
  order: -1;
}

@media (orientation: landscape) {
  .progress {
    order: 0;
    flex-basis: 0;
    flex-grow: 1;
    margin: auto 20px;
  }
}

#progress-bar {
  width: 0;
  height: 3px;
  background-color: white;
  transition: all 100ms ease-out;
}

.video-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  cursor: help;
}

.video-container iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw;
  height: 100vh;
}

@media (min-aspect-ratio: 16/9) {
  .video-container iframe {
    /* height = 100 * (9 / 16) = 56.25 */
    height: 56.25vw;
  }
}

@media (max-aspect-ratio: 16/9) {
  .video-container iframe {
    /* width = 100 / (9 / 16) = 177.777777 */
    width: 177.78vh;
  }
}

.is-portrait #landscape-container,
.is-landscape #portrait-container {
  display: none;
}

.content {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  transition: all 120ms linear;
}

.video-paused .content {
  background: linear-gradient(#00000078 0%, #97979700 33%);
}

.centered-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  pointer-events: none;
}

.centered-icon svg {
  width: 75vw;
  max-width: 300px;
}

.video-playing #btn-video-play,
.video-paused #btn-video-pause {
  display: none;
}

#overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

#js-caption {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  pointer-events: none;
  user-select: none;
  padding: 20px;

  transition: all 150ms linear;
  opacity: 1;
  filter: blur(0px);
}

.video-playing #js-caption {
  opacity: 0;
  filter: blur(1px);
}

.caption-inner > p {
  margin: 0;
  font-size: 16px;
  line-height: 1.4em;
}

.caption-inner p.branding {
  font-weight: lighter;
}

@media (min-width: 800px) {
  .caption-inner {
    width: 60vw;
    max-width: 740px;
  }

  .caption-inner > p {
    font-size: 18px;
    line-height: 1.5em;
  }
}

@media (orientation: landscape) and (max-height: 400px) {
  .caption-inner > p {
    font-size: 14px;
    line-height: 1.3em;
  }

  .centered-icon svg {
    width: 200px;
  }
}

@media (orientation: landscape) and (min-height: 400px) {
  .caption-inner > p {
    font-size: 16px;
    line-height: 1.4em;
  }

  .centered-icon svg {
    width: 250px;
  }
}

.about {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms linear;
  padding: 0 20px;
  overflow: auto;

  background-color: #000;
}

.show-about .about {
  opacity: 1;
  pointer-events: auto;
}

.about .col {
  max-width: 80%;
}

.btn-hide-about {
  cursor: pointer;
  width: 18px;
  padding: 10px;
  position: fixed;
  top: 10px;
  right: 10px;
  float: none;
}

@media (min-width: 1000px) {
  .about {
    top: auto;
    opacity: 0;
    padding: 20px 20px 0;
  }

  .about .columns {
    max-width: 1600px;
    margin: auto;

    display: grid;
    gap: 10px;
    grid-template-columns: 5fr 5fr 3fr;
    grid-gap: 15px 10px;
  }

  .about .col {
    padding-right: 30px;
    max-width: 600px;
  }

  .about p {
    margin: 0 0 1em 0;
  }

  .btn-hide-about {
    cursor: pointer;
    padding: 10px;
    position: absolute;
    top: 15px;
    right: 20px;
  }
}
