.directory-policy-content > [id] { scroll-margin-top: 110px; }
/* Shared Unify01 fixes and extension primitives. Site themes load after this. */


.autocomplete button#loc {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  width: 44px;
  height: 44px;
  padding: 6px;
  color: inherit;
  background: transparent;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  transform: translateY(-50%);
}

.autocomplete button#loc:hover,
.autocomplete button#loc:focus-visible {
  background: rgba(0, 0, 0, 0.06);
}

.autocomplete button#loc:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 2px;
}

.autocomplete button#loc img {
  display: block;
  width: 32px;
  height: 32px;
}

/* Reusable directory components. Site themes may change colour, typography,
   and decoration, but the behavior and layout remain available to every
   customised site without copying these rules. */
.directory-hero-search {
  max-width: 980px;
}

.directory-category-group { margin-bottom: 1rem; }
.directory-category-group summary { cursor: pointer; padding: .75rem 0; font-weight: 650; }
.directory-category-group a { display: block; padding: .45rem 0; }
.directory-category-group ul { max-height: 25rem; overflow-y: auto; padding-right: .75rem; }

/* Bootstrap supplies responsive column widths; Masonry packs unequal posts. */
.directory-post-grid { align-items: flex-start; }
.directory-post-grid > .masonry-grid-item { min-width: 0; }
.directory-post-grid article { overflow-wrap: anywhere; }

.directory-hero-search .form-group {
  margin-bottom: 0 !important;
}

.directory-results-toggle,
.directory-list-toggle {
  display: none;
}

.directory-result-content {
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.directory-result-marker {
  flex: 0 0 auto;
  margin-left: auto;
  text-align: right;
}

.directory-result-marker > strong {
  min-width: 38px;
  text-align: center;
}

.directory-results article header h4 {
  padding-left: 0;
  margin-left: 0;
}

.directory-results article header h4 > i.icon-hotel-restaurant-235 {
  display: none;
}

.directory-map-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--directory-marker-background, #72c02c);
  border: 2px solid #fff;
  border-radius: 8px 8px 8px 2px;
  box-shadow: 0 2px 8px rgba(27, 46, 62, 0.28);
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1;
}

.directory-map-marker > span {
  display: flex;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
}

/* Country and region overview maps identify places directly. The zero-sized
   Leaflet anchor keeps each variable-width label centred on its coordinates. */
.directory-city-map-marker {
  width: 0 !important;
  height: 0 !important;
  background: transparent;
  border: 0;
}

.directory-city-map-marker > span {
  position: absolute;
  bottom: 0;
  left: 0;
  display: block;
  width: max-content;
  max-width: 160px;
  overflow: hidden;
  padding: 0.38rem 0.58rem;
  color: #fff;
  background: var(--directory-marker-background, #72c02c);
  border: 2px solid #fff;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(27, 46, 62, 0.3);
  font-size: 0.75rem;
  font-weight: 750;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
  transform: translateX(-50%);
}

.directory-city-map-marker:hover,
.directory-city-map-marker:focus {
  z-index: 1000 !important;
}

.directory-city-map-marker:hover > span,
.directory-city-map-marker:focus > span {
  filter: brightness(0.9);
}

@media (max-width: 767.98px) {
  .directory-city-map-marker > span {
    max-width: 110px;
    padding: 0.3rem 0.45rem;
    font-size: 0.6875rem;
  }

  .directory-results.is-collapsible:not(.is-expanded) > div:nth-child(n + 13) {
    display: none !important;
  }

  .directory-results-toggle.is-enhanced {
    display: inline-flex;
  }
}

/* Sidebar lists collapse to eight items on phones. Homepage lists (e.g. every
   area of a detected big city) also collapse on larger screens; town pages
   cap their area list on the server and add their own "more areas" control. */
@media (max-width: 767.98px) {
  .directory-secondary-list.is-collapsible:not(.is-expanded) > li:nth-child(n + 9) {
    display: none !important;
  }

  .directory-list-toggle.is-enhanced {
    display: inline-flex;
  }
}

.directory-secondary-list.is-collapsible-always.is-collapsible:not(.is-expanded) > li:nth-child(n + 9) {
  display: none !important;
}

.directory-list-toggle.is-collapsible-always.is-enhanced {
  display: inline-flex;
}

.directory-results-toggle.is-enhanced,
.directory-list-toggle.is-enhanced {
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.1rem;
  color: var(--directory-action-color, currentColor);
  background: #fff;
  border: 1px solid currentColor;
  border-radius: 6px;
  font-weight: 700;
}

/* Result card facts: open status and rating in a column under the image,
   quick actions under the address. */
.directory-result-media {
  flex: 0 0 auto;
  width: 100px;
  margin-right: 20px;
}

article .directory-result-media > a.g-max-width-100 {
  margin: 0 auto !important;
}

.directory-result-facts {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  margin: 0.6rem 0 0;
  font-size: 0.78rem;
  line-height: 1.3;
  text-align: center;
}

.directory-result-facts .directory-result-status-detail {
  display: block;
}

/* Inline elsewhere, e.g. the listing page: "Open now · Closes 5pm". */
.directory-result-status-detail::before {
  content: " \00b7  "; /* the first space after \00b7 ends the escape */
}

.directory-result-facts .directory-result-status-detail::before {
  content: none;
}

@media (max-width: 575px) {
  /* Themes shrink the image to 64px here; keep room for "Closes 5:30pm". */
  .directory-result-media {
    width: 76px;
    margin-right: 14px;
  }
}

/* Cards with facts float the map letter inside the text column, so the
   chips and actions below the address use the width under it. */
.directory-result-content.has-card-facts {
  margin-right: 0 !important;
}

.directory-result-marker.is-floated {
  float: right;
  margin: 0 0 0.35rem 0.75rem;
}

.directory-result-chips,
.directory-result-content.has-card-facts .directory-result-actions {
  clear: right;
}

.directory-result-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
}

