/* ============================================================
   Nidu PWA — Componentes reutilizables
   ============================================================ */

/* ---------------- Top bar ---------------- */
.topbar {
  flex: none; z-index: var(--z-topbar);
  height: calc(var(--topbar-h) + var(--safe-t));
  padding: var(--safe-t) var(--sp-3) 0;
  display: flex; align-items: center; gap: var(--sp-2);
  /* SIN fondo propio. Pintar `--bg` acá tapaba el degradado de la app y dejaba
     una franja horizontal visible justo debajo de la barra — un corte que el
     prototipo no tiene, porque ahí la barra flota sobre el fondo del frame.
     No hace falta fondo: la topbar es hermana del scroll (`.app` es flex y
     `#app` scrollea aparte), así que el contenido nunca le pasa por debajo. */
  background: transparent;
  transition: transform var(--dur-fast) var(--ease-press);
}
/* Gesto de "tirar del hilo" (handoff 4a): al apretar volver, la barra entera
   se corre 6px a la izquierda antes de navegar — el mismo sentido que el hilo
   que se tira. Solo cuando hay back: sin botón no hay de dónde tirar. */
.topbar:has([data-action="back"]:active) { transform: translateX(-6px); }
/* Título de pantalla: ALINEADO A LA IZQUIERDA, como en el prototipo. Centrado
   quedaba descolgado en cuanto la fila dejó de ser simétrica (la marca ya no
   está en el medio). */
.topbar__title {
  flex: 0 1 auto; min-width: 0;
  font-size: var(--fs-23); font-weight: var(--fw-x); color: var(--ink);
  text-align: left; letter-spacing: -.01em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* Envoltorio del título con back (todo TopBar salvo brand/vacío): mismo
   flex-shrink que tenía `.topbar__title` sola, para que la elipsis siga
   funcionando igual — el hilo se ancla a este wrapper, no al `<h1>`. */
.topbar__titlewrap { position: relative; flex: 0 1 auto; min-width: 0; }
.topbar__hilo {
  position: absolute; left: 0; top: 100%; margin-top: -5px;
  width: 100%; height: 9px;
  overflow: visible; pointer-events: none;
}
/* El check remata la línea, siempre pegado a su final (no al ancho del
   wrapper: con elipsis el hilo termina ahí igual). Tamaño fijo — si se
   estirara con el hilo dejaría de leerse como un círculo. */
.topbar__hilo-check {
  position: absolute; right: -15px; top: 100%; margin-top: -7px;
  pointer-events: none;
}
/* Marca: el logotipo COMPLETO en PNG, alineado a la izquierda. No lleva `flex:1`
   —eso lo centraba— sino que el hueco lo empuja `.topbar__gap`. */
.topbar__title--brand { flex: none; display: flex; align-items: center; }
.topbar__brand-mark { height: 28px; width: auto; max-width: none; flex: none; display: block; }
.topbar__gap { flex: 1; }
/* Vuelta a la conversación con Nidu en WhatsApp. Ya no lleva punto de aviso:
   estaba siempre encendido y no avisaba de nada. */
.topbar__canal {
  position: relative; flex: none; width: 44px; height: 44px; border-radius: var(--r-pill);
  display: grid; place-items: center; color: var(--green);
  background: var(--surface); box-shadow: var(--sh-sm);
  transition: transform var(--dur-fast) var(--ease-out);
}
.topbar__canal:active { transform: scale(.92); }

/* Avatar del perfil (arriba a la derecha). Anillo blanco para despegarlo del
   fondo menta; inicial sobre el menta de marca cuando no hay foto. */
.topbar__avatar {
  flex: none; width: 42px; height: 42px; border-radius: var(--r-pill);
  display: grid; place-items: center; overflow: hidden; text-decoration: none;
  background: var(--green-soft); color: var(--green-dk);
  font-weight: var(--fw-black); font-size: var(--fs-16);
  box-shadow: var(--sh-sm); border: 2px solid var(--surface);
  transition: transform var(--dur-fast) var(--ease-out);
}
.topbar__avatar:active { transform: scale(.92); }
.topbar__avatar-img { width: 100%; height: 100%; object-fit: cover; }
.topbar__avatar-ini { line-height: 1; }

/* Botón circular (back, acciones de la topbar) */
.icon-btn {
  flex: none; width: 42px; height: 42px; border-radius: var(--r-pill);
  display: grid; place-items: center; color: var(--ink);
  background: var(--surface); box-shadow: var(--sh-sm);
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.icon-btn:hover { transform: translateY(-1px); box-shadow: var(--sh-md); }
.icon-btn:active { transform: scale(.94); }
.icon-btn svg { width: 22px; height: 22px; }

/* ---------------- Botones ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 var(--sp-5);
  border-radius: var(--r-pill); font-weight: var(--fw-bold); font-size: var(--fs-13-5);
  transition: transform var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
  user-select: none;
}
.btn svg { width: 20px; height: 20px; }
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--green); color: #fff; box-shadow: var(--sh-brand); }
.btn--primary:hover { background: var(--green-hover); }
.btn--dark { background: var(--ink); color: #fff; box-shadow: var(--sh-md); }
.btn--secondary { background: var(--green-soft); color: var(--green-dk); }
.btn--secondary:hover { background: color-mix(in srgb, var(--green-soft) 82%, var(--green) 18%); }
.btn--ghost { background: transparent; color: var(--green); border: 1.5px solid var(--line); }
.btn--ghost:hover { border-color: var(--green); background: color-mix(in srgb, var(--green-soft) 45%, transparent); }
.btn--block { display: flex; width: 100%; }
.btn--lg { min-height: 54px; font-size: var(--fs-16); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }

/* CTA inferior: va al FINAL del contenido, en flujo normal.
   Antes era `position: sticky; bottom: 0` —pegada al pulgar—, pero flotaba
   sobre lo último de la pantalla y tapaba campos al scrollear (en Crear se
   comía "¿Para cuándo?" y "Prioridad"). Ahora se apoya después de todo: se
   llega scrolleando y no cubre nada. El degradado y el sangrado a los bordes
   eran para enmascarar lo que pasaba por detrás de la barra fija; sin fija,
   sobran. */
.bottom-cta {
  margin-top: var(--sp-6);
  padding-bottom: var(--safe-b);
  /* Grid y no bloque: el detalle apila el cierre y la vuelta a WhatsApp. */
  display: grid; gap: var(--sp-2);
}

/* ---------------- Chips / badges ---------------- */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: var(--r-pill);
  font-size: var(--fs-13); font-weight: var(--fw-x); line-height: 1;
  background: var(--surface-sunk); color: var(--ink-2);
}
.chip__dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.chip--exito { background: var(--exito-bg); color: var(--exito); }
.chip--alerta { background: var(--alerta-bg); color: var(--alerta); }
.chip--info { background: var(--info-bg); color: var(--info); }
.chip--green { background: var(--green-soft); color: var(--green-dk); }

/* Prioridad (punto) */
.prio { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--ink-2); }
.prio__dot { width: 8px; height: 8px; border-radius: 50%; }
.prio--alta .prio__dot { background: var(--alerta); }
.prio--media .prio__dot { background: var(--coral); }
.prio--baja .prio__dot { background: var(--green); }

/* ---------------- Tarjeta de pendiente (Ruta, Agenda) ----------------
   Valores del prototipo. La tarjeta es BLANCA y el color de la categoría vive
   en el tile del icono. Antes se teñía la tarjeta entera: con seis categorías
   la lista quedaba un arcoíris donde nada resaltaba, justo lo contrario de una
   ruta priorizada. */
.pcard {
  display: flex; align-items: center; gap: 13px;
  width: 100%; text-align: left;
  padding: 13px; margin-bottom: 9px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  transform-style: preserve-3d;
  animation: cardIn var(--dur-base) var(--ease-out) both;
  transition: transform .32s var(--ease-out), opacity .32s var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.pcard:hover { box-shadow: var(--sh-md); }
/* Al resolver, la tarjeta se encoge y se va antes de que la lista se reordene. */
.pcard.is-resolving { transform: scale(.95); opacity: 0; }
/* Zona táctil que abre el detalle (separada del check para no anidar botones en enlaces) */
.pcard__hit { display: flex; align-items: center; gap: 13px; flex: 1 1 auto; min-width: 0; color: inherit; border-radius: var(--r-sm); }
/* Tile del icono: degradado desde el tint de la categoría hacia el blanco, con
   un brillo interno arriba. El `translateZ` lo despega de la tarjeta — se lee
   como una pieza apoyada encima, no como un cuadrado pintado. */
.pcard__ic {
  flex: none; width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center;
  background: linear-gradient(145deg, var(--tint-cat, var(--green-soft)), #ffffff 155%);
  border: 1px solid var(--borde-cat, var(--line));
  box-shadow: inset 0 1px 1px rgba(255,255,255,.7), 0 4px 10px rgba(37,51,49,.10);
  color: var(--acento-cat, var(--green));
  transform: translateZ(20px);
}
.pcard__ic svg { width: 22px; height: 22px; }
.pcard__body { flex: 1 1 auto; min-width: 0; display: block; }
/* Chip "Prioridad alta": solo cuando además vence HOY —empate real entre
   varios pendientes del mismo día (reporte de campo), no un rótulo permanente
   de prioridad. Mismo tratamiento ámbar que `.mcard__chip` en el Mapa. */
.pcard__prio {
  display: inline-flex; align-items: center; margin-bottom: 3px;
  font-size: 10px; font-weight: var(--fw-x); line-height: 1;
  padding: 3px 7px; border-radius: var(--r-pill);
  background: var(--amber-bg); color: var(--amber-ink);
}
.pcard__title {
  display: block; max-width: 100%;
  font-size: var(--fs-14-5); font-weight: var(--fw-bold); color: var(--ink);
  line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.pcard__meta {
  display: flex; gap: 8px; margin-top: 3px;
  font-size: var(--fs-12); font-weight: var(--fw-semi); color: var(--muted);
}
/* El `<em>` marca la categoría; no es cursiva, es el color oscuro de su paleta. */
.pcard__meta em { font-style: normal; color: var(--texto-cat, var(--ink-2)); }
.pcard__vencido { color: var(--alerta); font-weight: var(--fw-x); }
.pcard__right { flex: none; display: flex; align-items: center; gap: var(--sp-2); color: var(--ink-3); }
.pcard__right svg { width: 20px; height: 20px; }

/* Check de la tarjeta: cuadrado redondeado con el acento de la categoría, no un
   círculo gris. En el prototipo el check nunca es neutro. */
.pcard__check {
  flex: none; width: 34px; height: 34px; padding: 0;
  border-radius: 11px; border: 2.5px solid var(--borde-cat, var(--line));
  background: none; display: grid; place-items: center;
  color: var(--acento-cat, var(--green));
  transition: all var(--dur-base) var(--ease-spring);
}
.pcard__check:active { transform: scale(.86); }
.pcard__check.is-done {
  background: var(--acento-cat, var(--green));
  border-color: var(--acento-cat, var(--green));
  color: #fff;
}

/* Círculo de completar genérico (notas de Inicio y demás) */
.check {
  flex: none; width: 30px; height: 30px; border-radius: 50%;
  border: 2px solid var(--line); display: grid; place-items: center;
  color: transparent; background: var(--surface);
  transition: all var(--dur-fast) var(--ease-out);
}
.check svg { width: 16px; height: 16px; }
.check:hover { border-color: var(--green); }
.check.is-done { background: var(--green); border-color: var(--green); color: #fff; }

/* ---------------- Stat tiles (resumen) ---------------- */
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-3); }
.stat {
  padding: var(--sp-3) var(--sp-3) var(--sp-4);
  border-radius: var(--r-lg); background: var(--surface);
  border: 1px solid var(--line); box-shadow: var(--sh-sm);
}
.stat__num { font-size: var(--fs-28); font-weight: var(--fw-black); line-height: 1; color: var(--ink); }
.stat__label { margin-top: 6px; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--ink-2); }
.stat--green { background: var(--green-soft); border-color: transparent; }
.stat--green .stat__num { color: var(--green-dk); }
.stat--coral { background: var(--cat-compra-paper); border-color: transparent; }
.stat--coral .stat__num { color: var(--cat-compra-accent); }

/* ---------------- Contenedor genérico (card) ---------------- */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-xl); box-shadow: var(--sh-sm); padding: var(--sp-4);
}
.card--flat { box-shadow: none; }
.card--sunk { background: var(--surface-2); }

/* Bloque destacado "próximo paso" en Inicio */
.next {
  position: relative; overflow: hidden;
  border-radius: var(--r-xl); padding: var(--sp-5);
  background: var(--grad); color: #fff; box-shadow: var(--sh-brand);
}
.next__label { font-size: var(--fs-12); font-weight: var(--fw-x); letter-spacing: .05em; text-transform: uppercase; opacity: .85; }
.next__title { margin-top: 6px; font-size: var(--fs-20); font-weight: var(--fw-x); line-height: 1.2; }
.next__meta { margin-top: 8px; font-size: var(--fs-14); opacity: .9; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.next__actions { margin-top: var(--sp-4); display: flex; gap: var(--sp-2); }
.next .btn--secondary { background: rgba(255,255,255,.16); color: #fff; }
.next .btn--secondary:hover { background: rgba(255,255,255,.26); }
.next .btn--light { background: #fff; color: var(--green-dk); }
.next__blob { position: absolute; width: 180px; height: 180px; border-radius: 50%; background: rgba(255,255,255,.08); top: -70px; right: -50px; pointer-events: none; }

/* ---------------- Segmented control (orden de la ruta · lista/mapa) ----------
   La pastilla blanca es UN elemento que se desliza, no un fondo que se enciende
   en cada botón. `--n` es la cantidad de opciones y `--i` la activa: el
   prototipo tiene el 3 clavado porque su Ruta siempre tiene tres, pero acá el
   mismo control se usa con dos en Trámites. */
.segmented {
  position: relative; display: flex; padding: 4px;
  background: var(--track); border-radius: var(--r-pill);
  margin-bottom: 16px;
}
.segmented__thumb {
  position: absolute; top: 4px; bottom: 4px;
  width: calc((100% - 8px) / var(--n, 3));
  left: calc(4px + (100% - 8px) * var(--i, 0) / var(--n, 3));
  background: var(--surface); border-radius: var(--r-pill); box-shadow: var(--sh-sm);
  transition: left var(--dur-base) var(--ease-spring);
}
.segmented__btn {
  position: relative; flex: 1; justify-content: center;
  padding: 10px 4px; font-size: 13.5px; font-weight: var(--fw-x);
  color: var(--muted); display: inline-flex; align-items: center; gap: 6px;
  transition: color var(--dur-fast) var(--ease-out);
}
.segmented__btn svg { width: 16px; height: 16px; }
.segmented__btn.is-active { color: var(--ink); }
.segmented--block { display: flex; }

/* ---------------- Campos de formulario ---------------- */
.field { display: block; }
.field__label { display: block; font-size: var(--fs-13); font-weight: var(--fw-x); color: var(--ink-2); margin-bottom: 6px; }
.input, .textarea {
  width: 100%; background: var(--surface); border: 1.5px solid var(--line);
  border-radius: var(--r-md); padding: 14px 16px; font-size: var(--fs-16); color: var(--ink);
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.input::placeholder, .textarea::placeholder { color: var(--ink-3); }
.input:focus, .textarea:focus {
  outline: none; border-color: var(--green);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--green-soft) 70%, transparent);
}
.field__opt { font-weight: var(--fw-semi); color: var(--ink-3); }
.field__hint { display: block; margin-top: 6px; font-size: var(--fs-12); color: var(--muted); line-height: 1.4; }

/* ---- Editar perfil ---- */
.is-hidden { display: none !important; }
.ed-foto { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 8px 0 4px; }
.ed-foto__ring {
  position: relative; display: grid; place-items: center;
  width: 104px; height: 104px; border-radius: var(--r-pill);
  background: var(--green-dk); color: #fff;
  border: 4px solid var(--surface); box-shadow: var(--sh-md);
}
.ed-foto__img { width: 100%; height: 100%; border-radius: var(--r-pill); object-fit: cover; }
.ed-foto__ini { font-size: 40px; font-weight: var(--fw-black); letter-spacing: -.03em; }
.ed-foto__cam {
  position: absolute; right: -2px; bottom: -2px;
  display: grid; place-items: center; width: 34px; height: 34px;
  border-radius: var(--r-pill); background: var(--green); color: #fff;
  border: 3px solid var(--surface);
}
.ed-foto__acts { display: flex; align-items: center; gap: 8px; }
.ed-form { display: flex; flex-direction: column; gap: 16px; margin-top: 18px; }
.ed-guardar { margin-top: 20px; }

/* Dónde vivís/trabajás: el input de siempre + la lupa para "buscar en el
   mapa" en vez de escribirlo a mano. */
.ed-lugar { display: flex; gap: 8px; }
.ed-lugar .input { flex: 1; min-width: 0; }
.ed-lugar__buscar { flex: none; display: grid; place-items: center; width: 48px; border-radius: var(--r-md); border: 1.5px solid var(--line); background: var(--surface); color: var(--ink-2); }
.ed-lugar__buscar:active { background: var(--cream); }

/* Panel de búsqueda (Places, sin restricción de radio — buscarLugarPorTexto):
   una sola instancia compartida entre casa y trabajo, se abre debajo del
   formulario con la lupa que se tocó. */
.ed-buscador { margin-top: 18px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.ed-buscador__tit { font-size: var(--fs-13); font-weight: var(--fw-x); color: var(--ink-2); margin-bottom: 10px; }
.ed-buscador__head { display: flex; gap: 8px; }
.ed-buscador__head .input { flex: 1; min-width: 0; padding: 12px 14px; font-size: var(--fs-15); }
.ed-buscador__res { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.ed-buscador__item { display: flex; flex-direction: column; gap: 2px; width: 100%; padding: 10px 12px; text-align: left; background: var(--cream); border: 1px solid var(--line); border-radius: var(--r-md); }
.ed-buscador__item:active { background: var(--green-soft); }
.ed-buscador__nombre { font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink); }
.ed-buscador__dir { font-size: var(--fs-12-5); color: var(--muted); }
.ed-buscador__estado { padding: 8px 2px; font-size: var(--fs-13); color: var(--muted); }
.ed-buscador__cerrar { display: block; margin: 10px auto 0; padding: 6px 12px; font-size: var(--fs-12-5); font-weight: var(--fw-bold); color: var(--muted); }
/* Fecha/hora: en iOS Safari el input nativo trae SU propio fondo y forma de
   píldora que pisa el borde y el radio de `.input` — se ve como un elemento
   pegado, ajeno al resto de la tarjeta (reporte de campo, 3/8: "Recordar" en
   la Ruta). `appearance: none` deja el picker nativo (la rueda al tocar,
   que sigue siendo la correcta) pero el CAMPO cerrado usa el mismo fondo,
   borde y radio que cualquier otro `.input`. */
input[type="date"], input[type="time"], input[type="datetime-local"] {
  -webkit-appearance: none; appearance: none;
  color-scheme: light;
}
.textarea { min-height: 132px; resize: vertical; line-height: 1.5; }

/* Selector de categoría (chips seleccionables) */
.choice-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.choice {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 14px; border-radius: var(--r-pill);
  border: 1.5px solid var(--line); background: var(--surface);
  font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink-2);
  transition: all var(--dur-fast) var(--ease-out);
}
.choice svg { width: 18px; height: 18px; }
.choice[aria-pressed="true"] { border-color: var(--green); background: var(--green-soft); color: var(--green-dk); }
/* Grupo RESUELTO: el texto del pendiente ya dijo la respuesta, así que se muestra
   solo esa y no las cinco. No se esconde el grupo entero — la salida para
   corregir una lectura equivocada es el botón "Elijo yo", que le saca este
   atributo y deja todas las opciones a la vista. */
[data-resuelto] .choice:not([aria-pressed="true"]) { display: none; }
/* Salida discreta: es una corrección, no la acción de la pantalla. */
.link-suave {
  display: inline-block; font-size: var(--fs-12); font-weight: var(--fw-bold);
  color: var(--muted); text-decoration: underline; text-underline-offset: 3px;
}
.link-suave:active { color: var(--green-dk); }

/* ---------------- Grabador de audio (Crear) ---------------- */
.recorder { display: flex; flex-direction: column; align-items: center; gap: var(--sp-3); padding: var(--sp-5) 0; }
.mic-btn {
  width: 92px; height: 92px; border-radius: 50%;
  background: var(--grad); color: #fff; display: grid; place-items: center;
  box-shadow: var(--sh-brand); transition: transform var(--dur-fast) var(--ease-out);
}
.mic-btn svg { width: 38px; height: 38px; }
.mic-btn:active { transform: scale(.95); }
.mic-btn.is-recording { background: var(--coral); animation: pulse 1.4s var(--ease-out) infinite; }
@keyframes pulse { 0%,100%{ box-shadow: 0 0 0 0 rgba(233,137,115,.5);} 50%{ box-shadow: 0 0 0 16px rgba(233,137,115,0);} }
.rec-time { font-variant-numeric: tabular-nums; font-weight: var(--fw-x); font-size: var(--fs-20); color: var(--ink); }

/* ---------------- Instrucciones numeradas (Conectar) ----------------
   Distinto de `.step` de Detalle: aquello se tilda y es una tarjeta que
   responde al toque; esto es una lista de lectura, en orden, dentro de una
   `.card`. Compartían clase y por eso el rediseño de los pasos se le colaba. */
.instruccion { display: flex; gap: var(--sp-3); align-items: flex-start; padding: var(--sp-2) 0; }
.instruccion__n {
  flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--green-soft); color: var(--green-dk);
  display: grid; place-items: center; font-weight: var(--fw-x); font-size: var(--fs-13);
}
.instruccion__texto { padding-top: 3px; font-size: var(--fs-15); color: var(--ink); }

/* ---------------- Skeletons ---------------- */
.skeleton { position: relative; overflow: hidden; background: var(--surface-sunk); border-radius: var(--r-md); }
.skeleton::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.6), transparent);
  transform: translateX(-100%); animation: shimmer 1.3s infinite;
}
@keyframes shimmer { to { transform: translateX(100%); } }
.sk-card { display: flex; gap: var(--sp-3); align-items: center; padding: var(--sp-3); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.sk-tile { width: 48px; height: 48px; border-radius: var(--r-md); flex: none; }
.sk-line { height: 12px; border-radius: 6px; }
.sk-line.w-70 { width: 70%; } .sk-line.w-45 { width: 45%; } .sk-line.w-90 { width: 90%; }

/* ---------------- Estados vacío / error / offline ---------------- */
.state {
  text-align: center; padding: var(--sp-10) var(--sp-4);
  display: flex; flex-direction: column; align-items: center; gap: var(--sp-3);
}
.state__art {
  width: 88px; height: 88px; border-radius: 50%;
  display: grid; place-items: center; background: var(--green-soft); color: var(--green);
}
.state__art svg { width: 40px; height: 40px; }
.state--error .state__art { background: var(--alerta-bg); color: var(--alerta); }
.state--offline .state__art { background: var(--info-bg); color: var(--info); }
.state__title { font-size: var(--fs-20); font-weight: var(--fw-x); color: var(--ink); }
.state__text { font-size: var(--fs-15); color: var(--ink-2); max-width: 34ch; }

/* ---------------- Resolver: campo verde (rediseño ago 2026) ----------------
   El paso previo a revisar un pendiente (`resolver.js`, `estadoResolver` +
   `pintarEstado`): campo verde `#0B3C2F` de ancho completo, con su propio
   encabezado (la pantalla pide `hideTop` y oculta la `.topbar` compartida),
   ovillo animado de fondo y un botón que se "monta" sobre la costura con la
   zona crema de abajo. NO es `.state` (arriba): esa clase la comparten
   `EmptyState`/`ErrorState` en el resto de la app y no hay que tocarla. */
/* `#app` ya es columna flex (`base.css`) con UN solo `.screen` adentro; acá se
   lo hace crecer hasta el alto disponible SOLO cuando envuelve el campo verde
   —`:has()` en vez de acoplarlo a `.sin-top` a secas, porque «Tu día»
   (`.dia-sheet`) también usa `sin-top` y a propósito NO fuerza 100%: un sheet
   corto forzado a pantalla completa dejaba una franja vacía abajo (reporte de
   campo, 3/8). Acá el caso es al revés: el campo verde SIEMPRE va de punta a
   punta, tenga poco o mucho texto. */
/* ── Alquileres: HERO verde de categoría. Mismo verde profundo que ya domina
   Resolver/Ruta/Calendario (`--green-dk`, NO un tono nuevo) en el encabezado
   de las pantallas del vertical (filtros y seguimiento), con el contenido en
   crema debajo. Scope acotado: `.viv-hero` lo usan SÓLO esas pantallas, no
   toca el resto de la app. */
.viv-hero {
  margin: calc(var(--sp-4) * -1) calc(var(--sp-4) * -1) var(--sp-5);
  padding: calc(var(--safe-t) + var(--sp-5)) var(--sp-5) var(--sp-6);
  background: var(--green-dk);
  color: var(--app-bg);
  border-radius: 0 0 var(--r-xl) var(--r-xl);
}
.viv-hero__eyebrow {
  margin: 0 0 var(--sp-2);
  font-size: 13px; font-weight: var(--fw-x); letter-spacing: .1em;
  text-transform: uppercase; color: var(--sage);
}
.viv-hero__title {
  margin: 0; color: var(--app-bg);
  font-size: 30px; line-height: 1.12; font-weight: var(--fw-x); letter-spacing: -.01em;
}
.viv-hero__sub { margin: var(--sp-2) 0 0; color: rgba(247,245,240,.82); font-size: 15px; }
.viv-hero__meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-3);
  margin-top: var(--sp-4);
}
.viv-hero__meta .empleo__meta { color: rgba(247,245,240,.86); }
.viv-hero__chip {
  display: inline-flex; align-items: center;
  padding: 4px 12px; border-radius: var(--r-pill);
  background: rgba(247,245,240,.16); color: var(--app-bg);
  font-size: 13px; font-weight: var(--fw-semi);
}

