/* Swipe CRM
   Layout: one quiet column of work, a slim rail on the left, hairlines instead of boxes.
   Restraint: monochrome surfaces, Swipe Blue only where something is selected or new,
   black for the one thing you should do next.
   Type scale: 11, 13, 15, 17, 24, then display sizes. Weights: 300 display, 400 titles,
   500 interface, 600 only for tiny labels. */

@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 100 1000;
  font-display: swap;
  src: url('/fonts/dm-sans.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 100 1000;
  font-display: swap;
  src: url('/fonts/dm-sans-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;

  --canvas: #f4f5f7;
  --paper: #ffffff;
  --sunk: #eceef1;
  --ink: #0b0b0d;
  --ink-2: #55575d;
  --ink-3: #686a71;
  --hair: rgba(12, 16, 28, 0.08);
  --hair-2: rgba(12, 16, 28, 0.14);
  --hover: rgba(12, 16, 28, 0.04);
  --press: rgba(12, 16, 28, 0.07);
  --action: #0b0b0d;
  --action-ink: #ffffff;
  --blue: #85adee;
  --blue-soft: rgba(133, 173, 238, 0.18);
  --blue-ink: #2f5fb3;
  --red: #c2342a;
  --green: #327320;
  --violet: #5a5fc6;
  --rose: #b0566a;
  --focus: rgba(133, 173, 238, 0.6);
  --focus-ring: #2f5fb3;
  --scrim: rgba(10, 12, 18, 0.32);
  --lift: 0 1px 1px rgba(12, 16, 28, 0.03), 0 4px 24px rgba(12, 16, 28, 0.05);
  --float: 0 2px 8px rgba(12, 16, 28, 0.06), 0 24px 64px rgba(12, 16, 28, 0.16);
  --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23686a71' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E");

  --r-lg: 22px;
  --r-md: 14px;
  --r-sm: 10px;
  --pill: 999px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --spring: cubic-bezier(0.32, 0.72, 0, 1);
  /* A spring with a whisper of overshoot, for things that slide into place. */
  --spring-settle: cubic-bezier(0.3, 1.18, 0.4, 1);
  --rail: 232px;
  /* One control height for every toolbar: search, select, segmented control. */
  --h: 40px;
  /* Selected segment and track thumb: lifts off its track in both themes. */
  --thumb: var(--paper);
  --thumb-on-paper: var(--sunk);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --canvas: #0b0b0d; --paper: #161619; --sunk: #1f1f23; --ink: #f4f4f6; --ink-2: #a6a7ae; --ink-3: #8e8f97;
    --hair: rgba(255, 255, 255, 0.08); --hair-2: rgba(255, 255, 255, 0.14); --hover: rgba(255, 255, 255, 0.045);
    --press: rgba(255, 255, 255, 0.08); --action: #f4f4f6; --action-ink: #0b0b0d; --blue-soft: rgba(133, 173, 238, 0.16);
    --blue-ink: #a9c5f6; --red: #ff6b5f; --green: #8ed16f; --violet: #aeb1ff; --rose: #f1a6b5; --scrim: rgba(0, 0, 0, 0.6);
    --focus-ring: #85adee; --thumb: #2c2c31; --thumb-on-paper: #2c2c31;
    --lift: 0 0 0 1px rgba(255, 255, 255, 0.05); --float: 0 0 0 1px rgba(255, 255, 255, 0.07), 0 30px 80px rgba(0, 0, 0, 0.6);
    --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%238e8f97' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E");
    color-scheme: dark;
  }
}
:root[data-theme='dark'] {
  --canvas: #0b0b0d; --paper: #161619; --sunk: #1f1f23; --ink: #f4f4f6; --ink-2: #a6a7ae; --ink-3: #8e8f97;
  --hair: rgba(255, 255, 255, 0.08); --hair-2: rgba(255, 255, 255, 0.14); --hover: rgba(255, 255, 255, 0.045);
  --press: rgba(255, 255, 255, 0.08); --action: #f4f4f6; --action-ink: #0b0b0d; --blue-soft: rgba(133, 173, 238, 0.16);
  --blue-ink: #a9c5f6; --red: #ff6b5f; --green: #8ed16f; --violet: #aeb1ff; --rose: #f1a6b5; --scrim: rgba(0, 0, 0, 0.6);
  --focus-ring: #85adee; --thumb: #2c2c31; --thumb-on-paper: #2c2c31;
  --lift: 0 0 0 1px rgba(255, 255, 255, 0.05); --float: 0 0 0 1px rgba(255, 255, 255, 0.07), 0 30px 80px rgba(0, 0, 0, 0.6);
  --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%238e8f97' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E");
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  -webkit-tap-highlight-color: transparent;
}
button, input, textarea, select { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; text-align: inherit; }
a { color: inherit; text-decoration: none; }
svg { display: block; flex: none; }
img { max-width: 100%; }
h1, h2, h3, p { margin: 0; }
::selection { background: var(--blue-soft); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
[hidden] { display: none !important; }
.sr { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-2); }
.faint { color: var(--ink-3); }
.grow { flex: 1; min-width: 0; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row { display: flex; align-items: center; gap: 12px; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.gap-sm { gap: 8px; }
.wrap { flex-wrap: wrap; }
.mt { margin-top: 20px; }
.small { font-size: 13px; }

/* Page changes crossfade, briefly. */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 180ms; animation-timing-function: ease; }

/* shell */
.shell { display: grid; grid-template-columns: var(--rail) minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.rail {
  position: sticky; top: 0; height: 100vh; height: 100dvh;
  display: flex; flex-direction: column; gap: 2px;
  padding: 30px 16px 20px;
  border-right: 1px solid var(--hair);
}
.logo { display: block; color: var(--ink); }
.logo svg { height: 26px; width: auto; }
.rail .logo { padding: 0 12px 30px; }
.nav { display: flex; align-items: center; gap: 12px; height: 38px; padding: 0 12px; border-radius: var(--r-sm); color: var(--ink-2); font-weight: 500; font-size: 15px; transition: background 0.2s var(--ease), color 0.2s; }
@media (hover: hover) { .nav:hover { background: var(--hover); color: var(--ink); } }
.nav[aria-current='page'] { color: var(--ink); background: var(--paper); box-shadow: var(--lift); }
.nav .badge { margin-left: auto; }
.rail-foot { margin-top: auto; display: flex; flex-direction: column; gap: 2px; }
.rail-search { display: flex; align-items: center; gap: 10px; height: 38px; padding: 0 12px; margin-bottom: 14px; border-radius: var(--r-sm); background: var(--sunk); color: var(--ink-3); font-size: 15px; }
.rail-search kbd { margin-left: auto; font: inherit; font-size: 11px; color: var(--ink-3); }

.main { min-width: 0; }
.page { max-width: 1120px; margin: 0 auto; padding: 56px 56px 140px; }
.page.wide { max-width: 1600px; }
/* Narrow pages keep the same left edge as every other page; only the content column is shorter. */
.page.narrow { max-width: 1120px; }
.page.narrow > * { max-width: 760px; }
.enter { animation: enter 0.5s var(--spring) both; }
@keyframes enter { from { opacity: 0; transform: translateY(6px); } }

.badge {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--pill);
  background: var(--blue); color: #0b1b33; font-size: 11px; font-weight: 600; line-height: 18px; text-align: center;
  font-variant-numeric: tabular-nums;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); flex: none; }
.dot.off { background: transparent; }

