/* Diamantes — sistema visual "oscuro gamer" compartido por las 3 apps */
:root {
  --fondo: #070F14;
  --sup: #0E1A21;
  --sup2: #14242D;
  --linea: #213844;
  --borde-input: #2E5260;
  --nav: #0B161C;
  --nav-borde: #1A2D36;
  --texto: #ECF6F4;
  --tenue: #9DB4B9;
  --suave: #C9DADD;
  --placeholder: #7F9AA0;
  --verde: #2BE5A0;
  --verde-claro: #8DF7CF;
  --sobre-verde: #062016;
  --naranja: #FF9F43;
  --sobre-naranja: #1F1206;
  --naranja-texto: #FFB86B;
  --hl: #10282B;
  --hl-borde: #1F5A4B;
  --pendiente: #3A5561;
  --amarillo: #FFE27A;
  --display: 'Chakra Petch', 'Barlow', system-ui, sans-serif;
  --cuerpo: 'Barlow', 'Segoe UI', system-ui, sans-serif;
  --chaflan: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  --chaflan-chico: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%);
  --ancho: 520px;
  --seguro-abajo: env(safe-area-inset-bottom, 0px);
  --seguro-arriba: env(safe-area-inset-top, 0px);
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
/* Sin zoom en ninguna app: ni con dos dedos ni con doble toque (el iPhone usa "manipulation"; Chrome, "pan-x pan-y"). */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; touch-action: manipulation; touch-action: pan-x pan-y; }
body {
  margin: 0;
  background: var(--fondo);
  color: var(--texto);
  font-family: var(--cuerpo);
  font-size: 16px;
  line-height: 1.4;
  -webkit-tap-highlight-color: transparent;
}
a { color: var(--verde); text-decoration: none; }
a:hover { color: var(--verde-claro); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: 0.5; }
input::placeholder, textarea::placeholder { color: var(--placeholder); }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--verde); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--display); margin: 0; line-height: 1.15; }
h1 { font-size: 20px; font-weight: 700; }
h2 { font-size: 18px; font-weight: 700; }
h3 { font-size: 16px; font-weight: 700; }
p { margin: 0; }
.oculto-lector { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.app { max-width: var(--ancho); margin: 0 auto; min-height: 100vh; min-height: 100dvh; position: relative; }
.pantalla { display: flex; flex-direction: column; gap: 16px; padding: 16px; }
.pantalla.con-nav { padding-bottom: calc(100px + var(--seguro-abajo)); }
.pantalla.con-accion { padding-bottom: calc(110px + var(--seguro-abajo)); }
.pila { display: flex; flex-direction: column; gap: 12px; }
.pila-8 { display: flex; flex-direction: column; gap: 8px; }
.pila-4 { display: flex; flex-direction: column; gap: 4px; }
.fila-flex { display: flex; align-items: center; gap: 12px; }
.entre { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rejilla-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.rejilla-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.crece { flex: 1; min-width: 0; }
.centro { text-align: center; }

/* Encabezados */
.barra {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 8px;
  min-height: calc(64px + var(--seguro-arriba)); padding: var(--seguro-arriba) 12px 0 4px;
  background: var(--fondo); border-bottom: 1px solid var(--nav-borde);
}
.barra.sin-atras { padding-left: 16px; }
.barra .titulos { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.barra .titulos h1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.marca { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.marca .nombre { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--display); font-size: 19px; font-weight: 700; letter-spacing: 2px; }
/* El nombre como imagen («BOOYAHSTORE / GAMES», iconos/nombre.svg): si no cabe se achica sin deformarse. */
.nombre-marca { display: block; height: auto; max-width: 100%; }
.marca .nombre .nombre-marca { width: 162px; }
/* País de la tienda en el encabezado de Inicio (por ahora fijo: México). Cabe junto al nombre hasta en celulares de 360. */
.pais { flex: none; display: inline-flex; align-items: center; gap: 5px; height: 32px; padding: 0 8px; margin-left: -2px; border-radius: 999px; border: 1px solid var(--linea); background: var(--sup); font-size: 12px; font-weight: 700; line-height: 1; color: var(--texto); white-space: nowrap; }
.pais svg, .aviso-pais svg { flex: none; width: 19px; height: 13px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.22); }
.barra.con-pais .marca { gap: 8px; }
.barra.con-pais .btn-sec { padding: 0 12px; }
/* Aviso de "solo vendemos en México" (pantalla de Entrar) */
.aviso-pais { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--linea); background: var(--sup); font-size: 14px; font-weight: 600; line-height: 1.35; color: var(--texto); }
.aviso-pais svg { width: 21px; height: 14px; }
.etiqueta-admin {
  display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
  background: var(--naranja); color: var(--sobre-naranja); font-size: 11px; font-weight: 800; letter-spacing: 1px;
  clip-path: var(--chaflan-chico);
}

/* Textos */
.tenue { color: var(--tenue); }
.suave { color: var(--suave); }
.chico { font-size: 13px; }
.mini { font-size: 12px; }
.fuerte { font-weight: 700; }
.display { font-family: var(--display); font-weight: 700; }
.verde { color: var(--verde); }
.naranja { color: var(--naranja-texto); }
.monto-xl { font-family: var(--display); font-weight: 700; font-size: 40px; line-height: 1; color: var(--verde); }
.monto-l { font-family: var(--display); font-weight: 700; font-size: 24px; line-height: 1.1; }
.folio-xl { font-family: var(--display); font-weight: 700; font-size: 34px; letter-spacing: 4px; }
.ayuda { font-size: 13px; line-height: 1.45; color: var(--tenue); }
.error-texto { font-size: 13px; color: var(--naranja-texto); }

/* Tarjetas */
.tarjeta { display: flex; flex-direction: column; gap: 12px; padding: 14px; border-radius: 16px; background: var(--sup); border: 1px solid var(--linea); }
.tarjeta.destacada { background: var(--hl); border-color: var(--hl-borde); }
.tarjeta.alerta { border-color: var(--naranja); }
.tarjeta.punteada { background: var(--sup2); border: 1px dashed var(--borde-input); }
.tarjeta-enlace { color: var(--texto); }
.tarjeta-enlace:hover { color: var(--texto); border-color: var(--borde-input); }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 20px; border: 0;
  background: var(--verde); color: var(--sobre-verde); font-weight: 700; font-size: 16px;
  clip-path: var(--chaflan); text-align: center;
}
.btn:hover { color: var(--sobre-verde); filter: brightness(1.06); }
.btn.mediano { min-height: 48px; font-size: 15px; }
.btn.ancho { width: 100%; }
.btn.naranja { background: var(--naranja); color: var(--sobre-naranja); }
.btn-sec {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 16px; border-radius: 12px;
  border: 1px solid var(--borde-input); background: transparent; color: var(--texto); font-weight: 700; font-size: 15px;
}
.btn-sec:hover { color: var(--texto); border-color: var(--suave); }
.btn-sec.ancho { width: 100%; }
/* WhatsApp · Llamar · Cómo llegar de una tienda (app del socio): caben los tres en una fila. */
[data-contactos] .btn-sec { min-height: 44px; padding: 0 6px; gap: 6px; font-size: 14px; white-space: nowrap; }
[data-contactos] .btn-sec svg { flex: none; }
.btn-texto { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 8px; border: 0; background: transparent; font-weight: 700; font-size: 15px; color: var(--verde); }
.btn-texto.naranja { color: var(--naranja-texto); }
.btn-icono {
  flex: none; position: relative; width: 44px; height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 12px; border: 0; background: transparent; color: var(--texto);
}
.btn-icono.redondo { border-radius: 999px; border: 1px solid var(--linea); background: var(--sup); }
.punto { position: absolute; top: 9px; right: 10px; width: 9px; height: 9px; border-radius: 50%; background: var(--naranja); border: 2px solid var(--sup); }
.contador {
  position: absolute; top: -6px; right: -11px; min-width: 18px; height: 18px; padding: 0 5px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; border: 2px solid var(--nav); background: var(--naranja); color: var(--sobre-naranja);
  font-size: 11px; font-weight: 800; line-height: 1;
}
.btn .giro, .btn-sec .giro, .btn-google .giro { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: giro 0.8s linear infinite; }
@keyframes giro { to { transform: rotate(360deg); } }

