/* City Explore renderer. All shell changes apply only while the new local view is active. */
body.explore-grid-mode #map,
body.explore-grid-mode #map-message,
body.explore-grid-mode > .app-shell > .topbar,
body.explore-grid-mode > .app-shell > .map-tools,
body.explore-grid-mode #sheet-handle,
body.explore-grid-mode #browse-panel > :not(#results) {
  display: none !important;
}

body.explore-grid-mode .app-shell > .sheet {
  position: fixed;
  z-index: 20;
  inset: 0 0 var(--persistent-nav-height, calc(64px + env(safe-area-inset-bottom, 0px))) !important;
  width: 100%;
  height: auto !important;
  max-height: none !important;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #f7f8f6;
  box-shadow: none;
}

body.explore-grid-mode #browse-panel:not([hidden]) {
  position: absolute;
  inset: 0;
  display: block !important;
  overflow: hidden;
  background: #f7f8f6;
  color: #1d2823;
}

body.explore-grid-mode #results {
  position: absolute;
  inset: 0;
  display: block !important;
  width: 100%;
  height: 100% !important;
  min-height: 0;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
  background: #f7f8f6;
  scrollbar-width: thin;
}

body.explore-grid-mode .explore-feed {
  display: none !important;
}

body.explore-grid-mode .tabbar {
  z-index: 550;
  color:#738078;
  border-color:#dfe6e0;
  background:#f7f8f6;
}
body.explore-grid-mode .tab{color:#738078;}
body.explore-grid-mode .tab.active{color:#246b51;background:#e4eee7;}

.explore-grid {
  --grid-ink: #1d2823;
  --grid-muted: #737d77;
  --grid-line: #e3e8e4;
  --grid-green: #247957;
  --grid-soft: #edf3ef;
  box-sizing: border-box;
  width: 100%;
  min-height: 100%;
  margin: 0 auto;
  padding: calc(8px + env(safe-area-inset-top, 0px)) 16px calc(26px + env(safe-area-inset-bottom, 0px));
  color: var(--grid-ink);
  background: #f7f8f6;
  font-family: inherit;
}

.explore-grid *,
.explore-grid *::before,
.explore-grid *::after { box-sizing: border-box; }

.explore-grid button:not(.chip),
.explore-grid select { font: inherit; }

.explore-grid__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 45px;
  margin-bottom: 20px;
}

.explore-grid__brand { display: flex; align-items: center; gap: 9px; color: #214e3b; }
.explore-grid__brand strong { font-size: 18px; font-weight: 820; letter-spacing: -.035em; }
.explore-grid__brand-mark { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 11px; background: #dcebe1; color: #247957; }
.explore-grid__brand-mark svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
.explore-grid__language { min-width: 44px; height: 38px; padding: 0 12px; border: 1px solid #d7e0da; border-radius: 13px; background: #fff; color: #315c47; font-size: 12px; font-weight: 750; cursor: pointer; }

.explore-grid__section { min-width: 0; margin: 0 auto 28px; }
.explore-grid__section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 13px; }
.explore-grid__section-heading > div { min-width: 0; }
.explore-grid__eyebrow { margin: 0 0 4px; color: #829087; font-size: 9px; font-weight: 800; letter-spacing: .13em; line-height: 1.3; }
.explore-grid__section-heading h1,
.explore-grid__section-heading h2 { margin: 0; color: var(--grid-ink); font-size: clamp(20px, 5vw, 26px); font-weight: 790; letter-spacing: -.045em; line-height: 1.15; }
.explore-grid__section-heading h1 { font-size: clamp(18px, 4.6vw, 23px); }
.explore-grid__locate-icon { display: grid; flex: 0 0 38px; width: 38px; height: 38px; place-items: center; border: 1px solid #d7e2da; border-radius: 50%; background: #fff; color: var(--grid-green); cursor: pointer; }
.explore-grid__locate-icon svg,
.explore-grid__locate svg { width: 18px; height: 18px; }
.explore-grid__location-status{margin:0 0 12px;padding:10px 12px;border-radius:12px;background:#eaf1eb;color:#486353;font-size:12px;line-height:1.5;}
.explore-grid [data-grid-locate]:disabled{opacity:.5;cursor:wait;}

.explore-grid__nearby-filters { margin: 0 0 12px; color: var(--text); }
.explore-grid__rail-arrow:focus-visible,
.explore-grid__clear-nearby:focus-visible,
.explore-grid__profile-area:focus-visible,
.explore-grid__save:focus-visible,
.explore-grid__language:focus-visible,
.explore-grid__locate:focus-visible,
.explore-grid__locate-icon:focus-visible { outline: 3px solid #6aaf8a; outline-offset: 2px; }

.explore-grid__nearby-track {
  display: grid;
  grid-auto-columns: calc((100% - 12px) / 2);
  grid-auto-flow: column;
  align-items: start;
  gap: 12px;
  margin: 0 -16px;
  padding: 1px 16px 9px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scroll-padding-inline: 16px;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.explore-grid__nearby-track::-webkit-scrollbar,
.explore-grid__media-track::-webkit-scrollbar { display: none; }
.explore-grid__nearby-track > .explore-grid__card { scroll-snap-align: start; }
.explore-grid__nearby-track.is-pointer-dragging { cursor: grabbing; scroll-snap-type: none; user-select: none; }
.explore-grid__nearby-track { cursor: grab; }
.explore-grid__rail-footer { display: flex; min-height: 38px; align-items: center; justify-content: space-between; gap: 10px; margin: 1px 0 0; }
.explore-grid__rail-hint { color: #68776e; font-size: 10px; font-weight: 690; }
.explore-grid__rail-controls { display: flex; align-items: center; gap: 7px; }
.explore-grid__rail-arrow { display: grid; width: 32px; height: 32px; place-items: center; border: 1px solid #d6e1d9; border-radius: 50%; background: #fff; color: #286b4d; cursor: pointer; }
.explore-grid__rail-arrow svg { width: 16px; height: 16px; }
.explore-grid__rail-arrow:disabled { color: #aeb9b1; background: #f2f4f2; border-color: #e4e9e5; cursor: default; }

.explore-grid__cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 18px 12px; }
.explore-grid__card { position: relative; min-width: 0; overflow: hidden; border: 1px solid #e6eae7; border-radius: 17px; background: #fff; box-shadow: 0 5px 16px rgb(28 53 39 / 5%); }
.explore-grid__media-wrap { position: relative; min-width: 0; overflow: hidden; background: #e7ece8; }
.explore-grid__card--grid .explore-grid__media-track { aspect-ratio: 4 / 5; }
.explore-grid__card--nearby .explore-grid__media-track { aspect-ratio: 1.03 / 1; }
.explore-grid__media-track { display: flex; width: 100%; height: 100%; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; touch-action: auto; cursor: grab; }
.explore-grid__media-track.is-pointer-dragging { cursor: grabbing; scroll-snap-type: none; user-select: none; }
.explore-grid__slide { flex: 0 0 100%; width: 100%; height: 100%; min-width: 0; overflow: hidden; scroll-snap-align: start; scroll-snap-stop: always; }
.explore-grid__media-action { position: relative; display: grid; width: 100%; height: 100%; min-height: 100%; place-items: center; overflow: hidden; padding: 0; border: 0; background: #e7ece8; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.explore-grid__media-action img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; pointer-events: none; }
.explore-grid__media-action:focus-visible,
.explore-grid__media-action:focus-visible,
.explore-grid__arrow:focus-visible { outline: 3px solid #6aaf8a; outline-offset: 2px; }
.explore-grid__play { position: absolute; inset: 50% auto auto 50%; display: grid; width: 43px; height: 43px; place-items: center; padding-left: 2px; border: 1px solid rgb(255 255 255 / 82%); border-radius: 50%; transform: translate(-50%, -50%); background: rgb(27 42 34 / 58%); color: #fff; backdrop-filter: blur(8px); }
.explore-grid__play svg { width: 17px; height: 17px; }
.explore-grid__source-badge { position: absolute; left: 8px; bottom: 8px; max-width: calc(100% - 16px); padding: 5px 8px; overflow: hidden; border: 1px solid rgb(255 255 255 / 50%); border-radius: 999px; background: rgb(29 40 35 / 76%); color: #fff; font-size: 9px; font-weight: 720; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; backdrop-filter: blur(8px); }
.explore-grid__empty-media { display: grid; width: 100%; height: 100%; min-height: 115px; place-items: center; color: #8b9a90; font-size: 32px; }
.explore-grid__empty-media-mark { display: grid; width: 100%; height: 100%; place-items: center; color: #93a197; font-size: 28px; }

.explore-grid__media-controls { display: flex; min-height: 31px; align-items: center; justify-content: center; gap: 8px; padding: 3px 7px; border-top: 1px solid #edf0ed; background: #fff; }
.explore-grid__arrow { display: grid; flex: 0 0 25px; width: 25px; height: 25px; place-items: center; padding: 0; border: 0; border-radius: 50%; background: #f0f4f1; color: #456c56; font-size: 21px; line-height: 1; cursor: pointer; }
.explore-grid__arrow svg { width: 14px; height: 14px; }
.explore-grid__media-position { color: #68756d; font-size: 9px; font-variant-numeric: tabular-nums; font-weight: 720; white-space: nowrap; }
.explore-grid__dots { display: flex; max-width: 70px; align-items: center; justify-content: center; gap: 3px; overflow: hidden; }
.explore-grid__dot { display: block; flex: 0 0 4px; width: 4px; height: 4px; border-radius: 50%; background: #cbd4cd; }
.explore-grid__dot.is-active { flex-basis: 6px; width: 6px; height: 6px; background: var(--grid-green); }

.explore-grid__card-copy { position: static; min-width: 0; padding: 0; }
.explore-grid__save { position: absolute; z-index: 2; top: 10px; right: 8px; display: grid; width: 34px; height: 34px; place-items: center; padding: 0; border: 1px solid rgb(255 255 255 / 80%); border-radius: 50%; background: rgb(255 255 255 / 94%); color: #44594c; box-shadow: 0 2px 8px rgb(18 38 26 / 15%); cursor: pointer; }
.explore-grid__save svg { width: 17px; height: 17px; }
.explore-grid__save.is-saved { background: #257b57; color: #fff; }
.explore-grid__profile-area { display: block; width: 100%; min-height: 74px; padding: 9px 10px 11px; border: 0; background: #fff; color: inherit; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.explore-grid__name { display: -webkit-box; width: 100%; min-height: 2.65em; padding: 0 34px 0 0; overflow: hidden; color: #25332a; font-size: 12px; font-weight: 790; line-height: 1.34; text-align: left; text-overflow: ellipsis; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.explore-grid__details { display: flex; min-height: 18px; flex-wrap: wrap; align-items: center; gap: 4px 7px; margin-top: 4px; color: var(--grid-muted); font-size: 9px; line-height: 1.3; }
.explore-grid__location { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.explore-grid__distance { color: #526d5c; font-weight: 730; white-space: nowrap; }
.explore-grid__state { padding: 3px 6px; border-radius: 999px; background: #f0f2f0; color: #68736c; font-size: 8px; font-weight: 720; }
.explore-grid__state.is-open { background: #e7f3eb; color: #20714d; }
.explore-grid__state.is-closed { background: #f0f1ef; color: #69716c; }

.explore-grid__location-prompt { display: flex; align-items: center; gap: 14px; padding: 16px; border: 1px solid #e2e9e3; border-radius: 18px; background: #fff; }
.explore-grid__location-prompt > div { flex: 1; min-width: 0; }
.explore-grid__location-prompt strong { display: block; color: var(--grid-ink); font-size: 13px; font-weight: 600; line-height: 1.45; }
.explore-grid__location-prompt p { margin: 5px 0 0; color: var(--grid-muted); font-size: 11px; font-weight: 400; line-height: 1.55; }
.explore-grid button.explore-grid__locate { display: inline-flex; flex: 0 0 auto; min-height: 44px; align-items: center; justify-content: center; gap: 6px; padding: 0 12px; border: 1px solid #d6e7dc; border-radius: 999px; background: #edf5ef; color: var(--grid-green); font-size: 12px; font-weight: 600; line-height: 1; white-space: nowrap; cursor: pointer; }
.explore-grid__locate svg { width: 16px; height: 16px; }
.explore-grid__empty-state { margin: 0; padding: 14px 4px; color: #758078; font-size: 12px; line-height: 1.5; }
.explore-grid__empty-nearby { padding: 13px 2px 8px; color: #737d77; font-size: 11px; line-height: 1.45; }
.explore-grid__empty-nearby p { margin: 0; }
.explore-grid__clear-nearby { margin-top: 8px; padding: 6px 0; border: 0; background: transparent; color: #247957; font-size: 11px; font-weight: 750; text-decoration: underline; cursor: pointer; }
.explore-grid__load-sentinel { width: 100%; height: 1px; margin: 24px 0 0; pointer-events: none; }

@media (min-width: 760px) {
  .explore-grid { max-width: 820px; padding-inline: 24px; }
  .explore-grid__header { margin-bottom: 24px; }
  .explore-grid__nearby-track { grid-auto-columns: calc((100% - 16px) / 2); gap: 16px; margin-inline: -24px; padding-inline: 24px; scroll-padding-inline: 24px; }
  .explore-grid__cards { gap: 22px 18px; }
  .explore-grid__card { border-radius: 19px; }
  .explore-grid__profile-area { min-height: 82px; padding: 12px 14px 14px; }
  .explore-grid__name { font-size: 14px; }
  .explore-grid__details { font-size: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .explore-grid *, .explore-grid *::before, .explore-grid *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

/* Opened only after a deliberate video-poster tap; the grid stays underneath. */
.explore-grid-video-dialog{position:fixed;inset:0;width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;border:0;border-radius:0;background:#111;color:#fff;overflow:hidden;}
.explore-grid-video-dialog::backdrop{background:#111;}
body.explore-grid-mode .explore-grid-video-dialog .explore-feed{display:block!important;height:100dvh!important;min-height:0!important;border-radius:0;}
.explore-grid-video-dialog .explore-feed__viewport{height:100%!important;}
.explore-grid-video-dialog .explore-feed__card{height:100dvh!important;min-height:100dvh!important;}
.explore-grid-video-dialog .explore-feed__topbar{justify-content:flex-end;}
.explore-grid-video-dialog .explore-feed__eyebrow{display:none;}
.explore-grid-video-dialog .explore-feed__caption{padding-top:90px;}
.explore-grid-video-back{position:absolute;z-index:10;top:calc(12px + env(safe-area-inset-top,0px));left:14px;display:flex;align-items:center;gap:7px;min-height:44px;padding:8px 13px;background:#17251fca;border:1px solid #ffffff42;border-radius:24px;color:#fff;font-size:13px;font-weight:700;}
.explore-grid-video-back svg{width:20px;height:20px;}
.explore-grid-video-dialog [data-grid-video-content]{height:100%;}

/* Owner-selected logo 01 */
.explore-grid__brand-mark{background:transparent;color:#193e32;border-radius:0}.explore-grid__brand-mark svg{width:28px;height:28px;stroke:none}.explore-grid__wordmark img{display:block;width:124px;height:auto}