.screen:has(> .res-hero) { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.res-hero { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }

.res-hero__field {
  flex: 1 1 auto; min-height: 0;
  display: flex; flex-direction: column;
  position: relative; overflow: hidden;
  background: var(--green-dk); color: var(--app-bg);
  border-radius: 0 0 34px 34px;
  /* `padding-bottom:66px` es del handoff: es el aire entre el párrafo y la
     costura, sobre el que se monta el botón (que sube -28px). Con menos, el
     botón queda pegado al párrafo; con este valor, el párrafo respira y el
     botón se apoya en la curva como en el diseño. El top lo maneja el header
     (safe-area), por eso acá va 0. */
  padding: 0 20px 66px;
  animation: resHeroFieldIn .7s cubic-bezier(.2,.85,.25,1) both;
}

/* El ovillo va DETRÁS del texto siempre: decorativo, `aria-hidden`, nunca se
   colorea más fuerte ni se engrosa (ver "qué no hacer" del handoff). */
.res-hero__ovillo {
  /* Posición del handoff (opción 2b). No pisa el título porque el contenido va
     empujado ABAJO del campo (un solo `margin-top:auto` antes del mark), así
     el ovillo tiene todo el aire de arriba para él solo. */
  position: absolute; z-index: 0; right: -74px; top: 40px;
  /* `max-width:none` anula el reset `svg{max-width:100%}`, que si no capa el
     ovillo al ancho del campo (~390) y le come el sangrado a la derecha. */
  width: 410px; max-width: none; height: auto; opacity: .5; pointer-events: none;
}
.res-hero__ovillo-madeja { animation: resHeroSpin 90s linear infinite; }

.res-hero__head {
  position: relative; z-index: 1;
  flex: none; display: flex; align-items: center; gap: 8px;
  padding-top: calc(var(--safe-t) + 14px);
  animation: resHeroRise .5s var(--ease-out) .12s both;
}
.res-hero__icbtn {
  flex: none; width: 38px; height: 38px; border-radius: var(--r-pill);
  display: grid; place-items: center; color: var(--app-bg);
  background: rgba(247,245,240,.14);
  transition: background var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.res-hero__icbtn svg { width: 20px; height: 20px; }
.res-hero__icbtn:hover { background: rgba(247,245,240,.24); }
.res-hero__icbtn:active { transform: scale(.94); }
.res-hero__eyebrow {
  font-size: 13px; font-weight: var(--fw-x); letter-spacing: .1em; text-transform: uppercase;
  color: var(--sage);
}
.res-hero__gap { flex: 1; }
/* La vuelta a Nidu reusa `VolverANidu()` —mismo componente e ícono que la
   topbar clara—; acá solo se retoca para que ande translúcida sobre el verde
   en vez de blanca sobre superficie. */
.res-hero__head .topbar__canal {
  width: 38px; height: 38px; background: rgba(247,245,240,.14); color: var(--app-bg); box-shadow: none;
}
.res-hero__head .topbar__canal:hover { background: rgba(247,245,240,.24); }

.res-hero__mark {
  position: relative; z-index: 1; flex: none;
  /* EL único "aire flexible" del campo (handoff): este `margin-top:auto`
     empuja el mark —y todo lo que sigue: título, PRÓXIMO PASO, párrafo— hacia
     abajo del campo verde, dejando al ovillo todo el aire de arriba. PRÓXIMO
     PASO ya NO usa auto (usa un padding fijo), así que el bloque de abajo
     queda compacto, no repartido. */
  margin-top: auto;
  width: 46px; height: 46px; border-radius: var(--r-pill);
  background: rgba(247,245,240,.12); color: var(--app-bg);
  animation: resHeroRise .5s var(--ease-out) .5s both;
}
.res-hero__mark-ic { display: grid; place-items: center; width: 100%; height: 100%; animation: resHeroPulse 3.2s ease-in-out 1s infinite; }
.res-hero__mark svg { width: 24px; height: 24px; }

/* `display:contents`: el título/kicker/texto pasan a ser hijos DIRECTOS de la
   columna flex de `.res-hero__field` —así los DOS `margin-top:auto` (el del
   mark y el del rótulo) reparten el mismo aire disponible en vez de que el
   segundo herede uno propio ya reducido. `#buscarBox` sigue existiendo como
   nodo único para que `pintarEstado` lo siga pudiendo reemplazar entero; solo
   deja de generar caja (por eso `margin`/`z-index` bajan a los hijos). */
.res-hero__body { display: contents; }
.res-hero__title {
  position: relative; z-index: 1;
  flex: none; display: flex; flex-direction: column;
  margin-top: 18px; line-height: 1; letter-spacing: -.035em;
  animation: resHeroRise .6s var(--ease-out) .62s both;
}
.res-hero__title-lead { font-size: 26px; font-weight: var(--fw-bold); color: var(--sage); }
.res-hero__title-strong {
  margin-top: 14px; margin-left: 30px;
  font-size: 40px; font-weight: var(--fw-x); color: var(--app-bg);
}
.res-hero__title-bar {
  display: block; margin-top: 8px; width: 56px; height: 3px; border-radius: var(--r-pill);
  background: var(--mint); transform: scaleX(0); transform-origin: left;
  animation: resHeroBar .5s var(--ease-out) 1.05s forwards;
}
.res-hero__kicker {
  position: relative; z-index: 1;
  /* `padding-top:52px` FIJO (valor del handoff), no `auto`: el único aire
     flexible del campo es el del mark (arriba). Así el bloque título → PRÓXIMO
     PASO → párrafo queda compacto y pegado abajo, con la separación exacta del
     diseño entre el h1 y este rótulo. */
  flex: none; padding-top: 52px;
  font-size: 10.5px; font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase;
  color: var(--sage);
  animation: resHeroRise .5s var(--ease-out) .88s both;
}
.res-hero__text {
  position: relative; z-index: 1;
  /* SIN `margin-bottom:auto`: el único aire flexible es el del mark (arriba),
     así el bloque compacto (mark→título→PRÓXIMO PASO→párrafo) baja hasta el
     pie del campo verde. El párrafo queda contra la costura y el botón
     "Empezar" sube a su lado, sin el hueco verde que quedaba en el medio
     (pedido: "subí el botón empezar"). El ovillo llena el aire de arriba. */
  flex: none; margin-top: 8px;
  font-size: var(--fs-15); line-height: 1.5; color: #E4EDE8; max-width: 34ch;
  animation: resHeroRise .5s var(--ease-out) .98s both;
}
/* `pintarEstado` marca el body repintado (`buscar-ahora` que termina en
   `pedirDocumento`/`pedirAclaracion`/`fallaBusqueda`): la entrada escalonada
   es del primer vistazo, no de después de una acción que la persona ya
   esperó — sin esto quedaba casi 1s de verde en blanco tras "Empezar". */
.is-repintado .res-hero__title,
.is-repintado .res-hero__kicker,
.is-repintado .res-hero__text {
  animation: resHeroRise .3s var(--ease-out) both;
}

/* Zona crema debajo del campo verde: acá vive el CTA (montado sobre la
   costura), la nota de privacidad y el pie de siempre (`pieDeAcciones`). Con
   `hideTop`, `#app` pierde su padding lateral — este bloque lo repone. */
.res-hero__foot { flex: none; padding: 0 20px calc(var(--safe-b) + 20px); }

.res-hero__cta { position: relative; z-index: 2; }
.res-hero__cta:not(:empty) {
  margin-top: -28px;
  animation: resHeroRise .55s cubic-bezier(.2,.9,.25,1) 1.18s both;
}
/* Botón "Empezar": 56px de alto y tipografía 15.5/800 (handoff), un punto más
   grande que el `.btn` general porque es la única decisión de la pantalla. */
.res-hero__cta .btn { min-height: 56px; font-size: 15.5px; font-weight: var(--fw-x); }
/* Primario del CTA: crema sobre verde, no verde sobre crema — es el único
   lugar de la app donde `.btn--primary` se lee así, porque es el único botón
   que "flota" sobre el campo oscuro en vez de vivir sobre superficie clara. */
.res-hero__cta .btn--primary { background: var(--app-bg); color: var(--green-dk); box-shadow: var(--sh-md); }
.res-hero__cta .btn--primary:hover { background: #fff; color: var(--green-hover); }

.res-hero__privacy {
  display: flex; align-items: flex-start; gap: 6px; margin-top: 14px;
  font-size: 11.5px; line-height: 1.45; color: var(--muted);
  animation: resHeroRise .5s var(--ease-out) 1.34s both;
}
.res-hero__privacy svg { flex: none; width: 14px; height: 14px; margin-top: 1px; }

/* El pie compartido (`pieDeAcciones`) también lo usa la pantalla YA resuelta
   (con tarjetas) — la entrada solo corre acá, adentro del campo verde. */
.res-hero__foot .res-acts { animation: resHeroRise .5s var(--ease-out) 1.5s both; }
/* "Una sola acción rellena por fila": Recordármelo y Marcar resuelto van lado
   a lado acá (spec del rediseño) — contorno + ancho por contenido el primero,
   el resto para el segundo. Sigue apilado en la pantalla YA resuelta (no hay
   `.res-hero__foot` ahí): esto es puramente visual, no toca `pieDeAcciones`.
   El selector mira `.btn--secondary` a propósito: cuando el pago sin link
   sube "Recordármelo" a primario (única acción real, ver `pieDeAcciones`) se
   queda ancho completo con su hermano — apagarlo ahí lo volvería a hacer
   secundario visualmente, que es justo lo que esa regla de negocio evita. */
.res-hero__foot .res-acts__row { display: flex; flex-direction: row; gap: 10px; }
/* `min-width:0`: sin esto un botón flex no se achica más allá del ancho de su
   propio contenido (mínimo intrínseco de flexbox) y en un teléfono angosto la
   fila se sale del viewport en vez de ceder — se vio como scroll horizontal
   en las pruebas, con "Marcar resuelto" empujado fuera de la pantalla. */
.res-hero__foot .res-acts__row .btn { flex: 1 1 auto; min-width: 0; }
.res-hero__foot .res-acts__row .btn--secondary:first-child {
  /* `width:auto` deshace `.btn--block` (`width:100%`): sin esto, `flex:none`
     igual pedía el ancho ENTERO de la fila como `flex-basis` (lo resuelve
     `width` cuando `flex-basis` es `auto`) y dejaba a "Marcar resuelto" sin
     lugar — el bug del scroll horizontal que se vio en las pruebas. */
  flex: none; width: auto; padding: 0 18px; min-height: 52px;
  background: transparent; color: var(--green-dk); border: 1.5px solid #CFD8D3;
}
.res-hero__foot .res-acts__row .btn--secondary:first-child:hover { background: var(--green-soft); border-color: #B7CFC3; }

@keyframes resHeroFieldIn { from { opacity: 0; transform: translateY(-18px); } to { opacity: 1; transform: none; } }
@keyframes resHeroRise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes resHeroBar { to { transform: scaleX(1); } }
@keyframes resHeroSpin { to { transform: rotate(360deg); } }
@keyframes resHeroPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.16); } }

/* Reducción de movimiento: se apaga TODO —incluido el giro continuo de la
   madeja—, salvo una excepción obligatoria. Sin ella, los trazos del ovillo
   (`stroke-dashoffset:100` de arranque) y el check (`scale(0)` de arranque)
   quedarían clavados en su estado INICIAL invisible: la madeja y la hebra
   desaparecerían y el check quedaría flotando solo. Se autoriza el estado
   final, no el inicial. */
@media (prefers-reduced-motion: reduce) {
  .res-hero, .res-hero * { animation: none !important; }
  .res-hero__ovillo ellipse, .res-hero__ovillo path { stroke-dashoffset: 0 !important; }
  .res-hero__ovillo g[style*="scale"] { transform: scale(1) !important; }
}

/* ---------------- Banner offline ---------------- */
.offline-banner {
  z-index: var(--z-banner);
  display: flex; align-items: center; gap: 8px; justify-content: center;
  /* SIN padding vertical mientras está oculto. Con `max-height:0` + flex el
     padding igual reservaba 16px de alto en el FLUJO (no en lo visible), y ese
     hueco empujaba el `#app` hacia abajo dejando asomar el fondo crema del
     `body` por arriba. En las pantallas crema no se notaba; sobre el campo
     verde de Resolver se veía como una franja blanca al tope. El padding
     vertical vuelve recién cuando el banner aparece (`.is-visible`). */
  padding: 0 14px; font-size: var(--fs-13); font-weight: var(--fw-bold);
  background: var(--info-bg); color: var(--info);
  transform: translateY(-100%); max-height: 0; overflow: hidden;
  transition: transform var(--dur-base) var(--ease-out), max-height var(--dur-base) var(--ease-out), padding var(--dur-base) var(--ease-out);
}
.offline-banner svg { width: 16px; height: 16px; }
.offline-banner.is-visible { transform: none; max-height: 60px; padding: 8px 14px; }

/* ---------------- Bottom nav ---------------- */
/* Barra en píldora flotante (handoff `pwa-barra-inferior/`). Con dos destinos y
   una acción, ocupar los 390 px del ancho dejaba ~200 px de vacío en el medio y
   mandaba "Ruta" y "Perfil" a los bordes, justo donde el pulgar no llega.
   ⚠️ Dos cambios sobre el archivo del handoff:
   1. Sus tokens venían con el vocabulario en español (`--texto-3`, `--suave`,
      `--brand-grad`, `--t-fast`…), que en esta app NO EXISTEN: tokens.css usa
      los nombres del prototipo y su cabecera pide expresamente no traducirlo.
      Se tradujeron las REFERENCIAS, no los valores: son los mismos tokens.
      --texto-3→--ink-3 · --verde-oscuro→--green-dk · --suave→--green-soft
      --brand-grad→--grad · --sh-3→--sh-lg · --t-fast→--dur-fast · --ease→--ease-out
   2. `position: sticky` → `absolute`. Acá el <nav> es un item más de la columna
      flex de `.app`, así que con sticky seguía reservando su alto y la píldora
      no flotaba sobre nada: el `padding-bottom` de #app y el `bottom` del toast
      que ajusta el handoff habrían sumado un hueco muerto en vez de reservarlo.
      Con absolute sobre `.app` (ya es position:relative) el modelo cierra. */

/* La barra inferior: franja PLANA de ancho completo, apoyada en el borde
   (rediseño ago 2026). Antes flotaba como píldora con un FAB verde saliente;
   ahora los tres controles pesan igual y "Agregar" es el "+" en un círculo. */
.bottomnav {
  flex: none; z-index: var(--z-nav);
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; align-items: stretch;
  padding: var(--sp-2) var(--sp-2) calc(var(--safe-b) + var(--sp-2));
  background: var(--surface);
  border-top: 1px solid var(--line);
}
.bottomnav:empty { display: none; }

.navitem {
  flex: 1 1 0; min-width: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  padding: 6px 4px; border-radius: var(--r-md);
  color: var(--ink-2); font-size: var(--fs-10-5); font-weight: var(--fw-bold);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}
.navitem__ic { height: 30px; display: grid; place-items: center; color: inherit; }
.navitem__ic svg { width: 24px; height: 24px; transition: transform var(--dur-fast) var(--ease-out); }
.navitem__lbl { line-height: 1; }
/* Activo (Ruta / Perfil): verde, sin píldora de fondo. */
.navitem.is-active { color: var(--green); }
.navitem:active .navitem__ic svg { transform: scale(.9); }
.navitem:focus-visible { outline: 2px solid var(--foco); outline-offset: 2px; }

/* "Nuevo": el "+" en un círculo VERDE relleno — el alta destaca del resto. */
.navitem--add { color: var(--green); }
.navitem--add .navitem__ic { height: auto; }
.navitem--add .navitem__ring {
  width: 40px; height: 40px; border-radius: var(--r-pill);
  background: var(--green); color: #fff; box-shadow: 0 4px 12px rgba(0,90,80,.28);
  transition: transform var(--dur-fast) var(--ease-out);
}
.navitem--add:active .navitem__ring { transform: scale(.94); }
.navitem--add .navitem__ring svg { width: 22px; height: 22px; }

/* El contenido scrollea POR ENCIMA de la barra: se reserva su alto. */
#app { padding-bottom: calc(var(--safe-b) + 78px); }

/* ⚠️ Sin barra ese hueco no reserva nada: es aire. Y no es solo espacio de más:
   `#app` es el contenedor que scrollea, así que un `position: sticky; bottom: 0`
   se ancla al borde de su PADDING, no al de la pantalla — con el hueco reservado
   para una barra que no está, el "Guardar pendiente" de #/crear quedaba clavado
   arriba del fondo (reporte 29/7). La clase la pone el router con `hideNav`. */
.sin-nav #app { padding-bottom: calc(var(--safe-b) + var(--sp-4)); }

/* Pantallas SHEET («Tu día»): sin barra superior — el sheet trae su propio
   encabezado. `#app` deja de tener padding lateral/superior propio para que el
   panel ocupe todo el frame; el padding lo pone el panel por dentro. */
.sin-top .topbar { display: none; }
.sin-top #app { padding: 0; }

/* El toast se apoya sobre la barra. */
.toast-host { bottom: calc(var(--safe-b) + 84px); }
.sin-nav .toast-host { bottom: calc(var(--safe-b) + var(--sp-5)); }

@media (prefers-reduced-motion: reduce) {
  .navitem, .navitem__ic svg { transition: none !important; }
}

/* ---------------- Toast ---------------- */
.toast-host {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--safe-b) + 92px);   /* se apoya sobre la píldora */
  z-index: var(--z-toast); width: min(var(--app-max), 92%);
  display: flex; flex-direction: column; gap: 8px; pointer-events: none;
}
.toast {
  pointer-events: auto;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: var(--r-md);
  background: var(--ink); color: #fff; font-size: var(--fs-14); font-weight: var(--fw-semi);
  box-shadow: var(--sh-lg);
  animation: toastIn var(--dur-base) var(--ease-out) both;
}
.toast svg { width: 18px; height: 18px; flex: none; }
.toast--exito { background: var(--exito); }
.toast--alerta { background: var(--alerta); }
.toast.is-out { animation: toastOut var(--dur-base) var(--ease-out) both; }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(14px); } }

/* ---------------- Divisor de fecha (Ruta) ---------------- */
.day-head { display: flex; align-items: center; gap: 10px; margin: var(--sp-5) 0 var(--sp-3); }
.day-head__label { font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink); }
.day-head__count { font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--ink-3); background: var(--surface-sunk); padding: 2px 9px; border-radius: var(--r-pill); }
.day-head__line { flex: 1; height: 1px; background: var(--line); }

/* ---------------- Inicio: saludo, instalación ---------------- */
.greet__hi { font-size: var(--fs-24); font-weight: var(--fw-black); letter-spacing: -.02em; color: var(--ink); line-height: 1.15; }
.greet__sub { margin-top: 4px; color: var(--ink-2); font-size: var(--fs-15); }

/* ---------------- TRANSITORIO: tile e info de la tarjeta anterior -------------
   `.pcard__tile`, `.pcard__sub` y `.pcard__meta-sep` ya NO los usa la tarjeta de
   pendiente —Ruta y Agenda pasaron a `.pcard__ic` y `.pcard__meta` del
   prototipo—, pero siguen en pie Detalle, Historial y las fichas de lugares.
   Se van junto con la última de esas pantallas que se portee; hasta entonces
   borrarlos deja esas tres sin el tile de categoría. */
.pcard__tile {
  flex: none; width: 48px; height: 48px; border-radius: var(--r-md);
  display: grid; place-items: center;
  background: var(--tint-cat, var(--green-soft)); color: var(--acento-cat, var(--green));
}
.pcard__tile svg { width: 24px; height: 24px; }
.pcard__sub {
  margin-top: 2px; font-size: var(--fs-13); color: var(--ink-2);
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.pcard__meta-sep { color: var(--ink-3); }

.install-hint { display: none; align-items: center; gap: 12px; }
body.can-install .install-hint { display: flex; }

/* ---- Empujón a instalar, después de resolver un pendiente (§5.12/D2) ----
   Se apoya sobre la barra inferior igual que el toast, pero NO es un toast: se
   queda hasta que la persona lo cierra, porque en iOS el texto es una
   instrucción de dos pasos que nadie alcanza a leer en 2,8 s. */
/* El centrado va por `margin-inline: auto` y NO por `translateX(-50%)`: el
   `transform` es de la animación de entrada/salida (`toastIn`/`toastOut`
   terminan en `transform: none`), así que centrar con él lo deja corrido medio
   ancho a la derecha apenas termina de entrar. */
.instalar {
  position: fixed; left: 0; right: 0; margin-inline: auto;
  bottom: calc(var(--safe-b) + 92px);   /* idem: la píldora ya no es una franja */
  z-index: var(--z-sheet); width: min(var(--app-max), 92%);
  display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap;
  padding: 14px 16px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--sh-lg);
  animation: toastIn var(--dur-base) var(--ease-out) both;
}
.instalar.is-out { animation: toastOut var(--dur-base) var(--ease-out) both; }
.instalar__ic {
  flex: none; width: 40px; height: 40px; border-radius: var(--r-md);
  display: grid; place-items: center;
  background: var(--green-soft); color: var(--green);
}
.instalar__ic svg { width: 22px; height: 22px; }
.instalar__cuerpo { flex: 1; min-width: 12ch; }
.instalar__titulo { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.instalar__texto { margin-top: 2px; font-size: var(--fs-13); color: var(--ink-2); }
/* Los botones se van al ancho completo cuando el texto ya ocupó el renglón: en
   pantallas angostas, apretados al costado quedaban por debajo del área táctil. */
.instalar__acciones { display: flex; gap: 8px; margin-left: auto; }

/* =====================================================================
   Fase B — Compras, Trámites, Agenda, Historial, Perfil, Sincronización
   ===================================================================== */

/* ---- Buscador y rubros (Compras) ----
   El prototipo pone al lado del buscador un botón "Filtro" que abre una hoja
   que acá no existe; se omite en vez de dibujar un control muerto. */
.searchbar {
  display: flex; align-items: center; gap: 9px; margin-bottom: 14px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-pill); padding: 0 16px;
  box-shadow: var(--sh-sm); color: var(--muted);
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.searchbar:focus-within { border-color: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green-soft) 70%, transparent); }
.searchbar svg { flex: none; width: 18px; height: 18px; }
.searchbar__input {
  flex: 1; min-width: 0; border: none; background: none; outline: none;
  padding: 11px 0; font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink);
}
.searchbar__input::placeholder { color: var(--muted); font-weight: var(--fw-bold); }

/* Fila de rubros: se desplaza en horizontal en vez de envolver. Envolviendo,
   cambiar de filtro movía la grilla entera hacia abajo. */
.chip-row {
  display: flex; gap: 9px; overflow-x: auto;
  padding: 2px 2px 12px; scrollbar-width: none;
}
.chip-row::-webkit-scrollbar { display: none; }
.chip-filtro {
  flex: none; display: flex; align-items: center; gap: 6px;
  padding: 7px 14px 7px 10px; border-radius: var(--r-pill);
  border: 1px solid var(--line); background: var(--surface); color: var(--muted);
  font-size: var(--fs-12-5); font-weight: var(--fw-bold);
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.chip-filtro svg { flex: none; }
.chip-filtro.is-active { background: var(--green-soft); color: var(--green-dk); border-color: transparent; }
.chip-filtro:active { transform: scale(.95); }

/* ---- Grilla de productos ---- */
.prod-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; padding-bottom: 6px; }
.prod {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); box-shadow: var(--sh-sm);
  transform-style: preserve-3d;
  animation: cardIn var(--dur-base) var(--ease-out) both;
  transition: box-shadow var(--dur-fast) var(--ease-out);
}
.prod:hover { box-shadow: var(--sh-md); }
/* Media con el degradado del rubro. El prototipo pone acá la foto del producto
   (`<image-slot>`, que su README marca como cosa de prototipar); hasta que la
   API traiga `imagen_url`, va el emoji sobre el degradado. */
.prod__media {
  position: relative; height: 170px; display: grid; place-items: center;
  /* La caja recorta lo que sobre. Iba en `.prod`, que está más afuera: la foto
     desbordaba la media y `.prod` la recortaba recién al borde de la TARJETA,
     o sea después de haber pasado por encima del nombre, la tienda y el precio. */
  overflow: hidden;
  background: linear-gradient(150deg, var(--prod-tint, var(--green-soft)), var(--prod-deep, #EDF6F2));
}
.prod__emoji { font-size: 2.6rem; line-height: 1; color: var(--green-dk); filter: drop-shadow(0 6px 10px rgba(37,51,49,.18)); }
/* Foto real (opciones de compra que trae la API).
   ⚠️ `position: absolute`, y NO es cosmética: es el arreglo del bug del 29/7 en
   el que las tarjetas no mostraban ni tienda ni precio.
   Con la foto en el flujo de la grilla, `height: 100%` no resolvía contra nada
   —la fila es `auto` y `place-items: center` le saca el estirado—, así que valía
   `auto` y la imagen tomaba su alto INTRÍNSECO: una foto de ropa en retrato
   (600×900) medía 263 px dentro de una caja de 120 px y se pintaba encima del
   cuerpo. Se veía como "la tarjeta no trae precio", y el precio estaba ahí abajo,
   tapado. Cuanto más vertical la foto, más tapaba: por eso una tarjeta mostraba
   el precio y la de al lado no.
   Sacada del flujo, la imagen no puede empujar la fila ni desbordar: `inset: 0`
   la ata a los 170 px de la caja y `object-fit: cover` la encuadra. */
.prod__foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Un rubro por tinte, reusando los tokens que ya existen — no se inventan
   colores nuevos para esto. */
.prod--mascotas   { --prod-tint: var(--shop-super-tint);    --prod-deep: var(--shop-super-deep); }
.prod--hogar      { --prod-tint: var(--shop-hogar-tint);    --prod-deep: var(--shop-hogar-deep); }
.prod--regalos    { --prod-tint: var(--cat-recordatorio-tint); --prod-deep: var(--cat-recordatorio-border); }
.prod--transporte { --prod-tint: var(--shop-farmacia-tint); --prod-deep: var(--shop-farmacia-deep); }

.prod__body { padding: 11px 12px 13px; }
.prod__name {
  font-size: var(--fs-14); font-weight: var(--fw-black); color: var(--ink);
  line-height: 1.25; min-height: 35px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.prod__store { display: flex; align-items: center; gap: 5px; margin-top: 5px; color: var(--muted); font-size: var(--fs-12); font-weight: var(--fw-bold); }
.prod__store svg { width: 13px; height: 13px; flex: none; }
.prod__prices { display: flex; align-items: baseline; gap: 6px; margin-top: 8px; }
.prod__price { font-size: 19px; font-weight: var(--fw-black); color: var(--green-dk); letter-spacing: -.02em; }
.prod__acts { display: flex; gap: 7px; margin-top: 11px; }
.prod__go {
  flex: 1; min-width: 0; white-space: nowrap; text-align: center;
  padding: 10px 6px; border-radius: var(--r-pill);
  background: var(--green); color: #fff;
  font-size: var(--fs-12); font-weight: var(--fw-black);
  box-shadow: var(--sh-sm);
  transition: background var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.prod__go:hover { background: var(--green-hover); }
.prod__go:active { transform: scale(.94); }
.prod__share {
  flex: none; width: 36px; height: 36px; padding: 0;
  display: grid; place-items: center; border-radius: 50%;
  border: 1.5px solid var(--line); background: var(--cream); color: var(--green-dk);
}
.prod__share:active { transform: scale(.9); }

/* Las fichas de lugar viven en el bloque DETALLE, al final del archivo: son las
   mismas para Trámites y Detalle, con una sola definición. */

/* ---- Mapa estilizado ---- */
.map-holder { border-radius: var(--r-lg); overflow: hidden; height: 200px; box-shadow: var(--sh-sm); border: 1px solid var(--line); }
.map-holder svg { display: block; height: 100%; width: 100%; }

/* ---- Switch ---- */
.switch-row { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3) 0; }
.switch-row + .switch-row { border-top: 1px solid var(--line); }
.switch-row__text { flex: 1; }
.switch-row__label { display: block; font-weight: var(--fw-bold); color: var(--ink); }
.switch-row__hint { display: block; font-size: var(--fs-13); color: var(--ink-2); margin-top: 2px; }
.switch {
  flex: none; width: 50px; height: 30px; border-radius: var(--r-pill);
  background: var(--surface-sunk); border: 1px solid var(--line); position: relative;
  transition: background var(--dur-fast) var(--ease-out);
}
.switch__thumb { position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: var(--sh-sm); transition: transform var(--dur-base) var(--ease-out); }
.switch.is-on { background: var(--green); border-color: var(--green); }
.switch.is-on .switch__thumb { transform: translateX(20px); }

/* ---- Planes (Perfil) ---- */
.plan-card { border-radius: var(--r-xl); padding: var(--sp-5); background: var(--grad); color: #fff; box-shadow: var(--sh-brand); position: relative; overflow: hidden; }
.plan-card__blob { position: absolute; width: 160px; height: 160px; border-radius: 50%; background: rgba(255,255,255,.08); top: -60px; right: -40px; }
.plan-card__tag { font-size: var(--fs-12); font-weight: var(--fw-x); letter-spacing: .05em; text-transform: uppercase; opacity: .85; }
.plan-card__name { font-size: var(--fs-24); font-weight: var(--fw-black); margin-top: 2px; }
.plan-card__desc { margin-top: 6px; font-size: var(--fs-14); opacity: .92; }

/* ---- Filas de ajustes / navegación interna ---- */
.row-link {
  display: flex; align-items: center; gap: var(--sp-3); width: 100%; text-align: left;
  padding: var(--sp-3) var(--sp-4); background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); box-shadow: var(--sh-sm); color: inherit;
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.row-link:hover { transform: translateY(-2px); box-shadow: var(--sh-md); }
.row-link__ic { flex: none; width: 40px; height: 40px; border-radius: var(--r-md); display: grid; place-items: center; background: var(--green-soft); color: var(--green-dk); }
.row-link__ic svg { width: 20px; height: 20px; }
.row-link__body { flex: 1; min-width: 0; }
/* `display:block` porque en el markup son <span>: sin esto, título y subtítulo
   se pegan en un renglón ("Ver ficha del trámiteRequisitos, costos y lugares"). */
.row-link__title { display: block; font-weight: var(--fw-x); color: var(--ink); }
.row-link__sub { display: block; font-size: var(--fs-13); color: var(--ink-2); }
.row-link__chev { flex: none; color: var(--ink-3); }
.row-link--danger .row-link__ic { background: var(--alerta-bg); color: var(--alerta); }

/* ---- Perfil: cabecera ---- */
.profile-head { display: flex; align-items: center; gap: var(--sp-4); }
.profile-avatar { width: 68px; height: 68px; border-radius: 50%; display: grid; place-items: center; font-size: var(--fs-28); font-weight: var(--fw-black); color: #fff; background: var(--grad); box-shadow: var(--sh-md); }
.profile-name { font-size: var(--fs-24); font-weight: var(--fw-black); color: var(--ink); letter-spacing: -.02em; }
.profile-sub { color: var(--ink-2); font-size: var(--fs-14); }

/* ---- Chip de origen (WhatsApp / app) en historial ---- */
.mini-flag { font-size: var(--fs-11); font-weight: var(--fw-bold); color: var(--ink-3); }

/* ---- Sincronización ---- */
.sync-hero { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); text-align: center; padding: var(--sp-6) 0 var(--sp-2); }
.sync-hero__art { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; }
.sync-hero__art svg { width: 40px; height: 40px; }
.sync--ok .sync-hero__art { background: var(--exito-bg); color: var(--exito); }
.sync--pend .sync-hero__art { background: var(--info-bg); color: var(--info); }
.sync-item { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3) 0; border-bottom: 1px solid var(--line); }
.sync-item:last-child { border-bottom: none; }
.sync-item__dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--coral); }

/* ---- Confeti / celebración al resolver ---- */
.confeti { position: fixed; inset: 0; pointer-events: none; z-index: 70; overflow: hidden; }
.confeti i {
  position: absolute; left: 50%; top: 62%; border-radius: 2px; opacity: 0;
  animation: confeti-fly var(--d, 1.1s) cubic-bezier(.15, .7, .3, 1) var(--dl, 0s) forwards;
}
@keyframes confeti-fly {
  0%   { opacity: 0; transform: translate(0, 0) rotate(0); }
  12%  { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--x, 0), -240px) rotate(var(--r, 180deg)); }
}
@media (prefers-reduced-motion: reduce) { .confeti { display: none; } }

