/* Vista pública de gasolineras (invitados): mapa + buscador/chips flotantes + lista compacta y ficha.
   Patrón de Google Maps / GasBuddy. Escritorio: panel a la izquierda. Móvil y tableta: cajón inferior con tres alturas. */

.is-explore .app-main { padding: 0; }
.is-explore .app-content { max-width: none; padding: 0; }

.ex { position: fixed; z-index: 1; inset: var(--mobile-bar-h, 3.5rem) 0 calc(4rem + env(safe-area-inset-bottom)) 0; overflow: hidden; }
@media (min-width: 48rem) { .ex { inset: 0 0 0 16rem; } }

/* ---------- Mapa ---------- */
.ex-map { position: absolute; inset: 0; z-index: 0; isolation: isolate; }
.ex-map #exMap { width: 100%; height: 100%; background: var(--card-sunken, #e9eef2); }
.dark .ex-map .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(0.9) contrast(0.9); }
.ex .leaflet-control-zoom { border: 0; border-radius: 0.9rem; overflow: hidden; margin: 0 1.1rem 1.2rem 0; box-shadow: 0 0 0 1px var(--border), 0 10px 26px -12px rgb(0 0 0 / 0.55); }
.ex .leaflet-control-zoom a { width: 2.4rem; height: 2.4rem; line-height: 2.4rem; border: 0; color: var(--foreground); background: color-mix(in srgb, var(--card) 86%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.ex .leaflet-control-attribution { background: color-mix(in srgb, var(--card) 72%, transparent); color: var(--muted-foreground); font-size: 0.62rem; border-radius: 0.5rem 0 0 0; }
.ex .leaflet-control-attribution a { color: inherit; }
@media (max-width: 63.99rem) { .ex .leaflet-control-zoom { display: none; } }

/* Marcadores: píldora blanca con el color de la marca y el precio; la elegida se agranda y toma el color de acento */
.is-explore .fuel-marker { display: inline-flex; align-items: center; gap: 0.36rem; padding: 0.3rem 0.62rem 0.3rem 0.48rem; border-radius: 999px; font: 800 0.8rem/1 var(--font-body); letter-spacing: -0.01em; font-variant-numeric: tabular-nums; color: #11151a; background: rgb(255 255 255 / 0.95); border: 1px solid rgb(0 0 0 / 0.08); box-shadow: 0 1px 2px rgb(0 0 0 / 0.18), 0 6px 14px -4px rgb(0 0 0 / 0.4); transform: translate(-50%, -50%); transition: transform 0.22s var(--ease-out), background-color 0.2s, color 0.2s, box-shadow 0.2s; }
.is-explore .fuel-marker .fm-dot { flex: none; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--brand, #9aa3ad); box-shadow: 0 0 0 1.5px rgb(255 255 255 / 0.9), 0 0 0 2.5px rgb(0 0 0 / 0.08); }
.is-explore .fuel-marker.is-cheapest { box-shadow: 0 0 0 2px #1f8f5f, 0 6px 14px -4px rgb(0 0 0 / 0.4); }
.is-explore .fuel-marker.is-active { transform: translate(-50%, -50%) scale(1.1); color: #fff; background: rgb(var(--a-500)); border-color: transparent; box-shadow: 0 0 0 2px #fff, 0 12px 26px -6px rgb(var(--a-500) / 0.75); z-index: 2; }
.is-explore .fuel-marker.is-active .fm-dot { box-shadow: 0 0 0 1.5px #fff; }
@media (max-width: 63.99rem) { .is-explore .fuel-marker { padding: 0.26rem 0.55rem 0.26rem 0.42rem; font-size: 0.74rem; } }

/* ---------- Capa superior: buscador y chips ---------- */
.ex-col { display: contents; }
.ex-top { position: absolute; z-index: 7; top: 0.6rem; left: 0.6rem; right: 0.6rem; }
@media (min-width: 48rem) and (max-width: 63.99rem) { .ex-top { right: 17.25rem; } } /* deja libre el botón de acceso */

.ex-search { position: relative; z-index: 2; display: flex; align-items: center; gap: 0.25rem; height: 3rem; padding: 0 0.35rem 0 1rem; border-radius: 999px; background: color-mix(in srgb, var(--card) 94%, transparent); -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4); box-shadow: 0 0 0 1px var(--border), 0 12px 30px -14px rgb(0 0 0 / 0.5); transition: box-shadow 0.2s var(--ease-out); }
.ex-search:focus-within { box-shadow: 0 0 0 2px rgb(var(--a-500)), 0 14px 34px -14px rgb(0 0 0 / 0.55); }
.ex-search-ico { flex: none; width: 1.1rem; height: 1.1rem; color: var(--muted-foreground); margin-right: 0.35rem; }
.ex-search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: var(--foreground); font: 500 0.95rem/1 var(--font-body); }
.ex-search input::placeholder { color: var(--muted-foreground); }
.ex-search input::-webkit-search-cancel-button { display: none; }
.ex-locate { flex: none; width: 2.4rem; height: 2.4rem; display: grid; place-items: center; border: 0; border-radius: 50%; cursor: pointer; background: transparent; color: rgb(var(--a-500)); transition: background-color 0.16s, scale 0.16s var(--ease-out); }
.ex-locate:hover { background: rgb(var(--a-500) / 0.12); } .ex-locate:active { scale: 0.92; }
.ex-locate.is-loading svg { animation: exSpin 0.9s linear infinite; }
@keyframes exSpin { to { transform: rotate(360deg); } }
.ex-search:focus-within .ex-search-ico { color: rgb(var(--a-500)); }

.ex-place-list { position: absolute; z-index: 9; top: calc(100% + 0.45rem); left: 0; right: 0; max-height: 17rem; overflow: auto; margin: 0; padding: 0.35rem; list-style: none; border-radius: 1.1rem; background: var(--card); box-shadow: 0 0 0 1px var(--border-strong), 0 24px 50px -20px rgb(0 0 0 / 0.55); }
.ex-place-list li { display: flex; align-items: center; gap: 0.7rem; padding: 0.6rem 0.7rem; border-radius: 0.75rem; cursor: pointer; outline: 0; }
.ex-place-list li:hover, .ex-place-list li:focus { background: var(--muted); }
.ex-place-list svg { flex: none; color: var(--muted-foreground); }
.ex-place-list strong { display: block; font-size: 0.92rem; } .ex-place-list small { color: var(--muted-foreground); font-size: 0.76rem; }
.ex-place-empty { color: var(--muted-foreground); font-size: 0.85rem; cursor: default !important; }

.ex-chips { display: flex; align-items: center; gap: 0.4rem; margin-top: 0.55rem; padding: 2px 2px 6px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.ex-chips::-webkit-scrollbar { display: none; }
.ex-chip { flex: none; display: inline-flex; align-items: center; gap: 0.3rem; height: 2.2rem; padding: 0 0.9rem; border: 0; border-radius: 999px; cursor: pointer; white-space: nowrap; font: 600 0.82rem/1 var(--font-body); color: var(--foreground); background: color-mix(in srgb, var(--card) 94%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 0 0 1px var(--border), 0 6px 16px -10px rgb(0 0 0 / 0.5); transition: background-color 0.16s, color 0.16s, box-shadow 0.16s, scale 0.16s var(--ease-out); }
.ex-chip:active { scale: 0.96; }
.ex-chip[aria-checked='true'] { background: rgb(var(--a-500)); color: #fff; box-shadow: 0 1px 2px rgb(var(--a-700) / 0.5), 0 8px 18px -8px rgb(var(--a-500) / 0.8); }
.ex-chip.is-set { box-shadow: 0 0 0 1.5px rgb(var(--a-500)); color: rgb(var(--a-500)); }
.ex-chip-menu svg { opacity: 0.6; transition: transform 0.2s var(--ease-out); }
.ex-chip-menu[aria-expanded='true'] svg { transform: rotate(180deg); }
.ex-chip-sep { flex: none; width: 1px; height: 1.2rem; background: var(--border-strong); margin: 0 0.1rem; }
@media (hover: hover) { .ex-chip:not([aria-checked='true']):hover { background: var(--card); box-shadow: 0 0 0 1px var(--border-strong), 0 8px 18px -10px rgb(0 0 0 / 0.55); } }
.ex-chip:focus-visible, .ex-btn:focus-visible, .ex-row:focus-visible, .ex-back:focus-visible, .ex-pop button:focus-visible, .ex-locate:focus-visible { outline: 2px solid rgb(var(--a-500)); outline-offset: 2px; }

.ex-pop { position: absolute; z-index: 10; max-height: 17rem; overflow: auto; padding: 0.3rem; border-radius: 1.1rem; background: var(--card); box-shadow: 0 0 0 1px var(--border-strong), 0 24px 50px -20px rgb(0 0 0 / 0.55); }
.ex-pop[hidden] { display: none; }
.ex-pop button { width: 100%; display: flex; align-items: center; gap: 0.6rem; padding: 0.6rem 0.7rem; border: 0; border-radius: 0.75rem; background: none; text-align: left; cursor: pointer; font: 500 0.88rem/1.2 var(--font-body); color: var(--foreground); }
.ex-pop button span { flex: 1; } .ex-pop button:hover { background: var(--muted); }
.ex-pop button[aria-checked='true'] { font-weight: 700; color: rgb(var(--a-500)); }

/* ---------- Cajón / panel ---------- */
.ex-sheet { position: absolute; z-index: 5; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; border-radius: 1.5rem 1.5rem 0 0; background: color-mix(in srgb, var(--card) 95%, transparent); -webkit-backdrop-filter: blur(22px) saturate(1.4); backdrop-filter: blur(22px) saturate(1.4); box-shadow: 0 -1px 0 var(--border), 0 -20px 50px -22px rgb(0 0 0 / 0.5); will-change: transform; }
/* Antes de que el JS mida y coloque el cajón (carga diferida) ocupa ya la altura de "medio": sin salto al arrancar */
@media (max-width: 63.99rem) { .ex-sheet:not([data-snap]) { height: 28%; } }
.ex-sheet-head { flex: none; padding: 0.15rem 1rem 0.7rem; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.ex-grab { display: block; width: 100%; height: 1.3rem; padding: 0; border: 0; background: none; cursor: grab; }
.ex-grab span { display: block; width: 2.6rem; height: 4px; margin: 0.55rem auto 0; border-radius: 4px; background: var(--border-strong); }
.ex-sum { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.35rem 0.7rem; min-height: 1.6rem; }
.ex-sum-main { font-size: 0.9rem; color: var(--muted-foreground); white-space: nowrap; } .ex-sum-main strong, .ex-sum-main b { color: var(--foreground); font-variant-numeric: tabular-nums; }
.ex-live { flex: none; display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.25rem 0.6rem; border-radius: 999px; font-size: 0.72rem; font-weight: 600; color: var(--muted-foreground); background: var(--muted); }
.ex-live { border: 0; cursor: pointer; font-family: inherit; transition: background-color 0.15s, scale 0.15s var(--ease-out); }
.ex-live:hover:not(:disabled) { background: var(--border-strong); } .ex-live:active:not(:disabled) { scale: 0.96; }
.ex-live:disabled { cursor: default; } .ex-live:focus-visible { outline: 2px solid rgb(var(--a-500)); outline-offset: 2px; }
.ex-live-ico { opacity: 0.6; } .ex-live.is-busy .ex-live-ico { animation: exSpin 0.8s linear infinite; }
.ex-live i { width: 0.45rem; height: 0.45rem; border-radius: 50%; background: #1f8f5f; }
.ex-live.is-old i { background: #d49a1c; } .ex-live.is-stale i { background: #d4493c; }
.ex-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0 0.5rem calc(1rem + env(safe-area-inset-bottom)); scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }

/* Escritorio: panel docked a la izquierda con buscador arriba (como Google Maps) */
@media (min-width: 64rem) {
  .ex-col { position: absolute; z-index: 6; top: 0; left: 0; bottom: 0; width: clamp(22rem, 30vw, 26rem); display: flex; flex-direction: column; background: color-mix(in srgb, var(--card) 90%, transparent); -webkit-backdrop-filter: blur(24px) saturate(1.5); backdrop-filter: blur(24px) saturate(1.5); box-shadow: 1px 0 0 var(--border), 24px 0 60px -34px rgb(0 0 0 / 0.55); }
  .ex-top { position: relative; z-index: 7; top: auto; left: auto; right: auto; flex: none; padding: 1rem 1rem 0.35rem; }
  .ex-search { box-shadow: 0 0 0 1px var(--border-strong); background: var(--card); }
  .ex-sheet { position: relative; z-index: auto; flex: 1; min-height: 0; height: auto !important; transform: none !important; border-radius: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; will-change: auto; }
  .ex-sheet-head { padding: 0.35rem 1.2rem 0.6rem; cursor: default; touch-action: auto; }
  .ex-grab { display: none; }
  .ex-body { padding: 0 0.6rem 1rem; }
  .ex-chips { margin-top: 0.6rem; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 1.6rem), transparent); }
  .ex-chip { background: var(--card); backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* ---------- Lista compacta ---------- */
.ex-list { display: grid; }
.ex-row { width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 0.8rem; padding: 0.75rem 0.6rem; border: 0; border-radius: 1rem; background: none; text-align: left; cursor: pointer; color: inherit; transition: background-color 0.15s, scale 0.15s var(--ease-out); }
.ex-row + .ex-row { box-shadow: 0 -1px 0 var(--border); }
.ex-row:active { scale: 0.99; }
@media (hover: hover) { .ex-row:hover { background: var(--muted); } }
.ex-row.is-selected { background: rgb(var(--a-500) / 0.1); }
.ex-row-main { min-width: 0; display: grid; gap: 0.1rem; }
.ex-row-main strong { font: 700 0.95rem/1.25 var(--font-display); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ex-row-main small { color: var(--muted-foreground); font-size: 0.78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ex-best { justify-self: start; margin-top: 0.2rem; padding: 0.12rem 0.5rem; border-radius: 999px; font: 700 0.66rem/1.4 var(--font-body); font-style: normal; letter-spacing: 0.02em; color: #14633f; background: rgb(31 143 95 / 0.16); }
.dark .ex-best { color: #6fe0ac; }
.ex-row-price { display: grid; grid-template-columns: auto auto; align-items: baseline; justify-items: end; column-gap: 0.25rem; }
.ex-row-price b { font: 800 1.2rem/1 var(--font-display); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.ex-row-price small { color: var(--muted-foreground); font-size: 0.7rem; }
.ex-dot { grid-column: 1 / -1; margin-top: 0.4rem; width: 0.55rem; height: 0.55rem; border-radius: 50%; background: #d49a1c; }
.ex-dot.is-low { background: #1f8f5f; } .ex-dot.is-high { background: #d4493c; }
.ex-more { margin: 0.6rem auto 0.4rem; display: block; padding: 0.7rem 1.2rem; border: 0; border-radius: 999px; background: var(--muted); font: 600 0.86rem var(--font-body); color: var(--foreground); cursor: pointer; }
.ex-foot { margin: 0.9rem 0.7rem 0; font-size: 0.72rem; line-height: 1.45; color: var(--muted-foreground); }

/* ---------- Ficha de la estación ---------- */
.ex-detail { padding: 0.2rem 0.7rem 0.5rem; display: grid; gap: 1rem; }
.ex-back { justify-self: start; display: inline-flex; align-items: center; gap: 0.4rem; min-height: 2.5rem; padding: 0 0.6rem 0 0.3rem; border: 0; border-radius: 999px; background: none; cursor: pointer; font: 600 0.84rem var(--font-body); color: var(--muted-foreground); }
@media (hover: hover) { .ex-back:hover { color: var(--foreground); background: var(--muted); } }
.ex-d-head { display: flex; align-items: center; gap: 0.9rem; }
.ex-d-head h2 { margin: 0; font: 800 1.2rem/1.2 var(--font-display); letter-spacing: -0.02em; text-wrap: balance; }
.ex-d-head p { margin: 0.2rem 0 0; color: var(--muted-foreground); font-size: 0.84rem; }
.ex-d-price { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.ex-d-price b { font: 800 2.7rem/1 var(--font-display); letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.ex-d-price span { margin-left: 0.3rem; color: var(--muted-foreground); font-weight: 600; } .ex-d-price small { display: block; margin-top: 0.25rem; color: var(--muted-foreground); font-size: 0.78rem; }
.ex-tier { padding: 0.3rem 0.75rem; border-radius: 999px; font: 700 0.76rem/1.2 var(--font-body); color: #8a5b00; background: rgb(212 154 28 / 0.18); }
.ex-tier.is-low { color: #14633f; background: rgb(31 143 95 / 0.16); } .ex-tier.is-high { color: #9c2f24; background: rgb(212 73 60 / 0.16); }
.dark .ex-tier { color: #f0c36b; } .dark .ex-tier.is-low { color: #6fe0ac; } .dark .ex-tier.is-high { color: #ff9a8f; }
.ex-d-delta { margin: -0.4rem 0 0; font-size: 0.84rem; color: var(--muted-foreground); } .ex-d-delta strong { color: #1f8f5f; }
.ex-d-meta { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.ex-d-meta span { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.3rem 0.7rem; border-radius: 999px; background: var(--muted); font-size: 0.78rem; color: var(--muted-foreground); }
.ex-d-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.ex-btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 2.9rem; padding: 0 1rem; border: 0; border-radius: 999px; cursor: pointer; text-decoration: none; font: 700 0.88rem/1 var(--font-display); color: var(--foreground); background: var(--muted); box-shadow: 0 0 0 1px var(--border); transition: background-color 0.16s, box-shadow 0.16s, scale 0.16s var(--ease-out); }
.ex-btn:active { scale: 0.97; }
@media (hover: hover) { .ex-btn:hover { background: var(--card); box-shadow: 0 0 0 1px var(--border-strong); } }
.ex-btn-primary { color: #fff; background: linear-gradient(135deg, rgb(var(--a-500)), rgb(var(--a-400))); box-shadow: 0 1px 2px rgb(var(--a-700) / 0.5), 0 10px 22px -10px rgb(var(--a-500) / 0.8), inset 0 1px 0 rgb(255 255 255 / 0.25); }
@media (hover: hover) { .ex-btn-primary:hover { background: linear-gradient(135deg, rgb(var(--a-500)), rgb(var(--a-400))); filter: brightness(1.06); box-shadow: 0 1px 2px rgb(var(--a-700) / 0.5), 0 14px 28px -10px rgb(var(--a-500) / 0.9), inset 0 1px 0 rgb(255 255 255 / 0.3); } }
.ex-lock { opacity: 0.55; }
.ex-d-title { margin: 0.2rem 0 -0.3rem; font: 700 0.72rem/1 var(--font-body); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-foreground); }
.ex-d-prices { list-style: none; margin: 0; padding: 0; border-radius: 1rem; box-shadow: 0 0 0 1px var(--border); overflow: hidden; }
.ex-d-prices li { display: flex; justify-content: space-between; gap: 1rem; padding: 0.7rem 0.9rem; font-size: 0.88rem; }
.ex-d-prices li + li { box-shadow: 0 -1px 0 var(--border); }
.ex-d-prices li strong { font-variant-numeric: tabular-nums; } .ex-d-prices li.is-on { background: rgb(var(--a-500) / 0.1); font-weight: 700; }

/* ---------- Estados ---------- */
.ex-state { padding: 1.4rem 1rem 1rem; text-align: center; display: grid; justify-items: center; gap: 0.55rem; }
.ex-state[hidden] { display: none; }
.ex-state h2 { margin: 0.2rem 0 0; font: 800 1.15rem/1.2 var(--font-display); } .ex-state p { margin: 0 0 0.4rem; max-width: 22rem; color: var(--muted-foreground); font-size: 0.9rem; text-wrap: pretty; }
.ex-state-ico { width: 3rem; height: 3rem; display: grid; place-items: center; border-radius: 1rem; color: rgb(var(--a-500)); background: rgb(var(--a-500) / 0.12); }
.ex-state.is-loading { padding: 0.3rem 0.4rem; justify-items: stretch; }
.ex-skel { height: 4.2rem; margin: 0.4rem 0.2rem; border-radius: 1rem; background: linear-gradient(100deg, var(--muted) 30%, color-mix(in srgb, var(--muted) 40%, transparent) 50%, var(--muted) 70%); background-size: 200% 100%; animation: exShimmer 1.3s linear infinite; }
@keyframes exShimmer { to { background-position: -200% 0; } }

@media (prefers-reduced-motion: reduce) {
  .ex-skel, .ex-locate.is-loading svg { animation: none; }
  .ex-chip, .ex-row, .ex-btn, .is-explore .fuel-marker, .ex-chip-menu svg { transition: none; }
}

/* display:grid/flex de los bloques no debe anular el atributo hidden */
.ex [hidden] { display: none !important; }

/* ---------- Contenido SEO (renderizado en servidor): migas, títulos, tablas y enlaces internos ---------- */
a.ex-row { text-decoration: none; }
.ex-row-main h3 { margin: 0; font: 700 0.95rem/1.25 var(--font-display); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ex-intro { padding: 0.35rem 0.7rem 0.2rem; }
.ex-crumbs ol { list-style: none; margin: 0 0 0.35rem; padding: 0; display: flex; flex-wrap: wrap; gap: 0.15rem 0.35rem; font-size: 0.72rem; color: var(--muted-foreground); }
.ex-crumbs li + li::before { content: '›'; margin-right: 0.35rem; opacity: 0.6; }
.ex-crumbs a { color: inherit; text-decoration: none; } .ex-crumbs a:hover { color: var(--foreground); text-decoration: underline; }
.ex-h1 { margin: 0 0 0.3rem; font: 800 1.3rem/1.2 var(--font-display); letter-spacing: -0.02em; text-wrap: balance; }
.ex-h2 { margin: 0.7rem 0.7rem 0.15rem; font: 700 0.72rem/1.3 var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-foreground); }
.ex-seo { margin: 1.4rem 0.7rem 1rem; padding-top: 1rem; border-top: 1px solid var(--border); font-size: 0.88rem; line-height: 1.55; color: var(--muted-foreground); }
.ex-seo h2 { margin: 1.2rem 0 0.5rem; font: 800 1.05rem/1.25 var(--font-display); color: var(--foreground); } .ex-seo h2:first-child { margin-top: 0; }
.ex-seo p { margin: 0.4rem 0; text-wrap: pretty; } .ex-seo a { color: rgb(var(--a-500)); }
.ex-stats { width: 100%; margin: 0.7rem 0; border-collapse: collapse; font-size: 0.8rem; font-variant-numeric: tabular-nums; }
.ex-stats caption { padding-bottom: 0.35rem; text-align: left; font-weight: 700; color: var(--foreground); }
.ex-stats th, .ex-stats td { padding: 0.4rem 0.3rem; text-align: right; border-bottom: 1px solid var(--border); font-weight: 500; }
.ex-stats th:first-child, .ex-stats td:first-child { text-align: left; font-weight: 700; color: var(--foreground); }
.ex-stats thead th { font-size: 0.7rem; color: var(--muted-foreground); font-weight: 600; }
.ex-links { list-style: none; margin: 0.3rem 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.35rem; }
.ex-links a { display: inline-block; padding: 0.35rem 0.7rem; border-radius: 999px; background: var(--muted); color: var(--foreground); text-decoration: none; font-size: 0.8rem; transition: background-color 0.15s; }
@media (hover: hover) { .ex-links a:hover { background: var(--card); box-shadow: 0 0 0 1px var(--border-strong); } }
.ex-updated { font-size: 0.74rem; }
.ex-list-static { display: grid; margin: 0.4rem -0.5rem; }

.ex-body { overflow-x: hidden; }

/* Filas añadidas con "Ver más": solo aparecen (opacidad), sin mover nada */
.ex-row.is-new { animation: ex-appear 0.28s ease-out both; }
@keyframes ex-appear { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .ex-row.is-new { animation: none; } }

/* ---------- Parkings: interruptor del mapa, pines, tarjeta y avisos (assets/js/fuel/parking.js) ---------- */
.pk-toast[hidden], .pk-here[hidden], .pk-bar[hidden], .ex-fuelbar[hidden] { display: none; }

/* Los pines se animan con --s / --o (GSAP) para no pisar el transform con el que se colocan */
.is-explore .fuel-marker { scale: var(--s, 1); opacity: var(--o, 1); transform-origin: 50% 100%; }

.ex-mode { position: relative; display: grid; grid-template-columns: 1fr 1fr; height: 2.6rem; margin-bottom: 0.55rem; padding: 3px; border-radius: 999px; background: color-mix(in srgb, var(--card) 94%, transparent); -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4); box-shadow: 0 0 0 1px var(--border-strong), 0 10px 26px -14px rgb(0 0 0 / 0.5); }
.ex-mode-thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 999px; background: linear-gradient(135deg, rgb(var(--a-500)), rgb(var(--a-600, var(--a-500)))); box-shadow: 0 6px 16px -6px rgb(var(--a-500) / 0.8), inset 0 1px 0 rgb(255 255 255 / 0.25); transition: transform 0.38s cubic-bezier(0.32, 0.72, 0, 1); }
.ex-mode[data-mode='parking'] .ex-mode-thumb { transform: translateX(100%); }
.ex-mode button { position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem; border: 0; border-radius: 999px; background: none; cursor: pointer; font: 650 0.86rem/1 var(--font-body); color: var(--muted-foreground); transition: color 0.2s ease, scale 0.16s var(--ease-out); }
.ex-mode button:active { scale: 0.96; }
.ex-mode button[aria-checked='true'] { color: #fff; }
.ex-mode button:focus-visible { outline: 2px solid rgb(var(--a-500)); outline-offset: 2px; }
@media (min-width: 64rem) { .ex-mode { background: var(--card); -webkit-backdrop-filter: none; backdrop-filter: none; } }

.pk-marker-wrap { background: none; border: 0; }
.pk-marker { white-space: nowrap; display: inline-flex; align-items: center; gap: 0.36rem; padding: 0.26rem 0.6rem 0.26rem 0.3rem; border-radius: 999px; font: 800 0.76rem/1 var(--font-body); letter-spacing: -0.01em; font-variant-numeric: tabular-nums; color: #11151a; background: rgb(255 255 255 / 0.95); border: 1px solid rgb(0 0 0 / 0.08); box-shadow: 0 1px 2px rgb(0 0 0 / 0.18), 0 6px 14px -4px rgb(0 0 0 / 0.4); transform: translate(-50%, -50%); scale: var(--s, 1); opacity: var(--o, 1); cursor: pointer; transition: transform 0.22s var(--ease-out), background-color 0.2s, color 0.2s, box-shadow 0.2s; }
.pk-marker .pk-p { display: grid; place-items: center; width: 1.25rem; height: 1.25rem; border-radius: 50%; font: 800 0.72rem/1 var(--font-body); font-style: normal; color: #fff; background: linear-gradient(145deg, #3b82f6, #1d4ed8); }
.pk-marker.is-free { color: #15803d; box-shadow: 0 0 0 2px #22c55e, 0 6px 14px -4px rgb(0 0 0 / 0.4); }
.pk-marker.is-free .pk-p { background: linear-gradient(145deg, #34d399, #15803d); }
.pk-marker.is-active { transform: translate(-50%, -50%) scale(1.1); color: #fff; background: rgb(var(--a-500)); border-color: transparent; box-shadow: 0 0 0 2px #fff, 0 12px 26px -6px rgb(var(--a-500) / 0.75); z-index: 2; }
.pk-marker.is-active .pk-p { background: #fff; color: rgb(var(--a-500)); }
.fuel-cluster.is-park { background: #2563eb; box-shadow: 0 0 0 5px rgb(37 99 235 / 0.25), 0 8px 18px -6px rgb(0 0 0 / 0.55); }
.pk-ico.is-sm { width: 2.2rem; height: 2.2rem; border-radius: 0.7rem; font-size: 1.05rem; box-shadow: none; }
.pk-row { font-family: inherit; color: inherit; }

/* Modo parkings: el cajón (o panel lateral) cambia de contenido; el resumen y la lista de gasolineras se sustituyen por los de parkings */
.ex.is-parking #exSum, .ex.is-parking .ex-body:not(.pk-body) { display: none; }
.pk-sum[hidden], .pk-body[hidden] { display: none; }

.pk-ico { flex: none; display: grid; place-items: center; width: 2.8rem; height: 2.8rem; border-radius: 0.9rem; font: 800 1.4rem/1 var(--font-body); color: #fff; background: linear-gradient(145deg, #3b82f6, #1d4ed8); box-shadow: 0 8px 18px -8px rgb(29 78 216 / 0.8); }
.pk-tag { padding: 0.18rem 0.55rem; border-radius: 999px; font-size: 0.72rem; font-weight: 650; color: var(--muted-foreground); background: var(--muted); }
.pk-tag.is-free { color: #15803d; background: rgb(34 197 94 / 0.14); }
.pk-muted { color: var(--muted-foreground); font-size: 0.82rem; }

.pk-here { position: absolute; z-index: 8; top: 7.4rem; left: 50%; translate: -50% 0; display: inline-flex; align-items: center; gap: 0.45rem; height: 2.4rem; padding: 0 1rem; border: 0; border-radius: 999px; cursor: pointer; font: 650 0.84rem/1 var(--font-body); color: var(--foreground); background: var(--card); box-shadow: 0 0 0 1px var(--border-strong), 0 12px 28px -12px rgb(0 0 0 / 0.6); animation: pkIn 0.3s var(--ease-out); }
@media (min-width: 64rem) { .pk-here { top: 1rem; left: calc(50% + 6.5rem); } }
.pk-here:active { scale: 0.96; }
@keyframes pkIn { from { opacity: 0; translate: -50% -6px; } }

.pk-toast { position: absolute; z-index: 9; left: 50%; bottom: 1rem; translate: -50% 0; max-width: calc(100% - 1.4rem); display: flex; align-items: center; gap: 0.9rem; padding: 0.7rem 0.8rem 0.7rem 1.1rem; border-radius: 999px; font-size: 0.86rem; color: #f4f5f7; background: rgb(18 22 27 / 0.96); box-shadow: 0 0 0 1px rgb(255 255 255 / 0.1), 0 18px 40px -14px rgb(0 0 0 / 0.7); }
@media (min-width: 64rem) { .pk-toast { left: calc(50% + 6.5rem); } }
.pk-toast button { flex: none; height: 2rem; padding: 0 0.85rem; border: 0; border-radius: 999px; cursor: pointer; font: 700 0.8rem/1 var(--font-body); color: #fff; background: rgb(var(--a-500)); }
.pk-toast button:active { scale: 0.96; }

@media (prefers-reduced-motion: reduce) { .ex-mode-thumb, .pk-marker, .pk-primary, .pk-secondary { transition: none; } .pk-here { animation: none; } }

/* Móvil: controles flotantes compactos (menos alto robado al mapa) y tabla de precios con scroll propio */
.ex-stats-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0.7rem 0; }
.ex-stats-wrap .ex-stats { margin: 0; min-width: 21rem; }
.ex-stats th { text-transform: none; letter-spacing: 0; }
@media (max-width: 63.99rem) {
  .ex-mode { height: 2.25rem; margin-bottom: 0.4rem; }
  .ex-mode button { font-size: 0.8rem; }
  .ex-search { height: 2.65rem; }
  .ex-chips { margin-top: 0.4rem; padding-bottom: 4px; }
  .ex-chip { height: 2rem; padding: 0 0.8rem; }
  .pk-here { top: 6.2rem; }
}

/* Punto azul de "tu ubicación": marcador HTML de tamaño fijo (con SVG vectorial se agrandaba durante el zoom inicial) */
.ex-here-wrap { background: none; border: 0; }
.ex-here-dot { display: block; width: 16px; height: 16px; border-radius: 50%; background: #2e90fa; border: 3px solid #fff; box-shadow: 0 0 0 6px rgb(46 144 250 / 0.22), 0 2px 8px rgb(0 0 0 / 0.45); transform: translate(-50%, -50%); box-sizing: border-box; }


.ex-home[aria-pressed='true'] { color: #fff; background: rgb(var(--a-500)); }
.ex-home[aria-pressed='true']:hover { background: rgb(var(--a-500)); }

/* Móvil (< md): el mapa es el protagonista. Sin títulos largos (siguen para lectores de pantalla y buscadores), tarjetas ultra compactas y cajón con sombra hacia arriba */
@media (max-width: 47.99rem) {
  .ex-intro, .ex-h2 { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .ex-sheet { box-shadow: 0 -1px 0 var(--border-strong), 0 -18px 44px -18px rgb(0 0 0 / 0.55); }
  .ex-row { gap: 0.6rem; padding: 0.42rem 0.5rem; border-radius: 0.8rem; }
  .ex-row .fuel-logo.is-md { --s: 2.2rem; }
  .ex-row-main { gap: 0; }
  .ex-row-main h3 { font-size: 0.9rem; line-height: 1.2; }
  .ex-row-main small { font-size: 0.72rem; line-height: 1.25; }
  .ex-best { display: inline-block; margin: 0.12rem 0 0; padding: 0.05rem 0.42rem; font-size: 0.62rem; }
  .ex-row-price b { font-size: 1.45rem; }
  .ex-row-price small { font-size: 0.64rem; }
}
.ex-row.is-picked { background: rgb(var(--a-500) / 0.12); box-shadow: inset 0 0 0 1.5px rgb(var(--a-500) / 0.55); }
@media (max-width: 47.99rem) {
  .ex-row-price { grid-template-columns: auto auto auto; }
  .ex-row-price .ex-dot { grid-column: auto; margin: 0 0 0 0.2rem; align-self: center; }
}

/* Resumen y botón de actualizar siempre en una línea; la insignia "Más barata" junto al nombre; direcciones en una sola línea */
.ex-sum { flex-wrap: nowrap; }
.ex-sum-main { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 47.99rem) {
  .ex-live { padding: 0.2rem 0.55rem; font-size: 0.7rem; }
  .ex-row-main { grid-template-columns: minmax(0, 1fr) auto; column-gap: 0.4rem; }
  .ex-row-main h3, .ex-row-main small { grid-column: 1 / -1; }
  .ex-row-main h3 { grid-column: 1; }
  .ex-best { grid-column: 2; grid-row: 1; margin: 0; align-self: center; }
}

/* Grupos de gasolineras (Leaflet.markercluster): círculo con el número */
.fuel-cluster-wrap { background: none; border: 0; }
.fuel-cluster { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; font: 800 0.9rem/1 var(--font-body); font-variant-numeric: tabular-nums; color: #fff; background: rgb(var(--a-500)); border: 3px solid #fff; box-shadow: 0 0 0 5px rgb(var(--a-500) / 0.25), 0 8px 18px -6px rgb(0 0 0 / 0.55); scale: var(--s, 1); opacity: var(--o, 1); cursor: pointer; transition: transform 0.2s var(--ease-out); }
.fuel-cluster:active { transform: scale(0.94); }
.leaflet-cluster-anim .leaflet-marker-icon, .leaflet-cluster-anim .leaflet-marker-shadow { transition: transform 0.3s ease-out, opacity 0.3s ease-in; }
.leaflet-cluster-spider-leg { transition: stroke-dashoffset 0.3s ease-out, stroke-opacity 0.3s ease-in; }

/* Ficha de la gasolinera en móvil: cabecera compacta (volver + logo + nombre), precio, acciones a la vista y datos secundarios debajo */
@media (max-width: 47.99rem) {
  .ex-sheet.is-detail .ex-sum { display: none; }
  .ex-sheet.is-detail .ex-sheet-head { padding-bottom: 0.25rem; }
  .ex-detail { grid-template-columns: auto minmax(0, 1fr); gap: 0.65rem 0.4rem; padding: 0 0.6rem 0.6rem; }
  .ex-detail > .ex-back { grid-area: 1 / 1; justify-self: start; width: 2.4rem; min-height: 2.4rem; padding: 0; justify-content: center; font-size: 0; gap: 0; background: var(--muted); }
  .ex-detail > .ex-d-head { grid-area: 1 / 2; gap: 0.65rem; min-width: 0; }
  .ex-detail > .ex-d-head > div { min-width: 0; }
  .ex-d-head .fuel-logo.is-lg { --s: 2.6rem; }
  .ex-d-head h2 { font-size: 1.02rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ex-d-head p { margin-top: 0.1rem; font-size: 0.76rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ex-detail > .ex-d-price { grid-area: 2 / 1 / 3 / -1; align-items: center; padding: 0.15rem 0.2rem 0; }
  .ex-d-price b { font-size: 2.35rem; }
  .ex-d-price small { margin-top: 0.15rem; }
  .ex-detail > .ex-d-delta { grid-area: 3 / 1 / 4 / -1; margin: -0.25rem 0.2rem 0; font-size: 0.78rem; }
  .ex-detail > .ex-d-actions { grid-area: 4 / 1 / 5 / -1; gap: 0.5rem; }
  .ex-detail .ex-btn { min-height: 2.65rem; font-size: 0.84rem; }
  .ex-detail > .ex-d-meta { grid-area: 5 / 1 / 6 / -1; gap: 0.4rem; }
  .ex-d-meta span { padding: 0.22rem 0.6rem; font-size: 0.72rem; }
  .ex-detail > .ex-d-title { grid-area: 6 / 1 / 7 / -1; margin: 0.2rem 0.2rem -0.2rem; }
  .ex-detail > .ex-d-prices { grid-area: 7 / 1 / 8 / -1; }
  .ex-d-prices li { padding: 0.5rem 0.8rem; font-size: 0.82rem; }
}

@media (max-width: 47.99rem) { .pk-toast { bottom: auto; top: 7rem; } }
