* {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -ms-text-size-adjust: none;
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  -ms-content-zooming: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

html,
body {
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  overflow: hidden;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  background-color: #000;
  color: #fff;
}

a,
a:hover,
a:active,
a:visited {
  text-decoration: none;
  color: inherit;
}

#pano {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#titleBar {
  display: none !important;
}

.mobile #titleBar {
  height: 50px;
  right: 50px;
}

/* If there is a fullscreen button the title bar must make space for it */
body.fullscreen-enabled #titleBar {
  right: 80px;
}

body.fullscreen-enabled.mobile #titleBar {
  right: 100px;
}

/* If there are multiple scenes the title bar must make space for the scene list toggle */
body.multiple-scenes #titleBar {
  left: 40px;
}

body.multiple-scenes.mobile #titleBar {
  left: 50px;
}

#titleBar .sceneName {
  width: 100%;
  height: 100%;
  line-height: 30px;
  padding: 5px;
  background-color: rgb(58, 68, 84);
  background-color: rgba(58, 68, 84, 0.8);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.mobile #titleBar .sceneName {
  line-height: 40px;
}

#fullscreenToggle {
  display: none !important;
}

.mobile #fullscreenToggle {
  width: 50px;
  height: 50px;
}

body.fullscreen-enabled #fullscreenToggle {
  display: block;
}

#fullscreenToggle .icon {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 30px;
  height: 30px;
}

.mobile #fullscreenToggle .icon {
  top: 10px;
  right: 10px;
}

#fullscreenToggle .icon.on {
  display: none;
}

#fullscreenToggle .icon.off {
  display: block;
}

#fullscreenToggle.enabled .icon.on {
  display: block;
}

#fullscreenToggle.enabled .icon.off {
  display: none;
}

#autorotateToggle {
  display: none !important;
}

.mobile #autorotateToggle {
  width: 50px;
  height: 50px;
}

/* If there is a fullscreen button, autorotate must placed a bit to the left */
body.fullscreen-enabled #autorotateToggle {
  right: 40px;
}

body.fullscreen-enabled.mobile #autorotateToggle {
  right: 50px;
}

#autorotateToggle .icon {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 30px;
  height: 30px;
}

.mobile #autorotateToggle .icon {
  top: 10px;
  right: 10px;
}

#autorotateToggle .icon.on {
  display: none;
}

#autorotateToggle .icon.off {
  display: block;
}

#autorotateToggle.enabled .icon.on {
  display: block;
}

#autorotateToggle.enabled .icon.off {
  display: none;
}

#sceneListToggle {
  display: none !important;
}

.mobile #sceneListToggle {
  width: 50px;
  height: 50px;
}

#sceneListToggle .text {
  position: absolute;
  top: 5px;
  left: 15px;
  width: 100%;
  line-height: 30px;
}

#sceneListToggle .icon {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 30px;
  height: 30px;
}

.mobile #sceneListToggle .icon {
  top: 10px;
  right: 10px;
}

#sceneListToggle .icon.on {
  display: none;
}

#sceneListToggle .icon.off {
  display: block;
}

#sceneListToggle.enabled .icon.on {
  display: block;
}

#sceneListToggle.enabled .icon.off {
  display: none;
}

#sceneList {
  display: none !important;
  transition: margin-left 0.5s ease-in-out;
}

.mobile #sceneList {
  padding-top: 50px;
}

#sceneList .scenes {
  width: 100%;
  background-color: rgb(58, 68, 84);
  background-color: rgba(58, 68, 84, 0.8);
}

.mobile #sceneList {
  width: 100%;
  height: 100%;
  left: -100%;
}

.mobile #sceneList.enabled {
  margin-left: 100%;
}

.mobile #sceneList .scenes {
  height: 100%;
}

#sceneList.enabled {
  margin-left: 220px;
}

#sceneList .scene {
  display: block;
  width: 100%;
  height: 30px;
}

.mobile #sceneList .scene {
  height: 40px;
}

#sceneList .scene .text {
  width: 100%;
  height: 100%;
  padding: 0 15px;
  line-height: 30px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mobile #sceneList .scene .text {
  line-height: 40px;
}

.no-touch #sceneList .scene:hover {
  background-color: rgb(103, 115, 131);
  background-color: rgba(103, 115, 131, 0.8);
}

