/* Tipografías autoalojadas (SIL Open Font License) — sin llamadas a Google */
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/archivo-latin-ext-500.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/archivo-latin-500.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/archivo-latin-ext-600.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/archivo-latin-600.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/archivo-latin-ext-700.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/archivo-latin-700.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 800; font-display: swap; src: url('/fonts/archivo-latin-ext-800.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 800; font-display: swap; src: url('/fonts/archivo-latin-800.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/inter-latin-ext-400.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/inter-latin-400.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/inter-latin-ext-500.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/inter-latin-500.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/inter-latin-ext-600.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/inter-latin-600.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/inter-latin-ext-700.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/inter-latin-700.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-ext-500.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-500.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-ext-600.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/ibm-plex-mono-latin-600.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
/* Barrio Ideal · Mapa (Agencia Melón) */
:root {
  --ink: #151E1A; --ink-2: #2A3530; --muted: #5B655F; --faint: #8A928C;
  --cream: #FAF7F0; --sand: #F2EDE2; --sand-2: #E8E1D2; --yellow: #F7CF47; --yellow-2: #F3C22B;
  --line: rgba(21, 30, 26, .12); --line-2: rgba(21, 30, 26, .2);
  --k0: #C8553D; --k1: #E89B4C; --k2: #F7CF47; --k3: #8DB360; --k4: #2E7D4F;
  --r: 18px; --r-sm: 12px;
  --shadow: 0 1px 2px rgba(21, 30, 26, .06), 0 10px 30px rgba(21, 30, 26, .12);
  --shadow-sm: 0 1px 2px rgba(21, 30, 26, .08), 0 4px 14px rgba(21, 30, 26, .10);
  --f-display: 'Archivo', system-ui, sans-serif; --f-text: 'Inter', system-ui, sans-serif; --f-mono: 'IBM Plex Mono', ui-monospace, monospace;
  --gap: 16px; --panel-w: 404px; --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--sand); color: var(--ink); font: 15px/1.45 var(--f-text); -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--yellow-2); outline-offset: 2px; }
