body {
  height: 100%;
  margin: 0;
  padding: 0;

  font-family: "Helvetica Neue", "Inter", Arial, sans-serif;
  font-size: 11pt;
}

@font-face {
  font-family: Coolvetica;
  src: url("/fonts/coolvetica.otf") format("opentype");
}

@font-face {
  font-family: HelveticaNeueLight;
  src: url("/fonts/HelveticaNeueLight.woff2") format("woff2"),
    url("/fonts/HelveticaNeueLight.woff") format("woff");
}

@font-face {
  font-family: HelveticaNeue;
  src: url("/fonts/HelveticaNeueRegular.otf") format("opentype");
  font-weight: normal;
}

@font-face {
  font-family: HelveticaNeue;
  src: url("/fonts/HelveticaNeueBold.woff2") format("woff2"),
    url("/fonts/HelveticaNeueBold.woff") format("woff");
  font-weight: bold;
}

@keyframes kf-fade-in {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.fade-in {
  animation: kf-fade-in 1s;
}

#unity-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  background: white;
  color: #000;
  font-size: 22px;
  transition: filter 0.2s ease;
}

#monacoboxframe {
  position: fixed;
  border: none;
  user-select: none;
  /* Note: the left, top, width and height properties are driven from Unity */
}

/* Hack to make the iframe invisible and still let it load: move it off the
   visible part of the page. */
.iframe-invisible-hack {
  left: 200vw;
  top: 200vh;
  width: 800px;
  height: 600px;
}

.grid-bg {
  /* animation: gradient 150s linear infinite;
  background-image: linear-gradient(#dadada 0.8px, transparent 0.8px), linear-gradient(to right, #dadada 0.8px, #fcfcfc 0.8px);
  background-size: 40px 40px;
  background-position: 10px;*/

  /*background: radial-gradient(#f5f5f5 70%, #e0e0e0); */
  background: #111;
}

@keyframes gradient {
  0% {
    background-position-x: 0%;
  }

  100% {
    background-position-x: 50%;
  }
}

a {
  text-decoration: none;
  color: #2f69ff;
}

a:active {
  text-decoration: underline;
}

/* width */
::-webkit-scrollbar {
  width: 10px;
  visibility: visible;
}

/* Track */
::-webkit-scrollbar-track {
  background: #f5f5f5;
  border-radius: 5px;
}

/* Handle */
::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 5px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #555;
}

#mobile-web-not-supported {
  background-image: url("https://rooms.xyz/honeycomb_vert.png");
  background-size: cover;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  font: 12pt "Helvetica Neue", helvetica, sans-serif;
}

#mobile-web-not-supported .content {
  text-align: center;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
}

#mobile-web-not-supported h2 {
  margin-top: 48px;
  font-size: 24px;
}

#mobile-web-not-supported p {
  line-height: 1.2;
}

#download-ios-button {
  background: linear-gradient(149deg,
      rgba(236, 158, 191, 1) 35%,
      rgba(232, 133, 173, 1) 100%);
  color: rgba(0, 0, 0, 0.64);
  text-decoration: none;
  padding: 20px;
  display: inline-block;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  margin: 24px auto 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}

#mobile-web-title {
  width: 95%;
  margin-bottom: 55px;
}

#mobile-web-logo {
  width: 80%;
}

#mobile-web-subheading {
  font-size: 28px;
  font-weight: 500;
  text-align: center;
  margin-top: 80px;
  margin-bottom: 0px;
}

#mobile-web-bottom-text {
  text-align: center;
  color: #888888;
  margin-top: 5px;
}

#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

@keyframes kf-loading-screen-zoom-in {
  0% {
    opacity: 1;
    transform: scale(1);
  }

  100% {
    opacity: 0;
    transform: scale(2);
  }
}

.loading-screen-zoom-in {
  animation: kf-loading-screen-zoom-in 1s forwards;
}

#loading-screen-graphics {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

