/* Hallmark · component: module switch (double-tap Menu) · genre: modern-minimal · theme: existing tokens · states: n/a (cover and bar are not interactive) · contrast: pass · v2.0.0 */
/* critique: reuse what both modules already show (the loading look, Client Progress's bottom bar), so the switch reads as one app */
/* waive 7b · white text on the bar is Client Progress's --pg-paper on its #toast, copied exactly */
/* The bottom bar copies Client Progress's #toast exactly; the cover uses each page's own --bg-base. */
:root {
  --module-switch-bar: #171923;
  --module-switch-bar-ink: #ffffff;
  --module-switch-bar-muted: #c9ccd6;
  --module-switch-shadow: 0 8px 24px rgb(10 12 18 / 0.14);
}

/* A second tap must be a click, never a zoom (Leads' and Progress's Menu buttons). */
#bottomNavHamburger, #nav-menu { touch-action: manipulation; }

.module-switch-cover, .pg-loading.module-switch-boot {
  position: fixed; inset: 0; z-index: 10001;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-base);
}
/* Client Progress's start-up loader, when arriving from a switch, sits where the cover does. */
.pg-loading.module-switch-boot { flex-direction: column; }

.module-switch-toast {
  position: fixed; z-index: 10002;
  bottom: 32px; right: 32px;
  display: flex; flex-direction: column; gap: 2px;
  max-width: min(480px, calc(100% - 32px));
  padding: 12px 20px; border-radius: 8px;
  background: var(--module-switch-bar); color: var(--module-switch-bar-ink);
  font-size: 14px; box-shadow: var(--module-switch-shadow);
}
.module-switch-toast strong { font-weight: 500; }
.module-switch-toast small { font-size: 12px; color: var(--module-switch-bar-muted); }

/* Phones: centred just above the bottom nav, like Client Progress's bar. */
@media (max-width: 768px) {
  .module-switch-toast {
    left: 16px; right: 16px; width: fit-content; max-width: none; margin-inline: auto;
    bottom: calc(80px + env(safe-area-inset-bottom));
  }
}