/* Chips */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 700; white-space: nowrap; }
.chip.chico { height: 22px; padding: 0 8px; font-size: 11px; }
.chip-ok { background: var(--verde); color: var(--sobre-verde); }
.chip-pend { background: var(--naranja); color: var(--sobre-naranja); }
.chip-neutro { background: var(--sup2); border: 1px solid var(--borde-input); color: var(--suave); }
.chip-aviso { border: 1px solid var(--naranja); color: var(--naranja-texto); }
.chip-marca { background: var(--sup2); border: 1px solid var(--hl-borde); color: var(--verde); }
/* De qué socio es una tienda (Admin › Asociados), junto a su nombre: si no cabe, se corta el nombre y el socio se sigue viendo. */
.fila .textos .t1.t1-socio { display: flex; align-items: center; gap: 6px; }
.t1-socio .nombre { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.chip.chip-socio { flex: none; max-width: 45%; height: 22px; padding: 0 8px; font-size: 12px; overflow: hidden; text-overflow: ellipsis; display: inline-block; line-height: 20px; }
.filtros { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.filtros::-webkit-scrollbar { display: none; }
.filtro { flex: none; height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--borde-input); background: transparent; color: var(--suave); font-weight: 600; font-size: 14px; }
.filtro[aria-pressed="true"] { border-color: var(--verde); background: var(--hl); color: var(--verde); font-weight: 700; }

/* Formularios */
.campo { display: flex; flex-direction: column; gap: 8px; }
.campo > label, .etiqueta { font-size: 14px; font-weight: 600; }
.input, .select, .area {
  width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px;
  border: 1px solid var(--borde-input); background: var(--sup2); color: var(--texto); font-size: 16px; outline: none;
}
.area { min-height: 120px; padding: 12px 14px; resize: vertical; line-height: 1.45; }
/* Un campo en una rejilla de 2 columnas puede encogerse a su columna (si no, una fecha del iPhone se sale de la tarjeta). */
.rejilla-2 > .campo { min-width: 0; }
/* iPhone y iPad (Safari): las listas (select) y los campos de fecha traen su propio alto y ancho (más bajitos que los
   demás campos, y la fecha centrada y más ancha que su columna). Así quedan igual que los otros campos. Solo aplica en
   iOS (-webkit-touch-callout); el menú y el calendario del iPhone siguen saliendo igual al tocarlos. */
@supports (-webkit-touch-callout: none) {
  .select, input.input[type="date"], input.input[type="time"], input.input[type="datetime-local"] {
    -webkit-appearance: none; appearance: none; display: block; min-width: 0; max-width: 100%; height: 48px; line-height: 46px;
  }
  input.input[type="date"]::-webkit-date-and-time-value, input.input[type="time"]::-webkit-date-and-time-value,
  input.input[type="datetime-local"]::-webkit-date-and-time-value { text-align: left; margin: 0; line-height: 46px; }
  .select {
    padding-right: 42px;
    background: var(--sup2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2393A3AD' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center / 16px 16px;
  }
}
.input:focus, .select:focus, .area:focus { border-color: var(--verde); }
.input.grande { font-family: var(--display); font-size: 20px; letter-spacing: 1px; }
.input-con-boton { display: flex; gap: 10px; }
/* Atajo para buscar (Panel del admin): se ve como un campo y lleva a la pantalla de búsqueda. */
.buscador { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--borde-input); background: var(--sup2); color: var(--placeholder); font-size: 16px; }
.buscador:hover { color: var(--suave); border-color: var(--suave); }
.input-con-boton .input { flex: 1; min-width: 0; }
.casilla { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; line-height: 1.45; color: var(--suave); }
.casilla input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--verde); }

