:root { --location-pin-scale: 1; }

.location-pin-glow {
  position: absolute;
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%) scale(var(--location-pin-scale, 1));
  transform-origin: center center;
}

.location-pin-ring {
  position: absolute;
  left: 0;
  top: 0;
  width: 78px;
  height: 78px;
  margin-left: -39px;
  margin-top: -39px;
  border-radius: 50%;
  background: rgba(255, 235, 59, 0.32);
  box-shadow: 0 0 16px 8px rgba(255, 235, 59, 0.95), 0 0 34px 16px rgba(255, 193, 7, 0.55);
  animation: locationPinPulse 1.7s ease-out infinite;
}

.location-pin-ring.delay { animation-delay: 0.85s; }

@keyframes locationPinPulse {
  0% { transform: scale(0.32); opacity: 0.95; }
  70% { opacity: 0.4; }
  100% { transform: scale(1.7); opacity: 0; }
}

.place-pin-label {
  background: #ffffff !important;
  padding: 3px 8px !important;
  border-radius: 8px !important;
  font-weight: bold !important;
  white-space: nowrap;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.place-pin-label.place-pin-ship {
  color: #0D47A1 !important;
  border: 2px solid #1565C0 !important;
}

.place-pin-label.place-pin-use {
  color: #00695C !important;
  border: 2px solid #00897B !important;
}

.location-pin-label {
  background: #FFEB3B !important;
  color: #3E2723 !important;
  border: 2px solid #F57F17 !important;
  padding: 3px 8px !important;
  border-radius: 8px !important;
  font-weight: bold !important;
  box-shadow: 0 0 12px 3px rgba(255, 235, 59, 0.95);
  white-space: nowrap;
}

/* 大看板・小看板（束ね看板）のラベル強調 */
.signboard-label.sign-parent-label {
  background: #EDE7F6 !important;
  color: #4A148C !important;
  border: 2px solid #7E57C2 !important;
  padding: 2px 8px !important;
  border-radius: 8px !important;
  font-weight: bold !important;
  box-shadow: 0 2px 6px rgba(94, 53, 177, 0.28);
  white-space: nowrap;
}

.signboard-label.sign-parent-expanded {
  background: #6A1B9A !important;
  color: #ffffff !important;
  border: 2px solid #FFEB3B !important;
  padding: 3px 9px !important;
  border-radius: 8px !important;
  font-weight: bold !important;
  box-shadow: 0 0 10px 2px rgba(156, 39, 176, 0.65);
  white-space: nowrap;
}

.signboard-label.sign-child-expanded {
  background: #FFF8E1 !important;
  color: #BF360C !important;
  border: 2px solid #FF6F00 !important;
  padding: 3px 8px !important;
  border-radius: 8px !important;
  font-weight: bold !important;
  box-shadow: 0 2px 10px rgba(255, 111, 0, 0.45);
  white-space: nowrap;
}

/* ==========================================
   🔭 視野地点ピン選択UI（全体引き＋ピンタップで拡大）
   ========================================== */
.viewpoint-pin-wrap {
  position: absolute;
  left: 0;
  top: 0;
  transform: translate(-50%, -100%);
  z-index: 99999;
  pointer-events: auto;
  user-select: none;
  -webkit-user-select: none;
}

.viewpoint-pin-wrap:hover,
.viewpoint-pin-wrap:active,
.viewpoint-pin-wrap:focus-within {
  z-index: 100050;
}

.viewpoint-pin-ground {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 0;
  height: 0;
  transform: translate(-50%, 0);
  pointer-events: none;
}

.viewpoint-pin-pulse {
  position: absolute;
  left: -18px;
  top: -18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(171, 71, 188, 0.28);
  border: 2px solid rgba(225, 190, 231, 0.9);
  box-sizing: border-box;
  animation: viewpointPinPulse 1.8s ease-out infinite;
}

@keyframes viewpointPinPulse {
  0% {
    transform: scale(0.45);
    opacity: 0.95;
  }
  75% {
    opacity: 0.35;
  }
  100% {
    transform: scale(1.65);
    opacity: 0;
  }
}

.viewpoint-pin-btn {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: transparent;
  border: none;
  padding: 2px 4px 0;
  margin: 0;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transform-origin: center bottom;
  animation: viewpointPinDrop 0.36s cubic-bezier(0.22, 1.25, 0.36, 1) both;
  transition: transform 0.16s ease, filter 0.16s ease;
}

.viewpoint-pin-btn:hover {
  transform: scale(1.07);
}

.viewpoint-pin-btn:active {
  transform: scale(0.96);
}

@keyframes viewpointPinDrop {
  0% {
    opacity: 0;
    transform: translateY(-20px) scale(0.72);
  }
  70% {
    opacity: 1;
    transform: translateY(2px) scale(1.04);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.viewpoint-pin-badge {
  display: inline-block;
  max-width: 170px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 4px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #4A148C 0%, #6A1B9A 100%);
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  line-height: 1.25;
  border: 2px solid #fff;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.42);
}

.viewpoint-pin-head {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 44px;
  filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.48));
}

.viewpoint-picker-banner {
  position: fixed;
  top: calc(12px + env(safe-area-inset-top, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 10090;
  display: none;
  align-items: center;
  gap: 10px;
  max-width: calc(100vw - 24px);
  padding: 8px 10px 8px 14px;
  border-radius: 999px;
  background: rgba(49, 13, 92, 0.94);
  color: #fff;
  border: 1.5px solid rgba(225, 190, 231, 0.72);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.36);
  font-size: 13px;
  font-weight: bold;
  line-height: 1.3;
  box-sizing: border-box;
  pointer-events: auto;
}

.viewpoint-picker-banner.is-visible {
  display: inline-flex;
}

.viewpoint-picker-banner-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.viewpoint-picker-close {
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  padding: 5px 11px;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1.2;
}

.viewpoint-picker-close:hover,
.viewpoint-picker-close:active {
  background: rgba(255, 255, 255, 0.3);
}

.viewpoint-picker-btn-active {
  background: #6A1B9A !important;
  color: #fff !important;
  box-shadow: 0 0 0 3px rgba(171, 71, 188, 0.45), 0 4px 14px rgba(74, 20, 140, 0.45) !important;
}
