/* Custom 360 hotspot markers (admin + public) */

.pnlm-hotspot.re-360-hs-custom,
.pnlm-hotspot.re-hs-wrap {
  width: 52px !important;
  height: 52px !important;
  margin-left: -26px !important;
  margin-top: -26px !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  cursor: pointer !important;
  z-index: 5 !important;
}

.pnlm-hotspot.re-360-hs-custom .re-hs-marker {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  transform: scale(var(--re-hs-scale, 0.6));
  transform-origin: center center;
}

/* ---- Animated arrow ---- */
.re-hs-arrow .re-hs-arrow-core {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.55);
  border: 2px solid #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  position: relative;
}

.re-hs-arrow .re-hs-arrow-core::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 12px;
  margin: -8px 0 0 -6px;
  border-right: 3px solid #fff;
  border-bottom: 3px solid #fff;
  transform: rotate(45deg);
  animation: re-hs-bounce-y 1.05s ease-in-out infinite;
}

.re-hs-arrow.re-hs-dir-left .re-hs-arrow-core::after {
  transform: rotate(135deg);
  margin: -6px 0 0 -4px;
  animation-name: re-hs-bounce-x;
}
.re-hs-arrow.re-hs-dir-right .re-hs-arrow-core::after {
  transform: rotate(-45deg);
  margin: -6px 0 0 -8px;
  animation-name: re-hs-bounce-x;
}
.re-hs-arrow.re-hs-dir-up .re-hs-arrow-core::after {
  transform: rotate(-135deg);
  margin: -4px 0 0 -6px;
}
.re-hs-arrow.re-hs-dir-down .re-hs-arrow-core::after {
  transform: rotate(45deg);
  margin: -8px 0 0 -6px;
}
.re-hs-arrow.re-hs-dir-forward .re-hs-arrow-core::after {
  transform: rotate(45deg);
}

.re-hs-arrow.is-info .re-hs-arrow-core {
  background: rgba(180, 83, 9, 0.65);
}
.re-hs-arrow.is-link .re-hs-arrow-core {
  background: rgba(5, 150, 105, 0.65);
}

/* ---- Pulsing dot ---- */
.re-hs-dot .re-hs-dot-core {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #93c5fd, #2563eb 55%, #1d4ed8);
  border: 3px solid #fff;
  box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.55);
  animation: re-hs-pulse 1.5s ease-out infinite;
}
.re-hs-dot.is-info .re-hs-dot-core {
  background: radial-gradient(circle at 40% 35%, #fde68a, #f59e0b 55%, #d97706);
  box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.55);
}
.re-hs-dot.is-link .re-hs-dot-core {
  background: radial-gradient(circle at 40% 35%, #6ee7b7, #10b981 55%, #059669);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55);
}

/* ---- Ring ---- */
.re-hs-ring .re-hs-ring-core {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid #fff;
  background: rgba(37, 99, 235, 0.35);
  box-shadow: 0 0 0 0 rgba(96, 165, 250, 0.5);
  animation: re-hs-ring 1.7s ease-out infinite;
}

@keyframes re-hs-pulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.55); }
  70% { transform: scale(1.08); box-shadow: 0 0 0 14px rgba(37, 99, 235, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}
@keyframes re-hs-ring {
  0% { transform: scale(0.92); box-shadow: 0 0 0 0 rgba(96, 165, 250, 0.5); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 12px rgba(96, 165, 250, 0); }
  100% { transform: scale(0.92); box-shadow: 0 0 0 0 rgba(96, 165, 250, 0); }
}
@keyframes re-hs-bounce-y {
  0%, 100% { transform: translateY(0) rotate(45deg); opacity: 1; }
  50% { transform: translateY(4px) rotate(45deg); opacity: 0.85; }
}
@keyframes re-hs-bounce-x {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

/* Floor icons: drawn already foreshortened (ellipse / 3D chevron).
   Do NOT rotateX — Pannellum billboards hotspots and that flatten fails. */
.pnlm-hotspot.re-hs-floor {
  width: 128px !important;
  height: 88px !important;
  margin-left: -64px !important;
  margin-top: -28px !important;
  overflow: visible !important;
}

.re-hs-floor .re-hs-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.35));
  transform: scale(var(--re-hs-scale, 0.6));
  transform-origin: center center;
}