/* ============================================================
   Rediseño Claude Design — Inicio: header hero + tablero de notas
   ============================================================ */

/* Header hero — medidas del prototipo: el hero es 22px/800, no 32px/900. A 32px
   ocupaba tres líneas en un teléfono y empujaba el tablero fuera de la pantalla,
   que es lo primero que la persona tiene que ver. */
.greet__hi { font-size: var(--fs-15); font-weight: var(--fw-bold); color: var(--muted); letter-spacing: normal; }
.greet__hero { margin-top: 3px; font-size: 22px; font-weight: var(--fw-x); line-height: 1.2; letter-spacing: -.015em; color: var(--ink); }
.greet__accent { color: var(--green); }

/* Botón soft: secundario claro, para usar SOBRE una nota coloreada */
.btn--soft { background: rgba(255,255,255,.72); color: var(--green-dk); }
.btn--soft:hover { background: rgba(255,255,255,.9); }

/* Acción primaria que toma el COLOR DE LA CATEGORÍA del pendiente (prototipo:
   en un vencimiento el "Resolver" es ámbar, no verde). El acento lo define la
   clase `cat-*` del contenedor; el verde queda de reserva. */
.btn--cat { background: var(--acento-cat, var(--green)); color: #fff; }
.btn--cat:hover { filter: brightness(.94); }
/* Cada categoría publica sus cuatro papeles en un solo lugar: el acento fuerte,
   el tint del tile, su borde y el color de texto. Todo lo que se tiñe por
   categoría (notas, tarjetas, botones, checks) lee de acá, así agregar una
   categoría es agregar una línea y no rastrear reglas por todo el archivo. */
.cat-compra {
  --acento-cat: var(--cat-compra-accent); --tint-cat: var(--cat-compra-tint);
  --borde-cat: var(--cat-compra-border); --texto-cat: var(--cat-compra-ink);
}
.cat-vencimiento {
  --acento-cat: var(--cat-vencimiento-accent); --tint-cat: var(--cat-vencimiento-tint);
  --borde-cat: var(--cat-vencimiento-border); --texto-cat: var(--cat-vencimiento-ink);
}
.cat-tramite {
  --acento-cat: var(--cat-tramite-accent); --tint-cat: var(--cat-tramite-tint);
  --borde-cat: var(--cat-tramite-border); --texto-cat: var(--cat-tramite-ink);
}
.cat-objetivo {
  --acento-cat: var(--cat-objetivo-accent); --tint-cat: var(--cat-objetivo-tint);
  --borde-cat: var(--cat-objetivo-border); --texto-cat: var(--cat-objetivo-ink);
}
.cat-recordatorio {
  --acento-cat: var(--cat-recordatorio-accent); --tint-cat: var(--cat-recordatorio-tint);
  --borde-cat: var(--cat-recordatorio-border); --texto-cat: var(--cat-recordatorio-ink);
}
.cat-personal {
  --acento-cat: var(--cat-personal-accent); --tint-cat: var(--cat-personal-tint);
  --borde-cat: var(--cat-personal-border); --texto-cat: var(--cat-personal-ink);
}
.cat-recurrente {
  --acento-cat: var(--cat-recurrente-accent); --tint-cat: var(--cat-recurrente-tint);
  --borde-cat: var(--cat-recurrente-border); --texto-cat: var(--cat-recurrente-ink);
}

/* Tablero de notas.
   El papel es RECTO (border-radius 4px), no redondeado: con 16px las notas se
   leían como tarjetas de app y se perdía la metáfora de la heladera.

   Desde §5.12/B el tablero dejó de ser una PANTALLA y pasó a ser el bloque
   "Después" de la Ruta: arriba el prioritario como nota destacada, abajo el
   resto como papeles. Todo esto sigue en uso — `NotaDestacada`, `NotaCard` y
   `Tablero` en components.js. */
.noteboard { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 14px; padding: 10px 4px 6px; }
.nota {
  position: relative; border-radius: 4px;
  padding: 22px 13px 13px; background: var(--surface);
  box-shadow: 2px 5px 12px rgba(37,51,49,.15); transform: rotate(var(--rot, 0deg));
  /* El transform usa la curva de RESORTE: la nota se endereza pasándose un poco,
     como papel que se despega. La sombra acompaña con la curva suave. */
  transition: transform var(--dur-base) var(--ease-spring), box-shadow var(--dur-base) var(--ease-out);
}
.nota:hover { transform: rotate(0) translateY(-3px) scale(1.03); box-shadow: 3px 11px 22px rgba(37,51,49,.2); z-index: 1; }
.nota:active { transform: rotate(0) scale(.98); }
.nota--feat:active { transform: rotate(0) scale(.99); }
.nota__actions .btn:active { transform: scale(.96); }
/* Cinta y clip alternan por posición: dos formas de sujetar el papel, para que
   la grilla no se lea como una plantilla repetida. La cinta toma el color de la
   categoría (no blanca), como en el prototipo. */
.nota__tape {
  position: absolute; top: -5px; left: 14px; width: 34px; height: 13px;
  transform: rotate(-8deg); background: var(--acento-cat, var(--green));
  border-radius: 3px; opacity: .82;
}
.nota__clip--sm { top: -11px; left: 12px; transform: rotate(16deg); }
.nota__hit { display: block; color: inherit; }
.nota__title { display: block; margin-top: 16px; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); line-height: 1.28; }
.nota__cat { display: flex; align-items: center; gap: 5px; margin-top: 8px; font-size: 11.5px; font-weight: var(--fw-x); }
.nota__cat svg { width: 15px; height: 15px; flex: none; }
.nota__meta { display: block; margin-top: 3px; font-size: var(--fs-12); font-weight: var(--fw-bold); color: rgba(37,51,49,.55); }
/* Píldora de prioridad: arriba a la DERECHA, con su propio par fondo/texto. */
.nota__prio {
  position: absolute; top: 9px; right: 9px; z-index: 1;
  padding: 3px 8px; border-radius: var(--r-pill);
  font-size: 9.5px; font-weight: var(--fw-black); text-transform: uppercase; letter-spacing: .04em;
}
.nota__prio.prio-alta  { background: #F3D2C6; color: #B4442A; }
.nota__prio.prio-media { background: #F6E2BD; color: #8A5B12; }
.nota__prio.prio-baja  { background: #DBE7DE; color: #4B6B58; }
/* La nota del tablero NO lleva check: se cierra desde el detalle (ver inicio.js). */

/* Notas coloreadas por categoría (fondo tint + acento en el kicker) */
.nota.cat-compra { background: var(--cat-compra-paper); }        .nota.cat-compra .nota__cat { color: var(--cat-compra-accent); }
.nota.cat-vencimiento { background: var(--cat-vencimiento-paper); } .nota.cat-vencimiento .nota__cat { color: var(--cat-vencimiento-accent); }
.nota.cat-tramite { background: var(--cat-tramite-paper); }      .nota.cat-tramite .nota__cat { color: var(--cat-tramite-accent); }
.nota.cat-objetivo { background: var(--cat-objetivo-paper); }    .nota.cat-objetivo .nota__cat { color: var(--cat-objetivo-accent); }
.nota.cat-recordatorio { background: var(--cat-recordatorio-paper); } .nota.cat-recordatorio .nota__cat { color: var(--cat-recordatorio-accent); }
.nota.cat-personal { background: var(--cat-personal-paper); }    .nota.cat-personal .nota__cat { color: var(--cat-personal-accent); }

/* Nota destacada (prioritario): ancho completo, con clip y badge */
.nota--feat {
  grid-column: 1 / -1; padding: 30px 18px 16px; transform: rotate(-1deg);
  box-shadow: 3px 8px 20px rgba(37,51,49,.2);
}
.nota--feat:hover { transform: rotate(0) translateY(-3px); box-shadow: 4px 14px 28px rgba(37,51,49,.24); }
.nota__clip { position: absolute; top: -13px; left: 20px; color: #8A968F; transform: rotate(14deg); }
.nota__clip svg { display: block; }
/* La píldora se tiñe con el ACENTO DE LA CATEGORÍA (ámbar en un vencimiento),
   no con el verde de marca: así el prioritario se lee como parte de su nota. */
.nota__badge {
  position: absolute; top: 13px; right: 13px; z-index: 1; display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: var(--r-pill); background: var(--acento-cat, var(--green)); color: #fff;
  font-size: 10.5px; font-weight: var(--fw-black); text-transform: uppercase; letter-spacing: .04em;
}
.nota__badge svg { width: 12px; height: 12px; fill: currentColor; }
.nota--feat .nota__cat { margin-top: 0; gap: 6px; font-size: 11.5px; font-weight: var(--fw-black); text-transform: uppercase; letter-spacing: .03em; }
.nota--feat .nota__cat svg { width: 16px; height: 16px; }
/* El título de la nota destacada es un ENLACE al detalle desde que `/` es la
   Ruta (§5.12/B): la nota dejó de convivir con un tablero donde tocar cualquier
   otra abría sus pasos, así que sin esto "Ver pasos" no tendría camino. Se
   estila como texto — un link azul subrayado dentro del papel rompería la pieza. */
.nota__ftitle-hit { display: block; color: inherit; text-decoration: none; }
.nota__ftitle { margin-top: 8px; font-size: 22px; font-weight: var(--fw-black); letter-spacing: -.01em; line-height: 1.18; color: var(--ink); }
.nota__fmeta { margin-top: 8px; font-size: var(--fs-13); font-weight: var(--fw-bold); color: rgba(37,51,49,.55); }
.nota__actions { display: flex; gap: 10px; margin-top: 16px; }
.nota__actions .btn { min-height: 0; padding: 13px; font-size: 14.5px; font-weight: var(--fw-black); border-radius: var(--r-pill); }
.nota__actions .btn--cat { flex: 1; box-shadow: var(--sh-sm); }
/* El secundario del prototipo es papel translúcido con borde fino, no blanco
   sólido: sobre una nota de color, el blanco competía con el primario. */
.nota__actions .btn--soft {
  flex: none; padding: 13px 18px; font-size: var(--fs-14); font-weight: var(--fw-x);
  background: rgba(255,255,255,.4); border: 1.5px solid rgba(37,51,49,.2); color: var(--ink);
}
.nota__actions .btn--soft:hover { background: rgba(255,255,255,.62); }

/* El buscador vive en el bloque de Compras, más arriba: una sola definición. */

/* =====================================================================
   PERFIL 7a — cabecera verde con la foto colgada, cuatro filas, la fila del
   plan, la tarjeta de instalar y el pie.

   La pantalla pide `hideTop` (trae su propia cabecera en vez de la topbar
   compartida), así que `#app` va sin padding: la cabecera sangra sola de punta
   a punta y `.p7-body` pone el suyo. Del handoff `Perfil NIDU.dc.html` (7a).

   `.plan-seg*` (más abajo) lo usa `/planes`; `.ajustes/.ajuste/.sw` los usa
   `/avisos`.
   ===================================================================== */

/* ---- Cabecera verde: barra, curva de crema y foto montada ---- */
.p7-head {
  position: relative;
  min-height: 214px;
  background: var(--green-dk);
  /* Sin overflow:hidden a propósito: la foto cuelga -48 y se le cortaría la
     mitad de arriba. */
}
.p7-head__bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(var(--safe-t) + 16px) 20px 0;
}
.p7-icbtn {
  width: 40px; height: 40px; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: var(--r-pill);
  background: rgba(255,255,255,.14); color: #fff; cursor: pointer;
  transition: background var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.p7-icbtn:active { background: rgba(255,255,255,.24); transform: translateX(-2px); }
.p7-editar {
  min-height: 38px; padding: 0 15px;
  border: 1px solid rgba(255,255,255,.32); border-radius: var(--r-pill);
  background: transparent; color: #fff;
  font-family: inherit; font-size: var(--fs-12-5); font-weight: var(--fw-x); cursor: pointer;
  transition: background var(--dur-fast) var(--ease-out);
}
.p7-editar:active { background: rgba(255,255,255,.14); }

/* La curva se anima sola (`niduBowl`, scaleY con origen abajo): escalar la
   cabecera entera le deforma el texto. Va pegada al fondo del verde, ancho
   completo, y se rellena con el color del cuerpo para que la costura sea limpia. */
.p7-bowl {
  position: absolute; left: 0; right: 0; bottom: -1px;
  width: 100%; height: 62px; display: block;
  transform-origin: 50% 100%;
  animation: niduBowl .6s cubic-bezier(.3,0,.2,1) both;
}

/* Foto: DENTRO de la cabecera, colgada a bottom:-48. El centrado va en el
   envoltorio estático (`.p7-avatar`) y el rebote en el span interno
   (`.p7-avatar__pop`): nunca una posición dentro de un keyframe, porque
   `prefers-reduced-motion` apaga la animación y se llevaría puesto el centrado. */
.p7-avatar {
  position: absolute; left: 50%; bottom: -48px;
  display: inline-flex; transform: translateX(-50%);
}
.p7-avatar__pop {
  position: relative; display: inline-flex;
  animation: niduAvIn .5s var(--ease-spring) both .2s;
}
.p7-avatar__circle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 96px; height: 96px; border-radius: var(--r-pill);
  background: var(--green-dk); color: #fff; overflow: hidden;
  border: 5px solid var(--app-bg);
  font-size: 34px; font-weight: var(--fw-black); letter-spacing: -.03em;
}
.p7-avatar__img { width: 100%; height: 100%; border-radius: var(--r-pill); object-fit: cover; }
.p7-avatar__check {
  position: absolute; right: -2px; bottom: 2px;
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: var(--r-pill);
  background: var(--green); border: 4px solid var(--app-bg);
  animation: niduCheckPop .5s var(--ease-spring) both 1.5s;
}

/* ---- Cuerpo: pone el padding que `#app` dejó de poner (hideTop lo lleva a 0).
   El bottom reserva la nav absoluta (mismos 78px que `#app` en las pantallas
   normales, línea 662): sin esto el pie chocaba con la tab bar. ---- */
.p7-body { padding: 0 20px calc(var(--safe-b) + 78px); }

/* Nombre + pastilla de historial (la acción del progreso, no un dato suelto) */
.p7-ident { display: flex; flex-direction: column; align-items: center; padding-top: 60px; }
.p7-name { font-size: var(--fs-23); font-weight: var(--fw-black); letter-spacing: -.03em; color: var(--ink); }
.p7-hist {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 36px; margin-top: 5px; padding: 0 13px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-pill);
  transition: border-color var(--dur-fast) var(--ease-out);
}
.p7-hist:active { border-color: var(--green); }
.p7-hist__go { font-size: var(--fs-12-5); font-weight: var(--fw-x); color: var(--green-dk); }
.p7-hist__sep { width: 4px; height: 4px; border-radius: var(--r-pill); background: #C9CFC8; }
.p7-hist__link { font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--green); }
.p7-hist svg { color: var(--green); }

/* ---- Filas de ajuste: un ajuste por fila, su estado a la derecha ---- */
.p7-rows {
  margin-top: 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  overflow: hidden; box-shadow: var(--sh-sm);
}
.p7-row {
  display: flex; align-items: center; gap: 12px;
  min-height: 52px; padding: 8px 13px;
  border-bottom: 1px solid #F2EFE7; color: inherit;
  animation: niduFila .45s var(--ease-out) both;
}
.p7-row:last-child { border-bottom: 0; }
.p7-row:active { background: #FAF8F4; }
.p7-rows > :nth-child(1) { animation-delay: .06s; }
.p7-rows > :nth-child(2) { animation-delay: .12s; }
.p7-rows > :nth-child(3) { animation-delay: .18s; }
.p7-rows > :nth-child(4) { animation-delay: .24s; }
.p7-rows > :nth-child(5) { animation-delay: .30s; }
.p7-row__ic {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: var(--r-sm);
  background: var(--surface-sunk); color: #3C463F;
}
.p7-row__ic--star { background: var(--green-soft); color: var(--green); }
.p7-row__label { flex: 1; min-width: 0; font-size: var(--fs-14); font-weight: var(--fw-bold); letter-spacing: -.01em; color: var(--ink); }
.p7-row__label--stack { display: flex; flex-direction: column; }
.p7-row__t { font-size: var(--fs-14); font-weight: var(--fw-bold); letter-spacing: -.01em; color: var(--ink); }
.p7-row__s { margin-top: 1px; font-size: var(--fs-11-5); color: var(--muted); }
.p7-row__state { flex: none; font-size: var(--fs-12-5); color: var(--muted); }
.p7-row__on { display: inline-flex; align-items: center; gap: 6px; font-weight: var(--fw-bold); color: var(--green); }
.p7-row__dot { width: 7px; height: 7px; border-radius: var(--r-pill); background: var(--green); }
.p7-row__badge {
  flex: none; display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 22px; padding: 0 7px; border-radius: var(--r-sm);
  background: var(--green-soft); color: var(--green-dk);
  font-size: var(--fs-11-5); font-weight: var(--fw-black);
}
/* `display:inline-flex` de arriba le gana al `display:none` del atributo `hidden`,
   así que la insignia vacía se veía como un óvalo verde. Se apaga explícitamente. */
.p7-row__badge[hidden] { display: none; }
.p7-row__chev { flex: none; color: #8A948E; }

/* ---- Tarjeta de instalar: el ovillo late (halo) y se mece (p7Mark) ---- */
.p7-install {
  width: 100%; margin-top: 12px;
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px 9px 9px;
  background: var(--surface); border: 1px solid #C9DED2; border-radius: var(--r-md);
  text-align: left; cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
  animation: niduFila .45s var(--ease-out) both .36s;
}
.p7-install:active { border-color: var(--green); transform: scale(.985); }
.p7-install__mark { position: relative; flex: none; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; }
.p7-install__halo { position: absolute; inset: 0; border-radius: var(--r-pill); border: 1.5px solid var(--green); animation: niduHalo 3.4s ease-out infinite; }
.p7-install__glyph { display: inline-flex; animation: p7Mark 6s ease-in-out infinite; }
.p7-install__glyph svg { width: 34px; height: auto; }
.p7-install__body { flex: 1; min-width: 0; }
.p7-install__t { display: block; font-size: var(--fs-13); font-weight: var(--fw-black); letter-spacing: -.015em; color: var(--ink); }
.p7-install__s { display: block; margin-top: 1px; font-size: var(--fs-11); line-height: 1.3; color: var(--muted); }
.p7-install__cta {
  flex: none; display: inline-flex; align-items: center; height: 32px; padding: 0 13px;
  border-radius: var(--r-pill); background: var(--green); color: #fff;
  font-size: var(--fs-12); font-weight: var(--fw-black); white-space: nowrap;
}

/* ---- Pie: cerrar sesión / restaurar + versión ---- */
.p7-foot {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  padding: 12px 0 0;
  animation: niduFila .45s var(--ease-out) both .42s;
}
.p7-foot__btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 0 4px;
  background: none; border: 0; font-family: inherit;
  font-size: var(--fs-13); font-weight: var(--fw-bold); cursor: pointer;
  transition: color var(--dur-fast) var(--ease-out);
}
.p7-foot__btn--out { color: var(--coral); }
.p7-foot__btn--out:active { color: #7C3529; }
.p7-foot__dot { width: 4px; height: 4px; border-radius: var(--r-pill); background: #C9CFC8; }
.p7-foot__ver { background: none; border: 0; font-family: inherit; font-size: var(--fs-11); font-weight: var(--fw-semi); color: var(--muted); cursor: pointer; }

/* Movimiento reducido: sin animaciones, todo en su estado final. El centrado de
   la foto vive en `.p7-avatar` (no animado), así que apagar el rebote no lo
   descoloca. */
@media (prefers-reduced-motion: reduce) {
  .p7-bowl, .p7-avatar__pop, .p7-avatar__check,
  .p7-row, .p7-install, .p7-foot,
  .p7-install__halo, .p7-install__glyph { animation: none; }
}

/* ---- Planes: segmentador (opción 3b del handoff) ----
   Se elige la pestaña (Free · Plus · Premium) y la ficha de abajo cambia — sin
   swipe, con la lista COMPLETA del plan elegido. Reemplazó a la pila 3D girable:
   en `/planes` (pantalla propia) hay alto de sobra, así que el costo de los 67px
   que la 3b no entraba en Perfil ya no aplica. */
.plan-seg {
  margin-top: 6px;
  padding: 16px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
}
.plan-seg__label { display: block; margin: 2px 2px 12px; }
/* La barra de pestañas: track hundido, la activa se rellena de verde profundo. */
.plan-seg__tabs {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px;
  padding: 5px; border-radius: var(--r-sm);
  background: var(--surface-2); border: 1px solid var(--line);
}
.plan-seg__tab {
  min-height: 44px; padding: 0 6px;
  border: 0; border-radius: 10px; background: transparent;
  font-family: inherit; font-size: var(--fs-14-5); font-weight: var(--fw-bold);
  color: var(--ink-2); cursor: pointer;
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.plan-seg__tab.is-on { background: var(--green-dk); color: #fff; box-shadow: var(--sh-sm); }

/* La ficha del plan elegido. */
.plan-seg__card {
  margin-top: 14px; padding: 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  box-shadow: var(--sh-sm);
  animation: fadeIn var(--dur-base) var(--ease-out) both;
}
.plan-seg__head { display: flex; align-items: baseline; gap: 8px; }
.plan-seg__name { font-size: 22px; font-weight: var(--fw-black); letter-spacing: -.02em; color: var(--ink); }
.plan-seg__price { font-size: var(--fs-17); font-weight: var(--fw-black); color: var(--green); }
.plan-seg__per { font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--muted); }
.plan-seg__feats { display: flex; flex-direction: column; gap: 9px; margin-top: 14px; }
.plan-seg__feat { display: flex; align-items: center; gap: 10px; font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink); }
.plan-seg__feat svg { flex: none; color: var(--green); }
.plan-seg__cta {
  width: 100%; margin-top: 16px; min-height: 48px; padding: 0 14px;
  border-radius: var(--r-sm); border: 0;
  background: var(--green); color: #fff;
  font-family: inherit; font-size: var(--fs-14-5); font-weight: var(--fw-black); cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out);
}
.plan-seg__cta:active { transform: scale(.985); }
/* El plan que la persona YA tiene: botón inerte, contorneado en vez de relleno. */
.plan-seg__cta--actual {
  background: var(--surface); color: var(--green-dk);
  border: 1px solid var(--green-med); cursor: default;
}

/* ---- Lista de ajustes ---- */
.ajustes {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sh-sm);
}
.ajuste {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 15px; text-align: left; color: inherit;
  border: none; border-bottom: 1px solid var(--line); background: none;
}
.ajuste:last-child { border-bottom: none; }
.ajuste--link { cursor: pointer; }
.ajuste--link:active { background: var(--cream); }
.ajuste__ic { flex: none; display: grid; place-items: center; color: var(--muted); }
.ajuste__ic--verde { color: var(--whats); }
.ajuste__label { flex: 1; min-width: 0; font-size: var(--fs-15); font-weight: var(--fw-x); }
/* Fila de toggle a dos líneas (Avisos): título + aclaración debajo. */
.ajuste__label--stack { display: flex; flex-direction: column; gap: 1px; }
.ajuste__title { font-size: var(--fs-14-5); font-weight: var(--fw-x); color: var(--ink); }
.ajuste__sub { font-size: var(--fs-12); font-weight: var(--fw-regular); color: var(--muted); }
.ajuste__chev { flex: none; color: var(--ink-3); }
.ajuste--danger .ajuste__label { color: var(--alerta); }
.ajuste--danger .ajuste__ic { color: var(--alerta); }

/* Fila de dirección (Perfil: casa/trabajo) — mismo `.ajuste` que el resto de
   la lista, pero con la etiqueta angosta y fija (no `flex:1`) para dejarle
   el espacio elástico al input, alineado a la derecha como el switch. */
.ajuste--input .ajuste__label { flex: none; width: 64px; }
.ajuste__input { flex: 1; min-width: 0; border: none; background: none; padding: 0; font: inherit; font-size: var(--fs-15); font-weight: var(--fw-semi); color: var(--ink); text-align: right; }
.ajuste__input::placeholder { color: var(--ink-3); font-weight: var(--fw-regular); }
.ajuste__input:focus { outline: none; color: var(--green-dk); }

/* Interruptor */
.sw {
  position: relative; flex: none; width: 50px; height: 30px; padding: 0;
  border: none; border-radius: var(--r-pill); background: #CDD6D1; cursor: pointer;
  transition: background var(--dur-base) var(--ease-out);
}
.sw.is-on { background: var(--green); }
.sw__knob {
  position: absolute; top: 3px; left: 3px; width: 24px; height: 24px;
  border-radius: 50%; background: #fff; box-shadow: var(--sh-sm);
  transition: left var(--dur-base) var(--ease-spring);
}
.sw.is-on .sw__knob { left: 23px; }

.perfil-pie {
  margin: 22px 4px calc(var(--safe-b) + var(--sp-4));
  text-align: center; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted);
}

/* ---------------- Ruta: estado vacío ----------------
   Valores del prototipo. El anillo flota con `floaty` en bucle: es lo único que
   se mueve en la pantalla, y por eso funciona como recompensa. */
.ruta-empty {
  text-align: center; padding: 60px 20px;
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.ruta-empty__ring {
  width: 96px; height: 96px; margin: 0 auto 18px;
  border-radius: 50%; background: var(--green-soft);
  display: grid; place-items: center; color: var(--green-dk);
  animation: floaty 3s ease-in-out infinite;
}
.ruta-empty__title { font-size: var(--fs-20); font-weight: var(--fw-black); color: var(--ink); }
.ruta-empty__sub {
  margin-top: 6px; max-width: 250px; margin-inline: auto;
  font-size: 14.5px; font-weight: var(--fw-bold); color: var(--muted);
}

/* =====================================================================
   DETALLE — pasos con progreso, fichas de lugar, CTA
   El hero teñido del prototipo (bloque DETALLE de su components.css) se
   reemplazó por `rt-card`/`rt-next` (ver ruta.js): el resto de esta pantalla
   ya compartía componente con el resto de la app (`ListaCard`, `TramiteCard`,
   `LugarTramiteCard`), y el hero era la única pieza en su propio lenguaje
   visual, sin tocar desde el port inicial (reporte del fundador, 4/8).
   ===================================================================== */

/* Cabecera de sección: etiqueta a la izquierda, conteo en verde a la derecha. */
.detail-sec {
  display: flex; align-items: center; justify-content: space-between;
  margin: 22px 4px 10px;
}
.detail-count { font-size: var(--fs-13); font-weight: var(--fw-x); color: var(--green); }

/* Barra de progreso de los pasos */
.progress {
  height: 8px; margin: 0 2px 14px;
  background: var(--track-dk); border-radius: var(--r-pill); overflow: hidden;
}
.progress__fill {
  height: 100%; width: var(--pct, 0%);
  background: var(--grad); border-radius: var(--r-pill);
  transition: width var(--dur-slow) var(--ease-spring);
}

/* Paso / ítem: tarjeta con caja de check redondeada. Reemplaza al círculo
   numerado que había antes — el número sugería un orden obligatorio que estos
   pasos no tienen. */
.step {
  display: flex; align-items: center; gap: 13px; width: 100%;
  padding: 14px; text-align: left;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-md); cursor: pointer;
}
.step:active { transform: scale(.98); }
.step--item { padding: 13px 14px; }
.step__box {
  flex: none; width: 26px; height: 26px; border-radius: 9px;
  display: grid; place-items: center;
  border: 2px solid var(--step-ring); background: transparent; color: #fff;
  transition: all var(--dur-base) var(--ease-spring);
}
.step.is-done .step__box { border-color: var(--green); background: var(--green); }
.step__text { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.step.is-done .step__text { color: var(--muted); text-decoration: line-through; }
/* El tachado de una lista lo pone `.step-fila.is-done` (el tilde y el ⋮ son dos
   botones hermanos). Estas reglas siguen sirviendo para los pasos de trámite,
   que sí usan `.step` suelto. */
.step--item .step__text { flex: 1; }
.step__price { font-size: var(--fs-13); font-weight: var(--fw-black); color: var(--green-dk); }

/* Ficha de lugar */
.place {
  padding: 14px; margin-bottom: 8px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-md); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.place__row { display: flex; align-items: center; gap: 12px; }
.place__ic {
  flex: none; width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--green-soft); color: var(--green-dk);
}
.place__ic--pin { width: 42px; height: 42px; background: var(--green); color: #fff; }
.place__body { flex: 1; min-width: 0; }
.place__name { display: block; font-size: 14.5px; font-weight: var(--fw-x); color: var(--ink); }
.place__meta { display: block; font-size: 12.5px; font-weight: var(--fw-bold); color: var(--muted); }
.place__end { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.place__dist { font-size: 14.5px; font-weight: var(--fw-x); color: var(--green); }
/* Los dos enlaces reales de la PWA, dentro de la ficha. */
.place__acts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-2); margin-top: 12px; }
.place__acts .btn { min-height: 42px; font-size: var(--fs-14); }
/* Servicio sin teléfono publicado: se dice, en vez de dejar la tarjeta sin nada
   debajo del nombre y que parezca que faltó cargar algo. */
.place__sin-tel { display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: var(--fs-13); color: var(--muted); }
.place__sin-tel a { color: var(--green); font-weight: var(--fw-x); }

/* Falta el importe: la salida es subir la factura (§5.6, opción "c"). */
.pago__falta {
  margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line, #e6ede9);
}
.pago__falta-tit {
  font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink); margin-bottom: 10px;
}
/* El label ES el botón: es lo único que dispara un <input type=file> igual en
   iOS y en Android. */
.pago__falta label { cursor: pointer; }
.pago__falta-ayuda {
  margin-top: 8px; font-size: var(--fs-13); color: var(--muted); line-height: 1.35;
}
/* Ofrecer el correo va al final y en tono bajo: es una mejora, no el paso de hoy. */
.pago__conectar {
  display: flex; align-items: flex-start; gap: 6px; margin-top: 12px;
  font-size: var(--fs-13); color: var(--green); font-weight: var(--fw-x); line-height: 1.35;
}
.pago__conectar svg { flex: none; margin-top: 2px; }

/* Cuenta/referencia ya guardada (Redpagos/Abitab, transferencia): grande y en
   fondo suave porque el gesto es copiarla a mano, no solo leerla. */
.pago__cuenta {
  margin-top: 8px; padding: 10px 12px; background: var(--green-soft);
  border-radius: var(--r-md); font-size: var(--fs-16); font-weight: var(--fw-x);
  color: var(--green-dk); word-break: break-word;
}
/* "Cambiar cómo pagás": tono bajo a propósito, es la salida del panel, no la
   acción principal de la tarjeta. */
.pago__cambiar {
  display: flex; align-items: center; gap: 6px; margin-top: 12px; padding: 0;
  background: none; border: none; font-size: var(--fs-13); color: var(--muted);
  font-weight: var(--fw-x); cursor: pointer;
}
.pago__cambiar svg { flex: none; }

/* ---------------- Contacto (teléfono oficial) ---------------- */
/* Una sola cosa en pantalla: el número ES el botón, no un renglón con un botón
   al lado. No hay nada que comparar, solo que llamar. */
.contacto { background: var(--surface); border-radius: var(--r-lg); padding: 20px 18px; box-shadow: var(--sh-sm); }
.contacto__nombre { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.contacto__num {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin-top: 14px; padding: 16px 14px; border-radius: var(--r-pill);
  background: var(--green); color: #fff; font-size: 21px; font-weight: var(--fw-black);
  letter-spacing: .01em; transition: transform var(--dur-fast) var(--ease-out);
}
.contacto__num:active { transform: scale(.97); }
/* Varios números: cada uno su botón, apilados. Antes iban los dos en el mismo y
   el texto se cortaba al medio ("...*1930 (celul"). */
.contacto__nums { display: flex; flex-direction: column; gap: 10px; }
.contacto__nums .contacto__num { margin-top: 0; flex-wrap: wrap; }
.contacto__nums .contacto__num:first-child { margin-top: 14px; }
/* La etiqueta ("teléfono fijo") no compite con el número: más chica y en línea. */
.contacto__etq {
  font-size: var(--fs-13); font-weight: var(--fw-x); font-style: normal;
  opacity: .85; letter-spacing: 0;
}
/* El texto tal como lo publica la fuente, cuando dice algo más que los números. */
.contacto__crudo {
  margin-top: 10px; font-size: var(--fs-13); color: var(--muted); line-height: 1.35;
}
/* Sin `tel:`: mismo lugar, pero no simula ser tocable. */
.contacto__num--muerto { background: var(--surface-2, #eef3f0); color: var(--ink); }
.contacto__fuente, .contacto__viejo {
  display: flex; align-items: flex-start; gap: 6px; margin-top: 12px;
  font-size: var(--fs-13); color: var(--muted); line-height: 1.35;
}
.contacto__fuente svg, .contacto__viejo svg { flex: none; margin-top: 2px; }
.contacto__fuente a { color: var(--green); font-weight: var(--fw-x); }

/* ---------------- Chips de compra (§5.5 / §1.3) ---------------- */
.chips { margin-top: var(--sp-4); padding: 16px; border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--sh-sm); }
.chips__titulo { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
/* El título ES el botón que pliega el panel. Plegado ocupa una línea y deja las
   opciones arriba del pliegue, que es a lo que se entra a esta pantalla. */
.chips__toggle {
  width: 100%; display: flex; align-items: center; gap: 8px;
  font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); text-align: left;
}
.chips__toggle svg { flex: none; color: var(--green-dk); }
.chips__chevron { margin-left: auto; display: grid; place-items: center; color: var(--muted); }
/* Apunta hacia abajo cuando está abierta y hacia la derecha cuando está plegada:
   el ícono `chevron` del set mira a la derecha. */
.chips__toggle[aria-expanded="true"] .chips__chevron { transform: rotate(90deg); }
.chips__chevron { transition: transform var(--dur-fast) var(--ease-out); }
.chips.is-plegada .chips__cuerpo { display: none; }
.chips__hint { margin-top: 6px; font-size: var(--fs-12); color: var(--muted); line-height: 1.35; }
/* Sub-grupo plegable (Tiendas): son 22 y abiertas sepultan el resto del panel. */
.chips__sub { width: 100%; display: flex; align-items: center; gap: 8px; text-align: left; }
.chips__sub .chips__label { margin-bottom: 0; }
.chips__cuenta { margin-left: auto; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--green-dk); }
.chips__sub .chips__chevron { margin-left: 0; }
.chips__sub[aria-expanded="true"] .chips__chevron { transform: rotate(90deg); }
[data-plegado] .chips__fila--tiendas { display: none; }
/* Con 22 tiendas la lista se hace alta: se acota y se scrollea adentro, para que
   el botón de buscar no quede a media pantalla de distancia.
   El MARCO no es adorno: sin él la última fila queda cortada al medio y se lee
   como algo roto en vez de como una lista que sigue. Encerrada en una caja, el
   corte se entiende. */
/* Fila de tienda ("Tiendas que venden esto"). Renglón y no tarjeta: son una
   lista para recorrer con el pulgar, y seis tarjetas con sombra convierten una
   lista en seis decisiones. Mismo criterio que `ListaCard`. */
.tienda {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 12px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line);
}
.tienda:active { transform: scale(.99); }
.tienda__ic { flex: none; display: grid; place-items: center; color: var(--green-dk); }
.tienda__body { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.tienda__name { font-size: var(--fs-14); font-weight: var(--fw-black); color: var(--ink); }
.tienda__meta {
  font-size: var(--fs-12); color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.tienda__tag {
  font-size: 10px; font-weight: var(--fw-bold); text-transform: uppercase;
  letter-spacing: .04em; color: var(--muted);
  border: 1px solid var(--line); border-radius: var(--r-pill); padding: 1px 6px;
}
.tienda__go { margin-left: auto; flex: none; color: var(--muted); }

.chips__fila--tiendas {
  max-height: 164px; overflow-y: auto;
  padding: 10px; border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--cream);
  -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
}
.chips__grupo { margin-top: 12px; }
.chips__label { display: block; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); margin-bottom: 6px; }
/* Se envuelven: con cinco opciones en 375px, forzarlas en una fila las corta. */
.chips__fila { display: flex; flex-wrap: wrap; gap: 7px; }
.chips__monto { width: 100%; }

/* ---------------- Campo contextual (§5.11/A3) ---------------- */
/* Deliberadamente NO parece un chat: sin burbujas, sin avatar, sin historial.
   Es un campo de formulario con una respuesta debajo. */
.ctx__label { display: block; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.ctx__ayuda { margin-top: 2px; font-size: var(--fs-13); color: var(--muted); line-height: 1.4; }
.ctx__fila { display: flex; gap: var(--sp-2); align-items: flex-end; }
/* El `display: flex` de arriba gana contra el `display: none` del atributo
   `hidden` —CSS de autor le gana al de user-agent—, mismo problema que ya se
   arregló para `.p7-row__badge`/`.doc-elegido`. Sin esto, un `.ctx__fila
   hidden` (ej. el campo de "Cambiar número" en pagos, PagoCard) se ve igual. */
.ctx__fila[hidden] { display: none; }
.ctx__input { flex: 1; min-width: 0; resize: none; line-height: 1.4; }
/* El botón no se encoge y queda cuadrado: es un ícono, no una etiqueta. */
.ctx__enviar { flex: none; width: 48px; min-height: 48px; padding: 0; }
.ctx__respuesta {
  margin-top: 10px; padding: 12px 14px; border-radius: var(--r-md, 14px);
  font-size: var(--fs-14); line-height: 1.45; background: var(--cream); color: var(--ink);
  /* El backend manda encabezado + líneas separados por "\n" (respuestaBreve);
     sin esto el navegador los junta en un solo párrafo aunque el texto ya
     venga con los saltos y los guiones puestos. */
  white-space: pre-line;
}
.ctx__respuesta--pensando { color: var(--muted); font-style: italic; }
.ctx__respuesta--error { background: #F7E4DE; color: #8A3B22; }
/* El caso "esto va por otro lado": se distingue de una respuesta de verdad. */
.ctx__respuesta--chip { background: #F6E2BD; color: #7A5210; }
/* `a{color:inherit;text-decoration:none}` (base.css) deja cualquier link
   idéntico al texto de al lado — acá SÍ tiene que notarse que es tocable,
   es la única vez que este bloque enlaza afuera de la app. */
.ctx__respuesta a { color: var(--green); text-decoration: underline; font-weight: var(--fw-x); }

/* ---------------- Conexiones (§5.6) ---------------- */
.conex { background: var(--surface); border-radius: var(--r-lg); padding: 18px; box-shadow: var(--sh-sm); }
.conex__head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.conex__ic {
  flex: none; width: 34px; height: 34px; border-radius: var(--r-pill);
  display: grid; place-items: center; background: var(--green-soft, #e3efe9); color: var(--green);
}
.conex__titulo { flex: 1; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.conex__texto { margin-top: 12px; font-size: var(--fs-14); color: var(--ink); line-height: 1.45; }
/* "Ve" y "No ve" con el mismo peso visual: decir qué NO ve es la mitad del
   valor de esta pantalla, no una nota al pie. */
.conex__ve, .conex__nove {
  display: flex; align-items: flex-start; gap: 8px; margin-top: 12px;
  font-size: var(--fs-13); color: var(--muted); line-height: 1.45;
}
.conex__ve svg, .conex__nove svg { flex: none; margin-top: 3px; }
.conex__ve svg { color: var(--green); }
.conex__nove svg { color: var(--coral); }
.conex__ve strong, .conex__nove strong { color: var(--ink); }
/* La dirección se DICTA por teléfono: grande, monoespaciada y con espacio para
   que no se lean mal los caracteres parecidos. */
.conex__dir { margin-top: 14px; padding: 14px; border-radius: var(--r-md, 14px); background: var(--cream); }
.conex__dir-label { display: block; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }
.conex__dir-valor {
  display: block; margin-top: 6px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: var(--fs-15); font-weight: var(--fw-bold); color: var(--ink);
  letter-spacing: .02em; word-break: break-all;
}
.conex--oferta { border: 1.5px dashed rgba(37,51,49,.18); box-shadow: none; }

/* Cambiar la dirección: panel que se abre bajo los botones. No es un diálogo del
   navegador — el aviso de que la vieja deja de funcionar tiene que poder leerse
   con calma, y un `prompt()` lo mete todo en un párrafo del sistema. */
.dir-cambio { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.dir-cambio__nota {
  display: flex; align-items: flex-start; gap: 8px; margin-top: 10px;
  font-size: var(--fs-13); line-height: 1.45; color: #8A3B22;
}
.dir-cambio__nota svg { flex: none; margin-top: 3px; color: var(--alerta); }
.dir-cambio__acciones { display: flex; gap: 8px; margin-top: 12px; }
.dir-cambio__acciones .btn { flex: 1; }

/* El link ICS de Outlook: mismo patrón de panel-que-se-abre que .dir-cambio,
   con los pasos numerados porque la persona los sigue en otra pestaña (Outlook)
   e vuelve acá — tienen que poder releerse de un vistazo, no como un párrafo. */
.conex-ics { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.conex-ics__pasos {
  margin: 0; padding-left: 22px; font-size: var(--fs-13); color: var(--ink);
  line-height: 1.55;
}
.conex-ics__pasos li + li { margin-top: 8px; }
.conex-ics__pasos strong { color: var(--ink); }

/* ---- Conexiones (rediseño desplegable) ----
   La nota verde de "solo lectura", la tarjeta de activas (filas que se abren) y
   las tarjetas punteadas de "podés agregar". El detalle de adentro (`.conex__ve`
   /`__nove`/`__dir`, `.dir-cambio`, `.conex-ics`) se reusa tal cual. */
.conx-nota {
  display: flex; align-items: flex-start; gap: 10px;
  margin: 4px 0 2px; padding: 14px 16px;
  background: var(--green-soft); border-radius: var(--r-md);
  font-size: var(--fs-14); color: var(--ink-2); line-height: 1.45;
}
.conx-nota svg { flex: none; margin-top: 1px; color: var(--green); }
.conx-nota strong { color: var(--ink); font-weight: var(--fw-x); }

/* Tarjeta de conexiones activas: filas divididas, cada una desplegable. */
.conx-list {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sh-sm);
}
.conx-item + .conx-item { border-top: 1px solid var(--line); }
.conx-item__head {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 14px 16px; background: none; border: 0; text-align: left; cursor: pointer;
}
.conx-item__head:active { background: var(--surface-2); }
.conx-item__ic {
  flex: none; display: grid; place-items: center; width: 42px; height: 42px;
  border-radius: var(--r-pill); background: var(--green-soft); color: var(--green-dk);
}
.conx-item__main { flex: 1; min-width: 0; }
.conx-item__name {
  display: flex; align-items: center; gap: 8px;
  font-size: var(--fs-16); font-weight: var(--fw-x); letter-spacing: -.01em; color: var(--ink);
}
.conx-item__dot { flex: none; width: 8px; height: 8px; border-radius: var(--r-pill); background: var(--green-med); }
.conx-item__sub { display: block; margin-top: 2px; font-size: var(--fs-13); color: var(--muted); }
.conx-item__chev { flex: none; color: var(--ink-3); transform: rotate(90deg); transition: transform var(--dur-base) var(--ease-out); }
.conx-item__head[aria-expanded="true"] .conx-item__chev { transform: rotate(-90deg); }
.conx-item__body { padding: 0 16px 16px; }

/* Tarjetas punteadas de "podés agregar": el "+" abre la oferta. */
.conx-adds { display: flex; flex-direction: column; gap: 12px; }
.conx-add { border: 1.5px dashed rgba(37,51,49,.22); border-radius: var(--r-lg); overflow: hidden; }
.conx-add__head {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 13px 14px 13px 16px; background: none; border: 0; text-align: left; cursor: pointer;
}
.conx-add__ic {
  flex: none; display: grid; place-items: center; width: 42px; height: 42px;
  border-radius: var(--r-pill); background: var(--surface-sunk); color: var(--muted);
}
.conx-add__main { flex: 1; min-width: 0; }
.conx-add__name { font-size: var(--fs-16); font-weight: var(--fw-x); letter-spacing: -.01em; color: var(--ink); }
.conx-add__sub { display: block; margin-top: 2px; font-size: var(--fs-13); color: var(--muted); line-height: 1.35; }
.conx-add__plus {
  flex: none; display: grid; place-items: center; width: 40px; height: 40px;
  border-radius: var(--r-pill); background: var(--green-dk); color: #fff;
  transition: transform var(--dur-base) var(--ease-out);
}
.conx-add__head[aria-expanded="true"] .conx-add__plus { transform: rotate(45deg); }
.conx-add__body { padding: 0 16px 16px; }

/* Pie con candado: qué pasa al desconectar. */
.conx-pie {
  display: flex; align-items: flex-start; gap: 8px;
  margin: 18px 4px calc(var(--safe-b) + var(--sp-4));
  font-size: var(--fs-12-5); color: var(--muted); line-height: 1.45;
}
.conx-pie svg { flex: none; margin-top: 1px; color: var(--ink-3); }

/* ---------------- Tu día / Morning briefing (§5.14) ---------------- */

/* La tira de entrada al briefing, en la pantalla de la ruta. Va CLARA (rediseño
   ago 2026): una tarjeta blanca con su ícono y su chevron, del mismo material
   que las de la ruta. El emoji del sol la distingue de un pendiente. */
.dia-tira {
  display: flex; align-items: center; gap: 12px; margin: 0;
  padding: 14px 16px; border-radius: var(--r-lg); text-decoration: none;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line);
  box-shadow: var(--sh-sm);
  transition: transform var(--dur-fast) var(--ease-press), box-shadow var(--dur-base) var(--ease-out);
}
.dia-tira:hover { box-shadow: var(--sh-md); }
.dia-tira:active { transform: scale(.985); }
.dia-tira__emoji { flex: none; font-size: 22px; line-height: 1; }
.dia-tira__cuerpo { flex: 1; min-width: 0; }
.dia-tira__titulo { display: block; font-size: var(--fs-15); font-weight: var(--fw-black); color: var(--ink); }
.dia-tira__sub {
  display: block; margin-top: 2px; font-size: var(--fs-12); line-height: 1.35;
  color: var(--muted);
}
.dia-tira__chev { flex: none; color: var(--ink-3); }

/* Encabezado de cada bloque del briefing: emoji, título y un dato al costado.
   El emoji viene del pedido y se queda: es lo que hace que los seis bloques se
   distingan de un vistazo sin leer los títulos. */
.brief-head { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.brief-head__emoji { flex: none; font-size: 17px; line-height: 1; }
.brief-head__titulo {
  flex: 1; margin: 0; font-size: var(--fs-13); font-weight: var(--fw-black);
  letter-spacing: .04em; text-transform: uppercase; color: var(--muted);
}
.brief-head__extra { font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }
.brief-head__num {
  min-width: 22px; padding: 2px 7px; border-radius: var(--r-pill); text-align: center;
  font-size: var(--fs-12); font-weight: var(--fw-black);
  background: var(--cream); color: var(--ink);
}

.brief-bloque { margin-top: 22px; }
.brief-bloque--pie { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.brief-vacio { font-size: var(--fs-14); color: var(--muted); line-height: 1.45; }

/* 1. El día en una línea. Es lo único que muchos van a leer, así que ocupa el
      tamaño de un título y no el de un subtítulo. */
.brief-foco {
  padding: 18px; border-radius: var(--r-lg);
  background: var(--surface); box-shadow: var(--sh-sm);
}
.brief-foco__kicker {
  margin: 0; font-size: var(--fs-12); font-weight: var(--fw-black);
  letter-spacing: .04em; text-transform: uppercase; color: var(--green);
}
.brief-foco__texto {
  margin: 8px 0 0; font-size: var(--fs-18); font-weight: var(--fw-x);
  line-height: 1.35; color: var(--ink);
}
.brief-foco__texto strong { font-weight: var(--fw-black); }

/* 2. La próxima reunión. */
.brief-prox {
  margin-top: 22px; padding: 18px; border-radius: var(--r-lg);
  background: var(--surface); box-shadow: var(--sh-sm);
}
/* Ya empezó: el borde coral es la señal de "estás llegando tarde", que es el
   único momento en que esta tarjeta es urgente. */
.brief-prox--ahora { border-left: 4px solid var(--coral); }
.brief-prox__falta { font-size: var(--fs-12); font-weight: var(--fw-black); color: var(--green); }
.brief-prox__hora {
  margin: 0; font-size: 30px; font-weight: var(--fw-black); line-height: 1;
  color: var(--green); font-variant-numeric: tabular-nums;
}
.brief-prox__titulo { margin: 6px 0 0; font-size: var(--fs-16); font-weight: var(--fw-x); color: var(--ink); }
.brief-prox__lugar {
  display: flex; align-items: center; gap: 6px; margin: 8px 0 0;
  font-size: var(--fs-13); color: var(--muted);
}
.brief-prox__chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.brief-prox__chips:empty { display: none; }
.brief-prox .btn { margin-top: 14px; }

/* 3. Requieren tu respuesta hoy. Lista numerada: el número es la promesa de que
      son pocas y se pueden agotar. */
.brief-resp-list { display: flex; flex-direction: column; gap: 10px; }
.brief-resp {
  display: flex; align-items: flex-start; gap: 12px; padding: 14px;
  border-radius: var(--r-md); background: var(--surface); box-shadow: var(--sh-sm);
  text-decoration: none; color: inherit;
}
.brief-resp--link { transition: transform var(--dur-fast) var(--ease-press); }
.brief-resp--link:active { transform: scale(.99); }
.brief-resp__n {
  flex: none; width: 24px; height: 24px; border-radius: var(--r-pill);
  display: grid; place-items: center; font-size: var(--fs-12); font-weight: var(--fw-black);
  background: var(--coral); color: #fff;
}
.brief-resp__cuerpo { flex: 1; min-width: 0; }
.brief-resp__meta {
  display: flex; align-items: center; gap: 5px;
  font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted);
}
.brief-resp__meta svg { flex: none; }
.brief-resp__meta > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brief-resp__asunto {
  display: block; margin-top: 3px; font-size: var(--fs-15); font-weight: var(--fw-x);
  color: var(--ink); line-height: 1.3;
}
.brief-resp__accion { display: block; margin-top: 5px; font-size: var(--fs-13); color: var(--ink-2); line-height: 1.4; }
.brief-resp__chev { flex: none; color: var(--ink-3); align-self: center; }

/* 4. La agenda: la hora a la izquierda, en columna fija, para que se lea el día
      bajando por los números sin tener que leer los títulos. */
.brief-ev-list { display: flex; flex-direction: column; gap: 10px; }
.brief-ev {
  display: flex; gap: 14px; padding: 14px;
  border-radius: var(--r-md); background: var(--surface); box-shadow: var(--sh-sm);
}
.brief-ev--choque { border-left: 4px solid var(--coral); }
.brief-ev__hora { flex: none; width: 52px; }
.brief-ev__desde {
  display: block; font-size: var(--fs-15); font-weight: var(--fw-black);
  color: var(--ink); font-variant-numeric: tabular-nums;
}
.brief-ev__hasta { display: block; font-size: var(--fs-12); color: var(--ink-3); font-variant-numeric: tabular-nums; }
/* "Todo el día" no es una hora: entra en dos renglones chicos en vez de partirse
   con el cuerpo de un número grande. */
.brief-ev--dia .brief-ev__desde {
  font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); line-height: 1.25;
}
.brief-ev__cuerpo { flex: 1; min-width: 0; }
.brief-ev__titulo { margin: 0; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); line-height: 1.3; }
.brief-ev__lugar { margin: 4px 0 0; font-size: var(--fs-13); color: var(--muted); }
.brief-ev__chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.brief-ev__link {
  display: inline-flex; align-items: center; gap: 5px; margin-top: 10px;
  font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--green); text-decoration: none;
}

/* El caso sin calendario: NO se dibuja un vacío, porque un vacío se lee como
   "no tenés nada" y lo que pasa es que Nidu no sabe. */
.brief-sincal {
  padding: 16px; border-radius: var(--r-md);
  border: 1.5px dashed rgba(37, 51, 49, .18); background: var(--surface-2);
}
.brief-sincal__texto { margin: 0 0 12px; font-size: var(--fs-14); color: var(--ink); line-height: 1.45; }
.brief-sincal__nota { margin: 0; font-size: var(--fs-13); color: var(--muted); line-height: 1.45; }

/* 5. Alertas. */
.brief-alerta-list { display: flex; flex-direction: column; gap: 8px; }
.brief-alerta {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px;
  border-radius: var(--r-md); text-decoration: none; color: inherit;
  font-size: var(--fs-14); line-height: 1.45;
}
.brief-alerta__ic { flex: none; margin-top: 1px; }
.brief-alerta__texto { flex: 1; min-width: 0; }
.brief-alerta__texto strong { font-weight: var(--fw-black); }
.brief-alerta__chev { flex: none; align-self: center; opacity: .6; }
.brief-alerta--alerta { background: var(--alerta-bg); color: #8A3B22; }
.brief-alerta--alerta .brief-alerta__ic { color: var(--alerta); }
.brief-alerta--info { background: var(--info-bg); color: var(--ink); }
.brief-alerta--info .brief-alerta__ic { color: var(--info); }
.brief-alerta--link { transition: transform var(--dur-fast) var(--ease-press); }
.brief-alerta--link:active { transform: scale(.99); }

/* 6. La sugerencia: la tachadura fácil. Verde suave, no coral: es una
      oportunidad, no un problema. */
.brief-sug {
  margin-top: 22px; padding: 18px; border-radius: var(--r-lg);
  background: var(--green-soft); box-shadow: var(--sh-sm);
}
.brief-sug .brief-head__titulo { color: var(--green-dk); }
.brief-sug__texto { margin: 0; font-size: var(--fs-15); color: var(--ink); line-height: 1.45; }
.brief-sug__texto strong { font-weight: var(--fw-black); }
.brief-sug .btn { margin-top: 14px; }

/* El pie: con qué se armó. Compacto y sin sombra — es el respaldo de todo lo de
   arriba, no una tarjeta más que compita por la atención. */
.brief-canal-list { display: flex; flex-direction: column; gap: 14px; }
.brief-canal { display: flex; align-items: flex-start; gap: 10px; }
.brief-canal__ic { flex: none; margin-top: 2px; color: var(--muted); }
.brief-canal__cuerpo { flex: 1; min-width: 0; }
.brief-canal__nombre {
  display: flex; align-items: center; gap: 8px; margin: 0;
  font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink);
}
.brief-canal__detalle { margin: 4px 0 0; font-size: var(--fs-13); color: var(--muted); line-height: 1.45; }
.brief-canal__link {
  display: inline-flex; align-items: center; gap: 4px; margin-top: 6px;
  font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--green); text-decoration: none;
}

/* ---------------- Ruta real (la que armó Nidu) ---------------- */
.ruta-prog { margin: 4px 0 18px; }
.ruta-prog__row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 7px; }
.ruta-prog__label { font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--muted); }
.ruta-prog__pct { font-size: var(--fs-14); font-weight: var(--fw-black); color: var(--green); }
.ruta-prog__bar { height: 8px; border-radius: var(--r-pill); background: rgba(37,51,49,.1); overflow: hidden; }
.ruta-prog__fill {
  display: block; height: 100%; width: var(--pct, 0%); border-radius: var(--r-pill);
  background: var(--green); transition: width var(--dur-base) var(--ease-spring);
}
/* El punto de ahora: la ruta es "una a la vez" y la pantalla tiene que decir
   cuál es esa una. */
.ruta-ahora { margin-bottom: 6px; }
.ruta-ahora__kicker {
  display: flex; align-items: center; gap: 6px; margin-bottom: 8px;
  font-size: var(--fs-12); font-weight: var(--fw-black); letter-spacing: .06em;
  text-transform: uppercase; color: var(--green);
}
/* Lo ya resuelto se ve, pero apagado: está para dar sensación de avance, no
   para competir con lo que falta. */
.ruta-hechos { opacity: .55; }

/* ---------------- Borrador (mensaje listo para enviar) ---------------- */
.borrador { background: var(--surface); border-radius: var(--r-lg); padding: 18px; box-shadow: var(--sh-sm); }
.borrador__para { display: flex; align-items: center; gap: 10px; }
.borrador__ic {
  flex: none; width: 34px; height: 34px; border-radius: var(--r-pill);
  display: grid; place-items: center; background: var(--green-soft, #e3efe9); color: var(--green);
}
.borrador__label { display: block; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }
.borrador__dest { display: block; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); word-break: break-all; }
.borrador__asunto { margin-top: 12px; font-size: var(--fs-14); color: var(--ink); }
/* El cuerpo respeta los saltos de línea del borrador: un mensaje con saludo y
   despedida en un solo párrafo se lee como otro mensaje. */
.borrador__cuerpo {
  margin-top: 12px; padding: 14px; border-radius: var(--r-md, 14px);
  background: var(--cream); color: var(--ink); font-size: var(--fs-15); line-height: 1.5;
  white-space: pre-line;
}

/* =====================================================================
   TRÁMITES — ficha de la lista y envoltorio del mapa
   Valores del prototipo (bloque TRÁMITES de su components.css).
   ===================================================================== */
.ficha {
  display: block; width: 100%; text-align: left;
  padding: 18px; margin-bottom: 12px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  color: inherit; transform-style: preserve-3d;
  animation: cardIn var(--dur-base) var(--ease-out) both;
  transition: box-shadow var(--dur-fast) var(--ease-out);
}
.ficha:hover { box-shadow: var(--sh-md); }
.ficha:active { transform: scale(.985); }
.ficha__row { display: flex; align-items: center; gap: 12px; }
.ficha__ic {
  flex: none; width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center;
  background: var(--cat-tramite-tint); color: var(--cat-tramite-ink);
}
.ficha__body { flex: 1; min-width: 0; }
.ficha__title { display: block; font-size: 16.5px; font-weight: var(--fw-black); color: var(--ink); }
.ficha__sub { display: block; margin-top: 2px; font-size: 12.5px; font-weight: var(--fw-bold); color: var(--muted); }
.ficha__chev { flex: none; color: var(--muted); }
/* La barra sale de los pasos del pendiente vinculado; si no hay, no se dibuja. */
.ficha__track {
  display: block; height: 7px; margin-top: 14px;
  background: var(--track); border-radius: var(--r-pill); overflow: hidden;
}
.ficha__fill {
  display: block; height: 100%; width: var(--pct, 0%);
  background: var(--grad); border-radius: var(--r-pill);
  transition: width var(--dur-slow) var(--ease-spring);
}
.ficha__progress { display: block; margin-top: 7px; font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--green); }

