/* Explore the area on the hotel page (26 Oct 2026): the map (MapLibre on OpenFreeMap), the places with distance and travel time,
   and the full-screen view. Site tokens from home-a.css (navy, sun gold, line, mist), Manrope and Cairo, logical sides for Arabic.
   The map's own pins and labels are drawn by home-a/js/hotel-map.js inside .hmap-marks. */

.hmap-area { display: flex; gap: 6px; align-items: center; margin: -2px 0 12px; font-weight: 700; color: var(--navy); }
.hmap-area .ico { color: var(--teal); flex: none; }
.hmap-body { container: hmap / inline-size; }

/* the map frame: bigger than before, comfortable on phones */
.hmap-frame { position: relative; height: 320px; border-radius: var(--hx-r, 16px); border: 1px solid var(--line); background: #F8F4F0; overflow: hidden; isolation: isolate; container: hmapbox / inline-size; }
@container hmap (min-width: 560px) { .hmap-frame { height: 400px; } }
@container hmap (min-width: 820px) { .hmap-frame { height: 460px; } }
/* MapLibre gives its container position: relative; the holder must keep filling the frame (and the dialog) */
.hmap .hmap-map { position: absolute; inset: 0; }
.hmap-msg { position: absolute; inset: 0; z-index: 3; display: grid; place-content: center; justify-items: center; gap: 12px; padding: 20px; text-align: center; color: var(--text-2); font-weight: 600; }
.hmap-msg .btn { height: 44px; }
.hmap-frame.is-failed { height: 200px; background: var(--mist); } /* no tall empty box when the map cannot show */

/* "View larger map" */
.hmap-open { margin-top: 12px; height: 44px; padding: 0 16px; font-size: 15px; }
.hmap-open .ico { width: 18px; height: 18px; }

/* the places: name, travel time, distance */
.hmap-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; column-gap: 32px; }
@container hmap (min-width: 640px) { .hmap-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.hmap-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.hmap-ico { flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--mist); color: var(--navy); }
.hmap-ico .ico { width: 18px; height: 18px; }
.hmap-row-in { flex: 1; min-width: 0; display: grid; gap: 1px; }
.hmap-n { font-weight: 700; color: var(--text); line-height: 1.3; }
.hmap-t { font-size: 14px; color: var(--text-2); line-height: 1.35; }
.hmap-km { flex: none; font-weight: 700; color: var(--navy); white-space: nowrap; font-variant-numeric: tabular-nums; }
.hmap-note { margin-top: 10px; font-size: 13px; color: var(--muted); }
.hmap-note a { color: var(--link, #03489B); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }

/* the pins and labels over the map */
.hmap-marks { position: absolute; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; font-family: var(--font); -webkit-font-smoothing: antialiased; }
:lang(ar) .hmap-marks { font-family: 'Cairo', system-ui, sans-serif; }
.hmap-mk { position: absolute; left: 0; top: 0; }
.hmap-lbl { position: absolute; left: 0; top: 0; width: max-content; white-space: nowrap; padding: 4px 8px; border-radius: 8px; background: #fff; color: var(--navy); font-size: 13px; font-weight: 700; line-height: 1.3; box-shadow: 0 1px 4px rgba(2,31,69,.22), 0 0 0 1px rgba(2,31,69,.1); }
.hmap-lbl.is-off { visibility: hidden; }
.hmap-lbl-hotel { max-width: 240px; white-space: normal; padding: 6px 10px; border-radius: 10px; background: var(--navy); color: #fff; font-size: 14px; font-weight: 800; line-height: 1.25; box-shadow: 0 2px 8px rgba(2,31,69,.35); }
@container hmapbox (max-width: 480px) { .hmap-lbl-hotel { max-width: 190px; font-size: 13.5px; } }
.hmap .hmap-lbl-hotel.is-tight { max-width: 140px; font-size: 13px; padding: 5px 8px; }
:lang(ar) .hmap-lbl { line-height: 1.5; padding-block: 3px; }
.hmap-picon { position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--navy); border: 2px solid var(--navy); box-shadow: 0 1px 4px rgba(2,31,69,.3); }
.hmap-picon .ico { width: 15px; height: 15px; stroke-width: 2.2; }
.hmap-dot, .hmap-lead { display: none; position: absolute; }
.hmap-mk.is-moved .hmap-dot { display: block; left: -5px; top: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--navy); border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(2,31,69,.25); }
.hmap-mk.is-moved .hmap-lead { display: block; left: 0; top: -1px; height: 2px; background: var(--navy); transform-origin: 0 50%; }
.hmap-hpin { position: absolute; left: -20px; top: -44px; width: 40px; height: 48px; filter: drop-shadow(0 2px 3px rgba(2,31,69,.4)); }
.hmap-hpin-bg { position: absolute; inset: 0; width: 40px; height: 48px; fill: var(--sun); stroke: #fff; stroke-width: 1.2; }
.hmap-hpin .ico { position: absolute; left: 11px; top: 11px; width: 18px; height: 18px; color: var(--navy); stroke-width: 2.2; }

/* the map's own controls in the site's look */
.hmap .maplibregl-map { font: 12px/1.4 var(--font); }
:lang(ar) .hmap .maplibregl-map { font-family: 'Cairo', system-ui, sans-serif; }
.hmap .maplibregl-ctrl-top-left .maplibregl-ctrl, .hmap .maplibregl-ctrl-top-right .maplibregl-ctrl { margin: 12px 12px 0; }
.hmap .maplibregl-ctrl-group { border-radius: 10px; overflow: hidden; box-shadow: 0 2px 8px rgba(2,31,69,.22), 0 0 0 1px rgba(2,31,69,.08); }
.hmap .maplibregl-ctrl-group button { width: 40px; height: 40px; }
.hmap .maplibregl-ctrl-group button + button { border-top-color: var(--line); }
.hmap .maplibregl-ctrl-group button:focus-visible { box-shadow: inset 0 0 0 3px var(--focus, #03489B); }
.hmap .maplibregl-ctrl-attrib { font-size: 11px; line-height: 16px; }
.hmap .maplibregl-ctrl-attrib a { color: var(--text-2); }
.hmap .maplibregl-ctrl-attrib.maplibregl-compact { margin: 8px; }
@container hmapbox (max-width: 480px) { .hmap .maplibregl-ctrl-attrib { font-size: 10px; line-height: 15px; } }
/* MapLibre pins the credits button with both left and right; on Arabic pages "right" won and covered the text */
.hmap .maplibregl-ctrl-bottom-left .maplibregl-ctrl-attrib-button { right: auto; }
.hmap .maplibregl-cooperative-gesture-screen { background: rgba(2,31,69,.55); font: 700 18px/1.35 var(--font); text-align: center; }
:lang(ar) .hmap .maplibregl-cooperative-gesture-screen { font-family: 'Cairo', system-ui, sans-serif; }
.hmap .maplibregl-canvas:focus-visible { outline: 3px solid var(--focus, #03489B); outline-offset: -3px; }
@media (prefers-reduced-motion: reduce) { .hmap .maplibregl-cooperative-gesture-screen { transition: none; } }

/* the full-screen view */
.hmap-dlg { width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: #fff; color: var(--text); overflow: hidden; }
.hmap-dlg[open] { display: flex; flex-direction: column; }
.hmap-dlg.is-plain { position: fixed; inset: 0; z-index: 1000; }
.hmap-dlg::backdrop { background: rgba(2,31,69,.55); }
/* header like the room details dialog (hotels-a.css .hh-dialog-head) */
.hmap-dlg-head { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left)); border-bottom: 1px solid var(--line); }
.hmap .hmap-dlg-h { margin: 0; min-width: 0; font-size: 18px; font-weight: 800; line-height: 1.3; color: var(--navy); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hmap-close { flex: none; width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 999px; background: var(--mist); color: var(--navy); }
.hmap-close:hover { background: #E1E9F3; }
.hmap-dlg-body { position: relative; flex: 1; min-height: 0; margin-bottom: env(safe-area-inset-bottom); container: hmapbox / inline-size; }
html.hmap-lock, html.hmap-lock body { overflow: hidden; }