/* type */
.display { font-size: clamp(38px, 4.4vw, 58px); font-weight: 300; letter-spacing: -0.035em; line-height: 1.04; text-wrap: balance; }
.title { font-size: clamp(30px, 3vw, 40px); font-weight: 400; letter-spacing: -0.03em; line-height: 1.08; }
.lede { font-size: 17px; color: var(--ink-2); margin-top: 14px; max-width: 52ch; }
.label { font-size: 13px; font-weight: 500; color: var(--ink-3); }
.h { font-size: 17px; font-weight: 500; letter-spacing: -0.012em; }
.kicker { font-size: 13px; font-weight: 500; color: var(--ink-3); margin-bottom: 10px; }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 32px; flex-wrap: wrap; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 18px; border-radius: var(--pill); min-width: 0;
  font-size: 15px; font-weight: 500; white-space: nowrap; user-select: none;
  transition: transform 0.15s var(--ease), background 0.2s var(--ease), opacity 0.2s, box-shadow 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn[disabled] { opacity: 0.4; pointer-events: none; }
.btn-primary { background: var(--action); color: var(--action-ink); }
.btn-quiet { background: var(--sunk); }
.btn-ghost { color: var(--ink-2); }
.btn-danger { color: var(--red); background: var(--sunk); }
.btn-sm { height: 32px; padding: 0 13px; font-size: 13px; }
.btn-block { width: 100%; }
.icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: var(--ink-2); transition: background 0.2s, color 0.2s; }
.link { color: var(--blue-ink); font-weight: 500; }
@media (hover: hover) {
  .btn-primary:hover { opacity: 0.86; }
  .btn-quiet:hover { background: var(--press); }
  .btn-ghost:hover { background: var(--hover); color: var(--ink); }
  .btn-danger:hover { background: var(--press); }
  .icon-btn:hover { background: var(--hover); color: var(--ink); }
  .link:hover { text-decoration: underline; text-underline-offset: 3px; }
}

/* The three big actions on Home. */
.actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 40px 0 44px; }
.action {
  display: flex; align-items: center; gap: 16px; min-height: 88px; padding: 18px 22px;
  border-radius: var(--r-lg); background: var(--paper); box-shadow: var(--lift); text-align: left;
  transition: transform 0.35s var(--spring), box-shadow 0.3s var(--ease);
}
@media (hover: hover) { .action:hover { transform: translateY(-2px); } }
.action:active { transform: scale(0.985); }
.action .glyph { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--sunk); flex: none; }
.action.primary { background: var(--action); color: var(--action-ink); }
.action.primary .glyph { background: color-mix(in srgb, var(--action-ink) 16%, transparent); }
.action b { display: block; font-size: 17px; font-weight: 500; letter-spacing: -0.012em; }
.action span { display: block; font-size: 13px; opacity: 0.6; }

/* surfaces */
.panel { background: var(--paper); border-radius: var(--r-lg); box-shadow: var(--lift); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; padding: 14px 24px 4px; }
/* Header links line up with the right edge of row content below them. */
.panel-head > .btn:last-child { margin-right: -13px; }
.panel-body { padding: 4px 12px 12px; }
.empty-line { padding: 14px 12px 20px; color: var(--ink-3); }
.panel-body > .seg:only-child { margin: 0 12px 10px; }
.grid-2 { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.grid-2 > *, .split > * { min-width: 0; }

.item {
  position: relative; display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px; border-radius: var(--r-sm);
  text-align: left; transition: background 0.15s var(--ease);
}
@media (hover: hover) { a.item:hover, button.item:hover, .item.link-row:hover { background: var(--hover); } }
/* Dividers start where the text starts, like an iOS list. */
.item + .item::before, .contact + .contact::before {
  content: ''; position: absolute; top: 0; left: 50px; right: 12px; height: 1px; background: var(--hair); pointer-events: none;
}
.item:has(> .av.md, > .av.lg)::before { left: 66px; }
.item:has(> .dot + .av.sm)::before { left: 76px; }
@media (hover: hover) { a.item:hover::before, button.item:hover::before, a.item:hover + .item::before, button.item:hover + .item::before { opacity: 0; } }
.item-title { font-weight: 500; min-width: 0; overflow-wrap: anywhere; }
.item-sub { font-size: 13px; color: var(--ink-3); }
/* "Add a task" placeholder sits on the title column. */
.item > .check.add ~ .quiet { margin-left: -10px; }

/* Task completion: a strike drawn left to right, then the row folds away. */
.item[data-task] { max-height: 160px; transition: background 0.15s var(--ease), opacity 0.4s var(--spring), max-height 0.4s var(--spring), padding 0.4s var(--spring), margin 0.4s var(--spring); }
.item[data-task] .item-title {
  display: inline-block; max-width: 100%; vertical-align: top;
  background: linear-gradient(currentColor, currentColor) 0 55% / 0 1px no-repeat;
  transition: background-size 0.45s var(--spring), color 0.3s var(--ease);
}
.done .item-title { color: var(--ink-3); }
.item.done .item-title { text-decoration: none; background-size: 100% 1px; }
.item.leaving { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; margin: 0; overflow: hidden; pointer-events: none; }
.item.leaving::before, .item.leaving + .item::before { opacity: 0; }

.group-label { font-size: 13px; font-weight: 500; color: var(--ink-3); padding: 14px 12px 4px; }
.group-label.over { color: var(--red); }

/* Pulse: four numbers in one quiet strip. */
.pulse { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--paper); border-radius: var(--r-lg); box-shadow: var(--lift); margin-bottom: 20px; }
.pulse > div { padding: 24px 26px; min-width: 0; }
.pulse > div + div { box-shadow: -1px 0 0 var(--hair); }
.pulse .n { font-size: 34px; font-weight: 300; letter-spacing: -0.03em; line-height: 1.1; margin-top: 10px; font-variant-numeric: tabular-nums; }
.pulse .s { font-size: 13px; color: var(--ink-3); margin-top: 2px; }

/* Countdown: one big number, a row of days beneath it. */
.countdown { display: flex; align-items: center; gap: 24px; padding: 26px 24px 18px; }
.countdown .days { font-size: 88px; font-weight: 200; letter-spacing: -0.05em; line-height: 0.9; font-variant-numeric: tabular-nums; }
.ticks { display: grid; grid-auto-flow: column; grid-auto-columns: 2px; justify-content: start; gap: 3px; margin-top: 14px; max-width: 100%; overflow: hidden; }
.ticks i { display: block; width: 2px; height: 14px; border-radius: 1px; background: var(--hair-2); }
.ticks i.past { background: var(--ink); }
.ticks i.today { background: var(--blue); }
/* Retired meter: kept harmless in case older markup is still on screen. */
.meter { position: relative; height: 4px; border-radius: 4px; background: var(--sunk); overflow: hidden; margin-top: 14px; }
.meter i { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--ink); border-radius: 4px; transition: width 1s var(--spring); }
.countdown:has(.ticks) .meter { display: none; }
.countdown .count { display: flex; flex-direction: column; flex: none; }
@media (min-width: 761px) { .countdown .ticks { gap: 2px; } }
.countdown .count .days { margin-left: -0.05em; }

