/* ==========================================================================
   Venue directory: /venues, /venues/<city> and /venues/<city>/<venue>.
   Rendered on request by lib/venue-directory.js; this sheet only adds what
   style.css does not already have. Same tokens and type as the rest of the
   site, kept deliberately quiet: one card style, one label style, and the
   app's own rating colours as the only accent besides coral.
   ========================================================================== */

/* --- Shared --------------------------------------------------------------- */
.crumbs {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px;
  font-size: .86rem; color: var(--muted);
}
.crumbs li { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.crumbs li + li::before { content: '\203A'; color: var(--hint); font-weight: 700; }
.crumbs a { color: var(--ink-soft); font-weight: 600; transition: color .2s var(--ease-soft); }
.crumbs a:hover { color: var(--coral-deep); }
.crumbs [aria-current] { overflow-wrap: anywhere; }

/* Inline link inside running text. Underlined, because colour alone is not an
   affordance for everyone. */
.text-link {
  color: var(--coral-deep); font-weight: 600;
  text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px;
}
.text-link:hover { text-decoration-thickness: 2px; }

.vd-label {
  font-size: .74rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted);
}
.vd-fine { font-size: .88rem; line-height: 1.55; color: var(--muted); }

.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-list .chip { max-width: 100%; overflow-wrap: anywhere; }

.vd-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 2.6vw, 28px);
  box-shadow: var(--nm-flat);
  min-width: 0;
}
.vd-card > * + * { margin-top: 14px; }
.vd-card__title { font-size: 1.12rem; font-weight: 700; letter-spacing: -.012em; }

.vd-section-title { font-size: clamp(1.3rem, 2vw, 1.6rem); font-weight: 800; letter-spacing: -.02em; line-height: 1.25; }

/* --- Hero ----------------------------------------------------------------- */
.vd-hero { padding: clamp(22px, 3.4vw, 36px) 0 clamp(30px, 4vw, 46px); }
.vd-hero .crumbs { margin-bottom: clamp(18px, 2.6vw, 26px); }
.vd-tags { margin-bottom: 14px; }
.vd-title { overflow-wrap: break-word; max-width: 24ch; }
.vd-lede { margin-top: 12px; }
.vd-hero .vd-back { margin-top: 24px; }

.vd-body { padding: clamp(28px, 4vw, 44px) 0 clamp(48px, 6vw, 76px); }
.container.vd-narrow { max-width: 880px; }

.vd-footnote {
  margin-top: clamp(28px, 4vw, 40px);
  font-size: .9rem; line-height: 1.6; color: var(--muted);
}

/* --- Venue page ------------------------------------------------------------
   Phones read top to bottom: score, map, features, visit details. Wide
   screens put the map and the features in the main column and keep the score
   and visit details beside them; the grid areas let the right column run on
   without leaving a gap under the score. */
.vd-layout { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }

@media (min-width: 1024px) {
  .vd-layout {
    gap: 24px;
    grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
    grid-template-areas:
      "map score"
      "map visit"
      "features visit";
    align-items: start;
  }
  .vd-score { grid-area: score; }
  .vd-map { grid-area: map; }
  .vd-features { grid-area: features; }
  .vd-visit { grid-area: visit; }
}

.vd-score > * + * { margin-top: 10px; }
.vd-score__num { font-size: clamp(2.8rem, 6vw, 3.6rem); font-weight: 800; letter-spacing: -.045em; line-height: 1; }
.vd-score__num span { font-size: .5em; color: var(--muted); margin-left: 2px; }
.vd-score__none { font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; color: var(--ink-soft); }
.vd-score__band, .score-pill { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; }
.vd-score__band::before, .score-pill::before {
  content: ''; width: 11px; height: 11px; border-radius: 50%; flex: none;
  background: var(--band, var(--muted));
}

.meter {
  display: block; height: 10px; border-radius: 999px; overflow: hidden;
  background: var(--surface-sunken); box-shadow: var(--nm-inset-sm);
}
.meter > span { display: block; height: 100%; border-radius: inherit; }

.score-pill { font-size: .86rem; white-space: nowrap; }
.score-pill strong { font-weight: 800; }
.score-pill--none { color: var(--muted); font-weight: 600; }
.score-pill--none::before { background: none; box-shadow: inset 0 0 0 2px var(--hint); }