/* Control segmentado */
.seg { display: grid; grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 14px; background: var(--sup); border: 1px solid var(--linea); }
.seg button { min-height: 44px; border: 0; border-radius: 10px; background: transparent; color: var(--suave); font-weight: 700; font-size: 15px; }
.seg button[aria-pressed="true"] { background: var(--verde); color: var(--sobre-verde); }

/* Interruptor */
.switch { flex: none; position: relative; width: 52px; height: 44px; padding: 0; border: 0; background: transparent; }
.switch::before { content: ''; position: absolute; left: 0; top: 8px; width: 52px; height: 28px; border-radius: 999px; background: var(--borde-input); transition: background 0.15s; }
.switch::after { content: ''; position: absolute; top: 11px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.4); transition: left 0.15s; }
.switch[aria-checked="true"]::before { background: var(--verde); }
.switch[aria-checked="true"]::after { left: 27px; }
.switch:disabled { opacity: 0.45; cursor: not-allowed; }
/* El paquete al que llegaste desde su editor o desde un pedido (Recargas automáticas › Tus paquetes). */
.enfocado { background: var(--hl); box-shadow: 0 0 0 8px var(--hl); border-radius: 4px; }
/* «Tus paquetes» (Admin › Recargas automáticas): cada paquete sale cerrado con su resumen y se abre al tocarlo. */
details.paq { border-top: 1px solid var(--linea); padding-top: 12px; scroll-margin-top: calc(76px + var(--seguro-arriba)); }
details.paq > summary { list-style: none; cursor: pointer; display: flex; flex-direction: column; gap: 6px; min-height: 44px; }
details.paq > summary::-webkit-details-marker { display: none; }
details.paq .flecha { display: inline-flex; color: var(--tenue); transition: transform 0.15s; }
details.paq[open] .flecha { transform: rotate(180deg); }
details.paq[open] .paq-resumen { display: none; }
details.paq > .paq-dentro { margin-top: 4px; }
/* Una tarjeta plegable (p66, «Tarjeta del jugador» en Recargas automáticas): cerrada, solo su renglón de arriba con
   una flecha; abierta, lo de adentro. */
