/* Radio Mundo — estilo true-black-flat (seed 350402591).
   Elevación solo por luminosidad: #000 suelo, #111 tarjeta, #2a2a2a panel anidado.
   El único tono es el ámbar de un dial de radio de válvulas, solo sobre datos (lo que suena, el dial).
   Rejilla escritorio: sidebar 220 + 1px de regla; lienzo con 29px a cada lado.
   Zona principal: dos columnas 5fr / 7fr con 14px de separación, las dos tocan los bordes del lienzo. */
:root {
  --ground: #000000;
  --surface: #111111;
  --raised: #2a2a2a;
  --night: #161616;
  --border: #1a1a1a;
  --rule: #161616;
  --control: #444444;
  --text: #ffffff;
  --muted: #b4b4b4;
  --faint: #949494;
  --nav: #bbbbbb;
  --accent: #f2b33d;
  --positive: #f2b33d;
  --negative: #e5566f;
  --pill-negative-bg: #2c1a20;
  --pill-neutral-bg: #222222;
  /* superficies y líneas secundarias, para que cada tema pueda cambiarlas */
  --chip: #161616;        /* cajas de iconos, filas, opciones */
  --chip-2: #222222;      /* insignias, hover */
  --line: #2e2e2e;        /* separadores, pistas, barras vacías */
  --surface-2: #131313;   /* tarjetas dentro de tarjetas, campos */
  --sunk: #0c0c0c;        /* zonas hundidas (escenario del juego) */
  --on-accent: #000000;   /* texto sobre el color de acento */
  --inverse-hover: #e6e6e6;
  --map-space: #000000;
  --radius-card: 20px;
  --radius-nested: 12px;
  --radius-control: 999px;
  --sidebar-width: 252px;
  --topbar: 64px;
  --player: 76px;
  --gap: 14px;
  --pad: 22px;
  --gutter: 29px;
  --control-height: 36px;
  --font: "Inter", system-ui, sans-serif;
  --fs-title: 20px;
  --fs-section: 16px;
  --fs-kpi: 24px;
  --fs-body: 14px;
  --fs-small: 12px;
  /* Movimiento: curvas fuertes; nada de ease-in en la interfaz. */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--ground);
  color: var(--text);
  font: 400 var(--fs-body)/20px var(--font);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button, input, select { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
svg { flex: none; }
.num { font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }

/* Shell: T con reglas */
.shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  grid-template-rows: var(--topbar) 1fr;
  min-height: 100vh;
  min-height: 100dvh;
}
.sidebar {
  grid-row: 1 / 3;
  border-right: 1px solid var(--border);
  padding: 0 12px calc(var(--player) + 20px);
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  display: flex; flex-direction: column;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}

/* Marca: el icono de la app y una línea que dice qué es */
.wordmark {
  display: flex; align-items: center; gap: 10px;
  height: var(--topbar); padding: 0 6px;
  font-weight: 600; font-size: 16px;
}
.wm-logo { width: 34px; height: 34px; border-radius: 10px; flex: none; transition: transform 300ms var(--ease-out); }
.wm-text { display: flex; flex-direction: column; line-height: 18px; }
.wm-text small { font-size: 11px; font-weight: 400; color: var(--faint); line-height: 14px; }
@media (hover: hover) and (pointer: fine) { .wordmark:hover .wm-logo { transform: rotate(-12deg) scale(1.06); } }

/* Navegación principal: icono en su caja, fondo que se desliza a la sección activa */
.nav { position: relative; display: flex; flex-direction: column; gap: 2px; margin-top: 10px; }
.nav-ind {
  position: absolute; left: 0; right: 0; top: 0; height: 42px; border-radius: 12px;
  background: var(--surface); opacity: 0; pointer-events: none;
  transition: transform 320ms var(--ease-in-out), height 320ms var(--ease-in-out), opacity 200ms ease;
}
.nav-ind.on { opacity: 1; }
.nav a {
  position: relative; z-index: 1; display: flex; align-items: center; gap: 12px;
  height: 42px; padding: 0 8px; border-radius: 12px; color: var(--nav);
  transition: color 180ms ease;
}
.ni {
  width: 30px; height: 30px; border-radius: 9px; flex: none; display: grid; place-items: center;
  background: var(--chip); color: var(--muted);
  transition: background-color 220ms ease, color 220ms ease, transform 220ms var(--ease-out);
}
.nav a svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nl { flex: 1; }
.nav a[aria-current="page"] { color: var(--text); font-weight: 500; }
.nav a[aria-current="page"] .ni { background: var(--accent); color: var(--on-accent); }
.nav a:active .ni { transform: scale(0.92); }
@media (hover: hover) and (pointer: fine) {
  .nav a:hover { color: var(--text); }
  .nav a:hover .ni { transform: scale(1.08); color: var(--text); }
  .nav a[aria-current="page"]:hover .ni { color: var(--on-accent); }
}
.nb {
  min-width: 22px; height: 20px; padding: 0 7px; border-radius: 999px; display: grid; place-items: center;
  background: var(--chip-2); color: var(--text); font-size: 11px; font-weight: 600;
}
.nav a[aria-current="page"] .nb { background: var(--line); }

/* Géneros: cada uno con su color e icono */
.nav-group {
  display: flex; align-items: center; gap: 8px;
  margin: 26px 8px 8px; color: var(--faint); font-size: var(--fs-small);
}
.nav-group svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.genre-nav { display: flex; flex-direction: column; gap: 2px; }
.genre-nav button {
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%;
  height: 40px; padding: 0 8px; border: 0; border-radius: 12px; background: none; text-align: left; cursor: pointer;
  color: var(--nav);
  transition: color 180ms ease, background-color 180ms ease;
}
.gi {
  width: 30px; height: 30px; border-radius: 9px; flex: none; display: grid; place-items: center;
  background: color-mix(in srgb, var(--g) 16%, transparent); color: var(--g);
  transition: background-color 220ms ease, color 220ms ease, transform 260ms var(--ease-out);
}
.gi svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.gl { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.genre-nav .n {
  min-width: 22px; height: 20px; padding: 0 7px; border-radius: 999px; display: grid; place-items: center;
  background: var(--chip); color: var(--faint); font-size: 11px; font-weight: 600;
  transition: background-color 220ms ease, color 220ms ease;
}
.genre-nav .eq { display: none; }
.genre-nav .eq i { background: var(--g); }
.genre-nav button.live .eq { display: inline-flex; }
.genre-nav button[aria-pressed="true"] { color: var(--text); background: var(--surface); }
.genre-nav button[aria-pressed="true"] .gi { background: var(--g); color: #000; }
.genre-nav button[aria-pressed="true"] .n { background: color-mix(in srgb, var(--g) 22%, transparent); color: var(--g); }
.genre-nav button:active .gi { transform: scale(0.92); }
@media (hover: hover) and (pointer: fine) {
  .genre-nav button:hover { color: var(--text); background: var(--surface); }
  .genre-nav button:hover .gi { transform: rotate(-8deg) scale(1.1); }
}

/* Entrada escalonada de la barra al abrir la app (una sola vez) */
.nav a, .genre-nav button { animation: side-in 360ms var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 35ms + 80ms); }
@keyframes side-in { from { opacity: 0; transform: translateX(-10px); } }

/* "Sonando ahora": la emisora actual al pie de la barra */
.side-now {
  margin-top: auto; position: sticky; bottom: 0;
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; margin-bottom: 4px;
  background: var(--surface-2); border: 1px solid var(--chip-2); border-radius: 16px; color: var(--text);
  text-align: left; cursor: pointer; font: inherit;
  transition: border-color 200ms ease, transform 160ms var(--ease-out);
}
.side-now.playing { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.side-now:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) { .side-now:hover { border-color: var(--line); } .side-now.playing:hover { border-color: var(--accent); } }
.side-now .logo { width: 40px; height: 40px; border-radius: 10px; }
.sn-text { display: flex; flex-direction: column; min-width: 0; line-height: 17px; }
.sn-text b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sn-label { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--accent); }
.side-now:not(.playing) .sn-label { color: var(--faint); }
.sn-place { font-size: 12px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (prefers-reduced-motion: reduce) {
  .nav a, .genre-nav button { animation: none; }
  .nav-ind { transition: opacity 200ms ease; }
  .genre-nav button:hover .gi, .nav a:hover .ni, .wordmark:hover .wm-logo { transform: none; }
}

/* Tamaño y trazo de los iconos de línea fuera de la barra lateral */
.bottom-nav svg, .search svg, .volume svg, .btn-primary svg, .icon-btn svg {
  width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round;
}

.topbar {
  display: flex; align-items: center; gap: 16px;
  border-bottom: 1px solid var(--border);
  padding-left: var(--gutter);
  position: sticky; top: 0; z-index: 5; background: var(--ground);
}
.wordmark-phone { display: none; }
.search {
  flex: 1; max-width: 520px; height: var(--control-height);
  display: flex; align-items: center; gap: 8px; padding: 0 14px;
  background: var(--surface); border-radius: var(--radius-control); color: var(--faint);
}
.search:focus-within { background: var(--raised); color: var(--text); }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--text); height: 100%; }
.search input::placeholder { color: var(--faint); }
.topbar-switch {
  margin-left: auto; height: 100%; display: flex; align-items: center;
  padding: 0 var(--gutter); border-left: 1px solid var(--border);
}
.toggle { display: flex; align-items: center; gap: 10px; cursor: pointer; color: var(--muted); }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.toggle-track { width: 32px; height: 18px; border-radius: 999px; background: var(--raised); position: relative; transition: background-color .15s; }
.toggle-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; border-radius: 50%; background: var(--faint); transition: transform .15s, background-color .15s; }
.toggle input:checked + .toggle-track { background: var(--text); }
.toggle input:checked + .toggle-track::after { transform: translateX(14px); background: var(--ground); }
.toggle input:checked ~ span:last-child { color: var(--text); }
.toggle input:focus-visible + .toggle-track { outline: 2px solid var(--text); outline-offset: 2px; }

/* Lienzo */
.canvas { padding: 24px var(--gutter) calc(var(--player) + 40px); min-width: 0; outline: 0; }
.title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
h1 { font-size: var(--fs-title); line-height: 28px; font-weight: 600; margin: 0; }
h2 { font-size: var(--fs-section); line-height: 24px; font-weight: 600; margin: 0; }
.subline { margin: 4px 0 0; color: var(--muted); }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px; height: var(--control-height); padding: 0 16px;
  background: var(--text); color: var(--ground); border: 0; border-radius: var(--radius-control);
  font-weight: 500; cursor: pointer; white-space: nowrap; transition: transform .12s, background-color .15s;
}
.btn-primary:hover { background: var(--inverse-hover); }
.btn-primary:active { transform: scale(.97); }
.btn-text { background: none; border: 0; padding: 0; color: var(--text); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* Bloque principal: lo que suena + dial */
.lead { display: grid; grid-template-columns: 5fr 7fr; gap: var(--gap); margin-bottom: 40px; }
.dial-card { display: flex; flex-direction: column; }
.now, .dial-card { background: var(--surface); border-radius: var(--radius-card); padding: var(--pad); min-width: 0; }
.now { display: grid; grid-template-columns: 96px 1fr; grid-template-rows: auto 1fr auto; column-gap: 18px; row-gap: 14px; }
.now .logo-xl { grid-row: 1 / 3; }
.now-label { color: var(--faint); font-size: var(--fs-small); margin: 0 0 4px; }
.now-name { font-size: var(--fs-kpi); line-height: 30px; font-weight: 600; margin: 0; letter-spacing: -0.01em; }
.now-place { color: var(--muted); margin: 4px 0 0; }
.now-facts { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); background: var(--raised); border-radius: var(--radius-nested); }
.now-facts div { padding: 12px 14px; min-width: 0; }
.now-facts div + div { border-left: 1px solid var(--line); }
.now-facts dt { color: var(--faint); font-size: var(--fs-small); }
.now-facts dd { margin: 2px 0 0; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now-tags { grid-column: 2; align-self: start; display: flex; flex-wrap: wrap; gap: 6px; }
.now-status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: var(--fs-small); }

.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.legend { margin: 0; display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: var(--fs-small); flex-wrap: wrap; }
.sw { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-left: 8px; }
.sw:first-child { margin-left: 0; }
.sw-night { background: var(--ground); }
.sw-day { background: var(--raised); }
.sw-dot { background: var(--accent); border-radius: 50%; }

.dial { position: relative; flex: 1; min-height: 150px; margin-top: 18px; border-radius: var(--radius-nested); background: var(--raised); overflow: hidden; }
.dial .shades { position: absolute; inset: 0; }
.dial .shade { position: absolute; top: 0; bottom: 0; background: var(--ground); }
.dial .stack { position: absolute; bottom: 12px; display: flex; flex-direction: column-reverse; align-items: center; gap: 4px; transform: translateX(-50%); }
.dial .dot {
  width: 22px; height: 22px; padding: 6px; border: 0; background: none; cursor: pointer; border-radius: 50%;
  display: grid; place-items: center;
}
.dial .dot::before {
  content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--muted);
  transition: transform 160ms var(--ease-out), background-color 160ms ease;
}
.dial .dot:focus-visible::before { background: var(--text); transform: scale(1.3); }
@media (hover: hover) and (pointer: fine) {
  .dial .dot:hover::before { background: var(--text); transform: scale(1.3); }
}
.dial .dot:active::before { transform: scale(0.97); }
.dial .dot[aria-current="true"]::before { background: var(--accent); transform: scale(1.4); }

/* La aguja: una capa del ancho del dial que se traslada en %, así viaja de emisora a emisora.
   Es el gesto de sintonizar, por eso dura más que el resto de la interfaz. */
.dial .needle-track {
  position: absolute; inset: 0; pointer-events: none; z-index: 1;
  opacity: 0; transition: transform 520ms var(--ease-in-out), opacity 200ms var(--ease-out);
}
.dial .needle-track.shown { opacity: 1; }
.dial .needle { position: absolute; top: 0; bottom: 0; left: 0; width: 2px; margin-left: -1px; background: var(--accent); }
.dial .needle-label {
  position: absolute; top: 10px; left: 8px; font-size: var(--fs-small); color: var(--ground); background: var(--accent);
  padding: 2px 8px; border-radius: 999px; white-space: nowrap; font-weight: 500;
}
.dial .needle-label.flip { left: auto; right: calc(100% + 8px); }
.dial .needle-track.tuning .needle,
.dial .needle-track.tuning .needle-label { animation: tuning 900ms ease-in-out infinite alternate; }
@keyframes tuning { from { opacity: 1; } to { opacity: .45; } }
.dial-tip {
  position: absolute; pointer-events: none; z-index: 2; background: var(--text); color: var(--ground);
  font-size: var(--fs-small); padding: 4px 8px; border-radius: 6px; white-space: nowrap; transform: translate(-50%, -100%);
  box-shadow: 0 6px 18px rgba(0,0,0,.4);
}
.dial-regions { position: relative; height: 20px; color: var(--muted); font-size: var(--fs-small); }
.dial-regions span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.dial-hours { position: relative; height: 34px; color: var(--faint); font-size: var(--fs-small); }
.dial-hours span { position: absolute; top: 8px; transform: translateX(-50%); white-space: nowrap; }
.dial-hours span:first-child { transform: none; }
.dial-hours span:last-child { transform: translateX(-100%); }

/* Lista */
.list-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 8px; }
.count { color: var(--faint); font-size: var(--fs-small); }
.tabs { position: relative; display: flex; gap: 22px; border-bottom: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; margin-bottom: 4px; }
.tabs::-webkit-scrollbar { display: none; }
.tab { position: relative; height: 40px; background: none; border: 0; padding: 0; color: var(--nav); cursor: pointer; white-space: nowrap; }
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { color: var(--text); }
/* Indicador único: un bloque de 1px escalado al ancho de la pestaña activa y trasladado hasta ella. */
.tab-ind {
  position: absolute; left: 0; bottom: 0; width: 1px; height: 2px; background: var(--text);
  transform-origin: left; opacity: 0;
}
.tab-ind.ready { opacity: 1; transition: transform 240ms var(--ease-in-out); }

/* Filas que llegan: solo cuando cambia la lista (otro género, otro país, una búsqueda). */
.stations tr.enter { animation: row-in 240ms var(--ease-out) backwards; animation-delay: calc(var(--i) * 30ms); }
@keyframes row-in { from { opacity: 0; transform: translateY(6px); } }

/* Cambio de vista: un fundido corto para que el contenido no salte. */
.view:not([hidden]) { animation: view-in 200ms var(--ease-out); }
@keyframes view-in { from { opacity: 0; transform: translateY(4px); } }
.tab .n { color: var(--faint); margin-left: 4px; font-size: var(--fs-small); }

.table-wrap { width: 100%; }
table.stations { width: 100%; border-collapse: collapse; table-layout: fixed; }
.stations th { height: 40px; text-align: left; font-weight: 400; color: var(--faint); font-size: var(--fs-small); padding-right: 16px; }
.stations, .count, .tab .n, .genre-nav .n, .dial-hours, .now-facts dd, .player-sub, .subline { font-variant-numeric: tabular-nums; }
.stations th.num, .stations td.num { text-align: right; }
.stations td { height: 72px; border-top: 1px solid var(--rule); vertical-align: middle; padding-right: 16px; }
.stations td:last-child, .stations th:last-child { padding-right: 0; }
.stations tbody tr { cursor: pointer; transition: background-color .12s; }
.stations tbody tr:hover { background: var(--surface); }
.stations tbody tr:hover td:first-child { border-radius: 12px 0 0 12px; }
.stations tbody tr:hover td:last-child { border-radius: 0 12px 12px 0; }
.stations tr:hover td, .stations tr:hover + tr td { border-top-color: transparent; }
.col-station { width: 38%; }
.col-tags { width: 28%; }
.col-time { width: 12%; }
.col-format { width: 12%; }
.col-actions { width: 10%; }
.station-cell { display: flex; align-items: center; gap: 14px; min-width: 0; }
.station-cell > div { min-width: 0; }
.st-name { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 8px; }
.st-name > span:first-child { overflow: hidden; text-overflow: ellipsis; }
.st-place { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.playing .st-name > span:first-child { color: var(--accent); }
.tags { display: flex; gap: 6px; flex-wrap: nowrap; overflow: hidden; }
.pill { display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px; background: var(--pill-neutral-bg); color: var(--muted); font-size: var(--fs-small); white-space: nowrap; }
.dim { color: var(--faint); }
.unit { color: var(--faint); font-size: var(--fs-small); margin-left: 3px; }
.row-actions { display: flex; justify-content: flex-end; gap: 4px; }
.icon-btn {
  width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%;
  background: none; border: 0; color: var(--faint); cursor: pointer; transition: color .15s, background-color .15s, transform .12s;
}
.icon-btn:hover { color: var(--text); background: var(--raised); }
.icon-btn:active { transform: scale(.92); }
.icon-btn:disabled { opacity: .4; cursor: default; }
.icon-btn[aria-pressed="true"] { color: var(--text); }
.icon-btn[aria-pressed="true"] svg { fill: currentColor; }
.row-play svg { fill: currentColor; stroke: none; width: 16px; height: 16px; }

.logo { width: 44px; height: 44px; border-radius: 12px; background: var(--raised); display: grid; place-items: center; flex: none; overflow: hidden; font-weight: 600; font-size: 13px; color: var(--muted); }
.logo { position: relative; }
/* Monograma de respaldo: un color propio por emisora, para que nunca quede una caja gris */
.logo[style*="--h"] { background: hsl(var(--h) 38% 20%); color: hsl(var(--h) 80% 78%); }
/* El logotipo se ve solo cuando cargó de verdad, y entra con un fundido */
.logo img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff;
  opacity: 0; transform: scale(0.94); transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out);
}
.logo img.ok { opacity: 1; transform: none; }
.logo-xl { width: 96px; height: 96px; border-radius: 16px; font-size: 26px; }