/* pills */
.stage {
  display: inline-flex; align-items: center; gap: 7px; height: 24px; padding: 0 10px; border-radius: var(--pill);
  font-size: 13px; font-weight: 500; white-space: nowrap; background: var(--sunk); color: var(--ink-2);
}
/* Three states, two accents: waiting (gray), in motion (blue), live (green). */
.st-demo, .st-onboarding { color: var(--blue-ink); background: var(--blue-soft); }
.st-live { color: var(--green); }
.st-churned { color: var(--ink-3); }
.chip {
  position: relative; display: inline-flex; align-items: center; gap: 6px; min-height: 30px; max-width: 100%; min-width: 0;
  padding: 4px 12px; border-radius: var(--pill); line-height: 1.3; overflow-wrap: anywhere;
  background: var(--sunk); font-size: 13px; font-weight: 500; color: var(--ink-2);
  transition: background 0.15s, color 0.15s;
}
.chip[aria-pressed='true'], .apps .chip[aria-pressed='true'] { background: var(--ink); color: var(--paper); }
.chip .x { position: relative; z-index: 1; display: grid; place-items: center; width: 18px; height: 18px; margin-right: -5px; border-radius: 50%; }
@media (hover: hover) {
  button.chip:hover { color: var(--ink); }
  button.chip[aria-pressed='true']:hover { color: var(--paper); }
  .chip .x:hover { background: var(--press); }
}
/* The phone's Mine toggle; desktop uses the Everyone / Mine control. */
.chip.mine-chip { display: none; }
/* On the board the toggle sits in the toolbar, styled like the other toolbar controls. */
.toolbar > .mine-chip { height: var(--h); min-height: var(--h); padding: 0 18px; background: var(--paper); box-shadow: var(--lift); color: var(--ink-2); }
.toolbar > .mine-chip[aria-pressed='true'] { background: var(--ink); color: var(--paper); box-shadow: none; }
/* Inside the stage control it reads as a separate toggle, set off by a hairline. */
.seg .mine-chip { flex: none; height: calc(var(--h) - 6px); min-height: 0; line-height: 1.5; margin-right: 9px; padding: 0 14px; background: transparent; overflow: visible; }
.seg .mine-chip::before { content: ''; position: absolute; top: 30%; bottom: 30%; right: -6px; width: 1px; background: var(--hair-2); }
.page .seg .mine-chip[aria-pressed='true'] { background: var(--ink); color: var(--paper); box-shadow: none; }
.due { font-size: 13px; color: var(--ink-3); white-space: nowrap; }
.due.today { color: var(--blue-ink); font-weight: 500; }
.due.over { color: var(--red); font-weight: 500; }