#sceneList .scene.current {
  background-color: rgb(103, 115, 131);
  background-color: rgba(103, 115, 131, 0.8);
}

/* Hide scene list when only a single scene exists */
body.single-scene #sceneList,
body.single-scene #sceneListToggle {
  display: none;
}

/* Link hotspot */

.link-hotspot {
  width: 60px;
  height: 60px;
  margin-left: -30px;
  margin-top: -30px;
  opacity: 0.9;
  -webkit-transition: opacity 0.2s;
  transition: opacity 0.2s;
}

.no-touch .link-hotspot:hover {
  opacity: 1;
}

.mobile .link-hotspot {
  width: 70px;
  height: 70px;
}

.link-hotspot-icon {
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.link-hotspot-tooltip {
  position: absolute;
  left: 100%;
  top: 14px; /* ( 60 - (16 + 2*8) ) / 2 */

  margin-left: 3px;

  font-size: 16px;

  max-width: 300px;

  padding: 8px 10px;

  border-radius: 5px;

  background-color: rgb(58, 68, 84);
  background-color: rgba(58, 68, 84, 0.8);

  color: #fff;

  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;

  cursor: pointer;

  opacity: 0;

  -ms-transform: translateX(-8px);
  -webkit-transform: translateX(-8px);
  transform: translateX(-8px);

  -webkit-transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    opacity 0.3s;
  transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    opacity 0.3s;
}

.mobile .link-hotspot {
  top: 19px; /* ( 70 - (16 + 2*8) ) / 2 */
}

.no-touch .link-hotspot:hover .link-hotspot-tooltip {
  opacity: 1;
  -ms-transform: translateX(0);
  -webkit-transform: translateX(0);
  transform: translateX(0);
}

/* Prevent tooltip from triggering */
.link-hotspot-tooltip {
  pointer-events: none;
}
.no-touch .link-hotspot:hover .link-hotspot-tooltip {
  pointer-events: all;
}

/* Fallback mode without pointer-events (IE8-10) */
.tooltip-fallback .link-hotspot-tooltip {
  display: none;
}
.no-touch .tooltip-fallback .link-hotspot:hover .link-hotspot-tooltip {
  display: block;
}

/* Info hotspot */

.info-hotspot {
  line-height: 1.2em;
  opacity: 0.9;
  -webkit-transition: opacity 0.2s 0.2s;
  transition: opacity 0.2s 0.2s;
}

.no-touch .info-hotspot:hover {
  opacity: 1;
  -webkit-transition: opacity 0.2s;
  transition: opacity 0.2s;
}

.info-hotspot.visible {
  opacity: 1;
}

.info-hotspot .info-hotspot-header {
  width: 40px;
  height: 40px;
  border-radius: 20px;
  background-color: rgb(103, 115, 131);
  cursor: pointer;
  -webkit-transition: width 0.3s ease-in-out 0.5s,
    border-radius 0.3s ease-in-out 0.5s;
  transition: width 0.3s ease-in-out 0.5s, border-radius 0.3s ease-in-out 0.5s;
}

.mobile .info-hotspot .info-hotspot-header {
  width: 50px;
  height: 50px;
  border-radius: 25px;
}

.desktop.no-touch .info-hotspot .info-hotspot-header:hover {
  width: 260px;
  border-radius: 5px;
  -webkit-transition: width 0.3s ease-in-out, border-radius 0.3s ease-in-out;
  transition: width 0.3s ease-in-out, border-radius 0.3s ease-in-out;
}

.desktop .info-hotspot.visible .info-hotspot-header,
.desktop.no-touch .info-hotspot.visible .info-hotspot-header:hover {
  width: 260px;
  border-radius: 5px;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
  border-bottom-left-radius: 0;
  -webkit-transition: width 0.3s ease-in-out, border-radius 0.3s ease-in-out;
  transition: width 0.3s ease-in-out, border-radius 0.3s ease-in-out;
}

.info-hotspot .info-hotspot-icon-wrapper {
  width: 40px;
  height: 40px;
}

.mobile .info-hotspot .info-hotspot-icon-wrapper {
  width: 50px;
  height: 50px;
}

.info-hotspot .info-hotspot-icon {
  width: 90%;
  height: 90%;
  margin: 5%;
}

.info-hotspot .info-hotspot-title-wrapper {
  position: absolute;
  left: 40px;
  top: 0;
  width: 0;
  height: 40px;
  padding: 0;
  overflow: hidden;
  -webkit-transition: width 0s 0.4s, padding 0s 0.4s;
  transition: width 0s 0.4s, padding 0s 0.4s;
}

.desktop .info-hotspot.visible .info-hotspot-title-wrapper,
.desktop.no-touch
  .info-hotspot
  .info-hotspot-header:hover
  .info-hotspot-title-wrapper {
  width: 220px;
  padding: 0 5px;
  -webkit-transition: width 0s 0.4s, padding 0s 0.4s;
  transition: width 0s 0.4s, padding 0s 0.4s;
}

.info-hotspot .info-hotspot-title-wrapper:before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  height: 100%;
}

