/**
 * rcvda-map — shared locator-map styling (estate-wide).
 * Popups only appear on multi-marker maps; their dark-mode contrast is pinned
 * because the OpenFreeMap tiles + popup are always light surfaces regardless of
 * site theme (the same fix the FPT food directory uses).
 */

.rcvda-map { width: 100%; height: 200px; position: relative; }

/* Marker: a coloured circle with a white Lucide glyph. */
.rcvda-map__marker {
	width: 30px; height: 30px; border-radius: 50%; border: 2px solid #fff; padding: 0;
	display: flex; align-items: center; justify-content: center; cursor: pointer;
	box-shadow: 0 1px 4px rgba(0,0,0,.35);
}
.rcvda-map__marker svg { width: 16px; height: 16px; stroke: #fff; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Popup (multi-marker maps only). Colours are literals: the popup sits on the
   always-light map tiles, so it must not inherit a dark-theme text colour. */
.rcvda-map__pop { font-family: inherit; min-width: 160px; }
.rcvda-map__pop-name { display: block; font-weight: 600; font-size: .95rem; color: #17643a; text-decoration: none; }
.rcvda-map__pop-name:hover { text-decoration: underline; }
.rcvda-map__pop-line { display: block; margin-top: .3rem; font-size: .82rem; color: #231F20; }

/* Contact/booking detail rows inside a popup (additive; present only when the
   caller supplies point.details). Literal dark text — the popup is always a
   light surface regardless of site theme. */
.rcvda-map__pop-detail { display: block; margin-top: .28rem; font-size: .8rem; line-height: 1.35; color: #231F20; word-break: break-word; }
.rcvda-map__pop-label { font-weight: 600; }
.rcvda-map__pop-detail a { color: #10224b; text-decoration: underline; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-detail { color: #231F20; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-detail a { color: #10224b; }

/* Dark mode: keep text/links dark on the light popup + attribution surfaces. */
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content { background: #fff; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-name { color: #17643a; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-line { color: #231F20; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-tip { border-top-color: #fff; border-bottom-color: #fff; }
html[data-theme="dark"] .rcvda-map .maplibregl-ctrl-attrib.maplibregl-compact { background: rgba(255,255,255,.9); }
html[data-theme="dark"] .rcvda-map .maplibregl-ctrl-attrib a { color: #231F20; }

/* Page-embedded maps (main-site content) are taller than the 200px rail default. */
.rcvda-venue-map,
.rcvda-boundary-map,
.rcvda-food-map,
.rcvda-route-map { height: 460px; }
@media (max-width: 600px) {
	.rcvda-venue-map,
	.rcvda-boundary-map,
	.rcvda-food-map,
	.rcvda-route-map { height: 360px; }
}

/* Food map: "full directory" link + accessible location list. */
.rcvda-food-map__more { margin: .5rem 0 0; font-weight: 600; }
.rcvda-food-map__list { margin: 1rem 0 0; padding-left: 1.2rem; }
.rcvda-food-map__list li { margin: .15rem 0; }

/* Venue popups sit on RCVDA navy rather than the FPT green default. */
.rcvda-venue-map .rcvda-map__pop-name,
html[data-theme="dark"] .rcvda-venue-map .maplibregl-popup-content .rcvda-map__pop-name { color: #10224b; }

/* Accessible directory list beneath the venue map (also the no-JS fallback).
   A name/area heading per place, then its contact/booking detail rows. */
.rcvda-venue-list { margin: 1rem 0 0; padding: 0; list-style: none; }
.rcvda-place-list__item { margin: 0 0 .9rem; padding: 0 0 .9rem; border-bottom: 1px solid rgba(0,0,0,.12); }
.rcvda-place-list__item:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.rcvda-place-list__name { display: block; font-weight: 600; }
.rcvda-place-list__details { display: block; margin-top: .25rem; }
.rcvda-place-list__detail { display: block; font-size: .88rem; line-height: 1.4; }
.rcvda-place-list__label { font-weight: 600; }
.rcvda-place-list__detail a { text-decoration: underline; }
html[data-theme="dark"] .rcvda-place-list__item { border-bottom-color: rgba(255,255,255,.18); }

/* Venue-hire rate + bookable rooms (per-space "Venue hire" services). */
.rcvda-place-list__hire { display: block; margin-top: .35rem; }
.rcvda-place-list__rooms { margin: .15rem 0 0 1.6rem; padding-left: 0; list-style: disc; }
.rcvda-place-list__rooms li { font-size: .86rem; line-height: 1.4; margin: .1rem 0; }
.rcvda-place-list__roomshead { font-weight: 600; }

/* Lucide glyph labels on directory rows (per WEB.md iconography). */
.rcvda-place-list__ico { width: 16px; height: 16px; vertical-align: -.16em; margin-right: .35rem; color: var(--wp--preset--color--contrast, #333); opacity: .7; }
.rcvda-place-list__facilities { margin-top: .15rem; }

/* Public single venue page (the_content append). */
/* Public single venue page — main-column icon-headed sections beside a rail
   "Visit" card, modeled on the FPT service-point page. */
.rcvda-place-single { margin-top: 1.25rem; }
.rcvda-place-single__parent { font-size: .9rem; margin: 0 0 1.25rem; }
.rcvda-place-single__section { margin: 0 0 2.2rem; max-width: 620px; }
.rcvda-place-single__section:last-child { margin-bottom: 0; }
.rcvda-place-single__section--full { max-width: none; } /* Find us: fill the column like the contact page */
.rcvda-heading-icon { color: var(--wp--preset--color--accent, #f29f05); margin-right: .45rem; vertical-align: -.14em; } /* [rcvda_icon] in a content heading (e.g. contact-us Find us / Send us a Message) */
.rcvda-place-single h2 { display: flex; align-items: center; gap: .55rem; margin: 0 0 .9rem; }
.rcvda-place-single h2 .rcvda-place-list__ico { width: 20px; height: 20px; opacity: 1; color: var(--wp--preset--color--accent, #f29f05); }
.rcvda-place-single__amenities { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem .9rem; }
.rcvda-place-single__amenities li { display: inline-flex; align-items: center; }
.rcvda-place-single__amgroup { font-size: .8rem; font-weight: 600; color: var(--wp--preset--color--muted, #033e8c); margin: .9rem 0 .35rem; }
.rcvda-place-single__amgroup:first-of-type { margin-top: .2rem; }
.rcvda-place-single__aminh { font-size: .8rem; font-weight: 400; color: #5a6a86; }
html[data-theme="dark"] .rcvda-place-single__amgroup { color: #a7c1d9; }
html[data-theme="dark"] .rcvda-place-single__aminh { color: #9fb3d0; }
.rcvda-place-single__facs { columns: 2; column-gap: 1.5rem; margin: 0; padding-left: 1.1rem; }
@media (max-width: 600px) { .rcvda-place-single__facs { columns: 1; } }
.rcvda-place-single__rate { font-weight: 500; margin: 0 0 .6rem; }
.rcvda-place-single__tablewrap { overflow-x: auto; }
.rcvda-place-single__rooms { width: 100%; border-collapse: collapse; font-size: .92rem; }
.rcvda-place-single__rooms th, .rcvda-place-single__rooms td { text-align: left; padding: .45rem .6rem; border-bottom: 1px solid rgba(0,0,0,.12); vertical-align: top; }
.rcvda-place-single__rooms th { font-weight: 600; }
html[data-theme="dark"] .rcvda-place-single__rooms th, html[data-theme="dark"] .rcvda-place-single__rooms td { border-bottom-color: rgba(255,255,255,.18); }
.rcvda-place-single__status { display: inline-block; font-weight: 600; font-size: .9rem; padding: .3rem .7rem; border-radius: 4px; margin: 0 0 1rem; }
.rcvda-place-single__status--paused { background: #fff3cd; color: #7a5b00; }
.rcvda-place-single__status--closed { background: #f8d7da; color: #842029; }

/* Visit card — sits in the theme editorial rail via [rcvda_place_visit]. */
.rcvda-place-visit { margin: 0 0 1.5rem; }
.rcvda-place-visit__card { background: var(--wp--preset--color--base, #fff); border: 1px solid var(--wp--preset--color--divider, #c3d4e2); border-radius: 16px; overflow: hidden; }
.rcvda-place-visit__accent { height: 5px; background: var(--wp--preset--color--accent, #f29f05); }
.rcvda-place-visit__body { padding: 20px 22px 22px; }
.rcvda-place-visit__head { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.rcvda-place-visit__chip { display: inline-flex; align-items: center; gap: .4em; font-size: .78rem; font-weight: 600; color: #fff; background: var(--wp--preset--color--brand, #0e1f40); padding: .4em .8em; border-radius: 7px; text-transform: capitalize; }
.rcvda-place-visit__chip .rcvda-place-list__ico { width: 15px; height: 15px; color: #fff; opacity: 1; margin: 0; }
.rcvda-place-visit__status { display: inline-flex; align-items: center; font-size: .78rem; font-weight: 600; padding: .4em .8em; border-radius: 7px; }
.rcvda-place-visit__status.is-paused { background: #fff3cd; color: #7a5b00; }
.rcvda-place-visit__status.is-closed { background: #f8d7da; color: #842029; }
.rcvda-place-visit__hire { display: flex; align-items: center; gap: .4rem; font-weight: 600; margin: .9rem 0 0; }
.rcvda-place-visit h3 { font-size: .7rem; letter-spacing: .09em; text-transform: uppercase; color: var(--wp--preset--color--muted, #033e8c); margin: 20px 0 .45rem; font-weight: 600; }
.rcvda-place-visit__addr { margin: 0 0 .6rem; }
.rcvda-place-visit__map { height: 180px; border-radius: 10px; overflow: hidden; margin: 0 0 .6rem; }
.rcvda-place-visit__dir { display: inline-flex; align-items: center; gap: .4em; font-weight: 500; }
.rcvda-place-visit__contact { list-style: none; margin: 0; padding: 0; }
.rcvda-place-visit__contact li { display: flex; align-items: center; gap: .5em; padding: .25rem 0; min-width: 0; }
.rcvda-place-visit__amenities { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .3rem .9rem; }
.rcvda-place-visit__amenities li { display: flex; align-items: center; gap: .45em; padding: .2rem 0; }
.rcvda-place-visit__amgroup { margin: .7rem 0 .1rem; font-size: .78rem; font-weight: 600; color: var(--wp--preset--color--brand, #0e1f40); }
.rcvda-place-visit h3 + .rcvda-place-visit__amgroup { margin-top: .1rem; }
.rcvda-place-visit__aminh { font-size: .72rem; font-weight: 400; color: #5a6a86; }
.rcvda-place-visit__cap { display: flex; align-items: center; gap: .45em; margin: 0 0 .5rem; font-weight: 600; }
.rcvda-place-visit__caps { list-style: none; margin: 0; padding: 0; max-width: 340px; }
.rcvda-place-visit__caps li { display: flex; justify-content: space-between; gap: 1em; padding: .28rem 0; border-bottom: 1px solid var(--wp--preset--color--divider, #e2e8f0); }
.rcvda-place-visit__caps li:last-child { border-bottom: 0; }
.rcvda-place-visit__capval { font-weight: 600; font-variant-numeric: tabular-nums; }

/* Getting-here — [rcvda_getting_here]: place + linked transport/parking. */
.rcvda-getting-here { margin: 0 0 1.5rem; }
.rcvda-getting-here__map { width: 100%; border-radius: 12px; overflow: hidden; margin: 0 0 1rem; }
.rcvda-getting-here__list h3 { display: flex; align-items: center; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--wp--preset--color--muted, #033e8c); margin: 1.2rem 0 .35rem; font-weight: 600; }
.rcvda-getting-here__list ul { list-style: none; margin: 0; padding: 0; }
.rcvda-getting-here__list li { padding: .35rem 0; border-bottom: 1px solid var(--wp--preset--color--divider, #e2e8f0); }
.rcvda-getting-here__list li:last-child { border-bottom: 0; }
.rcvda-getting-here__dir { white-space: nowrap; }
/* Mode glyphs on headings + rows — coloured inline (style="color:…") to match the
   map marker; SVG strokes follow currentColor. */
.rcvda-getting-here__ico { display: inline-block; vertical-align: -.18em; margin-right: .45rem; flex: none; }
.rcvda-getting-here__ico svg { display: block; width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.rcvda-getting-here__list h3 .rcvda-getting-here__ico { margin-right: .4rem; }
.rcvda-getting-here__list h3 .rcvda-getting-here__ico svg { width: 15px; height: 15px; }
/* Walking-distance ring labels on the map. */
.rcvda-map__ring-label { font: 600 11px/1 'Atkinson Hyperlegible Next', Verdana, Arial, sans-serif; color: #0e1f40; background: rgba(255,255,255,.82); border: 1px solid rgba(14,31,64,.25); border-radius: 999px; padding: 2px 7px; white-space: nowrap; pointer-events: none; }
.rcvda-place-visit__contact li a, .rcvda-place-visit__contact li { overflow-wrap: anywhere; word-break: break-word; }
.rcvda-place-visit__contact .rcvda-place-list__ico { flex: none; }
.rcvda-place-visit__addr { overflow-wrap: anywhere; }
.rcvda-place-visit__runby p { margin: 0; }
.rcvda-place-visit__networks { margin-top: .3rem; }
.rcvda-place-visit__network { display: inline-flex; align-items: center; gap: .35em; font-size: .8rem; font-weight: 600; background: var(--wp--preset--color--surface, #a7c1d9); color: var(--wp--preset--color--brand, #0e1f40); padding: .3em .7em; border-radius: 20px; margin: .2rem .3rem 0 0; }
.rcvda-place-visit__network .rcvda-place-list__ico { width: 14px; height: 14px; opacity: 1; margin: 0; }
html[data-theme="dark"] .rcvda-place-visit__card { background: #10224b; border-color: rgba(255,255,255,.18); }
/* Dark-mode chips: pin to on-brand colours so neither depends on a preset token
   that flips (the MEMBER-OF chip's surface bg went dark while its text stayed
   brand-navy → dark-on-dark; the type badge's brand bg could flip light under
   white text). DESIGN.md: Light Blue #a7c1d9, Dark Blue #0e1f40. */
html[data-theme="dark"] .rcvda-place-visit__network { background: #a7c1d9; color: #0e1f40; }
html[data-theme="dark"] .rcvda-place-visit__network .rcvda-place-list__ico { color: #0e1f40; }
html[data-theme="dark"] .rcvda-place-visit__chip { background: #0e1f40; color: #fff; }
html[data-theme="dark"] .rcvda-place-visit__chip .rcvda-place-list__ico { color: #fff; }
html[data-theme="dark"] .rcvda-place-visit__amgroup { color: #a7c1d9; }
html[data-theme="dark"] .rcvda-place-visit__aminh { color: #9fb3d0; }
html[data-theme="dark"] .rcvda-place-visit__caps li { border-bottom-color: rgba(255,255,255,.18); }
/* Getting-here mode icons are coloured inline (per-mode brand colours). The Walk
   glyph is Dark Blue #0e1f40 — invisible on the dark card — so give it its
   dark-mode variant (Light Blue #a7c1d9). !important beats the inline color. */
html[data-theme="dark"] .rcvda-getting-here__ico--walk { color: #a7c1d9 !important; }

/* Map data-source credits (dataset attribution). Uses the theme's contrast
   colour so it stays legible in light and dark; muted via opacity. */
.rcvda-boundary-figure { margin: 0; }
.rcvda-map-credit {
	margin: .4rem 0 0;
	font-size: .78rem;
	line-height: 1.4;
	color: var(--wp--preset--color--contrast, #333);
	opacity: .72;
}
.rcvda-map-credit a { color: inherit; text-decoration: underline; }

/* Local area — LA / ward / constituency, stacked (label over value). */
.rcvda-place-visit__area { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .7rem; }
.rcvda-place-visit__area li { display: flex; flex-direction: column; min-width: 0; }
.rcvda-place-visit__area-lbl { display: flex; align-items: center; gap: .35em; font-size: .74rem; text-transform: uppercase; letter-spacing: .03em; font-weight: 700; opacity: .75; }
.rcvda-place-visit__area-lbl .rcvda-place-list__ico { flex: none; margin: 0; opacity: 1; }
.rcvda-place-visit__area-val { margin: .12rem 0 0; font-weight: 600; overflow-wrap: anywhere; }

/* Route maps — borough colour legend under the map (see inc/shortcode-route-map.php).
   Text uses the theme contrast colour; swatches carry the fixed DESIGN.md borough
   colours, so the legend reads correctly in light and dark. */
.rcvda-route-figure { margin: 0; }
.rcvda-route-legend {
	list-style: none;
	margin: .5rem 0 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: .35rem .9rem;
	font-size: .8rem;
	color: var(--wp--preset--color--contrast, #333);
}
.rcvda-route-legend__item { display: inline-flex; align-items: center; gap: .4em; }
.rcvda-route-legend__sw {
	width: 1.05em;
	height: .32em;
	border-radius: 2px;
	flex: none;
	box-shadow: 0 0 0 1px rgba(0,0,0,.12) inset;
}
.rcvda-route-legend__label { overflow-wrap: anywhere; }


/* Layer toggle panel (route maps with cfg.layerControl). */
.rcvda-map__layers {
	position: absolute; top: 10px; left: 10px; z-index: 2;
	background: rgba(255,255,255,.92); color: #231F20;
	border-radius: 8px; padding: 7px 10px; font-size: .78rem; line-height: 1.5;
	box-shadow: 0 1px 6px rgba(0,0,0,.22); max-width: 52%;
}
html[data-theme="dark"] .rcvda-map__layers { background: rgba(18,24,32,.94); color: #e9eef5; }
.rcvda-map__layers-title { margin: 0 0 .25rem; font-weight: 700; }
.rcvda-map__layers label { display: flex; align-items: center; gap: .4em; cursor: pointer; }
.rcvda-map__layers input { margin: 0; flex: none; }

/* Copy-location control in facility popups (brand medium-blue; legible on the light popup bubble in both themes). */
.rcvda-map__pop-copy { display: inline-block; margin-top: .5rem; padding: .3rem .62rem; font: 600 .78rem/1 inherit; color: #ffffff; background: #033e8c; border: 0; border-radius: 4px; cursor: pointer; }
.rcvda-map__pop-copy:hover { background: #0e1f40; }
.rcvda-map__pop-copy.is-copied { background: #17643a; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-copy { color: #ffffff; background: #033e8c; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-copy:hover { background: #0e1f40; }
html[data-theme="dark"] .rcvda-map .maplibregl-popup-content .rcvda-map__pop-copy.is-copied { background: #17643a; }

/* Designations strip on a place single page — the estate "designations" treatment
   (cf. RFS 360Giving / IVAR). Regulator references as public badges, listing
   references as a discreet action link. Identifier values are never shown.
   Badge mirrors .rcvda-place-visit__chip (navy pill + white text, legible both modes);
   action link uses brand medium-blue, lifting to light-blue on the dark page. */
.rcvda-place-single__standards { display: flex; flex-wrap: wrap; align-items: center; gap: .5em .75em; margin: .7rem 0 0; padding: 0; list-style: none; }
.rcvda-place-single__standards > li { margin: 0; padding: 0; list-style: none; }
.rcvda-place-single__standard { display: inline-flex; align-items: center; gap: .4em; font-size: .78rem; font-weight: 600; line-height: 1.3; color: #fff; background: var(--wp--preset--color--brand, #0e1f40); padding: .35em .85em; border-radius: 999px; text-decoration: none; }
a.rcvda-place-single__standard:hover, a.rcvda-place-single__standard:focus-visible { opacity: .9; text-decoration: none; }
a.rcvda-place-single__standard:focus-visible { outline: 3px solid var(--wp--preset--color--accent, #f29f05); outline-offset: 2px; }
.rcvda-place-single__maplink { display: inline-flex; align-items: center; gap: .35em; font-size: .82rem; font-weight: 600; color: #033e8c; text-decoration: none; }
.rcvda-place-single__maplink:hover, .rcvda-place-single__maplink:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
html[data-theme="dark"] .rcvda-place-single__standard { background: #0e1f40; color: #fff; }
html[data-theme="dark"] .rcvda-place-single__maplink { color: #a7c1d9; }

/* Visit-card directions actions — stack "Get directions" and "View Google Maps
   listing" vertically in the narrow rail (the base __dir is inline-flex). */
.rcvda-place-visit__dirs { display: flex; flex-direction: column; align-items: flex-start; gap: .35rem; margin-top: .3rem; }