#loading-screen-honeycomb {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#loading-screen-honeycomb-scrim {
  display: none;
  /* DISABLED FOR NOW */
  position: absolute;
  /*
  top: 0px;
  left: 0px;
  width: 100%;
  height: 100%;
  background: radial-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.9));*/
}

#loading-screen-thumb {
  position: absolute;
  width: 200px;
  height: 200px;

  width: 40.8vh;
  height: 40.8vh;
  left: calc(50vw - 20.4vh);
  top: calc(50vh - 20.4vh);
}

#loading-screen-top {
  position: absolute;
  top: 10vh;
  width: 100%;
  text-align: center;
}

#loading-screen-title {
  font-size: 48pt;
  font-weight: bold;
  text-align: center;
  color: white;
}

#loading-screen-attribution {
  color: white;
}

#loading-screen-attribution-author {
  font-weight: bold;
  color: white;
}

#loading-screen-bottom {
  position: absolute;
  height: auto;
  width: 240px;
  left: calc(50vw - 120px);
  bottom: 5vh;
  text-align: center;
}

#loading-bar-bg {
  width: 240px;
}

#loading-screen-vignette {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  box-shadow: 0 0px 100px rgb(0 0 0 / 10%) inset;
  pointer-events: none;
}

#loading-bar-bg {
  background: #e8e8e8;
  height: 12px;
  overflow: hidden;
  border-radius: 8px;
  margin-top: 12px;
}

@keyframes loading-anim {
  from {
    transform: translate(-120px);
  }

  to {
    transform: translate(120px);
  }
}

#loading-bar-fg {
  display: inline-block;
  background: #ee81a6;
  width: 80px;
  animation: loading-anim 1.5s infinite;
}

#loading-screen-title {
  width: 100%;
  padding-bottom: 10px;
}

#build-info {
  position: fixed;
  bottom: 8px;
  left: 32px;
  color: #b0b0b0;
  font: 8pt sans-serif;
}

#debug-info {
  position: fixed;
  bottom: 8px;
  right: 8px;
  color: #b0b0b0;
  font: 8pt sans-serif;
}

#made-in-rooms {
  color: white;
  margin: 14px auto 0px;
  font-weight: 300;
  font-size: 22px;
  width: 240px;
}

#made-in-rooms .heavy {
  font-weight: 500;
}

/* Warning Label */

#warning-label {
  background: #fff;
  margin: 30px auto 0px;
  transform: rotate(3deg) translateX(-6px);

  box-shadow: 0 0 3px rgba(0, 0, 0, 0.48);
  padding: 6px;
  border-radius: 16px;

  width: 240px;
}

#warning-label .inner {
  border-radius: 12px;
  border: 3px solid #000;
  background: #fef200;
  box-sizing: border-box;
  height: 100%;
  width: 100%;
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
}

#warning-label .inner .left img {
  width: 24px;
  margin-top: 2px;
}

#warning-label .inner .right {
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

#warning-label h3 {
  margin: 0;
  font-size: 12px;
  text-transform: uppercase;
}

#warning-label p {
  margin: 0;
  font-size: 12px;
}

/* Picture of the user that shows that they are signed in */
#user-picture {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  /* circle crop */
  position: fixed;
  right: 28px;
  top: 28px;
  -webkit-touch-callout: none;
  /* iOS Safari */
  -webkit-user-select: none;
  /* Safari */
  -khtml-user-select: none;
  /* Konqueror HTML */
  -moz-user-select: none;
  /* Old versions of Firefox */
  -ms-user-select: none;
  /* Internet Explorer/Edge */
  user-select: none;
  /* Non-prefixed version, currently
                                supported by Chrome, Edge, Opera and Firefox */
}

#sign-in-button {
  background: #0000001a;
  position: fixed;
  right: 28px;
  top: 28px;
}

#sign-in-button:hover {
  background: #00000040;
}

#sign-out-button {
  margin-top: 16px;
}

#sign-out-button:hover {
  background: #00000040;
}

