/* Ezseed redesign — two independent regions: top header + map card.
 * Scoped under body.ezseed-rd to avoid touching anything outside the new
 * layout. Higher specificity than existing rules → no !important needed.
 */

/* Body becomes a vertical layout that can scroll. */
body.ezseed-rd {
  overflow: auto;
  overscroll-behavior: auto;
  height: auto;
  min-height: 100vh;
  margin: 0;
  display: block;
}

/* === REGION 1: top header (nav lives here only) ====================== */
body.ezseed-rd .rd-header {
  position: relative;
  width: 100%;
  min-height: 76px;
  padding: 14px 24px;
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  box-sizing: border-box;
}

/* Force nav visible + reset its own positioning when it sits inside .rd-header.
 * Specificity: body.class .class #id  (1id + 2class + 1elem) beats
 *              body.fullscreen #site-nav (1id + 1class + 1elem). */
body.ezseed-rd .rd-header #site-nav {
  position: static;
  inset: auto;
  top: auto;
  left: auto;
  right: auto;
  transform: none;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 4px;
  max-width: none;
  margin: 0;
}

/* === REGION 2: map card area (3D box lives here only) ================ */
body.ezseed-rd .rd-mapwrap {
  padding: 16px 24px 16px;
  background: var(--bg-app, #f6f7fa);
  box-sizing: border-box;
}
@media (max-width: 720px) {
  body.ezseed-rd .rd-mapwrap { padding: 8px 8px 8px; }
}

body.ezseed-rd .rd-mapwrap #map-viewport {
  position: relative;
  inset: auto;
  top: auto; left: auto; right: auto; bottom: auto;
  width: 100%;
  height: calc(100dvh - 76px - 32px);
  min-height: 400px;
  margin: 0 auto;
  max-width: none;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,.18), 0 2px 8px rgba(0,0,0,.08);
  z-index: 1;
}

/* 3D iframe fills its parent card cleanly. Specificity beats the existing
 * body.view-3d.threed-windowed #view-3d-iframe (2 class + 1 id). */
body.ezseed-rd .rd-mapwrap #map-viewport #view-3d-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: none;
  border: 0;
  border-radius: inherit;
  box-shadow: none;
}

/* Comments / page-tail content shows below the map in normal flow. */
body.ezseed-rd #comments-section.home-comments {
  position: relative;
  display: block;
  visibility: visible;
  opacity: 1;
  margin-top: 24px;
}
