/* Houston places (pages/places.html, pages/place.html). Everything custom is prefixed pl- or pd-.
   Loaded after user.css. Cards and the split map follow the Directory theme's
   category-2 / detail-rooms layouts, drawn with Sparrow's black-and-white vocabulary. */

:root {
  --pl-restaurant: #b23a48;
  --pl-bar: #6b4fa0;
  --pl-coffee: #8a5a3c;
  --pl-music-and-venues: #2f5d8a;
  --pl-museums-and-art: #b08a1e;
  --pl-outdoors: #4c8c4a;
  --pl-other: #5f6368;
  --pl-nav-h: 0px;   /* fixed site nav height, set by places.js */
  --pl-stick: 0px;   /* nav + filter bar, set by places.js */
  --pl-ink: #1c1c1c;
}
[data-cat="restaurant"] { --pl: var(--pl-restaurant); }
[data-cat="bar"] { --pl: var(--pl-bar); }
[data-cat="coffee"] { --pl: var(--pl-coffee); }
[data-cat="music-and-venues"] { --pl: var(--pl-music-and-venues); }
[data-cat="museums-and-art"] { --pl: var(--pl-museums-and-art); }
[data-cat="outdoors"] { --pl: var(--pl-outdoors); }
[data-cat="other"] { --pl: var(--pl-other); }