/* Mapa con su leyenda debajo, en una sola pieza. */
.mapwrap {
  border-radius: var(--r-lg); overflow: hidden;
  border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: fadeIn var(--dur-base) var(--ease-out) both;
}
.mapwrap .map-holder { border-radius: 0; border: none; box-shadow: none; }
.maplegend {
  display: flex; gap: 16px; padding: 12px 14px;
  background: var(--surface);
  font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--ink);
}
.maplegend span { display: flex; align-items: center; gap: 6px; }
.maplegend i { display: block; width: 10px; height: 10px; border-radius: 50%; }

/* =====================================================================
   AGENDA — línea de tiempo
   ===================================================================== */
.agenda-day { margin-bottom: 20px; }
.agenda-day__label { margin: 0 2px 10px; font-size: var(--fs-13); font-weight: var(--fw-black); color: var(--green-dk); }
.agenda-row { display: flex; gap: 14px; align-items: stretch; margin-bottom: 2px; }
/* 68px y no los 52px del prototipo: ahí la columna es siempre una hora ("19:00")
   porque su semilla se la pone a todo. Acá casi siempre es una fecha corta
   ("Mar, 28 jul."), que a 52px se parte en dos renglones. */
.agenda-time {
  flex: none; width: 68px; padding-top: 15px; text-align: right;
  font-size: 12.5px; font-weight: var(--fw-x); color: var(--muted);
  line-height: 1.3;
}
.agenda-line { flex: none; position: relative; width: 2px; background: var(--line); }
/* El punto toma el acento de la categoría y el halo el color del fondo, así
   parece perforar la línea en vez de apoyarse encima. */