.directory-result-chips > li {
  padding: 0.15rem 0.55rem;
  color: #444;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 999px;
  font-size: 0.75rem;
  line-height: 1.4;
  white-space: nowrap;
}

.directory-result-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.86rem;
  line-height: 1.4;
}

/* Themes set the address margin themselves (often 0 !important); cards with
   facts own the spacing below the address instead. Category pages are not
   wrapped in .directory-results, so the address rules are repeated here. */
.directory-result-content.has-card-facts header h4 {
  padding-left: 0;
  margin-left: 0;
  margin-bottom: 0 !important;
}

.directory-result-content.has-card-facts header h4 > i.icon-hotel-restaurant-235 {
  display: none;
}

.directory-result-actions {
  margin: 0.75rem 0 0;
  gap: 0.5rem;
}

.directory-result-status[hidden] {
  display: none;
}

.directory-result-status.is-open > strong {
  color: #1e7e34;
}

.directory-result-status.is-closed > strong,
.directory-result-status.is-closed {
  color: #b02a37;
}

.directory-result-rating {
  color: #333;
  font-weight: 700;
  white-space: nowrap;
}

.directory-result-rating > span[aria-hidden] {
  color: #e7a100;
}

.directory-result-rating-count {
  color: #666;
  font-weight: 400;
}

.directory-result-action {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 44px;
  padding: 0 0.85rem;
  color: var(--directory-action-color, #2a6d9e);
  border: 1px solid currentColor;
  border-radius: 6px;
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none;
}

.directory-result-action:hover,
.directory-result-action:focus {
  text-decoration: none;
  background: rgba(0, 0, 0, 0.04);
}

.directory-listing-status {
  margin: 0.85rem 0 1rem;
}

.directory-listing-status .directory-result-status {
  display: inline-block;
  padding: 0.25rem 0.7rem;
  color: #fff;
  background: rgba(0, 0, 0, 0.45);
  border-radius: 999px;
}

.directory-listing-status .directory-result-status.is-open > strong {
  color: #7ee08f;
}

.directory-listing-status .directory-result-status.is-closed,
.directory-listing-status .directory-result-status.is-closed > strong {
  color: #ffb3b8;
}

.directory-listing-status .directory-result-status[hidden] {
  display: none;
}

/* Hero breadcrumbs sit on a darkened photo, where the themes' accent hover
   colour has too little contrast: stay white and underline instead. */
.g-bg-cover__inner .u-list-inline a.g-color-white.g-color-primary--hover:hover,
.g-bg-cover__inner .u-list-inline a.g-color-white.g-color-primary--hover:focus {
  color: #fff !important;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

/* Listing page "Shortcuts": links and buttons look and hover alike. The
   themes' g-color-primary--hover gives the accent text colour; every item
   adds the same light tint of that colour behind it. */
.directory-shortcut {
  width: 100%;
  text-align: left;
  font: inherit;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.directory-shortcut:hover,
.directory-shortcut:focus-visible {
  background: rgba(0, 0, 0, 0.04);
  background: color-mix(in srgb, currentColor 10%, transparent);
  text-decoration: none;
}

.directory-shortcut.is-cta {
  font-weight: 600;
}
