.streetview-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 14, 27, 0.62);
  z-index: 2420;
}

.streetview-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(1200px, 95vw);
  max-height: 92vh;
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid #dbe3ed;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.26);
  padding: 16px 18px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 2421;
}

.streetview-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-right: 32px;
}

.streetview-title {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.streetview-subtitle {
  font-size: 13px;
  color: #64748b;
}

.streetview-canvas-wrap {
  position: relative;
  border: 1px solid #d9e2ec;
  border-radius: 10px;
  background: #f8fafc;
  min-height: min(64vh, 560px);
  overflow: hidden;
}

.streetview-canvas {
  width: 100%;
  height: min(64vh, 560px);
  min-height: 360px;
}

.streetview-pip {
  position: absolute;
  top: 12px;
  right: 12px;
  width: min(320px, 34vw);
  min-width: 220px;
  max-width: 360px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #d9e2ec;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.2);
  overflow: hidden;
  z-index: 3;
}

.streetview-pip-title {
  padding: 8px 10px 6px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  border-bottom: 1px solid #e2e8f0;
}

.streetview-pip-map {
  width: 100%;
  height: 165px;
}

.streetview-pip-hint {
  display: block;
  padding: 6px 10px 8px;
  font-size: 11px;
  color: #64748b;
}

.streetview-pip-camera-marker {
  position: relative;
  width: 42px;
  height: 42px;
  --heading-deg: 0deg;
  cursor: grab;
}

.streetview-pip-camera-marker:active {
  cursor: grabbing;
}

.streetview-pip-camera-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #2563eb;
  border: 3px solid #ffffff;
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.5);
  transform: translate(-50%, -50%);
}

.streetview-pip-camera-dir {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-bottom: 21px solid #2563eb;
  transform: translate(-50%, -100%) rotate(var(--heading-deg));
  transform-origin: 50% calc(100% - 3px);
  filter: drop-shadow(0 1px 1px rgba(15, 23, 42, 0.35));
}

.streetview-status {
  position: absolute;
  left: 12px;
  bottom: 12px;
  max-width: calc(100% - 24px);
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.7);
  color: #f8fafc;
  font-size: 12px;
  line-height: 1.35;
}

.streetview-status.error {
  background: rgba(127, 29, 29, 0.88);
}

.streetview-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.streetview-popup.streetview-capture-mode {
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  max-height: none;
  transform: none;
  border-radius: 0;
  border: 0;
  padding: 0;
}

.streetview-popup.streetview-capture-mode .streetview-header,
.streetview-popup.streetview-capture-mode .streetview-actions,
.streetview-popup.streetview-capture-mode .streetview-close,
.streetview-popup.streetview-capture-mode .streetview-status {
  display: none !important;
}

.streetview-popup.streetview-capture-mode .streetview-canvas-wrap {
  border: 0;
  border-radius: 0;
  min-height: 100vh;
  height: 100vh;
}

.streetview-popup.streetview-capture-mode .streetview-canvas {
  height: 100vh;
  min-height: 100vh;
}

.streetview-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 30px;
  height: 30px;
  border: 1px solid #cfd8e3;
  border-radius: 8px;
  background: #ffffff;
  color: #475569;
  font-size: 13px;
  cursor: pointer;
}

.streetview-close:hover {
  border-color: var(--interactive);
  background: var(--interactive-light);
}
