/* G4 手机预览 iframe 嵌入模式 — 隐藏底部导航等壳层，地图占满可视区 */
html[data-g4-embed="1"] .tab-bar {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
}

html[data-g4-embed="1"] body.route-page {
  overflow: hidden;
  padding-bottom: 0 !important;
  margin: 0 !important;
  --route-nav-h: 0px !important;
  --route-nav-gap: 0px !important;
  --route-drawer-handle-bottom: 0px !important;
  --route-map-h: 100% !important;
  --route-map-h-cap: 100% !important;
}

html[data-g4-embed="1"] .scene-drawer-handle,
html[data-g4-embed="1"] .scene-drawer-handle-button {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

html[data-g4-embed="1"] body.route-page .page {
  height: 100% !important;
  max-height: 100% !important;
  min-height: 0 !important;
}

html[data-g4-embed="1"] body.route-page .map-wrapper {
  height: 100% !important;
  max-height: 100% !important;
  min-height: 0 !important;
  flex: 1 1 auto !important;
}

html[data-g4-embed="1"] body.route-page #map {
  height: 100% !important;
  max-height: 100% !important;
}

html[data-g4-embed="1"] body.pretrip-page {
  overflow: hidden;
  padding-bottom: 0 !important;
}

html[data-g4-embed="1"] .pretrip-home {
  min-height: 100%;
}

html[data-g4-embed="1"] .pretrip-report-modal.show {
  display: flex !important;
  position: absolute;
  inset: 0;
  z-index: 50;
  border-radius: 0;
  max-height: none;
}

html[data-g4-embed="1"] .pretrip-report-loading {
  display: none !important;
}

html[data-g4-embed="1"] #report-footer {
  display: flex !important;
}

html[data-g4-embed="1"] .pretrip-home,
html[data-g4-embed="1"] #pretrip-modal-root,
html[data-g4-embed="1"] #popover-backdrop {
  display: none !important;
}

html[data-g4-embed="1"] #report-backdrop {
  display: flex !important;
  position: absolute !important;
  inset: 0 !important;
  align-items: stretch !important;
  background: transparent !important;
  padding: 0 !important;
  z-index: 1 !important;
}

html[data-g4-embed="1"] #report-backdrop .pretrip-report-modal {
  width: 100% !important;
  max-width: none !important;
  height: 100% !important;
  max-height: none !important;
  margin: 0 !important;
  border-radius: 0 !important;
}

html[data-g4-embed="1"] #report-content[hidden] {
  display: flex !important;
  flex-direction: column;
  height: 100%;
}

html[data-g4-embed="1"] #report-backdrop .pretrip-report-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

/* G3 预览：隐藏 pretrip 首页，全屏展示清单弹层 */
html[data-g3-preview="1"] body.pretrip-page {
  overflow: hidden;
  padding-bottom: 0 !important;
}

html[data-g3-preview="1"] .pretrip-home,
html[data-g3-preview="1"] .pretrip-bottom-nav,
html[data-g3-preview="1"] #pretrip-modal-root,
html[data-g3-preview="1"] #popover-backdrop,
html[data-g3-preview="1"] .tab-bar {
  display: none !important;
}

html[data-g3-preview="1"] #report-backdrop {
  display: flex !important;
  position: absolute !important;
  inset: 0 !important;
  align-items: stretch !important;
  background: rgba(15, 23, 42, 0.92) !important;
  padding: 0 !important;
  z-index: 5000 !important;
}

html[data-g3-preview="1"] #report-backdrop .pretrip-report-modal {
  width: 100% !important;
  max-width: none !important;
  height: 100% !important;
  max-height: none !important;
  margin: 0 !important;
  border-radius: 0 !important;
}

html[data-g3-preview="1"] #report-content[hidden] {
  display: none !important;
}

html[data-g3-preview="1"] #report-backdrop.show #report-content:not([hidden]) {
  display: flex !important;
  flex-direction: column;
  height: 100%;
}

html[data-g3-preview="1"] #report-backdrop .pretrip-report-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

/* G4 corridor L0/L1/L2 info bubbles */
.g4-corridor-bubble {
  background: transparent !important;
  border: none !important;
}
.g4-corridor-bubble-inner {
  background: rgba(255, 255, 255, 0.95);
  border: 1.5px solid #2563eb;
  border-radius: 8px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.15);
  line-height: 1.3;
}