/* ---- Floor pulse: wide white oval + soft glow (reference photo) ---- */
.re-hs-pulse {
  position: relative;
  width: 108px;
  height: 48px;
}

.re-hs-pulse-glow {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 126px;
  height: 58px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(
    ellipse at center,
    rgba(255, 255, 255, 0.5) 0%,
    rgba(255, 255, 255, 0.18) 40%,
    rgba(255, 255, 255, 0) 72%
  );
  animation: re-hs-glow-breathe 1.55s ease-in-out infinite;
  pointer-events: none;
}

.re-hs-pulse-hoop {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 92px;
  height: 32px;
  margin: 0;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 6px solid #fff;
  background: transparent;
  box-sizing: border-box;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.75);
  animation: re-hs-hoop-breathe 1.55s ease-in-out infinite;
}

@keyframes re-hs-glow-breathe {
  0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(0.92); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
}

@keyframes re-hs-hoop-breathe {
  0%, 100% {
    border-width: 4px;
    opacity: 0.82;
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.4);
  }
  50% {
    border-width: 8px;
    opacity: 1;
    box-shadow: 0 0 16px rgba(255, 255, 255, 0.95);
  }
}

/* ---- Ground 3D chevron (reference photo: extruded bars + fade) ---- */
.re-hs-ground-svg {
  width: 118px;
  height: 88px;
  display: block;
  overflow: visible;
}

.re-hs-svg-front {
  animation: re-hs-svg-march 1.35s linear infinite;
}

.re-hs-svg-back {
  animation: re-hs-svg-march 1.35s linear infinite;
  animation-delay: -0.67s;
}

.re-hs-ground.re-hs-dir-left { transform: rotate(-90deg) scale(var(--re-hs-scale, 0.6)); }
.re-hs-ground.re-hs-dir-right { transform: rotate(90deg) scale(var(--re-hs-scale, 0.6)); }
.re-hs-ground.re-hs-dir-down { transform: rotate(180deg) scale(var(--re-hs-scale, 0.6)); }

@keyframes re-hs-svg-march {
  0% { transform: translateY(10px); opacity: 0; }
  16% { opacity: 1; }
  70% { opacity: 1; }
  100% { transform: translateY(-12px); opacity: 0; }
}

/* ---- 3D widgets (labels, buttons, posters) anchored on panorama ---- */
.pnlm-hotspot.re-hs-wide {
  width: auto !important;
  height: auto !important;
  min-width: 40px;
  min-height: 28px;
  margin-left: 0 !important;
  margin-top: 0 !important;
  transform: translate(-50%, -50%);
}

.re-hs-widget {
  pointer-events: none;
  max-width: 240px;
  white-space: normal;
  text-align: center;
}

.re-hs-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.45);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
}

.re-hs-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 10px;
  background: rgba(37, 99, 235, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.45);
}

.re-hs-heading {
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.65);
  padding: 4px 8px;
}

.re-hs-poster {
  background: rgba(15, 23, 42, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 12px;
  padding: 12px 14px;
  color: #f8fafc;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  text-align: left;
  min-width: 140px;
}

.re-hs-poster-title {
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 6px;
}

.re-hs-poster-body {
  font-size: 12px;
  line-height: 1.45;
  color: #cbd5e1;
}

.re-hs-html {
  max-width: 280px;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

.re-hs-html img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.pnlm-hotspot.re-hs-wide.is-clickable,
.re-hs-widget.is-clickable {
  cursor: pointer;
}

/* Freeze viewer while add-modal open */
body.re-360-modal-open #re-360-admin-viewer,
body.re-360-modal-open #re-360-admin-viewer .pnlm-container,
body.re-360-modal-open #re-360-admin-viewer .pnlm-render-container {
  pointer-events: none !important;
}
body.re-360-modal-open .re-360-modal,
body.re-360-modal-open .re-360-modal * {
  pointer-events: auto !important;
}