/* Ecualizador de lo que suena */
.eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; flex: none; }
.eq i { width: 3px; height: 100%; background: var(--accent); border-radius: 1px; transform-origin: bottom; animation: eq 1s ease-in-out infinite; }
/* Duraciones distintas por barra para que el vúmetro no se vea mecánico. */
.eq i:nth-child(1) { animation-duration: .9s; }
.eq i:nth-child(2) { animation-duration: .7s; animation-delay: -.4s; }
.eq i:nth-child(3) { animation-duration: 1.1s; animation-delay: -.7s; }
.paused .eq i, .eq.still i { animation: none; transform: scaleY(.4); }
@keyframes eq { 0%, 100% { transform: scaleY(.3); } 50% { transform: scaleY(1); } }

/* Estados */
.state { padding: 18px 0; color: var(--muted); border-top: 1px solid var(--rule); }
.state-box { border: 1px dashed var(--line); border-radius: 12px; padding: 14px 16px; color: var(--muted); margin-top: 8px; }
.err { color: var(--negative); }
.skeleton td { height: 72px; }
.bar { display: block; height: 12px; border-radius: 4px; background: var(--surface); }

/* Toolbar de Explorar */
.toolbar { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 12px; flex-wrap: wrap; }
.field { display: flex; flex-direction: column; gap: 6px; color: var(--faint); font-size: var(--fs-small); }
.field select {
  height: var(--control-height); min-width: 220px; padding: 0 36px 0 14px; border-radius: var(--radius-control);
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23b4b4b4' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center;
  border: 1px solid var(--control); appearance: none; color: var(--text); font-size: var(--fs-body); cursor: pointer;
}
.toolbar .count { margin-left: auto; padding-bottom: 8px; }

.credit { margin: 48px 0 0; color: var(--faint); font-size: var(--fs-small); }
.credit a { text-decoration: underline; text-underline-offset: 3px; }