/* avatars */
/* People are circles, stores are rounded squares. */
.av {
  --s: 32px; width: var(--s); height: var(--s); flex: none; border-radius: 50%;
  display: grid; place-items: center; font-size: calc(var(--s) * 0.38); font-weight: 500; letter-spacing: -0.01em;
  color: #1b1d22; background: #dfe3ea;
}
.av.xs { --s: 24px; font-size: 11px; }
.av.sm { --s: 28px; }
.av.md { --s: 40px; border-radius: 12px; }
.av.lg { --s: 40px; font-size: 15px; border-radius: 50%; }
.av.xl { --s: 72px; border-radius: 22px; font-size: 26px; }
/* Store avatars outside the big lists: palette results, merchant picker, board cards. */
.palette-list .av, .card .row > .av { border-radius: 9px; }
.picker-list .av { border-radius: 7px; }
.t0 { background: #dbe6f8; } .t1 { background: #f4dde1; } .t2 { background: #e2e4f8; } .t3 { background: #e6efdf; }
.t4 { background: #efe6da; } .t5 { background: #dcecee; } .t6 { background: #ece1f0; } .t7 { background: #e4e6ea; }
.avs { display: flex; align-items: center; }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) {
    .av { color: var(--ink); }
    .t0 { background: #1f2a3d; } .t1 { background: #3a2328; } .t2 { background: #26283f; } .t3 { background: #24301f; }
    .t4 { background: #332b20; } .t5 { background: #1f3133; } .t6 { background: #2f2436; } .t7 { background: #26272b; }
} }
:root[data-theme='dark'] .av { color: var(--ink); }
:root[data-theme='dark'] .t0 { background: #1f2a3d; } :root[data-theme='dark'] .t1 { background: #3a2328; }
:root[data-theme='dark'] .t2 { background: #26283f; } :root[data-theme='dark'] .t3 { background: #24301f; }
:root[data-theme='dark'] .t4 { background: #332b20; } :root[data-theme='dark'] .t5 { background: #1f3133; }
:root[data-theme='dark'] .t6 { background: #2f2436; } :root[data-theme='dark'] .t7 { background: #26272b; }
.avs .av { box-shadow: 0 0 0 2px var(--paper); }
.avs .av + .av { margin-left: -4px; }

/* inputs */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.input, .select, .textarea {
  width: 100%; min-height: 46px; padding: 11px 15px; border: 0; border-radius: var(--r-md);
  background: var(--sunk); font-size: 15px; outline: none; appearance: none;
  transition: box-shadow 0.2s var(--ease), background 0.2s;
}
.textarea { resize: vertical; min-height: 120px; line-height: 1.55; }
.input:focus, .select:focus, .textarea:focus { background-color: var(--paper); box-shadow: 0 0 0 2px var(--focus-ring); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible, .quiet:focus-visible, .hero-name:focus-visible { outline: none; }
.input::placeholder, .textarea::placeholder { color: var(--ink-3); }
.select { padding-right: 38px; background-image: var(--chevron); background-repeat: no-repeat; background-position: right 15px center; cursor: pointer; }
input[type='date']::-webkit-calendar-picker-indicator { opacity: 0.35; cursor: pointer; }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.check {
  width: 22px; height: 22px; border-radius: 50%; flex: none; display: grid; place-items: center;
  box-shadow: inset 0 0 0 1.5px var(--ink-3); color: transparent;
  transition: background 0.2s var(--ease), box-shadow 0.2s, color 0.2s, transform 0.25s var(--spring);
}
@media (hover: hover) { .check:hover { box-shadow: inset 0 0 0 1.5px var(--ink-2); } }
.check[aria-checked='true'] { background: var(--ink); box-shadow: none; color: var(--paper); }
.check:active { transform: scale(0.88); }
.check.add { color: var(--ink-3); box-shadow: inset 0 0 0 1.5px var(--ink-3); }

/* Toolbar: search, segmented control and select share one height and one fill. */
.toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.search { position: relative; flex: 1 1 320px; max-width: 440px; }
.search svg { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.search .input { height: var(--h); min-height: var(--h); padding: 0 15px 0 42px; background: var(--paper); box-shadow: var(--lift); border-radius: var(--pill); }
.search .input:focus { box-shadow: 0 0 0 2px var(--focus-ring); }
.toolbar .select { height: var(--h); min-height: var(--h); padding-top: 0; padding-bottom: 0; border-radius: var(--pill); background-color: var(--paper); box-shadow: var(--lift); font-size: 15px; }
.toolbar .select:focus { box-shadow: 0 0 0 2px var(--focus-ring); }
.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: var(--pill); background: var(--sunk); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { position: relative; display: inline-flex; align-items: center; justify-content: center; height: calc(var(--h) - 6px); padding: 0 14px; border-radius: var(--pill); font-size: 13px; font-weight: 500; color: var(--ink-2); white-space: nowrap; transition: background 0.2s var(--ease), color 0.2s, box-shadow 0.2s; }
@media (hover: hover) { .seg button:hover { color: var(--ink); } }
.seg button[aria-pressed='true'] { background: var(--thumb); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08); }
.seg .n { margin-left: 5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
/* On the canvas a control sits on paper; inside a panel it sits in the sunk well. */
.toolbar .seg, .head .seg, .page > .seg { height: var(--h); background: var(--paper); box-shadow: var(--lift); }
.toolbar .seg button[aria-pressed='true'], .head .seg button[aria-pressed='true'], .page > .seg button[aria-pressed='true'] { background: var(--thumb-on-paper); box-shadow: none; }

.facts { display: grid; grid-template-columns: 128px minmax(0, 1fr); align-items: start; gap: 0 8px; padding: 0 14px 16px; }
.facts > label, .facts > .k { font-size: 13px; color: var(--ink-3); padding: 10px 10px 0; }
.quiet {
  width: 100%; min-height: 38px; padding: 7px 10px; border: 0; border-radius: var(--r-sm); background: transparent;
  font-size: 15px; outline: none; appearance: none; transition: background 0.15s, box-shadow 0.15s; text-overflow: ellipsis;
}
@media (hover: hover) { .quiet:hover:not(:focus):not(:disabled) { background: var(--hover); } }
.quiet:focus { background: var(--paper); box-shadow: 0 0 0 2px var(--focus-ring); }
.quiet::placeholder { color: var(--ink-3); }
.quiet:disabled { color: var(--ink); opacity: 1; background: transparent; -webkit-text-fill-color: var(--ink); }
select.quiet { cursor: pointer; }
/* An unset date reads like a placeholder, left aligned with the values around it. */
.quiet.set-date { display: block; text-align: left; color: var(--ink-3); font-weight: 400; }

/* table list */
.panel:has(> .list) { overflow: hidden; }
.list { width: 100%; border-collapse: separate; border-spacing: 0; --inset: 78px; }
.list th { text-align: left; font-size: 13px; font-weight: 500; color: var(--ink-3); padding: 16px 14px 10px; border-bottom: 1px solid var(--hair); white-space: nowrap; }
/* Row dividers are drawn, not bordered, so they can start at the text column. */
.list td { padding: 13px 14px; vertical-align: middle; background: linear-gradient(var(--hair), var(--hair)) 0 0 / 100% 1px no-repeat; }
.list td:first-child { background-position: var(--inset) 0; background-size: calc(100% - var(--inset)) 1px; }
.list tbody tr:first-child td { background: none; }
.list th:first-child, .list td:first-child { padding-left: 24px; }
.list th:last-child, .list td:last-child { padding-right: 24px; }
.list tbody tr { cursor: pointer; transition: background 0.15s; }
@media (hover: hover) { .list tbody tr:hover td { background-color: var(--hover); } }
.list tbody tr:last-child td:first-child { border-bottom-left-radius: var(--r-lg); }
.list tbody tr:last-child td:last-child { border-bottom-right-radius: var(--r-lg); }
.list .r { text-align: right; }
.mcell { display: flex; align-items: center; gap: 14px; min-width: 0; max-width: 360px; }

/* board */
.board { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(228px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 24px; scroll-snap-type: x proximity; }
.col { display: flex; flex-direction: column; gap: 8px; min-height: 320px; padding: 10px; border-radius: var(--r-lg); background: var(--sunk); scroll-snap-align: start; transition: background 0.2s, box-shadow 0.2s; }
.col.drop { background: var(--blue-soft); box-shadow: inset 0 0 0 1.5px var(--blue); }
.col-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 6px 8px 8px; }
.col-head b { font-weight: 500; font-size: 15px; }
.card { display: block; padding: 14px; border-radius: var(--r-md); background: var(--paper); box-shadow: var(--lift); cursor: grab; transition: transform 0.25s var(--spring), opacity 0.2s; }
.col .card { border-radius: 12px; }
@media (hover: hover) { .card:hover { transform: translateY(-1px); } }
.card.dragging { opacity: 0.35; }
.card-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 12px; font-size: 13px; color: var(--ink-3); }
.col-empty { flex: 1; display: grid; place-items: center; min-height: 80px; border-radius: 12px; border: 1.5px dashed var(--hair-2); color: var(--ink-3); font-size: 13px; }

/* merchant */
.back { display: inline-flex; align-items: center; gap: 2px; margin: -10px 0 22px -8px; padding: 6px 12px 6px 6px; border-radius: var(--pill); color: var(--ink-2); font-size: 15px; font-weight: 500; }
@media (hover: hover) { .back:hover { background: var(--hover); color: var(--ink); } }
.hero { display: flex; align-items: center; gap: 22px; margin-bottom: 28px; }
.hero-name {
  width: 100%; padding: 0 6px; margin-left: -6px; border: 0; border-radius: var(--r-sm); background: none; outline: none;
  font-size: clamp(28px, 3.4vw, 44px); font-weight: 400; letter-spacing: -0.032em; line-height: 1.15; text-overflow: ellipsis;
}
@media (hover: hover) { .hero-name:hover:not(:focus):not(:disabled) { background: var(--hover); } }
.hero-name:focus { background: var(--paper); box-shadow: 0 0 0 2px var(--focus-ring); }
.hero-name:disabled { background: none; color: var(--ink); -webkit-text-fill-color: var(--ink); opacity: 1; }
.hero-meta { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 6px; color: var(--ink-2); font-size: 15px; min-width: 0; }
.hero-meta a { min-width: 0; overflow-wrap: anywhere; }
@media (hover: hover) { .hero-meta a:hover { color: var(--ink); } }

/* Stage track: one thumb slides under the six stages. */
.track {
  position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  padding: 3px; border-radius: var(--pill); background: var(--sunk); margin-bottom: 24px;
}
.track::before {
  content: ''; position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc((100% - 6px) / 6);
  border-radius: var(--pill); background: var(--thumb); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  transition: transform 0.55s var(--spring-settle); pointer-events: none;
}
.track:not([data-i])::before { display: none; }
.track[data-i='1']::before { transform: translateX(100%); }
.track[data-i='2']::before { transform: translateX(200%); }
.track[data-i='3']::before { transform: translateX(300%); }
.track[data-i='4']::before { transform: translateX(400%); }
.track[data-i='5']::before { transform: translateX(500%); }
.track button { position: relative; z-index: 1; min-width: 0; padding: 0 8px; text-align: center; height: 38px; border-radius: var(--pill); font-size: 13px; font-weight: 500; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color 0.25s var(--ease); }
@media (hover: hover) { .track button:hover:not(:disabled) { color: var(--ink); } }
.track button:disabled { cursor: default; }
.track button.past { color: var(--ink-2); }
.track button[aria-pressed='true'] { color: var(--ink); }

.split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(320px, 1fr); gap: 20px; align-items: start; }

.composer { padding: 20px 24px 14px; transition: box-shadow 0.2s var(--ease); }
.composer:focus-within { box-shadow: var(--lift), inset 0 0 0 2px var(--focus-ring); }
.composer textarea { width: 100%; min-height: 160px; max-height: 60vh; border: 0; outline: none; resize: none; background: transparent; font-size: 17px; line-height: 1.6; }
.composer textarea:focus-visible { outline: none; }
.composer textarea::placeholder { color: var(--ink-3); }
.composer-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-top: 14px; box-shadow: 0 -1px 0 var(--hair); }
.timeline { padding: 0 24px 24px; }
.day { font-size: 13px; font-weight: 500; color: var(--ink-3); margin: 22px 0 4px; }
.note { position: relative; display: flex; gap: 14px; padding: 14px 0; }
.note + .note::before { content: ''; position: absolute; top: 0; left: 42px; right: 0; height: 1px; background: var(--hair); }
.note-meta { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-3); flex-wrap: wrap; padding-right: 72px; }
.note-meta b { color: var(--ink); font-weight: 500; }
.note-body { margin-top: 4px; font-size: 15px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.note-body a { color: var(--blue-ink); text-decoration: underline; text-underline-offset: 3px; }
.mention { color: var(--blue-ink); font-weight: 500; }
.note-tools { position: absolute; top: 8px; right: -8px; display: flex; opacity: 0; transition: opacity 0.15s; }
.note:focus-within .note-tools { opacity: 1; }
@media (hover: hover) { .note:hover .note-tools { opacity: 1; } }
@media (hover: none) { .note-tools { opacity: 1; } }
.pinned { background: var(--blue-soft); margin: 4px -12px; padding: 14px 12px; border-radius: var(--r-md); }
.pinned + .note::before, .note + .pinned::before, .pinned::before { display: none; }
.kind { font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: var(--pill); background: var(--sunk); color: var(--ink-2); }
.event { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 13px; color: var(--ink-3); }
.event::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--ink-3); margin: 0 9px 0 11px; opacity: 0.6; flex: none; }
.estimate { margin: 0 24px; padding: 4px 0 18px; }
.estimate .n { font-size: 34px; font-weight: 300; letter-spacing: -0.03em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 4px 10px; transition: box-shadow 0.15s; }
.tags:focus-within { border-radius: var(--r-sm); box-shadow: 0 0 0 2px var(--focus-ring); }
.tags input { flex: 1; min-width: 80px; height: 30px; border: 0; background: none; outline: none; font-size: 15px; }
.tags input:focus-visible { outline: none; }
.tags input::placeholder { color: var(--ink-3); }
.apps { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 10px 6px; }
/* Swipe apps take the full row under their label so five chips settle into two even rows. */
.facts > .k:has(+ .apps) { grid-column: 1 / -1; }
.facts > .apps { grid-column: 1 / -1; padding: 6px 10px 8px; }
/* Social rows share the Store column grid so their labels line up with the facts above. */
.social { display: grid; grid-template-columns: 128px minmax(0, 1fr) 36px; align-items: center; gap: 0 8px; padding: 0 14px; }
.panel > .social { padding: 0 14px 12px; }
.panel-body > .social { padding: 0 2px; }
.social label { font-size: 13px; color: var(--ink-3); padding-left: 10px; }
.quick { display: flex; gap: 8px; margin: -10px 0 24px; min-width: 0; }
.quick .btn { min-width: 0; overflow: hidden; }
.stage-compact { display: none; }
.cols-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 12px; }
.cols-2 > .item:nth-child(2)::before { display: none; }
.more-toggle { align-self: flex-start; }
.contact { position: relative; display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: var(--r-sm); }
.contact .item-title { min-width: 0; overflow-wrap: anywhere; }
.contact-lines { display: flex; flex-direction: column; min-width: 0; font-size: 13px; color: var(--ink-2); margin-top: 2px; }
.contact-lines > * { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tag-primary { font-size: 11px; font-weight: 600; color: var(--blue-ink); }

/* sheets */
.scrim { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px; background: var(--scrim); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); animation: fade 0.25s var(--ease) both; }
.scrim.top { place-items: start center; padding-top: 12vh; }
@keyframes fade { from { opacity: 0; } }
.sheet { width: min(540px, 100%); max-height: calc(100dvh - 48px); overflow: auto; background: var(--paper); border-radius: 28px; box-shadow: var(--float); animation: rise 0.5s var(--spring) both; overscroll-behavior: contain; }
.sheet.wide { width: min(680px, 100%); }
.sheet-form { display: contents; }
@keyframes rise { from { opacity: 0; transform: translateY(16px) scale(0.98); } }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 24px 22px 6px 30px; }
.sheet-head h2 { font-size: 24px; font-weight: 400; letter-spacing: -0.025em; }
.sheet-body { display: flex; flex-direction: column; gap: 16px; padding: 14px 30px 10px; }
.sheet-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 20px 30px 30px; }
.sheet-foot .left { margin-right: auto; }
.sheet .more-toggle { margin-left: -13px; }
.form-error { min-height: 1px; color: var(--red); font-size: 13px; }
.form-error:empty { margin-top: -16px; }
.options { display: grid; gap: 8px; }
.option { display: flex; gap: 14px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r-md); background: var(--sunk); cursor: pointer; transition: box-shadow 0.15s, background 0.15s; }
.option.on { box-shadow: inset 0 0 0 1.5px var(--ink); background: var(--paper); }
.option input { margin: 3px 0 0; accent-color: var(--ink); }
.option b { display: block; font-weight: 500; }
.option small { color: var(--ink-3); font-size: 13px; }
.people { display: flex; flex-wrap: wrap; gap: 8px; }
.person { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px 0 4px; border-radius: var(--pill); background: var(--sunk); font-size: 15px; font-weight: 500; transition: background 0.15s, color 0.15s; }
.person[aria-pressed='true'] { background: var(--ink); color: var(--paper); }
.quick-dates { display: flex; gap: 8px; flex-wrap: wrap; }
.quick-dates .chip { min-height: 36px; padding: 0 14px; font-size: 15px; }
.sheet-body [data-more-body] { gap: 16px; }

