/* =========================================================
   Estilos de "Can I Build Here?" — tema oscuro
   Los colores principales están aquí arriba, en :root.
   ========================================================= */
:root {
  --fondo: #0a0b0d;           /* casi negro */
  --superficie: rgba(14, 16, 20, 0.88);
  --superficie-solida: #121418;
  --borde: rgba(255, 255, 255, 0.12);
  --texto: #ffffff;
  --texto-suave: #a1a1aa;
  --acento: #f5b301;          /* ámbar / dorado */
  --radio: 14px;
  --sombra: 0 8px 30px rgba(0, 0, 0, 0.45);
  --fuente: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --fuente-mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  --hueco: 16px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  background: var(--fondo);
  color: var(--texto);
  font-family: var(--fuente);
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

[hidden] { display: none !important; }

.mono { font-family: var(--fuente-mono); }

/* ---------- Mapa a pantalla completa ---------- */
.mapa { position: fixed; inset: 0; }

/* ---------- Barra superior ---------- */
.barra-superior {
  position: fixed;
  top: var(--hueco);
  left: var(--hueco);
  right: var(--hueco);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  pointer-events: none;   /* deja pasar los clics al mapa... */
  z-index: 10;
}
.barra-superior > * { pointer-events: auto; } /* ...salvo en los controles */

.marca {
  background: var(--superficie);
  backdrop-filter: blur(8px);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 10px 16px;
  box-shadow: var(--sombra);
  display: flex;
  flex-direction: column;
  /* Ancho fijo para que nada se mueva al cambiar de idioma (cabe el subtítulo más largo, el español). */
  width: 272px;
  flex-shrink: 0;
}
.marca-nombre { font-weight: 700; font-size: 17px; letter-spacing: -0.01em; }
.marca-nombre::after { content: ''; display: inline-block; width: 7px; height: 7px; margin-left: 6px;
  border-radius: 50%; background: var(--acento); vertical-align: middle; }
.marca-sub { color: var(--texto-suave); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.controles-superiores { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; margin-left: auto; }
/* Anchos fijos: iguales en español y en inglés ("Ver el mundo" / "World view", "España" / "Spain"). */
#boton-mundo { width: 146px; justify-content: center; }

/* ---------- Botones y selector ---------- */
.boton, .selector {
  font: inherit;
  font-weight: 600;
  font-size: 14px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 0 16px;
  cursor: pointer;
  box-shadow: var(--sombra);
  transition: transform 0.12s, background 0.15s;
}
.boton { background: #fff; color: #0a0b0d; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; flex-shrink: 0; }
.boton:hover { background: #f1f1f1; }
.boton:active { transform: scale(0.97); }
.boton-secundario { background: var(--superficie); color: var(--texto); border-color: var(--borde); backdrop-filter: blur(8px); }
.boton-secundario:hover { background: var(--superficie-solida); }

.selector {
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%230a0b0d' stroke-width='2' fill='none'/%3E%3C/svg%3E") no-repeat right 14px center;
  color: #0a0b0d;
  appearance: none;
  padding-right: 38px;
  /* Ancho fijo: si no, el navegador lo hace tan ancho como el país más largo de la lista,
     que cambia con el idioma ("Reino Unido" / "United Kingdom"). */
  width: 200px;
  text-overflow: ellipsis;
}
.selector option { color: #0a0b0d; }

.boton:focus-visible, .selector:focus-visible { outline: 2px solid var(--acento); outline-offset: 2px; }

/* ---------- Botón de idioma "ES | EN" ---------- */
.idiomas {
  display: inline-flex; align-items: center; flex-shrink: 0;
  height: 40px; padding: 0 6px;
  background: var(--superficie); backdrop-filter: blur(8px);
  border: 1px solid var(--borde); border-radius: 999px; box-shadow: var(--sombra);
}
.idiomas button {
  font: inherit; font-family: var(--fuente-mono); font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
  background: none; border: 0; color: var(--texto-suave); cursor: pointer;
  height: 30px; padding: 0 8px; border-radius: 999px; transition: color 0.15s;
}
.idiomas button:hover { color: var(--texto); }
.idiomas button[aria-pressed="true"] { color: var(--texto); }
.idiomas button[aria-pressed="true"]::after { /* rayita ámbar bajo el idioma activo */
  content: ''; display: block; height: 2px; margin-top: 1px; border-radius: 2px; background: var(--acento);
}
.idiomas button:focus-visible { outline: 2px solid var(--acento); outline-offset: 0; }
.idiomas-sep { color: var(--borde); font-size: 14px; user-select: none; }

/* ---------- Buscador ---------- */
.buscador {
  position: relative;
  flex: 0 1 400px;
  min-width: 0;
}
.buscador-lupa {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  width: 17px; height: 17px; fill: none; stroke: #52525b; stroke-width: 2.2; stroke-linecap: round;
  pointer-events: none;
}
.buscador input {
  width: 100%;
  height: 40px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: #fff;
  color: #0a0b0d;
  font: inherit;
  font-size: 14px;
  padding: 0 16px 0 40px;
  box-shadow: var(--sombra);
  outline: none;
}
.buscador input::placeholder { color: #71717a; }
.buscador input:focus { border-color: var(--acento); box-shadow: 0 0 0 3px rgba(245, 179, 1, 0.35), var(--sombra); }
.buscador input::-webkit-search-cancel-button { cursor: pointer; }

.buscador-lista {
  position: absolute;
  top: calc(100% + 6px);
  left: 0; right: 0;
  margin: 0; padding: 6px;
  list-style: none;
  background: var(--superficie-solida);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  box-shadow: var(--sombra);
  max-height: min(60vh, 420px);
  overflow-y: auto;
  z-index: 15;
}
.busca-op {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  cursor: pointer;
}
.busca-op.activo, .busca-op:hover { background: rgba(255, 255, 255, 0.08); }
.busca-icono { color: var(--acento); width: 14px; text-align: center; flex-shrink: 0; }
.busca-textos { display: flex; flex-direction: column; min-width: 0; }
.busca-nombre { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.busca-detalle { font-size: 12.5px; color: var(--texto-suave); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.busca-nota { padding: 8px 10px; color: var(--texto-suave); font-size: 13px; }

/* Marcador del lugar buscado: punto ámbar con un pulso */
.marcador-busqueda {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--acento); border: 3px solid #fff;
  box-shadow: 0 0 0 0 rgba(245, 179, 1, 0.7);
  animation: pulso 1.8s infinite;
}
@keyframes pulso {
  70% { box-shadow: 0 0 0 16px rgba(245, 179, 1, 0); }
  100% { box-shadow: 0 0 0 0 rgba(245, 179, 1, 0); }
}
@media (prefers-reduced-motion: reduce) { .marcador-busqueda { animation: none; } }

/* ---------- Tarjeta de controles (abajo a la izquierda) ---------- */
.tarjeta-controles {
  position: fixed;
  left: var(--hueco);
  bottom: calc(var(--hueco) + env(safe-area-inset-bottom));
  z-index: 10;
  width: 250px;
  background: var(--superficie);
  backdrop-filter: blur(8px);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  box-shadow: var(--sombra);
  padding: 6px 12px 12px;
}
.boton-plegar {
  all: unset;
  display: flex; justify-content: space-between; align-items: center;
  width: 100%;
  padding: 6px 0;
  font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--texto-suave);
  cursor: pointer;
}
.boton-plegar:focus-visible { outline: 2px solid var(--acento); outline-offset: 2px; border-radius: 6px; }
.boton-plegar .flecha { transition: transform 0.2s; }
.tarjeta-controles.plegada { padding-bottom: 6px; }
.tarjeta-controles.plegada .flecha { transform: rotate(-90deg); }
.tarjeta-controles.plegada .controles-cuerpo { display: none; }

.segmentado {
  display: grid; grid-template-columns: 1fr 1fr;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 3px;
  margin: 4px 0 12px;
}
.segmentado button {
  all: unset;
  text-align: center;
  padding: 6px 0;
  border-radius: 999px;
  font-size: 13px; font-weight: 600;
  color: var(--texto-suave);
  cursor: pointer;
}
.segmentado button[aria-pressed="true"] { background: #fff; color: #0a0b0d; }
.segmentado button:focus-visible { outline: 2px solid var(--acento); }

.control-opacidad { display: block; margin-bottom: 12px; }
.control-titulo { display: flex; justify-content: space-between; font-size: 13px; color: var(--texto-suave); margin-bottom: 6px; }
.control-titulo output { color: var(--texto); min-width: 5ch; text-align: right; } /* cabe "100 %" */
input[type="range"] { width: 100%; accent-color: var(--acento); cursor: pointer; }

.leyenda { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.leyenda li { display: flex; align-items: center; gap: 8px; }
.leyenda .muestra { width: 14px; height: 14px; border-radius: 4px; flex-shrink: 0; opacity: 0.9; }
.leyenda-rango { margin-left: auto; color: var(--texto-suave); font-size: 11.5px; }

/* ---------- Panel lateral ---------- */
.panel {
  position: fixed;
  top: calc(var(--hueco) + 56px);
  right: var(--hueco);
  bottom: calc(var(--hueco) + 104px); /* deja libres los botones de zoom */
  width: 360px;
  z-index: 12;
  background: rgba(14, 16, 20, 0.94);
  backdrop-filter: blur(10px);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  box-shadow: var(--sombra);
  overflow-y: auto;
  padding: 20px;
  animation: entrar-derecha 0.2s ease-out;
}
@keyframes entrar-derecha { from { opacity: 0; transform: translateX(20px); } }
@media (prefers-reduced-motion: reduce) { .panel { animation: none; } }

.panel-cerrar {
  position: absolute; top: 12px; right: 12px;
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--borde); background: rgba(255, 255, 255, 0.06); color: var(--texto);
  font-size: 14px; cursor: pointer;
}
.panel-cerrar:hover { background: rgba(255, 255, 255, 0.14); }
.panel-cerrar:focus-visible { outline: 2px solid var(--acento); }

.panel-etiqueta { margin: 0; font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--texto-suave); }
.panel-cabecera h2 { margin: 2px 0 0; font-size: 22px; font-weight: 600; }
.panel-lugar { margin: 4px 0 0; color: var(--texto-suave); font-size: 13.5px; }
.panel-mini { margin: 2px 0 0; font-size: 12px; color: var(--texto-suave); font-weight: 400; }

.panel-nota { display: flex; align-items: center; gap: 16px; margin: 18px 0 14px; }
.nota-circulo {
  width: 92px; height: 92px; border-radius: 50%;
  border: 4px solid var(--color);
  display: flex; align-items: baseline; justify-content: center; padding-top: 22px; box-sizing: border-box;
  background: color-mix(in srgb, var(--color) 14%, transparent);
  flex-shrink: 0;
}
.nota-numero { font-size: 34px; font-weight: 700; line-height: 1; }
.nota-max { font-size: 13px; color: var(--texto-suave); margin-left: 2px; }
.nota-categoria { margin: 0; font-size: 19px; font-weight: 700; }
.descartada .nota-numero { text-decoration: line-through; text-decoration-thickness: 2px; opacity: 0.7; }

.panel-aviso {
  display: flex; gap: 10px; align-items: flex-start;
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.55);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 14px;
}

.panel-subtitulo { margin: 18px 0 10px; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--texto-suave); font-weight: 600; }
/* Motivos ("Por qué se acepta" ✓ / "Por qué se rechaza" ✗) y permisos necesarios */
.motivos ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.motivos li { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; line-height: 1.35; }
.motivos svg { width: 16px; height: 16px; flex: none; margin-top: 1px; fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.motivos-favor svg { stroke: #22c55e; }
.motivos-contra svg { stroke: #ef4444; }
.permisos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.permiso {
  font-size: 12.5px; line-height: 1.3; padding: 4px 10px; border-radius: 999px;
  border: 1px solid rgba(245, 179, 1, 0.5); background: rgba(245, 179, 1, 0.12); color: #fde68a;
}
.permisos-bloque .panel-mini { font-size: 13px; }
.variables { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.variable-cabecera { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.variable-icono { width: 20px; height: 20px; flex: none; display: grid; place-items: center; }
.variable-icono svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.variable-nombre { flex: 1; }
.variable-valor { font-weight: 600; }
.sin-dato .variable-valor { color: var(--texto-suave); font-weight: 400; font-family: var(--fuente); font-size: 13px; }
.barra { height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); margin: 6px 0 3px 28px; overflow: hidden; }
.barra span { display: block; height: 100%; border-radius: 999px; }
.sin-dato .barra { background: repeating-linear-gradient(45deg, rgba(255,255,255,0.08) 0 4px, transparent 4px 8px); }

.panel-datos { margin: 18px 0 0; display: grid; gap: 8px; font-size: 13px; }
.panel-datos div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.panel-datos dd { white-space: nowrap; font-size: 12.5px; }
.panel-datos dt { color: var(--texto-suave); }
.panel-datos dd { margin: 0; text-align: right; }
.panel-nota-area { margin: 14px 0 0; padding-top: 12px; border-top: 1px solid var(--borde); font-size: 12px; color: var(--texto-suave); }

/* ---------- Etiqueta DATOS DE PRUEBA ---------- */
.etiqueta-prueba {
  position: fixed;
  left: var(--hueco);
  top: calc(var(--hueco) + 66px); /* justo debajo del nombre de la web */
  z-index: 10;
  font-family: var(--fuente-mono);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--acento);
  background: rgba(10, 11, 13, 0.85);
  border: 1px dashed var(--acento);
  border-radius: 999px;
  padding: 5px 12px;
  cursor: help;
  /* Ancho del texto más largo ("DATOS DE PRUEBA": 15 letras), igual en los dos idiomas. */
  width: calc(15ch + 15 * 0.12em + 26px);
  text-align: center;
}

/* ---------- Tooltip ---------- */
.tooltip {
  position: fixed;
  z-index: 20;
  pointer-events: none;
  background: var(--superficie-solida);
  border: 1px solid var(--borde);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 13px;
  box-shadow: var(--sombra);
  white-space: nowrap;
  transform: translate(12px, 12px);
}
.tooltip .tooltip-nota { color: var(--acento); font-size: 12px; }

/* ---------- Aviso ---------- */
.aviso {
  position: fixed;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  background: var(--superficie-solida);
  border: 1px solid var(--acento);
  border-radius: var(--radio);
  padding: 10px 16px;
  box-shadow: var(--sombra);
}

/* ---------- Ajustes de MapLibre al tema oscuro ---------- */
.maplibregl-ctrl-group { background: var(--superficie-solida) !important; border-radius: 12px !important; }
.maplibregl-ctrl-group button + button { border-top-color: var(--borde) !important; }
.maplibregl-ctrl-group button .maplibregl-ctrl-icon { filter: invert(1); }
/* ---------- Créditos (nuestro botón ⓘ, abajo a la derecha) ---------- */
/* Mismo relleno y alto abiertos o cerrados: así el botón ⓘ (y los + / − de encima) no se mueven al pulsarlo. */
.creditos { display: flex; align-items: center; justify-content: flex-end; gap: 8px; clear: both;
  padding: 6px; min-height: 44px; border-radius: 12px; }
.creditos.abiertos {
  background: var(--superficie-solida);
  padding-left: 12px;
  /* Pantalla grande: ancho fijo, igual en los dos idiomas, y sin llegar a la tarjeta de leyenda
     (abajo a la izquierda): termina 12 px antes de ella.
     Cuentas: pantalla − hueco izq. − tarjeta (250) − separación (12) − margen dcho. de MapLibre (10).
     Si cambia el ancho de la tarjeta, cambiar aquí el 250. */
  width: min(1240px, calc(100vw - var(--hueco) - 250px - 12px - 10px));
}
.creditos-texto { flex: 1; font-size: 11px; line-height: 1.45; color: #d4d4d8; text-align: right; }
.creditos-texto a { color: #fff; }
.creditos-boton {
  all: unset; flex: none; cursor: pointer;
  width: 28px; height: 28px; border-radius: 999px;
  display: grid; place-items: center;
  box-sizing: border-box; border: 1px solid rgba(255, 255, 255, 0.28);
  background: var(--superficie-solida); color: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}
.creditos.abiertos .creditos-boton { background: rgba(255, 255, 255, 0.1); box-shadow: none; }
.creditos-boton:hover { background: rgba(255, 255, 255, 0.18); }
.creditos-boton:focus-visible { outline: 2px solid var(--acento); outline-offset: 2px; }
.creditos-boton svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.maplibregl-ctrl-bottom-right { bottom: calc(env(safe-area-inset-bottom)); }

/* Buscador centrado en la pantalla cuando hay sitio. Su ancho deja libre, a cada lado, lo que
   ocupan los controles de la derecha en su estado más ancho (país abierto):
   "Ver el mundo" 146 + 8 + selector 200 + 8 + ES|EN 84 = 446, + margen 16 + separación 12 = 474.
   Así no se mueve al cambiar de idioma ni al abrir un país, y nunca toca los botones. */
@media (min-width: 1280px) {
  .buscador { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: min(400px, calc(100vw - 2 * 474px)); }
}

/* ---------- Móvil ---------- */
@media (max-width: 640px) {
  :root { --hueco: 10px; }
  /* Barra en 2 filas finas (antes 3 filas gruesas que tapaban un tercio del mapa):
       [ nombre ............. ES | EN ]
       [ ← ][ buscador                ]   (el "←" solo con un país abierto) */
  .barra-superior { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; }
  .controles-superiores { display: contents; } /* sus botones pasan a colocarse en la cuadrícula de arriba */
  .marca { grid-column: 1 / 3; grid-row: 1; justify-self: start; width: auto; height: 36px; padding: 0 12px; justify-content: center; }
  .marca-nombre { font-size: 15px; }
  .marca-sub { display: none; }
  .idiomas { grid-column: 3; grid-row: 1; height: 36px; }
  /* El país se elige tocándolo en el mapa o buscando un lugar (solo España tiene datos). */
  .selector { display: none; }
  #boton-mundo { grid-column: 1; grid-row: 2; width: 40px; height: 40px; padding: 0; font-size: 18px; } /* = alto del buscador */
  #boton-mundo [data-i18n] { display: none; } /* solo la flecha; el nombre va en aria-label */
  .buscador { grid-column: 2 / 4; grid-row: 2; width: auto; }
  .barra-superior:has(#boton-mundo[hidden]) .buscador { grid-column: 1 / 4; }
  /* Etiqueta de prueba: justo debajo de la barra, a la izquierda (como en escritorio, bajo el nombre).
     36 (fila 1) + 8 + 40 (fila 2) + 8 = 92 px. Mismo ancho en los dos idiomas. */
  .etiqueta-prueba { top: calc(var(--hueco) + 92px); font-size: 10px; padding: 3px 10px; width: calc(15ch + 15 * 0.12em + 22px); }
  /* Botones + / −: en el móvil se hace zoom con dos dedos. */
  .maplibregl-ctrl-bottom-right .maplibregl-ctrl-group { display: none; }
  .tarjeta-controles { width: auto; right: 64px; }
  /* Créditos en móvil: el botón ⓘ se queda SIEMPRE en su sitio (al lado de la tarjeta), y el texto
     sale como una burbuja encima, sin tapar la tarjeta. Antes la caja entera subía y el botón con
     ella: al volver a tocar en el mismo sitio para cerrar, ya no había botón. */
  .creditos { position: relative; }
  .creditos.abiertos { width: auto; background: none; padding-left: 6px; }
  .creditos.abiertos .creditos-boton { background: var(--superficie-solida); }
  .creditos-texto {
    position: absolute; right: 0; bottom: calc(100% + 4px);
    width: calc(100vw - 2 * var(--hueco));
    background: var(--superficie-solida); border: 1px solid var(--borde); border-radius: 12px;
    padding: 8px 12px; box-shadow: var(--sombra); text-align: left;
  }
  /* Panel: hoja que sale desde abajo */
  .panel {
    top: auto; left: 0; right: 0; bottom: 0;
    width: auto; max-height: 46vh; /* antes 62vh: tapaba más de media pantalla */
    border-radius: 20px 20px 0 0;
    padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
    animation: entrar-abajo 0.22s ease-out;
  }
  @keyframes entrar-abajo { from { transform: translateY(40px); opacity: 0; } }
  .panel-cerrar { top: 10px; right: 10px; width: 30px; height: 30px; }

  /* Cabecera compacta: la nota (círculo) a la izquierda y, a su lado, el cuadrado, el lugar y la categoría.
       ( 72 )  ES-00958
               Cerca de Cangas de Onís · Asturias
               Viable                                   */
  #panel-contenido { display: grid; grid-template-columns: 56px 1fr; column-gap: 12px; }
  #panel-contenido > * { grid-column: 1 / -1; }
  .panel-nota { display: contents; }
  .nota-circulo { grid-column: 1; grid-row: 1 / span 2; align-self: center;
    width: 56px; height: 56px; border-width: 3px; padding-top: 0; align-items: center; }
  .nota-numero { font-size: 21px; }
  .nota-max { display: none; } /* "/100" no cabe en el círculo pequeño */
  #panel-contenido > .panel-cabecera { grid-column: 2; grid-row: 1; padding-right: 36px; }
  .panel-etiqueta { display: none; }
  .panel-cabecera h2 { font-size: 17px; margin: 0; }
  .panel-lugar { font-size: 12.5px; margin-top: 1px; }
  .panel-nota > div:not(.nota-circulo) { grid-column: 2; grid-row: 2; }
  .nota-categoria { font-size: 15px; margin-top: 2px; }
  .panel-nota > div > p:nth-child(2) { display: none; } /* "Puntuación total" (se entiende por el círculo) */
  .panel-aviso { margin: 10px 0 0; padding: 8px 10px; font-size: 13px; }
  .panel-subtitulo { margin: 12px 0 6px; font-size: 11px; }

  /* Cada variable en UNA línea: icono · nombre · barra · valor. */
  .variables { gap: 8px; }
  .variable { display: grid; grid-template-columns: 20px 1fr 64px 58px; column-gap: 8px; align-items: center; }
  .variable-cabecera { display: contents; }
  .variable-icono { grid-column: 1; grid-row: 1; }
  .variable-nombre { grid-column: 2; grid-row: 1; line-height: 1.25; }
  .variable-nombre .panel-mini { display: block; font-size: 11px; line-height: 1.2; } /* "(100 = poco riesgo)" en su línea */
  .barra { grid-column: 3; grid-row: 1; margin: 0; }
  .variable-valor { grid-column: 4; grid-row: 1; text-align: right; }
  .sin-dato .variable-valor { font-size: 12px; }
  .panel-datos { margin-top: 12px; }
}