/* Reproductor */
.player {
  position: fixed; left: var(--sidebar-width); right: 0; bottom: 0; height: var(--player); z-index: 10;
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 20px;
  padding: 0 var(--gutter);
  background: var(--surface); border-top: 1px solid var(--border);
}
.play {
  width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--text); color: var(--ground);
  display: grid; place-items: center; cursor: pointer; flex: none; transition: transform .12s, background-color .15s;
}
.play:hover { background: var(--inverse-hover); }
.play:active { transform: scale(.94); }
.play:disabled { background: var(--raised); color: var(--faint); cursor: default; }
.play { position: relative; }
/* Play y pausa se cruzan en vez de saltar; al pulsar rápido la transición se reorienta. */
.play svg {
  width: 20px; height: 20px; fill: currentColor; grid-area: 1 / 1;
  transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out);
}
.play .i-pause { opacity: 0; transform: scale(0.9); }
.play[data-state="playing"] .i-play { opacity: 0; transform: scale(0.9); }
.play[data-state="playing"] .i-pause { opacity: 1; transform: none; }
.play[data-state="loading"] .i-play { opacity: .35; }
/* Mientras conecta, un arco gira alrededor del botón (progreso: lineal). */
.play::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid transparent; border-top-color: var(--accent);
  opacity: 0; transition: opacity 200ms var(--ease-out);
}
.play[data-state="loading"]::after { opacity: 1; animation: spin 900ms linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.player-meta { min-width: 0; flex: 1; }
.player-logo:empty { display: none; }
.player-logo .logo { width: 40px; height: 40px; border-radius: 10px; }

/* Mini dial sobre el reproductor: la aguja viaja a la longitud de la emisora, como en el dial grande. */
.player-dial {
  position: absolute; top: -1px; left: 0; right: 0; height: 3px; overflow: hidden; pointer-events: none; background: var(--raised);
  opacity: 0; transition: opacity 200ms var(--ease-out);
}
.player-dial.shown { opacity: 1; }
.player-needle {
  position: absolute; inset: 0;
  transition: transform 520ms var(--ease-in-out);
}
.player-needle::before { content: ""; position: absolute; top: 0; bottom: 0; left: -10px; width: 20px; border-radius: 2px; background: var(--accent); }
.player-dial.tuning .player-needle::before { animation: tuning 900ms ease-in-out infinite alternate; }

/* Pulsar en pantallas táctiles: la fila responde aunque no haya hover. */
.stations .logo { transition: transform 160ms var(--ease-out); }
@media (hover: none) {
  .stations tbody tr:active { background: var(--surface); }
  .stations tbody tr:active .logo { transform: scale(0.94); }
}
.st-name > span:first-child { transition: color 200ms ease; }
.player-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-sub { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 8px; }
.volume { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.volume input { width: 120px; accent-color: var(--text); }

.bottom-nav { display: none; }

/* Movimiento reducido: se quitan los desplazamientos y los bucles, se quedan los fundidos. */
@media (prefers-reduced-motion: reduce) {
  .dial .needle-track, .player-needle { transition: opacity 200ms ease; }
  .player-dial.tuning .player-needle::before { animation: none; }
  .bottom-nav a::before { transition: none; }
  .stations tbody tr:active .logo, .bottom-nav a:active svg { transform: none; }
  .tab-ind.ready { transition: none; }
  @keyframes row-in { from { opacity: 0; } }
  @keyframes view-in { from { opacity: 0; } }
  .eq i { animation: none; transform: scaleY(.6); }
  .play[data-state="loading"]::after { animation: none; border-color: var(--accent); }
  .dial .needle-track.tuning .needle,
  .dial .needle-track.tuning .needle-label { animation: none; opacity: .6; }
  .btn-primary:active, .play:active, .icon-btn:active { transform: none; }
}

/* Tableta */
@media (max-width: 1100px) {
  .lead { grid-template-columns: 1fr; }
  .col-tags { width: 30%; }
  .col-time { display: none; }
  .stations td.c-time, .stations th.c-time { display: none; }
}

/* Teléfono y tableta estrecha: la sidebar se pliega */
@media (max-width: 860px) {
  :root { --gutter: 16px; --topbar: 56px; --player: 68px; --pad: 16px; --radius-card: 16px; }
  .shell { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .dial-hours span:nth-child(2), .dial-hours span:nth-child(6) { display: none; }
  .sidebar { display: none; }
  .topbar { padding-left: var(--gutter); gap: 12px; flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 10px; }
  .wordmark-phone { display: flex; height: 36px; padding: 0; font-size: 15px; }
  .search { order: 3; flex-basis: 100%; max-width: none; margin-right: var(--gutter); height: 40px; }
  .topbar-switch { border-left: 0; padding: 0 var(--gutter) 0 0; height: 36px; }
  .dial-regions span:last-child { display: none; }
  .canvas { padding-top: 20px; padding-bottom: calc(var(--player) + 64px + 32px); }
  .title-row { flex-direction: column; }
  .title-row .btn-primary { height: 44px; }
  .now { grid-template-columns: 64px 1fr; column-gap: 14px; }
  .logo-xl { width: 64px; height: 64px; font-size: 20px; border-radius: 14px; }
  .now-name { font-size: 20px; line-height: 26px; }
  .now-tags { grid-column: 1 / -1; }
  .now .logo-xl { grid-row: 1; }
  .dial { min-height: 130px; }
  .dial .dot { width: 18px; height: 18px; padding: 5px; }
  .dial .dot::before { width: 8px; height: 8px; }
  .player { left: 0; bottom: 64px; padding: 0 var(--gutter); gap: 12px; border-top: 0; border-bottom: 1px solid var(--border); }
  .volume { display: none; }
  .bottom-nav {
    display: grid; grid-template-columns: repeat(4, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
    height: 64px; padding-bottom: env(safe-area-inset-bottom); background: var(--ground); border-top: 1px solid var(--border);
  }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 11px; color: var(--nav); }
  .bottom-nav a { position: relative; transition: color 200ms ease; }
  .bottom-nav a[aria-current="page"] { color: var(--text); }
  .bottom-nav svg { width: 20px; height: 20px; transition: transform 160ms var(--ease-out); }
  .bottom-nav a:active svg { transform: scale(0.88); }
  /* Marca de la sección activa: crece desde el centro al cambiar de pestaña. */
  .bottom-nav a::before {
    content: ""; position: absolute; top: 0; left: 50%; width: 24px; height: 2px; margin-left: -12px;
    background: var(--text); border-radius: 0 0 2px 2px; transform: scaleX(0); transition: transform 240ms var(--ease-out);
  }
  .bottom-nav a[aria-current="page"]::before { transform: scaleX(1); }
  .player-logo .logo { width: 40px; height: 40px; }
  .toolbar .field { flex: 1; }
  .field select { min-width: 0; width: 100%; height: 44px; }
  .toolbar .count { flex-basis: 100%; margin-left: 0; padding-bottom: 0; }

  /* La tabla pasa a filas de dos líneas */
  table.stations, .stations tbody, .stations tr { display: block; }
  .stations thead { display: none; }
  .stations tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; border-top: 1px solid var(--rule); padding: 12px 0; }
  .stations td { display: block; height: auto; border: 0; padding: 0; min-width: 0; }
  .stations td.c-tags, .stations td.c-format { display: none; }
  .stations tbody tr:hover { background: none; }
  .st-place .m-extra { display: inline; }
  .skeleton { height: 72px; }
}
.m-extra { display: none; }

/* ---------- Mapa (globo) ----------
   El globo ocupa el bloque principal; el océano es un paso sobre el negro y la tierra otro.
   Los puntos son los datos: gris para todas, ámbar para las destacadas y la que suena. */
.title-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-secondary {
  display: inline-flex; align-items: center; gap: 8px; height: var(--control-height); padding: 0 16px;
  background: none; color: var(--text); border: 1px solid var(--control); border-radius: var(--radius-control);
  font-weight: 500; cursor: pointer; white-space: nowrap; transition: transform 160ms var(--ease-out), background-color 150ms ease;
}
.btn-secondary svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.btn-secondary:active { transform: scale(0.97); }
.btn-secondary:disabled { opacity: .5; cursor: default; }
@media (hover: hover) and (pointer: fine) { .btn-secondary:hover { background: var(--surface); } }
.btn-primary { transition: transform 160ms var(--ease-out), background-color 150ms ease; }

.map-card { position: relative; border-radius: var(--radius-card); overflow: hidden; background: var(--map-space); margin-bottom: 40px; }
.map { height: clamp(420px, calc(100vh - var(--topbar) - var(--player) - 170px), 760px); background: var(--map-space); }
.map-legend {
  position: absolute; left: 16px; bottom: 14px; margin: 0; display: flex; align-items: center; gap: 6px;
  color: var(--muted); font-size: var(--fs-small); background: rgba(0,0,0,.72); padding: 6px 12px; border-radius: 999px;
}
.sw-grey { background: #9a9a9a; border-radius: 50%; }
.map-status {
  position: absolute; left: 16px; top: 16px; right: 64px; max-width: 420px;
  background: var(--surface); color: var(--muted); padding: 10px 14px; border-radius: 12px; font-size: 13px;
}
.map-tip {
  position: absolute; left: 0; top: 0; z-index: 3; pointer-events: none; white-space: nowrap;
  background: var(--text); color: var(--ground); font-size: var(--fs-small); font-weight: 500;
  padding: 4px 9px; border-radius: 6px; box-shadow: 0 6px 18px rgba(0,0,0,.45);
  opacity: 0; transition: opacity 125ms var(--ease-out);
}
.map-tip.on { opacity: 1; }

/* Controles de zoom de MapLibre, con el aspecto de la app */
.map .maplibregl-ctrl-group { background: var(--surface); border-radius: 12px; box-shadow: none; overflow: hidden; }
.map .maplibregl-ctrl-group button { width: 36px; height: 36px; background: none; }
.map .maplibregl-ctrl-group button + button { border-top: 1px solid var(--border); }
.map .maplibregl-ctrl-group button .maplibregl-ctrl-icon { filter: invert(1) brightness(.8); }
.map .maplibregl-ctrl-group button:hover { background: var(--raised); }
.map .maplibregl-ctrl-top-right { top: 6px; right: 6px; }

/* La emisora que suena: punto ámbar con un anillo que se expande y se desvanece. */
.map-pulse { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px #000; position: relative; pointer-events: none; }
.map-pulse span { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; }
.map-pulse.live span { animation: ring 1.8s var(--ease-out) infinite; }
.map-pulse.tuning { animation: tuning 900ms ease-in-out infinite alternate; }
@keyframes ring { from { transform: scale(1); opacity: .9; } to { transform: scale(3.2); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .map-pulse.live span { animation: none; opacity: .6; transform: scale(1.8); }
  .map-pulse.tuning { animation: none; opacity: .6; }
}

@media (max-width: 860px) {
  .title-actions { width: 100%; }
  .title-actions button { flex: 1; justify-content: center; height: 44px; }
  .map-card { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); border-radius: 0; }
  .map { height: 58vh; min-height: 340px; }
  .map-legend { left: 12px; bottom: 10px; }
  .bottom-nav { grid-template-columns: repeat(5, 1fr); }
}

/* ---------- Globo realista ----------
   Aquí la persona pidió color y realismo: la Tierra a color, atmósfera azul y estrellas.
   El resto de la app mantiene su negro plano. */
.map { background-color: var(--map-space); background-repeat: repeat; }
.sw-daydot { background: #ffffff; border-radius: 50%; box-shadow: 0 0 0 1px rgba(0,0,0,.6); }
.sw-nightdot { background: #ffcf6b; border-radius: 50%; }
.sw-shadow { background: #0a1430; border: 1px solid #3a4a72; }
.map-legend { flex-wrap: wrap; gap: 4px 14px; left: 16px; right: auto; bottom: 14px; max-width: calc(100% - 32px); background: rgba(2,6,23,.72); }
.map-legend .lg { display: inline-flex; align-items: center; gap: 6px; }
.map-legend .sw { margin-left: 0; }

/* Panel "Ahora en el mundo" */
.map-now {
  position: absolute; left: 16px; top: 16px; z-index: 2; width: 260px;
  background: rgba(2,6,23,.78); color: var(--text); border-radius: 16px; padding: 14px 16px;
  font-size: 13px; line-height: 18px; pointer-events: none;
  animation: now-in 500ms var(--ease-out) 400ms backwards;
}
@keyframes now-in { from { opacity: 0; transform: translateY(-8px); } }
.map-now .mn-title { margin: 0 0 8px; font-weight: 600; font-size: 14px; }
.map-now ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 7px; }
.map-now li { display: flex; align-items: flex-start; gap: 10px; color: #d6dbe6; }
.map-now b { color: #fff; font-weight: 600; }
.map-now .sw-only { display: none; }
.map-now svg, .map-tip svg, .map-pulse-label svg {
  width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}
.map-now li svg { margin-top: 1px; color: #9fb0d0; }
.i-day { color: #ffc94a !important; }
.i-dusk { color: #ff8a3d !important; }
.i-night { color: #dfe7ff !important; }
/* el sol del panel gira muy despacio */
.map-now .i-day { animation: sun-turn 24s linear infinite; }
@keyframes sun-turn { to { transform: rotate(360deg); } }

/* Etiqueta flotante con hora y sol/luna */
.map-tip { display: flex; flex-direction: column; gap: 2px; background: rgba(2,6,23,.92); color: #fff; padding: 7px 10px; border-radius: 10px; }
.map-tip b { font-weight: 600; }
.map-tip span, .map-pulse-label span { display: inline-flex; align-items: center; gap: 5px; color: #c9d2e3; }
.map-tip svg, .map-pulse-label svg { width: 14px; height: 14px; }

/* La emisora que suena lleva su nombre y su hora pegados al punto */
.map-pulse-label {
  position: absolute; left: 22px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 1px; white-space: nowrap;
  background: rgba(2,6,23,.88); color: #fff; font-size: 12px; line-height: 16px; padding: 6px 10px; border-radius: 10px;
  animation: label-in 300ms var(--ease-out);
}
.map-pulse-label b { font-weight: 600; }
@keyframes label-in { from { opacity: 0; transform: translate(-6px, -50%); } }
.map-pulse { box-shadow: 0 0 0 2px #fff, 0 0 18px 4px rgba(242,179,61,.55); }

.maplibregl-ctrl-attrib { font-size: 10px; }
.maplibregl-ctrl-attrib.maplibregl-compact { background: rgba(2,6,23,.6); color: #c9d2e3; }
.maplibregl-ctrl-attrib a { color: #c9d2e3; }

@media (prefers-reduced-motion: reduce) {
  .map-now, .map-pulse-label { animation: none; }
  .map-now .i-day, .map-now .w-drops, .map-now .w-bolt { animation: none !important; }
}

@media (max-width: 860px) {
  /* En el teléfono el panel se vuelve una franja compacta arriba del globo */
  .map-now { left: 10px; right: 56px; top: 10px; width: auto; padding: 10px 12px; font-size: 12px; }
  .map-now .mn-title { display: none; }
  .map-now .sw-only { display: inline; }
  .map-now ul { grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 8px; }
  .map-now li:nth-child(3), .map-now li:nth-child(5), .map-now .lw { display: none; }
  .map-now li { gap: 6px; white-space: nowrap; }
  .map-legend { left: 10px; right: 10px; bottom: 10px; max-width: none; justify-content: center; }
  .map-pulse-label { font-size: 11px; }
}

/* Cuando el navegador pide un toque antes de sonar, el botón de reproducir llama la atención */
.play.nudge { animation: nudge 1.6s var(--ease-out) infinite; }
@keyframes nudge {
  0% { box-shadow: 0 0 0 0 rgba(242, 179, 61, .7); }
  70%, 100% { box-shadow: 0 0 0 14px rgba(242, 179, 61, 0); }
}
.player:has(.play.nudge) .player-sub { color: var(--accent); }
@media (prefers-reduced-motion: reduce) { .play.nudge { animation: none; box-shadow: 0 0 0 3px var(--accent); } }


/* ---------- Panel de la emisora: hora local, día/noche y clima ---------- */
.map-now.station { width: 290px; }
.map-now.station .mn-title { display: flex; flex-direction: column; margin-bottom: 2px; }
.mn-where { font-size: 15px; font-weight: 600; color: #fff; }
.mn-station { font-size: 12px; font-weight: 400; color: #9fb0d0; }
.mn-time { margin: 2px 0 10px; display: flex; align-items: baseline; gap: 8px; }
.mn-time b { font-size: 32px; line-height: 38px; font-weight: 600; letter-spacing: -0.02em; color: #fff; }
.mn-time span { color: #9fb0d0; font-size: 12px; }
.map-now .mn-sky svg, .map-now .mn-wx svg { width: 20px; height: 20px; margin-top: -1px; }
.map-now .mn-sub { padding-left: 30px; color: #9fb0d0; font-size: 12px; }
.map-now .mn-sub b { font-weight: 500; color: #d6dbe6; }
.mn-wx.loading span { animation: wx-wait 1.2s ease-in-out infinite alternate; }
@keyframes wx-wait { from { opacity: 1; } to { opacity: .45; } }
.mn-world {
  margin: 12px 0 0; padding-top: 10px; border-top: 1px solid rgba(255,255,255,.08);
  display: flex; align-items: center; gap: 5px; flex-wrap: wrap; color: #9fb0d0; font-size: 12px;
}
.map-now .mn-world svg { width: 14px; height: 14px; }

/* Iconos del clima con su color */
.map-now li svg.w-cloud { color: #cbd5e1 !important; }
.map-now svg .w-sunpart { color: #ffc94a; stroke: #ffc94a; }
.map-now svg .w-moonpart { stroke: #dfe7ff; }
.map-now li svg.w-rain { color: #93c5fd !important; }
.map-now li svg.w-snow { color: #e0f2fe !important; }
.map-now li svg.w-storm { color: #cbd5e1 !important; }
.map-now svg .w-bolt { stroke: #fbbf24; }
.map-now svg .w-cloudpart { stroke: #cbd5e1; }
/* lluvia que cae y rayo que parpadea, muy sutiles */
.map-now .w-drops { animation: drops 1.1s linear infinite; }
@keyframes drops { from { transform: translateY(-1.5px); opacity: .5; } 50% { opacity: 1; } to { transform: translateY(1.5px); opacity: .5; } }
.map-now .w-bolt { animation: bolt 2.4s ease-in-out infinite; }
@keyframes bolt { 0%, 88%, 100% { opacity: 1; } 92% { opacity: .2; } 96% { opacity: 1; } 98% { opacity: .4; } }

@media (max-width: 860px) {
  /* En el teléfono: lugar y hora en una línea, día/noche y clima en otra */
  .map-now.station { width: auto; }
  .map-now.station .mn-title { display: flex; flex-direction: row; align-items: baseline; gap: 8px; }
  .map-now.station .mn-where { font-size: 13px; }
  .map-now.station .mn-station { display: none; }
  .map-now.station .mn-time { margin: 0 0 6px; }
  .map-now.station .mn-time b { font-size: 22px; line-height: 26px; }
  .map-now.station ul { grid-template-columns: 1fr; gap: 4px; }
  .map-now.station li { white-space: normal; }
  .map-now.station .mn-sub, .map-now.station .mn-world { display: none; }
}


/* ---------- Reproductor: info a la izquierda, todos los controles juntos al centro ---------- */
.player-info { display: flex; align-items: center; gap: 12px; min-width: 0; }
.controls {
  display: flex; align-items: center; gap: 2px;
  padding: 5px 12px 5px 6px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--chip-2);
}
.ctl { width: 38px; height: 38px; color: var(--muted); }
.ctl svg { width: 19px; height: 19px; }
.play { margin: 0 4px; }
.skip svg { width: 20px; height: 20px; fill: currentColor; stroke: currentColor; stroke-width: 1.2; stroke-linejoin: round; }
.ctl:disabled { opacity: .3; }
@media (hover: hover) and (pointer: fine) { .ctl:not(:disabled):hover { color: var(--text); background: var(--chip-2); } }

/* modo del siguiente: barajar o ubicación; ámbar cuando busca la más cercana */
.mode-btn .m-cerca { display: none; }
.mode-btn[data-mode="cerca"] .m-cerca { display: block; }
.mode-btn[data-mode="cerca"] .m-azar { display: none; }
.mode-btn[data-mode="cerca"] { color: var(--accent); background: color-mix(in srgb, var(--accent) 14%, transparent); }
#player-fav[aria-pressed="true"] { color: var(--accent); }

.ctl-sep { width: 1px; height: 22px; background: var(--line); margin: 0 8px 0 6px; }

/* volumen: icono que cambia con el nivel y barra que se rellena en ámbar */
.volume { display: flex; align-items: center; gap: 4px; color: var(--muted); }
.volume .v-x { display: none; }
.volume[data-level="0"] .v-w1, .volume[data-level="0"] .v-w2 { display: none; }
.volume[data-level="0"] .v-x { display: block; }
.volume[data-level="1"] .v-w2 { display: none; }
.volume input {
  -webkit-appearance: none; appearance: none; width: 96px; height: 4px; border-radius: 999px; cursor: pointer;
  background: linear-gradient(to right, var(--accent) var(--v, 80%), var(--line) var(--v, 80%));
}
.volume input::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%; background: var(--text); border: 0;
  transform: scale(0.85); transition: transform 160ms var(--ease-out);
}
.volume input::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: var(--text); border: 0; }
.volume input:hover::-webkit-slider-thumb, .volume input:focus-visible::-webkit-slider-thumb { transform: scale(1.1); }

.player-side { justify-self: end; color: var(--faint); font-size: 12px; white-space: nowrap; }
.mode-hint b { color: var(--muted); font-weight: 500; }

@media (max-width: 1100px) {
  .player { grid-template-columns: minmax(0, 1fr) auto; }
  .player-side { display: none; }
}
@media (max-width: 860px) {
  .player { gap: 10px; }
  .controls { background: none; border: 0; padding: 0; gap: 0; }
  .ctl { width: 34px; height: 40px; }
  .ctl-sep, .volume { display: none; }
  .player-logo { display: none; }
}

/* Selector de idioma: dos pastillas, la activa en blanco */
.topbar-switch { gap: 16px; }
.lang { display: flex; padding: 3px; border-radius: 999px; background: var(--surface); }
.lang button {
  height: 26px; min-width: 34px; padding: 0 9px; border: 0; border-radius: 999px;
  background: none; color: var(--faint); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease;
}
.lang button[aria-pressed="true"] { background: var(--text); color: var(--ground); }
@media (hover: hover) and (pointer: fine) { .lang button[aria-pressed="false"]:hover { color: var(--text); } }
.lang button:active { transform: scale(0.94); }
@media (max-width: 860px) { .topbar-switch { gap: 10px; } .lang button { min-width: 30px; padding: 0 7px; } }

/* ---------- Juego: Adivina el país ---------- */
.ni-game { background: color-mix(in srgb, #4ade80 18%, transparent); color: #4ade80; }
.nav a .nb-new, .nav a[aria-current="page"] .nb-new { background: #4ade80; color: #04250e; font-size: 10px; letter-spacing: 0.02em; }
.game { --ok: #3fc07a; --ko: #e5566f; max-width: 880px; }
.game svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.g-muted { color: var(--muted); margin: 0; }
.g-label { color: var(--faint); font-size: var(--fs-small); }
.g-btn, .g-end-actions button, .g-reveal-actions button { display: inline-flex; align-items: center; gap: 8px; justify-content: center; }
.g-btn svg, .g-end-actions svg { width: 16px; height: 16px; }

/* Inicio */
.g-start { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.g-card { background: var(--surface); border-radius: var(--radius-card); padding: var(--pad); display: flex; flex-direction: column; gap: 18px; }
.g-daily { background: color-mix(in srgb, #4ade80 7%, var(--surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, #4ade80 28%, transparent); }
.g-card-head { display: flex; gap: 14px; align-items: flex-start; }
.g-card-head h2 { font-size: 18px; line-height: 24px; margin-bottom: 4px; }
.g-card-head p { margin: 0; color: var(--muted); }
.g-ico { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; flex: none; background: #4ade80; color: #04250e; }
.g-ico svg { width: 22px; height: 22px; }
.g-ico-free { background: var(--accent); color: var(--on-accent); }
.g-card .g-btn { align-self: flex-start; margin-top: auto; }
.g-done { display: flex; flex-direction: column; gap: 6px; }
.g-done p { margin: 0; }
.g-stats { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); margin: 0; background: var(--surface); border-radius: var(--radius-card); }
.g-stats div { padding: 16px 20px; display: grid; grid-template-columns: auto 1fr; column-gap: 12px; align-items: center; }
.g-stats div + div { border-left: 1px solid var(--border); }
.g-stats svg { grid-row: 1 / 3; width: 22px; height: 22px; color: var(--accent); }
.g-stats dt { color: var(--faint); font-size: var(--fs-small); }
.g-stats dd { margin: 0; font-size: 18px; font-weight: 600; }
.g-how { grid-column: 1 / -1; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.g-how li { display: flex; gap: 10px; color: var(--muted); font-size: 13px; line-height: 19px; }
.g-how svg { color: #4ade80; margin-top: 1px; }

/* Ronda */
.g-round { background: var(--surface); border-radius: var(--radius-card); padding: var(--pad); display: flex; flex-direction: column; gap: 18px; }
.g-top { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.g-top .g-label { flex: 1; }
.g-dots, .g-marks { display: inline-flex; gap: 5px; }
.g-dots i, .g-marks i { width: 10px; height: 10px; border-radius: 3px; background: var(--line); transition: background-color 300ms ease, transform 300ms var(--ease-out); }
.g-dots i.cur { background: var(--text); transform: scale(1.15); }
.g-dots i.ok, .g-marks i.ok { background: var(--ok); }
.g-dots i.ko, .g-marks i.ko { background: var(--ko); }
.g-marks i { width: 22px; height: 22px; border-radius: 6px; }
.g-score { font-weight: 600; font-size: 16px; color: var(--accent); }

.g-stage { display: flex; align-items: center; gap: 22px; padding: 18px; border-radius: 16px; background: var(--sunk); }
.g-ring { position: relative; width: 74px; height: 74px; flex: none; }
.g-ring svg { width: 74px; height: 74px; transform: rotate(-90deg); }
.g-ring-bg { fill: none; stroke: var(--line); stroke-width: 3; }
.g-ring-fg { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 0; transition: stroke-dashoffset 200ms linear, stroke 300ms ease; }
.g-ring.hurry .g-ring-fg { stroke: var(--ko); }
.g-ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 22px; font-weight: 600; }
.g-ring.hurry b { color: var(--ko); animation: hurry 1s ease-in-out infinite; }
@keyframes hurry { 50% { transform: scale(1.12); } }
.g-wave { display: flex; align-items: center; gap: 5px; height: 48px; }
.g-wave i { width: 5px; height: 100%; border-radius: 3px; background: var(--line); transform: scaleY(0.15); transform-origin: center; transition: background-color 300ms ease; }
.g-stage.live .g-wave i { background: var(--accent); animation: wave 1s ease-in-out infinite; }
.g-stage.live .g-wave i:nth-child(2n) { animation-duration: .8s; }
.g-stage.live .g-wave i:nth-child(3n) { animation-duration: 1.3s; }
.g-stage.live .g-wave i:nth-child(4n+1) { animation-delay: -.3s; }
.g-stage.live .g-wave i:nth-child(5n+2) { animation-delay: -.6s; }
@keyframes wave { 0%, 100% { transform: scaleY(0.2); } 50% { transform: scaleY(1); } }
.g-stage.won .g-wave i { background: var(--ok); }
.g-stage.lost .g-wave i { background: var(--ko); }
.g-status { margin: 0; font-size: 16px; font-weight: 500; flex: 1; }
.g-stage.won .g-status { color: var(--ok); }
.g-stage.lost .g-status { color: var(--ko); }
.g-ask { margin: 0; font-size: 18px; font-weight: 600; }
.g-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.g-opt {
  height: 56px; border-radius: 14px; border: 1px solid var(--line); background: var(--chip); color: var(--text);
  font: inherit; font-size: 16px; font-weight: 500; cursor: pointer; padding: 0 16px; text-align: left;
  transition: background-color 200ms ease, border-color 200ms ease, transform 160ms var(--ease-out), opacity 200ms ease;
}
.g-opt:disabled { cursor: default; opacity: .5; }
@media (hover: hover) and (pointer: fine) { .g-opt:not(:disabled):hover { border-color: var(--accent); background: var(--chip-2); } }
.g-opt:not(:disabled):active { transform: scale(0.97); }
.g-opt.right { background: color-mix(in srgb, var(--ok) 20%, var(--surface)); border-color: var(--ok); color: var(--text); opacity: 1; }
.g-opt.wrong { background: color-mix(in srgb, var(--ko) 20%, var(--surface)); border-color: var(--ko); opacity: 1; }
.g-hint { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 12px; background: color-mix(in srgb, var(--accent) 12%, var(--surface)); color: var(--text); }
.g-hint svg { color: var(--accent); }
.g-actions { display: flex; gap: 22px; flex-wrap: wrap; }
.g-actions .btn-text { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; }
.g-actions .btn-text:disabled { opacity: .4; cursor: default; }
@media (hover: hover) and (pointer: fine) { .g-actions .btn-text:not(:disabled):hover { color: var(--text); } }

.g-reveal { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; padding: 14px; border-radius: 16px; background: var(--sunk); }
.g-reveal .logo { width: 56px; height: 56px; border-radius: 14px; }
.g-reveal-text { display: flex; flex-direction: column; min-width: 0; }
.g-reveal-text b { font-size: 17px; }
.g-reveal-text span { color: var(--muted); font-size: 13px; }
.g-reveal-text .g-muted { font-size: 12px; color: var(--faint); }
.g-reveal-actions { display: flex; gap: 8px; }

/* Final */
.g-end { background: var(--surface); border-radius: var(--radius-card); padding: 32px var(--pad); display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; }
.g-big { margin: 0; font-size: 22px; color: var(--muted); }
.g-big b { font-size: 56px; line-height: 60px; color: var(--accent); letter-spacing: -0.02em; margin-right: 4px; }
.g-sum { margin: 0; font-size: 16px; font-weight: 500; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: center; }
.g-record { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); }
.g-end-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }

.g-toast {
  position: fixed; left: 50%; bottom: calc(var(--player) + 24px); transform: translateX(-50%); z-index: 50;
  background: var(--text); color: var(--ground); padding: 10px 16px; border-radius: 999px; font-weight: 500; font-size: 14px;
  box-shadow: 0 8px 24px rgba(0,0,0,.5); animation: toast-in 260ms var(--ease-out); transition: opacity 300ms ease, transform 300ms ease;
}
.g-toast.out { opacity: 0; transform: translate(-50%, 8px); }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 10px); } }

@media (prefers-reduced-motion: reduce) {
  .g-stage.live .g-wave i { animation: none; transform: scaleY(0.6); }
  .g-ring.hurry b { animation: none; }
}
@media (max-width: 860px) {
  .g-start { grid-template-columns: 1fr; }
  .g-stats div { grid-template-columns: 1fr; padding: 12px; text-align: center; justify-items: center; }
  .g-stats svg { grid-row: auto; }
  .g-how { grid-template-columns: 1fr; }
  .g-stage { gap: 14px; padding: 14px; }
  .g-ring, .g-ring svg { width: 60px; height: 60px; }
  .g-wave { height: 36px; gap: 4px; }
  .g-wave i { width: 4px; }
  .g-status { font-size: 14px; }
  .g-ask { font-size: 16px; }
  .g-options { grid-template-columns: 1fr; gap: 8px; }
  .g-opt { height: 52px; }
  .g-reveal { grid-template-columns: auto 1fr; }
  .g-reveal-actions { grid-column: 1 / -1; }
  .g-reveal-actions button { flex: 1; height: 44px; }
  .g-big b { font-size: 44px; }
  .bottom-nav { grid-template-columns: repeat(6, 1fr); }
  .bottom-nav a { font-size: 10px; }
}

/* ---------- Tabla de posiciones del reto del día ---------- */
.g-start .g-board { grid-column: 1 / -1; }
.g-board-end { margin-top: var(--gap); }
.g-board { gap: 14px; }
.g-board-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.g-board-head h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.g-board-head h2 svg { color: var(--accent); width: 20px; height: 20px; }
.g-board-body { display: flex; flex-direction: column; gap: 12px; }
.g-rank { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.g-rank li {
  display: grid; grid-template-columns: 32px minmax(0, 1fr) auto 56px; align-items: center; gap: 12px;
  padding: 8px 12px; border-radius: 12px; background: var(--chip);
  transition: background-color 200ms ease;
}
.g-rank li.me { background: color-mix(in srgb, var(--accent) 16%, var(--chip)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 45%, transparent); }
.g-pos { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 13px; background: var(--chip-2); color: var(--muted); }
.g-pos.p1 { background: #f2c94c; color: #3a2b00; }
.g-pos.p2 { background: #c9ced6; color: #23262b; }
.g-pos.p3 { background: #d08b5b; color: #2b1607; }
.g-who { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-mini { display: inline-flex; gap: 3px; }
.g-mini i { width: 8px; height: 8px; border-radius: 2px; background: var(--line); }
.g-mini i.ok { background: var(--ok); }
.g-mini i.ko { background: var(--ko); }
.g-rank b { text-align: right; color: var(--accent); }
.g-you { margin: 0; font-weight: 500; }
.g-name { display: flex; gap: 8px; flex-wrap: wrap; }
.g-name input {
  flex: 1; min-width: 180px; height: var(--control-height); padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--control); background: var(--surface-2); color: var(--text); font: inherit;
}
.g-name input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.g-form-note { font-size: 12px; margin-top: -4px; }
.g-form-note.err { color: var(--ko); }
@media (max-width: 860px) {
  .g-rank li { grid-template-columns: 28px minmax(0, 1fr) auto 44px; gap: 8px; padding: 8px 10px; }
  .g-mini i { width: 6px; height: 6px; }
  .g-name input, .g-name button { width: 100%; height: 44px; }
}

/* ---------- Temas ----------
   "noche" es el de siempre (las variables de :root). Cada tema redefine solo las variables;
   los paneles sobre el globo se quedan oscuros en todos porque van sobre el espacio. */
:root[data-theme="claro"] {
  color-scheme: light;
  --ground: #f3f4f6; --surface: #ffffff; --raised: #e6e8ec; --night: #e9ebef;
  --border: #e1e4e8; --rule: #eceef1; --control: #c3c8d0;
  --text: #111418; --muted: #4a5160; --faint: #646b78; --nav: #4a5160;
  --accent: #c27a00; --positive: #2f855a; --negative: #c53030; --on-accent: #ffffff;
  --pill-neutral-bg: #eceef1; --pill-negative-bg: #fde8e8;
  --chip: #f0f2f5; --chip-2: #e5e8ec; --line: #d4d8de; --surface-2: #f7f8fa; --sunk: #f0f2f5;
  --inverse-hover: #2b3038; --map-space: #05070d;
}
:root[data-theme="vivo"] {
  color-scheme: dark;
  --ground: #150a2b; --surface: #22133f; --raised: #3a2366; --night: #1c0f36;
  --border: #2d1a52; --rule: #2a174d; --control: #5c3d94;
  --text: #ffffff; --muted: #d4c6f5; --faint: #ad9adf; --nav: #d4c6f5;
  --accent: #ff4f9a; --positive: #3fe0a0; --negative: #ff6b6b; --on-accent: #ffffff;
  --pill-neutral-bg: #33205c;
  --chip: #2b1850; --chip-2: #3a2366; --line: #4a2f7f; --surface-2: #1d1036; --sunk: #12082a;
  --inverse-hover: #ffe0ee; --map-space: #0b0418;
}
:root[data-theme="oceano"] {
  color-scheme: dark;
  --ground: #04101d; --surface: #0b1c31; --raised: #16304f; --night: #081627;
  --border: #12263f; --rule: #10233a; --control: #2d4d74;
  --text: #eaf4ff; --muted: #a9c3df; --faint: #86a3c4; --nav: #a9c3df;
  --accent: #38bdf8; --positive: #34d399; --negative: #f87171; --on-accent: #03121f;
  --pill-neutral-bg: #16304f;
  --chip: #0f2440; --chip-2: #183456; --line: #23466f; --surface-2: #081a2e; --sunk: #030d19;
  --inverse-hover: #cfeaff; --map-space: #020814;
}
:root[data-theme="bosque"] {
  color-scheme: dark;
  --ground: #07110b; --surface: #0e1d14; --raised: #1b3324; --night: #0b1810;
  --border: #15291c; --rule: #13261a; --control: #335a40;
  --text: #eefaf1; --muted: #b3cfbc; --faint: #8daa97; --nav: #b3cfbc;
  --accent: #a3e635; --positive: #a3e635; --negative: #fb7185; --on-accent: #0f1f00;
  --pill-neutral-bg: #1b3324;
  --chip: #12261a; --chip-2: #1c3626; --line: #284a35; --surface-2: #0b1810; --sunk: #050d08;
  --inverse-hover: #e4ffd0; --map-space: #020604;
}
/* El monograma de respaldo de los logos, claro en el tema claro */
:root[data-theme="claro"] .logo[style*="--h"] { background: hsl(var(--h) 70% 92%); color: hsl(var(--h) 55% 32%); }
:root[data-theme="claro"] .logo img { box-shadow: inset 0 0 0 1px var(--border); }
:root[data-theme="claro"] .g-pos.p1, :root[data-theme="claro"] .g-pos.p2, :root[data-theme="claro"] .g-pos.p3 { box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }

/* ---------- Selector de tema ---------- */
.theme-pick { position: relative; }
.theme-btn {
  width: 36px; height: 32px; border-radius: 999px; border: 0; background: var(--surface); color: var(--muted);
  display: grid; place-items: center; cursor: pointer; transition: color 160ms ease, background-color 160ms ease, transform 160ms var(--ease-out);
}
.theme-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.theme-btn:active { transform: scale(0.94); }
.theme-btn[aria-expanded="true"], .theme-btn:hover { color: var(--text); }
.theme-menu {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 30; width: 250px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 8px;
  box-shadow: 0 18px 48px rgba(0,0,0,.45);
  transform-origin: top right; opacity: 0; transform: scale(0.96) translateY(-4px); pointer-events: none;
  transition: opacity 180ms var(--ease-out), transform 180ms var(--ease-out);
}
.theme-menu.open { opacity: 1; transform: none; pointer-events: auto; }
.theme-menu p { margin: 4px 8px 8px; color: var(--faint); font-size: var(--fs-small); }
.theme-opt {
  width: 100%; display: flex; align-items: center; gap: 12px; padding: 8px; border: 0; border-radius: 12px;
  background: none; color: var(--text); font: inherit; text-align: left; cursor: pointer;
  transition: background-color 160ms ease;
}
.theme-opt:hover { background: var(--chip); }
.theme-opt[aria-checked="true"] { background: var(--chip-2); }
.theme-swatch {
  width: 46px; height: 32px; border-radius: 9px; flex: none; position: relative; overflow: hidden;
  background: var(--sw-ground); box-shadow: inset 0 0 0 1px rgba(127,127,127,.25);
}
.theme-swatch::before { content: ""; position: absolute; left: 6px; top: 6px; width: 22px; height: 20px; border-radius: 5px; background: var(--sw-surface); }
.theme-swatch::after { content: ""; position: absolute; right: 6px; bottom: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--sw-accent); }
.theme-opt .tn { flex: 1; font-weight: 500; }
.theme-opt .tc { width: 18px; height: 18px; color: var(--accent); opacity: 0; transition: opacity 160ms ease; }
.theme-opt[aria-checked="true"] .tc { opacity: 1; }
@media (max-width: 860px) {
  .theme-menu { position: fixed; left: 12px; right: 12px; top: 64px; width: auto; transform-origin: top center; }
}
@media (prefers-reduced-motion: reduce) { .theme-menu { transition: opacity 120ms ease; transform: none; } }

/* La leyenda va sobre el globo (siempre oscuro): texto claro en todos los temas */
.map-legend { color: #c9d2e3; }
.map .maplibregl-ctrl-group { background: rgba(2,6,23,.78); }
.map .maplibregl-ctrl-group button + button { border-top-color: rgba(255,255,255,.08); }
.map .maplibregl-ctrl-group button:hover { background: rgba(255,255,255,.08); }

/* ---------- Ambientes en vivo ---------- */
.ni-amb { background: color-mix(in srgb, #38bdf8 18%, transparent); color: #38bdf8; }
.btn-primary svg { width: 18px; height: 18px; }

/* tipos de ambiente como pastillas */
.amb-moods { border-bottom: 0; gap: 8px; margin-bottom: 18px; }
.amb-moods .tab {
  height: 34px; padding: 0 14px; border-radius: 999px; background: var(--surface); color: var(--muted);
  transition: background-color 180ms ease, color 180ms ease;
}
.amb-moods .tab[aria-selected="true"] { background: var(--text); color: var(--ground); }
.amb-moods .tab[aria-selected="true"]::after { display: none; }

.amb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--gap); }
.amb-card {
  display: flex; flex-direction: column; gap: 10px; padding: 0; border: 0; background: none; color: var(--text);
  text-align: left; cursor: pointer; font: inherit;
}
.amb-thumb { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: var(--map-space); }
.amb-thumb img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); transition: transform 600ms var(--ease-out), filter 300ms ease; }
@media (hover: hover) and (pointer: fine) {
  .amb-card:hover .amb-thumb img { transform: scale(1.08); }
}
.amb-card:active .amb-thumb { transform: scale(0.98); }
.amb-thumb { transition: transform 160ms var(--ease-out); }
.amb-live {
  position: absolute; left: 10px; top: 10px; display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 9px; border-radius: 999px; background: rgba(0,0,0,.62); color: #fff; font-size: 11px; font-weight: 600; letter-spacing: .04em;
}
.amb-live i { width: 7px; height: 7px; border-radius: 50%; background: #ef4444; animation: live-dot 1.4s ease-in-out infinite; }
@keyframes live-dot { 50% { opacity: .3; } }
.amb-clock {
  position: absolute; right: 10px; bottom: 10px; padding: 3px 9px; border-radius: 999px;
  background: rgba(0,0,0,.62); color: #fff; font-size: 13px; font-weight: 600;
}
.amb-meta { display: flex; flex-direction: column; gap: 2px; padding: 0 2px; }
.amb-meta b { font-size: 16px; font-weight: 600; }
.amb-meta span { color: var(--muted); font-size: 13px; }

/* Escenario a pantalla completa */
body.amb-open { overflow: hidden; }
.amb-stage { position: fixed; inset: 0; z-index: 200; background: #000; color: #fff; overflow: hidden; }
.amb-stage[hidden] { display: none; }
.amb-video { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
/* la cámara (16:9) cubre toda la pantalla, recortando lo que sobre */
.amb-video iframe {
  position: absolute; top: 50%; left: 50%; border: 0;
  width: max(100vw, 177.78vh); height: max(100vh, 56.25vw);
  transform: translate(-50%, -50%) scale(1.02);
}
.amb-veil { position: absolute; inset: 0; background: #000; opacity: 0; transition: opacity 600ms ease; pointer-events: none; }
.amb-veil.on { opacity: 1; transition-duration: 300ms; }
.amb-hud { position: absolute; inset: 0; display: flex; flex-direction: column; transition: opacity 500ms ease; }
.amb-hud .amb-bottom { margin-top: auto; }
/* velo neutro solo arriba y abajo, para leer el texto sobre la imagen */
.amb-hud::before, .amb-hud::after { content: ""; position: absolute; left: 0; right: 0; pointer-events: none; }
.amb-hud::before { top: 0; height: 140px; background: linear-gradient(rgba(0,0,0,.55), transparent); }
.amb-hud::after { bottom: 0; height: 55%; background: linear-gradient(transparent, rgba(0,0,0,.7)); }
.amb-top, .amb-bottom, .amb-credit { position: relative; z-index: 1; }
.amb-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 22px 28px; }
.amb-brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; }
.amb-brand img { border-radius: 8px; }
.amb-brand .amb-live { position: static; }
.amb-tools { display: flex; gap: 8px; }
.amb-btn {
  height: 42px; min-width: 42px; padding: 0 12px; border-radius: 999px; border: 0; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: rgba(255,255,255,.14); color: #fff; font: inherit; font-size: 14px; font-weight: 500; cursor: pointer;
  backdrop-filter: none; transition: background-color 160ms ease, transform 160ms var(--ease-out);
}
.amb-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.amb-btn:hover { background: rgba(255,255,255,.26); }
.amb-btn:active { transform: scale(0.94); }
.amb-btn[aria-pressed="true"] { background: #fff; color: #000; }
.amb-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding: 0 28px 18px; }
.amb-kicker { margin: 0 0 4px; font-size: 15px; color: rgba(255,255,255,.8); }
.amb-city { margin: 0; font-size: clamp(36px, 6vw, 84px); line-height: 1; font-weight: 600; letter-spacing: -0.02em; text-shadow: 0 2px 18px rgba(0,0,0,.4); }
.amb-time { margin: 6px 0 0; font-size: clamp(28px, 4vw, 56px); font-weight: 500; line-height: 1.1; color: rgba(255,255,255,.92); }
.amb-wx { margin: 8px 0 0; display: flex; align-items: center; gap: 8px; font-size: 16px; color: rgba(255,255,255,.88); }
.amb-wx svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.amb-wx .i-day, .amb-wx .w-sunpart { color: #ffc94a; stroke: #ffc94a; }
.amb-radio {
  display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 12px; border-radius: 20px;
  background: rgba(0,0,0,.55); max-width: 520px;
}
.amb-radio .logo { width: 52px; height: 52px; border-radius: 12px; }
.amb-radio-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.amb-radio-text b { font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.amb-radio-text > span:last-child { font-size: 13px; color: rgba(255,255,255,.75); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.amb-onair { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: rgba(255,255,255,.7); }
.amb-onair.on { color: var(--accent); }
.amb-round { width: 42px; padding: 0; }
.amb-swap span { white-space: nowrap; }
.amb-credit { margin: 0; padding: 0 28px 14px; font-size: 11px; color: rgba(255,255,255,.55); }
/* sin actividad: se esconden los controles y el cursor; queda la imagen */
.amb-stage.idle { cursor: none; }
.amb-stage.idle .amb-tools, .amb-stage.idle .amb-radio button, .amb-stage.idle .amb-credit { opacity: 0; pointer-events: none; }
.amb-tools, .amb-radio button, .amb-credit { transition: opacity 500ms ease; }

@media (prefers-reduced-motion: reduce) {
  .amb-live i { animation: none; }
  .amb-thumb img { transition: none; }
}
@media (max-width: 860px) {
  .amb-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .amb-meta b { font-size: 14px; }
  .amb-top { padding: 14px 14px; }
  .amb-brand { font-size: 0; }
  .amb-tvbtn span, .amb-swap span { display: none; }
  .amb-btn { height: 40px; min-width: 40px; padding: 0 10px; }
  .amb-bottom { flex-direction: column; align-items: stretch; padding: 0 14px 14px; }
  .amb-radio { max-width: none; }
  .amb-credit { padding: 0 14px 10px; }
}
@media (max-width: 480px) { .amb-grid { grid-template-columns: 1fr; } }

@media (max-width: 860px) {
  .bottom-nav { grid-template-columns: repeat(7, 1fr); }
  .bottom-nav a { font-size: 9.5px; gap: 3px; }
}

/* Barra de la radio del ambiente: anterior · reproducir · siguiente cambian cámara y emisora juntas */
.amb-radio { max-width: 680px; }
.amb-ctrls { display: flex; align-items: center; gap: 8px; flex: none; }
.amb-btn svg.skipico { fill: currentColor; stroke: currentColor; stroke-width: 1.2; stroke-linejoin: round; }
.amb-main { width: 48px; height: 48px; background: #fff; color: #000; }
.amb-main:hover { background: #e6e6e6; }
.amb-main svg { fill: currentColor; stroke: none; }
@media (max-width: 860px) {
  .amb-radio { flex-wrap: wrap; row-gap: 10px; }
  .amb-radio .logo { width: 44px; height: 44px; }
  .amb-radio-text { flex: 1 1 calc(100% - 60px); }
  .amb-ctrls { flex: 1 1 100%; justify-content: space-between; }
  .amb-ctrls .amb-btn { height: 44px; min-width: 44px; }
  .amb-main { width: 52px; height: 52px; }
}
.amb-place { min-width: 0; }
.amb-radio { min-width: 0; flex: 0 1 680px; }
@media (max-width: 1180px) {
  .amb-bottom { flex-direction: column; align-items: stretch; }
  .amb-radio { flex: none; max-width: none; }
}

/* ---------- Muros de graffiti ---------- */
.ni-wall { background: color-mix(in srgb, #f472b6 18%, transparent); color: #f472b6; }
.flag { display: inline-block; vertical-align: -2px; border-radius: 2px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,0,0,.15); }

/* Galería */
.wall-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--gap); }
.wall-card {
  display: flex; align-items: center; gap: 14px; padding: 14px; border: 0; border-radius: 18px; text-align: left;
  background: var(--surface); color: var(--text); font: inherit; cursor: pointer;
  transition: background-color 180ms ease, transform 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) { .wall-card:hover { background: var(--chip-2); } }
.wall-card:active { transform: scale(0.98); }
.wall-card .logo { width: 52px; height: 52px; border-radius: 14px; }
.wall-card-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.wall-card-text b { font-size: 16px; }
.wall-card-text > span { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.wall-here .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); display: inline-block; }
.wall-here .dot.on { background: #22c55e; box-shadow: 0 0 0 3px color-mix(in srgb, #22c55e 25%, transparent); animation: live-dot 1.6s ease-in-out infinite; }
.wall-here .flag { margin-left: 2px; }

/* Muro abierto */
.wall-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.wall-back { text-decoration: none; color: var(--muted); }
.wall-title { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 220px; }
.wall-title .logo { width: 48px; height: 48px; border-radius: 12px; }
.wall-title h2 { font-size: 20px; }
.wall-title p { margin: 2px 0 0; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.wall-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: var(--gap); align-items: start; }

/* La pared: ladrillo claro, para que la pintura destaque como en la calle */
.wall-board {
  position: relative; aspect-ratio: 16 / 10; border-radius: 16px; overflow: hidden; touch-action: none;
  background-color: #d8d2c7;
  background-image:
    linear-gradient(rgba(0,0,0,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,.07) 1px, transparent 1px);
  background-size: 100% 6.25%, 12.5% 12.5%, 12.5% 12.5%;
  background-position: 0 0, 0 0, 6.25% 6.25%;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
}
.wall-board[data-tool="pen"], .wall-board[data-tool="erase"] { cursor: crosshair; }
.wall-board[data-tool="note"], .wall-board[data-tool="sticker"] { cursor: copy; }
.wall-board canvas { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; }
.wall-layer { position: absolute; inset: 0; pointer-events: none; }
.wall-note {
  position: absolute; transform: translate(-50%, -50%) rotate(var(--r)); max-width: 30%; min-width: 90px;
  padding: 8px 10px 10px; background: var(--c); color: #1f2937; font-size: 13px; line-height: 17px; font-weight: 500;
  border-radius: 2px 2px 10px 2px; box-shadow: 0 6px 14px rgba(0,0,0,.25); overflow-wrap: anywhere;
}
.wall-note .flag { display: block; margin-bottom: 4px; }
.wall-sticker { position: absolute; transform: translate(-50%, -50%) rotate(var(--r)); font-size: clamp(22px, 3.2vw, 38px); line-height: 1; filter: drop-shadow(0 3px 4px rgba(0,0,0,.3)); }
.wall-sticker .flag { position: absolute; right: -8px; bottom: -4px; }
.wall-note-form {
  position: absolute; z-index: 3; width: min(240px, 70%); display: flex; flex-direction: column; gap: 6px;
  background: var(--surface); padding: 8px; border-radius: 12px; box-shadow: 0 12px 30px rgba(0,0,0,.35);
  animation: label-in 200ms var(--ease-out);
}
.wall-note-form textarea { border: 0; border-radius: 6px; padding: 8px; font: inherit; font-size: 14px; color: #1f2937; resize: none; }
.wall-note-form div { display: flex; justify-content: flex-end; gap: 10px; align-items: center; }
.wall-status { margin: 10px 2px 0; color: var(--faint); font-size: 13px; }
.wall-status.warn { color: var(--negative); }

/* Panel lateral */
.wall-side { display: flex; flex-direction: column; gap: 12px; }
.wall-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.wall-tool {
  display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 12px; border: 0; border-radius: 12px;
  background: var(--surface); color: var(--muted); font: inherit; font-weight: 500; cursor: pointer;
  transition: background-color 160ms ease, color 160ms ease, transform 140ms var(--ease-out);
}
.wall-tool svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.wall-tool[aria-checked="true"] { background: var(--accent); color: var(--on-accent); }
.wall-tool:active { transform: scale(0.96); }
.wall-palette { display: flex; flex-wrap: wrap; gap: 6px; background: var(--surface); padding: 10px; border-radius: 14px; min-height: 0; }
.wall-palette:empty { display: none; }
.sw-btn { width: 26px; height: 26px; border-radius: 8px; border: 0; background: var(--c); cursor: pointer; box-shadow: inset 0 0 0 1px rgba(127,127,127,.35); transition: transform 140ms var(--ease-out); }
.sw-btn[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--text); transform: scale(1.08); }
.sw-note { width: 32px; border-radius: 4px; }
.st-btn { width: 36px; height: 36px; border: 0; border-radius: 10px; background: none; font-size: 22px; cursor: pointer; transition: background-color 140ms ease, transform 140ms var(--ease-out); }
.st-btn:hover { background: var(--chip-2); }
.st-btn[aria-pressed="true"] { background: var(--chip-2); box-shadow: inset 0 0 0 2px var(--accent); transform: scale(1.06); }
.wall-hint { color: var(--faint); font-size: 12px; margin: -2px 2px 0; }
.wall-box { background: var(--surface); border-radius: 14px; padding: 12px; }
.wall-box-title { margin: 0 0 8px; font-size: 12px; color: var(--faint); }
.wall-flags { display: flex; flex-wrap: wrap; gap: 8px; }
.wf { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px 4px 5px; border-radius: 999px; background: var(--chip); font-size: 13px; }
.wall-me { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.wall-me select { flex: 1; min-width: 120px; height: 32px; border-radius: 999px; border: 1px solid var(--control); background: var(--surface-2); color: var(--text); padding: 0 10px; font: inherit; font-size: 13px; }
.wall-reset { margin: 0; color: var(--faint); font-size: 12px; text-align: center; }

@media (prefers-reduced-motion: reduce) { .wall-here .dot.on { animation: none; } }
@media (max-width: 1100px) {
  .wall-layout { grid-template-columns: 1fr; }
  .wall-side { display: grid; grid-template-columns: 1fr 1fr; }
  .wall-tools, .wall-palette, .wall-hint { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .wall-side { grid-template-columns: 1fr; }
  .wall-head .btn-primary { width: 100%; height: 44px; justify-content: center; }
  .wall-tools { grid-template-columns: repeat(4, 1fr); }
  .wall-tool { flex-direction: column; justify-content: center; gap: 2px; height: 54px; font-size: 11px; padding: 0 4px; }
  .wall-note { font-size: 11px; line-height: 14px; min-width: 70px; padding: 5px 7px 7px; }
  /* barra inferior con 8 secciones: se desliza de lado */
  .bottom-nav { display: flex; overflow-x: auto; scrollbar-width: none; }
  .bottom-nav::-webkit-scrollbar { display: none; }
  .bottom-nav a { flex: 0 0 auto; min-width: 64px; padding: 0 6px; font-size: 10px; }
}

/* ---------- Muros: bienvenida y recorrido de herramientas ---------- */
.rm-badge { display: inline-flex; align-items: center; gap: 5px; margin-bottom: 4px; font-size: 11px; font-weight: 600; color: #374151; }
.rm-badge img { border-radius: 4px; }
.wall-board-wrap { position: relative; }
.wall-demo { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.wall-coach {
  position: absolute; left: 14px; bottom: 44px; z-index: 4; width: min(360px, calc(100% - 28px));
  background: var(--surface); color: var(--text); border-radius: 16px; padding: 14px 16px;
  box-shadow: 0 16px 40px rgba(0,0,0,.4); border: 1px solid var(--border);
}
.wall-coach-step { margin: 0; font-size: 12px; color: var(--accent); font-weight: 600; }
.wall-coach-title { margin: 2px 0 4px; font-size: 17px; font-weight: 600; }
.wall-coach-text { margin: 0; color: var(--muted); font-size: 14px; line-height: 20px; }
.wall-coach-actions { display: flex; justify-content: flex-end; align-items: center; gap: 14px; margin-top: 12px; }
.wall-coach-actions .btn-text { color: var(--muted); text-decoration: none; }

/* la herramienta que se está explicando late */
.tour-focus { position: relative; animation: tour-ring 1.4s ease-out infinite; }
@keyframes tour-ring { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 70%, transparent); } 100% { box-shadow: 0 0 0 12px transparent; } }

/* Pincel: un trazo que se dibuja; Borrador: el mismo trazo que se borra */
.demo-stroke { position: absolute; left: 14%; top: 34%; width: 56%; height: 28%; }
.demo-stroke svg { width: 100%; height: 100%; overflow: visible; }
.demo-stroke path { fill: none; stroke: var(--c); stroke-width: 12; stroke-linecap: square; stroke-dasharray: 520; vector-effect: non-scaling-stroke; }
.demo-stroke.draw path { animation: demo-draw 2.4s ease-in-out infinite; }
.demo-stroke.erase path { animation: demo-erase 2.4s ease-in-out infinite; }
@keyframes demo-draw { 0% { stroke-dashoffset: 520; } 60%, 85% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes demo-erase { 0%, 15% { stroke-dashoffset: 0; } 75%, 100% { stroke-dashoffset: -520; } }
.demo-hand, .demo-eraser { position: absolute; top: 46%; left: 14%; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.4), 0 0 0 4px rgba(255,255,255,.35); }
.demo-hand.draw { animation: demo-move 2.4s ease-in-out infinite; }
.demo-eraser { border-radius: 5px; width: 26px; height: 18px; background: #f9a8d4; animation: demo-move 2.4s ease-in-out infinite; animation-delay: .36s; }
@keyframes demo-move { 0% { left: 14%; top: 56%; } 20% { top: 34%; } 40% { top: 52%; } 60%, 100% { left: 70%; top: 44%; } }

/* Nota y stickers que aparecen */
.demo-note {
  position: absolute; left: 58%; top: 52%; transform: translate(-50%, -50%) rotate(-4deg); padding: 8px 10px 10px; min-width: 110px;
  background: var(--c); color: #1f2937; font-size: 13px; font-weight: 500; border-radius: 2px 2px 10px 2px; box-shadow: 0 6px 14px rgba(0,0,0,.25);
  animation: demo-pop 2.6s cubic-bezier(0.23, 1, 0.32, 1) infinite;
}
.demo-note .flag { display: block; margin-bottom: 4px; }
@keyframes demo-pop { 0%, 20% { opacity: 0; transform: translate(-50%, -50%) rotate(-4deg) scale(.6); } 35%, 85% { opacity: 1; transform: translate(-50%, -50%) rotate(-4deg) scale(1); } 100% { opacity: 0; } }
.demo-tap { position: absolute; width: 18px; height: 18px; margin: -9px; border-radius: 50%; border: 3px solid #fff; animation: demo-tap 2.6s ease-out infinite; }
@keyframes demo-tap { 0% { opacity: 1; transform: scale(.4); } 25% { opacity: 0; transform: scale(2.2); } 100% { opacity: 0; } }
.demo-sticker { position: absolute; font-size: clamp(26px, 3.6vw, 42px); transform: translate(-50%, -50%); animation: demo-stick 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite; filter: drop-shadow(0 3px 4px rgba(0,0,0,.3)); }
.demo-sticker.d2 { animation-delay: .3s; }
.demo-sticker.d3 { animation-delay: .6s; }
@keyframes demo-stick { 0% { opacity: 0; transform: translate(-50%, -80%) scale(.4) rotate(-20deg); } 25%, 80% { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(0); } 100% { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .tour-focus { animation: none; box-shadow: 0 0 0 2px var(--accent); }
  .demo-stroke path { animation: none !important; stroke-dashoffset: 0; }
  .demo-hand, .demo-eraser, .demo-tap { display: none; }
  .demo-note, .demo-sticker { animation: none; }
}
@media (max-width: 860px) {
  .wall-coach { position: static; width: auto; margin-top: 10px; }
}

/* El recorrido va debajo del muro, para no tapar lo que hay pintado */
.wall-coach { position: static; width: auto; margin-top: 12px; box-shadow: none; animation: none; }
.wall-note .rm-badge { display: flex; }

/* ---------- Muros: lienzo grande con zoom y varias paredes ---------- */
.wall-viewport { position: relative; }
/* el visor: muestra el muro entero sin zoom y se desplaza cuando se acerca */
.wall-board {
  overflow: auto; background: var(--sunk); background-image: none; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
  scrollbar-width: thin; scrollbar-color: var(--line) transparent; overscroll-behavior: contain;
}
.wall-stage {
  --z: 1;
  position: relative; width: calc(100% * var(--z)); aspect-ratio: 16 / 10; container-type: inline-size;
  background-color: #d8d2c7;
  background-image:
    linear-gradient(rgba(0,0,0,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,.07) 1px, transparent 1px);
  background-size: 100% 6.25%, 12.5% 12.5%, 12.5% 12.5%;
  background-position: 0 0, 0 0, 6.25% 6.25%;
}
.wall-board[data-tool="move"] { cursor: grab; touch-action: pan-x pan-y; }
.wall-board.panning { cursor: grabbing; }
/* notas y stickers escalan con el muro (unidades del escenario) */
.wall-note { font-size: max(10px, 1.15cqw); line-height: 1.3; padding: .5cqw .7cqw .7cqw; min-width: 8cqw; max-width: 26%; }
.wall-sticker { font-size: max(18px, 3cqw); }
.demo-sticker { font-size: max(22px, 3.6cqw); }

.wall-zoom {
  position: absolute; right: 10px; top: 10px; z-index: 5; display: flex; align-items: center; gap: 2px; padding: 3px;
  border-radius: 999px; background: rgba(0,0,0,.66); color: #fff;
}
.wall-zoom button {
  width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: #fff; font: inherit; font-size: 18px; line-height: 1;
  display: grid; place-items: center; cursor: pointer; transition: background-color 140ms ease, transform 140ms var(--ease-out);
}
.wall-zoom button:hover { background: rgba(255,255,255,.18); }
.wall-zoom button:active { transform: scale(0.9); }
.wall-zoom svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wall-zoom span { min-width: 44px; text-align: center; font-size: 12px; font-weight: 600; }

.wall-pages { display: flex; gap: 6px; margin-bottom: 10px; overflow-x: auto; scrollbar-width: none; }
.wall-pages::-webkit-scrollbar { display: none; }
.wall-page {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border: 0; border-radius: 999px; flex: none;
  background: var(--surface); color: var(--muted); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer;
  transition: background-color 180ms ease, color 180ms ease, transform 140ms var(--ease-out);
}
.wall-page:active { transform: scale(0.96); }
.wall-page[aria-selected="true"] { background: var(--text); color: var(--ground); }
.wp-tag { font-size: 11px; opacity: .7; }
.wp-here { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-variant-numeric: tabular-nums; }
.wp-here i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .35; }
.wp-here.on i { background: #22c55e; opacity: 1; }
.wall-tools { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 860px) {
  .wall-tools { grid-template-columns: repeat(5, 1fr); }
  .wall-zoom { right: 6px; top: 6px; }
  .wall-zoom button { width: 36px; height: 36px; }
}

/* ---------- Micrófono abierto ---------- */
.ni-mic { background: color-mix(in srgb, #f43f5e 18%, transparent); color: #f43f5e; }
/* Panel flotante sobre el reproductor: aparece al escuchar una de las 20 */
.mic-dock {
  position: absolute; right: var(--gutter); bottom: calc(100% + 10px); width: 340px; z-index: 11;
  display: flex; flex-direction: column; gap: 10px; padding: 12px;
  border-radius: 18px; background: var(--surface); color: var(--text);
  border: 1px solid var(--border); box-shadow: 0 14px 40px rgba(0,0,0,.28);
}
.mic-dock[hidden] { display: none; }
.mic-dock[data-phase="rec"] { box-shadow: 0 0 0 2px #ef4444, 0 14px 40px rgba(0,0,0,.28); }
.mic-dock[data-phase="play"] { box-shadow: 0 0 0 2px var(--accent), 0 14px 40px rgba(0,0,0,.28); }
.mic-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mic-ico { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; background: color-mix(in srgb, #f43f5e 18%, transparent); color: #f43f5e; }
.mic-ico svg, .mic-btn svg, .mic-mini svg, .mic-empty > svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mic-title, .mic-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.mic-title b, .mic-who b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mic-title span, .mic-who span { font-size: 12px; color: var(--muted); }
.mic-mini {
  width: 34px; height: 34px; border-radius: 50%; border: 0; flex: none; display: grid; place-items: center;
  background: var(--chip); color: var(--text); cursor: pointer; transition: background-color 140ms ease, transform 140ms var(--ease-out);
}
.mic-mini:hover { background: var(--chip-2); }
.mic-mini:active, .mic-btn:active, .mic-replay:active { transform: scale(0.94); }
.mic-mini[aria-pressed="true"] { color: var(--muted); }
.mic-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 14px; border: 0; border-radius: 999px;
  background: var(--text); color: var(--ground); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: background-color 140ms ease, transform 140ms var(--ease-out), opacity 140ms ease;
}
.mic-btn.ask { flex: 1; background: #f43f5e; color: #fff; height: 42px; }
.mic-btn.ask:hover { background: #e11d48; }
.mic-btn:disabled { opacity: .5; cursor: default; }
.mic-btn.ghost { background: var(--chip); color: var(--text); font-weight: 500; height: 34px; padding: 0 12px; font-size: 13px; }
.mic-btn.ghost:hover { background: var(--chip-2); }
.mic-acts { flex-wrap: wrap; gap: 6px; }
.mic-q { font-size: 12px; color: var(--muted); white-space: nowrap; }
.mic-other { font-size: 13px; color: var(--muted); }
.mic-wait { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; background: var(--chip); }
.mic-air { display: flex; flex-direction: column; gap: 8px; padding: 10px; border-radius: 12px; background: var(--chip); }
.mic-air.me { background: color-mix(in srgb, #ef4444 14%, var(--surface)); }
.mic-live { flex: none; padding: 4px 8px; border-radius: 6px; background: #ef4444; color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; animation: live-dot 1.4s ease-in-out infinite; }
.mic-count { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: #ef4444; color: #fff; font-size: 20px; font-weight: 700; animation: mic-pop 1s var(--ease-out) infinite; }
@keyframes mic-pop { 0% { transform: scale(1.18); } 30% { transform: scale(1); } }
/* barras de voz: las mueve el nivel real del audio */
.mic-bars { display: inline-flex; align-items: center; gap: 3px; height: 26px; flex: none; }
.mic-bars i { width: 4px; height: 100%; border-radius: 2px; background: currentColor; transform: scaleY(.2); transform-origin: center; transition: transform 60ms linear; }
.mic-air.other .mic-bars { color: var(--accent); }
.mic-air.me .mic-bars { color: #ef4444; }
.mic-bars.idle { height: 16px; color: var(--muted); }
.mic-bars.idle i { animation: mic-idle 900ms ease-in-out infinite alternate; }
.mic-bars.idle i:nth-child(2) { animation-delay: -300ms; }
.mic-bars.idle i:nth-child(3) { animation-delay: -600ms; }
.mic-bars.idle i:nth-child(4) { animation-delay: -150ms; }
.mic-bars.idle i:nth-child(5) { animation-delay: -450ms; }
@keyframes mic-idle { to { transform: scaleY(1); } }
/* tiempo restante: una barra que se vacía */
.mic-left { --k: 0; position: relative; display: block; height: 4px; margin-top: 14px; border-radius: 2px; background: color-mix(in srgb, currentColor 14%, transparent); }
.mic-left::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: currentColor; transform-origin: left; transform: scaleX(calc(1 - var(--k))); }
.mic-air.other .mic-left { color: var(--accent); }
.mic-air.me .mic-left { color: #ef4444; }
.mic-left span { position: absolute; right: 0; top: -17px; font-size: 11px; color: var(--muted); }
.mic-flash { margin: 0; font-size: 13px; color: var(--muted); padding: 8px 10px; border-radius: 10px; background: var(--chip); }
.mic-flash.good { color: #16a34a; }

/* Vista */
.mic-room { margin-bottom: var(--gap); padding: 18px; border-radius: 20px; background: var(--surface); }
.mic-empty { display: flex; align-items: center; gap: 14px; }
.mic-empty > svg { width: 28px; height: 28px; color: #f43f5e; flex: none; }
.mic-empty div { display: flex; flex-direction: column; gap: 2px; }
.mic-empty span { color: var(--muted); font-size: 14px; }
.mic-room-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.mic-room-head .logo { width: 48px; height: 48px; border-radius: 12px; }
.mic-room-head h2 { font-size: 20px; }
.mic-room-head p { margin: 4px 0 0; display: flex; flex-wrap: wrap; gap: 6px; color: var(--muted); }
.mic-h2 { font-size: 18px; margin: 28px 0 12px; }
.mic-h3 { font-size: 14px; color: var(--muted); font-weight: 600; margin: 0 0 8px; }
.mic-clips { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.mic-clips li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.mic-clips li:first-child { border-top: 0; }
.mic-clip-text { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.mic-clip-text span { font-size: 12px; color: var(--muted); }
.mic-replay { width: 36px; height: 36px; border-radius: 50%; border: 0; display: grid; place-items: center; flex: none; background: var(--text); color: var(--ground); cursor: pointer; transition: transform 140ms var(--ease-out); }
.mic-replay svg { fill: currentColor; width: 16px; height: 16px; }
.mic-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.mic-steps li { display: flex; flex-direction: column; gap: 4px; padding: 16px; border-radius: 18px; background: var(--surface); }
.mic-steps .num { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: #f43f5e; color: #fff; font-weight: 700; font-size: 14px; margin-bottom: 4px; }
.mic-steps span:last-child { color: var(--muted); font-size: 14px; }
.mic-card.here { box-shadow: inset 0 0 0 2px #f43f5e; }
.mic-onair { display: inline-flex; align-items: center; gap: 4px; color: #ef4444; font-weight: 600; }
.mic-rules { margin: 20px 0 0; color: var(--muted); font-size: 13px; max-width: 70ch; }
@media (max-width: 860px) {
  .mic-dock { left: var(--gutter); right: var(--gutter); width: auto; bottom: calc(100% + 8px); padding: 10px; gap: 8px; }
  .mic-steps { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .mic-live, .mic-count, .mic-bars.idle i { animation: none; }
}

/* ---------- Dictado de beats ---------- */
.ni-beat { background: color-mix(in srgb, #22d3ee 18%, transparent); color: #22d3ee; }
.beat-menu { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: var(--gap); align-items: start; }
.beat-how, .beat-setup { padding: 20px; border-radius: 20px; background: var(--surface); }
.beat-how ol { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; counter-reset: b; }
.beat-how li { display: flex; flex-direction: column; gap: 2px; padding-left: 40px; position: relative; counter-increment: b; }
.beat-how li::before { content: counter(b); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: #22d3ee; color: #0b0b0b; font-weight: 700; font-size: 14px; }
.beat-how li span { color: var(--muted); font-size: 14px; }
/* mini demostración: notas que caen por 4 carriles */
.beat-demo { position: relative; height: 150px; border-radius: 14px; background: var(--sunk); display: grid; grid-template-columns: repeat(4, 1fr); overflow: hidden; }
.beat-demo::after { content: ""; position: absolute; left: 0; right: 0; bottom: 26px; height: 2px; background: var(--line); }
.beat-demo i { position: relative; }
.beat-demo i::before { content: ""; position: absolute; left: 50%; top: -24px; width: 22px; height: 22px; margin-left: -11px; border-radius: 50%; background: var(--c); animation: beat-fall 1s linear infinite; animation-delay: var(--d); }
.beat-demo i::after { content: ""; position: absolute; left: 50%; bottom: 16px; width: 22px; height: 22px; margin-left: -11px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--c); }
@keyframes beat-fall { to { transform: translateY(150px); } }
.beat-setup .mic-h3 { margin-top: 4px; }
.beat-setup .mic-h3 + * { margin-bottom: 18px; }
.beat-seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--chip); }
.beat-seg button { height: 36px; padding: 0 16px; border: 0; border-radius: 999px; background: none; color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; transition: background-color 160ms ease, color 160ms ease; }
.beat-seg button[aria-checked="true"] { background: var(--text); color: var(--ground); }
.beat-best { margin: -8px 0 18px; font-size: 13px; color: var(--muted); }
.beat-chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px; max-height: 300px; overflow: auto; scrollbar-width: thin; }
.beat-chip { display: flex; align-items: center; gap: 10px; padding: 8px; border: 0; border-radius: 12px; text-align: left; background: var(--chip); color: var(--text); font: inherit; cursor: pointer; transition: background-color 160ms ease, box-shadow 160ms ease; }
.beat-chip:hover { background: var(--chip-2); }
.beat-chip[aria-pressed="true"] { box-shadow: inset 0 0 0 2px #22d3ee; }
.beat-chip .logo { width: 34px; height: 34px; border-radius: 9px; flex: none; }
.beat-chip > span { display: flex; flex-direction: column; min-width: 0; }
.beat-chip b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-chip > span > span { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-play {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 28px; margin-top: 4px; border: 0; border-radius: 999px;
  background: #22d3ee; color: #0b0b0b; font: inherit; font-size: 16px; font-weight: 700; cursor: pointer; transition: transform 140ms var(--ease-out), background-color 140ms ease;
}
.beat-play:hover { background: #67e8f9; }
.beat-play:active { transform: scale(0.96); }
.beat-play svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Partida */
.beat-game { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: calc(var(--topbar) + 12px); }
.beat-hud { display: flex; align-items: center; gap: 10px 18px; flex-wrap: wrap; padding: 12px 14px; border-radius: 18px; background: var(--surface); }
.beat-station { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1 1 180px; }
.beat-station .logo { width: 38px; height: 38px; border-radius: 10px; flex: none; }
.beat-station > span { display: flex; flex-direction: column; min-width: 0; }
.beat-station b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-station > span > span { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-stat { display: flex; flex-direction: column; min-width: 64px; }
.beat-stat span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; display: inline-flex; align-items: center; gap: 5px; }
.beat-stat b { font-size: 20px; line-height: 1.2; }
.beat-tempo b { color: #22d3ee; }
#beat-dot { width: 8px; height: 8px; border-radius: 50%; background: #22d3ee; opacity: .6; display: inline-block; }
.beat-stage { position: relative; height: clamp(240px, calc(100dvh - var(--topbar, 64px) - var(--player) - 330px), 520px); border-radius: 20px; overflow: hidden; background: var(--sunk); touch-action: none; user-select: none; -webkit-user-select: none; }
.beat-stage canvas { display: block; width: 100%; height: 100%; }
.beat-status { position: absolute; left: 50%; top: 38%; transform: translate(-50%, -50%); margin: 0; max-width: 80%; padding: 10px 16px; border-radius: 12px; text-align: center; background: rgba(0,0,0,.6); color: #fff; font-size: 14px; pointer-events: none; }
.beat-status[hidden] { display: none; }
.beat-announce { position: absolute; left: 0; right: 0; top: 14%; margin: 0; text-align: center; font-size: 22px; font-weight: 700; color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,.6); opacity: 0; pointer-events: none; }
.beat-judge { position: absolute; left: 50%; bottom: 96px; margin: 0; transform: translateX(-50%); font-size: 20px; font-weight: 800; opacity: 0; pointer-events: none; white-space: nowrap; text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.beat-judge[data-g="perfect"] { color: #22d3ee; }
.beat-judge[data-g="good"] { color: #4ade80; }
.beat-judge[data-g="ok"] { color: #facc15; }
.beat-judge[data-g="break"] { color: #f43f5e; }
.beat-pads { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.beat-pad {
  position: relative; height: 76px; border: 0; border-radius: 16px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  background: color-mix(in srgb, var(--c) 22%, var(--surface)); color: var(--text); font: inherit; cursor: pointer;
  box-shadow: inset 0 -4px 0 color-mix(in srgb, var(--c) 55%, transparent); touch-action: none; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent;
}
.beat-pad b { font-size: 14px; }
.beat-pad kbd { font: inherit; font-size: 11px; color: var(--muted); padding: 1px 6px; border-radius: 5px; background: var(--chip); }
.beat-foot { display: flex; align-items: center; gap: 10px 16px; flex-wrap: wrap; font-size: 13px; }
.beat-sync { display: inline-flex; align-items: center; gap: 8px; }
.beat-sync input { width: 140px; accent-color: #22d3ee; }
.beat-sync b { min-width: 52px; font-weight: 500; }
.beat-toggle { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.beat-toggle input { accent-color: #22d3ee; }

/* Resumen */
.beat-summary { max-width: 560px; margin: 0 auto; padding: 28px; border-radius: 24px; background: var(--surface); text-align: center; }
.beat-kicker { margin: 0; color: #22d3ee; font-weight: 700; }
.beat-big { margin: 4px 0 0; font-size: 56px; font-weight: 800; line-height: 1.05; }
.beat-dl { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin: 22px 0; text-align: left; }
.beat-dl div { padding: 10px 12px; border-radius: 12px; background: var(--chip); }
.beat-dl dt { font-size: 12px; color: var(--muted); }
.beat-dl dd { margin: 2px 0 0; font-weight: 600; }
.beat-row { display: flex; justify-content: center; align-items: center; gap: 10px; flex-wrap: wrap; }
@media (max-width: 860px) {
  .beat-menu { grid-template-columns: 1fr; }
  .beat-hud { gap: 8px 14px; }
  .beat-stat { min-width: 54px; }
  .beat-stat b { font-size: 17px; }
  .beat-stage { height: clamp(220px, calc(100dvh - var(--topbar) - var(--player) - 64px - 290px), 460px); }
  .beat-pads { gap: 6px; }
  .beat-pad { height: 72px; }
  .beat-pad kbd { display: none; }
  .beat-big { font-size: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  .beat-demo i::before { animation: none; top: 40px; }
}
.beat-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.beat-top .beat-play { margin-top: 0; }
/* con el panel del micrófono abierto, el final de cada vista queda por encima de él */
body:has(.mic-dock:not([hidden])) .canvas { padding-bottom: calc(var(--player) + 180px); }
@media (max-width: 860px) { body:has(.mic-dock:not([hidden])) .canvas { padding-bottom: calc(var(--player) + 64px + 180px); } }

/* Tabla pública del Dictado de beats */
.beat-board-card { margin-top: var(--gap); padding: 20px; border-radius: 20px; background: var(--surface); }
.beat-summary + .beat-board-card { max-width: 760px; margin-left: auto; margin-right: auto; }
.beat-board-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.beat-board-head h2 { font-size: 18px; }
.beat-seg button[aria-selected="true"] { background: var(--text); color: var(--ground); }
.beat-board-card > .mic-flash { margin-bottom: 12px; }
.beat-send { padding: 14px; margin-bottom: 16px; border-radius: 14px; background: color-mix(in srgb, #22d3ee 10%, var(--surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, #22d3ee 35%, transparent); }
.beat-send p { margin: 0; }
.beat-send-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0 8px; }
.beat-send input { flex: 1 1 180px; height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 16px; }
.beat-send .beat-play { margin-top: 0; }
.beat-note { font-size: 13px; }
.beat-note.err { color: #f43f5e; }
.beat-facts { list-style: none; margin: 0 0 16px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
.beat-facts li { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 12px; background: var(--chip); min-width: 0; }
.beat-facts span { font-size: 12px; color: var(--muted); }
.beat-facts b { font-size: 18px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-facts em { font-style: normal; font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.beat-facts em b { font-size: 12px; font-weight: 600; color: var(--text); }
.beat-board-wrap { overflow-x: auto; }
.beat-board { width: 100%; border-collapse: collapse; font-size: 14px; }
.beat-board th { text-align: left; font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding: 0 8px 8px; }
.beat-board td { padding: 9px 8px; border-top: 1px solid var(--line); vertical-align: middle; }
.beat-board tr.me td { background: color-mix(in srgb, #22d3ee 12%, transparent); }
.bb-rank { width: 36px; color: var(--muted); font-weight: 700; }
.bb-rank.p1 { color: #facc15; } .bb-rank.p2 { color: #cbd5e1; } .bb-rank.p3 { color: #f59e0b; }
.bb-who { min-width: 0; }
.bb-name { display: flex; align-items: center; gap: 6px; }
.bb-sub { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.bb-perfect { font-size: 17px; font-weight: 800; color: #22d3ee; }
.beat-board-foot { margin-top: 10px; font-size: 13px; }
@media (max-width: 860px) {
  .bb-hide { display: none; }
  .beat-board-card { padding: 16px; }
  .beat-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Privacidad, reglas y contacto ---------- */
.side-legal { display: block; margin: 10px 12px 4px; font-size: 12px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.side-legal:hover { color: var(--text); }
.site-foot { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 48px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.site-foot a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.site-foot a:hover { color: var(--text); }
#view-mapa:not([hidden]) ~ .site-foot, #view-ritmo:not([hidden]) ~ .site-foot { display: none; }
.lg-nav { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 calc(var(--gutter) * -1) var(--gap); padding: 8px var(--gutter); position: sticky; top: var(--topbar); z-index: 2; background: var(--ground); }
.lg-nav a { height: 34px; padding: 0 14px; display: inline-flex; align-items: center; border-radius: 999px; background: var(--surface); color: var(--text); font-size: 14px; text-decoration: none; box-shadow: 0 2px 10px rgba(0,0,0,.15); }
.lg-nav a:hover { background: var(--chip-2); }
.lg-doc { max-width: 760px; padding: 22px; margin-bottom: var(--gap); border-radius: 20px; background: var(--surface); line-height: 1.6; scroll-margin-top: calc(var(--topbar) + 60px); }
.lg-doc h2 { font-size: 20px; margin: 0 0 10px; scroll-margin-top: calc(var(--topbar) + 60px); }
.lg-doc h3 { font-size: 15px; margin: 18px 0 4px; }
.lg-doc p { margin: 0 0 8px; color: var(--text); }
.lg-doc ul { margin: 6px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
.lg-doc li { color: var(--text); }
.lg-form { display: flex; flex-direction: column; gap: 14px; margin-top: 14px; }
.lg-form label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.lg-form select, .lg-form textarea, .lg-form input { font: inherit; font-size: 16px; font-weight: 400; color: var(--text); background: var(--ground); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.lg-form select { height: 46px; }
.lg-form textarea { resize: vertical; min-height: 120px; }
.lg-form :focus-visible { outline: 2px solid #22d3ee; outline-offset: 1px; }
.lg-about { margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--chip); font-size: 14px; }
.lg-trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.lg-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.lg-row .beat-play { margin-top: 0; }
.lg-note { margin: 0; }
.lg-note.good { color: #16a34a; }
.lg-note.err { color: #f43f5e; }
.wall-report { display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; padding: 0; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.wall-report svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.wall-report:hover { color: var(--text); }
.mic-consent { margin: 0; font-size: 13px; line-height: 1.5; }
.mic-consent a, .mic-rules a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 860px) { .lg-doc { padding: 16px; } }

/* ---------- Canción que suena, menú "⋯" y temporizador ---------- */
.player-sub .song { min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.song-find { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; color: var(--muted); }
.song-find:hover { color: var(--text); background: var(--chip); }
.song-find svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.more-btn { position: relative; }
.more-btn .i-more { fill: currentColor; stroke: none; }
.more-btn .i-moon { display: none; }
.more-btn.sleeping { color: var(--accent); }
.more-btn.sleeping .i-more { display: none; }
.more-btn.sleeping .i-moon { display: block; fill: none; stroke: currentColor; }
.sleep-left { position: absolute; right: -2px; top: -2px; min-width: 18px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--accent); color: var(--on-accent, #000); font-size: 10px; font-weight: 700; line-height: 16px; text-align: center; }
.sleep-left:empty { display: none; }
.player-menu {
  position: absolute; left: 50%; bottom: calc(100% + 10px); z-index: 12; width: 310px; margin-left: -155px; padding: 8px;
  display: flex; flex-direction: column; gap: 4px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border);
  box-shadow: 0 14px 40px rgba(0,0,0,.3);
}
.player-menu > button { display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 12px; border: 0; border-radius: 10px; background: none; color: var(--text); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.player-menu > button:hover, .player-menu > button:focus-visible { background: var(--chip); outline: none; }
.player-menu svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.pm-label { display: flex; align-items: center; gap: 10px; margin: 6px 12px 2px; font-size: 13px; color: var(--muted); }
.pm-chips { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; padding: 0 4px 4px; }
.pm-chips button { white-space: nowrap; padding: 0 4px; height: 36px; border: 0; border-radius: 10px; background: var(--chip); color: var(--text); font: inherit; font-size: 13px; cursor: pointer; transition: background-color 140ms ease, transform 140ms var(--ease-out); }
.pm-chips button:hover { background: var(--chip-2); }
.pm-chips button:active { transform: scale(0.95); }
@media (max-width: 860px) { .player-menu { left: auto; right: var(--gutter); margin-left: 0; } }

/* ---------- Pasar favoritas a otro teléfono ---------- */
.fav-sync { display: flex; gap: 8px; flex-wrap: wrap; margin: -6px 0 14px; }
.fav-sync-panel { margin-bottom: 18px; padding: 16px; border-radius: 16px; background: var(--surface); max-width: 620px; }
.fav-sync-panel p { margin: 0 0 8px; }
.fav-sync-panel a { color: var(--text); word-break: break-all; }
.fav-sync-panel .err { color: #f43f5e; }
.sync-code { font-size: 40px; font-weight: 700; letter-spacing: .12em; color: var(--accent); }
.sync-form { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.sync-form label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.sync-form input { height: 44px; width: 170px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 20px; letter-spacing: .1em; text-transform: uppercase; }

/* ---------- Menú agrupado: Radio, Jugar, Comunidad ---------- */
.nav .nav-sec { margin: 18px 8px 6px; text-transform: uppercase; letter-spacing: .06em; font-size: 11px; font-weight: 600; }
.nav .nav-sec:first-of-type { margin-top: 4px; }
.nav-sheet { display: none; }
@media (max-width: 860px) {
  /* barra inferior: 4 botones fijos (Mapa y tres grupos), sin desplazamiento lateral */
  .bottom-nav { display: grid; grid-template-columns: repeat(4, 1fr); overflow: visible; }
  .bottom-nav a, .bottom-nav button {
    position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    min-width: 0; padding: 0; border: 0; background: none; color: var(--nav); font: inherit; font-size: 11px; cursor: pointer;
    -webkit-tap-highlight-color: transparent; transition: color 200ms ease;
  }
  .bottom-nav a[aria-current="page"], .bottom-nav button[aria-current="page"], .bottom-nav button[aria-expanded="true"] { color: var(--text); }
  .bottom-nav button svg { width: 20px; height: 20px; transition: transform 160ms var(--ease-out); }
  .bottom-nav button:active svg { transform: scale(0.88); }
  .bottom-nav button::before {
    content: ""; position: absolute; top: 0; left: 50%; width: 24px; height: 2px; margin-left: -12px;
    background: var(--text); border-radius: 0 0 2px 2px; transform: scaleX(0); transition: transform 240ms var(--ease-out);
  }
  .bottom-nav button[aria-current="page"]::before { transform: scaleX(1); }
  /* panel del grupo, encima del reproductor */
  .nav-sheet:not([hidden]) {
    display: flex; flex-direction: column; gap: 2px; position: fixed; left: var(--gutter); right: var(--gutter);
    bottom: calc(64px + var(--player) + 10px + env(safe-area-inset-bottom)); z-index: 30; padding: 8px;
    border-radius: 18px; background: var(--surface); border: 1px solid var(--border); box-shadow: 0 16px 40px rgba(0,0,0,.35);
  }
  .nav-sheet a { display: flex; align-items: center; gap: 12px; height: 52px; padding: 0 12px; border-radius: 12px; color: var(--text); text-decoration: none; font-size: 15px; }
  .nav-sheet a[aria-current="page"] { background: var(--chip); }
  .nav-sheet a:active { background: var(--chip-2); }
  .nav-sheet .nl { flex: 1; }
}
@media (prefers-reduced-motion: reduce) { .bottom-nav button::before { transition: none; } }

.wm-logo-phone { border-radius: 7px; flex: none; }
.nav-sheet svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nav-sheet .ni { width: 34px; height: 34px; }
.nav-sheet a[aria-current="page"] .ni { background: var(--accent); color: var(--on-accent); }

/* ---------- Logo de BagotechRadio en lugar del nombre ---------- */
.brand-logo { display: block; line-height: 0; }
.brand-logo img { display: block; height: 50px; width: auto; }
.brand-logo .logo-light { display: none; }
:root[data-theme="claro"] .brand-logo .logo-dark { display: none; }
:root[data-theme="claro"] .brand-logo .logo-light { display: block; }
.wordmark .wm-text { gap: 0; }
.wordmark .wm-text small { padding-left: 3px; font-size: 10.5px; line-height: 12px; }
.wordmark-phone .brand-logo img { height: 40px; }
@media (hover: hover) and (pointer: fine) { .wordmark .brand-logo img { transition: transform 300ms var(--ease-out); } .wordmark:hover .brand-logo img { transform: scale(1.04); } }

/* ---------- Aviso de cookies (Google Analytics, solo con permiso) ---------- */
.cookie-banner {
  position: fixed; z-index: 40; left: calc(var(--sidebar-width) + var(--gutter)); bottom: calc(var(--player) + 14px);
  width: min(460px, calc(100vw - var(--sidebar-width) - var(--gutter) * 2)); padding: 16px;
  border-radius: 18px; background: var(--raised); color: var(--text); border: 1px solid var(--line); box-shadow: 0 16px 48px rgba(0,0,0,.5);
}
.cookie-banner p { margin: 0 0 12px; font-size: 14px; line-height: 1.5; }
.cookie-banner a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.cookie-acts { display: flex; justify-content: flex-end; gap: 8px; }
.cookie-acts button { min-width: 110px; justify-content: center; }
.lg-cookies { display: inline; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
@media (max-width: 860px) {
  .cookie-banner { left: var(--gutter); right: var(--gutter); width: auto; bottom: calc(64px + var(--player) + 10px + env(safe-area-inset-bottom)); }
  .cookie-acts button { flex: 1; }
}

/* ---------- Apoya BagotechRadio ---------- */
.ni-heart { background: color-mix(in srgb, #f43f5e 18%, transparent); color: #f43f5e; }
.dn-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: var(--gap); margin-bottom: var(--gap); }
.dn-card { padding: 22px; border-radius: 20px; background: var(--surface); }
.dn-grid .dn-card { margin: 0; }
.dn-card + .dn-card, .dn-msg { margin-bottom: var(--gap); }
.dn-card h2 { display: flex; align-items: center; gap: 10px; font-size: 18px; margin: 0 0 6px; }
.dn-card h2 svg { width: 22px; height: 22px; fill: none; stroke: #f43f5e; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.dn-main { box-shadow: inset 0 0 0 2px color-mix(in srgb, #f43f5e 45%, transparent); }
.dn-msg p { margin: 0; font-size: 16px; line-height: 1.55; }
.dn-amounts { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin: 16px 0 10px; }
.dn-amount {
  display: grid; place-items: center; height: 56px; border-radius: 14px; background: var(--chip); color: var(--text);
  font-size: 18px; font-weight: 700; text-decoration: none; font-variant-numeric: tabular-nums;
  transition: background-color 160ms ease, transform 140ms var(--ease-out), color 160ms ease;
}
.dn-amount:hover { background: #f43f5e; color: #fff; }
.dn-amount:active, .dn-btn:active { transform: scale(0.96); }
.dn-other { font-size: 14px; font-weight: 600; }
.dn-note { margin: 0; font-size: 13px; color: var(--muted); }
.dn-btns { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.dn-btn { display: flex; align-items: center; justify-content: center; height: 48px; border-radius: 999px; font-weight: 700; text-decoration: none; transition: filter 160ms ease, transform 140ms var(--ease-out); }
.dn-btn:hover { filter: brightness(1.08); }
.dn-kofi { background: #29abe0; color: #fff; }
.dn-bmc { background: #ffdd00; color: #111; }
.dn-list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.dn-list li { display: flex; flex-direction: column; gap: 4px; }
.dn-list span { color: var(--muted); font-size: 14px; }
.dn-foot { max-width: 70ch; font-size: 13px; }
.player-menu > .pm-donate { color: #f43f5e; }
@media (max-width: 860px) {
  .dn-grid, .dn-list { grid-template-columns: 1fr; }
  .dn-card { padding: 16px; }
}
.nav a[hidden], .nav-sheet a[hidden], .site-foot a[hidden] { display: none !important; }

/* ---------- Chat de las salas del Micrófono abierto ---------- */
.chat { display: flex; flex-direction: column; margin-bottom: var(--gap); border-radius: 20px; background: var(--surface); overflow: hidden; }
.chat-empty { padding: 18px; color: var(--muted); }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.chat-title { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.chat-title b { font-size: 16px; }
.chat-title span { font-size: 12px; color: var(--muted); }
.chat-nick { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border: 0; border-radius: 999px; background: var(--chip); color: var(--text); font: inherit; font-size: 13px; cursor: pointer; max-width: 46%; }
.chat-nick span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-nick svg, .chat-ico svg, .chat-send svg, .cm-acts svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.chat-ico { width: 36px; height: 36px; flex: none; border: 0; border-radius: 50%; display: grid; place-items: center; background: var(--chip); color: var(--text); cursor: pointer; }
.chat-ico svg { width: 18px; height: 18px; }
.chat-ico:hover, .chat-nick:hover { background: var(--chip-2); }
.chat-rules { padding: 14px; background: color-mix(in srgb, var(--accent) 10%, var(--surface)); border-bottom: 1px solid var(--line); font-size: 14px; }
.chat-rules ul { margin: 8px 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.chat-rules p { margin: 0 0 10px; font-size: 13px; }
.chat-body { position: relative; }
.chat-list { list-style: none; margin: 0; padding: 10px 14px; height: 380px; overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; gap: 2px; scrollbar-width: thin; }
.chat-hello { margin: auto; color: var(--muted); text-align: center; }
.cm { position: relative; padding: 6px 8px; border-radius: 12px; }
.cm:hover, .cm:focus-within { background: var(--chip); }
.cm.mention { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.cm-head { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.cm-nick { color: hsl(var(--h) 75% 68%); }
:root[data-theme="claro"] .cm-nick { color: hsl(var(--h) 60% 38%); }
.cm-you { color: var(--muted); font-size: 12px; }
.cm-head time { color: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.cm-text { margin: 2px 0 0; font-size: 15px; line-height: 1.4; word-break: break-word; }
.cm-at { color: var(--accent); font-weight: 600; }
.cm-rxs { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.cm-rx { height: 26px; padding: 0 8px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--text); font: inherit; font-size: 13px; cursor: pointer; }
.cm-rx.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); }
.cm-acts { position: absolute; right: 6px; top: -14px; display: none; gap: 2px; padding: 3px; border-radius: 999px; background: var(--raised); border: 1px solid var(--line); box-shadow: 0 6px 18px rgba(0,0,0,.25); }
.cm:hover .cm-acts, .cm:focus-within .cm-acts { display: flex; }
.cm-acts button { width: 30px; height: 30px; border: 0; border-radius: 50%; background: none; color: var(--text); font-size: 15px; cursor: pointer; display: grid; place-items: center; }
.cm-acts button:hover { background: var(--chip-2); }
.cm:first-child .cm-acts { top: 2px; }
@media (hover: none) { .cm-acts { position: static; display: flex; margin-top: 4px; width: max-content; box-shadow: none; background: none; border: 0; padding: 0; } .cm-acts button { width: 34px; height: 30px; background: var(--chip); border-radius: 8px; margin-right: 4px; } }
.chat-new { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); height: 32px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--accent); color: var(--on-accent); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; box-shadow: 0 6px 18px rgba(0,0,0,.3); }
.chat-form { position: relative; display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); }
.chat-form input { flex: 1; min-width: 0; height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 16px; }
.chat-form input:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; }
.chat-form.locked input { font-size: 13px; }
.chat-count { position: absolute; right: 64px; font-size: 11px; color: var(--muted); pointer-events: none; }
.chat-send { width: 44px; height: 44px; flex: none; border: 0; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--on-accent); cursor: pointer; }
.chat-send svg { width: 20px; height: 20px; }
.chat-form.locked .chat-send, .chat-form.locked [data-chat="emoji"] { opacity: .4; pointer-events: none; }
.chat-emojis { position: absolute; left: 10px; bottom: calc(100% + 6px); z-index: 5; width: min(340px, calc(100% - 20px)); max-height: 280px; overflow-y: auto; padding: 10px; border-radius: 16px; background: var(--raised); border: 1px solid var(--line); box-shadow: 0 14px 40px rgba(0,0,0,.35); }
.chat-emojis p { margin: 6px 4px 4px; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.chat-emojis div { display: grid; grid-template-columns: repeat(8, 1fr); }
.chat-emojis button { height: 36px; border: 0; border-radius: 8px; background: none; font-size: 21px; cursor: pointer; }
.chat-emojis button:hover { background: var(--chip-2); }
.chat-note { margin: 0; padding: 0 14px 10px; font-size: 13px; color: #f43f5e; min-height: 0; }
.chat-note:empty { display: none; }
.chat-note.good { color: #16a34a; }
@media (max-width: 860px) { .chat-list { height: 52vh; } .chat-count { right: 62px; } }

/* ---------- Lo que suena: barra fija al pie de la barra lateral (no flota sobre el menú) ---------- */
.sidebar { padding-bottom: 0; }
.side-legal { margin-bottom: 14px; }
.side-now {
  position: sticky; bottom: 0; z-index: 2; flex: none;
  margin: auto -12px 0; width: calc(100% + 24px); height: var(--player); padding: 0 18px;   /* misma altura que el reproductor: una sola franja abajo */
  border: 0; border-top: 1px solid var(--border); border-radius: 0;
  background: var(--ground);
}
/* el menú se desvanece al pasar por debajo, en vez de cortarse de golpe */
.side-now::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 22px; pointer-events: none;
  background: linear-gradient(to bottom, transparent, var(--ground));
}
.side-now.playing { border-color: var(--border); box-shadow: inset 3px 0 0 var(--accent); }
@media (hover: hover) and (pointer: fine) {
  .side-now:hover { background: var(--surface); border-color: var(--border); }
  .side-now.playing:hover { border-color: var(--border); }
}
.side-now:active { transform: none; background: var(--surface); }

/* El logo de Ambientes es un botón que vuelve al menú principal */
button.amb-brand { padding: 4px 8px 4px 4px; margin: -4px 0 -4px -4px; border: 0; border-radius: 12px; background: none; color: inherit; font: inherit; cursor: pointer; transition: background-color 160ms ease, transform 140ms var(--ease-out); }
button.amb-brand img { height: 36px; width: auto; border-radius: 0; filter: drop-shadow(0 2px 8px rgba(0,0,0,.55)); }
button.amb-brand:hover { background: rgba(0,0,0,.35); }
button.amb-brand:active { transform: scale(0.96); }
button.amb-brand:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
@media (max-width: 860px) { button.amb-brand img { height: 30px; } }

/* ---------- Invitación a apoyar la radio (no bloquea la página) ---------- */
.dn-pop { position: fixed; z-index: 45; left: calc(var(--sidebar-width) + (100vw - var(--sidebar-width)) / 2); bottom: calc(var(--player) + 18px); transform: translateX(-50%); width: min(440px, calc(100vw - var(--sidebar-width) - 32px)); pointer-events: none; }
.dn-pop-card {
  position: relative; pointer-events: auto; padding: 22px 22px 16px; border-radius: 22px; text-align: center;
  background: var(--raised); color: var(--text); border: 1px solid color-mix(in srgb, #f43f5e 45%, var(--line));
  box-shadow: 0 22px 60px rgba(0,0,0,.55), 0 0 0 6px color-mix(in srgb, #f43f5e 10%, transparent);
}
.dn-pop-x { position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: none; color: var(--muted); font-size: 24px; line-height: 1; cursor: pointer; }
.dn-pop-x:hover { background: var(--chip); color: var(--text); }
.dn-pop-heart { width: 52px; height: 52px; margin: 0 auto 8px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, #f43f5e 18%, transparent); }
.dn-pop-heart svg { width: 28px; height: 28px; fill: #f43f5e; stroke: #f43f5e; stroke-width: 1.5; animation: dn-beat 1.6s ease-in-out infinite; }
@keyframes dn-beat { 0%, 60%, 100% { transform: scale(1); } 15% { transform: scale(1.18); } 30% { transform: scale(1); } 45% { transform: scale(1.1); } }
.dn-pop h2 { margin: 0 0 6px; font-size: 19px; }
.dn-pop p { margin: 0 0 14px; font-size: 14.5px; line-height: 1.5; color: var(--text); }
.dn-pop-acts { display: flex; gap: 8px; justify-content: center; }
.dn-pop-acts button { flex: 1; justify-content: center; }
.dn-pop-yes { background: #f43f5e; color: #fff; }
.dn-pop-yes:hover { background: #e11d48; }
.dn-pop-yes svg { width: 16px; height: 16px; fill: currentColor; stroke: none; }
.dn-pop .dn-pop-small { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
@media (max-width: 860px) {
  .dn-pop { left: 50%; width: calc(100vw - var(--gutter) * 2); bottom: calc(64px + var(--player) + 12px + env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) { .dn-pop-heart svg { animation: none; } }

/* ---------- Ranking de apoyos ---------- */
.sup { margin-top: var(--gap); padding: 20px; border-radius: 20px; background: var(--surface); }
.sup-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.sup-head h2 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 18px; }
.sup-head svg, .sup-cta svg { width: 20px; height: 20px; fill: #f43f5e; stroke: none; flex: none; }
.sup-cta svg { fill: currentColor; width: 16px; height: 16px; }
.sup-head .g-muted { font-size: 13px; }
.sup-intro { margin: 0 0 16px; color: var(--muted); font-size: 14px; }
.sup-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; }
.sup-list li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; background: var(--chip); min-width: 0; }
.sup-list li.top { background: color-mix(in srgb, #facc15 12%, var(--chip)); }
.sup-rank { width: 26px; flex: none; text-align: center; font-weight: 700; color: var(--muted); }
.sup-list li.top .sup-rank { font-size: 20px; }
.sup-name { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.sup-name b, .sup-name span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sup-name span { font-size: 12px; color: var(--muted); }
.sup-amount { flex: none; font-size: 15px; }
/* podio vacío: tres lugares que invitan a ser el primero */
.sup-podium { list-style: none; margin: 0 auto; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); align-items: end; gap: 10px; max-width: 520px; }
.sup-podium li { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.sup-podium b { font-size: 13px; color: var(--muted); font-style: italic; }
.sup-medal { font-size: 28px; }
.sup-step { width: 100%; display: grid; place-items: center; border-radius: 12px 12px 4px 4px; font-size: 22px; font-weight: 800; color: var(--muted);
  background: linear-gradient(var(--chip-2), var(--chip)); border: 1px dashed var(--line); }
.sup-podium .p1 .sup-step { height: 92px; background: linear-gradient(color-mix(in srgb, #facc15 22%, var(--chip-2)), var(--chip)); }
.sup-podium .p2 .sup-step { height: 66px; }
.sup-podium .p3 .sup-step { height: 48px; }
.sup-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.sup-foot p { margin: 0; font-size: 13px; }
.sup-podium + .sup-foot { justify-content: center; }
.sup-cta { background: #f43f5e; color: #fff; text-decoration: none; }
.sup-cta:hover { background: #e11d48; }
@media (max-width: 860px) { .sup-list { grid-template-columns: 1fr; } .sup { padding: 16px; } }

/* ---------- Beneficios por apoyar ---------- */
/* stickers especiales (SVG animados) */
.ps { display: inline-grid; place-items: center; width: 1.3em; height: 1.3em; line-height: 0; }
.ps svg { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 2px 3px rgba(0,0,0,.35)); }
.wall-sticker.pro { font-size: max(26px, 4.4cqw); }
.ps-spin svg, .ps-spin-slow svg { animation: ps-spin 3s linear infinite; }
.ps-spin-slow svg { animation-duration: 12s; }
.ps-spin-reels .reel { transform-box: fill-box; transform-origin: center; animation: ps-spin 1.6s linear infinite; }
.ps-neon svg { animation: ps-neon 1.8s ease-in-out infinite; }
.ps-bob svg { animation: ps-bob 2.4s ease-in-out infinite; }
.ps-bump svg { animation: ps-bump .8s ease-in-out infinite; }
.ps-glow svg { animation: ps-glow 2s ease-in-out infinite; }
.ps-eq .bars path { transform-box: fill-box; transform-origin: bottom; animation: ps-eq .9s ease-in-out infinite alternate; }
.ps-eq .bars path:nth-child(2) { animation-delay: -.3s; } .ps-eq .bars path:nth-child(3) { animation-delay: -.6s; } .ps-eq .bars path:nth-child(4) { animation-delay: -.15s; }
.ps-beat svg { animation: dn-beat 1.6s ease-in-out infinite; }
.ps-twinkle svg { animation: ps-twinkle 2.2s ease-in-out infinite; }
.ps-flicker svg { animation: ps-flicker 1.2s ease-in-out infinite; transform-origin: bottom; }
.ps-shine svg { animation: ps-glow 2.6s ease-in-out infinite; }
@keyframes ps-spin { to { transform: rotate(360deg); } }
@keyframes ps-neon { 0%, 100% { filter: drop-shadow(0 0 2px #ff3b5c) drop-shadow(0 0 8px #ff3b5c); } 50% { filter: drop-shadow(0 0 1px #ff3b5c); } }
@keyframes ps-bob { 50% { transform: translateY(-6%) rotate(-4deg); } }
@keyframes ps-bump { 50% { transform: scale(1.07); } }
@keyframes ps-glow { 50% { filter: drop-shadow(0 0 6px rgba(103,232,249,.9)); } }
@keyframes ps-eq { from { transform: scaleY(.45); } to { transform: scaleY(1); } }
@keyframes ps-twinkle { 50% { transform: rotate(10deg) scale(1.08); } }
@keyframes ps-flicker { 50% { transform: scaleY(1.06) skewX(-2deg); } }
@media (prefers-reduced-motion: reduce) { .ps svg, .ps .reel, .ps .bars path { animation: none !important; } }
.st-pro-title { grid-column: 1 / -1; margin: 10px 0 2px; font-size: 12px; font-weight: 700; color: var(--accent); }
.st-btn.st-pro { font-size: 26px; background: linear-gradient(135deg, color-mix(in srgb, #facc15 14%, var(--chip)), var(--chip)); }
.st-btn.st-pro.locked { opacity: .45; filter: grayscale(.7); }
.wall-locked { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 6px; padding: 12px; margin-top: 8px; border-radius: 12px; background: color-mix(in srgb, #facc15 10%, var(--chip)); border: 1px dashed color-mix(in srgb, #facc15 50%, transparent); font-size: 13px; }
.wall-locked span { color: var(--muted); }
.wall-locked .btn-primary { align-self: flex-start; height: 34px; font-size: 13px; }
.wall-tool[data-pro] { position: relative; }
.wt-badge { position: absolute; top: 2px; right: 4px; font-style: normal; font-size: 10px; }
.pro-modes { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pro-mode { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; border: 0; border-radius: 10px; background: var(--chip); color: var(--text); font: inherit; font-size: 12px; cursor: pointer; }
.pro-mode span { font-size: 18px; }
.pro-mode[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); }
.pro-sizes { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; color: var(--muted); }
.pro-sizes button { width: 32px; height: 28px; border: 0; border-radius: 8px; background: var(--chip); color: var(--text); font: inherit; cursor: pointer; }
.pro-sizes button[aria-pressed="true"] { background: var(--text); color: var(--ground); }
.pro-colors { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; margin-top: 8px; }
/* micrófono: intervenciones del día */
.mic-quota { margin: 0; font-size: 12px; color: var(--muted); }
.mic-quota a { color: var(--accent); }
.mic-quota.pro { color: #facc15; }
/* chat: insignia de quien apoya */
.cm-sup { font-size: 12px; filter: drop-shadow(0 0 3px rgba(250,204,21,.6)); }
/* tarjeta de beneficios en Apoyar */
.pk-card { margin-bottom: var(--gap); padding: 22px; border-radius: 20px; background: linear-gradient(135deg, color-mix(in srgb, #facc15 12%, var(--surface)), var(--surface) 60%); border: 1px solid color-mix(in srgb, #facc15 35%, var(--line)); }
.pk-card.on { border-color: #22c55e; background: linear-gradient(135deg, color-mix(in srgb, #22c55e 14%, var(--surface)), var(--surface) 60%); }
.pk-card h2 { display: flex; align-items: center; gap: 10px; margin: 0 0 8px; font-size: 18px; }
.pk-card h2 svg { width: 22px; height: 22px; fill: #facc15; stroke: none; flex: none; }
.pk-card p { margin: 0 0 12px; }
.pk-status { font-weight: 600; color: #22c55e; }
.pk-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pk-list li { display: flex; gap: 10px; align-items: flex-start; }
.pk-ico { font-size: 22px; line-height: 1.2; }
.pk-list li > span:last-child { display: flex; flex-direction: column; }
.pk-list li span span { font-size: 13px; color: var(--muted); }
.pk-form label { display: block; font-weight: 600; margin-bottom: 6px; }
.pk-form div { display: flex; gap: 8px; flex-wrap: wrap; }
.pk-form input { flex: 1 1 220px; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 16px; letter-spacing: .06em; text-transform: uppercase; }
.pk-note { margin: 8px 0 0; font-size: 13px; color: #f43f5e; }
.pk-note:empty { display: none; }
.pk-how { margin: 10px 0 0 !important; font-size: 13px; }
.dn-pop .dn-pop-perks { margin: -4px 0 14px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, #facc15 10%, var(--chip)); font-size: 13px; text-align: left; }
@media (max-width: 860px) { .pk-list { grid-template-columns: 1fr; } .pk-card { padding: 16px; } }
/* la paleta del muro es flexible: estos bloques ocupan una fila completa */
.wall-palette .st-pro-title, .wall-palette .wall-locked, .wall-palette .pro-modes, .wall-palette .pro-sizes, .wall-palette .pro-colors { flex: 0 0 100%; width: 100%; }
.wall-palette .pro-colors { display: flex; flex-wrap: wrap; gap: 6px; }

/* Vitrina de stickers especiales (Apoyar y arriba de los muros) */
.pk-show { margin: 0 0 var(--gap); padding: 16px; border-radius: 18px; border: 1px solid color-mix(in srgb, #facc15 35%, var(--line));
  background: linear-gradient(135deg, color-mix(in srgb, #facc15 10%, var(--surface)), var(--surface) 65%); display: grid; grid-template-columns: 1fr auto; gap: 10px 14px; align-items: center; }
.pk-card .pk-show { margin: 4px 0 14px; background: color-mix(in srgb, var(--ground) 55%, transparent); }
.pk-show.on { border-color: #22c55e; }
.pk-show-head { display: grid; gap: 3px; }
.pk-show-head b { font-size: 15px; }
.pk-show-head span { font-size: 13px; color: var(--muted); }
.pk-show > .btn-primary { justify-self: end; }
.pk-show-grid { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.pk-show figure { margin: 0; position: relative; display: grid; justify-items: center; gap: 4px; padding: 10px 4px 8px; border-radius: 14px; background: var(--chip); }
.pk-show figure .ps { width: 44px; height: 44px; }
.pk-show figcaption { font-size: 11px; color: var(--muted); text-align: center; line-height: 1.2; }
.pk-show.locked figure .ps { opacity: .8; }
.pk-show.locked figure::after { content: "🔒"; position: absolute; top: 4px; right: 6px; font-size: 11px; }
@media (max-width: 640px) {
  .pk-show { grid-template-columns: 1fr; }
  .pk-show > .btn-primary { justify-self: start; }
  .pk-show-grid { grid-template-columns: repeat(4, 1fr); }
}

/* Micrófono abierto: controles y sala a un lado, chat al otro (o uno debajo de otro en pantallas angostas).
   El chat tiene altura fija y su propio scroll, así la página no se alarga. */
.mic-stage { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gap); margin-bottom: var(--gap); }
.mic-side { display: grid; gap: var(--gap); align-content: start; min-width: 0; }
.mic-stage .mic-room, .mic-stage .chat { margin-bottom: 0; }
.mic-dock.inline { position: static; width: auto; z-index: auto; padding: 14px; border: 1px solid var(--line); box-shadow: none; }
.mic-dock.inline[data-phase="rec"] { box-shadow: 0 0 0 2px #ef4444; }
.mic-dock.inline[data-phase="play"] { box-shadow: 0 0 0 2px var(--accent); }
.mic-stage .mic-clips { max-height: 300px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.mic-stage .chat { height: clamp(420px, calc(100dvh - var(--player) - 150px), 620px); }
.mic-stage .chat-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.mic-stage .chat-list { flex: 1; min-height: 0; height: auto; }
.mic-stage .chat-rules { flex: none; max-height: 48%; overflow-y: auto; overscroll-behavior: contain; padding: 12px 14px; font-size: 13px; }
.mic-stage .chat-rules ul { margin: 6px 0; gap: 2px; }
.mic-stage .chat-empty { display: grid; place-items: center; height: 100%; text-align: center; }
.mic-stage .chat:has(.chat-empty) { height: auto; }
.mic-stage .sup { margin-top: 0; }
#mic-sup-slot:has(> .sup[hidden]) { display: none; }
@media (min-width: 1100px) {
  /* chat a la izquierda, micrófono + sala + ranking a la derecha */
  .mic-stage { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: start; }
  .mic-chat-col { order: 1; position: sticky; top: 12px; }
  .mic-side { order: 2; }
}
#mic-dock-slot:has(> .mic-dock[hidden]) { display: none; }
/* en pantallas angostas: micrófono, luego el chat y al final las intervenciones */
@media (max-width: 1099px) {
  .mic-side { display: contents; }
  #mic-dock-slot { order: 1; } .mic-chat-col { order: 2; } .mic-stage .mic-room { order: 3; } #mic-sup-slot { order: 4; }
}
@media (max-width: 700px) {
  /* cabe entre la barra de arriba y el reproductor con la barra de abajo */
  .mic-stage .chat { height: clamp(340px, calc(100dvh - 330px), 520px); }
  .mic-stage .mic-clips { max-height: 240px; }
}

/* Bienvenida tras activar el código */
.pk-welcome h3 { margin: 0 0 6px; font-size: 18px; }
.pk-welcome p { margin: 0 0 12px; }
.pk-w-row { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.pk-w-row label { display: flex; flex-direction: column; gap: 6px; flex: 1 1 200px; font-weight: 600; font-size: 14px; }
.pk-w-row input, .pk-w-row select { height: 44px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 16px; }
.pk-check { display: flex; align-items: flex-start; gap: 8px; margin: 6px 0; font-size: 14px; }
.pk-check input { margin-top: 3px; accent-color: var(--accent); }
.pk-w-acts { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.btn-ghost { height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--text); font: inherit; cursor: pointer; }
.btn-ghost:hover { background: var(--chip); }

/* Aviso público de nuevo apoyo */
.ann { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px; background: rgba(0,0,0,.45); animation: ann-fade .3s ease-out; }
.ann.out { animation: ann-fade .3s ease-in reverse forwards; }
.ann-card { position: relative; overflow: hidden; width: min(460px, 100%); padding: 28px 24px 22px; border-radius: 26px; text-align: center; color: var(--text);
  background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, #facc15 22%, var(--surface)), var(--surface) 70%);
  border: 2px solid #facc15; box-shadow: 0 0 0 6px color-mix(in srgb, #facc15 18%, transparent), 0 30px 80px rgba(0,0,0,.5);
  animation: ann-pop .55s cubic-bezier(0.34, 1.56, 0.64, 1); }
.ann.out .ann-card { animation: ann-pop .3s ease-in reverse forwards; }
.ann-badge { display: inline-block; padding: 6px 14px; border-radius: 999px; background: #f43f5e; color: #fff; font-weight: 700; font-size: 14px; animation: ann-wiggle 1.2s ease-in-out .5s 2; }
.ann-card h2 { margin: 14px 0 12px; font-size: 22px; line-height: 1.25; }
.ann-who { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 0 10px; font-size: 18px; text-align: left; }
.ann-who > span { display: flex; flex-direction: column; }
.ann-who small { font-size: 13px; color: var(--muted); }
.ann-flag { width: 40px; height: 30px; border-radius: 6px; object-fit: cover; flex: none; box-shadow: 0 2px 8px rgba(0,0,0,.3); }
.ann-heart { font-size: 32px; }
.ann-amount { color: #facc15; font-size: 1.15em; }
.ann-thanks { margin: 0 0 16px; color: var(--muted); font-size: 14px; }
.ann-acts { display: flex; justify-content: center; }
.ann-x { position: absolute; top: 10px; right: 12px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: var(--chip); color: var(--text); font-size: 22px; line-height: 1; cursor: pointer; z-index: 2; }
.ann-bar { position: absolute; left: 0; bottom: 0; height: 4px; width: 100%; background: #facc15; transform-origin: left; animation: ann-bar 12s linear forwards; }
.ann-confetti { position: absolute; inset: 0; pointer-events: none; }
.ann-confetti i { position: absolute; top: -12px; left: var(--x); width: 8px; height: 14px; border-radius: 2px; background: var(--c); transform: rotate(var(--r)); animation: ann-fall 2.4s ease-in var(--d) 2 both; }
@keyframes ann-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ann-pop { from { opacity: 0; transform: scale(.7) translateY(30px); } to { opacity: 1; transform: none; } }
@keyframes ann-wiggle { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-6deg) scale(1.08); } 75% { transform: rotate(6deg) scale(1.08); } }
@keyframes ann-bar { to { transform: scaleX(0); } }
@keyframes ann-fall { to { transform: translateY(420px) rotate(calc(var(--r) + 540deg)); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .ann, .ann-card, .ann-badge, .ann-confetti i { animation: none; }
  .ann-confetti { display: none; }
}

/* ---------- Sugerencias ---------- */
.ni-idea { background: color-mix(in srgb, #facc15 18%, transparent); color: #eab308; }
.sg-card { max-width: 760px; padding: 22px; border-radius: 20px; background: var(--surface); display: grid; gap: 16px; }
.sg-cats { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; border: 0; }
.sg-cats legend { font-weight: 700; margin-bottom: 8px; padding: 0; }
.sg-cat { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--text); font: inherit; font-size: 14px; cursor: pointer; }
.sg-cat:hover { background: var(--chip); }
.sg-cat[aria-pressed="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); font-weight: 600; }
.sg-field { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; flex: 1 1 240px; min-width: 0; }
.sg-field .g-muted { font-weight: 400; }
.sg-field textarea, .sg-field input { padding: 10px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--ground); color: var(--text); font: inherit; font-size: 16px; font-weight: 400; }
.sg-field input { height: 44px; padding: 0 14px; }
.sg-field textarea { resize: vertical; min-height: 130px; line-height: 1.45; }
.sg-field textarea[aria-invalid="true"] { border-color: #f43f5e; outline-color: #f43f5e; }
.sg-meta { display: flex; justify-content: space-between; gap: 10px; font-weight: 400; font-size: 13px; color: var(--muted); }
.sg-status.bad { color: #f43f5e; }
.sg-status.good { color: #16a34a; }
.sg-row { display: flex; flex-wrap: wrap; gap: 14px; }
.sg-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.sg-rules { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0; padding: 0; list-style: none; font-size: 13px; color: var(--muted); }
.sg-rules li::before { content: "🚫 "; }
.sg-acts { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.sg-acts .btn-primary:disabled { opacity: .45; cursor: not-allowed; }
.sg-note { margin: 0; color: #f43f5e; font-size: 14px; }
.sg-done { text-align: center; justify-items: center; }
.sg-done h2 { margin: 0; }
.sg-done p { margin: 0; color: var(--muted); }
.sg-big { font-size: 46px; }

/* ---------- Instalar la app ---------- */
.ni-app { background: color-mix(in srgb, #22c55e 18%, transparent); color: #16a34a; }
.in-banner { position: fixed; left: 12px; right: 12px; bottom: calc(var(--player) + 72px + env(safe-area-inset-bottom)); z-index: 60;
  display: grid; grid-template-columns: auto 1fr; gap: 10px 12px; align-items: center; padding: 14px; border-radius: 20px;
  background: var(--surface); color: var(--text); border: 1px solid var(--line); box-shadow: 0 16px 44px rgba(0,0,0,.35); max-width: 520px; margin: 0 auto; }
.in-banner img { border-radius: 12px; }
.in-b-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.in-b-text b { font-size: 15px; }
.in-b-text span { font-size: 13px; color: var(--muted); }
.in-b-acts { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; }
@media (min-width: 861px) { .in-banner { bottom: calc(var(--player) + 16px); } }
.in-hero { display: flex; gap: 18px; align-items: flex-start; padding: 22px; border-radius: 20px; background: var(--surface); margin-bottom: var(--gap); }
.in-hero img { border-radius: 18px; flex: none; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.in-hero h2 { margin: 0 0 6px; font-size: 20px; }
.in-hero p { margin: 0 0 12px; color: var(--muted); }
.in-big { display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 22px; font-size: 16px; }
.in-big svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.in-hint { color: var(--text) !important; }
.in-perks { list-style: none; margin: 0 0 var(--gap); padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; }
.in-perks li { display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 16px; background: var(--surface); font-size: 14px; }
.in-perks span { font-size: 22px; }
.in-steps { display: grid; gap: 10px; max-width: 760px; }
.in-step { border-radius: 16px; background: var(--surface); padding: 4px 16px; }
.in-step summary { cursor: pointer; padding: 12px 0; font-weight: 700; }
.in-step ol { margin: 0 0 14px; padding-left: 22px; display: grid; gap: 8px; }
.in-you { margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); font-size: 12px; }
.in-ico { width: 18px; height: 18px; vertical-align: -4px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.in-step .in-ico circle { fill: currentColor; stroke: none; }
@media (max-width: 600px) { .in-hero { flex-direction: column; } }

/* ---------- Texto "Qué es BagotechRadio" (al final de cada apartado) ---------- */
.seo-about { margin: calc(var(--gap) * 2) 0 0; padding: 24px; border-radius: 20px; background: var(--surface); color: var(--muted); font-size: 14px; line-height: 1.55; }
.seo-about h2 { margin: 0 0 8px; font-size: 18px; color: var(--text); }
.seo-about h3 { margin: 0 0 4px; font-size: 15px; color: var(--text); }
.seo-about p { margin: 0 0 12px; }
.seo-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin: 6px 0 10px; }
.seo-cols p { margin: 0; }
.seo-about details { border-top: 1px solid var(--line); padding: 10px 0; }
.seo-about summary { cursor: pointer; color: var(--text); font-weight: 600; }
.seo-about details p { margin: 8px 0 0; }

.seo-links { margin: 6px 0 10px; }
.seo-links h3 { margin: 10px 0 4px; font-size: 15px; color: var(--text); }
.seo-links p { margin: 0 0 6px; line-height: 1.9; }
.seo-links a { color: var(--text); text-decoration: none; border-bottom: 1px solid var(--line); }
.seo-links a:hover { border-color: var(--accent); }
