/* Día de partido — hoja propia, prefijo simple porque la página es solo esta app.
   Reglas del design system de 1950foto:
     · Carbón #101418 de fondo, celeste #A5DDF3 como única voz de marca.
     · Archivo Black SOLO en titulares y cifras; Instrument Sans en toda la UI.
     · Verde y rojo únicamente como estado (ok / roto / en vivo).
   Lenguaje visual iOS: tarjetas insertas agrupadas, segmentos, hojas con manija,
   caras y escudos en vez de texto pelado. Y denso: nada de listas interminables —
   lo largo se pliega y se busca. */

@import url('https://fonts.googleapis.com/css2?family=Instrument+Sans:wght@400;500;600;700&display=swap');

@font-face {
  font-family: 'Archivo Black';
  src: url('/fonts/ArchivoBlack-latin.woff2') format('woff2');
  font-weight: 400 900; font-style: normal; font-display: swap;
}

:root {
  --carbon: #101418;
  --sup: #171C21;
  --sup-alt: #232B33;
  --borde: #232B33;
  --borde-fuerte: #2E3841;
  --texto: #F5F7F8;
  --texto-sec: #9DB0BC;
  --celeste: #A5DDF3;
  --celeste-ink: #0C2E40;
  --verde: #2F7A45;
  --verde-claro: #7BC48F;
  --rojo: #E24B4A;
  --ambar: #E2B45F;

  --display: 'Archivo Black', system-ui, sans-serif;
  /* Tracking de marca: -0.05em = el -50 con el que Juan compone en Illustrator. */
  --tracking-display: -0.05em;
  --body: 'Instrument Sans', system-ui, -apple-system, sans-serif;

  --barra-alta: calc(52px + env(safe-area-inset-top));
  --tabs-alta: calc(50px + env(safe-area-inset-bottom));
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; padding: 0;
  background: var(--carbon); color: var(--texto);
  font-family: var(--body); font-size: 16px; line-height: 1.4;
  /* La app no scrollea entera: scrollea la vista de adentro. Sin esto el rebote de
     Safari arrastra la barra y la tab bar y se ve como una web, no como una app. */
  height: 100%; overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

.oculto { display: none !important; }
.display { font-family: var(--display); font-weight: 900; letter-spacing: var(--tracking-display); }

/* ─────────────── Puerta ─────────────── */
.puerta { position: fixed; inset: 0; display: grid; place-items: center; padding: 24px; }
.puerta-caja { width: min(340px, 100%); text-align: center; }
.puerta-caja h1 { font-size: 30px; margin: 0 0 20px; }
.linea { display: flex; gap: 8px; justify-content: center; }
.linea input {
  width: 190px; padding: 11px 12px; font: inherit;
  background: var(--sup-alt); color: var(--texto);
  border: 1px solid var(--borde-fuerte); border-radius: 10px;
}
.linea button {
  padding: 11px 16px; font: inherit; font-weight: 600;
  background: var(--celeste); color: var(--celeste-ink);
  border: 0; border-radius: 10px;
}
.pie { font-size: 11px; color: var(--texto-sec); }
.error { color: var(--rojo); }

/* ─────────────── Barra y tabs ─────────────── */
.barra {
  position: fixed; top: 0; left: 0; right: 0; z-index: 20;
  height: var(--barra-alta); padding: env(safe-area-inset-top) 14px 0;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: rgba(16,20,24,.82);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--borde);
}
.barra-titulo { min-width: 0; display: flex; flex-direction: column; justify-content: center; }
/* El logotipo de la app: "matchday" en celeste pegado al wordmark de 1950foto,
   como una sola pieza. El img es inline para que su base caiga sobre la línea de
   base del texto — así el 1950 se apoya donde apoya la "matchday". */
/* Las medidas salen de la tipografía, no del ojo: en Archivo Black la "d" sube
   0,725em, y en el SVG los dígitos ocupan 62,46 de las 70 unidades del viewBox
   (el resto es el FOTO volado y un pelín de aire abajo). Para que el 1950 mida
   igual que la "d": alto = 0,725 / 0,892 = 0,8125em. El desplazamiento vertical
   apoya los dígitos en la misma línea de base que el texto. */