#user-profile-menu {
  position: fixed;
  right: 8px;
  top: 64px;
  background: #000;
  opacity: 75%;
  color: white;
  font-size: 10pt;
  width: 180px;
  border-radius: 4px;
  margin-top: 16px;
}

#user-profile-menu ul {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

#user-profile-menu ul li {
  margin: 0;
  display: block;
  height: 48px;
  line-height: 48px;
  cursor: pointer;
  padding-left: 16px;
  box-sizing: border-box;
}

#user-profile-menu ul li:hover {
  background: rgba(255, 255, 255, 0.2);
}

.full-scrim {
  position: fixed;
  right: 0;
  top: 0;
  left: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  pointer-events: all;
  z-index: 10;
}

#registration-window {
  position: fixed;
  top: calc(50vh - 208px);
  left: calc(50vw - 386px);
  width: 700px;
  height: 360px;
  border-radius: 16px;
  background: #f4f4f4;
  padding: 28px 36px;
}

#registration-window h1 {
  margin: 20px 0 24px 0;
  font-size: 24pt;
  font-weight: bold;
}

#registration-status {
  font-size: 8pt;
  margin-top: 7px;
  height: 8pt;
  color: #ff0000;
  margin-left: 6px;
}

#registration-container {
  display: flex;
  flex-direction: row;
}

img#registration-preview {
  width: 300px;
  height: 200px;
  border-radius: 16px;
  margin-right: 32px;
}

#registration-form {
  flex-grow: 1;
}

.field-header {
  font-size: 8pt;
  color: #555;
  margin-bottom: 4px;
  margin-left: 4px;
}

#registration-uname {
  box-sizing: border-box;
  border-radius: 6px;
  font-family: "Helvetica Neue", Inter, Arial, sans-serif;
  font-size: 11pt;
  padding: 10px;
  border: 1px solid #cecece;
  width: 100%;
  text-transform: lowercase;
}

#registration-button-bar {
  margin-top: 32px;
}

#registration-close-button {
  position: absolute;
  right: 22px;
  top: 24px;
  opacity: 0.5;
}

#registration-close-button:hover {
  opacity: 1;
}

#registration-ok {
  float: right;
}

#registration-preview-url {
  position: absolute;
  top: 200px;
  left: 107px;
  font-size: 11pt;
  color: #202020;
}

.tos {
  font-size: 13px;
  cursor: pointer;
  position: relative;
  padding-left: 30px;
  top: 20px;
}

.tos-text {
  position: absolute;
  left: 37px;
  width: 320px;
}

.tos input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* Create a custom checkbox */
.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 25px;
  width: 25px;
  background-color: white;
  border: 1px solid #787878;
  border-radius: 4px;
}

/* On mouse-over, change border to thicker */
.tos:hover input~.checkmark {
  border: 1px solid #000000;
}

/* When the checkbox is checked, change background color (not in use) */
.tos input:checked~.checkmark {
  background-color: white;
}

/* Create the checkmark/indicator (hidden when not checked) */
.checkmark:after {
  content: "";
  position: absolute;
  display: block;
  opacity: 0.05;
}

/* Show the checkmark when checked */
.tos input:checked~.checkmark:after {
  opacity: 1;
}

/* Style the checkmark/indicator */
.tos .checkmark:after {
  left: 9px;
  top: 5px;
  width: 5px;
  height: 10px;
  border: solid black;
  border-width: 0 3px 3px 0;
  -webkit-transform: rotate(45deg);
  -ms-transform: rotate(45deg);
  transform: rotate(45deg);
}

button {
  background: #666;
  border-radius: 8px;
  padding: 12px 18px;
  border: none;
  cursor: pointer;
  color: white;
}

button:hover {
  background: #444;
}

button:disabled {
  background: #bbb;
  cursor: not-allowed;
}

#email-feedback {
  position: fixed;
  right: 126px;
  bottom: 5px;
}