.info-hotspot .info-hotspot-title {
  display: inline-block;
  vertical-align: middle;

  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.info-hotspot .info-hotspot-close-wrapper {
  position: absolute;
  left: 260px;
  top: 0;
  height: 40px;
  width: 40px;
  border-top-right-radius: 5px;
  background-color: rgb(78, 88, 104);
  visibility: hidden;
  -ms-transform: perspective(200px) rotateY(90deg);
  -webkit-transform: perspective(200px) rotateY(90deg);
  transform: perspective(200px) rotateY(90deg);
  -ms-transform-origin: 0 50% 0;
  -webkit-transform-origin: 0 50% 0;
  transform-origin: 0 50% 0;
  -webkit-transition: -ms-transform 0.3s 0.3s, -webkit-transform 0.3s 0.3s,
    transform 0.3s 0.3s, visibility 0s 0.6s;
  transition: -ms-transform 0.3s 0.3s, -webkit-transform 0.3s 0.3s,
    transform 0.3s 0.3s, visibility 0s 0.6s;
}

.desktop .info-hotspot.visible .info-hotspot-close-wrapper {
  visibility: visible;
  -ms-transform: perspective(200px) rotateY(0deg);
  -webkit-transform: perspective(200px) rotateY(0deg);
  transform: perspective(200px) rotateY(0deg);
  -webkit-transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    visibility 0s 0s;
  transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    visibility 0s 0s;
}

.info-hotspot .info-hotspot-close-icon {
  width: 70%;
  height: 70%;
  margin: 15%;
}

.info-hotspot .info-hotspot-text {
  position: absolute;
  width: 300px;
  height: auto;
  max-height: 200px;
  top: 40px;
  left: 0;
  padding: 10px;
  background-color: rgb(58, 68, 84);
  border-bottom-right-radius: 5px;
  border-bottom-left-radius: 5px;
  overflow-y: auto;
  visibility: hidden;
  /* rotate(90deg) causes transition flicker on Firefox 58 */
  -ms-transform: perspective(200px) rotateX(-89.999deg);
  -webkit-transform: perspective(200px) rotateX(-89.999deg);
  transform: perspective(200px) rotateX(-89.999deg);
  -ms-transform-origin: 50% 0 0;
  -webkit-transform-origin: 50% 0 0;
  transform-origin: 50% 0 0;
  -webkit-transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    visibility 0s 0.3s;
  transition: -ms-transform 0.3s, -webkit-transform 0.3s, transform 0.3s,
    visibility 0s 0.3s;

  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.desktop .info-hotspot.visible .info-hotspot-text {
  visibility: visible;
  -ms-transform: perspective(200px) rotateX(0deg);
  -webkit-transform: perspective(200px) rotateX(0deg);
  transform: perspective(200px) rotateX(0deg);
  -webkit-transition: -ms-transform 0.3s 0.3s, -webkit-transform 0.3s 0.3s,
    transform 0.3s 0.3s, visibility 0s 0s;
  transition: -ms-transform 0.3s 0.3s, -webkit-transform 0.3s 0.3s,
    transform 0.3s 0.3s, visibility 0s 0s;
}

/* Info hotspot modal */

.desktop .info-hotspot-modal {
  display: none;
}

.info-hotspot-modal {
  top: 0;
  left: 0;
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 11000 !important;
  background-color: rgba(0, 0, 0, 0.5);
  line-height: 1.2em;
  opacity: 0;
  visibility: hidden;
  -webkit-transition: opacity 0.2s ease-in-out 0.5s, visibility 0s 0.7s;
  transition: opacity 0.2s ease-in-out 0.5s, visibility 0s 0.7s;
}

.info-hotspot-modal.visible {
  opacity: 1;
  visibility: visible;
  -webkit-transition: opacity 0.2s ease-in-out, visibility 0s 0s;
  transition: opacity 0.2s ease-in-out, visibility 0s 0s;
}

.info-hotspot-modal .info-hotspot-header {
  position: absolute;
  top: 60px;
  left: 10px;
  right: 10px;
  width: auto;
  height: 50px;
  background-color: rgb(103, 115, 131);
  background-color: rgba(103, 115, 131, 0.8);
  opacity: 0;
  -webkit-transition: opacity 0.3s ease-in-out 0.2s;
  transition: opacity 0.3s ease-in-out 0.2s;
}

.info-hotspot-modal.visible .info-hotspot-header {
  opacity: 1;
  -webkit-transition: opacity 0.3s ease-in-out 0.2s;
  transition: opacity 0.3s ease-in-out 0.2s;
}

.info-hotspot-modal .info-hotspot-icon-wrapper {
  width: 50px;
  height: 50px;
}

.info-hotspot-modal .info-hotspot-icon {
  width: 90%;
  height: 90%;
  margin: 5%;
}

.info-hotspot-modal .info-hotspot-title-wrapper {
  position: absolute;
  top: 0;
  left: 50px;
  right: 50px;
  width: auto;
  height: 50px;
  padding: 0 10px;
}

.info-hotspot-modal .info-hotspot-title-wrapper:before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  height: 100%;
}

.info-hotspot-modal .info-hotspot-title {
  display: inline-block;
  vertical-align: middle;

  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.info-hotspot-modal .info-hotspot-close-wrapper {
  position: absolute;
  top: 0;
  right: 0;
  width: 50px;
  height: 50px;
  background-color: rgb(78, 88, 104);
  background-color: rgba(78, 88, 104, 0.8);
  cursor: pointer;
}

.info-hotspot-modal .info-hotspot-close-icon {
  width: 70%;
  height: 70%;
  margin: 15%;
}

.info-hotspot-modal .info-hotspot-text {
  position: absolute;
  top: 110px;
  bottom: 10px;
  left: 10px;
  right: 10px;
  padding: 10px;
  background-color: rgb(58, 68, 84);
  background-color: rgba(58, 68, 84, 0.8);
  overflow-y: auto;
  opacity: 0;
  -webkit-transition: opacity 0.3s ease-in-out;
  transition: opacity 0.3s ease-in-out;

  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

.info-hotspot-modal.visible .info-hotspot-text {
  opacity: 1;
  -webkit-transition: opacity 0.3s ease-in-out 0.4s;
  transition: opacity 0.3s ease-in-out 0.4s;
}

/* View control buttons */

.viewControlButton {
  display: none;
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 40px;
  height: 40px;
  padding: 5px;
  background-color: rgb(103, 115, 131);
  background-color: rgba(103, 115, 131, 0.8);
}

body.view-control-buttons .viewControlButton {
  display: block;
}

/* Hide controls when width is too small */
@media (max-width: 600px) {
  body.view-control-buttons .viewControlButton {
    display: none;
  }
}

.viewControlButton .icon {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 30px;
  height: 30px;
}

/* Center is at margin-left: -20px */
.viewControlButton-1 {
  margin-left: -145px;
}
.viewControlButton-2 {
  margin-left: -95px;
}
.viewControlButton-3 {
  margin-left: -45px;
}
.viewControlButton-4 {
  margin-left: 5px;
}
.viewControlButton-5 {
  margin-left: 55px;
}
.viewControlButton-6 {
  margin-left: 105px;
}

/* ========================================
   VIDEO CONVERSION PANELS
   ======================================== */

/* Video Panel Base Styles */
.video-panel {
  position: relative;
  width: 340px;
  max-width: 340px;
  min-width: 320px;
  height: 600px;
  background: rgba(37, 34, 28, 0.25);
  border-radius: 16px;
  padding: 0;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  overflow: hidden;
  transition: all 0.3s ease;
  /* Center the hotspot using negative margins */
  margin-left: -170px;
  margin-top: -220px;
  display: flex;
  flex-direction: column;
}

.video-panel:hover {
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.6);
  border-color: rgba(37, 34, 28, 0.5);
  transform: translateY(-3px);
  background: rgba(37, 34, 28, 0.35);
}

.video-panel-header {
  background: rgba(37, 34, 28, 0.2);
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  gap: 12px;
}

.video-panel-icon {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(37, 34, 28, 0.3);
  border-radius: 6px;
}

.video-panel-icon svg {
  width: 18px;
  height: 18px;
  color: #fff;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.video-panel-title {
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  margin: 0;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.video-panel-body {
  padding: 20px 18px;
  position: relative;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

/* ========================================
   UPLOAD PANEL (Panel 1)
   ======================================== */

.upload-zone {
  border: 2px dashed rgba(37, 34, 28, 0.4);
  border-radius: 12px;
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(37, 34, 28, 0.15);
}

.upload-zone:hover {
  border-color: rgba(37, 34, 28, 0.6);
  background: rgba(37, 34, 28, 0.25);
}

.upload-zone.dragover {
  border-color: rgba(37, 34, 28, 0.8);
  background: rgba(37, 34, 28, 0.35);
  transform: scale(1.02);
}

.upload-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 12px;
  opacity: 0.7;
}

.upload-text {
  font-size: 14px;
  color: #fff;
  margin-bottom: 6px;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.upload-subtext {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 3px;
  line-height: 1.3;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.upload-file-input {
  display: none;
}

.file-info {
  background: rgba(35, 50, 80, 0.7);
  border-radius: 10px;
  padding: 16px;
  margin-top: 16px;
  display: none;
  border: 1px solid rgba(250, 240, 220, 0.3);
}

.file-info.visible {
  display: block;
}

.file-name {
  font-size: 14px;
  color: #fff;
  margin-bottom: 8px;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.file-size {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.upload-progress-bar {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  margin-top: 12px;
  overflow: hidden;
}

.upload-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #00d4ff, #00a8cc);
  width: 0%;
  transition: width 0.3s ease;
}

/* Video Preview Container */
.video-preview-container {
  margin-top: 16px;
}

.video-preview-player {
  width: 100%;
  border-radius: 10px;
  background: #000;
  margin-bottom: 12px;
  max-height: 180px;
  object-fit: cover;
}

.video-file-name {
  font-size: 13px;
  color: #fff;
  margin-bottom: 6px;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Upload Actions */
.upload-actions {
  margin-top: 16px;
  display: flex;
  justify-content: center;
}

.delete-reset-btn {
  display: flex;
  align-items: center;
  margin: 0 auto;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(255, 60, 60, 0.15);
  border: 1px solid rgba(255, 80, 80, 0.5);
  border-radius: 8px;
  color: #ff6b6b;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.delete-reset-btn:hover {
  background: rgba(255, 60, 60, 0.25);
  border-color: rgba(255, 80, 80, 0.7);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 80, 80, 0.3);
}

.delete-reset-btn svg {
  width: 16px;
  height: 16px;
}

/* Upload Privacy Note */
.upload-privacy-note {
  margin-top: 14px;
  padding: 12px;
  background: rgba(40, 55, 85, 0.5);
  border-radius: 8px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
  line-height: 1.4;
  border: 1px solid rgba(255, 255, 255, 0.15);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Upload Disclaimer (beta info + support email) */
.upload-disclaimer {
  margin-top: 14px;
  padding: 10px 12px;
  background: rgba(37, 34, 28, 0.22);
  border-radius: 8px;
  border: 1px dashed rgba(255, 255, 255, 0.25);
  font-size: 11px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.9);
  text-align: left;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.upload-disclaimer b {
  color: #ffe4b5;
}

.upload-disclaimer a {
  color: #ffd399;
  text-decoration: underline;
}

/* ========================================
   CONFIGURE PANEL (Panel 2)
   ======================================== */

.config-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.config-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.config-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.95);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.config-select,
.config-input {
  background: rgba(37, 34, 28, 0.2);
  border: 1px solid rgba(37, 34, 28, 0.4);
  border-radius: 6px;
  padding: 8px 10px;
  color: #fff;
  font-size: 13px;
  outline: none;
  transition: all 0.2s ease;
}

.config-select:hover,
.config-input:hover {
  background: rgba(37, 34, 28, 0.3);
  border-color: rgba(37, 34, 28, 0.5);
}

.config-select:focus,
.config-input:focus {
  background: rgba(37, 34, 28, 0.4);
  border-color: rgba(37, 34, 28, 0.6);
  box-shadow: 0 0 0 3px rgba(37, 34, 28, 0.2);
}

.config-select option {
  background: #2c3340;
  color: #fff;
}

.config-range {
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.2);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.config-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #f5ebd5;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.config-range::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #f5ebd5;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.range-value {
  display: inline-block;
  margin-left: 8px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.95);
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.config-subtext {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 3px;
  line-height: 1.3;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 24px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.3s ease;
}

.toggle-switch.active {
  background: #f5ebd5;
}

.toggle-slider {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.toggle-switch.active .toggle-slider {
  transform: translateX(24px);
}

.convert-btn {
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #f5ebd5, #c89860);
  border: none;
  border-radius: 50px;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: none;
  letter-spacing: 0.5px;
  box-shadow: 0 6px 20px rgba(245, 235, 215, 0.4),
    0 0 25px rgba(250, 240, 220, 0.15);
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.convert-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.convert-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s;
}

.convert-btn:hover::before {
  left: 100%;
}

.convert-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(245, 235, 215, 0.6),
    0 0 35px rgba(250, 240, 220, 0.25);
  background: linear-gradient(135deg, #e0b584, #f5ebd5);
}

.convert-btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 15px rgba(245, 235, 215, 0.4);
}

.convert-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
  background: rgba(60, 75, 95, 0.5);
  color: rgba(255, 255, 255, 0.5);
}

.convert-btn:disabled::before {
  display: none;
}

/* ========================================
   PROGRESS PANEL (Panel 3)
   ======================================== */

.progress-steps {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.progress-step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  background: rgba(37, 34, 28, 0.15);
  border-radius: 6px;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.progress-step.active {
  background: rgba(37, 34, 28, 0.25);
  border-left: 3px solid rgba(37, 34, 28, 0.8);
  border-color: rgba(37, 34, 28, 0.4);
}

.progress-step.completed {
  background: rgba(76, 175, 80, 0.25);
  border-left: 3px solid #4caf50;
  border-color: rgba(76, 175, 80, 0.3);
}

.progress-step-number {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(37, 34, 28, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
  border: 1px solid rgba(37, 34, 28, 0.5);
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.progress-step.active .progress-step-number {
  background: rgba(37, 34, 28, 0.6);
  border-color: rgba(37, 34, 28, 0.8);
  animation: pulse 1.5s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(37, 34, 28, 0.5);
}

.progress-step.completed .progress-step-number {
  background: #4caf50;
  border-color: #4caf50;
  box-shadow: 0 0 6px rgba(76, 175, 80, 0.4);
}

.progress-step.error {
  background: rgba(244, 67, 54, 0.25);
  border-left: 3px solid #f44336;
  border-color: rgba(244, 67, 54, 0.3);
}

.progress-step.error .progress-step-number {
  background: #f44336;
  border-color: #f44336;
  box-shadow: 0 0 6px rgba(244, 67, 54, 0.4);
}

.progress-step-text {
  flex: 1;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.3;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.progress-step.active .progress-step-text {
  color: #fff;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

.progress-overall {
  margin-top: 12px;
  padding: 12px;
  background: rgba(37, 34, 28, 0.2);
  border-radius: 8px;
  border: 1px solid rgba(37, 34, 28, 0.4);
}

.progress-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.progress-percentage {
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(
    90deg,
    rgba(37, 34, 28, 0.6),
    rgba(37, 34, 28, 0.8)
  );
  width: 0%;
  transition: width 0.3s ease;
  border-radius: 4px;
  box-shadow: 0 0 10px rgba(37, 34, 28, 0.5);
}

.progress-eta {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 6px;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
}

/* ========================================
   HISTORY PANEL (Panel 4)
   ======================================== */

.history-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 480px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 4px;
}

.history-list::-webkit-scrollbar {
  width: 6px;
}

.history-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb {
  background: rgba(37, 34, 28, 0.5);
  border-radius: 3px;
}

.history-list::-webkit-scrollbar-thumb:hover {
  background: rgba(37, 34, 28, 0.7);
}

.history-item {
  background: rgba(37, 34, 28, 0.2);
  border: 1px solid rgba(37, 34, 28, 0.4);
  border-radius: 8px;
  padding: 12px;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.history-item:hover {
  background: rgba(37, 34, 28, 0.3);
  border-color: rgba(37, 34, 28, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.history-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.history-item-icon {
  width: 36px;
  height: 36px;
  background: rgba(37, 34, 28, 0.3);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.history-item-icon svg {
  width: 20px;
  height: 20px;
  color: #fff;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.history-item-info {
  flex: 1;
  min-width: 0;
}

.history-item-name {
  font-size: 13px;
  font-weight: 500;
  color: #fff;
  margin-bottom: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.history-item-date {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.7);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.history-item-actions {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.history-action-btn {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid rgba(37, 34, 28, 0.5);
  border-radius: 6px;
  background: rgba(37, 34, 28, 0.25);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.history-action-btn svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.history-action-btn:hover {
  background: rgba(37, 34, 28, 0.4);
  border-color: rgba(37, 34, 28, 0.7);
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.history-action-btn.play-btn {
  background: linear-gradient(135deg, #f5ebd5, #c89860);
  border-color: rgba(245, 235, 215, 0.5);
  box-shadow: 0 2px 8px rgba(245, 235, 215, 0.3);
}

.history-action-btn.play-btn:hover {
  background: linear-gradient(135deg, #e0b584, #f5ebd5);
  box-shadow: 0 4px 12px rgba(245, 235, 215, 0.5);
}

.history-action-btn.download-btn:hover {
  background: rgba(37, 34, 28, 0.5);
}

.history-empty {
  text-align: center;
  padding: 40px 20px;
  color: rgba(255, 255, 255, 0.7);
}

.history-empty-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  opacity: 0.5;
}

.history-empty-icon svg {
  width: 100%;
  height: 100%;
  color: rgba(255, 255, 255, 0.5);
}

.history-empty-text {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.history-empty-subtext {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* ========================================
   VIDEO PLAYER
   ======================================== */

.video-player-container {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 95%;
  max-width: 1400px;
  max-height: 95vh;
  background: linear-gradient(
    135deg,
    rgba(20, 25, 35, 0.98),
    rgba(35, 42, 55, 0.98)
  );
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
  z-index: 10000;
  overflow: auto;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
}

.video-player-header {
  padding: 20px 24px;
  background: linear-gradient(
    135deg,
    rgba(100, 108, 255, 0.15),
    rgba(52, 152, 219, 0.15)
  );
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.video-player-header h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: #fff;
}

.video-close-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
}

.video-close-btn:hover {
  background: rgba(255, 59, 48, 0.9);
  transform: scale(1.05);
}

.video-close-btn svg {
  color: #fff;
  width: 20px;
  height: 20px;
}

.video-close-btn img {
  width: 20px;
  height: 20px;
  filter: brightness(0) invert(1);
}

.video-player-wrapper {
  padding: 0;
  background: #000;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  position: relative;
}

.vr-video-element {
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
  background: #000;
}

/* Stereo mode - side by side display */
.video-player-wrapper.stereo-mode .vr-video-element {
  object-fit: cover;
}

/* Active button state */
.vr-control-btn.active {
  background: rgba(76, 175, 80, 0.3) !important;
  border-color: rgba(76, 175, 80, 0.5) !important;
}

.video-player-controls {
  padding: 20px 24px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
  background: rgba(255, 255, 255, 0.03);
}

.vr-control-btn {
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.vr-control-btn:hover {
  background: rgba(100, 108, 255, 0.3);
  border-color: rgba(100, 108, 255, 0.5);
  transform: translateY(-2px);
}

.vr-control-btn img {
  width: 18px;
  height: 18px;
  filter: brightness(0) invert(1);
}

.vr-control-btn svg {
  width: 18px;
  height: 18px;
}

.vr-control-btn-reset {
  background: rgba(255, 152, 0, 0.2);
  border-color: rgba(255, 152, 0, 0.4);
}

.vr-control-btn-reset:hover {
  background: rgba(255, 152, 0, 0.4);
  border-color: rgba(255, 152, 0, 0.6);
}

.video-player-info {
  padding: 20px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.video-info-item {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

.video-info-item strong {
  color: #fff;
  margin-right: 6px;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
  .video-panel {
    min-width: 280px;
    max-width: 95%;
  }

  .video-panel-body {
    padding: 20px 16px;
  }

  .upload-zone {
    padding: 30px 16px;
  }

  .config-form {
    gap: 16px;
  }

  .video-player-container {
    width: 95%;
    max-width: none;
  }

  .video-player-controls {
    gap: 8px;
  }

  .vr-control-btn {
    padding: 8px 12px;
    font-size: 12px;
  }

  .vr-control-btn span {
    display: none;
  }

  .video-player-info {
    gap: 12px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .video-panel {
    min-width: 260px;
  }

  .video-panel-header {
    padding: 12px 16px;
  }

  .video-panel-title {
    font-size: 16px;
  }

  .video-player-header {
    padding: 16px 20px;
  }

  .video-player-header h3 {
    font-size: 18px;
  }

  .video-player-wrapper {
    padding: 0;
    min-height: 300px;
  }

  .vr-video-element {
    max-height: 50vh;
  }

  .video-player-header h3 {
    font-size: 16px;
  }

  .video-close-btn {
    padding: 8px;
    min-width: 36px;
    min-height: 36px;
  }
}

/* ========================================
   CARD-BASED INFO HOTSPOT WITH YOUTUBE EMBED
   ======================================== */

.card-title-text {
  position: absolute;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
  white-space: nowrap;
  transition: transform 0.3s ease;
  pointer-events: none;
}

.card-hotspot:hover .card-title-text {
  transform: translateX(-50%) scale(1.05);
}

.card-hotspot {
  /* Center the card using negative margins */
  margin-left: -250px;
  margin-top: -140px;
  perspective: 1000px;
  opacity: 0.95;
  transition: opacity 0.3s ease;
}

.card-hotspot:hover {
  opacity: 1;
}

.card3d {
  position: relative;
  width: 500px;
  height: 280px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s ease-out, box-shadow 0.3s ease;
  transform-style: preserve-3d;
  background: linear-gradient(
    135deg,
    rgba(40, 50, 70, 0.95),
    rgba(30, 40, 60, 0.95)
  );
  cursor: pointer;
}

.card3d:hover {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
}

.card-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 12px;
}

.card-cap {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 16px;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.9),
    rgba(0, 0, 0, 0.7),
    transparent
  );
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  pointer-events: none;
  -moz-user-select: text;
  -webkit-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

/* Mobile adjustments for card hotspot */
@media (max-width: 768px) {
  .card-hotspot {
    margin-left: -125px;
    margin-top: -90px;
  }

  .card3d {
    width: 250px;
    height: 167px;
  }

  .card-cap {
    font-size: 12px;
    padding: 10px 12px;
  }
}

@media (max-width: 480px) {
  .card-hotspot {
    margin-left: -100px;
    margin-top: -75px;
  }

  .card3d {
    width: 200px;
    height: 133px;
  }

  .card-cap {
    font-size: 11px;
    padding: 8px 10px;
  }
}


/* ========================================
   VR LOOK-AROUND BUTTON
   ======================================== */

#vrLookToggle {
  position: absolute;
  bottom: 20px;
  right: 20px;
  z-index: 20000;

  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.4);

  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;

  cursor: pointer;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.7);

  display: flex;
  align-items: center;
  justify-content: center;
}

#vrLookToggle.enabled {
  background: rgba(76, 175, 80, 0.9);
  border-color: rgba(129, 199, 132, 1);
  box-shadow: 0 0 18px rgba(129, 199, 132, 0.8);
}

#vrLookToggle:active {
  transform: scale(0.97);
}

/* Make it a bit smaller on phones */
@media (max-width: 768px) {
  #vrLookToggle {
    bottom: 16px;
    right: 16px;
    padding: 8px 14px;
    font-size: 12px;
  }
}