.lock { display: block; white-space: nowrap; line-height: 1; font-size: 19px; }
.lock-md {
  font-family: var(--display); font-weight: 900; font-size: 1em; color: var(--celeste);
  letter-spacing: var(--tracking-display); text-transform: lowercase;
}
.lock-logo {
  height: 0.8125em; vertical-align: -0.044em;
  /* El tracking negativo también se aplica después de la última letra: este margen
     lo compensa y deja el aire justo que tiene el logo original. */
  margin-left: 0.1em;
}
.lock-grande { margin: 0 0 18px; font-size: 34px; }
.barra-titulo .pie { line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icono { background: none; border: 0; color: var(--texto-sec); font-size: 19px; padding: 6px; line-height: 1; }

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  height: var(--tabs-alta); padding-bottom: env(safe-area-inset-bottom);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(16,20,24,.82);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--borde);
}
.tab {
  background: none; border: 0; color: var(--texto-sec);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font: inherit; font-size: 10px; padding: 0;
}
.tab svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tab.activo { color: var(--celeste); }

main {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  padding: calc(var(--barra-alta) + 10px) 0 calc(var(--tabs-alta) + 16px);
  overflow-y: auto; -webkit-overflow-scrolling: touch;
}
.vista { display: none; padding: 0 14px; }
.vista.activa { display: block; }

/* ─────────────── Tarjetas agrupadas ─────────────── */
.grupo { margin: 0 0 14px; }
.grupo > h2 {
  font-family: var(--body); font-size: 11px; font-weight: 600;
  color: var(--texto-sec); text-transform: uppercase; letter-spacing: .08em;
  margin: 0 0 6px 4px;
  display: flex; align-items: center; gap: 6px;
}
.grupo > h2 .extra { margin-left: auto; text-transform: none; letter-spacing: 0; font-weight: 500; }
.tarjeta { background: var(--sup); border: 1px solid var(--borde); border-radius: 14px; overflow: hidden; }

.fila {
  display: flex; align-items: center; gap: 10px;
  min-height: 40px; padding: 8px 13px;
  border-top: 1px solid var(--borde);
  font-size: 14px;
}
.fila:first-child { border-top: 0; }
.fila .k { color: var(--texto-sec); flex: 0 0 auto; display: flex; align-items: center; gap: 8px; }
.fila .k .ic { font-size: 15px; width: 20px; text-align: center; }
.fila .v { margin-left: auto; text-align: right; font-weight: 500; white-space: nowrap; }
.fila .v.grande { font-family: var(--display); font-size: 18px; letter-spacing: var(--tracking-display); }
.fila.tocable { cursor: pointer; }
.fila.tocable::after { content: '›'; color: var(--texto-sec); font-size: 17px; margin-left: 4px; }
.fila .sub { display: block; font-size: 11px; color: var(--texto-sec); font-weight: 400; }

.acento { color: var(--celeste); }
.ok { color: var(--verde-claro); }
.mal { color: var(--rojo); }
.ojo { color: var(--ambar); }
.tenue { color: var(--texto-sec); }

/* ─────────────── Hero del partido (escudos + cuenta) ─────────────── */
.hero {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 6px;
  padding: 16px 10px 14px; text-align: center;
}
.hero .eq { display: flex; flex-direction: column; align-items: center; gap: 7px; min-width: 0; }
.hero .eq img { width: 52px; height: 52px; object-fit: contain; filter: drop-shadow(0 2px 6px rgba(0,0,0,.4)); }
.hero .eq .sinlogo {
  width: 52px; height: 52px; border-radius: 50%; background: var(--sup-alt);
  display: grid; place-items: center; font-family: var(--display); font-size: 19px; color: var(--texto-sec); letter-spacing: var(--tracking-display); }
.hero .eq b { font-size: 12.5px; font-weight: 600; line-height: 1.2; max-width: 110px; }
.hero .centro { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 0 4px; }
.hero .cifra { font-family: var(--display); font-size: 40px; letter-spacing: var(--tracking-display); line-height: 1; }
.hero .cuenta { font-family: var(--display); font-size: 21px; color: var(--celeste); line-height: 1.1; letter-spacing: var(--tracking-display); }
.hero .hora-txt { font-size: 12px; color: var(--texto-sec); }
.hero .vs { font-family: var(--display); font-size: 15px; color: var(--texto-sec); letter-spacing: var(--tracking-display); }

.envivo {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--rojo); font-weight: 700;
}
.envivo::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--rojo); animation: late 1.6s infinite; }
@keyframes late { 0%,100% { opacity: 1 } 50% { opacity: .25 } }

.hero-pie {
  display: flex; justify-content: center; gap: 14px;
  padding: 0 12px 12px; font-size: 12px; color: var(--texto-sec);
  flex-wrap: wrap;
}

