/* =========================================
   Posao EU Custom Map Markers — Fullscreen (v2.3.0)
   Brand: #F28C0F (orange), #D97D0A (dark orange), #1d1b20 (ink)
   ========================================= */

/* --- Toggle button (white rounded square, matches Google controls) --- */
.pmm-fs-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 5;
    width: 40px;
    height: 40px;
    padding: 0;
    margin: 0;
    border: none;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1d1b20;
    transition: background 0.15s ease;
    -webkit-appearance: none;
    appearance: none;
}

.pmm-fs-btn:hover,
.pmm-fs-btn:focus {
    background: #f5f5f5;
    outline: none;
}

.pmm-fs-btn svg {
    width: 20px;
    height: 20px;
    display: block;
    pointer-events: none;
}

/* Hide the "close" glyph until the map is in fullscreen, and vice-versa. */
.pmm-fs-btn .pmm-fs-ico-close { display: none; }
.pmm-fs-btn .pmm-fs-ico-open  { display: block; }

/* --- Fullscreen container state --- */
.pmm-map--fullscreen {
    position: fixed !important;
    inset: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-height: none !important;   /* overrides hp-gl-style.css 480px/300px caps */
    min-height: 100vh !important;
    margin: 0 !important;
    border-radius: 0 !important;
    z-index: 99999 !important;
    box-shadow: none !important;
}

/* Force every nested map layer to fill the fullscreen container.
   The toggled element is div.widget.hp-map; HivePress nests an intermediate
   div, then Google's .gm-style canvas, several levels deep — so every
   descendant div must be stretched, not just direct children. */
.pmm-map--fullscreen,
.pmm-map--fullscreen > div,
.pmm-map--fullscreen [data-component="map"],
.pmm-map--fullscreen .gm-style,
.pmm-map--fullscreen .gm-style > div {
    height: 100% !important;
    min-height: 100vh !important;
    max-height: none !important;
}

.pmm-map--fullscreen .pmm-fs-btn .pmm-fs-ico-open  { display: none; }
.pmm-map--fullscreen .pmm-fs-btn .pmm-fs-ico-close { display: block; }

/* Round the toggle a touch more in fullscreen so it reads as "exit". */
.pmm-map--fullscreen .pmm-fs-btn {
    top: 14px;
    right: 14px;
}

/* --- Body scroll lock while a map is fullscreen --- */
body.pmm-fs-active {
    overflow: hidden !important;
}

/* Safe-area padding for notched iOS devices. */
@supports (padding: max(0px)) {
    .pmm-map--fullscreen .pmm-fs-btn {
        top: max(14px, env(safe-area-inset-top));
        right: max(14px, env(safe-area-inset-right));
    }
}
