/*
 * The archived Facebook and Instagram photo-import APIs are no longer usable.
 * Keep the original upload design, but expose only the working local upload.
 */
.add-steps-upload-methods-text-facebook,
.add-steps-upload-methods-text-instagram {
  display: none !important;
}

.add-steps-upload-methods-icons-container .circle-btn-symbol-local {
  left: 60px;
}

.archive-recreation-credit {
  position: absolute;
  top: -9px;
  left: -104px;
  width: 136px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  letter-spacing: 0.4px;
  line-height: 18px;
  text-align: center;
  pointer-events: none;
}

.footer-recreation-credit {
  cursor: default;
  font-size: 10px;
  line-height: normal;
  text-transform: none;
}

/* Mobile landscape tuning for the React migration preview only. */
html.react-modern-mobile,
html.react-modern-mobile body,
html.react-modern-mobile canvas {
  touch-action: none;
  overscroll-behavior: none;
}

html.react-modern-mobile body,
html.react-modern-mobile .app,
html.react-modern-mobile canvas,
html.react-modern-mobile .scene-3d {
  -webkit-user-select: none !important;
  user-select: none !important;
  -webkit-touch-callout: none !important;
  -webkit-tap-highlight-color: transparent !important;
  outline: 0 !important;
}

html.react-modern-mobile input,
html.react-modern-mobile textarea,
html.react-modern-mobile [contenteditable="true"] {
  -webkit-user-select: text !important;
  user-select: text !important;
}

html.react-modern-shell .mobile-zoom-controls {
  position: absolute;
  z-index: 3;
  left: -10px;
  top: 100px;
  width: 112px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  box-sizing: border-box;
  padding: 0 5px;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 16px;
  background: transparent;
  box-shadow: none;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(0, -5px, 0);
  transition: opacity .25s ease, transform .3s cubic-bezier(.22, .8, .22, 1);
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

html.react-modern-shell .mobile-zoom-controls.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translate3d(0, 0, 0);
}