details.plegable { display: block; } /* sin el gap de .tarjeta: cerrada, Chrome deja un hueco abajo */
details.plegable > summary { list-style: none; cursor: pointer; display: block; min-height: 44px; }
details.plegable > summary::-webkit-details-marker { display: none; }
details.plegable .flecha { display: inline-flex; color: var(--tenue); transition: transform 0.15s; }
details.plegable[open] .flecha { transform: rotate(180deg); }
details.plegable > .plegable-dentro { margin-top: 16px; }
.paq-lin { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.chip-mini { height: 22px; padding: 0 8px; font-size: 12px; }

/* Listas */
.lista { display: flex; flex-direction: column; border-radius: 16px; background: var(--sup); border: 1px solid var(--linea); overflow: hidden; }
.fila { display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 9px 14px; border-bottom: 1px solid var(--nav-borde); color: var(--texto); background: transparent; border-left: 0; border-right: 0; border-top: 0; text-align: left; width: 100%; }
.fila:last-child { border-bottom: 0; }
a.fila:hover, button.fila:hover { color: var(--texto); background: rgba(255,255,255,0.02); }
.fila .textos { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.fila .textos .t1 { font-weight: 700; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fila .textos .t2 { font-size: 13px; color: var(--tenue); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fila .lado { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.icono-caja { flex: none; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border-radius: 10px; background: var(--sup2); color: var(--verde); }
.icono-caja.redondo { border-radius: 50%; }
.icono-caja.grande { width: 44px; height: 44px; border-radius: 12px; }
/* La miniatura de un paquete con foto (Admin › Productos): la foto encima de su copia chiquita borrosa (p75). */
.icono-caja.con-foto { position: relative; padding: 0; overflow: hidden; }
.icono-caja.con-foto > .foto-mini { position: absolute; inset: -6px; background-size: cover; background-position: center; filter: blur(4px); }
.icono-caja.con-foto > img { position: relative; width: 100%; height: 100%; }
.icono-caja.verde { background: var(--verde); color: var(--sobre-verde); }
.icono-caja.naranja { background: var(--sup2); color: var(--naranja-texto); }
.desglose { display: flex; flex-direction: column; padding-top: 4px; border-top: 1px solid var(--nav-borde); }
.desglose .renglon { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; font-size: 14px; color: var(--suave); }
.desglose .renglon .valor { font-family: var(--display); font-weight: 700; font-size: 15px; color: var(--texto); }
/* En las cuentas de dinero (cortes) cada cantidad va en un solo renglón: que el «−» no se separe de su cantidad. */
.desglose.montos .renglon .valor { white-space: nowrap; flex: none; }
.desglose .renglon.total { font-size: 15px; font-weight: 600; color: var(--texto); }
.desglose .renglon.total .valor { font-size: 20px; color: var(--verde); }
/* Un subtotal (por ejemplo, la ganancia sin descontar el saldo): resaltado, pero sin competir con el total. */
.desglose .renglon.subtotal { font-size: 15px; font-weight: 600; color: var(--texto); }
.desglose .renglon.subtotal .mini { font-weight: 400; }
.desglose .renglon.subtotal .valor { font-size: 17px; }

/* Tiendas aliadas al pagar: la distancia en una etiqueta (verde cerca, naranja a más de 5 km) y el mapa (Leaflet), oscurecido
   para que combine con la app. El mapa es su propio «piso»: sus capas no se enciman a la barra de arriba ni a la de abajo. */
.etiqueta-distancia { flex: none; align-self: center; padding: 4px 10px; border-radius: 999px; font-weight: 700; font-size: 13px; white-space: nowrap; background: rgba(43, 229, 160, .14); color: var(--verde); }
.etiqueta-distancia.lejos { background: rgba(255, 159, 67, .14); color: var(--naranja-texto); }
.mapa-tiendas { position: relative; z-index: 0; height: 280px; border-radius: 14px; overflow: hidden; border: 1px solid var(--linea); background: var(--sup); }
.mapa-tiendas[hidden] { display: none; }
.mapa-tiendas.leaflet-container { background: var(--sup); font: inherit; }
.mapa-tiendas .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.95) contrast(.9); }
/* leaflet.css se carga después de este archivo: estas reglas llevan más peso para ganarle a las suyas. */
.mapa-tiendas.leaflet-container .leaflet-control-attribution { background: rgba(7, 15, 20, .75); color: var(--suave); font-size: 10px; }
.mapa-tiendas.leaflet-container .leaflet-control-attribution a { color: var(--suave); }
.mapa-tiendas .globo-mapa { background: var(--sup2); color: var(--texto); border: 1px solid var(--linea); box-shadow: none; font-weight: 600; font-size: 12px; padding: 2px 7px; }
.mapa-tiendas .globo-mapa.leaflet-tooltip-top::before { border-top-color: var(--linea); }
.mapa-tiendas .globo-mapa.leaflet-tooltip-bottom::before { border-bottom-color: var(--linea); }
/* La tarjetita de la tienda que tocó: arriba del mapa y chica (las tiendas van más abajo: no tapa ninguna y el mapa no se mueve). */
.mapa-tiendas .ficha-mapa { position: absolute; top: 8px; left: 8px; right: 8px; z-index: 1001; display: flex; align-items: center; gap: 6px; padding: 7px 7px 7px 12px; border-radius: 12px; background: var(--sup2); border: 1px solid var(--linea); box-shadow: 0 6px 18px rgba(0, 0, 0, .45); line-height: 1.3; cursor: default; }
.mapa-tiendas .ficha-mapa[hidden] { display: none; }
.mapa-tiendas .ficha-mapa .textos { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mapa-tiendas .ficha-mapa .arriba { display: flex; align-items: center; gap: 8px; min-width: 0; }
.mapa-tiendas .ficha-mapa .nombre { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.mapa-tiendas .ficha-mapa .etiqueta-distancia { padding: 2px 8px; font-size: 12px; }
.mapa-tiendas .ficha-mapa .renglon { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mapa-tiendas .ficha-mapa .ok { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: rgba(43, 229, 160, .16); color: #2BE5A0; }
.mapa-tiendas .ficha-mapa .btn-icono { flex: none; }

/* Navegación inferior */
.nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); z-index: 30;
  width: 100%; max-width: var(--ancho);
  display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); gap: 2px;
  padding: 8px 6px calc(12px + var(--seguro-abajo)); background: var(--nav); border-top: 1px solid var(--nav-borde);
}
.nav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 52px; color: var(--tenue); font-size: 12px; font-weight: 600; }
.nav a[aria-current="page"] { color: var(--verde); font-weight: 700; }
.nav .icono-nav { position: relative; display: flex; }

/* Barra de acción inferior */
.accion {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); z-index: 30;
  width: 100%; max-width: var(--ancho);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 16px calc(16px + var(--seguro-abajo)); background: var(--nav); border-top: 1px solid var(--nav-borde);
}
.accion .resumen { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

/* Tarjetas de paquete (estilo tienda de juegos) */
.paquetes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
/* Título de un grupo dentro de la cuadrícula (Diamantes, Pases): ocupa todo el ancho. */
.paquetes .titulo-grupo { grid-column: 1 / -1; margin: 4px 0 -4px; font-size: 15px; font-weight: 800; color: var(--suave); }
.paquetes .titulo-grupo:first-child { margin-top: 0; }
.paquete { position: relative; display: flex; flex-direction: column; padding: 0; overflow: hidden; text-align: left; border-radius: 16px; border: 1px solid var(--linea); background: var(--sup); color: var(--texto); }
.paquete:hover { color: var(--texto); }
.paquete.elegible { border-width: 2px; }
.paquete[aria-pressed="true"] { border-color: var(--verde); }
.paquete .arte { position: relative; display: block; height: 112px; overflow: hidden; }
.paquete.compacto .arte { height: 96px; }
.paquete .arte img.foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.paquete .arte svg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
/* Imagen subida: PNG transparente a la derecha sobre el color; foto normal con sombra abajo para leer el número. */
.paquete .arte img.foto.recorte { inset: 8px 6px 8px auto; width: 60%; height: calc(100% - 16px); object-fit: contain; object-position: right center; }
.paquete .arte .sombra { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 30%, rgba(0,0,0,0.72) 100%); pointer-events: none; }
/* Fotos de Storage (p75): no se ven hasta que llegan completas (ui.js les pone «lista» al cargar) y entonces aparecen con
   un desvanecido; mientras, se ve lo de atrás (en las tarjetas, la copia chiquita de la foto, borrosa). Nunca una foto a
   la mitad. */
.paquete .arte .foto-mini { position: absolute; inset: -12px; background-size: cover; background-position: center; filter: blur(10px); }
img[src*="/v0/b/"]:not(.lista) { opacity: 0; }
img[src*="/v0/b/"].lista { transition: opacity .2s ease-out; }
@media (prefers-reduced-motion: reduce) { img[src*="/v0/b/"].lista { transition: none; } }
.paquete .bono { position: absolute; top: 10px; left: 10px; padding: 4px 8px; background: var(--verde); color: var(--sobre-verde); font-size: 12px; font-weight: 800; letter-spacing: 0.3px; clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%); }
.paquete .cantidad { position: absolute; left: 12px; bottom: 10px; display: flex; flex-direction: column; text-shadow: 0 1px 8px rgba(0,0,0,0.4); }
.paquete .cantidad .num { display: flex; align-items: baseline; gap: 4px; }
.paquete .cantidad .num b { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1; color: #fff; }
.paquete .cantidad .num i { font-style: normal; font-family: var(--display); font-size: 16px; font-weight: 700; line-height: 1; color: var(--amarillo); }
.paquete .cantidad small { margin-top: 3px; font-size: 10px; font-weight: 800; letter-spacing: 1.5px; color: #fff; }
/* Un pase: su nombre en grande (puede ir en dos renglones) en lugar del número de diamantes. */
.paquete .cantidad.pase { right: 12px; }
.paquete .cantidad .nombre-pase { font-family: var(--display); font-size: 19px; font-weight: 700; line-height: 1.08; color: #fff; overflow-wrap: anywhere; }
.paquete.compacto .cantidad .nombre-pase { font-size: 17px; }
/* Nombre de pase largo (más de 12 letras, como PASE MENSUAL BOOYAH): más chico, para que quepa completo. */
.paquete .cantidad .nombre-pase.largo { font-size: 15px; }
.paquete.compacto .cantidad .nombre-pase.largo { font-size: 14px; }
.paquete .palomita { position: absolute; top: 8px; right: 8px; width: 24px; height: 24px; display: none; align-items: center; justify-content: center; border-radius: 50%; background: var(--verde); color: var(--sobre-verde); box-shadow: 0 0 0 2px var(--fondo); }
.paquete[aria-pressed="true"] .palomita { display: flex; }
.paquete .cuerpo { display: flex; flex-direction: column; gap: 8px; padding: 10px 12px 12px; }
.paquete .titulo { font-size: 13px; font-weight: 700; line-height: 1.3; }
.precios { display: flex; align-items: center; gap: 8px; min-height: 34px; }
.precios .desc { flex: none; display: flex; align-items: center; height: 34px; padding: 0 7px; background: var(--naranja); color: var(--sobre-naranja); font-family: var(--display); font-size: 14px; font-weight: 700; clip-path: var(--chaflan-chico); }
.precios .antes { font-size: 12px; color: var(--tenue); text-decoration: line-through; }
.precios .ahora { font-family: var(--display); font-size: 15px; font-weight: 700; }
.reloj { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--naranja-texto); }
.boton-comprar { display: flex; align-items: center; justify-content: center; min-height: 42px; background: var(--verde); color: var(--sobre-verde); font-weight: 700; font-size: 15px; clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); }
/* Agotado (p69): se ve en gris, con su sello, y no se puede comprar. */
.paquete.agotado .arte > :not(.sello-agotado) { filter: grayscale(1) brightness(0.55); }
.paquete.agotado .arte > .foto-mini { filter: blur(10px) grayscale(1) brightness(0.55); }
/* El sello va arriba, al centro: así se sigue leyendo el número (abajo a la izquierda). Sin el bono (no aplica). */
.paquete.agotado .sello-agotado { position: absolute; top: 12px; left: 50%; transform: translateX(-50%) rotate(-4deg); padding: 5px 12px; border: 2px solid var(--naranja); border-radius: 6px; background: rgba(7, 15, 20, 0.8); color: var(--naranja-texto); font-family: var(--display); font-size: 15px; font-weight: 700; letter-spacing: 2px; white-space: nowrap; pointer-events: none; }
.paquete.compacto.agotado .sello-agotado { top: 10px; font-size: 13px; padding: 4px 10px; }
.paquete.agotado .bono { display: none; }
.paquete.agotado .titulo, .paquete.agotado .precios { opacity: 0.6; }
.paquete.agotado:disabled { opacity: 1; }
.boton-comprar.agotado { background: var(--sup2); color: var(--tenue); }

/* Opciones elegibles (tarjetas de radio) */
.opcion { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px 14px; border-radius: 14px; border: 2px solid var(--linea); background: var(--sup); color: var(--texto); text-align: left; }
.opcion[aria-pressed="true"] { border-color: var(--verde); background: var(--hl); }
.opcion .radio { flex: none; margin-top: 1px; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; border-radius: 50%; border: 2px solid var(--pendiente); }
.opcion[aria-pressed="true"] .radio { border-color: var(--verde); }
.opcion[aria-pressed="true"] .radio::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--verde); }
/* Una forma de pago que no se puede elegir en esta compra (por ejemplo, la tarjeta abajo del monto mínimo): en gris. */
.opcion:disabled { opacity: .5; cursor: not-allowed; }
.opcion:disabled .radio { border-color: var(--linea); }

