/* Cocombee Mail shared stylesheet: tokens, shell and shared components (DESIGN.md 3, 5, 6, 7, 9, 12, 15). */

:root {
  --brand: #52A49B;
  --primary: #1E6F67;
  --primary-hover: #17564F;
  --selected: #E6F3F1;
  --ink: #182A28;
  --ink-2: #3D4F4C;
  --muted: #566764;
  --help: #647471;
  --faint: #7A8B88;
  --page: #F5F7F7;
  --side: #FAFBFB;
  --surface: #FFFFFF;
  --line: #E2E8E7;
  --line-2: #EDF1F0;
  --line-3: #F1F4F4;
  --field: #D9E1DF;
  --seg: #EAEFEE;
  --email-backdrop: #EEF5F4;
  --email-text: #1F3330;
  --hover: #F0F2EF;
  --row-hover: #F6F9F8;
  --chip: #EEF2F1;
  --danger: #B91C1C;
  --danger-line: #F0CACA;
  /* Audyt destructive: red buttons and the Close circle. */
  --destructive: #ED5565;
  --alert: #DA4453;
  --ease: cubic-bezier(.65, 0, .35, 1);
  --ease-out: cubic-bezier(.33, 1, .68, 1);
  --glide: 280ms;
  --font: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: Poppins, Inter, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --pad-x: 44px;
  /* Card inset: 20 on all four sides, 16 on phones (DESIGN 5). Every card's padding uses it. */
  --card-pad: 20px;
  /* Between cards, across and down alike (owner, 3 Nov 2026). The page head keeps the 24 section gap. */
  --card-gap: 16px;
  /* Notices (amber notes and the draft / unsaved bars): one padding, one height, one colour pair.
     A notice with a button keeps it on the right; one without still matches that height. */
  --note-pad: 14px 20px;
  --note-min-h: 64px;
  --warn-bg: #FDF1DC;
  --warn-fg: #B45309;
  --card-title: 600 var(--fs-body)/20px var(--font);
  /* Chart series (owner, 3 Nov 2026; Audyt's method): every chart takes them in this order: the system teal, red, blue,
     purple, orange, then pink and sky. No yellow. Fills for bars, rings, columns and lines, never text. */
  --s1: var(--primary);
  --s2: #ED5565;
  --s3: #3D7EBF;
  --s4: #AC92EC;
  --s5: #F0883E;
  --s6: #EC87C0;
  --s7: #4FC1E9; --s8: #48CFAD; --s9: #FC6E51;
  /* Corner sizes: five only (owner, 31 Oct 2026). Every corner uses one of these. */
  --r-round: 999px;    /* fully round: buttons, chips, pills, search, tabs (circles use 50%) */
  --r-field: 5px;      /* text fields and small marks */
  --r-icon: 8px;       /* small icon buttons, swatches, small chips */
  --r-card: 13px;      /* cards, dialogs, menus, rows, dropdowns */
  --r-tile: 12px;      /* large icon tiles, thumbnails, date tiles, popovers */
  /* Type scale (DESIGN 13a): the only sizes in the app. */
  --fs-label: 10px;    /* labels and status badges */
  --fs-small: 11px;    /* labels only: stat and field labels, chart axes and legends, nav section headings, counts */
  --fs-sub: 12px;     /* secondary: the faded lower line of a text group (email under a name, list under a campaign), meta, helper and lead text */
  --fs-body: 13px;     /* menu and body: nav, tabs, buttons, fields, table text and headers, row and card titles and meta, helper text, links */
  --fs-section: 15px;  /* section and dialog titles */
  --fs-value: 20px;    /* stat, chart headline and second-row numbers */
  /* Headline figures at their approved board sizes (owner, 31 Oct 2026); phones use the smaller step below. */
  --fs-figure: 28px;   /* headline figures of top stat cards: Home key numbers, Report rings, Audience counts (one size, owner 3 Nov 2026) */
  --fs-title: 30px;    /* page title (20 on phones) */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font: 400 var(--fs-body)/1.5 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); }