.dialog-window {
  position: fixed;
  background: white;
  border-radius: 8px;

  width: 400px;
  top: 40vh;
  left: calc(50vw - 200px);
  padding: 16px;
}

#dialog-message {
  margin: 16px 0 32px 0;
  text-align: center;
}

#dialog-button-bar {
  text-align: right;
}

#dialog-no-button {
  margin-right: 8px;
}

#progress-window {
  text-align: center;
}

#prefinery-form-cta {
  background: #0000001a;
  position: fixed;
  right: 120px;
  top: 28px;
}

#sign-in-interstitial-window {
  position: fixed;
  top: calc(50vh - 150px);
  left: calc(50vw - 200px);
  width: 400px;
  border-radius: 16px;
  background: #f5f5f5;
  padding: 4px 24px 20px 24px;
}

#sign-in-interstitial-button-bar {
  display: flex;
  flex-direction: row;
}

#sign-in-interstitial-cancel {
  background: none;
  text-decoration: underline;
  color: rgba(0, 0, 0, 0.5);
  cursor: pointer;
  margin-right: auto;
}

#sign-in-interstitial-button {
  margin-left: auto;
  background: #356df2;
}

/* Sign in picker */

#sign-in-picker {
  transition: opacity 0.2s ease, visibility 0.2s ease;
  opacity: 0;
  visibility: hidden;
}

#sign-in-picker.visible {
  opacity: 1;
  visibility: visible;
}

#sign-in-picker-window {
  position: fixed;
  top: calc(50vh - 154px);
  left: calc(50vw - 180px);
  width: 360px;
  border-radius: 16px;
  background: #f5f5f5;
  padding: 36px;
  box-sizing: border-box;
  line-height: 16px;
}

#sign-in-picker-window h1 {
  font-size: 24pt;
  font-weight: bold;
  margin: 0;
  text-align: center;
}

#sign-in-picker-wrapper {
  padding: 24px 0 12px 0;
}

#sign-in-picker-window button,
#sign-in-picker-window input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid #D8DADC;
  background: #FFF;
  color: #000;
  text-align: left;
  font-weight: 500;
  font-family: "Helvetica Neue", "Inter", Arial, sans-serif;
  font-size: 10pt;
  margin-bottom: 12px;
  margin-top: 6px;
  transition: box-shadow 0.2s ease;
}

#sign-in-picker-window button:hover {
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.2);
}

#sign-in-picker-window input {
  font-weight: 400;
  text-align: left;
}

#sign-in-picker-window button img {
  position: absolute;
}

#sign-in-picker-window button span {
  margin-left: 24px;
}

#sign-in-picker-window #sign-in-picker-email-confirm {
  background: #000;
  border: none;
  color: #fff;
  margin-bottom: 0px;
  text-align: center;
}

#sign-in-picker-window p {
  color: #494949;
  margin: 0;
  text-align: center;
  font-size: 10pt;
  margin: 4px 0px;
}

#sign-in-picker-window #sign-in-picker-email-message {
  margin: 30px 0px 0px 0px;
}

#video-recording-window {
  position: fixed;
  top: calc(50vh - 150px);
  left: calc(50vw - 200px);
  width: 400px;
  border-radius: 16px;
  background: #f5f5f5;
  padding: 4px 24px 20px 24px;
}

#video-recording-countdown {
  position: fixed;
  top: calc(50vh - 100px);
  left: calc(50vw - 100px);
  width: 200px;
  height: 200px;
  border-radius: 100px;
  text-align: center;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  font-size: 64px;
  font-weight: bold;
  line-height: 200px;
}

.video-recording-param {
  margin-top: 8px;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
}

.video-recording-param-label {
  width: 200px;
}

.video-recording-param-value {
  width: 300px;
  padding: 8px;
  border-radius: 8px;
}

#video-recording-button-bar {
  display: flex;
  margin-top: 8px;
  flex-direction: row;
  width: 100%;
  justify-content: right;
  align-items: center;
}