/* ─────────────── Clima visual ─────────────── */
.clima-cab { display: flex; align-items: center; gap: 12px; padding: 12px 14px 8px; }
.clima-cab .emoji { font-size: 40px; line-height: 1; }
.clima-cab .temp { font-family: var(--display); font-size: 34px; letter-spacing: var(--tracking-display); }
.clima-cab .desc { display: flex; flex-direction: column; gap: 1px; }
.clima-cab .desc b { font-size: 14px; font-weight: 600; }
.clima-cab .desc span { font-size: 11px; color: var(--texto-sec); }
.clima-strip {
  display: flex; gap: 4px; overflow-x: auto; padding: 4px 10px 12px;
  scrollbar-width: none;
}
.clima-strip::-webkit-scrollbar { display: none; }
.clima-h {
  flex: 0 0 auto; min-width: 56px; text-align: center;
  background: var(--sup-alt); border-radius: 10px; padding: 7px 6px;
  display: flex; flex-direction: column; gap: 2px;
}
.clima-h .hh { font-size: 10px; color: var(--texto-sec); }
.clima-h .em { font-size: 19px; }
.clima-h .tt { font-size: 13px; font-weight: 600; }
.clima-h .ll { font-size: 10px; color: var(--celeste); min-height: 13px; }

/* ─────────────── Mini-stats (fotos) ─────────────── */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 11px 6px; text-align: center;
}
.stats .st { border-left: 1px solid var(--borde); }
.stats .st:first-child { border-left: 0; }
.stats .n { font-family: var(--display); font-size: 21px; line-height: 1.15; letter-spacing: var(--tracking-display); }
.stats .l { font-size: 10px; color: var(--texto-sec); }

/* ─────────────── Segmentos iOS ─────────────── */
.segmentos {
  display: flex; background: var(--sup-alt); border-radius: 10px; padding: 2.5px;
  margin: 0 0 8px;
}
.segmentos button {
  flex: 1; border: 0; background: none; color: var(--texto-sec);
  font: inherit; font-size: 12.5px; font-weight: 600; padding: 7px 4px;
  border-radius: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.segmentos button.activo { background: #3A4550; color: var(--texto); box-shadow: 0 1px 3px rgba(0,0,0,.3); }

/* ─────────────── Buscador ─────────────── */
.buscar {
  display: flex; align-items: center; gap: 7px;
  background: var(--sup-alt); border-radius: 10px; padding: 8px 11px; margin: 0 0 8px;
}
.buscar svg { width: 15px; height: 15px; stroke: var(--texto-sec); fill: none; stroke-width: 2; flex: 0 0 auto; }
.buscar input {
  flex: 1; border: 0; background: none; color: var(--texto); font: inherit; font-size: 14px;
  outline: none; min-width: 0;
}
.buscar input::placeholder { color: var(--texto-sec); }

/* ─────────────── Chips de filtro ─────────────── */
.filtros { display: flex; gap: 6px; overflow-x: auto; padding: 0 0 10px; scrollbar-width: none; }
.filtros::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; font: inherit; font-size: 12px; font-weight: 500;
  padding: 5.5px 12px; border-radius: 999px;
  background: var(--sup-alt); color: var(--texto-sec); border: 1px solid var(--borde);
}
.chip.activo { background: var(--celeste); color: var(--celeste-ink); border-color: var(--celeste); font-weight: 600; }

/* ─────────────── Personas: avatar + fila ─────────────── */
.persona {
  display: grid; grid-template-columns: 34px 1fr auto auto; align-items: center; gap: 10px;
  padding: 5px 12px; min-height: 44px;
  border-top: 1px solid var(--borde); font-size: 13.5px;
}
.persona:first-child { border-top: 0; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; object-fit: cover;
  background: var(--sup-alt); flex: 0 0 auto;
}
.avatar.inicial {
  display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--texto-sec);
}
.persona .quien { min-width: 0; }
.persona .nombre { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 500; display: block; }
.persona .det { font-size: 10.5px; color: var(--texto-sec); display: flex; align-items: center; gap: 5px; }
.persona .marcas { display: flex; gap: 3px; }
.persona .n { font-family: var(--display); font-size: 14px; min-width: 24px; text-align: right; letter-spacing: var(--tracking-display); }
.persona .n.cero { color: var(--rojo); }

.marca {
  font-size: 9px; font-weight: 700; letter-spacing: .04em;
  padding: 1.5px 5px; border-radius: 4px; line-height: 1.5;
}
.marca.m { background: rgba(165,221,243,.16); color: var(--celeste); }
.marca.c { background: rgba(47,122,69,.22); color: var(--verde-claro); }
.marca.v { background: rgba(200,145,47,.2); color: var(--ambar); }
.marca.o { background: rgba(157,176,188,.16); color: var(--texto-sec); }

.vermas {
  display: block; width: 100%; padding: 11px; border: 0; border-top: 1px solid var(--borde);
  background: none; color: var(--celeste); font: inherit; font-size: 13px; font-weight: 600;
}

