/* Muuch — invitación a poner la app en el inicio (PWA).
   Usa los tokens de /dashboard/styles.css (el panel y la caja los comparten);
   los respaldos sólo cubren que el archivo cargue solo. */

.pwa-offer {
  background: var(--surface, #fff);
  border-bottom: 1px solid var(--border, #e4e7ec);
}
.pwa-offer[hidden] { display: none; }
.pwa-offer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 12px 20px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: 14px;
  row-gap: 10px;
}
.pwa-icon {
  width: 44px; height: 44px; border-radius: 11px;
  box-shadow: 0 0 0 1px rgba(14, 37, 51, .08), 0 1px 2px rgba(14, 37, 51, .12);
  display: block;
}
.pwa-copy { min-width: 0; }
.pwa-title {
  margin: 0; font-size: 15px; line-height: 1.25; font-weight: 650;
  letter-spacing: -.01em; color: var(--navy, #0e2533); text-wrap: balance;
}
.pwa-sub {
  margin: 2px 0 0; font-size: 13px; line-height: 1.4; color: var(--muted, #667085);
  letter-spacing: .005em; text-wrap: pretty;
}
.pwa-actions { display: flex; align-items: center; gap: 4px; }
.pwa-actions .btn { min-height: 44px; padding-inline: 18px; }
.pwa-later {
  appearance: none; background: none; border: 0; cursor: pointer;
  min-height: 44px; padding: 0 12px; border-radius: 9px;
  font: inherit; font-size: 13px; font-weight: 600; color: var(--muted, #667085);
  touch-action: manipulation;
  transition: background-color .12s ease, transform .1s ease;
}
.pwa-later:hover { background: rgba(14, 37, 51, .05); }
.pwa-later:active { transform: scale(.96); background: rgba(14, 37, 51, .08); }

@media (max-width: 520px) {
  .pwa-offer-inner { padding: 12px 16px; grid-template-columns: auto 1fr; }
  .pwa-actions { grid-column: 1 / -1; }
  .pwa-actions .btn { flex: 1; }
}

/* ---------- Hoja de pasos (iPhone) ---------- */
.pwa-scrim {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(14, 37, 51, .42);
  opacity: 0; transition: opacity .28s cubic-bezier(.22, 1, .36, 1);
}
.pwa-scrim.is-open { opacity: 1; }
.pwa-sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 91;
  max-width: 520px; margin: 0 auto;
  background: var(--surface, #fff);
  border-radius: 20px 20px 0 0;
  padding: 8px 20px max(20px, env(safe-area-inset-bottom));
  box-shadow: 0 -8px 32px rgba(14, 37, 51, .18), 0 -1px 0 rgba(14, 37, 51, .06);
  transform: translateY(100%);
  transition: transform .42s cubic-bezier(.22, 1, .36, 1);
  will-change: transform;
  outline: none;
}
.pwa-sheet.is-open { transform: translateY(0); }
.pwa-sheet.is-dragging { transition: none; }
.pwa-grab {
  /* Toda la franja de arriba se puede agarrar, no sólo la rayita. */
  display: block; width: 100%; height: 28px; padding: 0; border: 0; background: none;
  cursor: grab; touch-action: none;
  position: relative;
}
.pwa-grab::after {
  content: ""; position: absolute; left: 50%; top: 10px; width: 36px; height: 5px;
  margin-left: -18px; border-radius: 3px; background: var(--border, #e4e7ec);
}
.pwa-sheet h2 {
  margin: 0 0 4px; font-size: 21px; line-height: 1.15; letter-spacing: -.02em;
  font-weight: 700; color: var(--navy, #0e2533); text-wrap: balance;
}
.pwa-sheet > p { margin: 0 0 14px; font-size: 14px; color: var(--muted, #667085); text-wrap: pretty; }
.pwa-steps { list-style: none; margin: 0 0 16px; padding: 0; }
.pwa-steps li {
  display: grid; grid-template-columns: 40px 1fr; column-gap: 14px; align-items: center;
  padding: 12px 0;
}
.pwa-steps li + li { border-top: 1px solid var(--border, #e4e7ec); }
.pwa-step-ico {
  width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--brand, #ff558a) 12%, #fff);
  color: var(--brand-deep, #d6246a);
}
.pwa-step-ico svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pwa-step-text { font-size: 15px; line-height: 1.35; font-weight: 600; color: var(--navy, #0e2533); letter-spacing: -.005em; }
.pwa-step-text small { display: block; margin-top: 2px; font-size: 13px; font-weight: 500; color: var(--muted, #667085); letter-spacing: .005em; }
.pwa-note {
  margin: 0 0 16px; padding: 10px 12px; border-radius: 10px; font-size: 13px; line-height: 1.45;
  background: var(--warn-bg, #fffaeb); color: var(--warn, #b54708);
}
.pwa-sheet .btn { width: 100%; min-height: 48px; }

/* Con "reducir movimiento": sin deslizar; aparece y desaparece con un fundido. */
@media (prefers-reduced-motion: reduce) {
  .pwa-scrim { transition: opacity .15s linear; }
  .pwa-sheet { transform: none; opacity: 0; transition: opacity .15s linear; }
  .pwa-sheet.is-open { opacity: 1; }
  .pwa-later:active { transform: none; }
}
/* Con "reducir transparencia" / "más contraste": el fondo sólido, sin sombra suave. */
@media (prefers-contrast: more) {
  .pwa-scrim { background: rgba(14, 37, 51, .7); }
  .pwa-sheet { box-shadow: 0 0 0 2px var(--navy, #0e2533); }
  .pwa-sub, .pwa-sheet > p, .pwa-step-text small { color: var(--navy, #0e2533); }
}