svg.i { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
#map { position: absolute; inset: 0; }
.noscript { position: absolute; inset: 40% 20px auto; text-align: center; }

/* ---------- Buscador ---------- */
.top { position: absolute; z-index: 5; top: var(--gap); left: var(--gap); width: var(--panel-w); display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.top > * { pointer-events: auto; }
.search { z-index: 2; position: relative; display: flex; align-items: center; gap: 4px; height: 54px; padding: 0 6px 0 7px; background: #fff; border-radius: 999px; box-shadow: var(--shadow); }
.brand { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--yellow); }
.brand svg { width: 27px; height: 27px; }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; padding: 0 8px; font-size: 15.5px; outline: none; }
.search input::-webkit-search-cancel-button { display: none; }
.search input::placeholder { color: var(--faint); }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent; color: var(--muted); }
.icon-btn:hover { background: var(--sand); color: var(--ink); }
.icon-btn--go { background: var(--ink); color: var(--yellow); }
.icon-btn--go:hover { background: var(--ink-2); color: var(--yellow); }
.suggest { position: absolute; top: calc(100% + 8px); left: 0; right: 0; margin: 0; padding: 6px; list-style: none; background: #fff; border-radius: var(--r); box-shadow: var(--shadow); max-height: min(60vh, 420px); overflow: auto; }
.suggest li { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; cursor: pointer; }
.suggest li[aria-selected="true"], .suggest li:hover { background: var(--sand); }
.suggest .s-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--sand); flex: none; }
.suggest li[aria-selected="true"] .s-ico, .suggest li:hover .s-ico { background: #fff; }
.suggest .s-t { font-weight: 600; line-height: 1.25; }
.suggest .s-d { font-size: 13px; color: var(--muted); }
.suggest .s-k { margin-left: auto; font: 500 11px var(--f-mono); color: var(--faint); text-transform: uppercase; letter-spacing: .04em; }
.suggest .s-empty { color: var(--muted); cursor: default; }

/* ---------- Perfiles ---------- */
.chips { -webkit-mask-image: linear-gradient(90deg,#000 88%,transparent); mask-image: linear-gradient(90deg,#000 88%,transparent); display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 6px; margin: -2px -2px -6px; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 15px 0 12px; border: 1px solid var(--line); border-radius: 999px; background: #fff; box-shadow: var(--shadow-sm); font-weight: 600; font-size: 14px; white-space: nowrap; }
.chip svg.i { width: 18px; height: 18px; }
.chip:hover { border-color: var(--line-2); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--cream); }
.chip[aria-pressed="true"] svg.i { color: var(--yellow); }

/* ---------- Panel ---------- */
.sheet { position: absolute; z-index: 4; left: var(--gap); top: calc(var(--gap) + 54px + 10px + 38px + 12px); width: var(--panel-w); max-height: calc(100% - (var(--gap) * 2 + 114px)); display: flex; flex-direction: column; background: var(--cream); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.sheet-grip { display: none; }
.sheet-body { overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.sec { padding: 18px 20px; border-top: 1px solid var(--line); }
.sec:first-child { border-top: 0; }
.eyebrow { margin: 0 0 6px; font: 600 11.5px var(--f-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.h { margin: 0 0 4px; font: 800 22px/1.15 var(--f-display); letter-spacing: -.02em; }
.h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font: 700 16px/1.25 var(--f-display); letter-spacing: -.01em; }
.h2 svg.i { width: 18px; height: 18px; color: var(--muted); }
.p { margin: 0; color: var(--muted); }
.small { font-size: 13px; color: var(--muted); }
.mono { font-family: var(--f-mono); }
.row-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 16px; border: 1px solid var(--ink); border-radius: 999px; background: transparent; font-weight: 600; font-size: 14px; text-decoration: none; }
.btn svg.i { width: 18px; height: 18px; }
.btn:hover { background: var(--sand); }
.btn--y { background: var(--yellow); }
.btn--y:hover { background: var(--yellow-2); }
.btn--ink { background: var(--ink); color: var(--cream); }
.btn--ink:hover { background: var(--ink-2); }
.btn--ghost { border-color: transparent; padding: 0 10px; }
.close { position: absolute; top: 12px; right: 12px; z-index: 2; background: var(--cream); box-shadow: var(--shadow-sm); color: var(--ink); }
.field { display: grid; gap: 6px; margin-top: 12px; }
.field label { font-size: 13px; font-weight: 600; }
.select { appearance: none; height: 44px; padding: 0 38px 0 14px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23151E1A' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 14px center; }
.select { width: 100%; min-width: 0; }
.select:disabled { opacity: .5; }

/* Explorar */
.hello { display: flex; gap: 14px; align-items: flex-start; }
.hello-pin { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: var(--yellow); }
.weights { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.weights li { display: grid; grid-template-columns: 22px 1fr 44px; align-items: center; gap: 2px 10px; font-size: 14px; }
.weights li svg.i { width: 18px; height: 18px; color: var(--muted); }
.weights .w-bar { grid-column: 2; height: 5px; margin-top: 2px; border-radius: 6px; background: var(--sand-2); overflow: hidden; }
.weights .w-bar span { display: block; height: 100%; background: var(--ink); border-radius: 6px; }
.weights .w-v { font: 600 13px var(--f-mono); text-align: right; }
.weights .is-zero { color: var(--faint); }
.weights input[type=range] { grid-column: 2; width: 100%; margin: 4px 0 0; accent-color: var(--ink); }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stat { padding: 12px 10px; border-radius: var(--r-sm); background: var(--sand); }
.stat b { display: block; font: 700 19px/1.1 var(--f-display); letter-spacing: -.02em; }
.stat span { font-size: 12px; color: var(--muted); }

/* Resultado */
.place { padding: 20px 64px 6px 20px; }
.place .h { font-size: 20px; }
.score { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; align-items: end; padding: 14px 20px 20px; }
.score-n { font: 800 64px/0.9 var(--f-display); letter-spacing: -.045em; }
.score-n small { font: 600 18px var(--f-mono); letter-spacing: 0; color: var(--muted); margin-left: 2px; }
.score-c { display: inline-flex; align-self: center; justify-self: start; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px; font-weight: 700; font-size: 14px; }
.score-meta { grid-column: 1 / -1; font-size: 13px; color: var(--muted); }
.meter { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(10, 1fr); gap: 3px; margin-top: 4px; }
.meter span { height: 8px; border-radius: 3px; background: var(--sand-2); }
.k0 { --k: var(--k0); } .k1 { --k: var(--k1); } .k2 { --k: var(--k2); } .k3 { --k: var(--k3); } .k4 { --k: var(--k4); }
.score-c { background: var(--k); color: #fff; } .k2 .score-c, .score-c.k2 { color: var(--ink); }
.meter span.on { background: var(--k); }
.nodata { padding: 14px 20px 20px; }
.crits { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.crit { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 8px 0; }
.crit-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--sand); }
.crit-ico svg.i { width: 19px; height: 19px; }
.crit-t { font-weight: 600; font-size: 14.5px; line-height: 1.2; }
.crit-d { font-size: 12.5px; color: var(--muted); }
.crit-bar { height: 5px; margin-top: 6px; border-radius: 5px; background: var(--sand-2); overflow: hidden; }
.crit-bar span { display: block; height: 100%; border-radius: 5px; background: var(--ink); }
.crit-v { text-align: right; font: 600 13px var(--f-mono); white-space: nowrap; }
.crit-v em { display: block; font: 500 11px var(--f-text); font-style: normal; color: var(--faint); }
.crit.is-off { opacity: .45; }
.st-excelente .crit-ico { background: #DCEBDD; } .st-buena .crit-ico { background: #E8F0D9; } .st-regular .crit-ico { background: #FBEFC4; } .st-mala .crit-ico, .st-no-hay .crit-ico { background: #F5DCD5; }
.st-excelente .crit-bar span { background: var(--k4); } .st-buena .crit-bar span { background: var(--k3); } .st-regular .crit-bar span { background: var(--k1); } .st-mala .crit-bar span { background: var(--k0); }
.near { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.near button { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; width: 100%; padding: 8px; margin: 0 -8px; width: calc(100% + 16px); border: 0; border-radius: 12px; background: transparent; text-align: left; }
.near button:hover { background: var(--sand); }
.near .crit-ico { background: #fff; border: 1px solid var(--line); }
.near .n-t { font-weight: 600; font-size: 14px; line-height: 1.25; }
.near .n-d { font-size: 12.5px; color: var(--muted); }
.near .n-v { font: 600 13px var(--f-mono); text-align: right; }
.near .n-v em { display: block; font: 500 11px var(--f-text); font-style: normal; color: var(--faint); }
.trips { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.trip { padding: 12px; border-radius: var(--r-sm); background: #fff; border: 1px solid var(--line); }
.trip-h { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.trip-h svg.i { width: 17px; height: 17px; color: var(--muted); }
.trip b { display: block; margin-top: 6px; font: 700 17px/1.1 var(--f-display); letter-spacing: -.01em; }
.trip span { font: 500 12.5px var(--f-mono); color: var(--muted); }
.trip.is-best { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.km { display: flex; align-items: baseline; gap: 8px; margin: -4px 0 12px; }
.km b { font: 800 28px/1 var(--f-display); letter-spacing: -.03em; white-space: nowrap; }
details.more { margin-top: 12px; border-top: 1px dashed var(--line-2); padding-top: 10px; }
details.more summary { cursor: pointer; font-weight: 600; font-size: 13.5px; list-style: none; display: flex; align-items: center; gap: 6px; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary::before { content: ''; width: 7px; height: 7px; border-right: 1.8px solid; border-bottom: 1.8px solid; transform: rotate(-45deg); transition: transform .2s; margin-right: 4px; }
details.more[open] summary::before { transform: rotate(45deg); }
details.more p, details.more table { font-size: 12.5px; color: var(--muted); }
.tbl { width: 100%; border-collapse: collapse; margin-top: 8px; }
.tbl th, .tbl td { padding: 6px 4px; border-bottom: 1px solid var(--line); text-align: left; font-weight: 500; }
.tbl th { font: 600 11px var(--f-mono); text-transform: uppercase; letter-spacing: .04em; color: var(--faint); }
.tbl td.r, .tbl th.r { text-align: right; font-family: var(--f-mono); }
.walk { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.walk-n { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: conic-gradient(var(--ink) calc(var(--v) * 1%), var(--sand-2) 0); position: relative; flex: none; }
.walk-n::before { content: ''; position: absolute; inset: 7px; border-radius: 50%; background: var(--cream); }
.walk-n b { position: relative; font: 800 22px var(--f-display); letter-spacing: -.03em; }
.walk-t b { display: block; font: 700 16px var(--f-display); }
.walk-rows { display: grid; gap: 8px; }
.walk-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; font-size: 13.5px; }
.walk-row .crit-bar { grid-column: 1 / -1; margin-top: 2px; }
.walk-row span:last-child { font: 500 12.5px var(--f-mono); color: var(--muted); }
.note { margin-top: 10px; font-size: 12px; color: var(--faint); }
.sources { padding: 14px 20px 22px; font-size: 12px; color: var(--faint); }
.sources a { color: var(--muted); }
.loading { padding: 26px 20px; display: flex; align-items: center; gap: 12px; color: var(--muted); }
.spin { width: 22px; height: 22px; border: 2.5px solid var(--sand-2); border-top-color: var(--ink); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Controles ---------- */
.ctrls { position: absolute; z-index: 5; top: var(--gap); right: var(--gap); display: flex; gap: 8px; }
.ctrl { display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 14px; background: #fff; box-shadow: var(--shadow-sm); color: var(--ink); text-decoration: none; }
.ctrl:hover { background: var(--sand); }
.ctrl--pill { display: inline-flex; gap: 8px; width: auto; padding: 0 16px 0 13px; border-radius: 999px; font-size: 14px; }
.ctrl--pill b { font-weight: 600; }
.ctrl[aria-expanded="true"] { background: var(--ink); color: var(--cream); }
.ctrl--full { display: none; }
.zoom { position: absolute; z-index: 3; right: var(--gap); bottom: calc(var(--gap) + 26px); display: flex; flex-direction: column; gap: 10px; }
.ctrl-group { display: flex; flex-direction: column; border-radius: 14px; box-shadow: var(--shadow-sm); overflow: hidden; }
.ctrl-group .ctrl { border-radius: 0; box-shadow: none; }
.ctrl-group .ctrl + .ctrl { border-top: 1px solid var(--line); }
#btnLocate.is-busy svg { animation: spin 1s linear infinite; }

/* ---------- Capas ---------- */
.layers { position: absolute; z-index: 6; top: calc(var(--gap) + 54px); right: var(--gap); width: 320px; max-height: calc(100% - 100px); overflow: auto; padding: 8px 0; background: var(--cream); border-radius: var(--r); box-shadow: var(--shadow); }
.layers h3 { margin: 10px 18px 6px; font: 600 11.5px var(--f-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.tg { display: flex; align-items: center; gap: 12px; padding: 9px 18px; cursor: pointer; font-size: 14.5px; }
.tg:hover { background: var(--sand); }
.tg .dot { width: 12px; height: 12px; border-radius: 50%; flex: none; box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--line-2); }
.tg span { flex: 1; }
.tg input { appearance: none; width: 40px; height: 24px; border-radius: 24px; background: var(--sand-2); position: relative; transition: background .2s; flex: none; margin: 0; cursor: pointer; }
.tg input::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.tg input:checked { background: var(--ink); }
.tg input:checked::after { transform: translateX(16px); background: var(--yellow); }
.layers .small { padding: 4px 18px 10px; }

/* ---------- Leyenda y aviso ---------- */
.legend { position: absolute; z-index: 3; left: 50%; bottom: calc(var(--gap) + 18px); transform: translateX(-50%); display: flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 999px; background: rgba(250, 247, 240, .94); box-shadow: var(--shadow-sm); font-size: 12.5px; white-space: nowrap; backdrop-filter: blur(6px); }
.legend .sw { display: flex; gap: 2px; }
.legend .sw i { width: 22px; height: 9px; border-radius: 2px; }
.legend b { font-weight: 600; }
.legend[hidden] { display: none; }
.toast { position: absolute; z-index: 8; left: 50%; top: calc(var(--gap) + 120px); transform: translateX(-50%); max-width: min(92vw, 420px); padding: 11px 18px; border-radius: 999px; background: var(--ink); color: var(--cream); font-size: 14px; box-shadow: var(--shadow); text-align: center; }

/* ---------- Marcadores ---------- */
.mk-pin { width: 38px; height: 48px; filter: drop-shadow(0 4px 6px rgba(21,30,26,.3)); }
.mk-svc { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #fff; border: 2px solid var(--c, var(--ink)); color: var(--c, var(--ink)); box-shadow: var(--shadow-sm); cursor: pointer; }
.mk-svc svg.i { width: 16px; height: 16px; stroke-width: 2; }
.mk-prop { display: grid; place-items: center; min-width: 46px; height: 32px; padding: 0 8px; border-radius: 999px; background: var(--ink); color: #fff; font: 700 14px var(--f-display); border: 2px solid #fff; box-shadow: var(--shadow-sm); cursor: pointer; position: relative; }
.mk-prop i { position: absolute; left: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--k); }
.mk-prop { padding-left: 18px; }
.mk-work { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--ink); color: var(--yellow); border: 2px solid #fff; box-shadow: var(--shadow-sm); }
.maplibregl-popup-content { padding: 0; border-radius: 14px; box-shadow: var(--shadow); overflow: hidden; font: 14px var(--f-text); }
.maplibregl-popup-close-button { width: 30px; height: 30px; font-size: 20px; top: 4px; right: 4px; border-radius: 50%; background: rgba(250,247,240,.9); }
.pp { width: 250px; }
.pp img { display: block; width: 100%; height: 140px; object-fit: cover; background: var(--sand); }
.pp-b { padding: 12px 14px 14px; }
.pp-p { font: 800 19px var(--f-display); letter-spacing: -.02em; }
.pp-t { font-weight: 600; }
.pp-d { font-size: 12.5px; color: var(--muted); }
.pp .btn { width: 100%; margin-top: 10px; height: 38px; }
.pp-s { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12.5px; font-weight: 600; }
.pp-s b { display: inline-grid; place-items: center; min-width: 30px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--k); color: #fff; font: 700 12.5px var(--f-mono); }
.tip { padding: 8px 12px; font-size: 13px; }
.tip b { display: block; }
.maplibregl-ctrl-attrib { font-size: 11px; background: rgba(250,247,240,.8) !important; }
.maplibregl-ctrl-bottom-right { right: calc(var(--gap) + 52px); }

/* ---------- Embebido en el sitio ---------- */
.is-embed .ctrl--full { display: inline-flex; }

/* ---------- Tablet / celular ---------- */
@media (max-width: 899px) {
  :root { --gap: 12px; --panel-w: auto; }
  .top { right: var(--gap); width: auto; top: calc(var(--gap) + env(safe-area-inset-top, 0px)); }
  .search { height: 52px; }
  .ctrls { top: auto; bottom: auto; right: var(--gap); top: calc(var(--gap) + 52px + 10px + 38px + 12px + env(safe-area-inset-top, 0px)); flex-direction: column; align-items: flex-end; }
  .ctrl--pill b { display: none; }
  .ctrl--pill { width: 44px; padding: 0; justify-content: center; border-radius: 14px; }
  .sheet { left: 0; right: 0; top: auto; bottom: 0; width: auto; height: calc(100% - 128px); max-height: none; border-radius: 22px 22px 0 0; transform: translateY(calc(100% - var(--peek, 150px) - var(--safe-b))); transition: transform .32s cubic-bezier(.2, .8, .2, 1); will-change: transform; padding-bottom: var(--safe-b); }
  .sheet[data-state="full"] { transform: translateY(0); }
  .sheet.is-drag { transition: none; }
  .sheet-grip { display: block; flex: none; padding: 10px 0 4px; cursor: grab; touch-action: none; }
  .sheet-grip span { display: block; width: 42px; height: 5px; margin: 0 auto; border-radius: 5px; background: var(--line-2); }
  .sheet[data-state="peek"] .sheet-body { overflow: hidden; }
  .place { padding-top: 6px; }
  .close { top: 18px; }
  .zoom { bottom: calc(var(--peek, 150px) + var(--safe-b) + 11px); transition: bottom .32s; }
  .zoom .ctrl-group { display: none; }
  .legend { bottom: calc(var(--peek, 150px) + var(--safe-b) + 14px); left: var(--gap); transform: none; transition: bottom .32s; font-size: 11.5px; padding: 0 12px; height: 34px; gap: 8px; }
  .legend b { display: none; }
  .zoom .ctrl { width: 40px; height: 40px; }
  .maplibregl-ctrl-attrib.maplibregl-compact { min-height: 22px; }
  .legend .sw i { width: 14px; }
  .layers { left: var(--gap); right: var(--gap); width: auto; top: auto; bottom: calc(var(--safe-b) + var(--gap)); max-height: 70%; }
  .toast { top: auto; bottom: calc(var(--peek, 150px) + var(--safe-b) + 66px); }
  .maplibregl-ctrl-bottom-left { bottom: calc(var(--peek, 150px) + var(--safe-b)); }
  .maplibregl-ctrl-bottom-right .maplibregl-ctrl { margin: 0; }
  .maplibregl-ctrl-bottom-right { right: 56px; bottom: calc(var(--peek, 150px) + var(--safe-b) + 14px); }
  .score-n { font-size: 56px; }
}
@media (max-width: 899px) and (min-width: 600px) { .top { width: 420px; right: auto; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation-duration: .01s !important; } }

@media (max-width: 899px) { body:has(.sheet[data-state="full"]) .ctrls, body:has(.sheet[data-state="full"]) .legend, body:has(.sheet[data-state="full"]) .zoom { opacity: 0; pointer-events: none; } .ctrls, .legend, .zoom { transition: opacity .2s, bottom .32s; } }

.mk-best { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: var(--cream); font: 800 15px var(--f-display); border: 3px solid var(--k, var(--yellow)); box-shadow: var(--shadow-sm); cursor: pointer; }
.mk-best-n { font: 800 15px var(--f-display); background: var(--ink) !important; color: var(--cream); border: 3px solid var(--k) !important; border-radius: 50% !important; }
.crit.is-off { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; }

.bestnav { display: flex; align-items: center; gap: 6px; padding: 12px 64px 0 14px; }
.bestnav .icon-btn { width: 40px; height: 40px; border: 1px solid var(--line); background: #fff; color: var(--ink); }
.bestnav .icon-btn:disabled { opacity: .35; cursor: default; }
.bestnav-t { flex: 1; display: grid; justify-items: start; gap: 1px; padding: 6px 12px; border: 0; border-radius: 12px; background: var(--ink); color: var(--cream); text-align: left; }
.bestnav-t b { font: 700 14px var(--f-display); }
.bestnav-t span { font-size: 12px; color: var(--yellow); }
.bestnav-t--solo { display: flex; align-items: center; gap: 8px; padding: 10px 14px; }
.bestnav-t--solo svg.i { width: 18px; height: 18px; color: var(--yellow); }
.place--after { padding-top: 12px; }
.mk-best.is-active { width: 44px; height: 44px; font-size: 18px; background: var(--yellow); color: var(--ink); z-index: 2; }