#video-recording-start {
  background: #2f69ff;
  color: white;
  margin-left: 8px;
}

#honeycomb-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(#000, #345680);
}

#honeycomb-iframe {
  width: 100%;
  height: 100%;
  border: none;
}

#mobile-landing,
#ios-landing {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;

  opacity: 0;
  animation: fadeIn 1.5s forwards;
  animation-delay: 0.1s;

  /* TODO: replace with room background? */
  background: linear-gradient(#409cd4,
      #4b87c7,
      #7962bc,
      #b14fb3,
      #e549a1,
      #f15a87,
      #f47b60,
      #f4934d);
}

#mobile-landing.lightMode #mobile-landing-title,
#mobile-landing.lightMode #mobile-landing-subtitle,
#mobile-landing.lightMode #mobile-landing-ios-notify,
#mobile-landing.lightMode #mobile-landing-blurb {
  color: black;
}

#mobile-landing.lightMode #mobile-landing-desktop-only {
  color: rgba(0, 0, 0, 0.9);
}

#mobile-landing.lightMode #mobile-landing-blurb {
  border: 1px solid black;
}

#mobile-landing-flex {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.25), transparent 25%),
  linear-gradient(to top, rgba(0, 0, 0, 0.25), transparent 25%)
}

#mobile-landing-top,
#mobile-landing-bottom {
  position: fixed;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

#mobile-landing-top {
  top: 32px;
}

@media (max-height: 500px) {
  #mobile-landing-top {
    top: 16px;
  }
}

#mobile-landing-bottom {
  bottom: 32px;
}

@media (max-height: 500px) {
  #mobile-landing-bottom {
    bottom: 16px;
  }
}

#mobile-landing-title {
  opacity: 0;
  font: 42px "Coolvetica", "Helvetica Neue", HelveticaNeue;
  color: white;
  animation: fadeIn 1.5s forwards;
  animation-delay: 0.1s;
}

#mobile-landing-subtitle {
  opacity: 0;
  font: 22px "Helvetica Neue", HelveticaNeueLight;
  font-weight: 300;
  color: white;
  animation: fadeIn 1.5s forwards;
  animation-delay: 0.2s;
}

#mobile-landing-desktop-only {
  font: 16px HelveticaNeueLight;
  color: rgba(255, 255, 255, 0.75);
  padding: 16px;
}

#mobile-landing-ios-notify {
  color: white;
  text-decoration: underline;
}

#mobile-landing-blurb {
  font: 16px HelveticaNeueLight;
  width: auto;
  background: transparent;
  border: 1px solid white;
  border-radius: 0px;
  color: white;
  text-decoration: none;
  text-align: center;
  display: inline-block;
  padding: 12px;
  border-radius: 4px;
}

#mobile-landing-blurb:active {
  background: rgba(255, 255, 255, 0.5);
}

#mobile-landing-ios-form-bg {
  position: absolute;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.25);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  top: 0;
  z-index: 1;
}

.mobile-landing-ml-embedded {
  position: absolute;
  width: 90%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0px 0px 25px rgb(0 0 0 / 50%);
}

#mobile-landing-ios-form-bg.visible {
  opacity: 1;
  pointer-events: all;
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

#mobile-landing-thumb {
  opacity: 0;
  width: max(100vw, 100vh);
  animation: fadeIn 1.5s forwards;
  animation-delay: 0.6s;
  z-index: -1;
}

#mobile-landing-top-bar {
  opacity: 0;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  font: 15px "Helvetica Neue", HelveticaNeueLight;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 50px;
  left: 0;
  right: 0;
  animation: fadeIn 3s forwards;
  animation-delay: 1s;
}

#mobile-landing-top-bar {
  position: fixed;
  top: 0;
}

#mobile-landing-top-bar a {
  color: white;
}

@keyframes bounce {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }

  100% {
    transform: scale(1);
  }
}

.bounce span {
  animation: bounce 0.5s;
}

