/* Best Local Profile — front-end styles.
   Colors come from --blp-primary / --blp-accent / --blp-score, which a theme or the
   plugin's Appearance settings can set; the fallbacks below apply otherwise.
   Two designs: .blp-listing--modern (default) and .blp-listing--classic. */

.blp-listing, .blp-page, .blp-profile {
	--blp-p: var(--blp-primary, #e8192c);
	--blp-a: var(--blp-accent, #f5a623);
	--blp-s: var(--blp-score, #0f2d4a);
	--blp-ink: #1d2b3a;
	--blp-muted: #5d6b7a;
	--blp-line: #e3e8ee;
	color: var(--blp-ink);
}
.blp-listing *, .blp-page * { box-sizing: border-box; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }
.blp-icon { width: 16px; height: 16px; flex: none; }

/* ---------- Shared: header block (shortcode), buttons ---------- */
.blp-listing__header { text-align: center; padding: 2.5rem 1rem; }
.blp-listing__header h1, .blp-listing__header h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin: 0 0 .75rem; color: var(--blp-s); }
.blp-listing__intro { max-width: 70ch; margin: 0 auto; font-size: .95rem; color: var(--blp-muted); }
.blp-listing__intro > :last-child { margin-bottom: 0; }

.blp-btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; padding: .7rem 1.1rem; border: 1px solid transparent; border-radius: 6px; font-weight: 700; font-size: .875rem; text-decoration: none; cursor: pointer; font-family: inherit; line-height: 1.2; }
.blp-btn--visit { background: var(--blp-p); color: #fff; }
.blp-btn--profile { background: var(--blp-a); color: #fff; }
.blp-btn:hover { opacity: .92; color: #fff; }
.blp-btn .blp-icon { width: 15px; height: 15px; }

.blp-badge { display: inline-flex; flex: none; }
.blp-badge .blp-icon { width: 26px; height: 26px; }
.blp-badge--1 { color: #f0a30a; }
.blp-badge--2 { color: #aeb6c0; }
.blp-badge--3 { color: #c98a45; }
.blp-badge--4, .blp-badge--5 { color: #f0a30a; }
.blp-badge--4 .blp-icon, .blp-badge--5 .blp-icon { width: 22px; height: 22px; }

.blp-row__hint { margin: .6rem 0 0; padding: .4rem .7rem; border: 1px dashed #d99a00; background: #fff8e1; color: #6b5200; font-size: .75rem; border-radius: 3px; }
.blp-empty { text-align: center; padding: 3rem 1rem; color: var(--blp-muted); }

/* =====================================================================
   MODERN cards (default)
   ================================================================== */
.blp-listing--modern { max-width: 1180px; margin: 0 auto; padding: 0 1.5rem 2rem; }

.blp-listing--modern .blp-filters { display: flex; flex-wrap: wrap; gap: 1rem 1.25rem; align-items: flex-end; padding: 1.25rem 1.5rem; margin-bottom: 1.5rem; background: #fff; border-radius: 14px; box-shadow: 0 6px 26px rgba(15,45,74,.08); }
.blp-filters__field { display: flex; flex-direction: column; gap: .4rem; flex: 1 1 200px; min-width: 0; }
.blp-filters__label { display: inline-flex; align-items: center; gap: .4rem; font-size: .6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--blp-muted); }
.blp-filters__label .blp-icon { color: var(--blp-p); width: 14px; height: 14px; }
.blp-filters select { width: 100%; padding: .7rem .8rem; border: 1px solid var(--blp-line); border-radius: 8px; font: inherit; font-size: .9rem; color: var(--blp-ink); background: #fff; }
.blp-filters select:focus { outline: 2px solid var(--blp-p); outline-offset: 1px; }
.blp-filters__apply { padding: .8rem 1.4rem; border-radius: 10px; }
.blp-filters__reset { align-self: center; font-size: .8rem; font-weight: 700; color: var(--blp-p); text-decoration: none; }

.blp-summary { list-style: none; display: flex; flex-wrap: wrap; margin: 0 0 1.5rem; padding: 0 .5rem; }
.blp-summary li { display: flex; align-items: center; gap: .7rem; padding: .25rem 2rem .25rem 0; margin-right: 2rem; border-right: 1px solid var(--blp-line); }
.blp-summary li:last-child { border-right: 0; }
.blp-summary .blp-icon { width: 22px; height: 22px; color: var(--blp-p); }
.blp-summary strong { display: block; font-size: .9rem; line-height: 1.2; }
.blp-summary small { display: block; font-size: .72rem; color: var(--blp-muted); }

.blp-listing--modern .blp-row { display: grid; grid-template-columns: 190px minmax(0, 1fr) 190px; gap: 1.75rem; align-items: center; padding: 1.4rem 1.5rem; margin-bottom: 1.25rem; background: #fff; border-radius: 14px; box-shadow: 0 4px 22px rgba(15,45,74,.07); }
.blp-listing--modern .blp-row__media { display: flex; flex-direction: column; align-items: center; gap: .6rem; }
.blp-listing--modern .blp-row__logo { display: flex; align-items: center; justify-content: center; width: 100%; aspect-ratio: 1 / 1; padding: .9rem; border-radius: 14px; background: #fdeff0; background: color-mix(in srgb, var(--blp-p) 8%, #fff); }
.blp-listing--modern .blp-row__logo img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.blp-row__logo-fallback { font-weight: 700; text-align: center; color: var(--blp-s); font-size: .9rem; }
.blp-listing--modern .blp-score { margin: 0; text-align: center; }
.blp-listing--modern .blp-score__label { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .8rem; border-radius: 999px; background: #fff; box-shadow: 0 2px 10px rgba(15,45,74,.12); font-size: .75rem; color: var(--blp-muted); white-space: nowrap; }
.blp-listing--modern .blp-score__label strong { color: var(--blp-a); font-size: .8rem; }
.blp-score__star { width: 14px; height: 14px; color: var(--blp-a); }
.blp-score__bar { height: 8px; background: #ececec; margin-top: .5rem; border-radius: 4px; overflow: hidden; width: 100%; }
.blp-score__bar span { display: block; height: 100%; background: var(--blp-s); }

.blp-row__title { margin: 0 0 .45rem; font-size: 1.5rem; font-weight: 700; line-height: 1.2; display: flex; align-items: center; gap: .5rem; }
.blp-row__title a { color: var(--blp-s); text-decoration: none; }
.blp-row__title a:hover { text-decoration: underline; }
.blp-row__rank { margin: 0 0 .4rem; font-size: .9rem; font-weight: 700; color: var(--blp-ink); }
.blp-row__desc { margin: 0 0 .85rem; font-size: .9rem; line-height: 1.6; color: var(--blp-muted); max-width: 62ch; }
.blp-row__meta { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 0; margin: 0; padding: 0; font-size: .8rem; color: var(--blp-muted); }
.blp-meta { display: inline-flex; align-items: center; gap: .4rem; padding-right: 1.1rem; margin-right: 1.1rem; border-right: 1px solid var(--blp-line); }
.blp-meta:last-child { border-right: 0; margin-right: 0; padding-right: 0; }
.blp-meta a { color: inherit; text-decoration: none; }
.blp-meta a:hover { text-decoration: underline; }
.blp-meta--check .blp-icon { color: var(--blp-a); }
.blp-meta--pin .blp-icon { color: var(--blp-p); }

.blp-listing--modern .blp-row__actions { display: flex; flex-direction: column; gap: .6rem; }
.blp-listing--modern .blp-btn { justify-content: space-between; padding: .8rem 1rem; }
.blp-listing--modern .blp-btn--profile { background: #fff; color: var(--blp-s); border-color: var(--blp-line); }
.blp-listing--modern .blp-btn--profile:hover { border-color: var(--blp-s); color: var(--blp-s); opacity: 1; }

.blp-listing__footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem .5rem 0; }
.blp-count { margin: 0; font-size: .8rem; color: var(--blp-muted); }
.blp-pagination { display: flex; gap: .4rem; margin-left: auto; }
.blp-pagination .page-numbers { display: flex; align-items: center; justify-content: center; min-width: 36px; height: 36px; padding: 0 .5rem; border-radius: 50%; border: 1px solid var(--blp-line); background: #fff; color: var(--blp-ink); font-size: .85rem; text-decoration: none; }
.blp-pagination .page-numbers.current { background: var(--blp-p); border-color: var(--blp-p); color: #fff; }
.blp-pagination a.page-numbers:hover { border-color: var(--blp-p); color: var(--blp-p); }

/* =====================================================================
   CLASSIC rows (optional)
   ================================================================== */
.blp-listing--classic .blp-filters { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: flex-end; justify-content: center; padding: 1.1rem 1rem; border-bottom: 1px solid #e8e8e8; }
.blp-listing--classic .blp-filters__label .blp-icon, .blp-listing--classic .blp-score__star, .blp-listing--classic .blp-btn .blp-icon { display: none; }
.blp-listing--classic .blp-filters__field { flex: 0 1 auto; }
.blp-listing--classic .blp-filters select { min-width: 190px; width: auto; }
.blp-listing--classic .blp-summary { justify-content: center; margin: 1rem 0; }
.blp-listing--classic .blp-listing__rows { max-width: 1100px; margin: 0 auto; }
.blp-listing--classic .blp-row { display: grid; grid-template-columns: 200px minmax(0, 1fr) 170px; gap: 1.75rem; align-items: start; padding: 2rem 1.5rem; }
.blp-listing--classic.blp-listing--alt .blp-row:nth-child(even) { background: #f8f8f8; }
.blp-listing--classic .blp-row__logo { display: flex; align-items: center; justify-content: center; min-height: 70px; padding: .5rem; }
.blp-listing--classic .blp-row__logo img { max-width: 100%; max-height: 90px; width: auto; height: auto; }
.blp-listing--classic .blp-score { margin-top: .5rem; font-size: .8rem; }
.blp-listing--classic .blp-score__label strong { color: var(--blp-a); }
.blp-listing--classic .blp-row__title { font-weight: 400; font-size: 1.6rem; }
.blp-listing--classic .blp-row__actions { display: flex; flex-direction: column; gap: .5rem; }
.blp-listing--classic .blp-btn { display: block; text-align: center; border-radius: 3px; }
.blp-listing--classic .blp-listing__footer { max-width: 1100px; margin: 0 auto; }

/* ---------- Profile info block (profile page) ---------- */
.blp-bizinfo { margin-top: 1.1rem; }
.blp-bizinfo__list { list-style: none; margin: 0; padding: 0; display: grid; gap: .65rem; }
.blp-biz { display: flex; align-items: center; flex-wrap: wrap; gap: .25rem .6rem; font-size: .95rem; color: #1d2b3a; }
.blp-biz > .blp-icon { width: clamp(18px, 5vw, 22px); height: clamp(18px, 5vw, 22px); color: var(--blp-primary, #e8192c); }
.blp-biz--google > .blp-icon { color: #4285f4; }
.blp-biz--address { align-items: flex-start; }
.blp-biz a { color: inherit; }
.blp-biz a:hover { text-decoration: underline; }
.blp-biz__google { display: inline-flex; align-items: center; flex-wrap: wrap; gap: .2rem .55rem; }
.blp-biz__glabel { font-weight: 700; color: var(--blp-score, #0f2d4a); }
.blp-biz__rating { font-size: 1rem; }
.blp-biz__count { font-size: .85rem; color: #5d6b7a; }
.blp-stars { position: relative; display: inline-block; font-size: 1.05rem; line-height: 1; letter-spacing: .08em; color: #d9dee5; white-space: nowrap; }
.blp-stars__fill { position: absolute; left: 0; top: 0; overflow: hidden; white-space: nowrap; color: var(--blp-accent, #f5a623); }
.blp-tags { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; margin: .9rem 0 0; padding: 0; }
.blp-tags li { padding: .3rem .8rem; border-radius: 999px; background: #fdeff0; background: color-mix(in srgb, var(--blp-primary, #e8192c) 9%, #fff); color: var(--blp-primary, #e8192c); font-size: .78rem; font-weight: 700; }

/* ---------- Pages (plugin fallback templates) ---------- */
.blp-page__header { background: #f1f1f1; }
.blp-page__body { padding-bottom: 2rem; }
.blp-profile__inner { max-width: 960px; margin: 0 auto; padding: 2.5rem 1.5rem; }
.blp-profile__header { display: flex; gap: 2rem; align-items: center; margin-bottom: 2rem; }
.blp-profile__logo img { max-width: 220px; height: auto; }
.blp-profile__header h1 { display: flex; align-items: center; gap: .5rem; margin: 0 0 .75rem; color: var(--blp-s); }
.blp-profile__header .blp-btn { margin-top: 1rem; }
.blp-profile__terms { margin-top: 2rem; font-size: .9rem; display: flex; flex-wrap: wrap; gap: 1rem 2rem; }
.blp-profile__term-label { font-weight: 700; }

@media (max-width: 860px) {
	.blp-listing--modern .blp-row, .blp-listing--classic .blp-row { grid-template-columns: 1fr; gap: 1rem; }
	.blp-listing--modern .blp-row__media { flex-direction: row; justify-content: flex-start; gap: 1rem; }
	.blp-listing--modern .blp-row__logo { width: 96px; flex: none; }
	.blp-listing--modern .blp-row__actions, .blp-listing--classic .blp-row__actions { flex-direction: row; }
	.blp-listing--modern .blp-btn, .blp-listing--classic .blp-btn { flex: 1; }
	.blp-summary li { padding-right: 1rem; margin-right: 1rem; }
	.blp-pagination { margin-left: 0; }
	.blp-profile__header { flex-direction: column; align-items: flex-start; }
}

/* =====================================================================
   LOCAL listing format (default in v3): a ranking strip, name, address and
   Google stars, a round category icon, and a "View Profile" details table.
   Filters, summary strip, result count and pagination reuse the modern styles
   (the list carries both .blp-listing--modern and .blp-listing--local).
   ================================================================== */
.blp-listing--local .blp-row--local { display: block; padding: 0; overflow: hidden; background: #fff; border: 1px solid #e3e3e3; border-radius: 16px; box-shadow: 0 4px 18px rgba(15,45,74,.06); margin-bottom: 1.5rem; }
.blp-local__strip { padding: .9rem 1.5rem; background: #efeeee; font-weight: 700; font-size: clamp(.9rem, 2.6vw, 1.05rem); color: var(--blp-ink); }
.blp-local__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1.25rem; padding: 1.4rem 1.5rem .4rem; }
.blp-local__id { min-width: 0; }
.blp-local__name { margin: 0; font-size: clamp(1.35rem, 3.4vw, 2rem); font-weight: 800; line-height: 1.15; letter-spacing: -.01em; overflow-wrap: anywhere; }
.blp-local__name a { color: #111; text-decoration: none; }
.blp-local__name a:hover { text-decoration: underline; }
.blp-local__address { margin: .35rem 0 0; font-size: clamp(.9rem, 2.4vw, 1.15rem); line-height: 1.4; color: #8a949e; }
.blp-local__rating { display: flex; align-items: center; flex-wrap: wrap; gap: .1rem .45rem; margin: .5rem 0 0; font-size: .85rem; }
.blp-local__glink { display: inline-flex; align-items: center; flex-wrap: wrap; gap: .1rem .45rem; color: inherit; text-decoration: none; }
.blp-local__score { font-weight: 600; }
.blp-local__count { color: var(--blp-muted); }
.blp-local__icon { flex: none; display: flex; align-items: center; justify-content: center; width: clamp(44px, 10vw, 60px); height: clamp(44px, 10vw, 60px); border-radius: 50%; overflow: hidden; background: var(--blp-icon-color, var(--blp-p)); color: #fff; }
.blp-local__icon .blp-icon { width: 54%; height: 54%; }
.blp-local__icon img { width: 100%; height: 100%; object-fit: contain; padding: .3rem; background: #fff; }

.blp-local__more { padding: 0 1.5rem 1.5rem; }
.blp-local__more > summary { display: inline-flex; align-items: center; gap: .75rem; padding: .85rem 0; cursor: pointer; list-style: none; font-weight: 700; font-size: 1.05rem; color: #222; }
.blp-local__more > summary::-webkit-details-marker { display: none; }
.blp-local__more > summary:focus-visible { outline: 2px solid var(--blp-p); outline-offset: 3px; }
.blp-local__more > summary .blp-icon { width: 20px; height: 20px; transition: transform .18s ease; }
.blp-local__more[open] > summary .blp-icon { transform: rotate(180deg); }

.blp-local__table { width: 100%; border-collapse: separate; border-spacing: 0 .45rem; font-size: .92rem; }
.blp-local__table th, .blp-local__table td { padding: .8rem 1rem; border: 1px solid #ececec; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.blp-local__table th { width: 28%; min-width: 7.5rem; background: #fafafa; border-right: 0; border-radius: 6px 0 0 6px; color: #8a949e; font-weight: 700; }
.blp-local__table td { border-radius: 0 6px 6px 0; color: #1d2b3a; }
.blp-local__table td a { color: var(--blp-s); }
.blp-local__table .blp-tags { margin: 0; }
.blp-local__table .blp-stars { font-size: 1rem; }
.blp-local__actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1rem; }
.blp-listing--local .blp-local__actions .blp-btn { flex: 0 1 auto; min-width: 190px; }

@media (max-width: 860px) {
	.blp-local__head { padding: 1.1rem 1rem .3rem; }
	.blp-local__strip { padding: .75rem 1rem; }
	.blp-local__more { padding: 0 1rem 1.25rem; }
	.blp-local__table th { width: 34%; min-width: 0; padding: .7rem .75rem; }
	.blp-local__table td { padding: .7rem .75rem; }
	.blp-listing--local .blp-local__actions .blp-btn { flex: 1 1 100%; }
}