/* ─────────────── Plegables ─────────────── */
.plegable-cab { user-select: none; }
.plegable-cab .flecha { color: var(--texto-sec); font-size: 13px; transition: transform .18s; display: inline-block; }
.plegable-cab.abierto .flecha { transform: rotate(90deg); }

/* Progreso del checklist */
.aro { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; }
.aro svg { width: 22px; height: 22px; transform: rotate(-90deg); }
.aro .fondo { stroke: var(--sup-alt); }
.aro .valor { stroke: var(--celeste); stroke-linecap: round; }
.aro.listo .valor { stroke: var(--verde-claro); }

/* ─────────────── Checklist ─────────────── */
.check { display: flex; align-items: center; gap: 11px; padding: 7px 13px; min-height: 40px; border-top: 1px solid var(--borde); font-size: 14px; }
.check input { appearance: none; width: 21px; height: 21px; border-radius: 50%; border: 1.6px solid var(--borde-fuerte); flex: 0 0 auto; position: relative; }
.check input:checked { background: var(--celeste); border-color: var(--celeste); }
.check input:checked::after {
  content: '✓'; position: absolute; inset: 0; display: grid; place-items: center;
  color: var(--celeste-ink); font-size: 12px; font-weight: 700;
}
.check input:checked + span { color: var(--texto-sec); text-decoration: line-through; }
.check .quitar { margin-left: auto; color: var(--texto-sec); background: none; border: 0; font-size: 15px; padding: 2px 4px; }

/* ─────────────── Pills de estado (importador) ─────────────── */
.pills { display: flex; flex-wrap: wrap; gap: 6px; padding: 11px 12px; }
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--sup-alt); border-radius: 999px; padding: 5.5px 11px;
  font-size: 12px; font-weight: 500;
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--texto-sec); flex: 0 0 auto; }
.pill.ok .dot { background: var(--verde-claro); }
.pill.mal .dot { background: var(--rojo); }
.pill.mal { color: var(--rojo); }
.pill.ojo .dot { background: var(--ambar); }
.pill.ojo { color: var(--ambar); }

/* ─────────────── Tabla de posiciones ─────────────── */
.tabla { width: 100%; border-collapse: collapse; font-size: 12px; }
.tabla th {
  font-weight: 600; font-size: 9.5px; color: var(--texto-sec);
  text-transform: uppercase; letter-spacing: .06em;
  padding: 6px 4px; text-align: right; border-bottom: 1px solid var(--borde);
}
.tabla th:nth-child(2) { text-align: left; }
.tabla td { padding: 4.5px 4px; text-align: right; border-top: 1px solid var(--borde); }
.tabla td:nth-child(2) { text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 130px; }
.tabla tr.mio td { background: rgba(165,221,243,.07); }
.tabla tr.mio td:nth-child(2) { color: var(--celeste); font-weight: 600; }
.tabla td.pts { font-weight: 700; }

/* Cómo puede salir: la barra de tres tramos y los tres porcentajes */
.prob-barra { display: flex; height: 8px; margin: 13px 13px 11px; border-radius: 999px; overflow: hidden; background: var(--sup-alt); }
.prob-barra span { display: block; height: 100%; }
.prob-barra .p-local { background: var(--verde-claro); }
.prob-barra .p-empate { background: var(--borde-fuerte); }
.prob-barra .p-visita { background: var(--rojo); }
.prob-nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 0 13px 10px; text-align: center; }
.prob-nums b { display: block; font-family: var(--display); font-size: 22px; letter-spacing: var(--tracking-display); }
.prob-nums .p-l { color: var(--verde-claro); }
.prob-nums .p-e { color: var(--texto); }
.prob-nums .p-v { color: var(--rojo); }
.prob-nums span { font-size: 10.5px; color: var(--texto-sec); display: block; line-height: 1.2; }

/* Selector de tablas y tablas con escudo */
.tablas-caja { padding: 10px 12px 10px; border-top: 1px solid var(--borde); }
.tablas-seg { overflow-x: auto; scrollbar-width: none; }
.tablas-seg::-webkit-scrollbar { display: none; }
.tablas-seg button { flex: 0 0 auto; padding: 7px 12px; }