#ios-landing {
  display: none;
  /* changed to 'flex' programmatically */
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 64px;
  background-image: url("./dots-bg.jpg");
  /* Adjust the size and positioning of the dots */
  background-size: 8px 8px;
  /* Adjust the size of the dots */
  background-repeat: repeat;
  animation: fadeIn 1.5s 0.1s forwards, moveDots 4s linear infinite;
}

@keyframes moveDots {
  0% {
    background-position: 0px 0px;
  }

  100% {
    background-position: 16px 8px;
  }
}

#ios-landing.lightMode #ios-landing-phone-screen,
#ios-landing.lightMode #mobile-landing-subtitle,
#ios-landing.lightMode #mobile-landing-ios-notify,
#ios-landing.lightMode #mobile-landing-blurb {
  color: black !important;
}

#ios-landing.lightMode .ios-landing-action-icon,
#ios-landing.lightMode .ios-landing-icon {
  filter: none;
}


#ios-landing-phone-container {
  position: relative;
  /* Note: there's a lot of padding in the image, so 100vw doesn't
     mean the phone container actually expands to the full width. */
  width: 130vw;
  height: calc(130vw * 1.6129);
  /* keep aspect ratio */
  margin-top: -200px;
  flex-shrink: 0;

  opacity: 0;
  transform: translateY(-50px);
  animation: slideDown 1.5s 0.1s forwards, tiltAnimation 8s 2s infinite ease;
}

@keyframes slideDown {
  0% {
    opacity: 0;
    transform: translateY(-50px);
  }

  100% {
    opacity: 1;
    transform: translateY(0px);
  }
}

@keyframes tiltAnimation {
  0% {
    transform: scale(1) rotateX(0deg) rotateY(0deg) translateY(0);
  }

  50% {
    transform: rotateX(6deg) rotateY(-8deg) translateY(12px);
  }

  100% {
    transform: scale(1) rotateX(0deg) rotateY(0deg) translateY(0);
  }
}

@media only screen and (min-device-width: 391px) and (-webkit-min-device-pixel-ratio: 1) {
  #ios-landing-phone-container {
    width: 508px;
    height: calc(508px * 1.6129);
    margin-top: 0;
  }
}

/* This is positioned to cover the entire phone container */
#ios-landing-phone-frame {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 100%;
  height: 100%;
  object-fit: contain;
  z-index: 1;
  /* Hack to fix z-index bug in Chrome/Safari for iOS */
  transform: translateZ(10000px);
}

/* The positioning values were all found by trial and error and
   painstaking manual adjustments. Don't change unless you like suffering. 
   If you want to resize the whole phone, tweak #ios-landing-phone-container.*/
#ios-landing-phone-screen {
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
  position: absolute;
  border-radius: 40px;
  top: 6%;
  left: 18.8%;
  width: 61%;
  height: 81%;
  background: white;
  color: white;
  transform: perspective(513px) rotateX(1deg) rotateY(358deg) rotateZ(2deg);
  overflow: hidden;
  padding: 16px 16px 8px 16px;
  z-index: 0;
  padding: 16px 16px 8px 20px;
}

#ios-landing-thumb {
  width: 110%;
  align-self: center;
  margin-right: 5px;
}

#ios-landing-room-name {
  font: bold 16px HelveticaNeue;
  margin-bottom: 4px;
}

#ios-landing-info-box {
  display: flex;
  flex-direction: row;
  margin-bottom: 24px;
}

#ios-landing-info-box-left {
  display: flex;
  flex-direction: column;
}

#ios-landing-info-box-right {
  margin-left: auto;
  margin-right: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

#ios-landing-author {
  display: flex;
  flex-direction: row;
  align-items: center;
  font: 12px HelveticaNeue;
}

#ios-landing-author-img {
  width: 16px;
  height: 16px;
  border-radius: 8px;
  margin-right: 8px;
}

#ios-landing-stats {
  margin-top: 8px;
  font: 10px HelveticaNeue;
}