/* The map box keeps its size before MapLibre arrives, so nothing below it
   jumps when the map draws. */
.map {
  position: relative;
  height: clamp(240px, 34vw, 360px);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface-sunken);
  box-shadow: var(--nm-inset-sm);
}
.map__status {
  position: absolute; inset: 0; z-index: 1;
  display: grid; place-items: center; padding: 16px;
  text-align: center; font-size: .9rem; color: var(--muted);
}
.map.is-failed .map__status { color: var(--ink-soft); }
.map .maplibregl-ctrl-attrib { font-size: 11px; }

/* Map / Satellite switch, top-left so it never covers the zoom buttons. */
.map-views {
  position: absolute; top: 10px; left: 10px; z-index: 2;
  display: inline-flex; padding: 3px; gap: 2px;
  background: rgba(255, 255, 255, .94); border-radius: 999px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .18);
}
.map-views__btn {
  border: 0; background: transparent; cursor: pointer;
  font: inherit; font-size: .84rem; font-weight: 700; color: #3a3f4b;
  padding: 7px 14px; min-height: 34px; border-radius: 999px;
  transition: background-color .2s var(--ease-soft), color .2s var(--ease-soft);
}
/* Fixed colours: the switch sits on the map, which stays light in the dark
   theme, where --coral-dark turns pale. White on #b8351c is 6:1. */
.map-views__btn:hover { color: #b8351c; }
.map-views__btn[aria-pressed="true"] { background: #b8351c; color: #fff; }
.map-views__btn:focus-visible { outline: 2px solid #b8351c; outline-offset: 2px; }

.vd-address { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-soft); font-size: .95rem; line-height: 1.5; }
.vd-address svg { width: 19px; height: 19px; flex: none; margin-top: 2px; color: var(--coral-dark); }
.vd-address span { min-width: 0; overflow-wrap: anywhere; }

.feature-group + .feature-group { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.feature-group > * + * { margin-top: 10px; }
.feature-group__title { font-size: 1rem; font-weight: 700; }
.feature-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 24px; }
.feature-cols .vd-label { margin-bottom: 8px; }
.feature-list { display: grid; gap: 8px; }
.feature-list li { display: flex; gap: 10px; align-items: flex-start; font-size: .96rem; line-height: 1.5; }
.feature-list svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }
.feature-list--yes svg { color: var(--green); }
.feature-list--no svg { color: var(--red); }
.feature-list--unknown svg { color: var(--hint); }
.feature-list--unknown li { color: var(--muted); }

.facts > div {
  display: flex; justify-content: space-between; gap: 18px;
  padding-bottom: 12px; border-bottom: 1px solid var(--line);
}
.facts dt { color: var(--muted); font-size: .92rem; }
.facts dd { font-weight: 600; text-align: right; }

.hours { width: 100%; border-collapse: collapse; font-size: .94rem; }
.hours caption { text-align: left; padding-bottom: 6px; }
.hours th { text-align: left; font-weight: 600; color: var(--ink-soft); padding: 7px 12px 7px 0; }
.hours td { text-align: right; padding: 7px 0; white-space: nowrap; }
.hours tr + tr th, .hours tr + tr td { border-top: 1px solid var(--line); }

/* The written summary above the cards, the score's four parts, and the nearby
   list below them. */
.vd-summary { margin-bottom: 20px; }
.vd-summary p, .vd-glance p { color: var(--ink-soft); line-height: 1.65; max-width: 72ch; }
.score-parts { display: grid; gap: 12px; padding-top: 6px; }
.score-parts li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; align-items: baseline; font-size: .94rem; }
.score-parts li .meter { grid-column: 1 / -1; height: 7px; }
.score-parts__label small { display: block; font-size: .8rem; color: var(--muted); }
.vd-nearby { margin-top: 20px; }
.vd-glance { margin-bottom: clamp(30px, 4vw, 40px); }
.vd-glance .facts > div + div { margin-top: 10px; }
.vd-top { margin-top: clamp(36px, 5vw, 56px); }
.vd-top .vd-section-title { margin-bottom: 18px; }

