/* EW Live Map embed */
.ew-live-map {
    position: relative;
    width: 100%;
    margin: 0;
    background: #05080f; /* matches the map's dark canvas so there's no flash */
    overflow: hidden;
}
.ew-live-map__frame {
    display: block;
    border: 0;
    /* Absolute-fill the wrap. Avoids height:100% failing to resolve against the
       fullscreen wrap's auto height (which would collapse the iframe and the globe). */
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

/* Shown behind the iframe while the map loads; the map's own dark canvas covers it. */
.ew-live-map__loading {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #05080f;
    color: #8a96ab;
    font: 600 14px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    letter-spacing: 0.02em;
}

/* Return-home pill — sits over the map (bottom-right), legible on dark & light globe themes. */
.ew-live-map__home {
    position: absolute;
    right: 18px;
    bottom: 18px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    border-radius: 999px;
    background: rgba(10, 14, 22, 0.72);
    color: #fff;
    border: 1px solid rgba(233, 185, 73, 0.45);
    font: 600 13px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    text-decoration: none;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.ew-live-map__home:hover,
.ew-live-map__home:focus-visible {
    background: rgba(10, 14, 22, 0.92);
    border-color: #e9b949;
    color: #ffd97a;
}
.ew-live-map__home svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}
@media (max-width: 600px) {
    .ew-live-map__home {
        right: 12px;
        /* Sit above the map's footer caption (and the iOS home indicator) so they don't overlap */
        bottom: calc(env(safe-area-inset-bottom, 0px) + 52px);
        padding: 8px 13px;
        font-size: 12px;
    }
}

/* Edge-to-edge: a true viewport overlay so the whole globe is always visible and the page
   never overflows (no scrolling needed — the globe's own wheel-zoom won't fight page scroll).
   Sits above the theme header but below the WP admin bar, which we offset for. */
.ew-live-map--fullscreen {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: auto;
    height: auto;
    margin: 0;
    z-index: 9990;
}
/* Don't hide behind the logged-in admin bar */
body.admin-bar .ew-live-map--fullscreen {
    top: 32px;
}
@media screen and (max-width: 782px) {
    body.admin-bar .ew-live-map--fullscreen {
        top: 46px;
    }
}