.ios-landing-action-icon {
  width: 16px;
  height: 16px;
  filter: invert();
  /* makes the image white */
  margin-bottom: 16px;
}

.ios-landing-icon {
  width: 8px;
  height: 8px;
  filter: invert();
  /* makes the image white */
  margin-left: 12px;
  margin-right: 2px;
}

.ios-landing-icon:first-of-type {
  margin-left: 0px;
}

#ios-landing-try-button {
  height: 50px;
}

#ios-landing-logo-container {
  margin-top: -5vh;
}

#ios-landing-logo {
  width: 100px;
  margin-bottom: 8px;
  filter: invert();
}

/* Registered trademark mark next to the wordmark on the iOS landing
   screen. The wordmark PNG is white but gets inverted to black for the
   light landing background; the ® is just plain black text since this
   sibling element isn't affected by the wordmark's own filter. */
#ios-landing-trademark {
  display: inline-block;
  vertical-align: top;
  font: 10px HelveticaNeue, Helvetica, Arial, sans-serif;
  color: black;
  margin-left: 2px;
  margin-top: 2px;
  line-height: 1;
}

#mobile-404 {
  position: fixed;
  padding: 32px;
  font: 14px HelveticaNeue;
}

#build-info-fixed {
  position: fixed;
  bottom: 0px;
  right: 0px;
  font: 10px HelveticaNeue;
  background: black;
  color: white;
}

/* NOTE: there's an almost identical .app-store-button class in home/home.css, keep
   them in sync. */
.app-store-button {
  display: inline-block;
  flex-shrink: 0;
  height: 50px;
  width: 150px;
  background: url(/app-store-download-button.svg);
  background-repeat: no-repeat;
  background-size: contain;
}

#webgl-not-supported {
  position: fixed;
  top: 200px;
  background: white;
  width: 400px;
  left: calc(50vw - 200px);
  border-radius: 16px;
  border: 2px solid black;
  padding: 16px 16px 24px 16px;
  box-shadow: 4px 4px black;
}
#webgl-not-supported h1 { 
  color: #c00;
  font-size: 16px;
}

#loading-screen-v2 {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: black;
}

@keyframes kf-loading-screen-v2-fade-out {
  from { opacity: 1 }
  to { opacity: 0 }
}

.loading-screen-v2-fade-out {
  animation-name: kf-loading-screen-v2-fade-out;
  animation-duration: 0.1s;
  animation-fill-mode: both;
  animation-timing-function: ease-out;
}

#loading-screen-v2-canvas {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: black;
}

@keyframes loading-screen-v2-logo-anim {
  0% {
    opacity: 0;
    transform: translateY(50px);
  }
  99% {
    opacity: 1;
    transform: translateY(0px);
  }
}

#loading-screen-v2-logo {
  position: absolute;
  z-index: 2;
  width: 250px;
  left: calc(50vw - 125px);
  top: calc(50vh - 30px);
  opacity: 0;
  transform: translateY(50px);
  /* The container used to be an <img>; now it's a <span> wrapping the
     wordmark image and the ® text. display:block makes the transform
     above work the same way it did when the id was on the <img>. */
  display: block;
}

/* The wordmark image inside #loading-screen-v2-logo fills the container's
   width so it lands at the same 250px the old <img> rule produced. */
#loading-screen-v2-logo .logo-img {
  width: 100%;
  display: block;
}

/* Registered trademark mark, hung off the top-right corner of the
   wordmark. Absolutely positioned so it doesn't widen the 250px
   container, which would shift the animation's centered position. */
#loading-screen-v2-logo .logo-trademark {
  position: absolute;
  top: 0;
  left: 100%;
  margin-left: 3px;
  color: white;
  font: 14px HelveticaNeue, Helvetica, Arial, sans-serif;
  line-height: 1;
}

.loading-screen-v2-logo-anim {
  animation-name: loading-screen-v2-logo-anim;
  animation-duration: 1.00s;
  animation-timing-function: ease-out;
  animation-fill-mode: both;
}