/* Línea de tiempo del pedido */
.pasos { display: flex; flex-direction: column; padding: 6px 14px; border-radius: 16px; background: var(--sup); border: 1px solid var(--linea); }
.paso { display: flex; align-items: center; gap: 12px; min-height: 40px; font-size: 15px; color: var(--tenue); }
.paso .bolita { flex: none; width: 22px; height: 22px; display: flex; align-items: center; justify-content: center; border-radius: 50%; border: 2px solid var(--pendiente); }
.paso.hecho { color: var(--texto); font-weight: 600; }
.paso.hecho .bolita { background: var(--verde); border-color: var(--verde); color: var(--sobre-verde); }
.paso.actual { color: var(--naranja-texto); font-weight: 700; }
.paso.actual .bolita { border-color: var(--naranja); }
.paso.actual .bolita::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--naranja); }
.pasos.reglas { padding: 0; background: transparent; border: 0; gap: 8px; }
.pasos.reglas .paso { align-items: flex-start; min-height: 0; font-size: 14px; color: var(--suave); }
.pasos.reglas .bolita { background: var(--verde); border-color: var(--verde); color: var(--sobre-verde); font-size: 12px; font-weight: 700; }

/* Barras de ventas */
.barra-dato { display: block; height: 8px; border-radius: 999px; background: var(--sup2); overflow: hidden; }
.barra-dato > span { display: block; height: 100%; border-radius: 999px; background: var(--verde); }