/* ---------- hero: full-page photo, same layout as the culture calendar ---------- */
/* The photo is busy (lotería cards), so darken the bottom where the text sits. */
.pl-hero-full { position: relative; }
.pl-hero-full::after { content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: linear-gradient(to top, rgba(0, 0, 0, .7), rgba(0, 0, 0, 0) 65%); }
.pl-hero-full > .container, .pl-hero-full > .indicator { position: relative; z-index: 1; }
.pl-hero-full > .indicator { position: absolute; }
.pl-hero-full .pl-stats { color: rgba(255, 255, 255, .9); }
.pl-hero-full__lede, .pl-hero-full .pl-stats { text-shadow: 0 1px 14px rgba(0, 0, 0, .7); }
.pl-hero-full__lede { max-width: 38rem; }
.pl-hero-full .indicator-arrow { border-color: #fff; }
.pl-hero-full .indicator { bottom: 1.5rem; }
.pl-hero-full h1 { text-shadow: 0 2px 24px rgba(0, 0, 0, .45); }
.pl-sample { margin-top: 1.25rem; display: inline-block; padding: .2rem .6rem; border: 1px dashed rgba(255, 255, 255, .7); border-radius: 999px; color: rgba(255, 255, 255, .85); }
.pl-sample[hidden] { display: none; }
#pl-filterbar { scroll-margin-top: var(--pl-nav-h); }

/* ---------- sticky filter bar (same pattern as the culture calendar) ---------- */
.pl-filterbar { position: sticky; top: var(--pl-nav-h); z-index: 1020; background: #fff; border-bottom: 1px solid var(--sparrow-border-color, #e1e1e1); padding: .65rem 0; }
.pl-filterbar__inner { padding-left: 1.5rem; padding-right: 1.5rem; }
@media (min-width: 1200px) { .pl-filterbar__inner { padding-left: 3rem; padding-right: 3rem; } }
.pl-filterbar__row { display: flex; align-items: center; gap: .5rem; min-width: 0; }
.pl-chips { flex: 1 1 0; min-width: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0; padding: 0; list-style: none; }
.pl-chips::-webkit-scrollbar { display: none; }
@media (min-width: 768px) { .pl-chips { flex-wrap: wrap; overflow: visible; } }
.pl-chips .nav-item { flex: 0 0 auto; }
.pl-chip { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; background: transparent; border: 1px solid #fff; cursor: pointer; }
.pl-chip:hover { border-color: var(--sparrow-border-color, #e1e1e1); }
.pl-chip.active { border-color: #000; }
.pl-chip__n { font-size: .7em; color: #949494; }
.pl-dot { width: .6rem; height: .6rem; border-radius: 50%; background: var(--pl, var(--pl-other)); display: inline-block; flex: 0 0 auto; }
.pl-filterbar__extra { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .5rem 1rem; margin-top: .5rem; }
.pl-field { display: flex; flex-direction: column; gap: .15rem; }
.pl-field--grow { flex: 1 1 12rem; min-width: 0; }
.pl-field__label { color: #7f7f7f; }
.pl-select { min-width: 9.5rem; }
.pl-meta { display: flex; align-items: center; gap: .75rem; margin-left: auto; padding-bottom: .35rem; }
.pl-clear { color: #000; border-bottom: 1px solid #000; }
.pl-clear:hover { text-decoration: none; border-bottom-width: 2px; }
.pl-clear[hidden] { display: none; }
.pl-viewtoggle { display: inline-flex; border: 1px solid #000; border-radius: .375rem; overflow: hidden; flex: 0 0 auto; }
.pl-seg__btn { background: #fff; border: 0; padding: .3rem .75rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: #000; }
.pl-seg__btn[aria-pressed="true"] { background: #000; color: #fff; }
.pl-filters-toggle { flex: 0 0 auto; background: #fff; border: 1px solid #000; border-radius: .375rem; padding: .3rem .65rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: #000; }
.pl-filters-toggle[aria-expanded="true"], .pl-filters-toggle.has-active { background: #000; color: #fff; }
@media (max-width: 767.98px) {
  .pl-filterbar__extra { display: none; grid-template-columns: 1fr 1fr; }
  .pl-filterbar.is-open .pl-filterbar__extra { display: grid; }
  .pl-field--grow { grid-column: 1 / -1; }
  .pl-select { min-width: 0; }
  .pl-meta { grid-column: 1 / -1; margin-left: 0; }
}

/* ---------- list beside map (Directory category-2) ---------- */
.pl-split { display: grid; grid-template-columns: minmax(0, 1fr); }
.pl-list { padding: 1.5rem; }
.pl-mapcol { display: none; }
.pl-split[data-view="map"] .pl-list { display: none; }
.pl-split[data-view="map"] .pl-mapcol { display: block; }
.pl-map { height: calc(100vh - var(--pl-stick)); min-height: 24rem; background: #f2f2f2; }
@media (min-width: 992px) {
  .pl-split { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .pl-split[data-view] .pl-list, .pl-split[data-view] .pl-mapcol { display: block; }
  .pl-list { padding: 2rem 2rem 3rem 3rem; }
  .pl-mapcol { position: relative; border-left: 1px solid var(--sparrow-border-color, #e1e1e1); }
  .pl-map { position: sticky; top: var(--pl-stick); }
}
@media (min-width: 1200px) {
  .pl-list .row-cols-sm-2 > * { width: 33.333%; }
  .pl-list .pl-tile__icon { font-size: 2.75rem; }
  .pl-list .pl-card__overlay-bottom { font-size: .8rem; }
  .pl-list .pl-avatar { width: 2.2rem; height: 2.2rem; font-size: .85rem; }
}
@media (min-width: 1540px) {
  .pl-split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}

/* ---------- card ---------- */
.pl-card { position: relative; display: flex; flex-direction: column; background: #fff; border-radius: .5rem; overflow: hidden;
  box-shadow: 0 .5rem 1.25rem rgba(0, 0, 0, .08); transition: transform .3s, box-shadow .3s; }
.pl-card:hover, .pl-card:focus-within, .pl-card.is-hot { transform: translateY(-2px); box-shadow: 0 .75rem 1.75rem rgba(0, 0, 0, .14); }
.pl-card__media { position: relative; }
.pl-card__media::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(to top, rgba(0, 0, 0, .55), rgba(0, 0, 0, 0) 45%); }
.pl-card__overlay-bottom { position: absolute; z-index: 2; left: 1rem; right: 1rem; bottom: .85rem; display: flex; align-items: center; gap: .6rem; color: #fff; font-size: .9rem; font-weight: 700; font-family: var(--sparrow-font-sans-serif); }
.pl-avatar { width: 2.6rem; height: 2.6rem; border-radius: 50%; border: 2px solid #fff; background: var(--pl, var(--pl-other)); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 1rem; flex: 0 0 auto; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.pl-card__overlay-top { position: absolute; z-index: 2; top: .75rem; right: .75rem; }
.pl-fav { width: 2.25rem; height: 2.25rem; border-radius: 50%; background: rgba(0, 0, 0, .45); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: .95rem; }
.pl-card__body { padding: 1.1rem 1.25rem 1.25rem; display: flex; flex-direction: column; flex: 1 1 auto; }
.pl-card__title { font-size: 1.05rem; font-weight: 800; margin: 0 0 .35rem; line-height: 1.25; }
.pl-card__title-link { color: var(--pl-ink); text-decoration: none; background: none; border: 0; padding: 0; text-align: left; font: inherit; }
.pl-card__title-link:hover { color: #000; text-decoration: none; }
.pl-card__title-link:focus-visible { outline: 2px solid #000; outline-offset: 2px; }
.pl-card__sub { display: flex; align-items: center; justify-content: space-between; gap: .5rem; color: #7f7f7f; font-size: .9rem; margin-bottom: .9rem; }
.pl-card__goto { display: flex; align-items: baseline; gap: .6rem; margin: auto 0 0; color: #666; font-size: .9rem; line-height: 1.3; }
.pl-card__goto-text { font-style: italic; }
.pl-card__dist { margin: 0 0 .4rem; font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: #949494; }
.pl-card__more { position: absolute; top: .75rem; left: .75rem; z-index: 2; font-size: .65rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700;
  color: #000; background: #fff; border-radius: 999px; padding: .2rem .6rem; opacity: 0; transform: translateY(-4px); transition: opacity .2s, transform .2s; }
.pl-card:hover .pl-card__more, .pl-card:focus-within .pl-card__more, .pl-card.is-hot .pl-card__more { opacity: 1; transform: none; }
@media (hover: none) { .pl-card__more { opacity: 1; transform: none; } }

.pl-stars { display: inline-flex; gap: .1rem; color: #f3b41b; font-size: .75rem; white-space: nowrap; }
.pl-star--off { color: #e1e1e1; }
.pl-price { font-family: var(--sparrow-font-sans-serif); font-weight: 900; font-size: 1.35rem; color: #000; letter-spacing: .02em; white-space: nowrap; }
.pl-price__off { color: #e1e1e1; }

/* ---------- image tile ---------- */
.pl-tile { position: relative; overflow: hidden; aspect-ratio: 16 / 10; background: #e1e1e1; }
.pl-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.pl-card:hover .pl-tile img, .pl-card.is-hot .pl-tile img { transform: scale(1.05); }
.pl-tile--standin { background: var(--pl, var(--pl-other));
  background-image: radial-gradient(circle at 70% 20%, rgba(255, 255, 255, .22), rgba(255, 255, 255, 0) 55%), linear-gradient(160deg, rgba(255, 255, 255, .08), rgba(0, 0, 0, .25));
  display: flex; align-items: center; justify-content: center; }
.pl-tile__icon { color: rgba(255, 255, 255, .55); font-size: 3.25rem; line-height: 1; transition: transform .4s; }
.pl-tile__icon svg { width: 1em; height: 1em; }
.pl-card:hover .pl-tile__icon, .pl-card.is-hot .pl-tile__icon { transform: scale(1.08); }
.pl-tile__credit { position: absolute; z-index: 3; right: .5rem; top: .4rem; font-size: .6rem; color: rgba(255, 255, 255, .75); text-shadow: 0 1px 2px rgba(0, 0, 0, .8); }

.pl-empty { padding: 3rem 1rem; text-align: center; border: 1px dashed #bebebe; border-radius: .5rem; }
.pl-textlink { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: #000; text-decoration: none; border-bottom: 1px solid #000; }
.pl-textlink:hover { color: #000; text-decoration: none; border-bottom-width: 2px; }
.pl-textlink--muted { color: #7f7f7f; border-color: #bebebe; }

/* ---------- map markers and popups ---------- */
.pl-marker-wrap { background: none; border: 0; }
.pl-marker { position: relative; width: 28px; height: 28px; border-radius: 50%; background: #000; color: #fff; border: 2px solid #fff;
  display: flex; align-items: center; justify-content: center; font-size: 12px; box-shadow: 0 2px 6px rgba(0, 0, 0, .35);
  transition: transform .15s, background-color .15s; }
.pl-marker svg { width: 1em; height: 1em; }
.pl-marker::after { content: ""; position: absolute; right: -2px; bottom: -2px; width: 11px; height: 11px; border-radius: 50%; background: var(--pl, var(--pl-other)); border: 2px solid #fff; }
.pl-marker--fav { box-shadow: 0 0 0 2px #000, 0 2px 6px rgba(0, 0, 0, .35); }
.is-hot .pl-marker, .pl-marker-wrap:hover .pl-marker { transform: scale(1.25); background: var(--pl, #000); }
.leaflet-marker-icon.is-hot { z-index: 10000 !important; }
.leaflet-container { font-family: var(--sparrow-font-sans-serif); }
.pl-tiles--mono { filter: grayscale(1) contrast(.85) brightness(1.08); }
.leaflet-container a.pl-textlink { color: #000; }
.leaflet-container a.pl-textlink--muted { color: #7f7f7f; }
.pl-popup .leaflet-popup-content-wrapper { padding: 0; border-radius: .5rem; overflow: hidden; box-shadow: 0 .75rem 2rem rgba(0, 0, 0, .2); }
.pl-popup .leaflet-popup-content { margin: 0; width: 260px !important; line-height: 1.35; }
.pl-pop__tile { aspect-ratio: 16 / 9; }
.pl-pop__tile .pl-tile__icon { font-size: 2.5rem; }
.pl-pop__body { padding: .75rem .9rem .85rem; }
.pl-pop__kicker { font-size: .65rem; letter-spacing: .1em; text-transform: uppercase; color: #7f7f7f; }
.pl-pop__title { font-weight: 900; font-size: 1.05rem; color: #000; margin: .1rem 0 .25rem; }
.pl-pop__meta { display: flex; align-items: center; gap: .6rem; }
.pl-pop__meta .pl-price { font-size: .95rem; }
.pl-popup .pl-pop__take { margin: .45rem 0 .6rem; font-family: var(--sparrow-font-serif); color: #555; font-size: .85rem; }
.pl-pop__links { display: flex; gap: 1rem; }
.leaflet-control-zoom a { color: #000; }

/* ---------- detail page ---------- */
.pd-hero { position: relative; min-height: 62vh; display: flex; align-items: flex-end; color: #fff; overflow: hidden; }
.pd-hero__media { position: absolute; inset: 0; }
.pd-hero__media .pl-tile { position: absolute; inset: 0; aspect-ratio: auto; }
.pd-hero__media .pl-tile__icon { font-size: 14rem; position: absolute; right: 8%; top: 50%; transform: translateY(-50%); color: rgba(255, 255, 255, .18); }
.pd-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0, 0, 0, .7), rgba(0, 0, 0, .05) 60%); }
.pd-hero__inner { position: relative; z-index: 2; padding-top: 7rem; padding-bottom: 3rem; }
.pd-hero--plain { min-height: 0; color: inherit; }
.pd-hero--plain::after { display: none; }
.pd-crumbs { display: flex; gap: .5rem; color: rgba(255, 255, 255, .8); }
.pd-crumbs a { color: #fff; }
.pd-hero__title { text-shadow: 0 2px 24px rgba(0, 0, 0, .4); margin-bottom: 1rem; }
.pd-hero__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.5rem; font-size: .9rem; }
.pd-hero__meta .pl-price { color: #fff; font-size: 1.1rem; }
.pd-hero__meta .pl-price__off { color: rgba(255, 255, 255, .3); }
.pd-hero__meta .pl-stars { font-size: .9rem; }
.pd-hero__meta .pl-star--off { color: rgba(255, 255, 255, .3); }
.pd-hero__fav { text-transform: uppercase; letter-spacing: .1em; font-size: .7rem; font-weight: 700; }

.pd-block { margin-bottom: 2.75rem; }
.pd-h { font-size: .8rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 900; color: #000; padding-bottom: .6rem; border-bottom: 1px solid var(--sparrow-border-color, #e1e1e1); margin-bottom: 1.1rem; }
.pd-lede { font-size: 1.25rem; color: #404040; line-height: 1.5; }
.pd-body { color: #555; }
.pd-list { list-style: none; padding: 0; margin: 0; }
.pd-list li { position: relative; padding: .55rem 0 .55rem 1.5rem; border-bottom: 1px dashed var(--sparrow-border-color, #e1e1e1); color: #404040; }
.pd-list li::before { content: ""; position: absolute; left: .2rem; top: 1.05rem; width: .5rem; height: .5rem; border-radius: 50%; background: var(--pl, #000); }
.pd-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .75rem; }
.pd-gallery__item { display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: .375rem; }
.pd-gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.pd-gallery__item:hover img { transform: scale(1.05); }

.pd-side { position: sticky; top: 4.5rem; }
.pd-card { border-radius: .5rem; overflow: hidden; box-shadow: 0 .5rem 1.5rem rgba(0, 0, 0, .1); background: #fff; }
.pd-map { height: 15rem; background: #f2f2f2; }
.pd-card__body { padding: 1.25rem; }
.pd-addr { display: flex; gap: .6rem; color: #404040; margin-bottom: 1.1rem; }
.pd-addr svg { margin-top: .25rem; flex: 0 0 auto; }
.pd-tags { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--sparrow-border-color, #e1e1e1); }
.pd-tag { display: inline-block; font-size: .65rem; letter-spacing: .1em; text-transform: uppercase; padding: .2rem .6rem; border: 1px solid #949494; border-radius: 999px; color: #404040; margin: 0 .3rem .4rem 0; }
.pd-tag:hover { border-color: #000; color: #000; text-decoration: none; }
#pd-nearby-section[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) {
  .pl-card, .pl-tile img, .pl-tile__icon, .pl-marker, .pl-card__more, .pd-gallery__item img { transition: none; }
  .pl-card:hover, .pl-card.is-hot { transform: none; }
}

/* ---------- seeded-data additions: branches, clusters ---------- */
.pl-card__branches { margin-left: .5rem; font-size: .7rem; font-weight: 400; opacity: .85; }
.pl-pop__addr { margin: .4rem 0 .6rem; font-size: .75rem; color: #7f7f7f; }
.pl-pop__more { white-space: nowrap; }
.pl-field[hidden] { display: none; }
.pl-cluster { background: none; }
.pl-cluster span { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%;
  background: #000; color: #fff; border: 3px solid rgba(255, 255, 255, .9); box-shadow: 0 0 0 1px #000, 0 2px 8px rgba(0, 0, 0, .35);
  font: 700 .8rem var(--sparrow-font-sans-serif); transition: transform .15s; }
.pl-cluster--lg span { width: 36px; height: 36px; font-size: .85rem; }
.pl-cluster.is-hot span, .pl-cluster:hover span { transform: scale(1.15); }
.marker-cluster-anim .leaflet-marker-icon, .marker-cluster-anim .leaflet-marker-shadow { transition: transform .3s ease-out, opacity .3s ease-in; }