#loading-screen-v2-title {
  position: absolute;
  z-index: 2;
  width: 80vw;
  left: 10vw;
  top: 100px;
  font-size: 48pt;
  font-weight: bold;
  text-align: center;
  color: white;
}

@keyframes loading-screen-v2-title-anim {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0px);
  }
}

.loading-screen-v2-title-anim {
  animation-name: loading-screen-v2-title-anim;
  animation-duration: 1.0s;
  animation-timing-function: ease-out;
  animation-fill-mode: both;
}

#loading-screen-v2-attribution {
  position: absolute;
  z-index: 2;
  width: 80vw;
  left: 10vw;
  top: 180px;
  font-size: 18pt;
  text-align: center;
  color: white;
}

.loading-screen-v2-attribution-anim {
  animation-name: fade-in;
  animation-duration: 1.0s;
  animation-timing-function: ease-out;
  animation-fill-mode: both;
}

@keyframes fade-in {
  from { opacity: 0 }
  to {opacity: 1 }
}

#loading-screen-v2-bar {
  position: absolute;
  z-index: 2;
  width: 300px;
  left: calc(50vw - 150px);
  bottom: 220px;
  height: 8px;
  background: #888;
  border-radius: 4px;
  overflow: hidden;
  padding: 0;
}

.loading-screen-v2-bar-anim {
  animation-name: fade-in;
  animation-delay: 0.5s;
  animation-duration: 1.0s;
  animation-timing-function: ease-out;
  animation-fill-mode: both;
}

#loading-screen-v2-status {
  position: absolute;
  z-index: 2;
  left: 8px;
  right: 8px;
  bottom: 16px;
  color: white;
  opacity: 0.5;
  text-align: center;
}

@keyframes loading-screen-v2-bar-inner-anim {
  0% { transform: translateX(-50px); }
  100% { transform: translateX(300px); }
}

#loading-screen-v2-bar-inner {
  display: inline-block;
  height: 20px;
  width: 50px;
  background: white;
  animation: loading-screen-v2-bar-inner-anim 2s infinite;
}

#ai-help-box {
  display: none;  /* changed to 'flex' when shown */
  flex-direction: column;
  position: fixed;
  backdrop-filter: blur(10px);
  bottom: 14px;
  height: 50vh;
  min-height: 400px;
  right: 14px;
  width: 26vw;
  min-width: 360px;
  z-index: 9999;
  overflow: hidden;
  border-radius: 16px;
  box-shadow: 4px 4px 7px rgba(0, 0, 0, 0.3);
}

#ai-help-bar {
  background: rgb(0 0 0 / 20%);
  min-height: 42px;
  padding: 6px 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  cursor: move;
}

#ai-help-bar > div:first-child {
  margin-left: 16px;
  flex-grow: 1;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

#ai-help-title {
  color: white;
}

#ai-help-subtitle {
  color: rgba(255, 255, 255, 0.7);
  font-size: 11px;
  line-height: 1.2;
  margin-top: 2px;
}

#ai-help-close {
  width: 36px;
  height: 36px;
  cursor: pointer;
  color: white;
  text-align: center;
  font-size: 22px;
  font-weight: 200;
}

#ai-help-content {
  flex-grow: 1;
  display: flex;
  min-height: 0;
}

#ai-help-iframe {
  width: 100%;
  border: none;
  flex-grow: 1;
  opacity: 0.9;
}

/* Shown inside #ai-help-content when the user has not consented to the chatbot. */
#ai-help-consent-prompt {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  padding: 20px;
  color: white;
  background: rgba(0, 0, 0, 0.25);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.45;
  gap: 14px;
  text-align: center;
}

#ai-help-consent-prompt button {
  align-self: center;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 6px;
  border: 1px solid white;
  background: white;
  color: #1d1f24;
  cursor: pointer;
}
#ai-help-consent-prompt button:hover { background: #f1f3f5; }