/* Comprobante / imagen */
.comprobante { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 120px; border-radius: 12px; border: 1px dashed var(--borde-input); background: var(--sup2); color: var(--tenue); overflow: hidden; }
.comprobante img { width: 100%; max-height: 420px; object-fit: contain; background: #000; }
.banner { position: relative; min-height: 150px; border-radius: 16px; overflow: hidden; background: var(--sup); border: 1px solid var(--linea); }
/* El banner siempre se ve en proporción 12:5 (1200 × 500): si la imagen es de otra medida, se recorta parejo sin dejar huecos. */
.banner.con-imagen { min-height: 0; aspect-ratio: 12 / 5; }
.banner.con-imagen img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
@supports not (aspect-ratio: 1) { .banner.con-imagen img { position: static; height: auto; } }
/* Inicio: lo que todavía no tiene nada (sin banner, sin pedido pendiente…) no deja hueco. */
#banner:empty, #pendiente:empty, #extra:empty, #entregas:empty { display: none; }

/* Inicio: franja de confianza (3 datos en una tarjeta) y, debajo, las entregas recientes en una línea */
.confianza-grupo { display: flex; flex-direction: column; gap: 8px; }
.confianza { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); padding: 10px 4px; border-radius: 14px; background: var(--sup); border: 1px solid var(--linea); }
.confianza > div { display: flex; align-items: center; justify-content: center; gap: 7px; min-width: 0; padding: 0 6px; }
.confianza > div + div { border-left: 1px solid var(--linea); }
.confianza svg { flex: none; color: var(--verde); }
.confianza b { font-size: 12.5px; line-height: 1.15; overflow-wrap: anywhere; }
.entregas { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 9px 12px; border-radius: 12px; background: var(--sup); border: 1px solid var(--linea); font-size: 12.5px; }
/* Palomita de «entregado» (sin hora no lleva un puntito «en vivo»). */
.entregas .hecho { flex: none; display: flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: var(--hl); border: 1px solid var(--hl-borde); color: var(--verde); }
.entregas .que { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--tenue); }
.entregas .que.nueva { animation: entra .35s ease; }
.entregas .que b { color: var(--texto); }
.entregas .gema svg { vertical-align: -2px; }
@media (prefers-reduced-motion: reduce) { .entregas .que.nueva { animation: none; } }

/* Logos subidos desde el admin */
.logo-producto { flex: none; width: 44px; height: 44px; border-radius: 12px; object-fit: contain; background: var(--sup2); border: 1px solid var(--linea); }
.logo-producto.chico { width: 36px; height: 36px; border-radius: 10px; }
/* Un logo ancho se encoge para que nunca empuje los botones ni haga scroll de lado. */
.logo-marca { flex: 0 1 auto; min-width: 0; display: block; height: 36px; width: auto; max-width: 170px; object-fit: contain; object-position: left center; }
.bienvenida .logo .logo-marca { height: 72px; max-width: 100%; }

/* Botones flotantes: soporte por WhatsApp e "Instalar app" (siempre arriba de la barra de abajo) */
#flotantes { position: fixed; z-index: 40; right: max(16px, calc((100vw - var(--ancho)) / 2 + 16px)); bottom: calc(16px + var(--seguro-abajo));
  display: flex; align-items: center; gap: 10px; pointer-events: none; }