a:hover { color: var(--primary-hover); }
button, input, select, textarea { font: inherit; color: inherit; }
img, svg { display: block; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.cm-num { font-family: var(--display); font-variant-numeric: tabular-nums; }
.cm-skip { position: absolute; left: 8px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: var(--r-card); background: var(--primary); color: #fff; text-decoration: none; font-weight: 600; }
.cm-skip:focus { top: 8px; color: #fff; }
.cm-skip:hover { color: #fff; }
.cm-live-region { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cm-sr { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Brand mark ---------- */
.cm-mark { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--brand); display: grid; place-items: center; }
.cm-mark { overflow: hidden; }
.cm-mark > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cb-mark { display: block; width: 64%; height: 64%; background: #fff; -webkit-mask: url(../img/cocombee-mark.png) center / contain no-repeat; mask: url(../img/cocombee-mark.png) center / contain no-repeat; }
.cm-word { display: inline-flex; align-items: center; gap: 8px; font: 600 var(--fs-section) var(--display); color: var(--ink); letter-spacing: -.01em; white-space: nowrap; }
.cm-mail-chip { font: 600 var(--fs-small) var(--font); color: var(--primary); background: var(--selected); padding: 3px 8px; border-radius: var(--r-round); letter-spacing: 0; }
.cm-logo-in { display: inline-flex; align-items: center; gap: 10px; }

/* ---------- Shell ---------- */
.cm-root { min-height: 100vh; display: flex; align-items: stretch; background: var(--page); }
.cm-side { position: sticky; top: 0; align-self: flex-start; height: 100vh; flex: 0 0 248px; width: 248px; display: flex; flex-direction: column; gap: 24px; padding: 28px 16px 22px; background: var(--side); border-right: 1px solid var(--line); overflow: hidden auto; scrollbar-width: none; z-index: 20; transition: flex-basis var(--glide) var(--ease), width var(--glide) var(--ease); }
.cm-side::-webkit-scrollbar { display: none; }
.cm-brand-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex: none; }
.cm-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; padding-left: 2px; min-width: 0; }
.cm-collapse { width: 32px; height: 32px; flex: none; border: 0; border-radius: var(--r-icon); background: transparent; color: var(--muted); cursor: pointer; display: grid; place-items: center; transition: background 200ms var(--ease); }
.cm-collapse:hover { background: var(--hover); color: var(--ink); }
/* The phone tab bar's gliding pill: created on phone widths, out of the layout everywhere else. */
.cm-thl { display: none; }
.cm-side-sep { height: 1px; background: var(--line); margin: -8px 4px; flex: none; }
.cm-side-foot { margin-top: auto; margin-bottom: -14px; display: flex; flex-direction: column; gap: 8px; }
.cm-side-foot .cm-side-sep { margin: 0 4px; }
.cm-phone-icons { display: none; }

.cm-nav { display: flex; flex-direction: column; gap: 4px; }
.cm-nav a { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 12px; border-radius: var(--r-card); color: var(--ink-2); text-decoration: none; font-size: var(--fs-body); font-weight: 400; white-space: nowrap; transition: background var(--glide) var(--ease), color var(--glide) var(--ease); }
.cm-nav a svg { flex: none; }
.cm-nav a:hover { color: var(--ink); }
.cm-nav a.on, .cm-nav a.on:hover { background: var(--primary); color: #fff; font-weight: 600; }
.cm-hl-ready .cm-nav a.on { background: transparent; }
.cm-nav-main .cm-set-tab { display: none; }
.cm-lbl { display: inline-block; overflow: hidden; white-space: nowrap; max-width: 220px; opacity: 1; transition: max-width var(--glide) var(--ease), opacity var(--glide) var(--ease); }
.cm-nb { margin-left: auto; flex: none; height: 20px; min-width: 20px; padding: 0 6px; border-radius: var(--r-card); background: var(--primary); color: #fff; font: 600 var(--fs-small)/20px var(--font); text-align: center; transition: background var(--glide) var(--ease), color var(--glide) var(--ease); }
.cm-nav a.on .cm-nb { background: #fff; color: var(--ink); }
.cm-nsec { display: block; overflow: hidden; max-height: 40px; padding: 14px 13px 1px; font-size: var(--fs-small); font-weight: 500; color: var(--faint); white-space: nowrap; transition: opacity var(--glide) var(--ease), max-height var(--glide) var(--ease), padding var(--glide) var(--ease); }
.cm-nsec.first { padding-top: 2px; }
.cm-nsep { display: block; height: 1px; background: var(--line); margin: 10px 4px 0; transition: margin var(--glide) var(--ease); }
.cm-nhl { position: absolute; left: 0; top: 0; width: 0; height: 0; border-radius: var(--r-card); background: var(--primary); pointer-events: none; z-index: 0; opacity: 0; }
.cm-hl-ready .cm-nhl { opacity: 1; }

/* Rail: 76 px, icons keep their place (12 px inner padding in both states). */
.cm-rail .cm-side { flex-basis: 76px; width: 76px; }
.cm-rail .cm-lbl { max-width: 0; opacity: 0; }
.cm-rail .cm-nav a { width: 44px; gap: 0; }
.cm-rail .cm-nsec { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; }
.cm-rail .cm-nsep { margin-left: 10px; margin-right: 10px; }
.cm-rail .cm-nb { position: absolute; top: 3px; right: 2px; height: 16px; min-width: 16px; padding: 0 4px; border-radius: var(--r-icon); font-size: var(--fs-label); line-height: 16px; }
.cm-rail .cm-brand-row { flex-direction: column; align-items: flex-start; gap: 12px; padding-left: 2px; }
.cm-rail .cm-logo { padding-left: 0; }
.cm-mid .cm-collapse { display: none; }

/* Top padding + the bar's 4 above the search = the 28 from the search down to the page title (bar's 4 + the wrap's 24). */
.cm-main { flex: 1 1 0; min-width: 0; padding: 24px var(--pad-x) 56px; outline: 0; }
.cm-wrap { max-width: 1180px; margin: 0 auto; display: flex; flex-direction: column; gap: 24px; container: cmwrap / inline-size; }
.cm-page { display: flex; flex-direction: column; gap: var(--card-gap); min-width: 0; }
.cm-page > .cm-head { margin-bottom: calc(24px - var(--card-gap)); }

/* Top bar */
.tb { display: flex; align-items: center; gap: 20px; min-height: 52px; }
.tb-date { font-size: var(--fs-sub); color: var(--muted); white-space: nowrap; }
.tb-crumbs { display: flex; align-items: center; gap: 6px; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tb-crumbs a { color: var(--muted); text-decoration: none; }
.tb-crumbs a:hover { color: var(--primary); }
.tb-search { position: relative; flex: 0 1 420px; min-width: 0; margin-left: auto; }
.tb-search input { width: 100%; height: 44px; padding: 0 20px 0 48px; border: 1px solid var(--line); border-radius: var(--r-round); background: #fff; font: 400 var(--fs-body) var(--font); color: var(--ink); outline: 0; transition: border-color 200ms var(--ease), box-shadow 200ms var(--ease); }
.tb-search input::placeholder { color: var(--faint); }
.tb-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--selected); }
.tb-search svg { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--muted); }
.tb-bell { position: relative; flex: none; width: 40px; height: 40px; border: 0; border-radius: 50%; background: transparent; color: var(--ink); cursor: pointer; display: grid; place-items: center; transition: background 200ms var(--ease); }
.tb-bell:hover, .tb-bell[aria-expanded="true"] { background: rgba(30, 111, 103, .12); }
.tb-count { position: absolute; top: 3px; left: 30px; transform: translateX(-50%); height: 20px; min-width: 20px; padding: 0 6px; border-radius: var(--r-card); background: var(--alert); color: #fff; font: 600 var(--fs-small)/20px var(--font); text-align: center; }
.tb-av { flex: none; width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--primary); color: #fff; font: 600 var(--fs-body) var(--display); cursor: pointer; display: grid; place-items: center; }
.tb > .tb-av { margin-left: 4px; }

/* Popovers from the top bar */
.tb-pop { position: fixed; z-index: 61; background: #fff; border: 1px solid var(--line); border-radius: var(--r-tile); box-shadow: 0 18px 44px -18px rgba(19, 35, 29, .35); }
.tb-notif { padding: 8px; transform-origin: top; }
.tb-menu { padding: 4px; animation: cmFade var(--glide) var(--ease) both; }
.tb-hits { padding: 4px; max-height: 360px; overflow-y: auto; scrollbar-width: none; border-radius: var(--r-card); animation: cmFade 200ms var(--ease) both; }
.tb-hits::-webkit-scrollbar { display: none; }
.tb-grow { animation: tbGrow var(--glide) var(--ease) both; }
@keyframes tbGrow { from { opacity: 0; clip-path: inset(0 0 100% 0 round 14px); } to { opacity: 1; clip-path: inset(0 0 0 0 round 14px); } }
.tb-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 14px 12px 8px; font: 500 var(--fs-section) var(--font); color: var(--ink); }
.tb-h button { border: 0; background: none; padding: 4px 0; font: 500 var(--fs-body) var(--font); color: var(--primary); cursor: pointer; }
.tb-h button:hover { color: var(--primary-hover); }
.tb-tabs { position: relative; display: flex; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); }
.tb-tabs::-webkit-scrollbar { display: none; }
.tb-tabs button { flex: none; display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border: 0; background: none; cursor: pointer; font: 400 var(--fs-body) var(--font); color: var(--muted); transition: color var(--glide) var(--ease); }
.tb-tabs button[aria-selected="true"] { font-weight: 600; color: var(--ink); }
.tb-chip { height: 20px; min-width: 20px; padding: 0 6px; border-radius: var(--r-field); background: var(--chip); font: 600 var(--fs-small)/20px var(--font); text-align: center; color: var(--muted); }
.tb-tabs button[aria-selected="true"] .tb-chip { color: var(--ink); }
.tb-line { position: absolute; left: 0; bottom: -1px; height: 2px; width: 0; border-radius: var(--r-field); background: var(--primary); }
.tb-rowsbox { position: relative; margin-top: 4px; overflow: hidden; transition: height var(--glide) var(--ease); }
.tb-rows { display: flex; flex-direction: column; gap: 4px; }
.tb-prev { position: absolute; left: 0; right: 0; top: 0; pointer-events: none; }
.tb-rowsbox.scroll { overflow-y: auto; scrollbar-width: thin; }
.tb-row { position: relative; flex: none; display: flex; align-items: center; gap: 12px; height: 60px; margin: 0; padding: 0 12px; color: var(--ink); text-decoration: none; transition: background 200ms var(--ease); }
.tb-row svg { flex: none; }
.tb-row:hover { color: var(--ink); background: #F3F6F5; }
.tb-row.unread { background: rgba(30, 111, 103, .10); }
.tb-row.unread:hover { background: rgba(30, 111, 103, .15); }
.tb-row-main { flex: 1; min-width: 0; }
.tb-row.sep::after { content: ""; position: absolute; left: 20px; right: 20px; bottom: -2px; height: 1px; background: var(--line-2); }
.tb-rt { display: flex; align-items: baseline; gap: 12px; }
.tb-title { flex: 1; min-width: 0; font-size: var(--fs-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-when, .tb-detail { font-size: var(--fs-sub); color: var(--help); white-space: nowrap; }
.tb-detail { display: block; overflow: hidden; text-overflow: ellipsis; margin-top: 3px; }
.tb-none { margin: 0; padding: 20px 12px; font-size: var(--fs-body); color: var(--help); }
.tb-more { display: block; width: 100%; height: 44px; margin-top: 2px; border: 0; border-radius: var(--r-card); background: none; font: 500 var(--fs-body) var(--font); color: var(--primary); cursor: pointer; transition: background 200ms var(--ease); }
.tb-more:hover { background: var(--primary); color: #fff; }
.tb-in-r1 { animation: tbInR1 var(--glide) var(--ease) both; } .tb-in-r2 { animation: tbInR2 var(--glide) var(--ease) both; }
.tb-in-l1 { animation: tbInL1 var(--glide) var(--ease) both; } .tb-in-l2 { animation: tbInL2 var(--glide) var(--ease) both; }
@keyframes tbInR1 { from { transform: translateX(100%); } to { transform: none; } } @keyframes tbInR2 { from { transform: translateX(100%); } to { transform: none; } }
@keyframes tbInL1 { from { transform: translateX(-100%); } to { transform: none; } } @keyframes tbInL2 { from { transform: translateX(-100%); } to { transform: none; } }
.tb-out-l1 { animation: tbOutL1 var(--glide) var(--ease) both; } .tb-out-l2 { animation: tbOutL2 var(--glide) var(--ease) both; }
.tb-out-r1 { animation: tbOutR1 var(--glide) var(--ease) both; } .tb-out-r2 { animation: tbOutR2 var(--glide) var(--ease) both; }
@keyframes tbOutL1 { to { transform: translateX(-100%); } } @keyframes tbOutL2 { to { transform: translateX(-100%); } } @keyframes tbOutR1 { to { transform: translateX(100%); } } @keyframes tbOutR2 { to { transform: translateX(100%); } }
.tb-mi { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 12px; border: 0; border-radius: var(--r-card); background: none; font: 400 var(--fs-body) var(--font); color: var(--muted); text-decoration: none; cursor: pointer; text-align: left; transition: background 200ms var(--ease); }
.tb-mi:hover, .tb-mi:focus-visible { background: var(--hover); color: var(--ink); outline: 0; }
.tb-me-head { display: flex; align-items: center; gap: 12px; padding: 12px; }
.tb-me-head .tb-av { cursor: default; }
.tb-me-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tb-me-name { font-size: var(--fs-body); font-weight: 500; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tb-me-via { font-size: var(--fs-sub); color: var(--help); }
.tb-me-sep { height: 1px; background: var(--line-2); margin: 4px; }
.tb-hit { display: flex; align-items: center; gap: 20px; min-height: 52px; padding: 6px 12px; border-radius: var(--r-card); color: var(--ink); text-decoration: none; transition: background 200ms var(--ease); }
.tb-hit:hover, .tb-hit:focus-visible { background: var(--hover); color: var(--ink); outline: 0; }
/* The row Enter opens wears the selected tint (Audyt committed option). */
.tb-hit.is-active { background: var(--selected); color: var(--ink); }
.tb-hit.is-active:hover { background: rgba(30, 111, 103, .15); }
.tb-hit-m { flex: 1; min-width: 0; }
.tb-hit-t { display: block; font-size: var(--fs-body); line-height: 1.35; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-hit-d { display: block; margin-top: 2px; font-size: var(--fs-sub); line-height: 1.3; color: var(--help); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-kind { flex: none; margin-left: auto; padding: 2px 6px; border: 1px solid var(--line); border-radius: var(--r-field); background: var(--page); font-size: var(--fs-small); color: var(--help); }

/* Select menus (Audyt): the list of a .sel select. Corner = tile minus the 4px inset. */
.sel-pop { z-index: 72; width: max-content; padding: 4px; overflow-y: auto; scrollbar-width: none; animation: cmFade 200ms var(--ease) both; }
.sel-pop::-webkit-scrollbar { display: none; }
.sel-opt { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: var(--r-icon); font: 400 var(--fs-body)/1.35 var(--font); color: var(--ink); white-space: nowrap; cursor: pointer; transition: background 120ms var(--ease); }
.sel-opt.in { padding-left: 28px; }
.sel-opt.is-active { background: var(--hover); }
.sel-opt[aria-selected="true"] { background: var(--selected); }
.sel-opt[aria-selected="true"].is-active { background: rgba(30, 111, 103, .15); }
.sel-opt[aria-disabled="true"] { color: var(--help); cursor: default; background: none; }
/* Action menus (row More) use the same options, with the icon on the left; links and buttons lose their own chrome. */
a.sel-opt, button.sel-opt { gap: 10px; width: 100%; border: 0; background-color: transparent; text-align: left; text-decoration: none; }
.sel-opt > svg { flex: none; }
.sel-opt.danger { color: var(--danger); }
button.sel-opt:disabled { color: var(--help); cursor: default; }
.sel-grp { padding: 10px 12px 4px; font: 500 var(--fs-small) var(--font); color: var(--help); }
.sel select[aria-expanded="true"] { border-color: var(--primary); }
.tb-nohit { margin: 0; padding: 12px; font-size: var(--fs-body); color: var(--help); }

/* ---------- Page header ---------- */
/* One green principal action shares the title row and top-aligns with the title (as Audyt); every other control sits
   on the toolbar row under the head (.cm-tools), owner 3 Nov 2026. */
.cm-head { display: flex; flex-wrap: nowrap; align-items: flex-start; justify-content: space-between; gap: 16px 20px; }
.cm-head-t { display: flex; flex-direction: column; gap: 6px; min-width: 0; flex: 1 1 auto; }
/* At every width the green action keeps its place on the right of the title; the title wraps, and the description
   stops at two lines with an ellipsis (owner, 3 Nov 2026). */
.cm-head > .cm-actions { flex: none; flex-wrap: nowrap; }
.cm-head > .cm-head-t > .cm-lead, .rp-head .rp-meta { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
.cm-h1 { margin: 0; font: 600 var(--fs-title)/1.2 var(--display); letter-spacing: -.01em; color: var(--ink); }
.cm-lead { margin: 0; font-size: var(--fs-sub); color: var(--muted); }
.cm-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.cm-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; min-width: 0; }
.cm-tools > .cm-sp { flex: 1 1 auto; }

/* ---------- Cards ---------- */
.cm-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); }
.cm-card-pad { padding: var(--card-pad); }
.cm-card-h { margin: 0; }
/* Card title (owner, 3 Nov 2026): one token for every card's title, semibold; no card title sets its own font. */
.cm-card-h, .stat-l, .rv-title, .pl-head h2, .hm-chart-t h2 { font: var(--card-title); color: var(--muted); }
.cm-card-link { font-size: var(--fs-body); font-weight: 400; text-decoration: none; white-space: nowrap; }
[data-count] { font-variant-numeric: tabular-nums; }
.cm-row { transition: background var(--glide) var(--ease); }
.cm-row:hover { background: var(--row-hover); }
.cm-empty { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 18px 0 6px; font-size: var(--fs-body); color: var(--ink-2); }
.cm-empty b { font-weight: 500; color: var(--ink); }
.cm-help { font-size: var(--fs-sub); line-height: 1.5; color: var(--help); font-weight: 400; }
.cm-label { font-size: var(--fs-body); font-weight: 500; color: var(--muted); }
.cm-code { font: 400 var(--fs-body)/1.6 var(--mono); }

/* ---------- Stat tiles (DESIGN 13a) ----------
   .stat-cells: one combined card of cells divided by short centred lines (42 px, never touching the
   card edges). Use it while all cells fit one row; set --cols, and a cell may span leftover tracks.
   .stat-grid + .stat-card: when cells don't fit one row, each cell is its own card on a balanced grid
   (gap 20, min 220). Below ~480 px, .stat-sec details (icon tile, helper line) hide to keep two per row.
   .stat-cell content: .stat-top (label .stat-l + change chip .stat-chip), .stat-v number, then spark/meter.
   .stat-ic: icon variant, a 42 px primary tile (.stat-ic-tile, filled white 22 px glyph) 12 px from the text. */
.stat-cells { --cols: 4; display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); overflow: hidden; }
.stat-cells.alt { background: var(--side); }
.stat-cell { position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 20px; margin: 0 -1px -1px 0; }
.stat-cells > .stat-cell::after, .stat-cells > .stat-ic::after { content: ""; position: absolute; right: 0; top: 20px; bottom: 20px; width: 1px; background: var(--line); }
.stat-cells > .stat-cell::before, .stat-cells > .stat-ic::before { content: ""; position: absolute; left: 20px; right: 20px; bottom: 0; height: 1px; background: var(--line); }
.stat-cells + .stat-cells { border-top: 1px solid var(--line-2); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--card-gap); }
.stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); }
.stat-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.stat-v { font: 600 var(--fs-value)/1.25 var(--display); font-variant-numeric: tabular-nums; color: var(--ink); white-space: nowrap; }
.stat-v.sm { font-size: var(--fs-value); }
.stat-chip { font: 500 var(--fs-label) var(--display); font-variant-numeric: tabular-nums; padding: 2px 8px; border-radius: var(--r-round); white-space: nowrap; }
.stat-spark { width: 100%; height: 34px; margin-top: 4px; }
/* Meters (owner, 3 Nov 2026): every bar that shows a share uses Home's Sending-now bar token, a `primary` pill on
   the `seg` track, growing from the left as it appears (bars grow 600 ms). Its number is written beside it, never
   inside; amber for a warning, grey for a pause; a send still going adds the moving stripes (.cm-progress). */
.stat-meter, .rp-meter, .au-bar, .hm-track { display: block; height: 8px; border-radius: var(--r-round); background: var(--seg); overflow: hidden; }
.stat-meter > span, .rp-meter > span, .au-bar > span, .hm-fill { display: block; height: 100%; border-radius: var(--r-round); background-color: var(--primary); transform-origin: left; animation: cmMeter 600ms var(--ease-out) 150ms both; transition: width 600ms var(--ease-out); }
.stat-meter > span.warn { background-color: #D97706; }
/* Count token beside or over a progress bar: the count large, "of N sent" small (Report sending card, Home Sending now). */
.cm-progn { font-size: var(--fs-body); color: var(--muted); }
.cm-progn b { font: 600 var(--fs-value) var(--display); color: var(--ink); }
.rp-meter > span.paused, .hm-fill.paused { background-color: #9DACA9; }
.stat-ic { position: relative; display: flex; align-items: center; gap: 12px; min-width: 0; padding: 20px; margin: 0 -1px -1px 0; }
.stat-ic-tile { width: 42px; height: 42px; flex: none; border-radius: var(--r-card); background: var(--primary); color: #fff; display: grid; place-items: center; }
.stat-ic-tile svg { width: 22px; height: 22px; fill: currentColor; stroke: none; }
.stat-ic-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stat-ic .stat-v { font-size: var(--fs-value); }
@media (max-width: 559px) { :root { --fs-figure: 22px; } .stat-cell { padding: 14px 14px 12px; } .stat-v { font-size: var(--fs-value); } }
@container cmwrap (max-width: 480px) { .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .stat-sec { display: none !important; } }

/* ---------- Buttons (DESIGN 15a): 600 13.5, 44 page actions, 36 row actions, no press scale ---------- */
.cm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px; border: 1px solid var(--field); border-radius: var(--r-round); background: #fff; color: var(--ink); font: 400 var(--fs-body)/1 var(--font); text-decoration: none; cursor: pointer; white-space: nowrap; transition: background 200ms var(--ease), border-color 200ms var(--ease), color 200ms var(--ease); }
.cm-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.cm-btn:focus:not(:focus-visible) { outline: none; }
.cm-btn.pri { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.cm-btn.pri:hover { background: var(--primary-hover); border-color: var(--primary-hover); color: #fff; }
.cm-btn.ghost { background: transparent; border-color: transparent; color: var(--primary); }
.cm-btn.ghost:hover { background: var(--primary); color: #fff; }
/* Red buttons (Audyt destructive): filled, white label, a 4% black overlay on hover and 8% when pressed. */
.cm-btn.danger, .rv-btn.danger { background: var(--destructive); border-color: var(--destructive); color: #fff; font-weight: 600; }
.cm-btn.danger:hover, .rv-btn.danger:hover { background: linear-gradient(rgba(0, 0, 0, .04), rgba(0, 0, 0, .04)), var(--destructive); border-color: var(--destructive); color: #fff; }
.cm-btn.danger:active, .rv-btn.danger:active { background: linear-gradient(rgba(0, 0, 0, .08), rgba(0, 0, 0, .08)), var(--destructive); }
.cm-btn.sm { height: 36px; padding: 0 16px; }
.cm-btn:disabled, .cm-btn[aria-disabled="true"] { opacity: .45; cursor: default; pointer-events: none; }
.rv-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: var(--r-round); border: 1px solid var(--field); background: #fff; color: var(--ink); font: 400 var(--fs-body)/1 var(--font); white-space: nowrap; cursor: pointer; text-decoration: none; transition: background 200ms var(--ease), border-color 200ms var(--ease), color 200ms var(--ease); }
.rv-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.rv-btn.pri { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.rv-btn.pri:hover { background: var(--primary-hover); border-color: var(--primary-hover); color: #fff; }
.rv-btn.ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.rv-btn.ghost:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.rv-btn.icon { width: 36px; padding: 0; }
.rv-btn:disabled, .rv-btn[aria-disabled="true"] { opacity: .45; cursor: default; pointer-events: none; }
/* One row-button token: icon buttons and short text row actions share the same bordered container. */
.ic-btn { width: 32px; height: 32px; flex: none; border: 1px solid var(--line); border-radius: var(--r-icon); background: var(--surface); color: var(--ink-2); cursor: pointer; display: inline-grid; place-items: center; text-decoration: none; font: 400 var(--fs-body) var(--font); white-space: nowrap; transition: background 200ms var(--ease), border-color 200ms var(--ease), color 200ms var(--ease); }
/* Hover: the real green with white text; red actions turn Audyt red. */
.ic-btn:hover, .ic-btn[aria-expanded="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }
.ic-btn.del:hover { background: var(--destructive); border-color: var(--destructive); color: #fff; }
.ic-btn.txt { width: auto; padding: 0 12px; }
.ic-btn:disabled { opacity: .45; cursor: default; }
.cm-link-btn { border: 0; background: none; padding: 0; font: inherit; color: var(--primary); text-decoration: underline; cursor: pointer; }

/* ---------- Tabs: grey band with a white pill that glides only when the selection changes ---------- */
.cm-tabs { position: relative; display: flex; flex-wrap: nowrap; gap: 2px; padding: 4px; background: var(--seg); border-radius: var(--r-round); overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; flex: 0 1 auto; min-width: 0; max-width: 100%; align-self: flex-start; }
.cm-tabs::-webkit-scrollbar { display: none; }
.cm-tabs > [role="tab"] { position: relative; z-index: 1; flex: none; display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 16px; border: 0; border-radius: var(--r-round); background: transparent; cursor: pointer; font: 400 var(--fs-body) var(--font); white-space: nowrap; text-decoration: none; color: var(--muted); transition: color var(--glide) var(--ease); }
.cm-tabs > [role="tab"][aria-selected="true"] { color: var(--ink); font-weight: 600; }
.cm-tabs > [role="tab"] .n { font: 400 var(--fs-small) var(--display); font-variant-numeric: tabular-nums; padding: 1px 7px; border-radius: var(--r-round); background: #DFE6E4; transition: background var(--glide) var(--ease); }
.cm-tabs > [role="tab"][aria-selected="true"] .n { background: var(--chip); }
.cm-tthumb { position: absolute; top: 0; left: 0; width: 0; height: 0; border-radius: var(--r-round); background: #fff; box-shadow: 0 1px 2px rgba(24, 42, 40, .14); pointer-events: none; z-index: 0; opacity: 0; }
.cm-tthumb.ready { opacity: 1; }
.cm-tabs:not(.js) > [role="tab"][aria-selected="true"] { background: #fff; box-shadow: 0 1px 2px rgba(24, 42, 40, .14); }

/* Equal-option segmented control: CSS thumb moved by index (set --n and --i on .cm-seg). */
.cm-seg { --n: 2; --i: 0; position: relative; display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 4px; gap: 2px; background: var(--seg); border-radius: var(--r-round); }
.cm-seg > button, .cm-seg > a { position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; height: 36px; padding: 0 16px; border: 0; border-radius: var(--r-round); background: transparent; cursor: pointer; font: 400 var(--fs-body) var(--font); color: var(--muted); white-space: nowrap; text-decoration: none; transition: color var(--glide) var(--ease); }
.cm-seg > [aria-pressed="true"], .cm-seg > [aria-selected="true"], .cm-seg > [aria-checked="true"] { color: var(--ink); font-weight: 600; }
.cm-seg::before { content: ""; position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc((100% - 8px - (var(--n) - 1) * 2px) / var(--n)); border-radius: var(--r-round); background: #fff; box-shadow: 0 1px 2px rgba(19, 35, 29, .14); transform: translateX(calc(var(--i) * (100% + 2px))); transition: transform var(--glide) var(--ease); }

/* ---------- Fields ---------- */
.cm-field { display: flex; flex-direction: column; gap: 8px; font-size: var(--fs-body); color: var(--muted); font-weight: 500; min-width: 0; }
.cm-in-f { height: 44px; padding: 0 14px; border: 1px solid var(--field); border-radius: var(--r-field); font: 400 var(--fs-body) var(--font); color: var(--ink); background: #fff; width: 100%; outline: 0; transition: border-color 200ms var(--ease), box-shadow 200ms var(--ease); }
/* Dropdowns are fully round; a text field sharing their row or grid goes round with them. */
select.cm-in-f { border-radius: var(--r-round); padding-left: 18px; }
:has(> .cm-field > .sel) > .cm-field > input.cm-in-f, :has(> .sel) > input.cm-in-f { border-radius: var(--r-round); padding-left: 18px; padding-right: 18px; }
textarea.cm-in-f { height: auto; min-height: 96px; padding: 10px 14px; line-height: 1.5; resize: vertical; }
/* Dropzone (DESIGN 14a): icon, title, helper, Choose file button; the whole zone opens the file picker. */
.cm-drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 120px; padding: 20px; border: 1.5px dashed #C5D0CE; border-radius: var(--r-tile); color: var(--muted); font-size: var(--fs-body); text-align: center; cursor: pointer; background: var(--side); transition: background 200ms var(--ease), border-color 200ms var(--ease); }
.cm-drop:hover, .cm-drop.over { border-color: var(--primary); }
.cm-drop.over { background: var(--selected); }
.cm-drop b { color: var(--ink); font-weight: 600; }
.cm-drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.cm-drop:focus-within { outline: 2px solid var(--primary); outline-offset: 2px; }
.cm-in-f:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--selected); }
.cm-in-f::placeholder { color: var(--faint); }
.cm-in-f.dense { height: 40px; }
/* Number stepper (DESIGN: chevrons outside the value box, vertically centred; the box fits three digits).
   One owner for the designer's pixel steppers (.ce-step) and the filter rules (.cm-step). */
.ce-step, .cm-step { display: grid; gap: 0; flex: none; align-self: center; }
.ce-step button, .cm-step button { width: 14px; height: 13px; padding: 0; border: 0; border-radius: var(--r-field); background: transparent; color: #566764; cursor: pointer; display: grid; place-items: center; transition: background 200ms var(--ease), color 200ms var(--ease); }
.ce-step button:hover, .cm-step button:hover { background: #E6F3F1; color: #1E6F67; }
.cm-num-in { -moz-appearance: textfield; appearance: textfield; }
.cm-num-in::-webkit-inner-spin-button, .cm-num-in::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.cm-stepper { display: inline-flex; align-items: center; gap: 4px; flex: none; }
.cm-in-f[aria-invalid="true"] { border-color: #E5A3A3; }
.cm-err { font-size: var(--fs-body); color: #9B1C1C; font-weight: 400; }
.sel { position: relative; display: block; min-width: 0; }
.sel select { appearance: none; -webkit-appearance: none; padding-right: 40px !important; width: 100%; cursor: pointer; }
.sel-ch { position: absolute; top: 50%; right: 16px; margin-top: -8px; pointer-events: none; color: var(--muted); }
.ig { display: flex; align-items: stretch; height: 44px; border: 1px solid var(--field); border-radius: var(--r-field); background: #fff; overflow: hidden; transition: border-color 200ms var(--ease), box-shadow 200ms var(--ease); }
.ig:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px var(--selected); }
.ig input { flex: 1; min-width: 0; border: 0; outline: 0; padding: 0 14px; font: 400 var(--fs-body) var(--font); color: var(--ink); background: transparent; }
.ig input.cm-code { font-size: var(--fs-body); }
.ig-btn { flex: none; min-width: 72px; padding: 0 14px; border: 0; border-left: 1px solid var(--line); background: var(--row-hover); color: var(--ink); font: 400 var(--fs-body) var(--font); cursor: pointer; transition: background 200ms var(--ease); }
.ig-btn:hover { background: var(--primary); color: #fff; }
.ck { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-body); color: var(--ink); cursor: pointer; }
.ck input, .ct-ck { margin: 1px 0 0; }
/* Checkbox token (owner, 3 Nov 2026): one design for every checkbox in the app: 18 px, the small-mark radius
   (--r-field), field border, brand fill with a white tick. Public forms use the same token (forms-public.css). */
.ck input, .ct-ck, .ce-tchk, .au-pick input { -webkit-appearance: none; appearance: none; width: 18px; height: 18px; flex: none; box-sizing: border-box; border: 1.5px solid var(--field); border-radius: var(--r-field); background: var(--surface) center / 12px 12px no-repeat; cursor: pointer; transition: background-color 200ms var(--ease), border-color 200ms var(--ease); }
.ck input:hover, .ct-ck:hover, .ce-tchk:hover, .au-pick input:hover { border-color: var(--primary); }
.ck input:checked, .ct-ck:checked, .ce-tchk:checked, .au-pick input:checked { border-color: var(--primary); background-color: var(--primary); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E"); }
.ck input:indeterminate, .ct-ck:indeterminate, .ce-tchk:indeterminate, .au-pick input:indeterminate { border-color: var(--primary); background-color: var(--primary); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round'%3E%3Cpath d='M6 12h12'/%3E%3C/svg%3E"); }
.ck input:focus-visible, .ct-ck:focus-visible, .ce-tchk:focus-visible, .au-pick input:focus-visible { outline: 0; box-shadow: 0 0 0 3px var(--selected); }
.ck input:disabled, .ct-ck:disabled, .ce-tchk:disabled, .au-pick input:disabled { opacity: .45; cursor: default; }
.ct-ck { margin: 0; display: block; }
.cm-switch { display: inline-flex; align-items: center; gap: 8px; height: 44px; border: 0; background: none; padding: 0; cursor: pointer; font: 500 var(--fs-body) var(--font); color: var(--ink-2); white-space: nowrap; text-decoration: none; }
.cm-switch:hover { color: var(--ink); }
.cm-sw { width: 30px; height: 18px; border-radius: var(--r-round); padding: 2px; display: inline-flex; flex: none; background: #CBD5D3; transition: background var(--glide) var(--ease); }
.cm-sw::after { content: ""; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform var(--glide) var(--ease); }
[aria-checked="true"] > .cm-sw { background: var(--primary); }
[aria-checked="true"] > .cm-sw::after { transform: translateX(12px); }

/* ---------- Badges (one family: 12 px, 500, 2 x 8, fully rounded) ---------- */
.cm-badge { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-label); font-weight: 500; line-height: 1.5; padding: 2px 8px; border-radius: var(--r-round); white-space: nowrap; background: var(--chip); color: var(--ink-2); }
.cm-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.st-sent, .st-ok, .chip-good { background: #E3F1EA; color: #065F46; }
.st-scheduled { background: #E8EEFB; color: #1E3A8A; }
.st-sending { background: #FDF3D7; color: #7A5200; }
.st-sending .dot { background: #B58900; animation: cmPulse 1.8s ease-in-out infinite; }
.st-paused { background: #FDEBDD; color: #9A3412; }
.st-paused .dot { background: #EA580C; }
.st-draft { background: #EEF0EE; color: var(--ink-2); }
.st-canceled { background: #F1F1EF; color: #52525B; }
.st-warn { background: #FDF1DC; color: #B45309; }
.st-error, .chip-bad { background: #FDE2E2; color: #9B1C1C; }
.chip-flat { background: var(--line-2); color: var(--muted); }

/* ---------- Review rows (DESIGN 9b) ---------- */
.rv { padding: var(--card-pad) var(--card-pad) calc(var(--card-pad) - 14px); display: flex; flex-direction: column; }
.rv-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 16px; padding-bottom: 14px; }
/* One 20 px text line, so the title meets the card's top inset; the 22 px count overlaps it by 1 each way. */
.rv-title { margin: 0; display: flex; align-items: center; gap: 8px; height: 20px; }
.rv-count { margin: -1px 0; font-size: var(--fs-label); font-weight: 600; min-width: 22px; height: 22px; padding: 0 7px; border-radius: var(--r-round); background: var(--chip); color: var(--ink-2); display: inline-grid; place-items: center; }
.rv-lead { margin: 0; font-size: var(--fs-sub); color: var(--muted); line-height: 1.5; }
.rv-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; column-gap: 14px; row-gap: 10px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line-2); }
.rv-av { width: 40px; height: 40px; border-radius: 50%; background: var(--selected); color: var(--primary); display: grid; place-items: center; font: 600 var(--fs-body) var(--display); align-self: start; }
.rv-main { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.rv-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.rv-name { font-size: var(--fs-body); font-weight: 500; color: var(--ink); }
.rv-sub { font-size: var(--fs-sub); color: var(--muted); line-height: 1.5; }
.rv-change { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-variant-numeric: tabular-nums; }
.rv-old { color: var(--faint); text-decoration: line-through; text-decoration-color: #B7C3C0; }
.rv-new { color: var(--ink); font-weight: 500; }
.rv-tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-round); font-size: var(--fs-label); font-weight: 500; white-space: nowrap; }
/* Record tags: the brand's own (a role, a default) and a plain grey one (Settings team, senders on Settings and Brand). */
.set-tag-brand { background: var(--selected); color: var(--primary); }
.set-tag-grey { background: var(--chip); color: var(--ink-2); }
.rv-act { display: flex; align-items: center; gap: 6px; flex-wrap: nowrap; }
.rv-det { grid-column: 2 / -1; display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: var(--r-tile); background: var(--row-hover); }
.rv-det-h { font-size: var(--fs-body); font-weight: 600; color: var(--muted); }
.rv-empty { display: flex; align-items: center; gap: 10px; padding: 14px 0 16px; border-top: 1px solid var(--line-2); font-size: var(--fs-body); color: var(--ink-2); }
.rv-ok { width: 28px; height: 28px; border-radius: 50%; background: #E3F1EA; color: #065F46; display: grid; place-items: center; flex: none; }
.rv-foot { padding: 14px 0; border-top: 1px solid var(--line-2); }
.rv-th { display: grid; column-gap: 16px; padding: 0 0 8px; font-size: var(--fs-body); font-weight: 400; color: var(--ink); border-bottom: 1px solid var(--line-2); }
.rv-tr { display: grid; column-gap: 16px; align-items: center; width: 100%; padding: 12px 0; border: 0; border-bottom: 1px solid var(--line-2); background: none; text-align: left; font: 400 var(--fs-body) var(--font); color: var(--ink); transition: background 200ms var(--ease); }
.rv-tr:last-child { border-bottom: 0; }
.rv-stack { display: flex; gap: 3px; height: 12px; border-radius: var(--r-round); overflow: hidden; }
.rv-stack span { display: block; height: 100%; transition: width 600ms var(--ease-out); }
@container cmwrap (max-width: 540px) { .rv-row { grid-template-columns: 40px minmax(0, 1fr); } .rv-row .rv-act { grid-column: 2; } }

/* ---------- Tables (Audyt): each column sized to its longest header or value; the name column takes the rest ---------- */
.cm-table { width: 100%; border-collapse: collapse; font-size: var(--fs-body); }
.cm-table th, .cm-table td { width: 1%; white-space: nowrap; padding: 12px 16px 12px 0; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line-2); }
.cm-table th { padding-top: 0; padding-bottom: 8px; font-size: var(--fs-body); font-weight: 400; color: var(--ink); }
.cm-table th:last-child, .cm-table td:last-child { padding-right: 0; }
.cm-table .name { width: auto; white-space: normal; }
.cm-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.cm-table tbody tr:last-child td { border-bottom: 0; }
.cm-rowt { font-weight: 500; color: var(--ink); }

/* ---------- Record lists (DESIGN 9d) ---------- */
.ct-act { display: flex; gap: 8px; justify-content: flex-end; }
.ct-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 20px; border-bottom: 1px solid var(--line-2); background: var(--row-hover); font-size: var(--fs-body); color: var(--ink-2); }
.ct-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 14px 20px; border-top: 1px solid var(--line-2); }
.ct-rows { display: flex; align-items: center; gap: 12px; font-size: var(--fs-body); font-weight: 500; color: var(--muted); }
.ct-foot .sel select { height: 36px; border-radius: var(--r-round); padding: 0 36px 0 14px; width: auto; }
/* Chevron's painted edge at the 15 px text inset (1 border + 14), DESIGN 9c. */
.ct-foot .sel-ch { right: 11px; }
.ct-pager { display: flex; align-items: center; gap: 8px; font-size: var(--fs-body); color: var(--ink-2); }
.ct-pager .cm-num { margin-right: 4px; }

/* ---------- Toast (result bar) and dialogs ---------- */
.cm-toast { position: fixed; left: 16px; right: 16px; bottom: 24px; margin: 0 auto; max-width: 560px; z-index: 65; box-shadow: 0 16px 40px -16px rgba(19, 35, 29, .4); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-radius: var(--r-tile); background: #E3F1EA; color: #065F46; font-size: var(--fs-body); font-weight: 500; animation: cmPop var(--glide) var(--ease) both; }
.cm-toast.err { background: #FDE2E2; color: #9B1C1C; }
.cm-toast-acts { display: flex; gap: 14px; flex: none; }
.cm-toast button { border: 0; background: none; cursor: pointer; color: inherit; font: 600 var(--fs-body) var(--font); padding: 0; }
.cm-dlg-back { position: fixed; inset: 0; z-index: 70; background: rgba(24, 42, 40, .45); display: grid; place-items: center; padding: 16px; animation: cmFade var(--glide) var(--ease) both; }
.cm-dlg { width: 100%; max-width: 420px; background: #fff; border-radius: var(--r-card); padding: 20px; display: flex; flex-direction: column; gap: 12px; animation: cmPop var(--glide) var(--ease) both; }
.cm-dlg h2 { margin: 0; font: 600 var(--fs-section) var(--display); color: var(--ink); }
.cm-dlg p { margin: 0; font-size: var(--fs-body); line-height: 1.55; color: var(--ink-2); }
.cm-dlg-acts { display: flex; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
/* Three actions (discard, keep, save): the dialog fits its buttons on one row inside its usual padding. */
.cm-dlg:has(.cm-dlg-acts > :nth-child(3)) { width: fit-content; max-width: 100%; }
.cm-dlg:has(.cm-dlg-acts > :nth-child(3)) .cm-dlg-acts { flex-wrap: nowrap; }
@media (max-width: 520px) { .cm-dlg:has(.cm-dlg-acts > :nth-child(3)) .cm-dlg-acts { flex-wrap: wrap; } }
.cm-pop { animation: cmPop var(--glide) var(--ease) both; }
.cm-fade { animation: cmFade var(--glide) var(--ease) both; }

/* ---------- Motion ---------- */
/* Pages and steps paint their content at once (UX plan 8): motion is kept for values that change (numbers, charts, meters). */
.cm-draw { stroke-dasharray: 2600; stroke-dashoffset: 0; animation: cmDraw 700ms var(--ease-out) 200ms backwards; }
.cm-bar { transform-origin: bottom; animation: cmGrow 600ms var(--ease-out) both; }
.cm-progress { background-image: linear-gradient(115deg, rgba(255, 255, 255, .2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, transparent 75%); background-size: 22px 22px; animation: cmMeter 600ms var(--ease-out) 150ms both, cmStripe 1.2s linear infinite; }
.cm-live { animation: cmPulse 1.8s ease-in-out infinite; }
@keyframes cmDraw { from { stroke-dashoffset: 2600; } to { stroke-dashoffset: 0; } }
@keyframes cmGrow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes cmStripe { to { background-position: 22px 0; } }
@keyframes cmMeter { from { transform: scaleX(0); } }
@keyframes cmPulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes cmPop { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes cmFade { from { opacity: 0; } to { opacity: 1; } }
.cm-loading .cm-page { opacity: .6; transition: opacity 200ms var(--ease) 400ms; }
/* Loading skeleton: drawn from the page's own measured layout (owner, 10 Nov 2026). One band of light crosses every block together. */
.cm-page.cm-skel-hide { visibility: hidden; }
.cm-skel-measure { position: absolute; left: -99999px; top: 0; pointer-events: none; }
.cm-skel-measure * { animation: none !important; transition: none !important; }
.cm-skel { position: absolute; z-index: 1; pointer-events: none; background: var(--page); transition: opacity 200ms var(--ease); }
.cm-skel.out { opacity: 0; }
.cm-skel i { position: absolute; display: block; box-sizing: border-box; }
.cm-sk, .cm-sk.on-dark { background-repeat: no-repeat; background-size: 220vw 100%; background-attachment: fixed; animation: cmSkel 1.4s var(--ease) infinite; }
/* A see-through ink, so a block reads the same on a white card and on the grey page behind the title and top button. */
.cm-sk { background-color: rgba(24, 42, 40, .09); background-image: linear-gradient(100deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .75) 50%, rgba(255, 255, 255, 0) 70%); }
.cm-sk.on-dark { background-color: rgba(255, 255, 255, .2); background-image: linear-gradient(100deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .28) 50%, rgba(255, 255, 255, 0) 70%); }
@keyframes cmSkel { from { background-position: 120vw 0; } to { background-position: -120vw 0; } }
@media (prefers-reduced-motion: reduce) { .cm-sk, .cm-sk.on-dark { animation: none; background-image: none; } }
.cm-nt .cm-nav a, .cm-nt .cm-nb, .cm-nt .cm-side, .cm-nt .cm-lbl, .cm-nt .cm-nsec, .cm-nt .cm-nsep { transition: none !important; }

/* ---------- Responsive ---------- */
@media (max-width: 859px) {
  :root { --pad-x: 24px; }
  .cm-main { padding: 24px 24px 48px; }
}
@media (max-width: 639px) { .tb-date { display: none; } }
@media (max-width: 559px) {
  :root { --pad-x: 16px; --card-pad: 16px; }
  /* Header row and content row pack to the top: a short page never spreads spare height under the header. */
  .cm-root { flex-wrap: wrap; align-content: flex-start; }
  .cm-side { position: static; flex: 0 0 100%; width: 100%; height: auto; flex-direction: row; align-items: center; gap: 16px; padding: 10px 16px; border-right: 0; border-bottom: 1px solid var(--line); overflow: visible; transition: none; }
  .cm-rail .cm-side { flex-basis: 100%; width: 100%; }
  .cm-collapse, .cm-side-sep, .cm-side-foot, .cm-nhl, .cm-nsec, .cm-nsep { display: none !important; }
  .cm-rail .cm-lbl { max-width: none; opacity: 1; }
  .cm-brand-row, .cm-rail .cm-brand-row { flex-direction: row; align-items: center; padding-left: 0; }
  .cm-phone-icons { display: flex; align-items: center; gap: 8px; margin-left: auto; flex: none; }
  .cm-main { flex-basis: 100%; padding: 20px 16px 112px; }
  .tb { display: none; }
  /* The search moves into the phone header (app.js placeSearch) and takes the room beside the bell. */
  .cm-phone-icons { flex: 1 1 auto; min-width: 0; justify-content: flex-end; }
  .cm-brand-row { flex: none; }
  .cm-phone-icons .tb-search { flex: 1 1 auto; max-width: 420px; margin-left: 0; }
  .cm-phone-icons .tb-search input { height: 40px; padding: 0 20px 0 44px; }
  .cm-phone-icons .tb-search svg { left: 15px; }
  /* Focus widens the search smoothly: the brand name and Mail chip fold away beside the logo, and an icon-only
     search grows out of its circle. Both return when the search loses focus. */
  .cm-brand-row .cm-lbl { max-width: 240px; overflow: hidden; transition: max-width 280ms var(--ease), opacity 200ms var(--ease); }
  .cm-side:has(.tb-search input:focus) .cm-brand-row .cm-lbl { max-width: 0; opacity: 0; }
  .tb-search.tb-q-icon { flex: 1 1 auto; max-width: 40px; transition: max-width 280ms var(--ease); }
  .tb-search.tb-q-icon input { padding: 0; color: transparent; cursor: pointer; }
  .tb-search.tb-q-icon input::placeholder { color: transparent; }
  .tb-search.tb-q-icon svg { left: 50%; transform: translate(-50%, -50%); }
  .tb-search.tb-q-icon:has(input:focus) { max-width: 420px; }
  .tb-search.tb-q-icon:has(input:focus) input { padding: 0 20px 0 44px; color: var(--ink); cursor: text; }
  .tb-search.tb-q-icon:has(input:focus) input::placeholder { color: var(--faint); }
  .tb-search.tb-q-icon:has(input:focus) svg { left: 15px; transform: translateY(-50%); }
  .cm-h1 { font-size: var(--fs-value); }
  .cm-toast { bottom: 104px; }

  .cm-nav-main { position: fixed; left: 6px; right: 6px; bottom: calc(12px + env(safe-area-inset-bottom)); max-width: 480px; margin: 0 auto; z-index: 25; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; padding: 3px; border-radius: var(--r-round); background: rgba(30, 111, 103, .97); -webkit-backdrop-filter: saturate(1.4) blur(18px); backdrop-filter: saturate(1.4) blur(18px); border: 1px solid rgba(255, 255, 255, .08); box-shadow: 0 16px 36px -14px rgba(19, 35, 29, .5); }
  .cm-nav-main a, .cm-rail .cm-nav-main a { width: auto; flex-direction: column; justify-content: center; gap: 3px; height: 56px; padding: 0 8px; min-width: 0; border-radius: var(--r-round); font-size: var(--fs-label); font-weight: 400; color: #D7E7E4; }
  .cm-nav-main a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
  .cm-nav-main a.on, .cm-nav-main a.on:hover, .cm-hl-ready .cm-nav-main a.on { background: #fff; color: var(--primary); font-weight: 600; }
  .cm-nav-main .cm-set-tab { display: none; } /* five items only; Settings is in the account menu */
  .cm-nav-main .cm-lbl { max-width: 100%; opacity: 1; text-overflow: ellipsis; }
  .cm-nav-main .cm-nb, .cm-rail .cm-nav-main .cm-nb { position: absolute; top: 5px; left: calc(50% + 4px); right: auto; margin: 0; height: 16px; min-width: 16px; padding: 0 4px; border-radius: var(--r-icon); font-size: var(--fs-label); line-height: 16px; background: #fff; color: var(--primary); }
  .cm-nav-main a.on .cm-nb { background: var(--primary); color: #fff; }
  /* The white pill glides between items; once it is placed, the selected item itself stays clear. */
  .cm-thl { display: block; position: absolute; top: 0; left: 0; z-index: 0; border-radius: var(--r-round); background: #fff; pointer-events: none; opacity: 0; }
  .cm-thl-ready .cm-thl { opacity: 1; }
  .cm-nav-main a { position: relative; z-index: 1; }
  .cm-thl-ready a.on, .cm-thl-ready a.on:hover { background: transparent !important; }
  .cm-tabbar-icons .cm-lbl { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0); }
  .cm-tabbar-icons a { height: 48px !important; }

  /* A row that scrolls sideways is clipped at the cards' left and right edges, never past them (owner, 3 Nov 2026). */
  .cm-actions.scroll, .cm-tools.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .cm-actions.scroll::-webkit-scrollbar, .cm-tools.scroll::-webkit-scrollbar { display: none; }
  .cm-actions.scroll > *, .cm-tools.scroll > * { flex: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .cm-draw { stroke-dashoffset: 0; }
}

/* ---------- One-card pages: sign-in, errors ---------- */
.cp-body { background: #EEF5F4; }
.cp { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 16px; }
.cp-col { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 20px; }
.cp-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); padding: var(--card-pad); display: flex; flex-direction: column; gap: 18px; }
.cp-head { display: flex; align-items: center; justify-content: center; padding-bottom: 18px; border-bottom: 1px solid var(--line-2); margin: 0 -20px; }
.cp-body-in { display: flex; flex-direction: column; gap: 18px; animation: cmFade var(--glide) var(--ease) both; }
.cp-t { display: flex; flex-direction: column; gap: 6px; text-align: center; }
.cp-t h1 { margin: 0; font: 600 var(--fs-value)/1.3 var(--display); color: var(--ink); }
.cp-t p { margin: 0; font-size: var(--fs-body); line-height: 1.6; color: var(--ink-2); }
.cp-ic { width: 44px; height: 44px; border-radius: 50%; background: #FDF3D7; color: #7A5200; display: grid; place-items: center; align-self: center; }
.cp-foot { margin: 0; text-align: center; font-size: var(--fs-sub); color: var(--help); line-height: 1.6; }
.cp-note { margin: 0; font-size: var(--fs-body); line-height: 1.6; color: var(--ink-2); text-align: center; }
.cp-note.err { color: #9B1C1C; }
.gbtn { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 48px; border: 1px solid var(--field); border-radius: var(--r-round); background: #fff; color: var(--ink); font: 400 var(--fs-body) var(--font); cursor: pointer; text-decoration: none; transition: background 200ms var(--ease); }
.gbtn:hover { background: var(--selected); color: var(--primary); border-color: #B9DCD7; }
.gbtn[aria-disabled="true"] { opacity: .5; cursor: default; pointer-events: none; }
/* Google's sign-in button is laid invisibly over .gbtn and takes the click; .gbtn keeps the look. */
.gsi { position: relative; }
.gsi-hit { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: .01; overflow: hidden; }
.gsi:hover .gbtn, .gsi:focus-within .gbtn { background: var(--selected); color: var(--primary); border-color: #B9DCD7; }
.cp-dev { display: flex; flex-direction: column; gap: 8px; padding-top: 16px; border-top: 1px dashed var(--field); }
.cp-dev form { display: flex; gap: 8px; }
.cp-dev .cm-in-f { flex: 1; min-width: 0; }
/* Two-step sign-in: the code field and its button on one row (as the local sign-in), the QR code, the typed key and
   the one-time recovery codes. */
.cp-form { display: flex; gap: 8px; }
.cp-form .cm-in-f { flex: 1; min-width: 0; }
.cp-qr { width: 168px; height: 168px; align-self: center; padding: 10px; border: 1px solid var(--line); border-radius: var(--r-field); background: #fff; }
.cp-qr svg { display: block; width: 100%; height: 100%; }
.cp-key { display: inline-block; margin-top: 6px; padding: 4px 8px; border-radius: var(--r-field); background: var(--chip); font: 500 var(--fs-body)/1.5 var(--mono); color: var(--ink); letter-spacing: .04em; word-break: normal; overflow-wrap: normal; }
.cp-codes { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cp-codes code { display: block; padding: 6px 8px; border-radius: var(--r-field); background: var(--chip); font: 500 var(--fs-body)/1.5 var(--mono); color: var(--ink); text-align: center; }
.cp-go { justify-content: center; }
.cp-alt { display: flex; justify-content: center; }

/* Empty-state stand-ins: the real layout and typography with slot labels until records arrive (they replace it). */
.ph { pointer-events: none; user-select: none; }
.ph-wrap { position: relative; }
.ph-note { position: absolute; inset: 0 0 28px 44px; z-index: 1; display: grid; place-items: center; margin: 0; padding: 0 16px; text-align: center; font-size: var(--fs-body); color: var(--ink-2); pointer-events: none; }
/* A chart with no data yet stays drawn, flat at zero. */
.rv-stack-flat { background: var(--seg); }
.ph-img { object-fit: cover; background: var(--selected); }
.tb-av { overflow: hidden; padding: 0; position: relative; }
.rv-av { overflow: hidden; }
.rv-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tb-av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 50%; }
/* A lone field beside a fully round button, with no sibling fields, is fully round too. */
.solo-field { border-radius: var(--r-round) !important; padding-left: 18px !important; padding-right: 18px !important; }

/* A record table's folded column (app.js foldTables). */
.fold-off { display: none !important; }

/* Close (Audyt): a 20px red circle with a white X inside a 28px target, at the popout's top right. */
.cm-x { flex: none; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: transparent; display: grid; place-items: center; cursor: pointer; }
.cm-x::before { content: ""; grid-area: 1 / 1; width: 20px; height: 20px; border-radius: 50%; background: var(--destructive); transition: background 200ms var(--ease); }
.cm-x:hover::before { background: linear-gradient(rgba(0, 0, 0, .08), rgba(0, 0, 0, .08)), var(--destructive); }
.cm-x svg { grid-area: 1 / 1; position: relative; color: #fff; }
.cm-x:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
/* Pinned to the header's top: the painted circle sits as far from the popout's top as from its side. */
.cm-x { align-self: flex-start; margin: -4px -4px 0 0; }

/* A dialog's head: title and lead on the left, the close token at the top right (as forms.css .fl-dlg-head). */
.cm-dlg-h { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
/* Start from dialog: Blank, Your templates, A past email; each a record row with its action on the right. */
.st-box { max-width: 560px; max-height: calc(100vh - 32px); overflow: auto; gap: 16px; }
.st-body { display: flex; flex-direction: column; gap: 16px; min-height: 120px; }
.st-sec { display: flex; flex-direction: column; }
.st-sec > .cm-card-h { padding-bottom: 4px; }
.st-row:first-of-type { border-top: 0; }
.st-ic { border-radius: var(--r-tile); background: var(--page); color: var(--muted); }
.st-thumb { border-radius: var(--r-tile); object-fit: cover; }
.st-acts { display: flex; gap: 8px; }
.st-acts form, .st-row form { margin: 0; }
.st-empty { margin: 8px 0 0; }
.st-more { align-self: flex-start; margin-top: 8px; }

/* Sender dialog (Settings → Sender domain, Brand): the not-set-up note and how the sender shows in an inbox. */
.sd-warn { margin: 0; padding: var(--note-pad); border-radius: var(--r-tile); background: var(--warn-bg); color: var(--warn-fg); font-size: var(--fs-body); line-height: 1.5; }
.sd-warn[hidden] { display: none; }
.sd-prev { display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-tile); }
.sd-prev .rv-av { align-self: center; overflow: hidden; }
.sd-prev .rv-av img, .rv-av img { width: 100%; height: 100%; object-fit: cover; }
.sd-prev .rv-sub, .sd-prev .rv-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Popout guide (Home's Ready to send steps open it; owner, 3 Nov 2026) ---------- */
/* The hover hint for every titled element (public/js/app.js): above menus, dialogs and the guide; never takes the pointer. */
.cm-tip { position: fixed; z-index: 120; max-width: min(280px, calc(100vw - 16px)); box-sizing: border-box; padding: 5px 8px; border-radius: var(--r-field); background: var(--ink); color: #fff; font: 500 var(--fs-sub)/1.4 var(--font); white-space: pre-line; overflow-wrap: anywhere; pointer-events: none; }
.cm-guide { position: fixed; z-index: 90; width: 300px; max-width: calc(100vw - 16px); box-sizing: border-box; padding: 16px; display: flex; flex-direction: column; gap: 8px; background: var(--surface); border-radius: var(--r-card); box-shadow: 0 0 0 1px var(--line), 0 16px 40px -14px rgba(19, 35, 29, .4); }
.cm-guide-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; height: 20px; }
.cm-guide-n { font: 500 12px/16px var(--font); color: var(--muted); }
.cm-guide-t { margin: 0; font: var(--card-title); color: var(--ink); }
.cm-guide p { margin: 0; font-size: var(--fs-body); line-height: 1.5; color: var(--ink-2); }
.cm-guide-acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
/* The field the popout is about stays lit with its own box and corners; the rest dims as behind a dialog. */
.cm-guide-dim { position: fixed; z-index: 89; pointer-events: none; box-shadow: 0 0 0 200vmax rgba(24, 42, 40, .45); transition: left var(--glide) var(--ease), top var(--glide) var(--ease), width var(--glide) var(--ease), height var(--glide) var(--ease), border-radius var(--glide) var(--ease); }
@media (prefers-reduced-motion: reduce) { .cm-guide-dim { transition: none; } }

/* New campaign: channel choice above its starting points. */
.st-chan { display: grid; width: 100%; box-sizing: border-box; }
.st-panel { display: flex; flex-direction: column; gap: 16px; }
.st-panel[hidden] { display: none; }
.st-clip { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* A WhatsApp or SMS message as the person sees it: the composer's preview and the report's View message. */
.cm-chat { display: flex; flex-direction: column; gap: 8px; padding: var(--card-pad); background: var(--email-backdrop); }
.cm-bubble { align-self: flex-start; max-width: 100%; box-sizing: border-box; padding: 12px 14px; border-radius: var(--r-tile); background: var(--surface); font-size: var(--fs-body); line-height: 1.5; color: var(--email-text); white-space: pre-wrap; overflow-wrap: anywhere; }
.cm-bubble.empty { color: var(--muted); }
/* WhatsApp preview: one fixed bubble width and phone-sized words, so lines wrap as on a phone (message content keeps its own size, as email previews do). */
.cm-chat-wa { --wa-bubble: 300px; --wa-line: 22px; align-items: flex-start; }
.cm-chat-wa .cm-bubble, .cm-chat-wa .cm-chat-btns { width: var(--wa-bubble); max-width: 100%; }
.cm-wa-pic { margin-bottom: 8px; overflow: hidden; border-radius: var(--r-icon); background: var(--seg); }
.cm-wa-pic img { display: block; width: 100%; height: auto; }
.cm-wa-pic.crop { aspect-ratio: 1.91; }
.cm-wa-pic.crop img { height: 100%; object-fit: cover; }
.cm-wa-text { font-size: 16px; line-height: var(--wa-line); white-space: pre-wrap; overflow-wrap: anywhere; }
.cm-wa-text.clamp { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: var(--wa-lines, 5); overflow: hidden; }
.cm-wa-more { display: inline-block; margin-top: 4px; padding: 0; border: 0; background: none; cursor: pointer; font-size: 16px; line-height: var(--wa-line); color: var(--primary); }
.cm-bubble mark { padding: 0 4px; border-radius: var(--r-field); background: var(--selected); color: var(--primary); }
.cm-chat-btns { display: flex; flex-direction: column; gap: 8px; }
.cm-chat-btns:empty { display: none; }
.cm-chat-btns span { padding: 12px 14px; border-radius: var(--r-tile); background: var(--surface); text-align: center; font-size: var(--fs-body); font-weight: 500; color: var(--primary); }