.agenda-dot {
  position: absolute; top: 16px; left: -4px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--acento-cat, var(--green));
  box-shadow: 0 0 0 3px var(--cream);
}
.agenda-card {
  flex: 1; min-width: 0; display: block;
  padding: 13px 14px; margin-bottom: 8px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  color: inherit;
  animation: cardIn var(--dur-base) var(--ease-out) both;
  transition: box-shadow var(--dur-fast) var(--ease-out);
}
.agenda-card:hover { box-shadow: var(--sh-md); }
.agenda-card__title { display: block; font-size: 14.5px; font-weight: var(--fw-x); color: var(--ink); }
.agenda-card__meta { display: block; margin-top: 2px; font-size: 12.5px; font-weight: var(--fw-bold); color: var(--muted); }

/* =====================================================================
   HISTORIAL
   ===================================================================== */
/* La tarjeta con degradado: en el prototipo muestra una racha inventada; acá,
   el total resuelto, que es lo único que la app sabe de verdad. */
.streak {
  display: flex; align-items: center; gap: 16px;
  padding: 18px 20px; margin-bottom: 18px; border-radius: var(--r-lg);
  background: var(--grad); color: #fff; box-shadow: var(--sh-md);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.streak__ic {
  flex: none; width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(255,255,255,.16);
}
.streak__n { font-size: 22px; font-weight: var(--fw-black); line-height: 1; }
.streak__sub { margin-top: 3px; font-size: var(--fs-13); font-weight: var(--fw-bold); color: rgba(255,255,255,.85); }

