/* ieGlobal CRM ? Apple macOS dark */

:root {
  color-scheme: dark;
  --bg: #000000;
  --bg-elevated: #1c1c1e;
  --bg-elevated-2: #2c2c2e;
  --surface: rgba(28, 28, 30, 0.78);
  --surface-solid: #1c1c1e;
  --ink: #f5f5f7;
  --ink-secondary: #ebebf5;
  --muted: #aeaeb2;
  --line: rgba(255, 255, 255, 0.07);
  --line-strong: rgba(255, 255, 255, 0.10);
  --accent: #0a84ff;
  --accent-press: #409cff;
  --ok: #30d158;
  --warn: #ffd60a;
  --danger: #ff453a;
  /* Document / activity type marks ? ONE SoT for Timeline, Accounts, Insights, hub. */
  --doc-invoice: #0a84ff;
  --doc-payment: #30d158;
  --doc-credit: #ff453a;
  --doc-debit: #ff9f0a;
  --doc-quote: #0ea5e9;
  --doc-order: #6366f1;
  --doc-credit-req: #eab308;
  --doc-form: #a855f7;
  --doc-task: #f59e0b;
  --doc-task-done: #22c55e;
  --doc-visit: #10b981;
  --doc-comment: #3b82f6;
  --doc-complaint: #ef4444;
  --doc-merch: #f97316;
  --doc-stock: #06b6d4;
  --doc-contact: #14b8a6;
  --doc-note: #64748b;
  /* Catalogue stock status ? OUT=red, LOW=orange, IN=green (never share the same hue) */
  --stock-in: #30d158;
  --stock-low: #ff9f0a;
  --stock-out: #ff453a;
  /* Quiet, high-end depth ? soft ambient shadow, no heavy drop-shadow bulk.
     No sub-pixel hairline ring here ? compositors render those as visible
     grain/speckle on large flat surfaces (catalogue cards etc). */
  --shadow: 0 6px 20px rgba(0, 0, 0, 0.32);
  --radius: 20px;
  --radius-sm: 12px;
  --font: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue",
    Helvetica, Arial, sans-serif;
  --fw: 400;
  --fw-med: 500;
  --fw-semi: 540;
  --fw-strong: 600;
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  /* iOS sheet / modal motion ? subtle spring, not bounce-noise. */
  --ease-sheet: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-modal: cubic-bezier(0.2, 0.8, 0.2, 1);
  --dur-sheet: 0.34s;
  --dur-modal: 0.22s;
  /* Phone chrome condense + cross-step nav (crm531). */
  --dur-condense: 0.26s;
  --dur-nav: 0.16s;
  /* crm551 Wave1 ? shared press / state motion (aligns with sheet/nav). */
  --dur-micro: 120ms;
  --dur-state: 200ms;
  --ease-press: cubic-bezier(0.2, 0.8, 0.2, 1);
  --sheet-top-radius: 18px;
  /* Button design system - shared by Home / Calendar / Customers / Tasks /
     Settings / Admin / Forms. CTAs use squircle (~12px) on phone + PC. */
  --btn-radius: var(--radius-sm);
  --btn-radius-seg: 10px;
  --btn-radius-seg-item: 8px;
  --btn-h: 44px;
  --btn-h-sm: 34px;
  --btn-pad-y: 12px;
  --btn-pad-x: 18px;
  --btn-fs: 0.95rem;
  --btn-fs-sm: 0.8125rem;
  --btn-icon-size: 32px;
  --btn-icon-radius: 9px;
  --btn-primary-bg: linear-gradient(
    180deg,
    color-mix(in srgb, var(--accent) 88%, #fff 12%),
    var(--accent) 52%,
    color-mix(in srgb, var(--accent) 90%, #000 10%)
  );
  --btn-primary-bg-hover: linear-gradient(
    180deg,
    color-mix(in srgb, var(--accent-press) 86%, #fff 14%),
    var(--accent-press) 52%,
    color-mix(in srgb, var(--accent-press) 88%, #000 12%)
  );
  --btn-primary-border: color-mix(in srgb, var(--accent) 72%, #000 28%);
  /* crm356: less blue bloom, more neutral depth ? a real lifted slab reads
     "premium", a colored glow reads "neon banner ad". Blue kept only as a
     faint rim, black carries the actual depth. */
  --btn-primary-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 1px 2px rgba(0, 0, 0, 0.36),
    0 6px 16px rgba(0, 0, 0, 0.28),
    0 2px 6px rgba(10, 132, 255, 0.14);
  --btn-primary-shadow-hover:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 1px 2px rgba(0, 0, 0, 0.38),
    0 8px 20px rgba(0, 0, 0, 0.32),
    0 3px 8px rgba(10, 132, 255, 0.18);
  /* Elevated variant ? floating/sticky primary CTAs (Home + hub "Start a
     visit") that sit above content instead of inline in a form/list. */
  --btn-primary-shadow-elevated:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 10px 26px rgba(0, 0, 0, 0.4),
    0 3px 10px rgba(10, 132, 255, 0.16);
  /* Shared lift while dragging (reorder + sheet pull). crm804: loud in-hand. */
  --crm-drag-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.32),
    0 0 0 2.5px var(--accent, #0a84ff),
    0 28px 56px rgba(0, 0, 0, 0.92),
    0 12px 28px rgba(10, 132, 255, 0.55),
    0 4px 10px rgba(0, 0, 0, 0.55);
  --crm-drag-armed-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.26),
    0 0 0 2px var(--accent, #0a84ff),
    0 14px 28px rgba(0, 0, 0, 0.65),
    0 4px 12px rgba(10, 132, 255, 0.35);
  --crm-drag-scale: 1.045;
  --crm-drag-bg: var(--surface-elevated, var(--bg-elevated-2, #2c2c2e));
  --crm-drag-peer-opacity: 0.45;
  --btn-ghost-bg: var(--bg-elevated-2);
  --btn-ghost-border: var(--line-strong);
  --btn-ghost-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  --btn-focus-ring: 0 0 0 3px rgba(10, 132, 255, 0.24);
  --btn-seg-track: #2c2c2e;
  /* crm854: ONE selected language for segs + chips — light blue (Gen gold),
     never grey elevated #636366. Same solid as --btn-chip-on-bg. */
  --btn-seg-on: color-mix(in srgb, var(--accent) 94%, #fff 6%);
  /* Solid (not a gradient) ? reused inside color-mix() elsewhere (cart deal
     badges/rows), which requires a <color>, not an <image>. */
  --btn-chip-on-bg: color-mix(in srgb, var(--accent) 94%, #fff 6%);
  --btn-chip-on-border: color-mix(in srgb, var(--accent) 72%, #000 28%);
  --btn-chip-radius: var(--radius-sm);
  --btn-chip-on-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 1px 2px rgba(0, 0, 0, 0.25),
    0 2px 8px rgba(10, 132, 255, 0.14);
  --btn-seg-on-shadow: var(--btn-chip-on-shadow);
  /* Disabled ? visible grey (cart On-site), not ghost opacity-only */
  --btn-disabled-opacity: 0.45;
  --btn-disabled-fg: rgba(235, 235, 245, 0.42);
  --btn-disabled-bg: rgba(58, 58, 60, 0.55);
  /* Bottom-nav active icon wash ? one token instead of two hand-copied rgba washes. */
  --btn-nav-active-bg: rgba(10, 132, 255, 0.15);
  /* Quiet icon idle ? chips / hub-act glyphs (not full ink) */
  --crm-ico-idle-opacity: 0.8;
  /* MapLibre ? Customers Map + Near me (red pins / coral clusters; you-marker stays cyan) */
  --map-pin: #ea4335;
  --map-pin-soft: #ff6961;
  --map-pin-deep: #c5221f;
  --map-pin-halo: #ff8a80;
  --map-pin-active: #ff453a;
  --map-you-soft: #64d2ff;
  --map-cluster-halo: color-mix(in srgb, var(--map-pin-halo) 30%, transparent);
  --map-frame-glow: color-mix(in srgb, var(--map-pin) 12%, transparent);
  /* Smart rail ? Calendar Filter language shared by side-nav, hub rails,
     fold panels, More sheet chrome (see docs/UI_SIDEBARS.md). */
  --rail-bg: linear-gradient(180deg, rgba(28, 28, 32, 0.98), rgba(18, 18, 22, 0.98));
  --rail-line: rgba(255, 255, 255, 0.08);
  --rail-section-line: rgba(255, 255, 255, 0.07);
  --rail-lab: rgba(235, 235, 245, 0.45);
  --rail-lab-active: rgba(235, 235, 245, 0.78);
  --rail-pad-y: 12px;
  --rail-pad-x: 12px;
  --rail-radius: var(--radius-sm);
  --rail-link-radius: 10px;
  --rail-fold-min-h: 34px;
  /* Shared PC rail track width ? Calendar Filter / Nav / hub / Categories */
  --rail-width: 260px;
  --rail-width-min: 240px;
  --rail-width-max: 280px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  min-height: 100%;
  min-height: 100dvh;
  font-family: var(--font);
  font-weight: var(--fw);
  letter-spacing: 0.005em;
  line-height: 1.45;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Shell owns vertical scroll (.app-body). Prevent document rubber-banding
     from fighting the fixed app-shell on iOS Safari. */
  overflow: hidden;
}

button, input, select, textarea {
  font: inherit;
  font-weight: var(--fw-med);
  color: inherit;
}

h1, h2, h3, h4, strong, b {
  font-weight: var(--fw-strong);
}

html {
  height: 100%;
}
html, body, #app {
  height: 100%;
  min-height: 100%;
  min-height: 100dvh;
}
#app {
  /* Flat black ? soft radial washes dither into grainy bands on Safari/macOS. */
  background: var(--bg);
  height: 100%;
  min-height: 100%;
  min-height: 100dvh;
  position: relative;
}


/* ?? App chrome: ONE model ? PC top nav | Phone header + fixed bottom tabs ?? */
:root {
  --shell-pad-x: 16px;
  /* PC hubs: fill shell width (crm275 maximize / no centered gutters); phone unaffected */
  --hub-max: 100%;
  --hdr-h: 56px;
  --hdr-logo-h: 44px;
  --hdr-logo-w: 176px;
  --hdr-nav-fs: 0.82rem;
  --hdr-nav-pad-y: 8px;
  --hdr-nav-pad-x: 9px;
  --hdr-gap-y: 8px;
  --bottom-nav-h: 0px;
  /* Same surface as the phone header (#121214) - opaque, no backdrop sampling.
     Kept: fixed/sticky Safari chrome must not sample scrolled content
     (see .app-header / .shop-chrome / .sky-hub-tabs-sticky lesson). */
  --bottom-nav-bg: #121214;
  --shop-dock-h: 80px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  /* Bottom sheets: last option row clears fixed bottom nav (Wave 1 P0). */
  --sheet-nav-clear: calc(16px + var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px));
}
/* A stray double-tap used to leave the whole CRM zoomed. While iOS is zoomed,
   position:fixed anchors to the LAYOUT viewport, so the bottom nav and modal
   backdrops render short of the screen edge with content spilling past them -
   the long-running "floating tab bar" report. `manipulation` drops double-tap
   zoom while leaving pinch-zoom (accessibility) and scrolling untouched. */
html,
body {
  touch-action: manipulation;
}
/* Shell IS the screen: fixed to the visual viewport, chrome as flex children.
   Do not rely on position:fixed bottom-nav resolving against the layout viewport
   (iOS Safari leaves a dead band under collapsed browser chrome). */
.app-shell {
  position: fixed;
  inset: 0;
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 0 var(--shell-pad-x) 0;
  height: 100%;
  height: 100dvh;
  max-height: 100%;
  max-height: 100dvh;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.app-shell.screen {
  padding: 0 var(--shell-pad-x) 0;
  max-width: none;
  width: 100%;
  margin-left: 0;
  margin-right: 0;
  animation: none !important;
}
.app-shell.wide,
.app-shell.screen.wide {
  max-width: none;
  width: 100%;
}
.app-shell.shop-screen,
.app-shell.screen.shop-screen {
  max-width: none;
  width: 100%;
  padding: 0 var(--shell-pad-x) 0;
}
.app-shell.has-bottom-nav {
  --bottom-nav-h: 56px;
  /* Nav is an in-flow flex child ? no phantom padding-bottom. */
}
/* PC desk escape (?desk=1): bottom nav hidden ? no phantom token. */
body:not(.shell-phone) .app-shell.has-bottom-nav {
  --bottom-nav-h: 0px;
}
.app-header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0 14px;
  box-sizing: border-box;
  height: calc(var(--hdr-h) + var(--safe-top));
  min-height: calc(var(--hdr-h) + var(--safe-top));
  max-height: calc(var(--hdr-h) + var(--safe-top));
  padding: var(--safe-top) var(--shell-pad-x) 0;
  /* Full-bleed bar inside padded shell */
  width: calc(100% + 2 * var(--shell-pad-x));
  margin: 0 calc(-1 * var(--shell-pad-x)) var(--hdr-gap-y);
  min-width: 0;
  flex: 0 0 auto;
  /* Outside the scrollport (sibling of .app-body) ? not sticky. */
  position: relative;
  top: auto;
  z-index: 200;
  /* Solid only ? Safari paints sticky + backdrop-filter as jagged
     grey/black noise bands (top/bottom/right edge). Same lesson as .shop-chrome. */
  background: #0b0b0d;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transform: none;
  will-change: auto;
  border-bottom: 1px solid var(--line-strong);
  view-transition-name: crm-header;
}
/* Smooth screen changes ? keep header visually stable */
::view-transition-old(crm-header),
::view-transition-new(crm-header) {
  animation: none;
  mix-blend-mode: normal;
  height: 100%;
}
::view-transition-group(crm-header) {
  animation-duration: 0.01ms;
}
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: var(--dur-nav, 0.16s);
  animation-timing-function: var(--ease);
}
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation: none;
  }
}
/* Cross-step nav fallback when View Transitions API is unavailable. */
.app-content.crm-nav-fade,
#app.crm-nav-fade {
  transition: opacity var(--dur-nav, 0.16s) var(--ease);
}
.app-content.crm-nav-fade-out,
#app.crm-nav-fade-out {
  opacity: 0;
}
@media (prefers-reduced-motion: reduce) {
  .app-content.crm-nav-fade,
  #app.crm-nav-fade,
  .app-content.crm-nav-fade-out,
  #app.crm-nav-fade-out {
    transition: none !important;
    opacity: 1 !important;
  }
}
.app-header-brand {
  min-width: max-content;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  height: 100%;
}
.logo-home-btn {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  cursor: pointer;
  border-radius: 8px;
  line-height: 0;
  display: flex;
  align-items: center;
  height: var(--hdr-logo-h);
}
.logo-home-btn:hover { opacity: 0.92; }
.logo-home-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
/* Locked logo size ? wins over legacy .logo-bar / shop / compact rules */
.app-header .logo-bar,
.app-header .logo-bar-compact,
.app-shell.shop-screen .app-header .logo-bar {
  display: block;
  height: var(--hdr-logo-h) !important;
  width: auto;
  max-width: var(--hdr-logo-w) !important;
  object-fit: contain;
  object-position: left center;
  pointer-events: none;
  filter: none;
}
.cart-chip {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  min-height: var(--btn-h-sm);
  border-radius: var(--btn-chip-radius);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  flex: 0 0 auto;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.cart-chip:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
}
.cart-chip-lab {
  color: var(--muted);
  letter-spacing: -0.01em;
}
.cart-chip-n {
  min-width: 1.25em;
  max-width: none;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  display: inline;
  place-items: unset;
  font-variant-numeric: tabular-nums;
  font-size: 0.85rem;
  font-weight: var(--fw-semi);
  color: var(--accent);
  line-height: 1;
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
}
.main-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  /* Center titles+icons in the middle header column (logo stays left; Timeline+Settings right). */
  justify-content: center;
  gap: 0;
  min-width: 0;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0;
}
.main-nav::-webkit-scrollbar { display: none; }
.main-nav-link {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(245, 245, 247, 0.72);
  font: inherit;
  font-size: var(--hdr-nav-fs);
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  padding: 0 var(--hdr-nav-pad-x);
  border-radius: 0;
  cursor: pointer;
  white-space: nowrap;
  flex: 0 0 auto;
  flex-shrink: 0;
  min-width: max-content;
  overflow: visible;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: inset 0 -3px 0 transparent;
  transition: color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.main-nav-lab {
  display: inline-block;
  flex: 0 0 auto;
  min-width: max-content;
  overflow: visible;
  white-space: nowrap;
}
.main-nav-link:hover {
  background: transparent;
  color: #fff;
}
.main-nav-link.is-active {
  background: transparent;
  color: #fff;
  font-weight: var(--fw-med);
  box-shadow: inset 0 -2px 0 var(--accent);
}
/* Micro icon ? deliberately understated (14px, dimmed) so the label still
   carries the top nav; is-active/hover just brighten via currentColor. */
.main-nav-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.75;
  transition: opacity 0.15s var(--ease);
}
.main-nav-ico svg {
  width: 14px;
  height: 14px;
  display: block;
}
.main-nav-link:hover .main-nav-ico,
.main-nav-link.is-active .main-nav-ico {
  opacity: 1;
}
/* Narrow desktop (small laptops) ? up to ~10 top-nav items can crowd against the
   logo/session controls before .main-nav's own horizontal scroll kicks in.
   Tighten spacing only in this band; phone shell (?900 / main-nav hidden) unaffected.
   PC body overrides below keep the same density via --hdr-nav-* tokens. */
/* Leave-guard modal ? shared iOS confirm/prompt chrome */
.crm-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: auto;
  width: 100%;
  height: 100%;
  height: 100dvh;
  z-index: 500;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  display: grid;
  place-items: center;
  padding: 20px;
  /* Shared sheet clear ? confirm/prompt/form sheets clear fixed bottom nav */
  padding-bottom: max(20px, var(--sheet-nav-clear, 20px));
  box-sizing: border-box;
  animation: crmBackdropIn var(--dur-modal, 0.22s) var(--ease-modal, var(--ease)) both;
}
/* Inside the fixed shell: fill the shell box (covers the full visual screen). */
.app-shell > .crm-modal-backdrop {
  position: absolute;
  inset: 0;
  width: auto;
  height: auto;
}
.crm-modal {
  width: min(400px, 100%);
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
  max-height: min(80dvh, 640px);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--bg-elevated, #1c1c1e);
  border: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  border-radius: var(--radius-sm, 12px);
  padding: 22px 20px 18px;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.48),
    var(--btn-ghost-shadow, inset 0 1px 0 rgba(255, 255, 255, 0.04));
  animation: crmModalIn var(--dur-modal, 0.22s) var(--ease-modal, var(--ease)) both;
  will-change: transform, opacity;
}
.crm-modal-kicker {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: var(--fw-strong);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.crm-modal h2 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}
.crm-modal-body {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}
.crm-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}
.crm-modal-actions .btn { min-width: 88px; }
@keyframes crmBackdropIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes crmModalIn {
  from { opacity: 0; transform: scale(0.94) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Premium send-to-office busy (in-flight) */
.crm-send-busy-back {
  z-index: 525;
  pointer-events: auto;
  cursor: wait;
}
.crm-send-busy {
  text-align: center;
  width: min(360px, 100%);
  padding-top: 28px;
  padding-bottom: 22px;
}
.crm-send-busy-orb {
  position: relative;
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
}
.crm-send-busy-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid color-mix(in srgb, var(--accent) 18%, transparent);
  border-top-color: color-mix(in srgb, var(--accent) 95%, transparent);
  border-right-color: rgba(94, 92, 230, 0.55);
  animation: crm-send-busy-spin 0.9s linear infinite;
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 6%, transparent);
}
.crm-send-busy-core {
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  background: radial-gradient(
    circle at 35% 30%,
    color-mix(in srgb, var(--accent) 45%, transparent),
    color-mix(in srgb, var(--accent) 8%, transparent) 55%,
    transparent 70%
  );
  box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 35%, transparent);
  animation: crm-send-busy-pulse 1.4s ease-in-out infinite;
}
.crm-send-busy-kicker {
  color: var(--accent, #0a84ff);
  text-align: center;
}
.crm-send-busy h2 {
  text-align: center;
  margin-bottom: 6px;
  font-size: 1.15rem;
}
.crm-send-busy-sub {
  text-align: center;
  margin-bottom: 16px;
  font-size: 0.86rem;
}
.crm-send-busy-track {
  height: 3px;
  border-radius: var(--btn-radius);
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.crm-send-busy-bar {
  height: 100%;
  width: 42%;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, var(--accent, #0a84ff), rgba(94, 92, 230, 0.85), transparent);
  animation: crm-send-busy-slide 1.35s ease-in-out infinite;
}
@keyframes crm-send-busy-spin {
  to { transform: rotate(360deg); }
}
@keyframes crm-send-busy-pulse {
  0%, 100% { opacity: 0.55; transform: scale(0.92); }
  50% { opacity: 1; transform: scale(1); }
}
@keyframes crm-send-busy-slide {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(280%); }
}

/* Premium send-to-office success */
.crm-send-success {
  text-align: center;
  width: min(420px, 100%);
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
}
.crm-send-success-badge {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: linear-gradient(145deg, rgba(52, 199, 89, 0.28), rgba(52, 199, 89, 0.08));
  border: 1px solid rgba(52, 199, 89, 0.35);
  color: #30d158;
}
.crm-send-success.is-warn .crm-send-success-badge {
  background: linear-gradient(145deg, rgba(255, 159, 10, 0.28), rgba(255, 159, 10, 0.08));
  border-color: rgba(255, 159, 10, 0.4);
  color: #ff9f0a;
}
.crm-send-success-check { display: block; }
.crm-send-success-kicker { text-align: center; }
.crm-send-success h2 { text-align: center; }
.crm-send-success-meta {
  display: grid;
  gap: 8px;
  margin: 14px 0 12px;
  padding: 12px 14px;
  text-align: left;
  border-radius: var(--btn-chip-radius, 12px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}
.crm-send-success-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 8px 12px;
  min-width: 0;
}
.crm-send-success-key {
  font-size: 0.72rem;
  font-weight: var(--fw-strong, 600);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 0.2em;
}
.crm-send-success-val {
  min-width: 0;
  text-align: right;
  font-size: 0.95rem;
  font-weight: var(--fw-strong, 600);
  color: var(--text, #f5f5f7);
  overflow-wrap: anywhere;
  word-break: break-word;
  line-height: 1.35;
}
.crm-send-success-mon.is-ok { color: #30d158; }
.crm-send-success-mon.is-missing { color: #ff9f0a; }
.crm-send-success-mon.is-local { color: #ff9f0a; }
.crm-send-success-note {
  text-align: left;
  margin-bottom: 14px;
  font-size: 0.86rem;
}
.crm-send-success-monday {
  text-decoration: none;
}
.crm-send-success .crm-modal-actions {
  justify-content: center;
}

/* Phone: success meta must not clip mid-word (Roei iPhone SUCCESS shot). */
body.shell-phone .crm-modal-backdrop.crm-send-success-back {
  padding: 16px;
  overflow-x: hidden;
}
body.shell-phone .crm-modal.crm-send-success {
  width: min(420px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  max-height: calc(100dvh - 32px);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
body.shell-phone .crm-send-success .crm-modal-actions {
  flex-direction: column;
  align-items: stretch;
  flex-wrap: nowrap;
}
body.shell-phone .crm-send-success .crm-modal-actions .btn,
body.shell-phone .crm-send-success .crm-modal-actions a.btn {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  justify-content: center;
}
@media (max-width: 430px) {
  body.shell-phone .crm-send-success-row {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  body.shell-phone .crm-send-success-val {
    text-align: left;
  }
}

/* Timeline Order / Quote detail sheet */
.crm-tl-doc-back {
  z-index: 530;
}
.crm-tl-doc {
  width: min(440px, 100%);
  max-height: min(86vh, 720px);
  overflow: auto;
  text-align: left;
}
.crm-tl-doc .sky-modal-head {
  margin-bottom: 10px;
}
.crm-tl-doc .crm-send-success-meta {
  margin: 0 0 10px;
}
.crm-tl-doc-status {
  margin: 0 0 8px;
}
.crm-tl-doc-status.is-err {
  color: #ff453a;
}
.crm-tl-doc-note {
  margin: 0 0 10px;
  white-space: pre-wrap;
}
.crm-tl-doc-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 12px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.crm-tl-doc-line {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.88rem;
}
.crm-tl-doc-line-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.crm-tl-doc-line-meta {
  flex: 0 0 auto;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.crm-tl-doc-more {
  margin: 4px 0 0;
}
.crm-tl-doc .crm-modal-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Sent-to-office success (quote / order / form) */
.crm-send-success-back {
  z-index: 520;
}
.crm-send-success {
  text-align: center;
  padding-top: 26px;
}
.crm-send-success .crm-modal-actions {
  justify-content: center;
}
.crm-send-success-badge {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(48, 209, 88, 0.16);
  border: 1px solid rgba(48, 209, 88, 0.35);
  color: var(--ok, #30d158);
  box-shadow: 0 0 0 6px rgba(48, 209, 88, 0.08);
}
.crm-send-success.is-warn .crm-send-success-badge {
  background: rgba(255, 159, 10, 0.16);
  border-color: rgba(255, 159, 10, 0.4);
  color: #ff9f0a;
  box-shadow: 0 0 0 6px rgba(255, 159, 10, 0.08);
}
.crm-send-success-check {
  stroke: currentColor;
  stroke-width: 2.4;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.crm-send-success-kicker {
  color: var(--ok, #30d158);
}
.crm-send-success.is-warn .crm-send-success-kicker {
  color: #ff9f0a;
}
.crm-send-success h2 {
  letter-spacing: -0.03em;
}
.app-header-session {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  flex-shrink: 0;
  justify-content: flex-end;
  height: 100%;
  min-width: max-content;
}
.app-header .rep-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ink-secondary);
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
  padding: 0;
  flex: 0 1 auto;
  min-width: 0;
}
.app-header .topbar-action {
  font-size: 0.82rem;
  padding: 6px 4px;
}
.app-body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: start;
  min-width: 0;
  flex: 1 1 auto;
  min-height: 0; /* mandatory: flex child must shrink to scroll */
  width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.app-content {
  min-width: 0;
  width: 100%;
}

/* Condense / reveal top chrome (phone) --------------------------------------
   `body.crm-condensed` is driven by the ONE shared `.app-body` scroll watcher
   (app.js `bindAppCondense`): scrolling down folds the secondary chrome rows
   away and leaves a slim sticky search bar; a flick up springs the full chrome
   back. Opt-in is by selector - Products, list hubs (Timeline / Forms / Tasks)
   and the Customers list, matching `CRM_CONDENSE_SELS`.
   Gated to <=900px on purpose: `body.shell-phone` is true on desktop too under
   ONE UI, so the class alone is not a phone test.

   crm531: fold via `grid-template-rows: 1fr ? 0fr` (compositor-friendly) instead
   of fake `max-height: 240?0` which jumped the product list. JS wraps each fold
   target's children in `.crm-condense-fold-inner` so multi-child rows collapse
   as one track. Search (`#prodQ` / hub tools) stays visible. */
@media (max-width: 900px) {
  /* Hub / Customers heads become sticky like `.shop-chrome` already is.
     Solid surface only - Safari smears sticky + backdrop-filter (see .shop-chrome). */
  .sky-hub-page > .sky-page-head,
  .sky-customers > .sky-page-head {
    position: sticky;
    top: 0;
    z-index: 30;
    background: var(--bg, #000);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .shop-chrome-phone,
  .sky-hub-page > .sky-page-head,
  .sky-customers > .sky-page-head {
    transition:
      gap var(--dur-condense, 0.26s) var(--ease),
      padding var(--dur-condense, 0.26s) var(--ease);
  }
  .shop-chrome-phone .shop-search-field,
  .sky-page-head .sky-page-search input {
    transition:
      min-height var(--dur-condense, 0.26s) var(--ease),
      padding var(--dur-condense, 0.26s) var(--ease);
  }
  /* Secondary rows: title / account line / rail toggles.
     Search + filter row stays visible (Customers parity). */
  .shop-chrome-phone .shop-topbar-phone.crm-condense-fold,
  .sky-hub-page > .sky-page-head > .sky-page-head-titles.crm-condense-fold,
  .sky-hub-page > .sky-page-head > .sky-page-head-actions.crm-condense-fold,
  .sky-customers > .sky-page-head > h1.crm-condense-fold,
  .sky-customers > .sky-page-head > .sky-page-head-actions.crm-condense-fold {
    display: grid;
    grid-template-rows: 1fr;
    /* Beat phone `--btn-h` floors on `.sky-page-head-actions` so 0fr can win. */
    min-height: 0;
    overflow: hidden;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition:
      grid-template-rows var(--dur-condense, 0.26s) var(--ease),
      opacity 0.2s var(--ease),
      margin var(--dur-condense, 0.26s) var(--ease),
      transform var(--dur-condense, 0.26s) var(--ease),
      visibility 0s;
  }
  .crm-condense-fold > .crm-condense-fold-inner {
    min-height: 0;
    overflow: hidden;
  }
  /* Keep original flex layouts inside the single grid track. */
  .sky-page-head-titles.crm-condense-fold > .crm-condense-fold-inner {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
  }
  .sky-page-head-actions.crm-condense-fold > .crm-condense-fold-inner,
  .shop-topbar-phone.crm-condense-fold > .crm-condense-fold-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    min-width: 0;
  }
  .sky-page-head-actions.crm-condense-fold > .crm-condense-fold-inner {
    justify-content: flex-end;
  }
  body.crm-condensed .shop-chrome-phone .shop-topbar-phone.crm-condense-fold,
  body.crm-condensed .sky-hub-page > .sky-page-head > .sky-page-head-titles.crm-condense-fold,
  body.crm-condensed .sky-hub-page > .sky-page-head > .sky-page-head-actions.crm-condense-fold,
  body.crm-condensed .sky-customers > .sky-page-head > h1.crm-condense-fold,
  body.crm-condensed .sky-customers > .sky-page-head > .sky-page-head-actions.crm-condense-fold {
    grid-template-rows: 0fr;
    /* `.sky-page-head-actions` keeps a --btn-h floor on phone; override it or the
       row stays 44px tall with clipped contents. */
    min-height: 0;
    margin-top: 0;
    margin-bottom: 0;
    opacity: 0;
    transform: translateY(-4px);
    pointer-events: none;
    /* Clipped rows stay in the a11y tree; hide them once the fold has played so
       keyboard/VoiceOver cannot land on an invisible Sort / Category control. */
    visibility: hidden;
    transition:
      grid-template-rows var(--dur-condense, 0.26s) var(--ease),
      opacity 0.2s var(--ease),
      margin var(--dur-condense, 0.26s) var(--ease),
      transform var(--dur-condense, 0.26s) var(--ease),
      visibility 0s linear var(--dur-condense, 0.26s);
  }
  /* Flex row-gap survives a zero-height child - close it too. */
  body.crm-condensed .sky-hub-page > .sky-page-head,
  body.crm-condensed .sky-customers > .sky-page-head {
    gap: 0 18px;
    padding-top: 4px;
    padding-bottom: 4px;
  }
  /* The search stays reachable, just slimmer. Font-size is untouched (16px keeps
     iOS from zooming the field on focus). */
  body.crm-condensed .shop-chrome-phone {
    padding-top: 2px;
    padding-bottom: 4px;
  }
  body.crm-condensed .shop-chrome-phone .shop-search-field {
    min-height: var(--btn-h-sm);
    padding-top: 5px;
    padding-bottom: 5px;
  }
  body.crm-condensed .sky-page-head .sky-page-search input {
    padding-top: 6px;
    padding-bottom: 6px;
  }
}
@media (max-width: 900px) and (prefers-reduced-motion: reduce) {
  .shop-chrome-phone,
  .shop-chrome-phone .shop-search-field,
  .sky-hub-page > .sky-page-head,
  .sky-customers > .sky-page-head,
  .crm-condense-fold,
  .sky-page-head .sky-page-search input {
    transition: none !important;
  }
  body.crm-condensed .crm-condense-fold {
    transition: none !important;
  }
}
/* has-side only when Nav rail is open (default closed ? Calendar Filter pattern).
   Placement: content | RIGHT rail (same as Calendar Filter). */
.app-shell.has-side .app-body {
  grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max));
}
/* PC context Nav toggle ? sits above page content when a side-nav exists. */
.pc-context-rail-bar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 2px 2px 10px;
  min-width: 0;
}
body.shell-phone .pc-context-rail-bar {
  display: none;
}

/* ?? Smart rail (Calendar Filter look) ??
   Opt-in via `.crm-smart-rail`. Calendar Filter (`.sky-filter-premium`) is the
   reference; side-nav / hub rails / fold panels / More sheet share the surface. */
.crm-smart-rail {
  background: var(--rail-bg);
  border: 1px solid var(--rail-line);
  border-radius: var(--rail-radius);
  padding: var(--rail-pad-y) var(--rail-pad-x);
  min-width: 0;
}
.crm-smart-rail .panel-fold-bar,
.crm-smart-rail .sky-filter-head,
.crm-smart-rail .sky-rail-head,
.crm-smart-rail .sky-rail-title {
  margin: 0 0 4px;
  padding: 0 2px 10px;
  border-bottom: 1px solid var(--rail-line);
}
.crm-smart-rail .sky-rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.crm-smart-rail .sky-rail-head .sky-rail-title {
  margin: 0;
  padding: 0;
  border-bottom: 0;
}
.crm-smart-rail .panel-fold-title,
.crm-smart-rail .side-nav-title,
.crm-smart-rail .sky-filter-head h3,
.crm-smart-rail .sky-rail-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 1;
}
.crm-smart-rail .side-nav-fold,
.crm-smart-rail .sky-filter-fold {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 6px;
  margin: 0;
  cursor: pointer;
  border-radius: 8px;
  min-height: var(--rail-fold-min-h);
  text-align: left;
}
.crm-smart-rail .side-nav-fold:hover,
.crm-smart-rail .sky-filter-fold:hover {
  background: rgba(255, 255, 255, 0.055);
}
.crm-smart-rail .side-nav-fold-lab,
.crm-smart-rail .sky-filter-fold-lab,
.crm-smart-rail .sky-filter-lab,
.crm-smart-rail .sky-rail-subtitle {
  font-size: 0.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--rail-lab);
}
.crm-smart-rail .side-nav-sec.has-active > .side-nav-fold .side-nav-fold-lab {
  color: var(--rail-lab-active);
}
.crm-smart-rail .side-nav-link,
.crm-smart-rail .sky-view-item,
.crm-smart-rail .sky-tl-chip {
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-chip-radius);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.crm-smart-rail .side-nav-link:hover,
.crm-smart-rail .sky-view-item:hover,
.crm-smart-rail .sky-tl-chip:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
}
.crm-smart-rail .side-nav-link.is-active,
.crm-smart-rail .sky-view-item.is-on,
.crm-smart-rail .sky-tl-chip.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
  font-weight: var(--fw-med);
}
.crm-smart-rail .side-nav-link.is-active .side-nav-badge {
  color: #fff;
  background: rgba(255, 255, 255, 0.22);
}
.crm-smart-rail .sky-tl-chip.is-on .sky-tl-chip-ico {
  color: #fff;
  opacity: 1;
}
.crm-smart-rail .side-nav-chip,
.crm-smart-rail .sky-filter-field select,
.crm-smart-rail .sky-filter-select {
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.1));
  background: var(--btn-ghost-bg, rgba(0, 0, 0, 0.35));
  box-shadow: var(--btn-ghost-shadow);
}
.crm-smart-rail .side-nav-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.crm-smart-rail .panel-fold-ico,
.crm-smart-rail .sky-rail-close,
.crm-smart-rail .sky-filter-refresh {
  border-radius: 8px;
}
/* Slim PC context rails ? no heavy card chrome */
.crm-smart-rail.is-slim,
.side-nav.crm-smart-rail,
.sky-page-rail.crm-smart-rail {
  box-shadow: none;
}

.side-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--rail-pad-y) var(--rail-pad-x);
  border-radius: var(--rail-radius);
  border: 1px solid var(--rail-line);
  background: var(--rail-bg);
  position: sticky;
  top: calc(var(--hdr-h) + 8px);
  max-height: calc(100dvh - var(--hdr-h) - 20px);
  overflow-y: auto;
  align-self: start;
}
.side-nav-title {
  margin: 0;
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.side-nav .sky-rail-head {
  margin: -4px -2px 6px;
  padding: 4px 4px 8px;
}
/* Calendar People picker (sidebar) */
.acal-people-picker {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 2px 4px 6px;
}
.acal-people-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.acal-people-chip {
  appearance: none;
  flex: 0 0 auto;
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  background: var(--btn-ghost-bg, rgba(44, 44, 46, 0.9));
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius);
  padding: 5px 11px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  line-height: 1.15;
  min-height: 30px;
  white-space: nowrap;
  box-shadow: var(--btn-ghost-shadow, inset 0 1px 0 rgba(255, 255, 255, 0.04));
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease),
    box-shadow 0.14s var(--ease);
}
.acal-people-chip:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
}
.acal-people-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.acal-people-hint {
  margin: 0;
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.35;
}
.acal-people-selected {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.acal-people-sel {
  appearance: none;
  border: 1px solid var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  border-radius: var(--btn-chip-radius);
  padding: 4px 9px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  box-shadow: var(--btn-chip-on-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.acal-people-sel:hover {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
}
.acal-people-sel svg {
  width: 11px;
  height: 11px;
  display: block;
  opacity: 0.75;
}
.acal-people-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 168px;
  overflow: auto;
}
.acal-people-row {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: inherit;
  font: inherit;
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 6px 8px;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  text-align: left;
  min-height: 32px;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.acal-people-row:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
}
.acal-people-row.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
}
.acal-people-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.acal-people-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.08);
}
.acal-people-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.acal-people-meta {
  font-size: 0.66rem;
  color: var(--muted);
  white-space: nowrap;
}
.acal-people-legend {
  list-style: none;
  margin: 6px 0 0;
  padding: 6px 2px 0;
  border-top: 1px solid var(--acal-line, rgba(255, 255, 255, 0.08));
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.acal-people-legend li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  color: var(--ink-secondary, #c7c7cc);
  opacity: 0.9;
  pointer-events: none;
  padding: 2px 4px;
  min-height: 0;
  line-height: 1.2;
}
.acal-people-legend i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.acal-people-legend .is-done-key {
  opacity: 0.85;
}
.acal-people-clear {
  align-self: flex-start;
  margin: 0 !important;
  min-height: 30px !important;
  font-size: 0.75rem !important;
  padding: 4px 8px !important;
}

/* Foldable side panels ? icon dock */
.panel-foldable {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}
.panel-fold-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex: 0 0 auto;
  padding: 8px 10px;
  border-bottom: 1px solid var(--rail-line, var(--line));
}
.panel-fold-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.panel-foldable.crm-smart-rail:not(.side-nav) {
  padding: 0;
  overflow: hidden;
}
.panel-foldable.crm-smart-rail:not(.side-nav) .panel-fold-bar,
.panel-foldable.crm-smart-rail:not(.side-nav) .sky-rail-head {
  padding: 10px 12px;
  margin: 0;
}
.panel-foldable.crm-smart-rail:not(.side-nav) .panel-fold-body {
  padding: 8px 10px 12px;
}
.panel-fold-ico {
  appearance: none;
  border: 1px solid var(--line, rgba(255, 255, 255, 0.12));
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink-secondary, #ebebf5);
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: 0 0 auto;
  padding: 0;
}
.panel-fold-ico:hover {
  background: rgba(10, 132, 255, 0.2);
  color: #fff;
  border-color: rgba(10, 132, 255, 0.45);
}
.panel-fold-btn { display: none; }
.panel-fold-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.panel-fold-tab {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg-elevated, #1c1c1e);
  color: var(--accent, #0a84ff);
  width: 32px;
  min-height: 72px;
  padding: 8px 0;
  border-radius: 10px;
  cursor: pointer;
  display: grid;
  place-items: center;
  align-self: start;
  flex: 0 0 auto;
}
.panel-fold-tab:hover {
  background: rgba(10, 132, 255, 0.16);
}
.panel-ico {
  display: block;
}
.acal-body > .panel-foldable.is-right,
.acal-body > .panel-fold-tab.is-right {
  border-left: 1px solid var(--acal-line, rgba(255, 255, 255, 0.1));
  background: #000;
}
.acal-body > .panel-foldable.is-right {
  width: min(280px, 36vw);
}
.acal-body.rail-folded {
  grid-template-columns: minmax(0, 1fr) auto !important;
}
.acal-rail-inner {
  padding: 12px;
}
.shop-body.cat-folded,
.shop-body:not(.cats-rail-open) {
  grid-template-columns: minmax(0, 1fr);
}
.cat-panel-inner {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}
.cat-panel-inner .cat-list-full {
  flex: 1;
  overflow: auto;
}
.side-nav-sec {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin: 0 0 4px;
}
.side-nav-sec + .side-nav-sec {
  margin-top: 2px;
  padding-top: 4px;
  border-top: 1px solid var(--rail-section-line);
}
.side-nav-fold {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  font: inherit;
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  padding: 7px 6px;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  min-height: var(--rail-fold-min-h);
}
.side-nav-fold:hover {
  background: rgba(255, 255, 255, 0.055);
  color: var(--ink);
}
.side-nav-sec.has-active > .side-nav-fold {
  color: var(--ink);
}
.side-nav-fold-lab {
  font-size: 0.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--rail-lab);
  white-space: nowrap;
}
.side-nav-sec.has-active > .side-nav-fold .side-nav-fold-lab {
  color: var(--rail-lab-active);
}
.side-nav-fold-sum {
  font-size: 0.7rem;
  font-weight: var(--fw-semi);
  color: var(--accent, #0a84ff);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  justify-self: end;
  text-align: right;
}
.side-nav-fold-chev {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.55;
  transition: transform 0.15s ease, opacity 0.12s ease;
  margin-right: 2px;
}
.side-nav-fold-chev svg {
  width: 13px;
  height: 13px;
  display: block;
}
.side-nav-sec.is-open > .side-nav-fold .side-nav-fold-chev {
  transform: rotate(90deg);
  opacity: 0.75;
}
.side-nav-sub {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 0 0 4px 2px;
}
.side-nav-sec.is-folded > .side-nav-sub[hidden] {
  display: none !important;
}
.side-nav-heading {
  margin: 12px 0 4px;
  padding: 0 12px;
  font-size: 0.66rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(235, 235, 245, 0.42);
}
.side-nav > .side-nav-heading:first-of-type { margin-top: 2px; }
.side-nav-link {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-secondary);
  font: inherit;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  text-align: left;
  padding: 9px 12px;
  border-radius: var(--rail-link-radius);
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.side-nav-link:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.side-nav-link.is-active {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.side-nav-link.is-static { cursor: default; opacity: 0.65; font-weight: 500; }
.side-nav-badge {
  flex: 0 0 auto;
  min-width: 1.4em;
  padding: 1px 6px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.08);
  text-align: center;
}
.side-nav-link.is-active .side-nav-badge {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}
.side-nav-tools {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 2px 0 4px;
  padding: 0 4px;
}
.side-nav-search {
  display: block;
  margin: 0 0 2px;
  padding: 0 4px;
}
.side-nav-search input {
  width: 100%;
  box-sizing: border-box;
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg-elevated-2, rgba(255, 255, 255, 0.04));
  color: var(--ink);
  border-radius: 8px;
  padding: 7px 10px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 550;
}
.side-nav-search input::placeholder {
  color: var(--muted);
  opacity: 0.85;
}
.side-nav-search input:focus {
  outline: none;
  border-color: rgba(10, 132, 255, 0.55);
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.18);
}
.side-nav-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 0 2px;
}
.side-nav-chip {
  appearance: none;
  border: 1px solid var(--btn-ghost-border, var(--line));
  background: var(--btn-ghost-bg, transparent);
  color: var(--ink-secondary);
  font: inherit;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  padding: 4px 8px;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  line-height: 1.2;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.side-nav-chip:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
}
.side-nav-chip.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.app-content { min-width: 0; }
.app-content > .card { margin-top: 0; }
/* Phone: header Back arrow already covers this; PC screens (Documents,
   Account menu, History, etc.) rely on this in-page back button since the
   top nav only shows broad categories, not the specific previous screen. */
body.shell-phone .back-bar { display: none; }
/* Phone nested screens: header Back replaces in-page back buttons */
body.shell-phone .shop-back,
body.shell-phone .shop-topbar .back-btn,
body.shell-phone .cart-head .back-btn {
  display: none !important;
}
.app-shell.has-side .store-hub-actions { display: none; }
.duty-chip { display: none !important; }

/* Mobile: side-nav becomes a horizontal strip; phone chrome is body.shell-phone below */
@media (max-width: 900px) {
  :root {
    --shell-pad-x: 12px;
    --hdr-logo-h: 40px;
    --hdr-logo-w: 160px;
    --hdr-nav-fs: 0.82rem;
    --hdr-nav-pad-y: 7px;
    --hdr-nav-pad-x: 10px;
    --hdr-gap-y: 6px;
  }
  .app-header .rep-name { max-width: 110px; }
  .app-header .rep-name-text {
    max-width: 110px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    vertical-align: bottom;
  }
  .app-shell.has-side .app-body {
    grid-template-columns: 1fr;
  }
  .side-nav {
    position: static;
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    align-items: stretch;
    gap: 6px;
    padding: 8px 10px;
    top: auto;
  }
  .side-nav-title { display: none; }
  .side-nav-heading { display: none; }
  .side-nav-sec {
    flex: 0 0 auto;
    flex-direction: row;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 0;
    border: 0;
  }
  .side-nav-sec + .side-nav-sec {
    margin: 0;
    padding: 0;
    border: 0;
  }
  .side-nav-fold {
    width: auto;
    grid-template-columns: auto auto auto;
    padding: 8px 10px;
    border: 1px solid var(--line);
    background: var(--bg-elevated-2);
    border-radius: 10px;
    white-space: nowrap;
  }
  .side-nav-fold-lab {
    font-size: 0.72rem;
  }
  .side-nav-fold-sum {
    max-width: 72px;
  }
  .side-nav-sub {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 4px;
    padding: 0;
  }
  .side-nav-tools {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 0;
    flex: 0 0 auto;
  }
  .side-nav-search {
    margin: 0;
    padding: 0;
    flex: 0 0 auto;
  }
  .side-nav-search input {
    width: min(160px, 42vw);
    padding: 7px 10px;
  }
  .side-nav-chips {
    flex-wrap: nowrap;
    padding: 0;
  }
  .side-nav-link {
    width: auto;
    flex: 0 0 auto;
    padding: 8px 12px;
    white-space: nowrap;
    border: 1px solid var(--line);
    background: var(--bg-elevated-2);
  }
  .side-nav-badge {
    margin-left: 4px;
  }
}

/* Phone shell (?900px via JS): single header row + fixed bottom tabs ? no 96px ghost chrome */
body.shell-phone {
  --shell-pad-x: 10px;
  --hdr-h: 52px;
  --hdr-logo-h: 36px;
  --hdr-logo-w: 148px;
  --hdr-gap-y: 4px;
  /* crm408: unify nav token everywhere (not only .has-bottom-nav) */
  --bottom-nav-h: 56px;
  overflow-x: hidden;
}
body.shell-phone .app-header,
body.shell-phone .app-header-phone {
  position: relative;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: var(--hdr-h);
  grid-template-areas: none;
  height: calc(var(--hdr-h) + var(--safe-top));
  min-height: calc(var(--hdr-h) + var(--safe-top));
  max-height: calc(var(--hdr-h) + var(--safe-top));
  background: #121214;
}
body.shell-phone .app-header-brand {
  justify-self: start;
  height: var(--hdr-h);
  z-index: 2;
  position: relative;
}
body.shell-phone .app-header-session {
  justify-self: end;
  height: var(--hdr-h);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  z-index: 2;
  position: relative;
}
body.shell-phone .hdr-date-chip {
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: rgba(255, 255, 255, 0.5);
  white-space: nowrap;
  letter-spacing: -0.01em;
}
body.shell-phone .main-nav { display: none !important; }
/* Middle grid column (not absolute center) so Cart chip / icons never overlap the title. */
body.shell-phone .phone-page-title {
  position: relative;
  left: auto;
  top: auto;
  transform: none;
  margin: 0;
  justify-self: center;
  align-self: center;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  font-size: 1.02rem;
  font-weight: var(--fw-semi);
  text-align: center;
  letter-spacing: -0.02em;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
  z-index: 1;
}
/* Compact Cart chip on phone ? number-first; frees header middle column. */
body.shell-phone .app-header-session .cart-chip {
  max-width: 4.5rem;
  min-width: 0;
  padding: 0 10px;
  gap: 4px;
}
body.shell-phone .app-header-session .cart-chip-lab {
  display: none;
}
body.shell-phone .hdr-back-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  width: 44px;
  height: 44px;
  margin: 0 0 0 -8px;
  padding: 0;
  border-radius: 12px;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: 0 0 auto;
}
body.shell-phone .hdr-back-btn:active {
  background: rgba(10, 132, 255, 0.14);
}
body.shell-phone .app-header-phone.is-nested .logo-home-btn {
  display: none;
}
/* Phone: no shell `fadeUp` between screens (felt like a broken webview).
   Cross-step motion is View Transitions (`document.startViewTransition` in
   paintAppHtml) or the `.crm-nav-fade*` opacity fallback ? not this keyframe. */
body.shell-phone .screen,
body.shell-phone .app-shell.screen {
  animation: none !important;
}
/* In-page back bars stay hidden ? phone uses header Back; PC uses side/context */
body.shell-phone .sky-cust-head-m,
body.shell-phone .crm-entity-head {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 2px;
  overflow: visible;
}
body.shell-phone .crm-entity-head-title {
  font-size: 1rem;
  text-align: left;
}
body.shell-phone .sky-cust-head-m .sky-cust-head-mid {
  flex: 1;
  min-width: 0;
  padding-left: 0;
}
body.shell-phone .sky-cust-head-m .hub-quick-contact.is-header,
body.shell-phone .crm-entity-head-icons .hub-quick-contact.is-header {
  display: inline-flex;
  flex-shrink: 0;
  overflow: visible;
}
body.shell-phone .sky-cust-head-m #btnCustPlusMenu,
body.shell-phone .crm-entity-head-icons #btnCustPlusMenu,
body.shell-phone .crm-entity-head-add #btnCustPlusMenu {
  flex-shrink: 0;
}


.screen {
  max-width: 520px;
  margin: 0 auto;
  padding: 20px 18px 48px;
  animation: fadeUp 0.35s var(--ease);
}

/* Bare (non-shell) wide screens only ? never cap .app-shell (Home/hubs full-bleed). */
.screen.wide:not(.app-shell) { max-width: 1100px; }
.app-shell.screen.wide {
  max-width: none;
  width: 100%;
  margin-left: 0;
  margin-right: 0;
}
/* Legacy skinny home-card column ? phone / bare only. PC Home is .crm-home.is-pc. */
.screen.wide:not(.app-shell) .home-card,
body.shell-phone .screen.wide .home-card {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
/* PC home: kill any leftover 720 card / 1100 screen caps. */
@media (min-width: 901px) {
  body:not(.shell-phone) .screen.wide:has(.crm-home.is-pc),
  body:not(.shell-phone) .app-shell.screen.wide:has(.crm-home.is-pc) {
    max-width: none;
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }
  body:not(.shell-phone) .screen.wide .home-card,
  body:not(.shell-phone) .crm-home.is-pc .home-card {
    max-width: none;
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }
}
@media (min-width: 760px) {
  .screen.wide .home-card .home-blocks {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 520px) {
  .screen {
    padding: 16px 14px 40px;
  }
  .screen.wide .home-card .home-blocks,
  .home-card .home-blocks {
    grid-template-columns: 1fr;
  }
  .home-block {
    min-height: 72px;
  }
}
.screen.shop-screen {
  max-width: none;
  width: 100%;
  padding: 10px 16px 24px;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.logo-wrap {
  text-align: center;
  padding: 40px 12px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.logo-hero {
  width: min(320px, 78vw);
  height: auto;
  filter: drop-shadow(0 12px 40px rgba(10, 132, 255, 0.18));
}

.topbar {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 4px 0 12px;
  min-width: 0;
  width: 100%;
}
.brand-row {
  display: flex;
  align-items: center;
  min-width: 0;
  width: 100%;
}
.topbar-end {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px 10px;
  flex-wrap: wrap;
  min-width: 0;
  width: 100%;
  padding: 0 2px;
}
.topbar-action {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  padding: 6px 4px;
  margin: 0;
  cursor: pointer;
  white-space: nowrap;
  line-height: 1.2;
  width: auto;
  flex: 0 0 auto;
}
.topbar-action:hover { color: var(--accent-press); }
.duty-chip {
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  padding: 4px 9px;
  border-radius: var(--btn-chip-radius);
  background: rgba(48, 209, 88, 0.16);
  color: var(--ok);
  border: 1px solid rgba(48, 209, 88, 0.28);
  white-space: nowrap;
  text-transform: capitalize;
  margin-right: auto;
}
.clock-card h1 {
  margin-bottom: 6px;
}
.clock-header .logo-home-static {
  pointer-events: none;
  cursor: default;
}
.clock-header .logo-home-static:hover {
  opacity: 1;
}
.clock-header-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  text-align: center;
  letter-spacing: -0.02em;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.clock-rep {
  margin: 8px 0 10px;
  color: var(--ink-secondary);
  font-size: 0.9rem;
  text-align: center;
  line-height: 1.35;
}
.clock-rep .sub {
  display: inline;
  margin: 0;
  font-size: inherit;
  opacity: 0.75;
}
.clock-odo-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 4px 0 12px;
  text-align: left;
}
.clock-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  color: var(--ink-secondary);
  letter-spacing: 0.01em;
}
.clock-field .field {
  font-weight: var(--fw-regular);
  color: var(--ink);
  min-height: var(--btn-h);
}
.role-pick {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 0 0 16px;
}
.role-btn {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  color: var(--ink);
  border-radius: var(--radius-sm);
  padding: 14px 12px;
  font-weight: var(--fw-med);
  cursor: pointer;
}
.admin-card h1 { margin: 0; font-size: 1.35rem; }
.admin-card-clean {
  padding-top: 16px;
}
/* Admin Users ? sky-page hub (not a bolted-on card shell). */
.admin-users-page.sky-hub-page {
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
.admin-users-page .admin-tab-seg {
  margin: 0 0 12px;
  align-self: flex-start;
}
.admin-users-page .sky-page-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.admin-users-page .admin-desk-search {
  min-width: 200px;
  flex: 1 1 180px;
  max-width: 280px;
}
.admin-users-page .admin-desk-search input {
  width: 100%;
}
/* crm694: Status/Roles inset opt-rows — Filters sheet + PC Filter rail match ⋮ options menu shell. */
.admin-users-filter-rail,
.admin-users-filters-sheet {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable", "Segoe UI",
    system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.admin-users-filter-rail .crm-menu-body,
.admin-users-filters-sheet .crm-menu-body,
.hub-filters-sheet .crm-menu-body {
  padding: 0;
  gap: 10px;
}
.admin-users-filter-rail.sky-filter-premium .sky-filter-head {
  margin-bottom: 8px;
}
.admin-users-filters-sheet .cat-sheet-panel.crm-smart-rail,
.hub-filters-sheet .cat-sheet-panel.crm-smart-rail,
.shop-filters-sheet .cat-sheet-panel.crm-smart-rail {
  border: 1px solid var(--btn-ghost-border);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}
.admin-users-filters-sheet.cat-sheet.is-open,
.hub-filters-sheet.cat-sheet.is-open,
.shop-filters-sheet.cat-sheet.is-open {
  z-index: 260;
}
/* crm690: quieter Users face meta — no full-bleed rule under count line */
.admin-users-page .admin-result-meta.sky-page-meta {
  border-bottom: none;
  padding-bottom: 2px;
  margin-bottom: 10px;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}
.admin-users-page .sky-hub-tools.admin-users-tools {
  margin-bottom: 2px;
}
.admin-rail-roles,
.admin-rail-status {
  margin: 0 0 14px;
}
.admin-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin-bottom: 12px;
}
.admin-flash { margin: 0 0 10px; }
.admin-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 12px;
}
.admin-bar-phone,
.admin-bar-desk {
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  margin: 0 0 10px;
}
.admin-bar-phone .admin-role-chips,
.admin-bar-phone .admin-status-chips,
.admin-bar-desk .admin-role-chips,
.admin-bar-desk .admin-status-chips {
  /* Legacy face bars unused — keep chips hidden (sheet/rail own display:flex). */
  display: none;
  flex-wrap: wrap;
  gap: 6px;
  width: 100%;
}
.admin-search {
  flex: 1 1 180px;
  margin: 0 !important;
  min-width: 140px;
  max-width: 280px;
}
.admin-filter-role {
  display: none;
}
.admin-role-chips,
.admin-status-chips {
  /* Hidden by default — only sheet/rail rules above turn them on. */
  display: none;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  width: 100%;
}
.admin-sep {
  margin: 10px 0;
  border: none;
  border-top: 1px solid var(--line);
  background: none;
  height: 0;
}
.admin-inactive-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  font-size: 0.85rem;
  color: var(--ink-secondary);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}
.admin-foot {
  display: flex;
  margin-top: 14px;
}
.admin-foot .btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: auto;
}
.admin-table-wrap {
  overflow-x: auto;
  margin: 0 0 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.admin-table th {
  text-align: left;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: var(--fw-semi);
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.18);
}
.admin-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-tr.is-inactive { opacity: 0.55; }
.admin-td-name {
  min-width: 160px;
}
.admin-td-name strong {
  display: block;
  font-size: 0.92rem;
  line-height: 1.2;
}
.admin-email {
  display: block;
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 260px;
}
.admin-td-role {
  width: 190px;
  min-width: 170px;
}
.admin-td-role select.field {
  margin: 0;
  width: 100%;
  padding-top: 6px;
  padding-bottom: 6px;
  font-size: 0.85rem;
}
.admin-td-actions {
  width: 1%;
  white-space: nowrap;
}
.admin-td-actions .btn {
  margin: 0 2px 0 0;
}
.admin-empty-cell {
  color: var(--muted);
  text-align: center;
  padding: 20px 12px !important;
}
.admin-result-meta {
  margin: 0 0 14px;
  font-size: 0.75rem;
  color: var(--muted);
}
.admin-tools {
  margin: 0 0 16px;
  padding: 12px 0 0;
  border-top: 1px solid var(--line);
}
.admin-tools .hub-kicker {
  margin: 0 0 8px;
}
.admin-tools-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 10px;
}
.admin-matrix-box {
  max-height: min(40vh, 360px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: rgba(0, 0, 0, 0.22);
  padding: 10px 12px;
}
.admin-matrix-summary {
  margin: 0 0 10px;
  font-size: 0.82rem;
  color: var(--ink-secondary);
  line-height: 1.35;
}
.admin-matrix-desk-note {
  margin: 0 0 10px;
  font-size: 0.78rem;
  color: var(--muted);
}
.admin-matrix-roles {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.admin-matrix-role {
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: var(--bg-elevated-2, rgba(255, 255, 255, 0.04));
  overflow: hidden;
}
.admin-matrix-role > summary {
  list-style: none;
  cursor: pointer;
  padding: 10px 12px;
  font-size: 0.88rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: var(--btn-h-sm, 36px);
}
.admin-matrix-role > summary::-webkit-details-marker { display: none; }
.admin-matrix-role > summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  flex-shrink: 0;
  opacity: 0.7;
  transition: transform 0.15s var(--ease);
}
.admin-matrix-role[open] > summary::after {
  transform: rotate(-135deg);
  margin-top: 4px;
}
.admin-matrix-role-meta {
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: var(--muted);
}
.admin-matrix-groups {
  padding: 0 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.admin-matrix-group-lab {
  display: block;
  margin: 0 0 4px;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.admin-matrix-perms {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.admin-matrix-perm {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  min-height: 28px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  font-size: 0.74rem;
  font-weight: var(--fw-med);
  box-shadow: var(--btn-ghost-shadow);
}
.admin-matrix-perm.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.admin-matrix-empty {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
}
.admin-matrix-pre {
  display: none;
  margin: 10px 0 0;
  font-size: 0.72rem;
  line-height: 1.35;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--muted);
}
body:not(.shell-phone) .admin-matrix-pre.is-shown {
  display: block;
}

/* Admin Users ? one adaptive expand-row list (phone + desk). Legacy .admin-table kept unused. */
.admin-user-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0 0 8px;
  overflow: hidden;
}
/* crm696: ⋮ · avatar · User (name + last-seen) · Sign out · Deactivate · Type · Status — head/row tracks must match */
.admin-user-list-head {
  display: grid;
  grid-template-columns: 36px 40px minmax(0, 1fr) 36px 36px 7.5rem 4.75rem;
  align-items: end;
  column-gap: 10px;
  width: 100%;
  box-sizing: border-box;
  padding: 4px 14px 10px;
  margin: 0 0 4px;
  border-bottom: 0;
  font-size: 0.68rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 90%, transparent);
  user-select: none;
  position: relative;
}
.admin-user-list-head::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}
.admin-user-list-head-av,
.admin-user-list-head-more,
.admin-user-list-head-act {
  min-height: 1px;
}
.admin-user-list-head-user {
  min-width: 0;
}
/* crm677: headers centered over Type/Status column tracks */
.admin-user-list-head-type,
.admin-user-list-head-status {
  justify-self: stretch;
  text-align: center;
  width: 100%;
}
.admin-user-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: hidden;
}
/* crm690: inset hairlines inside settings-list card — not edge-to-edge */
.admin-user-list.settings-list > .admin-user-card {
  position: relative;
}
.admin-user-list.settings-list > .admin-user-card:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.admin-user-card.is-inactive {
  opacity: 0.62;
}
.admin-user-card.is-locked .admin-user-face-act:disabled,
.admin-user-card.is-locked .admin-user-face-act[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}
.admin-user-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
/* User face row — crm696: ⋮ · avatar · name+last-seen · face actions · Type · Status */
.admin-user-head {
  display: grid;
  grid-template-columns: 36px 40px minmax(0, 1fr) 36px 36px 7.5rem 4.75rem;
  align-items: center;
  column-gap: 10px;
  width: 100%;
  min-height: 56px;
  padding: 10px 14px;
  background: none;
  border: 0;
  color: inherit;
  text-align: left;
  font: inherit;
  overflow: hidden;
}
.admin-user-more {
  justify-self: center;
  align-self: center;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  padding: 0;
  margin: 0;
  border: 0;
  border-radius: var(--btn-radius-seg-item, 8px);
  background: transparent;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.admin-user-more:hover {
  color: var(--ink);
  background: color-mix(in srgb, var(--btn-ghost-bg) 80%, transparent);
}
.admin-user-more:active {
  transform: scale(0.94);
}
.admin-user-face-act {
  justify-self: center;
  align-self: center;
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  padding: 0;
  margin: 0;
  flex-shrink: 0;
  color: var(--muted);
}
.admin-user-face-act:hover:not(:disabled) {
  color: var(--ink);
}
.admin-user-face-act.admin-force-logout:hover:not(:disabled) {
  color: var(--danger, #ff453a);
}
.admin-user-face-act:disabled,
.admin-user-face-act[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
  pointer-events: auto; /* keep hover tip for locked actions */
}
.admin-user-head .admin-user-id {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.admin-user-head .admin-user-id strong {
  display: block;
  min-width: 0;
  font-size: 0.95rem;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-user-id .admin-user-last-seen {
  display: block;
  min-width: 0;
  margin-top: 2px;
  font-size: 0.72rem;
  font-weight: var(--fw-reg, 400);
  letter-spacing: normal;
  text-transform: none;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}
.admin-user-id .admin-user-last-seen.is-online {
  color: color-mix(in srgb, #30d158 82%, var(--muted));
}
/* Face chips: compact height (~26px) — 12px radius reads as stadium. Use seg-item
   squircle (8px), never 999px / 50% / half-height pills (premium-buttons).
   crm676: hard-clip inside Type/Status tracks — never spill into name.
   crm677: fill column track (same L/R edges every row); text centered + ellipsis. */
.admin-user-face-chip {
  box-sizing: border-box;
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 26px;
  margin: 0;
  padding: 3px 8px;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-radius-seg-item, 8px) !important;
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  font: inherit;
  font-size: 0.72rem;
  font-weight: var(--fw-med, 500);
  line-height: 1.2;
  color: var(--ink-secondary, var(--muted));
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* crm692: face Type chip is display-only — change via ⋮ only; no tap affordance. */
.admin-user-face-role {
  align-self: center;
  justify-self: stretch;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
  cursor: default;
  pointer-events: auto;
  touch-action: manipulation;
  font: inherit;
  border-color: color-mix(in srgb, var(--btn-ghost-border) 48%, transparent);
  background: color-mix(in srgb, var(--btn-ghost-bg) 65%, transparent);
  box-shadow: none;
}
.admin-user-face-role.is-locked {
  cursor: default;
}
.admin-user-face-status {
  cursor: default;
  pointer-events: auto;
  touch-action: manipulation;
}
.admin-user-list-head-sort {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin: 0;
  padding: 2px 4px;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  color: inherit;
  cursor: pointer;
  border-radius: var(--btn-radius-seg-item, 8px);
  min-width: 0;
}
.admin-user-list-head-user.admin-user-list-head-sort {
  justify-content: flex-start;
  justify-self: stretch;
}
.admin-user-list-head-type.admin-user-list-head-sort,
.admin-user-list-head-status.admin-user-list-head-sort {
  justify-content: center;
  justify-self: stretch;
  width: 100%;
}
.admin-user-list-head-sort:hover {
  color: var(--ink, var(--text));
  background: var(--btn-ghost-bg);
}
.admin-user-list-head-sort:focus-visible {
  outline: 2px solid var(--btn-focus-ring, rgba(10, 132, 255, 0.45));
  outline-offset: 1px;
}
.admin-user-sort-chev {
  display: inline-flex;
  flex-shrink: 0;
  opacity: 0.85;
}
/* crm685: premium inset Type + Actions cards (reference mock) */
.admin-user-options-sheet {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable", "Segoe UI",
    system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.admin-user-opt-menu {
  gap: 10px;
}
.admin-opt-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border-radius: var(--radius-sm, 12px);
  background: var(--bg-elevated-2);
  overflow: hidden;
}
.admin-opt-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  margin: 0;
  padding: 12px 14px;
  border: none;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.94rem;
  font-weight: var(--fw-med);
  text-align: left;
  cursor: pointer;
  position: relative;
  transition: background var(--dur-micro, 120ms) var(--ease-press);
}
.admin-opt-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 1px;
  background: var(--line);
  pointer-events: none;
}
.admin-opt-row:hover:not(:disabled):not([aria-disabled="true"]) {
  background: rgba(255, 255, 255, 0.035);
}
.admin-opt-row.is-current {
  background: transparent;
}
.admin-opt-row.is-current:hover:not(:disabled):not([aria-disabled="true"]) {
  background: rgba(255, 255, 255, 0.035);
}
.timeline-filter-menu .admin-opt-row.is-current,
.timeline-filter-menu .admin-opt-row.is-current:hover:not(:disabled):not([aria-disabled="true"]) {
  background: transparent;
}
.admin-opt-row.is-current .admin-opt-lab {
  font-weight: var(--fw-semi);
}
.admin-opt-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--btn-chip-on-bg);
  color: #fff;
}
.admin-opt-check svg {
  stroke: #fff;
}
.admin-opt-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  color: var(--muted);
  opacity: 0.78;
}
.admin-opt-lab {
  flex: 1;
  min-width: 0;
}
.admin-opt-current {
  flex-shrink: 0;
  padding: 3px 8px;
  border-radius: var(--btn-radius-seg-item, 8px);
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  line-height: 1.2;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
}
.admin-opt-sec {
  margin: 2px 0 0;
  padding: 0 2px;
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.88;
}
.admin-opt-sec:first-child {
  margin-top: 0;
}
.admin-opt-lab-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  flex: 1;
  gap: 1px;
}
.admin-opt-sub {
  font-size: 0.72rem;
  font-weight: var(--fw-reg, 400);
  letter-spacing: normal;
  text-transform: none;
  color: var(--muted);
  line-height: 1.25;
}
.admin-opt-well {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: #fff;
}
.admin-opt-well.is-blue {
  background: color-mix(in srgb, var(--accent) 90%, #fff 10%);
}
.admin-opt-well.is-slate {
  background: color-mix(in srgb, var(--muted) 42%, var(--bg-elevated-2) 58%);
}
.admin-opt-well.is-red {
  background: color-mix(in srgb, var(--danger) 88%, #fff 12%);
}
.admin-opt-chev {
  display: inline-flex;
  flex-shrink: 0;
  opacity: 0.42;
  color: var(--muted);
}
.admin-opt-row:disabled,
.admin-opt-row[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
  color: var(--btn-disabled-fg, var(--muted));
}
.admin-opt-row:disabled .admin-opt-well,
.admin-opt-row[aria-disabled="true"] .admin-opt-well {
  opacity: 0.72;
}
.admin-user-options-sheet .cat-sheet-panel.crm-smart-rail {
  border: 1px solid var(--btn-ghost-border);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}
.admin-user-head-end {
  display: contents;
}
/* CRM default menu — hybrid Type chips + Actions rows (crm678+).
   Reuse: .crm-menu-sheet · .crm-menu-choice-grid · .crm-menu-choice · .crm-menu-action
   Sheet chrome = handle + title + ghost Done (shop Sort head). Content-hug panel (crm682). */
.crm-menu-sheet.cat-sheet.is-open,
.more-nav-sheet.cat-sheet.is-open,
.admin-role-pick-sheet.cat-sheet.is-open,
.admin-user-options-sheet.cat-sheet.is-open,
.admin-users-filters-sheet.cat-sheet.is-open {
  z-index: 260;
}
.crm-menu-sheet .cat-sheet-panel,
.more-nav-sheet .cat-sheet-panel,
.admin-role-pick-sheet .cat-sheet-panel,
.admin-user-options-sheet .cat-sheet-panel,
.admin-users-filters-sheet .cat-sheet-panel {
  left: 50%;
  right: auto;
  width: min(100%, 400px);
  max-width: 400px;
  padding-bottom: var(--sheet-nav-clear, calc(16px + var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px)));
  max-height: min(85vh, 640px);
  transform: translate(-50%, 108%);
}
.crm-menu-sheet.cat-sheet.is-open .cat-sheet-panel,
.more-nav-sheet.cat-sheet.is-open .cat-sheet-panel,
.admin-role-pick-sheet.cat-sheet.is-open .cat-sheet-panel,
.admin-user-options-sheet.cat-sheet.is-open .cat-sheet-panel,
.admin-users-filters-sheet.cat-sheet.is-open .cat-sheet-panel {
  transform: translate(-50%, 0);
}
/* Phone: hug content — compact centered panel; stop above bottom nav (crm892). */
body.shell-phone .crm-menu-sheet .cat-sheet-panel,
body.shell-phone .more-nav-sheet .cat-sheet-panel,
body.shell-phone .admin-role-pick-sheet .cat-sheet-panel,
body.shell-phone .admin-user-options-sheet .cat-sheet-panel,
body.shell-phone .admin-users-filters-sheet .cat-sheet-panel {
  position: absolute;
  top: auto;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  left: 50%;
  right: auto;
  width: min(100%, 400px);
  max-width: 400px;
  height: auto;
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  margin: 0;
  padding: 12px 14px 12px;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  transform: translate(-50%, 108%);
}
body.shell-phone .crm-menu-sheet.cat-sheet.is-open .cat-sheet-panel,
body.shell-phone .admin-role-pick-sheet.cat-sheet.is-open .cat-sheet-panel,
body.shell-phone .admin-user-options-sheet.cat-sheet.is-open .cat-sheet-panel,
body.shell-phone .admin-users-filters-sheet.cat-sheet.is-open .cat-sheet-panel {
  transform: translate(-50%, 0);
}
.crm-menu-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  flex: 0 1 auto;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}
/* Shared phone menu harden — one scroll owner (.crm-menu-body); desk/rails untouched. */
body.shell-phone .crm-menu-sheet > .cat-sheet-panel {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone .crm-menu-sheet .crm-menu-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 24px;
}
/* Customer Filters owns an in-flow stop above phone navigation. Its long,
   uncapped option body scrolls inside the canonical sheet instead of under nav. */
body.shell-phone .sky-cust-filters-sheet.crm-menu-sheet .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone .sky-cust-filters-sheet .crm-menu-body {
  padding-bottom: 22px;
  overscroll-behavior: contain;
}
/* Peer menu batch 1: phone ADD / filter sheets stop above navigation and own scroll. */
body.shell-phone #shopFiltersSheet > .cat-sheet-panel,
body.shell-phone #adminUsersFiltersSheet > .cat-sheet-panel,
body.shell-phone #formsNewSheet > .cat-sheet-panel,
body.shell-phone #adminUserOptionsSheet > .cat-sheet-panel,
body.shell-phone .hub-add-sheet.crm-menu-sheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone #shopFiltersSheet .shop-filters-body,
body.shell-phone #adminUsersFiltersSheet .crm-menu-body,
body.shell-phone #formsNewSheet .crm-menu-body,
body.shell-phone #adminUserOptionsSheet .crm-menu-body,
body.shell-phone .hub-add-sheet .crm-menu-body {
  padding-bottom: 24px;
  overscroll-behavior: contain;
}
/* Place-for rep picker — long list scrolls inside sheet (phone + PC). */
.cart-place-for-sheet > .cat-sheet-panel {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.cart-place-for-sheet .crm-menu-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
body.shell-phone .cart-place-for-sheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone .cart-place-for-sheet .crm-menu-body {
  padding-bottom: 24px;
}
/* Peer menu batch 2: Timeline phone Filters — same nav clearance (id-scoped). */
body.shell-phone #timelineFiltersSheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone #timelineFiltersSheet .timeline-filter-menu {
  padding-bottom: 24px;
  overscroll-behavior: contain;
}
/* Peer menu batch 2: hub + Calendar Filters — same nav clearance (id gap). */
body.shell-phone #hubFiltersSheet > .cat-sheet-panel,
body.shell-phone #calendarFiltersSheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  padding-bottom: 12px;
}
body.shell-phone #hubFiltersSheet .crm-menu-body,
body.shell-phone #calendarFiltersSheet .crm-menu-body {
  padding-bottom: 24px;
  overscroll-behavior: contain;
}
body.shell-phone #timelineFiltersSheet .timeline-people-filter-search {
  display: block;
  margin: 2px 0;
}
body.shell-phone #timelineFiltersSheet .timeline-people-filter-search .field {
  width: 100%;
  min-height: var(--btn-h);
  padding: 10px 12px;
  border-radius: var(--btn-radius);
}
body.shell-phone #timelineFiltersSheet .timeline-people-filter-no-match {
  margin: 2px 0 0;
  padding: 14px;
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated-2);
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.35;
  text-align: center;
}
body.shell-phone #timelineFiltersSheet .timeline-people-filter-list .admin-opt-row[hidden],
body.shell-phone #timelineFiltersSheet .timeline-people-filter-no-match[hidden] {
  display: none !important;
}
.customer-filter-static-options,
.customer-filter-search-results,
.customer-filter-search-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.customer-filter-search {
  display: block;
  margin: 2px 0;
}
.customer-filter-search .field {
  min-height: var(--btn-h);
  padding: 10px 12px;
  border-radius: var(--btn-radius);
}
.customer-filter-no-match {
  margin: 2px 0 0;
  padding: 14px;
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated-2);
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.35;
  text-align: center;
}
.customer-filter-search-group[hidden],
.customer-filter-search-group .admin-opt-row[hidden],
.customer-filter-no-match[hidden] {
  display: none !important;
}
.timeline-filters-sheet .cat-sheet-panel {
  max-height: min(85vh, 700px);
}
.timeline-filters-sheet .timeline-filter-menu {
  padding-bottom: 4px;
}
.timeline-filter-menu {
  min-height: 0;
  overflow-y: auto;
}
.timeline-filter-menu .admin-opt-group {
  flex-shrink: 0;
}
.hub-filters-sheet .admin-opt-group,
.sky-filter-rail .admin-opt-group {
  flex-shrink: 0;
}
.crm-menu-section-lab,
.crm-menu-sheet .cat-sheet-group-lab,
.admin-user-options-sheet .cat-sheet-group-lab {
  margin: 4px 0 0;
}
.crm-menu-section-lab:first-child,
.crm-menu-sheet .cat-sheet-group-lab:first-child,
.admin-user-options-sheet .cat-sheet-group-lab:first-child {
  margin-top: 0;
}
.crm-menu-choice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  min-width: 0;
}
/* crm680: belt-and-suspenders — stale PWA must not collapse TYPE to 1-col */
.crm-menu-sheet .crm-menu-choice-grid,
.admin-user-options-sheet .crm-menu-choice-grid {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 8px;
  width: 100%;
  min-width: 0;
}
/* crm680: hide any leftover status-adjacent chev from cached markup */
.admin-user-chev,
.admin-user-head .admin-user-chev {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
}
.crm-menu-choice-grid .crm-menu-choice.btn:last-child:nth-child(odd) {
  grid-column: auto;
}
.crm-menu-choice.btn {
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 8px 10px;
  justify-content: center;
  text-align: center;
  white-space: normal;
  line-height: 1.2;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  box-shadow: var(--btn-ghost-shadow);
  font-weight: var(--fw-med);
}
.crm-menu-choice.btn.is-on,
.crm-menu-choice.btn.active,
.crm-menu-choice.btn[aria-selected="true"] {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
  font-weight: var(--fw-semi);
}
.crm-menu-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.crm-menu-action.btn {
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 8px 12px;
  justify-content: flex-start;
  text-align: left;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  box-shadow: var(--btn-ghost-shadow);
  font-weight: var(--fw-med);
}
.crm-menu-choice.btn:disabled,
.crm-menu-choice.btn[aria-disabled="true"],
.crm-menu-action.btn:disabled,
.crm-menu-action.btn[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
  color: var(--btn-disabled-fg, var(--muted));
  background: var(--btn-disabled-bg, var(--btn-ghost-bg));
  box-shadow: none;
}
body.admin-role-pick-open {
  overflow: hidden;
}
body.admin-role-pick-open .app-body {
  overflow: hidden;
}
/* Presence at a glance while the row is collapsed (green = connected). */
.admin-user-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
  opacity: 0.55;
  flex: 0 0 auto;
}
.admin-user-dot.is-on {
  background: var(--ok, #30d158);
  opacity: 1;
}
/* Long gmail addresses were breaking mid-word onto a second line - beats the
   card-level `word-break: break-word` further down this file. */
.admin-user-card .admin-user-head .admin-email {
  max-width: 100%;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: normal;
}
/* Collapsed face: Connected/Off + Last seen (iOS subtitle under name/email). */
.admin-user-face-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 3px;
  min-width: 0;
  font-size: 0.78rem;
  line-height: 1.25;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Face status column: always Active or Inactive chip (crm672+). crm677: full track. */
.admin-user-head > .admin-user-face-status {
  justify-self: stretch;
  align-self: center;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}
.admin-user-face-status.is-active {
  color: color-mix(in srgb, var(--ok, #30d158) 88%, #fff 12%);
  border-color: color-mix(in srgb, var(--ok, #30d158) 42%, var(--btn-ghost-border));
  background: color-mix(in srgb, var(--ok, #30d158) 14%, var(--btn-ghost-bg));
  box-shadow: none;
}
.admin-user-face-status.is-inactive {
  color: color-mix(in srgb, var(--warn, #ffd60a) 55%, var(--muted));
  border-color: color-mix(in srgb, var(--warn, #ffd60a) 28%, var(--btn-ghost-border));
  background: color-mix(in srgb, var(--warn, #ffd60a) 10%, var(--btn-ghost-bg));
  box-shadow: none;
}
.admin-user-face-status.is-on {
  color: var(--ok, #30d158);
}
.admin-user-face-status.is-off {
  color: var(--muted);
}
.admin-user-face-sep {
  opacity: 0.45;
  flex: 0 0 auto;
}
.admin-user-face-seen {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Legacy face Active/Inactive fill pills — keep selector; radius matches face chips. */
.admin-user-active-badge {
  border-radius: var(--btn-chip-radius);
}
.admin-user-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px 14px 14px;
  border-top: 1px solid var(--line);
}
.admin-user-av-wrap {
  position: relative;
  display: inline-flex;
  align-self: center;
  justify-self: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  overflow: visible;
  z-index: 1;
}
.admin-user-av-wrap .admin-user-avatar {
  display: block;
  width: 100%;
  height: 100%;
}
/* crm692: unmistakable online/offline dot on avatar — not clipped by card overflow. */
.admin-user-presence {
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--surface-elevated, var(--surface, var(--bg, #1c1c1e)));
  box-sizing: border-box;
  background: color-mix(in srgb, var(--muted) 78%, #8e8e93);
  pointer-events: none;
  z-index: 2;
}
.admin-user-presence.is-on {
  background: #30d158;
  box-shadow: 0 0 0 1px color-mix(in srgb, #30d158 45%, transparent);
}
.admin-user-presence.is-off {
  background: color-mix(in srgb, var(--muted) 72%, #8e8e93);
}
.admin-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  object-fit: cover;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}
.admin-user-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
}
.admin-user-id {
  min-width: 0;
  flex: 1;
}
.admin-user-id strong {
  display: block;
  font-size: 1rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}
.admin-user-card .admin-email {
  max-width: none;
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: normal;
}
.admin-user-role {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--muted);
}
.admin-user-role-lab,
.admin-user-actions .hub-kicker {
  display: block;
  margin: 0 2px 2px;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.admin-user-role select.field {
  margin: 0;
  width: 100%;
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
}
.admin-user-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.admin-user-actions .btn {
  margin: 0;
  min-height: var(--btn-h-sm, 36px);
  width: 100%;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.admin-user-act-btns {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
/* Recover PIN: two-line label so lost-PIN intent is obvious */
.admin-user-actions .admin-reset-pin {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
  height: auto;
  min-height: var(--btn-h, 44px);
  text-align: left;
  line-height: 1.2;
}
.admin-user-act-main {
  font-weight: var(--fw-semi, 600);
}
.admin-user-act-sub {
  font-size: 0.72rem;
  font-weight: var(--fw-reg, 400);
  color: var(--muted);
}
/* crm552: Role chips = Customers Filters ios-filter rows (check, not blue slabs) */
.admin-user-body .ios-filter-list,
.admin-user-role-list {
  display: flex;
  flex-direction: column;
  max-height: none;
  margin: 0;
  padding: 0;
  border-radius: 12px;
  background: var(--bg-elevated, rgba(255, 255, 255, 0.06));
  border: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  overflow: hidden;
  text-transform: none;
  letter-spacing: 0;
  font-weight: var(--fw-reg, 400);
  color: var(--ink);
}
.admin-user-body .ios-filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  margin: 0;
  border: 0;
  border-bottom: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  font-weight: var(--fw-med);
  text-align: left;
  text-transform: none;
  letter-spacing: 0;
  appearance: none;
  cursor: pointer;
}
.admin-user-body .ios-filter-row:last-child {
  border-bottom: 0;
}
.admin-user-body .ios-filter-row:active {
  background: rgba(255, 255, 255, 0.06);
}
.admin-user-body .ios-filter-row:disabled {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}
.admin-user-body .ios-filter-row-lab {
  flex: 1;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
}
.admin-user-body .ios-filter-row-txt {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.admin-user-body .ios-filter-row-check {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent, #0a84ff);
}
.admin-user-body .ios-filter-row.is-on .ios-filter-row-lab {
  color: var(--ink);
  font-weight: var(--fw-semi);
}
.admin-empty {
  margin: 0;
  padding: 28px 12px;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  border: 1px dashed var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
body.shell-phone .admin-users-page.admin-card {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
body.shell-phone .admin-users-page .admin-tab-seg {
  width: 100%;
  display: flex;
}
body.shell-phone .admin-users-page .admin-tab-seg .acal-seg-btn {
  flex: 1 1 0;
  text-align: center;
}
body.shell-phone .admin-card:not(.admin-users-page) {
  padding: 12px 10px 20px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
body.shell-phone .admin-card h1 {
  font-size: 1.15rem;
}
body.shell-phone .admin-bar {
  flex-direction: column;
  align-items: stretch;
}
body.shell-phone .admin-search {
  max-width: none;
  flex: 1 1 auto;
  width: 100%;
}
body.shell-phone .admin-filter-role {
  display: none;
}
body.shell-phone .admin-matrix-box {
  max-height: min(50vh, 420px);
}
body.shell-phone .admin-tabs {
  width: 100%;
  display: grid;
  /* Users + Deliveries only (Homes retired) ? two equal cols, no empty third */
  grid-template-columns: repeat(2, 1fr);
}
body.shell-phone .admin-tab {
  text-align: center;
  padding: 9px 6px;
}
body.shell-phone .admin-deliv-actions {
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}
body.shell-phone .admin-deliv-actions .btn {
  width: 100%;
  min-height: var(--btn-h, 44px);
}
body.shell-phone .admin-deliv-actions-ops {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
body.shell-phone .admin-deliv-actions-ops .btn {
  width: 100%;
}
body.shell-phone .admin-deliv-title {
  font-size: 1rem;
}
body.shell-phone .admin-user-card {
  padding: 0;
  gap: 0;
}
@media (max-width: 440px) {
  /* Seven fixed columns keep 44px phone actions separate at 390px and 430px. */
  .admin-user-list-head,
  .admin-user-head {
    grid-template-columns: 44px 32px minmax(0, 1fr) 44px 44px 4.25rem 3rem;
    column-gap: 2px;
    padding-left: 8px;
    padding-right: 8px;
  }
  .admin-user-list-head {
    padding-top: 4px;
    padding-bottom: 8px;
    font-size: 0.62rem;
  }
  .admin-user-head {
    padding-top: 8px;
    padding-bottom: 8px;
  }
  .admin-user-head .admin-user-id strong {
    font-size: 0.88rem;
  }
  .admin-user-id .admin-user-last-seen {
    font-size: 0.68rem;
  }
  .admin-user-av-wrap {
    width: 32px;
    height: 32px;
  }
  .admin-user-presence {
    width: 9px;
    height: 9px;
    border-width: 2px;
    right: -2px;
    bottom: -2px;
  }
  .admin-user-avatar {
    width: 32px;
    height: 32px;
  }
  .admin-user-more,
  .admin-user-face-act {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
  body.shell-phone .admin-user-head .admin-user-more,
  body.shell-phone .admin-user-head .admin-user-face-act {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
  }
  body.shell-phone .admin-user-head .admin-user-more svg,
  body.shell-phone .admin-user-head .admin-user-face-act svg {
    width: 16px;
    height: 16px;
  }
  .admin-user-face-chip {
    min-height: 22px;
    padding: 2px 4px;
    font-size: 0.66rem;
    border-radius: var(--btn-radius-seg-item, 8px) !important;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .admin-user-face-role,
  .admin-user-head > .admin-user-face-status {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    justify-self: stretch;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: center;
  }
}
body.shell-phone .admin-pin-display {
  font-size: 1.75rem;
  margin: 12px 0;
}
@media (min-width: 901px) {
  body:not(.shell-phone) .admin-user-list{
    display: flex;
    gap: 0;
  }
  body:not(.shell-phone) .admin-user-actions{
    grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.admin-label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.75rem;
  color: var(--muted);
  flex: 1 1 140px;
  min-width: 140px;
}
.admin-label select.field {
  margin: 0;
  width: 100%;
}
.admin-badge {
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  padding: 3px 8px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: rgba(10, 132, 255, 0.18);
  color: #7cb8ff;
  border: 1px solid rgba(10, 132, 255, 0.28);
}
.admin-badge.off {
  background: rgba(255, 69, 58, 0.14);
  color: #ff8a80;
  border-color: rgba(255, 69, 58, 0.28);
}

/* Admin Users ? presence (online/off) + last contacted */
.admin-presence {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  padding: 3px 8px;
  border-radius: 8px;
  background: rgba(48, 209, 88, 0.14);
  color: #30d158;
  border: 1px solid rgba(48, 209, 88, 0.3);
  white-space: nowrap;
}
.admin-presence.is-off {
  background: rgba(142, 142, 147, 0.14);
  color: var(--muted);
  border-color: var(--line);
}
.admin-presence-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}
.admin-last-seen {
  font-size: 0.78rem;
  color: var(--muted);
  white-space: nowrap;
}
.admin-user-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.admin-td-presence,
.admin-td-lastseen {
  white-space: nowrap;
}

/* Admin Users — PIN modal (Choose / Generate / Show) — crm688 */
.admin-pin-modal {
  width: min(440px, 100%);
  padding: 18px 18px 16px;
}
.admin-pin-head {
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.admin-pin-head h2 {
  flex: 1;
  min-width: 0;
  font-size: 1.08rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
}
.admin-pin-head-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  color: var(--accent);
}
.admin-pin-head-ico svg {
  display: block;
}
.admin-pin-body {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.admin-pin-intro {
  text-align: center;
  margin: 0 0 18px;
}
.admin-pin-lead {
  margin: 0 0 6px;
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  line-height: 1.35;
}
.admin-pin-hint {
  margin: 0;
  font-size: 0.86rem;
  color: var(--muted);
  line-height: 1.35;
}
.admin-pin-modal .admin-pin-row {
  gap: 14px;
  margin: 0 0 20px;
}
.admin-pin-modal .admin-pin-digit {
  width: 56px;
  height: 56px;
  min-height: 44px;
  font-size: 1.5rem;
  border-radius: var(--btn-radius, var(--radius-sm));
}
.admin-pin-opts {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0 0 16px;
}
.admin-pin-opt-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--btn-radius, var(--radius-sm));
  background: var(--bg-elevated-2);
  cursor: pointer;
  min-height: 44px;
}
.admin-pin-opt-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 16%, var(--bg-elevated-2) 84%);
  color: var(--accent);
}
.admin-pin-opt-ico svg {
  display: block;
}
.admin-pin-opt-copy {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.admin-pin-opt-lab {
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  line-height: 1.25;
}
.admin-pin-opt-sub {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.3;
}
.admin-pin-opt-card .settings-toggle {
  flex-shrink: 0;
}
.admin-pin-foot {
  margin-top: 4px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.admin-pin-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: nowrap;
  align-items: center;
}
/* Global .btn is width:100% — PIN footer must hug like the mock (Cancel | Save). */
.admin-pin-actions .btn {
  width: auto;
  flex: 0 0 auto;
  margin-top: 0;
  min-width: 5.75rem;
  padding-left: 18px;
  padding-right: 18px;
}
.admin-pin-display {
  margin: 4px 0 16px;
  text-align: center;
  font-size: 1.9rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.35em;
  color: var(--ink);
}
.admin-pin-msg {
  margin: 8px 0 0;
  text-align: center;
}
.admin-pin-modal .sky-modal-opt {
  margin-bottom: 8px;
}
body.shell-phone .admin-pin-modal {
  padding-bottom: max(16px, var(--sheet-nav-clear, 16px));
}
body.shell-phone .admin-pin-modal .admin-pin-digit {
  width: 52px;
  height: 52px;
}

.admin-tabs {
  display: inline-flex;
  gap: 2px;
  flex-wrap: wrap;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 0;
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
}
.admin-tab {
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  border-radius: var(--btn-radius-seg-item);
  padding: 7px 14px;
  font-weight: var(--fw-semi);
  cursor: pointer;
  font-size: 0.85rem;
  transition: background 0.14s var(--ease), color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.admin-tab.active {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
.admin-deliveries {
  margin: 0 0 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.admin-deliv-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.admin-deliv-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.admin-deliv-head .hub-kicker {
  margin: 0;
}
.admin-deliv-title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: var(--fw-strong);
  line-height: 1.25;
}
.admin-deliv-blurb {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.35;
}
.admin-deliv-status {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  border-radius: var(--radius-sm, 12px);
  border: 1px solid var(--line);
  font-size: 0.82rem;
}
.admin-deliv-status strong {
  font-size: 0.88rem;
}
.admin-deliv-meta {
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.35;
}
.admin-deliv-status-ok {
  background: rgba(48, 209, 88, 0.12);
  border-color: rgba(48, 209, 88, 0.35);
}
.admin-deliv-status-warn {
  background: rgba(255, 159, 10, 0.12);
  border-color: rgba(255, 159, 10, 0.35);
}
.admin-deliv-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.admin-deliv-actions .btn {
  margin: 0;
}
.admin-deliv-actions-ops {
  gap: 6px;
}
.admin-deliv-link {
  color: var(--accent, #0a84ff);
  font-weight: var(--fw-med);
  font-size: 0.82rem;
  padding: 0 4px;
}
.admin-deliv-msg {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ink-secondary);
  text-align: left;
  line-height: 1.35;
}
.admin-table th.num,
.admin-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.admin-homes-studio {
  margin: 4px 0 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.homes-studio-hint {
  margin: 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(10, 132, 255, 0.12);
  border: 1px solid rgba(10, 132, 255, 0.28);
}
.homes-tile-hidden-note {
  display: block;
  margin-top: 4px;
  font-size: 0.75rem;
  color: #ff9f0a;
  font-weight: var(--fw-med);
}
.homes-legacy-tiles {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.homes-edit-blocks .home-block {
  cursor: pointer;
}
.homes-studio-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}
.homes-role-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.homes-role-tab {
  border: 1px solid var(--line-strong);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  border-radius: var(--btn-radius-seg-item);
  padding: 7px 12px;
  min-height: 34px;
  font-size: 0.8rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease);
}
.homes-role-tab:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
}
.homes-role-tab.active {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.homes-device {
  display: inline-flex;
  gap: 0;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  border: 0;
  background: var(--btn-seg-track);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
  overflow: hidden;
}
.homes-device-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: var(--btn-radius-seg-item);
  padding: 8px 16px;
  min-height: 34px;
  font-size: 0.8rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
  transition: background 0.14s var(--ease), color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.homes-device-btn:hover { color: var(--ink); }
.homes-device-btn.active {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
.homes-studio-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}
.homes-studio-meta .admin-label { flex: 1 1 160px; }
.homes-preview-stage {
  display: flex;
  justify-content: center;
  padding: 12px 8px 16px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.homes-preview-chrome {
  width: 100%;
  max-width: 720px;
  transition: max-width 0.2s var(--ease);
}
.homes-preview-chrome.homes-preview-mobile {
  max-width: 390px;
}
.homes-preview-screen {
  background: var(--surface-solid);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  padding: 18px 16px 20px;
  box-shadow: var(--shadow);
}
.homes-preview-mobile .homes-preview-screen {
  border-radius: 10px;
  padding: 20px 14px 22px;
  min-height: 480px;
  border-width: 2px;
}
.homes-preview-kicker {
  margin: 0 0 6px;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.homes-preview-title {
  margin: 0 0 4px;
  font-size: 1.45rem;
  font-weight: var(--fw-strong);
}
.homes-preview-sub {
  margin: 0 0 16px;
  font-size: 0.88rem;
  color: var(--muted);
}
.homes-preview-empty { margin: 8px 0; }

/* Admin Homes studio on phone ? already a vertical stack; reduce density + grow tap targets */
@media (max-width: 900px) {
  .admin-homes-studio {
    gap: 16px;
  }
  .homes-studio-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .homes-role-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
  }
  .homes-role-tab {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 9px 14px;
  }
  .homes-device {
    align-self: flex-start;
  }
  .homes-device-btn {
    min-height: 44px;
    padding: 10px 16px;
  }
  .homes-studio-meta {
    flex-direction: column;
    align-items: stretch;
  }
  .homes-studio-meta .admin-label {
    flex: 1 1 auto;
  }
  .homes-preview-stage {
    padding: 10px 4px 14px;
  }
  .homes-preview-chrome,
  .homes-preview-chrome.homes-preview-mobile {
    max-width: 100%;
  }
  .homes-palette-row {
    gap: 10px;
  }
  .homes-palette-btn {
    min-height: 44px;
    padding: 10px 14px;
  }
  .homes-inspector-grid {
    grid-template-columns: 1fr;
  }
}

/* Phone shell (class from app.js) ? same density rules when viewport is still wide */
.admin-homes-studio.is-phone .homes-studio-meta,
body.shell-phone .admin-homes-studio .homes-studio-meta {
  flex-direction: column;
  align-items: stretch;
}
.admin-homes-studio.is-phone .homes-studio-meta .admin-label,
body.shell-phone .admin-homes-studio .homes-studio-meta .admin-label {
  flex: 1 1 auto;
  width: 100%;
}
.admin-homes-studio.is-phone .homes-role-tabs,
body.shell-phone .admin-homes-studio .homes-role-tabs {
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
}
.admin-homes-studio.is-phone .homes-role-tab,
body.shell-phone .admin-homes-studio .homes-role-tab {
  flex: 0 0 auto;
  min-height: 44px;
}
.admin-homes-studio.is-phone .homes-edit-blocks,
.admin-homes-studio.is-phone .homes-inspector-grid,
body.shell-phone .admin-homes-studio .homes-edit-blocks,
body.shell-phone .admin-homes-studio .homes-inspector-grid {
  grid-template-columns: 1fr;
}
.admin-homes-studio.is-phone .home-block-tools,
body.shell-phone .admin-homes-studio .home-block-tools {
  flex-wrap: wrap;
}
.admin-homes-studio.is-phone .home-block-tool,
body.shell-phone .admin-homes-studio .home-block-tool {
  min-height: 44px;
  padding: 10px 6px;
}

.home-blocks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.homes-preview-pc .home-blocks {
  grid-template-columns: 1fr 1fr;
}
.homes-preview-mobile .home-blocks {
  grid-template-columns: 1fr;
}
.home-card .home-blocks {
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 520px) {
  .home-card .home-blocks {
    grid-template-columns: 1fr;
  }
}
.home-block {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  text-align: left;
  min-height: 88px;
  padding: 0;
  width: 100%;
  border-radius: 6px;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  color: var(--ink);
  cursor: pointer;
  overflow: hidden;
  font: inherit;
  white-space: normal;
  line-height: 1.25;
  box-shadow: none;
  appearance: none;
}
button.home-block {
  padding: 14px 14px 12px;
}
.home-block-body {
  padding: 14px 14px 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.home-block strong {
  font-size: 1rem;
  font-weight: var(--fw-strong);
}
.home-block span {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}
/* Live Home tiles (homeBlocksHtml) ? icon badge + text, row layout so
 * ghost/outline tiles (e.g. Products, Customers) read as a clear CTA
 * instead of an empty outlined box. */
.home-block.home-block-live {
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 14px;
}
.home-block-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink-secondary);
  transition: transform 0.15s var(--ease), background 0.15s var(--ease);
}
.home-block-live:hover .home-block-ico {
  transform: scale(1.05);
}
.home-block-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.home-block-primary .home-block-ico {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}
.home-block-warm .home-block-ico {
  background: rgba(0, 0, 0, 0.08);
  color: #111;
}
.home-block-ghost .home-block-ico {
  background: rgba(10, 132, 255, 0.16);
  color: #8ec0ff;
}
.home-block-live.home-block-ghost:hover {
  background: rgba(10, 132, 255, 0.08);
  border-color: rgba(10, 132, 255, 0.75);
}
.home-block-live.home-block-primary:hover {
  background: #0077e6;
}
.home-block-primary {
  background: #0a84ff;
  border-color: #0070e0;
  color: #fff;
}
.home-block-primary strong { color: #fff; }
.home-block-primary span { color: rgba(255, 255, 255, 0.88); }
.home-block-warm {
  background: #f2f2f7;
  border-color: #cfcfd4;
  color: #111;
}
.home-block-warm strong { color: #111; }
.home-block-warm span { color: #555; }
.home-block-ghost {
  background: transparent;
  border-color: rgba(10, 132, 255, 0.5);
  color: #8ec0ff;
}
.home-block-ghost strong { color: #8ec0ff; }
.home-block-ghost span { color: rgba(142, 192, 255, 0.8); }
.home-block.is-selected {
  outline: 2px solid #fff;
  outline-offset: 2px;
}
.home-block.is-off {
  opacity: 0.42;
}
.home-block-tools {
  display: flex;
  gap: 0;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
}
.home-block-tool {
  flex: 1;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--ink-secondary);
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  padding: 7px 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.home-block-tool svg {
  width: 14px;
  height: 14px;
  display: block;
}
.home-block-tool:last-child { border-right: 0; }
.home-block-tool:disabled {
  opacity: 0.35;
  cursor: default;
}
.home-block-tool.danger { color: #ff8a80; }
.home-block-tool:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.06);
}
@media (max-width: 900px) {
  .home-block-tool {
    min-height: 44px;
    padding: 10px 6px;
    font-size: 0.76rem;
  }
}

.homes-palette {
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.homes-palette-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.homes-palette-btn {
  border: 1px dashed var(--line-strong);
  background: transparent;
  color: var(--ink-secondary);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
}
.homes-palette-btn:hover {
  border-style: solid;
  border-color: rgba(10, 132, 255, 0.45);
  background: rgba(10, 132, 255, 0.12);
  color: #fff;
}
.homes-inspector {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  background: var(--bg-elevated-2);
}
.homes-inspector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px 10px;
  margin: 8px 0 10px;
}
.homes-inspector-blurb { grid-column: 1 / -1; }
.homes-inspector-hint {
  margin: 0;
  padding: 4px 0 8px;
}

.home-card h1 { margin-bottom: 6px; }
.home-sky-head { align-items: flex-start; }
.home-status-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: 0.88rem;
  color: var(--ink-secondary);
}
.home-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(48, 209, 88, 0.18);
}
.home-start-cta {
  width: 100%;
  margin-top: 4px;
  padding: 14px 16px;
  font-size: 0.95rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.01em;
  text-transform: none;
  border-radius: var(--btn-radius);
}
/* Sticky primary CTA (Home + hub "Start a visit") ? floats above the bottom
 * nav, so it uses the elevated shadow token (deeper black lift, faint blue
 * rim) instead of a hand-rolled glow. Background stays on --btn-primary-bg
 * (richer 3-stop gradient) rather than a flatter one-off 2-stop override. */
body.shell-phone .sky-sticky-visit,
body.shell-phone .crm-home.is-phone .home-start-cta.sky-sticky-visit,
body.shell-phone .sky-page.sky-near-me .home-start-cta.sky-sticky-visit {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
  z-index: 120;
  width: auto;
  margin: 0;
  box-shadow: var(--btn-primary-shadow-elevated);
}
/* Home sticky Start a visit ? icon-only FAB (aria-label), not word chrome. */
body.shell-phone .home-start-cta.sky-sticky-visit.is-icon-only {
  left: auto;
  right: 16px;
  width: var(--btn-h);
  min-width: var(--btn-h);
  height: var(--btn-h);
  min-height: var(--btn-h);
  padding: 0;
  display: grid;
  place-items: center;
  border-radius: var(--btn-radius);
}
body.shell-phone .crm-home.is-phone.sky-dash,
body.shell-phone .sky-page.sky-near-me {
  display: flex;
  flex-direction: column;
  min-height: calc(100dvh - var(--hdr-h) - var(--safe-top) - var(--bottom-nav-h) - var(--safe-bottom) - 20px);
  /* Nav is in-flow under .app-body ? only local breathing room. */
  padding-bottom: 12px;
}
/* Reserve sticky CTA clearance only when Start a visit is present (no phantom pad). */
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit),
body.shell-phone .sky-page.sky-near-me:has(.sky-sticky-visit) {
  padding-bottom: 74px;
}
@media (min-width: 901px) {
  /* Desk-only: under ONE UI (body.shell-phone) keep sticky CTAs on any width */
  body:not(.shell-phone) .home-start-cta { display: none; }
  body:not(.shell-phone) .sky-page.sky-near-me .home-start-cta.sky-sticky-visit { display: none !important; }
}
.shop-sky-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding-bottom: 0;
  margin-bottom: -4px;
}
.shop-sky-title h1 {
  margin: 0;
}
.sky-shop.is-pc {
  min-width: 0;
}
.shop-load-more-wrap {
  display: flex;
  justify-content: center;
  padding: 12px 0 4px;
  grid-column: 1 / -1;
}
.cust-load-more-wrap {
  display: flex;
  justify-content: center;
  padding: 14px 8px 10px;
}
.cust-load-more-wrap .btn {
  min-width: 12rem;
}
.cust-load-more-cap {
  display: none;
}
.sky-task-done-lab {
  display: inline-flex;
  align-items: center;
  min-height: var(--btn-h-sm, 32px);
  padding: 0 10px;
  font-size: var(--btn-fs-sm, 0.8rem);
  color: var(--muted, #8e8e93);
  opacity: 0.85;
}
.sky-hub-filter-note {
  margin: 4px 0 0;
  line-height: 1.35;
}
.outlets-map-controls.is-rail .sky-cust-filter-chips {
  margin: 0 0 8px;
}
.sky-reports-table .sky-reports-action {
  width: 1%;
  white-space: nowrap;
  text-align: right;
}
.sky-reports-table .sky-reports-sub {
  font-weight: 400;
}
.home-card .home-blocks {
  margin: 14px 0 8px;
}
.home-empty-hint {
  margin: 18px 0 8px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}

/* ?? Settings (iOS-style inset groups, CRM tokens) ?? */
.settings-panel.settings-page {
  padding: 18px 18px 22px;
  max-width: 820px;
  margin: 0 auto;
  box-sizing: border-box;
}
/* Catalogues (marketing PDFs) — preview grid hub (crm727) */
.settings-panel.catalogues-page {
  padding: 18px 18px 22px;
  max-width: 920px;
  margin: 0 auto;
  box-sizing: border-box;
}
.settings-panel.catalogues-page.cat-hub-page {
  max-width: 960px;
}
.settings-panel.catalogues-page .catalogues-list {
  margin: 0;
}
.settings-panel.catalogues-page .catalogues-row {
  display: flex;
  align-items: stretch;
  gap: 4px;
  padding: 0;
}
.settings-panel.catalogues-page .catalogues-row-open {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}
.settings-panel.catalogues-page .catalogues-row-open:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--btn-focus-ring, rgba(10, 132, 255, 0.55));
}
.settings-panel.catalogues-page .catalogues-share-btn {
  flex: 0 0 auto;
  align-self: center;
  margin-right: 8px;
  color: var(--accent, #0a84ff);
}
.settings-panel.catalogues-page .catalogues-row .settings-row-blurb {
  display: block;
  margin-top: 2px;
  font-size: 0.78rem;
  font-weight: 400;
  opacity: 0.72;
}

/* Catalogues hub — tab seg, search, recent strip, preview grid */
/* crm860: Catalogues | Price lists = same control family as Products Gen|COD|Ex CPT
   (shop-pl-seg): track --btn-h + pad 3px + gap 2px; buttons fill track (no height drift). */
.acal-seg.cat-hub-tab-seg,
.cat-hub-tab-seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  align-items: stretch;
  margin: 0 0 8px;
  width: 100%;
  max-width: 420px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 3px;
  gap: 2px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
.cat-hub-tab-seg .acal-seg-btn,
.cat-hub-tab-seg .acal-seg-btn.is-on {
  appearance: none;
  flex: unset;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  /* Fill track remaining — do not claim full --btn-h (track already includes padding). */
  height: 100%;
  min-height: 0;
  max-height: none;
  padding: 0 6px;
  margin: 0;
  border: 1px solid transparent;
  border-radius: var(--btn-radius-seg-item);
  line-height: 1.05;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cat-hub-tab-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}
/* Beat late phone .acal-seg { padding: 2px } + .acal-seg-btn { min-height: --btn-h }. */
body.shell-phone .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-tab-seg {
  padding: 3px;
  gap: 2px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
body.shell-phone .cat-hub-tab-seg .acal-seg-btn,
body.shell-phone .cat-hub-tab-seg .acal-seg-btn.is-on {
  height: 100%;
  min-height: 0;
  max-height: none;
  padding: 0 6px;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  border-radius: var(--btn-radius-seg-item);
  box-sizing: border-box;
}
.pl-hub-list-row .pl-hub-crumb {
  display: block;
  overflow-wrap: anywhere;
}
/* Price lists — folder browse (folders → subfolders → PDFs) */
.pl-hub-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 10px;
  min-width: 0;
}
.pl-hub-back {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: var(--btn-h-sm, 36px);
}
.pl-hub-crumbs {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  font-size: 0.84rem;
  line-height: 1.25;
}
.pl-hub-crumb-btn {
  margin: 0;
  padding: 2px 0;
  border: 0;
  background: transparent;
  color: var(--accent, #0a84ff);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.pl-hub-crumb-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--btn-focus-ring, rgba(10, 132, 255, 0.55));
  border-radius: 4px;
}
.pl-hub-crumb-sep {
  opacity: 0.45;
  user-select: none;
}
.pl-hub-crumb-current {
  color: var(--text, inherit);
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}
.pl-hub-folder-row .pl-hub-folder-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent, #0a84ff);
  background: rgba(10, 132, 255, 0.1);
}
.pl-hub-folder-row .cat-hub-cover-ph.is-sm {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: transparent;
}
body.shell-phone .bottom-nav-link[data-main-nav="catalogues"] .bottom-nav-lab {
  font-size: 0.58rem;
  white-space: normal;
  line-height: 1.05;
  max-height: 2.2em;
}
.cat-hub-search-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 2px 0 10px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}
.cat-hub-search {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  height: var(--btn-h, 44px);
  min-height: var(--btn-h, 44px);
  max-height: var(--btn-h, 44px);
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  background: var(--surface-2, rgba(255, 255, 255, 0.06));
  border: 1px solid var(--hairline, rgba(255, 255, 255, 0.08));
  box-sizing: border-box;
}
.cat-hub-search-ico {
  flex: 0 0 auto;
  display: inline-flex;
  opacity: 0.55;
  color: var(--muted, #8e8e93);
}
.cat-hub-search input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.95rem;
  padding: 0;
  height: 100%;
  line-height: 1.2;
  outline: none;
}
.cat-hub-search input::placeholder {
  color: var(--muted, #8e8e93);
  opacity: 0.85;
}
.cat-hub-filter-btn {
  flex: 0 0 auto;
}
.cat-hub-sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 8px;
  min-height: 24px;
}
.cat-hub-sec-lead {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-width: 0;
}
.cat-hub-sec-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted, #8e8e93);
}
.cat-hub-updated {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-transform: none;
  color: var(--muted, #8e8e93);
  opacity: 0.92;
  line-height: 1.25;
}
.cat-hub-sec-trail {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.cat-hub-count {
  font-size: 0.78rem;
  color: var(--muted, #8e8e93);
  opacity: 0.9;
}
/* crm863: grid|list icons = Gen / Catalogues|Price lists track metrics */
.cat-hub-view-seg {
  display: inline-flex;
  align-items: stretch;
  gap: 2px;
  padding: 3px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
.cat-hub-view-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: calc(var(--btn-h) - 6px);
  height: 100%;
  min-height: 0;
  max-height: none;
  margin: 0;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: var(--btn-radius-seg-item);
  background: transparent;
  color: var(--muted, #8e8e93);
  cursor: pointer;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.cat-hub-view-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}
.cat-hub-view-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.cat-hub-recent {
  margin: 0 0 18px;
}
.cat-hub-recent-strip {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 2px 2px 8px;
  scroll-snap-type: x proximity;
}
.cat-hub-recent-card {
  flex: 0 0 auto;
  width: min(220px, 62vw);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cat-hub-recent-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  padding: 0 2px;
}
.cat-hub-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
@media (min-width: 720px) {
  .cat-hub-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
}
@media (min-width: 1100px) {
  .cat-hub-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.cat-hub-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  padding: 10px;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  background: var(--surface-2, rgba(255, 255, 255, 0.05));
  border: 1px solid var(--hairline, rgba(255, 255, 255, 0.07));
  box-sizing: border-box;
}
.cat-hub-cover {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  overflow: hidden;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02));
  cursor: pointer;
  position: relative;
  -webkit-tap-highlight-color: transparent;
  transition: transform 140ms ease, box-shadow 140ms ease;
}
.cat-hub-cover.is-wide {
  aspect-ratio: 16 / 10;
}
.cat-hub-cover:active {
  transform: scale(0.985);
}
.cat-hub-cover:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--btn-focus-ring, rgba(10, 132, 255, 0.55));
}
.cat-hub-cover-img,
.cat-hub-list-thumb-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}
.cat-hub-cover-ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted, #8e8e93);
  opacity: 0.55;
}
.cat-hub-cover-ph.is-sm {
  position: static;
  width: 100%;
  height: 100%;
}
.cat-hub-card-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}
.cat-hub-card-title {
  display: block;
  font-size: 0.92rem;
  font-weight: var(--fw-strong, 650);
  line-height: 1.25;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.cat-hub-card-meta {
  display: block;
  font-size: 0.72rem;
  color: var(--muted, #8e8e93);
  line-height: 1.3;
}
.cat-hub-card-acts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 6px;
}
.cat-hub-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: var(--btn-h-sm, 36px);
  width: 100%;
  padding-inline: 8px;
}
.cat-hub-act[data-catalogue-open] {
  color: var(--accent, #0a84ff);
  border-color: rgba(10, 132, 255, 0.35);
}
.cat-hub-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: var(--radius-sm, 12px);
  background: var(--surface-2, rgba(255, 255, 255, 0.04));
  border: 1px solid var(--hairline, rgba(255, 255, 255, 0.07));
  overflow: hidden;
}
.cat-hub-list-row {
  display: flex;
  align-items: stretch;
  gap: 2px;
  border-bottom: 1px solid var(--hairline, rgba(255, 255, 255, 0.06));
}
.cat-hub-list-row:last-child {
  border-bottom: 0;
}
.cat-hub-list-open {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 10px 12px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}
.cat-hub-list-open:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px var(--btn-focus-ring, rgba(10, 132, 255, 0.55));
}
.cat-hub-list-thumb {
  flex: 0 0 auto;
  width: 44px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
  position: relative;
}
.cat-hub-list-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.settings-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 4px;
}
.settings-head-txt {
  min-width: 0;
  flex: 1;
}
.settings-head-txt h1 {
  margin: 0 0 4px;
  font-size: 1.35rem;
  line-height: 1.2;
  font-weight: var(--fw-strong);
  text-align: left;
  letter-spacing: -0.02em;
}
.settings-head-blurb {
  margin: 0;
  max-width: 42rem;
  text-align: left;
}
.settings-stack {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 14px;
}
.settings-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.settings-section-label {
  margin: 0 0 0 14px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 88%, transparent);
}
/* iOS-style inset group cards ? same elevated fill as .ios-hub-group-body */
.settings-list {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.settings-row {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 0;
  padding: 10px 14px;
  border: 0;
  border-bottom: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  min-height: var(--btn-h);
  box-sizing: border-box;
  position: relative;
}
/* Hairline inset after icon tile (not full-bleed) */
.settings-list > .settings-row:not(:last-child)::after,
.settings-list > .settings-role-group:not(:last-child)::after,
.settings-list > .settings-img-preview-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: calc(14px + 30px + 12px);
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.settings-list > .settings-role-group,
.settings-list > .settings-img-preview-row {
  position: relative;
}
.settings-row.is-nav {
  cursor: pointer;
  transition: background 0.12s var(--ease);
}
.settings-row.is-nav:hover {
  background: rgba(255, 255, 255, 0.05);
}
.settings-row.is-nav:active {
  background: rgba(255, 255, 255, 0.09);
}
.settings-row.is-nav.is-on {
  background: var(--btn-chip-on-bg);
  box-shadow: inset 0 0 0 1px var(--btn-chip-on-border), var(--btn-chip-on-shadow);
}
/* Forms list picks stay quiet (tap opens template ? no blue wash). */
.forms-editor-pick.is-on {
  background: transparent;
  box-shadow: none;
}
.settings-row-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.1);
  border: 0;
  color: #fff;
}
.settings-row-ico svg {
  width: 17px;
  height: 17px;
  display: block;
}
/* Colored icon tiles (CRM dark ? tint fills, white glyph) */
.settings-row-ico[data-ico="blue"] {
  background: color-mix(in srgb, var(--accent) 92%, #000 8%);
}
.settings-row-ico[data-ico="teal"] {
  background: #30b0c7;
}
.settings-row-ico[data-ico="amber"] {
  background: #ff9f0a;
}
.settings-row-ico[data-ico="green"] {
  background: #30d158;
}
.settings-row-ico[data-ico="indigo"] {
  background: #5e5ce6;
}
.settings-row-ico[data-ico="slate"] {
  background: #636366;
}
.settings-row-ico[data-ico="purple"] {
  background: #bf5af2;
}
.settings-row-ico[data-ico="red"] {
  background: var(--danger);
}
.settings-row-main {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
}
.settings-row-title {
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  line-height: 1.25;
}
.settings-row-blurb {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.3;
}
.settings-row-trail {
  display: inline-flex;
  align-items: center;
  flex: none;
  gap: 8px;
  margin-left: 4px;
}
.settings-row-chev {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  color: var(--ink-secondary);
  opacity: 0.55;
}
.settings-row.is-nav:hover .settings-row-chev {
  color: var(--accent);
  opacity: 1;
}
.settings-row-btn {
  min-height: var(--btn-h);
  padding: 0 14px;
  font-size: 0.84rem;
}
.settings-empty {
  margin: 4px 2px 0;
}
.settings-list > .settings-empty,
.settings-list > .sub.settings-empty {
  padding: 14px;
  margin: 0;
  text-align: left;
}
.settings-seg {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
}
.settings-seg-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: #ebebf5;
  font: inherit;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  padding: 8px 14px;
  min-height: var(--btn-h-sm);
  border-radius: var(--btn-radius-seg-item);
  cursor: pointer;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.settings-seg-btn:hover { color: #fff; }
.settings-seg-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.settings-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
/* ===== Canonical check control =====
   Every visible checkbox / radio in the CRM, so a filter layer in the Calendar
   rail, a role option in Settings and a line select in the cart all look the
   same instead of falling back to the raw browser control per page.
   Inputs inside `.settings-toggle` are the hidden driver of the iOS switch and
   opt out below. */
input[type="checkbox"],
input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin: 0;
  padding: 0;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  position: relative;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease);
}
input[type="radio"] {
  border-radius: 50%;
}
input[type="checkbox"]:hover:not(:disabled),
input[type="radio"]:hover:not(:disabled) {
  border-color: rgba(255, 255, 255, 0.45);
}
input[type="checkbox"]:checked,
input[type="radio"]:checked {
  background: var(--accent);
  border-color: var(--accent);
}
input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 3px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
input[type="radio"]:checked::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: #fff;
}
input[type="checkbox"]:focus-visible,
input[type="radio"]:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
input[type="checkbox"]:disabled,
input[type="radio"]:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
}
.settings-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}
.settings-toggle input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  min-width: 0;
  border: 0;
  background: none;
  appearance: none;
}
.settings-toggle-ui {
  display: block;
  width: 46px;
  height: 28px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.2);
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease);
  position: relative;
}
.settings-toggle-ui::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  transition: transform 0.18s var(--ease);
}
.settings-toggle input:checked + .settings-toggle-ui {
  background: var(--accent);
  border-color: rgba(10, 132, 255, 0.55);
}
.settings-toggle input:checked + .settings-toggle-ui::after {
  transform: translateX(18px);
}
.settings-toggle input:focus-visible + .settings-toggle-ui {
  box-shadow: var(--btn-focus-ring);
}
.settings-check {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}
.settings-check input[type="checkbox"] {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  opacity: 0;
  pointer-events: none;
}
.settings-check-ui {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  box-sizing: border-box;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), transform 0.1s var(--ease);
}
.settings-check input:not(:checked) + .settings-check-ui svg {
  visibility: hidden;
}
.settings-check input:checked + .settings-check-ui {
  background: var(--accent);
  border-color: var(--accent);
}
.settings-check input:checked + .settings-check-ui:empty::after {
  content: "";
  width: 5px;
  height: 10px;
  margin-top: -2px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.settings-check:active .settings-check-ui {
  transform: scale(0.92);
}
.settings-check input:focus-visible + .settings-check-ui {
  box-shadow: var(--btn-focus-ring);
}
.settings-check-sm { font-size: 0.84rem; }
.settings-check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 6px 10px;
  margin-top: 0;
}
.settings-role-intro,
.settings-forms-intro {
  margin: 0 2px 2px;
  text-align: left;
  font-size: 0.86rem;
}
.settings-role-opts-legend {
  margin-top: 10px;
}
/* Role access ? inset settings-list groups (no admin-card chrome) */
.settings-role-group {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: visible;
  position: relative;
}
.settings-role-head.settings-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: default;
}
.settings-role-expand {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.settings-role-expand:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
  border-radius: var(--btn-chip-radius);
}
.settings-role-head .settings-row-trail {
  gap: 8px;
  flex: none;
  align-items: center;
}
.settings-role-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.settings-role-toolbar .settings-section-label {
  margin: 0;
}
.settings-role-rename.btn.small {
  flex: none;
  white-space: nowrap;
}
.settings-role-tip {
  margin: 0 0 10px;
  opacity: 0.85;
}
.settings-role-code {
  display: inline-flex;
  align-items: center;
  flex: none;
  padding: 4px 8px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.settings-role-chev {
  display: inline-flex;
  color: var(--muted);
  transition: transform 0.18s var(--ease);
}
.settings-role-group.is-open .settings-role-chev {
  transform: rotate(180deg);
}
.settings-role-body {
  padding: 0;
  border-top: 0;
}
.settings-role-checks {
  margin-top: 0;
}
.settings-role-list.settings-list {
  gap: 0;
}
.settings-role-opts {
  display: flex;
  flex-direction: column;
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
  overflow: visible;
}
.settings-role-opts .settings-role-opt {
  padding-left: 14px;
  padding-right: 14px;
}
.settings-role-opts .settings-role-opt:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.settings-role-opt .settings-row-main {
  min-width: 0;
}
.settings-role-opt .settings-row-trail {
  flex: 0 0 auto;
}
.settings-role-editor.is-loading .crm-skel {
  margin: 8px 0 12px;
}
/* crm720 Permissions: stacked kit sections (not ragged 2-col masonry cards) */
.settings-role-sec {
  margin: 0;
  min-width: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.settings-role-sec > .admin-opt-sec.settings-role-sec-label,
.settings-role-sec-label.admin-opt-sec {
  margin: 0 2px 6px;
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.88;
}
.settings-role-full {
  margin: 0 2px 10px;
}
.settings-role-menu {
  position: relative;
  width: min(100%, 320px);
  margin-top: 4px;
  z-index: 5;
}
.settings-role-menu-trigger.btn {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 18px;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: var(--btn-h);
  margin: 0;
  text-align: left;
}
.settings-role-menu-label {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.settings-role-menu-trigger strong {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.settings-role-menu-chev {
  display: inline-flex;
  justify-content: center;
  color: var(--muted);
  transition: transform 0.15s var(--ease);
}
.settings-role-menu-trigger[aria-expanded="true"] .settings-role-menu-chev {
  transform: rotate(180deg);
}
.settings-role-menu-popover {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.48);
}
.settings-role-menu-option {
  appearance: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24px;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: var(--btn-h);
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.settings-role-menu-option:last-child {
  border-bottom: 0;
}
.settings-role-menu-option:hover,
.settings-role-menu-option:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}
.settings-role-menu-option.is-on {
  font-weight: var(--fw-semi);
}
.settings-role-menu-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  color: var(--accent);
}
.settings-role-selected {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.settings-role-selected-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
}
.settings-role-selected-head > :first-child {
  min-width: 0;
}
.settings-role-selected-head > :first-child > strong,
.settings-role-selected-count {
  display: block;
}
.settings-role-selected-count {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.78rem;
}
.settings-role-settings-menu {
  margin-bottom: 12px;
}
.settings-role-settings-list .settings-role-opts {
  display: flex;
  flex-direction: column;
}
.settings-role-settings-list .settings-role-opt {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24px;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 10px 14px;
}
.settings-role-settings-list .settings-role-opt .settings-row-trail {
  width: 24px;
  margin: 0;
}
.settings-role-selected-title {
  margin: 0 0 2px;
  font-size: 1.05rem;
  line-height: 1.25;
}
.settings-role-selected-head .sub {
  margin: 0;
}
.settings-role-permission-list {
  overflow: visible;
  border: 0;
  background: transparent;
  box-shadow: none;
}
.settings-role-permission-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}
/* Legacy alias if any leftover markup still uses the old grid class */
.settings-role-permission-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
  align-items: stretch;
}
.settings-user-roles-editor .settings-role-opts.settings-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.settings-user-roles-editor .settings-role-opts.settings-list .settings-role-opt {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 10px 14px;
}
.settings-user-roles-editor .settings-role-opts.settings-list .settings-role-opt .settings-row-title {
  overflow-wrap: anywhere;
  font-size: 0.9rem;
  line-height: 1.3;
  font-weight: var(--fw-med);
}
.settings-user-roles-editor .settings-role-opts.settings-list .settings-role-opt .settings-row-trail {
  width: 28px;
  margin: 0;
  align-self: center;
  justify-content: flex-end;
}
.settings-user-roles-editor .settings-role-opts.settings-list .settings-role-opt:not(:last-child)::after {
  left: 14px;
  right: 14px;
  height: 1px;
  background: var(--line);
}
/* Quiet single-column section cards — equal peers, no ragged 2-col wells */
.settings-user-roles-editor .settings-role-permission-stack {
  max-width: 720px;
}
.settings-user-roles-editor .settings-role-opts.settings-list {
  background: var(--bg-elevated-2, var(--bg-elevated));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.settings-role-foot {
  margin: 8px 0 0;
  opacity: 0.72;
  font-size: 0.82rem;
}
/* wave3: hidden native select drivers for phone chips/seg */
select.acct-change-select[aria-hidden="true"],
select.af-pick-select,
select.admin-role-select {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
.acct-change-fold {
  margin-top: 8px;
}
.acct-change-fold .sky-filter-fold {
  min-height: 40px;
  padding: 8px 4px;
}
.acct-change-fold .admin-opt-group {
  margin-top: 4px;
}
.af-pick-group {
  margin-top: 8px;
}
.sky-field .af-pick-group {
  margin-top: 6px;
}
/* Call Form inline pick lists (Call site / Call type) — scroll when long. */
body.shell-phone .call-form-fields .sky-field .af-pick-group.admin-opt-group {
  max-height: min(48vh, 360px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.acal-assign-pick {
  margin-top: 4px;
}
.acal-assign-pick .admin-opt-sec {
  margin: 0 0 4px;
}
.acal-assign-free {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 14px;
}
.acal-assign-free input {
  width: 100%;
}
.af-pick-chips,
.admin-user-role-chips,
.forms-editor-kind-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.forms-editor-kind-picks.admin-opt-group {
  margin-top: 6px;
}
.forms-editor-kind-picks .ios-filter-row {
  width: 100%;
}
.af-pick-seg {
  margin-top: 8px;
  width: 100%;
  max-width: 360px;
}
.af-pick-seg .settings-seg-btn {
  flex: 1 1 0;
}
/* Pack 1: Warehouse chooser removed ? keep rule inert if any leftover markup */
.cart-wh-seg {
  display: none !important;
}
.admin-user-role-chips {
  margin-top: 6px;
  text-transform: none;
  letter-spacing: 0;
}
.forms-editor-kind {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.forms-editor-kind-lab {
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
}
.forms-editor-dep-row {
  grid-column: 1 / -1;
  margin-top: 4px;
}
body:not(.shell-phone) .acct-change-fold {
  display: none;
}
.settings-img-preview-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px 14px;
  border-bottom: 0;
  background: rgba(0, 0, 0, 0.12);
}
.settings-img-preview-lab {
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.settings-img-preview {
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.settings-img-preview-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  min-height: 0;
}
.settings-img-preview-item .meta h3 {
  margin: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
}
.settings-img-preview-ph {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  opacity: 0.55;
}
.settings-img-preview.products.img-xl .settings-img-preview-item {
  flex-direction: row;
  align-items: center;
}
.settings-img-preview.products.img-xl .product-media {
  width: 72px;
  height: 72px;
  max-height: 72px;
  aspect-ratio: auto;
}
.settings-role-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-top: 4px;
}
.settings-role-editor .btn { margin-top: 0; }
/* Passkey devices live as settings-rows inside Security (not a sibling ul) */
.settings-passkey-row .settings-row-main {
  min-width: 0;
}
.settings-passkey-row .settings-row-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.settings-passkey-row .passkey-revoke-mine {
  min-height: 44px;
}
.settings-list > .settings-passkey-row:not(:last-child)::after {
  left: 14px;
}
.settings-passkey-empty {
  margin: 0;
}
.settings-soon-pill {
  display: inline-flex;
  align-items: center;
  flex: none;
  padding: 5px 10px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
  white-space: nowrap;
}
.settings-row.is-soon {
  cursor: default;
  opacity: 0.92;
}
.settings-logout-row .settings-logout-title {
  color: var(--danger);
  font-weight: var(--fw-med);
}
.settings-logout-row:hover {
  background: color-mix(in srgb, var(--danger) 10%, transparent);
}
.settings-logout-row:active {
  background: color-mix(in srgb, var(--danger) 16%, transparent);
}
/* Profile hero — iOS Apple Account row (hub → Account page) */
.settings-profile-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  margin: 0;
  padding: 16px 14px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  min-height: 72px;
  box-sizing: border-box;
  position: relative;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  appearance: none;
}
.settings-profile-hero:hover {
  background: color-mix(in srgb, var(--ink) 4%, transparent);
}
.settings-profile-hero:active {
  background: color-mix(in srgb, var(--ink) 8%, transparent);
  transform: scale(0.992);
}
.settings-profile-hero:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.settings-profile-hero .settings-row-chev {
  flex: none;
  opacity: 0.45;
  margin-left: auto;
}
.settings-profile-hero-avatar {
  flex: none;
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.settings-profile-hero .settings-profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  display: block;
  background: rgba(255, 255, 255, 0.08);
  border: 0;
}
.settings-profile-hero .settings-profile-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 1.45rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
}
.settings-profile-hero-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.settings-profile-hero-name {
  font-size: 1.15rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.settings-profile-hero-meta {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.3;
}
.settings-profile-ico {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  padding: 0;
  overflow: hidden;
  background: transparent;
  border: none;
  color: inherit;
}
.settings-profile-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}
.settings-profile-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
}
.settings-profile-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}
.settings-profile-row .settings-row-trail {
  flex-shrink: 0;
}
.settings-profile-change {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  margin: 0;
  padding: 0 2px 0 4px;
  border: 0;
  border-radius: var(--btn-radius-seg-item);
  background: transparent;
  color: var(--ink-secondary);
  cursor: pointer;
  font: inherit;
}
.settings-profile-change:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.settings-profile-change:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
  color: var(--btn-disabled-fg);
}
.settings-profile-change .settings-row-chev {
  opacity: 0.55;
}
.settings-profile-change-lab:empty {
  display: none;
}
.settings-profile-remove {
  color: var(--danger);
}
/* Account page — Apple Account style (crm594) */
.settings-account-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 420px;
  margin: 0 auto;
  width: 100%;
}
.settings-account-hero {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
  padding: 16px;
}
.settings-account-profile-grid {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
}
.settings-account-identity {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 4px;
}
.settings-account-identity strong {
  overflow: hidden;
  font-size: 1.12rem;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.settings-account-identity span {
  color: var(--muted);
  font-size: 0.86rem;
}
.settings-account-avatar-btn {
  appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  line-height: 0;
  -webkit-tap-highlight-color: transparent;
}
.settings-account-avatar-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.settings-account-avatar-btn:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
}
.settings-account-avatar {
  width: 104px;
  height: 104px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  display: block;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}
.settings-account-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 104px;
  height: 104px;
  font-size: 2.4rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.settings-account-profile-card {
  overflow: visible;
}
.settings-account-photo-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: 8px;
}
.settings-account-photo-actions .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  min-height: var(--btn-h);
  padding: var(--btn-pad-y) var(--btn-pad-x);
}
.settings-account-photo-actions .btn:only-of-type {
  grid-column: 1 / -1;
}
.settings-account-photo-actions .settings-profile-remove {
  color: var(--danger);
}
.settings-account-photo-actions .settings-profile-remove:is(:hover, :focus-visible) {
  color: var(--danger);
}
.settings-account-field .settings-row-main {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  align-items: center;
  width: 100%;
  gap: 4px;
}
.settings-account-field .settings-row-title {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: var(--fw-med);
}
.settings-account-phone-line {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
}
.settings-account-dial-btn {
  appearance: none;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: var(--btn-ghost-bg, rgba(255, 255, 255, 0.06));
  box-shadow: var(--btn-ghost-shadow, none);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  line-height: 1.2;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.settings-account-dial-btn:hover {
  background: var(--btn-ghost-bg-hover, rgba(255, 255, 255, 0.1));
}
.settings-account-dial-btn:active {
  transform: scale(0.97);
}
.settings-account-dial-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.settings-account-dial-btn:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
}
.settings-account-dial-flag {
  font-size: 1.15rem;
  line-height: 1;
}
.settings-account-dial-code {
  letter-spacing: 0.01em;
}
.settings-account-dial-chev {
  display: inline-flex;
  opacity: 0.55;
  margin-left: 1px;
}
.settings-account-phone-line .settings-account-input {
  flex: 1 1 auto;
  min-width: 0;
}
.settings-account-input {
  width: 100%;
  margin: 0;
  padding: 4px 0 2px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 1.02rem;
  line-height: 1.35;
  outline: none;
  box-sizing: border-box;
}
.settings-account-input::placeholder {
  color: var(--muted);
  opacity: 0.75;
}
.settings-account-input:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
}
.settings-account-email {
  display: block;
  margin-top: 2px;
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.35;
  word-break: break-word;
}
.settings-account-actions {
  display: flex;
  justify-content: flex-end;
  padding: 0;
}
.settings-account-actions .btn {
  flex: 0 0 128px;
  width: 128px;
  max-width: 100%;
  min-width: 112px;
  min-height: var(--btn-h);
}
/* crm810: quiet push unavailable note on Account */
.settings-account-alerts-note {
  margin: 10px 0 0;
  text-align: center;
  opacity: 0.72;
}
/* Account Cell country dial sheet */
.account-dial-panel {
  max-height: min(78dvh, 640px);
  display: flex;
  flex-direction: column;
}
.account-dial-menu {
  min-height: 0;
  overflow: hidden;
}
.account-dial-search-wrap {
  padding: 0 2px 10px;
}
.account-dial-search {
  width: 100%;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  outline: none;
  box-sizing: border-box;
}
.account-dial-search:focus-visible {
  box-shadow: var(--btn-focus-ring);
}
.account-dial-list {
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  max-height: min(56dvh, 480px);
  padding-bottom: var(--sheet-nav-clear, 4px);
  flex: 1 1 auto;
  min-height: 0;
}
.account-dial-opt {
  width: 100%;
  text-align: left;
}
.account-dial-opt .admin-opt-lab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.account-dial-opt-flag {
  font-size: 1.25rem;
  line-height: 1;
}
.account-dial-opt-code {
  color: var(--muted);
  font-weight: var(--fw-reg, 400);
}
.account-dial-empty {
  margin: 12px 4px;
  text-align: center;
}
.home-avatar-btn {
  appearance: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  line-height: 0;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.home-avatar-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.home-avatar-btn:active {
  transform: scale(0.96);
}
.hdr-settings-ico,
.hdr-timeline-ico,
.hdr-cart-ico,
.hdr-refresh-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}
.hdr-settings-ico svg,
.hdr-timeline-ico svg,
.hdr-cart-ico svg,
.hdr-refresh-ico svg {
  width: 18px;
  height: 18px;
  display: block;
}
.hdr-cart-btn {
  position: relative;
}
.hdr-cart-btn .hdr-cart-badge {
  position: absolute;
  top: 4px;
  right: 3px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: var(--btn-radius);
  background: var(--accent);
  color: #fff;
  font-size: 0.62rem;
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
  display: grid;
  place-items: center;
  line-height: 1;
  pointer-events: none;
  box-shadow: 0 0 0 2px var(--bg, #000);
}
.hdr-cart-btn .hdr-cart-badge[hidden] {
  display: none !important;
}
.hdr-cart-btn.has-items {
  color: var(--accent-press);
}

/* ?? Home agenda widget (compact) ?? */
.home-widget {
  margin: 14px 0 8px;
  border-radius: var(--radius-sm);
  background: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.home-widget-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.home-widget-kicker {
  margin: 0 0 2px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #ff453a;
}
.home-widget-title h2 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.home-widget-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.home-widget-count {
  font-size: 0.8rem;
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}
/* Widget CTA uses .btn.small.primary tokens ? keep spacing only */
.home-widget-cal-btn {
  margin: 0;
  flex-shrink: 0;
}
.home-widget-fail {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 4px 0 2px;
}
.home-soft-fail {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: var(--bg-elevated-2, rgba(255, 255, 255, 0.04));
}
.home-soft-fail .msg,
.home-soft-fail .sub {
  margin: 0;
  flex: 1 1 160px;
}
.home-kpi-fail {
  margin-top: 8px;
}
.home-widget-body {
  padding: 10px 12px 14px;
  max-height: min(58vh, 520px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.home-widget-empty {
  margin: 12px 4px;
  color: var(--muted);
  font-size: 0.92rem;
}
.home-widget-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.home-widget-row {
  appearance: none;
  border: 0;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  cursor: pointer;
}
.home-widget-row.is-overdue {
  background: rgba(255, 69, 58, 0.12);
  box-shadow: inset 3px 0 0 var(--sky-late);
}
.home-widget-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: 6px;
  flex-shrink: 0;
}
.home-widget-row-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.home-widget-row-main strong {
  font-size: 0.92rem;
  font-weight: var(--fw-semi);
}
.home-widget-row-main span {
  font-size: 0.78rem;
  color: var(--muted);
}
.home-widget .route-panel { gap: 10px; }
.home-widget .route-summary {
  margin: 0;
  padding: 12px 14px;
}
.home-widget .route-list {
  max-height: none;
}

/* ?? Full Calendar page ?? */
.day-board-acal {
  padding: 0 !important;
  background: #0b0b0c !important;
  max-width: none;
  border-radius: 16px;
  overflow: hidden;
}
.acal-page-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  padding: 0 4px;
}
.acal-page-bar h1 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: var(--fw-strong);
}
.app-shell.wide:has(.day-board-acal),
.app-shell.screen.wide:has(.day-board-acal) {
  max-width: none;
  width: 100%;
}
/* Calendar page fills width (filters live inside sky-desk, not app side-nav) */
.app-shell:has(.day-board-acal) .app-body {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  /* Fill the flex scrollport ? do not re-add 100dvh (that overflowed the shell past the nav). */
  min-height: 0;
  height: 100%;
}
.app-content:has(.day-board-acal) {
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.app-content:has(.day-board-acal) > .card.day-board-acal {
  margin: 0;
  padding: 0 !important;
  overflow: hidden;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

/* Combined Calendar + Tasks plan page ? Tasks on top, calendar below */
.crm-plan-page {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}
.crm-plan-tasks {
  flex: 0 1 auto;
  max-height: min(28vh, 260px);
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: #0d0d0f;
  padding: 8px 12px 8px;
  gap: 6px;
}
.crm-plan-tasks.is-folded {
  max-height: none;
  min-height: 0;
  flex: 0 0 auto;
  padding: 6px 12px;
  gap: 0;
}
.crm-plan-tasks.is-folded .crm-plan-tasks-head {
  gap: 8px;
}
.crm-plan-tasks-count {
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  margin-left: 6px;
}
.crm-plan-tasks-fold {
  flex: 0 0 auto;
}
.crm-plan-tasks.is-focus {
  box-shadow: inset 0 0 0 1px var(--btn-focus-ring, rgba(10, 132, 255, 0.45));
}
.crm-plan-tasks-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}
.crm-plan-tasks-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  margin-right: auto;
}
.crm-plan-tasks-titles h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-strong, 650);
  letter-spacing: -0.01em;
}
.crm-plan-tasks-titles .sub {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted, #8e8e93);
}
.crm-plan-tasks-status,
.crm-plan-tasks-scope {
  flex: 0 0 auto;
}
/* Compact seg height on the tasks strip (phone + PC); PC media adds My day polish. */
.crm-plan-tasks .acal-seg-btn {
  min-height: 32px;
  padding: 5px 12px;
  font-size: 0.76rem;
}
.crm-plan-tasks-filters .sky-cust-filter-chip {
  width: auto;
}
.crm-plan-tasks-search {
  flex: 1 1 140px;
  min-width: 120px;
  max-width: 280px;
}
.crm-plan-tasks-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.crm-plan-tasks-meta {
  margin: 0;
  padding: 0;
  font-size: 0.75rem;
  color: var(--muted, #8e8e93);
}
.crm-plan-tasks-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}
/* PC desk: Tasks segs match Calendar My day / Week premium track. */
@media (min-width: 901px) {
  body:not(.shell-phone) .crm-plan-tasks .acal-seg {
    padding: 3px;
    border-radius: var(--btn-radius-seg);
    background: var(--btn-seg-track);
    box-shadow:
      inset 0 0 0 0.5px rgba(255, 255, 255, 0.08),
      0 1px 2px rgba(0, 0, 0, 0.22);
  }
  body:not(.shell-phone) .crm-plan-tasks .acal-seg-btn {
    min-height: var(--btn-h-sm);
    padding: 5px 12px;
    font-size: 0.76rem;
    color: rgba(235, 235, 245, 0.72);
    border-radius: var(--btn-radius-seg-item);
  }
  body:not(.shell-phone) .crm-plan-tasks .acal-seg-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
  }
  /* Same selected look as Calendar Month|Week|Day — light-blue seg-on. */
  body:not(.shell-phone) .crm-plan-tasks .acal-seg-btn.is-on {
    background: var(--btn-seg-on);
    color: #fff;
    box-shadow: var(--btn-seg-on-shadow);
  }
  /* Float ON: page scrolls; tasks stick at top. OFF keeps flex split (overflow hidden). */
  body:not(.shell-phone) .crm-plan-page.is-tasks-float {
    overflow: auto;
    overflow-x: hidden;
  }
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-tasks.is-float {
    position: sticky;
    top: 0;
    z-index: 40;
    flex: 0 0 auto;
    max-height: min(32vh, 280px);
    box-shadow: 0 10px 28px -16px rgba(0, 0, 0, 0.75);
    border-bottom-color: rgba(255, 255, 255, 0.12);
  }
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-tasks.is-float.is-collapsed {
    max-height: none;
    min-height: 0;
  }
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-tasks.is-float.is-collapsed .crm-plan-tasks-body,
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-tasks.is-float.is-collapsed .crm-plan-tasks-meta {
    display: none;
  }
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-calendar {
    overflow: visible;
    flex: 0 0 auto;
    min-height: min(72vh, 720px);
  }
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-calendar > .acal,
  body:not(.shell-phone) .crm-plan-page.is-tasks-float .crm-plan-calendar > .route-board {
    min-height: min(72vh, 720px);
  }
}
.crm-plan-tasks-body .sky-tasks-table {
  min-height: 0;
}
.crm-plan-tasks-body .sky-empty-chart {
  padding: 10px 8px;
}
.crm-plan-tasks-body .sky-empty-chart .sky-empty-ico {
  display: none;
}
.crm-plan-calendar {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.crm-plan-calendar > .acal,
.crm-plan-calendar > .route-board {
  flex: 1 1 auto;
  min-height: 0;
}
body.shell-phone .crm-plan-page {
  overflow: auto;
}
body.shell-phone .crm-plan-tasks {
  max-height: none;
  min-height: 0;
  flex: 0 0 auto;
}
/* Collapsed Tasks = slim chip row; expanded body still capped so My day keeps room. */
body.shell-phone .crm-plan-tasks.is-folded {
  padding: 6px 10px;
}
body.shell-phone .crm-plan-tasks.is-folded .crm-plan-tasks-head {
  flex-wrap: nowrap;
  gap: 8px;
}
body.shell-phone .crm-plan-tasks.is-folded .crm-plan-tasks-titles {
  display: none;
}
body.shell-phone .crm-plan-tasks-body {
  max-height: min(42vh, 320px);
}
/* iOS densify ? plan Tasks segs/chips/Done hit --btn-h (override 28/32 family). */
body.shell-phone .crm-plan-tasks-head {
  gap: 8px;
  align-items: center;
}
body.shell-phone .crm-plan-tasks-titles h2 {
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: visible;
}
body.shell-phone .crm-plan-tasks-titles .sub {
  font-size: 0.68rem;
  line-height: 1.2;
}
body.shell-phone .crm-plan-tasks .acal-seg-btn {
  min-height: var(--btn-h);
  padding: 8px 12px;
  font-size: 0.82rem;
  white-space: nowrap;
}
body.shell-phone .crm-plan-tasks-filters {
  flex-wrap: wrap;
  gap: 8px;
}
body.shell-phone .crm-plan-tasks-filters .sky-cust-filter-chip,
body.shell-phone .crm-plan-tasks .crm-plan-tasks-fold.sky-cust-filter-chip {
  min-height: var(--btn-h);
  padding: 8px 14px;
  font-size: 0.82rem;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
}
body.shell-phone .crm-plan-tasks .btn.sky-hub-add,
body.shell-phone .crm-plan-tasks .btn.primary.small.sky-hub-add {
  min-height: var(--btn-h);
  height: auto;
  padding: 0 14px;
  flex: 0 0 auto;
}
body.shell-phone .crm-plan-tasks .btn.ghost.sky-task-done-btn,
body.shell-phone .crm-plan-tasks .btn.ghost.small.sky-task-done-btn,
body.shell-phone .crm-plan-tasks-body .btn.ghost.sky-task-done-btn {
  min-height: var(--btn-h);
  height: auto;
  padding: 0 14px;
  font-size: var(--btn-fs-sm, 0.82rem);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
body.shell-phone .crm-plan-tasks-body .crm-ops-task {
  gap: 8px;
  padding: 8px 4px;
}
body.shell-phone .crm-plan-tasks-body .sky-hub-task-main {
  min-height: var(--btn-h);
}
body.shell-phone .crm-plan-tasks-body .sky-hub-task-main-txt strong {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
body.shell-phone .crm-plan-tasks-search {
  flex: 1 1 100%;
  max-width: none;
}
body.shell-phone .crm-plan-tasks-search input {
  min-height: var(--btn-h);
  font-size: 1rem;
}
body.shell-phone .crm-plan-tasks-meta {
  font-size: 0.72rem;
  line-height: 1.3;
}
/* Phone To-do / Calendar: denser expanded Tasks strip — no clipped chip labels.
   crm859: compress expanded head (titles + Open/All/Done + chips); keep Tasks. */
body.shell-phone .crm-plan-tasks:not(.is-folded) {
  padding: 6px 10px 8px;
  gap: 6px;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-head {
  flex-wrap: wrap;
  row-gap: 5px;
  column-gap: 6px;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-titles {
  flex: 1 1 auto;
  min-width: 0;
  gap: 0;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-titles h2 {
  font-size: 0.88rem;
  line-height: 1.15;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-titles .sub {
  font-size: 0.62rem;
  line-height: 1.15;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-status {
  flex: 1 1 auto;
  min-width: 0;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-status .acal-seg {
  width: 100%;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-status .acal-seg-btn {
  flex: 1 1 0;
  justify-content: center;
  min-height: var(--btn-h);
  padding: 6px 10px;
  font-size: 0.78rem;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-filters {
  gap: 5px;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-filters .sky-cust-filter-chip,
body.shell-phone .crm-plan-tasks:not(.is-folded) .crm-plan-tasks-fold.sky-cust-filter-chip {
  padding: 6px 12px;
  font-size: 0.78rem;
}
body.shell-phone .crm-plan-tasks:not(.is-folded) .btn.sky-hub-add,
body.shell-phone .crm-plan-tasks:not(.is-folded) .btn.primary.small.sky-hub-add {
  padding: 0 12px;
}
body.shell-phone .crm-plan-tasks-body .sky-empty-chart {
  padding: 20px 12px 16px;
}
body.shell-phone .crm-plan-tasks-body .sky-empty-chart p {
  white-space: normal;
  overflow: visible;
}
body.shell-phone .crm-plan-tasks-body .sky-empty-chart .sub {
  font-size: 0.78rem;
  line-height: 1.35;
}
body.shell-phone .crm-plan-calendar {
  overflow: visible;
  flex: 0 0 auto;
}
.acal-toolbar-slim {
  grid-template-columns: minmax(0, 1fr) auto;
}
.acal-toolbar-slim .acal-period {
  text-align: left;
}

.acal-mini-dow,
.acal-mini-grid {
  display: grid !important;
  grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
  width: 100%;
}
.acal-mini-dow span {
  text-align: center;
  font-size: 0.65rem;
  color: var(--acal-muted, #8e8e93);
}
.acal-mini-cell {
  width: 100%;
  min-width: 0;
}

.home-calendar {
  margin: 14px 0 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.22);
}
@media (min-width: 901px) {
  body:not(.shell-phone) .crm-home.is-pc .home-calendar {
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
}

/* ?? Apple Calendar (CRM) ?? */
.acal {
  --acal-line: rgba(255, 255, 255, 0.1);
  --acal-muted: #8e8e93;
  --acal-today: #0a84ff;
  --sky-late: #ff2d55;
  --sky-soon: #0a84ff;
  display: flex;
  flex-direction: column;
  min-height: 0;
  color: #f5f5f7;
  font-family: var(--font);
}
.acal.is-full {
  flex: 1;
  min-height: 0;
  height: 100%;
  max-height: none;
}
.acal-pad { padding: 16px; }
.acal-muted { color: var(--acal-muted); font-size: 0.8rem; }
.acal-toolbar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px 14px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--acal-line);
  background: linear-gradient(180deg, #1c1c1e 0%, #141416 100%);
  flex: 0 0 auto;
}
.acal-period {
  margin: 0;
  text-align: center;
  font-size: 1.05rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.acal-seg {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
}
.acal-seg-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: #ebebf5;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  padding: 7px 14px;
  min-height: var(--btn-h-sm);
  border-radius: var(--btn-radius-seg-item);
  cursor: pointer;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.acal-seg-btn:hover { color: #fff; }
.acal-seg-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
.acal-cpt-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--acal-line, rgba(255, 255, 255, 0.08));
  background: rgba(255, 159, 10, 0.1);
}
.acal-cpt-bar.is-fresh {
  background: rgba(48, 209, 88, 0.1);
}
.acal-cpt-bar.is-syncing {
  background: rgba(10, 132, 255, 0.12);
}
.acal-cpt-bar.is-error {
  background: rgba(255, 69, 58, 0.14);
}
.acal-cpt-bar-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.acal-cpt-bar-copy strong {
  font-size: 0.88rem;
  font-weight: var(--fw-semi);
}
.acal-cpt-bar-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--acal-muted, #8e8e93);
}
.acal-cpt-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(10, 132, 255, 0.55);
  animation: acal-cpt-pulse 1.1s ease-out infinite;
  flex-shrink: 0;
}
@keyframes acal-cpt-pulse {
  0% { box-shadow: 0 0 0 0 rgba(10, 132, 255, 0.55); }
  70% { box-shadow: 0 0 0 8px rgba(10, 132, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(10, 132, 255, 0); }
}
.acal-user-filter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 4px;
}
.acal-user-filter-compact .acal-user-filter-val {
  font-size: 0.78rem;
  color: var(--ink-secondary);
  font-weight: var(--fw-med);
}
.acal-user-filter-lab {
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  color: var(--acal-muted, #8e8e93);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.acal-user-filter select {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #2c2c2e;
  color: #f2f2f7;
  border-radius: 8px;
  padding: 6px 28px 6px 10px;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  max-width: 160px;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23ebebf5' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.acal-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: flex-end;
}
.acal-today-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-weight: var(--fw-semi);
  font-size: 0.88rem;
  padding: 6px 8px;
  cursor: pointer;
}
.acal-icon-btn {
  appearance: none;
  border: 0;
  background: #2c2c2e;
  color: #fff;
  width: var(--btn-icon-size);
  height: var(--btn-icon-size);
  border-radius: var(--btn-icon-radius);
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.14s var(--ease);
}
.acal-icon-btn svg {
  width: 16px;
  height: 16px;
  display: block;
}
.acal-icon-btn:hover { background: #3a3a3c; }
.acal-icon-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.acal-count {
  margin-left: 6px;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--acal-muted);
  font-variant-numeric: tabular-nums;
}
.acal-count.is-filtered {
  color: var(--accent, #0a84ff);
}
.acal-now {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 3;
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transform: translateY(-50%);
}
.acal-now i {
  flex: 1;
  height: 2px;
  background: #ff453a;
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(255, 69, 58, 0.45);
}
.acal-now span {
  font-size: 0.62rem;
  font-weight: var(--fw-strong);
  color: #ff453a;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.acal-event {
  appearance: none;
  border: 0;
  display: flex;
  align-items: stretch;
  gap: 0;
  width: 100%;
  height: 100%;
  text-align: left;
  padding: 0;
  border-radius: 8px;
  background: var(--acal-c, #bf5af2);
  background: color-mix(in srgb, var(--acal-c, #bf5af2) 82%, #000);
  color: #fff;
  cursor: pointer;
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
  transition: transform 0.12s var(--ease), filter 0.12s var(--ease);
}
.acal-event:hover { filter: brightness(1.06); }
.acal-event-bar {
  width: 5px;
  flex-shrink: 0;
  background: var(--acal-c, #bf5af2);
  box-shadow: 0 0 10px color-mix(in srgb, var(--acal-c, #bf5af2) 55%, transparent);
}
.acal-event-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 6px 8px;
  min-width: 0;
  flex: 1;
}
.acal-event.is-allday {
  height: auto;
  min-height: 38px;
}
.acal-event.is-overdue {
  background: color-mix(in srgb, #ff453a 75%, #000);
}
.acal-event.is-overdue .acal-event-bar { background: #ff453a; }
.acal-event.is-done {
  background: color-mix(in srgb, #ff2d55 72%, #000);
}
.acal-event.is-done .acal-event-bar { background: #ff2d55; }
/* Person-color mode: keep --acal-c fill; status = bar marks only. */
.acal-event.is-done-mark,
.acal-event.is-overdue-mark {
  background: color-mix(in srgb, var(--acal-c, #0a84ff) 55%, #000);
}
.acal-event.is-done-mark .acal-event-bar { background: #ff2d55; }
.acal-event.is-overdue-mark .acal-event-bar { background: #ff453a; }
.acal-event.is-type-delivery { box-shadow: inset -2px 0 0 rgba(100, 210, 255, 0.55); }
.acal-event.is-type-visit { box-shadow: inset -2px 0 0 rgba(48, 209, 88, 0.55); }
.acal-event.is-type-task { box-shadow: inset -2px 0 0 rgba(255, 214, 10, 0.55); }
.acal-detail-loc::before {
  content: none;
}

@media (max-width: 900px) {
  .acal-toolbar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
  }
  .acal-period { text-align: left; font-size: 0.98rem; }
  .acal-nav { justify-content: flex-end; }
}
.acal-body {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) 260px;
  flex: 1;
  min-height: 0;
  max-height: none;
}
.acal.is-full .acal-body {
  flex: 1;
  min-height: 0;
}
.acal.no-mini .acal-body {
  grid-template-columns: minmax(0, 1fr) 280px;
}
.acal.is-embedded {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--acal-line);
  background: #000;
  min-height: 420px;
}
.acal.is-embedded .acal-body {
  min-height: min(52vh, 480px);
  max-height: min(62vh, 560px);
}
.card .acal button.acal-mini-cell,
.card .acal button.acal-seg-btn,
.card .acal button.acal-today-btn,
.card .acal button.acal-icon-btn,
.card .acal button.acal-event,
.card .acal button.sky-day,
.card .acal button.sky-card-main,
.card .acal button.sky-card-go,
.card .acal button.sky-card-act,
.card .acal button.sky-strip-toggle {
  width: auto;
  max-width: none;
}
.acal-side,
.acal-rail {
  border-right: 1px solid var(--acal-line);
  background: #000;
  overflow: auto;
  padding: 12px;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
}
.acal-rail {
  border-right: 0;
  border-left: 1px solid var(--acal-line);
}
.acal-main {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #000;
}
.acal-mini-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.acal-mini-head strong {
  font-size: 0.85rem;
  font-weight: var(--fw-semi);
}
.acal-mini-dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 0.65rem;
  color: var(--acal-muted);
  margin-bottom: 4px;
}
.acal-mini-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.acal-mini-cell {
  appearance: none;
  border: 0;
  background: transparent;
  color: #f5f5f7;
  aspect-ratio: 1;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
  position: relative;
}
.acal-mini-cell.is-pad { visibility: hidden; pointer-events: none; }
.acal-mini-cell.is-today {
  background: var(--acal-today);
  color: #fff;
  font-weight: var(--fw-strong);
}
.acal-mini-cell.is-selected:not(.is-today) {
  box-shadow: inset 0 0 0 1.5px var(--accent);
}
.acal-mini-cell.has-events::after {
  content: "";
  position: absolute;
  bottom: 3px;
  left: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--sky-soon, var(--accent));
  transform: translateX(-50%);
}
.acal-mini-cell.has-late::after {
  background: var(--sky-late);
}
.acal-mini-cell.has-late.has-soon::after {
  box-shadow: 5px 0 0 var(--sky-soon);
}
.acal-mini-cell.is-today.has-events::after { background: #fff; }

/* ?? Skynamo-style To Do (CRM palette) ?? */
.sky-cal .acal-main {
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.sky-strip {
  flex: 0 0 auto;
  padding: 10px 12px 8px;
  border-bottom: 1px solid var(--acal-line);
  background: linear-gradient(180deg, #141416 0%, #0b0b0c 100%);
}
.sky-strip-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.sky-strip-toggle {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent, #0a84ff);
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
  padding: 4px 8px;
}
.sky-week {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.sky-day {
  appearance: none;
  border: 0;
  background: transparent;
  color: #f5f5f7;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 4px 2px 6px;
  border-radius: 14px;
  cursor: pointer;
  min-width: 0;
}
.sky-day:hover { background: rgba(255, 255, 255, 0.06); }
.sky-dow {
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  color: var(--acal-muted);
  letter-spacing: 0.04em;
}
.sky-num {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  line-height: 1;
}
.sky-day.is-today .sky-num {
  background: var(--acal-today);
  color: #fff;
}
.sky-day.is-selected:not(.is-today) .sky-num {
  box-shadow: inset 0 0 0 2px var(--accent, #0a84ff);
}
.sky-day.is-selected.is-today .sky-num {
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.35);
}
.sky-dots {
  display: flex;
  gap: 3px;
  min-height: 6px;
  align-items: center;
  justify-content: center;
}
.sky-dots i,
.sky-legend span,
.sky-month-dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  display: inline-block;
}
.sky-dots i.is-late,
.sky-legend span.is-late,
.sky-month-dots i.is-late { background: var(--sky-late); }
.sky-dots i.is-soon,
.sky-legend span.is-soon,
.sky-month-dots i.is-soon { background: var(--sky-soon); }
.sky-legend {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 10px 0 0;
  font-size: 0.7rem;
  color: var(--acal-muted);
  font-weight: 550;
}
.sky-legend span { margin-right: 2px; }
.sky-strip-month {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--acal-line);
}
.sky-cal-tab {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1;
}
.sky-day-head {
  padding: 14px 16px 6px;
  flex: 0 0 auto;
}
.sky-day-head h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.sky-day-head p {
  margin: 2px 0 0;
  color: var(--acal-muted);
  font-size: 0.88rem;
}
.sky-day-list {
  padding: 4px 12px 16px;
  flex: 1;
}
.sky-agenda {
  padding: 8px 12px 20px;
}
/* Phone To do / My day ? clear Today ? Upcoming ? Overdue sections */
.sky-todo-ordered .sky-todo-section {
  margin: 0 0 18px;
}
.sky-todo-sec-lab {
  margin: 0 0 8px;
  padding: 0 4px;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--acal-muted, var(--muted));
}
.sky-todo-ordered .sky-todo-section .sky-agenda-day {
  margin-bottom: 12px;
}
.sky-todo-ordered .sky-todo-section .sky-agenda-day.is-today .sky-agenda-head {
  display: none; /* section label already says Today */
}
body.shell-phone .sky-todo-ordered .sky-todo-section {
  margin: 0 0 12px;
}
body.shell-phone .sky-todo-sec-lab {
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  padding: 0 4px 2px;
  margin: 0 0 6px;
}
body.shell-phone .sky-todo-ordered .acal-muted.acal-pad {
  padding: 10px 12px;
  font-size: 0.84rem;
}
body.shell-phone .sky-agenda-empty {
  padding: 36px 16px 28px;
}
body.shell-phone .sky-agenda-empty-ico {
  width: 44px;
  height: 44px;
}
.acal.is-todo-simple .acal-toolbar-phone-combo {
  display: none; /* no My day/Team/Agenda mash ? To do is a personal list */
}
.acal.is-todo-simple .acal-toolbar-phone-title {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  min-width: 0;
  flex: 1 1 auto;
}
/* Keep "My to-do" readable in-toolbar (chrome title matches; no ellipsis hide). */
.acal.is-todo-simple .acal-toolbar-phone-title .acal-period {
  display: block;
  font-size: 0.95rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
}
.acal.is-todo-simple .acal-period-sub {
  font-size: 0.68rem;
}
.acal.is-todo-simple .acal-toolbar-phone-title .acal-count {
  margin-top: 1px;
}
.acal-period-sub {
  margin: 0;
  font-size: 0.72rem;
  font-weight: var(--fw-reg, 400);
  color: var(--acal-muted, var(--muted));
  line-height: 1.25;
}
/* Quiet centered empty state ? small muted icon over a short label, no card chrome. */
.sky-agenda-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 48px 16px 40px;
  text-align: center;
}
.sky-agenda-empty-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
}
.sky-agenda-empty-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  color: var(--ink-secondary);
}
.sky-agenda-day {
  margin: 0 0 22px;
}
/* Softened ? past days are context, not an alarm. Today/upcoming stay the focal point. */
.sky-agenda-day.is-past {
  opacity: 0.7;
}
.sky-agenda-day.is-today .sky-agenda-head strong {
  color: var(--accent, #0a84ff);
}
/* Collapsible "N overdue visits (older)" summary ? keeps today + upcoming front and center. */
.sky-agenda-overdue {
  margin: 0 0 14px;
  border-left: 3px solid var(--sky-late);
  border-radius: 0 12px 12px 0;
}
.sky-agenda-overdue-toggle {
  appearance: none;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid rgba(255, 45, 85, 0.28);
  background: rgba(255, 45, 85, 0.08);
  color: var(--ink-secondary);
  border-radius: 12px;
  padding: 10px 12px;
  min-height: 42px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
}
.sky-agenda-overdue.is-open .sky-agenda-overdue-toggle {
  border-radius: 12px 12px 0 0;
}
.sky-agenda-overdue-chev {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--sky-late);
  flex: 0 0 auto;
  transition: transform 0.15s ease;
}
.sky-agenda-overdue-chev svg {
  width: 14px;
  height: 14px;
  display: block;
}
.sky-agenda-overdue:not(.is-open) .sky-agenda-overdue-chev {
  transform: rotate(-90deg);
}
.sky-agenda-overdue .sky-agenda-day {
  margin: 0;
  padding: 4px 10px 10px;
  border: 1px solid rgba(255, 45, 85, 0.22);
  border-top: 0;
  opacity: 0.88;
}
.sky-agenda-overdue .sky-agenda-day:last-child {
  border-radius: 0 0 12px 12px;
}
.sky-agenda-head {
  display: flex;
  align-items: stretch;
  padding: 4px 2px 6px;
}
.sky-agenda-day-toggle {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 4px;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
}
.sky-agenda-day-toggle:hover,
.sky-agenda-day-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.05);
}
.sky-agenda-day-label {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.sky-agenda-day-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.sky-agenda-day-chev {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  width: 20px;
  transition: transform 0.15s ease, color 0.12s ease;
}
.sky-agenda-day-chev svg {
  width: 14px;
  height: 14px;
  display: block;
}
.sky-agenda-day.is-collapsed .sky-agenda-day-chev {
  color: var(--muted);
  transform: rotate(-90deg);
}
.sky-agenda-head strong {
  display: block;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--acal-muted);
}
.sky-agenda-head span {
  font-size: 0.92rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  letter-spacing: -0.01em;
}
.sky-agenda-head em {
  font-style: normal;
  font-size: 0.75rem;
  font-weight: var(--fw-strong);
  color: var(--acal-muted);
  font-variant-numeric: tabular-nums;
}
.sky-card-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}
/* List-row feel ? thin left accent bar only, no heavy card border/fill.
 * A hairline bottom border separates rows instead of a boxed card each. */
.sky-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 0;
  border-bottom: 1px solid var(--line, var(--acal-line));
  border-radius: 0;
  background: transparent;
  overflow: hidden;
  position: relative;
  box-shadow: inset 3px 0 0 var(--acal-c, var(--accent));
}
.sky-card-list .sky-card:last-child {
  border-bottom: 0;
}
.sky-card.is-selected {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
}
.sky-card.is-selected .sky-card-title,
.sky-card.is-selected .sky-card-due,
.sky-card.is-selected .sky-card-meta,
.sky-card.is-selected .sky-card-sub {
  color: #fff;
}
.sky-card.is-selected .sky-card-ico {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}
.sky-card.is-late {
  box-shadow: inset 3px 0 0 var(--sky-late);
}
.sky-card.is-done {
  background: color-mix(in srgb, #ff2d55 22%, transparent);
  box-shadow: inset 3px 0 0 #ff2d55;
}
.sky-card.is-done .sky-card-ico,
.sky-card-ico.is-done-pin {
  color: #ff2d55;
}
/* Person-color mode: person --acal-c fill; Done/Passed = bar/icon only. */
.sky-card.is-done-mark {
  background: color-mix(in srgb, var(--acal-c, #0a84ff) 18%, transparent);
  box-shadow: inset 3px 0 0 #ff2d55;
}
.sky-card.is-late-mark {
  background: color-mix(in srgb, var(--acal-c, #0a84ff) 18%, transparent);
  box-shadow: inset 3px 0 0 #ff453a;
}
.sky-card.is-done-mark .sky-card-ico.is-done-pin {
  color: #ff2d55;
}
/* My day / calendar cards */
.sky-card.is-done .sky-card-title,
.sky-card.is-done-mark .sky-card-title {
  text-decoration: line-through;
}
.acal-color-legend-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.acal-color-legend-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.74rem;
  color: var(--ink-secondary, #c7c7cc);
  min-height: 0;
  line-height: 1.2;
}
.acal-color-legend-list i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.acal-color-legend-btn {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: inherit;
  font: inherit;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
  padding: 4px 6px;
  margin: 0;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  min-height: 28px;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    box-shadow 0.14s var(--ease), color 0.14s var(--ease);
}
.acal-color-legend-btn:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
}
.acal-color-legend-btn.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.acal-color-legend-list .is-done-key {
  margin-top: 4px;
  padding: 6px 6px 2px;
  border-top: 1px solid var(--acal-line, rgba(255, 255, 255, 0.08));
  opacity: 0.85;
  pointer-events: none;
}
.acal-color-legend-list .is-type-key {
  margin-top: 4px;
  padding: 4px 6px;
  border-top: 1px solid var(--acal-line, rgba(255, 255, 255, 0.08));
  opacity: 0.9;
  pointer-events: none;
  gap: 8px;
}
.acal-color-legend-list .is-type-key + .is-type-key {
  border-top: 0;
  margin-top: 0;
  padding-top: 2px;
}
.acal-color-legend-list .is-type-key + .is-done-key {
  margin-top: 2px;
}
.route-complete.is-passed {
  color: #ff453a;
}
.sky-card-main {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  flex: 1;
  min-width: 0;
  padding: 11px 10px 11px 14px;
  cursor: pointer;
}
.sky-card-main:hover {
  background: rgba(255, 255, 255, 0.03);
}
.sky-card-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  flex: 0 0 auto;
  margin-top: 1px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
}
.sky-card-ico svg {
  width: 14px;
  height: 14px;
  display: block;
}
.sky-card-ico.is-visit {
  color: var(--accent);
  background: rgba(10, 132, 255, 0.12);
}
.sky-card-ico.is-task {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.14);
}
.sky-card.is-late .sky-card-ico {
  color: var(--sky-late);
  background: rgba(255, 45, 85, 0.14);
}
.sky-card-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.sky-card-copy strong {
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  line-height: 1.25;
}
/* Customer / task name reads like a link ? accent tint, no card chrome needed. */
.sky-card-title {
  color: var(--accent);
}
.sky-card.is-late .sky-card-title {
  color: var(--ink);
}
.sky-card-meta {
  font-size: 0.78rem;
  color: var(--acal-muted);
  line-height: 1.3;
}
.sky-card-due {
  flex: 0 0 auto;
  font-size: 0.72rem;
  font-weight: var(--fw-strong);
  color: var(--acal-muted);
  padding-top: 2px;
  white-space: nowrap;
  text-align: right;
}
.sky-card-due.is-late {
  color: var(--sky-late);
}
.sky-card-go {
  appearance: none;
  border: 0;
  border-left: 1px solid var(--acal-line);
  background: rgba(10, 132, 255, 0.12);
  color: var(--accent, #0a84ff);
  font: inherit;
  font-size: 0.78rem;
  font-weight: var(--fw-strong);
  padding: 0 14px;
  cursor: pointer;
  flex: 0 0 auto;
}
.sky-card-go:hover {
  background: rgba(10, 132, 255, 0.22);
}
/* Compact action row ? Open ? Visit form ? Done (phone restyles to premium squircles). */
.sky-card-actions {
  display: flex;
  border-top: 1px solid var(--acal-line);
}
.sky-card-act {
  appearance: none;
  -webkit-appearance: none;
  flex: 1 1 0;
  border: 0;
  border-right: 1px solid var(--acal-line);
  background: transparent;
  color: var(--accent, #0a84ff);
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  min-height: 44px;
  padding: 0 6px;
  cursor: pointer;
  text-align: center;
  box-shadow: none;
  outline: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.sky-card-act.is-open svg {
  display: block;
}
.sky-card-act:last-child {
  border-right: 0;
}
.sky-card-act:hover {
  background: rgba(255, 255, 255, 0.05);
}
.sky-card-act.is-done {
  color: var(--ok, #30d158);
  font-weight: var(--fw-strong);
}
.sky-card-act.is-done.is-locked {
  color: rgba(48, 209, 88, 0.38);
  cursor: not-allowed;
  opacity: 0.72;
}
.sky-card-act.is-done.is-locked:hover {
  background: transparent;
}
.btn.ghost.is-locked,
.btn.ghost:disabled.is-locked {
  opacity: 0.55;
  cursor: not-allowed;
}
.sky-month-dots {
  display: flex;
  gap: 3px;
  justify-content: center;
  min-height: 6px;
  margin: 0 0 2px;
}
.acal-month-chip.is-late {
  background: color-mix(in srgb, var(--sky-late) 70%, #000);
}

@media (max-width: 900px) {
  .sky-num { width: 30px; height: 30px; font-size: 0.88rem; }
  .sky-card-go { padding: 0 12px; }
}

.acal-day-head {
  padding: 12px 16px 8px;
  flex: 0 0 auto;
}
.acal-day-head h2 {
  margin: 0;
  font-size: 1.4rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.03em;
}
.acal-day-head p {
  margin: 2px 0 0;
  color: var(--acal-muted);
  font-size: 0.9rem;
}
.acal-allday {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 8px;
  padding: 6px 12px 10px;
  border-bottom: 1px solid var(--acal-line);
  align-items: start;
  flex: 0 0 auto;
}
.acal-allday-lab {
  font-size: 0.68rem;
  color: var(--acal-muted);
  padding-top: 8px;
}
.acal-day {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
}
.acal-day-agenda .acal-agenda {
  flex: 1;
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding: 4px 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.acal-agenda-row .acal-event {
  height: auto;
  min-height: 56px;
  border-radius: 12px;
}
.acal-agenda-row .acal-event-copy {
  padding: 10px 12px;
}
.acal-agenda-row .acal-event strong {
  font-size: 0.95rem;
}
.acal-allday-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: min(28vh, 220px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.acal-allday-list .acal-event {
  height: auto;
  min-height: 40px;
}
.acal-grid-scroll {
  flex: 1;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.acal-time-grid {
  position: relative;
  display: grid !important;
  grid-template-columns: 56px minmax(0, 1fr) !important;
  align-items: stretch;
  width: 100%;
}
.acal-hours {
  height: 100%;
}
.acal-hour {
  height: var(--acal-hour, 48px);
  border-bottom: 1px solid var(--acal-line);
  position: relative;
}
.acal-hour span {
  position: absolute;
  top: -0.55em;
  left: 0;
  font-size: 0.68rem;
  color: var(--acal-muted);
  font-variant-numeric: tabular-nums;
}
.acal-lanes {
  position: relative;
  border-left: 1px solid var(--acal-line);
  height: 100%;
  min-height: 100%;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent calc(var(--acal-hour, 48px) / 2 - 1px),
      rgba(255,255,255,0.04) calc(var(--acal-hour, 48px) / 2 - 1px),
      rgba(255,255,255,0.04) calc(var(--acal-hour, 48px) / 2),
      transparent calc(var(--acal-hour, 48px) / 2),
      transparent calc(var(--acal-hour, 48px) - 1px),
      var(--acal-line) calc(var(--acal-hour, 48px) - 1px),
      var(--acal-line) var(--acal-hour, 48px)
    );
}
.acal-lanes.is-today {
  background-color: rgba(10, 132, 255, 0.05);
}

/* Skynamo Week / Day time chips */
.sky-time-chip {
  appearance: none;
  border: 0;
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-width: 0;
  text-align: left;
  padding: 3px 5px;
  border-radius: 4px;
  font: inherit;
  font-size: 0.68rem;
  line-height: 1.15;
  cursor: pointer;
  background: rgba(10, 132, 255, 0.28);
  color: #fff;
  box-shadow: inset 3px 0 0 rgba(10, 132, 255, 0.85);
}
.sky-time-chip.is-soon {
  background: rgba(10, 132, 255, 0.32);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--sky-soon, #0a84ff);
}
.sky-time-chip.is-muted {
  background: rgba(142, 142, 147, 0.38);
  color: #fff;
  box-shadow: inset 3px 0 0 #8e8e93;
}
.sky-time-chip.is-late {
  background: rgba(255, 45, 85, 0.4);
  box-shadow: inset 3px 0 0 var(--sky-late);
}
.sky-time-chip.is-done {
  background: color-mix(in srgb, #ff2d55 85%, #000);
  box-shadow: inset 3px 0 0 var(--chip-c, #ff2d55);
  color: #fff;
}
.sky-time-chip.is-driver {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  box-shadow: inset 3px 0 0 var(--chip-c, #0a84ff);
  color: #fff;
}
/* Person-color mode: keep --chip-c fill; overdue = red bar + late dot (not full pink). */
.sky-time-chip.is-driver.is-late-mark {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  box-shadow: inset 3px 0 0 #ff453a;
  color: #fff;
}
.sky-time-chip.is-driver.is-late-mark::after {
  content: "";
  flex: 0 0 auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff453a;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  margin-left: 2px;
}
/* Person-color mode: Done = pink bar + dot (never blanket pink chip). */
.sky-time-chip.is-driver.is-done-mark {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  box-shadow: inset 3px 0 0 #ff2d55;
  color: #fff;
}
.sky-time-chip.is-driver.is-done-mark::after {
  content: "";
  flex: 0 0 auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff2d55;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  margin-left: 2px;
}
/* Type cue ? right edge stripe (person fill stays dominant). */
.sky-time-chip.is-type-delivery {
  border-right: 2px solid rgba(100, 210, 255, 0.65);
}
.sky-time-chip.is-type-visit {
  border-right: 2px dotted rgba(48, 209, 88, 0.7);
}
.sky-time-chip.is-type-task {
  border-right: 2px dashed rgba(255, 214, 10, 0.7);
}
.sky-time-chip.is-type-marker {
  border-right: 2px solid rgba(142, 142, 147, 0.55);
}
.sky-time-chip .acal-chip-txt {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Skynamo Week grid */
.sky-week-grid {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
}
.sky-week-head,
.sky-week-allday,
.sky-week-body {
  display: grid;
  grid-template-columns: 56px repeat(7, minmax(0, 1fr));
  width: 100%;
}
.sky-week-head {
  border-bottom: 1px solid var(--acal-line);
  flex: 0 0 auto;
}
.sky-week-col-head {
  padding: 8px 4px;
  text-align: center;
  border-left: 1px solid var(--acal-line);
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: center;
}
.sky-week-col-head.is-today {
  background: rgba(10, 132, 255, 0.08);
}
.sky-week-dow {
  font-size: 0.68rem;
  color: var(--acal-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.sky-week-col-head strong {
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
}
.sky-week-gutter {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 8px 6px 0 0;
  font-size: 0.68rem;
  color: var(--acal-muted);
}
.sky-week-allday {
  border-bottom: 1px solid var(--acal-line);
  flex: 0 0 auto;
  min-height: 44px;
}
.sky-week-allday-cell {
  border-left: 1px solid var(--acal-line);
  padding: 4px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-height: 40px;
}
.sky-week-allday-cell.is-today,
.sky-week-col.is-today {
  background: rgba(10, 132, 255, 0.05);
}
.sky-week-scroll {
  flex: 1;
  min-height: 0;
}
.sky-week-body {
  position: relative;
  align-items: stretch;
}
.sky-week-cols {
  grid-column: 2 / -1;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  position: relative;
  height: 100%;
}
.sky-week-body .acal-hours {
  grid-column: 1;
}
.sky-week-col {
  position: relative;
  border-left: 1px solid var(--acal-line);
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent calc(var(--acal-hour, 48px) / 2 - 1px),
      rgba(255,255,255,0.03) calc(var(--acal-hour, 48px) / 2 - 1px),
      rgba(255,255,255,0.03) calc(var(--acal-hour, 48px) / 2),
      transparent calc(var(--acal-hour, 48px) / 2),
      transparent calc(var(--acal-hour, 48px) - 1px),
      var(--acal-line) calc(var(--acal-hour, 48px) - 1px),
      var(--acal-line) var(--acal-hour, 48px)
    );
}
.sky-week-col .acal-abs-event {
  left: 3px;
  right: 3px;
}
.sky-day-grid .acal-day-head { display: none; }
.sky-day-grid .acal-allday-list {
  max-height: none;
  flex-direction: row;
  flex-wrap: wrap;
}
.sky-day-grid .sky-time-chip {
  width: auto;
  max-width: 100%;
}
.acal-abs-event {
  position: absolute;
  left: 6px;
  right: 10px;
  z-index: 1;
  box-sizing: border-box;
}
.acal-abs-event .acal-event {
  height: 100%;
  min-height: 36px;
  box-sizing: border-box;
}
.acal-event.is-selected {
  outline: 2px solid #fff;
  outline-offset: 1px;
}
.acal-event strong {
  font-size: 0.82rem;
  font-weight: var(--fw-strong);
  line-height: 1.2;
}
.acal-ev-meta,
.acal-ev-loc,
.acal-ev-time {
  font-size: 0.72rem;
  opacity: 0.92;
  line-height: 1.25;
}
.acal-week {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  flex: 1;
  min-height: 320px;
  overflow: auto;
}
.acal-week-col {
  border-right: 1px solid var(--acal-line);
  min-height: 100%;
  display: flex;
  flex-direction: column;
}
.acal-week-col.is-today { background: rgba(255, 69, 58, 0.06); }
.acal-week-col.is-cursor { background: rgba(10, 132, 255, 0.08); }
.acal-week-head {
  appearance: none;
  border: 0;
  border-bottom: 1px solid var(--acal-line);
  background: transparent;
  color: inherit;
  padding: 10px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-size: 0.72rem;
  color: var(--acal-muted);
}
.acal-week-head strong {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.92rem;
  color: #f5f5f7;
}
.acal-week-head strong.is-today {
  background: var(--acal-today);
  color: #fff;
}
.acal-week-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 6px;
  overflow: auto;
}
.acal-week-list .acal-event {
  min-height: 40px;
  height: auto;
}
.acal-month { padding: 8px 12px 16px; overflow: auto; }
.acal-month-title {
  margin: 4px 0 10px;
  font-size: 1.25rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.acal-month-dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 0.72rem;
  color: var(--acal-muted);
  margin-bottom: 6px;
}
.acal-month-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  background: var(--acal-line);
  border: 1px solid var(--acal-line);
  border-radius: 10px;
  overflow: hidden;
}
.acal-month-cell {
  background: #111113;
  min-height: 110px;
  padding: 4px 6px 6px;
  display: flex;
  flex-direction: column;
  position: relative;
}
.acal-month-cell.is-out { opacity: 0.4; }
.acal-month-cell.is-today { background: rgba(10, 132, 255, 0.08); }
.acal-month-cell.is-cursor { box-shadow: inset 0 0 0 1px rgba(10, 132, 255, 0.35); }
.acal-month-day {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  font-weight: var(--fw-med);
  font-size: 0.78rem;
  width: 26px;
  height: 22px;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  align-self: flex-end;
  margin: 0 0 2px;
  line-height: 1;
}
.acal-month-cell.is-today .acal-month-day {
  background: var(--acal-today);
  color: #fff;
  font-weight: var(--fw-semi);
}
.acal-month-evs {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 0;
  min-height: 0;
  flex: 1;
}
.acal-month-chip {
  appearance: none;
  border: 0;
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(142, 142, 147, 0.22);
  color: var(--ink);
  font-size: 0.7rem;
  font-weight: var(--fw);
  text-align: left;
  padding: 3px 6px;
  border-radius: 3px;
  cursor: pointer;
  min-width: 0;
  width: 100%;
  line-height: 1.25;
}
.acal-month-chip.is-soon {
  background: rgba(10, 132, 255, 0.22);
}
.acal-month-chip.is-late {
  background: rgba(255, 45, 85, 0.32);
  color: #fff;
}
/* Skynamo done = hot pink chip (non-person mode only); keep driver color as left bar */
.acal-month-chip.is-done {
  background: color-mix(in srgb, #ff2d55 82%, #000);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--chip-c, #ff2d55);
}
/* Multi-user / Drivers group ? tint from --chip-c (per driver) */
.acal-month-chip.is-driver {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  color: #fff;
  box-shadow: inset 3px 0 0 var(--chip-c, #0a84ff);
}
/* Person-color mode: keep --chip-c fill; overdue = red bar + late dot (not full pink). */
.acal-month-chip.is-driver.is-late-mark {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  color: #fff;
  box-shadow: inset 3px 0 0 #ff453a;
}
.acal-month-chip.is-driver.is-late-mark::after {
  content: "";
  flex: 0 0 auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff453a;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  margin-left: 2px;
}
/* Person-color mode: Done = pink bar + dot (Deliveries no longer all-pink). */
.acal-month-chip.is-driver.is-done-mark {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  color: #fff;
  box-shadow: inset 3px 0 0 #ff2d55;
}
.acal-month-chip.is-driver.is-done-mark::after {
  content: "";
  flex: 0 0 auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff2d55;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  margin-left: 2px;
}
/* Type cue ? right edge stripe on month chips. */
.acal-month-chip.is-type-delivery {
  border-right: 2px solid rgba(100, 210, 255, 0.65);
}
.acal-month-chip.is-type-visit {
  border-right: 2px dotted rgba(48, 209, 88, 0.7);
}
.acal-month-chip.is-type-task {
  border-right: 2px dashed rgba(255, 214, 10, 0.7);
}
.acal-month-chip.is-type-marker {
  border-right: 2px solid rgba(142, 142, 147, 0.55);
}
.acal-month-chip.is-muted {
  background: rgba(142, 142, 147, 0.18);
  color: var(--ink-secondary);
}
.acal-chip-ico {
  width: 10px;
  height: 10px;
  flex-shrink: 0;
  position: relative;
  opacity: var(--crm-ico-idle-opacity);
}
/* Type icons ? work on person-tinted chips (currentColor). */
.acal-chip-ico.is-visit {
  border-radius: 50% 50% 50% 0;
  background: currentColor;
  transform: rotate(-45deg) scale(0.85);
}
.acal-chip-ico.is-task {
  border: 1.5px solid currentColor;
  border-radius: 2px;
  background: transparent;
}
.acal-chip-ico.is-delivery {
  border-radius: 1px;
  background: currentColor;
  clip-path: polygon(0 40%, 50% 0, 100% 40%, 100% 100%, 0 100%);
}
.acal-chip-ico.is-marker {
  border-radius: 50%;
  border: 1.5px solid currentColor;
  background: transparent;
}
.acal-chip-pin {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.7;
  flex-shrink: 0;
}
.acal-chip-txt {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.acal-month-more {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  text-align: left;
  padding: 2px 4px;
  cursor: pointer;
}
.acal-month-more.is-late {
  color: var(--danger, #ff453a);
  font-weight: var(--fw-semi);
}
.acal-month-cell.has-overdue-carry {
  min-height: 132px;
}
/* Desktop rows are equal 1fr height, so a busy day (today carries every overdue
   visit) used to paint its chips straight over the cells below. Clip the cell
   and let the chip list shrink - the "+N more" button stays reachable. */
.acal-month-cell {
  overflow: hidden;
  min-width: 0;
}
.acal-month-evs {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.acal-month-evs > .acal-month-more {
  flex: 0 0 auto;
  margin-top: auto;
}
.acal-month-evs > .acal-month-more.is-late {
  margin-top: 0;
}
.acal-month-cell.has-overdue-carry .acal-month-more.is-late {
  display: block;
  width: 100%;
  text-align: left;
  margin: 0 0 2px;
  padding: 2px 6px;
  border-radius: var(--btn-chip-radius, 12px);
  background: rgba(255, 69, 58, 0.22);
}


/* Phone month ? whole cell is one big tap target: day number + dots + count, no name chips. */
.acal-month.is-phone .acal-month-cell {
  appearance: none;
  border: 0;
  width: 100%;
  min-height: 64px;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  color: inherit;
  font: inherit;
}
.acal-month.is-phone .acal-month-cell:active {
  background: rgba(255, 255, 255, 0.06);
}
.acal-month-daynum {
  font-size: 0.86rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
  line-height: 1;
}
.acal-month-cell.is-today .acal-month-daynum {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: var(--acal-today);
  color: #fff;
  font-weight: var(--fw-semi);
}
.acal-month-dots {
  display: flex;
  gap: 3px;
  align-items: center;
  justify-content: center;
  min-height: 6px;
}
.acal-month-dots.is-empty {
  min-height: 6px;
}
.acal-month-daycount {
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  color: var(--acal-muted);
  font-variant-numeric: tabular-nums;
}

/* ?? Skynamo desk layout (our dark palette) ?? */
.sky-desk {
  background: var(--bg);
}
/* Default: calendar alone (full width). Filter rail opt-in via Filter toggle. */
.sky-desk-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  flex: 1;
  min-height: 0;
  height: 100%;
}
.sky-desk-row.is-filter-open {
  grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max));
}
.sky-filter {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 12px;
  background: var(--bg-elevated);
  border-left: 1px solid var(--acal-line);
  overflow: auto;
  min-height: 0;
}
.sky-show-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.sky-show-title,
.sky-filter-head h3 {
  margin: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  color: var(--ink-secondary);
}
.sky-filter-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.sky-filter-head-actions {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}
/* WAVE2-SHEET-CLOSE-44 ? rail sheet close ?44px hit */
.sky-rail-close {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  min-width: 44px;
  min-height: 44px;
  width: 44px;
  height: 44px;
  border-radius: var(--btn-chip-radius);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 44px;
}
.sky-rail-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.sky-rail-close:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.sky-filter-refresh {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.sky-filter-refresh svg {
  width: 15px;
  height: 15px;
  display: block;
}
.sky-filter-refresh:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.sky-show-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  font-size: 0.86rem;
  font-weight: var(--fw);
  cursor: pointer;
  padding: 6px 4px;
  border-radius: 8px;
}
.sky-show-block {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  margin: 2px 0 4px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.acal-nav-start .acal-kind-seg {
  margin-inline-end: 4px;
}
.sky-filter-premium .sky-show-row {
  padding: 10px 12px;
  border-radius: 0;
  border: 0;
  gap: 10px;
  font-size: 0.82rem;
  position: relative;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease);
}
.sky-show-block .sky-show-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.sky-filter-premium .sky-show-row:hover {
  background: rgba(255, 255, 255, 0.05);
}
.sky-filter-premium .sky-show-row:has(input:checked) {
  background: var(--btn-chip-on-bg);
  border-color: transparent;
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
}
.sky-filter-premium .sky-show-row:has(input:checked) .sky-show-ico {
  background: rgba(255, 255, 255, 0.22);
}
.sky-show-row input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.sky-filter-refresh:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
}
.sky-show-row:hover {
  background: rgba(255, 255, 255, 0.04);
}
.sky-show-ico {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: rgba(10, 132, 255, 0.2);
  position: relative;
}
.sky-show-ico.is-visit::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  border: 2px solid var(--accent);
}
.sky-show-ico.is-task {
  background: rgba(48, 209, 88, 0.2);
}
.sky-show-ico.is-task::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 3px;
  width: 8px;
  height: 10px;
  border: 2px solid var(--ok);
  border-radius: 2px;
}
.sky-show-legend {
  margin-top: 8px;
  font-size: 0.72rem;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
}
.sky-show-legend .is-late,
.sky-show-legend .is-soon,
.sky-legend-dots i {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 4px;
  vertical-align: middle;
}
.sky-show-legend .is-late,
.sky-legend-dots i.is-late { background: var(--sky-late); }
.sky-show-legend .is-soon,
.sky-legend-dots i.is-soon { background: var(--sky-soon); }
.sky-legend-dots i.is-muted { background: #8e8e93; }
.sky-legend-dots {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  margin: 0 4px;
}
.sky-desk-center {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: #0a0a0b;
}
.acal-page-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 4px;
}
.acal-page-title h1 {
  margin: 0;
  font-size: 1.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
}
.acal-page-actions { display: flex; gap: 8px; align-items: center; }
/* Unified PC rail toggles ? one chrome for Calendar / Nav / hub / Categories.
   `.acal-rail-toggle` kept as alias for legacy Calendar markup. */
.crm-rail-toggles,
.acal-rail-toggles {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.crm-rail-toggle,
.acal-rail-toggle {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius);
  padding: 7px 13px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  white-space: nowrap;
  letter-spacing: -0.01em;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.crm-rail-toggle svg,
.acal-rail-toggle svg {
  width: 15px;
  height: 15px;
  display: block;
  opacity: 0.85;
  flex: 0 0 auto;
}
.crm-rail-toggle:hover,
.acal-rail-toggle:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.18);
}
.crm-rail-toggle.is-on,
.acal-rail-toggle.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.crm-rail-toggle.is-on:hover,
.acal-rail-toggle.is-on:hover {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
}
.crm-rail-toggle.has-active .crm-rail-toggle-dot,
.crm-rail-toggle-dot,
.acal-rail-toggle.has-active .acal-rail-toggle-dot,
.acal-rail-toggle-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex: 0 0 auto;
}
.acal-add-btn {
  width: auto !important;
  margin-top: 0 !important;
  min-height: 34px !important;
  padding: 7px 14px !important;
  font-size: 0.86rem !important;
  font-weight: var(--fw-med) !important;
  border-radius: var(--btn-chip-radius) !important;
  white-space: nowrap;
  display: inline-flex !important;
  align-items: center;
  gap: 5px;
}
.acal-add-btn svg {
  width: 13px;
  height: 13px;
  display: block;
  opacity: 0.85;
}
/* Sync CPT ? quiet ghost chip (Deliveries); not a loud sticker. */
.acal-cpt-chip {
  appearance: none;
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  background: var(--btn-ghost-bg, var(--bg-elevated-2, #1c1c1e));
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  padding: 6px 10px;
  min-height: var(--btn-h-sm);
  font: inherit;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: var(--btn-ghost-shadow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.acal-cpt-chip.is-stale {
  border-color: rgba(255, 159, 10, 0.22);
  color: rgba(235, 200, 120, 0.88);
  background: rgba(255, 159, 10, 0.06);
  box-shadow: none;
}
.acal-cpt-chip.is-fresh {
  border-color: rgba(48, 209, 88, 0.28);
  color: rgba(48, 209, 88, 0.92);
  background: rgba(48, 209, 88, 0.06);
  box-shadow: none;
}
.acal-cpt-chip.is-syncing {
  border-color: rgba(10, 132, 255, 0.32);
  color: var(--accent);
  background: rgba(10, 132, 255, 0.06);
  box-shadow: none;
}
.acal-cpt-chip.is-error {
  border-color: rgba(255, 69, 58, 0.32);
  color: #ff453a;
  background: rgba(255, 69, 58, 0.06);
  box-shadow: none;
}
.sky-filter-select {
  width: 100%;
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  color: var(--ink);
  border-radius: 8px;
  padding: 9px 12px;
  font: inherit;
  font-size: 0.88rem;
}
.sky-filter-select.is-static {
  color: var(--ink-secondary);
}
.sky-filter-slim .sky-filter-detail {
  margin-top: auto;
  border-top: 1px solid var(--acal-line);
  padding-top: 10px;
}
.sky-desk .acal-toolbar-sky {
  background: transparent;
  border-bottom: 0;
  padding: 4px 16px 10px;
}
.sky-legend-dots i.is-muted { background: #8e8e93; }
.sky-filter-hint {
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.35;
}
.sky-combo-field input {
  width: 100%;
}
.sky-task-add-account {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
}
.sky-task-add-results {
  margin-top: 8px;
  max-height: 220px;
}
.sky-task-add-picked {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  border-radius: 10px;
  padding: 10px 12px;
}
.sky-task-add-picked .sub {
  color: var(--muted);
  font-weight: normal;
}
#btnTaskHubAddNoAccount {
  display: block;
  margin-top: 8px;
  font-size: 0.82rem;
}
.sky-modal-back {
  position: fixed;
  inset: 0;
  /* Above bottom-nav (220) + header (200). Forms New / task Add were z:80 and sat under the nav. */
  z-index: 280;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  display: grid;
  place-items: center;
  padding: 20px;
  padding-bottom: max(20px, var(--sheet-nav-clear, 20px));
  box-sizing: border-box;
  animation: crmBackdropIn var(--dur-modal, 0.22s) var(--ease-modal, var(--ease)) both;
}
.sky-modal {
  width: min(420px, 100%);
  max-height: min(80vh, 640px);
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 16px;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.48),
    var(--btn-ghost-shadow);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
  animation: crmModalIn var(--dur-modal, 0.22s) var(--ease-modal, var(--ease)) both;
  will-change: transform, opacity;
}
.sky-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.sky-modal-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
}
/* WAVE2-SHEET-CLOSE-44 ? form / task / New-form sheet close hit target ?44px */
.sky-modal-x {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  line-height: 1;
  cursor: pointer;
  padding: 0;
  min-width: 44px;
  min-height: 44px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 44px;
  position: relative;
  z-index: 2;
  border-radius: var(--btn-chip-radius);
}
.sky-modal-x svg {
  width: 16px;
  height: 16px;
  display: block;
  pointer-events: none;
}
.sky-modal-x:hover {
  color: var(--ink);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, transparent);
}
.sky-modal-x:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.sky-modal-opt {
  width: 100%;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 12px;
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  border-radius: var(--btn-chip-radius);
  padding: 14px 12px;
  margin: 0 0 8px;
  font-size: 0.95rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  text-align: left;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    box-shadow 0.14s var(--ease), transform 0.12s var(--ease);
}
.sky-modal-opt:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.sky-modal-opt:active {
  transform: scale(0.98);
}
.sky-modal-opt:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.sky-modal-form {
  display: grid;
  gap: 12px;
}
.sky-modal-form label {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}
.sky-modal-form input {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  color: var(--ink);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  min-height: var(--btn-h);
  font: inherit;
  box-sizing: border-box;
}
.sky-modal-form input:focus {
  outline: none;
  border-color: var(--accent);
  background: #3a3a3c;
  box-shadow: var(--btn-focus-ring);
}
.sky-page-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
}
.acal-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Shared Skynamo page chrome (Customers / Home / lists) */
.sky-page {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}
/* PC: hub pages fill shell width (shell pad remains; no artificial center cap). */
.sky-hub-page.is-pc {
  width: 100%;
  max-width: var(--hub-max);
  margin: 0;
  box-sizing: border-box;
}
.sky-page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 18px;
  padding: 8px 2px 4px;
}
.sky-page-head-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.sky-page-head h1 {
  margin: 0;
  font-size: clamp(1.55rem, 2.4vw, 1.9rem);
  font-weight: var(--fw-strong);
  letter-spacing: -0.03em;
}
.sky-page-subtitle {
  margin: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  letter-spacing: -0.01em;
  max-width: 36rem;
  line-height: 1.35;
}
.sky-page-search {
  flex: 1 1 280px;
  max-width: 520px;
  margin-inline: auto;
}
.sky-page-search input {
  width: 100%;
  appearance: none;
  border: 0;
  background: var(--bg-elevated-2);
  border-radius: var(--btn-chip-radius);
  padding: 12px 18px;
  font-size: 0.95rem;
  font-weight: var(--fw);
  color: var(--ink);
}
.sky-page-search input::placeholder {
  color: var(--muted);
}
.sky-page-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  min-width: 0;
}
/* Default full width; View / Filter rails opt-in via toolbar toggles ? BOTH RIGHT.
   Stretch columns (Calendar desk-row pattern) ? never align-items:start short cards. */
.sky-hub-body {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  min-height: 0;
}
.sky-hub-body:has(.sky-view-rail):has(.sky-filter-rail) {
  grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max)) minmax(var(--rail-width-min), var(--rail-width-max));
}
.sky-hub-body:has(.sky-view-rail):not(:has(.sky-filter-rail)),
.sky-hub-body:not(:has(.sky-view-rail)):has(.sky-filter-rail) {
  grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max));
}
/* Hub right rails ? Calendar Filter gold (flush full-height column, not floating cards). */
.sky-hub-body > .sky-filter.sky-filter-premium,
.sky-customers .sky-hub-body > .sky-filter.sky-filter-premium {
  position: sticky;
  top: calc(var(--hdr-h) + 8px);
  max-height: calc(100dvh - var(--hdr-h) - 20px);
  align-self: stretch;
  min-width: 0;
  width: 100%;
  min-height: min(100%, calc(100dvh - var(--hdr-h) - 20px));
  overflow: auto;
  border-radius: 0;
  box-shadow: none;
}
.sky-hub-body > .sky-filter.sky-filter-premium .acal-people-roles {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
/* Quiet sidebar rails ? smart look via `.crm-smart-rail` (Calendar Filter language). */
.sky-page-rail {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 4px 0;
  min-width: 0;
}
.sky-page-rail.crm-smart-rail {
  background: var(--rail-bg);
  border: 1px solid var(--rail-line);
  border-radius: var(--rail-radius);
  padding: var(--rail-pad-y) var(--rail-pad-x);
}
.sky-page-rail.sky-view-rail.crm-smart-rail,
.sky-page-rail.sky-filter-rail.crm-smart-rail {
  /* Identical right-rail chrome ? no left/right forks */
  border: 1px solid var(--rail-line);
}
.sky-rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 10px;
  padding: 0 2px 10px;
  border-bottom: 1px solid var(--rail-line);
}
.sky-rail-head .sky-rail-title {
  margin: 0;
  padding: 0;
  border-bottom: 0;
}
.sky-rail-title {
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
  opacity: 1;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 10px;
  padding: 0 2px 10px;
  border-bottom: 1px solid var(--rail-line);
}
.sky-view-item {
  display: block;
  width: 100%;
  text-align: left;
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
  padding: 8px 10px;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.sky-view-item:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
}
.sky-view-item.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.sky-filter-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
  font-size: 0.82rem;
  color: var(--muted);
}
.sky-filter-field select {
  width: 100%;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 7px 10px;
  font-size: 0.85rem;
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease);
}
.sky-filter-field select:hover,
.sky-filter-field select:focus {
  background: var(--bg-elevated-2);
  border-color: var(--line-strong);
}
/* Compact "Add" pattern shared by every hub head (Timeline / Tasks / ?) ? sits
   inline next to search, never a full-width banner. `.btn` defaults to full
   width for stacked form buttons elsewhere and ? being a single class ? ties
   `.sky-hub-add` on specificity, so the later-in-file `.btn` rule would win
   the cascade on source order alone. Qualify with `.btn` here (two classes)
   so this reliably wins regardless of where either rule sits in the file. */
.btn.sky-hub-add {
  width: auto;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 0;
  padding: 9px 16px;
}
.sky-hub-add svg {
  width: 14px;
  height: 14px;
  display: block;
  flex: 0 0 auto;
}
/* Hub "Add" dropdown (Timeline ? Fill form / New task / New quote) ? same
   small anchored-menu chrome the customer-hub "+" sheet used to use. */
.sky-hub-add-wrap {
  position: relative;
  flex: 0 0 auto;
}
.sky-hub-add-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 180px;
  max-height: min(70vh, 520px);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px;
  padding-bottom: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--btn-chip-radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}
.sky-hub-add-menu[hidden] {
  display: none !important;
}
.sky-hub-add-menu button {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  text-align: left;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  min-height: 44px;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    box-shadow 0.14s var(--ease);
}
.sky-hub-add-menu button:hover,
.sky-hub-add-menu button:focus-visible {
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.sky-hub-add-menu button:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
/* Timeline hub Filter rail ? Period + Activity type chip groups (PC: stacked list,
   phone: horizontal scroll ? see body.shell-phone override below). */
.sky-tl-chip-block {
  margin-bottom: 14px;
}
.sky-rail-subtitle {
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 6px;
}
.sky-tl-chip-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sky-tl-chip {
  appearance: none;
  width: 100%;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-align: left;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  font: inherit;
  font-weight: var(--fw-med);
  font-size: 0.88rem;
  padding: 8px 12px;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.sky-tl-chip:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
}
.sky-tl-chip.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
  font-weight: var(--fw-med);
}
.sky-tl-chip-ico {
  display: inline-flex;
  flex: 0 0 auto;
  opacity: var(--crm-ico-idle-opacity);
}
.sky-tl-chip-ico svg {
  width: 14px;
  height: 14px;
  display: block;
}
.sky-tl-chip.is-on .sky-tl-chip-ico {
  opacity: 1;
  color: #fff;
}
@media (max-width: 980px) {
  .sky-hub-body,
  .sky-hub-body:has(.sky-view-rail):has(.sky-filter-rail),
  .sky-hub-body:has(.sky-view-rail):not(:has(.sky-filter-rail)),
  .sky-hub-body:not(:has(.sky-view-rail)):has(.sky-filter-rail) {
    grid-template-columns: minmax(0, 1fr);
  }
  .sky-page-rail {
    display: none;
  }
}
.sky-page-main {
  min-width: 0;
}
.sky-page-main.card {
  border-radius: var(--radius-sm);
  padding: 12px 14px 8px;
}
.sky-page-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 6px;
  padding: 0 2px 8px;
  border-bottom: 1px solid var(--line);
}
.sky-list-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 140px;
  gap: 12px;
  padding: 8px 10px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
/* Visit label ? PC ?901 only. */
.sky-list-head-visit,
.sky-list-head-rep,
.sky-list-head-cat,
.sky-list-head-region,
.sky-list-head-meta {
  display: none;
}
/* Legacy multi-col cells ? list is Name | Next visit only. */
.sky-cust-rep,
.sky-cust-cat,
.sky-cust-region,
.sky-cust-meta,
.results.sky-list .pick-cust > strong,
.sky-list .pick-cust > strong {
  display: none;
}
.sky-list-body {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
}
.sky-list .results,
.results.sky-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-height: none; /* override legacy `.results { max-height: 52vh }` */
}
.results.sky-list .row,
.sky-list .row {
  border-radius: 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 12px 4px;
  background: transparent;
}
/* Skynamo-style customer rows: Name | Next visit */
.results.sky-list .pick-cust,
.sky-list .pick-cust {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  text-align: left;
  appearance: none;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: inherit;
  padding: 12px 22px 12px 10px;
  cursor: pointer;
  transition: background 0.12s var(--ease);
  position: relative;
}
.results.sky-list .pick-cust:hover,
.sky-list .pick-cust:hover {
  background: var(--bg-elevated-2);
  box-shadow: inset 0 1px 0 var(--line-strong), inset 0 -1px 0 var(--line-strong);
}
/* Trailing chevron affordance ? subtle, sits inside the row's own right padding
 * so it doesn't need to fight the per-breakpoint (and PC-forced !important) grid rules. */
.results.sky-list .pick-cust::after,
.sky-list .pick-cust::after {
  content: "\203A";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-secondary);
  font-size: 1.15rem;
  font-weight: var(--fw-semi);
  line-height: 1;
  opacity: 0.82;
  pointer-events: none;
}
.results.sky-list .pick-cust:hover::after,
.sky-list .pick-cust:hover::after {
  color: var(--accent);
  opacity: 1;
}
.results.sky-list .pick-cust strong,
.sky-list .pick-cust strong {
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.results.sky-list .pick-cust .sky-cust-name,
.sky-list .pick-cust .sky-cust-name {
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.sky-cust-export {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  font-size: 0.68rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  vertical-align: middle;
  color: var(--ink-secondary, #c5cad6);
  background: var(--btn-ghost-bg, rgba(255, 255, 255, 0.06));
  border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.12));
  box-shadow: var(--btn-ghost-shadow, none);
}
.sky-cust-blocked {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  font-size: 0.68rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  vertical-align: middle;
  color: var(--danger, #ff453a);
  background: color-mix(in srgb, var(--danger, #ff453a) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--danger, #ff453a) 38%, transparent);
  box-shadow: none;
}
.results.sky-list .pick-cust .sky-cust-meta,
.sky-list .pick-cust .sky-cust-meta {
  font-size: 0.78rem;
  color: var(--muted);
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Call-plan visit cue ? same row as name (dot + label). */
.sky-cust-visit {
  grid-column: auto;
  font-size: 0.76rem;
  margin-top: 0;
  padding-left: 14px;
  text-align: right;
  position: relative;
  white-space: nowrap;
  justify-self: end;
}
.sky-cust-visit::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.06);
}
.sky-cust-visit.is-late {
  color: var(--sky-late);
  font-weight: var(--fw-semi);
}
.sky-cust-visit.is-late::before {
  background: var(--sky-late);
  box-shadow: 0 0 0 2px rgba(255, 45, 85, 0.22), 0 0 8px rgba(255, 45, 85, 0.45);
}
.sky-cust-visit.is-soon {
  color: var(--sky-soon);
  font-weight: var(--fw-semi);
}
.sky-cust-visit.is-soon::before {
  background: var(--sky-soon);
  box-shadow: 0 0 0 2px rgba(255, 159, 10, 0.22), 0 0 8px rgba(255, 159, 10, 0.4);
}
.sky-cust-visit.is-never,
.sky-cust-visit.is-upcoming {
  color: var(--muted);
}
.sky-cust-visit.is-never::before,
.sky-cust-visit.is-upcoming::before {
  background: color-mix(in srgb, var(--muted) 85%, #fff);
}
.sky-cust-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 4px;
}
.sky-cust-filter-chip {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 auto;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  /* Squircle only — never stadium / oval / 999px / 980px. */
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  padding: 4px 10px;
  min-height: 28px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  white-space: nowrap;
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  transition:
    background var(--dur-state, 200ms) var(--ease),
    border-color var(--dur-state, 200ms) var(--ease),
    color var(--dur-state, 200ms) var(--ease),
    box-shadow var(--dur-state, 200ms) var(--ease),
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease));
}
.sky-cust-filter-chip:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
}
.sky-cust-filter-chip:active {
  transform: scale(0.97);
}
.sky-cust-filter-chip:disabled:active,
.sky-cust-filter-chip[aria-disabled="true"]:active {
  transform: none;
}
.sky-cust-filter-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
@media (max-width: 700px) {
  .sky-list-head { display: none; }
  .results.sky-list .pick-cust,
  .sky-list .pick-cust {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "name visit";
    gap: 6px 10px;
    padding: 12px 24px 12px 8px;
  }
  .results.sky-list .pick-cust .sky-cust-name { grid-area: name; }
  .results.sky-list .pick-cust .sky-cust-visit { grid-area: visit; }
}
/* Phone shell: Name | Next visit same row */
body.shell-phone .sky-list-head { display: none !important; }
body.shell-phone .sky-cust-list-meta {
  display: none !important;
}
body.shell-phone .sky-cust-list-stack {
  margin: 2px 0 0;
}
body.shell-phone .sky-cust-list-group {
  /* inherits .ios-hub-group-body inset card */
}
body.shell-phone .sky-customers .sky-cust-list-group .results.sky-list,
body.shell-phone .sky-customers .sky-cust-list-group .sky-list-body {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  max-height: none;
  overflow: visible;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row,
body.shell-phone .sky-list .pick-cust.ios-cust-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  grid-template-columns: unset;
  grid-template-areas: unset;
  width: 100%;
  min-height: var(--btn-h, 44px);
  padding: 12px 28px 12px 14px;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  position: relative;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row:not(:last-child)::before,
body.shell-phone .sky-list .pick-cust.ios-cust-row:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row:hover,
body.shell-phone .sky-list .pick-cust.ios-cust-row:hover,
body.shell-phone .results.sky-list .pick-cust.ios-cust-row:active,
body.shell-phone .sky-list .pick-cust.ios-cust-row:active {
  background: rgba(255, 255, 255, 0.06);
  box-shadow: none;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row::after,
body.shell-phone .sky-list .pick-cust.ios-cust-row::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid rgba(255, 255, 255, 0.35);
  border-top: 1.5px solid rgba(255, 255, 255, 0.35);
  transform: translateY(-50%) rotate(45deg);
  opacity: 1;
  font-size: 0;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-name,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit {
  flex: 0 0 auto;
  max-width: 42%;
  margin: 0;
  padding-left: 0;
  font-size: 0.86rem;
  font-weight: var(--fw-med);
  color: var(--accent, #0a84ff);
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit::before,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit::before {
  display: none;
}
/* All visit cues lit ? overdue / due / scheduled / never (not muted gray) */
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-late,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-late {
  color: #ff453a;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-soon,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-soon {
  color: var(--sky-soon, #0a84ff);
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-upcoming,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-upcoming {
  color: #30d158;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-never,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit.is-never {
  color: #ff9f0a;
}
body.shell-phone .sky-customers .cust-load-more-wrap {
  padding: 12px 14px 14px;
  border-top: 0.5px solid rgba(255, 255, 255, 0.12);
}
/* PC Customers list also uses hub inset group */
body:not(.shell-phone) .sky-cust-list-stack {
  margin-top: 6px;
}
body:not(.shell-phone) .sky-cust-list-group .sky-list-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 8px 28px 8px 14px;
  margin: 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.12);
  background: transparent;
}
body:not(.shell-phone) .sky-cust-list-group .results.sky-list,
body:not(.shell-phone) .sky-cust-list-group .sky-list-body {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  max-height: none;
  overflow: visible;
}
body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  grid-template-columns: unset;
  padding: 11px 28px 11px 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  position: relative;
}
body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row:hover {
  background: rgba(255, 255, 255, 0.06);
  box-shadow: none;
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit {
  flex: 0 0 auto;
  padding-left: 0;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  color: var(--accent, #0a84ff);
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit::before {
  display: none;
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit.is-late {
  color: #ff453a;
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit.is-soon {
  color: var(--sky-soon, #0a84ff);
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit.is-upcoming {
  color: #30d158;
}
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit.is-never {
  color: #ff9f0a;
}
/* legacy name/visit class fallbacks on phone */
body.shell-phone .results.sky-list .pick-cust,
body.shell-phone .sky-list .pick-cust {
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "name visit";
  gap: 6px 10px;
  padding: 14px 26px 14px 10px;
  min-height: 52px;
  align-items: center;
}
body.shell-phone .results.sky-list .pick-cust strong,
body.shell-phone .sky-list .pick-cust strong,
body.shell-phone .results.sky-list .pick-cust .sky-cust-meta,
body.shell-phone .sky-list .pick-cust .sky-cust-meta {
  display: none !important;
}
body.shell-phone .results.sky-list .pick-cust .sky-cust-name,
body.shell-phone .sky-list .pick-cust .sky-cust-name {
  grid-area: name;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 1.02rem;
  line-height: 1.28;
}
body.shell-phone .results.sky-list .pick-cust .sky-cust-visit,
body.shell-phone .sky-list .pick-cust .sky-cust-visit {
  grid-area: visit;
  grid-column: auto;
  margin-top: 0;
  text-align: right;
}
.acal-toolbar-sky {
  grid-template-columns: auto minmax(0, 1fr) auto;
  background: transparent;
  border-bottom: 1px solid var(--acal-line);
}
.acal-nav-start,
.acal-nav-end {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.sky-desk-main {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 8px 12px;
}
.sky-filter-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.sky-filter-premium {
  gap: 0;
  padding: var(--rail-pad-y) 14px 16px;
  background: var(--rail-bg);
  border: 0;
  border-radius: 0;
}
.sky-filter-premium.crm-smart-rail {
  /* Calendar Filter gold surface ? flush desk column + hairline vs main */
  border: 0;
  border-left: 1px solid var(--acal-line, var(--rail-line));
  border-radius: 0;
  padding: var(--rail-pad-y) 14px 16px;
  background: var(--rail-bg);
}
.sky-filter-premium .sky-filter-head {
  margin-bottom: 4px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--rail-line);
}
.sky-filter-premium .sky-filter-head h3 {
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.sky-filter-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--rail-section-line);
}
.sky-filter-section.sky-filter-foldable {
  gap: 0;
  padding: 4px 0;
}
.sky-filter-section.sky-filter-foldable.is-folded {
  padding: 2px 0;
}
.sky-filter-fold {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  padding: 6px 2px;
  margin: 0;
  cursor: pointer;
  border-radius: 6px;
  min-height: 32px;
}
.sky-filter-fold:hover {
  background: rgba(255, 255, 255, 0.04);
}
.sky-filter-fold-lab {
  font-size: 0.65rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--rail-lab);
}
.sky-filter-fold-chev {
  display: inline-flex;
  color: rgba(235, 235, 245, 0.4);
  flex-shrink: 0;
}
.sky-filter-fold-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 2px 0 8px;
}
.sky-filter-fold-body[hidden] {
  display: none !important;
}
.sky-filter-section.is-grow,
.sky-filter-section.sky-filter-detail {
  border-bottom: 0;
  flex: 1;
  min-height: 120px;
}
.sky-filter-field-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sky-filter-premium .sky-filter-lab {
  font-size: 0.65rem;
  letter-spacing: 0.07em;
  color: var(--rail-lab);
}
.sky-filter-premium .sky-filter-select,
.sky-filter-premium .sky-combo-field input {
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.35);
  min-height: 36px;
}
.sky-filter-premium .sky-filter-hint,
.sky-filter-premium .acal-people-hint {
  margin: 0;
  font-size: 0.72rem;
  line-height: 1.35;
  color: rgba(235, 235, 245, 0.42);
}
.sky-filter-premium .acal-people-hint.is-default {
  color: rgba(48, 209, 88, 0.75);
}
.sky-filter-premium .acal-people-picker {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sky-filter-premium .acal-people-picker.is-merged .acal-people-list {
  max-height: 160px;
}
.sky-filter-premium .acal-people-legend {
  margin-top: 4px;
}
.sky-filter-premium .acal-people-roles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.sky-filter-premium .acal-people-chip {
  width: 100%;
  justify-content: center;
  border-radius: var(--btn-chip-radius);
  padding: 7px 10px;
  font-size: 0.78rem;
  min-height: 32px;
}
/* Calendar Filter only: soft person select ? do NOT wash roster / legend to solid accent
   (filter-unify chip-on leaked and killed person-color language). Event chips use --chip-c. */
.sky-desk .sky-filter-premium .acal-people-row.is-on {
  background: color-mix(in srgb, var(--accent) 16%, var(--btn-ghost-bg));
  border-color: color-mix(in srgb, var(--accent) 42%, var(--btn-ghost-border));
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink);
}
.sky-desk .sky-filter-premium .acal-color-legend-btn.is-on {
  background: color-mix(in srgb, var(--accent) 16%, var(--btn-ghost-bg));
  border-color: color-mix(in srgb, var(--accent) 42%, var(--btn-ghost-border));
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink);
}
/* Guard: calendar event chips keep --chip-c / --acal-c fills (never hub chip-on wash). */
.sky-desk .sky-time-chip.is-driver,
.sky-desk .acal-month-chip.is-driver {
  background: color-mix(in srgb, var(--chip-c, #0a84ff) 72%, #000);
  box-shadow: inset 3px 0 0 var(--chip-c, #0a84ff);
  color: #fff;
}
.sky-desk .sky-card {
  box-shadow: inset 3px 0 0 var(--acal-c, var(--accent));
}
.sky-filter-premium .acal-people-clear {
  align-self: flex-start;
  margin-top: 2px;
  font-size: 0.75rem;
  padding: 5px 12px;
  border-radius: var(--btn-chip-radius);
  min-height: 30px;
}
.sky-filter-premium .sky-filter-quick {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 4px;
}
.sky-filter-premium .acal-color-legend-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 160px;
  overflow: auto;
}
.sky-filter-premium .acal-color-legend-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.74rem;
  color: var(--ink-secondary);
}
.sky-filter-lab {
  font-size: 0.7rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.sky-filter-detail {
  border-bottom: 0;
  flex: 1;
  min-height: 0;
}
.sky-desk .acal-month-title { display: none; }
.sky-desk .acal-month {
  padding: 0 4px 8px;
}
.sky-desk .acal-month-grid {
  gap: 0;
  border: 1px solid var(--acal-line);
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-elevated);
}
.sky-desk .acal-month-cell {
  min-height: 110px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 4px;
  background: rgba(0, 0, 0, 0.2);
}
.sky-desk .acal-month-cell.is-out {
  opacity: 0.45;
}
.sky-desk .acal-month-dow {
  padding: 6px 4px;
  font-size: 0.72rem;
  color: var(--muted);
}

/* M4 ? the PC calendar centre owns every pixel below its toolbar. The Filter
   remains a separate, flush right rail; visit detail stays below the centre.
   Gate with body:not(.shell-phone) so ONE UI phone calendar on wide isn't clipped. */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-desk-row,
  body:not(.shell-phone) .sky-desk-center,
  body:not(.shell-phone) .sky-filter-premium.crm-smart-rail {
    min-height: 0;
    height: 100%;
  }
  body:not(.shell-phone) .sky-desk-row { align-items: stretch; }
  body:not(.shell-phone) .sky-desk-main {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  body:not(.shell-phone) .sky-desk-main > .acal-day,
  body:not(.shell-phone) .sky-desk-main > .sky-week-grid,
  body:not(.shell-phone) .sky-desk-main > .acal-month,
  body:not(.shell-phone) .sky-desk-main > .sky-agenda {
    flex: 1 1 auto;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-desk-main > .sky-agenda {
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  body:not(.shell-phone) .sky-desk-main > .acal-month {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  body:not(.shell-phone) .sky-desk-main > .acal-month .acal-month-grid {
    flex: 1 1 auto;
    min-height: 0;
    grid-auto-rows: minmax(110px, 1fr);
    overflow: auto;
  }
}

/* Bottom nav ? phone only, in-flow flex child of .app-shell (not position:fixed) */
.bottom-nav {
  display: none;
}
body.shell-phone .bottom-nav,
body.shell-phone .app-shell.has-bottom-nav .bottom-nav {
  display: grid;
  grid-template-columns: repeat(var(--bn-cols, 4), minmax(0, 1fr));
  position: relative;
  left: auto;
  right: auto;
  bottom: auto;
  flex: 0 0 auto;
  z-index: 220;
  width: calc(100% + 2 * var(--shell-pad-x));
  margin: 0 calc(-1 * var(--shell-pad-x));
  box-sizing: border-box;
  /* Solid only - same lesson as .app-header / .sky-hub chrome: a bar that
     samples its backdrop gets composited with the scrolled content on iOS. */
  background: var(--bottom-nav-bg);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-top: 1px solid var(--line-strong);
  padding: 6px 4px var(--safe-bottom);
  min-height: unset;
  height: auto;
  transform: none;
}
body.shell-phone .app-shell.has-bottom-nav {
  /* Content chrome only ? safe-area counted once on shell pad, not in token. */
  --bottom-nav-h: 56px;
}
body.shell-phone .app-shell.has-bottom-nav .acal.is-full {
  max-height: none;
  height: 100%;
  min-height: 0;
}
body.shell-phone .bottom-nav-link {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 2px;
  min-height: 44px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  border-radius: 10px;
  min-width: 0;
}
body.shell-phone .bottom-nav-link.is-active {
  color: var(--accent);
  background: transparent;
}
body.shell-phone .bottom-nav-ico {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: var(--btn-chip-radius);
  line-height: 0;
}
body.shell-phone .bottom-nav-link.is-active .bottom-nav-ico {
  background: var(--btn-nav-active-bg);
}
body.shell-phone .bottom-nav-ico svg {
  width: 20px;
  height: 20px;
  display: block;
}
body.shell-phone .bottom-nav-lab {
  line-height: 1.1;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  width: 100%;
}
/* Active tab - soft accent wash behind the icon (Skynamo-style), label picks
 * up the accent + a touch more weight. Squircle wash (not oval / stadium). */
body.shell-phone .bottom-nav-ico,
.bottom-nav-ico {
  width: 44px;
  height: 30px;
  border-radius: var(--btn-chip-radius);
  transition: background 0.15s var(--ease), transform 0.15s var(--ease);
}
body.shell-phone .bottom-nav-link.is-active .bottom-nav-ico,
.bottom-nav-link.is-active .bottom-nav-ico {
  background: var(--btn-nav-active-bg);
}
body.shell-phone .bottom-nav-link.is-active .bottom-nav-lab,
.bottom-nav-link.is-active .bottom-nav-lab {
  font-weight: var(--fw-semi);
}
body.shell-phone .bottom-nav-link:active .bottom-nav-ico,
.bottom-nav-link:active .bottom-nav-ico {
  transform: scale(0.92);
}
/* Roei: drag bottom tabs to set global order for everyone */
body.shell-phone .bottom-nav.is-roei-edit .bottom-nav-link.is-roei-reorder {
  cursor: grab;
  /* Pointer-based reorder needs the gesture; the bar itself never scrolls. */
  touch-action: none;
}
body.shell-phone .bottom-nav.is-roei-edit .bottom-nav-link.is-bnav-dragging {
  /* Feature marker + drop peers; lift look from .is-crm-dragging */
  cursor: grabbing;
}
body.shell-phone .bottom-nav.is-roei-edit .bottom-nav-link.is-bnav-drop-before {
  box-shadow: inset 3px 0 0 var(--accent);
}
body.shell-phone .bottom-nav.is-roei-edit .bottom-nav-link.is-bnav-drop-after {
  box-shadow: inset -3px 0 0 var(--accent);
}
@media (max-width: 900px) {
  .sky-desk-row,
  .sky-desk-row.is-filter-open {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr) auto;
  }
  .sky-filter {
    border-left: 0;
    border-top: 1px solid var(--acal-line);
    max-height: min(42vh, 360px);
  }
  .acal-toolbar-sky {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .acal-nav-end { justify-content: space-between; width: 100%; }
}
.acal-detail h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.acal-detail.is-empty {
  display: grid;
  place-items: center;
  min-height: 120px;
}
.acal-cal-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border-radius: var(--btn-chip-radius);
  background: #2c2c2e;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  margin-bottom: 10px;
}
.acal-cal-pill i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.acal-detail-loc {
  margin: 0 0 10px;
  font-size: 0.88rem;
}
.acal-detail-block {
  padding: 10px 0;
  border-top: 1px solid var(--acal-line);
  border-bottom: 1px solid var(--acal-line);
  margin-bottom: 12px;
}
.acal-detail-block p { margin: 0 0 4px; }
.acal-detail-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.acal-detail-actions .btn { width: 100%; }

/* Phone calendar visit detail ? iOS action-sheet grade (crm434) */
.acal-phone-detail {
  flex: 0 0 auto;
  max-height: 42vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 14px 16px calc(14px + var(--safe-bottom, 0px));
  border-top: 1px solid var(--acal-line);
  background: rgba(28, 28, 30, 0.98);
  border-radius: 16px 16px 0 0;
}
.acal-phone-detail .acal-detail {
  padding: 0;
  text-align: center;
}
.acal-phone-detail .acal-detail h3 {
  font-size: 1.12rem;
  font-weight: var(--fw-semi);
  margin: 0 0 8px;
  letter-spacing: -0.02em;
  text-align: center;
}
.acal-phone-detail .acal-cal-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0 auto 8px;
}
.acal-detail-status {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--btn-chip-radius, 12px);
  padding: 3px 10px;
  margin-bottom: 10px;
}
.acal-detail-status.is-overdue {
  color: #ff453a;
  background: rgba(255, 69, 58, 0.14);
}
.acal-phone-detail .acal-detail-block {
  padding: 8px 0 12px;
  margin-bottom: 4px;
  text-align: center;
}
.acal-phone-detail .acal-detail-block p {
  margin: 0 0 4px;
}
.acal-phone-detail .acal-detail-actions {
  flex-direction: column;
  gap: 8px;
}
.acal-phone-detail .acal-detail-actions .btn {
  width: 100%;
  min-height: var(--btn-h, 48px);
  border-radius: var(--btn-radius);
  justify-content: center;
}
.acal-phone-detail-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
}
.acal-phone-detail-empty p { margin: 0; }

/* Hub Scheduled visit ? phone density */
body.shell-phone .crm-schedule-visit .crm-callplan-lab {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
body.shell-phone .crm-schedule-visit .crm-callplan-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}
body.shell-phone .crm-schedule-visit .crm-callplan-actions .btn {
  width: 100%;
  min-height: var(--btn-h, 48px);
}

/* PC: visit/stop detail under centre calendar (Filter rail = Show/People/When/Find only). */
.sky-desk-center > .acal-pc-detail,
.acal-main ~ .acal-pc-detail {
  flex: 0 0 auto;
  max-height: 38vh;
  overflow-y: auto;
  padding: 10px 16px 14px;
  border-top: 1px solid var(--acal-line);
  background: var(--bg-elevated, rgba(28, 28, 30, 0.98));
}
.acal-pc-detail .acal-detail { padding: 0; }
.acal-pc-detail .acal-detail h3 { font-size: 1.05rem; margin-bottom: 6px; }
.acal-pc-detail .acal-detail-block { padding: 8px 0; margin-bottom: 8px; }
.acal-pc-detail .acal-detail-actions {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px;
}
.acal-pc-detail .acal-detail-actions .btn {
  width: auto;
  flex: 0 1 auto;
  min-width: 120px;
}
.acal-pc-detail-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
}
.acal-pc-detail-empty p { margin: 0; }

/* Phone: compact filter bar under the toolbar ? Board + Person select + Filters sheet trigger. */
.acal-phone-filter-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 4px 8px;
  flex-wrap: nowrap;
}
.acal-phone-filter-select {
  flex: 1 1 auto;
  min-width: 0;
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2, #1c1c1e);
  color: var(--ink);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  font-size: 0.82rem;
  min-height: 44px;
}
.acal-phone-filter-board {
  flex: 0 1 34%;
}
.acal-phone-filter-person {
  flex: 1 1 auto;
}
.acal-phone-filters-btn {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--accent);
  border-radius: var(--btn-radius-seg-item);
  padding: 0 12px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  min-height: var(--btn-h);
  height: var(--btn-h);
  box-sizing: border-box;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  flex: 0 0 auto;
  cursor: pointer;
}
.acal-phone-filters-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 16px;
  height: 16px;
  padding: 0 3px;
  border-radius: var(--btn-chip-radius);
  background: var(--accent);
  color: #fff;
  font-size: 0.65rem;
  font-weight: var(--fw-semi);
}

/* Phone: "Showing everyone" nudge when the unfiltered team board is huge (data stays visible). */
.acal-everyone-banner {
  display: block;
  width: 100%;
  text-align: left;
  appearance: none;
  border: 1px solid rgba(255, 159, 10, 0.35);
  background: rgba(255, 159, 10, 0.12);
  color: #ffd60a;
  border-radius: 10px;
  padding: 8px 12px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  margin-bottom: 8px;
  cursor: pointer;
}

/* Phone: Filters bottom sheet ? above bottom-nav (220) + header (200), same tier as maps-sheet. */
.acal-filters-back {
  align-items: flex-end;
  padding: 0;
  z-index: 250;
}
.acal-filters-sheet {
  width: 100%;
  max-width: none;
  max-height: 82vh;
  border-radius: 16px 16px 0 0;
  /* WAVE2-SHEET-NAV-CLEAR ? base + phone override both clear bottom nav */
  padding: 14px 14px var(--sheet-nav-clear);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.acal-filters-sheet-body {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  min-height: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.acal-filters-sheet .sky-filter-section {
  padding: 2px 0;
  border-bottom: 1px solid var(--rail-section-line);
}
.acal-filters-sheet .sky-filter-fold {
  min-height: 40px;
  padding: 8px 4px;
}
.acal-filters-sheet .sky-filter-fold-lab {
  font-size: 0.72rem;
  color: var(--rail-lab-active);
}
.acal-filters-sheet .acal-color-legend-btn {
  min-height: 36px;
  padding: 6px 10px;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
}
.acal-filters-sheet .acal-color-legend-btn.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
}
.acal-filters-done {
  width: 100%;
}
.acal-filters-sheet .acal-quick-chips {
  flex-wrap: wrap;
  gap: 8px;
}
.acal-filters-sheet .acal-people-chip {
  min-height: 36px;
  padding: 8px 14px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.8rem;
}
.acal-filters-sheet .acal-people-roles {
  gap: 8px;
}
.acal-filters-sheet .acal-people-row {
  min-height: 40px;
  padding: 8px 10px;
  border-radius: var(--btn-chip-radius);
}
.acal-filters-sheet .acal-people-sel {
  border-radius: var(--btn-chip-radius);
  min-height: 32px;
}

@media (max-width: 900px) {
  .app-shell.has-side:has(.day-board-acal) .app-body {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .acal.is-full {
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 20px);
    height: auto;
    max-height: none;
  }
  .acal-body,
  .acal.no-mini .acal-body {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(280px, 1fr) auto;
  }
  .acal-side { display: none; }
  .acal-rail {
    border-left: 0;
    border-top: 1px solid var(--acal-line);
    max-height: min(34vh, 280px);
    padding: 12px 14px 16px;
  }
  .acal-day-head h2 { font-size: 1.2rem; }
  .acal-week {
    grid-template-columns: repeat(7, minmax(44px, 1fr));
    overflow-x: auto;
    min-height: 280px;
  }
  .acal-week-head {
    padding: 6px 2px;
    gap: 2px;
    font-size: 0.62rem;
  }
  .acal-week-head strong {
    width: 24px;
    height: 24px;
    font-size: 0.8rem;
  }
  .acal-week-list {
    padding: 4px 3px;
    gap: 3px;
  }
  .acal-week-list .acal-event {
    min-height: 32px;
  }
  .acal-month-cell { min-height: 52px; }
  .acal-month-title { font-size: 1.1rem; }
  .acal-agenda-row .acal-event { min-height: 52px; }
}
.home-calendar.home-route {
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
}
.home-calendar.home-route .home-calendar-head {
  padding: 0 4px 10px;
  margin-bottom: 0;
}
.home-calendar-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.home-calendar-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.home-calendar-count {
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.home-calendar .day-list {
  margin: 0;
  max-height: min(70vh, 640px);
  overflow-y: auto;
}
@media (min-width: 901px) {
  body:not(.shell-phone) .crm-home.is-pc .home-calendar .day-list {
    max-height: none;
    flex: 1 1 auto;
    min-height: 0;
  }
}
.home-calendar.home-route .route-list {
  max-height: min(62vh, 560px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}

/* Driver route ? Apple Reminders / Maps style */
.route-panel { display: flex; flex-direction: column; gap: 12px; }
.route-empty {
  margin: 8px 4px 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}
.acal-empty-banner {
  margin: 10px 12px 4px;
  padding: 10px 12px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: var(--bg-elevated, #1c1c1e);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--ink-secondary, #ebebf5);
  font-size: 0.9rem;
  line-height: 1.4;
}
.route-summary {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
}
.route-summary-text {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.route-summary-text strong {
  font-size: 1.35rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.route-of {
  font-size: 0.85rem;
  font-weight: var(--fw-med);
  color: var(--muted);
}
.route-summary-text > span {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted);
}
.route-progress {
  height: 4px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.route-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--ok);
  transition: width 0.35s var(--ease);
}
.route-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.route-waiting-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.route-waiting-toggle {
  appearance: none;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 159, 10, 0.35);
  background: rgba(255, 159, 10, 0.08);
  color: #ffd60a;
  font: inherit;
  font-size: 0.86rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  text-align: left;
}
.route-waiting-toggle.is-open {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}
.route-waiting-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.85;
  transition: transform 0.15s ease;
}
.route-waiting-chevron svg {
  width: 14px;
  height: 14px;
  display: block;
}
.route-waiting-toggle:not(.is-open) .route-waiting-chevron {
  transform: rotate(-90deg);
}
.route-waiting-list {
  margin: 0;
  padding: 8px 14px 10px;
  list-style: none;
  border: 1px solid rgba(255, 159, 10, 0.25);
  border-top: 0;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  background: rgba(255, 159, 10, 0.05);
}
.route-waiting-list li {
  padding: 5px 0;
  font-size: 0.84rem;
  color: var(--ink-secondary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.route-waiting-list li:last-child {
  border-bottom: 0;
}
.acal-quick-row {
  padding: 0 12px 10px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.acal-quick-row .sky-filter-block {
  margin: 0;
  min-width: min-content;
}
.acal-quick-row .acal-quick-chips {
  flex-wrap: nowrap;
}
.acal-quick-row .acal-people-chip {
  white-space: nowrap;
}
/* Phone: kind seg (optional) stacked above Agenda/Week/Month. */
.acal-toolbar-phone-combo {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 0 4px 8px;
}
.acal-toolbar-phone-combo .acal-toolbar-phone-seg {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0;
}
.acal-toolbar-phone-combo .acal-quick-row {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0;
}
.acal-toolbar-phone-combo .sky-filter-lab {
  display: none;
}

/* Blocking "pick a person" state ? team calendar with no focus + a huge headcount. */
.acal.is-blocking-pick .acal-main {
  overflow: hidden;
  flex: 1 1 auto;
}
.acal.is-blocking-pick .sky-agenda,
.acal.is-blocking-pick .acal-month,
.acal.is-blocking-pick .acal-phone-detail {
  display: none !important;
}
.acal-pick-person {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: min(50vh, 380px);
  padding: 20px 16px;
  flex: 1 1 auto;
  background: #000;
}
.acal.is-blocking-pick .acal-pick-person {
  min-height: 0;
  align-self: stretch;
}
.acal-pick-person-card {
  width: 100%;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: center;
}
.acal-pick-person-card h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
.acal-pick-person-card .sub {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}
.acal-pick-person-select {
  appearance: none;
  width: 100%;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2, #1c1c1e);
  color: var(--ink);
  border-radius: 10px;
  padding: 10px 14px;
  font: inherit;
  font-size: 0.92rem;
  min-height: 44px;
  text-align: center;
}
.acal-pick-person-or {
  margin: 2px 0 0;
  font-size: 0.74rem;
  color: var(--acal-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.acal-pick-person-card .acal-people-roles {
  justify-content: center;
}
.acal-pick-person-card .acal-people-chip {
  padding: 9px 14px;
  font-size: 0.82rem;
  border-radius: var(--btn-chip-radius);
  min-height: 36px;
}
.route-marker {
  display: flex;
  justify-content: center;
  padding: 4px 0;
}
.route-marker span {
  font-size: 0.72rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 4px 10px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255, 255, 255, 0.06);
}
.route-stop {
  padding: 14px 14px 12px;
  border-radius: 0;
  background: transparent;
  border: 0;
  transition: background 0.2s var(--ease);
}
.route-list > .route-stop {
  position: relative;
}
.route-list > .route-stop:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.route-stop.is-on_site,
.route-stop.is-visit,
.route-stop.is-merc,
.route-stop.is-stock {
  background: rgba(10, 132, 255, 0.08);
}
.route-stop.is-done {
  opacity: 0.78;
}
.route-stop-top {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.route-seq {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  margin-top: 1px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.78rem;
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  background: var(--bg-elevated-2);
  border: 1px solid var(--line-strong);
}
.route-stop.is-done .route-seq {
  background: rgba(48, 209, 88, 0.18);
  border-color: rgba(48, 209, 88, 0.35);
  color: var(--ok);
}
.route-stop.is-on_site .route-seq,
.route-stop.is-visit .route-seq,
.route-stop.is-merc .route-seq,
.route-stop.is-stock .route-seq {
  background: rgba(10, 132, 255, 0.18);
  border-color: rgba(10, 132, 255, 0.4);
  color: var(--accent-press);
}
.req-star { color: var(--danger); font-weight: var(--fw-strong); }
.route-stop-copy { flex: 1; min-width: 0; }
.route-stop-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.route-store {
  margin: 0;
  font-size: 1rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
  line-height: 1.25;
  color: var(--ink);
}
.route-badge {
  flex: 0 0 auto;
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.02em;
  padding: 3px 8px;
  border-radius: var(--btn-chip-radius);
  line-height: 1.2;
}
.route-badge-muted {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
}
.route-badge-accent {
  color: var(--accent-press);
  background: rgba(10, 132, 255, 0.16);
}
.route-badge-warn {
  color: #ffd60a;
  background: rgba(255, 214, 10, 0.14);
}
.route-badge-ok {
  color: var(--ok);
  background: rgba(48, 209, 88, 0.14);
}
.route-chip-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: 6px;
}
.route-order-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.66rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.02em;
  padding: 3px 8px 3px 6px;
  border-radius: var(--btn-chip-radius);
  line-height: 1.2;
  border: 1px solid transparent;
  white-space: nowrap;
}
.route-order-chip::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 auto;
}
.route-order-chip-ok {
  color: var(--ok);
  background: rgba(48, 209, 88, 0.14);
  border-color: rgba(48, 209, 88, 0.3);
}
.route-order-chip-warn {
  color: #ffd60a;
  background: rgba(255, 214, 10, 0.14);
  border-color: rgba(255, 214, 10, 0.3);
}
.route-order-chip-muted {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--line);
}
.route-doc {
  margin: 4px 0 0;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ink-secondary);
  opacity: 0.85;
}
.route-dot { margin: 0 0.35em; color: var(--muted); }
.route-addr {
  margin: 3px 0 0;
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.route-steps {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 12px 0 0;
  padding-left: 40px;
}
.route-step {
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  color: rgba(152, 152, 157, 0.75);
  letter-spacing: 0.01em;
}
.route-step.is-on { color: var(--ink); }
.route-step-line {
  flex: 1;
  height: 2px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255, 255, 255, 0.08);
  min-width: 12px;
  max-width: 28px;
}
.route-step-line.is-on { background: rgba(10, 132, 255, 0.55); }
.route-times {
  margin: 8px 0 0;
  padding-left: 40px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.route-cta-wrap {
  margin: 12px 0 0;
  padding-left: 40px;
}
.route-cta {
  width: 100%;
  min-height: var(--btn-h);
  border: 1px solid var(--btn-primary-border);
  border-radius: var(--btn-radius);
  background: var(--btn-primary-bg);
  color: #fff;
  font: inherit;
  font-size: var(--btn-fs);
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  cursor: pointer;
  box-shadow: var(--btn-primary-shadow);
  transition: background 0.15s var(--ease), transform 0.1s var(--ease), box-shadow 0.15s var(--ease);
}
.route-cta:hover {
  background: var(--btn-primary-bg-hover);
  box-shadow: var(--btn-primary-shadow-hover);
}
.route-cta:active { transform: scale(0.985); }
.route-cta:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-primary-shadow);
}
.route-cta:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}
.route-cta-done {
  background: linear-gradient(180deg, color-mix(in srgb, var(--ok) 88%, #fff 12%), var(--ok));
  border-color: color-mix(in srgb, var(--ok) 70%, #000 30%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 1px 2px rgba(0, 0, 0, 0.28),
    0 4px 12px rgba(48, 209, 88, 0.18);
}
.route-cta-done:hover {
  background: #34c759;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 5px 14px rgba(48, 209, 88, 0.22);
}
.route-complete {
  margin: 10px 0 0;
  padding-left: 40px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  color: var(--ok);
}

.day-board-card h1 { margin-bottom: 4px; }
.day-meta { margin: 0 0 12px; font-size: 0.75rem; }
.route-board-head { margin-bottom: 14px; }
.route-board-head h1 { margin: 0 0 2px; }
.route-board-head .day-meta { margin: 2px 0 0; }
.day-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 12px 0 8px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.day-list > .day-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  text-align: left;
  width: 100%;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  padding: 10px 14px;
  cursor: pointer;
  font: inherit;
  position: relative;
  min-height: var(--btn-h);
  box-sizing: border-box;
}
.day-list > .day-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.day-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  text-align: left;
  width: 100%;
  color: var(--ink);
  font: inherit;
}
.day-row:disabled {
  opacity: 0.55;
  cursor: default;
}
.day-list > .day-row.is-overdue {
  background: rgba(255, 69, 58, 0.08);
}
.day-row-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.day-row-main strong {
  font-size: 0.92rem;
  font-weight: var(--fw-strong);
}
.day-seq {
  font-size: 0.75rem;
  font-weight: var(--fw-strong);
  color: var(--muted);
  min-width: 1.5rem;
  padding-top: 2px;
}
.day-marker {
  margin: 8px 0 2px;
  padding: 6px 4px;
  font-size: 0.72rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-press);
  border-bottom: 1px solid var(--line);
}

.role-btn.active {
  border-color: rgba(10, 132, 255, 0.55);
  background: rgba(10, 132, 255, 0.18);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(10, 132, 255, 0.25);
}
.btn.block {
  width: 100%;
}
.pull-refresh {
  position: fixed;
  top: calc(var(--hdr-h, 56px) + env(safe-area-inset-top, 0px) + 6px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  z-index: 1400;
  display: grid;
  grid-template-columns: 20px auto;
  align-items: center;
  gap: 8px;
  min-width: 150px;
  padding: 9px 14px 11px;
  overflow: hidden;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: color-mix(in srgb, var(--bg-elevated-2) 94%, transparent);
  color: #fff;
  font-size: 0.8rem;
  font-weight: var(--fw-semi);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, background 0.18s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.pull-refresh.is-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.pull-refresh.is-armed,
.pull-refresh.is-refreshing {
  background: color-mix(in srgb, var(--accent) 92%, transparent);
}
.pull-refresh.is-success {
  background: color-mix(in srgb, var(--ok, #30d158) 82%, var(--bg-elevated-2));
}
.pull-refresh.is-error {
  background: color-mix(in srgb, var(--danger, #ff453a) 82%, var(--bg-elevated-2));
}
.pull-refresh.is-refreshing {
  letter-spacing: 0.01em;
}
.pull-refresh-ico,
.pull-refresh-label {
  position: relative;
  z-index: 1;
}
.pull-refresh-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.pull-refresh.is-refreshing .pull-refresh-ico,
.app-refresh-btn.is-refreshing > span {
  animation: crm-refresh-spin 0.78s linear infinite;
}
.pull-refresh-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: color-mix(in srgb, #fff 75%, transparent);
  transform: scaleX(var(--pull-progress, 0));
  transform-origin: left center;
  transition: transform 60ms linear;
}
.app-refresh-btn.is-pressed {
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  transform: scale(0.9);
}
.app-refresh-btn.is-refreshing,
.app-refresh-btn:disabled {
  opacity: 1;
  color: var(--accent);
  cursor: wait;
}
@keyframes crm-refresh-spin {
  to {
    transform: rotate(360deg);
  }
}
/* crm590 — pull tick when navigator.vibrate is missing (iOS Safari/PWA) or weak */
.pull-refresh.crm-haptic-pulse,
.pull-refresh.is-tick {
  animation: crm-pull-haptic 0.28s var(--ease-press, cubic-bezier(0.2, 0.8, 0.2, 1));
}
@keyframes crm-pull-haptic {
  0% {
    transform: translateX(-50%) translateY(0) scale(1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  }
  35% {
    transform: translateX(-50%) translateY(2px) scale(1.08);
    box-shadow: 0 10px 28px rgba(10, 132, 255, 0.45);
  }
  100% {
    transform: translateX(-50%) translateY(0) scale(1);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  }
}
body.shell-phone.crm-haptic-pulse::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100000;
  background: rgba(255, 255, 255, 0.055);
  animation: crm-haptic-flash 0.14s ease-out forwards;
}
@keyframes crm-haptic-flash {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .pull-refresh.crm-haptic-pulse,
  body.shell-phone.crm-haptic-pulse::after,
  .pull-refresh.is-refreshing .pull-refresh-ico,
  .app-refresh-btn.is-refreshing > span {
    animation: none;
  }
}
/* Legacy logo helpers ? app header logo size is locked via --hdr-logo-* */
.logo-bar {
  display: block;
  height: 48px;
  width: auto;
  max-width: min(280px, 100%);
  object-fit: contain;
  object-position: left center;
  filter: drop-shadow(0 4px 16px rgba(0, 0, 0, 0.4));
}
.logo-bar-lg,
.topbar-home .logo-bar {
  height: 56px;
  max-width: min(320px, 100%);
}
.logo-bar-compact {
  height: 36px;
  max-width: min(160px, 70%);
}
.rep-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--ink-secondary);
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: min(180px, 42vw);
  padding: 0 2px;
  flex: 0 1 auto;
  min-width: 0;
}
.rep-chip { display: none; }

.card {
  background: var(--surface-solid);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 20px;
  margin-top: 0;
  box-shadow: var(--shadow);
  backdrop-filter: saturate(180%) blur(28px);
  -webkit-backdrop-filter: saturate(180%) blur(28px);
}

.card h1 {
  font-size: 1.625rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  margin: 0 0 6px;
  text-align: center;
  color: var(--ink);
}

.sub {
  text-align: center;
  color: var(--ink-secondary);
  opacity: 0.82;
  margin: 0 0 20px;
  font-size: 0.9375rem;
  line-height: 1.45;
  letter-spacing: -0.01em;
}

.label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 7px;
  letter-spacing: -0.01em;
}

.pin-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 18px 0 10px;
}
.pin-digit {
  width: 52px;
  height: 56px;
  min-height: var(--btn-h);
  text-align: center;
  font-size: 1.45rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.02em;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
  color: var(--ink);
  -webkit-text-security: disc;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease);
}
.pin-digit:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--btn-focus-ring, rgba(10, 132, 255, 0.28));
  background: #3a3a3c;
}

.field {
  width: 100%;
  padding: 14px 15px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: 16px;
  background: var(--bg-elevated-2);
  color: var(--ink);
  letter-spacing: -0.01em;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease);
}
.field::placeholder { color: #636366; }
.field:focus {
  outline: none;
  border-color: var(--accent);
  background: #3a3a3c;
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.22);
}

/* Shared premium buttons ? primary / secondary(ghost) / warm / small.
   Calendar sky-desk + all panel surfaces use this one family. */
.btn {
  width: 100%;
  appearance: none;
  border: 1px solid transparent;
  border-radius: var(--btn-radius);
  padding: var(--btn-pad-y) var(--btn-pad-x);
  min-height: var(--btn-h);
  font-weight: var(--fw-med);
  font-size: var(--btn-fs);
  letter-spacing: -0.01em;
  line-height: 1.25;
  cursor: pointer;
  margin-top: 10px;
  color: var(--ink);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  transition:
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease)),
    opacity var(--dur-state, 200ms) var(--ease),
    background var(--dur-state, 200ms) var(--ease),
    border-color var(--dur-state, 200ms) var(--ease),
    box-shadow var(--dur-state, 200ms) var(--ease),
    filter var(--dur-state, 200ms) var(--ease),
    color var(--dur-state, 200ms) var(--ease);
}
.btn:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.14);
}
.btn:active { transform: scale(0.98); }
.btn:disabled:active,
.btn[aria-disabled="true"]:active {
  transform: none;
}
.btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.btn.primary {
  background: var(--btn-primary-bg);
  color: #fff;
  border-color: var(--btn-primary-border);
  box-shadow: var(--btn-primary-shadow);
}
.btn.primary:hover {
  background: var(--btn-primary-bg-hover);
  border-color: var(--btn-primary-border);
  color: #fff;
  box-shadow: var(--btn-primary-shadow-hover);
}
.btn.primary:focus-visible {
  box-shadow: var(--btn-focus-ring), var(--btn-primary-shadow);
}
.btn.warm {
  background: #f5f5f7;
  color: #000;
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
.btn.warm:hover {
  filter: brightness(0.96);
  background: #f5f5f7;
  border-color: rgba(0, 0, 0, 0.12);
  color: #000;
}
.btn.ghost {
  background: var(--btn-ghost-bg);
  color: var(--ink);
  border: 1px solid var(--btn-ghost-border);
  font-weight: var(--fw-med);
  opacity: 1;
  box-shadow: var(--btn-ghost-shadow);
}
.btn.ghost:hover {
  opacity: 1;
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
  filter: none;
}
.btn:disabled,
.btn:disabled:hover,
.btn[aria-disabled="true"],
.btn[aria-disabled="true"]:hover {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, rgba(235, 235, 245, 0.42));
  background: var(--btn-disabled-bg, rgba(58, 58, 60, 0.55));
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
  filter: none;
}
.btn.small {
  width: auto;
  min-height: var(--btn-h-sm);
  padding: 6px 12px;
  font-size: var(--btn-fs-sm);
  margin: 0;
}

.af-section-head {
  margin: 18px 0 6px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted, #6b7280);
}
.af-section-head:first-of-type {
  margin-top: 8px;
  padding-top: 0;
  border-top: 0;
}

/* Merchandiser ? fold by section (Visit notes / Store & shelves / Stock count).
   Default ALL folded; finishing a section auto-opens the next (app.js wireMerchandiserFolds). */
.af-fold {
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  margin-top: 10px;
  overflow: hidden;
  background: var(--bg-elevated-2);
}
.af-fold:first-of-type { margin-top: 14px; }
.af-fold-head {
  appearance: none;
  border: 0;
  background: transparent;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  margin: 0;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
  min-height: var(--btn-h-sm);
}
.af-fold-head:hover,
.af-fold.is-open .af-fold-head {
  background: rgba(255, 255, 255, 0.05);
}
.af-fold-title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.af-fold.is-open .af-fold-title { color: var(--ink); }
.af-fold-chevron {
  display: inline-flex;
  flex-shrink: 0;
  color: var(--muted);
  transition: transform 0.18s var(--ease);
}
.af-fold.is-open .af-fold-chevron {
  transform: rotate(180deg);
  color: var(--accent);
}
.af-fold-body {
  padding: 2px 14px 16px;
  border-top: 1px solid var(--line);
}
.af-fold-body[hidden] { display: none !important; }
.af-fold-body .label:first-child,
.af-fold-body .sky-field:first-child { margin-top: 0 !important; }
.stock-lines-block { margin-top: 4px; }
.stock-line-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.stock-line-row:first-child { padding-top: 4px; }
.stock-line-main {
  flex: 1 1 auto;
  min-width: 0;
}
.stock-line-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.stock-line-grid .field {
  padding: 10px 12px;
  font-size: 16px;
}
.stock-line-row.stock-line-expected .sl-sku {
  border-color: var(--accent, #2f6fed);
  background: rgba(47, 111, 237, 0.06);
}
.stock-line-hint {
  margin: 4px 0 0;
  font-size: 0.75rem;
  color: var(--muted, #8a8f98);
}
.stock-line-note {
  margin-top: -2px;
  margin-bottom: 8px;
}
.stock-line-remove {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  margin-top: 0;
  border: 0;
  border-radius: 10px;
  background: rgba(255, 69, 58, 0.14);
  color: var(--danger);
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.stock-line-remove svg {
  width: 16px;
  height: 16px;
  display: block;
}
.stock-line-remove:hover { filter: brightness(1.1); }
@media (max-width: 900px) {
  .stock-line-remove {
    width: 44px;
    height: 44px;
  }
}
body.shell-phone .stock-line-remove {
  width: 44px;
  height: 44px;
}
@media (max-width: 430px) {
  .stock-line-grid { grid-template-columns: 1fr; }
}
/* ONE UI: merc stock lines single column on all shell-phone widths */
body.shell-phone .stock-line-grid {
  grid-template-columns: 1fr;
}

.msg {
  text-align: center;
  color: var(--danger);
  min-height: 1.2em;
  margin-top: 12px;
  font-size: 0.875rem;
}
.msg.ok { color: var(--ok); }

.results {
  margin-top: 12px;
  display: grid;
  gap: 8px;
  max-height: 52vh;
  overflow: auto;
}
.results:empty { display: none; margin: 0; }
.result {
  text-align: left;
  width: 100%;
  border: 1px solid var(--line);
  background: var(--bg-elevated-2);
  border-radius: var(--radius-sm);
  padding: 13px 14px;
  cursor: pointer;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), transform 0.14s var(--ease);
}
.result:hover {
  background: #3a3a3c;
  border-color: var(--line-strong);
}
.result:active { transform: scale(0.99); }
.result strong {
  display: block;
  font-size: 0.95rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.02em;
  color: var(--ink);
}
.result span {
  color: var(--muted);
  font-size: 0.8125rem;
}
/* Skynamo list rows ? override generic .result card look */
.results.sky-list .result.pick-cust,
.sky-list .result.pick-cust {
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  padding: 12px 10px;
}
.results.sky-list .result.pick-cust:hover,
.sky-list .result.pick-cust:hover {
  background: var(--bg-elevated-2);
  box-shadow: inset 0 1px 0 var(--line-strong), inset 0 -1px 0 var(--line-strong);
  border-color: transparent;
  border-bottom-color: var(--line);
}
.results.sky-list .result.pick-cust:active,
.sky-list .result.pick-cust:active,
.results.sky-list .pick-cust:active,
.sky-list .pick-cust:active {
  transform: scale(0.985);
}
.results.sky-list .result.pick-cust strong,
.sky-list .result.pick-cust strong {
  display: inline;
}

.shop-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.search-wrap {
  position: relative;
  z-index: 40;
}
/* Premium quiet search glyph ? mask so it always tracks currentColor's theme
 * (var(--muted)) without a second raster asset per theme. */
.search-wrap::before,
.sky-page-search::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 50%;
  width: 15px;
  height: 15px;
  transform: translateY(-50%);
  background-color: var(--muted);
  opacity: 0.65;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10.8' cy='10.8' r='6.3'/%3E%3Cpath d='M20 20l-4.35-4.35'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='10.8' cy='10.8' r='6.3'/%3E%3Cpath d='M20 20l-4.35-4.35'/%3E%3C/svg%3E");
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: contain;
  mask-size: contain;
  pointer-events: none;
  z-index: 1;
}
.search-wrap input,
.sky-page-search input {
  padding-left: 38px !important;
}
.sky-page-search {
  position: relative;
}
.search-hint {
  margin: 8px 2px 0;
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: -0.01em;
}
.suggest-dd {
  display: block;
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  max-height: min(560px, 70vh);
  overflow: auto;
  background: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-sm);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.65);
  z-index: 50;
}
.suggest-dd[hidden] {
  display: none !important;
}
.suggest-item {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 12px;
  text-align: left;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  padding: 9px 12px;
  cursor: pointer;
  transition: background 0.12s var(--ease);
}
.suggest-item:last-child { border-bottom: 0; }
.suggest-item:hover,
.suggest-item:focus {
  background: rgba(10, 132, 255, 0.14);
  outline: none;
}
.suggest-item strong {
  grid-column: 1;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.02em;
}
.suggest-item span {
  grid-column: 1;
  color: var(--muted);
  font-size: 0.75rem;
}
.suggest-item .suggest-price {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  color: var(--ink);
  font-weight: var(--fw-med);
  font-size: 0.875rem;
  letter-spacing: -0.02em;
}
.suggest-empty {
  margin: 0;
  padding: 16px;
  text-align: center;
  color: var(--muted);
  font-size: 0.875rem;
}
.cat-title {
  font-weight: var(--fw-med);
  font-size: 0.6875rem;
  margin: 4px 8px 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.cat-list { display: grid; gap: 2px; }
.cat-item {
  text-align: left;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  border-radius: 11px;
  padding: 9px 12px;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 450;
  line-height: 1.3;
  letter-spacing: -0.01em;
  transition: background 0.14s var(--ease), color 0.14s var(--ease);
}
.cat-item:hover { background: rgba(255, 255, 255, 0.06); }
.cat-item.active {
  background: rgba(10, 132, 255, 0.18);
  color: #64b5ff;
  font-weight: var(--fw-med);
}

.product {
  position: relative;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--surface-solid);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
  box-shadow: var(--shadow);
  transition:
    transform 0.22s var(--ease),
    box-shadow 0.22s var(--ease),
    border-color 0.22s var(--ease);
  min-width: 0;
  isolation: isolate;
  /* Skip layout/paint for off-screen cards on long catalogues ? the estimated
     size keeps the scrollbar/track stable until the real card is measured. */
  content-visibility: auto;
  contain-intrinsic-size: 0 96px;
}
.product:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  z-index: 4;
}
.product:focus-within {
  border-color: rgba(10, 132, 255, 0.45);
}
/* Catalogue tech refresh ? sharper geometry, scoped to the catalogue grid only
   (leaves reused card classes elsewhere, e.g. purchase-history cards, untouched). */
.products .product {
  border-radius: 11px;
  border-color: var(--line-strong);
}
.products .product:hover {
  border-color: rgba(10, 132, 255, 0.32);
}
.products .product-media {
  border-radius: 9px;
}
.product-media {
  position: relative;
  flex-shrink: 0;
  width: 88px;
  height: 88px;
  margin: 0;
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  font: inherit;
}
button.product-media {
  cursor: zoom-in;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
button.product-media:hover {
  border-color: rgba(10, 132, 255, 0.55);
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.18);
}
button.product-media:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.media-zoom-hint {
  position: absolute;
  right: 5px;
  bottom: 5px;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
  pointer-events: none;
  backdrop-filter: blur(6px);
}
.product:hover .media-zoom-hint,
button.product-media:focus-visible .media-zoom-hint {
  opacity: 1;
  transform: scale(1);
}
.product-media .stock-pill {
  display: none;
}
.meta-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin: 0 0 2px;
}
/* Tap-to-expand affordance ? compact (S/M) cards only; L shows detail inline. */
.meta-more-toggle {
  appearance: none;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.01em;
  border-radius: 6px;
  padding: 3px 6px;
  cursor: pointer;
  flex: 0 0 auto;
  transition: color 0.14s var(--ease), border-color 0.14s var(--ease), background 0.14s var(--ease);
}
.meta-more-toggle:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.05);
}
.meta-more-toggle .meta-more-ico {
  transition: transform 0.16s var(--ease);
}
.meta-more-toggle.is-open {
  color: var(--accent-press);
  border-color: rgba(10, 132, 255, 0.4);
}
.meta-more-toggle.is-open .meta-more-ico {
  transform: rotate(180deg);
}
/* Compact detail block ? hidden by default, revealed on expand or at L size */
.product-meta-extra {
  display: none;
  margin: 3px 0 0;
}
.product.is-expanded .product-meta-extra,
.products.img-xl .product-meta-extra {
  display: block;
  animation: metaExtraIn 0.16s var(--ease);
}
@keyframes metaExtraIn {
  from { opacity: 0; transform: translateY(-2px); }
  to { opacity: 1; transform: none; }
}
.products.img-xl .meta-more-toggle {
  display: none;
}
.product.is-expanded .meta h3,
.products.img-xl .product .meta h3 {
  -webkit-line-clamp: 3;
  min-height: 3.42em;
}
.meta-extra-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.product-sku-tag {
  display: inline-flex;
  align-items: center;
  font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.64rem;
  letter-spacing: 0.01em;
  color: var(--ink-secondary);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 2px 6px;
  white-space: nowrap;
}
.meta-cat {
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
.meta-sep {
  opacity: 0.5;
  margin: 0 1px;
}
.thumb {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: transparent;
  border: 0;
  border-radius: 0;
  flex-shrink: 0;
  display: block;
  transition: transform 0.28s var(--ease), opacity 0.22s ease;
}
.product:hover .thumb {
  transform: scale(1.03);
}
.products.img-md .product-media { width: 72px; height: 72px; border-radius: 8px; }
.products.img-lg .product-media { width: 100px; height: 100px; border-radius: 9px; }
.products.img-xl .product-media {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  max-height: 132px;
  border-radius: 10px;
}
.products.img-xl .product {
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  padding: 8px;
  contain-intrinsic-size: 0 280px;
}

/* Hover detail tip ? desktop / trackpad */
.product-tip {
  display: none;
}
@media (hover: hover) and (pointer: fine) {
  .product-tip {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 10px;
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: calc(100% + 8px);
    padding: 10px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(28, 28, 30, 0.92);
    backdrop-filter: saturate(180%) blur(18px);
    -webkit-backdrop-filter: saturate(180%) blur(18px);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.55);
    opacity: 0;
    visibility: hidden;
    transform: translateY(6px) scale(0.98);
    transition: opacity 0.18s var(--ease), transform 0.18s var(--ease), visibility 0.18s;
    pointer-events: none;
    z-index: 20;
  }
  .product:hover .product-tip,
  .product:focus-within .product-tip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
  }
  .products .product:nth-child(-n+3) .product-tip {
    bottom: auto;
    top: calc(100% + 8px);
  }
}
.product-tip-media {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
}
.product-tip-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.product-tip-empty {
  font-size: 0.62rem;
  color: var(--muted);
}
.product-tip-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.product-tip-body strong {
  font-size: 0.8rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-tip-sku,
.product-tip-cat,
.product-tip-packs,
.product-tip-hint {
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: -0.01em;
}
.product-tip-stock {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
}
.product-tip-stock.high { color: var(--stock-in); }
.product-tip-stock.low { color: var(--stock-low); }
.product-tip-stock.out { color: var(--stock-out); }
.product-tip-price {
  font-size: 0.84rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
  margin-top: 2px;
}
.product-tip-price em {
  font-style: normal;
  font-weight: 500;
  color: var(--muted);
  font-size: 0.72rem;
}
.product-tip-hint {
  margin-top: 4px;
  color: var(--accent-press);
}

/* Image lightbox */
body.lightbox-open { overflow: hidden; }
/* Shell rebuild: `.app-body` is the scroller, so locking `body` alone no longer
   freezes the page behind an overlay. */
body.lightbox-open .app-body,
body.cat-sheet-open .app-body { overflow: hidden; }
/* Category bottom sheet ? lock background scroll while it covers the screen,
   matching the lightbox pattern above. */
body.cat-sheet-open { overflow: hidden; }
/* Quote dock sits above the sheet content when z-index was low ? disable while sheet open. */
body.cat-sheet-open .shop-dock { pointer-events: none; }
.prod-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: auto;
  width: 100%;
  height: 100%;
  height: 100dvh;
  z-index: 2000;
  display: grid;
  place-items: center;
  /* Notch/home-indicator clearance so the card and its X never land in the
     status-bar strip (iOS clipped the close button against the screen corner). */
  padding: calc(20px + var(--safe-top)) 20px calc(20px + var(--safe-bottom));
  opacity: 0;
  transition: opacity 0.2s var(--ease);
}
.prod-lightbox.is-open { opacity: 1; }
.prod-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.prod-lightbox-card {
  position: relative;
  width: min(560px, 100%);
  max-height: min(90vh, 820px);
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(28, 28, 30, 0.96);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.65);
  overflow: hidden;
  transform: translateY(10px) scale(0.98);
  transition: transform 0.24s var(--ease);
}
.prod-lightbox.is-open .prod-lightbox-card {
  transform: translateY(0) scale(1);
}
/* WAVE2-SHEET-CLOSE-44 */
.prod-lightbox-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  border-radius: var(--btn-radius);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
}
.prod-lightbox-close svg {
  width: 17px;
  height: 17px;
  display: block;
  pointer-events: none;
}
.prod-lightbox-img-wrap {
  display: grid;
  place-items: center;
  min-height: 240px;
  max-height: 62vh;
  padding: 18px;
  background: #ffffff;
}
.prod-lightbox-img-wrap img {
  max-width: 100%;
  max-height: 56vh;
  object-fit: contain;
}
.prod-lightbox-meta {
  padding: 14px 16px 16px;
  border-top: 1px solid var(--line);
}
.prod-lightbox-meta h2 {
  margin: 0 0 4px;
  font-size: 1.05rem;
  letter-spacing: -0.03em;
  line-height: 1.25;
}
.prod-lightbox-meta p {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
}
.prod-lightbox-price {
  margin-top: 8px !important;
  color: var(--ink) !important;
  font-weight: var(--fw-semi);
  font-size: 0.95rem !important;
}
.prod-lightbox-price span {
  color: var(--muted);
  font-weight: 500;
}
/* Phone: product image lightbox as bottom sheet (ONE UI - not proto-shop).
   The card hugs its content at the bottom: `align-items: stretch` used to make it
   fill the screen, which left a dead slab under the details block and removed the
   only touch exit (no backdrop to tap, and phones have no Escape). */
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) {
  place-items: end center;
  /* Always leave a tappable strip of backdrop above the sheet. */
  padding: calc(var(--safe-top) + var(--btn-h)) 0 0;
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) .prod-lightbox-card {
  width: 100%;
  max-width: none;
  max-height: 100%;
  height: auto;
  align-self: end;
  border-radius: 16px 16px 0 0;
  /* WAVE2-SHEET-NAV-CLEAR */
  padding-bottom: var(--sheet-nav-clear);
  transform: translateY(24px);
  transition: transform var(--dur-sheet, 0.34s) var(--ease-sheet, var(--ease));
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) .prod-lightbox-meta {
  flex: 0 0 auto;
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox).is-open .prod-lightbox-card {
  transform: translateY(0);
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) .prod-lightbox-img-wrap {
  min-height: 180px;
  max-height: 48vh;
  padding: 14px;
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) .prod-lightbox-img-wrap img {
  max-height: 42vh;
}
body.shell-phone .prod-lightbox:not(.tl-img-lightbox) .prod-lightbox-close {
  width: var(--btn-h, 44px);
  height: var(--btn-h, 44px);
  min-width: var(--btn-h, 44px);
  min-height: var(--btn-h, 44px);
}

.cat-heading {
  margin: 12px 2px 0;
  font-size: 0.8125rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
  letter-spacing: -0.01em;
}
.img-size-label {
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: -0.01em;
}
.img-size-toggle {
  display: inline-flex;
  align-items: stretch;
  gap: 1px;
  padding: 2px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.img-size-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  min-height: calc(var(--btn-h-sm) - 6px);
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: var(--fw-med);
  border-radius: var(--btn-radius-seg-item);
  cursor: pointer;
  letter-spacing: 0.02em;
  line-height: 1.2;
  transition: background 0.16s var(--ease), color 0.16s var(--ease);
}
.img-size-btn:hover { color: var(--ink); }
.img-size-btn.active {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
.thumb.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 500;
  background: transparent;
  width: 100%;
  height: 100%;
}
/* crm809: phone shop data-saver placeholder (no /api/media/ until visible) */
.products .thumb.thumb-ph,
.products .product-media .thumb-ph {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 48px;
  background: color-mix(in srgb, var(--muted) 14%, transparent);
  border-radius: inherit;
}
.thumb-empty-ico { opacity: 0.5; }
/* Fade thumbs in once loaded ? paired with onload/onerror in productCardsHtml
   so a slow/broken image never pops in or leaves a layout-shifting blank box.
   Scoped to the <img> only ? the "no image" placeholder div is always visible. */
.products img.thumb {
  opacity: 0;
}
.products img.thumb.is-loaded {
  opacity: 1;
}
.price-missing {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.76rem;
  font-weight: var(--fw-med);
  color: var(--stock-low);
  letter-spacing: -0.01em;
}
.price-missing-ico { flex: 0 0 auto; }
/* Quiet catalogue cue ? prices shown inclusive of VAT (stored Ex for Partner CSV). */
.price-inclvat,
.price-exvat {
  font-size: 0.62em;
  font-weight: var(--fw-med);
  color: var(--muted);
  letter-spacing: 0.01em;
  margin-left: 0.2em;
  white-space: nowrap;
}
.products .price .price-inclvat,
.products .price .price-exvat,
.prod-lightbox-price .price-inclvat,
.prod-lightbox-price .price-exvat,
.product-tip-price .price-inclvat,
.product-tip-price .price-exvat {
  opacity: 0.72;
}
.product .meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.product .meta h3 {
  margin: 0;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.02em;
  line-height: 1.3;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
  word-break: break-word;
  /* Reserve 2 lines even for short titles ? keeps grid rows even so the
     catalogue doesn't feel like it's stair-stepping while scrolling. */
  min-height: 2.28em;
}
.product .meta .sku-line,
.product .meta p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 7px;
}

/* Quiet status chip ? small tag, not a loud rounded badge. */
.stock-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.56rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  border-radius: 5px;
  padding: 2px 6px;
  text-transform: uppercase;
  flex: 0 0 auto;
  max-width: 100%;
  border: 1px solid transparent;
  transition: background 0.16s var(--ease), border-color 0.16s var(--ease);
}
.stock-pill .stock-ico {
  flex: 0 0 auto;
  display: block;
}
.stock-pill.high {
  color: var(--stock-in);
  background: rgba(48, 209, 88, 0.09);
  border-color: rgba(48, 209, 88, 0.16);
}
.stock-pill.low {
  color: var(--stock-low);
  background: rgba(255, 159, 10, 0.09);
  border-color: rgba(255, 159, 10, 0.18);
}
.stock-pill.out {
  color: var(--stock-out);
  background: rgba(255, 69, 58, 0.09);
  border-color: rgba(255, 69, 58, 0.18);
}

/* Slim segmented control (Unit / Inner / Case) ? shared seg tokens. */
.uom-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 1px;
  margin: 8px 0 0;
  padding: 2px;
  height: 36px;
  min-height: 36px;
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--btn-radius-seg);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.uom-row::-webkit-scrollbar {
  display: none;
}
.uom-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  border-radius: var(--btn-radius-seg-item);
  padding: 0 10px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  flex: 1 1 0;
  min-width: 0;
  letter-spacing: -0.01em;
  transition: background 0.16s var(--ease), color 0.16s var(--ease), transform 0.14s var(--ease);
}
.uom-btn:hover { color: var(--ink); }
.uom-btn:active { transform: scale(0.97); }
.uom-btn .uom-price { display: none; }
.uom-btn.active {
  background: var(--btn-seg-on);
  color: #fff;
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-seg-on-shadow);
}
.uom-btn.active .uom-price { color: var(--ink); }
.uom-btn:disabled,
.uom-btn.is-disabled,
.uom-btn[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, var(--muted));
  cursor: not-allowed;
  pointer-events: none;
  transform: none;
}
/* Pack qty inside the segment (e.g. "Inner 24") ? size only, never a price;
   rendered as muted small text with a hairline separator before the number. */
.uom-btn .uom-qty {
  margin-left: 0.32em;
  font-size: 0.82em;
  font-weight: var(--fw-med);
  color: var(--muted);
  opacity: 0.85;
}
.uom-btn .uom-qty::before {
  content: "\00B7";
  margin-right: 0.28em;
  opacity: 0.7;
}
.uom-btn.active .uom-qty { color: var(--muted); }

.price {
  font-weight: var(--fw-semi);
  margin-top: 8px;
  font-size: 1.02rem;
  letter-spacing: -0.03em;
  color: var(--ink);
  line-height: 1.2;
}
.product-cart-chip {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 3px 8px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  border: 1px solid var(--btn-chip-on-border, var(--btn-ghost-border));
  background: color-mix(in srgb, var(--btn-chip-on-bg, var(--btn-ghost-bg)) 62%, transparent);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink-secondary);
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.01em;
  line-height: 1.2;
}
/* Rand currency marker ? plain R flowing with price text (same color/weight as amount).
   See money() in app.js. Applies globally (cards, cart, ledger, quotes). */
.zar { white-space: nowrap; font-variant-numeric: tabular-nums; }
.zar-sym {
  color: inherit;
  font-weight: inherit;
  font-size: 1em;
  opacity: 1;
  letter-spacing: 0;
  margin-right: 0.1em;
  vertical-align: baseline;
}
.zar-amt { font-variant-numeric: tabular-nums; letter-spacing: -0.01em; color: var(--ink); }
.price-uom {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--muted);
}
.price-pop {
  animation: pricePop 0.28s var(--ease);
}
@keyframes pricePop {
  0% { transform: scale(1); color: var(--accent-press); }
  40% { transform: scale(1.04); }
  100% { transform: scale(1); color: var(--ink); }
}
.qty-pop {
  animation: qtyPop 0.18s var(--ease);
}
@keyframes qtyPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.06); border-color: var(--accent); }
  100% { transform: scale(1); }
}
.add-pulse {
  animation: addPulse 0.35s var(--ease);
}
@keyframes addPulse {
  0% { transform: scale(1); }
  35% { transform: scale(0.96); }
  70% { transform: scale(1.03); }
  100% { transform: scale(1); }
}

.qty {
  width: 56px;
  padding: 8px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  font-size: 16px;
  text-align: center;
  background: var(--bg-elevated-2);
  color: var(--ink);
}
.qty:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.22);
}

.sticky {
  position: sticky;
  bottom: 14px;
  margin-top: 18px;
  background: rgba(28, 28, 30, 0.86);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
  backdrop-filter: saturate(180%) blur(28px);
  -webkit-backdrop-filter: saturate(180%) blur(28px);
}
.sticky .row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-weight: var(--fw-med);
  letter-spacing: -0.02em;
  color: var(--ink);
}

/* Fixed compact quote bar on shop ? retired; quote lives in top chrome */
.shop-screen .shop-sticky {
  display: none !important;
}
.shop-topbar .shop-back {
  flex: 0 0 auto;
  width: auto;
  min-height: 34px;
  padding: 6px 9px !important;
  font-size: 0.78rem !important;
  margin-top: 0;
}
.quote-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 1 auto;
  max-width: min(42vw, 220px);
  min-height: 34px;
  padding: 4px 10px;
  border-radius: var(--btn-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font: inherit;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), transform 0.12s var(--ease), box-shadow 0.18s var(--ease);
}
.quote-pill:disabled {
  opacity: 0.55;
  cursor: default;
}
.quote-pill:not(:disabled):active { transform: scale(0.97); }
.quote-pill.has-items {
  border-color: var(--btn-primary-border);
  background: var(--btn-primary-bg);
  color: #fff;
  box-shadow: var(--btn-primary-shadow);
}
.quote-pill-label {
  overflow: hidden;
  text-overflow: ellipsis;
}
.quote-pill .shop-cart-total {
  font-variant-numeric: tabular-nums;
  opacity: 0.92;
}

.context {
  font-size: 0.8125rem;
  color: var(--muted);
  margin: 4px 0 0;
  letter-spacing: -0.01em;
}

.cart-line {
  background: var(--bg-elevated-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin-bottom: 8px;
}
.cart-line .context { color: var(--muted); }

@media (min-width: 860px) {
  .shop-layout {
    grid-template-columns: 248px 1fr;
    align-items: start;
  }
}

/* Product grid ? denser columns so more products fit on screen */
.products {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  transition: opacity 0.2s ease, transform 0.22s ease;
}
.products.is-pl-fading {
  opacity: 0.35;
  transform: translateY(4px);
  pointer-events: none;
}
.products-pl-wait {
  margin: 28px 12px;
  text-align: center;
  color: var(--muted, #8b93a7);
  font-size: 0.9rem;
  font-weight: 600;
}
.products.is-pl-in {
  animation: plGridIn 0.26s ease;
}
@keyframes plGridIn {
  from { opacity: 0.4; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
.soft-toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%) translateY(12px);
  z-index: 1200;
  max-width: min(90vw, 320px);
  padding: 8px 14px;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-radius);
  background: var(--btn-ghost-bg);
  color: #fff;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  box-shadow: var(--btn-ghost-shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.22s ease;
}
.soft-toast.is-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.soft-toast.is-err {
  background: rgba(140, 30, 30, 0.92);
}
.soft-toast.is-ok { background: var(--btn-primary-bg); border-color: var(--btn-primary-border); box-shadow: var(--btn-primary-shadow); }
.soft-toast.is-info { background: var(--btn-ghost-bg); }
/* Bottom chrome stacking: keep the toast clear of the bottom nav (and the
   thumb-zone quote dock on shop screens) instead of hiding behind them. */
body.shell-phone .soft-toast {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 14px);
}

/* Shared loading and density language for every list hub. */
.crm-skel { display: grid; gap: 8px; padding: 10px 0; }
.crm-skel-row { display: grid; grid-template-columns: 1.3fr 2.7fr .8fr; gap: 12px; min-height: 48px; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg-elevated); overflow: hidden; }
.crm-skel-row i { display: block; border-radius: var(--radius-sm); background: linear-gradient(90deg, var(--bg-elevated-2) 20%, color-mix(in srgb, var(--bg-elevated-2) 65%, #fff 35%) 50%, var(--bg-elevated-2) 80%); background-size: 220% 100%; animation: crmSkelShimmer 1.25s linear infinite; }
@keyframes crmSkelShimmer { to { background-position: -220% 0; } }
.crm-density-compact { --crm-row-pad: 7px; --crm-row-font: .9rem; --crm-tl-pad-y: 6px; --crm-tl-pad-x: 8px; --crm-tl-gap: 6px; --crm-tl-title: 0.84rem; --crm-tl-sub: 0.7rem; --crm-tl-preview: 0.74rem; --crm-tl-main-gap: 2px; }
.crm-density-comfortable { --crm-row-pad: 12px; --crm-row-font: 1rem; --crm-tl-pad-y: 12px; --crm-tl-pad-x: 10px; --crm-tl-gap: 10px; --crm-tl-title: 0.92rem; --crm-tl-sub: 0.74rem; --crm-tl-preview: 0.82rem; --crm-tl-main-gap: 3px; }
.crm-density-compact .sky-tasks-row, .crm-density-compact .sky-tl-card, .crm-density-compact .hist-table td { padding-top: var(--crm-row-pad); padding-bottom: var(--crm-row-pad); font-size: var(--crm-row-font); }
.crm-density-compact .results.sky-list .pick-cust { padding-top: var(--crm-row-pad); padding-bottom: var(--crm-row-pad); }
/* Timeline density ? beat PC hub override `body:not(.shell-phone) .sky-hub-timeline .sky-tl-card { padding: 10px 12px }` */
.crm-density-comfortable .sky-tl-card,
.crm-density-compact .sky-tl-card {
  padding: var(--crm-tl-pad-y) var(--crm-tl-pad-x);
  gap: var(--crm-tl-gap);
}
.crm-density-comfortable .sky-tl-card-main,
.crm-density-compact .sky-tl-card-main {
  gap: var(--crm-tl-main-gap);
}
.crm-density-comfortable .sky-tl-card-cust,
.crm-density-comfortable .sky-tl-card-title,
.crm-density-compact .sky-tl-card-cust,
.crm-density-compact .sky-tl-card-title {
  font-size: var(--crm-tl-title);
}
.crm-density-comfortable .sky-tl-card-sub,
.crm-density-compact .sky-tl-card-sub {
  font-size: var(--crm-tl-sub);
}
.crm-density-comfortable .sky-tl-card-preview,
.crm-density-compact .sky-tl-card-preview {
  font-size: var(--crm-tl-preview);
}
body:not(.shell-phone) .crm-density-comfortable.sky-hub-timeline .sky-tl-card,
body:not(.shell-phone) .sky-hub-page.crm-density-comfortable .sky-tl-card,
body:not(.shell-phone) .sky-customer-hub.crm-density-comfortable .sky-tl-card {
  padding: var(--crm-tl-pad-y) var(--crm-tl-pad-x);
  gap: var(--crm-tl-gap);
}
body:not(.shell-phone) .crm-density-compact.sky-hub-timeline .sky-tl-card,
body:not(.shell-phone) .sky-hub-page.crm-density-compact .sky-tl-card,
body:not(.shell-phone) .sky-customer-hub.crm-density-compact .sky-tl-card {
  padding: var(--crm-tl-pad-y) var(--crm-tl-pad-x);
  gap: var(--crm-tl-gap);
}
.acal-people-chip:active, .sky-tl-chip:active, .result:active, .sky-tasks-row:active { transform: scale(.985); opacity: .9; }
.crm-map-popup-actions { display: grid; grid-template-columns: 1fr 1.25fr; gap: 7px; margin-top: 10px; }
.crm-map-popup-actions .btn { width: 100%; margin-top: 0; }
/* home-day-start moved next to .home-radar (iOS soft strip) */
@media (prefers-reduced-motion: reduce) {
  .crm-skel-row i { animation: none; }
  .btn, .acal-people-chip, .sky-tl-chip, .sky-cust-filter-chip, .result, .sky-tasks-row, .soft-toast { transition: none; }
  .btn:active,
  .sky-cust-filter-chip:active,
  .acal-people-chip:active,
  .sky-tl-chip:active,
  .result:active,
  .sky-tasks-row:active,
  .pick-cust:active,
  .results.sky-list .result.pick-cust:active,
  .sky-list .result.pick-cust:active,
  button.sky-tl-card.is-btn:active,
  div.sky-tl-card.is-btn:active {
    transform: none;
  }
}
.home-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}
.home-cta-row .btn {
  flex: 1 1 140px;
  margin-top: 0;
}
.assign-banner {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}
.assign-banner p {
  margin: 0 0 4px;
}
.assign-banner .btn {
  margin-top: 8px;
}
.quote-draft-banner {
  background: rgba(10, 132, 255, 0.06);
  border-color: rgba(10, 132, 255, 0.22);
  box-sizing: border-box;
  max-width: 100%;
  width: 100%;
}
.quote-draft-banner .home-cta-row {
  margin-top: 8px;
  gap: 8px;
  flex-wrap: wrap;
}
.quote-draft-banner .btn {
  margin-top: 0;
  flex: 0 1 auto;
  width: auto;
}
@media (min-width: 560px) {
  .products {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  /* Compact catalogue cards: image on top for S/M so more columns fit */
  .products.img-md .product,
  .products.img-lg .product {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 7px;
  }
  .products.img-md .product-media,
  .products.img-lg .product-media {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    border-radius: 10px;
  }
  .products.img-md .product-media { max-height: 88px; aspect-ratio: 3 / 2; }
  .products.img-lg .product-media { max-height: 104px; aspect-ratio: 3 / 2; }
}
@media (min-width: 800px) {
  .products {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 1100px) {
  .products {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (min-width: 1400px) {
  .products {
    grid-template-columns: repeat(5, 1fr);
  }
}
@media (min-width: 1680px) {
  .products {
    grid-template-columns: repeat(6, 1fr);
  }
}
@media (min-width: 2000px) {
  .products {
    grid-template-columns: repeat(7, 1fr);
  }
}

/* Smooth scrollbars (WebKit) */
.results::-webkit-scrollbar { width: 8px; }
.results::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 8px;
}

.action-form-picker {
  box-sizing: border-box;
  width: min(100%, 680px);
  margin-inline: auto;
  padding: 14px 14px 18px;
}
/* Customer hub Forms picker — canonical inset option rows shared with New form. */
.action-form-customer {
  margin-bottom: 14px;
}
.action-form-picker > .admin-opt-sec {
  margin-bottom: 6px;
}
.action-form-picks {
  margin-bottom: 14px;
}
.action-form-empty {
  margin: 0;
  padding: 18px 14px;
}
body.shell-phone .action-form-picker {
  padding: 12px 12px 16px;
}
/* Skynamo-style customer hub (same palette) */
.hub-kicker {
  margin: 0 0 4px;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.hub-title {
  font-size: 1.35rem;
  line-height: 1.25;
  margin-bottom: 6px;
}
.hub-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 18px 0 14px;
}
.hub-btn {
  width: 100%;
  min-height: 48px;
  font-size: 1.05rem;
  margin-top: 0;
}
.store-hub-actions .btn {
  margin-top: 0;
}
.shop-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 8px;
}
.shop-nav .btn {
  padding-left: 0;
}

.hub-link-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 8px 0 18px;
}
.hub-link {
  text-align: left;
  background: var(--bg-elevated-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  cursor: pointer;
  color: inherit;
  font: inherit;
}
.hub-link:hover {
  border-color: var(--line-strong);
  background: rgba(10, 132, 255, 0.12);
}

/* ?? Skynamo-style store hub (mobile stacked / laptop rail) ?? */
.store-hub {
  display: grid;
  gap: 10px;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
}
.store-head {
  margin-bottom: 2px;
}
.store-main .hub-title,
.store-code {
  margin: 2px 0 2px;
  font-size: 1.45rem;
  line-height: 1.2;
  word-break: break-word;
}
.store-name {
  margin: 0 0 4px;
  font-size: 1.02rem;
  font-weight: 560;
  line-height: 1.3;
  color: var(--ink-secondary);
}
.store-main-meta {
  margin: 0 0 4px;
  font-size: 0.88rem;
  line-height: 1.35;
}
.hub-action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 12px 0 10px;
}
.hub-action-grid .hub-btn {
  width: 100%;
  min-height: 44px;
  margin: 0;
  font-size: 1rem;
  padding: 10px 12px;
}
.hub-action-grid .hub-go {
  grid-column: 1 / -1;
}
.hub-action-grid .btn.ghost {
  min-height: 40px;
  font-size: 0.92rem;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  border-radius: var(--btn-radius);
  box-shadow: var(--btn-ghost-shadow);
}
.hub-btn.is-disabled,
.hub-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.hub-briefing {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 6px;
}
.hub-panel {
  background: var(--bg-elevated-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 10px 8px;
}
.hub-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
  min-height: var(--rail-fold-min-h, 34px);
}
.hub-panel-head .btn.small {
  margin: 0;
  flex: 0 0 auto;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: var(--btn-chip-radius);
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-ghost-shadow);
}
.hub-panel-head h2 {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.2;
}
/* Trail: optional linkish + fold chevron ? stays right-edge, vertically centered. */
.hub-panel-head-trail {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex: 0 0 auto;
  margin-left: auto;
}
/* Collapsible Details panels (Call plan / Assigned / Location / Tasks / History) ?
 * rail-fold language: subtle right-edge chevron, no blue badge wash. */
.sky-fold-toggle {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0;
  margin: 0 0 0 auto;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
}
.hub-panel-head-trail .sky-fold-toggle,
.cust-map-head-actions .sky-fold-toggle {
  margin-left: 0;
}
.sky-fold-toggle:hover,
.sky-fold-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.055);
  color: var(--ink);
}
.sky-fold-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  color: inherit;
  opacity: 0.55;
  background: none;
  border: 0;
  border-radius: 0;
  transition: transform 0.15s ease, opacity 0.12s ease;
}
.sky-fold-chevron svg {
  width: 13px;
  height: 13px;
  display: block;
}
.sky-fold-toggle:hover .sky-fold-chevron,
.sky-fold-toggle:focus-visible .sky-fold-chevron {
  opacity: 0.85;
}
.sky-fold.is-collapsed .sky-fold-chevron {
  transform: rotate(-90deg);
}
.sky-fold.is-collapsed .sky-fold-body {
  display: none;
}
.hub-panel .linkish {
  font-size: 0.78rem;
  padding: 0;
  background: none;
  border: 0;
  color: var(--accent);
  cursor: pointer;
}
.hub-balance {
  margin: 2px 0 8px;
  font-size: 1.15rem;
  font-weight: var(--fw-semi);
}
.hub-balance.owe { color: #ff453a; }
.hub-balance.credit { color: #30d158; }
.hub-mini-label {
  margin: 0 0 6px;
  font-size: 0.78rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.hub-quiet { margin: 4px 0 0; }
.hub-doc-list,
.hub-out-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.hub-doc,
.hub-out-row {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 2px 10px;
  width: 100%;
  text-align: left;
  padding: 9px 10px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  color: inherit;
  font: inherit;
  cursor: pointer;
  min-height: 44px;
  box-sizing: border-box;
}
.hub-doc:hover,
.hub-out-row:hover {
  border-color: var(--line-strong);
}
.hub-doc-id,
.hub-out-row span:first-child,
.hub-out-id {
  font-weight: var(--fw-semi);
  font-size: 0.88rem;
  font-variant-numeric: tabular-nums;
}
.hub-out-id {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.hub-out-mark {
  flex: 0 0 auto;
  display: inline-flex;
  line-height: 0;
  color: var(--doc-invoice);
}
.inv-card-mark {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  line-height: 0;
  margin-right: 2px;
  color: var(--accent);
}
.hub-doc-type {
  grid-column: 2;
  grid-row: 1;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.hub-doc-type.is-credit { color: #64d2ff; }
.hub-doc-meta {
  grid-column: 1;
  font-size: 0.72rem;
  color: var(--muted);
}
.hub-doc-tot,
.hub-out-row strong {
  grid-column: 2;
  grid-row: 2;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.hub-never-count {
  margin: 0 0 8px;
  font-size: 0.9rem;
  color: var(--muted);
}
.hub-never-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}
.hub-never-chip {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 64px;
  font-size: 0.72rem;
  color: var(--muted);
}
.hub-never-chip img,
.hub-never-ph {
  width: 52px;
  height: 52px;
  object-fit: contain;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
}
.hub-never-ph {
  display: grid;
  place-items: center;
}
.hub-never-chip span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Mobile: denser store hub (fixes sparse phone layout) */
@media (max-width: 900px) {
  .screen:has(.store-hub) {
    padding: 10px 10px 36px;
  }
  .store-hub {
    gap: 8px;
  }
  .store-main.card {
    padding: 14px 12px 14px;
    border-radius: 16px;
  }
  .store-hub .back-bar,
  .screen:has(.store-hub) .back-bar {
    margin-bottom: 6px;
  }
  .hub-action-grid {
    margin: 10px 0 8px;
    gap: 7px;
  }
  .store-map {
    margin-top: 4px;
  }
  .store-map .near-me-map-wrap {
    aspect-ratio: auto;
    height: 220px;
    min-height: 200px;
    max-height: none;
    border-radius: var(--radius-sm);
  }
  .store-map .cust-map-addr {
    margin: 6px 0 0;
    font-size: 0.8rem;
    line-height: 1.35;
  }
  .hub-panel {
    padding: 10px 9px 8px;
    border-radius: 10px;
  }
  .hub-balance {
    font-size: 1.08rem;
  }
}
.order-notes {
  margin: 0 0 14px;
  padding: 10px 12px;
  background: #f6f6f6;
  border: 1px solid #e2e2e2;
  border-radius: 6px;
}
.order-notes h4 {
  margin: 0 0 6px;
  font-size: 0.85rem;
}
.order-notes ul {
  margin: 0;
  padding-left: 18px;
}
.order-notes li {
  margin: 2px 0;
  font-size: 0.85rem;
  color: #333;
}
.order-doc.is-credit .order-no {
  color: #0a7a4c;
}
.visit-badge {
  margin: 10px 0 0;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: rgba(10, 132, 255, 0.16);
  border: 1px solid rgba(10, 132, 255, 0.35);
  color: #9ecbff;
  font-size: 0.92rem;
}
.hist-head {
  margin-bottom: 4px;
}
.hist-head h1 {
  margin: 2px 0 4px;
}
.hist-count {
  text-align: left;
  margin: 8px 0 2px;
  font-size: 0.9rem;
  color: var(--muted);
}
.hist-source {
  margin-bottom: 10px;
}
.hist-warn {
  color: #e8b86d !important;
}
.hist-search-row {
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: stretch;
  margin-top: 8px;
  width: 100%;
  box-sizing: border-box;
}
.hist-search-row .hist-search-input,
.hist-search-row .field {
  flex: 1 1 0%;
  min-width: 0;
  width: auto !important;
  max-width: none;
  margin: 0 !important;
  box-sizing: border-box;
}
.hist-search-row .hist-search-btn,
.hist-search-row .btn {
  flex: 0 0 auto;
  width: auto !important;
  min-width: 6.5rem;
  margin-top: 0 !important;
  white-space: nowrap;
}
.hist-toolbar {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  margin: 0 0 10px;
  align-items: center;
}
.hist-toolbar .btn {
  width: auto !important;
  margin-top: 0 !important;
  flex: 0 0 auto;
}
.hist-toolbar-tip {
  display: none; /* retired ? keep UI clean for field users */
}
.inv-doc-tools {
  justify-content: space-between;
  min-height: var(--btn-h);
}
.inv-doc-title {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  color: var(--ink, #fff);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Framed PDF tools ? same language as filter / Share / Download (not blue stadium) */
.hist-pdf-tool,
button.hist-pdf-tool,
a.hist-pdf-tool {
  text-decoration: none !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none !important;
  border-radius: var(--btn-radius-seg-item, 10px) !important;
  color: #fff !important;
  width: var(--btn-h) !important;
  min-width: var(--btn-h) !important;
  height: var(--btn-h) !important;
  padding: 0 !important;
  display: inline-grid !important;
  place-items: center !important;
}
.hist-pdf-tool:hover,
.hist-pdf-tool:active {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}
.hist-pdf-tool:disabled {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}
.hist-pdf-btn {
  min-height: var(--btn-h);
  border-radius: var(--btn-radius-seg-item, 10px) !important;
}
.order-crm-disclaimer {
  display: none;
}
/* Phone: full-bleed invoice paper ? edge-to-edge white doc, minimal chrome */
body.shell-phone .hist-card-pastel.is-phone-doc {
  margin: 0 calc(-1 * var(--shell-pad-x));
  width: calc(100% + 2 * var(--shell-pad-x));
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  padding: 0;
  background: transparent;
  box-shadow: none;
}
body.shell-phone .hist-card-pastel.is-phone-doc .inv-doc-tools {
  padding: 6px var(--shell-pad-x) 4px;
  min-height: unset;
  gap: 8px;
}
body.shell-phone .hist-card-pastel.is-phone-doc .inv-doc-title {
  font-size: 0.95rem;
}
body.shell-phone .hist-card-pastel.is-phone-doc .order-doc {
  border-radius: 0;
  margin-top: 0;
  width: 100%;
  padding: 12px 12px 16px;
  border-left: 0;
  border-right: 0;
  overflow: hidden;
  box-sizing: border-box;
}
body.shell-phone .hist-card-pastel.is-phone-doc .order-head {
  gap: 10px;
  margin-bottom: 12px;
}
body.shell-phone .hist-card-pastel.is-phone-doc .order-grid {
  gap: 10px 14px;
  margin-bottom: 12px;
}
body.shell-phone .hist-card-pastel.is-phone-doc .order-brand-logo {
  max-width: 130px;
  width: min(130px, 100%);
}
/* Phone CTAs on history/doc surfaces: squircle, never stadium primary wash */
body.shell-phone .hist-toolbar .btn.primary,
body.shell-phone .hist-card .btn.primary.hist-pdf-btn {
  border-radius: var(--btn-radius-seg-item, 10px) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  color: #fff !important;
  box-shadow: none !important;
  width: auto !important;
}
.accounts-pdf-bar {
  margin-top: 4px;
}
.hist-pdf-hint {
  margin: 6px 0 0;
  opacity: 0.85;
}
.accounts-panes {
  margin-top: 4px;
}
.hist-product-grid {
  margin-top: 10px;
}
.hist-product .add-row,
.hist-product .qty-stepper,
.hist-product .price {
  display: none;
}
.hist-product-meta {
  margin: 6px 0 0;
  font-size: 0.82rem;
  opacity: 0.78;
}
.hist-card-pastel {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
}
.order-doc {
  background: #fff;
  color: #111;
  border: 1px solid #ddd;
  border-radius: 2px;
  padding: 18px 16px 24px;
  margin-top: 8px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  line-height: 1.4;
}
/* money() uses --ink (light on dark CRM); force dark on white invoice paper */
.order-doc .zar,
.order-doc .zar-sym,
.order-doc .zar-amt {
  color: inherit;
}
.order-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
}
.order-head-left {
  min-width: 0;
  flex: 1 1 auto;
}
.order-head-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  flex: 0 0 auto;
  max-width: min(240px, 46%);
}
.order-co {
  font-weight: var(--fw-strong);
  font-size: 1.05rem;
}
.order-no {
  font-weight: var(--fw-strong);
  margin-top: 6px;
}
.order-when {
  opacity: 0.75;
  font-size: 0.85rem;
  margin-top: 2px;
}
.order-logo {
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 1.1rem;
}
.order-brand-logo {
  width: min(200px, 100%);
  height: auto;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}
.order-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 16px 24px;
  align-items: start;
  margin-bottom: 16px;
}
.order-to div,
.order-side div {
  margin-bottom: 4px;
}
.order-side {
  text-align: right;
  justify-self: stretch;
  min-width: 0;
}
.order-table-wrap {
  border-top: 1px solid #111;
  border-bottom: 1px solid #111;
  overflow-x: auto;
}
/* ONE UI invoice lines ? stacked cards instead of 7-col table */
.inv-line-cards {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 10px 0 4px;
  border-top: 1px solid #111;
  border-bottom: 1px solid #111;
  padding: 10px 0;
}
.inv-line-card {
  border: 1px solid var(--line, #e5e5ea);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  padding: 10px 12px;
  background: #fafafa;
  color: #111;
}
.inv-line-card-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.inv-line-card-id {
  flex: 1 1 auto;
  min-width: 0;
}
.inv-line-card-sku {
  font-weight: var(--fw-semi, 600);
  font-size: 0.88rem;
  letter-spacing: -0.01em;
}
.inv-line-card-desc {
  margin-top: 2px;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #333;
}
.inv-line-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 8px;
  font-size: 0.78rem;
  color: #555;
}
.inv-line-card-amt {
  margin-top: 6px;
  text-align: right;
  font-weight: var(--fw-semi, 600);
  font-variant-numeric: tabular-nums;
}
.inv-line-card-empty {
  text-align: center;
  color: #666;
  font-size: 0.85rem;
}
.inv-line-card .order-thumb {
  width: 40px;
  height: 40px;
}
.order-doc .inv-line-card .zar,
.order-doc .inv-line-card .zar-sym,
.order-doc .inv-line-card .zar-amt {
  color: #111;
}
.order-table {
  width: 100%;
  border-collapse: collapse;
  color: #111;
  font-size: 0.82rem;
  table-layout: fixed;
}
.order-table th,
.order-table td {
  padding: 8px 6px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid #eee;
}
.order-table th {
  font-weight: var(--fw-strong);
}
.order-table th.num,
.order-table td.num,
.order-table .num {
  text-align: right;
  white-space: nowrap;
}
.order-prod-inner {
  display: flex;
  align-items: center;
  gap: 8px;
}
.order-thumb {
  width: 36px;
  height: 36px;
  object-fit: cover;
  border: 1px solid #ddd;
  flex: 0 0 auto;
  background: #f5f5f5;
}
.order-thumb.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.55rem;
  color: #888;
  text-align: center;
  line-height: 1.1;
  padding: 2px;
}
.order-totals {
  margin-top: 14px;
  text-align: right;
}
.order-totals > div {
  margin-bottom: 4px;
}
.order-totals span {
  display: inline-block;
  min-width: 130px;
  text-align: right;
  margin-right: 12px;
}
.order-total {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 2px solid #111;
  font-size: 1.05rem;
}
.order-foot-meta {
  margin-top: 18px;
  font-size: 0.85rem;
}
.order-crm-disclaimer {
  margin-top: 10px;
  font-size: 0.78rem;
  color: var(--muted, #666);
}
.order-sign-page {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px dashed #bbb;
}
.order-sign-page h3 {
  margin: 14px 0 6px;
  font-size: 0.95rem;
}
.order-sign-line {
  border-bottom: 1px solid #222;
  min-height: 28px;
  max-width: 280px;
  margin: 4px 0 2px;
}
.order-sign-line.tall {
  min-height: 52px;
}
.order-sign-line.short {
  max-width: 160px;
  min-height: 22px;
}
.order-sign-hint {
  margin: 0 0 4px;
  font-size: 0.72rem;
  color: #666;
}
.order-x {
  display: none;
}
.sky-form-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 8px 0 24px;
}
/* ONE UI laptop: Visit/Call form not a skinny 720 column */
body.shell-phone .sky-form-wrap {
  max-width: min(960px, 92vw);
}
/* WAVE2-CALL-FORM-DARK ? kill white Arial paper; match Forms/Settings elevated sheet */
.sky-form {
  background: var(--bg-elevated);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 20px 18px 28px;
  font-family: var(--font);
  box-shadow: var(--shadow);
}
.sky-logo {
  text-align: center;
  font-weight: var(--fw-strong);
  letter-spacing: 0.08em;
  font-size: 1.25rem;
  color: var(--ink);
}
.sky-brand-logo {
  display: block;
  width: min(200px, 55vw);
  height: auto;
  margin: 0 auto 6px;
  object-fit: contain;
}
.sky-tag {
  text-align: center;
  font-size: 0.72rem;
  color: var(--muted);
  margin: 4px 0 18px;
}
.sky-title {
  font-size: 1.55rem;
  margin: 0 0 14px;
  color: var(--ink);
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
  text-align: center;
}
.sky-meta {
  margin-bottom: 8px;
}
.sky-meta > div {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.88rem;
  color: var(--ink);
}
.sky-meta span {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
}
.sky-meta-cust {
  margin: 4px 0 12px;
}
.sky-meta-cust > div {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 0.88rem;
  color: var(--ink);
}
.sky-meta-cust span {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
}
.sky-meta-cust #btnAfChangeCustInline {
  margin-top: 4px;
}
.af-cust-chooser {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
}
.sky-field {
  border-top: 1px solid var(--line);
  padding: 12px 0 10px;
}
.sky-q {
  color: var(--accent);
  font-size: 0.92rem;
  margin-bottom: 6px;
  font-weight: var(--fw-med);
}
/* Inherit global .field tokens ? do not force paper white inputs */
.sky-form .sky-a,
.sky-form .field {
  background: var(--bg-elevated-2);
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
}
.sky-form .sky-a:focus,
.sky-form .field:focus {
  outline: none;
  border-color: var(--accent);
  background: #3a3a3c;
  box-shadow: var(--btn-focus-ring);
}
.sky-photo-preview-host[hidden] {
  display: none !important;
}
.sky-photo-preview {
  display: block;
  max-width: 100%;
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
/* Call Form multi-photo bag (crm573) — append thumbs; intentional × remove only */
.sky-photo-bag {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}
.sky-photo-bag-item {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  overflow: hidden;
  background: var(--bg-elevated, #2c2c2e);
}
.sky-photo-bag-thumb {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sky-photo-bag-rm {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 28px;
  min-width: 28px;
  height: 28px;
  padding: 0;
  line-height: 1;
  font-size: 1.05rem;
  border-radius: var(--btn-radius, var(--radius-sm)) !important;
}
.sky-photo-bag-count {
  margin: 8px 0 0;
}
.sky-foot {
  text-align: center;
  color: var(--muted);
  font-size: 0.82rem;
  margin-top: 18px;
}
.sky-form .sky-form-lead,
.sky-form .sub {
  color: var(--muted);
}
@media (max-width: 720px) {
  .order-head {
    flex-direction: column;
    align-items: stretch;
  }
  .order-head-right {
    max-width: none;
    align-items: flex-start;
    text-align: left;
  }
  .order-grid {
    grid-template-columns: 1fr;
  }
  .order-side {
    text-align: left;
  }
  .order-brand-logo {
    width: min(180px, 56vw);
  }
}
.inv-card-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 10px 0 8px;
}
.inv-card {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 2px 12px;
  text-align: left;
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--bg-elevated-2);
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.inv-card:hover {
  border-color: var(--accent, #0a84ff);
  background: rgba(10, 132, 255, 0.1);
}
.inv-card-top {
  grid-column: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
}
.inv-card-type {
  color: var(--muted);
  font-size: 0.85rem;
}
.inv-card-meta {
  grid-column: 1;
  color: var(--muted);
  font-size: 0.82rem;
}
.inv-card-total {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  font-weight: var(--fw-semi);
  white-space: nowrap;
}
.acct-card.acct-card-static {
  cursor: default;
}
.acct-card.acct-card-static:hover {
  border-color: var(--line);
  background: var(--bg-elevated-2);
}
.acct-card-total.inv-card-total {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}
.acct-card-amt {
  font-weight: var(--fw-semi);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-variant-numeric: tabular-nums;
}
.acct-card-amt .amt-sign {
  font-weight: 700;
  font-size: 1.05em;
  line-height: 1;
}
.acct-card-amt.owe,
.acct-card-amt.debit {
  color: #ff453a;
}
.acct-card-amt.credit {
  color: #30d158;
}
.acct-card-bal {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  white-space: nowrap;
}
.inv-detail-head h1 {
  margin: 4px 0;
}
@media (min-width: 901px) {
  body:not(.shell-phone) .store-hub{
    grid-template-columns: 270px minmax(0, 1fr);
    align-items: start;
  }
  body:not(.shell-phone) .store-hub-actions{
    display: none;
  }
}

.stub-box {
  margin: 16px 0 18px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px dashed var(--line-strong);
  background: var(--bg-elevated-2);
}
.stub-box p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}
.hist-table-wrap {
  margin: 14px 0 8px;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
}
.hist-table-full {
  max-height: min(70vh, 720px);
  overflow: auto;
}
.hist-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  white-space: nowrap;
}
.hist-table th,
.hist-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.hist-table th {
  color: var(--muted);
  font-weight: var(--fw-med);
  background: rgba(0, 0, 0, 0.18);
  position: sticky;
  top: 0;
  z-index: 1;
}
.hist-table .linkish,
button.linkish {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  color: #6eb6ff;
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  text-align: left;
}
.hist-table tbody tr:last-child td {
  border-bottom: none;
}
.led-type {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  padding: 2px 8px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255,255,255,0.06);
  color: var(--ink-secondary);
  white-space: nowrap;
}
.led-type.inv { background: color-mix(in srgb, var(--doc-invoice) 22%, transparent); color: var(--doc-invoice); }
.led-type.pay { background: color-mix(in srgb, var(--doc-payment) 18%, transparent); color: var(--doc-payment); }
.led-type.credit { background: color-mix(in srgb, var(--doc-credit) 18%, transparent); color: var(--doc-credit); }
.led-type.debit { background: color-mix(in srgb, var(--doc-debit) 18%, transparent); color: var(--doc-debit); }
.hist-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 12px 0 8px;
}
.hist-tab {
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: inherit;
  font: inherit;
  font-size: 0.85rem;
  padding: 7px 12px;
  min-height: var(--btn-h);
  display: inline-flex;
  align-items: center;
  border-radius: var(--btn-chip-radius);
  box-shadow: var(--btn-ghost-shadow);
  cursor: pointer;
}
.hist-tab.active {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
/* Phone: floor ?44px touch (PAGE_TRUE hist tabs) ? keep chip-on tokens */
body.shell-phone .hist-tab {
  min-height: max(44px, var(--btn-h));
  padding: 10px 14px;
  box-sizing: border-box;
}
.hist-empty {
  text-align: left;
  margin: 12px 0;
}
/* hist-search-row rules defined once above ? keep mobile stack */
@media (max-width: 640px) {
  .hist-search-row {
    flex-wrap: wrap;
  }
  .hist-search-row .hist-search-input,
  .hist-search-row .field {
    flex: 1 1 100%;
  }
  .hist-search-row .hist-search-btn {
    flex: 1 1 auto;
  }
}
.hist-card {
  max-width: none;
}
.info-grid {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.info-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 8px;
  align-items: start;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.info-k {
  color: var(--muted);
  font-size: 0.85rem;
}
.info-row.locked .info-v {
  opacity: 0.95;
}
.info-row.locked .info-k::after {
  content: " · locked";
  font-size: 0.75em;
  opacity: 0.7;
}
/* Phone Insights fallback ? stacked key/value card when there's no dedicated
 * card renderer for an export (reuses .info-row inside a bordered card). */
.insight-kv-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
  padding: 10px 14px 2px;
}
.insight-kv-card .info-row:last-child {
  border-bottom: 0;
  padding-bottom: 8px;
}
.cust-map-block {
  margin-top: 18px;
  padding-top: 4px;
}
.cust-map-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}
.cust-map-go {
  flex: 0 0 auto;
  width: 36px;
  min-width: 36px;
  height: 36px;
  margin: 0;
  padding: 0;
}
body.shell-phone .cust-map-go {
  width: var(--btn-h);
  min-width: var(--btn-h);
  height: var(--btn-h);
  min-height: var(--btn-h);
  padding: 0;
  border-radius: var(--btn-icon-radius, 10px);
  display: grid;
  place-items: center;
  box-sizing: border-box;
}
body.shell-phone .sky-sticky-visit,
body.shell-phone .home-start-cta.sky-sticky-visit {
  min-height: var(--btn-h);
  border-radius: var(--btn-radius);
}
/* Hub Call / WhatsApp ? icon-only in header (.is-header); legacy body pills hidden */
.hub-quick-contact {
  display: none;
}
.hub-quick-contact:not(.is-header) {
  display: none !important;
}
.hub-quick-contact.is-header {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
}
.hub-quick-contact.is-header .hub-comm-ico {
  flex-shrink: 0;
  text-decoration: none;
  overflow: visible;
}
.hub-quick-contact.is-header .hub-comm-ico svg,
.hub-comm-ico svg {
  overflow: visible;
  display: block;
}
.hub-quick-contact.is-header .hub-comm-ico[aria-label="WhatsApp"] {
  color: #25d366;
  border-color: rgba(37, 211, 102, 0.5);
  background: rgba(37, 211, 102, 0.14);
}
.hub-quick-contact.is-header .hub-comm-ico[aria-label="WhatsApp"]:hover {
  color: #2fe576;
  background: rgba(37, 211, 102, 0.22);
  border-color: rgba(37, 211, 102, 0.7);
}
/* Hub Location uses the same .near-me-map-wrap chrome as Customers list Map / Near me. */
.cust-map-block .near-me-map-wrap {
  height: 300px;
  min-height: 240px;
}
.store-map .near-me-map-wrap {
  height: 260px;
  min-height: 220px;
}
.cust-map-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.cust-map-addr {
  margin: 0 0 10px;
}
.cust-addr-lines {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0 0 10px;
}
.cust-addr-line {
  margin: 0;
  font-size: var(--btn-fs-sm, 0.85rem);
  line-height: 1.35;
  color: var(--muted, #8b93a7);
}
.cust-addr-label {
  font-weight: 650;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-size: 0.72em;
  color: var(--muted, #8b93a7);
  margin-right: 4px;
}
.cust-addr-value {
  color: var(--text, #e8ecf4);
  font-size: 1.05em;
}
/* Quiet "No pin yet" / init-failure ? sits inside .near-me-map-wrap (liberty chrome). */
.cust-map-nopin {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e8eef4;
  color: #5c6578;
  font-size: 0.85rem;
  line-height: 1.35;
  text-align: center;
  padding: 16px 20px;
  z-index: 2;
}
.cust-map-nopin span {
  max-width: 18rem;
}
.cust-map-empty {
  padding: 10px 0 2px;
}
.cust-map-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin: 8px 0 0;
}
.cust-map-gmaps {
  font-size: 12px;
  color: var(--accent, #0a84ff);
  text-decoration: none;
}
.cust-map-gmaps:hover {
  text-decoration: underline;
}
@media (max-width: 700px) {
  .cust-map-block .near-me-map-wrap {
    height: 240px;
    min-height: 220px;
  }
  .store-map .near-me-map-wrap {
    height: 220px;
    min-height: 200px;
  }
}
textarea.field.area {
  min-height: 88px;
  resize: vertical;
  line-height: 1.4;
}
.field-hint {
  margin: 4px 0 0;
  font-size: 12px;
  color: var(--muted);
}
select.field {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 36px;
}
/* Phone shell: native selects still use .field chrome ? 44px hit + dark menu. */
body.shell-phone select.field,
body.shell-phone select:not([multiple]):not(.shop-sort-select) {
  min-height: var(--btn-h);
  font-size: 16px; /* iOS: avoid focus zoom */
  border-radius: var(--radius-sm);
  background-color: var(--bg-elevated-2);
  color: var(--ink);
  border: 1px solid var(--line-strong);
  color-scheme: dark;
}

/* Shop chrome ? sits under the fixed app header.
   Solid background (no gradient/blur/compositor layer) ? Safari renders the
   sticky + backdrop-filter + translateZ combo as a thick dark band bleeding
   over the product grid, so we keep this simple and predictable everywhere. */
.shop-chrome {
  position: sticky;
  /* Header is outside .app-body scrollport ? stick to the scroller top. */
  top: 0;
  z-index: 30;
  margin: 0 0 8px;
  padding: 4px 0 6px;
  background: var(--bg, #000);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transform: none;
  will-change: auto;
  border-bottom: 1px solid var(--line);
}
.shop-topbar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}
.shop-deliver {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}
.shop-deliver-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.shop-deliver strong {
  font-size: 0.78rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
  max-width: 100%;
  align-self: stretch;
}
.shop-deliver .context {
  font-size: 0.68rem;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}
.shop-pl-badge {
  display: inline-flex;
  align-items: center;
  margin-top: 2px;
  padding: 2px 8px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  color: var(--ink-secondary);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: fit-content;
  align-self: flex-start;
}
.shop-pl-seg {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  flex: 0 0 auto;
  align-self: flex-start;
  margin-top: 4px;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  gap: 2px;
}
.pl-seg-btn {
  appearance: none;
  box-sizing: border-box;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  padding: 6px 12px;
  border-radius: var(--btn-radius-seg-item);
  cursor: pointer;
  line-height: 1.2;
  white-space: nowrap;
  transition: background 0.18s var(--ease), color 0.18s var(--ease), transform 0.15s var(--ease), box-shadow 0.18s var(--ease), border-color 0.18s var(--ease);
}
.pl-seg-btn:hover {
  color: var(--ink);
}
.pl-seg-btn.active {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: transparent;
}
.pl-seg-btn:active { transform: scale(0.97); }
.shop-search { margin-bottom: 0; }
.shop-search-field {
  padding: 9px 12px;
  font-size: 16px; /* iOS zoom prevention */
  min-height: 40px;
  border-radius: var(--btn-radius, var(--radius-sm));
}
.cart-btn {
  position: relative;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  color: var(--ink);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: border-color 0.18s var(--ease), color 0.18s var(--ease), transform 0.12s var(--ease);
}
.cart-btn:active { transform: scale(0.92); }
.cart-btn.has-items {
  border-color: var(--accent);
  color: var(--accent-press);
}
.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: var(--btn-chip-radius);
  background: var(--accent);
  color: #fff;
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  display: grid;
  place-items: center;
  line-height: 1;
}
.cart-badge[hidden] { display: none !important; }
.cat-rail {
  display: none; /* replaced by .cat-panel */
}
.cat-chip { display: none; }

/* Full-width shop body: categories panel + catalogue */
.shop-body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: start;
  /* Progressive enhancement ? animates the rail collapse/expand on browsers
     that support animating grid tracks; a no-op (instant) elsewhere. */
  transition: grid-template-columns 0.22s var(--ease);
}
.cat-panel,
.shop-body > .panel-foldable[data-panel="cat-panel"] {
  background: var(--rail-bg);
  border: 1px solid var(--rail-line);
  border-radius: var(--rail-radius);
  padding: 10px;
  min-width: 0;
}
.shop-body > .panel-foldable[data-panel="cat-panel"] .sky-rail-head,
.shop-body > .panel-foldable[data-panel="cat-panel"] .sky-filter-head {
  border-bottom: 1px solid var(--rail-line);
  padding: 2px 2px 8px;
  margin: 0 0 8px;
}
/* Categories rail matches Calendar Filter flush premium column. */
.shop-body > .panel-foldable.sky-filter-premium[data-panel="cat-panel"] {
  border: 0;
  border-left: 1px solid var(--acal-line, var(--rail-line));
  border-radius: 0;
  padding: var(--rail-pad-y) 14px 16px;
  background: var(--rail-bg);
}
/* Single header lives in .sky-rail-head ("Categories ? N") ? this row only
   ever holds the Show all/Collapse control on narrow (<901px) viewports. */
.cat-panel-head {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: 6px;
}
.cat-toggle {
  width: auto !important;
  margin: 0 !important;
  min-height: 28px;
  padding: 3px 9px !important;
  font-size: 0.72rem !important;
  border-radius: 6px !important;
}
.cat-list-full {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-height: 88px;
  overflow: hidden;
  transition: max-height 0.2s var(--ease);
}
.shop-body.cats-open .cat-list-full {
  max-height: none;
  overflow: visible;
}
.cat-pick {
  flex: 0 0 auto;
  border: 1px solid var(--btn-ghost-border, var(--line));
  background: var(--btn-ghost-bg, var(--bg-elevated-2));
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius);
  padding: 6px 10px;
  font-size: 0.76rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  text-align: left;
  letter-spacing: -0.01em;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease), transform 0.1s var(--ease),
    box-shadow 0.14s var(--ease);
}
.cat-pick:hover {
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}
.cat-pick:active { transform: scale(0.96); }
.cat-pick.active {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  font-weight: var(--fw-med);
  box-shadow: var(--btn-chip-on-shadow);
}

/* Laptop+: Categories rail opt-in via Categories toggle (default closed = full width). */
@media (min-width: 901px) {
  body:not(.shell-phone) .shop-body{
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  /* Categories rail on the RIGHT ? same track as Calendar Filter / Nav */
  body:not(.shell-phone) .shop-body.cats-rail-open:has([data-panel="cat-panel"]),
  body:not(.shell-phone) .shop-body:has(.panel-foldable[data-panel="cat-panel"]){
    grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max));
  }
  body:not(.shell-phone) .shop-body.cat-folded{
    grid-template-columns: minmax(0, 1fr);
  }
  body:not(.shell-phone) .cat-panel,
  body:not(.shell-phone) .shop-body > .panel-foldable[data-panel="cat-panel"]{
    position: sticky;
    top: 8px;
    max-height: calc(100vh - 120px);
    display: flex;
    flex-direction: column;
    padding: 10px;
    overflow: hidden; /* outer chrome never scrolls ? list does */
  }
  /* Single scroll: kill .panel-fold-body overflow:auto nesting with .cat-list-full */
  body:not(.shell-phone) .shop-body > .panel-foldable[data-panel="cat-panel"] .panel-fold-body{
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  body:not(.shell-phone) .shop-body > .panel-foldable[data-panel="cat-panel"] .cat-panel-inner{
    flex: 1;
    min-height: 0;
  }
  body:not(.shell-phone) .cat-toggle{
    display: none; /* always show all on laptop */
  }
  body:not(.shell-phone) .cat-panel-head{
    display: none; /* nothing left to show once the toggle is hidden */
  }
  body:not(.shell-phone) .cat-list-full,
  body:not(.shell-phone) .shop-body .cat-list-full,
  body:not(.shell-phone) .shop-body.cats-open .cat-list-full{
    flex-direction: column;
    flex-wrap: nowrap;
    gap: 1px;
    max-height: none;
    overflow: auto; /* sole vertical scrollbar for Categories ? N */
    flex: 1;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
    padding-right: 2px;
  }
  body:not(.shell-phone) .cat-list-full::-webkit-scrollbar{
    width: 6px;
  }
  body:not(.shell-phone) .cat-list-full::-webkit-scrollbar-thumb{
    background: rgba(255, 255, 255, 0.16);
    border-radius: 6px;
  }
  body:not(.shell-phone) .cat-list-full::-webkit-scrollbar-track{
    background: transparent;
  }
  body:not(.shell-phone) .cat-pick{
    width: 100%;
    border: 1px solid transparent;
    border-radius: var(--btn-chip-radius);
    white-space: normal;
    line-height: 1.25;
    padding: 6.5px 9px;
    font-size: 0.74rem;
    background: transparent;
    box-shadow: none;
  }
  body:not(.shell-phone) .cat-pick:hover{
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.08);
  }
  body:not(.shell-phone) .cat-pick.active{
    background: var(--btn-chip-on-bg);
    border-color: var(--btn-chip-on-border);
    box-shadow: var(--btn-chip-on-shadow);
    color: #fff;
  }
}
.shop-main-solo {
  min-width: 0;
  padding-bottom: 12px;
}
.shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.shop-toolbar .cat-heading {
  margin: 0;
  flex: 1;
  min-width: 0;
}
.shop-toolbar-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.shop-sort-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.shop-sort-select {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-radius-seg);
  background-color: var(--btn-ghost-bg);
  color: var(--ink);
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  min-height: var(--btn-h-sm);
  padding: 6px 28px 6px 10px;
  cursor: pointer;
  max-width: 11.5rem;
  box-shadow: var(--btn-ghost-shadow);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23888' d='M0 0l5 6 5-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.shop-sort-select:focus {
  outline: none;
  border-color: rgba(10, 132, 255, 0.55);
  box-shadow: var(--btn-focus-ring);
}
.img-size-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
/* Product card action row - stepper + Add share one height / radius language
   (squircle via --btn-radius / --btn-chip-radius on phone + PC). */
.add-row,
.add-row.product-actions {
  display: flex;
  gap: 8px;
  align-items: stretch;
  margin-top: 10px;
  flex-wrap: nowrap;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
}
/* Shop catalogue only ? qty/Add row (do not touch cart steppers). */
.products .add-row,
.products .add-row.product-actions,
.products-phone .add-row,
.products-phone .add-row.product-actions {
  --product-qty-row-h: 40px;
  height: var(--product-qty-row-h);
  min-height: var(--product-qty-row-h);
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
}
.products .qty-stepper,
.products-phone .qty-stepper {
  height: var(--product-qty-row-h, 40px);
  min-height: var(--product-qty-row-h, 40px);
}
.products .qty-btn,
.products-phone .qty-btn {
  width: 40px;
  min-width: 40px;
  height: 100%;
  box-sizing: border-box;
}
/* Pin Qty+Add to the bottom of the card meta so Unit-only cards line up
   with Inner/Case cards in the same grid row. */
.product .meta > .add-row.product-actions {
  margin-top: auto;
  padding-top: 10px;
}
.add-row .btn,
.add-row .btn.add-sku {
  width: auto;
  margin-top: 0;
  flex: 1 1 auto;
  min-width: 72px;
  height: 100%;
  min-height: 0 !important;
  padding: 0 14px !important;
  font-size: var(--btn-fs-sm) !important;
  font-weight: var(--fw-semi) !important;
  border-radius: var(--btn-radius) !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--btn-primary-shadow);
  box-sizing: border-box;
}
.add-row .btn.primary:hover {
  box-shadow: var(--btn-primary-shadow-hover);
}
.qty-stepper {
  display: inline-flex;
  align-items: stretch;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-chip-radius);
  overflow: hidden;
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  flex: 0 0 auto;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  box-sizing: border-box;
}
.add-row .qty-stepper,
.add-row.product-actions .qty-stepper {
  height: 100%;
  min-height: 0;
  align-self: stretch;
}
.qty-stepper .qty {
  width: 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  padding: 0 2px;
  font-size: 0.86rem;
  font-weight: var(--fw-semi);
  text-align: center;
  color: var(--ink);
  -moz-appearance: textfield;
  appearance: textfield;
}
.qty-stepper .qty::-webkit-outer-spin-button,
.qty-stepper .qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.qty-btn {
  width: 40px;
  min-width: 40px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.12s var(--ease);
}
.qty-btn:hover { background: rgba(255,255,255,0.06); }
.qty-btn:active { background: rgba(255,255,255,0.1); }
.qty-btn:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px rgba(10, 132, 255, 0.45);
}
.sticky-actions {
  display: flex;
  gap: 8px;
}
.sticky-actions .btn { flex: 1; width: auto; margin-top: 0; }
.cart-card {
  box-sizing: border-box;
  width: 100%;
  max-width: min(1120px, 100%);
  margin-left: auto;
  margin-right: auto;
}
.cart-card > .hub-kicker,
.cart-card .cart-head .hub-kicker,
.cart-card .cart-head h1,
.cart-card .cart-head .sub,
.cart-card > .sub {
  text-align: left;
}
.cart-card .cart-head .sub {
  margin-bottom: 0;
}
.cart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.cart-head h1 { margin: 0; }
.cart-site-label {
  margin-top: 10px;
  display: block;
}
.cart-site-seg {
  margin: 6px 0 4px;
  max-width: 320px;
}
.checkout-box .cart-site-seg .acal-seg-btn {
  flex: 1;
  min-width: 0;
}
/* Greyed but still hit-testable: the tap must reach JS to explain WHY it is greyed,
   so no `pointer-events: none` here (that swallowed the tap and read as "dead button"). */
.cart-site-seg .acal-seg-btn:disabled,
.cart-site-seg .acal-seg-btn[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, rgba(235, 235, 245, 0.42));
  background: var(--btn-disabled-bg, rgba(58, 58, 60, 0.55));
  cursor: not-allowed;
}
.cart-site-seg .acal-seg-btn[aria-disabled="true"].is-on {
  background: var(--btn-disabled-bg, rgba(58, 58, 60, 0.55));
  box-shadow: none;
}
.cart-site-hint.is-warn {
  color: color-mix(in srgb, var(--warn, #ffd60a) 72%, var(--muted));
}
.cart-assign-hint {
  color: var(--muted);
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}
.cart-assign-cta .btn,
.checkout-box #btnFillNewDetails {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.cart-assign-cta .btn svg,
.checkout-box #btnFillNewDetails svg {
  flex-shrink: 0;
  opacity: var(--crm-ico-idle-opacity, 0.85);
}
.cart-assign-cta .btn.primary svg,
.checkout-box #btnFillNewDetails.primary svg {
  opacity: 1;
}
.cart-lines { margin-bottom: 16px; }
.cart-line {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.cart-line:last-child { border-bottom: 0; }
.cart-thumb {
  width: 72px;
  height: 72px;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.18s ease;
}
.cart-thumb.is-loaded {
  opacity: 1;
  background: #ffffff;
}
.cart-thumb.empty {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 2px;
  font-size: 0.65rem;
  color: var(--muted);
  background: var(--bg-elevated);
  text-align: center;
  padding: 4px;
  box-sizing: border-box;
  opacity: 1;
}
.cart-thumb.empty .thumb-empty-ico {
  width: 16px;
  height: 16px;
}
.cart-line-body { flex: 1; min-width: 0; }
.cart-line-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
}
.cart-order-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}
/* crm792: drag grip replaces ↑↓ .cart-move — Home/bottom-nav gesture language */
.cart-line-handle {
  margin-top: 0;
  width: var(--btn-h-sm);
  min-width: var(--btn-h-sm);
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--btn-chip-radius);
  font-weight: var(--fw-semi);
  line-height: 1;
  color: var(--muted);
  cursor: grab;
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}
.cart-line-handle:active {
  cursor: grabbing;
}
body.shell-phone .cart-line-handle {
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
}
/* .is-cart-dragging = feature marker; lift look from .is-crm-dragging */
/* crm804: peer-edge insert cue (backup to .crm-drag-insert-line). */
.cart-line.is-cart-drop-before,
.cart-table tbody tr.is-cart-drop-before,
.cart-line.is-crm-drop-target.is-cart-drop-before,
.cart-table tbody tr.is-crm-drop-target.is-cart-drop-before {
  box-shadow: inset 0 5px 0 0 var(--accent, #0a84ff),
    inset 0 14px 22px -10px color-mix(in srgb, var(--accent) 70%, transparent);
}
.cart-line.is-cart-drop-after,
.cart-table tbody tr.is-cart-drop-after,
.cart-line.is-crm-drop-target.is-cart-drop-after,
.cart-table tbody tr.is-crm-drop-target.is-cart-drop-after {
  box-shadow: inset 0 -5px 0 0 var(--accent, #0a84ff),
    inset 0 -14px 22px -10px color-mix(in srgb, var(--accent) 70%, transparent);
}
body.shell-phone .cart-lines-list > .cart-line.is-cart-drop-before .cart-line-front::before,
body.shell-phone .cart-lines-list > .cart-line.is-crm-drop-target.is-cart-drop-before .cart-line-front::before {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  top: 4px;
  height: 5px;
  border-radius: 999px;
  background: var(--accent, #0a84ff);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 55%, #fff 20%),
    0 0 14px rgba(10, 132, 255, 0.85);
  z-index: 6;
  pointer-events: none;
}
body.shell-phone .cart-lines-list > .cart-line.is-cart-drop-after .cart-line-front::after,
body.shell-phone .cart-lines-list > .cart-line.is-crm-drop-target.is-cart-drop-after .cart-line-front::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 4px;
  top: auto;
  height: 5px;
  border-radius: 999px;
  background: var(--accent, #0a84ff);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 55%, #fff 20%),
    0 0 14px rgba(10, 132, 255, 0.85);
  z-index: 6;
  pointer-events: none;
}
.cart-line-actions .rm-line {
  margin-top: 0;
  flex: 0 0 auto;
}
.cart-line-total {
  font-weight: var(--fw-med);
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}
.cart-price-edit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  justify-content: flex-end;
  max-width: 100%;
}
.cart-money-wrap {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  background: transparent;
  border: 0;
  padding: 0;
  border-radius: 0;
  box-shadow: none;
}
.cart-price-r {
  flex-shrink: 0;
  color: var(--muted);
  font-weight: 600;
  font-size: 12px;
}
.cart-disc-edit {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  justify-content: flex-end;
}
.cart-price-inp,
.cart-disc-inp {
  /* Squircle only - never stadium / 999px / 980px (kill iOS native oval via appearance). */
  appearance: none;
  -webkit-appearance: none;
  width: 72px;
  min-width: 0;
  min-height: var(--btn-h-sm, 34px);
  height: var(--btn-h-sm, 34px);
  padding: 4px 8px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  letter-spacing: -0.01em;
  border: 1px solid var(--line-strong);
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  background: var(--bg-elevated-2);
  box-shadow: none;
  box-sizing: border-box;
  transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.cart-price-inp:focus,
.cart-disc-inp:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.22);
  background: #3a3a3c;
}
.cart-disc-inp {
  width: 52px;
}
.cart-price-unit,
.cart-disc-suf {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}
.cart-price-read {
  font-variant-numeric: tabular-nums;
  font-weight: var(--fw-med);
}
/* Quiet "price overridden" indicator ? a small dot, not a debug-y text pill.
 * Hover/focus still surfaces the reason via the title attribute. */
.cart-price-mark {
  display: inline-flex;
  width: 6px;
  height: 6px;
  margin-left: 4px;
  border-radius: 50%;
  background: var(--accent, #0a84ff);
  vertical-align: middle;
  flex-shrink: 0;
}
/* Standing deal free gift lines */
.cart-deal-badge {
  display: inline-flex;
  align-items: center;
  margin: 2px 0 0;
  padding: 2px 8px;
  min-height: 20px;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1px solid var(--btn-chip-on-border, var(--btn-ghost-border));
  border-radius: var(--btn-chip-radius);
  background: var(--btn-chip-on-bg, var(--btn-ghost-bg));
  box-shadow: var(--btn-chip-on-shadow, var(--btn-ghost-shadow));
}
.cart-gl-badge {
  display: inline-flex;
  align-items: center;
  margin: 2px 0 0 6px;
  padding: 2px 8px;
  min-height: 20px;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated);
}
.cart-gl-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
}
.cart-gl-add {
  margin: 12px 0 4px;
}
.checkout-box.cart-checkout-kit > .cart-gl-add,
.checkout-box.cart-checkout-kit > .admin-opt-group.cart-gl-add {
  margin: 8px 0 4px;
}
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-row {
  min-height: 48px;
}
.sky-cart.is-phone .cart-site-hint {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  line-clamp: 1;
  overflow: hidden;
  white-space: normal;
}
.cart-gl-search {
  display: block;
  margin: 0 0 10px;
}
.cart-gl-list {
  max-height: min(52vh, 420px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.cart-gl-status {
  margin: 8px 0;
  padding: 0 4px;
}
.cart-gl-amount-head {
  margin-bottom: 10px;
}
.cart-gl-field {
  display: flex;
  margin-bottom: 12px;
}
.cart-gl-amount-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.cart-line.is-deal-free,
.cart-table tr.cart-row-deal-free {
  background: color-mix(in srgb, var(--btn-chip-on-bg, #e8f2ff) 55%, transparent);
}
.cart-deal-free-price,
.cart-free-qty {
  font-variant-numeric: tabular-nums;
  font-weight: var(--fw-med);
  color: var(--muted);
}
.cart-price-over .cart-price-inp,
.cart-line-pricing.cart-price-over .cart-price-inp {
  border-color: color-mix(in srgb, var(--accent, #0a84ff) 45%, var(--line));
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent, #0a84ff) 18%, transparent);
}
.cart-line-pricing {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
  margin: 6px 0 2px;
}
.cart-mini-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11px;
  color: var(--muted);
  font-weight: 600;
}
.cart-pricing-hint {
  margin: 0 0 10px;
  color: var(--muted);
}
body.shell-phone .cart-assign-hint,
body.shell-phone .cart-line-body > strong {
  overflow-wrap: anywhere;
  word-break: break-word;
}
body.shell-phone .cart-assign-cta .btn span {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  max-width: 100%;
}
.cart-bulk-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 14px;
  margin: 0 0 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated);
  box-shadow: var(--btn-ghost-shadow);
  box-sizing: border-box;
  max-width: 100%;
}
.cart-bulk-meta {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  margin-right: auto;
  align-self: center;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}
.cart-bulk-field {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-start;
}
.cart-bulk-field .cart-disc-edit,
.cart-bulk-field .cart-money-wrap {
  justify-content: flex-start;
}
.cart-bulk-bar .btn {
  margin-top: 0;
  width: auto;
  flex: 0 0 auto;
  align-self: flex-end;
  min-height: 32px;
}
.checkout-box {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.cart-layout {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.cart-main {
  min-width: 0;
}
/* PC shop: one primary cart entry ? header #btnHeaderCart (hide topbar duplicates). */
body:not(.shell-phone) .shop-topbar .quote-pill,
body:not(.shell-phone) .shop-topbar .cart-btn {
  display: none !important;
}
/* PC checkout: cart table left | sticky checkout right */
@media (min-width: 901px) {
  body:not(.shell-phone) .cart-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
    gap: 20px 28px;
    align-items: start;
  }
  body:not(.shell-phone) .cart-layout .checkout-box {
    position: sticky;
    top: calc(var(--hdr-h, 56px) + 12px);
    /* Cap so tall content (validation errors, branch picker, comments,
       totals, Send + Clear buttons) scrolls INSIDE the sidebar instead of
       being pinned off-screen by position:sticky (content taller than the
       sticky box's own containing block can never be scrolled into view ?
       this is what hid the "?customer." validation line and made Clear
       cart & draft unreachable on shorter PC screens).
       crm342: this was a flat `calc(100dvh - hdr - 24px)` ? correct ONLY
       once the box is actually stuck at `top`. Before that (page just
       loaded, box still in normal flow below the Order title/chips/banner),
       the box started well below the viewport top yet still claimed that
       full-viewport height, so it physically ran off the bottom of the
       screen ? Send/Clear were invisible with no scroll cue, and `.sky-cart
       .is-pc` had no real `height` (only `min-height`) so the whole page
       ALSO grew past the viewport, adding a second, hidden document-level
       scroll on top. Now that `.sky-cart.is-pc` is height-bound (see PAGE
       MAXIMIZE M3), `.cart-layout` resolves to a definite height, so `100%`
       here always matches the space actually left for the sidebar ? no
       viewport guessing, no overshoot, always reachable Send/Clear. */
    max-height: 100%;
    overflow-y: auto;
    overscroll-behavior: contain;
    border-top: none;
    padding-top: 0;
    border: 1px solid var(--line);
    border-radius: var(--btn-chip-radius);
    padding: 14px 14px 12px;
    background: var(--bg-elevated, var(--card, #fff));
    box-shadow: var(--btn-ghost-shadow);
  }
  body:not(.shell-phone) .cart-layout .checkout-box .sticky {
    position: static;
  }
}
/* PC quote cart ? dense table (phone keeps the .cart-line card stack above). */
.cart-table-wrap {
  margin: 0 0 16px;
  max-width: 100%;
}
.cart-table {
  table-layout: fixed;
  width: 100%;
  border-collapse: collapse;
  white-space: normal;
}
.cart-table col.cart-col-check { width: 40px; }
.cart-table col.cart-col-prod { width: auto; }
.cart-table col.cart-col-qty { width: 132px; }
.cart-table col.cart-col-price { width: 150px; }
.cart-table col.cart-col-disc { width: 92px; }
.cart-table col.cart-col-total { width: 110px; }
.cart-table col.cart-col-order { width: 88px; }
.cart-table col.cart-col-rm { width: 52px; }
.cart-table.cart-table-edit col.cart-col-price { width: 190px; }
.cart-table th.num,
.cart-table td.num {
  text-align: right;
}
.cart-table th.cart-th-qty,
.cart-table td.cart-td-qty {
  text-align: center;
}
.cart-table th.cart-th-check,
.cart-table td.cart-td-check {
  text-align: center;
  vertical-align: middle;
  width: 40px;
  padding-left: 8px;
  padding-right: 4px;
}
.cart-table th.cart-th-rm,
.cart-table td.cart-td-rm {
  text-align: center;
  white-space: nowrap;
  width: 52px;
}
.cart-table th.cart-th-order,
.cart-table td.cart-td-order {
  text-align: center;
  white-space: nowrap;
}
.cart-table th {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}
.cart-table th.cart-th-prod,
.cart-table td.cart-prod {
  text-align: left;
  overflow: hidden;
}
.cart-table th.cart-th-qty,
.cart-table th.cart-th-price,
.cart-table th.cart-th-disc,
.cart-table th.cart-th-total,
.cart-table th.cart-th-order,
.cart-table th.cart-th-rm,
.cart-table td.cart-td-qty,
.cart-table td.cart-td-price,
.cart-table td.cart-td-disc,
.cart-table td.cart-td-total,
.cart-table td.cart-td-order,
.cart-table td.cart-td-rm {
  padding-left: 8px;
  padding-right: 10px;
  box-sizing: border-box;
}
/* crm804: th text-align matches cell content (num alone was drifting Qty/Price). */
.cart-table th.cart-th-price,
.cart-table td.cart-td-price { text-align: left; }
.cart-table th.cart-th-disc,
.cart-table td.cart-td-disc { text-align: center; }
.cart-table th.cart-th-total,
.cart-table td.cart-td-total { text-align: right; }
.cart-table th.cart-th-qty,
.cart-table td.cart-td-qty { text-align: center; }
.cart-table td {
  white-space: normal;
  vertical-align: middle;
  box-sizing: border-box;
}
.cart-table td.cart-td-price,
.cart-table td.cart-td-disc,
.cart-table td.cart-td-total,
.cart-table td.cart-td-order,
.cart-table td.cart-td-qty {
  vertical-align: middle;
  overflow: hidden;
}
.cart-table td.cart-td-order .cart-order-controls {
  justify-content: center;
}
.cart-table td.cart-td-price {
  white-space: nowrap;
}
.cart-table td.cart-td-disc {
  white-space: nowrap;
}
.cart-table td.cart-td-total {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.cart-table .cart-price-edit {
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}
.cart-table td.cart-td-rm .rm-line,
.cart-line-actions .rm-line {
  margin-top: 0;
  width: var(--btn-h-sm);
  min-width: var(--btn-h-sm);
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--btn-chip-radius);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink);
}
.cart-table td.cart-td-rm .rm-line svg,
.cart-line-actions .rm-line svg {
  display: block;
  opacity: var(--crm-ico-idle-opacity, 0.85);
}
.cart-table td.cart-td-rm .rm-line:hover,
.cart-line-actions .rm-line:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
}
.cart-table td.cart-td-rm .rm-line:hover svg,
.cart-line-actions .rm-line:hover svg {
  opacity: 1;
}
/* Cart qty — compact squircle (fit-content); never full-width stadium pill. */
.cart-table-stepper,
.cart-phone-stepper {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  flex: 0 0 auto;
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  overflow: hidden;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
}
.cart-table-stepper {
  margin: 0 auto;
  width: fit-content;
}
.cart-table-stepper .qty,
.cart-phone-stepper .qty {
  width: 36px;
  min-width: 36px;
  font-size: 0.86rem;
  font-weight: var(--fw-semi);
}
.cart-table-stepper .qty-btn,
.cart-phone-stepper .qty-btn {
  width: 34px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  background: transparent;
}
.cart-table-stepper .qty-btn svg,
.cart-phone-stepper .qty-btn svg {
  display: block;
  opacity: 0.92;
}
.cart-table-stepper .qty-btn:hover,
.cart-phone-stepper .qty-btn:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 55%, #3a3a3c 45%);
}
.cart-checkout-sticky #btnSubmit,
.cart-checkout-sticky #btnCreateQuote,
.cart-checkout-sticky #btnPreviewPdf,
.cart-checkout-sticky #btnBackShop2,
.cart-checkout-sticky #btnClearCart,
.cart-checkout-sticky #btnFillNewDetails {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.cart-checkout-sticky #btnSubmit:not(:disabled) {
  box-shadow: var(--btn-primary-shadow-elevated);
}
.cart-checkout-sticky #btnSubmit svg,
.cart-checkout-sticky #btnPreviewPdf svg,
.cart-checkout-sticky #btnBackShop2 svg,
.cart-checkout-sticky #btnClearCart svg,
.cart-checkout-sticky #btnFillNewDetails svg {
  flex-shrink: 0;
}
.cart-checkout-sticky #btnPreviewPdf svg,
.cart-checkout-sticky #btnBackShop2 svg,
.cart-checkout-sticky #btnClearCart svg {
  opacity: var(--crm-ico-idle-opacity, 0.85);
}
.cart-prod-inner {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.cart-table-thumb {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  flex-shrink: 0;
  opacity: 0;
  transition: opacity 0.18s ease;
}
.cart-table-thumb.is-loaded {
  opacity: 1;
  background: #ffffff;
}
.cart-table-thumb.empty {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0;
  font-size: 0.5rem;
  color: var(--muted);
  background: var(--bg-elevated);
  overflow: hidden;
  opacity: 1;
}
.cart-table-thumb.empty .thumb-empty-ico {
  width: 14px;
  height: 14px;
}
.cart-table-thumb.empty span {
  display: none;
}
.cart-prod-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.cart-prod-text strong {
  font-weight: var(--fw-med);
  line-height: 1.25;
}
.cart-prod-sku {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: -0.01em;
}
/* Compact in-cart UOM seg (crm788) — reuse .uom-row / .uom-btn + --btn-seg-* */
.cart-uom-row {
  margin: 4px 0 0;
  height: 28px;
  min-height: 28px;
  max-width: 220px;
  width: fit-content;
  flex: 0 1 auto;
}
.cart-uom-row .uom-btn {
  padding: 0 8px;
  font-size: 0.68rem;
  flex: 0 1 auto;
  min-width: 2.4em;
}
.cart-line-uom-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
}
.cart-line-uom-meta .cart-uom-row {
  margin-top: 0;
}
.cart-line-sku {
  color: var(--muted);
}
.cart-prod-text .cart-uom-row {
  margin-top: 2px;
}
.products.img-xl .product-media {
  width: 100%;
}
.products.img-xl .product-media .thumb {
  width: 100%;
  height: 100%;
}

.back-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  padding: 0;
}
.back-bar-split { flex-wrap: wrap; }
.back-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  max-width: 100%;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: var(--btn-radius);
  font: inherit;
  font-weight: var(--fw-med);
  font-size: 0.9rem;
  letter-spacing: -0.01em;
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  color: var(--ink);
  flex: 0 0 auto;
  margin: 0;
  cursor: pointer;
  box-sizing: border-box;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease);
}
.back-btn:hover {
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--ink);
}
.back-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.back-btn.ghost { background: transparent; box-shadow: none; }
.btn.back-btn { width: auto !important; margin-top: 0 !important; }
.shop-topbar .back-btn { padding: 8px 12px; }

/* In-app PDF viewer ? Back stays in-app (PWA-safe). Phone = full-bleed stage. */
.pdf-view-page {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
}
.pdf-view-header {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  margin: 0;
  min-height: var(--btn-h);
}
.pdf-view-header .back-btn { flex: 0 0 auto; }
/* ONE UI: hide PDF viewer Back (app header chevron covers escape) */
body.shell-phone .pdf-view-header .back-btn {
  display: none;
}
.pdf-view-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text, #fff);
}
.pdf-view-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  margin-left: auto;
}
/* Icon-only tools ? same light square frame as filter/+ (never stadium word pills) */
.pdf-view-actions .pdf-tool-btn,
.pdf-view-actions a.pdf-tool-btn,
.pdf-view-actions .hdr-icon-btn.pdf-tool-btn {
  text-decoration: none !important;
  font-size: 0 !important;
  line-height: 0 !important;
  width: var(--btn-h) !important;
  min-width: var(--btn-h) !important;
  height: var(--btn-h) !important;
  padding: 0 !important;
  display: inline-grid !important;
  place-items: center !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none !important;
  border-radius: var(--btn-radius-seg-item, 10px) !important;
  color: #fff !important;
}
.pdf-view-actions .pdf-tool-btn svg,
.pdf-view-actions a.pdf-tool-btn svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}
.pdf-view-actions .pdf-tool-btn:hover,
.pdf-view-actions .pdf-tool-btn:active,
.pdf-view-actions a.pdf-tool-btn:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}
body.shell-phone .pdf-view-actions {
  gap: 6px;
}
.pdf-view-stage {
  min-height: 0;
  flex: 1 1 auto;
  border-radius: 12px;
  overflow: hidden;
  background: #0a0a0a;
  border: 1px solid var(--line-strong, rgba(255, 255, 255, 0.08));
}
.pdf-view-status { padding: 16px; }
.pdf-view-frame {
  width: 100%;
  height: 80vh;
  min-height: 420px;
  border: 0;
  border-radius: 0;
  background: #fff;
  display: block;
}
/* Desktop pdf.js stage ? same footprint as the old iframe viewer. */
body:not(.shell-phone) .pdf-view-page .pdf-view-stage .pdf-js-stage {
  height: 80vh;
  min-height: 420px;
  max-height: none;
}
body:not(.shell-phone) .pdf-view-page .pdf-view-stage.is-native {
  height: auto;
  max-height: calc(100vh - 168px);
  overflow-y: auto;
}
.pdf-view-hint { margin: 8px 0 0; text-align: left; }
@media (max-width: 900px) {
  .pdf-view-frame {
    height: calc(100dvh - 200px);
    min-height: 360px;
  }
}
/* Phone: edge-to-edge document ? fill remaining viewport; white page scrolls
   inside the stage (not a short frame with a void below). Safe-area aware. */
body.shell-phone.pdf-view-open,
body.shell-phone.pdf-view-open #app {
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
}
body.shell-phone.pdf-view-open .app-shell.has-bottom-nav {
  --bottom-nav-h: 0px;
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
body.shell-phone.pdf-view-open .bottom-nav {
  display: none !important;
}
/* Grid rows are content-sized by default ? switch to flex so the stage can
   claim the leftover viewport height under the header. */
body.shell-phone.pdf-view-open .app-body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  align-items: stretch;
  overflow: hidden;
  height: 100%;
}
body.shell-phone.pdf-view-open .app-content {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}
body.shell-phone .pdf-view-page.is-phone {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  gap: 6px;
  margin: 0 calc(-1 * var(--shell-pad-x));
  width: calc(100% + 2 * var(--shell-pad-x));
  min-height: 0;
  height: 100%;
  /* Keep tools clear of the home indicator; stage owns the rest. */
  padding-bottom: env(safe-area-inset-bottom, 0px);
  box-sizing: border-box;
}
body.shell-phone .pdf-view-page.is-phone .pdf-view-header {
  flex: 0 0 auto;
  padding: 0 var(--shell-pad-x);
}
body.shell-phone .pdf-view-page.is-phone .pdf-ledger-bar {
  flex: 0 0 auto;
  padding: 0 var(--shell-pad-x);
}
body.shell-phone .pdf-view-page.is-phone .pdf-view-stage {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-radius: 0;
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  background: #fff;
  /* Scroll lives on the stage / pdf.js host ? frame fills the stage. */
  overflow: hidden;
}
body.shell-phone .pdf-view-page.is-phone .pdf-view-frame {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  width: 100%;
}
/* Phone pdf.js FitW stage ? A4 Pastel pages scaled to viewport width. */
.pdf-js-stage {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
  background: #3a3a3c;
  display: flex;
  flex-direction: column;
}
.pdf-js-pages {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  padding: 0 0 12px;
  min-width: 0;
}
.pdf-js-page {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  background: #fff;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.2);
  animation: fadeUp 0.22s var(--ease);
}
/* Phone catalogue progressive FitW — full-bleed width, vertical page stack. */
.pdf-js-page-slot {
  display: block;
  width: 100%;
  min-width: 0;
  background: #2c2c2e;
}
.pdf-js-page-slot .pdf-js-page {
  width: 100% !important;
  max-width: 100%;
}
.pdf-js-stage.is-catalogue-phone,
body.shell-phone .pdf-view-page.is-catalogue .pdf-js-stage {
  width: 100%;
  max-width: 100%;
  align-items: stretch;
}
body.shell-phone .pdf-view-page.is-catalogue .pdf-js-pages-progressive {
  width: 100%;
  gap: 8px;
  padding-bottom: 20px;
}
body.shell-phone .pdf-view-page.is-catalogue .pdf-js-page {
  width: 100% !important;
  max-width: none;
}
body.shell-phone .pdf-view-page.is-phone .pdf-js-stage {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
}
/* Native ledger / statement reader ? Pastel's A4 page cannot reflow to 390px,
   so the history JSON is read as hub cards and the PDF stays behind Share /
   Download / "Open Pastel PDF". App chrome, not a document: keep the dark app
   surface and scroll the stage (the phone shell locks .app-body). */
.pdf-view-stage.is-native {
  background: transparent;
  border: 0;
  border-radius: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
}
body.shell-phone .pdf-view-page.is-phone .pdf-view-stage.is-native {
  background: transparent;
  display: block;
  flex: 1 1 auto;
  min-height: 0;
  height: auto;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 2px var(--shell-pad-x) calc(24px + env(safe-area-inset-bottom, 0px));
}
.pdf-ledger {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}
.pdf-ledger .ios-hub-val {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.pdf-ledger-cue {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: var(--fw-med);
}
.pdf-ledger-notes {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0 2px;
}
.pdf-ledger-note {
  margin: 0;
  text-align: left;
}
.pdf-ledger-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
/* Cards own their spacing here ? the shared list margin would double the gap. */
.pdf-ledger-list .inv-card-list {
  margin: 0;
}
/* Long Pastel descriptions must wrap instead of pushing the amount off screen. */
.pdf-ledger-list .inv-card {
  grid-template-columns: minmax(0, 1fr) auto;
}
.pdf-ledger-list .inv-card-meta,
.pdf-ledger-list .inv-card-top strong {
  overflow-wrap: anywhere;
}
.pdf-ledger-src {
  margin: 0;
  padding: 0 2px;
  text-align: left;
}
/* Under title: Open Pastel PDF / Back to statement|ledger (not after the list). */
.pdf-ledger-bar {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 8px;
  padding: 0 var(--shell-pad-x) 8px;
}
.pdf-ledger-bar .btn {
  min-height: var(--btn-h);
}

@media (max-width: 559px) {
  .app-shell.screen.shop-screen {
    padding: 0 var(--shell-pad-x) 16px;
  }
  .product {
    padding: 8px;
    gap: 8px;
    border-radius: 12px;
  }
  /* Narrow PC only ? phone shop uses 2-col image-on-top tiles below. */
  body:not(.shell-phone) .products.img-xl .product {
    flex-direction: row;
    align-items: flex-start;
  }
  body:not(.shell-phone) .products.img-xl .product-media {
    width: 72px;
    height: 72px;
    max-height: 72px;
    aspect-ratio: auto;
    flex-shrink: 0;
  }
  body:not(.shell-phone) .products.img-lg .product-media { width: 72px; height: 72px; }
  body:not(.shell-phone) .products.img-md .product-media { width: 64px; height: 64px; }
  body:not(.shell-phone) .product .meta h3 {
    font-size: 0.82rem;
  }
  body:not(.shell-phone) .price {
    font-size: 0.9rem;
  }
  .uom-btn {
    min-width: 0;
    padding: 0 8px;
  }
  .shop-screen .shop-sticky {
    display: none !important;
  }
}

@media (max-width: 430px) {
  .cart-btn {
    display: none;
  }
  .quote-pill {
    max-width: none;
    flex: 0 0 auto;
  }
  .shop-deliver strong {
    font-size: 0.72rem;
  }
}

/* ?? Tablets / small laptops ?? */
@media (min-width: 560px) and (max-width: 900px) {
  .screen.shop-screen {
    padding: 8px 12px 16px;
  }
  .quote-pill {
    max-width: 240px;
    font-size: 0.8rem;
  }
  .products.img-xl .product-media {
    max-height: 120px;
  }
}

/* ?? Laptops ?? */
@media (min-width: 901px) {
  body:not(.shell-phone) .screen.shop-screen{
    padding: 10px 18px 20px;
  }
  body:not(.shell-phone) .shop-chrome{
    padding: 4px 0 8px;
  }
  body:not(.shell-phone) .shop-deliver strong{
    font-size: 0.88rem;
  }
  body:not(.shell-phone) .quote-pill{
    max-width: 260px;
    min-height: 36px;
    font-size: 0.82rem;
  }
  body:not(.shell-phone) .cart-btn{
    width: 38px;
    height: 38px;
  }
  body:not(.shell-phone) .shop-screen .shop-sticky{
    display: none !important;
  }
  body:not(.shell-phone) .logo-bar-compact{
    height: 48px;
    max-width: 180px;
  }
}

@media (min-width: 1280px) {
  body:not(.shell-phone) .screen.shop-screen {
    padding: 10px 24px 20px;
  }
  body:not(.shell-phone) .shop-screen .shop-sticky {
    display: none !important;
  }
}

/* ?? Shop phone-shell pilot (toggle / ?shell=phone) ?? */
.shell-toggle {
  appearance: none;
  flex: 0 0 auto;
  margin: 0;
  padding: 5px 9px;
  min-height: 30px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid rgba(255, 214, 10, 0.45);
  background: rgba(255, 214, 10, 0.12);
  color: #ffd60a;
  font: inherit;
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
}
.shell-toggle.is-phone {
  border-color: rgba(10, 132, 255, 0.55);
  background: rgba(10, 132, 255, 0.18);
  color: #64b5ff;
}

/* Phone shop: dock clearance lives on the product scroller, not shell padding
   (shell padding-bottom sat under the in-flow nav and floated it). */
.shop-screen.shell-phone,
.app-shell.shop-screen.shell-phone {
  padding: 0 var(--shell-pad-x) 0;
  max-width: none;
}
body.shell-phone .sky-shop .products,
body.shell-phone .products.products-phone {
  /* Bottom nav is in-flow; keep last row clear without the removed shop dock. */
  padding-bottom: 24px;
}
.shop-chrome-phone {
  margin-bottom: 6px;
}
.shop-topbar-phone {
  gap: 6px;
  margin-bottom: 6px;
}
.shop-deliver-phone strong {
  font-size: 0.78rem;
}
/* Phone Products tools: search | filter (Customers `.sky-cust-tools` parity). */
.shop-phone-tools {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  margin: 8px 0 0;
  padding: 0;
  overflow: visible;
  -webkit-mask-image: none;
  mask-image: none;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools.shop-phone-tools {
  flex-direction: row;
  align-items: center;
  gap: 4px;
  width: 100%;
  margin: 8px 0 0;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .sky-page-search {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-search-field,
body.shell-phone .shop-chrome-phone .sky-cust-tools .sky-page-search input {
  width: 100%;
  min-height: var(--btn-h);
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .hdr-icon-btn {
  flex: 0 0 auto;
}
body.shell-phone .shop-phone-actions {
  display: none !important;
}
.shop-phone-pl {
  display: flex;
  justify-content: flex-start;
  min-width: 0;
}
.shop-phone-pl .shop-pl-seg {
  margin-top: 0;
  width: 100%;
  max-width: 100%;
  justify-content: stretch;
  box-sizing: border-box;
}
.shop-phone-pl .shop-pl-seg {
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 3px;
  align-items: stretch;
  box-sizing: border-box;
}
.shop-phone-pl .pl-seg-btn {
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  font-size: 0.78rem;
  /* Fill track remaining — do not claim full --btn-h (track already includes padding). */
  min-height: 0;
  height: 100%;
  max-height: none;
  box-sizing: border-box;
  border-radius: var(--btn-radius-seg-item);
}
.shop-phone-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  min-width: 0;
  align-items: stretch;
  min-height: var(--btn-h);
}
.shop-phone-actions .cat-sheet-btn {
  min-width: 0;
  max-width: none;
  width: 100%;
}
.cat-sheet-btn {
  appearance: none;
  flex: 0 0 auto;
  min-width: 0;
  max-width: 220px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 1px;
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 4px 12px;
  border-radius: var(--btn-radius-seg);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  text-align: left;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.16s var(--ease), border-color 0.16s var(--ease), transform 0.12s var(--ease);
  box-sizing: border-box;
}
.cat-sheet-btn:active {
  transform: scale(0.97);
  background: rgba(255, 255, 255, 0.08);
}
.cat-sheet-btn span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  /* Sort kicker also carries the live price list ("SORT / GENERAL") - clip, never wrap. */
  max-width: 100%;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cat-sheet-btn span svg {
  width: 11px;
  height: 11px;
  display: block;
  opacity: 0.85;
}
.cat-sheet-btn strong {
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.shop-body-phone {
  display: block;
}
.shop-body-phone .cat-heading {
  margin: 4px 2px 8px;
  font-size: 0.75rem;
}
.shop-toolbar-phone {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin: 4px 2px 8px;
}
.shop-toolbar-phone .cat-heading {
  margin: 0;
  flex: 1 1 120px;
  min-width: 0;
}
.img-size-row-phone {
  flex-shrink: 0;
  gap: 6px;
}
.img-size-row-phone .img-size-label {
  display: none;
}
/* Phone catalogue — dense GRID, image-on-top tiles (crm727/crm732 density).
   ONE UI always uses shell-phone; columns scale by viewport so iPad is not stuck at giant 2-col.
   Match both `.shop-screen.shell-phone` (same node) and `body.shell-phone .shop-screen`
   so density cannot miss when class placement differs across paints. */
.shop-screen.shell-phone .products,
.shop-screen.shell-phone .products-phone,
body.shell-phone .shop-screen .products,
body.shell-phone .shop-screen .products-phone,
body.shell-phone .products.products-phone {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 5px !important;
  flex-direction: unset !important;
}
.shop-screen.shell-phone .products-phone .product,
.shop-screen.shell-phone .products-phone .product-phone,
body.shell-phone .products.products-phone .product,
body.shell-phone .products.products-phone .product-phone {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 4px !important;
  padding: 5px !important;
  border-radius: var(--btn-chip-radius, 12px);
  min-width: 0;
  width: auto;
  box-sizing: border-box;
  contain-intrinsic-size: 0 210px;
}
.shop-screen.shell-phone .products-phone .product:hover,
body.shell-phone .products.products-phone .product:hover {
  transform: none;
}
.shop-screen.shell-phone .phone-card-top,
body.shell-phone .shop-screen .phone-card-top {
  display: contents;
}
/* Shorter stage than 1:1 — less white chrome; thumbs zoom slightly to fill the well. */
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media {
  position: relative;
  width: 100% !important;
  height: auto !important;
  max-height: 96px !important;
  min-width: 0 !important;
  aspect-ratio: 3 / 2 !important;
  border-radius: var(--btn-chip-radius);
  flex: 0 0 auto !important;
  align-self: stretch;
  overflow: hidden;
}
.shop-screen.shell-phone .products-phone.img-md .product-media,
body.shell-phone .products.products-phone.img-md .product-media {
  max-height: 72px !important;
}
.shop-screen.shell-phone .products-phone.img-lg .product-media,
body.shell-phone .products.products-phone.img-lg .product-media {
  max-height: 84px !important;
}
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media {
  max-height: 96px !important;
}
.shop-screen.shell-phone .products-phone .product-media .thumb,
.shop-screen.shell-phone .products-phone .product-media img,
body.shell-phone .products.products-phone .product-media .thumb,
body.shell-phone .products.products-phone .product-media img {
  width: 132%;
  height: 132%;
  max-width: none;
  object-fit: contain;
  object-position: center;
  border-radius: inherit;
}
.shop-screen.shell-phone .products-phone .product:hover .thumb,
body.shell-phone .products.products-phone .product:hover .thumb {
  transform: none;
}
/* Tablet / iPad (ONE UI shell-phone): prefer 3–4 columns — not giant 2-col blocks. */
@media (min-width: 700px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 6px !important;
  }
  .shop-screen.shell-phone .products-phone .product-media,
  body.shell-phone .products.products-phone .product-media {
    max-height: 92px !important;
  }
  .shop-screen.shell-phone .products-phone.img-md .product-media,
  body.shell-phone .products.products-phone.img-md .product-media {
    max-height: 70px !important;
  }
  .shop-screen.shell-phone .products-phone.img-lg .product-media,
  body.shell-phone .products.products-phone.img-lg .product-media {
    max-height: 82px !important;
  }
  .shop-screen.shell-phone .products-phone.img-xl .product-media,
  body.shell-phone .products.products-phone.img-xl .product-media {
    max-height: 92px !important;
  }
}
@media (min-width: 960px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 6px !important;
  }
  .shop-screen.shell-phone .products-phone .product-media,
  body.shell-phone .products.products-phone .product-media {
    max-height: 88px !important;
  }
  .shop-screen.shell-phone .products-phone.img-md .product-media,
  body.shell-phone .products.products-phone.img-md .product-media {
    max-height: 66px !important;
  }
  .shop-screen.shell-phone .products-phone.img-lg .product-media,
  body.shell-phone .products.products-phone.img-lg .product-media {
    max-height: 78px !important;
  }
  .shop-screen.shell-phone .products-phone.img-xl .product-media,
  body.shell-phone .products.products-phone.img-xl .product-media {
    max-height: 88px !important;
  }
}
@media (min-width: 1280px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(5, 1fr) !important;
  }
}
.shop-screen.shell-phone .products-phone .product-media .stock-pill {
  display: inline-flex !important;
  position: absolute;
  left: 4px;
  top: 4px;
  z-index: 2;
  margin: 0;
  font-size: 0.48rem;
  letter-spacing: 0.01em;
  padding: 1px 5px;
  gap: 2px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.shop-screen.shell-phone .products-phone .media-zoom-hint {
  opacity: 0.45;
  transform: none;
  width: 16px;
  height: 16px;
  right: 4px;
  bottom: 4px;
  background: rgba(0, 0, 0, 0.4);
  box-shadow: none;
}
.shop-screen.shell-phone .products-phone .product .meta {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
/* Phone: SKU/category stay off the tile ? pack info lives on the price line. */
.shop-screen.shell-phone .products-phone .product-meta-extra,
.shop-screen.shell-phone .products-phone.img-xl .product-meta-extra,
.shop-screen.shell-phone .products-phone .product.is-expanded .product-meta-extra {
  display: none !important;
}
.shop-screen.shell-phone .products-phone .meta-top,
.shop-screen.shell-phone .products-phone .meta-more-toggle {
  display: none !important;
}
.shop-screen.shell-phone .products-phone .product .meta h3,
.shop-screen.shell-phone .products-phone.img-xl .product .meta h3 {
  font-size: 0.74rem !important;
  line-height: 1.18 !important;
  -webkit-line-clamp: 2 !important;
  margin: 0 !important;
  min-height: 0 !important;
  letter-spacing: -0.02em;
}
.shop-screen.shell-phone .products-phone .product .meta .sku-line {
  display: none !important;
}
.shop-screen.shell-phone .products-phone .uom-row {
  margin: 3px 0 0;
  height: 32px;
  min-height: 32px;
  max-height: 32px;
  padding: 2px;
  gap: 1px;
  background: var(--btn-seg-track);
  border-radius: var(--btn-radius-seg);
}
.shop-screen.shell-phone .products-phone .uom-btn {
  font-size: 0.62rem;
  font-weight: var(--fw-med);
  padding: 0 4px;
  border-radius: var(--btn-radius-seg-item);
  letter-spacing: -0.02em;
}
.shop-screen.shell-phone .products-phone .uom-btn.active {
  background: var(--btn-seg-on);
}
/* Pack counts bloat the seg on narrow cols ? keep on price line only. */
.shop-screen.shell-phone .products-phone .uom-btn .uom-qty {
  display: none !important;
}
.shop-screen.shell-phone .products-phone .price {
  margin-top: 2px;
  font-size: 0.78rem !important;
  font-weight: var(--fw-strong);
  letter-spacing: -0.03em;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.shop-screen.shell-phone .products-phone .price-uom {
  font-size: 0.6rem;
  font-weight: var(--fw-med);
}
.shop-screen.shell-phone .products-phone .add-row,
.shop-screen.shell-phone .products-phone .add-row.product-actions {
  display: flex !important;
  flex-direction: row !important;
  align-items: stretch !important;
  gap: 6px !important;
  margin-top: 0 !important;
  width: 100%;
  flex-wrap: nowrap !important;
  /* One clean bar: equal-height qty + + (44px tap floor, no taller chrome) */
  --product-qty-row-h: 44px;
  height: var(--product-qty-row-h) !important;
  min-height: var(--product-qty-row-h) !important;
  max-height: var(--product-qty-row-h) !important;
  box-sizing: border-box;
}
.shop-screen.shell-phone .products-phone .qty-stepper {
  height: 100% !important;
  min-height: 0 !important;
  max-height: 100% !important;
  flex: 0 0 auto !important;
  width: fit-content;
  max-width: calc(100% - 46px);
  min-width: 0;
  align-self: stretch;
  border-radius: var(--btn-chip-radius) !important;
  border-color: var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  box-sizing: border-box;
  display: inline-flex !important;
  align-items: stretch !important;
}
.shop-screen.shell-phone .products-phone .qty-stepper .qty {
  width: 26px;
  min-width: 26px;
  font-size: 0.8rem;
  align-self: stretch;
  height: auto !important;
  min-height: 0 !important;
  line-height: 1;
  box-sizing: border-box;
}
.shop-screen.shell-phone .products-phone .qty-btn {
  width: 40px !important;
  min-width: 40px !important;
  height: auto !important;
  min-height: 0 !important;
  align-self: stretch;
  font-size: 1.05rem;
  line-height: 1;
  padding: 0 !important;
  box-sizing: border-box;
  display: inline-grid !important;
  place-items: center !important;
}
.shop-screen.shell-phone .products-phone .add-row .btn,
.shop-screen.shell-phone .products-phone .add-row .btn.add-sku {
  flex: 0 0 var(--product-qty-row-h) !important;
  width: var(--product-qty-row-h) !important;
  min-width: var(--product-qty-row-h) !important;
  max-width: var(--product-qty-row-h) !important;
  height: 100% !important;
  min-height: 0 !important;
  padding: 0 !important;
  font-size: var(--btn-fs-sm) !important;
  font-weight: var(--fw-semi) !important;
  border-radius: var(--btn-radius) !important;
  box-sizing: border-box;
  box-shadow: var(--btn-primary-shadow);
}
.shop-screen.shell-phone .products-phone .product-tip {
  display: none !important;
}
.shop-screen.shell-phone .shop-load-more-wrap {
  grid-column: 1 / -1;
}

/* Category / Sort bottom sheet ? above shop-dock (230) and bottom-nav (220) */
.cat-sheet {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: auto;
  width: 100%;
  height: 100%;
  height: 100dvh;
  z-index: 250;
  pointer-events: none;
}
.cat-sheet.is-open {
  pointer-events: auto;
}
.cat-sheet[hidden] {
  display: none !important;
}
.cat-sheet-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px) saturate(130%);
  -webkit-backdrop-filter: blur(8px) saturate(130%);
  cursor: pointer;
}
.cat-sheet-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: min(72vh, 560px);
  display: flex;
  flex-direction: column;
  /* Clear quote dock; bottom nav is in-flow under the shell, sheet covers it. */
  padding: 12px 14px calc(16px + var(--shop-dock-h, 80px) + var(--safe-bottom, 0px));
  border-radius: var(--sheet-top-radius, 18px) var(--sheet-top-radius, 18px) 0 0;
  border: 1px solid var(--line);
  border-bottom: 0;
  background: rgba(28, 28, 30, 0.98);
  box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.45);
  transform: translateY(108%);
  transition: transform var(--dur-sheet, 0.34s) var(--ease-sheet, var(--ease));
  will-change: transform;
}
.cat-sheet.is-open .cat-sheet-panel {
  transform: translateY(0);
}
/* Phone: near-fullscreen overlay ? list fills remaining height (not a short bottom card).
   Do NOT inherit panel padding that stacks shop-dock + bottom-nav (that ate ~half the sheet). */
body.shell-phone .cat-sheet-panel {
  position: fixed;
  top: env(safe-area-inset-top, 0px);
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: auto;
  max-height: none;
  max-width: none;
  margin: 0;
  display: flex;
  flex-direction: column;
  padding: 12px 14px 0;
  border-radius: var(--sheet-top-radius, 18px) var(--sheet-top-radius, 18px) 0 0;
}
body.shell-phone .cat-sheet-panel .sheet-handle,
body.shell-phone .cat-sheet-head {
  flex-shrink: 0;
}
body.shell-phone .cat-list-sheet {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  /* WAVE2-SHEET-NAV-CLEAR ? last Sort/Category pick stays tappable above nav */
  padding-bottom: var(--sheet-nav-clear);
}
body.shell-phone .cat-list-sheet .cat-pick {
  width: 100%;
  min-height: 48px;
  box-sizing: border-box;
  text-align: left;
}
/* Drag handle — real button + large hit target (tap or drag to close) */
.sheet-handle {
  position: relative;
  flex: 0 0 auto;
  display: block;
  width: 36px;
  height: 4px;
  margin: 2px auto 12px;
  padding: 0;
  border: 0;
  border-radius: var(--btn-radius);
  background: rgba(255, 255, 255, 0.28);
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
  cursor: grab;
  touch-action: none;
  z-index: 5;
  color: inherit;
  font: inherit;
}
.sheet-handle::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 96px;
  height: 44px;
  transform: translate(-50%, -50%);
}
.sheet-handle:hover {
  background: rgba(255, 255, 255, 0.4);
}
.sheet-handle:active {
  cursor: grabbing;
  background: rgba(255, 255, 255, 0.5);
}
.sheet-handle:focus-visible {
  outline: 2px solid var(--btn-focus-ring, rgba(10, 132, 255, 0.45));
  outline-offset: 6px;
}
.cat-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-size: 0.76rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
/* Sheet Done ? WAVE2-SHEET-CLOSE-44 (parity with filter-sheet actions) */
.cat-sheet-head .btn.small {
  margin: 0;
  min-height: 44px;
  min-width: 44px;
  padding: 8px 14px;
  border-radius: var(--btn-chip-radius);
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-ghost-shadow);
}
.cat-list-sheet {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 8px;
  max-height: none !important;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
  scrollbar-width: thin;
}
.cat-list-sheet::-webkit-scrollbar {
  width: 5px;
}
.cat-list-sheet::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 6px;
}
/* Grouped sheet sections (Sort by / Price list) - premium uppercase eyebrow, same
   chip language below it. */
.cat-sheet-group-lab {
  margin: 0;
  flex: 0 0 auto;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.cat-sheet-group-lab + .cat-sheet-group {
  margin-top: -2px;
}
.cat-sheet-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  flex: 0 0 auto;
}
/* Shared sheet/picker option chip ? Customers Add, Maps, Calendar Add, Sort/Category */
.shop-sheet-opt {
  appearance: none;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-chip-radius);
  padding: 12px 14px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  line-height: 1.25;
  white-space: normal;
  min-height: 48px;
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  box-shadow: var(--btn-ghost-shadow);
  text-align: left;
  cursor: pointer;
  transition:
    background 0.14s var(--ease),
    border-color 0.14s var(--ease),
    color 0.14s var(--ease),
    box-shadow 0.14s var(--ease),
    transform 0.12s var(--ease);
}
.shop-sheet-opt:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.shop-sheet-opt:active {
  transform: scale(0.98);
}
.shop-sheet-opt:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.shop-sheet-opt.active,
.shop-sheet-opt.is-on,
.shop-sheet-opt[aria-selected="true"] {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-chip-on-shadow);
}
.shop-sheet-opt.active:hover,
.shop-sheet-opt.is-on:hover,
.shop-sheet-opt[aria-selected="true"]:hover {
  color: #fff;
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
}
.shop-sheet-opt.active:focus-visible,
.shop-sheet-opt.is-on:focus-visible,
.shop-sheet-opt[aria-selected="true"]:focus-visible {
  box-shadow: var(--btn-focus-ring), var(--btn-chip-on-shadow);
}
/* Sort + Category sheet picks ? same chip language as .shop-sheet-opt */
.cat-list-sheet .cat-pick {
  appearance: none;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-chip-radius);
  padding: 12px 14px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  line-height: 1.25;
  white-space: normal;
  min-height: 48px;
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  box-shadow: var(--btn-ghost-shadow);
  text-align: left;
  cursor: pointer;
  transition:
    background 0.14s var(--ease),
    border-color 0.14s var(--ease),
    color 0.14s var(--ease),
    box-shadow 0.14s var(--ease),
    transform 0.12s var(--ease);
}
.cat-list-sheet .cat-pick:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.cat-list-sheet .cat-pick:active {
  transform: scale(0.98);
}
.cat-list-sheet .cat-pick:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.cat-list-sheet .cat-pick.active {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-chip-on-shadow);
}
.cat-list-sheet .cat-pick.active:hover {
  color: #fff;
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
}
.cat-list-sheet .cat-pick.active:focus-visible {
  box-shadow: var(--btn-focus-ring), var(--btn-chip-on-shadow);
}

/* Thumb-zone quote dock */
.shop-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.92) 28%);
  pointer-events: none;
}
body.shell-phone .shop-dock {
  /* Nav is in-flow under .app-body; fixed dock must clear nav-h + home-indicator once.
     Opaque surface (same as bottom-nav) so product cards never show through. */
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  z-index: 210;
  padding: 8px 12px;
  background: var(--bottom-nav-bg);
  border-top: 1px solid var(--line-strong);
  box-shadow: none;
}
.shop-dock-quote {
  pointer-events: auto;
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  min-height: var(--btn-h);
  padding: 10px 18px;
  border-radius: var(--btn-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font: inherit;
  font-size: var(--btn-fs);
  font-weight: var(--fw-semi);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow), 0 8px 22px rgba(0, 0, 0, 0.35);
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), transform 0.12s var(--ease), box-shadow 0.18s var(--ease);
}
.shop-dock-quote:disabled {
  opacity: 0.55;
  cursor: default;
}
.shop-dock-quote:not(:disabled):active {
  transform: scale(0.98);
  box-shadow: var(--btn-ghost-shadow), 0 4px 14px rgba(0, 0, 0, 0.35);
}
.shop-dock-quote.has-items {
  border-color: var(--btn-primary-border);
  background: var(--btn-primary-bg);
  color: #fff;
  box-shadow: var(--btn-primary-shadow-elevated);
}
.shop-dock-quote .shop-cart-total {
  font-variant-numeric: tabular-nums;
}

/* ===== Skynamo layout parity (dark + ieGlobal blue) ===== */
.sky-canvas {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px 14px;
  min-width: 0;
}
.sky-page-main.sky-canvas {
  box-shadow: none;
  backdrop-filter: none;
}
.sky-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  width: 100%;
  padding: 0 2px;
}
.sky-pill {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  border-radius: var(--btn-radius);
  padding: 8px 14px;
  min-height: 34px;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.sky-pill:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, 0.16);
}
.sky-pill.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
.sky-fabs {
  display: flex;
  gap: 8px;
  margin-left: auto;
}
.sky-fab {
  /* Match toolbar peers (Filters / seg) ? squircle, not a lonely circle. */
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  box-sizing: border-box;
  border-radius: var(--btn-radius-seg-item);
  border: 1px solid var(--btn-primary-border);
  background: var(--btn-primary-bg);
  color: #fff;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--btn-primary-shadow);
  transition: background 0.16s var(--ease), transform 0.12s var(--ease), box-shadow 0.16s var(--ease);
  padding: 0;
  flex: 0 0 auto;
}
.sky-fab svg {
  width: 20px;
  height: 20px;
  display: block;
}
.sky-fab:hover {
  background: var(--btn-primary-bg-hover);
  box-shadow: var(--btn-primary-shadow-hover);
}
.sky-fab:active {
  transform: scale(0.92);
  box-shadow: 0 4px 12px rgba(10, 132, 255, 0.3);
}
.sky-fab:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-primary-shadow);
}
.hdr-icon-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  width: 36px;
  height: 36px;
  border-radius: var(--btn-icon-radius);
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  transition: color 0.14s var(--ease), background 0.14s var(--ease);
}
/* Instant icon action labels (desk hover) — native title is too slow */
.crm-ico-tip {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  max-width: min(240px, calc(100vw - 16px));
  padding: 6px 10px;
  border-radius: var(--btn-radius-seg-item, 8px);
  border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.12));
  background: color-mix(in srgb, var(--bg-elevated-2, #2c2c2e) 94%, #000);
  color: var(--ink, #f5f5f7);
  font-size: 0.75rem;
  font-weight: var(--fw-semi, 600);
  line-height: 1.25;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.crm-ico-tip[hidden] {
  display: none !important;
}
.hdr-icon-btn:hover { color: #fff; background: rgba(255,255,255,0.08); }
.hdr-icon-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.hdr-icon-btn.is-active {
  color: var(--accent);
  background: rgba(10, 132, 255, 0.16);
}
.hdr-clockout-btn { color: var(--accent); }
.hdr-clockout-btn:hover { color: var(--accent-press); background: rgba(10, 132, 255, 0.12); }

/* Phone More overflow — kit cat-sheet via .more-nav-sheet (crm825 Wave A1) */

.hdr-user-menu {
  position: relative;
}
.hdr-user-opener {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  border: 0;
  background: transparent;
  font: inherit;
}
.hdr-user-chevron {
  display: inline-flex;
  align-items: center;
  margin-left: 3px;
  opacity: 0.55;
  transition: opacity 0.15s var(--ease), transform 0.15s var(--ease);
}
.hdr-user-chevron svg { width: 10px; height: 10px; display: block; }
.hdr-user-menu:hover .hdr-user-chevron { opacity: 0.85; }
.hdr-user-menu.is-open .hdr-user-chevron { transform: rotate(180deg); opacity: 0.85; }
.hdr-user-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  width: 200px;
  padding: 6px;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--btn-ghost-shadow);
  z-index: 80;
}
.hdr-user-panel[hidden] {
  display: none;
}
.hdr-user-panel .admin-opt-row {
  min-height: 44px;
  padding: 8px 10px;
}
.home-blocks-secondary {
  margin-top: 16px;
  opacity: 0.92;
}
.sky-dashboard .home-sky-head {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.sky-dashboard .home-sky-head .sub { text-align: left; margin: 0; }
.home-start-cta {
  position: static;
  z-index: 30;
}
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-dashboard .home-start-cta{
    position: static;
    max-width: 280px;
    margin: 8px 0 0;
  }
}
/* Force flat Skynamo table rows on PC desk only (override .result cards).
   NEVER fire under body.shell-phone ? ONE UI wide laptops stay card stack. */
body:not(.shell-phone) .results.sky-list .result.pick-cust,
body:not(.shell-phone) .sky-list .result.pick-cust {
  display: grid !important;
  grid-template-columns: 120px minmax(0, 1fr) 140px !important;
  gap: 12px !important;
  border: 0 !important;
  border-bottom: 1px solid var(--line) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 12px 22px 12px 10px !important;
}
body:not(.shell-phone) .results.sky-list .result.pick-cust strong {
  display: inline !important;
}
/* Phone shell (any width): Name | Next visit same row */
body.shell-phone .results.sky-list .result.pick-cust,
body.shell-phone .sky-list .result.pick-cust {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  grid-template-areas: "name visit" !important;
  gap: 6px 10px !important;
  padding: 14px 26px 14px 10px !important;
  min-height: 52px;
  align-items: center;
}
body.shell-phone .results.sky-list .result.pick-cust strong,
body.shell-phone .sky-list .result.pick-cust strong,
body.shell-phone .results.sky-list .result.pick-cust .sky-cust-meta,
body.shell-phone .sky-list .result.pick-cust .sky-cust-meta {
  display: none !important;
}
body.shell-phone .results.sky-list .result.pick-cust .sky-cust-name,
body.shell-phone .sky-list .result.pick-cust .sky-cust-name {
  grid-area: name;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.shell-phone .results.sky-list .result.pick-cust .sky-cust-visit,
body.shell-phone .sky-list .result.pick-cust .sky-cust-visit {
  grid-area: visit;
  grid-column: auto !important;
}
/* Narrow desk escape (?desk=1 on small screens): same lean row */
@media (max-width: 900px) {
  body:not(.shell-phone) .results.sky-list .result.pick-cust,
  body:not(.shell-phone) .sky-list .result.pick-cust {
    grid-template-columns: minmax(0, 1fr) auto !important;
    grid-template-areas: "name visit" !important;
    gap: 6px 10px !important;
    padding: 14px 26px 14px 10px !important;
    min-height: 52px;
    align-items: center;
  }
  body:not(.shell-phone) .results.sky-list .result.pick-cust strong,
  body:not(.shell-phone) .sky-list .result.pick-cust strong,
  body:not(.shell-phone) .results.sky-list .result.pick-cust .sky-cust-meta,
  body:not(.shell-phone) .sky-list .result.pick-cust .sky-cust-meta {
    display: none !important;
  }
  body:not(.shell-phone) .results.sky-list .result.pick-cust .sky-cust-name,
  body:not(.shell-phone) .sky-list .result.pick-cust .sky-cust-name {
    grid-area: name;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  body:not(.shell-phone) .results.sky-list .result.pick-cust .sky-cust-visit,
  body:not(.shell-phone) .sky-list .result.pick-cust .sky-cust-visit {
    grid-area: visit;
    grid-column: auto !important;
  }
}
.crm-acct-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 4px 0 12px;
}
.crm-acct-actions .btn,
.crm-acct-actions .hub-act-btn {
  width: 100%;
  min-height: 48px;
  margin: 0;
}
.hub-act-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.hub-act-btn .hub-act-ico {
  flex: 0 0 auto;
  opacity: var(--crm-ico-idle-opacity);
  display: inline-flex;
}
.hub-act-ico svg {
  width: 16px;
  height: 16px;
  display: block;
}
.hub-act-btn span {
  min-width: 0;
}
.sky-cust-pc-tools .hub-act-btn {
  min-height: 40px;
  padding-left: 12px;
  padding-right: 14px;
}
/* Customer hub action buttons ? consistent "premium pill" family: one primary
   CTA (Quote) + matching secondary outline pills (History / Forms / Info),
   same height/border/padding on both PC (.sky-cust-pc-tools) and phone
   (.crm-acct-actions). */
.sky-cust-pc-tools .hub-act-btn,
.crm-acct-actions .hub-act-btn {
  width: auto;
  margin-top: 0;
  min-height: 40px;
}
.sky-cust-pc-tools .hub-act-btn.btn.ghost,
.sky-cust-pc-tools .hub-act-btn.btn.warm,
.crm-acct-actions .hub-act-btn.btn.ghost,
.crm-acct-actions .hub-act-btn.btn.warm {
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font-weight: var(--fw-med);
  box-shadow: var(--btn-ghost-shadow);
}
.sky-cust-pc-tools .hub-act-btn.btn.ghost:hover,
.sky-cust-pc-tools .hub-act-btn.btn.warm:hover,
.crm-acct-actions .hub-act-btn.btn.ghost:hover,
.crm-acct-actions .hub-act-btn.btn.warm:hover {
  opacity: 1;
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
  border-color: rgba(255, 255, 255, 0.16);
  filter: none;
}
.crm-acct-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 14px 16px;
  margin-bottom: 0;
  overflow: hidden;
  isolation: isolate;
}
.crm-acct-card .sky-dash-timeline,
.crm-acct-card .sky-tl-groups {
  margin: 0;
  min-width: 0;
}
.crm-acct-card .sky-tl-group-head {
  margin-left: -4px;
  margin-right: -4px;
  padding-left: 8px;
  padding-right: 8px;
  border-radius: 8px;
}
.crm-acct-card .sky-tl-row {
  padding-left: 2px;
  padding-right: 2px;
}
.crm-acct-card .crm-ops-form {
  margin-bottom: 4px;
}
.crm-acct-card .crm-ops-form + .sub,
.crm-acct-card .crm-ops-form + .crm-ops-item {
  margin-top: 4px;
}
/* Phone Details tab ? LABEL (all-caps muted) above VALUE, tighter field hierarchy. */
.hub-kv-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
}
.hub-kv-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.hub-kv-label {
  font-size: 11px;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.hub-kv-value {
  font-size: 0.92rem;
  color: var(--ink);
  line-height: 1.35;
}
.crm-acct-card .hub-panel-head {
  margin-bottom: 8px;
}
.crm-acct-cal {
  width: 100%;
  margin: 8px 0;
}
.crm-ops-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.crm-ops-form label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.82rem;
  color: var(--muted);
  min-width: 0;
  align-self: start;
}
.crm-ops-form input,
.crm-ops-form textarea {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 8px 12px;
  min-height: var(--btn-h-sm);
  height: auto;
  max-height: 48px;
  line-height: 1.25;
  background: rgba(0, 0, 0, 0.28);
  color: var(--ink);
  font: inherit;
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  color-scheme: dark;
  appearance: none;
  -webkit-appearance: none;
}
.crm-ops-form textarea {
  max-height: none;
  min-height: 72px;
  appearance: auto;
  -webkit-appearance: auto;
}
/* Native date/number on Win Chromium: cap height + ink color ? invalid --text
 * blanked values into full-bleed black voids. */
.crm-ops-form input[type="date"],
.crm-ops-form input[type="number"] {
  display: block;
  min-height: var(--btn-h-sm);
  max-height: 40px;
  height: 40px;
  padding: 0 10px;
}
.crm-ops-form input[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0.7;
  cursor: pointer;
  filter: invert(0.85);
}
.crm-ops-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
  align-items: start;
}
.crm-ops-form-grid > button,
.crm-ops-form-grid .crm-callplan-actions {
  grid-column: 1 / -1;
}
.crm-callplan-blurb {
  text-align: left;
  margin: 0 0 8px;
  font-size: 0.8rem;
  line-height: 1.35;
}
.crm-callplan-potential {
  grid-column: 1 / -1;
  margin: 0 0 6px;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--danger, #ff453a);
}
.crm-callplan-foot {
  margin-top: 8px;
  text-align: left;
  font-size: 0.75rem;
}
.crm-callplan-field {
  margin: 0;
}
.crm-callplan-lab {
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.2;
}
.crm-callplan-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}
.crm-callplan-actions .btn {
  flex: 1 1 140px;
  min-height: var(--btn-h-sm);
  width: auto;
}
@media (max-width: 900px) {
  .crm-ops-form-grid {
    grid-template-columns: 1fr 1fr;
  }
  .sky-page-head {
    flex-wrap: wrap;
    gap: 10px;
  }
  .sky-page-search {
    flex: 1 1 100%;
    max-width: none;
    margin-inline: 0;
  }
  .btn.sky-hub-add {
    width: 100%;
  }
  .sky-forms-grid {
    grid-template-columns: 1fr;
  }
}
.sky-hub-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
}
/* Tasks hub ? compact-Add next to search (not full-width banner). Without this, a PC window
   narrower than the 900px breakpoint (is-pc still applies ? is-pc/is-phone is a
   touch-input check, not a viewport-width one) falls into the `.btn.sky-hub-add
   { width:100% }` phone rule further down and renders a giant full-width blue
   "+ Add" banner over the dense table ? exactly the "admin dashboard" look this
   redesign removes. Quiet outline pill next to search, same as Timeline. */
.sky-hub-page.is-pc.sky-hub-tasks .sky-hub-add {
  width: auto;
  flex-basis: auto;
  margin-top: 0;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line-strong);
  padding: 9px 16px;
  font-size: 0.88rem;
}
.sky-hub-page.is-pc.sky-hub-tasks .sky-hub-add:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--accent);
  color: var(--accent);
}
/* PC: dense Tasks table ? Due | Description | Account | For | Actions.
   Description flexes; other cols are px (resizable via .crm-col-resize). */
.sky-tasks-table {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.sky-tasks-table.crm-col-table {
  --crm-col-due: 176px;
  --crm-col-desc-min: 240px;
  --crm-col-acct: 168px;
  --crm-col-who: 140px;
  --crm-col-actions: 78px;
}
.sky-tasks-hub-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin: 0 0 10px;
}
.sky-tasks-hub-chips .sky-tl-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.sky-task-src-badge {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  font-size: 0.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0 7px;
  min-height: 20px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--muted);
  line-height: 1;
}
.sky-task-src-badge.is-skynamo {
  color: var(--ink-secondary);
}
.sky-task-src-badge.is-crm {
  color: var(--accent, #0a84ff);
  border-color: color-mix(in srgb, var(--accent, #0a84ff) 28%, var(--line-strong));
  background: color-mix(in srgb, var(--accent, #0a84ff) 10%, var(--btn-ghost-bg));
}
.sky-task-for-lab {
  color: var(--muted);
  font-weight: var(--fw-med);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-right: 2px;
}
.sky-tasks-col-desc .sky-task-src-badge {
  margin-right: 2px;
}
.sky-hub-task-main-txt strong {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.sky-tasks-row {
  display: grid;
  grid-template-columns:
    var(--crm-col-due)
    minmax(var(--crm-col-desc-min), 1fr)
    var(--crm-col-acct)
    var(--crm-col-who)
    var(--crm-col-actions);
  align-items: center;
  gap: 8px 12px;
  /* Extra left pad so inset overdue/today bar + Due badge aren't clipped. */
  padding: 9px 10px 9px 14px;
  border-radius: 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.12s var(--ease), box-shadow 0.12s var(--ease);
  min-height: 44px;
  box-sizing: border-box;
  overflow: visible;
}
.sky-tasks-col-due {
  min-width: 0;
  overflow: visible;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-left: 2px;
}
.sky-tasks-body .sky-tasks-row:last-child {
  border-bottom: 0;
}
/* Hairline hover ? refined row cue, not a flat button wash. */
.sky-tasks-body .sky-tasks-row:not(.is-overdue):not(.is-today):hover {
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 var(--line-strong), inset 0 -1px 0 var(--line-strong);
}
.sky-tasks-head {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 8px 10px 9px;
  margin: 0 0 1px;
  font-size: 0.7rem;
  font-weight: var(--fw-semi);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  border-bottom: 1px solid var(--line-strong);
  background: color-mix(in srgb, var(--bg-elevated) 92%, #000);
  min-height: 0;
}
.sky-tasks-row.is-overdue {
  background: rgba(255, 69, 58, 0.07);
  box-shadow: inset 3px 0 0 var(--sky-late);
}
.sky-tasks-row.is-today {
  background: rgba(255, 159, 10, 0.07);
  box-shadow: inset 3px 0 0 var(--sky-soon);
}
.sky-tasks-col-desc {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: var(--fw-med);
  text-align: left;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sky-tasks-col-desc:disabled {
  cursor: default;
  color: var(--ink);
}
.sky-tasks-col-desc:not(:disabled):hover {
  text-decoration: underline;
}
/* Leading task icon as a quiet chip ? tints with overdue/today row cues. */
.sky-tasks-col-desc .sky-hub-task-ico {
  width: 22px;
  height: 22px;
  border-radius: var(--btn-icon-radius);
  background: var(--btn-ghost-bg);
  border: 1px solid transparent;
  color: var(--muted);
  opacity: 1;
  flex: 0 0 auto;
}
.sky-tasks-row.is-overdue .sky-tasks-col-desc .sky-hub-task-ico {
  background: rgba(255, 69, 58, 0.14);
  color: var(--danger);
}
.sky-tasks-row.is-today .sky-tasks-col-desc .sky-hub-task-ico {
  background: rgba(255, 159, 10, 0.16);
  color: #ff9f0a;
}
.sky-tasks-col-desc .sky-task-desc {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.sky-tasks-col-acct,
.sky-tasks-col-who {
  font-size: 0.85rem;
  color: var(--ink-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.sky-tasks-col-who {
  color: var(--muted);
}
.sky-tasks-col-actions {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
}
/* Done ? premium ghost .btn tokens (not a cheap text link). */
.btn.ghost.sky-task-done-btn,
.btn.ghost.small.sky-task-done-btn {
  color: var(--ink-secondary);
  min-height: var(--btn-h-sm);
  height: var(--btn-h-sm);
  padding: 0 12px;
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-med);
  border-radius: var(--btn-radius);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  line-height: 1;
}
.btn.ghost.sky-task-done-btn:hover,
.btn.ghost.small.sky-task-done-btn:hover {
  color: var(--ink);
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.sky-task-due-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-semi);
  padding: 0 10px;
  min-height: 26px;
  border-radius: var(--btn-chip-radius);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
  /* Keep first glyphs (Today / date) visible ? clip only from the right. */
  direction: ltr;
  text-align: left;
  justify-content: flex-start;
}
.sky-task-due-badge.is-overdue {
  background: rgba(255, 69, 58, 0.16);
  border-color: color-mix(in srgb, var(--danger) 35%, var(--line-strong));
  color: var(--danger);
  box-shadow: none;
}
.sky-task-due-badge.is-today {
  background: rgba(255, 159, 10, 0.18);
  border-color: color-mix(in srgb, #ff9f0a 40%, var(--line-strong));
  color: #ff9f0a;
  box-shadow: none;
}
.sky-task-due-badge.is-anytime {
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--muted);
}
.sky-task-unlinked-chip {
  display: inline-flex;
  align-items: center;
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-med);
  color: var(--muted);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  border-radius: var(--btn-chip-radius);
  padding: 0 10px;
  min-height: 26px;
  box-sizing: border-box;
}

/* Shared PC column-resize handles (Tasks / Contacts hub tables). Hidden on phone. */
.crm-col-th {
  position: relative;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crm-col-resize {
  display: none;
}
body:not(.shell-phone) .crm-col-table .crm-col-resize {
  display: block;
  position: absolute;
  top: -4px;
  bottom: -4px;
  right: -7px;
  width: 14px;
  cursor: col-resize;
  z-index: 3;
  touch-action: none;
  user-select: none;
}
body:not(.shell-phone) .crm-col-table .crm-col-resize::after {
  content: "";
  position: absolute;
  top: 20%;
  bottom: 20%;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  border-radius: 2px;
  background: transparent;
  transition: background 0.12s var(--ease);
}
body:not(.shell-phone) .crm-col-table .crm-col-resize:hover::after,
body:not(.shell-phone) .crm-col-table.is-col-resizing .crm-col-resize::after {
  background: color-mix(in srgb, var(--accent) 55%, transparent);
}
body.crm-col-resizing,
body.crm-col-resizing * {
  cursor: col-resize !important;
  user-select: none !important;
}
.sky-forms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  padding: 4px 0 12px;
}
.sky-form-card {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 76px;
}
.sky-form-card:hover,
.sky-form-card.is-on {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line-strong));
  background: var(--bg-elevated-2);
  box-shadow: var(--btn-ghost-shadow);
}
.sky-hub-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  margin-bottom: 10px;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 12%, var(--bg-elevated));
  border: 1px solid color-mix(in srgb, var(--accent) 32%, var(--line-strong));
}
.sky-hub-banner p {
  margin: 0;
}
.sky-hub-foot {
  margin: 8px 2px 0;
  text-align: left;
}
.sky-forms-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin: 0 0 10px;
}
.sky-forms-toolbar-note {
  flex: 1 0 100%;
  margin: 0;
  text-align: left;
}
.sky-forms-new-sheet {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-height: 0;
  overflow: hidden;
}
.sky-forms-new-menu .sky-forms-new-seg {
  margin: 0 0 10px;
  flex: 0 0 auto;
}
.sky-forms-new-picks {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0 0 8px;
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: var(--sheet-nav-clear, 4px);
}
.sky-forms-new-sheet .sky-hub-foot {
  flex: 0 0 auto;
  margin-top: 4px;
}
/* Phone Forms New: one scroll owner = .crm-menu-body (not picks). crm892 */
body.shell-phone .forms-new-menu-sheet {
  z-index: 280;
}
body.shell-phone .forms-new-menu-sheet > .cat-sheet-panel.sky-forms-new-sheet,
body.shell-phone .sky-forms-new-sheet {
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
  overflow: hidden;
}
body.shell-phone .sky-forms-new-menu .sky-forms-new-picks,
body.shell-phone .sky-forms-new-sheet .sky-forms-new-picks {
  margin-bottom: 0;
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  -webkit-overflow-scrolling: auto;
  padding-bottom: 0;
}
body.shell-phone .sky-forms-new-menu .sky-hub-foot,
body.shell-phone .sky-forms-new-sheet .sky-hub-foot {
  padding: 8px 2px 0;
  margin: 0;
  flex: 0 0 auto;
}
.sky-forms-table {
  margin-top: 2px;
}
.sky-forms-table th:first-child,
.sky-forms-table td:first-child {
  width: 26px;
  padding-right: 0;
}
.sky-forms-row-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 18px;
  height: 18px;
  color: var(--muted);
  opacity: 0.85;
}
.sky-forms-row-ico svg {
  width: 14px;
  height: 14px;
}
.form-status-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  padding: 2px 8px;
  border-radius: var(--btn-chip-radius);
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink-secondary);
  white-space: nowrap;
}
.form-status-badge.is-posted {
  background: rgba(48, 209, 88, 0.14);
  color: #30d158;
}
.form-status-badge.is-pending {
  background: rgba(255, 159, 10, 0.14);
  color: #ff9f0a;
}
.form-status-badge.is-failed {
  background: rgba(255, 69, 58, 0.16);
  color: #ff453a;
}
.form-status-badge.is-other {
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
}
.sky-forms-rows {
  padding-bottom: 4px;
}
.sky-forms-row-wrap {
  border-bottom: 1px solid var(--line);
}
.sky-forms-row-wrap:last-child {
  border-bottom: 0;
}
.sky-forms-row {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 10px 0;
  border: 0;
  background: none;
  text-align: left;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.sky-forms-row-wrap .sky-forms-row {
  padding-bottom: 6px;
}
.sky-forms-row:disabled {
  cursor: default;
  opacity: 0.7;
}
.sky-forms-row-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.sky-forms-row-meta {
  font-size: 0.78rem;
  color: var(--muted);
}
.sky-forms-row-foot {
  padding: 0 0 10px;
}
.sky-forms-monday-link {
  font-size: 0.76rem;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  opacity: 0.78;
  color: var(--muted);
}
.sky-forms-monday-link:hover {
  opacity: 1;
  color: var(--accent);
}
.sky-forms-monday-link svg {
  width: 11px;
  height: 11px;
  display: block;
  opacity: 0.85;
}
td .sky-forms-monday-link {
  font-size: 0.8rem;
}
.sky-forms-empty-actions {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
body.shell-phone .sky-forms-toolbar {
  gap: 6px;
  margin-bottom: 8px;
}
body.shell-phone .sky-forms-toolbar .btn {
  min-height: var(--btn-h-sm, 34px);
}
body.shell-phone .sky-hub-forms .sky-hub-body {
  /* crm858: Clear New-form dock only (nav is in-flow under .app-body); was hard 72. */
  padding-bottom: calc(var(--bottom-nav-h, 56px) + 12px);
}
.sky-forms-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.92) 28%);
  pointer-events: none;
}
body.shell-phone .sky-forms-dock {
  /* Sit above nav with gap; z below bottom-nav (220) so nav stays tappable */
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  z-index: 210;
  padding-bottom: 10px;
}
.sky-forms-dock .btn.primary {
  pointer-events: auto;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: var(--btn-primary-shadow-hover);
}
.sky-forms-dock .btn.primary svg {
  width: 14px;
  height: 14px;
  display: block;
}
.near-me-row {
  position: relative;
  padding-right: 72px;
}
/* Near me: code | name | address + km ? no visit cell, no list chevron */
.near-me-row::after {
  content: none !important;
  display: none !important;
}
.near-me-km {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  color: var(--accent);
  white-space: nowrap;
}
.near-me-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
}
.near-me-rail-main {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}
.near-me-rail-main > .near-me-body {
  height: 100%;
  min-height: 0;
}
.near-me-map-col {
  order: -1;
  min-width: 0;
}
.near-me-map-wrap {
  position: relative;
  height: 300px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--map-pin-soft) 28%, var(--line-strong));
  background: #e8eef4;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 0 1px var(--map-frame-glow),
    0 10px 28px rgba(0, 0, 0, 0.22);
}
/* ONE UI: taller maps for Customers Map + Near me (any viewport width) */
body.shell-phone .sky-customers-map .near-me-map-wrap,
body.shell-phone .sky-page.sky-near-me .near-me-map-wrap,
body.shell-phone .sky-customers-near .near-me-map-wrap {
  height: min(55dvh, 520px);
  min-height: 280px;
}
/* Phone hub Location / Info maps ? compact so Details isn't eaten by the map */
body.shell-phone .cust-map-block .near-me-map-wrap,
body.shell-phone .customer-info-page .cust-map-block .near-me-map-wrap {
  height: clamp(180px, 28dvh, 220px);
  min-height: 180px;
  max-height: 220px;
}
/* No inset vignette ? washed street labels soft on MapLibre canvas. Frame glow stays on wrap. */
.near-me-map-wrap::after {
  content: none;
  display: none;
}
.near-me-map,
.outlets-map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #e8eef4;
  /* Keep MapLibre canvas on a crisp layer ? ancestor transforms/filters soft-scale GL. */
  transform: none;
  filter: none;
  -webkit-filter: none;
  will-change: auto;
}
.crm-map-vendor-missing {
  display: grid;
  place-items: center;
  padding: 16px;
  box-sizing: border-box;
}
.crm-map-vendor-msg {
  margin: 0;
  text-align: center;
  max-width: 28rem;
  color: var(--ink-secondary, #ebebf5);
}
.crm-map-error {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 10px;
  z-index: 450;
  margin: 0;
  padding: 10px 12px;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  background: var(--btn-ghost-bg, rgba(18, 18, 20, 0.92));
  box-shadow: var(--btn-ghost-shadow, 0 4px 12px rgba(0, 0, 0, 0.35));
  color: var(--ink, #f5f5f7);
  font-size: 0.82rem;
  line-height: 1.35;
  text-align: center;
}
.crm-map-error[hidden] {
  display: none !important;
}
.near-me-locate-btn {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 400; /* above MapLibre / Leaflet controls */
  /* iOS ?44 touch ? never shrink below 44 even if desk --btn-h is 42 */
  width: max(44px, var(--btn-h));
  height: max(44px, var(--btn-h));
  min-width: 44px;
  min-height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  border-radius: 50%;
  background: var(--btn-ghost-bg, var(--bg-elevated-2));
  color: var(--accent);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow, 0 4px 12px rgba(0, 0, 0, 0.35));
  padding: 0;
  box-sizing: border-box;
}
.near-me-locate-btn svg {
  width: 18px;
  height: 18px;
  display: block;
}
.near-me-locate-btn:hover,
.near-me-locate-btn:focus-visible {
  background: var(--bg-elevated);
  border-color: var(--accent);
}
.near-me-locate-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow, 0 4px 12px rgba(0, 0, 0, 0.35));
}
.near-me-locate-btn:active {
  transform: scale(0.95);
}
.near-me-locate-btn:disabled {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, var(--muted));
  cursor: not-allowed;
  transform: none;
}
.near-me-msg.is-err {
  color: var(--danger, #ff453a);
}
.near-me-empty {
  margin: 8px 4px;
}
.near-me-list-col {
  min-width: 0;
}
.near-me-popup,
.crm-ml-popup-card {
  font-size: 0.85rem;
  line-height: 1.4;
  min-width: 168px;
}
.crm-ml-popup-kicker {
  margin: 0 0 4px;
  font-size: 0.68rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--map-pin-soft, #ff6961);
}
.crm-ml-popup-title {
  display: block;
  font-size: 0.98rem;
  letter-spacing: -0.02em;
  color: var(--ink, #f5f5f7);
  font-weight: var(--fw-strong, 600);
}
.crm-ml-popup-code {
  margin-top: 2px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  color: var(--ink-secondary, #ebebf5);
  opacity: 0.85;
}
.near-me-popup-sub {
  color: var(--muted);
  font-size: 0.78rem;
  margin-top: 6px;
}
.near-me-popup-km {
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  margin-top: 4px;
  color: var(--accent-press, #409cff);
}
.near-me-popup-btn {
  width: 100%;
  margin-top: 0;
  padding: 8px 12px;
  font-size: var(--btn-fs, 0.9rem);
  min-height: var(--btn-h);
  height: var(--btn-h);
  box-sizing: border-box;
}
/* Call | Navigate on row 1; View customer full-width primary on row 2 */
.near-me-popup .crm-map-popup-actions {
  grid-template-columns: 1fr 1fr;
}
.near-me-popup .crm-map-popup-actions:not(:has(a.btn)) {
  grid-template-columns: 1fr;
}
.near-me-popup .crm-map-popup-actions .near-me-popup-btn {
  grid-column: 1 / -1;
}

/* Customers ? Map (outlets Smart scan) */
.cust-view-toggle {
  flex-shrink: 0;
}
/* ONE UI: Customers phone head ? Filters + List|Map|Near + + share --btn-h
   and seg-item squircle so edges line up (no lonely circle FAB). */
body.shell-phone .sky-customers .sky-page-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  row-gap: 5px;
  min-height: var(--btn-h);
}
body.shell-phone .sky-customers .sky-page-head-actions .hdr-icon-btn.acal-filter-icon-btn,
body.shell-phone .sky-customers .sky-page-head-actions .acal-phone-filters-btn {
  flex: 0 0 auto;
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  width: var(--btn-h);
  height: var(--btn-h);
  border-radius: var(--btn-radius-seg-item);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink-secondary);
}
body.shell-phone .sky-customers .sky-page-head-actions .sky-fabs {
  display: none;
}
body.shell-phone .sky-customers .sky-page-head-actions .sky-fab,
body.shell-phone .sky-customers .sky-page-head-actions #btnNewCustomer {
  display: none;
}
/* Customers phone: search | filter | + one row (hub-style +).
   crm859: denser sticky head — pad/gap only; keep List|Map|Near. */
body.shell-phone .sky-customers .sky-page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px 4px;
  padding: 0 0 4px;
}
body.shell-phone .sky-customers .sky-page-head > h1 {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}
body.shell-phone .sky-customers .sky-cust-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  flex: 1 0 100%;
  min-width: 0;
}
body.shell-phone .sky-customers .sky-cust-tools .sky-page-search {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}
body.shell-phone .sky-customers .sky-cust-tools .sky-page-search input {
  width: 100%;
  min-height: var(--btn-h);
}
body.shell-phone .sky-customers .sky-cust-tools .hdr-icon-btn {
  flex: 0 0 auto;
}
/* Hub phone tools = Customers tools parity (search | filter | +). */
body.shell-phone .sky-hub-page .sky-hub-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  flex: 1 0 100%;
  min-width: 0;
}
body.shell-phone .sky-hub-page .sky-hub-tools .sky-page-search {
  flex: 1 1 auto !important;
  min-width: 0;
  max-width: none;
  margin: 0;
}
body.shell-phone .sky-hub-page .sky-hub-tools .sky-page-search input {
  width: 100%;
  min-height: var(--btn-h);
}
body.shell-phone .sky-hub-page .sky-hub-tools .hdr-icon-btn,
body.shell-phone .sky-hub-page .sky-hub-tools .crm-plus-ico,
body.shell-phone .sky-hub-page .sky-hub-tools .sky-hub-add-wrap {
  flex: 0 0 auto;
}
body.shell-phone .sky-customers .sky-page-head-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  flex: 1 0 100%;
  justify-content: flex-start;
}
/* Framed + - same light square as filter icon (not blue FAB / naked). */
.crm-plus-ico,
.hdr-icon-btn.crm-plus-ico,
button.crm-plus-ico {
  font-size: 1.45rem !important;
  font-weight: 300 !important;
  line-height: 1 !important;
  color: #fff !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none !important;
  border-radius: var(--btn-radius-seg-item, 10px) !important;
  min-width: var(--btn-h);
  width: var(--btn-h);
  height: var(--btn-h);
  padding: 0 !important;
  display: inline-grid !important;
  place-items: center !important;
}
.crm-plus-ico:hover,
.crm-plus-ico:active {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}
body.shell-phone .sky-cust-head-m #btnCustPlusMenu,
body.shell-phone .crm-entity-head-icons #btnCustPlusMenu,
body.shell-phone .crm-entity-head-add #btnCustPlusMenu,
.hdr-icon-btn.acal-add-icon-btn.crm-plus-ico,
button.acal-add-icon-btn.crm-plus-ico {
  font-size: 1.45rem !important;
  font-weight: 300 !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none !important;
  color: #fff !important;
  border-radius: var(--btn-radius-seg-item, 10px) !important;
}
.cust-map-near-seg {
  width: 100%;
}
body.shell-phone .cust-view-toggle.img-size-toggle {
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  padding: 2px;
  gap: 1px;
  align-items: stretch;
  min-height: var(--btn-h);
  box-sizing: border-box;
  flex: 0 0 auto;
}
body.shell-phone .cust-view-toggle .img-size-btn {
  border-radius: var(--btn-radius-seg-item);
  min-height: calc(var(--btn-h) - 4px);
  height: calc(var(--btn-h) - 4px);
  padding: 0 10px;
  font-size: var(--btn-fs-sm, 0.82rem);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}
body.shell-phone .cust-view-toggle .img-size-btn.active {
  background: var(--btn-seg-on);
  border-color: transparent;
  box-shadow: var(--btn-seg-on-shadow);
  color: #fff;
}
/* Map desk row = Calendar `.sky-desk-row.is-filter-open`: main | Filter RIGHT.
   NEVER flex-column (that stacked Filter under a tiny map). */
.sky-customers-map .outlets-map-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  align-items: stretch;
  min-height: 0;
  flex: 1;
}
.sky-customers-map .outlets-map-body:has(> .sky-filter-rail),
.sky-customers-map .outlets-map-body:has(> .sky-filter.sky-filter-premium) {
  grid-template-columns: minmax(0, 1fr) minmax(var(--rail-width-min), var(--rail-width-max));
}
.outlets-map-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  min-height: 0;
}
.outlets-map-controls {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.outlets-map-mode-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}
.outlets-map-mode-toggle .img-size-btn {
  padding: 4px 10px;
  white-space: nowrap;
}
.outlets-map-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.outlets-map-select,
.outlets-map-sku-input {
  appearance: none;
  font: inherit;
  color: var(--ink);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  min-height: var(--btn-h-sm);
  min-width: min(100%, 220px);
  max-width: 100%;
}
.outlets-map-sku-wrap {
  position: relative;
  flex: 1;
  min-width: min(100%, 240px);
}
.outlets-map-sku-input {
  width: 100%;
  box-sizing: border-box;
}
.outlets-map-suggest {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 40;
  max-height: 240px;
  overflow: auto;
}
.outlets-map-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 6px 10px;
}
.outlets-map-status {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
  letter-spacing: -0.01em;
  line-height: 1.35;
}
.outlets-map-status:empty,
.outlets-map-meta-row:empty,
.outlets-map-meta-row[hidden] {
  display: none;
}
.outlets-map-status.is-err {
  color: var(--danger, #ef4444);
}
.outlets-map-coverage-disclosure {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.outlets-map-info-btn {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  border-radius: 50%;
  background: var(--btn-ghost-bg, var(--bg-elevated-2));
  color: var(--muted);
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow, 0 2px 8px rgba(0, 0, 0, 0.2));
}
.outlets-map-info-btn svg {
  width: 14px;
  height: 14px;
  display: block;
}
.outlets-map-info-btn:hover,
.outlets-map-info-btn:focus-visible,
.outlets-map-info-btn[aria-expanded="true"] {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line-strong));
}
.outlets-map-coverage-tip {
  margin: 0;
  max-width: 22rem;
  font-size: 0.72rem;
  color: var(--ink-secondary);
  text-align: right;
  line-height: 1.35;
}
.outlets-map-col {
  min-width: 0;
}
.crm-map-loading {
  position: absolute;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  color: var(--ink, #f5f5f5);
  font-size: 0.9rem;
  font-weight: var(--fw-semi, 600);
}
.crm-map-loading span {
  padding: 11px 18px;
  border-radius: 18px;
  background: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 0 0 1px rgba(10, 132, 255, 0.12),
    0 16px 40px rgba(0, 0, 0, 0.42);
}
/* MapLibre GL ? Customers Map + Near me (OpenFreeMap liberty) */
.near-me-map.maplibregl-map,
.outlets-map.maplibregl-map {
  background: #e8eef4;
  font: inherit;
}
.near-me-map .maplibregl-canvas,
.outlets-map .maplibregl-canvas {
  outline: none;
  /* MapLibre sets buffer = CSS size ? pixelRatio; never stretch via CSS. */
  transform: none !important;
  filter: none !important;
}
.near-me-map .maplibregl-ctrl-attrib,
.outlets-map .maplibregl-ctrl-attrib {
  background: rgba(0, 0, 0, 0.48) !important;
  color: #636366;
  font-size: 8.5px;
  line-height: 1.25;
  margin: 0 6px 6px 0;
  border-radius: 8px;
  padding: 2px 6px;
  max-width: 42%;
  opacity: 0.85;
}
.near-me-map .maplibregl-ctrl-attrib.maplibregl-compact,
.outlets-map .maplibregl-ctrl-attrib.maplibregl-compact {
  min-height: 20px;
  background: rgba(28, 28, 30, 0.72) !important;
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.near-me-map .maplibregl-ctrl-attrib a,
.outlets-map .maplibregl-ctrl-attrib a {
  color: #8e8e93;
}
.near-me-map .maplibregl-ctrl-group,
.outlets-map .maplibregl-ctrl-group {
  background: var(--bg-elevated-2, #1c1c1e);
  border: 1px solid var(--line-strong, #333);
  border-radius: var(--btn-chip-radius, 12px);
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}
.near-me-map .maplibregl-ctrl-group button,
.outlets-map .maplibregl-ctrl-group button {
  background: transparent;
  border-color: var(--line, #2c2c2e);
  width: 32px;
  height: 32px;
}
.near-me-map .maplibregl-ctrl-group button + button,
.outlets-map .maplibregl-ctrl-group button + button {
  border-top-color: var(--line, #2c2c2e);
}
.near-me-map .maplibregl-ctrl-icon,
.outlets-map .maplibregl-ctrl-icon {
  filter: invert(1) brightness(1.12);
}
.crm-ml-popup.maplibregl-popup {
  z-index: 450;
}
.crm-ml-popup .maplibregl-popup-content {
  background: var(--bg-elevated, #1c1c1e);
  color: var(--ink, #f5f5f5);
  border: 1px solid var(--line-strong, rgba(255, 255, 255, 0.1));
  border-radius: var(--radius-sm, 12px);
  padding: 16px 16px 14px;
  box-shadow:
    0 0 0 1px var(--map-frame-glow),
    var(--shadow, 0 16px 40px rgba(0, 0, 0, 0.45));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}
.crm-ml-popup .maplibregl-popup-content::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--map-pin-soft, #ff6961) 35%,
    var(--map-pin, #e53935) 65%,
    transparent
  );
  opacity: 0.9;
  pointer-events: none;
}
.crm-ml-popup .maplibregl-popup-close-button {
  color: var(--muted, #8e8e93);
  font-size: 18px;
  padding: 4px 10px;
  right: 4px;
  top: 6px;
}
.crm-ml-popup .maplibregl-popup-close-button:hover {
  background: transparent;
  color: var(--ink, #f5f5f5);
}
.crm-ml-popup .maplibregl-popup-tip {
  border-top-color: var(--bg-elevated, #1c1c1e);
  border-bottom-color: var(--bg-elevated, #1c1c1e);
}
.crm-ml-popup-card .crm-ml-popup-kicker {
  margin: 0 0 6px;
  font-size: 0.7rem;
  font-weight: var(--fw-strong, 700);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--map-pin-soft, #ff6961);
}
.crm-ml-popup-card .crm-ml-popup-title {
  display: block;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.crm-ml-popup-card .crm-ml-popup-code {
  margin-top: 2px;
  font-size: 0.78rem;
  color: var(--muted, #8e8e93);
  font-variant-numeric: tabular-nums;
}
.crm-ml-popup-card .near-me-popup-btn {
  margin-top: 0;
  width: 100%;
}
.crm-ml-popup-card .crm-map-popup-actions .near-me-popup-btn {
  margin-top: 0;
}
.crm-ml-user-marker {
  position: relative;
  width: 40px;
  height: 40px;
  pointer-events: none;
}
.crm-ml-user-pulse,
.crm-ml-user-ring,
.crm-ml-user-core,
.crm-ml-user-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.crm-ml-user-pulse {
  width: 38px;
  height: 38px;
  background: color-mix(in srgb, var(--map-you-soft, #64d2ff) 34%, transparent);
  animation: crmMlUserPulse 2.1s var(--ease, ease) infinite;
}
.crm-ml-user-pulse-2 {
  animation-delay: 0.75s;
  background: color-mix(in srgb, var(--accent) 22%, transparent);
}
.crm-ml-user-ring {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border: 2.5px solid rgba(255, 255, 255, 0.96);
  background: linear-gradient(
    160deg,
    color-mix(in srgb, var(--map-you-soft, #64d2ff) 72%, #fff 28%),
    var(--accent, #0a84ff) 72%
  );
  box-shadow:
    0 0 0 3px color-mix(in srgb, var(--map-you-soft, #64d2ff) 28%, transparent),
    0 3px 10px rgba(0, 0, 0, 0.48);
}
.crm-ml-user-glyph {
  display: block;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.35));
}
.crm-ml-user-core,
.crm-ml-user-dot {
  width: 8px;
  height: 8px;
  background: #ffffff;
  border: 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  cursor: default;
}
@keyframes crmMlUserPulse {
  0% { transform: translate(-50%, -50%) scale(0.5); opacity: 0.92; }
  70% { transform: translate(-50%, -50%) scale(1.65); opacity: 0; }
  100% { transform: translate(-50%, -50%) scale(1.65); opacity: 0; }
}
.crm-ml-selected-pin {
  width: 34px;
  height: 44px;
  pointer-events: none;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.45));
  transform: translateY(-1px);
}
.crm-ml-selected-pin.is-on {
  filter:
    drop-shadow(0 0 7px color-mix(in srgb, var(--map-pin-active) 60%, transparent))
    drop-shadow(0 4px 8px rgba(0, 0, 0, 0.42));
}
.crm-ml-selected-pin svg {
  display: block;
  width: 34px;
  height: 44px;
}

.outlets-map-empty {
  margin: 0;
}
.outlets-map-popup-hint {
  margin: 8px 0 0;
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.35;
}
body:not(.shell-phone) .sky-customers-map .sky-page-main.sky-canvas.outlets-map-panel {
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  padding: 12px 14px 16px;
}

@media (min-width: 901px) {
  body:not(.shell-phone) .near-me-body{
    grid-template-columns: minmax(0, 1.3fr) minmax(320px, 1fr);
    align-items: start;
  }
  body:not(.shell-phone) .near-me-map-col{
    order: 0;
    position: sticky;
    top: 12px;
  }
  body:not(.shell-phone) .near-me-map-wrap{
    height: 560px;
  }
  body:not(.shell-phone) .near-me-list-col .results.sky-list{
    max-height: 560px;
    overflow-y: auto;
  }
}

/* New customer ? sectioned form + Leaflet pin (CRM-74) */
.nc-card h1 { margin-bottom: 4px; }
.nc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
}
.nc-col-top,
.nc-col-bottom {
  min-width: 0;
}
.nc-section {
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.nc-col-top .nc-section:first-child { border-top: 0; padding-top: 0; }
.nc-section-title {
  margin: 0 0 12px;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
}
.nc-section .label { margin-top: 10px; }
.nc-section .label:first-child { margin-top: 0; }
/* crm889: each cell = label ABOVE full-width input (equal 2-col).
   Never auto-place flat label|input as side-by-side siblings.
   Supports: `.nc-field` / bare `div` cells, OR flat label/field/label/field. */
.nc-row2 {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: 12px;
  row-gap: 4px;
  margin-top: 10px;
  align-items: start;
}
.nc-row2 > .nc-field,
.nc-row2 > div:not(.field) {
  min-width: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
}
.nc-row2 > .nc-field > .label,
.nc-row2 > div:not(.field) > .label {
  margin-top: 0;
}
.nc-row2 > .nc-field > .field,
.nc-row2 > div:not(.field) > .field,
.nc-row2 > .field {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
/* Flat legacy: label, field, label, field as direct children → 2 cells stacked */
.nc-row2 > .label:nth-child(1) { grid-column: 1; grid-row: 1; margin-top: 0; }
.nc-row2 > .field:nth-child(2) { grid-column: 1; grid-row: 2; }
.nc-row2 > .label:nth-child(3) { grid-column: 2; grid-row: 1; margin-top: 0; }
.nc-row2 > .field:nth-child(4) { grid-column: 2; grid-row: 2; }
@media (max-width: 340px) {
  .nc-row2 { grid-template-columns: minmax(0, 1fr); }
  .nc-row2 > .label:nth-child(1),
  .nc-row2 > .field:nth-child(2),
  .nc-row2 > .label:nth-child(3),
  .nc-row2 > .field:nth-child(4) {
    grid-column: 1;
    grid-row: auto;
  }
}
.nc-addr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
.nc-addr-actions .btn.small {
  margin-top: 0;
  flex: 1 1 auto;
}
.nc-map-col {
  margin: 4px 0 0;
  min-width: 0;
}
.nc-map-wrap {
  position: relative;
  height: 200px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
}
.nc-map {
  width: 100%;
  height: 100%;
  background: var(--bg-elevated);
  cursor: crosshair;
}
.nc-map-hint { margin-top: 6px; }
.nc-pl-seg { margin-top: 2px; }
.nc-more {
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.nc-more summary {
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: var(--fw-med);
  color: var(--accent);
  list-style: none;
}
.nc-more summary::-webkit-details-marker { display: none; }
.nc-more summary::before {
  content: "+ ";
}
.nc-more[open] summary::before {
  content: "- ";
}
.nc-more-body { margin-top: 10px; }
.nc-card .field.error,
.nc-card textarea.field.error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(255, 69, 58, 0.16);
}
.nc-pl-seg.is-error {
  box-shadow: 0 0 0 3px rgba(255, 69, 58, 0.16);
  border-radius: var(--btn-radius-seg);
}
.nc-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}
.nc-actions-secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.nc-actions-secondary .btn {
  margin-top: 0;
  flex: 1 1 auto;
}
.nc-sticky-submit .btn { margin-top: 14px; }
.nc-actions .nc-sticky-submit .btn { margin-top: 0; }
@media (min-width: 901px) {
  body:not(.shell-phone) .nc-layout{
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    grid-template-rows: auto auto;
    align-items: start;
    gap: 0 24px;
  }
  body:not(.shell-phone) .nc-col-top{ grid-column: 1; grid-row: 1; }
  body:not(.shell-phone) .nc-col-bottom{ grid-column: 1; grid-row: 2; }
  body:not(.shell-phone) .nc-map-col{
    grid-column: 2;
    grid-row: 1 / span 2;
    position: sticky;
    top: 12px;
    margin: 0;
  }
  body:not(.shell-phone) .nc-map-wrap{ height: 460px; }
}
body.shell-phone .nc-map-wrap { height: 240px; }
/* Phone: dock the whole NC action stack (ghost + primary). Bare
   `.nc-sticky-submit` (action forms) keeps its own fixed dock below. */
body.shell-phone .nc-actions {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
  z-index: 120;
  padding: 10px 12px;
  border-radius: var(--btn-radius);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
}
body.shell-phone .nc-actions .nc-sticky-submit {
  position: static;
  left: auto;
  right: auto;
  bottom: auto;
  box-shadow: none;
}
body.shell-phone .nc-sticky-submit {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
  z-index: 120;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
}
body.shell-phone .nc-sticky-submit .btn { margin-top: 0; }
/* crm889: clear fixed NC dock + bottom nav so Comments + actions stay scrollable */
body.shell-phone .nc-card {
  padding-bottom: calc(
    var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 120px
  );
}
/* Action forms use the same phone submit dock as New customer; desktop keeps
   the button naturally in its form.
   WAVE2-SHEET-NAV-CLEAR ? last fields clear sticky CTA + bottom nav. */
body.shell-phone .action-form-card {
  padding-bottom: calc(var(--sheet-nav-clear) + 56px);
}
/* Forms Wave 2 ? denser Call / Merc chrome (keep nav-clear bottom pad) */
body.shell-phone .sky-form.action-form-card {
  padding: 14px 14px calc(var(--sheet-nav-clear) + 56px);
}
body.shell-phone .sky-form .sky-tag {
  margin: 2px 0 10px;
  font-size: 0.68rem;
  color: var(--muted);
}
body.shell-phone .sky-form .sky-title {
  font-size: 1.35rem;
  margin: 0 0 8px;
  color: var(--ink);
}
body.shell-phone .sky-form-lead {
  margin: 0 0 10px;
  font-size: 0.82rem;
  color: var(--muted);
}
body.shell-phone .sky-form .sky-foot {
  margin-top: 10px;
  font-size: 0.72rem;
  color: var(--muted);
}
body.shell-phone .card.action-form-card {
  /* Keep sticky Submit clear of bottom nav (do not collapse to 16px). */
  padding: 12px 12px calc(var(--sheet-nav-clear) + 56px);
}
body.shell-phone .card.action-form-card > h1 {
  font-size: 1.25rem;
  margin-bottom: 4px;
}
body.shell-phone .card.action-form-card > .sub {
  margin-bottom: 10px;
  font-size: 0.82rem;
}

/* PAGE MAXIMIZE M3 ? catalogue, cart and new-account workspace own the
   remaining canvas. Phone stays naturally scrollable; PC keeps dense work
   surfaces inside the viewport instead of leaving a black lower half. */
@media (min-width: 901px) {
  /* crm342: these were `min-height` only, which never actually bounds a box
     (a min just raises the floor ? a taller child still grows it past the
     viewport). Catalogue (400+ cards), cart and the new-account map all have
     content taller than one screen, so with only min-height the WHOLE PAGE
     grew to fit that content (measured live: Shop hit ~14,200px, Cart ~990px
     in a 768px viewport) instead of staying inside the viewport ? the exact
     opposite of "PAGE MAXIMIZE". That produced the doc-level scroll Roei saw
     as cards/buttons sliced off at the raw window edge (no scrollbar cue),
     PLUS a second, independent scroll inside `.checkout-box` ? two scrolls,
     neither obvious. `height` (real bound) + `min-height:0` makes every
     flex descendant below (`.shop-body`/`.products`, `.cart-card`/
     `.cart-layout`, `.nc-card`/`.nc-layout`) resolve against a definite
     size, so their own `overflow:auto` regions finally do the scrolling
     instead of the whole document. */
  body:not(.shell-phone) .sky-shop.is-pc,
  body:not(.shell-phone) .sky-cart.is-pc,
  body:not(.shell-phone) .sky-new-customer.is-pc{
    height: calc(100dvh - var(--hdr-h) - 28px);
    min-height: 0;
  }

  body:not(.shell-phone) .sky-shop.is-pc{
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-shop.is-pc .shop-body{
    flex: 1 1 auto;
    min-height: 0;
    align-items: stretch;
  }
  body:not(.shell-phone) .sky-shop.is-pc .shop-main-solo{
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-shop.is-pc .products{
    flex: 1 1 auto;
    min-height: 280px;
    align-content: start;
    overflow: auto;
    padding-right: 4px;
    scrollbar-width: thin;
  }
  body:not(.shell-phone) .sky-shop.is-pc .shop-body > .panel-foldable.sky-filter-premium[data-panel="cat-panel"]{
    position: static;
    top: auto;
    height: auto;
    max-height: none;
    min-height: 0;
    padding-bottom: var(--rail-pad-y);
  }

  body:not(.shell-phone) .sky-cart.is-pc{
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-cart.is-pc .cart-card{
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 16px 18px;
  }
  body:not(.shell-phone) .sky-cart.is-pc .cart-layout{
    flex: 1 1 auto;
    min-height: 0;
    /* NOT align-items:stretch ? stretching the sticky checkout-box to match
       cart-main's height (crm338 regression) triggers a Safari sticky+stretch
       clipping bug (top of the box, incl. the red validation line, rendered
       cut off) and forced cart-main into a cramped fixed-height scroll box.
       "start" lets each column size to its own content; the checkout box
       still gets its own max-height + scroll above so it's always usable. */
    align-items: start;
  }
  /* Cart table owns ONE scroll region (see .hist-table-full below) ? cart-main
     must NOT also be a scroll container, or you get the double/nested
     scrollbar Roei hit (outer cart-main scroll fighting the inner table's own
     scroll, squeezing the visible area down to ~1-2 rows regardless of how
     many lines are actually in the cart). */
  body:not(.shell-phone) .sky-cart.is-pc .cart-main{
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: visible;
  }
  body:not(.shell-phone) .sky-cart.is-pc .cart-main .cart-bulk-bar{
    flex: 0 0 auto;
  }
  body:not(.shell-phone) .sky-cart.is-pc .cart-main .cart-table-wrap{
    flex: 1 1 auto;
    min-height: 240px;
  }
  body:not(.shell-phone) .sky-cart.is-pc .cart-layout .checkout-box{
    margin: 0;
  }

  body:not(.shell-phone) .sky-new-customer.is-pc{
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-new-customer.is-pc .nc-card{
    flex: 1 1 auto;
    min-height: 0;
    padding: 16px 18px;
    /* crm342: .sky-new-customer.is-pc got a firm `height` in crm340 (was
       min-height-only, which just raised a floor while the map/form content
       still grew the WHOLE PAGE past the viewport ? cards/buttons sliced at
       the raw window edge, same bug as shop/cart). But `.nc-layout` right
       below kept its own `min-height: calc(100dvh?)` floor with no scroll
       boundary above it, so New customer never actually got the crm340 fix ?
       nc-card is now the one scroll region (sticky map still sticks inside it). */
    overflow: auto;
    overscroll-behavior: contain;
  }
  body:not(.shell-phone) .sky-new-customer.is-pc .nc-layout{
    min-height: 0;
  }
  body:not(.shell-phone) .sky-new-customer.is-pc .nc-map-col{
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-new-customer.is-pc .nc-map-wrap{
    flex: 1 1 auto;
    height: auto;
    min-height: 460px;
  }
}

.home-kpi-strip {
  display: grid;
  /* Option A My-day: 2 personal tiles ? fixed track so they don?t stretch full-bleed */
  grid-template-columns: repeat(2, minmax(160px, 220px));
  gap: 8px;
  margin: 0 0 14px;
  justify-content: start;
}
.home-kpi {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 12px 10px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  min-height: 72px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.home-kpi strong {
  font-size: 1.25rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.home-kpi span {
  font-size: 0.75rem;
  color: var(--muted);
}
.home-kpi-lab {
  display: flex;
  align-items: center;
  gap: 4px;
}
.home-kpi-ico {
  display: inline-flex;
  flex-shrink: 0;
  color: var(--muted);
}
.home-kpi:hover {
  border-color: var(--accent);
}
.home-kpi:hover .home-kpi-ico {
  color: var(--accent);
}
.home-radar {
  margin: 0 0 14px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 12px;
  box-shadow: var(--btn-ghost-shadow);
}
.home-radar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 10px;
}
.home-radar-title {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.home-radar-head h2 {
  margin: 0;
  font-size: 0.82rem;
  font-weight: var(--fw-strong);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}
/* Shared muted section-title icon mark ? Running deals / Call plan headers. */
.home-sec-ico {
  display: inline-flex;
  flex-shrink: 0;
  color: var(--muted);
}
.home-radar-sub {
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.25;
}
.home-radar-link,
.home-radar-cal-btn {
  appearance: none;
  flex-shrink: 0;
}
.home-radar-cal-btn {
  margin: 0;
}
.home-radar-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.home-radar-counts.admin-opt-group {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0;
}
.home-radar-counts .ios-filter-row.home-radar-filter {
  width: 100%;
  text-align: left;
}
.home-radar-counts .home-radar-filter-n {
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
  margin-right: 4px;
}
.home-radar-counts .ios-filter-row.is-late .home-radar-filter-n {
  color: var(--sky-late, #ff453a);
}
.home-radar-counts .ios-filter-row.is-soon .home-radar-filter-n {
  color: var(--sky-soon, var(--accent));
}
.home-radar-list-wrap {
  min-width: 0;
}
.home-radar-sec-label {
  margin: 0 0 6px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-radar-foot {
  margin-top: 10px;
}
.home-radar-foot .home-radar-cal-btn {
  width: 100%;
}
.home-radar-error {
  color: var(--muted);
}
/* Soft-fill count chips (iOS tint) ? not thin outline boxes */
.home-radar-chip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  gap: 5px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--btn-radius-seg-item, 10px);
  padding: 10px 12px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  line-height: 1.15;
  min-height: var(--btn-h, 44px);
  white-space: nowrap;
  cursor: pointer;
  color: var(--ink-secondary);
  box-shadow: none;
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease);
}
.home-radar-chip strong {
  font-size: 0.95rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
  color: inherit;
}
.home-radar-chip:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.14);
  color: var(--ink);
}
.home-radar-chip.is-late {
  border-color: color-mix(in srgb, var(--sky-late, #ff453a) 22%, transparent);
  background: color-mix(in srgb, var(--sky-late, #ff453a) 14%, rgba(255, 255, 255, 0.03));
  color: var(--sky-late, #ff453a);
}
.home-radar-chip.is-soon {
  border-color: color-mix(in srgb, var(--sky-soon, var(--accent)) 22%, transparent);
  background: color-mix(in srgb, var(--sky-soon, var(--accent)) 14%, rgba(255, 255, 255, 0.03));
  color: var(--sky-soon, var(--accent));
}
/* Single iOS inset group for stops */
.home-radar-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  max-height: 280px;
  overflow-y: auto;
  border-radius: var(--btn-radius-seg-item, 10px);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.home-radar-list > li + li {
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}
.home-radar-row {
  appearance: none;
  width: 100%;
  border: 0;
  border-left: 3px solid transparent;
  background: transparent;
  border-radius: 0;
  padding: 11px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
  min-height: 48px;
  box-shadow: none;
  transition: background 0.14s var(--ease);
}
.home-radar-main {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.home-radar-last {
  font-size: 0.7rem;
  font-weight: var(--fw-med, 500);
  line-height: 1.25;
  color: var(--muted);
}
.home-radar-last.is-never {
  color: color-mix(in srgb, var(--muted) 80%, #ff9f0a);
}
.home-radar-row:hover {
  background: rgba(255, 255, 255, 0.05);
}
.home-radar-row:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.home-radar-row.is-overdue {
  border-left-color: var(--sky-late, #ff453a);
}
.home-radar-row.is-overdue:hover {
  background: color-mix(in srgb, var(--sky-late, #ff453a) 8%, transparent);
}
.home-radar-row.is-today {
  border-left-color: var(--sky-soon, var(--accent));
}
.home-radar-row.is-today:hover {
  background: color-mix(in srgb, var(--sky-soon, var(--accent)) 8%, transparent);
}
.home-radar-row.is-soon {
  border-left-color: rgba(255, 255, 255, 0.18);
}
.home-radar-name {
  font-size: 0.92rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--ink);
}
.home-radar-meta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.01em;
  line-height: 1.1;
  color: var(--muted);
  border: 0;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--btn-radius-seg-item);
  padding: 5px 8px;
  min-height: 24px;
  box-shadow: none;
}
.home-radar-meta.is-overdue {
  color: #ff453a;
  background: color-mix(in srgb, #ff453a 16%, transparent);
}
.home-radar-meta.is-today {
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
}
.home-radar-meta.is-soon {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
}
.home-radar-empty {
  margin: 2px 0 0;
  font-size: 0.78rem;
}
.home-radar.is-compact {
  margin: 0 0 12px;
  padding: 10px;
}
/* Soft next-visit strip (not loud solid blue wash) */
.home-day-start {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 8px;
  padding: 12px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, rgba(255, 255, 255, 0.08));
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--accent) 12%, rgba(255, 255, 255, 0.03));
  box-shadow: none;
}
.home-day-start span,
.home-day-start small {
  display: block;
  color: var(--muted);
  font-size: var(--btn-fs-sm);
}
.home-day-start strong {
  display: block;
  color: var(--ink);
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
}
.home-day-start .btn,
.home-radar-start-btn {
  width: auto;
  margin: 0;
  flex-shrink: 0;
  min-width: 72px;
}
body.shell-phone .crm-home .home-radar {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
  margin: 0 0 18px;
}
.home-radar.is-compact .home-radar-sec-label {
  margin-top: 2px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.home-radar.is-compact .home-radar-list {
  max-height: 220px;
}
.home-radar.is-compact .home-radar-chip {
  min-height: var(--btn-h, 44px);
  padding: 10px 12px;
  font-size: 0.8rem;
}

/* Home Running deals ? bold promo strip. "Africa Flame" warm/lime brand lane,
 * not the generic purple-indigo AI gradient wash: Deal A = amber ? coral,
 * Deal B = teal ? lime. Section frame gets a warm top bar + tinted wash so
 * it reads as "there's a deal on" before anyone reads a word. */
.home-deals {
  --deals-a-1: #f59e0b;
  /* crm726: thumb size inside shared media well (was cramped 52px corner chips). */
  --deals-card-visual: 52px;
  --deals-card-thumb: 96px;
  --home-deal-media-h: 132px;
  --deals-a-2: #f97316;
  --deals-a-3: #e11d48;
  --deals-b-1: #0d9488;
  --deals-b-2: #22c55e;
  --deals-b-3: #a3e635;
  /* Deal C ? deep ember / wine (distinct from A amber and B teal) */
  --deals-c-1: #be123c;
  --deals-c-2: #9f1239;
  --deals-c-3: #7f1d1d;
  --deals-d-1: #4338ca;
  --deals-d-2: #6366f1;
  --deals-d-3: #818cf8;
  --deals-e-1: #7c3aed;
  --deals-e-2: #a855f7;
  --deals-e-3: #c084fc;
  --deals-f-1: #e11d48;
  --deals-f-2: #f43f5e;
  --deals-f-3: #fb7185;
  --deals-g-1: #0369a1;
  --deals-g-2: #0ea5e9;
  --deals-g-3: #38bdf8;
  --deals-h-1: #ca8a04;
  --deals-h-2: #eab308;
  --deals-h-3: #fde047;
  position: relative;
  margin: 0 0 14px;
  border: 1px solid color-mix(in srgb, var(--deals-a-2) 30%, var(--line));
  background: linear-gradient(180deg, color-mix(in srgb, var(--deals-a-1) 9%, var(--bg-elevated)) 0%, var(--bg-elevated) 60%);
  border-radius: var(--radius-sm);
  padding: 14px 12px 12px;
  box-shadow: var(--btn-ghost-shadow);
  /* Visible so Roei drag handle (top:-11px) and gear icons aren't clipped. */
  overflow: visible;
}
.home-deals::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  /* .home-deals is overflow:visible (drag handle / gear clipping fix) ? this
     bar sits flush with the box edge, so it needs its own top corner radius
     or it'd show square corners poking past the card's rounded top now that
     the parent no longer clips it. */
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  background: linear-gradient(
    90deg,
    var(--deals-a-1),
    var(--deals-a-3) 38%,
    var(--deals-b-1) 62%,
    var(--deals-b-3)
  );
}
.home-deals-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 10px;
}
.home-deals-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.home-deals-head-actions .btn {
  gap: 6px;
}
.home-deals-main-banner {
  width: 100%;
  margin: 0 0 10px;
  cursor: default;
  pointer-events: none;
}
.home-deals-title {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.home-deals-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  align-self: flex-start;
  padding: 2px 9px 3px;
  border-radius: var(--btn-chip-radius);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(120deg, var(--deals-a-1), var(--deals-a-3));
  box-shadow: 0 2px 8px -3px color-mix(in srgb, var(--deals-a-3) 70%, transparent);
}
.home-deals-eyebrow svg {
  flex-shrink: 0;
}
.home-deals-head h2 {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.home-deals-sub {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.25;
}
.home-deals-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  align-items: stretch;
}
.home-deals-grid > .home-deals-card {
  height: 100%;
  min-height: 76px;
}
.home-deals-card-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100%;
  height: 100%;
}
.home-deals-card-wrap .home-deals-card {
  width: 100%;
  flex: 1 1 auto;
  height: 100%;
  min-height: 76px;
}
/* Minimal icon chrome ? gear on card corner, + in section head. */
.home-deals-ico-btn {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: var(--btn-icon-radius);
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 0.14s var(--ease), transform 0.14s var(--ease);
}
.home-deals-ico-btn:hover {
  background: rgba(0, 0, 0, 0.58);
  transform: scale(1.04);
}
.home-deals-ico-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.home-deals-head-actions .home-deals-add-btn {
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink);
}
.home-deals-head-actions .home-deals-add-btn:hover {
  color: #fff;
  background: var(--bg-elevated-2);
  transform: none;
}
.home-deals-card-settings {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
}
.home-deals-banner-wrap {
  margin: 0 0 10px;
  flex: 0 0 auto;
  width: 100%;
}
.home-deals-card {
  /* crm726: media stage + foot — absolute fill so tall equal-height cards stay dense. */
  appearance: none;
  width: 100%;
  display: block;
  text-align: left;
  border: none;
  border-radius: var(--btn-chip-radius);
  padding: 0;
  font: inherit;
  color: #fff;
  cursor: pointer;
  position: relative !important;
  overflow: hidden;
  min-height: 112px;
  box-sizing: border-box;
  box-shadow: 0 8px 20px -10px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  transition: transform 0.14s var(--ease), box-shadow 0.14s var(--ease), filter 0.14s var(--ease);
}
/* Positioned host inside <button> — WebKit won't absolute-layout direct button kids. */
.home-deals-card-inner {
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  left: 0 !important;
  display: block !important;
  box-sizing: border-box;
}
.home-deals-card.is-a {
  background: linear-gradient(135deg, var(--deals-a-1) 0%, var(--deals-a-2) 48%, var(--deals-a-3) 100%);
}
.home-deals-card.is-b {
  background: linear-gradient(135deg, var(--deals-b-1) 0%, var(--deals-b-2) 55%, var(--deals-b-3) 100%);
}
.home-deals-card.is-c {
  background: linear-gradient(135deg, var(--deals-c-1) 0%, var(--deals-c-2) 48%, var(--deals-c-3) 100%);
}
.home-deals-card.is-d {
  background: linear-gradient(135deg, var(--deals-d-1) 0%, var(--deals-d-2) 48%, var(--deals-d-3) 100%);
}
.home-deals-card.is-e {
  background: linear-gradient(135deg, var(--deals-e-1) 0%, var(--deals-e-2) 48%, var(--deals-e-3) 100%);
}
.home-deals-card.is-f {
  background: linear-gradient(135deg, var(--deals-f-1) 0%, var(--deals-f-2) 48%, var(--deals-f-3) 100%);
}
.home-deals-card.is-g {
  background: linear-gradient(135deg, var(--deals-g-1) 0%, var(--deals-g-2) 48%, var(--deals-g-3) 100%);
}
.home-deals-card.is-h {
  background: linear-gradient(135deg, var(--deals-h-1) 0%, var(--deals-h-2) 48%, var(--deals-h-3) 100%);
}
/* Dual-tone ? accent + accent2; --deals-dual-* set inline from picker tokens. */
.home-deals-card.is-dual {
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--deals-dual-1, var(--deals-a-1)) 88%, #000 12%) 0%,
    color-mix(
      in srgb,
      var(--deals-dual-1, var(--deals-a-1)) 42%,
      var(--deals-dual-2, var(--deals-b-1)) 58%
    ) 52%,
    color-mix(in srgb, var(--deals-dual-2, var(--deals-b-1)) 88%, #000 12%) 100%
  );
}
.home-deals-card.is-dual::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  border-radius: var(--btn-chip-radius) 0 0 var(--btn-chip-radius);
  background: linear-gradient(
    180deg,
    var(--deals-dual-1, var(--deals-a-1)),
    var(--deals-dual-2, var(--deals-b-1))
  );
  box-shadow: 1px 0 0 rgba(255, 255, 255, 0.12);
  pointer-events: none;
  z-index: 2;
}
.home-deals-card:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}
.home-deals-card:active {
  transform: translateY(0);
  filter: brightness(0.97);
}
.home-deals-card:focus-visible {
  box-shadow: var(--btn-focus-ring), 0 8px 20px -10px rgba(0, 0, 0, 0.6);
}
.home-deals-card-visual {
  /* Media stage fills card above the foot band. */
  position: absolute !important;
  top: 10px !important;
  right: 10px !important;
  bottom: 58px !important;
  left: 10px !important;
  width: auto !important;
  height: auto !important;
  inset: auto;
  display: flex !important;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 10px 12px;
  box-sizing: border-box;
  border-radius: calc(var(--btn-chip-radius) - 2px);
  background:
    radial-gradient(120% 90% at 50% 42%, rgba(255, 255, 255, 0.16), transparent 64%),
    rgba(0, 0, 0, 0.34) !important;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
  overflow: hidden;
  z-index: 0;
}
.home-deals-card-badge {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--deals-card-thumb, 96px);
  height: var(--deals-card-thumb, 96px);
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.32);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
.home-deals-card-imgs {
  flex-shrink: 0;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: auto;
  max-width: 100%;
  min-width: 0;
  height: auto;
  margin: 0 auto;
  overflow: visible;
}
.home-deals-card-imgs img {
  width: var(--deals-card-thumb, 96px);
  height: var(--deals-card-thumb, 96px);
  border-radius: 18px;
  object-fit: cover;
  background: #fff;
  border: 2.5px solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.42);
  flex-shrink: 0;
}
.home-deals-card-imgs img + img {
  margin-left: -28px;
}
/* Rare single product / custom thumb — fill media stage. Multi-thumb collage
 * keeps overlap stamps (crm841: flyer is modal-only, not card face). */
.home-deals-card-imgs[data-n="1"] {
  width: 100%;
  height: 100%;
  max-width: none;
}
.home-deals-card-imgs[data-n="1"] img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: calc(var(--btn-chip-radius) - 4px);
  background: rgba(0, 0, 0, 0.2);
}
.home-deals-card-foot {
  position: absolute !important;
  left: 12px !important;
  right: 10px !important;
  bottom: 10px !important;
  top: auto !important;
  z-index: 1;
  display: flex !important;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 40px;
  padding: 0 2px;
  margin: 0;
}
.home-deals-card-copy {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1 1 auto;
}
.home-deals-card-big {
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  text-transform: uppercase;
  line-height: 1.18;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.home-deals-card-cap {
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.25;
  color: rgba(255, 255, 255, 0.9);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Flame retired crm726 — cluttered vs restrained chevron kit. */
.home-deals-card-flame {
  display: none !important;
}
.home-deals-card-chev {
  position: static;
  transform: none;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--btn-radius-seg-item, 8px);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.95);
  pointer-events: none;
  box-sizing: border-box;
}
.home-deals.is-compact {
  margin: 0 0 12px;
  padding: 12px 10px 10px;
  --deals-card-visual: 100px;
  --deals-card-thumb: 100px;
  --home-deal-media-h: 140px;
}
.home-deals.is-compact .home-deals-card {
  min-height: 68px;
}
.home-deals.is-compact .home-deals-card-visual {
  top: 8px !important;
  right: 8px !important;
  bottom: 54px !important;
  left: 8px !important;
}
.home-deals.is-compact .home-deals-card-foot {
  left: 12px !important;
  right: 10px !important;
  bottom: 8px !important;
}
.home-deals.is-compact .home-deals-card-big {
  font-size: 0.96rem;
}
.home-deals.is-compact .home-deals-card-cap {
  font-size: 0.74rem;
}
/* Premium flyer viewer ? dark elevated sheet, full readable flyer + Save/Send. */
.home-deals-flyer-back {
  padding: max(10px, env(safe-area-inset-top, 0px)) 12px
    max(12px, env(safe-area-inset-bottom, 0px));
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.home-deals-flyer-back .home-deals-flyer-sheet {
  width: min(96vw, 560px);
  max-height: min(94vh, 960px);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55), var(--shadow);
}
.home-deals-flyer-sheet .home-deals-flyer-head {
  flex-shrink: 0;
  align-items: flex-start;
  gap: 12px;
  margin: 0;
  padding: 14px 14px 12px;
  border-bottom: 1px solid var(--line);
}
.home-deals-flyer-head-copy {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.home-deals-flyer-head-copy h2 {
  margin: 0;
  font-size: 1.02rem;
  font-weight: var(--fw-semi);
  line-height: 1.25;
  color: var(--ink);
}
.home-deals-flyer-shout {
  margin: 0;
  font-size: 0.74rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  line-height: 1.3;
  color: var(--muted);
}
.home-deals-flyer-view {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 16px;
  background: #0a0a0c;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.home-deals-flyer-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 100%;
  max-height: min(72vh, 760px);
  margin: 0 auto;
  padding: 0;
  border-radius: var(--btn-chip-radius);
  overflow: hidden;
  background: #000;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
}
.home-deals-flyer-img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: min(72vh, 760px);
  object-fit: contain;
  object-position: center;
}
.home-deals-flyer-frame {
  display: block;
  width: 100%;
  height: min(72vh, 760px);
  min-height: min(52vh, 420px);
  border: 0;
  background: #111;
}
.home-deals-flyer-actions {
  flex-shrink: 0;
  display: flex;
  gap: 8px;
  padding: 12px 14px calc(12px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line);
  background: var(--bg-elevated);
}
.home-deals-flyer-actions .btn {
  flex: 1 1 0;
  width: auto;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}
.home-deals-flyer-actions .btn svg {
  flex-shrink: 0;
}
.home-deals-flyer-sheet .home-deals-flyer-actions .btn.primary {
  width: auto;
}
@media (min-width: 900px) {
  body:not(.shell-phone) .home-deals-flyer-back .home-deals-flyer-sheet {
    width: min(92vw, 720px);
  }
  body:not(.shell-phone) .home-deals-flyer-stage,
  body:not(.shell-phone) .home-deals-flyer-img {
    max-height: min(78vh, 820px);
  }
  body:not(.shell-phone) .home-deals-flyer-frame {
    height: min(78vh, 820px);
  }
}
.home-deals-sheet .home-deals-chip-echo {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--accent);
}
.home-deals-sheet .home-deals-desc {
  margin: 0 0 12px;
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--ink);
}
.home-deals-sheet .home-deals-sec-label {
  margin: 0 0 8px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-deals-families {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0 0 12px;
  max-height: min(42vh, 280px);
  overflow-y: auto;
}
.home-deals-family {
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  border-radius: var(--btn-chip-radius);
  padding: 9px 11px;
  box-shadow: var(--btn-ghost-shadow);
}
.home-deals-family h3 {
  margin: 0 0 3px;
  font-size: 0.86rem;
  font-weight: var(--fw-strong);
  color: var(--ink);
}
.home-deals-family p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--muted);
}
.home-deals-free {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
  margin: 0 0 12px;
  padding: 9px 11px;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--btn-ghost-border));
  background: color-mix(in srgb, var(--accent) 8%, var(--btn-ghost-bg));
  border-radius: var(--btn-chip-radius);
}
.home-deals-free-lab {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  width: 100%;
}
.home-deals-free strong {
  font-size: 0.9rem;
  color: var(--ink);
}
.home-deals-free-sku {
  font-size: 0.72rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--muted);
}
.home-deals-foot {
  margin: 0 0 12px;
  font-size: 0.74rem;
}
.home-deals-sheet .btn.primary {
  width: 100%;
}
.home-radar.is-compact .home-radar-row {
  padding: 7px 9px;
  min-height: 44px;
}
.home-radar.is-compact .home-radar-last {
  font-size: 0.68rem;
}
.home-pc-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
/* Wave 1 P0 ? never show PC home CTA row (omitted in renderHome; CSS belt). */
.crm-home.is-pc .home-pc-cta-row {
  display: none !important;
}
.crm-home.is-pc:has(.crm-home-panel) .home-quick-grid.is-pc {
  display: none !important;
}
.sky-hub-task-main {
  appearance: none;
  border: 0;
  background: transparent;
  text-align: left;
  color: inherit;
  font: inherit;
  cursor: pointer;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 0;
}
.sky-hub-task-main:disabled {
  cursor: default;
  opacity: 0.55;
}
.sky-hub-task-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 15px;
  height: 15px;
  margin-top: 2px;
  color: var(--muted);
  opacity: 0.8;
}
.sky-hub-task-main-txt {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.dash-rail-card {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 10px 12px 12px;
}
.dash-rail-card .sky-hub-tabs {
  margin: 0 0 8px;
}
.dash-rail-card .sky-hub-tab-body {
  padding-top: 0;
}
.dash-rail-names {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 220px;
  overflow: auto;
}
.dash-rail-names li {
  font-size: 0.88rem;
  padding: 6px 8px;
  border-radius: 8px;
  background: var(--bg-elevated-2);
}
.hub-insight-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.hub-insight-stats div {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--line);
}
.hub-insight-stats strong {
  font-size: 1.05rem;
}
.hub-insight-stats span {
  font-size: 0.75rem;
  color: var(--muted);
}
@media (max-width: 900px) {
  .home-kpi-strip {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
    max-width: 440px;
  }
  .home-kpi {
    min-height: 64px;
    padding: 10px 8px;
  }
  .home-kpi strong {
    font-size: 1.1rem;
  }
  .home-quick-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.sky-modal-opt .sub {
  display: block;
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 2px;
}
@media (max-width: 900px) {
  .near-me-row {
    padding-right: 64px;
  }
  .sky-page.sky-near-me .sky-page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  .sky-page.sky-near-me .sky-hub-add {
    width: auto;
    flex: 0 0 auto;
  }
}
.crm-ops-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
}
.crm-ops-item:last-child {
  border-bottom: 0;
}
.crm-ops-task {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.crm-ops-task.is-today {
  background: rgba(255, 159, 10, 0.06);
  padding: 10px 8px;
  box-shadow: inset 3px 0 0 var(--sky-soon);
}
.crm-ops-task.is-unlinked .sky-hub-task-main .sub {
  opacity: 0.7;
}
.sky-hub-task-main .sub.is-today {
  color: #ff9f0a;
  font-weight: var(--fw-med);
}
.crm-ops-task.is-overdue {
  background: rgba(255, 69, 58, 0.06);
  padding: 10px 8px;
  box-shadow: inset 3px 0 0 var(--sky-late);
}
/* Tasks hub ? done = strikethrough on .sky-task-desc; Undone drops .is-done */
.crm-ops-task.is-done .sky-task-desc,
.sky-tasks-row.is-done .sky-task-desc {
  text-decoration: line-through;
  text-decoration-thickness: 1px;
  opacity: 0.72;
}
.crm-ops-task:not(.is-done) .sky-task-desc,
.sky-tasks-row:not(.is-done) .sky-task-desc {
  text-decoration: none;
  opacity: 1;
}
/* Don't let desc-button hover underline cancel done strike on the text span. */
.sky-tasks-row.is-done .sky-tasks-col-desc:not(:disabled):hover .sky-task-desc {
  text-decoration: line-through underline;
}
.crm-ops-task > .btn {
  width: auto;
  flex: 0 0 auto;
  margin-top: 0;
}
.crm-ops-body {
  display: block;
  margin-top: 2px;
  opacity: 0.85;
}
/* Hub meta line (customer ? due ? assignee) inside task/contact/activity rows ?
   these rows are left-aligned, single-line captions, not the centred login-card .sub. */
.crm-ops-item .sub,
.sky-hub-task-main .sub {
  text-align: left;
  margin: 0;
}
.sky-hub-task-main .sub.is-overdue {
  color: var(--danger);
  font-weight: var(--fw-med);
}
/* Tap-to-call / tap-to-email chips ? customer hub header meta + Contacts rows. */
.sky-tel-link,
.sky-mail-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--accent);
  text-decoration: none;
  font-weight: var(--fw-semi);
}
.sky-tel-link svg,
.sky-mail-link svg {
  flex: 0 0 auto;
  opacity: 0.9;
}
.sky-tel-link:hover,
.sky-mail-link:hover,
.sky-tel-link:focus-visible,
.sky-mail-link:focus-visible {
  text-decoration: underline;
}
.btn.sm {
  width: auto;
  flex: 0 0 auto;
  margin-top: 0;
  min-height: 36px;
  padding: 6px 12px;
  font-size: 0.85rem;
}
.sky-tl-row.is-btn {
  appearance: none;
  border: 0;
  background: transparent;
  width: 100%;
  text-align: left;
  color: inherit;
  cursor: pointer;
  font: inherit;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
}
.sky-tl-row.is-btn:active {
  background: rgba(255, 255, 255, 0.04);
}
.crm-acct.is-phone .home-start-cta:not(.sky-sticky-visit) {
  display: block;
  position: static;
  margin-top: 12px;
}
body.shell-phone .sky-customer-hub.is-phone .sky-hub-tab-body {
  padding-bottom: 12px;
}
body.shell-phone .sky-customer-hub.is-phone .home-start-cta.sky-sticky-visit {
  position: static;
  left: auto;
  right: auto;
  bottom: auto;
  width: 100%;
  margin: 12px 0 0;
  box-shadow: var(--btn-primary-shadow);
}
@media (max-width: 700px) {
  .results.sky-list .result.pick-cust,
  .sky-list .result.pick-cust {
    grid-template-columns: minmax(0, 1fr) auto !important;
    grid-template-areas:
      "code meta"
      "name name" !important;
  }
}

/* ?? Home (live agenda + dense quick grid) ?? */
.crm-home {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 2px 0 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: calc(100dvh - var(--hdr-h) - var(--safe-top) - var(--hdr-gap-y) - var(--bottom-nav-h) - var(--safe-bottom) - 28px);
}
.crm-home.is-pc {
  width: 100%;
  max-width: none;
  margin: 0;
  min-height: 0;
  box-sizing: border-box;
}
.crm-home.is-phone {
  max-width: none;
  padding-bottom: 4px;
}
.crm-home-head h1,
.crm-home-head .home-greet {
  margin: 2px 0 4px;
  font-size: 1.55rem;
  letter-spacing: -0.03em;
  font-weight: var(--fw-semi);
}
.home-head-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.home-head-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1px;
  flex: 0 0 auto;
  padding-top: 5px;
  white-space: nowrap;
}
.home-head-date {
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  letter-spacing: -0.01em;
}
.home-head-time {
  font-size: 0.76rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}
.home-greet-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 2px;
  min-width: 0;
}
.home-greet-text {
  min-width: 0;
  flex: 1;
}
.home-greet-line {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px 12px;
  min-width: 0;
}
.home-greet-line .home-greet,
.home-greet-line .sky-dash-greet {
  margin: 0;
  min-width: 0;
}
.home-greet-date {
  flex: 0 0 auto;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  letter-spacing: -0.01em;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.shell-phone .home-greet-date {
  font-size: 0.82rem;
}
.home-avatar-btn {
  margin-top: 2px;
}
.home-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  display: block;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}
.home-avatar-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
  box-sizing: border-box;
}
.crm-home.is-pc .crm-home-head h1,
.crm-home.is-pc .crm-home-head .home-greet {
  font-size: 1.65rem;
}
.home-today-line {
  margin: 0 0 8px;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  letter-spacing: -0.01em;
  line-height: 1.35;
  word-break: break-word;
}
.crm-home-date {
  margin: 0;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.crm-home-sub {
  margin: 0 0 4px;
  text-align: left;
  max-width: 40rem;
}
/* One efficient row: greet + date/time aside, tighter status line under it. */
.crm-home-head .home-today-line {
  margin-bottom: 4px;
}
.crm-home-head .home-status-line {
  margin: 2px 0 0;
  font-size: 0.85rem;
}
/* Home block drag-reorder (Roei only ? crm356/crm359). `.home-section` tags the
   block's existing root element in place (no extra wrapper) so grid/flex
   placement, e.g. `.crm-home-panel` grid-column, is untouched. Handle only
   renders for Roei. */
.home-section {
  position: relative;
  transition: box-shadow 0.16s var(--ease), transform 0.16s var(--ease), opacity 0.16s var(--ease);
}
.home-section-handle {
  /* Floating tab poking above the section's own top edge (into the inter-section
     gap) ? never overlaps a block's own title / gear / add-block chrome. */
  position: absolute;
  top: -12px;
  left: 12px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: var(--btn-chip-radius, 12px);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--muted);
  cursor: grab;
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  /* Roei chrome: hidden unless section hovered / editing / briefly revealed. */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    color 0.15s var(--ease),
    background 0.15s var(--ease),
    opacity 0.15s var(--ease),
    visibility 0.15s var(--ease);
}
/* Phone: ?44px grip + expanded left hit pad (does not span the whole head ?
   that would lock-scroll every block top for Roei). */
body.shell-phone .crm-home .home-section-handle {
  top: -14px;
  left: 8px;
  width: 44px;
  height: 44px;
}
body.shell-phone .crm-home .home-section-handle::after {
  content: "";
  position: absolute;
  left: -8px;
  top: -4px;
  width: 72px;
  height: 52px;
  border-radius: var(--btn-chip-radius, 12px);
}
.home-section-handle:hover,
.home-section-handle:focus-visible {
  color: var(--ink);
  background: var(--bg-elevated-2);
}
.home-section-handle:active {
  cursor: grabbing;
}
/* Hide this block from Home (Roei only). Sits beside the grip; restore lives in
   the Home "Hidden" bar, so nothing is ever destroyed by hiding. */
.home-section-hide {
  /* Opposite edge to the grip - keeps narrow phone block titles clear. */
  position: absolute;
  top: -11px;
  right: 14px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 22px;
  padding: 0;
  border-radius: var(--btn-chip-radius, 12px);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--muted);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    color 0.15s var(--ease),
    background 0.15s var(--ease),
    opacity 0.15s var(--ease),
    visibility 0.15s var(--ease);
}
.home-section-hide:hover,
.home-section-hide:focus-visible {
  color: var(--danger, #d7263d);
  background: var(--bg-elevated-2);
}
/* Reveal Roei drag / hide only on hardware that truly supports hover.
   Do NOT use section :focus-within / :active — KPI/deal buttons keep focus and
   made grip/X look permanently on. Phone uses explicit `.is-editing` only. */
@media (hover: hover) and (pointer: fine) {
  .home-section:hover > .home-section-handle,
  .home-section:hover > .home-section-hide {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
}
.home-section.is-home-dragging > .home-section-handle,
.home-section.is-home-dragging > .home-section-hide,
.crm-home.is-editing .home-section > .home-section-handle,
.crm-home.is-editing .home-section > .home-section-hide {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
/* Keyboard / press on the grip / X itself only. */
.home-section-handle:focus-visible,
.home-section-hide:focus-visible,
.home-section-handle:active,
.home-section-hide:active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
/* crm578/crm592 — Deals Edit / + / card gear: true hover or explicit edit only. */
.crm-home.is-roei-edit .home-deals-head {
  position: relative;
}
.crm-home.is-roei-edit .home-deals-edit-quiet,
.crm-home.is-roei-edit .home-deals-head-actions .home-deals-add-btn,
.crm-home.is-roei-edit .home-deals-card-settings {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.15s var(--ease),
    visibility 0.15s var(--ease),
    background 0.14s var(--ease),
    transform 0.14s var(--ease);
}
/* Quiet Edit sits in the head corner so a hidden button does not leave a gap. */
.crm-home.is-roei-edit .home-deals-edit-quiet {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
}
@media (hover: hover) and (pointer: fine) {
  .crm-home.is-roei-edit .home-deals:hover .home-deals-edit-quiet,
  .crm-home.is-roei-edit .home-deals:hover .home-deals-head-actions .home-deals-add-btn,
  .crm-home.is-roei-edit .home-deals:hover .home-deals-card-settings,
  .crm-home.is-roei-edit .home-deals-card-wrap:hover .home-deals-card-settings {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
}
.crm-home.is-roei-edit.is-editing .home-deals-edit-quiet,
.crm-home.is-roei-edit.is-editing .home-deals-head-actions .home-deals-add-btn,
.crm-home.is-roei-edit.is-editing .home-deals-card-settings,
.crm-home.is-roei-edit .home-deals-edit-quiet:focus-visible,
.crm-home.is-roei-edit .home-deals-add-btn:focus-visible,
.crm-home.is-roei-edit .home-deals-card-settings:focus-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.home-hidden-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0 4px;
  padding: 10px 12px;
  border-radius: var(--radius-sm, 12px);
  border: 1px dashed var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
}
.home-hidden-lab {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-hidden-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.home-hidden-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
/* Drag in progress (pointer-based, incl. touch): kill selection + rubber-band so
   the lifted block tracks the finger instead of scrolling the page. */
body.is-crm-reordering {
  user-select: none;
  -webkit-user-select: none;
  overscroll-behavior: contain;
}
/* Peers dim so the in-hand row pops (shared reorder path). crm804 ≤0.5. */
body.is-crm-reordering .cart-lines-list > .cart-line:not(.is-crm-dragging):not(.is-crm-drag-armed),
body.is-crm-reordering .cart-table tbody tr:not(.is-crm-dragging):not(.is-crm-drag-armed),
body.is-crm-reordering .home-section:not(.is-crm-dragging):not(.is-crm-drag-armed) {
  opacity: var(--crm-drag-peer-opacity, 0.45);
  transition: none;
}
/* crm804: settings-list overflow:hidden clipped ring/shadow — open during reorder. */
body.shell-phone.is-crm-reordering .sky-cart .cart-lines-list.settings-list,
body.shell-phone .cart-lines-list.settings-list:has(> .cart-line.is-crm-drag-armed),
body.shell-phone .cart-lines-list.settings-list:has(> .cart-line.is-crm-dragging) {
  overflow: visible !important;
}
/* crm804: dedicated insert bar (placed by bindPointerReorder; not a float card). */
.crm-drag-insert-line {
  position: absolute;
  left: 10px;
  right: 10px;
  height: 5px;
  margin: 0;
  border: 0;
  border-radius: 999px;
  background: var(--accent, #0a84ff);
  box-shadow:
    0 0 0 2px color-mix(in srgb, var(--accent, #0a84ff) 50%, #fff 30%),
    0 0 16px rgba(10, 132, 255, 0.9),
    0 2px 8px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  z-index: 80;
  opacity: 0;
  transform: scaleX(0.92);
  transition: none;
}
.crm-drag-insert-line.is-on {
  opacity: 1;
  transform: scaleX(1);
}
.crm-drag-insert-line.is-axis-x {
  top: 8px;
  bottom: 8px;
  left: auto;
  right: auto;
  width: 5px;
  height: auto;
  transform: scaleY(0.92);
}
.crm-drag-insert-line.is-axis-x.is-on {
  transform: scaleY(1);
}
/* crm804: handle pressed / chosen — 2px accent ring + elevated fill, instant. */
.is-crm-drag-armed:not(.is-crm-dragging) {
  opacity: 1;
  z-index: 25;
  cursor: grabbing;
  background: color-mix(in srgb, var(--crm-drag-bg, var(--bg-elevated-2)) 78%, var(--accent) 22%);
  box-shadow: var(--crm-drag-armed-shadow);
  transform: translateY(-2px) scale(1.02);
  transition: none;
}
/* crm804: shared lifted look — solid + ring + scale ≥1.04; no laggy tween. */
.is-crm-dragging {
  opacity: 1 !important;
  transform: translateY(-4px) scale(var(--crm-drag-scale, 1.045));
  box-shadow: var(--crm-drag-shadow);
  background: var(--crm-drag-bg, var(--bg-elevated-2, #2c2c2e));
  z-index: 50;
  cursor: grabbing;
  position: relative;
  transition: none;
}
/* Phone cart swipe rows clip shadows (`overflow:hidden`) — lift the painted front. */
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-crm-drag-armed,
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-crm-dragging {
  overflow: visible !important;
  z-index: 50;
  transform: none;
  box-shadow: none;
  opacity: 1;
  background: transparent;
}
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-crm-dragging > .crm-swipe-actions,
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-crm-drag-armed > .crm-swipe-actions {
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
body.shell-phone .cart-lines-list > .cart-line.is-crm-drag-armed:not(.is-crm-dragging) .cart-line-front,
body.shell-phone .cart-lines-list > .cart-line.is-crm-drag-armed:not(.is-crm-dragging):not(.is-swipeable) {
  box-shadow: var(--crm-drag-armed-shadow) !important;
  background: color-mix(in srgb, var(--crm-drag-bg, var(--bg-elevated-2)) 78%, var(--accent) 22%) !important;
  outline: 2px solid var(--accent, #0a84ff);
  outline-offset: 0;
  opacity: 1;
  transform: translateY(-2px) scale(1.02) !important;
  z-index: 45;
  position: relative;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  transition: none !important;
}
body.shell-phone .cart-lines-list > .cart-line.is-crm-dragging .cart-line-front,
body.shell-phone .cart-lines-list > .cart-line.is-crm-dragging:not(.is-swipeable) {
  box-shadow: var(--crm-drag-shadow) !important;
  background: var(--crm-drag-bg, var(--bg-elevated-2, #2c2c2e)) !important;
  outline: 2.5px solid var(--accent, #0a84ff);
  outline-offset: 0;
  opacity: 1 !important;
  transform: translateY(-5px) scale(var(--crm-drag-scale, 1.045)) !important;
  z-index: 50;
  position: relative;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  transition: none !important;
}
/* crm804: handle tint when chosen / in hand (kit handle uses !important clear). */
body.shell-phone .cart-line.is-crm-drag-armed .cart-line-handle,
body.shell-phone .cart-line.is-crm-dragging .cart-line-handle,
body.shell-phone .cart-line.is-crm-drag-armed .cart-kit-card-head .cart-line-handle.cart-kit-handle,
body.shell-phone .cart-line.is-crm-dragging .cart-kit-card-head .cart-line-handle.cart-kit-handle {
  color: var(--accent, #0a84ff) !important;
  background: color-mix(in srgb, var(--accent) 22%, var(--bg-elevated-2, #2c2c2e)) !important;
  opacity: 1 !important;
  border-radius: var(--btn-chip-radius, 10px) !important;
}
body.shell-phone .cart-line-handle,
body.shell-phone [data-cart-drag-handle] {
  touch-action: none;
}
/* crm801: qty/controls must receive taps — never let swipe front steal them. */
body.shell-phone .cart-lines-list .qty-stepper,
body.shell-phone .cart-lines-list .cart-phone-stepper,
body.shell-phone .cart-lines-list .qty-btn,
body.shell-phone .cart-lines-list .uom-row,
body.shell-phone .cart-lines-list .cart-kit-metrics {
  touch-action: manipulation;
}
.cart-table tbody tr.is-crm-drag-armed:not(.is-crm-dragging) td {
  box-shadow: var(--crm-drag-armed-shadow);
  background: color-mix(in srgb, var(--crm-drag-bg, var(--bg-elevated-2)) 92%, var(--accent) 8%);
}
.cart-table tbody tr.is-crm-dragging td {
  box-shadow: var(--crm-drag-shadow);
  background: var(--crm-drag-bg, var(--bg-elevated-2, #2c2c2e));
  transition: none;
}
/* Sheets already translateY / translate(-50%, y) — shadow only, no scale fight. */
.is-crm-sheet-dragging {
  opacity: 0.92;
  box-shadow: var(--crm-drag-shadow);
  z-index: 20;
  cursor: grabbing;
  transition: none;
}
@media (prefers-reduced-motion: reduce) {
  .is-crm-drag-armed:not(.is-crm-dragging),
  .is-crm-dragging,
  body.shell-phone .cart-lines-list > .cart-line.is-crm-drag-armed:not(.is-crm-dragging) .cart-line-front,
  body.shell-phone .cart-lines-list > .cart-line.is-crm-drag-armed:not(.is-crm-dragging):not(.is-swipeable),
  body.shell-phone .cart-lines-list > .cart-line.is-crm-dragging .cart-line-front,
  body.shell-phone .cart-lines-list > .cart-line.is-crm-dragging:not(.is-swipeable) {
    transform: none;
    transition: none;
  }
  .is-crm-sheet-dragging {
    transition: none;
  }
}
/* .is-home-dragging = feature marker (handles stay visible); lift from .is-crm-dragging */
/* Drop placeholder ? inset (never clipped by a block's own overflow:hidden,
   e.g. .home-deals) crisp accent line + soft inward glow reads as a clear
   "it'll land here" ghost slot rather than a thin hairline. */
.home-section.is-home-drop-before {
  box-shadow: inset 0 8px 14px -8px color-mix(in srgb, var(--accent) 65%, transparent),
    inset 0 3px 0 0 var(--accent);
}
.home-section.is-home-drop-after {
  box-shadow: inset 0 -8px 14px -8px color-mix(in srgb, var(--accent) 65%, transparent),
    inset 0 -3px 0 0 var(--accent);
}
.crm-home-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1 1 auto;
  position: relative;
}
.crm-home-panel {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.crm-home-panel .home-widget {
  margin: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 220px;
}
.crm-home-panel .home-widget-body {
  flex: 1 1 auto;
  max-height: none;
}
.home-quick-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.home-quick-grid.is-pc {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.home-quick {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  color: var(--ink);
  border-radius: var(--radius-sm);
  padding: 18px 14px;
  font: inherit;
  cursor: pointer;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 88px;
  transition: background 0.15s var(--ease), border-color 0.15s var(--ease);
}
.home-quick-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 4px;
  border-radius: var(--btn-radius-seg-item);
  background: rgba(10, 132, 255, 0.14);
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 0.15s var(--ease);
}
.home-quick:hover .home-quick-ico {
  transform: scale(1.06);
}
.home-quick strong {
  font-size: 1.02rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
.home-quick span {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: var(--fw-med);
}
.home-quick:hover,
.home-quick:active {
  background: var(--bg-elevated-2);
  border-color: rgba(10, 132, 255, 0.45);
}
.crm-home .home-blocks {
  margin: 0;
  display: grid;
  gap: 10px;
}
.crm-home.is-phone .home-blocks {
  grid-template-columns: 1fr;
}
/* PC: role tiles (e.g. admin Home with no panel) get a 2-col grid instead of
   full-width single-column rows ? matches .home-quick-grid.is-pc density. */
.crm-home.is-pc .home-blocks {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.crm-home.is-phone .home-start-cta:not(.sky-sticky-visit) {
  position: static;
  display: block;
  margin-top: auto;
  width: 100%;
  padding: 16px;
  font-size: 1rem;
  border-radius: var(--btn-radius);
}
body.shell-phone .crm-home.is-phone .home-start-cta.sky-sticky-visit {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 1rem;
  border-radius: var(--btn-radius);
}
@media (min-width: 901px) {
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body{
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.85fr);
    gap: 16px;
    align-items: stretch;
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-panel{
    grid-column: 1;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-blocks,
  body:not(.shell-phone) .crm-home.is-pc .home-quick-grid,
  body:not(.shell-phone) .crm-home.is-pc .home-empty-hint,
  body:not(.shell-phone) .crm-home.is-pc .dash-rail-card{
    grid-column: 2;
  }
  body:not(.shell-phone) .crm-home.is-pc:not(:has(.crm-home-panel)) .crm-home-body{
    grid-template-columns: 1fr;
  }
  body:not(.shell-phone) .crm-home.is-pc:not(:has(.crm-home-panel)) .home-blocks,
  body:not(.shell-phone) .crm-home.is-pc:not(:has(.crm-home-panel)) .home-quick-grid,
  body:not(.shell-phone) .crm-home.is-pc:not(:has(.crm-home-panel)) .dash-rail-card{
    grid-column: 1;
  }
  /* Panel alone (admin Call plan) ? do not leave an empty 0.85fr right column. */
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body:has(> .crm-home-panel):not(:has(> .home-blocks)):not(:has(> .home-quick-grid)):not(:has(> .dash-rail-card)):not(:has(> .home-empty-hint)){
    grid-template-columns: minmax(0, 1fr);
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body:has(> .crm-home-panel):not(:has(> .home-blocks)):not(:has(> .home-quick-grid)):not(:has(> .dash-rail-card)):not(:has(> .home-empty-hint)) .crm-home-panel{
    grid-column: 1 / -1;
  }
}

/* ?? Skynamo mobile Dashboard ? live markup from renderHome() phone branch ?? */
.sky-dash-mobile {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 88px;
}
.sky-dash-stats {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px;
}
.sky-dash-head {
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sky-dash-head .home-greet,
.sky-dash-greet {
  margin: 0;
  font-size: 1.38rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
.sky-dash-head .home-today-line {
  margin: 0 0 2px;
  font-size: 0.88rem;
  line-height: 1.35;
}
.sky-dash-head .home-avatar,
.sky-dash-head .home-avatar-fallback {
  width: 48px;
  height: 48px;
}
.sky-dash-date {
  margin: 0;
  font-size: 1.3rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
.sky-dash-date strong {
  display: block;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}
.sky-dash-date .home-status-line { margin: 6px 0 0; }
.home-status-dot.is-off { background: #888; }
.sky-dash-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}
.sky-dash-metrics > div {
  background: rgba(255,255,255,0.03);
  border-radius: 10px;
  padding: 12px;
}
.sky-dash-metrics em,
.sky-dash-metrics strong {
  display: block;
  font-style: normal;
  font-size: 1.35rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
}
.sky-dash-metrics span {
  display: block;
  margin-top: 4px;
  font-size: 0.78rem;
  color: var(--ink-secondary);
}
.sky-dash-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.sky-dash-sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0 10px;
}
.sky-dash-sec-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
}
.sky-dash-sec-link {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 0.86rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
  padding: 6px 2px;
  flex: 0 0 auto;
}
.sky-dash-sec-link:hover,
.sky-dash-sec-link:active { opacity: 0.8; }
.sky-dash-empty {
  padding: 28px 16px 24px;
  border: 1px dashed var(--line);
  border-radius: var(--radius-sm);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.sky-dash-empty-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-bottom: 4px;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
}
.sky-dash-empty-title {
  margin: 0;
  font-weight: var(--fw-semi);
  font-size: 0.98rem;
  color: var(--ink);
}
.sky-dash-empty .sub {
  margin: 0;
}
.sky-dash-empty .btn.ghost {
  margin-top: 8px;
  width: auto;
  padding: 8px 18px;
}
/* Home phone densify + soft-fail / sticky CTA (Home worker ? .crm-home / .sky-dash / home-* only) */
body.shell-phone .crm-home.is-phone.sky-dash {
  gap: 10px;
}
body.shell-phone .crm-home.is-phone .sky-dash-head {
  margin: 0 0 8px;
  gap: 4px;
}
body.shell-phone .crm-home.is-phone .sky-dash-metrics {
  margin-top: 0;
  gap: 8px;
}
body.shell-phone .crm-home.is-phone .sky-dash-metrics > div {
  padding: 10px;
}
body.shell-phone .crm-home.is-phone .sky-dash-empty {
  padding: 20px 14px 18px;
}
body.shell-phone .crm-home .home-soft-fail {
  margin: 0 0 8px;
  padding: 8px 10px;
  gap: 8px;
}
body.shell-phone .crm-home .home-soft-fail .btn {
  margin-top: 0;
  width: auto;
  min-height: var(--btn-h);
  flex: 0 0 auto;
}
body.shell-phone .crm-home .home-radar-chip,
body.shell-phone .crm-home .home-radar.is-compact .home-radar-chip {
  min-height: var(--btn-h);
  padding: 8px 12px;
}
body.shell-phone .crm-home .home-radar.is-compact .home-radar-row {
  min-height: var(--btn-h);
  padding: 8px 10px;
}
body.shell-phone .crm-home .home-day-start .btn {
  min-height: var(--btn-h);
  margin-top: 0;
}
body.shell-phone .crm-home .home-start-cta.sky-sticky-visit {
  text-transform: none;
  letter-spacing: -0.01em;
  font-weight: var(--fw-semi);
}
body.shell-phone .crm-home .sky-dash-empty .btn.ghost {
  min-height: var(--btn-h);
  margin-top: 8px;
  width: auto;
}
.sky-dash-tl-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.sky-dash-tl-head h2 {
  margin: 0;
  font-size: 1rem;
}
.sky-tl-row {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
}
.sky-tl-ico {
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 4px;
}
.sky-tl-ico svg {
  width: 10px;
  height: 10px;
  display: block;
}
.sky-tl-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.sky-tl-body strong {
  font-size: 0.95rem;
  font-weight: var(--fw-semi);
}
.sky-tl-body span {
  font-size: 0.8rem;
  color: var(--ink-secondary);
}

/* ?? Timeline hub: day-bucket groups + typed activity cards (Wave C) ?? */
.sky-tl-groups {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sky-tl-group-head {
  appearance: none;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 8px 10px;
  min-height: 40px;
  transition: background 0.12s var(--ease);
}
.sky-tl-group-head:hover,
.sky-tl-group-head:focus-visible {
  background: rgba(10, 132, 255, 0.08);
}
.sky-tl-group-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}
.sky-tl-group-count {
  margin-left: auto;
  flex: 0 0 auto;
  font-size: 0.75rem;
  color: var(--muted);
  background: var(--bg-elevated-2);
  border-radius: var(--btn-chip-radius);
  padding: 1px 8px;
}
/* Small caret beside the day label (Skynamo parity) ? not a big standalone circle
 * button on the far right. Whole header stays clickable via .sky-tl-group-head. */
.sky-tl-group-chevron {
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition: transform 0.15s ease, color 0.12s ease;
}
.sky-tl-group-chevron svg {
  width: 13px;
  height: 13px;
  display: block;
}
.sky-tl-group-head:hover .sky-tl-group-chevron,
.sky-tl-group-head:focus-visible .sky-tl-group-chevron {
  color: var(--accent);
}
.sky-tl-group.is-collapsed .sky-tl-group-chevron {
  transform: rotate(-90deg);
}
.sky-tl-group.is-collapsed .sky-tl-group-body {
  display: none;
}
/* Vertical rail through the icon column ? icons paint on top of it (Skynamo parity).
 * left = card padding-left (4px) + time column (70px) + grid gap (10px) + half the
 * icon rail column (30px / 2 = 15px) = 99px. Keep in sync with .sky-tl-card below. */
.sky-tl-group-body {
  position: relative;
}
.sky-tl-group-body::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 99px;
  width: 1px;
  background: var(--line);
}
.sky-tl-card {
  display: grid;
  grid-template-columns: 70px 30px minmax(0, 1fr);
  gap: var(--crm-tl-gap, 10px);
  width: 100%;
  padding: var(--crm-tl-pad-y, 12px) var(--crm-tl-pad-x, 4px);
  border-bottom: 1px solid var(--line);
  text-align: left;
  color: inherit;
  font: inherit;
  border: 0;
  background: transparent;
}
button.sky-tl-card.is-btn,
div.sky-tl-card.is-btn {
  cursor: pointer;
  width: 100%;
  text-align: left;
  font: inherit;
  color: inherit;
}
button.sky-tl-card.is-btn:active,
div.sky-tl-card.is-btn:active {
  background: rgba(255, 255, 255, 0.04);
  transform: scale(0.985);
}
div.sky-tl-card.is-btn:hover {
  background: rgba(255, 255, 255, 0.03);
}
div.sky-tl-card.is-btn:focus-visible {
  outline: 2px solid var(--btn-focus-ring, var(--accent));
  outline-offset: 2px;
}
.sky-tl-group-body .sky-tl-card:last-child {
  border-bottom: 0;
}
/* Left rail: absolute date/time ? Skynamo parity (full stamp, not just "3h ago"). */
.sky-tl-card-time {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  padding-top: 3px;
  overflow: hidden;
}
.sky-tl-card-time-date,
.sky-tl-card-time-clock {
  font-size: 0.64rem;
  line-height: 1.3;
  color: var(--muted);
  white-space: nowrap;
}
.sky-tl-card-time-clock {
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
}
/* Icon rail column ? icon sits centered on top of .sky-tl-group-body's vertical line. */
.sky-tl-card-rail {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex: 0 0 auto;
}
.sky-tl-card-ico {
  position: relative;
  z-index: 1;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: #fff;
  background: #64748b;
}
.sky-tl-card-ico svg {
  display: block;
}
.sky-tl-card-ico.type-comment { background: var(--doc-comment); }
.sky-tl-card-ico.type-task { background: var(--doc-task); }
.sky-tl-card-ico.type-task-done { background: var(--doc-task-done); }
.sky-tl-card-ico.type-form { background: var(--doc-form); }
.sky-tl-card-ico.type-contact { background: var(--doc-contact); }
.sky-tl-card-ico.type-assignment { background: #ec4899; }
.sky-tl-card-ico.type-quote { background: var(--doc-quote); }
.sky-tl-card-ico.type-order { background: var(--doc-order); }
.sky-tl-card-ico.type-invoice { background: var(--doc-invoice); }
.sky-tl-card-ico.type-payment { background: var(--doc-payment); }
.sky-tl-card-ico.type-attendance { background: var(--doc-note); }
.sky-tl-card-ico.type-travel { background: #78716c; }
.sky-tl-card-ico.type-visit { background: var(--doc-visit); }
.sky-tl-card-ico.type-merch { background: var(--doc-merch); }
.sky-tl-card-ico.type-stock { background: var(--doc-stock); }
.sky-tl-card-ico.type-complaint { background: var(--doc-complaint); }
.sky-tl-card-ico.type-credit { background: var(--doc-credit-req); }
.sky-tl-card-ico.type-credit-note { background: var(--doc-credit); }
.sky-tl-card-ico.type-newclient { background: #84cc16; }
.sky-tl-card-ico.type-account { background: #94a3b8; }
.sky-tl-card-ico.type-note { background: var(--doc-note); }
.sky-tl-load-more {
  width: auto;
  margin: 10px auto 4px;
  display: block;
}
.sky-tl-card-main {
  display: flex;
  flex-direction: column;
  gap: var(--crm-tl-main-gap, 3px);
  min-width: 0;
}
.sky-tl-card-row1 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.sky-tl-card-headline {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1 1 auto;
}
.sky-tl-card-trail {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  margin-top: 1px;
}
.sky-tl-card-actions {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.sky-tl-card-title {
  font-size: var(--crm-tl-title, 0.92rem);
  font-weight: var(--fw-semi);
}
.sky-tl-card-title.is-link {
  color: var(--accent);
}
.sky-tl-card.is-doc:hover .sky-tl-card-title.is-link,
.sky-tl-card.is-form:hover .sky-tl-card-title.is-link {
  text-decoration: underline;
  text-underline-offset: 2px;
}
/* Secondary relative stamp ("3h ago") ? abs time on the left rail is primary. */
.sky-tl-card-time-rel {
  flex: 0 0 auto;
  font-size: 0.72rem;
  color: var(--muted);
  white-space: nowrap;
}
/* Option 1: customer is primary clickable line */
.sky-tl-card-cust {
  display: block;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: var(--crm-tl-title, 0.92rem);
  font-weight: var(--fw-semi);
  color: var(--accent);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sky-tl-card-cust:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.sky-tl-card-cust:focus-visible {
  outline: 2px solid var(--btn-focus-ring, var(--accent));
  outline-offset: 2px;
  border-radius: 4px;
}
.sky-tl-card-sub {
  font-size: var(--crm-tl-sub, 0.74rem);
  font-weight: var(--fw-med);
  color: var(--muted);
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sky-tl-card-preview {
  font-size: var(--crm-tl-preview, 0.82rem);
  color: var(--ink-secondary);
  opacity: 0.9;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.crm-density-compact .sky-tl-card-preview {
  display: none;
}
.sky-tl-card-who {
  font-size: 0.72rem;
  color: var(--muted);
}
/* Meta / icon-only trailing actions */
.sky-tl-card-meta {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 4px;
  margin-top: 0;
}
.sky-tl-onsite-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: 0 0 auto;
  background: #10b981;
  box-shadow: 0 0 0 2px color-mix(in srgb, #10b981 25%, transparent);
}
.sky-tl-onsite-dot.is-off {
  background: #94a3b8;
  box-shadow: 0 0 0 2px color-mix(in srgb, #94a3b8 25%, transparent);
}
.sky-tl-photo-thumb {
  display: block;
  margin: 6px 0 2px;
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  overflow: hidden;
  width: min(148px, 42vw);
  height: 96px;
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow, 0 1px 2px rgba(0, 0, 0, 0.08));
}
.sky-tl-photo-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--bg-elevated-2, #f2f2f7);
}
.sky-tl-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  color: var(--muted);
  background: var(--bg-elevated-2);
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  padding: 2px 8px 2px 6px;
  line-height: 1.3;
}
.sky-tl-meta-chip.is-ico-only {
  padding: 4px;
  min-width: 26px;
  min-height: 26px;
  justify-content: center;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  background: var(--btn-ghost-bg, var(--bg-elevated-2));
  border: 1px solid var(--btn-ghost-border, transparent);
  box-shadow: var(--btn-ghost-shadow, none);
  text-decoration: none;
}
.sky-tl-meta-chip.is-ico-only:hover {
  filter: brightness(1.05);
  text-decoration: none;
}
.sky-tl-meta-chip svg {
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  opacity: 0.85;
}
.sky-tl-meta-chip.is-cust {
  color: var(--accent);
  background: rgba(10, 132, 255, 0.1);
  font-weight: var(--fw-med);
}
.sky-tl-meta-chip.is-monday,
.sky-tl-meta-chip.is-file,
.sky-tl-meta-chip.is-link {
  color: var(--accent);
  background: rgba(10, 132, 255, 0.1);
  font-weight: var(--fw-med);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent);
  text-underline-offset: 2px;
  border: 0;
  cursor: pointer;
  font: inherit;
}
.sky-tl-meta-chip.is-ico-only.is-monday,
.sky-tl-meta-chip.is-ico-only.is-file,
.sky-tl-meta-chip.is-ico-only.is-link {
  background: var(--btn-ghost-bg, var(--bg-elevated-2));
  border: 1px solid var(--btn-ghost-border, transparent);
  box-shadow: var(--btn-ghost-shadow, none);
  text-decoration: none;
  color: var(--ink-secondary, var(--muted));
}
.sky-tl-meta-chip.is-ico-only.is-monday:hover,
.sky-tl-meta-chip.is-ico-only.is-file:hover,
.sky-tl-meta-chip.is-ico-only.is-link:hover {
  color: var(--accent);
  text-decoration: none;
}
.sky-tl-meta-chip.is-monday:hover,
.sky-tl-meta-chip.is-file:hover,
.sky-tl-meta-chip.is-link:hover {
  text-decoration-color: var(--accent);
  filter: brightness(1.05);
}
.sky-tl-meta-chip.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
  text-decoration: none;
}
/* Timeline Order/Quote detail sheet */
.crm-tl-doc {
  max-width: min(520px, 94vw);
  max-height: min(88vh, 720px);
  overflow: auto;
}
.crm-tl-doc .sky-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.crm-tl-doc .sky-modal-head h2 {
  margin: 0;
  font-size: 1.05rem;
}
.crm-tl-doc-status {
  margin: 8px 0 4px;
}
.crm-tl-doc-status.is-err {
  color: #f87171;
}
.crm-tl-doc-note {
  margin: 8px 0;
  white-space: pre-wrap;
  word-break: break-word;
}
.crm-tl-doc-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 10px 0 4px;
  max-height: 220px;
  overflow: auto;
}
.crm-tl-doc-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--btn-chip-radius, 12px);
  background: var(--bg-elevated-2);
}
.crm-tl-doc-line-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.crm-tl-doc-line-meta {
  flex: 0 0 auto;
  font-size: 0.82rem;
  color: var(--muted);
  white-space: nowrap;
}
.crm-tl-doc-more {
  margin: 4px 0 0;
}
/* Narrow phones: tighten the abs-time/icon rail columns so the title still has room. */
@media (max-width: 380px) {
  .sky-tl-card {
    grid-template-columns: 56px 26px minmax(0, 1fr);
    gap: 8px;
  }
  .sky-tl-card-time-date,
  .sky-tl-card-time-clock {
    font-size: 0.58rem;
  }
  .sky-tl-card-ico {
    width: 22px;
    height: 22px;
  }
  .sky-tl-group-body::before {
    left: 81px;
  }
}

/* ?? Skynamo customer hub tabs ?? */
.sky-hub-tabs-sticky {
  position: sticky;
  /* Header is outside .app-body scrollport ? stick to the scroller top. */
  top: 0;
  z-index: 15;
  margin: 0 calc(-1 * var(--shell-pad-x, 10px));
  padding: 0 var(--shell-pad-x, 10px);
  /* Solid sticky chrome only ? backdrop-filter here caused Safari noise
     bands across the hub (top strip, bottom strip, right edge bar). */
  background: #0b0b0d;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transform: none;
  will-change: auto;
  border-bottom: 1px solid var(--line);
  box-shadow: none;
}
.sky-hub-tabs {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin: 12px 0 8px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}
.sky-hub-tabs-sticky .sky-hub-tabs {
  margin: 0;
  border-bottom: 0;
}
.sky-hub-tabs::-webkit-scrollbar {
  display: none;
}
/* Customer hub: keep the Details/Timeline/Contacts/? tabs visible while the page scrolls. */
.sky-customer-hub .sky-hub-tabs-sticky {
  margin-top: 8px;
  margin-bottom: 4px;
}
/* Phone: hint that there are more tabs than fit ? fade the trailing edge + leave scroll room */
body.shell-phone .sky-hub-tabs-sticky {
  padding-right: calc(var(--shell-pad-x, 10px) + 12px);
}
body.shell-phone .sky-hub-tabs {
  padding-right: 22px;
  mask-image: linear-gradient(to right, #000 88%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, #000 88%, transparent 100%);
}
.sky-hub-tab {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 14px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
  scroll-snap-align: start;
  border-bottom: 2px solid transparent;
  margin: 0;
  box-sizing: border-box;
  vertical-align: middle;
}
.sky-hub-tab.is-on {
  color: #fff;
  font-weight: var(--fw-semi);
  border-bottom-color: var(--accent);
}
.sky-hub-tab-body {
  padding-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ?? Skynamo customer Overview (PC 3-col) + mobile Details ?? */
.sky-customer-hub {
  width: 100%;
  max-width: none;
  margin: 0;
}
.sky-customer-hub.is-pc {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0 16px 24px;
  box-sizing: border-box;
}
/* PC Details (crm314): overview + location full width; Call plan|Assigned then Tasks|Docs. */
.hub-details-desk {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 16px;
    align-items: start;
    width: 100%;
    max-width: none;
  }
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk > .hub-details-span,
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk > .crm-acct-card.hub-details-span {
    grid-column: 1 / -1;
  }
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk > .crm-acct-card {
    margin: 0;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .sky-customer-hub.is-pc .sky-hub-tab-body {
    width: 100%;
    max-width: none;
  }
  /* Desk panels always show bodies ? never phone accordion chevron-only. */
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk .sky-fold.is-collapsed .sky-fold-body {
    display: block;
  }
  body:not(.shell-phone) .sky-customer-hub.is-pc .hub-details-desk .sky-fold-toggle {
    display: none;
  }
}
.sky-cust-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
  position: relative;
}
/* Default CRM entity bar: title LEFT ? Call/WA ? + FAR RIGHT. */
.crm-entity-head {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-width: 0;
  overflow: visible;
}
.crm-entity-head-icons {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 0;
  flex: 0 0 auto;
  order: 1;
  margin-left: auto;
  overflow: visible;
}
.crm-entity-head-icons .hub-quick-contact.is-header,
.crm-entity-head-add .sky-hub-add-wrap,
.crm-entity-head-icons .sky-hub-add-wrap {
  display: inline-flex;
  flex-shrink: 0;
}
.crm-entity-head-title {
  flex: 0 1 auto;
  min-width: 0;
  order: 0;
  margin: 0 !important;
  padding: 0 4px 0 0;
  text-align: left;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crm-entity-head-add {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  flex: 0 0 auto;
  order: 2;
  overflow: visible;
}
body:not(.shell-phone) .crm-entity-head-title {
  font-size: 1.35rem;
}
.sky-cust-head-pc .sky-cust-pc-name {
  font-size: 1.55rem;
  margin: 0 0 4px;
  font-weight: var(--fw-semi);
  line-height: 1.25;
}
.sky-cust-pc-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex-shrink: 0;
}
.sky-cust-head-m {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 4px;
  overflow: visible;
}
.sky-cust-head-mid {
  flex: 1;
  min-width: 0;
}
.sky-cust-head-mid .hub-title {
  font-size: 1.05rem;
  margin: 0;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sky-cust-head-mid .hub-kicker {
  margin: 0 0 2px;
}
.sky-cust-head-m .hub-quick-contact.is-header,
.sky-cust-pc-tools .hub-quick-contact.is-header {
  display: inline-flex;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
}
.sky-cust-head-m #btnCustPlusMenu {
  flex-shrink: 0;
}
/* iOS Settings-style customer hub inset groups (mirror .settings-list) */
.ios-hub-stack {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}
.ios-hub-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.ios-hub-group-title {
  margin: 0 0 0 14px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 88%, transparent);
}
.ios-hub-group-body {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.35);
}
.ios-hub-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 14px;
  min-height: var(--btn-h);
  box-sizing: border-box;
  position: relative;
}
.ios-hub-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.ios-hub-lab {
  flex: 0 0 auto;
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  line-height: 1.25;
}
.ios-hub-val {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.92rem;
  color: var(--muted);
  text-align: right;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 900px) {
  .ios-hub-val {
    white-space: normal;
    word-break: break-word;
  }
}
body:not(.shell-phone) .sky-customer-hub.is-pc .ios-hub-stack {
  grid-column: 1 / -1;
}
/* Hub Insights product samples + Accounts tab (crm444) */
.hub-insight-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 6px;
  padding: 0 2px 0 14px;
}
.hub-insight-block-head .ios-hub-group-title {
  margin: 0;
}
.hub-insight-count {
  margin: 0;
  padding: 12px 14px 4px;
  font-size: 0.92rem;
  color: var(--muted);
}
.hub-insight-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 14px 14px;
}
.hub-insight-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 64px;
  font-size: 0.62rem;
  color: var(--muted);
  text-align: center;
}
.hub-insight-chip img,
.hub-insight-chip-ph {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.06);
}
.hub-insight-chip-ph {
  display: grid;
  place-items: center;
  font-size: 0.75rem;
}
.ios-hub-action-row {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: flex-start;
  min-height: var(--btn-h);
  padding: 11px 14px;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  text-align: left;
  cursor: pointer;
  box-sizing: border-box;
}
.ios-hub-action-row.ios-hub-action-ico {
  justify-content: center;
  color: var(--ink);
  padding: 12px;
}
.ios-hub-action-row.ios-hub-action-ico svg {
  display: block;
}
.hub-office-note-hint {
  margin: 0;
  padding: 0 14px 12px;
}
.hub-acct-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  margin: 0 0 10px;
}
.hub-acct-toolbar.accounts-pdf-bar {
  margin-top: 0;
}
/* Hub Accounts: PDF bar sits at top of stack (above Outstanding). */
.hub-acct-stack > .accounts-pdf-bar {
  margin: 0 0 12px;
  justify-content: flex-start;
}
.hub-acct-stack > .hub-acct-all-docs {
  margin: 4px 0 12px;
  align-self: flex-start;
}
.hub-acct-pdf-btn:disabled,
.hub-acct-toolbar .hist-pdf-tool:disabled {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}
.ios-hub-balance-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  min-height: var(--btn-h);
}
.ios-hub-balance-row .hub-balance {
  margin: 0;
  font-size: 1.05rem;
  text-align: right;
}
.hub-credit-cue {
  margin: 0 14px;
  font-size: 0.85rem;
  color: color-mix(in srgb, #30d158 80%, var(--muted));
}
.hub-out-list-wrap {
  padding: 0;
}
.hub-out-list-wrap .hub-out-list {
  margin: 0;
}
.pdf-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
/* Customer hub "+" quick actions ? Skynamo-style bottom sheet (same chrome as
   the catalogue category sheet, see .cat-sheet). */
.cust-plus-sheet {
  position: fixed;
  inset: 0;
  z-index: 260;
  pointer-events: none;
}
.cust-plus-sheet.is-open {
  pointer-events: auto;
}
.cust-plus-sheet[hidden] {
  display: none !important;
}
.cust-plus-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px) saturate(130%);
  -webkit-backdrop-filter: blur(8px) saturate(130%);
  cursor: pointer;
}
.cust-plus-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  max-height: min(88dvh, 720px);
  /* Head fixed; grid scrolls; --sheet-nav-clear keeps last option above bottom nav. */
  padding: 12px 14px 0;
  border-radius: var(--sheet-top-radius, 18px) var(--sheet-top-radius, 18px) 0 0;
  border: 1px solid var(--line);
  border-bottom: 0;
  background: rgba(28, 28, 30, 0.98);
  box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.45);
  transform: translateY(108%);
  transition: transform var(--dur-sheet, 0.34s) var(--ease-sheet, var(--ease));
  will-change: transform;
  overflow: hidden;
}
.cust-plus-sheet.is-open .cust-plus-panel {
  transform: translateY(0);
}
.cust-plus-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 0.76rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  flex: 0 0 auto;
}
.cust-plus-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: var(--sheet-nav-clear);
}
.cust-add-sec {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cust-add-sec-more {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.cust-add-sec-label {
  margin: 0 0 2px 4px;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}
.cust-plus-head .btn.small {
  margin: 0;
  /* WAVE2-SHEET-CLOSE-44 ? Close on hub + sheet */
  min-height: 44px;
  min-width: 44px;
  padding: 8px 14px;
  border-radius: var(--btn-chip-radius);
  font-weight: var(--fw-semi);
  box-shadow: var(--btn-ghost-shadow);
}
.cust-plus-grid button,
.cust-hub-add-menu button {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  text-align: left;
  padding: 12px 14px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease),
    box-shadow 0.14s var(--ease), transform 0.12s var(--ease);
}
.cust-plus-grid .hub-act-ico,
.cust-hub-add-menu .hub-act-ico {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: var(--btn-radius-seg-item);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
}
.cust-plus-grid button:hover,
.cust-plus-grid button:focus-visible,
.cust-hub-add-menu button:hover,
.cust-hub-add-menu button:focus-visible {
  border-color: rgba(255, 255, 255, 0.16);
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
}
.cust-plus-grid button:focus-visible,
.cust-hub-add-menu button:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.cust-plus-grid button:active,
.cust-hub-add-menu button:active {
  transform: scale(0.98);
}
.cust-hub-add-menu {
  min-width: 280px;
  max-height: min(70vh, 520px);
  overflow: auto;
  padding: 8px;
  gap: 8px;
}
.cust-email-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
}
.cust-email-chips {
  margin-bottom: 0;
  flex-shrink: 0;
  min-height: min-content;
  height: auto;
  overflow: visible;
}
.cust-email-body > .admin-opt-sec,
.cust-email-body > .cust-email-send,
.cust-email-body > .field-hint {
  flex-shrink: 0;
}
.cust-email-chips .admin-opt-row .admin-opt-sub.cust-email-addr {
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: var(--fw-reg);
}
.cust-email-chips .admin-opt-row.is-current .admin-opt-sub.cust-email-addr {
  color: rgba(255, 255, 255, 0.78);
}
.cust-email-panel {
  max-height: min(88dvh, 760px);
}
.cust-email-menu {
  min-height: 0;
  overflow-y: auto;
  padding-bottom: var(--sheet-nav-clear, 8px);
}
.cust-email-fields {
  overflow: visible;
}
.cust-email-field {
  align-items: stretch;
  flex-direction: column;
  gap: 7px;
}
.cust-email-field .field {
  width: 100%;
  margin: 0;
}
.cust-email-send {
  width: 100%;
  flex: 0 0 auto;
}
.sky-ov-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(280px, 1.35fr) minmax(240px, 1fr);
  gap: 12px;
  align-items: start;
  width: 100%;
}
.sky-ov-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.sky-ov-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.sky-ov-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
}
.sky-ov-card h2 {
  margin: 0;
  font-size: 0.98rem;
  font-weight: var(--fw-semi);
}
.sky-ov-add {
  min-height: 32px;
  padding: 4px 12px;
  font-size: 0.82rem;
}
.sky-ov-comment {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 8px 0 12px;
}
.sky-ov-comment select,
.sky-ov-comment textarea {
  width: 100%;
  box-sizing: border-box;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.25);
  color: var(--ink);
  padding: 8px 10px;
  font: inherit;
}
.sky-ov-comment textarea {
  resize: vertical;
  min-height: 72px;
}
.sky-ov-quick {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.sky-ov-fields {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}
.sky-ov-fields label {
  display: grid;
  gap: 4px;
  font-size: 0.78rem;
  color: var(--ink-secondary);
}
.sky-ov-fields input {
  width: 100%;
  box-sizing: border-box;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
  color: var(--ink);
  padding: 8px 10px;
  font: inherit;
  font-size: 0.92rem;
}
.sky-ov-fields input.owe {
  color: #ff9f0a;
}
.sky-ov-fields input.credit {
  color: #30d158;
}
.sky-m-add-comment {
  width: 100%;
  min-height: 44px;
  border-style: dashed;
  letter-spacing: 0.02em;
  font-weight: var(--fw-semi);
}
.sky-m-section {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
}
.sky-m-section .hub-panel-head {
  margin-bottom: 6px;
}
.sky-m-section h2 {
  margin: 0;
  font-size: 1.05rem;
}
.sky-m-empty {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.92rem;
}
.sky-m-illu {
  text-align: center;
  font-size: 2rem;
  opacity: 0.55;
  margin: 8px 0 12px;
}
.sky-m-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}
.sky-m-duo .btn {
  min-height: 40px;
  font-size: 0.78rem;
  padding: 8px 6px;
}
.sky-m-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.sky-m-start-visit {
  width: 100%;
  min-height: 48px;
  margin-top: 4px;
  position: sticky;
  bottom: calc(var(--bottom-nav-h, 56px) + env(safe-area-inset-bottom, 0px));
  z-index: 5;
}
.sky-m-chev {
  color: var(--ink-secondary);
  font-size: 0.85rem;
}
@media (max-width: 1100px) {
  .sky-ov-grid {
    grid-template-columns: 1fr 1.2fr;
  }
  .sky-ov-grid .sky-ov-col:last-child {
    grid-column: 1 / -1;
  }
}
@media (max-width: 900px) {
  .sky-ov-grid,
  .sky-ov-grid-2 {
    grid-template-columns: 1fr;
  }
}
body.shell-phone .store-hub {
  display: block;
}
body.shell-phone .store-main.card {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

.sky-near-me .near-me-row .sky-cust-meta {
  grid-column: 1 / -1;
  font-size: 0.8rem;
  color: var(--ink-secondary);
}
@media (min-width: 901px) {
  /* PC Near me keeps address in the meta column (not full-width wrap). */
  body:not(.shell-phone) .sky-near-me .near-me-row .sky-cust-meta,
  body:not(.shell-phone) .sky-customers-near .near-me-row .sky-cust-meta {
    grid-column: auto;
  }
}
/* Shop FAB removed ? every product card has Add; Quote dock opens cart.
   Keep rule so any stale markup never overlaps card CTAs. */
.sky-fabs-shop {
  display: none !important;
}

/* ?? Skynamo PC Dashboard (dark ieGlobal) ?? */
.sky-dashboard-pc {
  max-width: none;
  width: 100%;
  padding: 0;
}
.sky-dash-pc {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 0;
  min-height: calc(100vh - 72px);
  margin: 0 -8px;
}
.sky-dash-rail {
  background: var(--bg-elevated);
  border-right: 1px solid var(--line);
  padding: 16px 12px 24px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.sky-dash-rail-group {
  margin: 14px 8px 6px;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-secondary);
}
.sky-dash-rail-group:first-child { margin-top: 4px; }
.sky-dash-rail-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  padding: 9px 12px;
  border-radius: 10px;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.sky-dash-rail-btn:hover { background: rgba(255,255,255,0.05); }
.sky-dash-rail-btn.is-on {
  background: rgba(10, 132, 255, 0.22);
  color: #fff;
  font-weight: var(--fw-semi);
}
.sky-beta {
  font-style: normal;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  color: #fff;
  background: var(--accent);
  border-radius: var(--btn-chip-radius);
  padding: 2px 7px;
}
.sky-dash-rail-foot {
  margin-top: auto;
  padding: 16px 8px 0;
  font-size: 0.72rem;
  color: var(--ink-secondary);
}
.sky-dash-main {
  padding: 20px 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  background: var(--bg);
}
.sky-dash-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
}
.sky-dash-toolbar h1 {
  margin: 0;
  font-size: 1.75rem;
  letter-spacing: -0.03em;
}
.sky-dash-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.sky-date-btn {
  appearance: none;
  border: 1px solid rgba(10, 132, 255, 0.55);
  background: rgba(10, 132, 255, 0.1);
  color: #fff;
  border-radius: 10px;
  padding: 8px 12px;
  font: inherit;
  font-size: 0.88rem;
  cursor: pointer;
  display: inline-flex;
  gap: 8px;
  align-items: center;
}
.sky-date-btn span { color: var(--accent); font-weight: var(--fw-semi); }
.sky-select select {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  color: var(--ink);
  border-radius: 10px;
  padding: 8px 28px 8px 12px;
  font: inherit;
  font-size: 0.88rem;
  min-width: 120px;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-secondary) 50%),
    linear-gradient(135deg, var(--ink-secondary) 50%, transparent 50%);
  background-position: calc(100% - 14px) 50%, calc(100% - 9px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.sky-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.sky-kpi-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  min-height: 96px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.sky-kpi-top {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-secondary);
  font-size: 0.85rem;
}
.sky-kpi-ico { display: grid; place-items: center; color: var(--ink); }
.sky-kpi-val {
  font-size: 1.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  margin-top: 10px;
}
.sky-dash-mid {
  display: grid;
  grid-template-columns: minmax(220px, 320px) minmax(0, 1fr);
  gap: 12px;
}
.sky-dash-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  min-height: 220px;
}
.sky-dash-panel.sky-dash-wide { min-height: 160px; }
.sky-dash-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.sky-dash-panel-head h2 {
  margin: 0;
  font-size: 1rem;
  font-weight: var(--fw-semi);
}
.sky-donut-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 8px 0 4px;
}
.sky-donut {
  width: 148px;
  height: 148px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.sky-donut > span {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: var(--bg-elevated);
}
.sky-donut-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--ink-secondary);
  width: 100%;
}
.sky-donut-legend i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  margin-right: 8px;
}
.sky-donut-legend i.in { background: var(--accent); }
.sky-donut-legend i.out { background: #2a4a6e; }
.sky-empty-chart {
  min-height: 140px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--ink-secondary);
  background:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 18px,
      rgba(255,255,255,0.03) 18px,
      rgba(255,255,255,0.03) 36px
    );
  border-radius: 8px;
}
.sky-empty-chart p { margin: 0; }
.sky-empty-chart .btn {
  margin-top: 10px;
  width: auto;
  padding: 8px 18px;
}
/* Quiet variant ? flat (no diagonal chart stripes) with a small muted icon,
   used where the "empty chart placeholder" look reads wrong (e.g. a plain
   to-do list with nothing on it). */
.sky-empty-chart.sky-empty-quiet {
  background: none;
}
.sky-empty-ico {
  display: inline-flex;
  color: var(--muted);
  opacity: 0.5;
  margin-bottom: 6px;
}
.sky-empty-ico svg {
  width: 26px;
  height: 26px;
}
.sky-empty { color: var(--ink-secondary); margin: 24px 0; text-align: center; }
.sky-dash-visit-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.sky-dash-visit-row {
  appearance: none;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
  padding: 10px 4px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font: inherit;
}
.sky-dash-visit-row:hover { background: rgba(255,255,255,0.03); }
.sky-dash-visit-row span {
  font-size: 0.8rem;
  color: var(--ink-secondary);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
@media (max-width: 1100px) {
  .sky-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sky-dash-mid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .sky-dash-pc { grid-template-columns: 1fr; }
  .sky-dash-rail { display: none; }
}

/* ===== MOBILE-FIRST: body.shell-phone overrides (field CRM) ===== */
body.shell-phone .side-nav,
body.shell-phone .app-shell.has-side .side-nav {
  display: none !important;
}
body.shell-phone .app-shell.has-side .app-body {
  grid-template-columns: 1fr !important;
}
body.shell-phone .sky-page-head h1,
body.shell-phone .crm-home-head h1,
body.shell-phone .acal-page-title,
body.shell-phone .settings-head-txt h1,
body.shell-phone .admin-card > .admin-top h1,
body.shell-phone .shop-sky-title h1 {
  display: none !important;
}
/* Keep .hub-kicker visible on phone ? Details tab field/section labels (Account, Location, hub-kv-list companions). */
body.shell-phone .sky-page-head {
  padding: 0 0 8px;
  gap: 10px;
}
body.shell-phone .sky-page-search {
  flex: 1 1 100%;
  max-width: none;
  margin: 0;
}
body.shell-phone .sky-page-search input {
  min-height: 44px;
  font-size: 1rem;
}
body.shell-phone .sky-hub-body {
  grid-template-columns: minmax(0, 1fr) !important;
}
/* Full-height results list on phone ? page scrolls, not a cramped inner box */
body.shell-phone .results {
  max-height: none;
  overflow: visible;
}
body.shell-phone .sky-phone-seg {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 2px 0 10px;
  scrollbar-width: none;
}
body.shell-phone .sky-phone-seg::-webkit-scrollbar { display: none; }
.sky-phone-seg-btn {
  appearance: none;
  flex: 0 0 auto;
  border: 1px solid var(--btn-ghost-border, var(--line-strong));
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius);
  padding: 8px 14px;
  min-height: var(--btn-h-sm);
  font: inherit;
  font-size: 0.82rem;
  font-weight: var(--fw-semi);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: var(--btn-ghost-shadow);
  transition: background 0.14s var(--ease), border-color 0.14s var(--ease), color 0.14s var(--ease),
    box-shadow 0.14s var(--ease);
}
.sky-phone-seg-btn.is-on {
  border-color: transparent;
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
body.shell-phone .settings-panel .settings-phone-nav {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 0;
  overflow: hidden;
  margin: 6px 0 0;
  padding: 3px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
body.shell-phone .settings-panel .settings-phone-nav::-webkit-scrollbar { display: none; }
body.shell-phone .settings-panel .settings-phone-nav .settings-phone-seg-btn {
  appearance: none;
  flex: 1 1 0;
  min-width: 0;
  border: 0;
  margin: 0;
  padding: 0 10px;
  min-height: calc(var(--btn-h) - 6px);
  height: calc(var(--btn-h) - 6px);
  border-radius: var(--btn-radius-seg-item);
  background: transparent;
  color: #ebebf5;
  font: inherit;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
body.shell-phone .settings-panel .settings-phone-nav .settings-phone-seg-btn:hover {
  color: #fff;
}
body.shell-phone .settings-panel .settings-phone-nav .settings-phone-seg-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
body.shell-phone .settings-panel .settings-phone-nav .settings-phone-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: transparent;
}
body.shell-phone .settings-panel .settings-head {
  gap: 6px;
  margin-bottom: 0;
}
/* Quiet category label for Forms / Role access only (Preferences has no in-page kicker) */
body.shell-phone .settings-panel .settings-cat-kicker {
  display: block;
  margin: 0;
  opacity: 0.72;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
}
body.shell-phone .settings-panel .settings-head-blurb {
  font-size: 0.8rem;
  margin-top: 2px;
  opacity: 0.85;
}
body.shell-phone .settings-panel.settings-page {
  padding: 8px 12px 28px;
}
body.shell-phone .settings-panel.catalogues-page {
  padding: 8px 12px 28px;
}
body.shell-phone .cat-hub-search-row {
  margin: 0 0 8px;
}
body.shell-phone .cat-hub-grid {
  gap: 10px;
}
body.shell-phone .cat-hub-card {
  padding: 8px;
}
body.shell-phone .cat-hub-card-acts .btn {
  font-size: var(--btn-fs-sm, 0.8rem);
}
body.shell-phone .settings-panel .settings-stack {
  gap: 18px;
  margin-top: 8px;
}
body.shell-phone .settings-panel .settings-section {
  gap: 5px;
}
body.shell-phone .settings-panel .settings-section-label {
  margin: 0 0 0 14px;
  font-size: 0.65rem;
  letter-spacing: 0.06em;
}
body.shell-phone .settings-panel .settings-list {
  border-radius: var(--radius-sm);
}
body.shell-phone .settings-panel .settings-row {
  padding: 10px 14px;
  min-height: var(--btn-h);
  gap: 12px;
}
body.shell-phone .settings-panel .settings-list > .settings-empty,
body.shell-phone .settings-panel .settings-list > .sub.settings-empty {
  padding: 14px;
  margin: 0;
  text-align: left;
}
body.shell-phone .settings-panel .settings-row.is-control .settings-row-trail {
  width: auto;
  justify-content: flex-end;
  margin: 0 0 0 4px;
  padding-left: 0;
}
body.shell-phone .settings-panel .settings-row.is-control[data-settings-id="cats_open"] .settings-row-trail,
body.shell-phone .settings-panel .settings-row.is-control[data-settings-id="security"] .settings-row-trail {
  width: auto;
  margin: 0 0 0 4px;
  padding-left: 0;
  justify-content: flex-end;
}
/* Profile: single iOS row ? avatar + title; Remove text + chevron trail (not full-width primary) */
body.shell-phone .settings-panel .settings-row.is-control.settings-profile-row {
  flex-wrap: nowrap;
  align-items: center;
  padding: 10px 12px 10px 14px;
  gap: 12px;
  min-height: var(--btn-h);
}
body.shell-phone .settings-panel .settings-profile-row .settings-row-main {
  flex: 1 1 0;
  min-width: 0;
}
body.shell-phone .settings-panel .settings-profile-row .settings-row-trail {
  flex: 0 0 auto;
  width: auto;
  max-width: none;
  margin: 0;
  padding-left: 0;
  justify-content: flex-end;
}
body.shell-phone .settings-panel .settings-profile-actions {
  width: auto;
  flex-wrap: nowrap;
  justify-content: flex-end;
  gap: 2px;
}
body.shell-phone .settings-panel .settings-profile-change {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  margin: 0;
  padding: 0 2px 0 4px;
  border: 0;
  border-radius: var(--btn-radius-seg-item);
  background: transparent;
  color: var(--ink-secondary);
  cursor: pointer;
  font: inherit;
}
body.shell-phone .settings-panel .settings-profile-change:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
body.shell-phone .settings-panel .settings-profile-change:disabled {
  opacity: var(--btn-disabled-opacity);
  cursor: not-allowed;
  color: var(--btn-disabled-fg);
}
body.shell-phone .settings-panel .settings-profile-change .settings-row-chev {
  opacity: 0.55;
}
body.shell-phone .settings-panel .settings-profile-change-lab:empty {
  display: none;
}
body.shell-phone .settings-panel .settings-profile-hero {
  flex-wrap: wrap;
  padding: 14px 14px 12px;
  gap: 12px;
  min-height: 0;
}
body.shell-phone .settings-panel .settings-profile-hero-avatar,
body.shell-phone .settings-panel .settings-profile-hero .settings-profile-avatar {
  width: 56px;
  height: 56px;
}
body.shell-phone .settings-panel .settings-profile-hero .settings-row-trail {
  width: 100%;
  margin: 4px 0 0;
  justify-content: flex-start;
}
body.shell-phone .settings-panel .settings-row-btn {
  min-height: var(--btn-h);
  padding: 0 16px;
}
body.shell-phone .settings-passkey-row .passkey-revoke-mine {
  min-height: var(--btn-h);
}
/* Segmented + toggle controls ? bump to a real tap target without changing
 * their compact look. */
body.shell-phone .settings-seg {
  border-radius: var(--btn-radius-seg);
  padding: 3px;
  align-items: stretch;
  min-height: var(--btn-h);
  box-sizing: border-box;
}
body.shell-phone .settings-seg-btn {
  min-height: calc(var(--btn-h) - 6px);
  height: calc(var(--btn-h) - 6px);
  padding: 0 16px;
  border-radius: var(--btn-radius-seg-item);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}
body.shell-phone .settings-toggle-ui {
  width: 50px;
  height: 32px;
}
body.shell-phone .settings-toggle-ui::after {
  width: 26px;
  height: 26px;
}
body.shell-phone .settings-toggle input:checked + .settings-toggle-ui::after {
  transform: translateX(18px);
}
/* Role access: settings-row groups on phone */
body.shell-phone .settings-role-group {
  padding: 0;
}
body.shell-phone .settings-role-head {
  margin: 0;
}
body.shell-phone .settings-role-opts .settings-role-opt {
  min-height: var(--btn-h);
}
body.shell-phone .settings-role-actions {
  margin-top: 8px;
}
body.shell-phone .settings-role-actions .btn {
  min-height: var(--btn-h);
  flex: 1 1 auto;
}
/* Legacy settings-check (forms editor elsewhere) ? keep tap targets */
body.shell-phone .settings-check-grid {
  grid-template-columns: 1fr;
  gap: 2px;
}
body.shell-phone .settings-check {
  padding: 10px 4px;
  min-height: 40px;
  gap: 12px;
}
body.shell-phone .settings-check input {
  width: 22px;
  height: 22px;
  margin-top: 0;
  flex: none;
}
body.shell-phone .info-row {
  grid-template-columns: 1fr;
  gap: 2px;
}
body.shell-phone .hdr-icon-btn {
  width: 44px;
  height: 44px;
}
/* Admin Users face grid reserves one full 44px touch target per action. */
body.shell-phone .admin-user-head .admin-user-more,
body.shell-phone .admin-user-head .admin-user-face-act {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
}
body.shell-phone .admin-user-head .admin-user-more svg,
body.shell-phone .admin-user-head .admin-user-face-act svg {
  width: 16px;
  height: 16px;
}
body.shell-phone .acal-icon-btn {
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
}
body.shell-phone .acal-icon-btn svg {
  width: 18px;
  height: 18px;
}
body.shell-phone .acal-today-btn {
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 12px;
  font-size: 0.8rem;
  border-radius: var(--btn-radius-seg-item, 10px);
}
body.shell-phone .acal-seg-btn {
  min-height: var(--btn-h);
  padding: 6px 10px;
}
/* Phone seg active — shared light-blue --btn-seg-on (crm854). */
body.shell-phone .acal-seg {
  background: var(--btn-seg-track, rgba(255, 255, 255, 0.05));
  border-radius: var(--btn-radius-seg);
  padding: 3px;
  width: 100%;
}
body.shell-phone .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-radius: var(--btn-radius-seg-item);
}
body.shell-phone .acal-add-btn {
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 12px;
  width: auto !important;
  min-width: 3rem;
  overflow: visible;
  border-radius: var(--btn-radius-seg-item, 10px);
  font-size: 0.84rem !important;
}
body.shell-phone .acal-toolbar-phone {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 2px 4px 6px;
  background: transparent;
  border-bottom: 0;
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-width: 0;
  padding: 0 2px;
}
body.shell-phone .acal-toolbar-phone-top .acal-today-btn {
  flex: 0 0 auto;
  align-self: center;
  min-height: 44px;
  padding: 0 4px;
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-med, 500);
  letter-spacing: -0.01em;
  color: var(--accent);
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: var(--btn-chip-radius, 12px);
}
body.shell-phone .acal-toolbar-phone-top .acal-today-btn:active {
  background: rgba(10, 132, 255, 0.12);
}
body.shell-phone .acal-period-nav {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: 0;
  flex: 1 1 auto;
  min-width: 0;
  max-width: min(72%, 16rem);
}
body.shell-phone .acal-period-nav .acal-period {
  flex: 0 1 auto;
  margin: 0;
  padding: 0 2px;
  text-align: center;
  font-size: 1.05rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  max-width: 100%;
}
body.shell-phone .acal-period-nav .acal-period-chev {
  flex: 0 0 auto;
  width: 40px;
  height: 44px;
  min-width: 40px;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: var(--accent);
  border-radius: var(--btn-chip-radius, 12px);
}
body.shell-phone .acal-period-nav .acal-period-chev:active {
  background: rgba(10, 132, 255, 0.12) !important;
}
body.shell-phone .acal-period-nav .acal-period-chev svg {
  width: 18px;
  height: 18px;
  pointer-events: none;
}
body.shell-phone .acal-toolbar-phone .acal-count {
  display: none;
}
body.shell-phone .acal-toolbar-phone .acal-add-btn {
  flex: 0 0 auto;
  width: auto !important;
  min-width: 3rem;
  padding: 0 11px !important;
  font-size: 0.82rem !important;
  line-height: 1.1;
  white-space: nowrap;
  overflow: visible;
  text-overflow: clip;
}
/* Phone tools: full-width search | filter | + (Customers `.sky-cust-tools` parity). */
body.shell-phone .acal-toolbar-phone-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  flex: 1 0 100%;
  min-width: 0;
  max-width: none;
  justify-content: flex-start;
}
body.shell-phone .acal-toolbar-phone-title {
  flex: 1 1 auto;
  max-width: none;
}
body.shell-phone .acal-search-inline {
  flex: 1 1 auto;
  min-width: 0;
  max-width: none;
}
body.shell-phone .acal-search-input-inline {
  width: 100%;
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 10px;
  border-radius: var(--btn-chip-radius, 12px);
  border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.12));
  background: var(--btn-ghost-bg, rgba(255, 255, 255, 0.06));
  color: var(--ink);
  font-size: 0.82rem;
  outline: none;
  box-sizing: border-box;
}
body.shell-phone .acal-search-input-inline:focus {
  border-color: rgba(10, 132, 255, 0.45);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.18);
}
body.shell-phone .acal-filter-icon-btn,
body.shell-phone .acal-add-icon-btn {
  flex: 0 0 auto;
  position: relative;
}
body.shell-phone .acal-filter-icon-btn .acal-phone-filters-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 14px;
  height: 14px;
  padding: 0 3px;
  font-size: 0.58rem;
  line-height: 14px;
  border-radius: var(--btn-chip-radius);
  background: var(--accent);
  color: #fff;
  text-align: center;
}
body.shell-phone .acal-add-icon-btn {
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1;
}
.acal-schedule-note {
  margin: 0 0 8px;
}
.acal-schedule-who {
  margin: 0 0 12px;
}
.acal-schedule-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.acal-schedule-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}
.acal-schedule-field input[type="date"] {
  min-height: var(--btn-h);
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  padding: 0 12px;
}
/* Sync + Filters: legacy second-row (unused when tools cluster is present). */
body.shell-phone .acal-toolbar-phone-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  flex: 1 0 100%;
  order: 5;
  padding: 0 0 2px;
}
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip {
  flex: 1 1 auto;
  min-width: 5.5rem;
  max-width: none;
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 14px;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  line-height: 1.15;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
  border-color: var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink-secondary);
}
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip.is-stale {
  border-color: rgba(255, 159, 10, 0.2);
  color: rgba(235, 200, 120, 0.88);
  background: rgba(255, 159, 10, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip.is-fresh {
  border-color: rgba(48, 209, 88, 0.24);
  color: rgba(48, 209, 88, 0.9);
  background: rgba(48, 209, 88, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip.is-syncing {
  border-color: rgba(10, 132, 255, 0.28);
  color: var(--accent);
  background: rgba(10, 132, 255, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip.is-error {
  border-color: rgba(255, 69, 58, 0.28);
  color: #ff453a;
  background: rgba(255, 69, 58, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone-actions .acal-phone-filters-btn {
  flex: 0 0 auto;
  min-height: var(--btn-h);
  height: var(--btn-h);
  min-width: 5.5rem;
  padding: 0 14px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  border-color: var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink-secondary);
}
body.shell-phone .acal-toolbar-phone-actions .acal-phone-filters-btn:active {
  background: rgba(255, 255, 255, 0.08);
}
/* Legacy in-toolbar Sync (PC / older markup) ? keep tap floor. */
body.shell-phone .acal-toolbar-phone .acal-cpt-chip {
  flex: 0 0 auto;
  box-sizing: border-box;
  padding: 0 12px;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  max-width: none;
  min-height: var(--btn-h);
  height: var(--btn-h);
  line-height: 1.15;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  overflow: visible;
  text-overflow: clip;
  border-color: var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  color: var(--ink-secondary);
}
body.shell-phone .acal-toolbar-phone .acal-cpt-chip.is-stale {
  border-color: rgba(255, 159, 10, 0.2);
  color: rgba(235, 200, 120, 0.88);
  background: rgba(255, 159, 10, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone .acal-cpt-chip.is-fresh {
  border-color: rgba(48, 209, 88, 0.24);
  color: rgba(48, 209, 88, 0.9);
  background: rgba(48, 209, 88, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone .acal-cpt-chip.is-syncing {
  border-color: rgba(10, 132, 255, 0.28);
  color: var(--accent);
  background: rgba(10, 132, 255, 0.05);
  box-shadow: none;
}
body.shell-phone .acal-toolbar-phone .acal-cpt-chip.is-error {
  border-color: rgba(255, 69, 58, 0.28);
  color: #ff453a;
  background: rgba(255, 69, 58, 0.05);
  box-shadow: none;
}

/* Deliveries (driver_route) ? same Apple toolbar language as Calendar (not ops densify crush). */
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone {
  row-gap: 8px;
  column-gap: 6px;
  padding: 6px 2px 4px;
}
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone-title {
  gap: 6px;
}
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone .acal-period {
  font-size: 0.9rem;
}
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone .acal-count {
  font-size: 0.68rem;
}
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone-combo {
  padding: 0 2px 8px;
}
body.shell-phone .acal[data-acal-kind="driver_route"] .acal-toolbar-phone .acal-add-btn {
  padding: 0 11px !important;
  font-size: 0.82rem !important;
}
/* Phone To-do + Calendar agenda: denser visit/stop cards, no clipped titles. */
body.shell-phone .acal.is-todo-simple .sky-agenda,
body.shell-phone .acal[data-acal-kind="driver_route"] .sky-agenda,
body.shell-phone .acal[data-acal-kind="my_day"] .sky-agenda {
  padding: 4px 8px 16px;
}
body.shell-phone .acal.is-todo-simple .sky-card,
body.shell-phone .acal[data-acal-kind="driver_route"] .sky-card,
body.shell-phone .acal[data-acal-kind="my_day"] .sky-card {
  padding: 8px 8px 8px 6px;
  gap: 6px;
}
body.shell-phone .acal.is-todo-simple .sky-card-title,
body.shell-phone .acal[data-acal-kind="driver_route"] .sky-card-title,
body.shell-phone .acal[data-acal-kind="my_day"] .sky-card-title {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 0.9rem;
  line-height: 1.25;
}
body.shell-phone .acal.is-todo-simple .sky-card-act,
body.shell-phone .acal[data-acal-kind="driver_route"] .sky-card-act,
body.shell-phone .acal[data-acal-kind="my_day"] .sky-card-act {
  min-height: var(--btn-h);
  padding: 0 12px;
  font-size: 0.8rem;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
body.shell-phone .acal-toolbar-phone .acal-phone-filters-btn {
  flex: 0 0 auto;
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 12px;
  border-radius: var(--btn-radius-seg-item, 10px);
  font-size: 0.78rem;
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink-secondary);
}
body.shell-phone .acal-toolbar-phone .acal-phone-filters-btn:active {
  background: rgba(255, 255, 255, 0.08);
}
body.shell-phone .acal-toolbar-phone-seg {
  display: flex;
  width: 100%;
}
body.shell-phone .acal-toolbar-phone-combo {
  padding: 2px 2px 10px;
}
body.shell-phone .acal-toolbar-phone-combo .acal-toolbar-phone-seg {
  padding: 0;
  width: 100%;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg {
  display: flex;
  width: 100%;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg-btn {
  flex: 1;
  text-align: center;
  padding: 7px 6px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  white-space: nowrap;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  border-radius: var(--btn-radius-seg-item, 10px);
  min-height: var(--btn-h);
}
/* Restore selected blue — more-specific transparent above wins over .acal-seg-btn.is-on (crm855). */
body.shell-phone .acal-toolbar-phone-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
/* Kind seg (My day | Deliveries) ? premium, equal columns, no clip. */
body.shell-phone .acal-toolbar-phone-kind .acal-kind-seg .acal-seg-btn {
  font-size: 0.82rem;
  padding: 8px 10px;
}
body.shell-phone .acal-quick-row .acal-people-chip {
  min-height: var(--btn-h);
  padding: 8px 14px;
  font-size: 0.78rem;
  border-radius: var(--btn-chip-radius);
}

/* Premium phone task actions ? equal-height squircles, no browser chrome. */
body.shell-phone .sky-card-list {
  gap: 8px;
}
body.shell-phone .sky-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(28, 28, 30, 0.92);
  box-shadow: inset 3px 0 0 var(--acal-c, var(--accent));
  overflow: hidden;
}
body.shell-phone .sky-card-list .sky-card:last-child {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
body.shell-phone .sky-card.is-selected {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
  color: #fff;
}
body.shell-phone .sky-card.is-selected .sky-card-title,
body.shell-phone .sky-card.is-selected .sky-card-due,
body.shell-phone .sky-card.is-selected .sky-card-meta,
body.shell-phone .sky-card.is-selected .sky-card-sub {
  color: #fff;
}
body.shell-phone .sky-card.is-selected .sky-card-ico {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}
body.shell-phone .sky-card.is-late {
  box-shadow: inset 3px 0 0 rgba(255, 69, 58, 0.72);
  border-color: rgba(255, 69, 58, 0.18);
  background: rgba(255, 69, 58, 0.05);
}
body.shell-phone .sky-card.is-late .sky-card-title {
  color: var(--ink);
}
body.shell-phone .sky-card.is-late .sky-card-due.is-late {
  color: rgba(255, 105, 97, 0.92);
  font-weight: var(--fw-semi);
}
body.shell-phone .sky-card.is-late .sky-card-ico {
  color: rgba(255, 105, 97, 0.95);
  background: rgba(255, 69, 58, 0.12);
}
body.shell-phone .sky-card-title {
  color: #fff;
}
body.shell-phone .sky-card-main {
  padding: 12px 12px 10px 14px;
}
body.shell-phone .sky-card-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  border-top: 0;
  padding: 0 10px 10px;
  background: transparent;
}
body.shell-phone .card .acal button.sky-card-act,
body.shell-phone .sky-card-act {
  appearance: none;
  -webkit-appearance: none;
  border: 0 !important;
  border-right: 0 !important;
  min-height: 42px;
  height: 42px;
  min-width: 42px;
  width: 42px;
  padding: 0;
  border-radius: 11px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  line-height: 1;
  display: inline-grid;
  place-items: center;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, 0 2px 8px rgba(0, 0, 0, 0.28);
  transition: transform 0.12s ease, filter 0.12s ease, background 0.12s ease;
}
body.shell-phone .sky-card-act svg {
  display: block;
}
body.shell-phone .sky-card-act:active {
  transform: scale(0.97);
  filter: brightness(1.06);
}
body.shell-phone .sky-card-act.is-open,
body.shell-phone .sky-card-act.is-visit {
  background: rgba(255, 255, 255, 0.09);
  color: #f2f2f7;
}
body.shell-phone .sky-card-act.is-open:hover,
body.shell-phone .sky-card-act.is-visit:hover {
  background: rgba(255, 255, 255, 0.14);
}
body.shell-phone .sky-card-act.is-done {
  background: #30d158;
  color: #06240f;
  font-weight: var(--fw-strong);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.22) inset, 0 3px 10px rgba(48, 209, 88, 0.28);
}
body.shell-phone .sky-card-act.is-done:hover {
  background: #34d65c;
  filter: none;
}
body.shell-phone .sky-card-act.is-done.is-locked {
  background: rgba(48, 209, 88, 0.28);
  color: rgba(6, 36, 15, 0.55);
  box-shadow: none;
  cursor: not-allowed;
}
body.shell-phone .sky-card-act.is-done.is-locked:hover,
body.shell-phone .sky-card-act.is-done.is-locked:active {
  background: rgba(48, 209, 88, 0.28);
  filter: none;
  transform: none;
}
body.shell-phone .sky-agenda-overdue-toggle {
  min-height: 48px;
}
body.shell-phone .acal.is-phone .sky-desk-main {
  padding: 0 2px 12px;
}
body.shell-phone .home-kpi-strip-phone {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
body.shell-phone .home-kpi {
  min-height: 72px;
  padding: 12px 8px;
}
body.shell-phone .home-quick {
  min-height: 64px;
  text-align: left;
  padding: 12px 14px;
}
body.shell-phone .admin-driver-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.admin-driver-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}
.admin-driver-card {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm, 12px);
  background: var(--bg-elevated-2);
}
.admin-driver-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}
.admin-driver-card-top strong {
  font-size: 0.88rem;
}
.admin-driver-card .admin-badge {
  font-variant-numeric: tabular-nums;
}
body.shell-phone .admin-user-actions .btn {
  min-height: 44px;
}
body.shell-phone .btn.sm,
body.shell-phone .btn.small {
  min-height: 40px;
}
body.shell-phone .sky-cust-tabs button,
body.shell-phone .hub-tabs button,
body.shell-phone [data-hub-tab] {
  min-height: 44px;
  padding: 10px 14px;
}
body.shell-phone .screen.wide,
body.shell-phone .app-shell.screen.wide {
  max-width: none;
  padding-left: 10px;
  padding-right: 10px;
}
body.shell-phone .app-content {
  min-width: 0;
}
/* ONE UI laptop comfort ? modest cap; forms already min(960px, 92vw) */
body.shell-phone .app-content > .sky-page,
body.shell-phone .app-content > .crm-home,
body.shell-phone .app-content > .shop-chrome-phone {
  max-width: min(1100px, 100%);
  margin-inline: auto;
}
body.shell-phone .hist-table-wrap {
  max-width: 100%;
  border-radius: 10px;
}
body.shell-phone .hist-table {
  font-size: 0.78rem;
}
body.shell-phone .hist-table th,
body.shell-phone .hist-table td {
  padding: 7px 8px;
}
body.shell-phone .crm-home.is-phone .crm-home-date {
  margin: 0 0 4px;
  font-size: 0.78rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ===== UI-06 / crm383+ Auth ? quieter pin/clock (no frosted .card mud) ===== */
body.shell-phone .clock-shell .app-content {
  padding-top: 8px;
}
body.shell-phone .clock-shell .clock-card {
  margin-top: 0;
}

/* .screen-bare = PIN only (fully bare shell) */
.screen-bare {
  min-height: 100dvh;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px 14px calc(16px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.clock-shell .app-body {
  flex: 1 1 auto;
  display: flex;
}
.clock-shell .app-content {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
}

.proto-auth {
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 16px;
}
.proto-auth .logo-wrap {
  padding: 8px 8px 0;
  gap: 6px;
  display: flex;
  justify-content: center;
}
.proto-auth .logo-hero {
  width: min(200px, 56vw);
  filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.22));
}
.proto-auth.is-phone .logo-wrap {
  display: none;
}

/* crm693: Sign in card — same elevated inset language as admin-pin-modal / sky-modal. */
.proto-auth-card {
  width: 100%;
  box-sizing: border-box;
  padding: 18px 18px 16px;
  border-radius: var(--btn-radius, var(--radius-sm));
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.proto-auth-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.proto-auth-head .proto-auth-title {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 1.08rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  text-align: left;
  color: var(--ink);
}
.proto-auth-hint {
  text-align: center;
  margin: 0 0 14px;
}
.proto-auth-pin-row {
  margin: 0 0 16px;
  gap: 14px;
}
.proto-auth-card .proto-auth-digit {
  width: 56px;
  height: 56px;
  min-height: 44px;
  font-size: 1.5rem;
  border-radius: var(--btn-radius, var(--radius-sm));
}
.proto-auth-msg {
  min-height: 1.2em;
  margin: 0 0 12px;
  text-align: center;
  font-size: 0.88rem;
}
.proto-auth-actions {
  display: flex;
  gap: 10px;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: stretch;
  margin-top: 4px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.proto-auth-actions .btn {
  width: auto;
  flex: 1 1 0;
  min-width: 0;
  margin-top: 0;
  min-height: var(--btn-h);
  border-radius: var(--btn-radius, var(--radius-sm));
  font-size: var(--btn-fs, 0.95rem);
}
.proto-auth-actions.is-single .btn {
  flex: 1 1 100%;
}
.proto-auth-forgot {
  margin-top: 12px;
  display: flex;
  justify-content: center;
}
.proto-auth-forgot .btn {
  width: auto;
  min-width: min(100%, 240px);
  flex: 0 1 auto;
}

/* Solid elevated panel — clock-in keeps generic auth-panel; Sign in uses proto-auth-card. */
.auth-panel {
  width: 100%;
  box-sizing: border-box;
  padding: 18px 16px 16px;
  border-radius: var(--radius);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.auth-panel h1 {
  font-size: 1.35rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  margin: 0 0 4px;
  text-align: center;
  color: var(--ink);
}
.auth-panel > .sub {
  margin: 0 0 12px;
  font-size: 0.9rem;
}
.auth-panel .msg {
  min-height: 1.2em;
  margin: 0 0 10px;
  text-align: center;
  font-size: 0.88rem;
}
.auth-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
}
.auth-actions-foot {
  margin-top: 10px;
}
.clock-shell .auth-actions .btn.primary,
.clock-shell .auth-actions .btn.ghost {
  min-height: max(50px, var(--btn-h));
  width: 100%;
  font-size: 1.02rem;
}
.proto-auth-card .proto-auth-pin-row {
  justify-content: center;
}
body.shell-phone .proto-auth-card {
  padding-bottom: max(16px, env(safe-area-inset-bottom, 0px));
}
body.shell-phone .proto-auth-card .proto-auth-digit {
  width: 52px;
  height: 52px;
}
body.shell-phone .proto-auth-actions {
  flex-direction: column;
  flex-wrap: wrap;
}
body.shell-phone .proto-auth-actions .btn {
  width: 100%;
  flex: 1 1 100%;
}
@media (max-width: 440px) {
  .proto-auth-actions {
    flex-direction: column;
  }
  .proto-auth-actions .btn {
    width: 100%;
    flex: 1 1 100%;
  }
}

/* ===== crm45: high-visibility phone polish ? tap targets + no cramped rows ===== */
body.shell-phone .cart-chip {
  min-height: 40px;
  padding: 0 12px;
  border-radius: var(--btn-chip-radius);
}
body.shell-phone .cart-chip-lab {
  display: none;
}
body.shell-phone .sky-hub-tab {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
body.shell-phone .qty-stepper {
  height: 44px;
  min-height: 44px;
  width: fit-content;
  max-width: 100%;
  border-radius: var(--btn-chip-radius);
}
body.shell-phone .cart-phone-stepper {
  height: var(--btn-h);
  min-height: var(--btn-h);
  width: fit-content;
  max-width: 100%;
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
}
/* Phone cart Unit price / Disc % — lock squircle (PC media !important did not cover shell-phone). */
body.shell-phone .cart-price-inp,
body.shell-phone .cart-disc-inp {
  appearance: none;
  -webkit-appearance: none;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
  min-height: var(--btn-h-sm, 34px);
  height: var(--btn-h-sm, 34px);
}
body.shell-phone .cart-phone-stepper .qty-btn {
  width: 44px;
  min-width: 44px;
}
body.shell-phone .qty-btn {
  width: 44px;
  min-width: 44px;
  font-size: 1.25rem;
}
body.shell-phone .cart-line-actions .rm-line {
  width: var(--btn-h);
  min-width: var(--btn-h);
  height: var(--btn-h);
  min-height: var(--btn-h);
  border-radius: var(--btn-radius);
  box-sizing: border-box;
}
body.shell-phone .cart-assign-cta .btn,
body.shell-phone .cart-checkout-sticky .btn {
  min-height: var(--btn-h);
  height: auto;
  border-radius: var(--btn-radius);
  box-sizing: border-box;
}
body.shell-phone .cart-assign-cta {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 8px;
}
body.shell-phone .cart-assign-cta .btn {
  flex: 0 0 auto;
  width: 100%;
  margin-top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
body.shell-phone .cart-chip {
  min-height: 40px;
  padding: 0 10px;
  max-width: 4.5rem;
  border-radius: var(--btn-chip-radius);
}
body.shell-phone .cart-chip-n {
  min-width: 1.5em;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}
body.shell-phone .cart-line-total {
  font-size: 0.95rem;
}
body.shell-phone .crm-ops-form input,
body.shell-phone .crm-ops-form textarea {
  font-size: 1rem;
}
body.shell-phone .crm-ops-form input:not([type="date"]):not([type="number"]) {
  min-height: 44px;
  padding: 10px 12px;
  max-height: none;
}
body.shell-phone .crm-ops-form input[type="date"],
body.shell-phone .crm-ops-form input[type="number"] {
  min-height: 40px;
  max-height: 40px;
  height: 40px;
  padding: 0 10px;
  font-size: 0.95rem;
}
body.shell-phone .crm-ops-form textarea {
  min-height: 72px;
  max-height: none;
}
body.shell-phone .crm-callplan-actions .btn {
  min-height: 44px;
  flex: 1 1 calc(50% - 4px);
}
body.shell-phone .hub-out-row {
  min-height: 48px;
}
body.shell-phone .sky-form-card {
  min-height: 84px;
  padding: 16px;
}
body.shell-phone .admin-user-actions .btn {
  min-height: 44px;
}
body.shell-phone .crm-ops-task {
  min-height: 44px;
}
body.shell-phone .crm-ops-item .btn.sm {
  min-height: 40px;
  flex: 0 0 auto;
}

/* ===== PC premium polish PASS 2 ? Customers / Contacts / Reports =====
   Scoped to ?901px and never body.shell-phone so phone field CRM is untouched.
   Skynamo dark + --accent blue only ? no purple/cream redesign. */
@media (min-width: 901px) {
  /* Comfortable side pad (~20px); hubs/home fill remaining viewport (no 1560 cap). */
  body:not(.shell-phone) {
    --shell-pad-x: 20px;
    --hub-max: none;
  }
  /* Kill legacy .screen { margin:auto + 1100 wide } gutters on PC chrome. */
  body:not(.shell-phone) .app-shell.screen,
  body:not(.shell-phone) .app-shell.screen.wide {
    max-width: none;
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

  /* ?? Shared hub header: editorial title + search pill depth ?? */
  body:not(.shell-phone) .sky-page-head {
    padding: 10px 2px 10px;
    gap: 14px 22px;
    align-items: center;
  }
  body:not(.shell-phone) .sky-page-head h1 {
    font-size: clamp(1.65rem, 2.2vw, 2rem);
    font-weight: var(--fw-strong);
    letter-spacing: -0.035em;
    line-height: 1.15;
  }
  body:not(.shell-phone) .sky-page-search {
    max-width: 480px;
  }
  body:not(.shell-phone) .sky-page-search input {
    background: var(--bg-elevated-2);
    border: 1px solid var(--line);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 4px 14px rgba(0, 0, 0, 0.22);
    padding-top: 11px;
    padding-bottom: 11px;
    transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
  }
  body:not(.shell-phone) .sky-page-search input:hover {
    border-color: var(--line-strong);
  }
  body:not(.shell-phone) .sky-page-search input:focus {
    outline: none;
    border-color: rgba(10, 132, 255, 0.45);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 0 0 3px rgba(10, 132, 255, 0.18);
  }

  /* ?? Customers: Code | Name | Visit | Price list ? dense shared-fr table ??
     Mobile card stack (?900 / shell-phone) is untouched.
     crm294 gave Name alone minmax(12rem,1fr) + fixed Visit/Price ? giant empty
     band between Name text and Visit on wide hubs. Share leftover across Name
     (2fr) + Visit (1fr) + Price (0.8fr) so columns stay adjacent like Tasks/
     Forms densified tables. Full-bleed shell (--hub-max:none) kept. */
  body:not(.shell-phone) .sky-customers {
    width: 100%;
    max-width: var(--hub-max);
    margin: 0;
    box-sizing: border-box;
  }
  /* Map view: full-bleed desk (no hub-max centering that shrinks the map) */
  body:not(.shell-phone) .sky-customers.sky-customers-map {
    max-width: none;
    width: 100%;
    margin: 0;
    flex: 1;
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 24px);
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-body {
    flex: 1;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-customers .sky-page-main.sky-canvas {
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow);
    padding: 10px 12px 14px;
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust {
    /* Name | Next visit (iOS-lean list) */
    grid-template-columns: minmax(0, 1fr) minmax(6.5rem, 9rem) !important;
    grid-template-areas: "name visit" !important;
    gap: 8px 12px !important;
    align-items: center;
    justify-content: stretch;
    width: 100%;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-visit,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-rep,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-cat,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-region {
    display: none;
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-visit {
    display: block;
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head-meta,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-meta,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-meta,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-cust-rep,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-cust-cat,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-cust-region,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust > strong,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust > strong {
    display: none !important;
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head > span:nth-child(1),
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-name,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-name {
    grid-area: name;
    min-width: 0;
    max-width: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.95rem;
    font-weight: var(--fw-semi);
    color: var(--ink);
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head > .sky-list-head-visit,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-visit,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-visit {
    grid-area: visit !important;
  }
  /* Sticky head lives inside scrolling .results.sky-list ? pad matches rows. */
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .sky-list-head,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list-head {
    position: sticky;
    top: 0;
    z-index: 3;
    padding: 9px 20px 9px 8px;
    margin: 0;
    background: color-mix(in srgb, var(--bg-elevated) 92%, #000);
    border-bottom: 1px solid var(--line-strong);
    font-size: 0.68rem;
    font-weight: var(--fw-semi);
    letter-spacing: 0.05em;
    backdrop-filter: blur(8px);
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust {
    padding: 9px 20px 9px 8px !important;
    border-radius: 8px !important;
    border-bottom-color: transparent !important;
    box-shadow: inset 0 -1px 0 var(--line) !important;
    transition: background 0.12s var(--ease), box-shadow 0.12s var(--ease), transform 0.12s var(--ease);
  }
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .results.sky-list .result.pick-cust:hover,
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-list .result.pick-cust:hover {
    background: var(--bg-elevated-2) !important;
    box-shadow: inset 0 1px 0 var(--line-strong), inset 0 -1px 0 var(--line-strong) !important;
  }
  /* Kill base .sky-cust-visit { grid-column: 1 / -1 } ? must stay in Visit cell.
     No extra padding-left ? gap:12px already separates Name|Visit (Filter-open
     narrow width made padding+gap read as a double band). */
  body:not(.shell-phone) .sky-customers:not(.sky-customers-near) .sky-cust-visit {
    grid-area: visit !important;
    grid-column: auto !important;
    margin-top: 0;
    padding-left: 0;
    font-size: 0.76rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
    max-width: none;
    justify-self: stretch;
  }
  body:not(.shell-phone) .sky-customers .sky-cust-filter-chips {
    gap: 6px;
    margin: 2px 0 8px;
  }
  body:not(.shell-phone) .sky-customers .sky-cust-filter-chip {
    border-radius: var(--btn-chip-radius);
    min-height: 28px;
    padding: 3px 10px;
    font-size: 0.76rem;
  }

  /* Near me PC: code | name | address ? km absolute; no Visit track */
  body:not(.shell-phone) .sky-customers-near .near-me-row,
  body:not(.shell-phone) .sky-near-me .near-me-row {
    grid-template-columns: 5rem minmax(8rem, 1fr) minmax(8.5rem, 1.1fr) !important;
    grid-template-areas: "code name meta" !important;
    gap: 6px 12px !important;
    align-items: center;
    padding: 9px 72px 9px 8px !important;
    border-radius: 8px !important;
    border-bottom-color: transparent !important;
    box-shadow: inset 0 -1px 0 var(--line) !important;
  }
  body:not(.shell-phone) .sky-customers-near .near-me-row > strong,
  body:not(.shell-phone) .sky-near-me .near-me-row > strong {
    grid-area: code;
    min-width: 0;
  }
  body:not(.shell-phone) .sky-customers-near .near-me-row .sky-cust-name,
  body:not(.shell-phone) .sky-near-me .near-me-row .sky-cust-name {
    grid-area: name;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body:not(.shell-phone) .sky-customers-near .near-me-row .sky-cust-meta,
  body:not(.shell-phone) .sky-near-me .near-me-row .sky-cust-meta {
    grid-area: meta;
    grid-column: auto !important;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.78rem;
    color: var(--ink-secondary);
  }
  body:not(.shell-phone) .sky-customers-near .near-me-row:hover,
  body:not(.shell-phone) .sky-near-me .near-me-row:hover {
    background: var(--bg-elevated-2) !important;
    box-shadow: inset 0 1px 0 var(--line-strong), inset 0 -1px 0 var(--line-strong) !important;
  }

  /* ?? Customers Map: compact header + Smart scan bar (PC) ?? */
  body:not(.shell-phone) .sky-customers-map .sky-page-head {
    flex-wrap: nowrap;
    align-items: center;
    gap: 10px 14px;
    padding: 6px 0 8px;
    min-height: 44px;
  }
  body:not(.shell-phone) .sky-customers-map .sky-page-search {
    flex: 1 1 200px;
    max-width: 360px;
    min-width: 140px;
  }
  body:not(.shell-phone) .sky-customers-map .sky-page-main.sky-canvas.outlets-map-panel {
    padding: 10px 12px 12px;
    gap: 8px;
    flex: 1;
    min-height: 0;
    height: 100%;
    width: 100%;
    max-width: none;
  }
  /* Full-bleed map column ? kill Near-me 300/560px box that shrank outlets map */
  body:not(.shell-phone) .sky-customers-map .outlets-map-col {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-customers-map .near-me-map-wrap {
    flex: 1 1 auto;
    width: 100%;
    min-height: 560px;
    max-height: none;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-body > .sky-filter.sky-filter-premium {
    align-self: stretch;
    height: auto;
    max-height: calc(100dvh - var(--hdr-h) - 20px);
    border-radius: 0;
    box-shadow: none;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-controls {
    gap: 6px;
    padding-bottom: 2px;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-mode-row {
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px 10px;
    min-width: 0;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-mode-row .img-size-label {
    flex: 0 0 auto;
    font-size: 0.72rem;
    font-weight: var(--fw-semi);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
    white-space: nowrap;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-mode-toggle.img-size-toggle {
    flex: 0 1 auto;
    min-width: 0;
    border-radius: var(--btn-radius-seg);
    background: var(--btn-seg-track);
    padding: 3px;
    gap: 2px;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-mode-toggle .img-size-btn {
    border-radius: var(--btn-radius-seg-item);
    min-height: 30px;
    padding: 4px 11px;
    font-size: 0.76rem;
    white-space: nowrap;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-mode-toggle .img-size-btn.active {
    background: var(--btn-seg-on);
    color: #fff;
    box-shadow: var(--btn-seg-on-shadow);
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-filter-row {
    gap: 8px;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-select,
  body:not(.shell-phone) .sky-customers-map .outlets-map-sku-input {
    min-height: 34px;
    min-width: min(100%, 200px);
    max-width: 420px;
    border-radius: var(--btn-radius);
    padding: 6px 12px;
    font-size: 0.84rem;
    box-shadow: var(--btn-ghost-shadow);
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-status {
    font-size: 0.78rem;
    margin: 0;
  }
  body:not(.shell-phone) .sky-customers-map .outlets-map-coverage-tip {
    font-size: 0.7rem;
    margin: 0;
  }
  /* FAB depth lives in PASS 1 button language (quiet, not neon). */

  /* ?? Reports: Download centre fills the hub; cards don?t look abandoned ?? */
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-page-main.sky-canvas {
    width: 100%;
    min-height: min(480px, calc(100dvh - 210px));
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow);
    padding: 16px 18px 22px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-page-meta {
    font-size: 0.9rem;
    font-weight: var(--fw-med);
    color: var(--ink-secondary);
    padding-bottom: 12px;
    margin-bottom: 12px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-reports-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-content: start;
    min-height: 220px;
    padding: 2px 0 8px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-form-card {
    min-height: 112px;
    padding: 18px 20px;
    border-radius: 14px;
    border-color: var(--line-strong);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
    transition: border-color 0.14s var(--ease), background 0.14s var(--ease), transform 0.12s var(--ease);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-form-card strong {
    font-size: 1.05rem;
    font-weight: var(--fw-strong);
    letter-spacing: -0.02em;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-form-card:hover {
    transform: translateY(-1px);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-view-rail {
    padding-right: 18px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-rail-title {
    margin-bottom: 12px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-view-item {
    padding: 9px 12px;
    margin-bottom: 2px;
    font-size: 0.92rem;
    transition: background 0.12s var(--ease);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports .sky-view-item:hover {
    background: rgba(255, 255, 255, 0.05);
  }
}

/* ===== PC premium polish PASS 1 - Home + chrome + buttons (>=901 only) =====
   Button look is shared (base .btn tokens). PC denser sizing; radius stays
   squircle via --btn-radius (= --radius-sm / 12px) on phone + PC. */
@media (min-width: 901px) {
  /* Keep PC #app flat ? vignette/radial washes dither into jagged bands on Safari. */
  body:not(.shell-phone) #app {
    background: var(--bg);
  }

  /* Top nav ? desk density, left-clustered (not floating center).
     Centered flex + overflow clipped "Home"?"ne" (crm188/190); with ~10
     labels, safe-center also reads off-balance vs logo/session widths. */
  body:not(.shell-phone) {
    --hdr-h: 58px;
    --hdr-nav-fs: 0.84rem;
    --hdr-nav-pad-x: 10px;
    --hdr-gap-y: 10px;
    --btn-radius: 12px;
    --btn-h: 42px;
    --btn-pad-y: 10px;
    --btn-pad-x: 18px;
    --btn-fs: 0.9rem;
  }
  /* PC top bar: logo left ? nav truly centered in viewport ? session right.
     Equal 1fr side columns keep Home/Timeline/? on the optical center even when
     logo width ? session width. (Left-cluster was a temporary anti-clip hack
     when ~10 nav labels crowded the bar; unified nav is short enough to center.) */
  body:not(.shell-phone) .app-header {
    gap: 0 14px;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: stretch;
  }
  body:not(.shell-phone) .app-header-brand {
    min-width: max-content;
    flex-shrink: 0;
    align-self: stretch;
    justify-self: start;
  }
  body:not(.shell-phone) .app-header-session {
    min-width: max-content;
    flex-shrink: 0;
    align-self: stretch;
    justify-self: end;
    gap: 8px;
  }
  body:not(.shell-phone) .main-nav {
    gap: 0;
    justify-content: center;
    justify-self: center;
    align-items: stretch;
    min-width: 0;
    overflow-x: visible;
  }
  body:not(.shell-phone) .main-nav-link {
    font-size: var(--hdr-nav-fs);
    font-weight: var(--fw-med);
    letter-spacing: -0.01em;
    padding: 0 var(--hdr-nav-pad-x);
    gap: 5px;
    flex: 0 0 auto;
    min-width: max-content;
    overflow: visible;
    line-height: 1;
    box-shadow: inset 0 -2px 0 transparent;
  }
  body:not(.shell-phone) .main-nav-lab {
    display: inline-block;
    min-width: max-content;
    overflow: visible;
    line-height: 1.15;
  }
  body:not(.shell-phone) .main-nav-ico {
    flex: 0 0 auto;
    width: 14px;
    height: 14px;
    opacity: 0.7;
  }
  body:not(.shell-phone) .main-nav-ico svg {
    width: 14px;
    height: 14px;
  }
  body:not(.shell-phone) .main-nav-link:hover {
    color: #fff;
  }
  body:not(.shell-phone) .main-nav-link.is-active {
    color: #fff;
    font-weight: var(--fw-semi);
    box-shadow: inset 0 -2px 0 var(--accent);
  }
  body:not(.shell-phone) .main-nav-link.is-active .main-nav-ico {
    opacity: 1;
    color: var(--accent);
  }

  /* Settings ? iOS inset groups on desk */
  body:not(.shell-phone) .settings-panel.settings-page {
    padding: 22px 24px 28px;
    max-width: 820px;
  }
  body:not(.shell-phone) .settings-head {
    gap: 16px;
    margin-bottom: 8px;
  }
  body:not(.shell-phone) .settings-head-txt h1 {
    font-size: 1.5rem;
  }
  body:not(.shell-phone) .settings-list {
    border-radius: var(--radius-sm);
  }
  body:not(.shell-phone) .settings-row {
    padding: 12px 16px;
    min-height: var(--btn-h);
  }
  body:not(.shell-phone) .settings-row-ico {
    width: 30px;
    height: 30px;
    border-radius: 7px;
  }
  body:not(.shell-phone) .settings-list > .settings-row:not(:last-child)::after {
    left: calc(16px + 30px + 12px);
  }

  body:not(.shell-phone) .btn,
  body:not(.shell-phone) .btn.sky-hub-add,
  body:not(.shell-phone) .hub-action-grid .btn.ghost,
  body:not(.shell-phone) .hub-act-btn,
  body:not(.shell-phone) .sky-pill,
  body:not(.shell-phone) .home-quick,
  body:not(.shell-phone) .back-btn,
  body:not(.shell-phone) .route-cta,
  body:not(.shell-phone) .quote-pill,
  body:not(.shell-phone) .shop-dock-quote {
    border-radius: var(--btn-radius);
  }
  /* Filter chips stay chip squircle (never inherit stadium --btn-radius legacy). */
  body:not(.shell-phone) .sky-cust-filter-chip {
    border-radius: var(--btn-chip-radius, var(--radius-sm, 12px)) !important;
  }
  body:not(.shell-phone) .cat-sheet-btn {
    border-radius: var(--btn-radius-seg);
  }
  body:not(.shell-phone) .products .add-row .btn {
    border-radius: var(--btn-radius) !important;
  }
  /* Qty group stays chip squircle; Add (+) uses --btn-radius (never stadium). */
  body:not(.shell-phone) .products .qty-stepper {
    border-radius: var(--btn-chip-radius) !important;
  }
  body:not(.shell-phone) .cart-table-stepper,
  body:not(.shell-phone) .cart-phone-stepper,
  body:not(.shell-phone) .cart-chip,
  body:not(.shell-phone) .cart-price-inp,
  body:not(.shell-phone) .cart-disc-inp {
    border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
  }
  /* Hub Add ? compact primary (override quiet outline chrome on Contacts/Tasks).
     Exclude .ghost so Near me Reload/Seed stay elevated secondary. */
  body:not(.shell-phone) .sky-hub-page.is-pc .btn.sky-hub-add:not(.ghost),
  body:not(.shell-phone) .btn.primary.sky-hub-add {
    width: auto;
    flex-basis: auto;
    margin-top: 0;
    min-height: 38px;
    padding: 8px 14px;
    font-size: 0.88rem;
    font-weight: var(--fw-med);
    background: var(--btn-primary-bg);
    color: #fff;
    border: 1px solid var(--btn-primary-border);
    box-shadow: var(--btn-primary-shadow);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .btn.sky-hub-add:not(.ghost):hover,
  body:not(.shell-phone) .btn.primary.sky-hub-add:hover {
    background: var(--btn-primary-bg-hover);
    border-color: var(--btn-primary-border);
    color: #fff;
    box-shadow: var(--btn-primary-shadow-hover);
  }
  body:not(.shell-phone) .btn.ghost.sky-hub-add {
    background: var(--btn-ghost-bg);
    color: var(--ink);
    border: 1px solid var(--btn-ghost-border);
    box-shadow: var(--btn-ghost-shadow);
  }
  body:not(.shell-phone) .btn.ghost.sky-hub-add:hover {
    background: color-mix(in srgb, var(--bg-elevated-2) 70%, #3a3a3c 30%);
    border-color: rgba(255, 255, 255, 0.16);
    color: var(--ink);
  }
  /* FAB stays circle; slight lift on hover. */
  body:not(.shell-phone) .sky-fab:hover {
    transform: scale(1.04);
  }
  body:not(.shell-phone) .sky-cust-filter-chip,
  body:not(.shell-phone) .sky-pill {
    min-height: 32px;
    padding: 5px 12px;
  }

  /* Cards that already exist ? hairline + soft shadow so content floats above void. */
  body:not(.shell-phone) .card,
  body:not(.shell-phone) .home-widget,
  body:not(.shell-phone) .dash-rail-card,
  body:not(.shell-phone) .home-quick {
    border-color: var(--line);
    box-shadow: var(--shadow);
  }

  /* Home width ? kill skinny .screen.wide / .home-card 720 caps on PC. */
  body:not(.shell-phone) .screen.wide:has(.crm-home.is-pc),
  body:not(.shell-phone) .screen.wide:has(.crm-home.is-pc) {
    max-width: none;
    width: 100%;
  }
  body:not(.shell-phone) .screen.wide:has(.crm-home.is-pc) .home-card,
  body:not(.shell-phone) .crm-home.is-pc .home-card{
    max-width: none;
    width: 100%;
    margin-left: 0;
    margin-right: 0;
  }

  /* ?? Forms hub: center canvas fills rails; table flexes ? no H-scroll when wide ?? */
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-forms .sky-hub-body {
    width: 100%;
    min-width: 0;
    align-items: stretch;
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 110px);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-forms .sky-page-main.sky-canvas {
    width: 100%;
    min-width: 0;
    min-height: 100%;
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow);
    padding: 12px 14px 16px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table.hist-table-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    margin-top: 4px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table.hist-table-full {
    overflow-x: hidden;
    overflow-y: auto;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table {
    table-layout: fixed;
    width: 100%;
    white-space: normal;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th,
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    vertical-align: middle;
  }
  /* Icon | Date | Type | Customer | Rep | Status | Monday */
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(1),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(1) {
    width: 36px;
    padding-left: 8px;
    padding-right: 4px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(2),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(2) {
    width: 12%;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(3),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(3) {
    width: 12%;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(4),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(4) {
    width: 28%;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(5),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(5) {
    width: 14%;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(6),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(6) {
    width: 10%;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th:nth-child(7),
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td:nth-child(7) {
    width: 9%;
  }

  /* KPI strip ? My-day 2 tiles; elevated + clear number hierarchy. */
  body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip{
    grid-template-columns: repeat(2, minmax(180px, 240px));
    gap: 10px;
    margin-bottom: 16px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-kpi{
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: var(--shadow);
    padding: 14px 12px;
    min-height: 80px;
    gap: 6px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-kpi strong{
    font-size: 1.45rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-kpi span{
    font-size: 0.72rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--muted);
  }
  body:not(.shell-phone) .crm-home.is-pc .home-kpi:hover{
    border-color: rgba(10, 132, 255, 0.55);
    background: var(--bg-elevated-2);
  }

  /* Running deals ? bold promo strip; cards share full Home width on PC. */
  body:not(.shell-phone) .crm-home.is-pc .home-deals{
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    padding: 16px 16px 14px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar{
    width: 100%;
    max-width: none;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-head h2{
    font-size: 1.12rem;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals{
    --deals-card-visual: 88px;
    --deals-card-thumb: 88px;
    --home-deal-media-h: 0px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-grid{
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
    width: 100%;
    align-items: start;
    grid-auto-rows: auto;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-grid > .home-deals-card,
  body:not(.shell-phone) .crm-home.is-pc .home-deals-card-wrap,
  body:not(.shell-phone) .crm-home.is-pc .home-deals-card-wrap .home-deals-card{
    min-height: 132px;
    height: 132px;
    max-height: 132px;
  }
  /* Desk: left media stage + right copy (absolute regions). */
  body:not(.shell-phone) .crm-home.is-pc .home-deals-card-visual{
    top: 10px !important;
    right: auto !important;
    bottom: 10px !important;
    left: 10px !important;
    width: 46% !important;
    max-width: 200px;
    height: auto !important;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-card-foot{
    left: calc(46% + 20px) !important;
    right: 12px !important;
    top: 0 !important;
    bottom: 0 !important;
    align-items: center;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-banner-wrap{
    grid-column: 1 / -1;
    width: 100%;
    height: auto;
    max-height: none;
    min-height: 0;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-deals-card-big{
    font-size: 1.05rem;
  }

  /* Call plan ? light card, one horizontal chip row above a short list; status via left accent + muted meta. */
  body:not(.shell-phone) .crm-home.is-pc .home-radar{
    border: 1px solid var(--line);
    background: var(--bg-elevated);
    box-shadow: var(--btn-ghost-shadow);
    border-radius: var(--radius-sm);
    padding: 14px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar:not(.is-compact) .home-radar-body{
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar:not(.is-compact) .home-radar-list{
    max-height: 180px;
    overflow-y: auto;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-head h2{
    font-size: 0.78rem;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-chip{
    min-height: 32px;
    padding: 6px 13px;
    font-size: 0.8rem;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-chip strong{
    font-size: 0.92rem;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-row{
    padding: 9px 12px;
    min-height: 42px;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-name{
    font-size: 0.9rem;
  }
  body:not(.shell-phone) .crm-home.is-pc .home-radar-meta{
    font-size: 0.7rem;
    padding: 5px 9px;
  }

  /* Wave 1 P0: hide PC home CTA row (nav covers Forms / Reports / Start visit). */
  body:not(.shell-phone) .crm-home.is-pc .home-pc-cta-row{
    display: none !important;
  }
  /* Role panel home: hide duplicate quick grid. */
  body:not(.shell-phone) .crm-home.is-pc:has(.crm-home-panel) .home-quick-grid.is-pc{
    display: none !important;
  }

  /* Warm home tiles on dark PC ? no #f2f2f7 billboard (phone keeps light warm). */
  body:not(.shell-phone) .home-block-warm {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--line-strong);
    color: var(--ink);
  }
  body:not(.shell-phone) .home-block-warm strong {
    color: var(--ink);
  }
  body:not(.shell-phone) .home-block-warm span {
    color: var(--muted);
  }
}

/* Wide desktop ? slightly roomier tab pads; stay left-clustered. */
@media (min-width: 1280px) {
  body:not(.shell-phone) {
    --hdr-nav-fs: 0.875rem;
    --hdr-nav-pad-x: 11px;
  }
  body:not(.shell-phone) .main-nav {
    gap: 1px;
    justify-content: flex-start;
  }
  body:not(.shell-phone) .main-nav-link {
    padding: 0 var(--hdr-nav-pad-x);
  }
  /* Keep home on the same wide band as hubs (do not re-cap at 1280). */
  body:not(.shell-phone) .crm-home.is-pc {
    max-width: none;
    width: 100%;
  }
}

/* Narrow PC ? denser tabs so ~10 items + New customer fit before scroll. */
@media (min-width: 901px) and (max-width: 1180px) {
  body:not(.shell-phone) {
    --hdr-nav-fs: 0.8rem;
    --hdr-nav-pad-x: 7px;
  }
  body:not(.shell-phone) .app-header {
    gap: 0 10px;
  }
  body:not(.shell-phone) .main-nav-link {
    font-size: var(--hdr-nav-fs);
    padding: 0 var(--hdr-nav-pad-x);
    gap: 4px;
  }
  body:not(.shell-phone) .main-nav-ico,
  body:not(.shell-phone) .main-nav-ico svg {
    width: 12px;
    height: 12px;
  }
}

/* ===== PC Calendar chrome crm111 ? premium seg / Today / Filter / folds ===== */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-desk .acal-seg {
    padding: 3px;
    border-radius: var(--btn-radius-seg);
    background: var(--btn-seg-track);
    box-shadow:
      inset 0 0 0 0.5px rgba(255, 255, 255, 0.08),
      0 1px 2px rgba(0, 0, 0, 0.22);
  }
  body:not(.shell-phone) .sky-desk .acal-seg-btn {
    min-height: var(--btn-h-sm);
    padding: 5px 12px;
    font-size: 0.76rem;
    color: rgba(235, 235, 245, 0.72);
    border-radius: var(--btn-radius-seg-item);
  }
  body:not(.shell-phone) .sky-desk .acal-seg-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
  }
  body:not(.shell-phone) .sky-desk .acal-seg-btn.is-on {
    background: var(--btn-seg-on);
    color: #fff;
    box-shadow: var(--btn-seg-on-shadow);
  }
  body:not(.shell-phone) .sky-desk .acal-kind-seg .acal-seg-btn {
    padding: 5px 11px;
  }
  body:not(.shell-phone) .sky-desk .acal-today-btn {
    border: 1px solid rgba(10, 132, 255, 0.35);
    background: rgba(10, 132, 255, 0.1);
    border-radius: 10px;
    min-height: 32px;
    padding: 5px 12px;
    font-size: 0.78rem;
  }
  body:not(.shell-phone) .sky-desk .acal-today-btn:hover {
    background: rgba(10, 132, 255, 0.18);
    border-color: rgba(10, 132, 255, 0.5);
    color: #fff;
  }
  body:not(.shell-phone) .sky-desk .acal-icon-btn {
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
  }
  body:not(.shell-phone) .sky-desk .acal-icon-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.18);
  }
  body:not(.shell-phone) .sky-desk .acal-toolbar-sky {
    padding: 2px 16px 10px;
    gap: 8px 12px;
  }
  body:not(.shell-phone) .sky-desk .acal-nav-start,
  body:not(.shell-phone) .sky-desk .acal-nav-end {
    display: inline-flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 8px;
    min-height: 34px;
  }
  body:not(.shell-phone) .sky-desk .acal-nav-end .acal-seg {
    align-self: center;
  }
  body:not(.shell-phone) .sky-desk .acal-period {
    line-height: 34px;
    align-self: center;
  }
  body:not(.shell-phone) .sky-filter-premium .sky-filter-fold {
    padding: 7px 6px;
    border-radius: 8px;
    min-height: 34px;
  }
  body:not(.shell-phone) .sky-filter-premium .sky-filter-fold:hover {
    background: rgba(255, 255, 255, 0.055);
  }
  body:not(.shell-phone) .sky-filter-premium .acal-people-chip {
    border-radius: var(--btn-chip-radius);
    min-height: 32px;
    padding: 6px 10px;
    font-size: 0.76rem;
    border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.1));
    background: var(--btn-ghost-bg, rgba(255, 255, 255, 0.04));
    box-shadow: var(--btn-ghost-shadow);
  }
  /* Role / quick chips may use solid chip-on; Calendar people roster stays soft (above). */
  body:not(.shell-phone) .sky-filter-premium .acal-people-chip.is-on {
    border-color: var(--btn-chip-on-border);
    background: var(--btn-chip-on-bg);
    color: #fff;
    box-shadow: var(--btn-chip-on-shadow);
  }
  body:not(.shell-phone) .sky-desk .sky-filter-premium .acal-people-row.is-on,
  body:not(.shell-phone) .sky-desk .sky-filter-premium .acal-color-legend-btn.is-on {
    background: color-mix(in srgb, var(--accent) 16%, var(--btn-ghost-bg));
    border-color: color-mix(in srgb, var(--accent) 42%, var(--btn-ghost-border));
    box-shadow: var(--btn-ghost-shadow);
    color: var(--ink);
  }
  body:not(.shell-phone) .sky-filter-premium .acal-people-row {
    border-radius: var(--btn-chip-radius);
    min-height: 32px;
  }
  body:not(.shell-phone) .sky-filter-premium .acal-people-sel {
    border-radius: var(--btn-chip-radius);
  }
  body:not(.shell-phone) .sky-desk .acal-add-btn {
    border-radius: var(--btn-chip-radius) !important;
    min-height: 32px !important;
    height: 32px !important;
    padding: 0 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px;
    font-size: 0.76rem !important;
    line-height: 1;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .sky-desk .acal-today-btn {
    min-height: 32px;
    height: 32px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .sky-desk .acal-icon-btn {
    width: 32px;
    height: 32px;
    min-height: 32px;
  }
  /* Plan page: calendar owns the viewport; folded tasks = one slim bar. */
  body:not(.shell-phone) .crm-plan-page {
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 20px);
  }
  body:not(.shell-phone) .crm-plan-page .crm-plan-calendar {
    flex: 1 1 auto;
    min-height: 0;
  }
  body:not(.shell-phone) .crm-plan-page .crm-plan-calendar > .acal.is-full {
    height: 100%;
    max-height: none;
    min-height: 0;
  }
}

/* ===== MOBILE Reports hub ? chips + Download centre fill (phone only) =====
   Scoped to body.shell-phone so PC crm95 Reports polish stays untouched.
   App-shell already clears bottom-nav; panel flex-grows into that band. */
body.shell-phone .sky-hub-reports {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: calc(
    100dvh - var(--hdr-h) - var(--safe-top) - var(--bottom-nav-h, 56px) - var(--safe-bottom) - 16px
  );
}

/* Hide empty Reports landing head only. Call Report tools use chips + hdr-icon-btn
   (not .btn / input) — never swallow Period · People · Filters (crm871). */
body.shell-phone .sky-hub-reports:not(.sky-hub-reports-call):not(.sky-hub-reports-rep-performance):not(.sky-hub-reports-orders):not(.sky-hub-reports-visit-compliance) .sky-page-head:not(:has(input)):not(:has(.btn)):not(:has(.sky-hub-tools)) {
  display: none;
}
body.shell-phone .sky-hub-reports-call > .sky-page-head,
body.shell-phone .sky-hub-reports-rep-performance > .sky-page-head,
body.shell-phone .sky-hub-reports-orders > .sky-page-head,
body.shell-phone .sky-hub-reports-visit-compliance > .sky-page-head {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
}

/* Filter chips ? elevated fill, not thin grey outline on black */
body.shell-phone .sky-hub-reports .sky-phone-seg {
  gap: 8px;
  padding: 4px 0 4px;
  margin: 0;
  flex-shrink: 0;
}
body.shell-phone .sky-hub-reports .sky-phone-seg-btn {
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  box-shadow: var(--btn-ghost-shadow);
  border-radius: var(--btn-chip-radius);
  padding: 8px 16px;
  min-height: var(--btn-h-sm);
  font-size: 0.84rem;
  font-weight: var(--fw-semi);
}
body.shell-phone .sky-hub-reports .sky-phone-seg-btn.is-on {
  border-color: transparent;
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}

body.shell-phone .sky-hub-reports .sky-hub-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding-bottom: 8px;
}

/* Download centre ? stronger surface that owns the remaining height */
body.shell-phone .sky-hub-reports .sky-page-main.sky-canvas {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  width: 100%;
  padding: 14px 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.38);
}
body.shell-phone .sky-hub-reports .sky-page-meta {
  flex-shrink: 0;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  color: var(--ink-secondary);
  padding: 0 2px 10px;
  margin: 0;
  border-bottom-color: var(--line-strong);
}

body.shell-phone .sky-hub-reports .sky-reports-grid {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: 1fr;
  gap: 12px;
  align-content: stretch;
  min-height: 220px;
  padding: 2px 0 4px;
}
body.shell-phone .sky-hub-reports .sky-form-card {
  min-height: 108px;
  height: 100%;
  padding: 16px 14px;
  border-radius: 14px;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated-2);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.28);
  gap: 8px;
  justify-content: center;
}
body.shell-phone .sky-hub-reports .sky-form-card strong {
  font-size: 1rem;
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
  line-height: 1.2;
}
body.shell-phone .sky-hub-reports .sky-form-card .sub {
  font-size: 0.78rem;
  line-height: 1.3;
  color: var(--muted);
}
body.shell-phone .sky-hub-reports .sky-form-card:active {
  border-color: rgba(10, 132, 255, 0.55);
  background: rgba(10, 132, 255, 0.14);
}

/* Footer note ? quieter, sits at panel bottom above nav clearance */
body.shell-phone .sky-hub-reports .sky-hub-foot {
  flex-shrink: 0;
  margin: auto 2px 0;
  padding-top: 6px;
  font-size: 0.7rem;
  line-height: 1.35;
  color: var(--muted);
  opacity: 0.55;
  text-align: left;
}

/* ===== Wave M1 ? viewport-owned list hubs (crm275) =====
   The page head stays fixed in the page flow while the list/table owns every
   remaining pixel. Rails remain the crm274 full-height RIGHT grid columns. */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-hub-page.is-pc,
  body:not(.shell-phone) .sky-customers.is-pc {
    height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 24px);
    min-height: 0;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body,
  body:not(.shell-phone) .sky-customers.is-pc .sky-hub-body {
    flex: 1 1 auto;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.is-pc .sky-page-main.sky-canvas {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
  }

  /* Customers: fixed metadata/header, dense rows scroll within the canvas.
     Clear legacy `.results { max-height: 52vh }` or list stays a short box + empty gap. */
  body:not(.shell-phone) .sky-customers.is-pc .results.sky-list {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  /* Forms and reports use native tables; keep their column labels visible. */
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table,
  body:not(.shell-phone) .sky-hub-reports .sky-reports-table {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table.hist-table-full,
  body:not(.shell-phone) .sky-hub-reports .sky-reports-table.hist-table-full {
    max-height: none;
    overflow: auto;
    overscroll-behavior: contain;
  }
  body:not(.shell-phone) .sky-hub-forms .hist-table thead th,
  body:not(.shell-phone) .sky-hub-reports .hist-table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--bg-elevated-2);
  }

  /* Activity and column tables retain their head while their bodies scroll. */
  body:not(.shell-phone) .sky-hub-timeline .sky-tl-groups,
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    overscroll-behavior: contain;
  }
  body:not(.shell-phone) .sky-hub-timeline .sky-tl-groups {
    padding-right: 2px;
  }
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-table {
    flex: 1 1 auto;
    min-height: 0;
  }
}

/* Phone keeps Filter/View as sheets, but the primary list now occupies the
   viewport below its head/search instead of ending in a black void. */
body.shell-phone .sky-hub-page:is(.sky-hub-forms, .sky-hub-timeline, .sky-hub-tasks, .sky-hub-reports),
body.shell-phone .sky-customers {
  min-height: calc(100dvh - var(--hdr-h) - var(--safe-top) - var(--bottom-nav-h) - var(--safe-bottom) - 22px);
  display: flex;
  flex-direction: column;
}

/* ===== Wave M2 ? customer workspaces own their viewport (crm276) ===== */
@media (min-width: 901px) {
  body:not(.shell-phone) .app-content:has(.sky-customer-hub.is-pc),
  body:not(.shell-phone) .app-content:has(.sky-near-me),
  body:not(.shell-phone) .app-content:has(.sky-customers-near),
  body:not(.shell-phone) .app-content:has(.sky-customers.sky-customers-map),
  body:not(.shell-phone) .app-content:has(.customer-info-page),
  body:not(.shell-phone) .app-content:has(.customer-insight-page) {
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 24px);
    display: flex;
    flex-direction: column;
  }

  /* Account hub: head + tabs stay in flow; the active workspace owns the rest. */
  body:not(.shell-phone) .sky-customer-hub.is-pc {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-customer-hub.is-pc .sky-hub-tab-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    overscroll-behavior: contain;
    padding-right: 4px;
  }
  /* Integer px height ? fractional clamp(48dvh) soft-scales the MapLibre canvas. */
  body:not(.shell-phone) .sky-customer-hub.is-pc .cust-map-block .near-me-map-wrap,
  body:not(.shell-phone) .customer-info-page .cust-map-block .near-me-map-wrap {
    height: 480px;
    min-height: 380px;
    max-height: none;
  }
  @media (min-height: 900px) {
    body:not(.shell-phone) .sky-customer-hub.is-pc .cust-map-block .near-me-map-wrap,
    body:not(.shell-phone) .customer-info-page .cust-map-block .near-me-map-wrap {
      height: 560px;
    }
  }
  @media (min-height: 1100px) {
    body:not(.shell-phone) .sky-customer-hub.is-pc .cust-map-block .near-me-map-wrap,
    body:not(.shell-phone) .customer-info-page .cust-map-block .near-me-map-wrap {
      height: 640px;
    }
  }

  /* Near me (standalone legacy + Customers hub Near me segment): full-bleed map+list. */
  body:not(.shell-phone) .sky-near-me,
  body:not(.shell-phone) .sky-customers-near {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-near-me .near-me-body,
  body:not(.shell-phone) .sky-customers-near .near-me-body {
    flex: 1 1 auto;
    min-height: 0;
    align-items: stretch;
  }
  body:not(.shell-phone) .sky-near-me .near-me-map-col,
  body:not(.shell-phone) .sky-near-me .near-me-list-col,
  body:not(.shell-phone) .sky-customers-near .near-me-map-col,
  body:not(.shell-phone) .sky-customers-near .near-me-list-col {
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-near-me .near-me-map-col,
  body:not(.shell-phone) .sky-customers-near .near-me-map-col {
    position: static;
  }
  /* Clear fixed height:560 from earlier near-me rule so MapLibre can flex-fill (crm323). */
  body:not(.shell-phone) .sky-near-me .near-me-map-wrap,
  body:not(.shell-phone) .sky-customers-near .near-me-map-wrap {
    flex: 1 1 auto;
    height: 100%;
    min-height: 560px;
    max-height: none;
  }
  body:not(.shell-phone) .sky-near-me .near-me-list-col .results.sky-list,
  body:not(.shell-phone) .sky-customers-near .near-me-list-col .results.sky-list {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow: auto;
    overscroll-behavior: contain;
  }

  /* Customers Map ? same viewport stretch as Near me (Wave M2). */
  body:not(.shell-phone) .sky-customers.sky-customers-map {
    flex: 1 1 auto;
    min-height: 0;
  }
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-body {
    flex: 1 1 auto;
    min-height: 0;
    align-items: stretch;
  }
  body:not(.shell-phone) .sky-customers.sky-customers-map .sky-page-main.sky-canvas.outlets-map-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-col {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-customers.sky-customers-map .near-me-map-wrap {
    flex: 1 1 auto;
    height: 100%;
    min-height: 560px;
    max-height: none;
  }

  /* Information and history stay useful on tall desks rather than ending midway. */
  body:not(.shell-phone) .customer-info-page,
  body:not(.shell-phone) .customer-insight-page {
    flex: 1 1 auto;
    min-height: 0;
    width: 100%;
    max-width: var(--hub-max);
    margin: 0;
  }
  body:not(.shell-phone) .customer-insight-page {
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .customer-insight-page .hist-table-full {
    flex: 1 1 auto;
    min-height: 280px;
    max-height: none;
    overflow: auto;
  }
}

/* Phone keeps one clear scroll path; maps remain large enough for pin work. */
body.shell-phone .sky-customer-hub,
body.shell-phone .customer-info-page,
body.shell-phone .customer-insight-page,
body.shell-phone .sky-near-me {
  min-height: calc(100dvh - var(--hdr-h) - var(--safe-top) - var(--bottom-nav-h) - var(--safe-bottom) - 22px);
}
body.shell-phone .sky-hub-page:is(.sky-hub-forms, .sky-hub-timeline, .sky-hub-tasks, .sky-hub-reports) .sky-hub-body,
body.shell-phone .sky-customers .sky-hub-body {
  flex: 1 1 auto;
  min-height: 0;
}
body.shell-phone .sky-hub-page:is(.sky-hub-forms, .sky-hub-timeline, .sky-hub-tasks, .sky-hub-reports) .sky-page-main.sky-canvas,
body.shell-phone .sky-customers .sky-page-main.sky-canvas {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
body.shell-phone .sky-hub-timeline .sky-tl-groups,
body.shell-phone .sky-hub-tasks .sky-hub-list,
body.shell-phone .sky-hub-forms .sky-forms-rows,
body.shell-phone .sky-hub-forms .sky-forms-table.hist-table-full,
body.shell-phone .sky-hub-reports .sky-reports-table.hist-table-full,
body.shell-phone .sky-customers .results.sky-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

/* ===== PC premium polish PASS 3 ? headers / search / hub density (crm189) =====
   Phone (=900 / shell-phone) untouched. No purple/Inter ? accent blue + Segoe. */
@media (min-width: 901px) {
  body:not(.shell-phone) {
    --shell-pad-x: 20px;
  }

  /* Title | search | actions ? one aligned toolbar row */
  body:not(.shell-phone) .sky-page-head {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-start;
    gap: 12px 16px;
    padding: 8px 0 10px;
    min-height: 48px;
  }
  body:not(.shell-phone) .sky-page-head h1 {
    flex: 0 1 auto;
    min-width: 0;
    font-size: clamp(1.45rem, 1.8vw, 1.75rem);
    letter-spacing: -0.03em;
    line-height: 1.2;
    white-space: nowrap;
  }
  body:not(.shell-phone) .sky-page-search {
    flex: 1 1 220px;
    max-width: 420px;
    margin-inline: 0;
    min-width: 160px;
  }
  body:not(.shell-phone) .sky-page-head-actions {
    flex: 0 0 auto;
    margin-left: auto;
    gap: 8px;
  }
  body:not(.shell-phone) .sky-page-head-actions:empty {
    display: none;
  }

  /* Slimmer premium search ? squircle, not tall stadium */
  body:not(.shell-phone) .sky-page-search input {
    border-radius: var(--btn-radius);
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: var(--btn-ghost-shadow);
    padding: 7px 14px 7px 36px;
    min-height: 36px;
    font-size: 0.875rem;
    font-weight: var(--fw-med);
    line-height: 1.25;
    transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease), background 0.14s var(--ease);
  }
  body:not(.shell-phone) .sky-page-search input:hover {
    border-color: rgba(255, 255, 255, 0.16);
    background: var(--bg-elevated-2);
  }
  body:not(.shell-phone) .sky-page-search input:focus {
    outline: none;
    border-color: color-mix(in srgb, var(--accent) 50%, var(--line-strong));
    box-shadow: var(--btn-focus-ring);
    background: var(--bg-elevated-2);
  }
  body:not(.shell-phone) .sky-page-search::before {
    left: 12px;
    width: 14px;
    height: 14px;
    opacity: 0.55;
  }

  /* Products search ? match hub density */
  body:not(.shell-phone) .shop-search-field,
  body:not(.shell-phone) .search-wrap.shop-search input {
    border-radius: var(--btn-radius);
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: var(--btn-ghost-shadow);
    min-height: 36px;
    padding-top: 7px;
    padding-bottom: 7px;
    font-size: 0.875rem;
  }
  body:not(.shell-phone) .shop-sky-title {
    padding: 8px 0 6px;
    gap: 12px 16px;
    align-items: center;
  }
  body:not(.shell-phone) .shop-sky-title h1 {
    font-size: clamp(1.45rem, 1.8vw, 1.75rem);
    font-weight: var(--fw-strong);
    letter-spacing: -0.03em;
  }
  body:not(.shell-phone) .shop-chrome {
    gap: 10px;
  }

  /* Customers List|Map|Near me seg ? token language */
  body:not(.shell-phone) .cust-view-toggle.img-size-toggle {
    border-radius: var(--btn-radius-seg);
    background: var(--btn-seg-track);
    padding: 3px;
    gap: 2px;
  }
  body:not(.shell-phone) .cust-view-toggle .img-size-btn {
    border-radius: var(--btn-radius-seg-item);
    min-height: 30px;
    padding: 4px 10px;
    font-size: 0.76rem;
    white-space: nowrap;
  }
  body:not(.shell-phone) .cust-view-toggle .img-size-btn.active {
    background: var(--btn-seg-on);
    color: #fff;
    box-shadow: var(--btn-seg-on-shadow);
  }

  /* Shared hub canvas ? one panel language; fill the grid track height */
  body:not(.shell-phone) .sky-hub-page.is-pc {
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 24px);
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body {
    flex: 1;
    align-items: stretch;
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y, 12px) - 110px);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers .sky-page-main.sky-canvas {
    border: 1px solid var(--line-strong);
    box-shadow: var(--shadow);
    border-radius: var(--radius-sm);
    min-height: 100%;
  }
  /* Hub View/Filter rails: docked full-height columns (Calendar Filter flush) */
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body > .sky-filter.sky-filter-premium,
  body:not(.shell-phone) .sky-customers .sky-hub-body > .sky-filter.sky-filter-premium {
    align-self: stretch;
    border-radius: 0;
    box-shadow: none;
    max-height: calc(100dvh - var(--hdr-h) - 20px);
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-meta {
    font-size: 0.82rem;
    color: var(--muted);
    padding: 0 2px 10px;
  }

  /* Tasks ? denser premium rows (resize vars from sibling still apply) */
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-tasks .sky-page-main.sky-canvas {
    width: 100%;
    /* Left pad keeps Due badge clear of flush edge after crm294 shell-pad:0 */
    padding: 10px 12px 14px 16px;
  }
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-row {
    padding: 9px 10px 9px 14px;
    gap: 10px 12px;
    border-radius: 8px;
  }
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-head {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 6px 10px 8px 14px;
    margin: 0 0 2px;
    background: color-mix(in srgb, var(--bg-elevated) 92%, #000);
    backdrop-filter: blur(8px);
    font-size: 0.68rem;
    letter-spacing: 0.05em;
  }
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-col-acct,
  body:not(.shell-phone) .sky-hub-tasks .sky-tasks-col-who {
    font-size: 0.84rem;
  }
  body:not(.shell-phone) .sky-task-due-badge {
    border-radius: var(--btn-chip-radius);
    min-height: 24px;
    padding: 2px 9px;
    font-size: 0.72rem;
    border: 1px solid transparent;
    background: var(--btn-ghost-bg);
    box-shadow: var(--btn-ghost-shadow);
  }
  body:not(.shell-phone) .sky-task-due-badge.is-anytime {
    border: 1px solid var(--btn-ghost-border);
    border-style: solid;
    background: var(--btn-ghost-bg);
    color: var(--muted);
  }
  body:not(.shell-phone) .btn.ghost.sky-task-done-btn {
    border-radius: var(--btn-radius);
    border: 1px solid var(--btn-ghost-border);
    background: var(--btn-ghost-bg);
    box-shadow: var(--btn-ghost-shadow);
    min-height: 30px;
    padding: 4px 10px;
    font-size: 0.78rem;
    color: var(--ink-secondary);
  }
  body:not(.shell-phone) .btn.ghost.sky-task-done-btn:hover {
    color: var(--ink);
    border-color: rgba(255, 255, 255, 0.16);
  }

  /* Forms ? denser table + schema cards */
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th,
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td {
    padding-top: 8px;
    padding-bottom: 8px;
    font-size: 0.86rem;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th {
    font-size: 0.68rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: var(--fw-semi);
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-grid {
    gap: 12px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-form-card {
    min-height: 88px;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    border-color: var(--line-strong);
    box-shadow: var(--btn-ghost-shadow);
    transition: border-color 0.14s var(--ease), background 0.14s var(--ease), transform 0.12s var(--ease);
  }
  body:not(.shell-phone) .sky-hub-forms .sky-form-card:hover,
  body:not(.shell-phone) .sky-hub-forms .sky-form-card.is-on {
    transform: translateY(-1px);
    border-color: color-mix(in srgb, var(--accent) 45%, var(--line-strong));
  }

  /* Timeline hub ? denser cards; density classes own padding via --crm-tl-* */
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-timeline .sky-page-main.sky-canvas {
    width: 100%;
    padding: 12px 14px 16px;
  }
  body:not(.shell-phone) .sky-hub-timeline .sky-tl-card {
    padding: var(--crm-tl-pad-y, 10px) var(--crm-tl-pad-x, 12px);
    gap: var(--crm-tl-gap, 10px);
    border-radius: 10px;
  }
  body:not(.shell-phone) .sky-hub-timeline .sky-tl-group-head {
    padding: 8px 4px;
  }
  body:not(.shell-phone) .sky-tl-chip {
    border-radius: var(--btn-chip-radius);
    border: 1px solid var(--btn-ghost-border);
    background: var(--btn-ghost-bg);
    box-shadow: var(--btn-ghost-shadow);
    min-height: 32px;
    padding: 5px 11px;
    font-size: 0.78rem;
  }
  body:not(.shell-phone) .sky-tl-chip.is-on {
    border-color: var(--btn-chip-on-border);
    background: var(--btn-chip-on-bg);
    box-shadow: var(--btn-chip-on-shadow);
    color: #fff;
  }

  /* Hub Add ? always token primary/ghost (kill quiet outline forks) */
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-tasks .btn.sky-hub-add {
    background: var(--btn-primary-bg);
    color: #fff;
    border: 1px solid var(--btn-primary-border);
    box-shadow: var(--btn-primary-shadow);
    border-radius: var(--btn-radius);
    min-height: 36px;
    padding: 7px 13px;
    font-size: 0.86rem;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-tasks .btn.sky-hub-add:hover {
    background: var(--btn-primary-bg-hover);
    border-color: var(--btn-primary-border);
    color: #fff;
    box-shadow: var(--btn-primary-shadow-hover);
  }

  /* Customers filter chips ? token chips */
  body:not(.shell-phone) .sky-cust-filter-chip {
    border-radius: var(--btn-chip-radius);
    border: 1px solid var(--btn-ghost-border);
    background: var(--btn-ghost-bg);
    box-shadow: var(--btn-ghost-shadow);
  }
  body:not(.shell-phone) .sky-cust-filter-chip.is-on,
  body:not(.shell-phone) .sky-cust-filter-chip.active {
    border-color: var(--btn-chip-on-border);
    background: var(--btn-chip-on-bg);
    box-shadow: var(--btn-chip-on-shadow);
    color: #fff;
  }
}

/* Wave M1 cascade guard: later desk-density rules may not reintroduce an
   intrinsic viewport minimum inside the explicitly sized hub canvas. */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body,
  body:not(.shell-phone) .sky-customers.is-pc .sky-hub-body,
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.is-pc .sky-page-main.sky-canvas {
    min-height: 0;
  }
}

/* M5 ? Home, Settings and Admin use the remaining desktop canvas without
   turning Settings into an ultrawide spreadsheet. Phone stays naturally
   scrollable under its existing bottom navigation. */
@media (min-width: 901px) {
  body:not(.shell-phone) .app-shell:has(.crm-home.is-pc),
  body:not(.shell-phone) .app-shell:has(.settings-panel.settings-page),
  body:not(.shell-phone) .app-shell:has(.admin-card){
    min-height: 100dvh;
  }
  body:not(.shell-phone) .app-shell:has(.crm-home.is-pc) .app-body,
  body:not(.shell-phone) .app-shell:has(.settings-panel.settings-page) .app-body,
  body:not(.shell-phone) .app-shell:has(.admin-card) .app-body{
    align-items: stretch;
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 16px);
  }
  body:not(.shell-phone) .app-content:has(.crm-home.is-pc),
  body:not(.shell-phone) .app-content:has(.settings-panel.settings-page),
  body:not(.shell-phone) .app-content:has(.admin-card){
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  /* Dashboard: compact priority strips above a usable, elastic work area. */
  body:not(.shell-phone) .crm-home.is-pc{
    flex: 1 1 auto;
    min-height: 0;
    max-width: none;
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body{
    min-height: clamp(260px, 34dvh, 520px);
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body > .home-blocks,
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body > .home-quick-grid,
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body > .dash-rail-card{
    align-content: start;
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body > .home-blocks .home-block,
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body > .home-quick-grid .home-quick{
    min-height: 76px;
  }
  body:not(.shell-phone) .crm-home.is-pc .crm-home-panel .home-widget-body{
    overflow: auto;
  }

  /* Settings remains a deliberate readable column, but its card owns the
     visible work area instead of leaving a black lower half. */
  body:not(.shell-phone) .settings-panel.settings-page{
    width: min(820px, 100%);
    min-height: min(680px, calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 16px));
    margin: 0 auto;
    box-sizing: border-box;
  }

  /* Admin tabs are workspaces: table/preview areas absorb available height. */
  body:not(.shell-phone) .admin-card{
    width: 100%;
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 16px);
    margin: 0;
    box-sizing: border-box;
  }
  body:not(.shell-phone) .admin-card.admin-tab-users{
    display: flex;
    flex-direction: column;
  }
  body:not(.shell-phone) .admin-card.admin-tab-users .admin-user-list{
    flex: 1 1 auto;
    min-height: 220px;
  }
  body:not(.shell-phone) .admin-card.admin-tab-users .admin-table-wrap{
    display: none;
  }
  body:not(.shell-phone) .admin-card.admin-tab-homes .admin-homes-studio{
    min-height: min(600px, calc(100dvh - var(--hdr-h) - 150px));
  }
  body:not(.shell-phone) .admin-card.admin-tab-homes .homes-preview-stage{
    flex: 1 1 auto;
  }
  body:not(.shell-phone) .admin-card.admin-tab-deliveries .admin-deliveries{
    min-height: min(500px, calc(100dvh - var(--hdr-h) - 170px));
  }

  /* Context Nav follows the flush-right Calendar Filter language when open. */
  body:not(.shell-phone) .app-shell:has(.settings-panel.settings-page) .side-nav.crm-smart-rail,
  body:not(.shell-phone) .app-shell:has(.admin-card) .side-nav.crm-smart-rail{
    align-self: stretch;
    position: sticky;
    top: calc(var(--hdr-h) + var(--hdr-gap-y));
    max-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 16px);
    border: 0;
    border-left: 1px solid var(--rail-line);
    border-radius: 0;
    margin-top: 0;
  }

  /* Printed call form retains its readable column; only the surrounding
     workspace gets enough depth to avoid an abrupt black cutoff. */
  body:not(.shell-phone) .app-content:has(.sky-form-wrap){
    min-height: calc(100dvh - var(--hdr-h) - var(--hdr-gap-y) - 16px);
  }
  body:not(.shell-phone) .sky-form-wrap{
    min-height: min(620px, calc(100dvh - var(--hdr-h) - 100px));
  }
}

/* ===== crm294 / crm303 / crm311 / crm314 ? PC hub + Home edge-to-edge =====
   Root cause of ?boxed with black gutters?: shell still used --shell-pad-x:20px
   and .sky-page-body { gap:12px }, so the elevated .sky-canvas + Filter sat as
   floating cards with black strips (Calendar already uses gap:0 + flush rail).
   --hub-max:none alone was not enough. Settings 820px + invoice paper untouched.
   crm303: also flush .sky-customer-hub (was still padded under FORCE scope).
   crm311: Home (.crm-home.is-pc) was still on the padded/legacy band ? same flush
   as Customers/Timeline so deals + call plan span the panel (phone untouched).
   crm314: app-content/app-body stretch + canvas 16px inset; Details desk always open. */
@media (min-width: 901px) {
  body:not(.shell-phone) .app-shell.screen:has(.sky-hub-page.is-pc),
  body:not(.shell-phone) .app-shell.screen:has(.sky-customers.is-pc),
  body:not(.shell-phone) .app-shell.screen:has(.sky-customers.sky-customers-map),
  body:not(.shell-phone) .app-shell.screen:has(.sky-customer-hub.is-pc),
  body:not(.shell-phone) .app-shell.screen:has(.crm-home.is-pc),
  body:not(.shell-phone) .app-shell.screen:has(.sky-shop.is-pc),
  body:not(.shell-phone) .app-shell.screen.shop-screen {
    --shell-pad-x: 0px;
    --hub-max: none;
    max-width: none !important;
    width: 100%;
    margin: 0 !important;
    padding-left: 0;
    padding-right: 0;
  }

  /* Header keeps 16px inset when shell pad is killed (logo/nav not glass-flush). */
  body:not(.shell-phone) .app-shell.screen:has(.sky-hub-page.is-pc) .app-header,
  body:not(.shell-phone) .app-shell.screen:has(.sky-customers.is-pc) .app-header,
  body:not(.shell-phone) .app-shell.screen:has(.sky-customers.sky-customers-map) .app-header,
  body:not(.shell-phone) .app-shell.screen:has(.sky-customer-hub.is-pc) .app-header,
  body:not(.shell-phone) .app-shell.screen:has(.crm-home.is-pc) .app-header,
  body:not(.shell-phone) .app-shell.screen:has(.sky-shop.is-pc) .app-header,
  body:not(.shell-phone) .app-shell.screen.shop-screen .app-header {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
    padding-left: 16px;
    padding-right: 16px;
  }

  body:not(.shell-phone) .app-content:has(.sky-hub-page.is-pc),
  body:not(.shell-phone) .app-content:has(.sky-customers.is-pc),
  body:not(.shell-phone) .app-content:has(.sky-customers.sky-customers-map),
  body:not(.shell-phone) .app-content:has(.sky-customer-hub.is-pc),
  body:not(.shell-phone) .app-content:has(.sky-shop.is-pc) {
    width: 100%;
    max-width: none;
    margin: 0;
    min-width: 0;
  }
  body:not(.shell-phone) .app-shell.screen:has(.sky-hub-page.is-pc) .app-body,
  body:not(.shell-phone) .app-shell.screen:has(.sky-customers.is-pc) .app-body,
  body:not(.shell-phone) .app-shell.screen:has(.sky-customer-hub.is-pc) .app-body,
  body:not(.shell-phone) .app-shell.screen:has(.sky-shop.is-pc) .app-body,
  body:not(.shell-phone) .app-shell.screen.shop-screen .app-body {
    width: 100%;
    max-width: none;
    gap: 0;
    align-items: stretch;
  }

  body:not(.shell-phone) .sky-hub-page.is-pc,
  body:not(.shell-phone) .sky-customers.is-pc,
  body:not(.shell-phone) .sky-customers.sky-customers-map,
  body:not(.shell-phone) .sky-customer-hub.is-pc,
  body:not(.shell-phone) .crm-home.is-pc {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    box-sizing: border-box;
  }

  body:not(.shell-phone) .sky-customer-hub.is-pc,
  body:not(.shell-phone) .crm-home.is-pc {
    padding-left: 16px;
    padding-right: 16px;
  }

  /* Home sections (Running deals / Call plan / body) own the panel width. */
  body:not(.shell-phone) .crm-home.is-pc .home-deals,
  body:not(.shell-phone) .crm-home.is-pc .home-radar,
  body:not(.shell-phone) .crm-home.is-pc .crm-home-body,
  body:not(.shell-phone) .crm-home.is-pc .crm-home-panel,
  body:not(.shell-phone) .crm-home.is-pc .home-blocks,
  body:not(.shell-phone) .crm-home.is-pc .home-quick-grid {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
  }

  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-head,
  body:not(.shell-phone) .sky-customers.is-pc .sky-page-head,
  body:not(.shell-phone) .sky-customers.sky-customers-map .sky-page-head {
    padding-left: 16px;
    padding-right: 16px;
    box-sizing: border-box;
  }

  /* Calendar desk-row language: no black gutter between canvas and Filter. */
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body,
  body:not(.shell-phone) .sky-customers.is-pc .sky-hub-body,
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-body {
    gap: 0;
    width: 100%;
    margin: 0;
  }

  body:not(.shell-phone) .sky-hub-page.is-pc .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.is-pc .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.sky-customers-map .sky-page-main.sky-canvas.outlets-map-panel {
    width: 100%;
    max-width: none;
    margin: 0;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    box-sizing: border-box;
    /* ~16px content inset ? shell pad is 0; avoid glass-flush text */
    padding-left: 16px;
    padding-right: 16px;
  }
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-tl-groups,
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-tl-skel,
  body:not(.shell-phone) .sky-customers.is-pc .results.sky-list {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
  }

  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body:has(.sky-filter-rail) > .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body:has(.sky-view-rail) > .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.is-pc .sky-hub-body:has(.sky-filter-rail) > .sky-page-main.sky-canvas,
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-body:has(> .sky-filter) > .sky-page-main.sky-canvas {
    border-right: 0;
  }

  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body > .sky-filter.sky-filter-premium,
  body:not(.shell-phone) .sky-hub-page.is-pc .sky-hub-body > .sky-view-rail,
  body:not(.shell-phone) .sky-customers.is-pc .sky-hub-body > .sky-filter.sky-filter-premium,
  body:not(.shell-phone) .sky-customers.sky-customers-map .outlets-map-body > .sky-filter.sky-filter-premium {
    border-radius: 0;
    border: 0;
    border-left: 1px solid var(--rail-line);
    box-shadow: none;
    margin: 0;
  }
}

/* Home promo editor (Roei only) ? list + focused edit pane */
.home-promo-edit-back {
  padding: max(10px, env(safe-area-inset-top, 0px)) 12px
    max(12px, env(safe-area-inset-bottom, 0px));
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 80;
}
.home-promo-edit-sheet {
  width: min(96vw, 720px);
  max-height: min(94vh, 960px);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55), var(--shadow);
}
.home-promo-edit-sheet.is-editing .home-promo-edit-body {
  padding-top: 8px;
}
.home-promo-edit-sheet .sky-modal-head {
  flex-shrink: 0;
  margin: 0;
  padding: 14px 14px 12px;
  border-bottom: 1px solid var(--line);
}
.home-promo-edit-lead {
  margin: 0;
  padding: 8px 14px 0;
  flex-shrink: 0;
  font-size: 0.88rem;
  line-height: 1.4;
}
.home-promo-edit-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.home-promo-edit-list-label {
  margin: 8px 2px 0;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
/* List mode ? flat summary rows */
.home-promo-edit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg);
}
.home-promo-edit-row.is-inactive {
  opacity: 0.72;
  border-style: dashed;
}
.home-promo-edit-row-main {
  flex: 1 1 10rem;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.home-promo-edit-row-main strong {
  font-size: 0.92rem;
  line-height: 1.25;
}
.home-promo-edit-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex: 0 1 auto;
}
.home-promo-edit-actions .btn.small {
  min-height: var(--btn-h-sm);
  padding: var(--btn-pad-y) 10px;
  font-size: var(--btn-fs-sm);
}
.home-promo-edit-settings {
  min-width: 5.5rem;
  justify-content: center;
}
.home-promo-edit-summary {
  margin: 0;
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.home-promo-edit-empty {
  margin: 0;
  padding: 8px 2px;
  font-size: 0.88rem;
  color: var(--muted);
}
.home-promo-edit-add-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 8px;
  margin-top: 4px;
  border-top: 1px solid var(--line);
}
.home-promo-edit-add-cta {
  width: 100%;
  justify-content: center;
  min-height: var(--btn-h);
  font-weight: var(--fw-med);
}
.home-promo-edit-history {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.home-promo-edit-history summary.home-promo-edit-list-label {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.home-promo-edit-history summary.home-promo-edit-list-label::-webkit-details-marker {
  display: none;
}
.home-promo-edit-history-count {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  color: var(--muted);
  padding: 2px 7px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--line);
  background: var(--bg);
}
.home-promo-edit-history-hint {
  margin: 0 0 8px;
}
.home-promo-edit-history-row {
  opacity: 0.88;
}
/* Edit mode ? focused pane with live preview */
.home-promo-edit-pane {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
/* Sheet head while editing: Back | title | close, title truly centred. */
.sky-modal-head.has-back {
  align-items: center;
}
.sky-modal-head.has-back h2 {
  flex: 1 1 auto;
  text-align: center;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.home-promo-edit-done {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  width: auto;
  min-width: 44px;
}
.home-promo-edit-preview {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: color-mix(in srgb, var(--bg) 92%, var(--bg-elevated));
}
.home-promo-edit-preview-label {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-promo-edit-preview-inner {
  pointer-events: none;
  --deals-card-visual: 72px;
  --deals-card-thumb: 64px;
  --home-deal-media-h: 96px;
  /* Same accent tokens as .home-deals ? preview sits outside that section. */
  --deals-a-1: #f59e0b;
  --deals-a-2: #f97316;
  --deals-a-3: #e11d48;
  --deals-b-1: #0d9488;
  --deals-b-2: #22c55e;
  --deals-b-3: #a3e635;
  --deals-c-1: #be123c;
  --deals-c-2: #9f1239;
  --deals-c-3: #7f1d1d;
  --deals-d-1: #4338ca;
  --deals-d-2: #6366f1;
  --deals-d-3: #818cf8;
  --deals-e-1: #7c3aed;
  --deals-e-2: #a855f7;
  --deals-e-3: #c084fc;
  --deals-f-1: #e11d48;
  --deals-f-2: #f43f5e;
  --deals-f-3: #fb7185;
  --deals-g-1: #0369a1;
  --deals-g-2: #0ea5e9;
  --deals-g-3: #38bdf8;
  --deals-h-1: #ca8a04;
  --deals-h-2: #eab308;
  --deals-h-3: #fde047;
}
.home-promo-edit-preview-card {
  width: 100%;
  min-height: 76px;
  cursor: default;
  text-align: left;
}
.home-promo-edit-preview-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 4px 2px;
}
.home-promo-edit-preview-section-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: var(--fw-med);
  line-height: 1.2;
}
.home-promo-edit-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
/* Grouped inset list - label left, value right, hairline separators. The loose
   stack of floating labels + boxed inputs read as a web form, not a settings
   sheet. */
.home-promo-edit-basic {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated-2);
  overflow: hidden;
}
.home-promo-edit-basic > label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 46px;
  padding: 6px 12px;
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.home-promo-edit-basic > label:last-child,
.home-promo-edit-basic > .home-promo-accent-row:last-child {
  border-bottom: 0;
}
.home-promo-edit-basic > label > input {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  background: none;
  border: 0;
  padding: 6px 0;
}
.home-promo-edit-basic > label > input:focus-visible {
  outline: none;
  box-shadow: none;
  color: var(--accent);
}
.home-promo-edit-basic .home-promo-accent-row {
  min-height: 46px;
  padding: 6px 12px;
  border-bottom: 1px solid var(--line);
}
.home-promo-edit-basic input,
.home-promo-edit-basic select,
.home-promo-edit-basic textarea,
.home-promo-edit-more-body input,
.home-promo-edit-more-body select,
.home-promo-edit-more-body textarea {
  font: inherit;
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--ink);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  padding: 8px 10px;
}
.home-promo-edit-active {
  padding: 6px 12px;
}
.home-promo-edit-more {
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated-2);
  overflow: hidden;
}
/* Disclosure row, not a full-width dark slab. */
.home-promo-edit-more summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 46px;
  padding: 6px 12px;
  font-size: 0.92rem;
  font-weight: var(--fw-med);
  color: var(--ink);
}
.home-promo-edit-more summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border: solid var(--muted);
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(45deg);
  margin-right: 3px;
  transition: transform 0.18s var(--ease);
}
.home-promo-edit-more[open] summary::after {
  transform: rotate(-135deg);
  margin-top: 4px;
}
.home-promo-edit-more summary::-webkit-details-marker {
  display: none;
}
.home-promo-edit-more[open] summary {
  border-bottom: 1px solid var(--line);
}
.home-promo-edit-more-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
}
.home-promo-edit-more-body label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-promo-edit-more-body textarea {
  text-transform: none;
  letter-spacing: 0;
}
/* Legacy card classes kept for grid/thumbs inside edit fields */
.home-promo-edit-card {
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  background: var(--bg);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.home-promo-edit-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--muted);
  cursor: pointer;
}
.home-promo-edit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.home-promo-edit-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
}
.home-promo-edit-grid input,
.home-promo-edit-grid select,
.home-promo-edit-grid textarea {
  font: inherit;
  font-size: 0.92rem;
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--btn-chip-radius);
  padding: 8px 10px;
}
.home-promo-edit-span2 {
  grid-column: 1 / -1;
}
.home-promo-edit-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.home-promo-edit-thumb {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: var(--btn-chip-radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #111;
}
.home-promo-edit-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.home-promo-edit-thumb .btn {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 0;
  padding: 2px 4px;
  --btn-h-sm: 22px;
}
.home-promo-edit-img-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.home-promo-upload-btn {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.home-promo-edit-foot {
  flex-shrink: 0;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  background: var(--bg-elevated);
}
/* Compact accent swatch + popover picker (Block / Banner settings). */
.home-promo-accent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 0;
}
.home-promo-accent-label {
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--muted);
}
/* Inside the grouped list the Colour row is a peer of Headline/Subline. */
.home-promo-edit-basic .home-promo-accent-label {
  font-size: 0.92rem;
  color: var(--ink);
}
.home-promo-accent-picker-wrap {
  position: relative;
  flex-shrink: 0;
}
.home-promo-accent-swatch-btn {
  appearance: none;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  border-radius: var(--btn-chip-radius);
  padding: 4px;
  cursor: pointer;
  box-shadow: var(--btn-ghost-shadow);
  line-height: 0;
  transition: border-color 0.14s var(--ease), box-shadow 0.14s var(--ease);
}
.home-promo-accent-swatch-btn:hover {
  border-color: var(--line-strong);
}
.home-promo-accent-swatch-btn:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
.home-promo-accent-swatch {
  display: block;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.18);
}
.home-promo-accent-pop {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 12;
  width: min(240px, 72vw);
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated);
  box-shadow: var(--btn-ghost-shadow);
}
.home-promo-accent-pop-head {
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 6px;
}
.home-promo-accent-pop-head + .home-promo-accent-grid {
  margin-bottom: 8px;
}
.home-promo-accent-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.home-promo-accent-opt {
  appearance: none;
  width: 100%;
  aspect-ratio: 1;
  border: 2px solid transparent;
  border-radius: var(--btn-chip-radius);
  cursor: pointer;
  padding: 0;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
  transition: transform 0.12s var(--ease), border-color 0.12s var(--ease);
}
.home-promo-accent-opt:hover {
  transform: scale(1.06);
}
.home-promo-accent-opt.is-on {
  border-color: var(--btn-chip-on-border, var(--accent));
  box-shadow: var(--btn-chip-on-shadow, var(--btn-focus-ring));
}
.home-promo-accent-opt:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring);
}
@media (max-width: 640px) {
  .home-promo-edit-grid {
    grid-template-columns: 1fr;
  }
}


/* Settings → Forms editor (Users-kit inset list + quiet toolbar) */
.forms-editor.is-list .forms-editor-picks {
  margin: 0;
}
.forms-editor-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.forms-editor-list-head .settings-section-label {
  margin: 0;
}
.forms-editor-list-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.forms-editor-list-actions .btn {
  margin: 0;
  flex: none;
  width: auto;
  white-space: nowrap;
}
.forms-editor-list-actions #btnFeAddForm {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
/* Coherent icon · title/meta · chevron grid (organized-list-grid). */
.forms-editor-picks .forms-editor-pick {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 18px;
  align-items: center;
  column-gap: 12px;
  row-gap: 0;
  min-height: var(--btn-h, 44px);
  padding: 10px 14px;
  box-sizing: border-box;
}
.forms-editor-picks .forms-editor-pick .settings-row-main {
  min-width: 0;
}
.forms-editor-picks .forms-editor-pick .settings-row-title,
.forms-editor-picks .forms-editor-pick .settings-row-blurb {
  overflow: hidden;
  text-overflow: ellipsis;
}
.forms-editor-back-list {
  margin: 0 0 12px;
}
.forms-editor-back {
  margin: 0;
  width: 100%;
  text-align: left;
}
.forms-editor-detail {
  margin-top: 16px;
  padding-top: 4px;
}
.forms-editor-meta-list {
  overflow: visible;
}
.forms-editor-meta,
.forms-editor-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  width: 100%;
}
.forms-editor-meta {
  padding: 14px;
  box-sizing: border-box;
}
.forms-editor-meta label,
.forms-editor-field-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.82rem;
  color: var(--muted);
}
.forms-editor-meta input,
.forms-editor-meta select,
.forms-editor-field-grid input,
.forms-editor-field-grid select {
  width: 100%;
}
.forms-editor-dep {
  align-self: end;
  margin-bottom: 2px;
}
.forms-editor-dep-row {
  grid-column: 1 / -1;
  border: 0;
  background: transparent;
  padding: 8px 0 0;
  min-height: 0;
}
.forms-editor-field-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 4px 2px 10px;
}
.forms-editor-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: var(--btn-chip-radius, 12px);
  font-size: 0.78rem;
  color: var(--ink-secondary);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}
.forms-editor-fields {
  gap: 0;
}
/* Expand rows = inset hairlines in one elevated list (not nested dark cards). */
.forms-editor-field.settings-row.is-inset {
  flex-direction: column;
  align-items: stretch;
  min-height: 0;
  padding: 0;
  background: transparent;
  gap: 0;
}
.settings-list.forms-editor-fields > .forms-editor-field:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.forms-editor-field-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18px;
  align-items: center;
  column-gap: 10px;
  width: 100%;
  min-height: var(--btn-h, 44px);
  padding: 10px 14px;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  box-sizing: border-box;
}
.forms-editor-field-head-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.forms-editor-field-title {
  font-size: 0.92rem;
  font-weight: var(--fw-semi, 600);
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
}
.forms-editor-field-meta {
  font-size: 0.76rem;
  color: var(--muted);
  font-family: var(--font);
  letter-spacing: 0.01em;
  overflow: hidden;
  text-overflow: ellipsis;
}
.forms-editor-field-chev {
  flex: none;
  justify-self: end;
  opacity: 0.55;
  transition: transform 0.18s ease;
}
.forms-editor-field.is-open .forms-editor-field-chev {
  transform: rotate(180deg);
}
.forms-editor-field.is-open .forms-editor-field-grid,
.forms-editor-field.is-open .forms-editor-req,
.forms-editor-field.is-open .forms-editor-field-foot {
  padding-left: 14px;
  padding-right: 14px;
}
.forms-editor-field.is-open .forms-editor-field-grid {
  padding-top: 4px;
  padding-bottom: 4px;
}
.forms-editor-field.is-open .forms-editor-field-foot {
  padding-bottom: 12px;
}
.forms-editor-field-foot {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}
/* Required switch — kit ghost well + toggle. */
.forms-editor-req {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: var(--btn-chip-radius, 12px);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
}
.forms-editor-req-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1 1 auto;
}
.forms-editor-req-main strong {
  font-size: 0.88rem;
  color: var(--ink);
}
.forms-editor-req-blurb {
  font-size: 0.76rem;
  color: var(--muted);
}
.forms-editor-field.is-req {
  box-shadow: inset 3px 0 0 var(--accent);
}
/* Soft tint only — avoid a wall of blue when many fields are required. */
.forms-editor-field.is-req .forms-editor-req {
  border-color: color-mix(in srgb, var(--accent) 42%, transparent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
}
.forms-editor-pick-meta {
  font-family: inherit;
  font-size: 0.76rem;
  opacity: 0.85;
}
.forms-editor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.forms-editor-actions-ios {
  margin-top: 14px;
  padding: 0 2px;
  gap: 10px;
}
.forms-editor-actions-ios .btn {
  flex: none;
  width: auto;
  margin: 0;
}
.forms-editor-actions-ios #btnFeAddForm {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
@media (max-width: 720px) {
  .forms-editor-list-head {
    align-items: center;
    flex-wrap: wrap;
  }
  .forms-editor-list-actions {
    width: auto;
    margin-left: auto;
  }
  .forms-editor-list-actions .btn {
    flex: none;
  }
  .forms-editor-meta,
  .forms-editor-field-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Phone Timeline iOS (main hub + customer hub Activity) ? crm433 =====
   Was inheriting the PC 3-col card grid (70px abs-time | 30px icon | 1fr) ?
   starved content, cut off trail chips. Phone-only; PC Timeline untouched.
   Shared surface: .sky-hub-timeline + .sky-customer-hub / .sky-dash-timeline. */

body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub) .btn.sky-hub-add {
  width: auto;
  flex: 0 0 auto;
}
body.shell-phone .sky-hub-timeline .sky-page-head-actions {
  flex-wrap: nowrap;
}

body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline).crm-density-compact,
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub) .crm-density-compact,
body.shell-phone .sky-customer-hub {
  --crm-tl-pad-y: 8px;
  --crm-tl-pad-x: 8px;
  --crm-tl-gap: 8px;
  --crm-tl-title: 0.9rem;
  --crm-tl-sub: 0.76rem;
  --crm-tl-main-gap: 2px;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card,
body.shell-phone .crm-acct-card .sky-tl-card {
  grid-template-columns: 30px minmax(0, 1fr);
  gap: var(--crm-tl-gap, 8px);
  padding: var(--crm-tl-pad-y, 8px) var(--crm-tl-pad-x, 8px);
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-time,
body.shell-phone .crm-acct-card .sky-tl-card-time {
  display: none;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-group-body::before,
body.shell-phone .crm-acct-card .sky-tl-group-body::before {
  left: 23px; /* card padding-left (8px) + half the 30px icon rail (15px) */
}

body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-row1,
body.shell-phone .crm-acct-card .sky-tl-card-row1 {
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-headline,
body.shell-phone .crm-acct-card .sky-tl-card-headline {
  width: 100%;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-cust,
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-title,
body.shell-phone .crm-acct-card .sky-tl-card-cust,
body.shell-phone .crm-acct-card .sky-tl-card-title {
  font-size: var(--crm-tl-title, 0.9rem);
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  line-height: 1.3;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-sub,
body.shell-phone .crm-acct-card .sky-tl-card-sub {
  font-size: var(--crm-tl-sub, 0.76rem);
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-trail,
body.shell-phone .crm-acct-card .sky-tl-card-trail {
  width: 100%;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 6px 8px;
  margin-top: 0;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card-time-rel,
body.shell-phone .crm-acct-card .sky-tl-card-time-rel {
  order: 99;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-meta-chip.is-ico-only,
body.shell-phone .crm-acct-card .sky-tl-meta-chip.is-ico-only {
  min-width: var(--btn-h-sm, 34px);
  min-height: var(--btn-h-sm, 34px);
  padding: 6px;
}

/* iOS section headers ? day buckets */
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-group-head,
body.shell-phone .crm-acct-card .sky-tl-group-head {
  padding: 10px 8px 8px;
  min-height: 36px;
}
body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-group-label,
body.shell-phone .crm-acct-card .sky-tl-group-label {
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
}

@media (max-width: 380px) {
  body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-card,
  body.shell-phone .crm-acct-card .sky-tl-card {
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 8px;
  }
  body.shell-phone :is(.sky-hub-timeline, .sky-customer-hub, .sky-dash-timeline) .sky-tl-group-body::before,
  body.shell-phone .crm-acct-card .sky-tl-group-body::before {
    left: 21px;
  }
}

body.shell-phone .sky-hub-timeline .sky-tl-groups,
body.shell-phone .sky-customer-hub .sky-tl-groups,
body.shell-phone .sky-dash-timeline .sky-tl-groups {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
}
body.shell-phone .sky-hub-timeline .sky-page-main.sky-canvas {
  overflow: visible;
}
body.shell-phone .sky-hub-timeline .sky-tl-load-more {
  margin: 14px auto 10px;
}

/* ===== crm408 Wave 0+1 ? iOS tap floors + cart Send thumb dock ===== */
body.shell-phone .sky-cust-filter-chip {
  min-height: var(--btn-h);
  padding: 8px 14px;
  font-size: 0.82rem;
  appearance: none;
  -webkit-appearance: none;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px)) !important;
}
/* crm415 ? cart sticky taller (3 VAT rows); Send clears bottom nav; VAT not clipped */
body.shell-phone {
  --cart-sticky-pad-y: 10px;
  --cart-sticky-pad-x: 12px;
  --cart-sticky-row-gap: 5px;
  /* pad + 3 VAT rows + 3?--btn-h CTAs + compact btn gaps */
  --cart-sticky-h: calc(
    (var(--cart-sticky-pad-y) * 2) +
    (3 * 1.3em) +
    (3 * var(--cart-sticky-row-gap)) +
    (3 * var(--btn-h)) +
    20px
  );
}
body.shell-phone .sticky.cart-checkout-sticky {
  /* crm422: in-flow only ? fixed/sticky covered Assign CTAs or left a black void. */
  position: static;
  left: auto;
  right: auto;
  bottom: auto;
  z-index: auto;
  margin-top: 14px;
  max-width: none;
  box-sizing: border-box;
  padding: 0;
  max-height: none;
  overflow: visible;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
}
body.shell-phone .sticky.cart-checkout-sticky.is-empty {
  margin-top: 14px;
}
body.shell-phone .sticky.cart-checkout-sticky .cart-money-row {
  min-height: 44px;
  font-size: 0.86rem;
  line-height: 1.25;
}
body.shell-phone .sticky.cart-checkout-sticky .cart-money-row.cart-total-incl {
  min-height: 54px;
}
body.shell-phone .sticky.cart-checkout-sticky .btn {
  margin-top: 8px;
}
body.shell-phone .sticky.cart-checkout-sticky .btn:first-of-type {
  margin-top: 4px;
}
body.shell-phone .checkout-box,
body.shell-phone .sky-cart .app-content,
body.shell-phone .cart-card {
  padding-bottom: calc(var(--cart-sticky-h, 180px) + 28px);
}

/* crm415 ? driver .route-board lightly align to calendar token language */
body.shell-phone .route-board.day-board-card,
body.shell-phone .card.route-board {
  border-color: var(--acal-line, var(--line));
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  box-shadow: none;
}
body.shell-phone .route-board-head {
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--acal-line, var(--line));
}
body.shell-phone .route-board-head h1 {
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  font-weight: var(--fw-semi);
}
body.shell-phone .route-board-head .sub,
body.shell-phone .route-board-head .day-meta {
  color: var(--acal-muted, var(--muted));
  font-size: 0.75rem;
}
body.shell-phone .route-board .route-list {
  border-color: var(--acal-line, rgba(255, 255, 255, 0.06));
  background: var(--bg-elevated-2, var(--bg-elevated));
}
body.shell-phone .route-board .route-stop {
  border: 0;
  border-radius: 0;
  background: transparent;
}

/* ===== Customers list ? Filter chips + phone sheet (list ownership; no ?v=) =====
   Visit/Rep/Category/Region use .sky-cust-filter-chip (not .acal-people-chip). */
.sky-customers .sky-filter.sky-filter-premium .sky-cust-filter-chips,
.sky-customers .sky-filter-rail .sky-cust-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 8px;
}
.sky-customers .sky-filter.sky-filter-premium .sky-cust-filter-chip,
.sky-customers .sky-filter-rail .sky-cust-filter-chip {
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px)) !important;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  min-height: 30px;
  padding: 5px 11px;
  font-size: 0.76rem;
}
.sky-customers .sky-filter.sky-filter-premium .sky-cust-filter-chip.is-on,
.sky-customers .sky-filter-rail .sky-cust-filter-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
/* Phone Filters sheet chips for Customers list (sheet is outside .sky-customers). */
body.shell-phone .acal-filters-sheet .sky-cust-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
body.shell-phone .acal-filters-sheet .sky-cust-filter-chip {
  min-height: var(--btn-h);
  padding: 8px 14px;
  font-size: var(--btn-fs-sm, 0.82rem);
  appearance: none;
  -webkit-appearance: none;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px)) !important;
}
body.shell-phone .acal-filters-sheet .sky-cust-filter-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
/* Reinforce List|Map|Near segs to --btn-h on phone list chrome. */
body.shell-phone .sky-customers .cust-view-toggle.img-size-toggle {
  min-height: var(--btn-h);
}
body.shell-phone .sky-customers .cust-view-toggle .img-size-btn {
  min-height: calc(var(--btn-h) - 4px);
  height: calc(var(--btn-h) - 4px);
  padding: 0 9px;
}
body.shell-phone .sky-customers .cust-view-toggle .img-size-btn.active {
  background: var(--btn-seg-on);
  border-color: transparent;
  box-shadow: var(--btn-seg-on-shadow);
  color: #fff;
}

/* ===== crm426: Customers phone iOS comfort ? List + Map + Near + Filters ===== */

/* --- List: name + next visit same row (iOS Contacts lean) --- */
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust {
  grid-template-columns: minmax(0, 1fr) auto !important;
  grid-template-areas: "name visit" !important;
  gap: 6px 10px !important;
  padding: 14px 30px 14px 12px !important;
  min-height: max(44px, var(--btn-h));
  align-items: center;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-name,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-name {
  grid-area: name;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  line-height: 1.28;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust > strong,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust > strong,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-meta,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-meta {
  display: none !important;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust .sky-cust-visit,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust .sky-cust-visit {
  grid-area: visit;
  grid-column: auto !important;
  font-size: 0.78rem;
  margin-top: 0;
  padding-left: 0;
  opacity: 0.92;
  white-space: nowrap;
  text-align: right;
  justify-self: end;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list .result.pick-cust::after,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-list .result.pick-cust::after {
  right: 10px;
  font-size: 1.35rem;
  opacity: 0.5;
  color: var(--muted);
}

/* --- List: whole-page scroll (no cramped inner .results box) --- */
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-hub-body,
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-page-main.sky-canvas {
  min-height: 0;
  overflow: visible;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .results.sky-list {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  overscroll-behavior: auto;
  padding-bottom: 12px;
}
body.shell-phone .sky-customers:not(.sky-customers-map):not(.sky-customers-near) .sky-page-meta {
  font-size: 0.78rem;
  color: var(--muted);
  padding: 4px 2px 8px;
}

/* --- Map: comfortable chrome above bottom-nav --- */
body.shell-phone .sky-customers.sky-customers-map .outlets-map-meta-row {
  gap: 8px 12px;
  padding: 2px 0 10px;
}
body.shell-phone .sky-customers.sky-customers-map .outlets-map-status {
  font-size: 0.84rem;
  line-height: 1.4;
  padding: 2px 0;
}
body.shell-phone .sky-customers.sky-customers-map .outlets-map-info-btn {
  width: max(44px, var(--btn-h));
  height: max(44px, var(--btn-h));
  min-width: 44px;
  min-height: 44px;
}
body.shell-phone .sky-customers.sky-customers-map .near-me-map-wrap {
  height: min(58dvh, 560px);
  min-height: 300px;
  margin-bottom: 4px;
}
body.shell-phone .sky-customers.sky-customers-map .sky-page-main.sky-canvas.outlets-map-panel {
  padding-bottom: 10px;
}
body.shell-phone .sky-customers.sky-customers-map .near-me-locate-btn {
  right: 12px;
  bottom: 12px;
  width: max(44px, var(--btn-h));
  height: max(44px, var(--btn-h));
  min-width: 44px;
  min-height: 44px;
}

/* --- Near me: name-first rows + map/list clearance + sticky CTA --- */
body.shell-phone .sky-customers-near .near-me-row,
body.shell-phone .sky-near-me .near-me-row {
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-areas:
    "name"
    "code"
    "meta" !important;
  gap: 2px 0 !important;
  padding: 14px 72px 14px 12px !important;
  min-height: max(44px, var(--btn-h));
  align-items: start;
}
body.shell-phone .sky-customers-near .near-me-row .sky-cust-name,
body.shell-phone .sky-near-me .near-me-row .sky-cust-name {
  grid-area: name;
  font-size: 1.05rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  line-height: 1.28;
  white-space: normal;
}
body.shell-phone .sky-customers-near .near-me-row > strong,
body.shell-phone .sky-near-me .near-me-row > strong {
  grid-area: code;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  color: var(--muted);
}
body.shell-phone .sky-customers-near .near-me-row .sky-cust-meta,
body.shell-phone .sky-near-me .near-me-row .sky-cust-meta {
  grid-area: meta;
  grid-column: auto;
  font-size: 0.74rem;
  color: var(--muted);
  opacity: 0.9;
  white-space: normal;
}
body.shell-phone .sky-customers-near .near-me-km,
body.shell-phone .sky-near-me .near-me-km {
  right: 14px;
  font-size: 0.78rem;
  opacity: 0.92;
}
body.shell-phone .sky-customers-near .near-me-map-wrap,
body.shell-phone .sky-near-me .near-me-map-wrap {
  height: min(48dvh, 480px);
  min-height: 260px;
}
body.shell-phone .sky-customers-near .near-me-locate-btn,
body.shell-phone .sky-near-me .near-me-locate-btn {
  right: 12px;
  bottom: 12px;
  width: max(44px, var(--btn-h));
  height: max(44px, var(--btn-h));
  min-width: 44px;
  min-height: 44px;
}
body.shell-phone .sky-customers-near .near-me-body,
body.shell-phone .sky-near-me .near-me-body {
  gap: 12px;
}
body.shell-phone .sky-customers-near .near-me-list-col .results.sky-list,
body.shell-phone .sky-near-me .near-me-list-col .results.sky-list {
  flex: 0 0 auto;
  overflow: visible;
  overscroll-behavior: auto;
  /* Clear sticky Start a visit only (nav is in-flow under .app-body). */
  padding-bottom: 80px;
}
body.shell-phone .sky-customers-near .sky-page-meta,
body.shell-phone .sky-near-me .sky-page-meta {
  font-size: 0.78rem;
  color: var(--muted);
  padding: 4px 2px 8px;
}
body.shell-phone .sky-customers-near .sky-page-head-actions .btn.sky-hub-add,
body.shell-phone .sky-near-me .sky-page-head-actions .btn.sky-hub-add {
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 12px;
  border-radius: var(--btn-radius-seg-item);
  font-size: var(--btn-fs-sm, 0.82rem);
}
body.shell-phone .sky-customers-near .home-start-cta.sky-sticky-visit,
body.shell-phone .sky-near-me .home-start-cta.sky-sticky-visit {
  min-height: var(--btn-h);
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
}

/* --- Filters sheet: iOS tap targets + bottom-nav clearance (helps Calendar too) --- */
body.shell-phone .acal-filters-sheet {
  padding: 14px 14px var(--sheet-nav-clear);
  max-height: min(88vh, 100dvh);
}
body.shell-phone .acal-filters-sheet .sky-filter-fold {
  min-height: max(44px, var(--btn-h));
  padding: 10px 4px;
}
body.shell-phone .acal-filters-sheet .sky-filter-fold-lab {
  font-size: 0.72rem;
}
body.shell-phone .acal-filters-sheet .acal-filters-done {
  min-height: var(--btn-h);
}
/* Customers Filters sheet extras (list Visit/Rep/Cat/Region + map Smart scan) */
body.shell-phone .acal-filters-sheet.sky-cust-filters-sheet .sky-cust-filter-chip,
body.shell-phone .acal-filters-sheet.sky-cust-filters-sheet .acal-people-chip {
  min-height: var(--btn-h);
  padding: 8px 14px;
  font-size: var(--btn-fs-sm, 0.82rem);
  appearance: none;
  -webkit-appearance: none;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px)) !important;
}
body.shell-phone .acal-filters-sheet.sky-cust-filters-sheet .sky-filter-section {
  padding: 4px 0;
}

/* ===== crm438: Calendar top search + single-accent month dots ===== */
.acal-search-bar {
  padding: 0 12px 10px;
  box-sizing: border-box;
}
.acal-search-input {
  width: 100%;
  min-height: var(--btn-h, 36px);
  padding: 8px 12px;
  border-radius: var(--btn-chip-radius, 12px);
  border: 1px solid var(--btn-ghost-border, rgba(255,255,255,0.12));
  background: var(--btn-ghost-bg, rgba(255,255,255,0.06));
  box-shadow: var(--btn-ghost-shadow, none);
  color: var(--ink);
  font-size: 0.92rem;
  outline: none;
  box-sizing: border-box;
}
.acal-search-input:focus {
  border-color: rgba(10, 132, 255, 0.45);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.18);
}
.acal-search-input::placeholder {
  color: var(--muted);
}
body.shell-phone .acal-search-bar {
  padding: 0 10px 8px;
}
body.shell-phone .acal-search-input {
  min-height: var(--btn-h);
  font-size: 1rem;
}

/* ===== crm441/crm448: Filters ? iOS grouped list (sheets + rails CRM-wide) ===== */
body.shell-phone .sky-cust-filters-sheet.acal-filters-sheet,
body.shell-phone .acal-filters-sheet {
  max-height: min(78dvh, 720px);
}
body.shell-phone .sky-cust-filters-sheet .acal-filters-sheet-body,
body.shell-phone .acal-filters-sheet .acal-filters-sheet-body {
  padding: 4px 12px 12px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
body.shell-phone .sky-cust-filters-sheet .sky-filter-section.sky-filter-foldable,
body.shell-phone .acal-filters-sheet .sky-filter-section.sky-filter-foldable,
.sky-filter.sky-filter-premium .sky-filter-section.sky-filter-foldable,
.crm-smart-rail .sky-filter-section.sky-filter-foldable,
.settings-panel .sky-filter-section.sky-filter-foldable {
  margin: 0 0 14px;
  padding: 0;
  border: 0;
  background: transparent;
}
body.shell-phone .sky-cust-filters-sheet .sky-filter-fold,
body.shell-phone .acal-filters-sheet .sky-filter-fold,
.sky-filter.sky-filter-premium .sky-filter-fold,
.crm-smart-rail .sky-filter-fold,
.settings-panel .sky-filter-fold {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 28px;
  padding: 6px 4px 8px;
  margin: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: left;
}
body.shell-phone .sky-cust-filters-sheet .sky-filter-fold-lab,
body.shell-phone .acal-filters-sheet .sky-filter-fold-lab,
.sky-filter.sky-filter-premium .sky-filter-fold-lab,
.crm-smart-rail .sky-filter-fold-lab,
.settings-panel .sky-filter-fold-lab {
  color: var(--muted);
}
body.shell-phone .sky-cust-filters-sheet .sky-filter-fold-body,
body.shell-phone .acal-filters-sheet .sky-filter-fold-body,
.sky-filter.sky-filter-premium .sky-filter-fold-body,
.crm-smart-rail .sky-filter-fold-body,
.settings-panel .sky-filter-fold-body {
  margin: 0;
  padding: 0;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated, rgba(255,255,255,0.06));
  border: 1px solid var(--line, rgba(255,255,255,0.08));
  overflow: hidden;
}
/* iOS filter rows ? sheets + smart rails (phone + PC). */
.sky-cust-filters-sheet .ios-filter-list,
.acal-filters-sheet .ios-filter-list,
.sky-filter .ios-filter-list,
.crm-smart-rail .ios-filter-list,
.settings-panel .ios-filter-list {
  display: flex;
  flex-direction: column;
  max-height: min(42dvh, 320px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.settings-panel .ios-filter-list {
  max-height: none;
}
.sky-cust-filters-sheet .ios-filter-row,
.acal-filters-sheet .ios-filter-row,
.sky-filter .ios-filter-row,
.crm-smart-rail .ios-filter-row,
.settings-panel .ios-filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  margin: 0;
  border: 0;
  border-bottom: 1px solid var(--line, rgba(255,255,255,0.08));
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  font-weight: var(--fw-med);
  text-align: left;
  appearance: none;
  cursor: pointer;
}
.sky-cust-filters-sheet .ios-filter-row:last-child,
.acal-filters-sheet .ios-filter-row:last-child,
.sky-filter .ios-filter-row:last-child,
.crm-smart-rail .ios-filter-row:last-child,
.settings-panel .ios-filter-row:last-child {
  border-bottom: 0;
}
.sky-cust-filters-sheet .ios-filter-row:active,
.acal-filters-sheet .ios-filter-row:active,
.sky-filter .ios-filter-row:active,
.crm-smart-rail .ios-filter-row:active,
.settings-panel .ios-filter-row:active {
  background: rgba(255,255,255,0.06);
}
.sky-cust-filters-sheet .ios-filter-row-lab,
.acal-filters-sheet .ios-filter-row-lab,
.sky-filter .ios-filter-row-lab,
.crm-smart-rail .ios-filter-row-lab,
.settings-panel .ios-filter-row-lab {
  flex: 1;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  overflow: hidden;
}
.sky-cust-filters-sheet .ios-filter-row-ico,
.acal-filters-sheet .ios-filter-row-ico,
.sky-filter .ios-filter-row-ico,
.crm-smart-rail .ios-filter-row-ico,
.settings-panel .ios-filter-row-ico {
  flex: 0 0 auto;
  display: inline-flex;
  color: var(--muted);
}
.sky-cust-filters-sheet .ios-filter-row-txt,
.acal-filters-sheet .ios-filter-row-txt,
.sky-filter .ios-filter-row-txt,
.crm-smart-rail .ios-filter-row-txt,
.settings-panel .ios-filter-row-txt {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sky-cust-filters-sheet .ios-filter-row-check,
.acal-filters-sheet .ios-filter-row-check,
.sky-filter .ios-filter-row-check,
.crm-smart-rail .ios-filter-row-check,
.settings-panel .ios-filter-row-check {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent, #0a84ff);
}
.sky-cust-filters-sheet .ios-filter-row.is-on .ios-filter-row-lab,
.acal-filters-sheet .ios-filter-row.is-on .ios-filter-row-lab,
.sky-filter .ios-filter-row.is-on .ios-filter-row-lab,
.crm-smart-rail .ios-filter-row.is-on .ios-filter-row-lab,
.settings-panel .ios-filter-row.is-on .ios-filter-row-lab {
  color: var(--ink);
  font-weight: var(--fw-semi);
}
.sky-cust-filters-sheet .ios-filter-row.is-on .ios-filter-row-ico,
.acal-filters-sheet .ios-filter-row.is-on .ios-filter-row-ico,
.sky-filter .ios-filter-row.is-on .ios-filter-row-ico,
.crm-smart-rail .ios-filter-row.is-on .ios-filter-row-ico,
.settings-panel .ios-filter-row.is-on .ios-filter-row-ico {
  color: var(--accent, #0a84ff);
}
/* Hide legacy chip wrap inside Customers phone Filters (rows replace chips). */
/* ===== crm443: Calendar phone tools cluster + icon Filter/Add ===== */
.acal-toolbar-phone-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
}
.acal-search-inline {
  flex: 1 1 auto;
  min-width: 0;
  max-width: none;
}
.acal-search-input-inline {
  width: 100%;
  min-height: var(--btn-h);
  height: var(--btn-h);
  padding: 0 10px;
  font-size: 0.88rem;
}
.acal-filter-icon-btn {
  position: relative;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink-secondary);
  border-radius: var(--btn-radius-seg-item);
}
.acal-filter-icon-btn.is-active {
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  border-color: color-mix(in srgb, var(--accent) 35%, transparent);
}
.acal-filter-icon-btn .acal-phone-filters-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 8px;
  height: 8px;
  padding: 0;
  font-size: 0;
  border-radius: 50%;
  background: var(--accent);
}
.acal-add-icon-btn {
  flex: 0 0 auto;
  font-size: 1.35rem;
  font-weight: var(--fw-semi);
  line-height: 1;
  color: var(--accent);
  border: 1px solid rgba(10, 132, 255, 0.35);
  background: rgba(10, 132, 255, 0.12);
  border-radius: var(--btn-radius-seg-item);
}
.acal-add-icon-btn:hover {
  color: #fff;
  background: rgba(10, 132, 255, 0.22);
}
body.shell-phone .acal-toolbar-phone-tools {
  gap: 4px;
  max-width: none;
  width: 100%;
}
body.shell-phone .acal-toolbar-phone-tools .hdr-icon-btn {
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  flex: 0 0 auto;
}
body.shell-phone .acal-toolbar-phone-tools .acal-search-inline {
  max-width: none;
  flex: 1 1 auto;
  min-width: 0;
}
body.shell-phone .acal-toolbar-phone .acal-toolbar-phone-title {
  flex: 1 1 auto;
}
/* Legacy second-row actions row ? retired (Filter moved into tools cluster). */
body.shell-phone .acal-toolbar-phone-actions {
  display: none !important;
}
.acal-schedule-note {
  margin: 0 0 6px;
}
.acal-schedule-who {
  margin: 0 0 12px;
  font-size: 0.92rem;
}
.acal-schedule-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.acal-schedule-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.82rem;
  color: var(--muted);
}
.acal-schedule-field input[type="date"] {
  min-height: var(--btn-h);
  padding: 8px 12px;
  border-radius: var(--btn-chip-radius, 12px);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink);
  font: inherit;
  box-sizing: border-box;
}
.acal-schedule-save {
  width: 100%;
}
.acal-add-sheet .cust-plus-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.acal-add-sheet .shop-sheet-opt {
  width: 100%;
}
body.shell-phone .acal-search-bar {
  display: none;
}
body.shell-phone .acal.is-phone .acal-search-bar {
  display: none;
}

/* ===== crm479: Calendar phone chrome ? search+filter+add ? Month|Week|Day ? Today/skipper ===== */
/* Row 1 (tools) sits alone in the toolbar now ? the period row moved below the mode seg. */
body.shell-phone .acal.is-phone .acal-toolbar-phone {
  gap: 0;
  padding: 2px 4px 8px;
}
/* Row 2: Month | Week | Day. */
body.shell-phone .acal.is-phone .acal-toolbar-phone-combo {
  padding: 0 2px 6px;
}
/* Row 3: Today (left) ? period ? skipper (right). Absent in Day mode. */
body.shell-phone .acal.is-phone .acal-toolbar-phone-top {
  padding: 0 2px 8px;
}
body.shell-phone .acal.is-phone .acal-toolbar-phone-top .acal-today-btn {
  min-height: 40px;
  padding: 0 10px;
  font-size: 1rem;
}
body.shell-phone .acal.is-phone .acal-toolbar-phone-top .acal-period-chev {
  height: 40px;
}
/* Day mode: date label only ? no Today button, no month skipper. */
body.shell-phone .acal.is-phone .acal-toolbar-phone-top.is-day-label {
  justify-content: flex-start;
}
body.shell-phone .acal.is-phone .acal-toolbar-phone-top.is-day-label .acal-period {
  margin: 0;
  font-size: 1.05rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
}

/* Phone Week = Month grid language, one Sun?Sat row with taller cells. */
.acal-month.is-phone.is-week-grid .acal-week-grid {
  grid-template-rows: 1fr;
}
.acal-month.is-phone.is-week-grid .acal-month-cell {
  min-height: 92px;
}
.acal-month.is-phone.is-week-grid .acal-month-daynum {
  font-size: 1rem;
}
.acal-month.is-phone.is-week-grid .acal-month-daycount {
  font-size: 0.74rem;
}

/* ===== crm481: Calendar sheets escape the calendar card =====
   `.card` sets backdrop-filter, which makes the calendar card a containing block
   for position:fixed. Every overlay rendered inside `.acal` (Add, Filters,
   Schedule) then resolved inset:0 against the card and was clipped by its
   overflow:hidden. The card forces its own opaque background, so the blur was
   never visible here anyway. */
.card.day-board-acal {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
/* Bottom nav is fixed at z-index 220 - calendar overlays must clear it. */
.acal-filters-back,
.acal-schedule-back {
  z-index: 260;
}

/* ===== crm482: bottom nav stays pinned while scrolling on iOS =====
   `overflow-x: hidden` on body propagates to the viewport, and a non-visible
   viewport overflow makes iOS Safari drop position:fixed elements out of sync
   during momentum scroll - the tab bar floats mid-list until the scroll ends.
   `clip` expresses the same intent (no horizontal scroll) without creating a
   scroll container; `hidden` stays first as the fallback for older engines. */
body.shell-phone {
  overflow-x: hidden;
  overflow-x: clip;
}
/* (crm485 vv-gap / translate3d / ::after skirt removed ? shell is the screen) */

/* ===== crm484: Accounts PDF actions - labelled Statement + Ledger, left ===== */
.hub-acct-toolbar.is-labelled,
.hist-toolbar.accounts-pdf-bar.is-labelled {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}
.hub-pdf-action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: var(--btn-h);
  padding: 0 12px;
  border-radius: var(--btn-radius-seg-item, 10px);
  white-space: nowrap;
}
.hub-pdf-action .hub-pdf-action-ico {
  display: inline-grid;
  place-items: center;
  color: var(--accent);
}
.hub-pdf-action:disabled,
.hub-pdf-action[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}
.hub-pdf-action:disabled .hub-pdf-action-ico {
  color: var(--btn-disabled-fg, var(--muted));
}

/* ========================================================================
   WAVE2-SHEET-CANON ? phone form / action sheets (iOS-grade chrome)
   Markers MAIN can grep: WAVE2-CALL-FORM-DARK ? WAVE2-SHEET-NAV-CLEAR ?
   WAVE2-SHEET-CLOSE-44 ? WAVE2-SHEET-CANON
   Leaves invoice .order-doc paper, PDF viewer, Role access untouched.
   ======================================================================== */
body.shell-phone .sky-modal-back {
  padding-bottom: max(20px, var(--sheet-nav-clear, 20px));
}
body.shell-phone .sky-modal {
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border-color: var(--line-strong);
  color: var(--ink);
  font-family: var(--font);
}
body.shell-phone .sky-forms-new-sheet {
  padding-bottom: 0;
}
/* Picks stay in-flow; .crm-menu-body scrolls (no dual scroll / nav-clear foot pad). */
body.shell-phone .sky-forms-new-sheet .sky-forms-new-picks {
  padding-bottom: 0;
  overflow: visible;
}
body.shell-phone .sky-forms-new-sheet .sky-hub-foot {
  padding: 8px 2px 0;
}
body.shell-phone .crm-modal {
  max-height: min(78dvh, 640px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
body.shell-phone .crm-modal-backdrop {
  padding-bottom: max(20px, var(--sheet-nav-clear, 20px));
  align-content: end;
}
body.shell-phone .crm-modal-backdrop .crm-modal {
  width: min(100%, 420px);
  margin-bottom: 0;
  animation: crmModalIn var(--dur-modal, 0.22s) var(--ease-modal, var(--ease)) both;
}
/* WAVE2-SHEET-CLOSE-44 ? every sheet Close / X on phone */
body.shell-phone .sky-modal-x,
body.shell-phone .sky-rail-close,
body.shell-phone .prod-lightbox-close {
  min-width: 44px;
  min-height: 44px;
  width: 44px;
  height: 44px;
}
body.shell-phone .cust-plus-head .btn.small,
body.shell-phone .cat-sheet-head .btn.small {
  min-height: 44px;
  min-width: 44px;
}
/* Smooth open for shared bottom sheets ? iOS sheet ease tokens */
body.shell-phone .cat-sheet-panel,
body.shell-phone .cust-plus-panel,
body.shell-phone .acal-filters-sheet {
  transition: transform var(--dur-sheet, 0.34s) var(--ease-sheet, var(--ease));
}
/* WAVE2 form surfaces ? no paper leftovers on action / task sheets */
body.shell-phone .sky-form,
body.shell-phone .sky-form.action-form-card,
body.shell-phone .card.action-form-card {
  background: var(--bg-elevated);
  color: var(--ink);
  border-color: var(--line);
  font-family: var(--font);
}
body.shell-phone .sky-form .field,
body.shell-phone .sky-form .sky-a,
body.shell-phone .card.action-form-card .field {
  background: var(--bg-elevated-2);
  color: var(--ink);
  border-color: var(--line-strong);
}
/* Call Form: one restrained CRM form surface; field behaviour stays unchanged. */
.call-form-wrap {
  box-sizing: border-box;
  width: min(100%, 680px);
  max-width: 680px;
  padding: 8px 16px 28px;
}
.call-form-surface {
  padding: 24px 24px 30px;
}
.call-form-head {
  margin-bottom: 18px;
}
.call-form-surface .sky-title {
  margin: 0 0 6px;
  text-align: left;
  font-size: 1.6rem;
  line-height: 1.15;
}
.call-form-surface .sky-form-lead {
  margin: 0;
  max-width: 56ch;
  line-height: 1.45;
}
.call-form-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.35;
}
.call-form-meta span {
  min-width: 0;
}
.call-form-meta strong {
  color: var(--ink-secondary);
  font-weight: var(--fw-semi);
}
.call-form-customer {
  margin-bottom: 2px;
}
.call-form-customer > .sky-meta-cust {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(100px, 0.5fr);
  gap: 8px 18px;
  margin: 0 0 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
}
.call-form-customer > .sky-meta-cust > div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  margin: 0;
  min-width: 0;
}
.call-form-customer > .sky-meta-cust strong {
  min-width: 0;
  overflow-wrap: anywhere;
}
.call-form-fields {
  border-top: 1px solid var(--line);
}
.call-form-fields .sky-field {
  display: grid;
  grid-template-columns: minmax(150px, 0.38fr) minmax(0, 1fr);
  gap: 6px 18px;
  align-items: start;
  padding: 14px 0;
}
.call-form-fields .sky-field > .sky-q {
  grid-column: 1;
  margin: 10px 0 0;
  color: var(--ink);
}
.call-form-fields .sky-field > :not(.sky-q) {
  grid-column: 2;
  min-width: 0;
}
.call-form-fields .sky-field > .field-hint {
  margin-top: 0;
}
.call-form-surface > .nc-sticky-submit {
  display: flex;
  justify-content: flex-end;
}
.call-form-surface > .nc-sticky-submit .btn {
  min-width: 180px;
}
/* Non-Call action forms share the restrained Call Form composition while
   retaining their existing field engines, folds, maps, drafts and submit flow. */
.action-form-wrap {
  box-sizing: border-box;
  width: min(100%, 680px);
  max-width: 680px;
  margin: 0 auto;
  padding: 8px 16px 28px;
}
.action-form-surface {
  min-width: 0;
  padding: 24px 24px 30px;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.action-form-head {
  margin-bottom: 18px;
}
.action-form-surface .action-form-title {
  margin: 0 0 6px;
  text-align: left;
  font-size: 1.6rem;
  line-height: 1.15;
}
.action-form-surface .action-form-lead {
  max-width: 56ch;
  margin: 0;
  line-height: 1.45;
  text-align: left;
}
.action-form-customer {
  min-width: 0;
  margin: 0 0 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated-2);
}
.action-form-customer > .sub:first-child {
  margin: 0 0 10px;
  color: var(--ink-secondary);
  font-weight: var(--fw-semi);
  overflow-wrap: anywhere;
}
.action-form-customer > .info-grid {
  margin-bottom: 0 !important;
}
.action-form-customer .info-row {
  min-width: 0;
}
.action-form-customer .info-v {
  min-width: 0;
  overflow-wrap: anywhere;
}
.action-form-customer > :last-child {
  margin-bottom: 0;
}
.action-form-fields {
  min-width: 0;
  padding-top: 2px;
  border-top: 1px solid var(--line);
}
.action-form-fields > .label,
.action-form-fields > #afChangeRest > .label,
.action-form-fields .af-fold-body > .label {
  display: block;
  margin: 14px 0 6px !important;
  color: var(--ink);
  line-height: 1.35;
}
.action-form-fields > .field,
.action-form-fields > #afChangeRest > .field,
.action-form-fields .af-fold-body > .field,
.action-form-fields .sky-combo-field,
.action-form-fields .af-phone-pick,
.action-form-fields .pl-seg,
.action-form-fields .nc-map-wrap {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}
.action-form-fields > .af-fold:first-child {
  margin-top: 12px;
}
.action-form-surface > .nc-sticky-submit {
  display: flex;
  justify-content: flex-end;
}
.action-form-surface > .nc-sticky-submit .btn {
  min-width: 180px;
}
@media (max-width: 700px) {
  .call-form-wrap {
    width: 100%;
    max-width: none;
    padding: 4px 12px 20px;
  }
  body.shell-phone .sky-form.call-form-surface {
    padding: 18px 16px calc(var(--sheet-nav-clear) + 56px);
  }
  .call-form-head {
    margin-bottom: 14px;
  }
  .call-form-surface .sky-title {
    font-size: 1.42rem;
  }
  .call-form-meta {
    gap: 3px 10px;
    margin-top: 10px;
  }
  .call-form-customer > .sky-meta-cust {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 12px;
  }
  .call-form-customer > .sky-meta-cust > div {
    grid-template-columns: 76px minmax(0, 1fr);
  }
  .call-form-fields .sky-field {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
    padding: 12px 0;
  }
  .call-form-fields .sky-field > .sky-q,
  .call-form-fields .sky-field > :not(.sky-q) {
    grid-column: 1;
  }
  .call-form-fields .sky-field > .sky-q {
    margin: 0;
  }
  .call-form-surface > .nc-sticky-submit {
    display: block;
  }
  .call-form-surface > .nc-sticky-submit .btn {
    min-width: 0;
    width: 100%;
  }
  .action-form-wrap {
    width: 100%;
    max-width: none;
    padding: 4px 12px 20px;
  }
  body.shell-phone .card.action-form-surface {
    padding: 18px 16px calc(var(--sheet-nav-clear) + 56px);
  }
  .action-form-head {
    margin-bottom: 14px;
  }
  .action-form-surface .action-form-title {
    font-size: 1.42rem;
  }
  .action-form-customer {
    padding: 12px;
  }
  .action-form-fields > .label,
  .action-form-fields > #afChangeRest > .label,
  .action-form-fields .af-fold-body > .label {
    margin-top: 12px !important;
  }
  .action-form-surface > .nc-sticky-submit {
    display: block;
  }
  body.shell-phone .action-form-surface > .nc-sticky-submit {
    position: sticky;
    left: auto;
    right: auto;
    bottom: 12px;
  }
  .action-form-surface > .nc-sticky-submit .btn {
    min-width: 0;
    width: 100%;
  }
}
body.shell-phone .home-promo-edit-sheet {
  max-height: min(92dvh, 960px);
}
body.shell-phone .home-promo-edit-body {
  padding-bottom: var(--sheet-nav-clear);
}
body.shell-phone .home-promo-edit-foot {
  padding-bottom: max(12px, env(safe-area-inset-bottom, 0px));
}



/* ===== Premium Experience Waves 2?6 (crm533) ===== */
.crm-net-stack {
  position: sticky;
  top: 0;
  z-index: 80;
  display: grid;
  gap: 0;
}
.crm-net-banner {
  padding: 7px 14px;
  text-align: center;
  font-size: 0.78rem;
  font-weight: var(--fw-med, 600);
  letter-spacing: -0.01em;
  color: #fff;
  background: rgba(40, 40, 44, 0.92);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.crm-net-banner.is-offline { background: rgba(120, 70, 20, 0.94); }
.crm-net-banner.is-back { background: var(--btn-primary-bg, #0a84ff); }
.crm-net-banner.is-warn { background: rgba(100, 60, 20, 0.94); }
.crm-net-banner.is-link-wifi { background: rgba(18, 128, 96, 0.94); }
.crm-net-banner.is-link-cell { background: rgba(55, 78, 118, 0.94); }

.soft-toast.has-undo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  pointer-events: auto;
  max-width: min(94vw, 380px);
  padding-right: 8px;
}
.soft-toast-undo {
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
  font: inherit;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: var(--btn-radius-seg-item, 10px);
  cursor: pointer;
}
.soft-toast-undo:hover { background: rgba(255, 255, 255, 0.28); }

.crm-cmd-back { z-index: 1400; }
.crm-cmd-modal {
  width: min(560px, 94vw);
  max-height: min(78vh, 640px);
  display: flex;
  flex-direction: column;
  padding-bottom: 10px;
}
.crm-cmd-search { display: block; padding: 0 14px 10px; }
.crm-cmd-search input {
  width: 100%;
  min-height: var(--btn-h, 44px);
  border-radius: var(--btn-chip-radius, 12px);
  border: 1px solid var(--line-strong, var(--line));
  background: var(--bg-elevated-2, var(--bg-elevated));
  color: var(--ink);
  padding: 10px 12px;
  font: inherit;
  font-size: 1rem;
}
.crm-cmd-list {
  overflow: auto;
  padding: 0 8px 8px;
  display: grid;
  gap: 4px;
  flex: 1;
  min-height: 120px;
}
.crm-cmd-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 8px;
  align-items: center;
  text-align: left;
  min-height: 44px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: var(--btn-chip-radius, 12px);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
}
.crm-cmd-item:hover { background: var(--btn-ghost-bg); }
.crm-cmd-item.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
}
.crm-cmd-kicker {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted, #8e8e93);
}
.crm-cmd-label { font-weight: var(--fw-med, 600); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.crm-cmd-hint { font-size: 0.78rem; color: var(--muted, #8e8e93); }
.crm-cmd-empty { padding: 18px 12px; color: var(--muted); text-align: center; }
.crm-cmd-foot {
  margin: 0;
  padding: 6px 14px 2px;
  font-size: 0.7rem;
  color: var(--muted);
}
.crm-cmd-foot kbd {
  display: inline-block;
  padding: 1px 5px;
  margin: 0 1px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg-elevated-2);
  font-size: 0.68rem;
}

.crm-cust-row {
  position: relative;
  overflow: hidden;
  background: transparent;
}
.crm-cust-row-front {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: stretch;
  gap: 0;
  background: var(--bg-elevated, #111);
  transition: transform 0.22s var(--ease, ease);
  will-change: transform;
}
.crm-cust-row-front .pick-cust {
  flex: 1;
  min-width: 0;
}
.crm-cust-check {
  display: flex;
  align-items: center;
  padding: 0 4px 0 10px;
  flex: 0 0 auto;
}
.crm-cust-check input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent, #0a84ff);
}
/* Select mode OFF: no row checks (belt if stale DOM); toggle lives in .sky-cust-tools */
.sky-customers:not(.is-select-mode) .crm-cust-check {
  display: none;
}
.crm-cust-preview-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted, #8e8e93);
  padding: 0 12px;
  min-width: 44px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.crm-cust-preview-btn:hover { color: var(--ink); }
.crm-cust-row.is-selected .crm-cust-row-front,
.crm-cust-row-front.is-selected {
  background: color-mix(in srgb, var(--btn-chip-on-bg) 55%, var(--bg-elevated, #1c1c1e));
}
.crm-swipe-actions {
  position: absolute;
  inset: 0 0 0 auto;
  display: flex;
  align-items: stretch;
  z-index: 0;
  pointer-events: none;
}
.crm-cust-row.is-open .crm-swipe-actions,
.cart-line.is-open .crm-swipe-actions,
.is-swipeable.is-open > .crm-swipe-actions {
  pointer-events: auto;
}
.crm-swipe-act {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 64px;
  padding: 8px 10px;
  color: #fff;
  text-decoration: none;
  font-size: 0.65rem;
  font-weight: 700;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}
.crm-swipe-act.is-call { background: #34c759; }
.crm-swipe-act.is-wa { background: #25d366; }
.crm-swipe-act.is-mail { background: #0a84ff; }
.crm-swipe-act.is-more { background: #636366; }
.crm-swipe-act.is-delete { background: var(--danger, #ff453a); }

/* ===== crm804: cart bidirectional swipe + long-pull delete commit ===== */
.crm-swipe-actions.is-leading {
  inset: 0 auto 0 0;
  padding: 4px 0 4px 4px;
  justify-content: flex-start;
}
.crm-swipe-actions.is-trailing {
  inset: 0 0 0 auto;
  padding: 4px 4px 4px 0;
  justify-content: flex-end;
}
.crm-swipe-act.is-options {
  background: #636366;
  min-width: 72px;
}
body.shell-phone .cart-line.is-open-right .crm-swipe-actions.is-leading,
body.shell-phone .cart-line.is-open-left .crm-swipe-actions.is-trailing,
body.shell-phone .cart-line.is-open .crm-swipe-actions.is-trailing,
body.shell-phone .cart-line.is-swipe-commit .crm-swipe-actions.is-trailing {
  pointer-events: auto;
  z-index: 2;
}
body.shell-phone .cart-line.is-open-left .crm-swipe-actions.is-trailing .crm-swipe-act.is-delete,
body.shell-phone .cart-line.is-open .crm-swipe-actions.is-trailing .crm-swipe-act.is-delete,
body.shell-phone .cart-line.is-open-right .crm-swipe-actions.is-leading .crm-swipe-act.is-options {
  pointer-events: auto;
  touch-action: manipulation;
}
body.shell-phone .cart-line.is-open-right .crm-swipe-actions.is-trailing,
body.shell-phone .cart-line.is-open-left .crm-swipe-actions.is-leading,
body.shell-phone .cart-line.is-open .crm-swipe-actions.is-leading {
  pointer-events: none;
}
/* crm812: compositor-only during drag — kill CSS transition fighting finger */
.is-crm-swiping .cart-line-front,
.is-crm-swiping .crm-cust-row-front {
  transition: none !important;
}
/* crm812: paint-only commit cue WHILE dragging — no inset/width layout thrash */
body.shell-phone .cart-line.is-swipe-commit.is-crm-swiping .crm-swipe-actions.is-trailing .crm-swipe-act.is-delete {
  background: color-mix(in srgb, var(--danger, #ff453a) 82%, #fff);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #fff 28%, transparent);
  transform: scale(1.05);
  pointer-events: none; /* commit is release-driven; don't steal the pull */
}
/* Full-bleed only when NOT mid-gesture (delete usually fires on release) */
body.shell-phone .cart-line.is-swipe-commit:not(.is-crm-swiping) .crm-swipe-actions.is-trailing {
  inset: 0;
  padding: 0;
  z-index: 2;
}
body.shell-phone .cart-line.is-swipe-commit:not(.is-crm-swiping) .crm-swipe-actions.is-trailing .crm-swipe-act.is-delete {
  flex: 1 1 auto;
  min-width: 100%;
  width: 100%;
  border-radius: 0;
  font-size: 0.8rem;
  gap: 6px;
  background: var(--danger, #ff453a);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #fff 18%, transparent);
  pointer-events: none;
}
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-open-right .cart-line-front {
  box-shadow: 2px 0 0 var(--bg-elevated, #1c1c1e);
}


/* Front face MUST stay opaque ? transparent let Call/WA/Email bleed under overdue (crm533 P0). */
body.shell-phone .crm-cust-row.is-swipeable .crm-cust-row-front {
  background: var(--bg-elevated, #1c1c1e);
}
body.shell-phone .crm-cust-row .pick-cust.ios-cust-row {
  padding-right: 10px;
}
body.shell-phone .crm-cust-row .pick-cust.ios-cust-row::after { display: none; }
body.shell-phone .crm-cust-preview-btn { color: rgba(255, 255, 255, 0.45); }
body:not(.shell-phone) .crm-swipe-actions { display: none; }

.crm-preview-rail {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(360px, 92vw);
  z-index: 1300;
  background: var(--bg-elevated);
  border-left: 1px solid var(--line);
  box-shadow: -8px 0 28px rgba(0, 0, 0, 0.18);
  padding: 0 0 16px;
  overflow: auto;
}
.crm-preview-back .crm-preview-sheet {
  width: min(480px, 96vw);
  max-height: min(86vh, 720px);
}
.crm-preview-body { padding: 8px 16px 18px; }
.crm-preview-name {
  margin: 0 0 2px;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.crm-preview-code {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.85rem;
}
.crm-preview-dl {
  margin: 0 0 16px;
  display: grid;
  gap: 10px;
}
.crm-preview-dl > div {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 8px;
  font-size: 0.9rem;
}
.crm-preview-dl dt {
  margin: 0;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.crm-preview-dl dd { margin: 0; }
.crm-preview-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
body.crm-preview-open { overflow: hidden; }

.crm-bulk-bar {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 1100;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px 8px 14px;
  border-radius: var(--btn-radius);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  box-shadow: var(--btn-ghost-shadow);
  color: #fff;
  max-width: min(96vw, 520px);
}
.crm-bulk-count {
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  margin-right: 4px;
}
body.shell-phone .crm-bulk-bar {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
  border-radius: var(--btn-chip-radius, 12px);
}
@media (prefers-reduced-motion: reduce) {
  .crm-cust-row-front { transition: none; }
}
/* ===== end crm533 premium waves ===== */

/* crm533 ? phone list dividers on wrapped rows */
body.shell-phone .sky-customers .crm-cust-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
  z-index: 2;
}
body.shell-phone .crm-cust-row .pick-cust.ios-cust-row:not(:last-child)::before {
  display: none;
}

/* ===== crm542 Cosmetic Pack A ? first-glance Home / Customers / Products ===== */

/* --- Home: quieter greeting, calmer strips, sharper hierarchy --- */
.crm-home {
  gap: 10px;
  padding-top: 0;
}
.crm-home-head h1,
.crm-home-head .home-greet {
  margin: 0;
  font-size: 1.42rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.035em;
  line-height: 1.15;
}
.crm-home.is-pc .crm-home-head .home-greet {
  font-size: 1.5rem;
}
.home-greet-row {
  gap: 10px;
  margin: 0;
}
.home-avatar,
.home-avatar-fallback {
  width: 40px;
  height: 40px;
  margin-top: 1px;
  border-color: rgba(255, 255, 255, 0.08);
}
.sky-dash-head .home-avatar,
.sky-dash-head .home-avatar-fallback {
  width: 42px;
  height: 42px;
}
.home-greet-date {
  font-size: 0.8rem;
  opacity: 0.85;
}
.home-today-line,
.crm-home-head .home-today-line {
  margin: 2px 0 0;
  font-size: 0.82rem;
  font-weight: var(--fw-reg, 400);
  color: color-mix(in srgb, var(--muted) 92%, transparent);
  letter-spacing: -0.005em;
}
.crm-home-head .home-status-line,
.sky-dash-head .home-status-line,
.home-status-line {
  margin: 4px 0 0;
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.01em;
  color: color-mix(in srgb, var(--muted) 88%, transparent);
  opacity: 0.9;
}
.home-head-meta {
  padding-top: 2px;
  gap: 0;
}
.home-head-date {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: var(--fw-med);
}
.home-head-time {
  font-size: 0.7rem;
  opacity: 0.85;
}
.sky-dash-head {
  margin: 0 0 8px;
  gap: 4px;
}
.sky-dash-head .home-greet,
.sky-dash-greet {
  font-size: 1.28rem;
  letter-spacing: -0.03em;
}

/* KPI / radar / deals ? one soft sky-card language, less dashboard noise */
.home-kpi-strip {
  gap: 8px;
  margin: 0 0 4px;
  grid-template-columns: repeat(2, minmax(140px, 200px));
}
.home-kpi {
  min-height: 58px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border-color: rgba(255, 255, 255, 0.06);
  background: var(--bg-elevated);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
  transition: background 0.15s var(--ease, ease), border-color 0.15s var(--ease, ease), transform 0.12s var(--ease, ease);
}
.home-kpi strong {
  font-size: 1.12rem;
  letter-spacing: -0.03em;
}
.home-kpi span,
.home-kpi-lab {
  font-size: 0.7rem;
  letter-spacing: 0.01em;
}
.home-kpi:active {
  transform: scale(0.985);
}
.home-radar {
  margin: 0 0 8px;
  padding: 10px 12px;
  border-color: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
}
.home-deals {
  margin: 0 0 8px;
}
.home-radar-head {
  margin: 0 0 8px;
}
.home-radar-head h2,
.home-deals-head h2 {
  font-size: 0.72rem;
  letter-spacing: 0.07em;
}
.sky-dash-metrics {
  gap: 8px;
  margin-top: 6px;
}
.sky-dash-metrics > div {
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: var(--bg-elevated);
}
.sky-dash-metrics em,
.sky-dash-metrics strong {
  font-size: 1.18rem;
}
.crm-home.is-pc .crm-home-body {
  gap: 10px;
}
.home-quick-grid {
  gap: 8px;
}
.home-quick {
  border-radius: var(--radius-sm);
  border-color: rgba(255, 255, 255, 0.06);
  padding: 12px 12px 10px;
  transition: background 0.15s var(--ease, ease), transform 0.12s var(--ease, ease);
}
.home-quick:active {
  transform: scale(0.985);
}

/* Optional one-time ?K hint ? calm desk strip */
.home-cmdk-hint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 2px;
  padding: 7px 10px 7px 12px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: color-mix(in srgb, var(--bg-elevated-2) 70%, transparent);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.home-cmdk-hint-text kbd {
  display: inline-block;
  padding: 1px 6px;
  margin-left: 2px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.72rem;
  font-family: inherit;
  font-weight: var(--fw-semi);
  color: var(--ink);
  letter-spacing: 0;
}
.home-cmdk-hint-x {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  width: 28px;
  height: 28px;
  border-radius: var(--btn-chip-radius, 12px);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  flex: 0 0 auto;
}
.home-cmdk-hint-x:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}
body.shell-phone .home-cmdk-hint {
  display: none !important;
}

/* --- Customers: tighter rows, clear overdue chip, calm tools, press --- */
.sky-customers .sky-page-head > h1 {
  letter-spacing: -0.03em;
  font-weight: var(--fw-semi);
}
.sky-cust-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.sky-cust-tools .hdr-icon-btn,
.sky-cust-tools .crm-plus-ico,
.sky-cust-tools .acal-filter-icon-btn {
  border-radius: var(--btn-radius, var(--radius-sm)) !important;
  opacity: 0.92;
  transition: background 0.15s var(--ease, ease), border-color 0.15s var(--ease, ease), opacity 0.15s var(--ease, ease), transform 0.12s var(--ease, ease);
}
.sky-cust-tools .hdr-icon-btn:hover,
.sky-cust-tools .crm-plus-ico:hover {
  opacity: 1;
}
.sky-cust-tools .hdr-icon-btn:active,
.sky-cust-tools .crm-plus-ico:active {
  transform: scale(0.94);
}
.sky-cust-tools #btnCustSelectMode.is-active {
  background: var(--btn-chip-on-bg) !important;
  border-color: var(--btn-chip-on-border) !important;
  box-shadow: var(--btn-chip-on-shadow) !important;
  opacity: 1;
}
body.shell-phone .sky-customers .sky-cust-tools {
  gap: 4px;
  padding: 0;
}
body.shell-phone .sky-customers .sky-cust-tools .sky-page-search input {
  border-radius: var(--btn-radius, var(--radius-sm));
}

/* Row density + name vs visit hierarchy */
body.shell-phone .results.sky-list .pick-cust.ios-cust-row,
body.shell-phone .sky-list .pick-cust.ios-cust-row,
body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row {
  padding: 9px 12px 9px 14px;
  gap: 10px;
  min-height: 44px;
  transition: background 0.14s var(--ease, ease);
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-name,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-name,
body:not(.shell-phone) .sky-cust-list-group .ios-cust-name {
  font-size: 0.94rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.015em;
  color: var(--ink);
}
.ios-cust-visit {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  max-width: 46%;
  flex: 0 0 auto;
}
.ios-cust-visit-lab {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  line-height: 1.2;
}
/* Overdue = real chip (squircle), not plain red text */
.ios-cust-visit.is-late .ios-cust-visit-lab {
  padding: 3px 8px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: rgba(255, 69, 58, 0.16);
  border: 1px solid rgba(255, 69, 58, 0.28);
  color: #ff6961;
  font-size: 0.7rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.01em;
}
.ios-cust-visit.is-soon .ios-cust-visit-lab {
  padding: 3px 8px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
  color: color-mix(in srgb, var(--accent) 72%, #fff 28%);
  font-size: 0.7rem;
  font-weight: var(--fw-semi);
}
.ios-cust-visit.is-upcoming .ios-cust-visit-lab {
  color: #30d158;
  font-size: 0.76rem;
}
.ios-cust-visit.is-never .ios-cust-visit-lab {
  color: #ff9f0a;
  font-size: 0.76rem;
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row .ios-cust-visit,
body.shell-phone .sky-list .pick-cust.ios-cust-row .ios-cust-visit,
body:not(.shell-phone) .sky-cust-list-group .ios-cust-visit {
  font-size: inherit;
  padding-left: 0;
  color: inherit;
}

/* Press states on list rows */
body.shell-phone .crm-cust-row-front:active,
body:not(.shell-phone) .crm-cust-row-front:active {
  background: color-mix(in srgb, var(--bg-elevated-2) 55%, var(--bg-elevated));
}
body.shell-phone .results.sky-list .pick-cust.ios-cust-row:active,
body.shell-phone .sky-list .pick-cust.ios-cust-row:active,
body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row:active {
  background: rgba(255, 255, 255, 0.07);
}
@media (hover: hover) and (pointer: fine) {
  body:not(.shell-phone) .sky-cust-list-group .pick-cust.ios-cust-row:hover {
    background: rgba(255, 255, 255, 0.045);
  }
}

/* Swipe actions: squircle tiles, opaque front (no bleed) */
.crm-swipe-actions {
  gap: 3px;
  padding: 4px 4px 4px 0;
  align-items: stretch;
}
.crm-swipe-act {
  min-width: 58px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  margin: 0;
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.01em;
}
body.shell-phone .crm-cust-row.is-swipeable .crm-cust-row-front {
  background: var(--bg-elevated, #1c1c1e) !important;
  border-radius: 0;
}
body.shell-phone .crm-cust-row.is-swipeable.is-open .crm-cust-row-front {
  box-shadow: -2px 0 0 var(--bg-elevated, #1c1c1e);
}
.crm-cust-preview-btn {
  border-radius: var(--btn-chip-radius, 12px);
  transition: color 0.15s var(--ease, ease), background 0.15s var(--ease, ease);
}
.crm-cust-preview-btn:active {
  background: rgba(255, 255, 255, 0.06);
}

/* --- Products: shop head + tools bar density / type --- */
.shop-sky-title {
  margin-bottom: 2px;
  padding-bottom: 2px;
  gap: 8px 12px;
}
.shop-sky-title h1 {
  font-size: 1.35rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.shop-chrome {
  margin-bottom: 6px;
  padding: 2px 0 8px;
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
.shop-topbar {
  margin-bottom: 8px;
  gap: 8px;
}
.shop-deliver strong {
  font-size: 0.84rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
.shop-toolbar {
  margin-bottom: 10px;
  padding: 2px 0 0;
  gap: 8px 12px;
  align-items: center;
}
.shop-toolbar .cat-heading,
.cat-heading {
  margin: 0;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.02em;
  text-transform: none;
  color: var(--ink-secondary);
}
.shop-toolbar-actions {
  gap: 8px;
}
.shop-toolbar-phone {
  margin-bottom: 8px;
  align-items: center;
}
body.shell-phone .shop-chrome-phone {
  padding-bottom: 4px;
}
body.shell-phone .shop-toolbar-phone .cat-heading {
  font-size: 0.76rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.015em;
}
/* Phone Products unified Filters sheet */
body.shell-phone #shopFiltersSheet > .cat-sheet-panel {
  max-height: min(
    85vh,
    640px,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 12px)
  );
}
body.shell-phone #shopFiltersSheet .shop-filters-cats.category-sheet-scroll {
  height: min(36vh, 280px);
  max-height: min(36vh, 280px);
  flex: 0 0 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
body.shell-phone #shopFiltersSheet .shop-filters-cats .category-option-list {
  min-height: 100%;
}
body.shell-phone #shopFiltersSheet .shop-filters-cats .category-option-list .category-option-row {
  min-height: 44px;
}
body.shell-phone #shopFiltersSheet .shop-category-filter-search {
  display: block;
  margin: 2px 0;
}
body.shell-phone #shopFiltersSheet .shop-category-filter-search .field {
  width: 100%;
  min-height: var(--btn-h);
  padding: 10px 12px;
  border-radius: var(--btn-radius);
}
body.shell-phone #shopFiltersSheet .shop-category-filter-no-match {
  margin: 2px 0 0;
  padding: 14px;
  border-radius: var(--btn-chip-radius);
  background: var(--bg-elevated-2);
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.35;
  text-align: center;
}
body.shell-phone #shopFiltersSheet .category-option-row[hidden],
body.shell-phone #shopFiltersSheet .shop-category-filter-no-match[hidden] {
  display: none !important;
}
.shop-filters-body .shop-filters-img {
  padding: 0 12px 8px;
}

@media (prefers-reduced-motion: reduce) {
  .home-kpi,
  .home-quick,
  .crm-swipe-act,
  .sky-cust-tools .hdr-icon-btn,
  body.shell-phone .shop-chrome-phone .sky-cust-tools .hdr-icon-btn {
    transition: none;
  }
  .home-kpi:active,
  .home-quick:active {
    transform: none;
  }
}
/* ===== end crm542 Cosmetic Pack A ===== */

/* ===== crm543 Cosmetic Pack B ? Cart/Order + product cards ===== */

/* --- Cart head + quieter field labels --- */
.sky-cart .cart-head {
  margin-bottom: 10px;
  gap: 10px;
}
.sky-cart .cart-head h1 {
  font-size: 1.35rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.sky-cart .cart-pricing-hint {
  margin: 0 0 8px;
  font-size: 0.78rem;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}
.checkout-box > .hub-kicker,
.checkout-box.cart-checkout-kit > .admin-opt-sec:first-child {
  margin: 0 0 10px;
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.88;
  padding: 0 2px;
}
/* Checkout labels = Users `.admin-opt-sec` kit (do not dilute meta type) */
.checkout-box .label,
.checkout-box .cart-site-label,
.checkout-box .cart-field-lab,
.checkout-box.cart-checkout-kit > .admin-opt-sec {
  margin-top: 12px;
  margin-bottom: 6px;
  font-size: 0.62rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.88;
  padding: 0 2px;
}
.checkout-box .cart-site-label,
.checkout-box.cart-checkout-kit > .admin-opt-sec.cart-site-label {
  margin-top: 10px;
}
.checkout-box .cart-site-label .req-star,
.checkout-box.cart-checkout-kit .req-star {
  opacity: 0.7;
  font-weight: var(--fw-med);
  letter-spacing: 0;
  text-transform: none;
}
/* Cart checkout kit — assign rows match Users Filters admin-opt language */
.checkout-box.cart-checkout-kit .cart-assign-opts {
  margin: 8px 0 4px;
}
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-row {
  min-height: 48px;
}
.checkout-box.cart-checkout-kit .field {
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  appearance: none;
  -webkit-appearance: none;
}
.checkout-box.cart-checkout-kit .cart-quote-comment {
  width: 100%;
  min-height: 64px;
  resize: vertical;
  line-height: 1.35;
  box-sizing: border-box;
}
.checkout-box.cart-checkout-kit > .cart-checkout-target {
  margin: 0 0 10px;
  padding: 0 0 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.checkout-box.cart-checkout-kit .cart-target-incl-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 2px;
}
.checkout-box.cart-checkout-kit .cart-target-incl-row .cart-target-incl {
  flex: 1 1 auto;
  min-width: 0;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}
.checkout-box.cart-checkout-kit .cart-target-acts {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
}
.checkout-box.cart-checkout-kit .cart-target-incl-row .cart-revert-prices,
.checkout-box.cart-checkout-kit .cart-target-incl-row .cart-cost-as-target {
  flex: 0 0 auto;
  margin: 0;
  width: auto;
  white-space: nowrap;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
  min-height: var(--btn-h-sm);
  box-sizing: border-box;
}
.checkout-box .field-hint,
.checkout-box .cart-site-hint {
  margin: 4px 0 0;
  font-size: 0.74rem;
  line-height: 1.35;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}

/* On/Off Site + Warehouse ? same full-width seg language */
.checkout-box .cart-site-seg,
.checkout-box .cart-wh-seg {
  display: flex;
  width: 100%;
  max-width: 100%;
  margin: 4px 0 2px;
  padding: 3px;
  box-sizing: border-box;
  border-radius: var(--btn-radius-seg) !important;
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  gap: 2px;
}
.checkout-box .cart-site-seg .acal-seg-btn,
.checkout-box .cart-wh-seg .pl-seg-btn {
  flex: 1 1 0;
  min-width: 0;
  min-height: 40px;
  padding: 8px 10px;
  border-radius: var(--btn-radius-seg-item) !important;
  font-size: 0.8rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  transition:
    background 0.15s var(--ease, ease),
    color 0.15s var(--ease, ease),
    box-shadow 0.15s var(--ease, ease),
    transform 0.12s var(--ease, ease);
}
.checkout-box .cart-site-seg .acal-seg-btn:active:not([aria-disabled="true"]),
.checkout-box .cart-wh-seg .pl-seg-btn:active {
  transform: scale(0.98);
}
.checkout-box .cart-wh-seg .pl-seg-btn.active {
  background: var(--btn-seg-on);
  color: #fff;
  border: 0;
  box-shadow: var(--btn-seg-on-shadow);
}

/* Line cards ? denser air, calmer separators */
.sky-cart .cart-lines {
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.sky-cart .cart-line {
  gap: 10px;
  padding: 12px 0;
  border-bottom-color: rgba(255, 255, 255, 0.06);
}
.sky-cart .cart-line-body > strong {
  font-size: 0.94rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.015em;
  line-height: 1.25;
}
.sky-cart .cart-line-body > .context {
  font-size: 0.76rem;
  margin-top: 2px;
}
.sky-cart .cart-line-actions {
  margin-top: 10px;
  gap: 8px;
}
.sky-cart .cart-line-total {
  font-size: 0.92rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.sky-cart .cart-mini-label {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.01em;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}
/* Cart line Unit price / Disc % / qty — squircle lock (never oval / 999 / 980). */
.sky-cart .cart-price-inp,
.sky-cart .cart-disc-inp {
  text-align: center;
}
.sky-cart .cart-price-inp,
.sky-cart .cart-disc-inp,
.sky-cart .cart-table-stepper,
.sky-cart .cart-phone-stepper {
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
}
.sky-cart .cart-table-stepper,
.sky-cart .cart-phone-stepper {
  width: fit-content;
  max-width: 100%;
  flex: 0 0 auto;
}
.sky-cart .cart-thumb {
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  border-color: rgba(255, 255, 255, 0.08);
}
body.shell-phone .sky-cart .cart-line {
  padding: 10px 14px;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
body.shell-phone .sky-cart .cart-line:last-child {
  margin-bottom: 0;
}
body.shell-phone .sky-cart .cart-line.is-deal-free {
  background: color-mix(in srgb, var(--btn-chip-on-bg, #e8f2ff) 12%, transparent);
}

/* crm790: sticky totals = kit language (admin-opt-group + pack chips) */
.sky-cart .cart-checkout-sticky,
.sky-cart .sticky.cart-checkout-sticky {
  margin-top: 14px;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.sky-cart .cart-checkout-sticky .cart-money-totals.admin-opt-group {
  margin: 0 0 10px;
}
.sky-cart .cart-checkout-sticky .cart-money-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  margin: 0;
  padding: 10px 14px;
  position: relative;
  font-size: 0.88rem;
  font-weight: var(--fw-med);
  letter-spacing: -0.01em;
  color: color-mix(in srgb, var(--muted) 82%, var(--ink));
  font-variant-numeric: tabular-nums;
}
.sky-cart .cart-checkout-sticky .cart-money-row:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 1px;
  background: var(--line);
  pointer-events: none;
}
.sky-cart .cart-checkout-sticky .cart-money-lab {
  min-width: 0;
  color: inherit;
}
.sky-cart .cart-checkout-sticky .cart-money-val {
  flex: 0 0 auto;
  color: var(--ink);
  font-weight: var(--fw-med);
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.sky-cart .cart-checkout-sticky .cart-money-row.cart-total-incl {
  min-height: 56px;
  padding-top: 12px;
  padding-bottom: 12px;
  color: var(--ink);
  font-size: 1.02rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
  background: color-mix(in srgb, var(--btn-chip-on-bg) 18%, transparent);
}
.sky-cart .cart-checkout-sticky .cart-money-row.cart-total-incl .cart-money-lab {
  font-weight: var(--fw-semi);
}
.sky-cart .cart-checkout-sticky .cart-money-row.cart-total-incl .cart-money-val {
  font-size: 1.18rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
}
.sky-cart .cart-checkout-sticky .cart-pack-sec.admin-opt-sec {
  margin: 2px 0 6px;
}
.sky-cart .cart-checkout-sticky .cart-pack-totals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  margin: 0 0 12px;
  padding: 4px;
  border-radius: var(--btn-radius-seg, var(--radius-sm));
  background: var(--btn-seg-track, #2c2c2e);
  box-sizing: border-box;
}
.sky-cart .cart-checkout-sticky .cart-pack-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 0;
  min-height: var(--btn-h-sm, 34px);
  padding: 6px 6px 7px;
  border-radius: var(--btn-radius-seg-item, var(--btn-chip-radius, var(--radius-sm)));
  border: 1px solid transparent;
  background: color-mix(in srgb, var(--bg-elevated) 55%, transparent);
  font-variant-numeric: tabular-nums;
  text-align: center;
}
.sky-cart .cart-checkout-sticky .cart-pack-stat em {
  font-style: normal;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
}
.sky-cart .cart-checkout-sticky .cart-pack-stat strong {
  font-size: 0.9rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
/* Sticky CTAs — hard squircle lock (never stadium / 999 / 980). */
.sky-cart .cart-checkout-sticky .btn,
body.shell-phone .sky-cart .cart-checkout-sticky .btn,
body.shell-phone .cart-checkout-sticky .btn {
  width: 100%;
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
  transition:
    background 0.15s var(--ease, ease),
    border-color 0.15s var(--ease, ease),
    box-shadow 0.15s var(--ease, ease),
    transform 0.12s var(--ease, ease),
    opacity 0.15s var(--ease, ease);
}
.sky-cart .cart-checkout-sticky .btn:active:not(:disabled) {
  transform: scale(0.98);
}
.sky-cart .cart-checkout-sticky #btnSubmit:not(:disabled):active {
  transform: scale(0.985);
}
.sky-cart .cart-line-actions .rm-line,
.sky-cart .cart-table td.cart-td-rm .rm-line {
  transition:
    background 0.14s var(--ease, ease),
    border-color 0.14s var(--ease, ease),
    transform 0.12s var(--ease, ease);
}
.sky-cart .cart-line-actions .rm-line:active,
.sky-cart .cart-table td.cart-td-rm .rm-line:active {
  transform: scale(0.94);
}
.sky-cart .cart-phone-stepper .qty-btn:active,
.sky-cart .cart-table-stepper .qty-btn:active {
  background: rgba(255, 255, 255, 0.12);
}
.sky-cart .cart-assign-cta .btn:active:not(:disabled) {
  transform: scale(0.98);
}
body:not(.shell-phone) .sky-cart .cart-layout .checkout-box {
  border-color: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 14px 14px 12px;
  background: var(--bg-elevated);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
}

/* --- Shop product cards: calm surface + matched Add/QTY weight --- */
.products .product,
.products-phone .product,
.products-phone .product-phone {
  border-radius: var(--radius-sm);
  border-color: rgba(255, 255, 255, 0.07);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
  transition:
    background 0.15s var(--ease, ease),
    border-color 0.15s var(--ease, ease),
    box-shadow 0.18s var(--ease, ease),
    transform 0.14s var(--ease, ease);
}
.products .product:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.38);
}
.products .product-media {
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.products .product .meta h3 {
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
/* QTY stays compact fit-content squircle ? never stretch / stadium */
.products .add-row .qty-stepper,
.products .add-row.product-actions .qty-stepper,
.products-phone .add-row .qty-stepper,
.products-phone .add-row.product-actions .qty-stepper {
  flex: 0 0 auto !important;
  width: fit-content !important;
  max-width: 100%;
  height: 100% !important;
  min-height: 0 !important;
  align-self: stretch;
  border-radius: var(--btn-chip-radius) !important;
  box-sizing: border-box;
}
.products .add-row .qty-stepper .qty,
.products-phone .add-row .qty-stepper .qty {
  align-self: stretch;
  height: 100%;
  box-sizing: border-box;
}
/* Add (+) matches QTY row height ? primary squircle, same optical weight */
.products .add-row .crm-plus-ico.add-sku,
.products .add-row .hdr-icon-btn.crm-plus-ico.add-sku,
.products-phone .add-row .crm-plus-ico.add-sku,
.products-phone .add-row .hdr-icon-btn.crm-plus-ico.add-sku {
  flex: 0 0 var(--product-qty-row-h, 40px) !important;
  width: var(--product-qty-row-h, 40px) !important;
  min-width: var(--product-qty-row-h, 40px) !important;
  max-width: var(--product-qty-row-h, 40px) !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: none !important;
  aspect-ratio: auto !important;
  align-self: stretch;
  box-sizing: border-box !important;
  border-radius: var(--btn-radius) !important;
  background: var(--btn-primary-bg) !important;
  border: 1px solid var(--btn-primary-border) !important;
  box-shadow: var(--btn-primary-shadow) !important;
  color: #fff !important;
  font-size: 1.35rem !important;
  font-weight: 300 !important;
  line-height: 1 !important;
  padding: 0 !important;
  display: inline-grid !important;
  place-items: center !important;
  transition:
    background 0.15s var(--ease, ease),
    border-color 0.15s var(--ease, ease),
    box-shadow 0.15s var(--ease, ease),
    transform 0.12s var(--ease, ease);
  position: relative;
  overflow: visible;
}
.products .add-row .crm-plus-ico.add-sku.is-in-cart,
.products-phone .add-row .crm-plus-ico.add-sku.is-in-cart {
  background: color-mix(in srgb, var(--btn-chip-on-bg) 65%, var(--btn-primary-bg)) !important;
  border-color: var(--btn-chip-on-border) !important;
}
.products .add-row .crm-plus-ico.add-sku .add-sku-plus,
.products-phone .add-row .crm-plus-ico.add-sku .add-sku-plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.products .add-row .crm-plus-ico.add-sku .add-sku-badge,
.products-phone .add-row .crm-plus-ico.add-sku .add-sku-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  box-shadow: var(--btn-chip-on-shadow);
  color: var(--ink);
  font-size: 10px;
  font-weight: var(--fw-bold);
  line-height: 14px;
  text-align: center;
}
.products .add-row .crm-plus-ico.add-sku:hover,
.products-phone .add-row .crm-plus-ico.add-sku:hover {
  background: var(--btn-primary-bg-hover, var(--accent-press)) !important;
  box-shadow: var(--btn-primary-shadow-hover) !important;
}
.products .add-row .crm-plus-ico.add-sku:active,
.products-phone .add-row .crm-plus-ico.add-sku:active {
  transform: scale(0.94);
  background: var(--accent-press) !important;
}
.products .add-row .qty-btn:active,
.products-phone .add-row .qty-btn:active {
  background: rgba(255, 255, 255, 0.12);
}
.shop-screen.shell-phone .products-phone .add-row .crm-plus-ico.add-sku,
.shop-screen.shell-phone .products-phone .add-row .hdr-icon-btn.crm-plus-ico.add-sku {
  flex: 0 0 var(--product-qty-row-h, 40px) !important;
  width: var(--product-qty-row-h, 40px) !important;
  min-width: var(--product-qty-row-h, 40px) !important;
  max-width: var(--product-qty-row-h, 40px) !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: none !important;
  align-self: stretch !important;
  border-radius: var(--btn-radius) !important;
  box-sizing: border-box !important;
}
body:not(.shell-phone) .products .add-row .crm-plus-ico.add-sku,
body:not(.shell-phone) .products .add-row .hdr-icon-btn.crm-plus-ico.add-sku {
  flex: 0 0 40px !important;
  width: 40px !important;
  min-width: 40px !important;
  max-width: 40px !important;
}

@media (prefers-reduced-motion: reduce) {
  .checkout-box .cart-site-seg .acal-seg-btn,
  .checkout-box .cart-wh-seg .pl-seg-btn,
  .sky-cart .cart-checkout-sticky .btn,
  .sky-cart .cart-line-actions .rm-line,
  .products .add-row .crm-plus-ico.add-sku,
  .products .product {
    transition: none;
  }
  .checkout-box .cart-site-seg .acal-seg-btn:active:not([aria-disabled="true"]),
  .checkout-box .cart-wh-seg .pl-seg-btn:active,
  .sky-cart .cart-checkout-sticky .btn:active:not(:disabled),
  .products .add-row .crm-plus-ico.add-sku:active,
  .products .product:hover {
    transform: none;
  }
}
/* ===== end crm543 Cosmetic Pack B ===== */

/* ===== crm544 Cosmetic Pack C ? Calendar + Forms hub chrome ===== */
/* Filter rail open/fold/default-closed behaviour unchanged ? look tokens only. */

/* --- Calendar: leftover one-offs ? Filter / Customers chip language --- */
.acal-event {
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.sky-day {
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.acal-cal-pill {
  border: 1px solid var(--btn-ghost-border, rgba(255, 255, 255, 0.12));
  background: var(--btn-ghost-bg, rgba(44, 44, 46, 0.9));
  box-shadow: var(--btn-ghost-shadow, inset 0 1px 0 rgba(255, 255, 255, 0.04));
  color: var(--ink-secondary);
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.acal-user-filter select,
.sky-filter-select,
.sky-filter-field select {
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}

/* Desk segs / Today / icon / fold heads ? squircle tokens (not stadium) */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-desk .acal-seg,
  body:not(.shell-phone) .crm-plan-tasks .acal-seg {
    border-radius: var(--btn-radius-seg);
  }
  body:not(.shell-phone) .sky-desk .acal-seg-btn,
  body:not(.shell-phone) .crm-plan-tasks .acal-seg-btn {
    border-radius: var(--btn-radius-seg-item);
  }
  body:not(.shell-phone) .sky-desk .acal-today-btn {
    border-radius: var(--btn-chip-radius, var(--radius-sm));
  }
  body:not(.shell-phone) .sky-desk .acal-icon-btn {
    border-radius: var(--btn-chip-radius, var(--radius-sm));
  }
  body:not(.shell-phone) .sky-filter-premium .sky-filter-fold {
    border-radius: var(--btn-chip-radius, var(--radius-sm));
  }
  body:not(.shell-phone) .sky-desk .acal-toolbar-sky {
    padding: 2px 14px 8px;
  }
  body:not(.shell-phone) .sky-desk .acal-period {
    font-size: 1.02rem;
    font-weight: var(--fw-semi);
    letter-spacing: -0.025em;
  }
}

/* Phone denser quieter Calendar chrome */
body.shell-phone .acal-toolbar-phone {
  gap: 6px;
  padding: 0 2px 4px;
}
body.shell-phone .acal-toolbar-phone-combo {
  padding: 0 2px 6px;
}
body.shell-phone .acal-toolbar-phone-top .acal-today-btn {
  font-size: 0.98rem;
  font-weight: var(--fw-med);
  min-height: 40px;
}
body.shell-phone .acal-period-nav .acal-period {
  font-size: 0.98rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.02em;
}
body.shell-phone .acal-period-nav .acal-period-chev {
  width: 36px;
  min-width: 36px;
  height: 40px;
}
body.shell-phone .acal-seg {
  padding: 2px;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg-btn {
  padding: 6px 4px;
  font-size: 0.76rem;
  min-height: 40px;
  font-weight: var(--fw-med);
}
body.shell-phone .acal-search-input-inline {
  font-size: 0.8rem;
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
}
body.shell-phone .acal-filter-icon-btn,
body.shell-phone .acal-add-icon-btn,
body.shell-phone .hdr-icon-btn.acal-filter-icon-btn,
body.shell-phone .hdr-icon-btn.acal-add-icon-btn {
  border-radius: var(--btn-radius, var(--radius-sm)) !important;
  opacity: 0.92;
}
body.shell-phone .acal-toolbar-phone .acal-cpt-chip,
body.shell-phone .acal-toolbar-phone-actions .acal-cpt-chip {
  min-height: 28px;
  padding: 4px 9px;
  font-size: 0.72rem;
}
body.shell-phone .acal-quick-row .acal-people-chip {
  min-height: 36px;
  padding: 6px 12px;
  font-size: 0.76rem;
}
body.shell-phone .sky-card {
  border-radius: var(--radius-sm);
  border-color: rgba(255, 255, 255, 0.06);
  background: var(--bg-elevated, rgba(28, 28, 30, 0.92));
}
body.shell-phone .sky-card-list {
  gap: 6px;
}
body.shell-phone .sky-card-main {
  padding: 10px 10px 8px 12px;
}
body.shell-phone .acal-phone-detail {
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  padding: 12px 14px calc(12px + var(--safe-bottom, 0px));
}
body.shell-phone .acal-detail-status {
  font-size: 0.7rem;
  padding: 3px 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* --- Forms hub: match Customers / Admin chips + row language --- */
.sky-hub-forms .sky-page-head > h1,
.sky-hub-forms .sky-page-head-titles h1 {
  letter-spacing: -0.03em;
  font-weight: var(--fw-semi);
}
.sky-hub-forms .sky-forms-toolbar {
  gap: 6px;
  margin: 0 0 8px;
  padding: 0 2px;
}
.sky-hub-forms .sky-forms-toolbar .btn {
  border-radius: var(--btn-radius, var(--radius-sm));
  min-height: 32px;
  font-size: 0.78rem;
}
.sky-hub-forms .sky-forms-toolbar-note {
  font-size: 0.76rem;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}
.sky-hub-forms .form-status-badge {
  padding: 3px 8px;
  font-size: 0.7rem;
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
.sky-hub-forms .form-status-badge.is-failed {
  border-color: rgba(255, 69, 58, 0.28);
}
.sky-hub-forms .form-status-badge.is-pending {
  border-color: rgba(255, 159, 10, 0.22);
}
.sky-hub-forms .form-status-badge.is-posted {
  border-color: rgba(48, 209, 88, 0.22);
}
.sky-hub-forms .sky-hub-banner {
  padding: 8px 10px;
  margin-bottom: 8px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}

/* Phone Forms rows ? Customers denser list */
body.shell-phone .sky-hub-forms .sky-forms-rows.ios-hub-group {
  gap: 0;
  padding: 0 0 8px;
}
body.shell-phone .sky-hub-forms .sky-forms-rows .ios-hub-group-body {
  margin: 0;
}
body.shell-phone .sky-hub-forms .sky-forms-row-wrap {
  border-bottom: 0;
  position: relative;
}
body.shell-phone .sky-hub-forms .sky-forms-row-wrap:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
  z-index: 1;
}
body.shell-phone .sky-hub-forms .sky-forms-row {
  padding: 9px 12px 9px 14px;
  gap: 10px;
  min-height: 44px;
  transition: background 0.14s var(--ease, ease);
}
body.shell-phone .sky-hub-forms .sky-forms-row:active:not(:disabled) {
  background: rgba(255, 255, 255, 0.07);
}
body.shell-phone .sky-hub-forms .sky-forms-row-main strong {
  font-size: 0.94rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.015em;
  color: var(--ink);
  line-height: 1.25;
}
body.shell-phone .sky-hub-forms .sky-forms-row-meta {
  font-size: 0.76rem;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
  letter-spacing: -0.01em;
}
body.shell-phone .sky-hub-forms .sky-forms-row-foot {
  padding: 0 14px 8px;
}
body.shell-phone .sky-hub-forms .sky-hub-tools {
  gap: 5px;
  padding: 1px 0 2px;
}
body.shell-phone .sky-hub-forms .sky-hub-tools .hdr-icon-btn,
body.shell-phone .sky-hub-forms .sky-hub-tools .crm-plus-ico {
  border-radius: var(--btn-radius, var(--radius-sm)) !important;
  opacity: 0.92;
}
body.shell-phone .sky-hub-forms .sky-hub-tools .sky-page-search input {
  border-radius: var(--btn-radius, var(--radius-sm));
}

/* Desk Forms quieter table + toolbar */
@media (min-width: 901px) {
  body:not(.shell-phone) .sky-hub-forms .sky-forms-toolbar {
    margin-bottom: 6px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table th,
  body:not(.shell-phone) .sky-hub-forms .sky-forms-table .hist-table td {
    padding-top: 7px;
    padding-bottom: 7px;
  }
  body:not(.shell-phone) .sky-hub-forms .sky-hub-body .sky-view-item,
  body:not(.shell-phone) .sky-hub-forms .crm-smart-rail .sky-view-item {
    border-radius: var(--btn-chip-radius);
    min-height: 32px;
    padding: 6px 10px;
    font-size: 0.82rem;
  }
}

/* New form sheet seg ? shared seg tokens */
.sky-forms-new-sheet .sky-phone-seg {
  border-radius: var(--btn-radius-seg);
  padding: 3px;
  background: var(--btn-seg-track, rgba(44, 44, 46, 0.92));
}
.sky-forms-new-sheet .sky-phone-seg-btn {
  border-radius: var(--btn-radius-seg-item);
  min-height: 36px;
  font-size: 0.78rem;
}
.sky-forms-new-sheet .sky-phone-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}

@media (prefers-reduced-motion: reduce) {
  body.shell-phone .sky-hub-forms .sky-forms-row {
    transition: none;
  }
}
/* ===== end crm544 Cosmetic Pack C ===== */

/* ===== crm546 Cosmetic Pack 4 ? Settings iOS-grade ===== */
/* .settings-list background already var(--bg-elevated) (= .ios-hub-group-body).
   Passkey devices = settings-rows; Role access = settings-list groups (no admin-card). */
.settings-list.settings-role-list > .settings-role-group:not(:last-child)::after {
  left: 14px;
}
/* ===== end crm546 Cosmetic Pack 4 ===== */

/* ===== crm547 Cosmetic Pack 5 ? Home premium (toward reference) ===== */
.home-kpi-strip-premium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 10px;
  max-width: 100%;
}
.home-kpi-strip-premium .home-kpi {
  min-height: 72px;
  padding: 12px 12px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-elevated) 92%, #fff 8%), var(--bg-elevated));
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.32), 0 8px 20px rgba(0, 0, 0, 0.18);
  text-align: left;
  transition: transform 0.12s var(--ease, ease), border-color 0.15s ease, background 0.15s ease;
}
.home-kpi-strip-premium .home-kpi strong {
  display: block;
  font-size: 1.45rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 4px;
}
.home-kpi-strip-premium .home-kpi-lab {
  font-size: 0.72rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.01em;
  opacity: 0.92;
}
.home-kpi-strip-premium .home-kpi.is-late {
  border-color: color-mix(in srgb, #ff453a 42%, transparent);
  background: linear-gradient(180deg, color-mix(in srgb, #ff453a 14%, var(--bg-elevated)), var(--bg-elevated));
}
.home-kpi-strip-premium .home-kpi.is-late strong { color: #ff6961; }
.home-kpi-strip-premium .home-kpi.is-soon {
  border-color: color-mix(in srgb, var(--accent) 38%, transparent);
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 12%, var(--bg-elevated)), var(--bg-elevated));
}
.home-kpi-strip-premium .home-kpi.is-soon strong { color: color-mix(in srgb, var(--accent) 78%, #fff 22%); }
.home-kpi-strip-premium .home-kpi.is-upcoming {
  border-color: color-mix(in srgb, #30d158 38%, transparent);
  background: linear-gradient(180deg, color-mix(in srgb, #30d158 12%, var(--bg-elevated)), var(--bg-elevated));
}
.home-kpi-strip-premium .home-kpi.is-upcoming strong { color: #30d158; }
.home-kpi-strip-premium .home-kpi:active { transform: scale(0.985); }

.home-next-up {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 14px;
  margin: 0 0 10px;
  border-radius: var(--radius-sm);
  border: 1px solid color-mix(in srgb, var(--accent) 28%, rgba(255, 255, 255, 0.08));
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 16%, transparent), transparent 55%),
    var(--bg-elevated);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28), 0 10px 24px rgba(0, 0, 0, 0.22);
}
.home-next-up-main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.home-next-up-kicker {
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 90%, transparent);
}
.home-next-up-name {
  font-size: 1.02rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.home-next-up-meta {
  font-size: 0.78rem;
  color: var(--muted);
}
.home-next-up-cta {
  flex: 0 0 auto;
  min-height: 40px;
  padding: 0 16px;
  border-radius: var(--btn-radius) !important;
  font-weight: var(--fw-semi, 600);
  box-shadow: var(--btn-primary-shadow);
}
.home-radar-list-wrap .home-radar-sec-label {
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 88%, transparent);
  margin: 4px 0 8px;
}
.crm-home-head .home-greet,
.sky-dash-head .home-greet {
  letter-spacing: -0.04em;
}
.home-deals .home-deal-card,
.crm-home .home-deals {
  border-radius: var(--radius-sm);
}
@media (max-width: 900px) {
  .home-kpi-strip-premium {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }
  .home-kpi-strip-premium .home-kpi {
    min-height: 64px;
    padding: 10px 8px 8px;
  }
  .home-kpi-strip-premium .home-kpi strong { font-size: 1.2rem; }
  .home-kpi-strip-premium .home-kpi-lab { font-size: 0.64rem; }
  .home-next-up { padding: 12px; }
  .home-next-up-cta { min-height: 38px; padding: 0 12px; font-size: 0.85rem; }
}
/* ===== end crm547 Cosmetic Pack 5 ===== */

/* ===== crm548 Users filter-menus + Home ChatGPT-ref ===== */
.home-next-up.is-hero {
  margin: 0 0 12px;
  padding: 16px 14px;
  min-height: 88px;
  border-width: 1px;
  border-color: color-mix(in srgb, var(--accent) 40%, rgba(255, 255, 255, 0.1));
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.28),
    0 14px 28px rgba(0, 0, 0, 0.28),
    0 0 0 1px color-mix(in srgb, var(--accent) 12%, transparent);
}
.home-next-up.is-hero .home-next-up-name {
  font-size: 1.12rem;
}
.home-next-up.is-hero .home-next-up-cta {
  min-height: 44px;
  padding: 0 18px;
  font-size: 0.92rem;
}
.home-radar-list-wrap.is-after-hero .home-radar-sec-label {
  margin-top: 4px;
  opacity: 0.9;
}
.home-radar.is-compact .home-radar-head {
  margin-bottom: 6px;
}
body.shell-phone .crm-home .home-kpi-strip-premium {
  margin: 4px 0 12px;
}
/* crm549: do NOT force KPI above greeting ? ChatGPT ref = greeting ? KPI ? Next Up */
/* ===== end crm548 ===== */

/* ===== crm549 / crm591: Settings inset groups (Apple section spacing) ===== */
.settings-panel.settings-page.is-hub .settings-stack {
  gap: 18px;
}
/* Account group: hero + following account/security row share one inset list — light divider */
.settings-list > .settings-profile-hero + :is(.settings-profile-row, .settings-row) {
  border-top: 1px solid color-mix(in srgb, var(--line, rgba(128, 128, 128, 0.28)) 85%, transparent);
}
.settings-panel .sky-filter-fold-body .settings-list.is-in-fold {
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
}
.settings-panel .sky-filter-fold-body .settings-profile-hero {
  padding: 14px;
}
.settings-panel .sky-filter-fold-body .settings-profile-hero + .settings-profile-row {
  border-top: 1px solid color-mix(in srgb, var(--line, rgba(128, 128, 128, 0.28)) 85%, transparent);
}
.settings-panel .ios-filter-row.settings-ios-nav .ios-filter-row-lab {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.settings-panel .ios-filter-row.settings-ios-nav {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 18px;
  align-items: center;
  min-height: var(--btn-h, 44px);
  gap: 10px;
  padding: 8px 14px;
}
.settings-panel .ios-filter-row.settings-ios-nav .settings-row-ico {
  width: 30px;
  height: 30px;
}
.settings-panel :is(.settings-row-btn, .settings-passkey-row .btn.small) {
  min-width: 78px;
  justify-content: center;
}
.settings-panel .ios-filter-row.settings-ios-nav .settings-row-blurb {
  font-size: 0.78rem;
  font-weight: var(--fw-reg, 400);
  color: var(--muted);
  white-space: normal;
}
.settings-panel .ios-filter-row.settings-logout-row .ios-filter-row-txt {
  color: #ff453a;
}
/* ===== end crm549 ===== */

/* ===== crm551 Wave1 ? motion tokens wired + Home ChatGPT density + nav glass ===== */

/* Shared press language (buttons already use tokens; chips + Home surfaces). */
.acal-people-chip,
.sky-tl-chip,
.home-radar-chip,
.cat-list-sheet .cat-pick,
.shop-sheet-opt,
.sky-view-item {
  transition:
    background var(--dur-state, 200ms) var(--ease),
    border-color var(--dur-state, 200ms) var(--ease),
    color var(--dur-state, 200ms) var(--ease),
    box-shadow var(--dur-state, 200ms) var(--ease),
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease));
}
.acal-people-chip:active,
.sky-tl-chip:active,
.home-radar-chip:active,
.cat-list-sheet .cat-pick:active,
.shop-sheet-opt:active,
.sky-view-item:active {
  transform: scale(0.97);
}
.acal-people-chip:disabled:active,
.sky-tl-chip:disabled:active,
.home-radar-chip:disabled:active,
.cat-list-sheet .cat-pick:disabled:active,
.shop-sheet-opt:disabled:active,
.sky-view-item:disabled:active,
.acal-people-chip[aria-disabled="true"]:active,
.sky-tl-chip[aria-disabled="true"]:active,
.home-radar-chip[aria-disabled="true"]:active {
  transform: none;
}

.home-kpi,
.home-kpi-strip-premium .home-kpi,
.home-next-up,
.home-deals-card {
  transition:
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease)),
    border-color var(--dur-state, 200ms) var(--ease),
    background var(--dur-state, 200ms) var(--ease),
    box-shadow var(--dur-state, 200ms) var(--ease),
    filter var(--dur-state, 200ms) var(--ease);
}
.home-kpi:active,
.home-kpi-strip-premium .home-kpi:active,
.home-next-up:active {
  transform: scale(0.985);
}
.home-kpi:disabled:active,
.home-kpi[aria-disabled="true"]:active {
  transform: none;
}
.home-deals-card:active {
  transform: scale(0.985);
  filter: brightness(0.97);
}
.home-deals-card:disabled:active,
.home-deals-card[aria-disabled="true"]:active {
  transform: none;
  filter: none;
}

/* KPI strip ? denser premium tiles (Overdue red / Due blue / Upcoming green). */
.home-kpi-strip-premium {
  gap: 6px;
  margin: 0 0 8px;
}
.home-kpi-strip-premium .home-kpi {
  min-height: 64px;
  padding: 10px 10px 8px;
  border-radius: var(--radius-sm);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28), 0 6px 14px rgba(0, 0, 0, 0.16);
}
.home-kpi-strip-premium .home-kpi strong {
  font-size: 1.28rem;
  letter-spacing: -0.045em;
  margin-bottom: 2px;
}
.home-kpi-strip-premium .home-kpi-lab {
  font-size: 0.68rem;
  letter-spacing: 0.02em;
  opacity: 0.9;
}
.home-kpi-strip-premium .home-kpi.is-late {
  border-color: color-mix(in srgb, var(--danger, #ff453a) 40%, transparent);
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--danger, #ff453a) 12%, var(--bg-elevated)),
    var(--bg-elevated)
  );
}
.home-kpi-strip-premium .home-kpi.is-late strong {
  color: color-mix(in srgb, var(--danger, #ff453a) 82%, #fff 18%);
}
.home-kpi-strip-premium .home-kpi.is-soon {
  border-color: color-mix(in srgb, var(--accent) 36%, transparent);
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--accent) 11%, var(--bg-elevated)),
    var(--bg-elevated)
  );
}
.home-kpi-strip-premium .home-kpi.is-soon strong {
  color: color-mix(in srgb, var(--accent) 80%, #fff 20%);
}
.home-kpi-strip-premium .home-kpi.is-upcoming {
  border-color: color-mix(in srgb, var(--ok, #30d158) 36%, transparent);
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--ok, #30d158) 11%, var(--bg-elevated)),
    var(--bg-elevated)
  );
}
.home-kpi-strip-premium .home-kpi.is-upcoming strong {
  color: var(--ok, #30d158);
}

/* Next Up hero ? stronger, not noisy. */
.home-next-up.is-hero {
  margin: 0 0 10px;
  padding: 15px 14px;
  min-height: 84px;
  border-radius: var(--radius-sm);
  border-color: color-mix(in srgb, var(--accent) 44%, rgba(255, 255, 255, 0.1));
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 18%, transparent), transparent 58%),
    linear-gradient(180deg, color-mix(in srgb, var(--bg-elevated) 88%, #fff 12%), var(--bg-elevated));
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.28),
    0 12px 26px rgba(0, 0, 0, 0.26),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.home-next-up.is-hero .home-next-up-kicker {
  color: color-mix(in srgb, var(--accent) 55%, var(--muted));
}
.home-next-up.is-hero .home-next-up-name {
  font-size: 1.14rem;
  letter-spacing: -0.03em;
}
.home-next-up.is-hero .home-next-up-cta {
  min-height: 44px;
  border-radius: var(--btn-radius) !important;
}

/* Running Deals ? horizontal snap scroller (new class + phone grid). */
.home-deals-scroller,
body.shell-phone .crm-home .home-deals-grid {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 10px;
  align-items: stretch;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  margin: 0 -2px;
  padding: 2px 2px 6px;
}
.home-deals-scroller::-webkit-scrollbar,
body.shell-phone .crm-home .home-deals-grid::-webkit-scrollbar {
  display: none;
}
.crm-scroll-overflow-cue {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 14px;
  margin: 1px 0 0;
  color: color-mix(in srgb, var(--muted) 58%, transparent);
}
.crm-scroll-overflow-cue[hidden] {
  display: none;
}
.crm-scroll-overflow-cue i {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  transition:
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease)),
    background var(--dur-state, 200ms) var(--ease);
}
.crm-scroll-overflow-cue i.is-on {
  color: var(--accent);
  transform: scale(1.18);
}
.home-deals-scroller > .home-deals-card,
.home-deals-scroller > .home-deals-card-wrap,
.home-deals-scroller > .home-deals-snap,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap {
  flex: 0 0 82%;
  width: 82%;
  max-width: 82%;
  scroll-snap-align: start;
  scroll-snap-stop: normal;
  min-width: 0;
  height: auto;
}
.home-deals-scroller > .home-deals-snap .home-deals-card,
.home-deals-scroller > .home-deals-card-wrap .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap .home-deals-card {
  width: 100%;
  min-height: 72px;
}
/* Deals interleaved between Next Up and Next stops (phone Wave 1). */
.home-radar-deals-slot {
  margin: 10px 0 12px;
  min-width: 0;
}
.home-radar-deals-slot .home-deals {
  margin: 0;
}
.home-radar-deals-slot .home-deals-head {
  margin-bottom: 8px;
}

/* Next stops ? cleaner rows. */
.home-radar-list-wrap .home-radar-sec-label,
.home-radar.is-compact .home-radar-sec-label {
  margin: 2px 0 6px;
  padding-top: 0;
  border-top: 0;
  font-size: 0.66rem;
  letter-spacing: 0.07em;
  opacity: 0.88;
}
.home-radar-list {
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--bg-elevated) 92%, #fff 8%);
  border-color: rgba(255, 255, 255, 0.07);
}
.home-radar-list > li + li {
  border-top-color: rgba(255, 255, 255, 0.055);
}
.home-radar-row {
  padding: 10px 12px;
  min-height: 46px;
  gap: 8px;
  transition:
    background var(--dur-state, 200ms) var(--ease),
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease));
}
.home-radar-row:active {
  transform: scale(0.992);
  background: rgba(255, 255, 255, 0.04);
}
.home-radar-row:disabled:active {
  transform: none;
}
.home-radar-name {
  font-size: 0.9rem;
  letter-spacing: -0.015em;
}
.home-radar-last {
  font-size: 0.68rem;
}
.home-radar-meta {
  border-radius: var(--btn-radius-seg-item);
  padding: 4px 8px;
  font-size: 0.66rem;
}

/* Phone bottom-nav ? light glass polish; still 4 equal tabs, no center-+. */
body.shell-phone .bottom-nav,
body.shell-phone .app-shell.has-bottom-nav .bottom-nav {
  grid-template-columns: repeat(var(--bn-cols, 4), minmax(0, 1fr));
  background: color-mix(in srgb, var(--bottom-nav-bg) 88%, transparent);
  backdrop-filter: saturate(1.15) blur(14px);
  -webkit-backdrop-filter: saturate(1.15) blur(14px);
  border-top-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.18);
}
body.shell-phone .bottom-nav-link {
  transition:
    color var(--dur-state, 200ms) var(--ease),
    background var(--dur-state, 200ms) var(--ease),
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease));
  border-radius: var(--btn-chip-radius, var(--radius-sm));
}
body.shell-phone .bottom-nav-ico,
.bottom-nav-ico {
  transition:
    background var(--dur-state, 200ms) var(--ease),
    transform var(--dur-micro, 120ms) var(--ease-press, var(--ease));
}
body.shell-phone .bottom-nav-link:active {
  transform: scale(0.96);
}
body.shell-phone .bottom-nav-link:active .bottom-nav-ico,
.bottom-nav-link:active .bottom-nav-ico {
  transform: scale(0.94);
}

@media (max-width: 900px) {
  .home-kpi-strip-premium {
    gap: 5px;
    margin: 0 0 8px;
  }
  .home-kpi-strip-premium .home-kpi {
    min-height: 58px;
    padding: 8px 7px 7px;
  }
  .home-kpi-strip-premium .home-kpi strong {
    font-size: 1.12rem;
  }
  .home-kpi-strip-premium .home-kpi-lab {
    font-size: 0.62rem;
  }
  .home-next-up.is-hero {
    padding: 13px 12px;
    min-height: 78px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn,
  .sky-cust-filter-chip,
  .acal-people-chip,
  .sky-tl-chip,
  .home-radar-chip,
  .cat-list-sheet .cat-pick,
  .shop-sheet-opt,
  .sky-view-item,
  .home-kpi,
  .home-kpi-strip-premium .home-kpi,
  .home-next-up,
  .home-deals-card,
  .home-radar-row,
  body.shell-phone .bottom-nav-link,
  body.shell-phone .bottom-nav-ico,
  .bottom-nav-ico {
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
  }
  .btn:active,
  .sky-cust-filter-chip:active,
  .acal-people-chip:active,
  .sky-tl-chip:active,
  .home-radar-chip:active,
  .cat-list-sheet .cat-pick:active,
  .shop-sheet-opt:active,
  .sky-view-item:active,
  .home-kpi:active,
  .home-kpi-strip-premium .home-kpi:active,
  .home-next-up:active,
  .home-deals-card:active,
  .home-radar-row:active,
  body.shell-phone .bottom-nav-link:active,
  body.shell-phone .bottom-nav-link:active .bottom-nav-ico,
  .bottom-nav-link:active .bottom-nav-ico {
    transform: none !important;
  }
  .home-deals-scroller,
  body.shell-phone .crm-home .home-deals-grid {
    scroll-behavior: auto;
  }
  .crm-scroll-overflow-cue i {
    transition: none;
  }
}
/* ===== end crm551 Wave1 ===== */

/* Hub Timeline type chips (All / Invoices / Credits / All docs) */
.ios-hub-timeline-body .hub-tl-type-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 10px;
  padding: 0 2px;
}
.ios-hub-timeline-body .hub-tl-type-chips .sky-tl-chip {
  margin: 0;
}

/* ===== crm555 phone density =====
   Kill viewport min-height floors / flex-grow voids on phone.
   Content height = content; .app-body owns scroll. Overrides earlier rules. */
body.shell-phone .crm-home,
body.shell-phone .crm-home.is-phone.sky-dash,
body.shell-phone .sky-hub-page:is(.sky-hub-forms, .sky-hub-timeline, .sky-hub-tasks, .sky-hub-reports),
body.shell-phone .sky-customers,
body.shell-phone .sky-customer-hub,
body.shell-phone .sky-near-me,
body.shell-phone .sky-page.sky-near-me,
body.shell-phone .settings-panel.settings-page {
  min-height: 0 !important;
}

/* Timeline groups: content-sized (no flex grow void). */
body.shell-phone .sky-hub-timeline .sky-tl-groups,
body.shell-phone .sky-customer-hub .sky-tl-groups {
  flex: 0 0 auto !important;
  overflow: visible !important;
}

/* PDF phone: stage is app chrome (dark), not a white void; page canvas stays white. */
body.shell-phone .pdf-view-page.is-phone .pdf-view-stage {
  background: #3a3a3c !important;
}
body.shell-phone .pdf-view-page.is-phone {
  padding-bottom: 0 !important;
}
body.shell-phone .pdf-view-page.is-phone .pdf-view-stage.is-native {
  padding-bottom: 12px !important;
}
body.shell-phone .pdf-view-page.is-phone .pdf-js-page {
  background: #fff !important;
}

/* Home: sticky visit clearance only via :has(.sky-sticky-visit) ? no phantom pad.
   Neutralize unused legacy .sky-dash-mobile bottom pad under phone. */
body.shell-phone .sky-dash-mobile {
  padding-bottom: 0 !important;
}

/* Products list: modest bottom breathing room (nav is in-flow). */
body.shell-phone .sky-shop .products,
body.shell-phone .products.products-phone {
  padding-bottom: 16px !important;
}
/* ===== end crm555 phone density ===== */

/* ===== crm556 phone densify chrome (less top/bottom waste) ===== */
body.shell-phone .settings-panel.settings-page {
  padding: 6px 12px 12px !important;
}
body.shell-phone .settings-panel .settings-stack {
  gap: 10px !important;
  margin-top: 4px !important;
  margin-bottom: 0 !important;
}
/* Hub: comfortable Apple section gaps (override densify squeeze). */
body.shell-phone .settings-panel.settings-page.is-hub .settings-stack {
  gap: 16px !important;
  margin-top: 6px !important;
}
body.shell-phone .settings-panel.settings-page.is-hub {
  padding-bottom: calc(var(--bottom-nav-h, 56px) + 16px) !important;
}
body.shell-phone .settings-panel .sky-filter-section.sky-filter-foldable {
  margin-bottom: 10px !important;
}
body.shell-phone .crm-home.is-phone.sky-dash {
  gap: 8px !important;
  padding-bottom: 8px !important;
}
body.shell-phone .crm-home.is-phone .sky-dash-head {
  margin: 0 0 4px !important;
  gap: 2px !important;
}
body.shell-phone .crm-home.is-phone .home-greet-row {
  gap: 10px;
}
body.shell-phone .crm-home.is-phone .home-greet,
body.shell-phone .crm-home.is-phone .sky-dash-greet {
  font-size: 1.15rem !important;
  line-height: 1.2 !important;
  margin: 0 !important;
}
body.shell-phone .crm-home.is-phone .home-status-line {
  margin: 2px 0 0 !important;
}
body.shell-phone .sky-customer-hub.is-phone {
  padding-bottom: 8px !important;
}
body.shell-phone .sky-customer-hub .ios-hub-timeline-body,
body.shell-phone .sky-customer-hub .sky-hub-tab-body {
  padding-bottom: 8px !important;
}
body.shell-phone .ios-hub-timeline-body .hub-tl-type-chips {
  margin-bottom: 6px !important;
}
body.shell-phone .sky-tl-groups {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}
body.shell-phone .products.products-phone,
body.shell-phone .sky-shop .products {
  padding-bottom: 10px !important;
}
/* Sticky Start-visit FAB was reserving 74px even when icon-only ? main bottom gap. */
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit.is-icon-only) {
  padding-bottom: 40px !important;
}
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit):not(:has(.sky-sticky-visit.is-icon-only)) {
  padding-bottom: 52px !important;
}
/* Deal card gear ? superseded by crm561 (never on phone Home; quiet Edit only). */
body.shell-phone .settings-panel .sky-filter-section.sky-filter-foldable {
  margin: 0 0 6px !important;
}
body.shell-phone .settings-panel .sky-filter-fold {
  min-height: 30px !important;
  padding: 4px 2px 4px !important;
}
body.shell-phone .crm-home .home-section[data-home-section="kpi"] {
  margin-top: 2px !important;
}
body.shell-phone .crm-home .msg:empty {
  display: none !important;
  margin: 0 !important;
  padding: 0 !important;
}
/* ===== end crm556 phone densify ===== */

/* ===== crm561 Home rematch =====
   Phone Home toward ChatGPT mockup (visual only). No What's Moving modules.
   Nav stays 4 tabs. HTML worker may add .is-stack / .is-stacked on Next Up. */
body.shell-phone .crm-home.is-phone.sky-dash {
  gap: 6px !important;
  padding-bottom: 8px !important;
}
body.shell-phone .crm-home.is-phone .sky-dash-head {
  margin: 0 0 2px !important;
  gap: 1px !important;
}
body.shell-phone .crm-home.is-phone .home-greet-row {
  gap: 8px;
}
body.shell-phone .crm-home.is-phone .home-greet,
body.shell-phone .crm-home.is-phone .sky-dash-greet {
  font-size: 1.08rem !important;
  line-height: 1.15 !important;
  letter-spacing: -0.045em;
  margin: 0 !important;
}
body.shell-phone .crm-home.is-phone .home-status-line {
  margin: 0 !important;
  font-size: 0.72rem;
  line-height: 1.25;
}
body.shell-phone .crm-home .home-section[data-home-section="kpi"],
body.shell-phone .crm-home .home-kpi-strip-premium {
  margin: 0 0 6px !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium {
  gap: 5px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi {
  min-height: 52px;
  padding: 7px 6px 6px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi strong {
  font-size: 1.05rem;
  margin-bottom: 1px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-lab {
  font-size: 0.58rem;
  letter-spacing: 0.02em;
}

/* Next Up hero ? card squircle inside shell pad (crm699). */
body.shell-phone .crm-home .home-next-up.is-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 6px;
  width: 100%;
  max-width: 100%;
  padding: 14px 14px 12px;
  min-height: 0;
  border-radius: var(--radius-sm);
  border-color: color-mix(in srgb, var(--accent) 36%, rgba(255, 255, 255, 0.08));
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.22),
    0 10px 22px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-name {
  font-size: 1.08rem;
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-meta {
  font-size: 0.74rem;
  line-height: 1.3;
}

/* Stacked CTA (HTML .is-stack / .is-stacked) ? full-width under meta. */
body.shell-phone .crm-home .home-next-up.is-hero.is-stack,
body.shell-phone .crm-home .home-next-up.is-hero.is-stacked,
body.shell-phone .crm-home .home-next-up.is-stack,
body.shell-phone .crm-home .home-next-up.is-stacked {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}
body.shell-phone .crm-home .home-next-up.is-hero.is-stack .home-next-up-main,
body.shell-phone .crm-home .home-next-up.is-hero.is-stacked .home-next-up-main,
body.shell-phone .crm-home .home-next-up.is-stack .home-next-up-main,
body.shell-phone .crm-home .home-next-up.is-stacked .home-next-up-main {
  width: 100%;
}
body.shell-phone .crm-home .home-next-up.is-hero.is-stack .home-next-up-cta,
body.shell-phone .crm-home .home-next-up.is-hero.is-stacked .home-next-up-cta,
body.shell-phone .crm-home .home-next-up.is-stack .home-next-up-cta,
body.shell-phone .crm-home .home-next-up.is-stacked .home-next-up-cta {
  flex: 0 0 auto;
  width: 100%;
  min-height: 44px;
  justify-content: center;
}

/* Legacy row hero ? keep side CTA, still full-bleed card. */
body.shell-phone .crm-home .home-next-up.is-hero:not(.is-stack):not(.is-stacked) {
  flex-direction: row;
  align-items: center;
}
body.shell-phone .crm-home .home-next-up.is-hero:not(.is-stack):not(.is-stacked) .home-next-up-cta {
  flex: 0 0 auto;
  min-height: 40px;
  padding: 0 14px;
  font-size: 0.86rem;
}

/* Tighten Next Up ? deals / Next stops. */
body.shell-phone .crm-home .home-next-up,
body.shell-phone .crm-home .home-next-up.is-hero {
  margin-bottom: 6px !important;
}
body.shell-phone .crm-home .home-radar {
  margin-bottom: 10px !important;
}
body.shell-phone .crm-home .home-radar-deals-slot {
  margin: 4px 0 8px !important;
}
body.shell-phone .crm-home .home-radar-list-wrap.is-after-hero .home-radar-sec-label,
body.shell-phone .crm-home .home-radar.is-compact .home-radar-sec-label {
  margin: 2px 0 4px !important;
  padding-top: 0 !important;
  border-top: 0 !important;
}

/* Call plan head demoted on phone compact (ref has no loud CALL PLAN bar). */
body.shell-phone .crm-home .home-radar.is-compact > .home-radar-head.is-phone-quiet {
  display: none !important;
}
body.shell-phone .crm-home .home-radar.is-compact > .home-radar-head:not(.is-phone-quiet) {
  margin: 0 0 6px;
  opacity: 0.72;
}
body.shell-phone .crm-home .home-radar.is-compact > .home-radar-head:not(.is-phone-quiet) h2 {
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  font-weight: var(--fw-med, 500);
}

/* Next Up secondary Call / More (only when phone/WA exist on cached customer). */
body.shell-phone .crm-home .home-next-up-sec {
  display: flex;
  gap: 8px;
  width: 100%;
}
body.shell-phone .crm-home .home-next-up-sec-btn {
  flex: 1 1 0;
  min-height: 40px;
  justify-content: center;
  border-radius: var(--btn-radius) !important;
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-main {
  gap: 3px;
}

/* Running deals ? quieter head; no permanent + / gear on phone. */
body.shell-phone .crm-home .home-deals-head {
  margin: 0 0 6px;
  align-items: baseline;
}
body.shell-phone .crm-home .home-deals-eyebrow {
  padding: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  font-size: 0.62rem;
  font-weight: var(--fw-med, 500);
  letter-spacing: 0.06em;
  color: color-mix(in srgb, var(--muted) 92%, transparent);
}
body.shell-phone .crm-home .home-deals-eyebrow svg {
  display: none;
}
body.shell-phone .crm-home .home-deals-head h2 {
  font-size: 0.92rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
}
body.shell-phone .crm-home .home-deals-sub {
  font-size: 0.68rem;
  opacity: 0.85;
}
/* Permanent + / gear never on phone Home (JS also omits). Quiet Edit: Roei only,
   and only in explicit Home `.is-editing` mode (crm578 — not always-on). */
body.shell-phone .crm-home .home-deals-card-settings,
body.shell-phone .crm-home .home-deals-add-btn {
  display: none !important;
}
body.shell-phone .crm-home .home-deals-head-actions:not(:has(button:not(.home-deals-add-btn))) {
  display: none !important;
}
body.shell-phone .crm-home .home-deals-edit-quiet {
  flex: 0 0 auto;
  min-height: 28px;
  padding: 0 8px;
  font-size: 0.72rem;
  font-weight: var(--fw-med, 500);
  border-radius: var(--btn-radius) !important;
}
body.shell-phone .crm-home.is-roei-edit.is-editing .home-deals-edit-quiet {
  opacity: 0.85;
}
body.shell-phone .crm-home:not(.is-roei-edit) .home-deals-edit-quiet {
  display: none !important;
}

/* Sticky clearance ? 40px (kill 74px / 52px voids). Nav is in-flow. */
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit),
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit.is-icon-only),
body.shell-phone .crm-home.is-phone.sky-dash:has(.sky-sticky-visit):not(:has(.sky-sticky-visit.is-icon-only)) {
  padding-bottom: 40px !important;
}
body.shell-phone .crm-home.is-phone.sky-dash:not(:has(.sky-sticky-visit)) {
  padding-bottom: 8px !important;
}
/* ===== end crm561 Home rematch ===== */

/* ===== crm575 Home KPI — centered number + icon, denser tiles ===== */
.home-kpi-strip-premium .home-kpi {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 2px;
  min-height: 52px;
  padding: 8px 6px;
}
.home-kpi-strip-premium .home-kpi strong {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 1.18rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin-bottom: 0;
}
.home-kpi-strip-premium .home-kpi-lab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  width: 100%;
  font-size: 0.64rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  opacity: 0.9;
  text-align: center;
}
.home-kpi-strip-premium .home-kpi-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: inherit;
  opacity: 0.85;
}
.home-kpi-strip-premium .home-kpi-ico svg {
  width: 11px;
  height: 11px;
}

body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi {
  min-height: 56px;
  padding: 10px 8px;
  gap: 3px;
  align-items: center;
  justify-content: center;
  text-align: center;
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi strong {
  font-size: 1.28rem;
  letter-spacing: -0.045em;
  text-align: center;
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi span,
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi-lab {
  font-size: 0.66rem;
  letter-spacing: 0.02em;
  text-transform: none;
  justify-content: center;
  text-align: center;
}

@media (max-width: 900px) {
  .home-kpi-strip-premium .home-kpi {
    min-height: 48px;
    padding: 7px 5px;
  }
  .home-kpi-strip-premium .home-kpi strong {
    font-size: 1.08rem;
  }
  .home-kpi-strip-premium .home-kpi-lab {
    font-size: 0.58rem;
  }
}

body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi {
  min-height: 48px;
  padding: 7px 5px 6px;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 1px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi strong {
  font-size: 1.05rem;
  margin-bottom: 0;
  text-align: center;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-lab {
  font-size: 0.56rem;
  justify-content: center;
  text-align: center;
}
/* ===== end crm575 Home KPI center ===== */

/* Products category choices only. Keep .cat-list-full generic: Sort and price-list
   sheets also use it and retain their own picker language. */
.category-option-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 6px;
  width: 100%;
  min-width: 0;
  max-height: none;
}
.category-option-list .category-option-row {
  appearance: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24px;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  min-height: var(--btn-h);
  box-sizing: border-box;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-chip-radius);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  box-shadow: var(--btn-ghost-shadow);
  font: inherit;
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-med);
  line-height: 1.25;
  text-align: left;
  white-space: normal;
}
.category-option-label {
  display: -webkit-box;
  min-width: 0;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.category-option-check {
  display: grid;
  width: 24px;
  min-width: 24px;
  height: 24px;
  place-items: center;
  justify-self: end;
  color: currentColor;
}
.category-option-list .category-option-row:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: var(--bg-elevated-2);
}
.category-option-list .category-option-row.active,
.category-option-list .category-option-row.active:hover {
  color: #fff;
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  box-shadow: var(--btn-chip-on-shadow);
}
.category-option-list .category-option-row:focus-visible {
  outline: none;
  box-shadow: var(--btn-focus-ring), var(--btn-ghost-shadow);
}
.category-option-list .category-option-row.active:focus-visible {
  box-shadow: var(--btn-focus-ring), var(--btn-chip-on-shadow);
}
/* Phone category sheet only: this wrapper is the sole scroll owner. Clearance
   belongs here (not on the inner grid) so the last row can pass the phone nav. */
body.shell-phone #catSheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + var(--btn-pad-y));
  min-height: 0;
  border-bottom: 1px solid var(--line);
  border-radius: var(--sheet-top-radius) var(--sheet-top-radius) var(--btn-chip-radius)
    var(--btn-chip-radius);
}
body.shell-phone #catSheet .category-sheet-scroll {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding-bottom: var(--btn-pad-y);
  scroll-padding-bottom: var(--btn-pad-y);
}
body.shell-phone #catSheet .category-sheet-scroll > .category-option-list {
  flex: 0 0 auto;
  min-height: auto;
  overflow: visible;
  padding-bottom: 0;
}
body.shell-phone #catSheet .category-option-list .category-option-row {
  grid-template-columns: minmax(0, 1fr) 24px;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  white-space: normal;
}
body.shell-phone #catSheet .category-option-list .category-option-label {
  width: 100%;
  max-width: min(100%, 22ch);
  justify-self: start;
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: break-word;
}
@media (min-width: 901px) {
  body:not(.shell-phone) [data-panel="cat-panel"] .category-option-list {
    display: grid;
    flex: 1;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding-right: 2px;
  }
  body:not(.shell-phone) [data-panel="cat-panel"] .category-option-list .category-option-row {
    display: grid;
    min-height: var(--btn-h);
    padding: 8px 10px;
    border-color: var(--btn-ghost-border);
    background: var(--btn-ghost-bg);
    box-shadow: var(--btn-ghost-shadow);
    font-size: var(--btn-fs-sm);
  }
  body:not(.shell-phone) [data-panel="cat-panel"] .category-option-list .category-option-row:hover {
    color: var(--ink);
    border-color: var(--line-strong);
    background: var(--bg-elevated-2);
  }
  body:not(.shell-phone) [data-panel="cat-panel"] .category-option-list .category-option-row.active,
  body:not(.shell-phone) [data-panel="cat-panel"] .category-option-list .category-option-row.active:hover {
    color: #fff;
    border-color: var(--btn-chip-on-border);
    background: var(--btn-chip-on-bg);
    box-shadow: var(--btn-chip-on-shadow);
  }
}


/* ===== crm700: Home → visible rectangle kit (not soft 12px marketing cards) =====
   Roei: Home still looked “old” after crm699 radius retoken. Force sharper
   squircles (8px seg-item), flat elevated fills, no soft gradients/shadows.
   Match Users / Settings kit language. Status dots stay circular. */
body.shell-phone .crm-home,
body.shell-phone .crm-home.is-phone {
  --home-r: var(--btn-radius-seg-item, 8px);
}
body.shell-phone .crm-home .home-kpi-strip-premium {
  gap: 6px;
  margin: 0 0 10px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi {
  min-height: 56px;
  padding: 10px 10px 8px;
  border-radius: var(--home-r) !important;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: var(--bg-elevated) !important;
  box-shadow: none !important;
  text-align: left;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late {
  border-color: color-mix(in srgb, var(--danger, #ff453a) 45%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, var(--danger, #ff453a) 10%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon {
  border-color: color-mix(in srgb, var(--accent) 40%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, var(--accent) 10%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming {
  border-color: color-mix(in srgb, #30d158 40%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, #30d158 10%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi strong {
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}
body.shell-phone .crm-home .home-next-up,
body.shell-phone .crm-home .home-next-up.is-hero,
body.shell-phone .crm-home .home-day-start {
  border-radius: var(--home-r) !important;
  box-shadow: none !important;
  background: var(--bg-elevated) !important;
  border: 1px solid rgba(255, 255, 255, 0.10) !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}
body.shell-phone .crm-home .home-next-up.is-hero {
  padding: 12px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 10px !important;
}
body.shell-phone .crm-home .btn,
body.shell-phone .crm-home .home-next-up-cta,
body.shell-phone .crm-home .home-radar-start-btn,
body.shell-phone .crm-home .home-radar-cal-btn,
body.shell-phone .crm-home .home-next-up-sec-btn {
  border-radius: var(--home-r) !important;
}
body.shell-phone .crm-home .home-next-up-cta,
body.shell-phone .crm-home .home-radar-start-btn {
  width: 100%;
  min-height: var(--btn-h, 44px);
  justify-content: center;
}
body.shell-phone .crm-home .home-next-up-sec {
  display: grid !important;
  grid-template-columns: 1fr 1fr;
  gap: 8px !important;
  width: 100%;
  background: transparent !important;
  border: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
}
body.shell-phone .crm-home .home-next-up-sec-btn {
  flex: none !important;
  width: 100%;
  min-height: 40px;
  margin: 0;
  border: 1px solid var(--btn-ghost-border) !important;
  background: var(--btn-ghost-bg) !important;
  box-shadow: var(--btn-ghost-shadow) !important;
}
body.shell-phone .crm-home .home-deals,
body.shell-phone .crm-home .home-deals-card,
body.shell-phone .crm-home .home-radar,
body.shell-phone .crm-home .home-radar-list,
body.shell-phone .crm-home .home-widget,
body.shell-phone .crm-home .home-quick {
  border-radius: var(--home-r) !important;
  box-shadow: none !important;
}
body.shell-phone .crm-home .home-deals-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
}
body.shell-phone .crm-home .home-radar-meta {
  border-radius: var(--home-r) !important;
  min-height: 22px;
  padding: 2px 8px;
  font-size: 0.66rem;
  font-weight: var(--fw-semi, 600);
}
body.shell-phone .crm-home .home-radar-list {
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  padding: 0;
}
body.shell-phone .crm-home .home-radar-list > li {
  margin: 0;
  list-style: none;
}
body.shell-phone .crm-home .home-radar-list > li + li .home-radar-row {
  border-top: 0.5px solid rgba(255, 255, 255, 0.10);
}
body.shell-phone .crm-home .home-radar-row {
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-left-width: 3px;
  border-left-style: solid;
}
body.shell-phone .crm-home .home-radar-cal-btn {
  width: 100%;
  justify-content: center;
}
/* Desk Home: same sharper kit */
body:not(.shell-phone) .crm-home {
  --home-r: var(--btn-radius-seg-item, 8px);
}
body:not(.shell-phone) .crm-home .home-kpi-strip-premium .home-kpi,
body:not(.shell-phone) .crm-home .home-next-up,
body:not(.shell-phone) .crm-home .home-deals,
body:not(.shell-phone) .crm-home .home-deals-card,
body:not(.shell-phone) .crm-home .home-widget,
body:not(.shell-phone) .crm-home .btn {
  border-radius: var(--home-r) !important;
}
body:not(.shell-phone) .crm-home .home-kpi-strip-premium .home-kpi {
  background: var(--bg-elevated) !important;
  box-shadow: none !important;
}


/* ===== crm701: Products phone = search + Filters icon (Customers/Users kit) ===== */
body.shell-phone .shop-chrome-phone .sky-cust-tools.shop-phone-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  margin: 0 0 6px;
  min-width: 0;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search,
body.shell-phone .shop-chrome-phone .sky-cust-tools .sky-page-search {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .sky-page-search input,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-search-field {
  width: 100%;
  min-height: var(--btn-h);
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .hdr-icon-btn {
  flex: 0 0 auto;
}
body.shell-phone .shop-chrome-phone .shop-phone-actions {
  display: none !important;
}

/* ===== crm762/crm856: Products phone — ONE --btn-h row (search | Gen/COD/Ex CPT | filter) ===== */
body.shell-phone .shop-chrome-phone .sky-cust-tools.shop-phone-tools {
  gap: 6px;
  align-items: center;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search {
  flex: 0 1 34%;
  max-width: 38%;
  min-width: 5.5rem;
  align-self: center;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
  display: flex;
  align-items: center;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search .shop-search-field,
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search input.field.shop-search-field,
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search input {
  width: 100%;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0 12px 0 38px;
  margin: 0;
  box-sizing: border-box;
  line-height: 1.15;
  /* Kill base .field 14px / .shop-search-field 40px floors; squircle never stadium. */
  border-radius: var(--btn-radius, var(--radius-sm));
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  align-self: center;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .shop-pl-seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  align-items: stretch;
  margin-top: 0;
  padding: 3px;
  gap: 2px;
  width: 100%;
  max-width: 100%;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .pl-seg-btn {
  appearance: none;
  flex: unset;
  width: 100%;
  min-width: 0;
  padding: 0 6px;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  min-height: 0;
  height: 100%;
  max-height: none;
  line-height: 1.05;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  border: 1px solid transparent;
  border-radius: var(--btn-radius-seg-item);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .pl-seg-btn.active {
  border-color: var(--btn-chip-on-border);
  /* Paint only — keep same box as off. */
  height: 100%;
  min-height: 0;
  padding: 0 6px;
}
body.shell-phone .shop-chrome-phone .sky-cust-tools .hdr-icon-btn {
  flex: 0 0 auto;
  margin-left: 0;
  align-self: center;
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  max-width: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0;
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}

.shop-filters-sheet .shop-filters-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}
.shop-filters-sheet .shop-filters-cats {
  max-height: min(42vh, 320px);
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.shop-filters-sheet .shop-filters-img {
  padding: 4px 2px 8px;
}
.shop-filters-sheet.crm-menu-sheet .cat-sheet-panel {
  left: 50%;
  right: auto;
  width: min(100%, 400px);
  max-width: 400px;
  transform: translate(-50%, 108%);
}
.shop-filters-sheet.crm-menu-sheet.cat-sheet.is-open .cat-sheet-panel {
  transform: translate(-50%, 0);
}
body.shell-phone .shop-filters-sheet .cat-sheet-panel {
  position: absolute;
  top: auto;
  bottom: 0;
  left: 50%;
  width: min(100%, 400px);
  max-height: min(85vh, 640px);
  height: auto;
  padding: 12px 14px var(--sheet-nav-clear, calc(16px + var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px)));
  transform: translate(-50%, 108%);
}
body.shell-phone .shop-filters-sheet.cat-sheet.is-open .cat-sheet-panel {
  transform: translate(-50%, 0);
}

/* ===== crm702: Wave A kit — Cart inset list · Home skel · Forms Kind ===== */
/* Cart phone: inset hairlines inside .settings-list.cart-lines-list (not full-bleed cards). */
.cart-lines-list > .cart-line {
  position: relative;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 14px;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.cart-lines-list > .cart-line:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 0;
  bottom: 0;
  height: 0.5px;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
  z-index: 2;
}
.cart-lines-list > .cart-line.is-deal-free {
  background: color-mix(in srgb, var(--btn-chip-on-bg, #e8f2ff) 10%, transparent);
}
/* crm791: phone cart swipe-to-delete — same kit as Customers (.crm-swipe-*) */
body.shell-phone .cart-lines-list > .cart-line.is-swipeable {
  display: block;
  overflow: hidden;
  padding: 0;
}
body.shell-phone .cart-lines-list > .cart-line.is-swipeable .cart-line-front {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 14px;
  background: var(--bg-elevated, #1c1c1e);
  /* crm801: pan-y until JS arms clear horizontal swipe; sheet ease on settle. */
  touch-action: pan-y;
  transition: transform 240ms var(--ease-sheet, cubic-bezier(0.32, 0.72, 0, 1));
  will-change: transform;
}
body.shell-phone .cart-lines-list > .cart-line.is-swipeable.is-open .cart-line-front {
  box-shadow: -2px 0 0 var(--bg-elevated, #1c1c1e);
}
body.shell-phone .cart-lines-list > .cart-line.is-swipeable .crm-swipe-actions {
  align-items: stretch;
}
@media (prefers-reduced-motion: reduce) {
  body.shell-phone .cart-lines-list > .cart-line.is-swipeable .cart-line-front {
    transition: none;
  }
}
.sky-cart .cart-lines-list {
  margin-bottom: 12px;
}
/* crm768 — Cart empty = calm kit empty (inset list, no orphan chrome) */
.sky-cart .cart-empty-list {
  margin-bottom: 8px;
}
.sky-cart .cart-empty-list > .cart-empty,
.sky-cart .settings-list.cart-empty-list > .sub.settings-empty.cart-empty {
  margin: 0;
  padding: 28px 16px;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
  border: 0;
  background: transparent;
  box-shadow: none;
}
body.shell-phone .sky-cart .cart-card:has(.cart-checkout-sticky.is-empty) {
  padding-bottom: calc((2 * var(--btn-h, 44px)) + 72px);
}
body.shell-phone .sticky.cart-checkout-sticky.is-empty {
  margin-top: 8px;
  padding-top: 10px;
  padding-bottom: 10px;
}
/* Home KPI + radar loading skeletons */
.crm-skel-compact .crm-skel-row-compact {
  display: grid;
  grid-template-columns: 1.4fr 2fr;
  gap: 10px;
  min-height: 40px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--btn-radius-seg-item, 8px);
  background: var(--bg-elevated);
  overflow: hidden;
}
.crm-skel-compact .crm-skel-row-compact i {
  display: block;
  min-height: 10px;
  border-radius: var(--btn-radius-seg-item, 8px);
  background: linear-gradient(90deg, var(--bg-elevated-2) 20%, color-mix(in srgb, var(--bg-elevated-2) 65%, #fff 35%) 50%, var(--bg-elevated-2) 80%);
  background-size: 220% 100%;
  animation: crmSkelShimmer 1.25s linear infinite;
}
.home-kpi-strip-premium.is-skel .home-kpi.crm-skel-kpi {
  pointer-events: none;
  cursor: default;
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: flex-end;
}
.home-kpi-strip-premium.is-skel .crm-skel-kpi-n,
.home-kpi-strip-premium.is-skel .crm-skel-kpi-l {
  display: block;
  border-radius: var(--btn-radius-seg-item, 8px);
  background: linear-gradient(90deg, var(--bg-elevated-2) 20%, color-mix(in srgb, var(--bg-elevated-2) 65%, #fff 35%) 50%, var(--bg-elevated-2) 80%);
  background-size: 220% 100%;
  animation: crmSkelShimmer 1.25s linear infinite;
}
.home-kpi-strip-premium.is-skel .crm-skel-kpi-n {
  width: 42%;
  height: 22px;
}
.home-kpi-strip-premium.is-skel .crm-skel-kpi-l {
  width: 68%;
  height: 10px;
}
.home-radar .crm-skel-compact {
  padding: 0;
}
@media (prefers-reduced-motion: reduce) {
  .crm-skel-compact .crm-skel-row-compact i,
  .home-kpi-strip-premium.is-skel .crm-skel-kpi-i,
  .home-kpi-strip-premium.is-skel .crm-skel-kpi-n,
  .home-kpi-strip-premium.is-skel .crm-skel-kpi-l {
    animation: none;
  }
}

/* ===== crm703: Wave B kit — Near me skel · Permissions role sheet · Clock-in vehicle · Hub Add sheets ===== */
.clock-vehicle-pick .af-pick-select {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.clock-vehicle-picks .ios-filter-row {
  width: 100%;
}
.hub-add-sheet .admin-opt-row .hub-act-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.settings-role-pick {
  margin: 8px 0 12px;
}
.settings-role-pick-sheet .admin-opt-group {
  margin-bottom: 0;
}
/* Permissions role pick — clear bottom nav like peer phone menus */
body.shell-phone .settings-role-pick-sheet.crm-menu-sheet > .cat-sheet-panel {
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  max-height: min(
    85vh,
    calc(100dvh - var(--bottom-nav-h, 56px) - var(--safe-bottom, 0px) - 24px)
  );
}
body.shell-phone .settings-role-pick-sheet .crm-menu-body {
  padding-bottom: 24px;
  overscroll-behavior: contain;
}
.cust-hub-add-sheet .admin-opt-well .hub-act-ico {
  display: inline-flex;
}
.acal-schedule-sheet {
  max-height: min(82dvh, 640px);
}
.acal-schedule-body {
  min-height: 0;
  overflow-y: auto;
  padding-bottom: var(--sheet-nav-clear, 8px);
}
.acal-schedule-group {
  overflow: visible;
}
.acal-schedule-group .acal-schedule-form {
  display: contents;
}
.acal-schedule-group .acal-schedule-field {
  align-items: stretch;
  flex-direction: column;
  gap: 7px;
}
.acal-schedule-group .acal-schedule-field input[type="date"] {
  width: 100%;
  box-sizing: border-box;
}
.acal-schedule-action .btn {
  width: 100%;
}
.hub-call-sheet .admin-opt-group {
  flex-shrink: 0;
}

/* ===== crm705: Home phone — Roei mockup (revert crm704 Users-kit KPI) =====
   KPI = 3 horizontal tinted squircle cards · Next Up hero · deals · Next stops. */
.home-kpi-strip-premium {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}
.home-kpi-strip-premium .home-kpi {
  position: relative;
  display: grid;
  grid-template-rows: 14px auto minmax(1.3em, auto);
  justify-items: center;
  align-content: center;
  text-align: center;
  gap: 2px;
}
.home-kpi-strip-premium .home-kpi-top {
  display: contents;
}
.home-kpi-strip-premium .home-kpi-chev {
  display: inline-flex;
  position: absolute;
  top: 50%;
  right: 8px;
  margin: 0;
  transform: translateY(-50%);
  color: var(--muted);
  opacity: 0.4;
}
.home-kpi-strip-premium .home-kpi-ico,
.home-kpi-strip-premium .home-kpi strong,
.home-kpi-strip-premium .home-kpi-lab {
  justify-self: center;
  text-align: center;
}
.home-kpi-strip-premium .home-kpi-lab {
  width: calc(100% - 20px);
  max-width: none;
  line-height: 1.15;
  overflow-wrap: normal;
  word-break: normal;
}
body.shell-phone .crm-home .home-kpi-strip-premium {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 12px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi {
  position: relative;
  display: grid;
  grid-template-rows: 14px auto minmax(1.3em, auto);
  justify-items: center;
  align-content: center;
  text-align: center;
  gap: 2px;
  min-height: 72px;
  padding: 8px;
  border-radius: var(--radius-sm, 12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--bg-elevated) !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28), 0 8px 18px rgba(0, 0, 0, 0.16) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-top {
  display: contents;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-ico {
  display: inline-flex;
  justify-self: center;
  opacity: 0.9;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-chev {
  display: inline-flex;
  position: absolute;
  top: 50%;
  right: 7px;
  margin: 0;
  transform: translateY(-50%);
  color: var(--muted);
  opacity: 0.45;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi strong {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 1.35rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin: 2px 0 0;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-lab {
  display: block;
  width: calc(100% - 20px);
  max-width: none;
  text-align: center;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.01em;
  opacity: 0.92;
  margin-top: 2px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late {
  border-color: color-mix(in srgb, var(--danger, #ff453a) 42%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, var(--danger, #ff453a) 14%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late .home-kpi-ico {
  color: #ff6961;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon {
  border-color: color-mix(in srgb, var(--accent) 38%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, var(--accent) 12%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon .home-kpi-ico {
  color: color-mix(in srgb, var(--accent) 78%, #fff 22%);
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming {
  border-color: color-mix(in srgb, #30d158 38%, rgba(255, 255, 255, 0.08));
  background: color-mix(in srgb, #30d158 12%, var(--bg-elevated)) !important;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming .home-kpi-ico {
  color: #30d158;
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium {
  grid-template-columns: repeat(3, minmax(180px, 240px));
  align-items: stretch;
}

/* ===== crm706: Home KPI icon/center polish (late cascade after crm705) =====
   Phone: full-opacity ~16px icons, true center, brighter status tints. */
.home-kpi-strip-premium .home-kpi-lab {
  width: 100%;
}
.home-kpi-strip-premium .home-kpi-ico {
  opacity: 1;
}
.home-kpi-strip-premium .home-kpi-ico svg {
  width: 14px;
  height: 14px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi {
  padding: 8px 8px;
  grid-template-rows: 16px auto minmax(1.3em, auto);
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-ico {
  opacity: 1;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-ico svg {
  width: 16px;
  height: 16px;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-lab {
  width: 100%;
  font-size: 0.72rem;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi strong {
  font-size: 1.4rem;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi-chev {
  opacity: 0.35;
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-late .home-kpi-ico {
  color: color-mix(in srgb, #ff6961 68%, #fff 32%);
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-soon .home-kpi-ico {
  color: color-mix(in srgb, var(--accent) 62%, #fff 38%);
}
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming strong,
body.shell-phone .crm-home .home-kpi-strip-premium .home-kpi.is-upcoming .home-kpi-ico {
  color: color-mix(in srgb, #30d158 68%, #fff 32%);
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi-ico {
  opacity: 1;
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi-ico svg {
  width: 14px;
  height: 14px;
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi.is-late .home-kpi-ico {
  color: color-mix(in srgb, #ff6961 72%, #fff 28%);
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi.is-soon .home-kpi-ico {
  color: color-mix(in srgb, var(--accent) 68%, #fff 32%);
}
body:not(.shell-phone) .crm-home.is-pc .home-kpi-strip-premium .home-kpi.is-upcoming .home-kpi-ico {
  color: color-mix(in srgb, #30d158 72%, #fff 28%);
}
/* ===== end crm706 Home KPI polish ===== */

/* Next Up premium hero */
body.shell-phone .crm-home .home-next-up.is-hero.is-stack {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  gap: 8px !important;
  margin: 0 0 12px !important;
  padding: 14px !important;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--radius-sm, 12px) !important;
  border: 1px solid color-mix(in srgb, var(--accent) 32%, rgba(255, 255, 255, 0.1)) !important;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 14%, transparent), transparent 58%),
    var(--bg-elevated) !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28), 0 12px 26px rgba(0, 0, 0, 0.22) !important;
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-kicker {
  position: relative;
  z-index: 3;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--accent) 72%, var(--muted));
}
body.shell-phone .crm-home .home-next-up-body {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  max-width: 74%;
  position: relative;
  z-index: 3;
}
body.shell-phone .crm-home .home-next-up-avatar {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, rgba(255, 255, 255, 0.12));
  background: color-mix(in srgb, var(--accent) 12%, var(--bg-elevated));
  color: color-mix(in srgb, var(--accent) 80%, #fff 20%);
}
body.shell-phone .crm-home .home-next-up-copy {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.72);
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-name {
  font-size: 1.05rem;
  font-weight: var(--fw-semi, 600);
  letter-spacing: -0.02em;
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.25;
}
body.shell-phone .crm-home .home-next-up-meta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.76rem;
  line-height: 1.25;
  color: var(--muted);
}
body.shell-phone .crm-home .home-next-up-meta.is-dist {
  color: color-mix(in srgb, var(--accent) 75%, #fff 25%);
}
body.shell-phone .crm-home .home-next-up-meta-ico {
  display: inline-flex;
  flex: 0 0 auto;
  opacity: 0.85;
}
/* DNA-1: static Next Up illustration (no MapLibre / readiness wait). */
body.shell-phone .crm-home .home-next-up-map-wrap {
  position: absolute;
  z-index: 1;
  top: 22px;
  right: -4px;
  width: 58%;
  height: 108px;
  min-width: 0;
  overflow: hidden;
  pointer-events: none;
}
body.shell-phone .crm-home .home-next-up-map-wrap::after {
  content: "";
  position: absolute;
  z-index: 3;
  inset: 0;
  background:
    linear-gradient(90deg, var(--bg-elevated) 0%, color-mix(in srgb, var(--bg-elevated) 78%, transparent) 18%, color-mix(in srgb, var(--bg-elevated) 18%, transparent) 36%, transparent 48%),
    linear-gradient(0deg, color-mix(in srgb, var(--bg-elevated) 72%, transparent) 0%, color-mix(in srgb, var(--bg-elevated) 16%, transparent) 18%, transparent 34%);
  pointer-events: none;
}
body.shell-phone .crm-home .home-next-up-map-art {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  border: 0;
  pointer-events: none;
  user-select: none;
}
/* Legacy MapLibre Next Up container — hidden if a stale DOM node remains. */
body.shell-phone .crm-home .home-next-up-map,
body.shell-phone .crm-home .home-next-up-map-fallback {
  display: none !important;
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-cta {
  width: 100%;
  min-height: var(--btn-h, 44px);
  justify-content: center;
  gap: 8px;
  border-radius: var(--btn-radius) !important;
  position: relative;
  z-index: 3;
}
body.shell-phone .crm-home .home-next-up-seg {
  display: flex;
  width: 100%;
  border-radius: var(--btn-radius) !important;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  box-shadow: var(--btn-ghost-shadow);
  overflow: hidden;
  position: relative;
  z-index: 3;
}
body.shell-phone .crm-home .home-next-up-seg-btn {
  flex: 1 1 0;
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  margin: 0;
  padding: 0 10px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.86rem;
  font-weight: var(--fw-med);
  cursor: pointer;
}
body.shell-phone .crm-home .home-next-up-seg-btn + .home-next-up-seg-btn {
  border-left: 1px solid var(--line, rgba(255, 255, 255, 0.1));
}
body.shell-phone .crm-home .home-next-up-seg-btn:active {
  background: rgba(255, 255, 255, 0.06);
}

/* Call plan compact shell */
body.shell-phone .crm-home .home-radar.is-compact {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}
body.shell-phone .crm-home .home-radar.is-compact .home-radar-head.is-phone-quiet {
  display: none;
}
body.shell-phone .crm-home .home-radar-sec-label,
body.shell-phone .crm-home .home-deals-sec-label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 6px 0 8px;
  padding: 0 2px;
  font-size: 0.68rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
body.shell-phone .crm-home .home-radar-sec-label .home-sec-ico {
  color: color-mix(in srgb, #bf5af2 70%, var(--muted));
}
body.shell-phone .crm-home .home-deals-sec-label .home-sec-ico {
  color: color-mix(in srgb, #ff9f0a 75%, var(--muted));
}
body.shell-phone .crm-home .home-radar-foot {
  margin: 10px 0 12px;
}
body.shell-phone .crm-home .home-radar-cal-btn {
  width: 100%;
  border-radius: var(--btn-radius) !important;
}
body.shell-phone .crm-home .home-radar-deals-slot {
  margin: 0 0 10px;
}
body.shell-phone .crm-home .home-radar-deals-slot .home-deals {
  margin: 0;
}

/* Next stops — thin left accent + red overdue text (not pills) */
body.shell-phone .crm-home .home-radar-list {
  border-radius: var(--radius-sm, 12px);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
body.shell-phone .crm-home .home-radar-row {
  border-left-width: 3px;
  padding: 11px 10px 11px 9px;
}
body.shell-phone .crm-home .home-radar-meta {
  background: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  min-height: 0 !important;
  font-size: 0.72rem;
  font-weight: var(--fw-med, 500);
}
body.shell-phone .crm-home .home-radar-meta.is-overdue {
  color: #ff453a !important;
}
body.shell-phone .crm-home .home-radar-meta.is-today {
  color: var(--accent) !important;
}
body.shell-phone .crm-home .home-radar-chev {
  flex: 0 0 auto;
  display: inline-flex;
  color: var(--muted);
  opacity: 0.45;
}

/* Running deals — quiet section chrome; keep gradient promo cards */
body.shell-phone .crm-home .home-deals.is-compact {
  margin: 0 0 10px;
  padding: 0 0 10px;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible;
}
body.shell-phone .crm-home .home-deals.is-compact::before {
  display: none !important;
  content: none !important;
}
body.shell-phone .crm-home .home-deals-head.is-mockup {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 8px;
  padding: 0 2px;
}
body.shell-phone .crm-home .home-deals-scroller {
  padding: 0;
}
body.shell-phone .crm-home .home-radar-deals-slot .home-deals.is-compact {
  padding-bottom: 0;
}

/* Home shared geometry: one rhythm and stable peer columns across content states. */
.crm-home {
  --home-gap-major: 12px;
  --home-gap-label: 8px;
  --home-gap-control: 8px;
  --home-stop-status-w: 5.25rem;
  --home-stop-chevron-w: 16px;
}
/* Phone Home stacked modules — equal shells (Next Up / Running Deals / Next Stops). KPI stays 3 peers. */
body.shell-phone .crm-home {
  --home-mod-min-h: 150px; /* crm857 density: was 208 */
  --home-mod-radius: var(--radius-sm);
  --home-mod-inset-x: 12px;
  --home-mod-inset-y: 12px;
}
body.shell-phone .crm-home .home-next-up.is-hero,
body.shell-phone .crm-home .home-deals.is-compact .home-deals-scroller,
body.shell-phone .crm-home .home-deals.is-compact .home-deals-grid,
body.shell-phone .crm-home .home-radar-list {
  width: 100%;
  max-width: 100%;
  min-height: var(--home-mod-min-h);
  box-sizing: border-box;
  border-radius: var(--home-mod-radius) !important;
}
body.shell-phone .crm-home .home-next-up.is-hero {
  padding: var(--home-mod-inset-y) var(--home-mod-inset-x) !important;
}
body.shell-phone .crm-home .home-radar.is-compact .home-radar-list {
  max-height: none;
  min-height: var(--home-mod-min-h);
}
body.shell-phone .crm-home .home-deals-scroller > .home-deals-snap,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap {
  height: auto;
  min-height: var(--home-mod-min-h);
  max-height: none;
  align-self: stretch;
}
body.shell-phone .crm-home .home-deals-scroller > .home-deals-snap .home-deals-card,
body.shell-phone .crm-home .home-deals-scroller > .home-deals-card-wrap .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap .home-deals-card {
  height: 100%;
  min-height: var(--home-mod-min-h);
  max-height: none;
}
/* crm726: shared media well + fixed shout/meta slots (1/2/3 image peers align). */
.crm-home .home-deals-card-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.crm-home .home-deals-card-imgs {
  flex: 0 0 auto;
  min-width: 0;
  width: auto;
  max-width: 100%;
  justify-content: center;
}
.crm-home .home-deals-card-copy {
  display: grid;
  grid-template-rows: minmax(2.35em, auto) 1.25em;
  align-content: center;
  gap: 3px;
  min-height: calc(3.6em + 3px);
}
.crm-home .home-deals-card-big {
  min-block-size: 2.35em;
}
.crm-home .home-deals-card-cap {
  block-size: 1.25em;
  line-height: 1.25;
}
.crm-home .home-deals-grid {
  align-items: stretch;
  grid-auto-rows: auto;
}
.crm-home .home-deals-grid > .home-deals-card,
.crm-home .home-deals-grid > .home-deals-card-wrap {
  height: 100%;
}
.crm-home .home-radar-row {
  display: grid;
  grid-template-columns:
    minmax(0, 1fr) var(--home-stop-status-w)
    var(--home-stop-chevron-w);
  align-items: center;
  column-gap: var(--home-gap-control);
  min-height: 54px;
  block-size: 54px;
}
.crm-home .home-radar-main,
.crm-home .home-radar-name,
.crm-home .home-radar-last {
  min-width: 0;
}
.crm-home .home-radar-name,
.crm-home .home-radar-last {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crm-home .home-radar-meta {
  width: var(--home-stop-status-w);
  max-width: var(--home-stop-status-w);
  justify-self: end;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crm-home .home-radar-chev {
  width: var(--home-stop-chevron-w);
  justify-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.home-kpi-strip-premium.is-skel .home-kpi.crm-skel-kpi {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: 14px auto minmax(1.3em, auto);
  justify-items: center;
  align-content: center;
  gap: 2px;
}
.home-kpi-strip-premium.is-skel .crm-skel-kpi-i,
.home-kpi-strip-premium.is-skel .crm-skel-kpi-n,
.home-kpi-strip-premium.is-skel .crm-skel-kpi-l {
  justify-self: center;
}
.home-kpi-strip-premium.is-skel .crm-skel-kpi-i {
  display: block;
  width: 12px;
  height: 12px;
  border-radius: var(--btn-radius-seg-item, 8px);
  background: linear-gradient(
    90deg,
    var(--bg-elevated-2) 20%,
    color-mix(in srgb, var(--bg-elevated-2) 65%, #fff 35%) 50%,
    var(--bg-elevated-2) 80%
  );
  background-size: 220% 100%;
  animation: crmSkelShimmer 1.25s linear infinite;
}
body.shell-phone .crm-home .home-next-up-body {
  min-height: 72px;
}
body.shell-phone .crm-home .home-next-up-copy {
  display: grid;
  grid-template-rows: 2.5em 1em 1em;
  align-content: start;
  gap: 3px;
  min-height: 72px;
}
body.shell-phone .crm-home .home-next-up.is-hero .home-next-up-name {
  block-size: 2.5em;
  min-height: 2.5em;
  max-height: 2.5em;
}
body.shell-phone .crm-home .home-deals.is-compact {
  margin-bottom: var(--home-gap-major);
  padding-bottom: var(--home-gap-major);
}
body.shell-phone .crm-home .home-deals-head.is-mockup {
  gap: var(--home-gap-control);
  margin-bottom: var(--home-gap-label);
}
body.shell-phone .crm-home .home-radar-sec-label,
body.shell-phone .crm-home .home-deals-sec-label {
  margin-top: var(--home-gap-label);
  margin-bottom: var(--home-gap-label);
}
body.shell-phone .crm-home .home-radar-deals-slot {
  margin: 0 0 var(--home-gap-major);
}
body.shell-phone .crm-home .home-deals-scroller > .home-deals-snap,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap {
  height: auto;
  min-height: var(--home-mod-min-h, 150px);
  max-height: none;
}
body.shell-phone .crm-home .home-deals-scroller > .home-deals-snap .home-deals-card,
body.shell-phone .crm-home .home-deals-scroller > .home-deals-card-wrap .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card,
body.shell-phone .crm-home .home-deals-grid > .home-deals-card-wrap .home-deals-card {
  height: 100%;
  min-height: var(--home-mod-min-h, 150px);
  max-height: none;
}
body.shell-phone .crm-home .home-radar-row {
  min-height: 56px;
  block-size: 56px;
  padding-top: 8px;
  padding-bottom: 8px;
}

/* Phone Home: hide thick overlay scrollbar track (Simulator noise) */
body.shell-phone .crm-home.is-phone,
body.shell-phone .app-main,
body.shell-phone #app {
  scrollbar-width: none;
}
body.shell-phone .crm-home.is-phone::-webkit-scrollbar,
body.shell-phone .app-main::-webkit-scrollbar,
body.shell-phone #app::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
}

/* --- crm744 Products density pass 2 (phone + shell-phone + PC shop) --- */
.products {
  --prod-tile-pad: 6px;
  --prod-tile-gap: 5px;
  --prod-grid-gap: 5px;
  gap: var(--prod-grid-gap);
}
.products .product {
  gap: var(--prod-tile-gap);
  padding: var(--prod-tile-pad);
  contain-intrinsic-size: 0 84px;
}
.products .product .meta h3 {
  min-height: 0;
  line-height: 1.2;
  font-size: 0.84rem;
}
.products .product .meta .price,
.products .price {
  margin-top: 3px;
  font-size: 0.92rem;
  line-height: 1.15;
}
.products .uom-row {
  margin: 3px 0 0;
  height: 32px;
  min-height: 32px;
}
.products .product .meta > .add-row.product-actions {
  padding-top: 4px;
}
.products .add-row,
.products .add-row.product-actions,
.products-phone .add-row,
.products-phone .add-row.product-actions {
  --product-qty-row-h: 44px;
  gap: 6px;
}
.products.img-md .product-media {
  width: 64px;
  height: 64px;
}
.products.img-lg .product-media {
  width: 84px;
  height: 84px;
}
.products.img-xl .product-media {
  max-height: 100px;
}
.products.img-xl .product {
  padding: 6px;
  gap: 4px;
  contain-intrinsic-size: 0 210px;
}
.products .product-media {
  background: #fafafa;
}
.products .product-media .thumb {
  width: 120%;
  height: 120%;
  max-width: none;
  object-fit: contain;
  object-position: center;
}
@media (min-width: 560px) {
  .products {
    grid-template-columns: 1fr 1fr;
    gap: var(--prod-grid-gap);
  }
  .products.img-md .product,
  .products.img-lg .product {
    padding: 5px;
    gap: 4px;
  }
  .products.img-md .product-media {
    max-height: 68px;
  }
  .products.img-lg .product-media {
    max-height: 80px;
  }
}
@media (min-width: 720px) {
  .products {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 980px) {
  .products {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (min-width: 1280px) {
  .products {
    grid-template-columns: repeat(5, 1fr);
  }
}
@media (min-width: 1560px) {
  .products {
    grid-template-columns: repeat(6, 1fr);
  }
}
@media (min-width: 1880px) {
  .products {
    grid-template-columns: repeat(7, 1fr);
  }
}
/* Shell-phone / tablet: tighter tiles + more columns at lower widths */
.shop-screen.shell-phone .products,
.shop-screen.shell-phone .products-phone,
body.shell-phone .shop-screen .products,
body.shell-phone .shop-screen .products-phone,
body.shell-phone .products.products-phone {
  gap: 4px !important;
}
.shop-screen.shell-phone .products-phone .product,
.shop-screen.shell-phone .products-phone .product-phone,
body.shell-phone .products.products-phone .product,
body.shell-phone .products.products-phone .product-phone {
  padding: 4px !important;
  gap: 3px !important;
  contain-intrinsic-size: 0 164px;
}
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media {
  max-height: 64px !important;
}
.shop-screen.shell-phone .products-phone.img-md .product-media,
body.shell-phone .products.products-phone.img-md .product-media {
  max-height: 52px !important;
}
.shop-screen.shell-phone .products-phone.img-lg .product-media,
body.shell-phone .products.products-phone.img-lg .product-media {
  max-height: 58px !important;
}
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media {
  max-height: 64px !important;
}
.shop-screen.shell-phone .products-phone .product-media .thumb,
.shop-screen.shell-phone .products-phone .product-media img,
body.shell-phone .products.products-phone .product-media .thumb,
body.shell-phone .products.products-phone .product-media img {
  width: 138%;
  height: 138%;
}
.shop-screen.shell-phone .products-phone .product .meta h3,
.shop-screen.shell-phone .products-phone.img-xl .product .meta h3,
body.shell-phone .products.products-phone .product .meta h3 {
  font-size: 0.72rem !important;
  line-height: 1.16 !important;
}
.shop-screen.shell-phone .products-phone .uom-row,
body.shell-phone .products.products-phone .uom-row {
  margin: 2px 0 0;
  height: 30px;
  min-height: 30px;
  max-height: 30px;
}
.shop-screen.shell-phone .products-phone .price,
body.shell-phone .products.products-phone .price {
  margin-top: 1px;
  font-size: 0.76rem !important;
}
@media (min-width: 620px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 5px !important;
  }
  .shop-screen.shell-phone .products-phone .product-media,
  body.shell-phone .products.products-phone .product-media {
    max-height: 60px !important;
  }
  .shop-screen.shell-phone .products-phone.img-md .product-media,
  body.shell-phone .products.products-phone.img-md .product-media {
    max-height: 50px !important;
  }
  .shop-screen.shell-phone .products-phone.img-lg .product-media,
  body.shell-phone .products.products-phone.img-lg .product-media {
    max-height: 56px !important;
  }
  .shop-screen.shell-phone .products-phone.img-xl .product-media,
  body.shell-phone .products.products-phone.img-xl .product-media {
    max-height: 60px !important;
  }
}
@media (min-width: 880px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(4, 1fr) !important;
  }
  .shop-screen.shell-phone .products-phone .product-media,
  body.shell-phone .products.products-phone .product-media {
    max-height: 56px !important;
  }
}
@media (min-width: 1200px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(5, 1fr) !important;
  }
}
@media (min-width: 1500px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(6, 1fr) !important;
  }
}

/* --- crm745 Products large-image lock (always xl) + tight equal grid --- */
.products,
.products.products-phone {
  --prod-tile-pad: 3px;
  --prod-tile-gap: 3px;
  --prod-grid-gap: 3px;
  --prod-media-ratio: 4 / 3;
  --prod-thumb-scale: 150%;
  gap: var(--prod-grid-gap) !important;
  align-items: stretch;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.products .product,
.products.products-phone .product,
.products.products-phone .product-phone {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  min-height: 0;
  padding: var(--prod-tile-pad) !important;
  gap: var(--prod-tile-gap) !important;
  border-radius: var(--radius-sm) !important;
  box-sizing: border-box;
  contain-intrinsic-size: 0 248px;
  content-visibility: visible;
}
.products.img-xl .product-media,
.products.products-phone.img-xl .product-media,
.products .product-media,
.products.products-phone .product-media {
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  min-height: 0 !important;
  aspect-ratio: var(--prod-media-ratio) !important;
  flex: 0 0 auto !important;
  margin: 0;
  padding: 0;
  border-radius: var(--btn-chip-radius) !important;
  background: #fff;
  overflow: hidden;
  align-self: stretch;
}
.products.img-xl .product-media .thumb,
.products.img-xl .product-media img,
.products .product-media .thumb,
.products .product-media img,
.products.products-phone.img-xl .product-media .thumb,
.products.products-phone.img-xl .product-media img,
.products.products-phone .product-media .thumb,
.products.products-phone .product-media img {
  width: var(--prod-thumb-scale) !important;
  height: var(--prod-thumb-scale) !important;
  max-width: none !important;
  object-fit: contain !important;
  object-position: center;
}
.products .product .meta {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
  width: 100%;
}
.products .product .meta h3,
.products.products-phone .product .meta h3 {
  -webkit-line-clamp: 2;
  line-clamp: 2;
  min-height: 2.36em;
  line-height: 1.18;
  font-size: 0.78rem;
  margin: 0;
}
.products .product .meta .price,
.products .price {
  margin-top: 2px;
  font-size: 0.84rem;
  line-height: 1.12;
}
.products .uom-row {
  margin: 2px 0 0;
  height: 30px;
  min-height: 30px;
  max-height: 30px;
}
.products .product .meta > .add-row.product-actions {
  margin-top: auto;
  padding-top: 3px;
}
.products .add-row,
.products .add-row.product-actions,
.products-phone .add-row,
.products-phone .add-row.product-actions {
  --product-qty-row-h: 44px;
  min-height: 44px;
  gap: 5px;
}
/* Always column + tall well — never shrink xl to side-thumb row on narrow PC */
body:not(.shell-phone) .products.img-xl .product {
  flex-direction: column !important;
  align-items: stretch !important;
}
body:not(.shell-phone) .products.img-xl .product-media {
  width: 100% !important;
  max-height: none !important;
  aspect-ratio: var(--prod-media-ratio) !important;
}
/* Phone-card-top: image stacks above meta (display:contents unwraps row fork) */
.shop-screen.shell-phone .phone-card-top,
body.shell-phone .shop-screen .phone-card-top {
  display: contents !important;
}
@media (min-width: 560px) {
  .products,
  .products.products-phone {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 900px) {
  .products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 1200px) {
  .products {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
/* Shell-phone / tablet — tall wells, tight equal tiles, fewer cols (image wins) */
.shop-screen.shell-phone .products,
.shop-screen.shell-phone .products-phone,
body.shell-phone .shop-screen .products,
body.shell-phone .shop-screen .products-phone,
body.shell-phone .products.products-phone {
  --prod-thumb-scale: 156%;
  gap: 3px !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}
.shop-screen.shell-phone .products-phone .product,
.shop-screen.shell-phone .products-phone .product-phone,
body.shell-phone .products.products-phone .product,
body.shell-phone .products.products-phone .product-phone {
  padding: 3px !important;
  gap: 3px !important;
  border-radius: var(--radius-sm) !important;
  contain-intrinsic-size: 0 220px;
  content-visibility: visible;
}
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media,
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media {
  max-height: none !important;
  aspect-ratio: 4 / 3 !important;
  border-radius: var(--btn-chip-radius) !important;
}
.shop-screen.shell-phone .products-phone.img-xl .product-media .thumb,
.shop-screen.shell-phone .products-phone.img-xl .product-media img,
body.shell-phone .products.products-phone.img-xl .product-media .thumb,
body.shell-phone .products.products-phone.img-xl .product-media img {
  width: var(--prod-thumb-scale) !important;
  height: var(--prod-thumb-scale) !important;
}
@media (min-width: 620px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}
@media (min-width: 900px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }
}

/* --- crm746 Products equal-fill OCD (img-xl lock, edge bleed, tall wells) --- */
.shop-screen.shell-phone,
.app-shell.shop-screen.shell-phone {
  --shell-pad-x: 0px;
}
body.shell-phone .app-shell.screen.wide.shop-screen,
body.shell-phone .screen.wide.shop-screen {
  padding-left: 0 !important;
  padding-right: 0 !important;
}
body.shell-phone .shop-chrome-phone {
  padding-inline: 4px;
}
body.shell-phone .shop-body-phone .shop-toolbar-phone {
  margin: 2px 4px 2px;
}
body.shell-phone .shop-body-phone .shop-main-solo {
  padding-bottom: 6px;
}
.products,
.products.products-phone {
  --prod-tile-pad: 2px;
  --prod-tile-gap: 2px;
  --prod-grid-gap: 2px;
  --prod-media-ratio: 1 / 1;
  --prod-thumb-scale: 178%;
  gap: var(--prod-grid-gap) !important;
  align-items: stretch;
  grid-auto-rows: 1fr;
  padding-inline: 2px;
  box-sizing: border-box;
}
.products .product,
.products.products-phone .product,
.products.products-phone .product-phone {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  min-height: 0;
  padding: var(--prod-tile-pad) !important;
  gap: var(--prod-tile-gap) !important;
  border-radius: var(--radius-sm) !important;
  box-sizing: border-box;
  overflow: hidden;
  contain-intrinsic-size: 0 240px;
  content-visibility: visible;
}
.products.img-xl .product-media,
.products.products-phone.img-xl .product-media,
.products .product-media,
.products.products-phone .product-media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  min-height: 0 !important;
  aspect-ratio: var(--prod-media-ratio) !important;
  flex: 0 0 auto !important;
  margin: 0;
  padding: 0;
  border-radius: var(--btn-chip-radius) !important;
  background: var(--bg-elevated-2, #1c1c1e);
  overflow: hidden;
  align-self: stretch;
}
.products.img-xl .product-media .thumb,
.products.img-xl .product-media img,
.products .product-media .thumb,
.products .product-media img,
.products.products-phone.img-xl .product-media .thumb,
.products.products-phone.img-xl .product-media img,
.products.products-phone .product-media .thumb,
.products.products-phone .product-media img {
  width: var(--prod-thumb-scale) !important;
  height: var(--prod-thumb-scale) !important;
  max-width: none !important;
  object-fit: contain !important;
  object-position: center;
  flex-shrink: 0;
}
.products .product .meta {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
  width: 100%;
}
.products .product .meta h3,
.products.products-phone .product .meta h3 {
  -webkit-line-clamp: 2;
  line-clamp: 2;
  min-height: 2.28em;
  line-height: 1.14;
  font-size: 0.76rem;
  margin: 0;
}
.products .product .meta .price,
.products .price {
  margin-top: 1px;
  font-size: 0.82rem;
  line-height: 1.1;
}
.products .uom-row {
  margin: 1px 0 0;
  height: 28px;
  min-height: 28px;
  max-height: 28px;
}
.products .product .meta > .add-row.product-actions {
  margin-top: auto;
  padding-top: 2px;
}
.products .add-row,
.products .add-row.product-actions,
.products-phone .add-row,
.products-phone .add-row.product-actions {
  --product-qty-row-h: 44px;
  min-height: 44px;
  gap: 4px;
}
body:not(.shell-phone) .products.img-xl .product {
  flex-direction: column !important;
  align-items: stretch !important;
}
body:not(.shell-phone) .products.img-xl .product-media {
  width: 100% !important;
  max-height: none !important;
  aspect-ratio: var(--prod-media-ratio) !important;
}
body:not(.shell-phone) .sky-shop.is-pc .products {
  --prod-grid-gap: 4px;
  --prod-tile-pad: 3px;
  --prod-thumb-scale: 172%;
  padding-inline: 0;
  padding-right: 2px;
}
body:not(.shell-phone) .sky-shop.is-pc .products .product {
  content-visibility: visible !important;
  contain-intrinsic-size: none !important;
}
.shop-screen.shell-phone .products,
.shop-screen.shell-phone .products-phone,
body.shell-phone .shop-screen .products,
body.shell-phone .shop-screen .products-phone,
body.shell-phone .products.products-phone {
  --prod-thumb-scale: 182%;
  --prod-grid-gap: 2px;
  gap: 2px !important;
  padding-inline: 2px !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}
.shop-screen.shell-phone .products-phone .product,
.shop-screen.shell-phone .products-phone .product-phone,
body.shell-phone .products.products-phone .product,
body.shell-phone .products.products-phone .product-phone {
  padding: 2px !important;
  gap: 2px !important;
  border-radius: var(--radius-sm) !important;
  contain-intrinsic-size: 0 210px;
}
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media,
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media,
.shop-screen.shell-phone .products-phone.img-md .product-media,
.shop-screen.shell-phone .products-phone.img-lg .product-media,
body.shell-phone .products.products-phone.img-md .product-media,
body.shell-phone .products.products-phone.img-lg .product-media {
  max-height: none !important;
  aspect-ratio: 1 / 1 !important;
  border-radius: var(--btn-chip-radius) !important;
}
.shop-screen.shell-phone .products-phone.img-xl .product-media .thumb,
.shop-screen.shell-phone .products-phone.img-xl .product-media img,
body.shell-phone .products.products-phone.img-xl .product-media .thumb,
body.shell-phone .products.products-phone.img-xl .product-media img {
  width: var(--prod-thumb-scale) !important;
  height: var(--prod-thumb-scale) !important;
}
@media (min-width: 620px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 2px !important;
  }
}
@media (min-width: 900px) {
  .shop-screen.shell-phone .products,
  .shop-screen.shell-phone .products-phone,
  body.shell-phone .shop-screen .products,
  body.shell-phone .shop-screen .products-phone,
  body.shell-phone .products.products-phone {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }
}
@media (min-width: 560px) {
  .products,
  .products.products-phone {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 900px) {
  .products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 1200px) {
  .products {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* --- crm747 Products thumb fix (full packaging, no over-zoom) --- */
.products,
.products.products-phone,
body:not(.shell-phone) .sky-shop.is-pc .products,
.shop-screen.shell-phone .products,
.shop-screen.shell-phone .products-phone,
body.shell-phone .shop-screen .products,
body.shell-phone .shop-screen .products-phone,
body.shell-phone .products.products-phone {
  --prod-media-ratio: 4 / 3;
  --prod-thumb-scale: 100%;
}
.products.img-xl .product-media,
.products.products-phone.img-xl .product-media,
.products .product-media,
.products.products-phone .product-media,
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media,
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media,
.shop-screen.shell-phone .products-phone.img-md .product-media,
.shop-screen.shell-phone .products-phone.img-lg .product-media,
body.shell-phone .products.products-phone.img-md .product-media,
body.shell-phone .products.products-phone.img-lg .product-media {
  aspect-ratio: var(--prod-media-ratio) !important;
  background: #fafafa !important;
}
.products.img-xl .product-media .thumb,
.products.img-xl .product-media img,
.products .product-media .thumb,
.products .product-media img,
.products.products-phone.img-xl .product-media .thumb,
.products.products-phone.img-xl .product-media img,
.products.products-phone .product-media .thumb,
.products.products-phone .product-media img,
.shop-screen.shell-phone .products-phone.img-xl .product-media .thumb,
.shop-screen.shell-phone .products-phone.img-xl .product-media img,
body.shell-phone .products.products-phone.img-xl .product-media .thumb,
body.shell-phone .products.products-phone.img-xl .product-media img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center !important;
}
body:not(.shell-phone) .sky-shop.is-pc .products .product-media,
body:not(.shell-phone) .sky-shop.is-pc .products.img-xl .product-media {
  max-height: none !important;
  padding: 4px;
  box-sizing: border-box;
  background: #fafafa !important;
}
body:not(.shell-phone) .sky-shop.is-pc .products .product-media img,
body:not(.shell-phone) .sky-shop.is-pc .products .product-media .thumb {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center !important;
}

/* --- crm749 Products white wells + dark card chrome (keep crm747 contain thumbs) --- */
.products .product,
.products.products-phone .product,
.products.products-phone .product-phone,
.shop-screen.shell-phone .products-phone .product,
.shop-screen.shell-phone .products-phone .product-phone,
body.shell-phone .products.products-phone .product,
body.shell-phone .products.products-phone .product-phone,
body:not(.shell-phone) .sky-shop.is-pc .products .product {
  background: var(--surface-solid, var(--bg-elevated, #1c1c1e)) !important;
  border-color: rgba(255, 255, 255, 0.07) !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
}
.products .product:hover,
.products.products-phone .product:hover,
.shop-screen.shell-phone .products-phone .product:hover,
body.shell-phone .products.products-phone .product:hover {
  border-color: rgba(255, 255, 255, 0.12) !important;
}
.products.img-xl .product-media,
.products.products-phone.img-xl .product-media,
.products .product-media,
.products.products-phone .product-media,
.shop-screen.shell-phone .products-phone .product-media,
body.shell-phone .products.products-phone .product-media,
.shop-screen.shell-phone .products-phone.img-xl .product-media,
body.shell-phone .products.products-phone.img-xl .product-media,
.shop-screen.shell-phone .products-phone.img-md .product-media,
.shop-screen.shell-phone .products-phone.img-lg .product-media,
body.shell-phone .products.products-phone.img-md .product-media,
body.shell-phone .products.products-phone.img-lg .product-media,
body:not(.shell-phone) .sky-shop.is-pc .products .product-media,
body:not(.shell-phone) .sky-shop.is-pc .products.img-xl .product-media {
  background: #fafafa !important;
  border-color: rgba(0, 0, 0, 0.06);
}
.products .product-media .thumb.empty,
.products.products-phone .product-media .thumb.empty {
  background: #fafafa !important;
}

/* --- crm750 Catalogues hub grid/list alignment (late cascade) --- */
.cat-hub-card {
  height: 100%;
}
.cat-hub-card-body {
  flex: 1 1 auto;
  min-height: 0;
}
.cat-hub-card-acts {
  margin-top: auto;
  padding-top: 4px;
}
.cat-hub-card-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-height: calc(0.92rem * 1.25 * 2);
}
.cat-hub-grid > .crm-skel {
  grid-column: 1 / -1;
}
.cat-hub-list-row {
  align-items: center;
  gap: 0;
}
.cat-hub-list-row > .catalogues-share-btn {
  flex: 0 0 44px;
  width: 44px;
  min-width: 44px;
  height: 44px;
  margin: 0 6px 0 0;
  align-self: center;
  color: var(--accent, #0a84ff);
}
.cat-hub-list-open {
  padding: 10px 8px 10px 12px;
}
.cat-hub-list-thumb {
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
}

/* center product qty/+ as one compact group */
.products .add-row,
.products .add-row.product-actions,
.products-phone .add-row,
.products-phone .add-row.product-actions,
.shop-screen.shell-phone .products-phone .add-row,
.shop-screen.shell-phone .products-phone .add-row.product-actions {
  justify-content: center;
}

/* ===== crm761: Products phone — even PL + qty/+ flush + pin add-row ===== */
body.shell-phone .shop-screen .products-phone .product-phone,
body.shell-phone .products.products-phone .product-phone,
.shop-screen.shell-phone .products-phone .product-phone {
  height: 100%;
  align-self: stretch;
}
body.shell-phone .shop-screen .products-phone .product-phone > .add-row,
body.shell-phone .products.products-phone .product-phone > .add-row,
.shop-screen.shell-phone .products-phone .product-phone > .add-row,
body.shell-phone .shop-screen .products-phone .product-phone > .add-row.product-actions,
body.shell-phone .products.products-phone .product-phone > .add-row.product-actions,
.shop-screen.shell-phone .products-phone .product-phone > .add-row.product-actions {
  margin-top: auto !important;
  flex: 0 0 auto;
}
body.shell-phone .shop-screen .products-phone .product-phone .meta,
body.shell-phone .products.products-phone .product-phone .meta,
.shop-screen.shell-phone .products-phone .product-phone .meta {
  flex: 1 1 auto;
  min-height: 0;
}
body.shell-phone .shop-screen .products-phone .add-row,
body.shell-phone .products.products-phone .add-row,
.shop-screen.shell-phone .products-phone .add-row,
body.shell-phone .shop-screen .products-phone .add-row.product-actions,
body.shell-phone .products.products-phone .add-row.product-actions,
.shop-screen.shell-phone .products-phone .add-row.product-actions {
  --product-qty-row-h: 44px;
  align-items: center !important;
  height: var(--product-qty-row-h) !important;
  min-height: var(--product-qty-row-h) !important;
  max-height: var(--product-qty-row-h) !important;
}
body.shell-phone .shop-screen .products-phone .add-row .qty-stepper,
body.shell-phone .products.products-phone .add-row .qty-stepper,
.shop-screen.shell-phone .products-phone .add-row .qty-stepper,
body.shell-phone .shop-screen .products-phone .add-row.product-actions .qty-stepper,
body.shell-phone .products.products-phone .add-row.product-actions .qty-stepper,
.shop-screen.shell-phone .products-phone .add-row.product-actions .qty-stepper {
  height: var(--product-qty-row-h) !important;
  min-height: var(--product-qty-row-h) !important;
  max-height: var(--product-qty-row-h) !important;
  align-self: center !important;
  box-sizing: border-box !important;
}
body.shell-phone .shop-screen .products-phone .add-row .crm-plus-ico.add-sku,
body.shell-phone .products.products-phone .add-row .crm-plus-ico.add-sku,
.shop-screen.shell-phone .products-phone .add-row .crm-plus-ico.add-sku,
body.shell-phone .shop-screen .products-phone .add-row .hdr-icon-btn.crm-plus-ico.add-sku,
body.shell-phone .products.products-phone .add-row .hdr-icon-btn.crm-plus-ico.add-sku,
.shop-screen.shell-phone .products-phone .add-row .hdr-icon-btn.crm-plus-ico.add-sku,
body.shell-phone .shop-screen .products-phone .add-row .btn.add-sku,
body.shell-phone .products.products-phone .add-row .btn.add-sku,
.shop-screen.shell-phone .products-phone .add-row .btn.add-sku {
  flex: 0 0 var(--product-qty-row-h) !important;
  width: var(--product-qty-row-h) !important;
  min-width: var(--product-qty-row-h) !important;
  max-width: var(--product-qty-row-h) !important;
  height: var(--product-qty-row-h) !important;
  min-height: var(--product-qty-row-h) !important;
  max-height: var(--product-qty-row-h) !important;
  align-self: center !important;
  aspect-ratio: auto !important;
  box-sizing: border-box !important;
  padding: 0 !important;
}

/* ===== crm794: Cart phone kit — sticky Add more + Pack + Quote dock ===== */
body.shell-phone .sky-cart.is-phone {
  /* crm817 target block adds ~72px; was 188px pre-target (Add more + Pack + dock only).
     crm820: 260px clearance; crm859: modest −30px (kit order Add more → Pack → Quote kept). */
  --cart-kit-dock-h: 230px;
  --cart-sticky-h: calc(var(--cart-kit-dock-h) + 8px);
}
body.shell-phone .sky-cart.is-phone .cart-card.cart-kit-phone {
  padding-bottom: calc(var(--cart-kit-dock-h) + var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 16px);
  background: transparent;
  border: 0;
  box-shadow: none;
  /* crm481 lesson: .card backdrop-filter traps position:fixed to the card box,
     so the dock floated mid-list with a black void above bottom nav. */
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
body.shell-phone .sky-cart.is-phone .cart-kit-layout { display: block; }

/* Draft banner shell unused (toast-only restore) — reopen resubmit banner excepted */
.cart-kit-draft.quote-draft-banner { display: none; }
.cart-reopen-banner.quote-draft-banner {
  display: block;
  margin: 0 0 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm, 12px);
  border: 1px solid rgba(10, 132, 255, 0.22);
}
.cart-reopen-banner.quote-draft-banner.is-compact {
  margin: 0 0 8px;
  padding: 8px 10px;
  font-size: 13px;
}
.cart-reopen-banner.quote-draft-banner p {
  margin: 0;
  color: var(--muted, #6e6e73);
}

/* Toolbar — Clear left · Sort right (crm801) */
.cart-kit-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 6px;
  padding: 0 2px;
}
.cart-kit-toolbar .cart-kit-clear,
.cart-kit-toolbar .cart-kit-sort {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: auto;
  min-height: var(--btn-h-sm, 34px);
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
}
.cart-kit-toolbar .cart-kit-sort {
  margin-left: auto;
}

/* Kit list rows — denser (~15–20% shorter) */
body.shell-phone .cart-lines-list.cart-kit-list > .cart-line.cart-kit-line {
  display: block;
  padding: 0;
}
body.shell-phone .cart-lines-list.cart-kit-list > .cart-line.cart-kit-line.is-swipeable .cart-line-front,
body.shell-phone .cart-lines-list.cart-kit-list > .cart-line.cart-kit-line:not(.is-swipeable) {
  display: block;
  padding: 6px 10px 7px;
  background: var(--bg-elevated, #1c1c1e);
}
body.shell-phone .cart-lines-list.cart-kit-list > .cart-line.cart-kit-line.is-swipeable .cart-line-front {
  gap: 0;
  align-items: stretch;
}
.cart-kit-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.cart-kit-card-head.is-product {
  display: grid;
  grid-template-columns: 22px 44px minmax(0, 1fr);
  align-items: start;
  gap: 6px;
  min-width: 0;
}
.cart-kit-card-head.is-gl {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  min-width: 0;
}
/* Subtle ≡ handle — no button chrome */
.cart-kit-card-head .cart-line-handle.cart-kit-handle,
body.shell-phone .cart-kit-card-head .cart-line-handle.cart-kit-handle {
  justify-self: start;
  align-self: center;
  margin: 0;
  width: 22px;
  min-width: 22px;
  height: 36px;
  min-height: 36px;
  padding: 0;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  color: color-mix(in srgb, var(--muted) 88%, var(--ink));
  opacity: 0.85;
  cursor: grab;
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}
.cart-kit-card-head .cart-line-handle.cart-kit-handle:active {
  cursor: grabbing;
  opacity: 1;
}
.cart-kit-card-head .cart-thumb {
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  background: #fff;
}
.cart-kit-prod-text { min-width: 0; padding-top: 0; }
.cart-kit-title {
  display: block;
  font-size: 0.88rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--ink);
}
.cart-kit-sub {
  margin-top: 2px;
  font-size: 0.7rem;
  line-height: 1.25;
  color: var(--muted);
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cart-kit-more {
  justify-self: end;
  align-self: start;
  width: 32px;
  min-width: 32px;
  height: 32px;
  padding: 0;
  margin: 0;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
}
.cart-kit-gl-well {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  background: color-mix(in srgb, #0a84ff 35%, #1c1c1e);
  border: 1px solid rgba(10, 132, 255, 0.28);
}
.cart-kit-gl-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.cart-kit-gl-title-row .cart-kit-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Metrics: Price | Disc | Qty | Total — crm804 denser + column-aligned labs */
.cart-kit-metrics {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 52px minmax(124px, 1.15fr) minmax(0, 0.95fr);
  gap: 4px 6px;
  align-items: start;
  min-width: 0;
  overflow: visible;
  margin-top: 2px;
}
.cart-kit-metric.is-qty {
  overflow: visible;
  min-width: 124px;
  justify-items: center;
  align-items: center;
}
.cart-kit-metric {
  display: grid;
  grid-template-rows: auto minmax(28px, auto);
  align-items: stretch;
  justify-items: stretch;
  gap: 2px;
  min-width: 0;
}
.cart-kit-metric.is-price { justify-items: start; }
.cart-kit-metric.is-disc { justify-items: center; }
.cart-kit-metric.is-total { justify-items: end; }
.cart-kit-metric-lab {
  font-size: 0.52rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 92%, var(--ink));
  line-height: 1.05;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 1em;
  width: 100%;
  text-align: inherit;
}
.cart-kit-metric.is-price .cart-kit-metric-lab { text-align: left; }
.cart-kit-metric.is-disc .cart-kit-metric-lab,
.cart-kit-metric.is-qty .cart-kit-metric-lab { text-align: center; }
.cart-kit-metric.is-total .cart-kit-metric-lab { text-align: right; }
.cart-kit-metric-val {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.1;
  width: 100%;
}
.cart-kit-metric.is-price .cart-kit-metric-val { justify-content: flex-start; }
.cart-kit-metric.is-disc .cart-kit-metric-val { justify-content: center; }
.cart-kit-metric.is-qty .cart-kit-metric-val,
.cart-kit-metric.is-qty .cart-phone-stepper { justify-self: center; }
.cart-kit-metric.is-total .cart-kit-metric-val {
  justify-content: flex-end;
  font-size: 0.84rem;
}
.cart-kit-pct,
.cart-kit-disc .cart-disc-suf {
  margin-left: 1px;
  font-size: 0.7rem;
  color: var(--muted);
}
.cart-kit-price-edit,
.cart-kit-disc {
  display: inline-flex;
  align-items: center;
  gap: 0;
  max-width: 100%;
  min-height: 28px;
  padding: 1px 5px;
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: color-mix(in srgb, var(--bg, #000) 55%, transparent);
  box-sizing: border-box;
}
.cart-kit-price-edit .cart-price-r,
.cart-kit-phone .cart-kit-price-edit .zar-sym {
  margin: 0;
  margin-right: 0;
  padding: 0;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  letter-spacing: 0;
}
.cart-kit-metrics .cart-price-inp,
.cart-kit-metrics .cart-disc-inp {
  width: 100%;
  max-width: 100%;
  min-height: 24px;
  padding: 1px 1px;
  font-size: 0.78rem;
  text-align: left;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  font-variant-numeric: tabular-nums;
}
.cart-kit-metric.is-price .cart-kit-price-edit {
  max-width: 108px;
  justify-self: start;
}
.cart-kit-metric.is-disc .cart-kit-disc {
  justify-self: center;
}
.cart-kit-metrics .cart-disc-inp { text-align: center; max-width: 32px; }
/* crm801: no scale/clip — both − and + must stay visible (44px phone hits). */
.cart-kit-metrics .cart-phone-stepper {
  width: fit-content;
  max-width: none;
  flex-shrink: 0;
  overflow: visible;
  transform: none;
  justify-self: center;
}
/* Cart kit money: R6,218.28 — no space after R */
.cart-kit-phone .cart-kit-zar,
.cart-kit-sticky .cart-kit-zar,
.cart-kit-metrics .cart-kit-zar {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.cart-kit-phone .zar-sym { margin-right: 0; }

/* Sticky stack: Add more → Pack → Quote bar (no dead black gaps) */
body.shell-phone .sky-cart .cart-kit-sticky {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px));
  z-index: 180;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 8px 12px 0;
  box-sizing: border-box;
  background: color-mix(in srgb, var(--bg-elevated, #1c1c1e) 96%, #000);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
body.shell-phone .sky-cart .cart-kit-sticky.is-empty {
  padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
}

.cart-kit-add-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  margin: 0 0 6px;
  padding: 8px 12px;
  box-sizing: border-box;
  border: 1.5px dashed rgba(10, 132, 255, 0.55);
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  background: transparent;
  color: #0a84ff;
  font: inherit;
  font-size: 0.88rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.01em;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  flex: 0 0 auto;
}
.cart-kit-add-more:active {
  background: rgba(10, 132, 255, 0.08);
  transform: scale(0.99);
}

/* Pack totals — part of sticky dock, not orphan card */
.cart-kit-sticky .cart-kit-pack {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 8px 2px;
  border-radius: var(--btn-radius, var(--radius-sm, 12px));
  background: color-mix(in srgb, var(--bg, #000) 45%, var(--bg-elevated, #1c1c1e));
  border: 1px solid rgba(255, 255, 255, 0.08);
  flex: 0 0 auto;
}
.cart-kit-target-block {
  flex: 0 0 auto;
  margin: 0 0 8px;
  padding: 8px 2px 0;
}
.cart-kit-target-block .admin-opt-sec.cart-field-lab {
  margin: 0 0 6px;
}
.cart-kit-target-block .cart-target-incl-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}
.cart-kit-target-block .cart-target-incl-row .cart-target-incl {
  flex: 1 1 auto;
  min-width: 0;
}
.cart-kit-target-block .cart-target-acts {
  display: flex;
  flex-shrink: 0;
  gap: 6px;
}
.cart-kit-pack-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 0;
  padding: 2px 4px;
  text-align: center;
  position: relative;
  font-variant-numeric: tabular-nums;
}
.cart-kit-pack-stat:not(:last-child)::after {
  content: "";
  position: absolute;
  right: 0;
  top: 6px;
  bottom: 6px;
  width: 1px;
  background: rgba(255, 255, 255, 0.12);
}
.cart-kit-pack-ico {
  display: inline-flex;
  color: #0a84ff;
}
.cart-kit-pack-stat.is-inner .cart-kit-pack-ico { color: #bf5af2; }
.cart-kit-pack-stat.is-units .cart-kit-pack-ico { color: #30d158; }
.cart-kit-pack-lab {
  font-size: 0.58rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.cart-kit-pack-stat strong {
  font-size: 0.98rem;
  font-weight: var(--fw-semi);
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

/* Quote bar sits directly under pack strip */
body.shell-phone .sky-cart .cart-kit-sticky .cart-kit-dock {
  position: static;
  left: auto;
  right: auto;
  bottom: auto;
  z-index: auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.15fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 56px;
  margin: 0;
  padding: 8px 0 calc(8px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
  background: transparent;
  border-top: 0;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
body.shell-phone .sky-cart .cart-kit-sticky .cart-kit-dock.is-empty {
  grid-template-columns: 1fr;
  padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
}
body.shell-phone .sky-cart .cart-kit-sticky .cart-kit-dock.is-empty .btn {
  width: 100%;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
}
.cart-kit-dock-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.cart-kit-dock-ico {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: #111;
}
.cart-kit-dock-lines {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.cart-kit-dock-lines strong {
  font-size: 0.8rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.015em;
  color: var(--ink);
  line-height: 1.15;
}
.cart-kit-dock-lines em {
  font-style: normal;
  font-size: 0.64rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cart-kit-dock-total {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  min-width: 0;
  margin: 0;
  padding: 2px 2px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.cart-kit-dock-total-lab {
  font-size: 0.58rem;
  font-weight: var(--fw-med);
  letter-spacing: 0.02em;
  color: var(--muted);
  line-height: 1.1;
}
.cart-kit-dock-total-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
}
.cart-kit-dock-total-row strong {
  font-size: 1rem;
  font-weight: var(--fw-semi);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  line-height: 1.1;
}
.cart-kit-dock-chev {
  display: inline-flex;
  color: var(--muted);
  opacity: 0.85;
}
.cart-kit-dock-cta,
body.shell-phone .sky-cart .cart-kit-sticky .cart-kit-dock .cart-kit-dock-cta.btn {
  flex: 0 0 auto;
  width: auto !important;
  min-height: var(--btn-h, 44px);
  padding-left: 12px;
  padding-right: 10px;
  white-space: nowrap;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.cart-review-sheet .cart-review-body {
  padding-bottom: calc(12px + var(--safe-bottom, 0px));
}
.cart-review-sheet .cart-checkout-sticky {
  margin-top: 12px;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.cart-review-sheet .cart-checkout-sticky .btn {
  width: 100%;
  margin-top: 8px;
  border-radius: var(--btn-radius, var(--radius-sm, 12px)) !important;
}
.cart-review-sheet .cart-money-totals.admin-opt-group { margin: 0 0 10px; }
.cart-line-menu-sheet .admin-opt-row.is-danger .admin-opt-lab { color: #ff453a; }
@media (prefers-reduced-motion: reduce) {
  body.shell-phone .sky-cart .cart-kit-sticky {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .cart-kit-add-more:active { transform: none; }
}


/* ===== crm805: Checkout kit + not-ready CTA + phone browse assign ===== */
.btn.primary.cart-kit-dock-cta.is-not-ready,
.btn.primary.is-not-ready,
.btn.primary[aria-disabled="true"].cart-kit-dock-cta {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, rgba(255, 255, 255, 0.55));
  background: var(--btn-disabled-bg, color-mix(in srgb, var(--btn-primary-bg, #0a84ff) 35%, #3a3a3c 65%));
  border-color: transparent;
  box-shadow: none;
  cursor: not-allowed;
  filter: grayscale(0.15);
}
.btn.primary.cart-kit-dock-cta.is-not-ready:hover,
.btn.primary.is-not-ready:hover {
  opacity: var(--btn-disabled-opacity, 0.45);
  background: var(--btn-disabled-bg, color-mix(in srgb, var(--btn-primary-bg, #0a84ff) 35%, #3a3a3c 65%));
}
body.shell-phone .sky-cart .cart-assign-sec {
  margin: 8px 2px 6px;
}
body.shell-phone .sky-cart .cart-assign-opts-phone {
  margin: 0 0 10px;
}
.cart-review-sheet .acal-seg.cart-site-seg .acal-seg-btn.is-on,
.cart-doc-seg .acal-seg-btn.is-on,
.cart-site-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  font-weight: var(--fw-semi, 600);
}
.acal-seg-btn.is-blocked,
.acal-seg-btn[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  cursor: not-allowed;
}


/* ===== crm806: Products browse assign + PC not-ready CTA clickable ===== */
.shop-assign-sec {
  margin: 8px 2px 6px;
}
.shop-assign-opts {
  margin: 0 0 10px;
}
body.shell-phone .shop-body-phone .shop-assign-opts {
  margin: 0 0 12px;
}
.btn.primary.is-not-ready[aria-disabled="true"] {
  opacity: var(--btn-disabled-opacity, 0.45);
  color: var(--btn-disabled-fg, rgba(255, 255, 255, 0.55));
  background: var(--btn-disabled-bg, color-mix(in srgb, var(--btn-primary-bg, #0a84ff) 35%, #3a3a3c 65%));
  border-color: transparent;
  box-shadow: none;
  cursor: not-allowed;
  pointer-events: auto; /* click still fires why-toast */
}

/* ===== crm814: Place-for checkout row — match GL/assign peers + review-sheet ink ===== */
.cart-place-for {
  margin: 12px 0 4px;
}
.checkout-box.cart-checkout-kit > .cart-place-for,
.checkout-box.cart-checkout-kit > .admin-opt-group.cart-place-for,
.cart-review-sheet .cart-place-for,
.cart-review-sheet .admin-opt-group.cart-place-for {
  margin: 8px 0 4px;
  background: var(--bg-elevated-2, #2c2c2e);
  overflow: hidden;
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-row,
.cart-review-sheet .cart-place-for .admin-opt-row {
  min-height: 48px;
  color: var(--ink, #f5f5f7);
  opacity: 1;
  visibility: visible;
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-lab-wrap,
.cart-review-sheet .cart-place-for .admin-opt-lab-wrap,
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-lab-wrap,
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-lab-wrap,
.cart-review-sheet .cart-gl-add .admin-opt-lab-wrap,
.cart-review-sheet .cart-assign-opts .admin-opt-lab-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  flex: 1 1 auto;
  gap: 1px;
  opacity: 1;
  visibility: visible;
  overflow: visible;
  color: var(--ink, #f5f5f7);
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-lab,
.cart-review-sheet .cart-place-for .admin-opt-lab,
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-lab,
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-lab,
.cart-review-sheet .cart-gl-add .admin-opt-lab,
.cart-review-sheet .cart-assign-opts .admin-opt-lab {
  flex: 0 1 auto;
  min-width: 0;
  color: var(--ink, #f5f5f7);
  opacity: 1;
  font-size: 0.94rem;
  font-weight: var(--fw-med, 500);
  letter-spacing: normal;
  text-transform: none;
  line-height: 1.25;
  -webkit-text-fill-color: var(--ink, #f5f5f7);
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-sub,
.cart-review-sheet .cart-place-for .admin-opt-sub,
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-sub,
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-sub,
.cart-review-sheet .cart-gl-add .admin-opt-sub,
.cart-review-sheet .cart-assign-opts .admin-opt-sub {
  color: var(--muted, #aeaeb2);
  opacity: 1;
  font-size: 0.72rem;
  font-weight: var(--fw-reg, 400);
  letter-spacing: normal;
  text-transform: none;
  line-height: 1.25;
  -webkit-text-fill-color: var(--muted, #aeaeb2);
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-well,
.cart-review-sheet .cart-place-for .admin-opt-well,
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-well,
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-well,
.cart-review-sheet .cart-gl-add .admin-opt-well,
.cart-review-sheet .cart-assign-opts .admin-opt-well {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  opacity: 1;
  visibility: visible;
  color: #fff;
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-well.is-blue,
.cart-review-sheet .cart-place-for .admin-opt-well.is-blue {
  background: #0a84ff;
  background: color-mix(in srgb, var(--accent, #0a84ff) 90%, #fff 10%);
  color: #fff;
}
.checkout-box.cart-checkout-kit .cart-place-for .admin-opt-chev,
.cart-review-sheet .cart-place-for .admin-opt-chev,
.checkout-box.cart-checkout-kit .cart-gl-add .admin-opt-chev,
.checkout-box.cart-checkout-kit .cart-assign-opts .admin-opt-chev,
.cart-review-sheet .cart-gl-add .admin-opt-chev,
.cart-review-sheet .cart-assign-opts .admin-opt-chev {
  display: inline-flex;
  flex-shrink: 0;
  opacity: 0.55;
  color: var(--muted, #aeaeb2);
  visibility: visible;
}
/* Phone review sheet: kit wrapper must not add desk checkout chrome */
.cart-review-sheet .checkout-box.cart-checkout-kit.cart-review-kit {
  border: 0;
  border-top: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  box-shadow: none;
  max-height: none;
  overflow: visible;
}

/* Call Report page (crm844) — document preview canvas + Filter rail / phone inline */
.reports-daily-field-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.reports-daily-field-body .admin-opt-sec {
  margin: 0;
}
.reports-daily-field-body .sky-filter-fold-lab-wrap {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex: 1;
  min-width: 0;
}
.reports-daily-period-seg {
  display: flex;
  width: 100%;
  box-sizing: border-box;
  padding: 3px;
  gap: 2px;
  min-height: var(--btn-h);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.reports-daily-period-seg .acal-seg-btn {
  flex: 1;
  min-width: 0;
  height: 100%;
  min-height: 0;
  padding: 0 4px;
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  line-height: 1.15;
  text-align: center;
  border-radius: var(--btn-radius-seg-item);
}
.reports-daily-period-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}
/* Apply CTA — Filter Report sheet / rail footer outside scroll (crm873). */
.reports-daily-filters-apply {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 0 calc(8px + env(safe-area-inset-bottom, 0px));
  background: var(--sheet-bg, var(--bg-elevated, var(--bg, #fff)));
  box-shadow: 0 -10px 18px -12px rgba(0, 0, 0, 0.28);
}
.reports-daily-filters-apply-foot {
  flex: none;
  position: static;
  margin-top: 0;
  z-index: auto;
}
.reports-daily-filters-apply .btn.primary {
  width: 100%;
}
.reports-daily-filters-apply-note {
  margin: 0;
}
.reports-filter-report-sheet .cat-sheet-panel {
  display: flex;
  flex-direction: column;
  max-height: min(85vh, 700px);
}
.reports-filter-report-sheet .crm-menu-body.reports-daily-field-body,
.reports-filter-report-sheet .reports-daily-field-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding-bottom: 4px;
}
.sky-hub-reports-pc .sky-filter-rail .crm-menu-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.reports-filter-report-rail {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
}
.reports-filter-report-rail-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
.reports-daily-people-row.is-on {
  background: var(--btn-chip-on-bg);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
}
.reports-daily-people-row .reports-daily-people-role {
  flex: none;
  margin-left: auto;
  text-align: right;
}
.reports-daily-custom-range {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.reports-daily-period-meta {
  margin: 0;
}
.reports-daily-field-user-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.reports-daily-field-actions {
  margin-top: 4px;
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 8px);
}
.reports-daily-field-status {
  margin: 10px 0 0;
  text-align: center;
  min-height: 1.2em;
  color: var(--muted);
}
.reports-daily-field-status.is-building {
  color: var(--ink-secondary);
}
.reports-daily-field-status.is-sent {
  color: var(--ok);
}
.reports-daily-field-status.is-failed {
  color: var(--danger);
}
.reports-daily-field-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 8px 0 0;
  font-size: 0.68rem;
  line-height: 1.35;
  color: var(--muted);
  text-align: center;
}
.reports-daily-field-footer-ico {
  display: inline-flex;
  opacity: 0.7;
}
.reports-daily-field-preview {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-height: 0;
}
.reports-daily-field-preview-card {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  min-height: 180px;
}
.reports-daily-field-preview-row {
  display: grid;
  grid-template-columns: minmax(88px, 34%) 1fr;
  gap: 8px 10px;
  align-items: start;
}
.reports-daily-field-preview-k {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.35;
  padding-top: 1px;
}
.reports-daily-field-preview-v {
  font-size: 0.82rem;
  line-height: 1.35;
  color: var(--ink);
  word-break: break-word;
}
.reports-daily-field-preview-empty,
.reports-daily-field-preview-note {
  margin: 0;
}
.reports-daily-field-actions .js-reports-daily-done,
.reports-daily-field-actions #btnReportsDailyFieldDone {
  margin-top: 8px;
  width: 100%;
}
.reports-call-page {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  width: 100%;
}
.reports-daily-canvas {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
  max-width: 920px;
  min-height: 320px;
  padding: 4px 2px 12px;
  box-sizing: border-box;
}
.reports-daily-canvas-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px 16px;
}
.reports-daily-canvas-toolbar-segs {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  flex: 1 1 280px;
  min-width: 0;
}
.reports-daily-toolbar-block {
  flex: 1 1 140px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.reports-daily-toolbar-block .admin-opt-sec {
  margin: 0;
}
.reports-daily-canvas-export {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.reports-daily-canvas-export .btn.primary {
  min-width: 140px;
}
.reports-daily-canvas-preview .reports-daily-field-preview-empty {
  text-align: center;
  padding: 48px 16px;
  font-size: 0.9rem;
}
.reports-daily-preview-table-wrap {
  margin: 0;
  max-width: 100%;
}
.reports-daily-preview-table {
  font-size: 0.82rem;
}
.reports-daily-field-preview-note {
  margin: 4px 0 0;
}
body:not(.shell-phone) .sky-hub-reports-pc .sky-filter-rail .reports-daily-field-body {
  padding: 0 2px 8px;
}
body:not(.shell-phone) .sky-hub-reports-pc .reports-daily-canvas {
  min-height: min(62vh, 560px);
}
/* Phone Call Report — full page + sticky Export above bottom nav */

.reports-daily-canvas-meta {
  margin: -4px 0 0;
  font-size: 0.68rem;
  color: var(--muted);
  line-height: 1.35;
}
.reports-daily-doc {
  flex: 1;
  min-height: 0;
}
.reports-daily-doc-paper {
  background: var(--bg-elevated, #fff);
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: var(--btn-radius);
  box-shadow: var(--shadow);
  padding: 20px 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 240px;
  overflow: auto;
}
.reports-daily-doc-paper.is-empty {
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 12px;
}
.reports-daily-doc-head {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.reports-daily-doc-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--ink);
}
.reports-daily-doc-period {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-secondary);
  line-height: 1.35;
}
.reports-daily-doc-gen {
  margin: 0;
  font-size: 0.72rem;
  color: var(--muted);
}
.reports-daily-doc-sec {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.reports-daily-doc-sec-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.reports-daily-doc-table {
  margin: 0;
  max-width: 100%;
}
.reports-daily-doc-table .hist-table {
  width: 100%;
}
.reports-daily-doc-table .hist-table th,
.reports-daily-doc-table .hist-table td {
  white-space: nowrap;
}
.reports-daily-doc-table .hist-table th:nth-child(3),
.reports-daily-doc-table .hist-table td:nth-child(3) {
  white-space: normal;
  min-width: 8rem;
}
.reports-daily-doc-empty-sec,
.reports-daily-doc-trunc {
  margin: 0;
}
body:not(.shell-phone) .sky-hub-reports-pc .reports-daily-doc-paper {
  min-height: min(52vh, 480px);
}

body.shell-phone .sky-hub-reports-phone .reports-call-page.is-phone {
  /* crm858: CTA strip clearance uses --bottom-nav-h (was hard 72 + nav). */
  padding-bottom: calc(var(--bottom-nav-h, 56px) + var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
}
body.shell-phone .sky-hub-reports-phone .reports-daily-canvas {
  max-width: none;
  min-height: 240px;
  padding-bottom: 0;
}
body.shell-phone .sky-hub-reports-phone .reports-call-inline-filters {
  padding: 0 2px 8px;
}
body.shell-phone .sky-hub-reports-phone .reports-call-phone-cta {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 8px);
  z-index: 40;
  margin: 0;
  padding: 10px 12px;
  border-radius: var(--btn-radius);
  background: color-mix(in srgb, var(--bg-elevated) 92%, transparent);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
body.shell-phone .sky-hub-reports-phone .reports-call-phone-cta .btn.primary {
  width: 100%;
}
body.shell-phone .sky-hub-reports-phone .reports-call-phone-cta .reports-daily-field-footer {
  display: none;
}

/* crm845 Reports Sky document + landing · crm852 dark catalog hub */
.reports-landing {
  width: 100%;
  max-width: 920px;
  margin: 0 auto;
  padding: 4px 2px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px; /* crm858 density: was 18 */
}
.reports-landing-list {
  margin: 0;
}
.reports-landing-opt .admin-opt-sub {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
/* Reports hub tools = same family as Catalogues `.cat-hub-search-row` + Products Gen toolbar (crm861). */
.reports-hub-search-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 2px 0 10px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}
.reports-hub-search {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  border-radius: var(--btn-radius);
  background: var(--surface-2, rgba(255, 255, 255, 0.06));
  border: 1px solid var(--hairline, rgba(255, 255, 255, 0.08));
  box-sizing: border-box;
}
.reports-hub-search-ico {
  flex: none;
  color: var(--muted);
  display: inline-flex;
  opacity: 0.55;
}
.reports-hub-search input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.95rem;
  padding: 0;
  height: 100%;
  line-height: 1.2;
}
.reports-hub-search input::placeholder {
  color: var(--muted);
  opacity: 0.85;
}
.reports-hub-cat-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
  border-radius: var(--btn-radius);
}
.reports-hub-cat-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-seg-on-shadow, var(--btn-chip-on-shadow));
}
body.shell-phone .reports-hub-search-row {
  margin: 0 0 8px;
  gap: 4px;
}
.reports-hub-sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 6px; /* crm858 density: was 10 */
}
.reports-hub-sec-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.reports-hub-view-all {
  border: 0;
  background: transparent;
  color: var(--accent, #0a84ff);
  font: inherit;
  font-size: 0.85rem;
  font-weight: var(--fw-med);
  padding: 0;
  cursor: pointer;
}
.reports-hub-recent-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 2px 2px 6px;
  scroll-snap-type: x proximity;
}
.reports-hub-recent-card {
  flex: 0 0 auto;
  width: min(168px, 46vw);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 12px;
  text-align: left;
  border-radius: var(--btn-radius);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: inherit;
  cursor: pointer;
}
.reports-hub-recent-card:hover {
  background: rgba(255, 255, 255, 0.08);
}
.reports-hub-recent-card:active {
  transform: scale(0.98);
}
.reports-hub-recent-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  width: 100%;
}
.reports-hub-recent-title {
  font-size: 0.9rem;
  font-weight: var(--fw-semi);
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.reports-hub-recent-meta {
  font-size: 0.75rem;
  color: var(--muted);
}
.reports-hub-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px; /* crm858 density: was 10 */
}
@media (min-width: 560px) {
  .reports-hub-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.reports-hub-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
  width: 100%;
  margin: 0;
  padding: 10px 12px; /* crm858 density: was 14px 12px */
  text-align: left;
  border-radius: var(--btn-radius);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: inherit;
  cursor: pointer;
  min-height: 72px; /* crm858 density: was 96 */
}
.reports-hub-card:hover:not(:disabled):not([aria-disabled="true"]) {
  background: rgba(255, 255, 255, 0.08);
}
.reports-hub-card:active:not(:disabled):not([aria-disabled="true"]) {
  transform: scale(0.99);
}
.reports-hub-card.is-soon,
.reports-hub-card:disabled,
.reports-hub-card[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: var(--btn-disabled-opacity, 0.72);
}
.reports-hub-card-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.reports-hub-card-title {
  font-size: 0.98rem;
  font-weight: var(--fw-semi);
  color: var(--text);
}
.reports-hub-card-blurb {
  font-size: 0.8rem;
  line-height: 1.35;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.reports-hub-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px; /* crm858 density */
}
.reports-hub-tag {
  /* Squircle chip — never capsule 999px (crm861 kit align). */
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  min-height: 24px;
  box-sizing: border-box;
  border-radius: var(--btn-chip-radius, var(--radius-sm, 12px));
  font-size: 0.68rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  line-height: 1.2;
}
.reports-hub-tag.is-activity {
  color: #7eb6ff;
  background: rgba(10, 132, 255, 0.16);
}
.reports-hub-tag.is-popular {
  color: #8fd99a;
  background: rgba(52, 199, 89, 0.16);
}
.reports-hub-tag.is-logistics {
  color: #8fd99a;
  background: rgba(52, 199, 89, 0.14);
}
.reports-hub-tag.is-sales {
  color: #f0b27a;
  background: rgba(255, 159, 10, 0.16);
}
.reports-hub-tag.is-customers {
  color: #8fd99a;
  background: rgba(52, 199, 89, 0.14);
}
.reports-hub-tag.is-admin {
  color: #7eb6ff;
  background: rgba(10, 132, 255, 0.14);
}
.reports-hub-tag.is-muted {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.06);
}
.reports-hub-card-chev {
  color: var(--muted);
  margin-top: 2px;
  display: inline-flex;
}
.reports-hub-ico.settings-row-ico {
  width: 40px;
  height: 40px;
  border-radius: var(--btn-radius);
  flex: none;
}
.reports-hub-ico.settings-row-ico.is-sm {
  width: 32px;
  height: 32px;
}
.reports-hub-foot {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}
.reports-hub-info {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 14px;
  border-radius: var(--btn-radius);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.reports-hub-info-ico {
  flex: none;
  color: #7eb6ff;
  margin-top: 1px;
}
.reports-hub-info-txt {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--muted);
}
.reports-hub-how-btn {
  width: 100%;
  justify-content: flex-start;
  gap: 8px;
}
.reports-hub-how-btn .reports-hub-how-ico {
  color: #7eb6ff;
}
/* crm863: denser category chips → chip-on tokens (no opt-row markup this pass) */
.reports-hub-cat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 2px 0 4px;
  margin: 0;
}
.reports-hub-how-body {
  padding: 4px 2px 12px;
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.45;
}
.reports-hub-how-body p {
  margin: 0 0 10px;
  color: var(--muted);
}
.reports-hub-how-body ul {
  margin: 0;
  padding-left: 1.15em;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.reports-hub-how-body li strong {
  color: var(--text);
}
.reports-sky-viewer {
  background: var(--reports-call-canvas, var(--bg));
  border: 1px solid var(--reports-call-line, var(--line-strong));
  border-radius: var(--btn-radius);
  padding: 12px 12px 16px;
  max-width: none;
  min-height: min(68vh, 640px);
}
.reports-sky-viewer-stage {
  display: flex;
  justify-content: center;
  padding: 8px 4px 4px;
  min-height: 280px;
}
.reports-sky-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
  flex-wrap: wrap;
  color: var(--reports-call-ink, var(--ink));
}
.reports-sky-tb-left,
.reports-sky-tb-pager,
.reports-sky-tb-save {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
.reports-sky-tb-pager {
  padding: 2px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid var(--line);
}
.reports-sky-page-lab {
  min-width: 6.5em;
  text-align: center;
  font-size: var(--btn-fs-sm);
  font-variant-numeric: tabular-nums;
  color: var(--reports-call-ink, var(--ink));
  padding: 0 6px;
}
.reports-sky-toolbar .btn.ghost {
  color: var(--reports-call-ink, var(--ink));
  background: var(--btn-ghost-bg);
  border-color: var(--btn-ghost-border);
}
/* Format = kit `.acal-seg` (not native <select>) — crm848 */
.reports-sky-tb-save .acal-seg {
  flex: 0 0 auto;
  background: var(--btn-seg-track);
}
.reports-sky-tb-save .acal-seg-btn {
  color: var(--reports-call-ink, var(--ink));
  min-height: var(--btn-h-sm);
  font-size: var(--btn-fs-sm);
  padding: 0 10px;
}
.reports-call-desk-done {
  display: flex;
  justify-content: flex-end;
  margin: 8px 0 4px;
}
.reports-sky-tb-btn {
  min-width: 34px;
}
.reports-sky-tb-save .btn span:last-child {
  margin-left: 4px;
}
.reports-call-back {
  display: flex;
  justify-content: flex-start;
}
.reports-call-back .btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.reports-sky-phone-saves {
  display: flex;
  gap: 8px;
}
.reports-sky-phone-saves .btn {
  flex: 1;
}
.reports-sky-track {
  background: var(--reports-call-elev, var(--bg-elevated));
  border: 1px solid var(--reports-call-line, var(--line));
  border-radius: var(--btn-radius);
  padding: 10px 12px;
}
.reports-landing-row {
  width: 100%;
  text-align: left;
}
body.shell-phone .sky-hub-reports-phone .reports-call-phone-cta .reports-sky-phone-saves .btn.primary {
  width: auto;
}
body.shell-phone .sky-hub-reports-phone .reports-sky-tb-save .btn span:not([aria-hidden]) {
  display: none;
}
.reports-sky-toolbar-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  flex: 1 1 220px;
  min-width: 0;
}
.reports-sky-toolbar-tools .btn.ghost.small {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.reports-sky-page-nav {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: 4px;
  padding: 2px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
}
.reports-sky-page-nav .btn.ghost.small {
  min-width: 32px;
  padding-left: 8px;
  padding-right: 8px;
}
.reports-sky-page-lab {
  min-width: 3.2em;
  text-align: center;
  font-size: var(--btn-fs-sm);
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  padding: 0 4px;
}
.reports-sky-doc {
  width: 100%;
  max-width: 820px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.reports-sky-paper {
  background: var(--reports-call-paper, var(--bg-elevated));
  color: var(--reports-call-ink, var(--ink));
  border: 1px solid var(--reports-call-line, var(--line-strong));
  border-radius: var(--btn-radius);
  box-shadow: var(--shadow);
  padding: 22px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 260px;
}
/* crm853 — Call Report team rollup shell (honest preview fields only) */
.reports-team-paper {
  min-height: 0;
}
.reports-team-users-meta {
  margin: 2px 0 0;
  font-size: 0.82rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-team-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  gap: 10px;
}
.reports-team-kpi {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 12px 12px 10px;
  border-radius: var(--btn-radius);
  background: var(--bg-elevated-2);
  border: 1px solid var(--reports-call-line, var(--line));
  min-width: 0;
}
.reports-team-kpi-ico {
  display: inline-flex;
  color: var(--accent, #0a84ff);
}
.reports-team-kpi[data-tint="blue"] .reports-team-kpi-ico { color: var(--accent, #0a84ff); }
.reports-team-kpi[data-tint="green"] .reports-team-kpi-ico { color: var(--ok, #34c759); }
.reports-team-kpi[data-tint="purple"] .reports-team-kpi-ico { color: #af52de; }
.reports-team-kpi[data-tint="orange"] .reports-team-kpi-ico { color: #ff9f0a; }
.reports-team-kpi[data-tint="red"] .reports-team-kpi-ico { color: var(--danger, #ff453a); }
.reports-team-kpi[data-tint="teal"] .reports-team-kpi-ico { color: #64d2ff; }
.reports-team-kpi[data-tint="grey"] .reports-team-kpi-ico { color: var(--muted); }
.reports-team-kpi-val {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--reports-call-ink, var(--ink));
  line-height: 1.15;
}
.reports-team-kpi-lab {
  font-size: 0.72rem;
  color: var(--reports-call-muted, var(--muted));
  line-height: 1.25;
}
.reports-team-sec-title {
  margin: 0 0 8px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--reports-call-muted, var(--muted));
}
.reports-team-chart {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.reports-team-chart-svg {
  width: 100%;
  max-width: 360px;
  height: auto;
  display: block;
}
.reports-team-chart-tick {
  fill: var(--reports-call-muted, var(--muted));
  font-size: 9px;
  font-family: inherit;
}
.reports-team-perf {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.reports-orders-totals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.reports-orders-total {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  background: var(--reports-call-elevated, var(--bg-elevated));
  border: 1px solid var(--reports-call-line, var(--line));
}
.reports-orders-total-k {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--reports-call-muted, var(--muted));
}
.reports-orders-total-v {
  font-size: 1.05rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--reports-call-ink, var(--ink));
}
.reports-orders-value-note {
  margin: 8px 0 0;
}
.reports-team-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -4px;
  padding: 0 4px;
}
.reports-team-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
  color: var(--reports-call-ink, var(--ink));
}
.reports-team-table th,
.reports-team-table td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--reports-call-line, var(--line));
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
}
.reports-team-table th {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--reports-call-muted, var(--muted));
}
.reports-team-table .reports-team-user {
  white-space: normal;
  min-width: 8.5rem;
}
.reports-team-user {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.reports-team-user strong {
  font-weight: 600;
  color: var(--reports-call-ink, var(--ink));
}
.reports-team-user span {
  font-size: 0.75rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-daily-people-search {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  padding: 0 10px;
  min-height: var(--btn-h);
  border-radius: var(--btn-radius);
  background: var(--bg-elevated, #fff);
  border: 1px solid var(--line-strong, rgba(0, 0, 0, 0.12));
}
.reports-daily-people-search-ico {
  flex: none;
  color: var(--muted);
  display: inline-flex;
}
.reports-daily-people-search .field {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  box-shadow: none;
  padding: 10px 0;
  font: inherit;
  font-size: 0.92rem;
}
.reports-daily-people-sel-count {
  margin-left: auto;
  align-self: center;
}
.reports-daily-people-no-match[hidden],
.admin-opt-group .admin-opt-row[hidden] {
  display: none !important;
}
body.shell-phone .sky-hub-reports-phone .reports-team-kpis {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
  margin: 0 -2px;
  padding: 0 2px 2px;
}
body.shell-phone .sky-hub-reports-phone .reports-team-kpi {
  flex: 0 0 auto;
  width: 6.6rem;
  min-width: 6.6rem;
  padding: 10px 10px 8px;
  scroll-snap-align: start;
}
body.shell-phone .sky-hub-reports-phone .reports-team-kpi-val {
  font-size: 1.15rem;
}
.reports-sky-paper.is-empty,
.reports-sky-paper.is-skel {
  min-height: 320px;
}
.reports-sky-paper-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.reports-sky-paper-titles h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--accent, #0a84ff);
}
.reports-sky-paper-titles p {
  margin: 4px 0 0;
  font-size: 0.88rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-logo {
  height: 36px;
  width: auto;
  object-fit: contain;
}
.reports-sky-who {
  display: flex;
  align-items: center;
  gap: 14px;
}
.reports-sky-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-elevated-2);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.reports-sky-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.reports-sky-avatar-fb {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-who-txt strong {
  display: block;
  font-size: 1.05rem;
  color: var(--reports-call-ink, var(--ink));
}
.reports-sky-who-txt span {
  font-size: 0.82rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-status,
.reports-sky-track,
.reports-sky-quiet-copy {
  margin: 0;
  font-size: 0.9rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-track {
  display: flex;
  align-items: center;
  gap: 6px;
}
.reports-sky-metrics {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px 28px;
}
.reports-sky-donut-wrap {
  position: relative;
  width: 140px;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.reports-sky-donut-lab {
  position: absolute;
  inset: 0 0 auto 0;
  height: 112px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  text-align: center;
}
.reports-sky-donut-lab strong {
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  color: var(--reports-call-ink, var(--ink));
}
.reports-sky-donut-lab span {
  font-size: 0.68rem;
  color: var(--reports-call-muted, var(--muted));
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.reports-sky-donut-legs {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 0.72rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-leg-drive::before,
.reports-sky-leg-visit::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  margin-right: 6px;
  vertical-align: middle;
}
.reports-sky-leg-drive::before { background: var(--accent); }
.reports-sky-leg-visit::before { background: var(--ok); }
.reports-sky-kpis {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 140px;
}
.reports-sky-kpi {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.reports-sky-kpi strong {
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--accent, #0a84ff);
}
.reports-sky-kpi span {
  font-size: 0.78rem;
  color: var(--reports-call-muted, var(--muted));
}
.reports-sky-day {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}
.reports-sky-day-h {
  margin: 8px 0 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--reports-call-ink, var(--ink));
}
.reports-sky-act {
  display: grid;
  grid-template-columns: 52px 18px minmax(0, 1fr);
  gap: 8px 10px;
  align-items: start;
  padding: 6px 0;
  border-top: 1px solid var(--reports-call-line, var(--line));
}
.reports-sky-act-t {
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: var(--reports-call-muted, var(--muted));
  margin: 0;
}
.reports-sky-act-pin {
  color: var(--accent);
  margin-top: 2px;
}
.reports-sky-act-body {
  min-width: 0;
}
.reports-sky-act-lab {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--reports-call-ink, var(--ink));
}
.reports-sky-act-meta,
.reports-sky-act-type {
  margin: 2px 0 0;
  font-size: 0.78rem;
  color: var(--reports-call-muted, var(--muted));
}
body:not(.shell-phone) .sky-hub-reports-pc .reports-sky-viewer {
  min-height: min(68vh, 720px);
}
body.shell-phone .sky-hub-reports-phone .reports-sky-viewer {
  padding: 10px 8px 14px;
}
body.shell-phone .sky-hub-reports-phone .reports-sky-paper {
  padding: 16px 14px 20px;
}
body.shell-phone .sky-hub-reports-phone .reports-sky-toolbar-tools .btn span:not([aria-hidden]) {
  display: none;
}
body.shell-phone .sky-hub-reports-call .sky-page-subtitle,
body.shell-phone .sky-hub-reports-rep-performance .sky-page-subtitle,
body.shell-phone .sky-hub-reports-orders .sky-page-subtitle,
body.shell-phone .sky-hub-reports-visit-compliance .sky-page-subtitle {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* crm868 — Call Report + Rep Performance + Orders dark CRM kit (match shell + phone refs). Top bar + bottom nav stay global dark. */
.sky-hub-reports-call,
.sky-hub-reports-rep-performance,
.sky-hub-reports-orders, .sky-hub-reports-visit-compliance {
  --reports-call-bg: var(--bg);
  --reports-call-canvas: var(--bg);
  --reports-call-paper: var(--bg-elevated);
  --reports-call-ink: var(--ink);
  --reports-call-muted: var(--muted);
  --reports-call-line: var(--line);
  --reports-call-elev: var(--bg-elevated);
  color: var(--reports-call-ink);
  background: var(--reports-call-bg);
  border-radius: var(--btn-radius);
  flex: 1 1 auto;
  min-height: 0;
}
.sky-hub-reports-call .sky-page-head h1,
.sky-hub-reports-rep-performance .sky-page-head h1,
.sky-hub-reports-orders .sky-page-head h1 , .sky-hub-reports-visit-compliance .sky-page-head h1 {
  color: var(--reports-call-ink);
}
.sky-hub-reports-call .sky-page-subtitle,
.sky-hub-reports-rep-performance .sky-page-subtitle,
.sky-hub-reports-orders .sky-page-subtitle,
.sky-hub-reports-visit-compliance .sky-page-subtitle {
  color: var(--reports-call-muted);
}
.sky-hub-reports-call .sky-page-main.sky-canvas,
body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports-call .sky-page-main.sky-canvas,
body.shell-phone .sky-hub-reports-call .sky-page-main.sky-canvas,
.sky-hub-reports-rep-performance .sky-page-main.sky-canvas,
body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports-rep-performance .sky-page-main.sky-canvas,
body.shell-phone .sky-hub-reports-rep-performance .sky-page-main.sky-canvas,
body:not(.shell-phone) .sky-hub-page.is-pc.sky-hub-reports-orders .sky-page-main.sky-canvas, .sky-hub-reports-visit-compliance .sky-page-main.sky-canvas,
body.shell-phone .sky-hub-reports-orders .sky-page-main.sky-canvas , body.shell-phone .sky-hub-reports-visit-compliance .sky-page-main.sky-canvas {
  background: var(--reports-call-bg);
  color: var(--reports-call-ink);
  border-color: var(--reports-call-line);
  box-shadow: none;
}
.sky-hub-reports-call .reports-call-page,
.sky-hub-reports-rep-performance .reports-call-page,
.sky-hub-reports-orders .reports-call-page , .sky-hub-reports-visit-compliance .reports-call-page {
  color: var(--reports-call-ink);
}
.sky-hub-reports-call .reports-call-back .btn.ghost,
.sky-hub-reports-rep-performance .reports-call-back .btn.ghost,
.sky-hub-reports-orders .reports-call-back .btn.ghost , .sky-hub-reports-visit-compliance .reports-call-back .btn.ghost {
  color: var(--reports-call-ink);
  background: var(--btn-ghost-bg);
  border-color: var(--btn-ghost-border);
}
.sky-hub-reports-call .reports-call-back .btn.ghost:hover,
.sky-hub-reports-rep-performance .reports-call-back .btn.ghost:hover {
  background: var(--bg-elevated-2);
  border-color: var(--line-strong);
}
.sky-hub-reports-call .hdr-icon-btn.acal-filter-icon-btn,
.sky-hub-reports-rep-performance .hdr-icon-btn.acal-filter-icon-btn,
.sky-hub-reports-orders .hdr-icon-btn.acal-filter-icon-btn , .sky-hub-reports-visit-compliance .hdr-icon-btn.acal-filter-icon-btn {
  color: var(--reports-call-ink);
  background: var(--btn-ghost-bg);
  border: 1px solid var(--btn-ghost-border);
  border-radius: var(--btn-radius);
}
.sky-hub-reports-call .hdr-icon-btn.acal-filter-icon-btn.is-active,
.sky-hub-reports-rep-performance .hdr-icon-btn.acal-filter-icon-btn.is-active {
  color: #fff;
  background: var(--btn-seg-on);
  border-color: var(--btn-chip-on-border);
  box-shadow: var(--btn-chip-on-shadow);
}
.sky-hub-reports-call .reports-sky-viewer,
.sky-hub-reports-rep-performance .reports-sky-viewer,
.sky-hub-reports-orders .reports-sky-viewer , .sky-hub-reports-visit-compliance .reports-sky-viewer {
  background: var(--reports-call-canvas);
  border-color: var(--reports-call-line);
}
.sky-hub-reports-call .reports-daily-field-status,
.sky-hub-reports-call .reports-daily-field-footer,
.sky-hub-reports-call .admin-opt-sub,
.sky-hub-reports-rep-performance .reports-daily-field-status,
.sky-hub-reports-rep-performance .reports-daily-field-footer,
.sky-hub-reports-rep-performance .admin-opt-sub,
.sky-hub-reports-orders .reports-daily-field-status, .sky-hub-reports-visit-compliance .reports-daily-field-status,
.sky-hub-reports-orders .reports-daily-field-footer, .sky-hub-reports-visit-compliance .reports-daily-field-footer,
.sky-hub-reports-orders .admin-opt-sub , .sky-hub-reports-visit-compliance .admin-opt-sub {
  color: var(--reports-call-muted);
}
.sky-hub-reports-call .reports-call-phone-cta,
.sky-hub-reports-rep-performance .reports-call-phone-cta,
.sky-hub-reports-orders .reports-call-phone-cta , .sky-hub-reports-visit-compliance .reports-call-phone-cta {
  background: color-mix(in srgb, var(--bg-elevated) 92%, transparent);
  border-color: var(--line-strong);
  color: var(--reports-call-ink);
  box-shadow: var(--shadow);
}
.sky-hub-reports-call .reports-call-phone-cta .reports-daily-field-status,
.sky-hub-reports-rep-performance .reports-call-phone-cta .reports-daily-field-status,
.sky-hub-reports-orders .reports-call-phone-cta .reports-daily-field-status , .sky-hub-reports-visit-compliance .reports-call-phone-cta .reports-daily-field-status {
  color: var(--reports-call-muted);
}
.sky-hub-reports-call .reports-sky-paper.is-empty .btn.primary,
.sky-hub-reports-rep-performance .reports-sky-paper.is-empty .btn.primary,
.sky-hub-reports-orders .reports-sky-paper.is-empty .btn.primary , .sky-hub-reports-visit-compliance .reports-sky-paper.is-empty .btn.primary {
  margin-top: 4px;
}
/* Phone Filters summary strip — above viewer (dark kit; desk Filter rail stays CRM chrome) */
.sky-hub-reports-call .reports-call-filter-strip,
.sky-hub-reports-rep-performance .reports-call-filter-strip,
.sky-hub-reports-orders .reports-call-filter-strip , .sky-hub-reports-visit-compliance .reports-call-filter-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 10px;
  flex-wrap: wrap;
  padding: 8px 10px; /* crm858 density: was 10px 12px */
  border-radius: var(--btn-radius);
  background: var(--reports-call-elev);
  border: 1px solid var(--reports-call-line);
  color: var(--reports-call-ink);
}
.sky-hub-reports-call .reports-call-filter-strip-meta,
.sky-hub-reports-rep-performance .reports-call-filter-strip-meta,
.sky-hub-reports-orders .reports-call-filter-strip-meta , .sky-hub-reports-visit-compliance .reports-call-filter-strip-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.82rem;
  font-weight: var(--fw-med);
  line-height: 1.3;
  color: var(--reports-call-ink);
}
.sky-hub-reports-call .reports-call-filter-strip-sep,
.sky-hub-reports-rep-performance .reports-call-filter-strip-sep,
.sky-hub-reports-orders .reports-call-filter-strip-sep , .sky-hub-reports-visit-compliance .reports-call-filter-strip-sep {
  color: var(--reports-call-muted);
  flex: 0 0 auto;
}
.sky-hub-reports-call .reports-call-filter-strip .btn.ghost,
.sky-hub-reports-rep-performance .reports-call-filter-strip .btn.ghost,
.sky-hub-reports-orders .reports-call-filter-strip .btn.ghost , .sky-hub-reports-visit-compliance .reports-call-filter-strip .btn.ghost {
  flex: 0 0 auto;
  color: var(--reports-call-ink);
  background: var(--btn-ghost-bg);
  border-color: var(--btn-ghost-border);
}

@media print {
  body.reports-sky-printing #app > *:not(.shell),
  body.reports-sky-printing .sky-page-head,
  body.reports-sky-printing .reports-sky-toolbar,
  body.reports-sky-printing .crm-smart-rail,
  body.reports-sky-printing .crm-rail-toggle,
  body.reports-sky-printing .bottom-nav,
  body.reports-sky-printing .reports-daily-field-footer,
  body.reports-sky-printing .reports-daily-field-status,
  body.reports-sky-printing .reports-call-phone-cta,
  body.reports-sky-printing .reports-call-back {
    display: none !important;
  }
  body.reports-sky-printing .reports-sky-viewer {
    background: #fff;
    border: none;
    box-shadow: none;
    padding: 0;
  }
  body.reports-sky-printing .reports-sky-paper {
    box-shadow: none;
    border: none;
  }
}

/* ===== crm862: Shell unify Batch 1 — phone tools rows + track segs (CSS-only) =====
   Gold: Customers `.sky-cust-tools` + Products Gen `.shop-pl-seg` / Catalogues `.cat-hub-tab-seg`.
   Do not touch Home dashboard or Cart dock. Catalogues=Gen (crm860) + Reports search (crm861) kept. */

/* --- Tools rows: one --btn-h / gap / search / hdr-icon-btn rhythm --- */
body.shell-phone .sky-cust-tools,
body.shell-phone .sky-hub-tools,
body.shell-phone .acal-toolbar-phone-tools,
body.shell-phone .cat-hub-search-row,
body.shell-phone .reports-hub-search-row {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}
/* Products keeps Gen|COD|Ex CPT mid-track — slightly roomier gap, still one --btn-h row. */
body.shell-phone .shop-chrome-phone .sky-cust-tools.shop-phone-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
body.shell-phone .sky-hub-forms .sky-hub-tools {
  gap: 4px;
  padding: 0;
}
body.shell-phone .cat-hub-search-row {
  margin: 0 0 8px;
}
body.shell-phone .cat-hub-search,
body.shell-phone .reports-hub-search {
  flex: 1 1 auto;
  min-width: 0;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0 12px;
  border-radius: var(--btn-radius, var(--radius-sm));
  box-sizing: border-box;
}
body.shell-phone .cat-hub-search input,
body.shell-phone .reports-hub-search input {
  padding: 0;
  height: 100%;
  line-height: 1.2;
  font-size: 0.95rem;
}
body.shell-phone .cat-hub-filter-btn.hdr-icon-btn,
body.shell-phone .cat-hub-search-row .hdr-icon-btn,
body.shell-phone .sky-cust-tools .hdr-icon-btn,
body.shell-phone .sky-hub-tools .hdr-icon-btn,
body.shell-phone .sky-hub-tools .crm-plus-ico,
body.shell-phone .acal-toolbar-phone-tools .hdr-icon-btn {
  flex: 0 0 auto;
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  max-width: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0;
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}
body.shell-phone .reports-hub-cat-btn {
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}
body.shell-phone .sky-customers .sky-cust-tools .sky-page-search input,
body.shell-phone .sky-hub-page .sky-hub-tools .sky-page-search input,
body.shell-phone .acal-toolbar-phone-tools .acal-search-input-inline {
  min-height: var(--btn-h);
  height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}

/* --- Track segs: phone `.sky-phone-seg` → `.acal-seg` / `.shop-pl-seg` family --- */
body.shell-phone .sky-phone-seg,
body.shell-phone .sky-hub-reports .sky-phone-seg,
.sky-forms-new-sheet .sky-phone-seg {
  display: flex;
  align-items: stretch;
  gap: 2px;
  margin: 0;
  padding: 3px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
body.shell-phone .sky-phone-seg::-webkit-scrollbar,
body.shell-phone .sky-hub-reports .sky-phone-seg::-webkit-scrollbar {
  display: none;
}
body.shell-phone .sky-phone-seg-btn,
body.shell-phone .sky-hub-reports .sky-phone-seg-btn,
.sky-forms-new-sheet .sky-phone-seg-btn {
  appearance: none;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-secondary, #ebebf5);
  box-shadow: none;
  border-radius: var(--btn-radius-seg-item);
  padding: 0 12px;
  min-height: 0;
  height: 100%;
  max-height: none;
  font: inherit;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  line-height: 1.05;
  white-space: nowrap;
  cursor: pointer;
  box-sizing: border-box;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
body.shell-phone .sky-phone-seg-btn.is-on,
body.shell-phone .sky-hub-reports .sky-phone-seg-btn.is-on,
.sky-forms-new-sheet .sky-phone-seg-btn.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}

/* Calendar phone Day|Week|Month (+ kind) = Gen track metrics; Month blue stays --btn-seg-on. */
body.shell-phone .acal-seg {
  padding: 3px;
  gap: 2px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg {
  display: flex;
  width: 100%;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 3px;
  gap: 2px;
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg-btn {
  flex: 1 1 0;
  min-width: 0;
  min-height: 0;
  height: 100%;
  max-height: none;
  padding: 0 6px;
  font-size: 0.78rem;
  font-weight: var(--fw-semi);
  line-height: 1.05;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-secondary);
  border-radius: var(--btn-radius-seg-item);
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}
/* Preserve Catalogues = Gen (crm860) — beat late phone .acal-seg-btn min-height. */
body.shell-phone .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-tab-seg {
  padding: 3px;
  gap: 2px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
body.shell-phone .cat-hub-tab-seg .acal-seg-btn,
body.shell-phone .cat-hub-tab-seg .acal-seg-btn.is-on {
  height: 100%;
  min-height: 0;
  max-height: none;
  padding: 0 6px;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  border-radius: var(--btn-radius-seg-item);
  box-sizing: border-box;
}
body.shell-phone .cat-hub-tab-seg .acal-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}
/* ===== end crm862 ===== */

/* ===== crm863 Shell unify Batch 2 (CSS-only) =====
   Forms hub view tabs · Catalogues grid|list · Reports cat chips.
   Gold: Products Gen / Catalogues|Price lists --btn-seg-* track. Preserve crm860–862. */

/* --- Forms hub phone view tabs = Gen equal-column track (beat early chip forks) ---
   crm865: view segs live IN `.sky-hub-tools` before Filters (Products Gen mid-row parity). */
body.shell-phone .sky-hub-forms .sky-hub-tools .sky-page-search {
  flex: 0 1 28% !important;
  max-width: 34%;
  min-width: 72px;
}
body.shell-phone .sky-hub-forms .sky-hub-tools .sky-phone-seg {
  display: flex;
  align-items: stretch;
  flex: 1 1 0;
  min-width: 0;
  width: auto;
  max-width: 100%;
  gap: 2px;
  margin: 0;
  padding: 3px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
  align-self: center;
}
body.shell-phone .sky-hub-forms .sky-phone-seg::-webkit-scrollbar {
  display: none;
}
body.shell-phone .sky-hub-forms .sky-phone-seg-btn {
  appearance: none;
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-secondary, #ebebf5);
  box-shadow: none;
  border-radius: var(--btn-radius-seg-item);
  padding: 0 6px;
  min-height: 0;
  height: 100%;
  max-height: none;
  font: inherit;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  line-height: 1.05;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
  box-sizing: border-box;
  transition: background 0.15s var(--ease), color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
body.shell-phone .sky-hub-forms .sky-phone-seg-btn.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
}
/* New-form sheet seg — same Gen fill (kill leftover min-height: 36) */
.sky-forms-new-sheet .sky-phone-seg {
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 3px;
  gap: 2px;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
.sky-forms-new-sheet .sky-phone-seg-btn {
  flex: 1 1 0;
  min-width: 0;
  min-height: 0;
  height: 100%;
  max-height: none;
  padding: 0 6px;
  font-size: 0.74rem;
  font-weight: var(--fw-semi);
  border-radius: var(--btn-radius-seg-item);
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
  box-sizing: border-box;
}
.sky-forms-new-sheet .sky-phone-seg-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}

/* --- Catalogues grid|list = Gen track height (phone + desk) --- */
.cat-hub-view-seg,
body.shell-phone .cat-hub-view-seg {
  display: inline-flex;
  align-items: stretch;
  gap: 2px;
  padding: 3px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
.cat-hub-view-btn,
body.shell-phone .cat-hub-view-btn {
  width: auto;
  min-width: calc(var(--btn-h) - 6px);
  height: 100%;
  min-height: 0;
  max-height: none;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: var(--btn-radius-seg-item);
  background: transparent;
  box-sizing: border-box;
}
.cat-hub-view-btn.is-on,
body.shell-phone .cat-hub-view-btn.is-on {
  background: var(--btn-seg-on);
  color: #fff;
  box-shadow: var(--btn-seg-on-shadow);
  border-color: var(--btn-chip-on-border);
}

/* --- Reports landing Categories chips → dense chip-on (beat phone --btn-h floor) --- */
.reports-hub-cat-chips,
.reports-hub-cat-sheet .reports-hub-cat-chips,
.reports-hub-cat-sheet .sky-cust-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 2px 0 4px;
  margin: 0;
}
.reports-hub-cat-chips .sky-cust-filter-chip,
.reports-hub-cat-sheet .sky-cust-filter-chip,
body.shell-phone .reports-hub-cat-chips .sky-cust-filter-chip,
body.shell-phone .reports-hub-cat-sheet .sky-cust-filter-chip {
  appearance: none;
  -webkit-appearance: none;
  min-height: var(--btn-h-sm);
  height: auto;
  max-height: none;
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: var(--fw-med);
  border-radius: var(--btn-chip-radius) !important;
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--ink-secondary);
  box-shadow: var(--btn-ghost-shadow);
  box-sizing: border-box;
}
.reports-hub-cat-chips .sky-cust-filter-chip.is-on,
.reports-hub-cat-sheet .sky-cust-filter-chip.is-on,
body.shell-phone .reports-hub-cat-chips .sky-cust-filter-chip.is-on,
body.shell-phone .reports-hub-cat-sheet .sky-cust-filter-chip.is-on {
  border-color: var(--btn-chip-on-border);
  background: var(--btn-chip-on-bg);
  color: #fff;
  box-shadow: var(--btn-chip-on-shadow);
}
/* ===== end crm863 ===== */

/* ===== crm864 Call Report phone top chrome (Skynamo tools row) =====
   Period chip · People chip · Filters — one tools row under title.
   Demote heavy Sky print/pager/format toolbar; dense export under preview.
   Preserve crm860–863 shell unify. Pastel READ-ONLY. */
.sky-hub-reports-call .reports-call-filter-strip.sky-hub-tools {
  display: flex;
  align-items: stretch;
  gap: 6px;
  flex-wrap: nowrap;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: 0;
  margin: 4px 0 0;
  background: transparent;
  border: none;
  border-radius: 0;
}
.sky-hub-reports-call .reports-call-meta-chip {
  appearance: none;
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: var(--btn-chip-radius);
  border: 1px solid var(--btn-ghost-border);
  background: var(--btn-ghost-bg);
  color: var(--reports-call-ink);
  box-shadow: var(--btn-ghost-shadow);
  cursor: pointer;
  text-align: left;
  font: inherit;
  line-height: 1.15;
  min-height: var(--btn-h);
  box-sizing: border-box;
}
.sky-hub-reports-call .reports-call-meta-chip-ico {
  flex: 0 0 auto;
  display: inline-flex;
  color: var(--reports-call-muted);
}
.sky-hub-reports-call .reports-call-meta-chip-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.sky-hub-reports-call .reports-call-meta-chip-k {
  font-size: 0.62rem;
  font-weight: var(--fw-med, 600);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--reports-call-muted);
  line-height: 1.1;
}
.sky-hub-reports-call .reports-call-meta-chip-v {
  font-size: 0.78rem;
  font-weight: var(--fw-med, 600);
  color: var(--reports-call-ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.shell-phone .sky-hub-reports-phone .reports-call-back {
  display: none; /* global shell back owns nav — save chrome */
}
body.shell-phone .sky-hub-reports-phone .reports-sky-toolbar-phone-slim {
  justify-content: center;
  padding: 4px 0 0;
  margin: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}
body.shell-phone .sky-hub-reports-phone .reports-sky-toolbar-phone-slim .reports-sky-tb-pager {
  background: var(--btn-seg-track);
  border: 1px solid var(--line);
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin: 8px 2px 4px;
  padding: 8px 10px;
  border-radius: var(--btn-radius);
  background: var(--reports-call-elev);
  border: 1px solid var(--reports-call-line);
  color: var(--reports-call-ink);
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats {
  flex: 1 1 auto;
  min-width: 0;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats .acal-seg {
  width: 100%;
  max-width: 280px;
  background: var(--btn-seg-track);
  border: 1px solid var(--line);
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats .acal-seg-btn {
  color: var(--reports-call-ink);
  min-height: var(--btn-h-sm);
  font-size: var(--btn-fs-sm);
  padding: 0 10px;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-acts {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-acts .btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-acts .btn.ghost {
  color: var(--reports-call-ink);
  background: var(--btn-ghost-bg);
  border-color: var(--btn-ghost-border);
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense .reports-daily-field-status {
  flex: 1 1 100%;
  margin: 0;
  min-height: 1.1em;
  color: var(--reports-call-muted);
}
body.shell-phone .sky-hub-reports-phone .reports-call-page.is-phone {
  /* sticky CTA removed — only bottom-nav clearance */
  padding-bottom: calc(var(--bottom-nav-h, 56px) + var(--safe-bottom, 0px) + 12px);
}
body.shell-phone .sky-hub-reports-phone .reports-sky-paper.is-empty .btn.ghost {
  margin-top: 8px;
}
/* ===== end crm864 ===== */

/* ===== crm866 Catalogues phone tools = Products Gen mid-row SoT =====
   One row: search | Catalogues|Price lists | grid|list | Filters.
   Tabs no longer a separate full-width row. Preserve crm860–865. */
body.shell-phone .cat-hub-page .sky-hub-tools.cat-hub-tools {
  display: flex;
  align-items: center;
  gap: 6px;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  width: 100%;
  min-width: 0;
  margin: 0 0 8px;
  padding: 0;
  box-sizing: border-box;
}
body.shell-phone .cat-hub-page .cat-hub-tools .sky-page-search {
  flex: 0 1 28%;
  max-width: 34%;
  min-width: 72px;
  margin: 0;
}
body.shell-phone .cat-hub-page .cat-hub-tools .sky-page-search input {
  min-height: var(--btn-h);
  height: var(--btn-h);
  max-height: var(--btn-h);
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}
body.shell-phone .cat-hub-page .cat-hub-tools .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-page .cat-hub-tools .cat-hub-tab-seg {
  flex: 1 1 0;
  min-width: 0;
  width: auto;
  max-width: 100%;
  margin: 0;
  align-self: center;
}
body.shell-phone .cat-hub-page .cat-hub-tools .cat-hub-view-seg {
  flex: 0 0 auto;
  align-self: center;
  margin: 0;
}
body.shell-phone .cat-hub-page .cat-hub-tools .cat-hub-filter-btn.hdr-icon-btn {
  flex: 0 0 auto;
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  max-width: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0;
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
}
/* ===== end crm866 ===== */

/* ===== crm867 Call Report team dash — outcome donut + Success/No orders =====
   Honest KPIs when visits > 0; never invent Not reached. Phone dense layout.
   Preserve crm861 Filter Report · crm864 Period·People·Filters. Pastel READ-ONLY.
   crm868: dark kit tokens (no light elev/#fff paper wash). */
.reports-call-dash {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px 18px 16px;
  margin: 0 0 12px;
  border-radius: var(--btn-radius);
  background: var(--reports-call-paper, var(--bg-elevated));
  border: 1px solid var(--reports-call-line, var(--line-strong));
  box-shadow: var(--shadow);
  color: var(--reports-call-ink, var(--ink));
  min-width: 0;
}
.reports-call-dash-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.reports-call-dash-titles h2 {
  margin: 0;
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--accent, #0a84ff);
  line-height: 1.2;
}
.reports-call-dash-titles p {
  margin: 4px 0 0;
  font-size: 0.84rem;
  color: var(--reports-call-muted, var(--muted));
  line-height: 1.3;
}
.reports-call-dash-logo {
  height: 34px;
  width: auto;
  object-fit: contain;
  flex: 0 0 auto;
}
.reports-team-charts {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 12px 16px;
  align-items: start;
  min-width: 0;
}
.reports-team-charts:has(.reports-team-chart:only-child),
.reports-team-charts:has(.reports-team-outcome:only-child) {
  grid-template-columns: 1fr;
}
.reports-team-outcome {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.reports-team-outcome-body {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.reports-team-outcome-svg {
  width: 104px;
  height: 104px;
  flex: 0 0 auto;
  display: block;
}
.reports-team-outcome-legs {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.reports-team-outcome-leg {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--reports-call-ink, var(--ink));
  line-height: 1.25;
}
.reports-team-outcome-leg i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex: 0 0 auto;
  background: var(--muted);
}
.reports-team-outcome-leg[data-lab="Orders"] i {
  background: var(--ok, #34c759);
}
.reports-team-outcome-leg[data-lab="No orders"] i {
  background: var(--danger, #ff453a);
}
.reports-team-success {
  min-width: 4.5rem;
}
.reports-team-success-lab {
  display: inline-block;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--reports-call-ink, var(--ink));
}
.reports-team-success-bar {
  display: block;
  margin-top: 4px;
  height: 4px;
  width: 3.2rem;
  border-radius: 3px;
  background: color-mix(in srgb, var(--ok, #30d158) 22%, transparent);
  overflow: hidden;
}
.reports-team-success-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--ok, #34c759);
}
.reports-role-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-top: 2px;
  padding: 1px 7px;
  border-radius: var(--btn-chip-radius, var(--radius-sm));
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: color-mix(in srgb, var(--accent) 78%, #fff 22%);
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}
body.shell-phone .sky-hub-reports-phone .reports-call-dash {
  gap: 12px;
  padding: 14px 12px 12px;
  margin: 0 0 10px;
  box-shadow: var(--shadow);
}
body.shell-phone .sky-hub-reports-phone .reports-call-dash-titles h2 {
  font-size: 1.12rem;
}
body.shell-phone .sky-hub-reports-phone .reports-call-dash-titles p {
  font-size: 0.78rem;
}
body.shell-phone .sky-hub-reports-phone .reports-call-dash-logo {
  height: 28px;
}
body.shell-phone .sky-hub-reports-phone .reports-team-charts {
  grid-template-columns: 1fr;
  gap: 12px;
}
body.shell-phone .sky-hub-reports-phone .reports-team-chart-svg {
  max-width: 100%;
}
body.shell-phone .sky-hub-reports-phone .reports-team-outcome-body {
  gap: 12px;
}
body.shell-phone .sky-hub-reports-phone .reports-team-outcome-svg {
  width: 92px;
  height: 92px;
}
body.shell-phone .sky-hub-reports-phone .reports-team-table {
  font-size: 0.78rem;
}
body.shell-phone .sky-hub-reports-phone .reports-team-table th,
body.shell-phone .sky-hub-reports-phone .reports-team-table td {
  padding: 8px 6px;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-k {
  flex: 1 1 100%;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--reports-call-muted, var(--muted));
  line-height: 1.1;
}
/* ===== end crm867 / crm868 ===== */

/* ===== crm869: equal track segs · Calendar one tools row · Call Report SoT =====
   A) Gen|COD|Ex CPT + Catalogues|Price lists = equal columns (shrink search).
   B) Calendar phone: search | Month|Week|Day | Filters | + (no third chrome band).
   C/D) Call Report dark kit + Export TOP + crm-condense-fold. Pastel READ-ONLY. */

/* --- A) Equal-width track segments (beat content-sized / flex shrink-wrap) --- */
.shop-pl-seg,
.shop-phone-pl .shop-pl-seg,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .shop-pl-seg,
.acal-seg.cat-hub-tab-seg,
.cat-hub-tab-seg,
body.shell-phone .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-tab-seg,
body.shell-phone .cat-hub-page .cat-hub-tools .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-page .cat-hub-tools .cat-hub-tab-seg {
  display: grid !important;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}
.shop-pl-seg .pl-seg-btn,
.shop-phone-pl .pl-seg-btn,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .pl-seg-btn,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .pl-seg-btn.active,
.cat-hub-tab-seg .acal-seg-btn,
.cat-hub-tab-seg .acal-seg-btn.is-on,
body.shell-phone .cat-hub-tab-seg .acal-seg-btn,
body.shell-phone .cat-hub-tab-seg .acal-seg-btn.is-on {
  flex: unset !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none;
  justify-content: center;
  box-sizing: border-box;
  padding-left: 4px;
  padding-right: 4px;
}
/* Shrink search so mid-track segs stay equal + readable */
body.shell-phone .shop-chrome-phone .sky-cust-tools .search-wrap.shop-search {
  flex: 0 1 22% !important;
  max-width: 26% !important;
  min-width: 4.25rem !important;
}
body.shell-phone .cat-hub-page .cat-hub-tools .sky-page-search {
  flex: 0 1 20% !important;
  max-width: 24% !important;
  min-width: 3.75rem !important;
}
body.shell-phone .cat-hub-page .cat-hub-tools .acal-seg.cat-hub-tab-seg,
body.shell-phone .cat-hub-page .cat-hub-tools .cat-hub-tab-seg {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  max-width: none !important;
  width: auto !important;
}

/* --- B) Calendar phone tools: search | view segs | Filters | + --- */
body.shell-phone .acal-toolbar-phone-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-width: 0;
  flex-wrap: nowrap;
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-tools .acal-search-inline {
  flex: 0 1 28%;
  max-width: 34%;
  min-width: 4.5rem;
}
body.shell-phone .acal-toolbar-phone-view {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  align-self: center;
  height: var(--btn-h);
  max-height: var(--btn-h);
}
body.shell-phone .acal-toolbar-phone-view .acal-seg {
  display: grid !important;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  width: 100%;
  height: var(--btn-h);
  min-height: var(--btn-h);
  max-height: var(--btn-h);
  padding: 3px;
  gap: 2px;
  margin: 0;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-view .acal-seg-btn {
  flex: unset !important;
  width: 100%;
  min-width: 0;
  height: 100%;
  min-height: 0;
  max-height: none;
  padding: 0 4px;
  font-size: 0.72rem;
  font-weight: var(--fw-semi);
  border-radius: var(--btn-radius-seg-item);
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-combo {
  display: none !important; /* retired third chrome band */
}
body.shell-phone .acal-toolbar-phone-kind-inline {
  flex: 1 1 100%;
  min-width: 0;
  margin: 0 0 6px;
}
body.shell-phone .acal-toolbar-phone-kind-inline .acal-seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  width: 100%;
  max-width: 100%;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  padding: 2px;
  gap: 2px;
  box-sizing: border-box;
}
body.shell-phone .acal-toolbar-phone-top {
  flex-wrap: wrap;
}

/* --- C/D) Call Report dark composition + Export TOP fold --- */
.reports-team-kpi-ico-well {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  margin-bottom: 2px;
}
.reports-team-kpi[data-tint="blue"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, var(--accent, #0a84ff) 22%, transparent);
}
.reports-team-kpi[data-tint="green"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, var(--ok, #34c759) 22%, transparent);
}
.reports-team-kpi[data-tint="purple"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, #af52de 22%, transparent);
}
.reports-team-kpi[data-tint="orange"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, #ff9f0a 22%, transparent);
}
.reports-team-kpi[data-tint="red"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, var(--danger, #ff453a) 22%, transparent);
}
.reports-team-kpi[data-tint="teal"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, #64d2ff 22%, transparent);
}
.reports-team-kpi[data-tint="grey"] .reports-team-kpi-ico-well {
  background: color-mix(in srgb, var(--muted) 22%, transparent);
}
.reports-team-chart-card {
  padding: 12px 12px 10px;
  border-radius: var(--btn-radius);
  background: var(--bg-elevated-2, #2c2c2e);
  border: 1px solid var(--reports-call-line, var(--line));
  box-sizing: border-box;
  min-width: 0;
}
.reports-call-dash-titles h2 {
  color: var(--reports-call-ink, var(--ink));
}
.reports-call-dash-empty {
  align-items: flex-start;
}
.reports-call-dash-empty .btn.ghost {
  margin-top: 4px;
}
.reports-call-export-fold {
  margin: 0 0 10px;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense,
.sky-hub-reports-call .reports-call-export-dense,
.sky-hub-reports-rep-performance .reports-call-export-dense,
.sky-hub-reports-orders .reports-call-export-dense , .sky-hub-reports-visit-compliance .reports-call-export-dense {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin: 0;
  padding: 8px 10px;
  border-radius: var(--btn-radius);
  background: var(--reports-call-elev, var(--bg-elevated));
  border: 1px solid var(--reports-call-line, var(--line));
  color: var(--reports-call-ink, var(--ink));
}
.sky-hub-reports-call .reports-call-export-dense-formats .acal-seg,
.sky-hub-reports-call .reports-call-export-dense-formats .reports-daily-period-seg,
.sky-hub-reports-rep-performance .reports-call-export-dense-formats .acal-seg,
.sky-hub-reports-rep-performance .reports-call-export-dense-formats .reports-daily-period-seg,
.sky-hub-reports-orders .reports-call-export-dense-formats .acal-seg, .sky-hub-reports-visit-compliance .reports-call-export-dense-formats .acal-seg,
.sky-hub-reports-orders .reports-call-export-dense-formats .reports-daily-period-seg , .sky-hub-reports-visit-compliance .reports-call-export-dense-formats .reports-daily-period-seg {
  display: grid !important;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  width: 100%;
  max-width: 280px;
}
/* Filter Report kit — people checklist + date (not Users opt-rows / Current) */
.reports-filter-date {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: var(--btn-h);
  padding: 0 10px;
  margin: 0 0 10px;
  border-radius: var(--btn-radius);
  background: var(--bg-elevated-2, #2c2c2e);
  border: 1px solid var(--line-strong, rgba(255, 255, 255, 0.12));
  box-sizing: border-box;
}
.reports-filter-date-ico {
  flex: 0 0 auto;
  color: var(--muted);
  display: inline-flex;
}
.reports-filter-date input[type="date"] {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.92rem;
  padding: 10px 0;
}
.reports-filter-people-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0 0 8px;
}
.reports-filter-person {
  appearance: none;
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin: 0;
  padding: 8px 10px;
  min-height: var(--btn-h);
  border-radius: var(--btn-radius);
  border: 1px solid var(--line);
  background: var(--bg-elevated-2, #2c2c2e);
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  box-sizing: border-box;
}
.reports-filter-person.is-on {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: color-mix(in srgb, var(--accent) 12%, var(--bg-elevated-2));
}
.reports-filter-person-check,
.reports-filter-person-ico {
  display: inline-flex;
  color: var(--muted);
}
.reports-filter-person.is-on .reports-filter-person-check {
  color: var(--accent, #0a84ff);
}
.reports-filter-person-lab {
  min-width: 0;
  font-size: 0.9rem;
  font-weight: var(--fw-med);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.reports-filter-person-off {
  font-style: normal;
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
}
.reports-filter-person .reports-role-chip {
  margin-top: 0;
}
.reports-daily-people-search {
  background: var(--bg-elevated-2, #2c2c2e);
  border-color: var(--line-strong, rgba(255, 255, 255, 0.12));
}
.reports-filter-report-sheet .crm-menu-body,
.reports-daily-field-body {
  color: var(--ink);
}
.reports-daily-filters-apply {
  background: var(--bg-elevated, #1c1c1e);
}
.reports-filter-people-list .reports-filter-person[hidden],
.admin-opt-group .admin-opt-row[hidden] {
  display: none !important;
}
/* ===== end crm869 ===== */

/* ===== crm870 Call Report Filters = kit hdr-icon-btn =====
   Same Products/Calendar/Catalogues filter ico — no text Filters CTA. */
.sky-hub-reports-call .reports-call-filter-strip .hdr-icon-btn.acal-filter-icon-btn {
  flex: 0 0 auto;
  width: var(--btn-h);
  height: var(--btn-h);
  min-width: var(--btn-h);
  min-height: var(--btn-h);
  max-width: var(--btn-h);
  max-height: var(--btn-h);
  padding: 0;
  box-sizing: border-box;
  border-radius: var(--btn-radius, var(--radius-sm));
  position: relative;
}
/* ===== end crm870 ===== */

/* ===== crm871 Call Report phone: tools always on · compact Export · dark logo =====
   Period·People·Filters never condensed away. Export sized to text (--btn-h-sm).
   Dash logo = white wordmark (logo.png). Pastel READ-ONLY. */
body.shell-phone .sky-hub-reports-call .reports-call-filter-strip.sky-hub-tools {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  height: auto !important;
  min-height: var(--btn-h);
  max-height: none;
  pointer-events: auto;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
}
/* Export may still fold on scroll; tools strip never joins CRM_CONDENSE_FOLD_SELS. */
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense,
.sky-hub-reports-call .reports-call-export-dense,
.sky-hub-reports-rep-performance .reports-call-export-dense,
.sky-hub-reports-orders .reports-call-export-dense , .sky-hub-reports-visit-compliance .reports-call-export-dense {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 6px 8px;
  margin: 0 0 8px;
  padding: 6px 8px;
  width: fit-content;
  max-width: 100%;
  box-sizing: border-box;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-k,
.sky-hub-reports-call .reports-call-export-dense-k {
  flex: 0 0 auto;
  width: auto;
  margin: 0;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--reports-call-muted, var(--muted));
  line-height: 1;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats,
.sky-hub-reports-call .reports-call-export-dense-formats {
  flex: 0 0 auto;
  width: auto;
  min-width: 0;
}
.sky-hub-reports-call .reports-call-export-dense-formats .acal-seg,
.sky-hub-reports-call .reports-call-export-dense-formats .reports-daily-period-seg,
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats .acal-seg {
  display: inline-grid !important;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  width: auto !important;
  max-width: none !important;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm);
  max-height: var(--btn-h-sm);
  padding: 2px;
  gap: 2px;
  box-sizing: border-box;
  border-radius: var(--btn-radius-seg);
  background: var(--btn-seg-track);
  border: 1px solid var(--line);
}
.sky-hub-reports-call .reports-call-export-dense-formats .acal-seg-btn,
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-formats .acal-seg-btn {
  width: auto !important;
  min-width: 2.6rem;
  height: 100%;
  min-height: 0 !important;
  max-height: none;
  padding: 0 8px !important;
  font-size: var(--btn-fs-sm);
  font-weight: var(--fw-semi);
  border-radius: var(--btn-radius-seg-item);
  box-sizing: border-box;
  color: var(--reports-call-ink, var(--ink));
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-acts,
.sky-hub-reports-call .reports-call-export-dense-acts {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  width: auto;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense-acts .btn,
.sky-hub-reports-call .reports-call-export-dense-acts .btn {
  width: fit-content !important;
  max-width: none;
  flex: 0 0 auto;
  height: var(--btn-h-sm);
  min-height: var(--btn-h-sm) !important;
  max-height: var(--btn-h-sm);
  padding: 0 10px !important;
  font-size: var(--btn-fs-sm);
  border-radius: var(--btn-radius, var(--radius-sm));
  display: inline-flex;
  align-items: center;
  gap: 5px;
  box-sizing: border-box;
}
body.shell-phone .sky-hub-reports-phone .reports-call-export-dense .reports-daily-field-status,
.sky-hub-reports-call .reports-call-export-dense .reports-daily-field-status {
  flex: 1 1 100%;
  margin: 0;
  min-height: 0;
  font-size: 0.72rem;
}
/* Dark dash: white wordmark logo (logo.png via LOGO_DASH_SRC) */
.sky-hub-reports-call .reports-call-dash-logo,
body.shell-phone .sky-hub-reports-phone .reports-call-dash-logo {
  height: 28px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  opacity: 1;
  filter: none;
}
/* ===== end crm871 ===== */

/* ===== crm872 Call Report: Activity filter · Apply bar · build status =====
   Visits filter on team dash; Filter Report order Activity before people;
   sticky Apply clearance; kit build status strip (no dual Building… buttons). */
.reports-call-build-status[hidden] {
  display: none !important;
}
.reports-call-build-status {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  border-radius: var(--btn-radius, var(--radius-sm));
  background: var(--bg-elevated-2, rgba(255, 255, 255, 0.06));
  border: 1px solid rgba(10, 132, 255, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  color: var(--ink-secondary, var(--ink));
  font-size: var(--btn-fs-sm, 0.75rem);
  font-weight: var(--fw-semi, 600);
  line-height: 1.25;
}
.reports-call-build-status-spin {
  flex: 0 0 14px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(10, 132, 255, 0.22);
  border-top-color: var(--accent, #0a84ff);
  animation: crm-send-busy-spin 0.85s linear infinite;
}
.reports-call-build-status-txt {
  flex: 1;
  min-width: 0;
}
.reports-call-export-dense .reports-call-build-status,
.reports-sky-tb-save .reports-call-build-status,
.reports-daily-field-actions .reports-call-build-status {
  flex: 1 1 100%;
  margin: 0;
}
.reports-sky-tb-save {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
/* ===== end crm872 ===== */

/* ===== crm873 Call Report hard fix: visits-only dash · Apply footer · build strip DOM =====
   Activity=Visits hides order KPIs/outcome; Apply outside scroll; build status always in DOM. */
.reports-filter-report-sheet .reports-daily-filters-apply-foot {
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}
.sky-hub-reports-pc .reports-filter-report-rail .reports-daily-filters-apply-foot {
  padding: 10px 12px 12px;
}
/* ===== end crm873 ===== */

/* ===== crm895: desk full shop PL map (scroll, not equal-crush) ===== */
.shop-pl-seg.shop-pl-seg--all,
.shop-phone-pl .shop-pl-seg.shop-pl-seg--all,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .shop-pl-seg.shop-pl-seg--all {
  display: inline-flex !important;
  grid-auto-flow: unset;
  grid-auto-columns: unset;
  width: auto !important;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.shop-pl-seg.shop-pl-seg--all .pl-seg-btn,
.shop-phone-pl .shop-pl-seg.shop-pl-seg--all .pl-seg-btn,
body.shell-phone .shop-chrome-phone .sky-cust-tools .shop-phone-pl .shop-pl-seg.shop-pl-seg--all .pl-seg-btn {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: max-content !important;
  padding-left: 8px;
  padding-right: 8px;
  white-space: nowrap;
}
/* ===== end crm895 ===== */