#flotantes > * { pointer-events: auto; }
.fab-soporte { flex: none; width: 56px; height: 56px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: #25D366; color: #FFFFFF; box-shadow: 0 6px 18px rgba(0,0,0,0.45); }
.fab-soporte:hover, .fab-soporte:active { color: #FFFFFF; filter: brightness(1.06); }
.fab-instalar { display: flex; align-items: center; height: 46px; border-radius: 999px; background: var(--sup2); border: 1px solid var(--hl-borde);
  box-shadow: 0 6px 18px rgba(0,0,0,0.45); overflow: hidden; }
.fab-instalar-boton { display: flex; align-items: center; gap: 8px; height: 100%; padding: 0 4px 0 16px; border: 0; background: transparent;
  color: var(--verde); font-weight: 700; font-size: 15px; white-space: nowrap; }
.fab-instalar-cerrar { width: 44px; height: 100%; display: flex; align-items: center; justify-content: center; border: 0; background: transparent; color: var(--tenue); }
body.con-flotantes .pantalla { padding-bottom: calc(84px + var(--seguro-abajo)); }
body.con-flotantes .pantalla.con-nav { padding-bottom: calc(168px + var(--seguro-abajo)); }
body.con-flotantes .pantalla.con-accion { padding-bottom: calc(178px + var(--seguro-abajo)); }
body.con-flotantes #toasts { bottom: calc(172px + var(--seguro-abajo)); }

/* Avisos emergentes y diálogos. El aviso no tapa los toques: lo que queda debajo (por ejemplo el siguiente paquete de la
   lista) se puede tocar mientras se ve. */
#toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(100px + var(--seguro-abajo)); z-index: 100; width: calc(100% - 32px); max-width: 488px; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { padding: 12px 14px; border-radius: 12px; background: var(--sup2); border: 1px solid var(--borde-input); color: var(--texto); font-size: 14px; font-weight: 600; box-shadow: 0 8px 24px rgba(0,0,0,0.45); pointer-events: none; animation: entra 0.18s ease-out; }
.toast.ok { border-color: var(--hl-borde); background: var(--hl); }
.toast.error { border-color: var(--naranja); }
@keyframes entra { from { transform: translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }
.velo { position: fixed; inset: 0; z-index: 90; display: flex; align-items: flex-end; justify-content: center; background: rgba(3,7,10,0.72); padding: 16px; }
.dialogo { width: 100%; max-width: 488px; max-height: 88vh; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding: 18px 16px calc(18px + var(--seguro-abajo)); border-radius: 18px; background: var(--sup); border: 1px solid var(--linea); animation: entra 0.18s ease-out; }
@media (min-width: 600px) { .velo { align-items: center; } }
/* Diálogo con campos: nunca más alto que lo que se ve (arriba del teclado). Los campos se recorren adentro y el título, el
   aviso de error y los botones se quedan siempre a la vista. */
.velo.con-campos { padding-top: max(16px, env(safe-area-inset-top, 0px)); }
.velo.con-campos .dialogo { max-height: 100%; }
.velo.con-campos .dialogo > * { flex-shrink: 0; }
.velo.con-campos .dialogo > .dialogo-cuerpo { flex: 0 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; gap: 14px; }
/* Con el teclado abierto: menos margen para que quepa más (abajo lo tapa el teclado, no hace falta el espacio del iPhone). */
.velo.con-campos.con-teclado { padding: max(8px, env(safe-area-inset-top, 0px)) 8px 8px; }
.velo.con-campos.con-teclado .dialogo { gap: 10px; padding-bottom: 14px; }
.velo.con-campos.con-teclado .dialogo > .dialogo-cuerpo { gap: 10px; }
.input[aria-invalid="true"] { border-color: var(--naranja); }

/* Estados vacíos y carga */
.vacio { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 28px 16px; text-align: center; color: var(--tenue); font-size: 14px; }
.esqueleto { border-radius: 16px; background: linear-gradient(90deg, var(--sup) 0%, var(--sup2) 50%, var(--sup) 100%); background-size: 200% 100%; animation: brillo 1.2s ease-in-out infinite; }
@keyframes brillo { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.cargando-pantalla { display: flex; min-height: 70vh; align-items: center; justify-content: center; }
.giro-grande { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--linea); border-top-color: var(--verde); animation: giro 0.8s linear infinite; }
/* Pantalla de arranque (index.html de cada app): el logo de BooyahStore sobre negro, del mismo tamaño y en el mismo
   lugar que en las pantallas de arranque del iPhone (iconos/inicio-*.jpg, de marca/hacer_iconos.py): el logo al 62 % del
   ancho (la imagen trae su margen negro, 664 px por 584 de logo: por eso 70.5 %) y su centro al 49 % del alto. En una
   pantalla grande no pasa de 470 px, ni de 2/3 del alto. --mitad: la mitad del alto de la imagen entre su ancho (en Tienda
   y Admin la imagen es cuadrada: trae la etiqueta abajo y el mismo negro arriba). Se quita sola cuando la app pinta su
   primera pantalla; si tarda, aparece la ruedita abajo del logo. */
.arranque { position: fixed; inset: 0; z-index: 50; background: #000; --a: min(70.5vw, 470px, 66vh); --mitad: 0.3554; }
.arranque.con-etiqueta { --mitad: 0.5; }
.arranque img { position: absolute; left: 50%; top: 49%; width: var(--a); height: auto; transform: translate(-50%, -50%); }
.arranque .giro-grande { position: absolute; left: 50%; top: calc(49% + var(--a) * var(--mitad) + 24px); margin-left: -17px; opacity: 0; animation: giro 0.8s linear infinite, aparece 0.3s ease 0.8s forwards; }
@keyframes aparece { to { opacity: 1; } }

/* Bienvenida / inicio de sesión */
.bienvenida { display: flex; flex-direction: column; gap: 18px; padding: calc(40px + var(--seguro-arriba)) 20px 32px; min-height: 100dvh; }
.bienvenida .logo { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.bienvenida .logo b { font-family: var(--display); font-size: 26px; letter-spacing: 3px; }
.bienvenida .logo .nombre-marca { width: 280px; }
.separador { display: flex; align-items: center; gap: 12px; color: var(--tenue); font-size: 13px; }
.separador::before, .separador::after { content: ''; flex: 1; height: 1px; background: var(--linea); }
.btn-google { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; border-radius: 12px; border: 1px solid var(--borde-input); background: #fff; color: #1f1f1f; font-weight: 700; font-size: 16px; }
/* Mientras Google se prepara (en Safari): «Preparando Google…», sin poder tocarlo, menos apagado que un botón desactivado. */
.btn-google[aria-busy] { opacity: 0.8; cursor: progress; }

.texto-largo { white-space: pre-wrap; font-size: 14px; line-height: 1.55; color: var(--suave); }
.decoracion { position: absolute; top: -70px; right: -90px; opacity: 0.08; pointer-events: none; }

/* QR del folio y escáner de la tienda */
.qr-caja { display: flex; align-items: center; justify-content: center; min-width: 212px; min-height: 212px; padding: 14px; border-radius: 14px; background: #FFFFFF; line-height: 0; }
.qr-caja .giro-grande { border-color: #D7E2E4; border-top-color: #0E7C86; }
.escaner { position: fixed; inset: 0; z-index: 95; display: flex; flex-direction: column; background: #000; }
.escaner video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.escaner .marco { position: absolute; left: 50%; top: 42%; width: 240px; height: 240px; transform: translate(-50%, -50%); border-radius: 18px; border: 3px solid var(--verde); box-shadow: 0 0 0 9999px rgba(0,0,0,0.45); }
.escaner .abajo { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; gap: 12px; padding: 18px 16px calc(20px + var(--seguro-abajo)); background: linear-gradient(transparent, rgba(0,0,0,0.85) 30%); }
.escaner .estado { color: #fff; font-weight: 600; text-align: center; }

/* Ticket de una venta (app de tiendas): cómo se ve en la ventanita y, al imprimir, solo el ticket a 58 mm de ancho. */
.ticket-vista { padding: 10px; border-radius: 12px; background: #FFFFFF; max-height: 50vh; overflow-y: auto; overscroll-behavior: contain; }
.ticket-vista img { width: 100%; max-width: 288px; height: auto; margin: 0 auto; }
#ticket-hoja { display: none; }
/* Historial de pedidos (Admin): en pantalla no se ve; al imprimir desde esa pantalla sale solo su hoja (una tabla en blanco
   y negro, con los encabezados en cada hoja). */
#historial-hoja { display: none; }
@media print {
  body.imprimiendo { background: #FFFFFF; }
  body.imprimiendo > :not(#ticket-hoja) { display: none !important; }
  body.imprimiendo #ticket-hoja { display: block; }
  #ticket-hoja img { width: 58mm; max-width: 100%; height: auto; }
  body.con-historial { background: #FFFFFF; }
  body.con-historial > :not(#historial-hoja) { display: none !important; }
  body.con-historial #historial-hoja { display: block; color: #000000; background: #FFFFFF; font: 8pt/1.35 -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }
  #historial-hoja h1 { font-size: 13pt; margin: 0 0 2pt; color: #000000; }
  #historial-hoja .sub { margin: 0 0 8pt; color: #333333; }
  #historial-hoja table { width: 100%; border-collapse: collapse; }
  #historial-hoja thead { display: table-header-group; }
  #historial-hoja tr { break-inside: avoid; }
  #historial-hoja th, #historial-hoja td { border-bottom: 0.5pt solid #999999; padding: 3pt 4pt; text-align: left; vertical-align: top; color: #000000; }
  #historial-hoja th { border-bottom: 1pt solid #000000; font-weight: 700; }
  #historial-hoja .num { text-align: right; white-space: nowrap; }
  #historial-hoja .c { white-space: nowrap; }
  /* El total, una sola vez al final (sin esto, Chrome lo repite abajo de cada hoja). */
  #historial-hoja tfoot { display: table-row-group; }
  #historial-hoja tfoot td { font-weight: 700; border-top: 1pt solid #000000; border-bottom: none; }
}

/* ---------- Tarjeta del jugador (p66): foto y datos de su cuenta de Free Fire al escribir su ID ---------- */
.tj { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: 16px; background: var(--hl); border: 1px solid var(--hl-borde); }
.tj-fila { display: flex; gap: 14px; align-items: center; min-width: 0; }
.tj-foto { position: relative; flex: none; width: 68px; height: 68px; clip-path: var(--chaflan); background: linear-gradient(135deg, var(--verde), #157A5A); }
.tj-foto > img, .tj-inicial { position: absolute; inset: 2px; width: calc(100% - 4px); height: calc(100% - 4px); clip-path: var(--chaflan); }
.tj-foto > img { display: block; object-fit: cover; background: var(--sup2); }
.tj-inicial { display: grid; place-items: center; background: var(--sup2); color: var(--verde); font-family: var(--display); font-weight: 700; font-size: 30px; }
.tj-datos { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.tj-ok { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; font-family: var(--display); font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--verde); text-transform: uppercase; }
.tj-nick { font-family: var(--display); font-weight: 700; font-size: 22px; line-height: 1.1; color: var(--texto); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tj-uidfila { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.tj-uid { font-family: var(--display); font-size: 13px; letter-spacing: .06em; color: var(--tenue); white-space: nowrap; }
.tj-nivel { flex: none; white-space: nowrap; display: inline-flex; align-items: center; height: 22px; padding: 0 8px; clip-path: var(--chaflan-chico); background: var(--naranja); color: var(--sobre-naranja); font-family: var(--display); font-weight: 700; font-size: 12px; letter-spacing: .04em; }
.tj-mas { flex: none; align-self: center; width: 34px; height: 34px; padding: 0; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--hl-borde); background: rgba(43, 229, 160, .08); color: var(--verde); }
.tj-mas svg { transition: transform .2s ease; }
.tj.abierta .tj-mas svg { transform: rotate(180deg); }
.tj-extra { padding-top: 10px; border-top: 1px solid var(--hl-borde); }
.tj-extra[hidden] { display: none; }
.tj-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.tj-chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 999px; background: rgba(43, 229, 160, .08); border: 1px solid var(--hl-borde); color: var(--suave); font-size: 13px; font-weight: 600; white-space: nowrap; }
.tj-chip svg { flex: none; color: var(--verde); }
.tj-chip.tj-prime svg { color: var(--amarillo); }
.tj-chip b { color: var(--texto); }
.tj-pase { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: #2A230E; border: 1px solid #6B5A1E; color: var(--amarillo); font-size: 14px; line-height: 1.4; }
.tj-pase svg { flex: none; margin-top: 1px; }
.tj-ok svg { flex: none; }
/* Celulares angostos: un poco más chicos la foto, los espacios y el letrero, para que «Cuenta encontrada» (con su
   palomita) quepa junto a la flecha sin tocarla. En los más angostos (320) se quita la palomita. */
@media (max-width: 400px) {
  .tj-fila { gap: 10px; }
  .tj-foto { width: 60px; height: 60px; }
  .tj-inicial { font-size: 26px; }
  .tj-ok { gap: 5px; font-size: 11px; letter-spacing: .06em; }
}
@media (max-width: 340px) {
  .tj-foto { width: 54px; height: 54px; }
  .tj-ok svg { display: none; }
}
@media (prefers-reduced-motion: reduce) { .tj-mas svg { transition: none; } }