.hist {
  display: flex; align-items: center; gap: 13px;
  padding: 13px 14px; margin-bottom: 8px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.hist__hit { display: flex; align-items: center; gap: 13px; flex: 1 1 auto; min-width: 0; color: inherit; }
.hist__ic {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--tint-cat, var(--green-soft)); color: var(--acento-cat, var(--green-dk));
}
.hist__body { flex: 1; min-width: 0; }
.hist__title {
  display: block; font-size: 14.5px; font-weight: var(--fw-x); color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hist__cat { display: block; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }
.hist__when { flex: none; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }

/* D4 — fila de "Mis documentos". Mismo esqueleto que .hist (icono + título +
   subtítulo + dato a la derecha), con lugar para el chip de estado y la fecha
   apiladas a la derecha en vez de un solo dato. */
.docbib { margin-bottom: 8px; }
.docbib__hit {
  display: flex; align-items: center; gap: 13px; padding: 13px 14px;
  border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--sh-sm); color: inherit;
}
.docbib__ic {
  flex: none; width: 34px; height: 34px; border-radius: 10px;
  display: grid; place-items: center; background: var(--surface-sunk); color: var(--muted);
}
.docbib__body { flex: 1; min-width: 0; }
.docbib__title {
  display: block; font-size: 14.5px; font-weight: var(--fw-x); color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.docbib__sub {
  display: block; font-size: var(--fs-12); font-weight: var(--fw-semi); color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.docbib__meta { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.docbib__fecha { font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }

/* =====================================================================
   SINCRONIZACIÓN
   ===================================================================== */
.sync-card {
  display: flex; align-items: center; gap: 14px;
  padding: 18px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.sync-card__ic {
  flex: none; width: 52px; height: 52px; border-radius: 15px;
  display: grid; place-items: center; background: var(--whats); color: #fff;
}
.sync-card__title { font-size: var(--fs-16); font-weight: var(--fw-black); color: var(--ink); }
.sync-card__sub { font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--muted); }
.sync-card__dot {
  flex: none; width: 12px; height: 12px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 0 4px var(--green-soft);
}
.sync-card__dot--pend { background: var(--coral); box-shadow: 0 0 0 4px var(--cat-compra-tint); }

.sync-item {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px; margin-bottom: 8px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.sync-item__ic {
  flex: none; width: 34px; height: 34px; border-radius: 10px;
  display: grid; place-items: center;
  background: var(--green-soft); color: var(--green-dk);
}
.sync-item__body { flex: 1; min-width: 0; }
.sync-item__title {
  display: block; font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sync-item__raw { display: block; font-size: var(--fs-12); font-weight: var(--fw-bold); color: var(--muted); }
.sync-item__when { flex: none; font-size: 11.5px; font-weight: var(--fw-bold); color: var(--muted); }

/* =====================================================================
   CREAR — grilla de categorías
   ===================================================================== */
/* Tres columnas de fichas. Antes eran seis píldoras grises iguales, y después
   —al toque, antes de deployar— seis pasteles distintos (uno por categoría):
   un color por opción no es la paleta de Nidu, son seis paletas ajenas
   pegadas encima. En reposo las seis quedan neutras e iguales; la que se
   elige se marca en VERDE NIDU, el mismo verde que "elegido/activo" en el
   resto de la app — no un color propio por categoría. */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.cat-chip {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 14px 8px; border-radius: var(--r-md);
  border: 1.5px solid var(--line); background: var(--surface);
  color: var(--ink-2);
  transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out),
    color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.cat-chip span { font-size: 12.5px; font-weight: var(--fw-x); color: var(--ink-2); }
.cat-chip:active { transform: scale(.95); }
.cat-chip[aria-pressed="true"] { border-color: var(--green); background: var(--green-soft); color: var(--green-dk); }
.cat-chip[aria-pressed="true"] span { color: var(--green-dk); }

/* ---- Seguimiento automático de ofertas (empleo) ----
   Vive DENTRO de la caja de "Recordármelo": es la misma pregunta —cuándo te
   vuelvo a hablar de esto— con otra respuesta. El interruptor reusa `.sw` de
   Perfil; acá solo va la fila que lo contiene. */
.seguimiento {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--line);
}
.seguimiento__txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.seguimiento__titulo { font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink); }
.seguimiento__sub { font-size: var(--fs-13); color: var(--ink-2); }

/* =====================================================================
   RESOLVER — tarjetas de los verticales que no son "comparar opciones"

   Compra usa `.prod` en grilla de dos columnas porque son opciones que se miran
   de a pares. Evento, pago y trámite son UNA cosa sola: van a ancho completo,
   apiladas, con la acción abajo de todo. Comparten la caja (fondo, borde,
   sombra, entrada) y se diferencian por el tinte del icono, igual que las
   categorías en la Ruta.
   ===================================================================== */
/* Notas al pie con un icono adelante. El reset pone `svg { display:block }`, así
   que sin esto el icono se lleva un renglón entero para él solo y la aclaración
   arranca en la línea de abajo, desalineada. */
.nota-inline svg { display: inline-block; vertical-align: -2px; margin-right: 4px; }

/* El pie: las dos salidas de la pantalla, apiladas. Recordar arriba y cerrar
   abajo — el cierre es la acción definitiva y va donde cae el pulgar. */
.res-acts { display: flex; flex-direction: column; gap: var(--sp-2); }
/* Sin esto, `.res-acts__row` (los dos `.btn--block` de "Recordármelo"/"Marcar
   resuelto") caía al `display:block` de un `<div>` sin estilo, apilados con
   CERO separación — se veían pegados/superpuestos (reporte de campo, 6/8). La
   regla de `.res-hero__foot .res-acts__row` de más abajo solo cubría el campo
   verde del intro; esta es la base para todo el resto de las pantallas. */
.res-acts__row { display: flex; flex-direction: column; gap: var(--sp-2); }
/* "Recordármelo"/"Marcar resuelto" van al PIE de la pantalla, no pegados al
   contenido — con un pendiente sin ficha (bloqueBuscar) o con poco contenido,
   quedaba un hueco enorme entre los botones y el borde inferior (reporte de
   campo, 4/8). `.res-normal` pasa a ocupar todo el alto visible bajo el
   topbar (56px medidos + el padding de `#app`, con `--safe-b` para que se
   adapte al home indicator del dispositivo real) y `.res-acts`, al ser el
   último hijo, se empuja al fondo con `margin-top: auto`. Con contenido que
   ya llena la pantalla no cambia nada — el `min-height` nunca fuerza scroll
   de más, solo evita el hueco cuando sobra alto. */
.res-normal {
  display: flex; flex-direction: column;
  min-height: calc(100dvh - 68px - var(--sp-4) - var(--safe-b) - var(--sp-6));
}
.res-normal > .res-acts { margin-top: auto; padding-top: var(--sp-6); }
/* "Eliminar pendiente": solo el ícono, chico y centrado — el tacho ya dice
   de qué acción se trata, sin competir por atención con "Recordármelo"/
   "Marcar resuelto". `.res-acts` estira a sus hijos (`flex-direction:
   column`, sin `align-items` propio); `align-self: center` evita que este
   botón de 48px se estire al ancho completo como los de arriba. El color de
   alerta (ámbar/coral) es lo único que lo diferencia de un ghost común. */
.btn-eliminar { align-self: center; color: var(--alerta); border-color: var(--alerta-borde); }
.btn-eliminar:active { background: var(--alerta-bg); }
/* Teléfono + "Crear el link". El botón NO se encoge: con `flex` por defecto se
   comprimía hasta partir "Crear el / link" en dos renglones en 375px. */
.compartir-row { display: flex; gap: var(--sp-2); align-items: stretch; }
.compartir-row .input { flex: 1; min-width: 0; }
.compartir-row .btn { flex: none; white-space: nowrap; }

.evento, .pago, .tramite {
  padding: 18px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.evento__row, .pago__row { display: flex; align-items: center; gap: 13px; }
.evento__ic, .pago__ic {
  flex: none; width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center;
}
.evento__ic { background: var(--cat-recordatorio-tint); color: var(--cat-recordatorio-ink); }
.pago__ic { background: var(--cat-vencimiento-tint); color: var(--cat-vencimiento-ink); }

/* Evento: la fecha es el dato, así que va en el tamaño del título. Arriba, en
   chico, lo que la persona quiere saber de un vistazo ("Mañana"). */
.evento__when { flex: 1; min-width: 0; }
.evento__rel { display: block; font-size: var(--fs-13); font-weight: var(--fw-black); color: var(--green); text-transform: uppercase; letter-spacing: .04em; }
.evento__rel.is-pasado { color: var(--alerta); }
.evento__full { display: block; margin-top: 2px; font-size: var(--fs-18); font-weight: var(--fw-x); color: var(--ink); line-height: 1.25; }
.evento__hora { display: flex; align-items: center; gap: 5px; margin-top: 4px; font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink-2); }
.evento__hora svg { flex: none; }
.evento__desc { margin-top: 14px; font-size: var(--fs-15); color: var(--ink-2); line-height: 1.5; white-space: pre-line; }
.evento__acts { margin-top: 16px; }
/* La ayuda de iPhone: la misma que la página /agendar, que es donde la gente se
   traba con el .ics. Chica y al pie, no compite con el botón. */
.evento__ayuda { margin-top: 10px; font-size: var(--fs-13); color: var(--muted); line-height: 1.45; }
/* El reset pone `svg { display:block }`, así que el icono de la ayuda hay que
   volver a meterlo en la línea o se lleva un renglón entero para él solo. */
.evento__ayuda svg { display: inline-block; vertical-align: -2px; margin-right: 3px; }

/* Pago: el monto es lo que se busca en la tarjeta, va en negrita grande. */
.pago__body { flex: 1; min-width: 0; }
.pago__emisor { display: block; font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--muted); }
.pago__monto { display: block; margin-top: 2px; font-size: var(--fs-24); font-weight: var(--fw-black); color: var(--green-dk); letter-spacing: -.02em; }
.pago__limite { display: flex; align-items: center; gap: 6px; margin-top: 12px; font-size: var(--fs-13); font-weight: var(--fw-x); color: var(--ink-2); }
.pago__limite.is-vencido { color: var(--alerta); }
.pago__limite svg { flex: none; }
.pago__hist { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.pago__hist-tit { font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.pago__hist-row { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--ink-2); }
.pago__hist-monto { flex: 1; color: var(--ink); }
.pago__acts { margin-top: 16px; }

/* Trámite: la ficha es texto, así que la jerarquía la dan los bloques y no el
   color. El primer paso va arriba y destacado porque es lo único accionable hoy. */
.tramite__org { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--cat-tramite-ink); text-transform: uppercase; letter-spacing: .05em; }
.tramite__primero { margin-top: 10px; padding: 13px 14px; border-radius: var(--r-md); background: var(--green-soft); color: var(--ink); font-size: var(--fs-15); line-height: 1.45; }
.tramite__primero strong { font-weight: var(--fw-black); color: var(--green-dk); }
.tramite__bloque { margin-top: 16px; }
.tramite__tit { display: flex; align-items: center; gap: 6px; font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.tramite__tit svg { flex: none; }
.tramite__lista, .tramite__pasos { margin: 8px 0 0; padding-left: 20px; font-size: var(--fs-15); color: var(--ink-2); line-height: 1.5; }
.tramite__lista { list-style: disc; }
.tramite__pasos { list-style: decimal; }
.tramite__lista li + li, .tramite__pasos li + li { margin-top: 6px; }
.tramite__costo { display: flex; align-items: center; gap: 6px; margin-top: 16px; font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink); }
.tramite__costo svg { flex: none; color: var(--muted); }
/* "También lo hacen los privados": la otra puerta del trámite. Se lee como el
   resto de los bloques —no es una promoción— y el precio va en negrita porque es
   el dato por el que alguien mira esto. */
.tramite__alt { margin-top: 8px; font-size: var(--fs-15); color: var(--ink-2); line-height: 1.5; }
.tramite__alt strong { font-weight: var(--fw-black); color: var(--ink); }
.tramite__fuente { display: inline-block; margin-top: 6px; font-size: var(--fs-13); color: var(--green-dk); text-decoration: underline; }
.tramite__acts { margin-top: 18px; }

/* ---- Empleo (ofertas de trabajo) ----
   Va en columna simple (`stack-3`), no en la grilla de dos columnas: un aviso
   de trabajo es texto, no una miniatura de producto.
   Tokens del rediseño (--line, --ink, --green-*): los viejos en español
   (--borde, --oscuro, --verde) ya no existen. */
.empleo {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: var(--sp-4); box-shadow: var(--sh-sm);
  display: flex; flex-direction: column; gap: 6px;
}
.empleo__cargo { font-size: var(--fs-16); font-weight: var(--fw-x); line-height: 1.25; color: var(--ink); }
.empleo__empresa { font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--green-dk); margin-top: 2px; }
.empleo__chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 4px; }
.empleo__meta { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: var(--fs-13); }
.empleo__meta svg { width: 13px; height: 13px; flex: none; }
/* El "por qué está primero": es lo que convierte una lista en recomendación. */
.empleo__motivo {
  display: flex; align-items: flex-start; gap: 6px; margin-top: 4px;
  background: var(--green-soft); color: var(--green-dk);
  border-radius: var(--r-md); padding: 8px 10px;
  font-size: var(--fs-13); line-height: 1.35;
}
.empleo__motivo svg { width: 13px; height: 13px; flex: none; margin-top: 2px; }
.empleo__avisos { list-style: none; display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.empleo__avisos li { display: flex; align-items: flex-start; gap: 6px; color: var(--alerta); font-size: var(--fs-12); line-height: 1.35; }
.empleo__avisos svg { width: 13px; height: 13px; flex: none; margin-top: 2px; }
/* Acciones de seguimiento: guardar · me postulé · descartar. */
.btn--sm { min-height: 40px; padding: 0 14px; font-size: var(--fs-13); }
.btn--sm svg { width: 18px; height: 18px; }
.empleo__acciones { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.empleo__acciones .btn { flex: 0 1 auto; }

/* ---- Correo de postulación preparado (dentro de la tarjeta de oferta) ----
   El cuerpo va COMPLETO y editable: la persona completa lo que quedó entre
   corchetes y lo copia. Nidu no lo envía (§7 / EMPLEO §11). */
.empleo__correo { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); }
.empleo__correo-asunto { font-size: var(--fs-14); color: var(--muted); margin-bottom: 8px; }
.empleo__correo-cuerpo { min-height: 180px; }

/* ---- Filtros con chips (pantalla de búsqueda de empleo) ----
   Tres chips en una pantalla en vez de tres turnos de chat (§1.3). */
.filtro__label { display: block; font-size: var(--fs-13); font-weight: var(--fw-x); color: var(--muted); margin-bottom: 8px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-sel {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 14px; border-radius: var(--r-pill);
  background: var(--surface); border: 1.5px solid var(--line);
  color: var(--ink); font-size: var(--fs-14); font-weight: var(--fw-bold);
  transition: background var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.chip-sel:hover { border-color: var(--green); }
.chip-sel:active { transform: scale(.96); }
.chip-sel.is-on { background: var(--green); border-color: var(--green); color: var(--ink-inv); }

/* ── Documento (contrato, póliza, carné, garantía) ─────────────────────────
   La jerarquía invierte a propósito lo que la gente espera: arriba y grande va
   QUÉ HACER Y HASTA CUÁNDO, y el vencimiento baja a la lista de datos. Poner el
   vencimiento arriba es el error que este vertical existe para arreglar — la
   fecha que importa es la de avisar, no la de vencer.

   El RITMO VERTICAL es generoso a propósito: esta tarjeta tiene más bloques que
   ninguna otra (acción, advertencia, cinco datos, penalidad, aviso, dos
   acciones, confianza y dudas). Con el espaciado del resto de la app se leía
   como un muro y había que buscar dónde terminaba cada cosa. */
.doc {
  padding: 22px 20px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  animation: cardIn var(--dur-base) var(--ease-out) both;
}
.doc__head { display: flex; align-items: flex-start; gap: 14px; }
.doc__ic {
  flex: none; width: 46px; height: 46px; border-radius: 13px;
  display: grid; place-items: center;
  background: var(--cat-tramite-tint); color: var(--cat-tramite-ink);
}
.doc__body { flex: 1; min-width: 0; }
/* La acción es el título de la tarjeta: es lo que la persona vino a saber. */
.doc__accion { display: block; font-size: var(--fs-20); font-weight: var(--fw-black); color: var(--ink); line-height: 1.25; letter-spacing: -.01em; }
.doc__cuando { display: block; margin-top: 6px; font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--green-dk); line-height: 1.4; }
.doc__cuando.is-tarde { color: var(--alerta); }
.doc__cuenta { margin-top: 14px; }

/* D3 — Versiones anteriores: historial colapsable, no contenido de primer plano.
   Un <details> nativo, mismos tokens que el resto de la ficha. */
.doc__versiones { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.doc__versiones > summary {
  display: flex; align-items: center; gap: 8px; cursor: pointer; list-style: none;
  font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--muted);
}
.doc__versiones > summary::-webkit-details-marker { display: none; }
.doc__versiones-lista { margin: 12px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.doc__versiones-lista li { display: flex; flex-direction: column; gap: 2px; }
.doc__versiones-fecha { font-size: var(--fs-13); font-weight: var(--fw-bold); }
.doc__versiones-det { font-size: var(--fs-13); color: var(--muted); }

/* La advertencia de renovación automática: visible, pero no un cartel de error.
   Que se renueve solo es un HECHO del contrato, no una falla. */
.doc__alerta {
  display: flex; align-items: flex-start; gap: 9px;
  margin-top: 20px; padding: 14px 15px; border-radius: var(--r-md);
  background: var(--alerta-bg); color: var(--alerta);
  font-size: var(--fs-14); font-weight: var(--fw-bold); line-height: 1.45;
}
.doc__alerta svg { flex: none; margin-top: 1px; }

.doc__datos { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.doc__fila { display: flex; align-items: baseline; gap: 12px; margin-top: 14px; font-size: var(--fs-14); line-height: 1.45; }
.doc__fila:first-child { margin-top: 0; }
.doc__fila span { flex: none; color: var(--muted); font-weight: var(--fw-bold); }
/* `overflow-wrap: anywhere` porque el valor puede ser un correo entero
   (socgestionclientes@securitasuruguay.com): sin esto se salía de la tarjeta y
   quedaba cortado justo en la dirección a la que hay que escribir. */
.doc__fila strong {
  flex: 1; min-width: 0; text-align: right; color: var(--ink); font-weight: var(--fw-x);
  overflow-wrap: anywhere;
}
/* Un valor largo en dos columnas deja el label solo y el texto apretado contra
   el borde. A partir de cierto largo se apila: label arriba, valor abajo y a la
   izquierda, que es como se lee un dato de varias líneas. */
.doc__fila--largo { display: block; }
.doc__fila--largo strong { display: block; text-align: left; margin-top: 5px; }

.doc__penalidad { margin-top: 20px; font-size: var(--fs-13); color: var(--ink-2); line-height: 1.55; }
.doc__penalidad svg { display: inline-block; vertical-align: -2px; margin-right: 5px; color: var(--muted); }

/* Sin fondo ni píldora: con el mismo verde suave de los botones se leía como un
   tercer botón apilado, y esto NO es una acción — es la confirmación de que la
   fecha ya quedó cubierta. Lo que se toca y lo que se lee tienen que verse
   distinto. */
.doc__agendado {
  display: flex; align-items: center; gap: 8px;
  margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line);
  color: var(--green-dk);
  font-size: var(--fs-14); font-weight: var(--fw-bold); line-height: 1.45;
}
.doc__agendado svg { flex: none; }

/* Las dos acciones: separadas entre sí y del texto de arriba, porque son lo
   único que se toca en toda la tarjeta. */
.doc__acciones { margin-top: 16px; display: grid; gap: 10px; }
.doc__correo-nota { margin-top: 10px; font-size: var(--fs-12); color: var(--muted); line-height: 1.5; overflow-wrap: anywhere; }

/* El pie lleva la confianza SIEMPRE, incluso cuando es alta: una fecha sin
   decir de dónde salió se lee como un hecho, y esta salió de un modelo leyendo
   un PDF. La persona decide con un plazo legal en la mano. */
.doc__pie { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.doc__dudas { margin: 12px 0 0; padding-left: 20px; list-style: disc; font-size: var(--fs-13); color: var(--ink-2); line-height: 1.55; }
.doc__dudas li + li { margin-top: 8px; }
.doc__origen { margin-top: 14px; font-size: var(--fs-13); color: var(--muted); line-height: 1.45; }
.doc__origen svg { display: inline-block; vertical-align: -2px; margin-right: 4px; }

/* ── Subir un documento (#/documento) ──────────────────────────────────────
   La zona de archivo es un LABEL envolviendo un input oculto: así el toque
   funciona en todo el bloque y no hace falta JS para abrir el selector. */
.doc-drop {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 28px 20px; border-radius: var(--r-lg);
  border: 2px dashed var(--line); background: var(--surface-2);
  text-align: center; cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}
.doc-drop:hover, .doc-drop:focus-within { border-color: var(--green); background: var(--green-soft); }
.doc-drop__ic { color: var(--muted); }
.doc-drop__tit { font-size: var(--fs-16); font-weight: var(--fw-black); color: var(--ink); }
.doc-drop__sub { font-size: var(--fs-13); color: var(--muted); }

/* El archivo elegido, con su peso: es el dato con el que alguien se da cuenta
   de que agarró el adjunto equivocado antes de gastar una lectura. */
.doc-elegido {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px; border-radius: var(--r-md);
  background: var(--green-soft); color: var(--green-dk);
  font-size: var(--fs-14); font-weight: var(--fw-bold);
}
.doc-elegido.is-error { background: var(--alerta-bg); color: var(--alerta); }
/* `display:flex` le gana al atributo `hidden`, así que sin esto el bloque
   vacío se dibuja igual antes de elegir archivo. */
.doc-elegido[hidden] { display: none; }
.doc-elegido svg { flex: none; }
.doc-elegido__nombre { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-elegido__peso { flex: none; opacity: .75; }

/* UN archivo o varios (3/8, reporte de campo): siempre la misma lista, con
   miniatura por archivo. Antes era sin previews a propósito, pero "IMG_9202.
   jpg" no dice cuál página es cuál —la miniatura es la única forma de
   confirmar que se elige lo que corresponde antes de subir. Y un solo camino
   de render (nunca una fila "especial" para un solo archivo) es lo que
   arregla el bug de fondo: antes, con 1 archivo, no había botón para
   quitarlo. */
.doc-elegido-lista { display: flex; flex-direction: column; gap: 1px; margin-top: 8px; border-radius: var(--r-md); overflow: hidden; background: var(--line); }
.doc-elegido-fila {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px 8px 10px; background: var(--surface);
  font-size: var(--fs-13); color: var(--ink);
}
.doc-elegido-fila__thumb {
  flex: none; width: 36px; height: 36px; border-radius: 8px;
  object-fit: cover; background: var(--surface-sunk);
}
.doc-elegido-fila__ic {
  flex: none; width: 36px; height: 36px; border-radius: 8px;
  display: grid; place-items: center; background: var(--surface-sunk); color: var(--muted);
}
.doc-elegido-fila__nombre { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-elegido-fila__peso { flex: none; color: var(--muted); font-size: var(--fs-12); }
.doc-elegido-fila__quitar {
  flex: none; display: grid; place-items: center; width: 28px; height: 28px;
  border-radius: 50%; color: var(--muted); background: none;
}
.doc-elegido-fila__quitar:hover, .doc-elegido-fila__quitar:active { background: var(--surface-sunk); color: var(--alerta); }

/* D1 — picker de intención ("¿Qué necesitás hacer con este documento?").
   Lista de filas seleccionables, un solo radio activo. Mismo contenedor blanco
   con borde que usa `mapa-spec.md` para listas de opciones; el verde vive SOLO
   en el estado activo (paleta shippeada, no el lila del mockup). */
.doc-intencion {
  border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden;
  background: var(--surface); margin-top: 8px;
}
.doc-intencion__fila {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 12px 14px; border: none; border-bottom: 1px solid var(--divider, var(--line));
  background: none; text-align: left; cursor: pointer; font: inherit; color: var(--ink);
  transition: background var(--dur-fast) var(--ease-out);
}
.doc-intencion__fila:last-child { border-bottom: none; }
.doc-intencion__fila:hover { background: var(--surface-2); }
.doc-intencion__fila[aria-checked="true"] { background: var(--green-soft); }
.doc-intencion__ic {
  flex: none; display: grid; place-items: center; width: 32px; height: 32px;
  border-radius: var(--r-sm, 8px); background: var(--surface-sunk); color: var(--muted);
}
.doc-intencion__fila[aria-checked="true"] .doc-intencion__ic { background: var(--surface); color: var(--green); }
.doc-intencion__label { flex: 1; font-size: var(--fs-14-5); font-weight: var(--fw-semi); }
.doc-intencion__dot {
  position: relative; flex: none; width: 18px; height: 18px; border-radius: 50%;
  border: 1.5px solid var(--line);
}
.doc-intencion__fila[aria-checked="true"] .doc-intencion__dot { border-color: var(--green); }
.doc-intencion__fila[aria-checked="true"] .doc-intencion__dot::after {
  content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--green);
}

.doc-aviso {
  padding: 13px 14px; border-radius: var(--r-md);
  background: var(--surface-2); color: var(--ink-2);
  font-size: var(--fs-14); line-height: 1.45;
}
.doc-aviso.is-error { background: var(--alerta-bg); color: var(--alerta); }

/* La puerta desde "Nuevo pendiente". */
.doc-puerta {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
}
.doc-puerta__ic {
  flex: none; width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--cat-tramite-tint); color: var(--cat-tramite-ink);
}
.doc-puerta__body { flex: 1; min-width: 0; }
.doc-puerta__tit { display: block; font-size: var(--fs-15); font-weight: var(--fw-black); color: var(--ink); }
.doc-puerta__sub { display: block; margin-top: 2px; font-size: var(--fs-13); color: var(--muted); line-height: 1.35; }
.doc-puerta__end { flex: none; color: var(--muted); }

/* ---------------- Modo mostrador (§5.13.C) ----------------
   La vista para tener el teléfono en la mano, parado en la fila: qué llevar
   (para tildar), cuánto cuesta y dónde queda. Nada más.

   El resto de la pantalla se ESCONDE, no se achica: los pasos, los tips, los
   lugares y los tres botones de cierre compiten justo cuando hay que mirar una
   sola cosa. Todo va más grande porque se lee de un vistazo y muchas veces con
   una mano ocupada. */
.is-mostrador .res-normal { display: none; }
.mostrador { animation: cardIn var(--dur-base) var(--ease-out) both; }
.mostrador__head {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
}
.mostrador__titulo {
  font-size: var(--fs-20); font-weight: var(--fw-black); color: var(--ink); line-height: 1.25;
}
.mostrador__bloque { margin-top: var(--sp-6); }
.mostrador__label {
  font-size: var(--fs-12); font-weight: var(--fw-x); color: var(--muted);
  text-transform: uppercase; letter-spacing: .05em;
}
.mostrador__dato {
  margin-top: 4px; font-size: var(--fs-24); font-weight: var(--fw-black);
  color: var(--ink); line-height: 1.2;
}
.mostrador__sub { margin-top: 4px; font-size: var(--fs-16); color: var(--ink-2); line-height: 1.4; }
.mostrador__prog { margin-top: 2px; font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--green-dk); }
.mostrador__pie {
  margin-top: var(--sp-8); font-size: var(--fs-13); color: var(--muted); line-height: 1.45;
}
/* El renglón para tildar, en tamaño mostrador. */
.step--grande { padding: 16px; }
.step--grande .step__box { width: 34px; height: 34px; border-radius: 11px; }
.step--grande .step__text { font-size: var(--fs-18); line-height: 1.3; }

/* Vista previa del correo que se comparte (§5.13.E): Para/Asunto fijos y el
   cuerpo EDITABLE (textarea) — se redacta en primera persona y se valida
   antes de abrir el canal, nunca se manda algo que la persona no vio y pudo
   corregir. */
#correoCuerpo { max-height: 260px; }

/* Código de vinculación (§5.12/E). Grande, monoespaciado y con espacio entre
   letras: se lee en voz alta o se copia a mano en otro teléfono, así que la
   diferencia entre 0 y O y entre 1 y l tiene que ser obvia. */
.codigo-vinculacion {
  margin: var(--sp-3) 0;
  text-align: center;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 38px;
  font-weight: var(--fw-black);
  letter-spacing: .12em;
  color: var(--green-dk);
  font-variant-numeric: tabular-nums;
  /* Los seis dígitos se seleccionan de un toque largo, por si se copian. */
  user-select: all;
}

/* ============================================================
   Rediseño PWA (handoff, ago 2026) — pantalla RUTA
   Ruta numerada: UNA tarjeta abierta (la activa, "Te toca", con próximo paso y
   un solo botón lleno) y el resto —incluido lo resuelto, atenuado— en filas de
   dos líneas con chip de estado. Paleta verde/marfil de los tokens. Prefijo `.rt-`.
   ============================================================ */

/* ---- Encabezado: título + fecha (izq), anillo de progreso (der) ---- */
.rt-head { margin-bottom: var(--sp-3); }
.rt-head__row { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }
.rt-head__main { flex: 1 1 auto; min-width: 0; }
.rt-head__title { font-size: var(--fs-23); font-weight: var(--fw-x); line-height: 1.1; letter-spacing: -.02em; color: var(--ink); }
.rt-head__date { margin-top: 4px; font-size: var(--fs-13); font-weight: var(--fw-regular); color: var(--muted); }
.rt-head__prog { flex: none; }
.rt-prog { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 8px 12px 8px 14px; box-shadow: var(--sh-sm); }
.rt-prog__txt { display: flex; flex-direction: column; line-height: 1.1; text-align: right; }
.rt-prog__txt b { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.rt-prog__txt span { font-size: var(--fs-12); font-weight: var(--fw-semi); color: var(--muted); }
.rt-prog__ring { position: relative; width: 40px; height: 40px; flex: none; }
.rt-prog__track { stroke: var(--surface-sunk); }
.rt-prog__arc { stroke: var(--green); transition: stroke-dashoffset var(--dur-slow) var(--ease-out); }
.rt-prog__pct { position: absolute; inset: 0; display: grid; place-items: center; font-size: var(--fs-11); font-weight: var(--fw-x); color: var(--green-dk); }

/* La pantalla es el marco de referencia del marcador "Tu día". */
.screen { position: relative; }

/* ---- "Tu día": MARCADOR fijo (sticky) en el borde derecho, con punto ámbar
   que late. Se OCULTA deslizándolo hacia adentro (toggle): queda una franjita
   verde que se toca para traerlo de vuelta. Se queda quieto al scrollear. ---- */
.dia-peek {
  position: sticky; top: 12px; z-index: 3;
  width: fit-content; margin: 0 calc(-1 * var(--sp-4)) -46px auto;
  display: flex; align-items: stretch;
  background: var(--green-dk); color: #fff;
  border-radius: 15px 0 0 15px; box-shadow: -6px 6px 18px -8px rgba(11,60,47,.5);
  transition: transform .32s var(--ease-out);
}
/* Colapsado: queda SOLO la franja verde con el chevron; el contenido (punto +
   "Tu día" + avisos) se esconde para que no se asome nada. */
.dia-peek.is-oculto { transform: translateX(calc(100% - 34px)); }
.dia-peek.is-oculto .dia-peek__open { opacity: 0; pointer-events: none; }
.dia-peek__toggle {
  flex: none; width: 34px; display: flex; align-items: center; justify-content: center;
  background: transparent; border: 0; color: rgba(255,255,255,.75); cursor: pointer; padding: 0;
}
.dia-peek__toggle svg { transition: transform .32s var(--ease-out); }
.dia-peek.is-oculto .dia-peek__toggle svg { transform: rotate(180deg); }
.dia-peek__open { display: flex; align-items: center; text-decoration: none; color: inherit; padding: 8px 14px 8px 4px; }
.dia-peek__body { display: flex; flex-direction: column; line-height: 1.15; }
.dia-peek__label { display: flex; align-items: center; gap: 6px; font-size: 11px; font-weight: var(--fw-x); letter-spacing: .07em; text-transform: uppercase; color: rgba(255,255,255,.82); }
.dia-peek__meta { display: flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: var(--fw-bold); margin-top: 1px; }
/* Vacío hasta que `onMount` trae la condición real (sin ubicación guardada,
   se queda así) — vacío no ocupa lugar, así que no hay salto cuando se llena. */
.dia-peek__clima { display: inline-flex; }
.dia-peek__clima svg { display: block; }
.dia-peek__dot { width: 7px; height: 7px; border-radius: 999px; background: var(--amber); flex: none; animation: diaPeekPulse 2s ease-in-out infinite; }
@keyframes diaPeekPulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.7); } }
@media (prefers-reduced-motion: reduce) { .dia-peek__dot { animation: none; } }

/* ---- Color del estado en la meta ---- */
.u-amber { font-weight: var(--fw-bold); color: var(--amber-ink); }
.u-coral { font-weight: var(--fw-bold); color: var(--coral); }

/* ---- La línea del día ---- */
.rt { margin-top: var(--sp-3); }
.rt-step { position: relative; display: grid; grid-template-columns: 32px 1fr; gap: 12px; padding-bottom: var(--sp-4); }
.rt-step:last-child { padding-bottom: 0; }
.rt-rail { position: relative; display: flex; justify-content: center; }
.rt-node {
  position: relative; z-index: 1; width: 32px; height: 32px; flex: none;
  display: grid; place-items: center; border-radius: var(--r-pill);
  font-size: var(--fs-14); font-weight: var(--fw-black); background: var(--surface);
  border: 2px solid var(--ink-3); color: var(--ink-3);
}
.rt-node--done { background: var(--green); border-color: var(--green); color: #fff; }
.rt-node--activo { background: var(--green); border-color: var(--green); color: #fff; box-shadow: 0 0 0 4px var(--green-soft); }
.rt-node--falta { background: var(--surface); border-color: var(--coral); color: var(--coral); }
/* Un solo trazo punteado verde para TODO el camino, del primer nodo al
   último (incluida la conexión) — antes se ponía sólido en los tramos
   resueltos/activo y quedaban dos lecturas de color compitiendo (línea Y
   nodo). El estado ya lo dice el NODO; la línea es siempre el mismo camino. */
.rt-line { position: absolute; top: 32px; bottom: calc(-1 * var(--sp-4)); left: 50%; transform: translateX(-50%); border-left: 2px dashed var(--green-med); }

/* ---- La tarjeta del paso ---- */
.rt-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: var(--sh-sm); overflow: hidden;
  transition: box-shadow var(--dur-base) var(--ease-out), transform var(--dur-fast) var(--ease-press);
}
.rt-card:active { transform: scale(.99); }
.rt-card--activo { border: 1.5px solid var(--green); box-shadow: var(--sh-md); }
.rt-step.is-resuelto { opacity: .62; }
.rt-step.is-resuelto .rt-card { background: var(--surface-2); box-shadow: none; }
.rt-step.is-resuelto .rt-card__title { text-decoration: line-through; text-decoration-color: var(--ink-3); }

.rt-card__hit { display: flex; align-items: center; gap: 12px; padding: 13px 14px; text-decoration: none; }
.rt-card--activo .rt-card__hit { align-items: flex-start; padding-bottom: 6px; }
.rt-card__ic { flex: none; width: 38px; height: 38px; border-radius: var(--r-md); display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
.rt-step.is-resuelto .rt-card__ic { background: var(--surface-sunk); color: var(--muted); }
.rt-card__body { flex: 1; min-width: 0; }
.rt-card__top { display: flex; align-items: flex-start; gap: 8px; justify-content: space-between; }
/* Título a 2 líneas como TOPE, con elipsis: un pendiente dictado entra crudo
   ("Necesito realizar el trámite de transferir al auto…") y sin cortar ocupaba
   7 renglones y tapaba la tarjeta. El resumen corto de verdad lo dará el modelo
   (categoría + título breve); esto es el techo visual mientras tanto. */
.rt-card__title {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden;
  font-size: var(--fs-14-5); font-weight: var(--fw-bold); color: var(--ink); line-height: 1.25;
}
.rt-card--activo .rt-card__title { font-size: var(--fs-18); font-weight: var(--fw-x); }
.rt-card__meta { display: block; margin-top: 3px; font-size: var(--fs-12); font-weight: var(--fw-semi); color: var(--muted); line-height: 1.4; }
.rt-card__meta b { color: var(--green-dk); font-weight: var(--fw-bold); }
/* Fila meta + chip: el chip NO comparte renglón con el título (así el título usa
   todo el ancho y deja de amontonarse cuando es largo). */
.rt-card__metarow { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; margin-top: 5px; }
.rt-card__metarow .rt-card__meta { margin-top: 0; }
.rt-card__chev { flex: none; color: var(--ink-3); align-self: center; }

/* ---- Chip de la tarjeta: la CATEGORÍA del pendiente (neutro, paleta Nidu).
   El estado se lee en la meta y en la forma de la tarjeta, no acá. ---- */
.rt-chip { flex: none; align-self: center; font-size: var(--fs-12); font-weight: var(--fw-x); padding: 4px 11px; border-radius: var(--r-pill); white-space: nowrap; }
.rt-chip--cat { background: var(--surface-sunk); color: var(--muted); }
/* El tiempo ("10:07 p. m.") no se parte entre renglones. */
.rt-meta-nowrap { white-space: nowrap; }

/* ---- Cuerpo de la tarjeta ACTIVA: próximo paso + botón lleno + recordar ---- */
.rt-next { margin: 6px 14px 14px; background: var(--green-soft); border-radius: var(--r-md); padding: 12px 14px; }
.rt-next__lead { font-size: var(--fs-10-5); font-weight: var(--fw-x); text-transform: uppercase; letter-spacing: .1em; color: var(--green); }
.rt-next__q { margin-top: 5px; font-size: var(--fs-14); font-weight: var(--fw-regular); color: var(--ink); line-height: 1.35; }
.rt-next__acts { display: flex; gap: 8px; margin-top: 12px; }
.rt-next__acts .btn--primary { flex: 1 1 auto; }
.btn--icon { flex: none; width: 48px; min-width: 48px; padding: 0; }
.rt-next .btn--ghost { background: var(--surface); border: 1px solid var(--line); }

/* ---- Hallazgo de conexión (opcional): fondo verde suave + borde punteado
   (#C6DBD0, el "borde verde" del handoff para hallazgos) + botón "Ver" ----
   Vive DENTRO de un `.rt-step` (ver ruta.js): el ícono ya no es propio —lo
   pone el nodo del rail, `.rt-node--done` con el bulbo— así que acá queda
   solo el cuerpo + la acción, sin margen propio (el `.rt-step` ya espacia). */
.rt-link {
  display: flex; align-items: center; gap: 12px;
  background: var(--green-soft); border: 1.5px dashed #C6DBD0;
  border-radius: var(--r-lg); padding: 14px 16px;
}
.rt-link__body { flex: 1; min-width: 0; }
.rt-link__kicker { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .1em; text-transform: uppercase; color: var(--green-dk); }
.rt-link__txt { margin-top: 3px; font-size: var(--fs-13); color: var(--ink-2); line-height: 1.4; }
.rt-link__cta { flex: none; min-height: 40px; padding: 0 18px; }
@media (max-width: 360px) {
  .rt-link { flex-wrap: wrap; }
  .rt-link__cta { width: 100%; justify-content: center; }
}

/* ============================================================
   Rediseño PWA — Fase 2 (handoff): barra de 4 pestañas + Calendario + Mapa
   ============================================================ */

/* ---- Pestaña "Mapa" con insignia "+" (agregar y mapa comparten pestaña) ---- */
.navitem--mapa { position: relative; padding: 0; }
.navitem--mapa .navitem__hit {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  width: 100%; padding: 6px 4px; border-radius: var(--r-md); color: inherit; text-decoration: none;
}
.navitem--mapa.is-active { color: var(--green); }
.navitem__add {
  position: absolute; top: 2px; left: 50%; margin-left: 5px;
  width: 18px; height: 18px; border-radius: 999px; background: var(--green); color: #fff;
  display: grid; place-items: center; border: 2px solid var(--app-bg); box-shadow: 0 2px 5px rgba(11,60,47,.3);
}
.navitem__add svg { width: 12px; height: 12px; }
.navitem--mapa:active .navitem__hit { transform: none; }

/* ---- Calendario ---- */
.cal-head { margin: 0 2px var(--sp-4); }
.cal-head__date { font-size: var(--fs-13); font-weight: var(--fw-regular); color: var(--muted); }
.cal-head__summary { margin-top: 4px; font-size: var(--fs-13); font-weight: var(--fw-semi); color: var(--ink); }
.cal-head__summary span[aria-hidden] { color: var(--ink-3); font-weight: var(--fw-semi); }

.cal-month { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 16px; box-shadow: var(--sh-sm); }
.cal-month__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal-month__name { font-size: var(--fs-16); font-weight: var(--fw-x); color: var(--ink); }
.cal-month__nav { display: flex; gap: 6px; }
.cal-arrow { width: 32px; height: 32px; display: grid; place-items: center; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); cursor: pointer; }
.cal-arrow:active { transform: scale(.94); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-grid--dow { margin-bottom: 6px; }
.cal-dow { text-align: center; font-size: var(--fs-11); font-weight: var(--fw-bold); color: var(--ink-3); }
/* `.cal-cell` es un <button> (tocar un día muestra sus pendientes) salvo los
   rellenos vacíos antes del día 1, que siguen siendo <span aria-hidden>. Se
   resetea el chrome de botón para que los estados de color (is-uno/is-cargado/
   is-hoy) sigan siendo los únicos que se ven. */
.cal-cell {
  position: relative; aspect-ratio: 1; display: grid; place-items: center;
  font: inherit; font-size: var(--fs-13); font-weight: var(--fw-semi); color: var(--ink-2);
  border: none; border-radius: var(--r-sm); background: transparent; padding: 0; width: 100%;
  cursor: pointer;
}
.cal-cell:active { transform: scale(.92); }
.cal-cell--empty { visibility: hidden; cursor: default; }
.cal-cell.is-uno { background: var(--green-soft); color: var(--green-dk); }
.cal-cell.is-cargado { background: var(--green-med); color: #fff; font-weight: var(--fw-bold); }
.cal-cell.is-hoy { background: var(--green-dk); color: #fff; font-weight: var(--fw-black); }
/* Anillo de selección: se pinta ARRIBA del relleno de color, así se ve igual
   sobre cualquiera de los tres (incluida is-hoy, donde un fondo más no se vería). */
.cal-cell.is-sel { box-shadow: inset 0 0 0 2px var(--ink); }
.cal-cell__dot { position: absolute; bottom: 4px; width: 4px; height: 4px; border-radius: 999px; background: var(--green); }
.cal-cell.is-cargado .cal-cell__dot { background: #fff; }
/* "Tenés algo en tu calendario" ese día: un anillo ámbar alrededor del día,
   SIN tocar el verde de pendientes (is-uno/is-cargado/is-hoy) — el fundador
   probó pisar el relleno con ámbar sólido y pidió volver atrás: "mantener los
   mismos colores que estaban antes... solo diferenciar con el color ámbar".
   El anillo se pinta ARRIBA del relleno que sea, así los dos hechos conviven:
   el relleno dice cuántos pendientes tiene, el anillo dice si además hay algo
   en el calendario externo (Google/Outlook).
   Va DESPUÉS de `.is-sel` a propósito: en un día seleccionado que ADEMÁS tiene
   evento, el anillo de selección (tinta, más grueso) se comía el ámbar y
   apenas se veía —"pintalo de ámbar", pedido del fundador viendo el
   resultado—, así que acá gana el ámbar solo, sin combinarlo con el de tinta. */
.cal-cell.tiene-evento { box-shadow: inset 0 0 0 2px var(--amber); }
.cal-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: var(--fs-12); color: var(--muted); }
.cal-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cal-lg { width: 12px; height: 12px; border-radius: 4px; }
.cal-lg--uno { background: var(--green-soft); }
.cal-lg--cargado { background: var(--green-med); }
.cal-lg--hoy { background: var(--green-dk); }
.cal-lg--evento { background: transparent; box-shadow: inset 0 0 0 2px var(--amber); }

/* Pendientes del día tocado en la grilla, y el calendario de HOY — dos
   secciones de "un día" que pueden convivir en la misma pantalla (tocás un
   día que no es hoy) y necesitan el título para no leerse como una sola
   lista contradictoria ("nada para ese día" + una lista debajo). */
.cal-dia-pend, .cal-hoy { margin-top: var(--sp-4); }
.cal-dia-ext { margin-top: var(--sp-4); }
.cal-seclabel { margin: 0 2px 8px; font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: var(--muted); }

/* Nota informativa: mensajes que informan un estado (no una acción ni un dato
   de un pendiente) van en su propia caja con tinte "info", no como texto suelto
   flotando en la pantalla — así se leen como una aclaración y no como contenido. */
.cal-note { display: flex; align-items: flex-start; gap: 8px; margin: var(--sp-4) 2px; padding: 10px 12px; background: var(--info-bg); border-radius: var(--r-md); font-size: var(--fs-13); color: var(--ink-2); line-height: 1.5; }
.cal-note svg { flex: none; margin-top: 1px; color: var(--info); }

.cal-slot { display: grid; grid-template-columns: 52px 1fr; gap: 10px; padding-bottom: var(--sp-3); }
.cal-slot__time { font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--ink-3); padding-top: 12px; }
.cal-event { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 12px 14px; box-shadow: var(--sh-sm); }
.cal-event__tit { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.cal-event__meta { margin-top: 2px; font-size: var(--fs-12); color: var(--muted); }
.cal-hueco { background: var(--green-soft); border: 1px dashed #C6DBD0; border-radius: var(--r-md); padding: 12px 14px; }
.cal-hueco__lead { display: flex; align-items: center; gap: 6px; font-size: var(--fs-10-5); font-weight: var(--fw-x); text-transform: uppercase; letter-spacing: .1em; color: var(--green-dk); }
.cal-hueco__txt { margin-top: 5px; font-size: var(--fs-14); color: var(--ink); line-height: 1.35; }
.cal-hueco__txt b { color: var(--green-dk); }
.cal-hueco__acts { display: flex; gap: 8px; margin-top: 10px; }
.cal-hueco__acts .btn { flex: 1 1 auto; }

/* ---- Mapa v3: pendientes por CATEGORÍA como GRILLA de fichas ----
   Dos columnas de fichas con cabecera de color (verde reposo / coral si algo
   vence, paleta nueva de la web) y el ícono asomando por encima del borde. La
   cabecera es la única señal cromática y se lee antes que el texto; el ícono
   nunca lleva color propio por categoría. Todo entra sin scroll. Medidas
   calcadas de `!!Diseños Nidu/PWA/Mapa NIDU v3.dc.html`; el verde de reposo
   sigue siendo literal del handoff, pero el coral de urgencia reusa
   `--cat-compra-*` (mismo tono que la web nueva) en vez de repetirlo suelto. */
.mapa-sub {
  margin: 2px 2px 0; font-size: var(--fs-13); font-weight: var(--fw-regular); color: var(--muted);
  text-align: center; text-shadow: 0 1px 2px rgba(37, 51, 49, .15);
}
/* Las dos mitades se distinguen: lo urgente en coral (salta a la vista), lo que
   espera en neutro. `.is-on` solo cuando hay algo urgente; en 0 queda neutro. */
.mapa-sub__urge { font-weight: var(--fw-bold); color: var(--muted); }
.mapa-sub__urge.is-on { color: var(--cat-compra-ink); }
.mapa-sub__wait { font-weight: var(--fw-semi); color: var(--muted); }
.mapa-sub__sep { margin: 0 2px; color: var(--ink-3); }

/* Nota contextual: orientación, no aviso — nunca cambia de color ni pide acción. */
.mapa-nota { display: flex; align-items: center; gap: 11px; margin-top: var(--sp-4); background: var(--green-soft); border-radius: 14px; padding: 12px 13px; }
.mapa-nota__ic { flex: none; display: inline-flex; color: var(--green); }
.mapa-nota__txt { flex: 1; min-width: 0; font-size: var(--fs-12-5); font-weight: var(--fw-regular); line-height: 1.4; color: var(--green-dk); }

/* La grilla. minmax(0,1fr) es obligatorio: con 1fr a secas el min-width:auto de
   los ítems deja que el texto sin cortar estire las columnas y rompa el ancho.
   La separación vertical la da el margin-top de cada ficha (que es también el
   hueco que el ícono necesita para asomar), no el row-gap. */
.mapa-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 11px; margin-top: 4px; }

.mcard {
  position: relative; display: block; min-width: 0; margin-top: 24px; padding: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px;
  text-decoration: none; box-shadow: 0 1px 2px rgba(11,60,47,.04), 0 14px 26px -20px rgba(11,60,47,.4);
  transition: transform .2s var(--ease-out), box-shadow .2s var(--ease-out);
  animation: mapaRise .5s var(--ease-out) both;
}
.mcard:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(11,60,47,.06), 0 22px 34px -22px rgba(11,60,47,.5); }
/* Cabecera de color: verde en reposo, coral cuando algo de la categoría urge
   (paleta nueva de la web: mismo `#E98973`/`#B45A42` que ya vive acá como
   `--cat-compra-*` — antes esto era ámbar, no coincidía). */
.mcard__head { display: block; height: 40px; border-radius: 19px 19px 0 0; background: #3E7A64; }
.mcard.is-urgente .mcard__head { background: var(--cat-compra-ink); }
/* Ícono asomando: círculo sobre el fondo de página, montado a -24px. */
.mcard__ic {
  position: absolute; left: 50%; top: -24px; transform: translateX(-50%);
  width: 56px; height: 56px; border-radius: 999px; display: grid; place-items: center;
  background: var(--app-bg); border: 1px solid #D5E7DD; color: var(--green);
  box-shadow: 0 6px 14px -8px rgba(11,60,47,.5);
}
.mcard.is-urgente .mcard__ic { border-color: var(--cat-compra-border); color: var(--cat-compra-ink); }
.mcard__body { display: block; min-width: 0; padding: 10px 13px 11px; }
.mcard__name { display: block; font-size: var(--fs-14); font-weight: var(--fw-x); letter-spacing: -.015em; color: var(--ink); }
/* Resumen: chip de estado (si urge) + título corto, en una fila de alto fijo.
   El chip va PRIMERO y no se encoge, así el estado no se pierde nunca; el
   título se recorta a una línea con elipsis. Alto fijo para que las fichas de
   las dos columnas queden alineadas tengan chip o no. */
.mcard__sum { display: flex; align-items: center; gap: 6px; margin-top: 3px; height: 20px; }
.mcard__chip {
  flex: none; font-size: 10px; font-weight: var(--fw-x); line-height: 1;
  padding: 3px 7px; border-radius: var(--r-pill);
  background: var(--cat-compra-tint); color: var(--cat-compra-ink); white-space: nowrap;
}
.mcard__sum-txt {
  flex: 1; min-width: 0; font-size: var(--fs-11-5); font-weight: var(--fw-semi); color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mcard__foot { margin-top: 8px; display: flex; align-items: center; justify-content: space-between; }
.mcard__chev { display: flex; color: var(--ink-3); }

/* Badge contador: neutro por defecto; coral con anillo pulsante cuando urge. */
.mcard__badge {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 22px; padding: 0 7px; border-radius: 7px;
  font-size: var(--fs-11-5); font-weight: var(--fw-x);
  background: var(--surface-sunk); color: var(--muted);
}
.mcard__badge.is-urgente { background: var(--cat-compra-tint); color: var(--cat-compra-ink); }
.mcard__badge-ring { position: absolute; inset: -3px; border-radius: 9px; border: 1.5px solid var(--cat-compra-ink); opacity: .5; animation: mapaBadgePulse 2.4s ease-out infinite; }

/* Ficha fija "Futuros": no compite con las categorías de dominio, así que
   el head va en el gris azulado del ink-3 (más quieto que el verde), el
   ícono en el mismo tono para reforzar que es un ESTADO temporal (lo
   agendado a >14 días), no un rubro. */
.mcard--futuros .mcard__head { background: var(--ink-3); }
.mcard--futuros .mcard__ic { color: var(--ink-3); border-color: #D6DDE0; }

/* Ficha fija "En seguimiento": mismo criterio que "Futuros" — es un ESTADO
   temporal (con seguimiento automático activo), no una categoría de dominio.
   El head toma el ámbar suave para distinguir: son pendientes que se están
   moviendo solos (Nidu revisando), no simplemente diferidos. */
.mcard--seguimientos .mcard__head { background: var(--amber-ink, #b76e00); }
.mcard--seguimientos .mcard__ic { color: var(--amber-ink, #b76e00); border-color: #F1D9AC; }

/* "Nueva categoría": ficha punteada de ancho completo que cierra la grilla. Es
   una acción, no un ítem — por eso queda fuera del ritmo de dos columnas. */
.mapa-nueva {
  display: flex; align-items: center; gap: 11px; width: 100%; min-height: 44px; margin-top: 14px;
  padding: 10px 14px; border: 1.5px dashed var(--line); border-radius: 16px;
  background: transparent; font-family: inherit; text-align: left; cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}
.mapa-nueva:hover { border-color: var(--green); background: #F2F7F4; }
.mapa-nueva__ic { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 999px; background: var(--green-soft); color: var(--green); }
.mapa-nueva__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mapa-nueva__tit { font-size: var(--fs-14); font-weight: var(--fw-bold); letter-spacing: -.01em; color: var(--green); }
.mapa-nueva__sub { margin-top: 1px; font-size: var(--fs-11-5); color: var(--ink-3); }

/* Botón primario: único lugar para agregar. Alto 42, radio 12 (no píldora). Va
   arriba, debajo del subtítulo, para que quede visible sin bajar. */
.mapa-add {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  height: 42px; margin-top: var(--sp-4); border-radius: 12px;
  background: var(--green); color: #fff; text-decoration: none;
  font-size: var(--fs-13-5); font-weight: var(--fw-bold);
  transition: background var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.mapa-add:hover { background: var(--green-hover); color: #fff; }
.mapa-add:active { transform: scale(.99); }

@keyframes mapaRise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes mapaBadgePulse { 0% { transform: scale(1); opacity: .55; } 70% { transform: scale(2.4); opacity: 0; } 100% { transform: scale(2.4); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .mcard, .mcard__badge-ring { animation: none; } }

/* ---- Categorías propias: controles y sheets del Mapa ---- */
.mapa-toolbar { display: flex; justify-content: flex-end; margin: 10px 2px 2px; }
.mapa-ordenar {
  display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent;
  font: inherit; font-size: var(--fs-13); font-weight: var(--fw-bold); color: var(--green);
  padding: 5px 8px; border-radius: 9px; cursor: pointer;
}
.mapa-ordenar:hover { background: var(--green-soft); }

.mapa-cat-gestion { display: flex; justify-content: flex-end; margin-bottom: 12px; }

.mapa-sheet { position: fixed; inset: 0; z-index: var(--z-sheet); display: flex; align-items: flex-end; justify-content: center; }
.mapa-sheet__scrim { position: absolute; inset: 0; background: rgba(20,33,28,.38); opacity: 0; transition: opacity var(--dur-base); }
.mapa-sheet.is-open .mapa-sheet__scrim { opacity: 1; }
.mapa-sheet__panel {
  position: relative; width: min(var(--app-max), 100%);
  background: var(--surface); border-radius: 22px 22px 0 0;
  padding: 8px 20px calc(20px + var(--safe-b)); max-height: 86vh; overflow-y: auto;
  transform: translateY(100%); transition: transform var(--dur-base) var(--ease-out); box-shadow: var(--sh-lg);
}
.mapa-sheet.is-open .mapa-sheet__panel { transform: translateY(0); }
.mapa-sheet__head { position: sticky; top: 0; background: var(--surface); display: flex; align-items: center; justify-content: space-between; padding: 8px 0 10px; z-index: 1; }
.mapa-sheet__title { font-size: var(--fs-18); font-weight: var(--fw-x); color: var(--ink); }
.mapa-sheet__body { padding-bottom: 6px; }
.mapa-field-gap { margin-top: 14px; }

.mapa-orden { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mapa-orden__op {
  width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--surface);
  font: inherit; text-align: left; cursor: pointer;
}
.mapa-orden__op:hover { background: var(--surface-2); }
.mapa-orden__op.is-sel { border-color: var(--green); background: #F2F7F4; }
.mapa-orden__check { flex: none; width: 20px; color: var(--green); opacity: 0; display: inline-flex; }
.mapa-orden__op.is-sel .mapa-orden__check { opacity: 1; }
.mapa-orden__txt { display: flex; flex-direction: column; }
.mapa-orden__t { font-size: var(--fs-14); font-weight: var(--fw-bold); color: var(--ink); }
.mapa-orden__s { font-size: var(--fs-12); color: var(--ink-2); }

.mapa-manual { margin-top: 12px; }
.mapa-manual__hint { font-size: var(--fs-12); color: var(--ink-2); margin-bottom: 8px; }
.mapa-manual__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mapa-manual__list li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; }
.mapa-manual__ic { flex: none; width: 30px; height: 30px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: var(--surface-sunk); color: var(--ink-2); }
.mapa-manual__lbl { flex: 1; min-width: 0; font-size: var(--fs-14); font-weight: var(--fw-semi); color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mapa-manual__mov { flex: none; display: flex; gap: 4px; }
.mapa-manual__mov button {
  width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface);
  display: inline-flex; align-items: center; justify-content: center; color: var(--ink-2); cursor: pointer;
}
.mapa-manual__mov button:hover:not(:disabled) { border-color: var(--green); color: var(--green); }
.mapa-manual__mov button:disabled { opacity: .35; cursor: default; }
.mapa-manual__up svg { transform: rotate(-90deg); }
.mapa-manual__down svg { transform: rotate(90deg); }

.mapa-icons { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.mapa-icons__op {
  aspect-ratio: 1; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink-2); cursor: pointer;
}
.mapa-icons__op:hover { background: var(--surface-2); }
.mapa-icons__op.is-sel { border-color: var(--green); color: var(--green-dk); background: #F2F7F4; }

.mapa-form__actions { display: flex; gap: 10px; margin-top: 18px; }
.mapa-form__actions .btn--primary { flex: 1; }
.mapa-form__del { flex: none; color: var(--alerta); }
.mapa-form__confirm { margin-top: 14px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.mapa-form__confirm p { font-size: var(--fs-13); color: var(--ink-2); line-height: 1.5; }
.mapa-form__confirm-btns { display: flex; gap: 10px; margin-top: 12px; }
.mapa-form__confirm-btns .btn { flex: 1; }

@media (prefers-reduced-motion: reduce) {
  .mapa-sheet__scrim, .mapa-sheet__panel { transition: none; }
}

/* ============================================================
   Tu día — sheet v7, "persiana" (`!!Diseños Nidu/PWA/tu-dia-nidu`)
   Colores propios de la pantalla (clima/crítico) como literales del handoff.
   Sin inventario (sin tira de contadores por categoría: ver [[nidu-mapa]]).
   ============================================================ */
/* La hoja se ajusta al CONTENIDO, con tope de pantalla — no fuerza 100% de
   alto: con pocas tarjetas eso dejaba una franja vacía abajo (reporte de
   campo, 3/8). El cuerpo scrollea (`.dia-sheet__body`) si el contenido no
   entra; la animación de la persiana (`max-height` en `.dia-criticos-panel` /
   `.dia-ruta-panel`) no depende de esto y sigue igual. */
.dia-sheet { display: flex; flex-direction: column; max-height: 100%; background: var(--app-bg); }
.dia-sheet__handle { flex: none; width: 40px; height: 4px; border-radius: 999px; background: #D8D4CA; margin: 10px auto 0; }
/* Fijo arriba mientras se scrollea: como la hoja ya no fuerza 100% de alto, el
   que scrollea cuando hay mucho contenido (persiana abierta) es `#app` — sin
   `sticky` acá, el título y el botón de cerrar se irían con el resto. */
.dia-sheet__head { position: sticky; top: 0; z-index: 1; flex: none; display: flex; align-items: flex-start; gap: 12px; padding: 14px 20px 0; background: var(--app-bg); }
.dia-sheet__titwrap { flex: 1; min-width: 0; }
.dia-sheet__tit { display: block; font-size: 27px; font-weight: var(--fw-x); letter-spacing: -.03em; color: var(--green-dk); }
.dia-sheet__sub { display: block; margin-top: 3px; font-size: var(--fs-13); color: var(--muted); }
.dia-sheet__close { flex: none; width: 38px; height: 38px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); display: grid; place-items: center; }
.dia-sheet__close:active { transform: scale(.94); }
.dia-sheet__body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 14px 20px calc(var(--safe-b) + 10px); display: flex; flex-direction: column; }

/* 0 · Frase motivacional — un empujoncito, no un aviso: por eso NO comparte el
   componente `.dia-ctx`/`.dia-aviso` (esos son cosas que pasaron o que hay
   que resolver). Tarjeta oscura propia (el único bloque oscuro de la hoja
   junto al slab de lluvia) para que se lea como un gesto aparte, no como una
   tarjeta de datos más. Siempre visible, no se va cuando se abre la persiana
   (a diferencia de `.dia-ruta-panel`): no es contexto de la ruta, es un
   saludo. El pie "Actualizado" queda AFUERA de la tarjeta oscura (fondo
   claro), como en el resto de la hoja. */
.dia-motiv { position: relative; overflow: hidden; margin-bottom: 4px; padding: 16px 18px 18px; background: var(--green-dk); border-radius: 22px; animation: diaRise .5s var(--ease-out) both; }
.dia-motiv__garabato { position: absolute; top: -10px; right: -10px; width: 140px; height: 100px; pointer-events: none; }
.dia-motiv__head { position: relative; display: flex; align-items: center; gap: 8px; }
.dia-motiv__quote { flex: none; font-size: 22px; line-height: 1; font-weight: var(--fw-x); color: #6E9D89; }
.dia-motiv__kicker { flex: 1; font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: #9CC2AF; }
.dia-motiv__acts { flex: none; display: flex; align-items: center; gap: 8px; }
.dia-motiv__btn { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 999px; border: 1px solid rgba(255,255,255,.25); color: #CFE3D8; }
.dia-motiv__ok { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 999px; background: #BFDCCB; color: var(--green-dk); }
.dia-motiv__tit { position: relative; margin-top: 10px; font-size: var(--fs-19); font-weight: var(--fw-x); letter-spacing: -.02em; line-height: 1.25; color: #fff; }
.dia-motiv__pie { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 8px 0 4px; font-size: var(--fs-11-5); font-weight: var(--fw-semi); color: var(--ink-3); }

/* 1 · Aviso crítico — es el TIRADOR de la persiana (button, no link). Un solo
   estado (aria-expanded en este botón) maneja, vía selector de hermanos, el
   chevron y los dos paneles de abajo — sin eso no hay re-render que corte la
   transición. */
.dia-aviso { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 13px; background: #FDF1EA; border: 1px solid #F5DCCE; border-radius: 18px; font-family: inherit; text-align: left; cursor: pointer; animation: diaRise .5s var(--ease-out) both .04s; }
.dia-aviso__ic { position: relative; flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; background: #FAE3D8; color: #C4453A; }
.dia-aviso__badge { position: absolute; top: -3px; right: -3px; display: grid; place-items: center; width: 19px; height: 19px; border-radius: 999px; background: #C4453A; color: #fff; font-size: 11px; font-weight: var(--fw-x); border: 2px solid #FDF1EA; }
.dia-aviso__ring { position: absolute; inset: -4px; border-radius: 999px; border: 1.5px solid #C4453A; opacity: .35; animation: diaPulse 2.8s ease-out infinite; }
.dia-aviso__body { flex: 1; min-width: 0; }
.dia-aviso__tit { display: block; font-size: var(--fs-15); font-weight: var(--fw-x); letter-spacing: -.015em; color: #8E3527; }
.dia-aviso__sub { display: block; margin-top: 3px; font-size: var(--fs-12-5); line-height: 1.4; color: #7C6A62; }
.dia-aviso__sub--abierto { display: none; }
.dia-aviso[aria-expanded="true"] .dia-aviso__sub--cerrado { display: none; }
.dia-aviso[aria-expanded="true"] .dia-aviso__sub--abierto { display: block; }
.dia-aviso__chev { flex: none; display: flex; color: #C08A76; transition: transform .45s cubic-bezier(.4,0,.2,1); }
.dia-aviso[aria-expanded="true"] .dia-aviso__chev { transform: rotate(90deg); }

/* 2 · Tarjetas de crítico (estado ABAJO de la persiana). El resto del sheet
   ("lo que cambia tu ruta" + información) no se achica: se va entero — misma
   mecánica de max-height, con el retraso de `visibility` asimétrico (entra
   visible al toque, sale de la tabulación recién al terminar de cerrar) hecho
   con dos declaraciones de `transition` distintas en vez de JS por elemento. */
.dia-criticos-panel {
  display: flex; flex-direction: column;
  overflow: hidden; max-height: 0; opacity: 0; transform: translateY(-12px); visibility: hidden;
  transition: max-height .45s cubic-bezier(.4,0,.2,1), transform .45s cubic-bezier(.4,0,.2,1), opacity .3s ease, visibility 0s linear .45s;
}
.dia-aviso[aria-expanded="true"] ~ .dia-criticos-panel {
  max-height: var(--criticos-h, 560px); opacity: 1; transform: translateY(0); visibility: visible;
  transition: max-height .45s cubic-bezier(.4,0,.2,1), transform .45s cubic-bezier(.4,0,.2,1), opacity .3s ease, visibility 0s linear 0s;
}
/* Ni la persiana ni la lista scrollean por sí solas — el único scroll de toda
   la hoja es `.dia-sheet__body`. Antes la lista tenía su propio scroll interno
   (cap fijo de 560px + `overflow-y:auto` acá) para no depender de medir el
   contenido real; con tres scrolls anidados (`#app` → `.dia-sheet__body` →
   esta lista) más `overscroll-behavior:contain`, en iOS Safari el touch-scroll
   se trababa antes de llegar al final real y dejaba los botones de la última
   tarjeta sin alcanzar — el reflow forzado que se probó (JS, 4/8) no lo
   sacaba del todo (seguía reproduciendo, reporte de campo 4/8 otra vez). El
   JS ahora mide el alto real de esta lista con `scrollHeight` antes de abrir
   la persiana y se lo pasa al panel como `max-height` exacto (custom property
   `--criticos-h`) — así el panel nunca sobra ni corta, y esta lista no
   necesita scroll ni cap propios.
   FLEX en columna, no grid: con grid, `grid-auto-rows` fijaba cada fila en
   los 116px del `min-height` de la tarjeta en vez de medir el contenido real
   —una tarjeta con título de 2 líneas necesita hasta 160px—, así que la
   tarjeta se salía de su propia fila y quedaba tapada a medias por la
   siguiente (reporte del fundador). Flex-column sí mide cada hijo por su
   contenido; `flex: none` en la tarjeta evita además que el scroll la achique. */
.dia-criticos-list { flex: none; padding: 11px 0 18px; display: flex; flex-direction: column; gap: 10px; }
.dia-critico { flex: none; display: flex; align-items: flex-start; gap: 11px; min-height: 116px; padding: 12px 13px; background: #fff; border: 1px solid #F0DCD3; border-radius: 18px; box-shadow: 0 10px 22px -18px rgba(154,67,49,.7); }
.dia-critico__ic { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 999px; background: #FAEBE6; color: #C4453A; }
.dia-critico__body { flex: 1; min-width: 0; }
.dia-critico__top { display: flex; align-items: center; gap: 8px; }
.dia-critico__cat { font-size: 10px; font-weight: var(--fw-x); letter-spacing: .11em; color: var(--muted); }
.dia-critico__plazo { display: inline-flex; align-items: center; height: 20px; padding: 0 8px; border-radius: 999px; background: #FAEBE6; color: #9A4331; font-size: var(--fs-10-5); font-weight: var(--fw-x); white-space: nowrap; }
.dia-critico__tit { display: block; margin-top: 4px; font-size: var(--fs-16); font-weight: var(--fw-x); letter-spacing: -.025em; color: var(--ink); }
.dia-critico__det { display: block; margin-top: 4px; font-size: var(--fs-12-5); line-height: 1.4; color: var(--muted); }
.dia-critico__acts { margin-top: 9px; display: flex; gap: 8px; flex-wrap: wrap; }
.dia-critico__btn { min-height: 36px; display: inline-flex; align-items: center; padding: 0 13px; border: 0; border-radius: 11px; background: #C4453A; color: #fff; text-decoration: none; font-size: var(--fs-12-5); font-weight: var(--fw-x); }
.dia-critico__btn--out { border: 1px solid #F0DCD3; background: #fff; color: #8E3527; font-weight: var(--fw-bold); }

/* Rótulo de sección */
.dia-seclabel { margin: 9px 0 0; font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: var(--muted); }

/* Estado ARRIBA de la persiana: "lo que cambia tu ruta" + información. */
.dia-ruta-panel {
  overflow: hidden; max-height: 560px; opacity: 1; transform: translateY(0); visibility: visible;
  transition: max-height .45s cubic-bezier(.4,0,.2,1), transform .45s cubic-bezier(.4,0,.2,1), opacity .3s ease, visibility 0s linear 0s;
}
.dia-aviso[aria-expanded="true"] ~ .dia-ruta-panel {
  max-height: 0; opacity: 0; transform: translateY(-12px); visibility: hidden;
  transition: max-height .45s cubic-bezier(.4,0,.2,1), transform .45s cubic-bezier(.4,0,.2,1), opacity .3s ease, visibility 0s linear .45s;
}

/* 3 · Slab de clima. Es un <a>: la tarjeta entera es el link a `#/clima` (no al
   pendiente — ver comentario de `filaContextoHTML` en briefing.js). El CTA de
   abajo es un `<span>`, no un botón propio: no puede haber un control
   interactivo anidado dentro del `<a>` que ya cubre toda la tarjeta (mismo
   patrón que `.dia-ctx__cta` en la fila). Sin él la tarjeta no tenía ninguna
   pista visual de que se puede tocar — quedaba como texto suelto (reporte de
   campo 4/8). */
.dia-slab { position: relative; display: block; overflow: hidden; margin-top: 7px; padding: 11px 14px; border-radius: 20px; background: #3E566B; color: #fff; text-decoration: none; box-shadow: 0 18px 30px -22px rgba(11,60,47,.8); animation: diaRise .5s var(--ease-out) both .12s; }
.dia-slab__kicker { position: relative; display: block; font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; color: #BCD0E0; }
.dia-slab__tit { position: relative; display: block; margin-top: 5px; font-size: var(--fs-19); font-weight: var(--fw-x); letter-spacing: -.03em; line-height: 1.08; }
.dia-slab__txt { position: relative; display: block; margin-top: 7px; max-width: 230px; font-size: var(--fs-12-5); line-height: 1.4; color: #D3E0EA; }
.dia-slab__cta { position: relative; display: inline-flex; align-items: center; gap: 6px; margin-top: 11px; min-height: 36px; padding: 0 13px; border: 1px solid rgba(255,255,255,.4); border-radius: 999px; color: #fff; font-size: var(--fs-12-5); font-weight: var(--fw-bold); }
/* Ilustración de lluvia arriba a la derecha (decorativa). */
.dia-slab__art { position: absolute; right: 12px; top: 12px; width: 104px; height: 74px; pointer-events: none; }
/* Variante sin lluvia: el ícono de `iconoClima` (mismo set que Ruta/`#/clima`)
   centrado en vez del dibujo de nubes+gotas, que es específico de lluvia. */
.dia-slab__art--icono { display: flex; align-items: center; justify-content: center; width: 72px; height: 72px; top: 8px; }
.dia-cloud { position: absolute; border-radius: 999px; background: #F1F6FA; }
.dia-cloud--a { left: 18px; top: 10px; width: 70px; height: 26px; animation: diaFloat 8s ease-in-out infinite; }
.dia-cloud--b { left: 6px; top: 22px; width: 38px; height: 20px; background: #DDE8F0; animation: diaFloat 11s ease-in-out infinite; }
.dia-drop { position: absolute; top: 40px; width: 2.5px; height: 12px; border-radius: 2px; background: #C3D5E2; animation: diaRain 1.2s linear infinite; }

/* 3 · Fila de contexto (tránsito). Es un <a>: la fila entera es el link al pendiente. */
.dia-ctx { display: flex; align-items: flex-start; gap: 11px; width: 100%; margin-top: 8px; padding: 9px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; font-family: inherit; text-align: left; text-decoration: none; color: inherit; cursor: pointer; animation: diaRise .5s var(--ease-out) both .18s; }
.dia-ctx__ic { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px; background: #E8A33D; }
.dia-ctx__ic svg { animation: diaFloat 2.4s ease-in-out infinite; }
.dia-ctx__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dia-ctx__kicker { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .11em; color: #8A6013; }
.dia-ctx__tit { margin-top: 3px; font-size: var(--fs-15); font-weight: var(--fw-x); letter-spacing: -.02em; color: var(--ink); }
.dia-ctx__cta { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; margin-top: 8px; min-height: 36px; padding: 0 13px; border: 1px solid #EDDCB5; border-radius: 999px; color: #8A6013; font-size: var(--fs-12-5); font-weight: var(--fw-bold); }
/* Tema calendario (próxima reunión): mismo componente que tránsito, paleta azul. */
.dia-ctx--calendario .dia-ctx__ic { background: #D2E0EC; color: #2D5C8A; }
.dia-ctx--calendario .dia-ctx__kicker { color: #2D5C8A; }
.dia-ctx--calendario .dia-ctx__cta { color: #2D5C8A; border-color: #C3D6E6; }

.dia-ctx--clima .dia-ctx__ic { background: #DCE3E8; }
.dia-ctx--clima .dia-ctx__kicker { color: #3E566B; }
.dia-ctx--clima .dia-ctx__cta { color: #3E566B; border-color: #CBD8DE; }

/* Tema hueco (próximo tramo libre entre reuniones): paleta verde, distinta de
   la reunión —es una oportunidad, no un compromiso— aunque comparta el ícono
   de calendario en el kicker. */
.dia-ctx--hueco .dia-ctx__ic { background: #D7E8DE; color: var(--green-dk); }
.dia-ctx--hueco .dia-ctx__kicker { color: var(--green-dk); }
.dia-ctx--hueco .dia-ctx__cta { color: var(--green-dk); border-color: #C7DECF; }

/* Tema "lugar" (contextoLugarFaltante): NO es un <a> de fila entera como el
   resto — puede ofrecer DOS respuestas (casa y trabajo), así que son botones
   que disparan una acción en vez de un link que navega. Mismo cascarón que
   `.dia-ctx` (incluida la paleta ámbar, como tránsito: es lo mismo — un
   trayecto que falta resolver — solo que acá falta el destino, no el tráfico). */
.dia-lugar { display: flex; flex-direction: column; width: 100%; margin-top: 8px; padding: 12px 13px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; animation: diaRise .5s var(--ease-out) both .18s; }
.dia-lugar__kicker { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .11em; color: #8A6013; }
.dia-lugar__tit { margin-top: 3px; font-size: var(--fs-15); font-weight: var(--fw-x); letter-spacing: -.02em; color: var(--ink); }
.dia-lugar__acts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 9px; }
.dia-lugar__btn { min-height: 36px; display: inline-flex; align-items: center; padding: 0 13px; border: 1px solid #EDDCB5; border-radius: 999px; background: #fff; color: #8A6013; font-family: inherit; font-size: var(--fs-12-5); font-weight: var(--fw-bold); }
.dia-lugar__btn:active { background: #FBF3E2; }
.dia-lugar__btn:disabled { opacity: .5; }

/* 4 · Información para tus pendientes (hallazgo) */
.dia-find { display: flex; align-items: flex-start; gap: 12px; margin-top: 7px; padding: 10px 13px; background: #EFF5F1; border: 1px solid #D5E7DD; border-radius: 18px; text-decoration: none; animation: diaRise .5s var(--ease-out) both .24s; }
.dia-find__ic { position: relative; flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; background: #DCEBE3; color: var(--green); }
.dia-find__badge { position: absolute; right: -2px; bottom: -2px; display: grid; place-items: center; width: 17px; height: 17px; border-radius: 999px; background: var(--green); color: #fff; font-size: 11px; font-weight: var(--fw-x); border: 2px solid #EFF5F1; animation: diaGlow 2.6s ease-in-out infinite; }
.dia-find__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dia-find__kicker { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .11em; color: var(--muted); }
.dia-find__tit { margin-top: 3px; font-size: var(--fs-15); font-weight: var(--fw-x); letter-spacing: -.02em; color: var(--ink); }
.dia-find__txt { margin-top: 4px; font-size: var(--fs-12-5); line-height: 1.4; color: var(--muted); }
.dia-find__cta { align-self: flex-start; margin-top: 9px; min-height: 40px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 11px; background: var(--green-dk); color: #fff; font-size: var(--fs-13); font-weight: var(--fw-x); }
.dia-find__chev { flex: none; display: flex; align-self: center; color: #8FA894; }

/* Vacío de "información para tus pendientes": nunca se esconde el bloque
   entero (a diferencia de "lo que cambia tu ruta") — el silencio se confunde
   con "no lo revisó". */
.dia-vacio { display: flex; align-items: center; gap: 11px; margin-top: 7px; padding: 12px 13px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; animation: diaRise .5s var(--ease-out) both .24s; }
.dia-vacio__ic { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 999px; background: var(--surface-sunk); color: var(--muted); }
.dia-vacio__txt { font-size: var(--fs-13); color: var(--muted); font-weight: var(--fw-semi); }

/* Cierre */
.dia-cierre { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: auto; padding: 7px 0 2px; font-size: var(--fs-11-5); font-weight: var(--fw-semi); color: var(--ink-3); }

@keyframes diaRise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes diaPulse { 0% { transform: scale(1); opacity: .35; } 70% { transform: scale(1.9); opacity: 0; } 100% { transform: scale(1.9); opacity: 0; } }
@keyframes diaRain { 0% { transform: translateY(-4px); opacity: 0; } 25% { opacity: 1; } 100% { transform: translateY(26px); opacity: 0; } }
@keyframes diaFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes diaGlow { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .dia-aviso, .dia-slab, .dia-ctx, .dia-find, .dia-vacio, .dia-aviso__ring, .dia-cloud, .dia-drop, .dia-ctx__ic svg, .dia-find__badge { animation: none; }
  /* La persiana pasa a un corte seco (spec §9): sin transición, el bloque
     entra o sale entero en el mismo frame que cambia aria-expanded. */
  .dia-aviso__chev, .dia-criticos-panel, .dia-ruta-panel { transition: none; }
}

/* ============================================================
   Pantalla Clima (`#/clima`) — a dónde lleva la etiqueta de clima de "Tu día".
   ============================================================ */
.clima-hero { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--sp-3); margin-top: var(--sp-2); padding: var(--sp-5) var(--sp-4); background: var(--surface); border: 1px solid var(--line); border-radius: 22px; }
.clima-hero__col { display: flex; flex-direction: column; min-width: 0; }
.clima-hero__ciudad { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: var(--muted); }
.clima-hero__temp { margin-top: 6px; font-size: 52px; font-weight: var(--fw-x); letter-spacing: -.03em; line-height: 1; color: var(--ink); }
.clima-hero__cond { margin-top: 8px; font-size: var(--fs-15); font-weight: var(--fw-bold); color: var(--ink-2); }
.clima-hero__detalle { margin-top: 2px; font-size: var(--fs-12-5); color: var(--muted); }
.clima-hero__ic { flex: none; margin-top: 4px; }

.clima-seclabel { margin: 0; font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: var(--muted); }
.clima-seclabel--llano { margin: 0; }

/* Tramos de 3 h en fila horizontal (scroll si no entran todos), con la hora
   REAL de cada uno — ver nota de honestidad arriba en clima.js. */
.clima-horas { margin-top: var(--sp-4); padding: var(--sp-3) var(--sp-3) var(--sp-4); background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.clima-horas__head { display: flex; align-items: baseline; justify-content: space-between; }
.clima-horas__hasta { font-size: var(--fs-12-5); color: var(--muted); }
.clima-horas__scroll { display: flex; gap: var(--sp-2); margin-top: var(--sp-3); overflow-x: auto; padding-bottom: 2px; }
.clima-hora { flex: none; display: flex; flex-direction: column; align-items: center; gap: 5px; width: 34px; }
.clima-hora__temp { font-size: var(--fs-13-5); font-weight: var(--fw-x); color: var(--ink); }
.clima-hora__pill { display: inline-flex; align-items: center; height: 19px; padding: 0 8px; border-radius: 999px; background: var(--green-dk); color: #fff; font-size: 10px; font-weight: var(--fw-x); white-space: nowrap; }
.clima-hora__lbl { font-size: var(--fs-12-5); color: var(--muted); }

/* Barras de probabilidad de lluvia, alineadas 1 a 1 con los tramos de
   `.clima-horas__scroll` (mismo array, mismo orden) — SIN scroll propio: se
   cortan a los mismos `TRAMOS_VISIBLES` que la fila de arriba para no
   desincronizar dos scrolls independientes. */
.clima-lluvia { margin-top: var(--sp-4); padding: 0 var(--sp-3); }
.clima-lluvia__bars { display: flex; align-items: flex-end; gap: var(--sp-2); height: 42px; overflow-x: auto; }
.clima-lluvia__bar { flex: none; width: 34px; border-radius: 6px 6px 2px 2px; background: #CBD8E4; }
.clima-lluvia__bar--pico { background: #3E7FB0; }
.clima-lluvia__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 7px; }
.clima-lluvia__pico { font-size: var(--fs-12-5); font-weight: var(--fw-semi); color: #3E7FB0; }

/* "Por esto te avisé": mismo aviso del slab de "Tu día" — ver `porEstoHTML`. */
.clima-porque { display: flex; align-items: flex-start; gap: 11px; width: 100%; margin-top: var(--sp-4); padding: var(--sp-3); background: #FBF3E2; border: 1px solid #EDDCB5; border-radius: 18px; text-decoration: none; color: inherit; }
.clima-porque__ic { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 999px; background: #F1E3C2; }
.clima-porque__body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.clima-porque__kicker { font-size: var(--fs-10-5); font-weight: var(--fw-x); letter-spacing: .13em; text-transform: uppercase; color: #8A6013; }
.clima-porque__tit { margin-top: 3px; font-size: var(--fs-15); font-weight: var(--fw-x); letter-spacing: -.015em; color: var(--ink); }
.clima-porque__txt { margin-top: 3px; font-size: var(--fs-12-5); line-height: 1.4; color: var(--ink-2); }
.clima-porque__chev { flex: none; margin-top: 7px; color: #8A6013; }

.clima-pie { display: flex; align-items: center; gap: 6px; margin-top: var(--sp-5); font-size: var(--fs-12-5); color: var(--muted); }

/* ---------------- WhatsApp precargado a un lugar del trámite ---------------
   Pantalla 4 del mockup "Patrón de trámite". La idea NO es fingir la UI de
   WhatsApp — es que el mensaje se vea como algo listo para mandar, editable
   y en el idioma de la app. La burbuja tira a verde soft (la marca de Nidu,
   no el verde WhatsApp) para que no parezca una captura del otro lado. */
.wa-lugar__head { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3); background: var(--surface-2); border-radius: var(--r-md); }
.wa-lugar__ic { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px; background: var(--green-soft); color: var(--green-dk); }
.wa-lugar__id { flex: 1; min-width: 0; }
.wa-lugar__nombre { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.wa-lugar__tel { margin-top: 2px; font-size: var(--fs-12-5); color: var(--ink-2); font-variant-numeric: tabular-nums; }

/* La burbuja lleva la sombra por debajo (`--sh-sm` sería demasiado plano) y una
   cola sutil abajo-izquierda, como un mensaje saliente pero SIN los colores de
   WhatsApp — no queremos que se confunda con una captura real. */
.wa-burbuja { position: relative; padding: 14px 16px; background: var(--green-soft); border-radius: 18px 18px 18px 6px; box-shadow: var(--sh-sm); }
.wa-burbuja__texto { width: 100%; min-height: 120px; padding: 0; background: transparent; border: 0; outline: none; resize: vertical; font: inherit; font-size: var(--fs-15); line-height: 1.5; color: var(--ink); }
.wa-burbuja__texto:focus-visible { outline: 2px solid var(--green); outline-offset: 6px; border-radius: 6px; }

/* ---------------- Pantalla celebratoria al cerrar un pendiente ----------------
   Mockup #8 del Patrón de trámite: círculo verde con check, título, subtítulo,
   nota opcional y tres CTAs apilados. Pintada como "reward moment" — el
   confeti la cubre pero la pantalla queda igual de leíble cuando termina. */
.resuelto-hero { display: flex; flex-direction: column; align-items: center; text-align: center; padding-top: var(--sp-5); }
.resuelto-hero__disco {
  display: grid; place-items: center;
  width: 96px; height: 96px; border-radius: 999px;
  background: var(--green-soft); color: var(--green-dk);
  box-shadow: 0 8px 24px -8px color-mix(in srgb, var(--green) 45%, transparent);
  animation: resuelto-pop 500ms cubic-bezier(.16,.9,.24,1.2) both;
}
.resuelto-hero__disco svg { width: 44px; height: 44px; }
.resuelto-hero__tit { margin-top: var(--sp-4); font-size: var(--fs-24); font-weight: var(--fw-black); color: var(--ink); letter-spacing: -.02em; }
.resuelto-hero__sub { margin-top: var(--sp-2); font-size: var(--fs-15); color: var(--ink); max-width: 34ch; }

@keyframes resuelto-pop {
  0%   { transform: scale(.6); opacity: 0; }
  60%  { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .resuelto-hero__disco { animation: none; }
}

/* ---------------- Bloque "Requisitos oficiales" de un trámite ----------------
   Mockup Trámite #2. Reemplaza el "Qué llevar" viejo dentro de `TramiteCard`.
   Comparte los stat tiles de `.stat-row` (arriba) y los renglones tildables
   (`ItemLlevar`), así que acá solo van el label + descripción y la caja
   informativa verde de "marcá cuáles ya tenés". */
.requisitos-oficiales { display: flex; flex-direction: column; gap: 4px; }
.requisitos-oficiales__label { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-11); font-weight: var(--fw-x); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.requisitos-oficiales__label svg { color: var(--green-dk); }
.requisitos-oficiales__sub { font-size: var(--fs-13); color: var(--ink-2); line-height: 1.4; }

.requisitos-info { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; background: var(--green-soft); border-radius: 14px; font-size: var(--fs-13); line-height: 1.45; color: var(--green-dk); }
.requisitos-info__ic { flex: none; display: grid; place-items: center; color: var(--green-dk); }
.requisitos-info strong { color: var(--green-dk); font-weight: var(--fw-x); }

/* ---------------- Interstitial "Nidu no agenda por vos" ----------------
   Mockup Trámite #5. Es una PARADA: la persona vino buscando algo (¿cómo
   agarro turno?) y la respuesta es "yo te ayudo, pero no lo hago yo". Por
   eso el ícono grande, un solo mensaje sin niveles, y un solo botón. */
.no-agendo { display: flex; flex-direction: column; align-items: center; text-align: center; padding: var(--sp-5) var(--sp-3) 0; }
.no-agendo__art {
  display: grid; place-items: center;
  width: 96px; height: 96px; border-radius: 999px;
  background: var(--info-bg); color: var(--info);
  margin-bottom: var(--sp-4);
}
.no-agendo__art svg { width: 44px; height: 44px; }
.no-agendo__tit { font-size: var(--fs-20); font-weight: var(--fw-x); line-height: 1.3; color: var(--ink); max-width: 32ch; }
.no-agendo__sub { margin-top: var(--sp-3); font-size: var(--fs-15); line-height: 1.5; color: var(--ink-2); max-width: 36ch; }
.no-agendo__cta { margin-top: var(--sp-6); width: 100%; max-width: 320px; }

/* Link chico al interstitial, arriba de la lista de lugares. Tinta info, sin
   fondo — no compite con las tarjetas ni parece un botón más. */
.no-agendo-link { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-12-5); color: var(--info); text-decoration: none; }
.no-agendo-link:hover { text-decoration: underline; }

/* ---------------- Recordar más tarde (rediseño mockup Trámite #7) ------------
   Mismo #recordarBox de siempre, con más aire y las cuatro piezas nuevas:
   picker nativo prominente arriba, tres chips atajo abajo, chips de canal
   INFORMATIVOS (link a /avisos para cambiarlos), textarea de nota local, y
   caja info verde al pie. La regla de fondo: no dibujar controles que la
   app no puede persistir de verdad (por eso los chips de canal NO son
   toggles — reflejan la preferencia global que ya está en /avisos). */
.recordar-cuando { display: flex; }
.recordar-cuando .input {
  flex: 1; min-height: 54px;
  font-size: var(--fs-16); font-weight: var(--fw-semi);
  text-align: center;
  padding-block: 0;
}

.recordar-canal__chips { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.recordar-canal__chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted);
  font-size: var(--fs-12-5); font-weight: var(--fw-semi);
  opacity: .55;
}
.recordar-canal__chip.is-on { background: var(--green-soft); color: var(--green-dk); opacity: 1; }
.recordar-canal__chip svg { color: currentColor; }
.recordar-canal__link { margin-left: auto; font-size: var(--fs-12-5); color: var(--green); text-decoration: none; }
.recordar-canal__link:hover { text-decoration: underline; }

.recordar-nota { min-height: 64px; resize: vertical; font-size: var(--fs-14); line-height: 1.4; }

.recordar-info { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; background: var(--green-soft); border-radius: 14px; font-size: var(--fs-13); line-height: 1.45; color: var(--green-dk); }
.recordar-info svg { flex: none; margin-top: 2px; color: currentColor; }

/* ============================================================
   Pantalla Seguimientos (`#/seguimientos`) — la lista de pendientes con
   seguimiento automático activo (vivienda + empleo). Salen de la Ruta
   principal por el mismo criterio que Futuros. Cada tarjeta muestra:
   vertical, frecuencia, cuánto falta para vencer y acciones.
   ============================================================ */
.sg-card { padding: var(--sp-4); background: var(--surface); border: 1px solid var(--line); border-radius: 18px; animation: sgCardIn .28s var(--ease-out) both; }
.sg-card__head { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-2); margin-bottom: var(--sp-2); }
.sg-card__chip { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 8px; background: var(--green-soft); color: var(--green); font-size: var(--fs-11-5); font-weight: var(--fw-x); }
.sg-card__meta { font-size: var(--fs-12-5); color: var(--muted); }
.sg-card__title { margin: 0; font-size: var(--fs-16); font-weight: var(--fw-x); letter-spacing: -.015em; color: var(--ink); }
.sg-card__title a { color: inherit; text-decoration: none; }
.sg-card__title a:hover { text-decoration: underline; }
.sg-card__row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3); margin-top: var(--sp-2); }
.sg-card__novedades, .sg-card__vence { display: inline-flex; align-items: center; gap: 5px; font-size: var(--fs-12-5); color: var(--ink-2); }
.sg-card__vence svg, .sg-card__novedades svg { flex: none; }
.sg-card__ext { margin: 6px 0 0; font-size: var(--fs-11-5); color: var(--muted); }
.sg-card__acts { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-3); }

@keyframes sgCardIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .sg-card { animation: none; }
}

/* ============================================================
   Mi lista de compras (paso 2 y 6 del board) + Recurrentes
   ============================================================ */

/* Cabecera: cada cuánto se repite, y si está activa. El selector es un
   <select> nativo y no un menú propio: es una elección de cuatro opciones que
   se hace una vez, y el nativo ya sabe abrirse bien en cualquier teléfono. */
.lista-cab { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.lista-frec {
  flex: 1; min-height: 44px; padding: 10px 14px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-pill); color: var(--ink);
  font: inherit; font-size: var(--fs-14); font-weight: var(--fw-x);
}
.lista-badge {
  flex: none; padding: 7px 13px; border-radius: var(--r-pill);
  background: var(--cat-recurrente-tint); color: var(--cat-recurrente-ink);
  font-size: var(--fs-12); font-weight: var(--fw-black);
}
/* Qué lista es. En una recurrente el tipo NO se edita —es su identidad, y
   editarlo se llevaba los productos a otra lista—, así que es una etiqueta y no
   un control: nada que invite a tocarlo. */
.lista-tipo {
  flex: 1; display: inline-flex; align-items: center; gap: 8px;
  min-height: 44px; padding: 10px 16px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-pill); color: var(--ink);
  font-size: var(--fs-14); font-weight: var(--fw-black);
}
.lista-tipo svg { flex: none; opacity: .7; }

/* Para qué es esta lista. Los tres tipos no se distinguen por su nombre solo
   —"De la semana" no dice que repite casi todo—, y esta línea es lo único que
   lo explica sin abrir nada. */
.lista-pista {
  margin: -6px 0 12px; padding: 0 2px;
  color: var(--ink-2); font-size: var(--fs-13);
}

/* La banda de estado: cuántos faltan, y que la lista sigue viva. */
.lista-estado {
  display: flex; align-items: flex-start; gap: 11px;
  padding: 13px 15px; margin-bottom: 14px;
  background: var(--cat-recurrente-tint); border-radius: var(--r-md);
  color: var(--cat-recurrente-ink);
}
.lista-estado svg { flex: none; margin-top: 1px; }
.lista-estado strong { display: block; font-size: var(--fs-14); font-weight: var(--fw-black); }
.lista-estado em { display: block; margin-top: 3px; font-style: normal; font-size: var(--fs-13); opacity: .85; }

/* Tabs. `--scroll` para la fila de Recurrentes, que puede tener varios. */
.tabs {
  display: flex; gap: 4px; padding: 4px; margin-bottom: 14px;
  background: var(--green-soft); border-radius: var(--r-pill);
}
.tabs--scroll { overflow-x: auto; scrollbar-width: none; }
.tabs--scroll::-webkit-scrollbar { display: none; }
.tab {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  flex: 1 0 auto; min-height: 40px; padding: 9px 16px;
  border: 0; border-radius: var(--r-pill); background: transparent;
  color: var(--green-dk); font: inherit; font-size: var(--fs-14);
  font-weight: var(--fw-x); white-space: nowrap; cursor: pointer;
}
.tab.is-active { background: var(--surface); font-weight: var(--fw-black); box-shadow: var(--sh-sm); }
.tab:active { transform: scale(.97); }

/* Un grupo de góndola. */
.lista-grupo { margin-bottom: 16px; }
.lista-grupo__tit {
  display: flex; align-items: center; gap: 8px; margin: 0 2px 8px;
  color: var(--muted); font-size: var(--fs-13); font-weight: var(--fw-black);
  text-transform: uppercase; letter-spacing: .02em;
}
.lista-grupo__tit em { font-style: normal; opacity: .7; }

/* Comprado / Pendiente, a la derecha del renglón (paso 6). */
.step__estado {
  flex: none; font-size: var(--fs-12); font-weight: var(--fw-black);
  color: var(--muted);
}
.step.is-done .step__estado { color: var(--green); }

/* "¿Cómo querés resolverla?" — tres filas, no una pantalla. */
.lista-resolver { margin-top: 18px; }
.fila-accion {
  display: flex; align-items: center; gap: 12px;
  min-height: 60px; padding: 12px 14px; margin-bottom: 8px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-md); color: var(--ink); text-decoration: none;
}
.fila-accion > svg:first-child { flex: none; color: var(--green-dk); }
.fila-accion > span { flex: 1; min-width: 0; }
.fila-accion strong { display: block; font-size: var(--fs-15); font-weight: var(--fw-x); }
.fila-accion em {
  display: block; margin-top: 2px; font-style: normal;
  font-size: var(--fs-13); color: var(--muted);
}
.fila-accion > svg:last-child { flex: none; color: var(--muted); }
.fila-accion:active { transform: scale(.99); }

/* La repesca: qué vuelve a entrar cuando la lista se dio vuelta.
   Todo llega tildado a propósito — el caso real es "sí, casi todo". */
.repesca__intro {
  display: flex; align-items: flex-start; gap: 9px;
  margin: 0 0 14px; color: var(--muted); font-size: var(--fs-14); line-height: 1.45;
}
.repesca__intro svg { flex: none; margin-top: 2px; color: var(--green-dk); }
.repesca__lista { list-style: none; margin: 0 0 16px; padding: 0; }
.repesca__op {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 12px; margin-bottom: 6px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-sm); cursor: pointer;
}
.repesca__op input { position: absolute; opacity: 0; pointer-events: none; }
.repesca__check {
  flex: none; width: 24px; height: 24px; border-radius: 8px;
  display: grid; place-items: center;
  border: 2px solid var(--step-ring); background: transparent; color: transparent;
}
.repesca__op input:checked ~ .repesca__check {
  border-color: var(--green); background: var(--green); color: #fff;
}
.repesca__op input:focus-visible ~ .repesca__check { outline: 3px solid var(--coral); outline-offset: 2px; }
.repesca__txt { font-size: var(--fs-15); font-weight: var(--fw-x); color: var(--ink); }
.repesca__pie { display: flex; gap: 9px; }
.repesca__pie .btn { flex: 1; }

/* La cantidad, al lado del producto. Va en gris y más chica: lo que se busca en
   la góndola es el NOMBRE; el "2 kg" se lee recién cuando ya lo encontraste. */
.step__cuanto {
  margin-left: 8px; font-style: normal;
  font-size: var(--fs-13); font-weight: var(--fw-black); color: var(--muted);
}
.step.is-done .step__cuanto { text-decoration: line-through; }

/* La fila de un producto: el tilde ocupa todo, el ⋮ va aparte a la derecha.
   Son dos botones hermanos porque uno dentro de otro no es HTML válido. */
.step-fila { display: flex; align-items: stretch; gap: 6px; }
.step-fila .step { flex: 1; min-width: 0; }
.step-fila.is-done .step__box { border-color: var(--green); background: var(--green); }
.step-fila.is-done .step__text { color: var(--muted); text-decoration: line-through; }
.step-fila.is-done .step__estado { color: var(--green); }
.step__menu {
  flex: none; width: 40px; border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); color: var(--muted); cursor: pointer;
  display: grid; place-items: center;
}
.step__menu:active { transform: scale(.95); }

/* El sheet del producto. */
.campo-bloque { display: block; margin-bottom: 14px; }
.campo-bloque__label {
  display: block; margin: 0 2px 6px;
  font-size: var(--fs-13); font-weight: var(--fw-black); color: var(--muted);
}
.campo-bloque__label em { font-style: normal; font-weight: var(--fw-x); opacity: .75; }
.item-menu__pie { display: flex; gap: 9px; margin-top: 18px; }
.item-menu__pie .btn { flex: 1; }
.item-menu__borrar { color: var(--coral); }

/* ---------------- Ficha de trámite con secciones desplegables ----------------
   Rediseño 6/8 (fundadora): la ficha de `/tramites/:id` pasa a secciones
   colapsables (`<details>`), para que la persona vea solo lo que le interesa
   consultar en cada momento. Antes era un scroll largo con todo abierto.
   El `<details>` nativo es accordion sin JS: funciona incluso si la app
   queda inerte por un bug de módulo. */

.tramite-head { display: flex; flex-direction: column; gap: 6px; }
.tramite-head__org {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 8px;
  padding: 4px 10px; background: var(--surface-2); border-radius: 999px;
  font-size: var(--fs-11); font-weight: var(--fw-x); letter-spacing: .08em;
  text-transform: uppercase; color: var(--ink-2);
  align-self: flex-start;
}
.tramite-head__org svg { color: var(--green-dk); }
.tramite-head__costo {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 6px;
  font-size: var(--fs-14); font-weight: var(--fw-x); color: var(--ink);
  align-self: flex-start;
}
.tramite-head__costo svg { color: var(--green-dk); }

.tramite-secciones { display: flex; flex-direction: column; gap: 8px; }

.tramite-sec {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  /* Sin marker nativo del <details>, dibujamos uno con chevron. */
}
.tramite-sec > summary { list-style: none; }
.tramite-sec > summary::-webkit-details-marker { display: none; }

.tramite-sec__summary {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px;
  cursor: pointer;
  user-select: none;
  color: var(--ink);
  font-weight: var(--fw-x);
  /* Sin focus-ring por defecto: al tocar en móvil el nativo se pinta feo. */
  outline: none;
}
.tramite-sec__summary:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: -2px;
  border-radius: var(--r-md);
}
.tramite-sec:hover { border-color: color-mix(in srgb, var(--line) 40%, var(--green) 60%); }
.tramite-sec[open] { background: var(--surface-2); }

.tramite-sec__ic { flex: none; display: grid; place-items: center; color: var(--green-dk); }
.tramite-sec__titulo { flex: 1; font-size: var(--fs-15); }
.tramite-sec__contador {
  flex: none; padding: 2px 8px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted);
  font-size: var(--fs-12); font-weight: var(--fw-semi);
}
.tramite-sec[open] .tramite-sec__contador { background: var(--surface); }
.tramite-sec__chev {
  flex: none; display: grid; place-items: center;
  color: var(--muted);
  transition: transform 180ms var(--ease-out, ease-out);
  transform: rotate(0deg);
}
/* Chevron apunta abajo cuando el desplegable está cerrado, arriba cuando
   está abierto — la rotación indica "esto se pliega/despliega". */
.tramite-sec > summary .tramite-sec__chev { transform: rotate(90deg); }
.tramite-sec[open] > summary .tramite-sec__chev { transform: rotate(-90deg); }

.tramite-sec__body {
  padding: 4px 16px 16px;
  border-top: 1px solid var(--line);
  animation: tramite-sec-in 200ms var(--ease-out, ease-out);
}
@keyframes tramite-sec-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .tramite-sec__chev { transition: none; }
  .tramite-sec__body { animation: none; }
}

.tramite-sec__primer-paso { font-size: var(--fs-15); line-height: 1.5; margin-top: 12px; }
.tramite-sec__pasos { margin: 12px 0 0; padding-left: 20px; font-size: var(--fs-14); line-height: 1.55; }
.tramite-sec__pasos li + li { margin-top: 6px; }
.tramite-sec__tips { margin: 12px 0 0; padding-left: 20px; font-size: var(--fs-14); line-height: 1.55; color: var(--ink-2); list-style: none; }
.tramite-sec__tips li { position: relative; padding-left: 4px; }
.tramite-sec__tips li + li { margin-top: 8px; }
.tramite-sec__tips li::before { content: "✨"; position: absolute; left: -18px; top: 0; }

/* Pie de la ficha (botones al final). Cada botón ocupa su fila para no
   competir entre sí — son cuatro accesos alternativos, no un flujo. */
.tramite-final { display: flex; flex-direction: column; gap: 10px; }