/* Tablas con escudo: anual, promedios, clausura */
.tabla-pos td:nth-child(2) { display: flex; align-items: center; gap: 6px; max-width: none; }
.tlogo { width: 16px; height: 16px; object-fit: contain; flex: 0 0 auto; }
.tabla-pos .np { color: var(--texto-sec); width: 22px; }
.tabla-pos tr.z-arriba td:first-child { box-shadow: inset 2px 0 0 var(--celeste); }
.tabla-pos tr.z-abajo td:first-child { box-shadow: inset 2px 0 0 var(--rojo); }
.tabla-pos tr.z-abajo td.pts { color: var(--rojo); }
.grupo > h2 .tlogo { width: 15px; height: 15px; }
.fila .pos { font-family: var(--display); font-size: 15px; letter-spacing: var(--tracking-display); }

/* Forma: G/E/P en cuadraditos */
.forma { display: flex; gap: 3px; }
.forma span {
  width: 19px; height: 19px; border-radius: 5px;
  font-size: 10px; font-weight: 700; display: grid; place-items: center;
}
.forma .G { background: rgba(47,122,69,.28); color: var(--verde-claro); }
.forma .E { background: rgba(157,176,188,.18); color: var(--texto-sec); }
.forma .P { background: rgba(226,75,74,.2); color: #F08281; }
.forma-fila { display: flex; align-items: center; gap: 9px; padding: 9px 13px; border-top: 1px solid var(--borde); }
.forma-fila:first-child { border-top: 0; }
.forma-fila img { width: 24px; height: 24px; object-fit: contain; }
.forma-fila b { font-size: 13px; font-weight: 600; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ─────────────── Noticias: pila con gestos ─────────────── */
/* Una arriba de la otra. Se arrastra a la izquierda para darla por leída y a la
   derecha para abrir la nota; los botones de abajo hacen lo mismo. */
.tin {
  position: relative; height: 58vh; min-height: 340px; max-height: 480px;
  margin-bottom: 12px;
}
.tin-card {
  position: absolute; inset: 0; display: flex; flex-direction: column; overflow: hidden;
  background: var(--sup); border: 1px solid var(--borde); border-radius: 16px;
  box-shadow: 0 6px 20px rgba(0,0,0,.35);
  transform-origin: 50% 100%;
  touch-action: pan-y;             /* el gesto horizontal es nuestro; el vertical scrollea */
  -webkit-user-select: none; user-select: none;
}
.tin-card.frente { cursor: grab; }
.tin-card img { width: 100%; flex: 0 0 44%; object-fit: cover; background: var(--sup-alt); }
.tin-cuerpo { padding: 13px 15px 15px; display: flex; flex-direction: column; gap: 7px; flex: 1; min-height: 0; }
.tin-fuente { font-size: 10.5px; color: var(--texto-sec); text-transform: uppercase; letter-spacing: .06em; }
.tin-tit {
  font-size: 17px; font-weight: 700; line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.tin-resumen {
  margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--texto-sec);
  display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden;
}
.tin-resumen.pendiente { opacity: .5; font-style: italic; }
/* Sin resumen propio: es el copete del feed, y la tarjeta lo dice. */
.tin-resumen.copete::after { content: ' — copete del medio'; color: var(--texto-sec); opacity: .7; font-size: 11px; }
/* Sin foto sobra media tarjeta: se le da más aire al resumen en vez de dejar el hueco. */
.tin-card.sin-foto .tin-tit { font-size: 19px; -webkit-line-clamp: 4; }
.tin-card.sin-foto .tin-resumen { font-size: 14.5px; -webkit-line-clamp: 14; }

/* Los sellos que aparecen al arrastrar, como el LIKE/NOPE de Tinder. */
.tin-sello {
  position: absolute; top: 16px; z-index: 2; opacity: 0; pointer-events: none;
  font-family: var(--display); font-size: 15px; letter-spacing: var(--tracking-display);
  padding: 5px 12px; border-radius: 8px; border: 2px solid currentColor; text-transform: uppercase;
}
.tin-sello.izq { left: 16px; color: var(--texto-sec); transform: rotate(-12deg); }
.tin-sello.der { right: 16px; color: var(--celeste); transform: rotate(12deg); }

.tin-acciones { display: flex; justify-content: center; gap: 22px; }
.tin-btn {
  width: 52px; height: 52px; border-radius: 50%; font-size: 20px;
  background: var(--sup); color: var(--texto-sec);
  border: 1px solid var(--borde-fuerte);
}
.tin-btn.abrir { color: var(--celeste); border-color: rgba(165,221,243,.4); }

.tin-fin {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 6px; padding: 24px; text-align: center;
  background: var(--sup); border: 1px solid var(--borde); border-radius: 16px;
}
.tin-fin-tilde {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(47,122,69,.18); color: var(--verde-claro); font-size: 22px; margin-bottom: 4px;
}
.tin-fin b { font-size: 16px; }
.tin-fin .boton { width: auto; padding: 10px 18px; margin-top: 10px; }

/* ─────────────── Radio ─────────────── */
.radio-card { padding: 16px 14px; display: flex; align-items: center; gap: 14px; }
.radio-card .bola {
  width: 58px; height: 58px; border-radius: 50%; flex: 0 0 auto; border: 0;
  background: var(--celeste); color: var(--celeste-ink);
  display: grid; place-items: center; font-size: 22px;
}
.radio-card.sonando .bola { animation: pulso 2.2s infinite; }
@keyframes pulso { 0%,100% { box-shadow: 0 0 0 0 rgba(165,221,243,.35) } 50% { box-shadow: 0 0 0 10px rgba(165,221,243,0) } }
.radio-card .info b { display: block; font-size: 16px; font-weight: 700; }
.radio-card .info span { font-size: 12px; color: var(--texto-sec); }
.radio-card.sonando .info span { color: var(--rojo); font-weight: 600; }

/* ─────────────── Botones y hoja ─────────────── */
.boton {
  display: block; width: 100%; padding: 12px; margin-top: 8px;
  font: inherit; font-weight: 600; font-size: 14px;
  background: var(--sup-alt); color: var(--texto);
  border: 1px solid var(--borde-fuerte); border-radius: 12px; text-align: center; text-decoration: none;
}
.boton.principal { background: var(--celeste); color: var(--celeste-ink); border-color: var(--celeste); }

.hoja { position: fixed; inset: 0; z-index: 40; }
.hoja-fondo { position: absolute; inset: 0; background: rgba(0,0,0,.5); }
.hoja-caja {
  position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; overflow-y: auto;
  background: var(--carbon); border-radius: 16px 16px 0 0;
  padding: 8px 14px calc(20px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--borde);
}
.manija { width: 36px; height: 4px; border-radius: 2px; background: var(--borde-fuerte); margin: 0 auto 12px; }

.vacio { text-align: center; color: var(--texto-sec); font-size: 13px; padding: 30px 12px; }

/* Interruptor iOS */
.sw { appearance: none; margin-left: auto; width: 46px; height: 27px; border-radius: 999px; background: var(--sup-alt); border: 1px solid var(--borde-fuerte); position: relative; flex: 0 0 auto; }
.sw::after { content: ''; position: absolute; top: 2px; left: 2px; width: 21px; height: 21px; border-radius: 50%; background: var(--texto); transition: transform .16s; }
.sw:checked { background: var(--verde); border-color: var(--verde); }
.sw:checked::after { transform: translateX(19px); }

.mini { margin-left: auto; width: 72px; padding: 7px 9px; font: inherit; font-size: 14px; text-align: right;
  background: var(--sup-alt); color: var(--texto); border: 1px solid var(--borde-fuerte); border-radius: 8px; }

/* Ficha de persona en la hoja */
.ficha-cab { display: flex; align-items: center; gap: 13px; margin: 2px 0 14px; }
.ficha-cab .avatar { width: 58px; height: 58px; font-size: 19px; }
.ficha-cab h2 { margin: 0; font-size: 21px; }
.ficha-cab .pie { margin: 2px 0 0; }

/* ─────────────── Próximos partidos ─────────────── */
/* Hora a la izquierda separada por un filete, los dos equipos apilados y la cancha
   abajo. Con nombres como "Montevideo City Torque" una sola línea siempre se corta. */
.fx {
  display: grid; grid-template-columns: 50px 1fr auto; align-items: center; gap: 13px;
  padding: 12px 14px; border-top: 1px solid var(--borde);
}
.fx:first-child { border-top: 0; }

.fx-hora {
  position: relative; text-align: center;
  font-family: var(--display); font-size: 15px; letter-spacing: var(--tracking-display);
  font-variant-numeric: tabular-nums;
}
/* Filete que separa la hora de los equipos: ordena la fila sin agregar una línea más. */
.fx-hora::after {
  content: ''; position: absolute; right: -7px; top: -2px; bottom: -2px;
  width: 1px; background: var(--borde);
}

.fx-cuerpo { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.fx-eq {
  display: flex; align-items: center; gap: 9px;
  font-size: 14.5px; font-weight: 600; line-height: 1.15;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* Círculo detrás del escudo: los emblemas vienen de mil formas y tamaños, y así
   todas las filas se leen alineadas. */
.fx-esc {
  width: 24px; height: 24px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center; background: rgba(255,255,255,.05);
}
.fx-esc img { width: 18px; height: 18px; object-fit: contain; }

.fx-cancha { display: flex; align-items: center; gap: 4px; font-size: 10.5px; color: var(--texto-sec); margin-top: 1px; }
.fx-pin { width: 11px; height: 11px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; opacity: .8; }

.fx-pie { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 1px; }
.fx-copa {
  font-size: 9px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
  padding: 2px 6px; border-radius: 4px;
  background: rgba(226,180,95,.16); color: var(--ambar);
}

/* "Voy": lo que decide si el partido aparece como el del día. */
.fx-voy-btn {
  font: inherit; font-size: 11px; font-weight: 700; letter-spacing: .02em;
  padding: 6px 11px; border-radius: 999px; white-space: nowrap;
  background: var(--sup-alt); color: var(--texto-sec); border: 1px solid var(--borde-fuerte);
}
.fx-voy-btn.activo { background: var(--celeste); color: var(--celeste-ink); border-color: var(--celeste); }
.fx-voy { background: rgba(165,221,243,.07); }
.fx-voy .fx-hora { color: var(--celeste); }

/* ─────────────── Noticias: pila con gestos ─────────────── */
/* Una arriba de la otra. Se arrastra a la izquierda para darla por leída y a la
   derecha para abrir la nota; los botones de abajo hacen lo mismo. */
.tin {
  position: relative; height: 58vh; min-height: 340px; max-height: 480px;
  margin-bottom: 12px;
}
.tin-card {
  position: absolute; inset: 0; display: flex; flex-direction: column; overflow: hidden;
  background: var(--sup); border: 1px solid var(--borde); border-radius: 16px;
  box-shadow: 0 6px 20px rgba(0,0,0,.35);
  transform-origin: 50% 100%;
  touch-action: pan-y;             /* el gesto horizontal es nuestro; el vertical scrollea */
  -webkit-user-select: none; user-select: none;
}
.tin-card.frente { cursor: grab; }
.tin-card img { width: 100%; flex: 0 0 44%; object-fit: cover; background: var(--sup-alt); }
.tin-cuerpo { padding: 13px 15px 15px; display: flex; flex-direction: column; gap: 7px; flex: 1; min-height: 0; }
.tin-fuente { font-size: 10.5px; color: var(--texto-sec); text-transform: uppercase; letter-spacing: .06em; }
.tin-tit {
  font-size: 17px; font-weight: 700; line-height: 1.25;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.tin-resumen {
  margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--texto-sec);
  display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden;
}
.tin-resumen.pendiente { opacity: .5; font-style: italic; }
/* Sin resumen propio: es el copete del feed, y la tarjeta lo dice. */
.tin-resumen.copete::after { content: ' — copete del medio'; color: var(--texto-sec); opacity: .7; font-size: 11px; }
/* Sin foto sobra media tarjeta: se le da más aire al resumen en vez de dejar el hueco. */
.tin-card.sin-foto .tin-tit { font-size: 19px; -webkit-line-clamp: 4; }
.tin-card.sin-foto .tin-resumen { font-size: 14.5px; -webkit-line-clamp: 14; }

/* Los sellos que aparecen al arrastrar, como el LIKE/NOPE de Tinder. */
.tin-sello {
  position: absolute; top: 16px; z-index: 2; opacity: 0; pointer-events: none;
  font-family: var(--display); font-size: 15px; letter-spacing: var(--tracking-display);
  padding: 5px 12px; border-radius: 8px; border: 2px solid currentColor; text-transform: uppercase;
}
.tin-sello.izq { left: 16px; color: var(--texto-sec); transform: rotate(-12deg); }
.tin-sello.der { right: 16px; color: var(--celeste); transform: rotate(12deg); }

.tin-acciones { display: flex; justify-content: center; gap: 22px; }
.tin-btn {
  width: 52px; height: 52px; border-radius: 50%; font-size: 20px;
  background: var(--sup); color: var(--texto-sec);
  border: 1px solid var(--borde-fuerte);
}
.tin-btn.abrir { color: var(--celeste); border-color: rgba(165,221,243,.4); }

.tin-fin {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 6px; padding: 24px; text-align: center;
  background: var(--sup); border: 1px solid var(--borde); border-radius: 16px;
}
.tin-fin-tilde {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(47,122,69,.18); color: var(--verde-claro); font-size: 22px; margin-bottom: 4px;
}
.tin-fin b { font-size: 16px; }
.tin-fin .boton { width: auto; padding: 10px 18px; margin-top: 10px; }

/* ─────────────── Radio ─────────────── */
.radio-card { padding: 16px 14px; display: flex; align-items: center; gap: 14px; }
.radio-card .bola {
  width: 58px; height: 58px; border-radius: 50%; flex: 0 0 auto; border: 0;
  background: var(--celeste); color: var(--celeste-ink);
  display: grid; place-items: center; font-size: 22px;
}
.radio-card.sonando .bola { animation: pulso 2.2s infinite; }
@keyframes pulso { 0%,100% { box-shadow: 0 0 0 0 rgba(165,221,243,.35) } 50% { box-shadow: 0 0 0 10px rgba(165,221,243,0) } }
.radio-card .info b { display: block; font-size: 16px; font-weight: 700; }
.radio-card .info span { font-size: 12px; color: var(--texto-sec); }
.radio-card.sonando .info span { color: var(--rojo); font-weight: 600; }

/* ─────────────── Botones y hoja ─────────────── */
.boton {
  display: block; width: 100%; padding: 12px; margin-top: 8px;
  font: inherit; font-weight: 600; font-size: 14px;
  background: var(--sup-alt); color: var(--texto);
  border: 1px solid var(--borde-fuerte); border-radius: 12px; text-align: center; text-decoration: none;
}
.boton.principal { background: var(--celeste); color: var(--celeste-ink); border-color: var(--celeste); }

.hoja { position: fixed; inset: 0; z-index: 40; }
.hoja-fondo { position: absolute; inset: 0; background: rgba(0,0,0,.5); }
.hoja-caja {
  position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; overflow-y: auto;
  background: var(--carbon); border-radius: 16px 16px 0 0;
  padding: 8px 14px calc(20px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--borde);
}
.manija { width: 36px; height: 4px; border-radius: 2px; background: var(--borde-fuerte); margin: 0 auto 12px; }

.vacio { text-align: center; color: var(--texto-sec); font-size: 13px; padding: 30px 12px; }

/* Interruptor iOS */
.sw { appearance: none; margin-left: auto; width: 46px; height: 27px; border-radius: 999px; background: var(--sup-alt); border: 1px solid var(--borde-fuerte); position: relative; flex: 0 0 auto; }
.sw::after { content: ''; position: absolute; top: 2px; left: 2px; width: 21px; height: 21px; border-radius: 50%; background: var(--texto); transition: transform .16s; }
.sw:checked { background: var(--verde); border-color: var(--verde); }
.sw:checked::after { transform: translateX(19px); }

.mini { margin-left: auto; width: 72px; padding: 7px 9px; font: inherit; font-size: 14px; text-align: right;
  background: var(--sup-alt); color: var(--texto); border: 1px solid var(--borde-fuerte); border-radius: 8px; }

/* Ficha de persona en la hoja */
.ficha-cab { display: flex; align-items: center; gap: 13px; margin: 2px 0 14px; }
.ficha-cab .avatar { width: 58px; height: 58px; font-size: 19px; }
.ficha-cab h2 { margin: 0; font-size: 21px; }
.ficha-cab .pie { margin: 2px 0 0; }

/* ─────────────── Próximos partidos ─────────────── */
/* Hora a la izquierda y los dos equipos apilados, como en las apps de fútbol:
   con nombres como "Montevideo City Torque" una sola línea siempre se corta. */
.fx {
  display: grid; grid-template-columns: 46px 1fr auto; align-items: center; gap: 10px;
  padding: 10px 13px; border-top: 1px solid var(--borde);
}
.fx:first-child { border-top: 0; }
.fx-hora { font-family: var(--display); font-size: 14px; color: var(--texto-sec); letter-spacing: var(--tracking-display); }
.fx-cuerpo { min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.fx-eq {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 500; line-height: 1.15;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.fx-esc { width: 20px; height: 20px; object-fit: contain; flex: 0 0 auto; }
.fx-cancha { font-size: 10.5px; color: var(--texto-sec); margin-top: 2px; }
.fx-pie { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 1px; }
.fx-copa {
  font-size: 9px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
  padding: 2px 6px; border-radius: 4px;
  background: rgba(226,180,95,.16); color: var(--ambar);
}

/* "Voy": lo que decide si el partido aparece como el del día. */
.fx-voy-btn {
  font: inherit; font-size: 11px; font-weight: 700; letter-spacing: .02em;
  padding: 6px 11px; border-radius: 999px; white-space: nowrap;
  background: var(--sup-alt); color: var(--texto-sec); border: 1px solid var(--borde-fuerte);
}
.fx-voy-btn.activo { background: var(--celeste); color: var(--celeste-ink); border-color: var(--celeste); }
.fx-voy { background: rgba(165,221,243,.07); }
.fx-voy .fx-hora { color: var(--celeste); }

/* ─────────────── Marca 1950foto ─────────────── */
/* El logotipo va SIEMPRE arriba a la izquierda (pedido de Juan) y el engranaje
   queda solo a la derecha. En la barra no va nada más: el contexto del partido ya
   está en cada pantalla. */
.barra .icono { margin-left: auto; }