.picker-list { margin-top: 6px; border-radius: var(--r-md); background: var(--sunk); padding: 6px; max-height: 240px; overflow: auto; }
[data-mpicker][data-picked] .picker-list { display: none; }
.picker-list button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: var(--r-sm); text-align: left; }
.picker-list button[aria-selected='true'] { background: var(--paper); box-shadow: inset 0 0 0 1.5px var(--ink); }
@media (hover: hover) { .picker-list button:hover { background: var(--paper); } }

.popover { position: fixed; z-index: 70; min-width: 220px; max-width: calc(100vw - 32px); padding: 6px; border-radius: var(--r-md); background: var(--paper); box-shadow: var(--float); animation: rise 0.2s var(--spring) both; }
.popover button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: 8px; text-align: left; font-size: 15px; }
.popover button:focus-visible { background: var(--hover); outline: none; }
@media (hover: hover) { .popover button:hover { background: var(--hover); } }
.popover button.danger { color: var(--red); }
.popover:has(button > svg) button:not(:has(> svg)) > span { margin-left: 28px; }
.catcher { position: fixed; inset: 0; z-index: 60; }
body.locked { overflow: hidden; }

.palette { width: min(640px, 100%); border-radius: var(--r-lg); background: var(--paper); box-shadow: var(--float); overflow: hidden; animation: rise 0.35s var(--spring) both; }
.palette-in { display: flex; align-items: center; gap: 12px; padding: 0 20px; box-shadow: 0 1px 0 var(--hair); color: var(--ink-3); transition: box-shadow 0.15s; }
.palette-in:focus-within { box-shadow: inset 0 -2px 0 var(--focus-ring); }
.palette-in input { flex: 1; min-width: 0; height: 62px; border: 0; outline: none; background: none; font-size: 17px; color: var(--ink); }
.palette-in input:focus-visible { outline: none; }
.palette-list { max-height: min(440px, 60vh); overflow: auto; padding: 8px; scroll-padding: 8px; }
.palette-list .group { font-size: 13px; font-weight: 500; color: var(--ink-3); padding: 10px 12px 4px; }
.palette-list button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; border-radius: 12px; text-align: left; }
.palette-list button[aria-selected='true'] { background: var(--hover); }
.palette-list button > .grow { display: flex; align-items: baseline; gap: 6px; overflow: hidden; }
.palette-list button > .grow > .item-title { flex: none; max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-list button > .grow > .item-sub { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-list .ic { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--sunk); color: var(--ink-2); flex: none; }

.toasts { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast:has(.toast-action) { display: flex; align-items: center; gap: 14px; padding-right: 8px; }
.toast-action { pointer-events: auto; border: 0; background: color-mix(in srgb, var(--paper) 18%, transparent); color: inherit; font: inherit; font-weight: 600; padding: 6px 14px; border-radius: var(--pill); cursor: pointer; }
.toast { padding: 12px 20px; border-radius: var(--pill); background: var(--ink); color: var(--paper); font-size: 15px; font-weight: 500; box-shadow: var(--float); animation: toast 0.45s var(--spring) both; text-align: center; }
.toast.err { background: #c2342a; color: #fff; }
.toast.out { animation: toastOut 0.25s var(--ease) forwards; }
@keyframes toast { from { opacity: 0; transform: translateY(14px) scale(0.96); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px); } }

/* auth */
.auth { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 32px 20px; background: var(--paper); }
.auth-card { width: min(380px, 100%); display: flex; flex-direction: column; gap: 14px; animation: enter 0.8s var(--spring) both; }
.auth-card .logo svg { height: 30px; margin-bottom: 40px; }
.auth-card h1 { font-size: 30px; font-weight: 400; letter-spacing: -0.03em; line-height: 1.15; }
.auth-card p { color: var(--ink-2); margin-bottom: 14px; }
.auth-card .btn { height: 50px; margin-top: 6px; }
.auth-foot { margin-top: 28px; font-size: 13px; color: var(--ink-3); }
.remember { display: flex; align-items: center; gap: 10px; padding: 4px 2px; font-size: 14px; color: var(--ink-2); cursor: pointer; user-select: none; }
.remember input { width: 18px; height: 18px; margin: 0; accent-color: var(--ink); flex: none; }
.code { letter-spacing: 0.5em; text-align: center; font-size: 24px; font-variant-numeric: tabular-nums; }
.qr { width: 184px; height: 184px; padding: 12px; border-radius: 18px; background: #fff; box-shadow: var(--lift); align-self: center; }
.secret { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; letter-spacing: 0.08em; text-align: center; color: var(--ink-2); word-break: break-all; user-select: all; }

.banner { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; padding: 9px 16px; background: var(--ink); color: var(--paper); font-size: 13px; }
.banner select { height: 30px; padding: 0 12px; border: 0; border-radius: var(--pill); background: color-mix(in srgb, var(--paper) 16%, transparent); color: inherit; }
.banner button { color: inherit; text-decoration: underline; text-underline-offset: 3px; }

/* mobile */
.tabbar { display: none; }

@media (min-width: 761px) {
  .page.wide .board { margin-right: -56px; padding-right: 56px; }
}
@media (min-width: 1081px) {
  /* Desktop merchant page: the composer and notes stay in view while you work down the side. */
  .split > .stack:first-child { position: sticky; top: 24px; align-self: start; }
}
@media (max-width: 1080px) {
  .cols-2 { grid-template-columns: minmax(0, 1fr); }
  .cols-2 > .item:nth-child(2)::before { display: block; }
  .split, .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .pulse { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pulse > div:nth-child(3) { box-shadow: 0 -1px 0 var(--hair); }
  .pulse > div:nth-child(4) { box-shadow: 0 -1px 0 var(--hair), -1px 0 0 var(--hair); }
  .hide-md { display: none; }
}
@media (max-width: 760px) {
  :root { --h: 44px; }
  .shell { grid-template-columns: minmax(0, 1fr); }
  .rail { display: none; }
  .page { padding: 28px 16px calc(120px + env(safe-area-inset-bottom, 0px)); }
  .head { margin-bottom: 22px; }
  .lede { font-size: 15px; }
  .actions { gap: 8px; margin: 28px 0 32px; }
  .action { flex-direction: column; align-items: flex-start; justify-content: space-between; gap: 16px; min-height: 118px; padding: 16px; border-radius: var(--r-lg); }
  .action span { display: none; }
  .action b { font-size: 15px; line-height: 1.25; }
  .pulse > div { padding: 18px 24px; }
  .pulse .n { font-size: 28px; }
  .hide-sm { display: none; }
  .mcell { max-width: 58vw; }
  .search { max-width: none; flex-basis: 100%; }
  .hero { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 14px 16px; }
  .hero > .grow { grid-column: 1 / -1; grid-row: 2; }
  .hero > .row { justify-self: end; }
  .hero-name { font-size: 30px; }
  .hero-meta { gap: 4px 16px; }
  .hero-meta .faint:last-child { display: none; }
  .hero-meta a { min-height: 44px; display: inline-flex; align-items: center; }
  .av.xl { --s: 56px; border-radius: 18px; font-size: 24px; }
  .composer-bar .seg { flex: 1 1 auto; min-width: 0; }
  /* Phone merchant page: the next move first, then the work, then reference. */
  .split { display: flex; flex-direction: column; gap: 16px; }
  .split > .stack { display: contents; }
  .split .panel { min-width: 0; max-width: 100%; }
  #m-tasks { order: 1; } #m-composer { order: 2; } #m-timeline { order: 3; } #m-people { order: 4; } #m-store { order: 5; } #m-social { order: 6; }
  .track { display: none; }
  .stage-compact { display: flex; align-items: center; gap: 8px; margin-bottom: 20px; }
  .stage-compact .stage { height: 30px; padding: 0 12px; font-size: 13px; }
  .quick { margin: -6px 0 18px; }
  .quick .btn { flex: 1; }
  .composer textarea { min-height: 56px; transition: min-height 0.3s var(--spring); }
  .composer textarea:focus { min-height: 150px; }

  /* Touch targets: 44px or more. Where a control should look compact, an invisible hit area does the work. */
  .btn { height: 44px; }
  .btn-sm { height: 38px; min-height: 44px; }
  .icon-btn { width: 44px; height: 44px; }
  .check { position: relative; width: 26px; height: 26px; }
  .check::after { content: ''; position: absolute; inset: -10px; }
  .seg button::after { content: ''; position: absolute; inset: -3px 0; }
  .chip { min-height: 32px; }
  .chip::after { content: ''; position: absolute; inset: -6px 0; }
  .apps, .quick-dates, .tags { row-gap: 12px; }
  .chip .x { width: 24px; height: 24px; }
  .chip .x::after { content: ''; position: absolute; inset: -10px; }
  .popover button { min-height: 44px; }
  .hero-name { min-height: 44px; }
  .quick-dates .chip { min-height: 44px; }
  .picker-list { max-height: none; }
  .sheet-head { position: sticky; top: 0; z-index: 1; background: var(--paper); }
  /* The tab bar's plus opens the same three actions, so Home leads with the day instead. */
  [data-view='home'] .actions { display: none; }
  [data-view='home'] .actions + .grid-2 { margin-top: 28px; }
  .person, .picker-list button { min-height: 44px; }
  .quiet, .tags input { min-height: 44px; }
  .back { min-height: 44px; }
  .item > [data-action='edit-task'] { align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
  .facts > label, .facts > .k { padding-top: 13px; }
  .chip.mine-chip { display: inline-flex; }
  [data-view='merchants'] .toolbar > .seg { display: none; }

  /* Phone lists: no headers, no second add button (the tab bar has one). */
  .list thead { display: none; }
  .list tbody tr:first-child td:first-child { border-top-left-radius: var(--r-lg); }
  .list tbody tr:first-child td:last-child { border-top-right-radius: var(--r-lg); }
  .list td:nth-child(2) { width: 1%; padding-left: 4px; text-align: right; }
  .mcell { max-width: none; }
  [data-view='merchants'] .head .btn-primary, [data-view='tasks'] .head .btn-primary { display: none; }
  .seg, .track { -webkit-mask-image: linear-gradient(90deg, #000 86%, transparent); mask-image: linear-gradient(90deg, #000 86%, transparent); }
  .seg:has(button:last-child[aria-pressed='true']), .seg:not(:has(button:nth-child(4))) { -webkit-mask-image: none; mask-image: none; }
  .composer-bar > .grow { display: none; }
  .sheet .action { flex-direction: row; align-items: center; justify-content: flex-start; min-height: 72px; }
  .sheet .action:not(.primary) { background: var(--sunk); box-shadow: none; }
  .board { grid-auto-columns: 84%; margin: 0 -16px; padding: 0 16px 20px; scroll-snap-type: x mandatory; }
  .facts { grid-template-columns: 104px minmax(0, 1fr); padding: 0 14px 12px; }
  .social { grid-template-columns: 104px minmax(0, 1fr) 44px; }
  .two, .three { grid-template-columns: minmax(0, 1fr); }
  .scrim { padding: 0; place-items: end center; }
  .scrim.top { padding: 10px; place-items: start center; }
  .sheet { width: 100%; max-height: 94dvh; border-radius: 28px 28px 0 0; padding-bottom: env(safe-area-inset-bottom, 0px); animation: up 0.5s var(--spring) both; }
  /* Bottom sheets get a grabber. */
  .scrim:not(.top) > .sheet::before { content: ''; display: block; width: 36px; height: 5px; border-radius: 3px; background: var(--hair-2); margin: 8px auto 0; }
  @keyframes up { from { transform: translateY(100%); } }
  .sheet-head { padding: 12px 14px 4px 22px; }
  .sheet-body { padding: 12px 22px 8px; }
  .sheet-foot { padding: 14px 22px 22px; flex-wrap: wrap; }
  .sheet-foot .btn { flex: 1; height: 48px; }
  .composer { padding: 16px 18px 12px; }
  .composer textarea { min-height: 140px; }
  .timeline { padding: 0 18px 20px; }
  .note-tools { opacity: 1; }
  .countdown { flex-direction: column; align-items: flex-start; gap: 12px; padding: 24px 24px 14px; }
  .countdown .days { font-size: 64px; }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: center;
    position: fixed; z-index: 40; left: 0; right: 0; bottom: 0;
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom, 0px));
    background: color-mix(in srgb, var(--paper) 88%, transparent);
    backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px);
    box-shadow: 0 -1px 0 var(--hair);
  }
  .tabbar a, .tabbar button { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; font-size: 11px; font-weight: 500; color: var(--ink-3); }
  .tabbar [aria-current='page'] { color: var(--ink); }
  .tabbar .badge { position: absolute; top: 0; left: calc(50% + 4px); }
  .tabbar .plus { justify-self: center; width: 54px; height: 54px; padding: 0; border-radius: 50%; background: var(--action); color: var(--action-ink); display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2); }
  .toasts { bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}
.list td.est { color: var(--ink-2); }

/* Swipe sky. The CRM wears swipe.ai's colors: the sky gradient (Swipe Blue
   into lavender into blush) behind everything, white cards floating on it,
   Swipe Pink for the one action to take next, and the Swipe Blue card for
   the number that matters most. Text on the sky stays dark for reading,
   except the Home greeting, which is set in white like the site's heroes. */
:root {
  --sky: linear-gradient(180deg, #8eade9 0%, #a9b9ea 34%, #c7cbea 62%, #e2d7ea 84%, #f3e3ea 100%);
  --on-sky: #0b1b33;
  --on-sky-2: rgba(11, 27, 51, 0.68);
  --rail-glass: rgba(255, 255, 255, 0.22);
  --rail-on: rgba(255, 255, 255, 0.92);
  --pink: #eab2ba;
  --pink-hover: #e9a8b4;
  --pink-soft: rgba(234, 178, 186, 0.28);
  --lav-soft: rgba(206, 212, 255, 0.6);
  --lav-ink: #4f55b8;
  --green-key: #77985c;
  --hero: #85adee;
  --hero-ink: #0b1b33;
  --band: linear-gradient(90deg, #fbe3e6 0%, #ced4ff 100%);
  --tick: rgba(11, 27, 51, 0.16);
  --action: #eab2ba;
  --action-ink: #0b0b0d;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --sky: linear-gradient(180deg, #1b2740 0%, #1a1f36 40%, #1d1a30 72%, #261b2b 100%);
    --on-sky: #f4f4f6; --on-sky-2: rgba(244, 244, 246, 0.68);
    --rail-glass: rgba(255, 255, 255, 0.04); --rail-on: rgba(255, 255, 255, 0.1);
    --pink-soft: rgba(234, 178, 186, 0.16); --lav-soft: rgba(206, 212, 255, 0.14); --lav-ink: #c3c8ff;
    --green-key: #a5f567;
    --band: linear-gradient(90deg, rgba(234, 178, 186, 0.12) 0%, rgba(133, 173, 238, 0.16) 100%);
    --action: #eab2ba; --action-ink: #0b0b0d; --tick: rgba(255, 255, 255, 0.18);
  }
}
:root[data-theme='dark'] {
  --sky: linear-gradient(180deg, #1b2740 0%, #1a1f36 40%, #1d1a30 72%, #261b2b 100%);
  --on-sky: #f4f4f6; --on-sky-2: rgba(244, 244, 246, 0.68);
  --rail-glass: rgba(255, 255, 255, 0.04); --rail-on: rgba(255, 255, 255, 0.1);
  --pink-soft: rgba(234, 178, 186, 0.16); --lav-soft: rgba(206, 212, 255, 0.14); --lav-ink: #c3c8ff;
  --green-key: #a5f567;
  --band: linear-gradient(90deg, rgba(234, 178, 186, 0.12) 0%, rgba(133, 173, 238, 0.16) 100%);
  --action: #eab2ba; --action-ink: #0b0b0d; --tick: rgba(255, 255, 255, 0.18);
}

/* The sky sits behind the whole app and stays put while the page scrolls. */
html { min-height: 100%; background: var(--canvas) var(--sky) no-repeat; background-size: 100% max(100%, 100vh); }
body { background: transparent; }
.btn-primary:hover, .action.primary:hover { background: var(--pink-hover); opacity: 1; }

/* The rail is frosted glass over the sky, with the wordmark in white. */
.rail { background: var(--rail-glass); backdrop-filter: blur(24px) saturate(140%); -webkit-backdrop-filter: blur(24px) saturate(140%); border-right-color: rgba(255, 255, 255, 0.28); }
.rail .logo { color: #ffffff; }
.rail .nav { color: var(--on-sky-2); }
.rail .nav[aria-current='page'] { color: var(--ink); background: var(--paper); }
@media (hover: hover) { .rail .nav:hover { background: var(--rail-on); color: var(--on-sky); } .rail .nav[aria-current='page']:hover { background: var(--paper); color: var(--ink); } }
.rail-search { background: var(--rail-on); color: var(--on-sky-2); }
.rail-search kbd { color: var(--on-sky-2); }
.rail-foot { color: var(--on-sky); }

/* Page headings read on the sky. */
.page > header .kicker, .head .kicker { color: var(--on-sky-2); }
.page .title, .page > header .lede, .head .lede { color: var(--on-sky); }

/* Home greets you like the site does: big, light, white. */
.page > header.home-head .kicker { color: rgba(255, 255, 255, 0.85); }
.page > header.home-head .display { color: #ffffff; }
.page > header.home-head .lede { color: rgba(255, 255, 255, 0.92); }

.action.primary .glyph { background: rgba(255, 255, 255, 0.45); color: #0b0b0d; }
.action.tint-blue .glyph { background: var(--blue-soft); color: var(--blue-ink); }
.action.tint-lav .glyph { background: var(--lav-soft); color: var(--lav-ink); }

.pulse { overflow: hidden; }
.pulse > .key { background: var(--hero); color: var(--hero-ink); }
.pulse > .key .label, .pulse > .key .s { color: var(--hero-ink); opacity: 0.72; }
.pulse > .key + div { box-shadow: none; }
.pulse > div > .label { display: flex; align-items: center; gap: 8px; }
.pulse > div > .label::before { content: ''; width: 8px; height: 8px; border-radius: 50%; flex: none; background: currentColor; }
.pulse > .k-lav > .label::before { background: var(--lav-ink); }
.pulse > .k-pink > .label::before { background: var(--pink); }
.pulse > .k-green > .label::before { background: var(--green-key); }

.runway .countdown { background: var(--band); border-radius: var(--r-lg) var(--r-lg) 0 0; }
.runway .ticks i { background: var(--tick); }
.runway .ticks i.past { background: var(--blue); }
.runway .ticks i.today { background: #e48a9b; }
.runway .meter i { background: linear-gradient(90deg, var(--blue), var(--pink)); }
.runway .countdown + .panel-body { padding-top: 8px; }

/* Sign in floats a white card on the sky. */
.auth { background: transparent; }
.auth-card { background: var(--paper); padding: 40px 36px 32px; border-radius: 28px; box-shadow: var(--float); }
.auth-card .logo { color: var(--ink); }
.auth-card .logo svg { margin-bottom: 32px; }
.auth-foot { margin-top: 18px; }

@media (max-width: 760px) {
  .tabbar .plus { box-shadow: 0 6px 20px rgba(228, 138, 155, 0.45); }
  .auth-card { padding: 32px 24px 26px; }
}

/* Documents on a merchant. */
.doc { align-items: center; }
.doc-glyph { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--sunk); color: var(--ink-2); }
.doc-glyph.f-pdf { background: var(--pink-soft); color: #a4485a; }
.doc-glyph.f-doc { background: var(--blue-soft); color: var(--blue-ink); }
.doc-glyph.f-img { background: var(--lav-soft); color: var(--lav-ink); }
.doc .icon-btn { flex: none; }
.drop { display: grid; place-items: center; gap: 6px; padding: 26px 16px; border-radius: var(--r-md); background: var(--sunk); border: 1.5px dashed var(--hair-2); text-align: center; cursor: pointer; transition: border-color 0.2s, background 0.2s; }
.drop.over, .drop:focus-within { border-color: var(--blue); background: var(--blue-soft); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop b { font-weight: 500; }
.drop small { color: var(--ink-3); font-size: 13px; }
.kinds { display: flex; flex-wrap: wrap; gap: 8px; }
.kinds label { position: relative; }
.kinds input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.kinds span { display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border-radius: var(--pill); background: var(--sunk); font-size: 14px; font-weight: 500; color: var(--ink-2); transition: background 0.2s, color 0.2s, box-shadow 0.2s; }
.kinds input:checked + span { background: var(--paper); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.kinds input:focus-visible + span { outline: 2px solid var(--focus-ring); outline-offset: 2px; }

/* Onboarding checklist and its progress, on the merchant and on board cards. */
.meter.onboard { margin: 2px 12px 8px; }
.meter.onboard i, .card-progress .bar i { transition: width 0.6s var(--spring); background: linear-gradient(90deg, var(--blue), var(--pink)); }
.meter i.w0, .card-progress .bar i.w0 { width: 0; }
.meter i.w1, .card-progress .bar i.w1 { width: 25%; }
.meter i.w2, .card-progress .bar i.w2 { width: 50%; }
.meter i.w3, .card-progress .bar i.w3 { width: 75%; }
.meter i.w4, .card-progress .bar i.w4 { width: 100%; }
.card-progress { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 11px; color: var(--ink-3); }
.card-progress .bar { position: relative; flex: 1; height: 4px; border-radius: 4px; background: var(--sunk); overflow: hidden; }
.card-progress .bar i { position: absolute; inset: 0 auto 0 0; border-radius: 4px; }

/* Pipeline. */
.goal { background: var(--hero); color: var(--hero-ink); overflow: hidden; }
.goal-body { padding: 26px 28px 24px; display: flex; flex-direction: column; gap: 10px; }
.goal .label { color: var(--hero-ink); opacity: 0.72; }
.goal-n { font-size: clamp(36px, 4vw, 52px); font-weight: 300; letter-spacing: -0.035em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.goal-n span { font-size: 0.45em; letter-spacing: -0.01em; opacity: 0.72; }
.goal-bar { position: relative; height: 12px; border-radius: 12px; background: rgba(255, 255, 255, 0.4); overflow: hidden; margin-top: 6px; }
.goal-bar i { position: absolute; top: 0; bottom: 0; left: 0; width: 0; transition: width 1s var(--spring), left 1s var(--spring); }
.goal-bar i.live { background: #ffffff; border-radius: 12px 0 0 12px; }
.goal-bar i.pipe { background: var(--pink); }
.goal-keys { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 14px; }
.goal-keys span { display: inline-flex; align-items: center; gap: 8px; }
.goal-keys .k { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.goal-keys .k.live { background: #ffffff; }
.goal-keys .k.pipe { background: var(--pink); }
.goal-line { font-size: 14px; opacity: 0.8; }
.scroll-x { overflow-x: auto; }
.list.stats tbody tr { cursor: default; }
.list.stats th.r, .list.stats td.r { text-align: right; }
.list.stats tfoot td { padding: 13px 14px; border-top: 1px solid var(--hair); font-weight: 500; }
.list.stats tfoot td:first-child { padding-left: 24px; }
.list.stats tfoot td:last-child { padding-right: 24px; }
.grid-2.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.conv { padding: 12px; display: flex; flex-direction: column; gap: 6px; }
.conv + .conv { box-shadow: 0 -1px 0 var(--hair); }
.conv-top { display: flex; justify-content: space-between; gap: 12px; font-weight: 500; }
.conv .meter { margin-top: 2px; }
.conv .meter i { background: linear-gradient(90deg, var(--blue), var(--pink)); }
.stuck { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.stuck .chip { font-size: 12px; }
.months { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; padding: 4px 24px 22px; }
.month { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.month-bar { position: relative; width: 100%; max-width: 56px; height: 110px; border-radius: 10px; background: var(--sunk); overflow: hidden; }
.month-bar i { position: absolute; left: 0; right: 0; bottom: 0; height: 0; border-radius: 10px; background: linear-gradient(180deg, var(--blue), var(--pink)); transition: height 1s var(--spring); }
@media (max-width: 760px) {
  .grid-2.even { grid-template-columns: minmax(0, 1fr); }
  .goal-body { padding: 22px 20px 20px; }
  .months { gap: 6px; padding: 4px 14px 18px; }
  .month-bar { height: 80px; }
  .list.stats th, .list.stats td { padding-left: 10px; padding-right: 10px; }
}

/* Goal and playbooks sheet; import sheet. */
.odds { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.odds label { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.odds small { font-size: 12px; color: var(--ink-3); }
.pct { position: relative; display: block; }
.pct .input { padding-right: 28px; width: 100%; }
.pct i { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-style: normal; color: var(--ink-3); pointer-events: none; }
.pb { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: var(--r-md); background: var(--sunk); }
.pb-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pb-list { display: flex; flex-direction: column; gap: 8px; }
.pb-row { display: grid; grid-template-columns: minmax(0, 1fr) 96px 36px; gap: 8px; align-items: center; }
.pb-row .input { background: var(--paper); }
.pb-days { position: relative; display: block; }
.pb-days .input { width: 100%; padding-right: 44px; }
.pb-days span { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: 12px; color: var(--ink-3); pointer-events: none; }
.imp-cols { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin-top: 8px; }
.imp-col { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 10px; border-radius: var(--r-sm); background: var(--sunk); }
.imp-col > span { font-size: 13px; font-weight: 500; }
.imp-col .select { width: 100%; }
.over { color: var(--red); }
@media (max-width: 760px) {
  .odds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pb-row { grid-template-columns: minmax(0, 1fr) 84px 36px; }
}

/* Connect Claude: consent page and the You page panel. */
.connect { max-width: 560px; margin: 4vh auto 0; }
.connect-body { padding: 34px 32px 28px; display: flex; flex-direction: column; gap: 16px; }
.connect-mark { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: var(--hero); color: var(--hero-ink); }
.connect-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.connect-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-2); }
.connect-list svg { margin-top: 2px; color: var(--blue-ink); }
.connect-actions { justify-content: flex-end; gap: 10px; margin-top: 4px; }
.claude-body { display: flex; flex-direction: column; gap: 12px; padding: 0 24px 18px; }
.claude-body .item { padding-left: 0; padding-right: 0; }
.copy-row { display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 14px; border-radius: var(--r-sm); background: var(--sunk); min-width: 0; }
.copy-row code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; font-size: 13px; }
@media (max-width: 760px) { .connect-body { padding: 26px 22px 22px; } }

.goal-link { align-self: flex-start; background: rgba(255, 255, 255, 0.5); color: var(--hero-ink); }

/* Deal terms: each merchant's own opt in, price, claims and share. */
.terms .term { display: flex; align-items: center; gap: 10px; min-width: 0; }
.terms .term input { flex: 1 1 auto; min-width: 0; }
.terms .term .small { flex: none; padding-right: 10px; }
.terms > .k:has(+ .price-row) { grid-column: 1 / -1; }
.price-row { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; padding: 6px 10px 2px; min-width: 0; flex-wrap: wrap; }
.price-row .price-in { flex: 1 1 90px; min-width: 0; }
.seg-sm { --h: 34px; }
.seg-sm button { padding: 0 12px; }
.deal { margin: 0 24px 20px; padding: 14px 16px; border-radius: var(--r-sm); background: var(--sunk); display: grid; gap: 8px; }
.deal p { margin: 0; }
.deal-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--ink-2); }
.deal-row b { font-weight: 500; color: var(--ink); }
.deal-row.swipe { padding-top: 8px; border-top: 1px solid var(--hair); }
.deal-row.swipe b { color: var(--blue-ink); font-size: 17px; }
.deal-row.merchant b { color: var(--green); }
