/* ⏳ The sync cover (marmot-sync-cover.js; a kit file, the same bytes in every Flying Marmot app). While the app's
   load or catch-up is on its way: the grey backdrop of a modal over the whole page (the page faintly under it), a
   small white card in the middle (white in dark mode too: Jared asked for white) with a spinner in the app's colour
   (--msc-accent, else --accent). data-msc="wait": on but not drawn yet (the first 250 ms: taps caught, nothing seen);
   "show": drawn. */
.msc-cover {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  pointer-events: auto;
  touch-action: none;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.msc-cover[hidden] { display: none; }
.msc-cover[data-msc="show"] {
  background: rgba(16, 24, 40, .45);
  animation: msc-in .16s ease-out;
}
.msc-card {
  display: none;
  align-items: center;
  justify-content: center;
  width: 88px;
  height: 88px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(16, 24, 40, .22), 0 2px 6px rgba(16, 24, 40, .12);
}
.msc-cover[data-msc="show"] .msc-card { display: flex; animation: msc-pop .18s ease-out; }
.msc-spin {
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 4px solid color-mix(in srgb, var(--msc-accent, var(--accent, #4b5563)) 22%, #e5e7eb);
  border-top-color: var(--msc-accent, var(--accent, #4b5563));
  animation: msc-spin .8s linear infinite;
}
.msc-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.msc-toast {
  position: fixed;
  left: 50%;
  bottom: calc(1.2rem + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%);
  z-index: 2147483001;
  max-width: calc(100vw - 2rem);
  padding: .6rem .95rem;
  border-radius: 999px;
  background: #1f2937;
  color: #ffffff;
  font: 600 .88rem/1.3 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  box-shadow: 0 8px 24px rgba(16, 24, 40, .25);
}
.msc-toast[hidden] { display: none; }
@keyframes msc-spin { to { transform: rotate(360deg); } }
@keyframes msc-in { from { background: transparent; } }
@keyframes msc-pop { from { opacity: 0; transform: scale(.94); } }
@media (prefers-reduced-motion: reduce) {
  .msc-cover[data-msc="show"], .msc-cover[data-msc="show"] .msc-card { animation: none; }
  .msc-spin { animation-duration: 1.6s; }
}
