.visitor-preview-open { overflow: hidden; }
.visitor-preview {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: #fbf5ef;
}
.visitor-preview > iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
.visitor-tools {
  position: fixed;
  z-index: 21;
  top: max(12px, env(safe-area-inset-top));
  left: max(12px, env(safe-area-inset-left));
  display: flex;
  gap: 8px;
  align-items: center;
}
.visitor-tool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid #e1d3bd;
  border-radius: 24px;
  background: #fffcf8;
  color: #2d1723;
  font: 600 13px/1.2 'DM Sans', Arial, sans-serif;
  text-decoration: none;
  cursor: pointer;
}
.visitor-tool[hidden], .visitor-tools[hidden] { display: none; }
.visitor-tool:hover { background: #f5e9ec; }
.visitor-tool:focus-visible { outline: 2px solid #8b3150; outline-offset: 3px; }
.visitor-close { width: 44px; padding: 0; font-size: 21px; }
.scene-controls {
  top: max(12px, env(safe-area-inset-top));
  right: max(12px, env(safe-area-inset-right));
}
#story-nav, .scene-celebrate { bottom: max(17px, env(safe-area-inset-bottom)); }
@media (max-width: 360px) {
  #story-nav:not([hidden]) ~ .scene-celebrate { bottom: calc(68px + env(safe-area-inset-bottom)); }
}