/* --- City page ------------------------------------------------------------ */
.vd-group + .vd-group { margin-top: clamp(30px, 4vw, 40px); }
.vd-group__title {
  display: flex; align-items: baseline; gap: 10px;
  font-size: 1.15rem; font-weight: 800; letter-spacing: -.015em; margin-bottom: 12px;
}
.vd-group__title span { font-size: .86rem; font-weight: 700; color: var(--muted); }

.place-list { background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--nm-flat); overflow: hidden; }
.place {
  position: relative;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 8px 16px; padding: 16px 20px;
  transition: background-color .2s var(--ease-soft);
}
.place + .place { border-top: 1px solid var(--line); }
.place:hover { background: var(--surface-raised); }
.place__link { flex: 1 1 15rem; min-width: 0; display: grid; gap: 2px; }
/* The whole row is one link target: the link stretches over it. */
.place__link::after { content: ''; position: absolute; inset: 0; }
.place__name { font-weight: 700; line-height: 1.35; overflow-wrap: break-word; }
.place:hover .place__name { color: var(--coral-deep); }
.place__addr { font-size: .86rem; line-height: 1.45; color: var(--muted); overflow-wrap: anywhere; }
/* Inside a card (the venue page's nearby list) the rows sit flush with the
   card's own heading, divided by lines, with no second raised box. This must
   come after .place-list and .place: same specificity, so the later rule wins. */
.place-list--flat { box-shadow: none; background: transparent; border-radius: 0; overflow: visible; }
.place-list--flat .place { padding: 14px 0; }
.place-list--flat .place:first-child { padding-top: 4px; }
.place-list--flat .place:last-child { padding-bottom: 4px; }
.place-list--flat .place:hover { background: transparent; }

.vd-more { margin-top: 28px; font-size: .95rem; color: var(--ink-soft); }
.vd-back { margin-top: 22px; }

/* --- Directory index ------------------------------------------------------ */
.vd-body .vd-section-title + .state-grid { margin-top: 18px; }
.state-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.state { padding-bottom: 12px; }
.state > * + * { margin-top: 8px; }
.state__title { font-size: 1.02rem; font-weight: 800; }
.city-list li + li { border-top: 1px solid var(--line); }
.city-list a {
  display: flex; justify-content: space-between; align-items: baseline; gap: 14px;
  padding: 10px 0; font-weight: 600;
  transition: color .2s var(--ease-soft);
}
.city-list a:hover { color: var(--coral-deep); }
.city-list__count { font-size: .84rem; font-weight: 500; color: var(--muted); white-space: nowrap; }

.vd-scores { margin-top: clamp(36px, 5vw, 56px); }
.vd-scores > * + * { margin-top: 18px; }
.vd-scores__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.vd-scores__text p { color: var(--ink-soft); line-height: 1.65; }
.vd-scores__text p + p { margin-top: 12px; }
.band-list { display: grid; gap: 12px; }
.band-list li { display: grid; grid-template-columns: 11.5em minmax(0, 1fr); gap: 12px; align-items: baseline; }
.band-list li > span:last-child { color: var(--muted); font-size: .94rem; }

/* --- Responsive ----------------------------------------------------------- */
@media (max-width: 1024px) {
  .state-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .vd-scores__grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .state-grid { grid-template-columns: minmax(0, 1fr); }
  .feature-cols { grid-template-columns: minmax(0, 1fr); }
  .band-list li { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .place { padding: 14px 16px; }
}

/* Shared venue and trip links (lib/share-pages.js) */
.share-score { margin-top: 14px; font-size: 1.05rem; }
.share-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.share-day { margin-top: 28px; font-size: 1.15rem; }
.share-day:first-child { margin-top: 0; }
.share-places { margin-top: 10px; padding-left: 22px; }
.share-places li { margin-top: 6px; }

/* AdSense units. Labelled so nobody mistakes an ad for our own content (and
   AdSense allows the word "Advertisement"); min-height reserves room so the
   text below does not jump when the ad arrives. */
.ad-slot { margin: 32px 0; min-height: 120px; }
.ad-slot::before { content: "Advertisement"; display: block; margin-bottom: 6px; font-size: .75rem; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.ad-slot--multiplex { margin-top: 48px; min-height: 280px; }