html.react-modern-shell .mobile-zoom-button {
  flex: 0 0 24px;
  width: 24px;
  height: 28px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: rgba(255, 255, 255, .5);
  font: 300 20px/28px Arial, sans-serif;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

html.react-modern-shell .mobile-zoom-button:active {
  color: #fff;
  transform: scale3d(.88, .88, 1);
}

html.react-modern-shell .mobile-zoom-slider {
  flex: 1 1 auto;
  width: 42px;
  height: 28px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  touch-action: none;
}

html.react-modern-shell .mobile-zoom-slider::-webkit-slider-runnable-track {
  height: 1px;
  border: 0;
  background: rgba(255, 255, 255, .25);
}

html.react-modern-shell .mobile-zoom-slider::-webkit-slider-thumb {
  width: 9px;
  height: 9px;
  margin-top: -4px;
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 50%;
  background: rgba(255, 255, 255, .55);
  box-shadow: none;
  -webkit-appearance: none;
  appearance: none;
}

html.react-modern-shell .mobile-zoom-slider::-moz-range-track {
  height: 1px;
  border: 0;
  background: rgba(255, 255, 255, .25);
}

html.react-modern-shell .mobile-zoom-slider::-moz-range-thumb {
  width: 9px;
  height: 9px;
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 50%;
  background: rgba(255, 255, 255, .55);
}

html.react-modern-shell .mobile-zoom-controls:hover,
html.react-modern-shell .mobile-zoom-controls:focus-within {
  border-color: rgba(255, 255, 255, .55);
}

html.react-modern-shell .mobile-zoom-controls:hover .mobile-zoom-button,
html.react-modern-shell .mobile-zoom-controls:focus-within .mobile-zoom-button {
  color: rgba(255, 255, 255, .9);
}

html.react-modern-shell .nav.mobile-zoom-visible .nav-search-wrapper {
  margin-top: 44px;
}

@media (orientation: portrait) and (max-width: 600px) {
  html.react-modern-mobile .preloader {
    margin-top: -78px !important;
  }

  html.react-modern-mobile .preloader-text {
    width: 84vw !important;
    margin: 0 auto !important;
    font-size: 17px !important;
    line-height: 24px !important;
    letter-spacing: .35px !important;
  }

  html.react-modern-mobile .preloader-mobile-line {
    display: block;
  }

  html.react-modern-mobile .preloader-remember {
    white-space: nowrap;
  }

  html.react-modern-mobile .preloader-text-line-2,
  html.react-modern-mobile .preloader-text-line-4 {
    margin-top: 12px;
  }
}


@media (orientation: landscape) and (max-width: 1000px),
       (orientation: landscape) and (max-height: 600px) {
  html.react-modern-mobile .header {
    height: 68px !important;
  }

  html.react-modern-mobile .header-content {
    top: 0 !important;
    height: 68px !important;
  }

  html.react-modern-mobile .header-logo {
    left: max(18px, env(safe-area-inset-left)) !important;
    top: 18px !important;
    transform: scale3d(.56, .56, 1) !important;
    transform-origin: 0 0 !important;
  }

  html.react-modern-mobile .header-description {
    top: 17px !important;
    right: calc(max(16px, env(safe-area-inset-right)) + 62px) !important;
    max-width: 155px;
    font-size: 9px !important;
    line-height: 11px !important;
    letter-spacing: .2px !important;
  }

  html.react-modern-mobile .header-fade-container {
    top: 8px !important;
    right: max(12px, env(safe-area-inset-right)) !important;
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
  }

  html.react-modern-mobile .header-fade-percent,
  html.react-modern-mobile.is-mac .header-fade-percent {
    margin-top: 9px !important;
    padding-right: 7px !important;
    font-size: 11px !important;
    line-height: 14px !important;
  }

  html.react-modern-mobile .header-fade-percent-num {
    font-size: 20px !important;
  }

  html.react-modern-mobile .header-fade-percent-symbol {
    right: -2px !important;
  }

  html.react-modern-mobile .header-fade-percent-text {
    margin-top: -1px !important;
    font-size: 6px !important;
    line-height: 7px !important;
  }

  html.react-modern-mobile .footer,
  html.react-modern-mobile .footer-content {
    height: 56px !important;
  }

  html.react-modern-mobile .footer-content {
    bottom: 0 !important;
    padding-right: max(12px, env(safe-area-inset-right));
  }

  html.react-modern-mobile .footer-link-item {
    margin-top: 31px !important;
    margin-left: 14px !important;
    font-size: 8px !important;
  }

  html.react-modern-mobile .footer-sound-btn {
    margin-top: 23px !important;
    transform: scale3d(.8, .8, 1) !important;
  }

  html.react-modern-mobile .add-steps-upload-methods-icons-container .circle-btn-symbol-local {
    left: 0 !important;
  }

  html.react-modern-mobile .archive-recreation-credit {
    top: 48px !important;
    left: -85px !important;
    width: 170px !important;
    font-size: 10px !important;
  }

  html.react-modern-mobile .post-2d-center-wrapper {
    left: 7vw !important;
    top: 19vh !important;
    width: 86vw !important;
    height: 62vh !important;
    margin: 0 !important;
  }

  html.react-modern-mobile .post-2d-img {
    width: calc(86vw - min(34vw, 260px)) !important;
    height: 100% !important;
    background-position: center center !important;
    background-size: cover !important;
  }

  html.react-modern-mobile .post-2d-content-wrapper {
    width: 348px;
    max-width: min(34vw, 260px) !important;
    height: 100% !important;
    overflow: hidden !important;
  }

  html.react-modern-mobile .post-2d-content-wrapper .scroll-indicator-wrapper {
    left: auto !important;
    right: 0 !important;
  }

  html.react-modern-mobile .post-2d-content {
    left: 22px !important;
    width: calc(100% - 44px) !important;
    font-size: 13px !important;
    line-height: 18px !important;
  }

  html.react-modern-mobile .post-2d-content-top {
    width: 100% !important;
    height: 54px !important;
  }

  html.react-modern-mobile .post-2d-matched-wrapper {
    display: none !important;
  }

  html.react-modern-mobile .post-2d-close-btn {
    top: 7px !important;
    right: 7px !important;
    z-index: 3;
  }

  html.react-modern-mobile .post-2d-message-wrapper {
    padding-top: clamp(66px, 18vh, 78px) !important;
  }

  html.react-modern-mobile .post-2d-name {
    margin-top: 10px !important;
    font-size: 15px !important;
    line-height: 18px !important;
  }

  html.react-modern-mobile .post-2d-share-container {
    display: none !important;
  }

  html.react-modern-mobile .post-2d-message-wrapper,
  html.react-modern-mobile .post-2d-name {
    transition: opacity .55s ease .28s, transform .7s cubic-bezier(.22, .8, .22, 1) .22s;
  }

  html.react-modern-mobile .post-2d.mobile-memory-opening .post-2d-message-wrapper,
  html.react-modern-mobile .post-2d.mobile-memory-opening .post-2d-name {
    opacity: 0;
    transform: translate3d(0, 16px, 0);
  }

  html.react-modern-mobile .post-2d.mobile-memory-open .post-2d-message-wrapper,
  html.react-modern-mobile .post-2d.mobile-memory-open .post-2d-name {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@media (orientation: portrait) and (max-width: 700px) {
  html.react-modern-mobile .header {
    height: 104px !important;
  }

  html.react-modern-mobile .header-content {
    top: 0 !important;
    height: 104px !important;
  }

  html.react-modern-mobile .header-logo {
    left: max(18px, env(safe-area-inset-left)) !important;
    top: 22px !important;
    transform: scale3d(.52, .52, 1) !important;
    transform-origin: 0 0 !important;
  }

  html.react-modern-mobile .header-description {
    left: max(20px, env(safe-area-inset-left)) !important;
    right: auto !important;
    top: 60px !important;
    width: 175px !important;
    text-align: left !important;
    font-size: 9px !important;
    line-height: 11px !important;
    letter-spacing: .2px !important;
  }

  html.react-modern-mobile .header-fade-container {
    top: 14px !important;
    right: max(16px, env(safe-area-inset-right)) !important;
    width: 70px !important;
    height: 70px !important;
    border-radius: 50% !important;
  }

  html.react-modern-mobile .header-fade-percent,
  html.react-modern-mobile.is-mac .header-fade-percent {
    margin-top: 15px !important;
    padding-right: 9px !important;
    font-size: 14px !important;
    line-height: 17px !important;
  }

  html.react-modern-mobile .header-fade-percent-num {
    font-size: 28px !important;
  }

  html.react-modern-mobile .header-fade-percent-symbol {
    right: -3px !important;
  }

  html.react-modern-mobile .header-fade-percent-text {
    margin-top: 0 !important;
    font-size: 7px !important;
    line-height: 8px !important;
  }

  html.react-modern-mobile .footer,
  html.react-modern-mobile .footer-content {
    height: 50px !important;
  }

  html.react-modern-mobile .footer-content {
    bottom: 0 !important;
    display: flex !important;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 max(10px, env(safe-area-inset-right)) 0 max(10px, env(safe-area-inset-left));
  }

  html.react-modern-mobile .footer-content > * {
    float: none !important;
    flex: 0 0 auto;
    margin: 0 !important;
    white-space: nowrap;
  }

  html.react-modern-mobile .footer-link-item {
    font-size: 7px !important;
    letter-spacing: 0 !important;
  }

  html.react-modern-mobile .footer-sound-btn {
    transform: scale3d(.72, .72, 1) !important;
  }

  html.react-modern-mobile .post-2d-center-wrapper {
    left: 6vw !important;
    top: 9vh !important;
    width: 88vw !important;
    height: 82vh !important;
    margin: 0 !important;
  }

  html.react-modern-mobile .post-2d-img {
    float: none !important;
    width: 100% !important;
    height: 44% !important;
    background-position: center center !important;
    background-size: cover !important;
  }

  html.react-modern-mobile .post-2d-content-wrapper {
    float: none !important;
    width: 100% !important;
    max-width: none !important;
    height: 56% !important;
    overflow: hidden !important;
  }

  html.react-modern-mobile .post-2d-content-top {
    width: 100% !important;
    height: 52px !important;
  }

  html.react-modern-mobile .post-2d-close-btn {
    top: 7px !important;
    right: 7px !important;
    z-index: 3;
  }

  html.react-modern-mobile .post-2d-matched-wrapper,
  html.react-modern-mobile .post-2d-share-container {
    display: none !important;
  }

  html.react-modern-mobile .post-2d-content {
    left: 24px !important;
    width: calc(100% - 48px) !important;
    font-size: 14px !important;
    line-height: 20px !important;
  }

  html.react-modern-mobile .post-2d-message-wrapper {
    padding-top: 62px !important;
  }

  html.react-modern-mobile .post-2d-name {
    margin-top: 11px !important;
    font-size: 16px !important;
  }
}
