  /* ======================================================================
     DecoSign design system tokens (Light = Paper, Dark = Night), IBM Plex Sans Arabic only.
     Source of truth: the DecoSign design system artifact (tokens.json). Magenta is spent sparingly:
     the primary button, the page-head rule, the active link, key numbers. Magenta TEXT is --accent-text.
     success / danger are states only. Square-cut by default, 4px for inputs and chips.
     ====================================================================== */
  @font-face { font-family: "IBM Plex Sans Arabic"; src: url(/assets/IBMPlexSansArabic-Regular.woff2) format("woff2"), url(/assets/IBMPlexSansArabic-Regular.ttf) format("truetype"); font-weight: 400; font-display: swap; }
  @font-face { font-family: "IBM Plex Sans Arabic"; src: url(/assets/IBMPlexSansArabic-SemiBold.woff2) format("woff2"), url(/assets/IBMPlexSansArabic-SemiBold.ttf) format("truetype"); font-weight: 600; font-display: swap; }
  @font-face { font-family: "IBM Plex Sans Arabic"; src: url(/assets/IBMPlexSansArabic-Bold.woff2) format("woff2"), url(/assets/IBMPlexSansArabic-Bold.ttf) format("truetype"); font-weight: 700; font-display: swap; }

  :root {
    --magenta: #ce0f69; --magenta-deep: #a40755; --pink-glow: #ff5ca4; --deep: #11161c;
    --bg: #f7f5f6; --surface: #fff; --sunken: #e9e6e8; --panel: #1d242c;
    --ink: #1d242c; --muted: #565b60; --subtle: #63686d;
    --line: #dedcdf; --line-strong: #80858a; --rule: #1d242c;
    --accent: var(--magenta); --accent-text: #ce0f69; --on-accent: #fff; --on-panel: #fff; --focus: #1d242c;
    --success: #1f6b4a; --danger: #b42318; --warn: #8a5300; --on-state: #fff;
    --scrim: rgba(17, 22, 28, .55);
    --on-deep: #fff; --on-deep-muted: #aeb3b7;                       /* text on the always-dark brand panel */
    --shadow-pop: 0 6px 20px rgba(29, 36, 44, .22); --glow: rgba(206, 15, 105, .55);
    --sans: "IBM Plex Sans Arabic", "Avenir Next", "Century Gothic", Arial, sans-serif;
    --r-sm: 4px;
    --ease: cubic-bezier(.215, .61, .355, 1);
    --ease-in: cubic-bezier(.55, .055, .675, .19);
  }
  @media (prefers-color-scheme: dark) {
    :root {
      --bg: #11161c; --surface: #1d242c; --sunken: #252d35; --panel: #252d35;
      --ink: #fff; --muted: #aeb3b7; --subtle: #9e98a4;
      --line: #414a52; --line-strong: #787d82; --rule: #70757a;
      --accent-text: #ff5ca4; --focus: #ff5ca4;
      --success: #6fd3a5; --danger: #ff8a7a; --warn: #f2b44e; --on-state: #11161c;
      --scrim: rgba(0, 0, 0, .62); --shadow-pop: 0 6px 20px rgba(0, 0, 0, .55);
    }
  }

  * { box-sizing: border-box; }
  body {
    margin: 0; background: var(--bg); color: var(--ink);
    font: 400 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased;
  }
  button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
  button { cursor: pointer; }
  :focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
  [dir="rtl"], [dir="auto"] { line-height: 1.8; }
  h1 { font: 700 36px/1.05 var(--sans); letter-spacing: -.8px; margin: 0; text-wrap: balance; }
  h1 em { font-style: normal; color: var(--accent-text); }

  /* ---------------- top bar ---------------- */
  .bar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30; background: var(--surface); border-bottom: 1px solid var(--line); }
  .bar-in { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 24px; min-height: 64px; }
  .mark { display: flex; align-items: center; flex: none; cursor: pointer; transition: opacity .15s; }
  .mark:hover { opacity: .8; }
  .mark img { height: 28px; width: auto; display: block; }
  .bar-r { display: flex; align-items: center; gap: 12px; flex: none; margin-left: auto; }

  /* ---------------- page head: eyebrow, title with one accent word, the 2px accent rule ---------------- */
  .ph { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px 24px; flex-wrap: wrap; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 2px solid var(--accent); animation: rise .4s var(--ease) both; }
  .eyebrow { margin: 0 0 8px; color: var(--accent-text); font: 700 12px/1.2 var(--sans); letter-spacing: 1.6px; text-transform: uppercase; }
  .ph p { margin: 8px 0 0; color: var(--muted); max-width: 60ch; }
  .ph-acts { display: flex; gap: 12px; flex-wrap: wrap; }

  /* ---------------- status chips: the word is always there; colour is only a state ---------------- */
  .pill {
    display: inline-flex; align-items: center; padding: 2px 9px; border: 1px solid transparent; border-radius: var(--r-sm);
    font: 600 12px/1.5 var(--sans); white-space: nowrap;
  }
  .pill.p-open { color: var(--ink); border-color: var(--line-strong); }
  .pill.p-part { color: var(--ink); background: var(--sunken); }
  .pill.p-void { color: var(--muted); background: var(--sunken); }
  .pill.p-ok { color: var(--success); background: color-mix(in srgb, var(--success) 13%, var(--surface)); }
  .pill.p-bad { color: var(--danger); background: color-mix(in srgb, var(--danger) 13%, var(--surface)); }

  /* ---------------- toast ---------------- */
  #toast-host { position: fixed; left: 24px; bottom: calc(24px + env(safe-area-inset-bottom, 0px) + var(--sum-h, 0px)); z-index: 9600; }
  .toast {
    max-width: min(460px, calc(100vw - 48px)); padding: 12px 18px;
    background: var(--panel); color: var(--on-panel); border: 1px solid var(--line-strong); box-shadow: var(--shadow-pop);
    font-size: 14px; animation: fade-in .15s var(--ease) both;
  }
  .toast + .toast { margin-top: 8px; }
  @media (max-width: 560px) { #toast-host { left: 16px; right: 16px; } .toast { max-width: none; } }

  /* ======================================================================
     Interface kit: page-change loader, sign-in, fields, buttons, overlays, menus, chips, tabs, history.
     Tokens come from base.css (the DecoSign design system).
     ====================================================================== */

  /* ---------------- page change: the DecoSign loader, always the WHITE wordmark on the dark ground ---------------- */
  .swap {
    position: fixed; inset: 0; z-index: 10000;
    display: flex; align-items: center; justify-content: center;
    background: var(--deep);
    opacity: 0; pointer-events: none;
    transition: opacity .24s var(--ease);
  }
  .swap.on, html.swapping .swap { opacity: 1; pointer-events: auto; }
  html.swapping .swap { transition: none; animation: swap-giveup 0s 7s forwards; }   /* never stuck */
  .swap.sweep { opacity: 1; pointer-events: auto; clip-path: inset(0 58% 0 0); animation: sweep .44s var(--ease) forwards; }
  @keyframes sweep { to { clip-path: inset(0 0 0 0); } }
  @keyframes swap-giveup { to { opacity: 0; pointer-events: none; } }

  /* ---------------- sign-in: the dark brand panel (with the arc) on the left, the form on the right ---------------- */
  .auth { position: fixed; inset: 0; z-index: 9000; display: grid; grid-template-columns: minmax(340px, 42%) 1fr; background: var(--bg); overflow-y: auto; }
  .auth-brand {
    position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: center;
    padding: 56px clamp(28px, 5vw, 64px); background: var(--deep); color: var(--on-deep);
  }
  .auth-brand::before {             /* the arc: a thin neon circle segment on deep */
    content: ""; position: absolute; width: 440px; height: 440px; right: -190px; top: -130px;
    border: 2px solid var(--pink-glow); border-radius: 50%; opacity: .8;
    box-shadow: 0 0 40px var(--glow), inset 0 0 40px var(--glow);
  }
  .auth-brand > * { position: relative; z-index: 1; }
  .auth-logo { width: 150px; height: auto; }
  .auth-brand .eyebrow { margin: 44px 0 16px; color: var(--pink-glow); }
  .auth-brand h1 { max-width: 12ch; font-size: clamp(36px, 3.6vw, 48px); line-height: 1; letter-spacing: -1px; }
  .auth-brand h1 em { color: var(--pink-glow); }
  .auth-brand p { margin: 20px 0 0; max-width: 36ch; color: var(--on-deep-muted); }

  .auth-side { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
  .auth-card { width: 100%; max-width: 420px; background: var(--surface); border: 1px solid var(--line); padding: 32px 32px 20px; }
  .auth-icon { width: 40px; height: 40px; background: var(--sunken); color: var(--ink); display: grid; place-items: center; }
  .auth-kicker { margin: 18px 0 4px; color: var(--accent-text); font: 700 12px/1.2 var(--sans); letter-spacing: 1.6px; text-transform: uppercase; }
  .auth-card h2 { margin: 0; font: 700 24px/1.15 var(--sans); letter-spacing: -.3px; }
  .auth-help { margin: 8px 0 22px; color: var(--muted); font-size: 14px; line-height: 1.55; }
  .auth-foot { display: flex; gap: 8px; align-items: flex-start; margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; line-height: 1.5; }
  .auth-foot svg { flex: none; margin-top: 3px; }
  .auth-foot a { color: var(--accent-text); font-weight: 600; text-decoration: none; }
  .auth-foot a:hover { text-decoration: underline; }
  .auth-for { margin: -10px 0 18px; padding: 10px 12px; background: var(--sunken); color: var(--muted); font-size: 13px; line-height: 1.5; }
  .auth-for b { color: var(--ink); font-weight: 600; }
  .auth .form-msg { margin-top: 10px; }

  .auth-brand > * { animation: rise .42s var(--ease) both; }
  .auth-brand > :nth-child(2) { animation-delay: .06s; }
  .auth-brand > :nth-child(3) { animation-delay: .12s; }
  .auth-brand > :nth-child(4) { animation-delay: .18s; }
  .auth-card { animation: card-in .42s .1s var(--ease) both; }
  .auth.done .auth-card { animation: card-leave .32s var(--ease-in) forwards; }   /* signed in: the form steps back while the brand sweeps across */

  @media (max-width: 820px) {
    /* stacked: each part as tall as its content (a plain auto row would squeeze the brand panel) */
    .auth { grid-template-columns: 1fr; grid-auto-rows: max-content; align-content: start; }
    .auth-brand { padding: 32px 24px 28px; }
    .auth-brand h1 { font-size: 32px; }
    .auth-brand p { display: none; }
    .auth-brand .eyebrow { margin: 24px 0 12px; }
    .auth-logo { width: 120px; }
    .auth-side { padding: 24px 16px 40px; }
    .auth-card { padding: 24px 20px 16px; }
  }
  /* phones: iOS zooms into any field under 16px; 16px everywhere on touch keeps the page still */
  @media (hover: none) and (pointer: coarse) { input, textarea, select { font-size: 16px !important; } }

  /* ---------------- fields: label above, always visible ---------------- */
  .fld { display: block; }
  .fld[hidden] { display: none; }
  .fld + .fld { margin-top: 16px; }
  .fld label { display: block; margin: 0 0 8px; font: 600 14px/1.3 var(--sans); }
  .fld input, .fld select, .fld textarea {
    width: 100%; min-height: 46px; padding: 12px 16px;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-sm);
    font: 400 16px/1.4 var(--sans); transition: border-color .15s;
  }
  .fld textarea { min-height: 84px; resize: vertical; }
  .fld input::placeholder, .fld textarea::placeholder { color: var(--subtle); }
  .fld input:focus-visible, .fld select:focus-visible, .fld textarea:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; border-color: var(--ink); }
  input[type="file"] { font-size: 14px; max-width: 100%; }
  input[type="file"]::file-selector-button {
    font: 600 13px/1 var(--sans); padding: 9px 14px; margin-inline-end: 12px; cursor: pointer;
    background: transparent; color: var(--ink); border: 2px solid var(--ink); border-radius: 0; transition: background .15s, color .15s;
  }
  input[type="file"]::file-selector-button:hover { background: var(--ink); color: var(--bg); }
  .fld-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
  .fld-row.three { grid-template-columns: repeat(3, 1fr); }
  .fld-row .fld + .fld { margin-top: 0; }
  .fld-row + .fld, .fld + .fld-row, .fld-row + .fld-row { margin-top: 16px; }
  .fld-hint { display: block; margin-top: 6px; color: var(--muted); font-size: 13px; line-height: 1.4; }
  .form-msg { min-height: 18px; margin: 12px 0 0; font: 600 13px/1.45 var(--sans); color: var(--danger); }
  .form-msg.ok { color: var(--success); }

  /* ---------------- buttons: square-cut, 44px tall, press / work / finish ---------------- */
  .btn {
    position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 44px; padding: 0 24px; border-radius: 0; border: 2px solid transparent;
    font: 600 15px/1 var(--sans); text-decoration: none;
    transition: transform .12s var(--ease), background-color .15s, color .15s, border-color .15s, opacity .15s;
  }
  .btn:active:not(:disabled) { transform: scale(.97); }
  .btn.primary { background: var(--accent); color: var(--on-accent); }
  .btn.primary:hover:not(:disabled) { background: var(--magenta-deep); }
  .btn.ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
  .btn.ghost:hover:not(:disabled) { background: var(--ink); color: var(--bg); }
  .btn.go { background: var(--success); color: var(--on-state); }
  .btn.go:hover:not(:disabled) { background: color-mix(in srgb, var(--success) 82%, var(--ink)); }
  .btn.stop { background: var(--danger); color: var(--on-state); }
  .btn.stop:hover:not(:disabled) { background: color-mix(in srgb, var(--danger) 82%, var(--ink)); }
  .btn.danger { background: transparent; color: var(--danger); border-color: var(--danger); }
  .btn.danger:hover:not(:disabled) { background: var(--danger); color: var(--on-state); }
  .btn.wide { width: 100%; }
  .btn:disabled:not(.busy):not(.done), .btn[aria-disabled="true"] { cursor: default; background: var(--sunken); color: var(--muted); border-color: var(--line-strong); }   /* muted text on sunken stays above 4.5:1 */
  .btn.ghost[aria-disabled="true"]:hover, .btn.primary[aria-disabled="true"]:hover { background: var(--sunken); color: var(--muted); }
    .btn.busy .btn-l, .btn.done .btn-l { opacity: 0; }
  .btn.busy::after, .btn.done::after { content: ""; position: absolute; inset: 0; margin: auto; }
  .btn.busy::after { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
  .btn.done::after { width: 18px; height: 9px; border: solid currentColor; border-width: 0 0 2.5px 2.5px; transform: translateY(-2px) rotate(-45deg); animation: tick .3s var(--ease) both; }
  .btn.done.primary { background: var(--success); color: var(--on-state); }
  .btn-l svg { vertical-align: -2px; margin-right: 7px; }
  .btn-row { display: flex; gap: 12px; margin-top: 20px; }
  .btn-row > .btn { flex: 1; }
  @keyframes spin { to { transform: rotate(360deg); } }
  @keyframes tick { from { opacity: 0; transform: translateY(-2px) rotate(-45deg) scale(.4); } }
  .icb {
    width: 32px; height: 32px; display: grid; place-items: center; flex: none; padding: 0;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: 0; color: var(--muted);
    transition: color .15s, border-color .15s, transform .12s var(--ease);
  }
  .icb:hover { color: var(--ink); border-color: var(--ink); }
  .icb:active { transform: scale(.94); }
  .icb:disabled { opacity: .3; cursor: default; }

  /* ---------------- overlays: the page dimmed behind a square-cut sheet ---------------- */
  .ovl {
    position: fixed; inset: 0; z-index: 9500; display: flex; align-items: flex-start; justify-content: center;
    padding: max(7vh, 24px) 16px 24px; overflow-y: auto; background: var(--scrim); animation: fade-in .2s var(--ease) both;
  }
  .ovl.out { animation: fade-out .16s var(--ease-in) both; pointer-events: none; }   /* a closing overlay never eats the next click */
  .ovl-card {
    position: relative; width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--line-strong);
    padding: 24px 24px 20px; animation: card-in .3s var(--ease) both;
  }
  .ovl-card.wide { max-width: 800px; }
  .ovl.out .ovl-card { animation: card-leave .16s var(--ease-in) both; }
  .ovl-x { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; display: grid; place-items: center; border: 0; background: none; color: var(--muted); transition: background .15s, color .15s; }
  .ovl-x:hover { background: var(--sunken); color: var(--ink); }
  .ovl-title { margin: 0 40px 4px 0; font: 700 24px/1.2 var(--sans); letter-spacing: -.3px; }
  .ovl-title + .ovl-body { margin-top: 18px; }
  .ovl-sub { margin: 0 0 18px; color: var(--muted); font-size: 14px; line-height: 1.5; }
  .ovl-note { margin: 16px 0 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
  body.ovl-open { overflow: hidden; }
  .linkbox { margin: 4px 0; padding: 12px 14px; background: var(--sunken); font-size: 13px; line-height: 1.5; word-break: break-all; user-select: all; }

  /* ---------------- anchored menus ---------------- */
  .pop {
    position: fixed; z-index: 9400; width: 280px; max-width: calc(100vw - 24px); padding: 6px;
    background: var(--surface); border: 1px solid var(--line-strong);
    transform-origin: top right; animation: pop-in .18s var(--ease) both;
  }
  .pop.out { animation: pop-out .12s var(--ease-in) both; pointer-events: none; }
  .pop-head { display: flex; gap: 12px; align-items: center; padding: 10px 10px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--line); }
  .pop-head b { display: block; font: 600 14px/1.3 var(--sans); }
  .pop-head small { display: block; font-size: 13px; line-height: 1.35; color: var(--muted); word-break: break-all; }
  .pop-head .role { margin-top: 3px; color: var(--accent-text); font-weight: 600; }
  .pop-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border: 0; background: none; font: 600 14px/1.2 var(--sans); text-align: left; transition: background .12s; }
  .pop-item:hover, .pop-item:focus-visible { background: var(--sunken); outline: none; }
  .pop-item.danger, .pop-item.danger svg { color: var(--danger); }
  .pop-item svg { color: var(--muted); flex: none; }
  .pop-item.nochk { padding-left: 35px; }
  .pop-label { padding: 10px 10px 4px; font: 600 11px/1 var(--sans); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
  .pop-label:not(:first-child) { margin-top: 6px; border-top: 1px solid var(--line); padding-top: 12px; }
  .pop-form { padding: 8px 10px 10px; animation: rise .22s var(--ease) both; }
  .pop-form .fld input { min-height: 42px; font-size: 14px; }

  .avatar { width: 34px; height: 34px; flex: none; display: grid; place-items: center; background: var(--panel); color: var(--on-panel); font: 700 12px/1 var(--sans); }
  .avatar.lg { width: 40px; height: 40px; font-size: 14px; }
  #acctbtn { width: 34px; height: 34px; padding: 0; border: 0; transition: transform .12s var(--ease), box-shadow .15s; }
  #acctbtn:hover, #acctbtn[aria-expanded="true"] { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--ink); }
  #acctbtn:active { transform: scale(.94); }

  /* ---------------- filter chips and tabs ---------------- */
  .chips { display: flex; gap: 8px; flex-wrap: wrap; }
  .chip {
    padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: var(--r-sm); background: var(--surface);
    font: 600 13px/1 var(--sans); color: var(--ink); transition: background-color .15s, color .15s, border-color .15s, transform .12s var(--ease);
  }
  .chip:hover { border-color: var(--ink); }
  .chip:active { transform: scale(.96); }
  .chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
  .tabs2 { display: flex; gap: 24px; margin: 0 0 24px; border-bottom: 1px solid var(--line); overflow-x: auto; overflow-y: hidden; }
  .tabs2 button { padding: 10px 0; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; background: none; font: 600 15px/1.2 var(--sans); color: var(--muted); white-space: nowrap; transition: color .15s, border-color .15s; }
  .tabs2 button:hover { color: var(--ink); }
  .tabs2 button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }

  /* ---------------- history: day-grouped timeline, diamond dots ---------------- */
  .tl-tools { display: flex; gap: 12px; flex-wrap: wrap; margin: 0 0 8px; }
  .tl-tools .fld { flex: 1; min-width: 200px; }
  .tl-scroll { max-height: min(58vh, 560px); overflow-y: auto; margin: 0 -6px; padding: 0 6px; overscroll-behavior: contain; }
  .tl-scroll.small { max-height: 240px; }
  .tl-day { margin: 18px 0 6px; font: 600 11px/1 var(--sans); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
  .tl { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line-strong); }
  .tl-row { position: relative; display: grid; grid-template-columns: 46px 1fr; gap: 10px; padding: 8px 0 8px 16px; animation: rise .3s var(--ease) both; animation-delay: calc(var(--i, 0) * 18ms); }
  .tl-row::before { content: ""; position: absolute; left: -5px; top: 15px; width: 9px; height: 9px; transform: rotate(45deg); background: var(--surface); border: 2px solid var(--line-strong); }
  .tl-row.bad::before { border-color: var(--danger); }
  .tl-row.good::before { border-color: var(--success); }
  .tl-time { font: 600 12px/1.6 var(--sans); font-variant-numeric: tabular-nums; color: var(--muted); }
  .tl-line { font-size: 14px; line-height: 1.5; color: var(--muted); }
  .tl-line b { color: var(--ink); font-weight: 600; }
  .tl-sub { font-size: 13px; line-height: 1.45; color: var(--muted); word-break: break-word; }
  .tl-empty { color: var(--muted); font-size: 14px; padding: 20px 0; }

  /* ---------------- shared motion ---------------- */
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } }
  @keyframes card-in { from { opacity: 0; transform: translateY(12px) scale(.97); } }
  @keyframes card-leave { to { opacity: 0; transform: translateY(6px) scale(.97); } }
  @keyframes fade-in { from { opacity: 0; } }
  @keyframes fade-out { to { opacity: 0; } }
  @keyframes pop-in { from { opacity: 0; transform: translateY(-4px) scale(.96); } }
  @keyframes pop-out { to { opacity: 0; transform: translateY(-4px) scale(.97); } }

/* The DecoSign loader (markup: src/loader.js), as on the redesigned website. Timeline (0.66 s): "Deco" rises 0.25 s (power3.out), the pen stroke runs 0.4 s
   from t = 0.2 s (power2.out), the whole of "Sign" settles in over 0.08 s at t = 0.58 s, then the finished wordmark holds. "Deco" is ink on light
   grounds and white on dark; "Sign" is always the brand magenta (#ce0f69: 3.4:1 on the dark ground, a logo mark, so the 3:1 non-text bar).
   The animations run whenever the loader is shown (.on) or the page is still changing (.swapping), or always when the
   loader sits on its own (.dsl-solo). With prefers-reduced-motion it is simply the finished wordmark. */
.dsl { width: min(60vw, 300px); height: auto; display: block; overflow: visible; }
.dsl .on-dark { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .dsl .on-light { display: none; } :root:not([data-theme="light"]) .dsl .on-dark { display: inline; } }
:root[data-theme="dark"] .dsl .on-light, html.swap-dark .dsl .on-light, .dsl-dark .dsl .on-light { display: none; }
:root[data-theme="dark"] .dsl .on-dark, html.swap-dark .dsl .on-dark, .dsl-dark .dsl .on-dark { display: inline; }

.dsl-pen { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); }
.dsl-full { opacity: 0; }
.dsl-deco { opacity: 0; }
.swap.on .dsl-deco, html.swapping .dsl-deco, .dsl-solo .dsl-deco { animation: dsl-rise .25s cubic-bezier(.215, .61, .355, 1) both; }
.swap.on .dsl-pen, html.swapping .dsl-pen, .dsl-solo .dsl-pen { animation: dsl-write .4s .2s cubic-bezier(.25, .46, .45, .94) both; }
.swap.on .dsl-full, html.swapping .dsl-full, .dsl-solo .dsl-full { animation: dsl-settle .08s .58s linear both; }
@keyframes dsl-rise { from { opacity: 0; transform: translateY(22%); } to { opacity: 1; transform: none; } }
@keyframes dsl-write { from { stroke-dashoffset: var(--len); } to { stroke-dashoffset: 0; } }
@keyframes dsl-settle { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .dsl-deco, .dsl-full { opacity: 1 !important; animation: none !important; }
  .dsl-pen { animation: none !important; }
}

  /* ======================================================================
     Outreach Desk: header links, page frame, stat row and filter chips (from Billing), then the desk screens below.
     Tokens from base.css, kit from ui.css.
     ====================================================================== */
  .bar-in .nav { display: flex; gap: 24px; flex: 1 1 auto; min-width: 0; align-self: stretch; }
  .navlink { display: flex; align-items: center; color: var(--muted); font-weight: 600; text-decoration: none; white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color .15s, border-color .15s; }
  .navlink:hover { color: var(--ink); }
  .navlink[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }
  .newlink { min-height: 40px; padding: 0 20px; }
  .whoami { display: none; line-height: 1.2; text-align: right; }
  .whoami b { display: block; font-size: 13px; } .whoami small { color: var(--muted); font-size: 12px; }
  @media (min-width: 900px) { .whoami { display: block; } }
  @media (max-width: 680px) {
    .bar-in { flex-wrap: wrap; row-gap: 0; padding: 10px 16px 0; gap: 12px; }
    .bar-in .nav { order: 3; flex-basis: 100%; gap: 20px; min-height: 40px; }
    .newlink { padding: 0 14px; min-height: 36px; } .nl-more { display: none; }
  }

  .app { max-width: 1200px; margin: 0 auto; padding: 40px 24px 96px; }
  .dash-sub { margin: 8px 0 24px; color: var(--muted); font-size: 14px; animation: rise .4s .05s var(--ease) both; }
  @media (max-width: 560px) { .app { padding: 24px 16px 80px; } h1 { font-size: 30px; } }

  .dash-empty { text-align: center; padding: 56px 24px; background: var(--surface); border-block: 1px solid var(--line); animation: rise .4s var(--ease) both; }
  .dash-empty h2 { margin: 0 0 8px; font: 700 24px/1.15 var(--sans); }
  .dash-empty p { margin: 0 auto 24px; max-width: 44ch; color: var(--muted); }

  /* ---------------- numbers: the stat row ---------------- */
  .stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 24px; border-block: 1px solid var(--line); }
  .stat { display: flex; flex-direction: column; gap: 4px; padding: 20px 16px; border-inline-end: 1px solid var(--line); animation: rise .38s var(--ease) both; animation-delay: calc(var(--i, 0) * 50ms); }
  .stat:last-child { border-inline-end: 0; }
  .stat-k { font: 600 11px/1.3 var(--sans); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
  .stat-v { margin-top: 4px; font: 700 24px/1.1 var(--sans); letter-spacing: -.3px; font-variant-numeric: tabular-nums; }

  .stat.accent .stat-v { color: var(--accent-text); } .stat .stat-v.zero { color: var(--subtle); } .stat.bad .stat-v { color: var(--danger); } .stat.ok .stat-v { color: var(--success); }
  .stat-n { margin-top: 4px; font-size: 13px; color: var(--muted); }
  @media (max-width: 860px) {
    .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stat:nth-child(2n) { border-inline-end: 0; } .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  }
  @media (max-width: 560px) { .stat-v { font-size: 20px; } }

  /* ---------------- filters ---------------- */
  .dash-tools { display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 16px; animation: rise .4s .1s var(--ease) both; }
  .dash-tools .fld { min-width: 150px; }
  .dash-tools .fld.grow { flex: 1 1 240px; }
  .dash-tools .fld label { font-size: 13px; }
  .dash-tools .fld input, .dash-tools .fld select { min-height: 42px; font-size: 15px; }
  .dash-tools .chips { align-items: center; }
  .dash-tools .chip { min-height: 42px; padding: 0 14px; font-size: 14px; }
  /* colour-coded status chips: a dot in the status colour, the whole chip filled with it when lit */
  .chip[data-tone]::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; background: var(--tone); }
  .chip[data-tone="ink"] { --tone: var(--ink); --on-tone: var(--bg); } .chip[data-tone="bad"] { --tone: var(--danger); --on-tone: var(--on-state); }
  .chip[data-tone="part"] { --tone: var(--accent); --on-tone: var(--on-accent); } .chip[data-tone="ok"] { --tone: var(--success); --on-tone: var(--on-state); }
  .chip[data-tone][aria-pressed="true"] { background: var(--tone); border-color: var(--tone); color: var(--on-tone); }
  .chip[data-tone][aria-pressed="true"]::before { background: currentColor; }
  .chip.more::after { content: ""; display: inline-block; width: 6px; height: 6px; margin: 0 0 3px 9px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); transition: transform .15s; }
  .chip.more[aria-expanded="true"]::after { transform: rotate(225deg) translate(-2px, -2px); }
  .tab-n { margin-left: 8px; padding: 1px 7px; background: var(--sunken); color: var(--muted); font: 600 12px/1.5 var(--sans); }
  /* ---------------- five nav links on a narrow phone: the nav row scrolls inside itself, the page never does ---------------- */
  @media (max-width: 560px) {
    .bar-in .nav { overflow-x: auto; scrollbar-width: none; gap: 18px; }
    .bar-in .nav::-webkit-scrollbar { display: none; }
    .bar-in .nav .navlink { flex: none; }
  }
  .cap-meter { align-items: center; gap: 10px; font: 600 13px/1.2 var(--sans); color: var(--muted); white-space: nowrap; }
  .cap-meter b { color: var(--ink); font-variant-numeric: tabular-nums; }
  .cap-meter i { display: block; width: 72px; height: 6px; background: var(--sunken); overflow: hidden; } .cap-meter i u { display: block; height: 100%; background: var(--success); text-decoration: none; }
  .cap-meter.full i u { background: var(--danger); } .cap-meter.full b { color: var(--danger); }
  .cap-meter { display: flex; } .cap-meter i { display: none; }
  @media (min-width: 640px) { .cap-meter i { display: block; } }

  .pill.p-warm { color: var(--warn); background: color-mix(in srgb, var(--warn) 14%, var(--surface)); }
  .chip .n { margin-left: 8px; padding: 1px 6px; background: var(--sunken); color: var(--muted); font: 600 11px/1.5 var(--sans); border-radius: 2px; }
  .chip[aria-pressed="true"] .n { background: rgba(255,255,255,.2); color: inherit; }

/* ======================================================================
   DecoSign CRM screens. Same tokens and kit as Billing; nothing here invents a new look.
   ====================================================================== */
#acctbtn { background: var(--panel); color: var(--on-panel); font: 700 12px/1 var(--sans); }
.cap-meter.test b { color: var(--warn); }
.btn.small { min-height: 34px; padding: 0 14px; font-size: 13px; }
.linkb { padding: 0; border: 0; background: none; color: var(--accent-text); font: 600 14px/1.4 var(--sans); text-decoration: none; cursor: pointer; }
.linkb:hover { text-decoration: underline; }
.empty { color: var(--muted); padding: 24px 0; } .empty.sm { padding: 6px 0; font-size: 14px; }
.rtl { direction: rtl; text-align: left; unicode-bidi: plaintext; }
.note-box, .warn-box { display: block; width: 100%; margin: 12px 0; padding: 12px 14px; border: 0; border-left: 3px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); font: 600 14px/1.45 var(--sans); color: var(--ink); text-align: left; }
.warn-box { border-left-color: var(--warn); background: color-mix(in srgb, var(--warn) 10%, var(--surface)); }
.note-box.click { cursor: pointer; } .note-box.click:hover { text-decoration: underline; }
.cb { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 14px; cursor: pointer; }
.cb input { width: 18px; height: 18px; accent-color: var(--accent); }
.tool-cb { align-self: center; margin: 0 0 10px; }
.fld-hint { display: block; margin: 6px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.sec-h { margin: 22px 0 10px; font: 700 15px/1.2 var(--sans); }
.back { display: inline-block; margin-bottom: 16px; color: var(--muted); font-size: 14px; text-decoration: none; } .back:hover { color: var(--ink); }

/* segmented control (List / Board, admin tabs) */
.seg { display: inline-flex; border: 1px solid var(--line-strong); }
.seg-b { padding: 0 16px; min-height: 40px; display: inline-flex; align-items: center; border: 0; background: var(--surface); color: var(--muted); font: 600 14px/1 var(--sans); text-decoration: none; cursor: pointer; }
.seg-b + .seg-b { border-left: 1px solid var(--line-strong); }
.seg-b[aria-current] { background: var(--ink); color: var(--bg); }
.admin-host { margin-top: 20px; }

/* stages: the word always, a colour only as a hint */
.stage { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: var(--r-sm); font: 600 12px/1.5 var(--sans); white-space: nowrap; border: 1px solid transparent; }
.stage.click { cursor: pointer; } .stage.click:hover { box-shadow: 0 0 0 2px var(--line-strong); }
.s-new { color: var(--ink); border-color: var(--line-strong); }
.s-contacted { color: var(--ink); background: var(--sunken); }
.s-interested { color: var(--accent-text); background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.s-quoted { color: var(--on-accent); background: var(--accent); }
.s-won { color: var(--success); background: color-mix(in srgb, var(--success) 14%, var(--surface)); }
.s-lost { color: var(--danger); background: color-mix(in srgb, var(--danger) 12%, var(--surface)); }
.s-nurture { color: var(--warn); background: color-mix(in srgb, var(--warn) 13%, var(--surface)); }
.hot-dot { display: inline-flex; align-items: center; gap: 6px; color: var(--accent-text); font: 600 12px/1.4 var(--sans); }
.hot-dot::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }

/* logos and initials */
.logo { width: 44px; height: 44px; flex: none; display: grid; place-items: center; overflow: hidden; background: var(--panel); color: var(--on-panel); font: 700 15px/1 var(--sans); border: 1px solid var(--line); }
.logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.logo.sm { width: 32px; height: 32px; font-size: 12px; } .logo.lg { width: 72px; height: 72px; font-size: 24px; }

/* ---------------- Today ---------------- */
.tsec { margin: 28px 0 0; animation: rise .35s var(--ease) both; }
.tsec-h { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.tsec-h h2 { margin: 0; font: 700 20px/1.2 var(--sans); }
.tsec-h p { flex-basis: 100%; margin: 0; color: var(--muted); font-size: 14px; }
.tsec-h .btn { margin-left: auto; }
.tsec .tab-n { margin-left: 0; }
.tlist { border-top: 1px solid var(--line); }
.trow { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.trow-t { min-width: 0; color: inherit; text-decoration: none; }
.trow-t b { display: block; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow-t small { display: block; color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow-t small.hot { color: var(--accent-text); font-weight: 600; } .trow-t small.late { color: var(--danger); font-weight: 600; } .trow-t small.today { color: var(--ink); font-weight: 600; }
.trow-t:hover b { text-decoration: underline; }
.trow-a { display: flex; gap: 8px; }
.trow-a .btn { min-height: 40px; padding: 0 16px; font-size: 14px; }
.tsec > .btn, .tsec > .linkb { margin-top: 12px; }
@media (max-width: 640px) {
  .trow { grid-template-columns: auto minmax(0, 1fr) auto; }
  .trow .stage { display: none; }
  .trow-a { grid-column: 1 / -1; } .trow-a .btn { flex: 1; }
}

/* ---------------- Companies ---------------- */
.ph-acts { align-items: center; }
.bulk { position: sticky; top: 72px; z-index: 5; display: flex; align-items: center; gap: 10px; margin: 0 0 12px; padding: 10px 14px; background: var(--panel); color: var(--on-panel); }
.bulk .btn.ghost { color: var(--on-panel); border-color: var(--on-panel); }
.ctable { margin-top: 16px; border-top: 1px solid var(--line); }
.crow { display: grid; grid-template-columns: 28px minmax(220px, 2.2fr) 130px 120px minmax(150px, 1.4fr) 150px 100px; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.chead { font: 600 11px/1.3 var(--sans); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); padding: 8px 0; }
.c-cb input { width: 16px; height: 16px; accent-color: var(--accent); }
.c-name { display: flex; align-items: center; gap: 10px; min-width: 0; color: inherit; text-decoration: none; }
.c-name span { min-width: 0; } .c-name b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-name small { display: block; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-name:hover b { text-decoration: underline; }
.c-st { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.c-own, .c-next { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.c-next.late { color: var(--danger); font-weight: 600; } .c-next.today { color: var(--ink); font-weight: 600; }
.c-reach { display: flex; gap: 4px; flex-wrap: wrap; }
.rch { padding: 1px 6px; font: 600 11px/1.5 var(--sans); background: var(--sunken); color: var(--muted); }
.rch.done { background: color-mix(in srgb, var(--success) 14%, var(--surface)); color: var(--success); }
.c-v { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 900px) {
  .chead { display: none; }
  .crow { grid-template-columns: 24px minmax(0, 1fr) auto; row-gap: 4px; }
  .c-own, .c-reach, .c-v { display: none; }
  .c-next { grid-column: 2 / -1; font-size: 13px; }
}
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 12px; margin-top: 16px; overflow-x: auto; padding-bottom: 12px; }
.bcol { background: var(--sunken); min-height: 300px; display: flex; flex-direction: column; }
.bcol.over { outline: 2px dashed var(--accent); outline-offset: -2px; }
.bcol-h { display: flex; align-items: center; gap: 8px; padding: 10px 12px; }
.bcol-h .n { font: 600 13px/1 var(--sans); color: var(--muted); } .bcol-h .v { margin-left: auto; font: 600 12px/1 var(--sans); color: var(--muted); }
.bcol-b { display: flex; flex-direction: column; gap: 8px; padding: 0 8px 10px; overflow-y: auto; max-height: 70vh; }
.bcard { display: block; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); color: inherit; text-decoration: none; cursor: grab; }
.bcard:hover { border-color: var(--line-strong); } .bcard.drag { opacity: .4; }
.bcard-t { display: flex; align-items: center; gap: 8px; } .bcard-t b { font-size: 14px; line-height: 1.25; }
.bcard small { display: block; margin-top: 6px; color: var(--muted); font-size: 12px; }
.bcard-n.late { color: var(--danger); font-weight: 600; } .bcard-n.today { color: var(--ink); font-weight: 600; }
.bcol .more { padding: 4px; color: var(--muted); font-size: 12px; }

/* forms in overlays */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .fld + .fld { margin-top: 0; } .form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.cmp-form .fld { margin-top: 14px; }
.mail-body { font: 400 14px/1.6 var(--sans); }
.fld textarea + .linkb { margin-top: 6px; }

/* ---------------- Company page ---------------- */
.co-h { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; padding-bottom: 18px; border-bottom: 2px solid var(--accent); animation: rise .35s var(--ease) both; }
.co-t { flex: 1 1 300px; min-width: 0; }
.co-t h1 { font-size: 32px; }
.co-ar { margin-top: 4px; color: var(--muted); font-size: 16px; }
.co-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; color: var(--muted); font-size: 14px; }
.co-own { display: flex; gap: 8px; }
.co-next { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 16px 0 0; font-size: 15px; }
.co-next .lbl { color: var(--muted); font: 600 11px/1.3 var(--sans); letter-spacing: 1px; text-transform: uppercase; }
.co-next b.late { color: var(--danger); } .co-next b.today { color: var(--accent-text); }
.co-acts { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0 8px; }
.co-acts .btn { min-height: 42px; padding: 0 16px; font-size: 14px; }
@media (max-width: 640px) { .co-acts .btn { flex: 1 1 calc(50% - 8px); } .co-t h1 { font-size: 26px; } }
.co-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 20px; margin-top: 16px; align-items: start; }
@media (max-width: 900px) { .co-cols { grid-template-columns: 1fr; } .co-r { order: -1; } }
.co-l, .co-r { display: flex; flex-direction: column; gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--line); padding: 18px 20px 20px; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.card-h h2 { margin: 0; font: 700 17px/1.2 var(--sans); }
.ct { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) auto; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.ct b { display: block; } .ct small { color: var(--muted); }
.ct-l { display: flex; flex-direction: column; gap: 2px; min-width: 0; } .ct-l a { color: var(--ink); overflow: hidden; text-overflow: ellipsis; }
.facts { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 8px 14px; margin: 0; font-size: 14px; }
.facts dt { color: var(--muted); } .facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; } .facts a { color: var(--ink); }
.facts .pre { white-space: pre-wrap; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; } .tag { padding: 1px 8px; background: var(--sunken); font-size: 12px; }
.deck-ctl { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 8px; } .deck-ctl .fld + .fld { margin-top: 0; }
.ord { margin: 8px 0 0; padding: 0; list-style: none; counter-reset: o; }
.ord li { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); counter-increment: o; font-size: 14px; }
.ord li::before { content: counter(o); width: 22px; color: var(--muted); font-weight: 600; }
.ord li span { flex: 1; } .ord .icb { width: 28px; height: 28px; }
.ord li:first-child span { font-weight: 700; }
.evs { display: flex; flex-direction: column; }
.ev { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.ev-i { width: 28px; height: 28px; display: grid; place-items: center; background: var(--sunken); color: var(--muted); }
.ev-email .ev-i, .ev-deck_open .ev-i { background: color-mix(in srgb, var(--accent) 14%, var(--surface)); color: var(--accent-text); }
.ev-stage .ev-i { background: var(--panel); color: var(--on-panel); }
.ev-l { font: 600 14px/1.4 var(--sans); } .ev-t { margin-top: 2px; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.ev time { display: block; margin-top: 2px; color: var(--muted); font-size: 12px; }
.ev-mail summary { margin-top: 4px; color: var(--accent-text); font-size: 13px; cursor: pointer; }
.ev-mail pre { margin: 8px 0 0; padding: 12px; background: var(--sunken); white-space: pre-wrap; font: 400 13px/1.55 var(--sans); }

/* call sheet */
.phones { display: flex; flex-direction: column; gap: 8px; }
.phone-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .phone-row .btn.primary { flex: 1; font-size: 17px; letter-spacing: .5px; } .phone-row small { flex-basis: 100%; color: var(--muted); }
.chips.big .chip { min-height: 44px; padding: 0 16px; font-size: 14px; }
.chips.big .chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }

/* undo bar */
.toast.undo { display: flex; align-items: center; gap: 16px; position: relative; overflow: hidden; }
.undo-b { padding: 6px 12px; border: 1px solid var(--on-panel); background: none; color: var(--on-panel); font: 700 13px/1 var(--sans); }
.undo-t { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--accent); transform-origin: left; animation: undo-run linear forwards; }
@keyframes undo-run { to { transform: scaleX(0); } }

/* ---------------- Dashboard ---------------- */
.stats.five { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 860px) { .stats.five { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.dash-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 20px; align-items: start; }
.wide-card { grid-column: 1 / -1; }
.pipe-r { display: grid; grid-template-columns: 110px minmax(0, 1fr) 40px 90px; align-items: center; gap: 10px; padding: 6px 0; font-size: 14px; }
.pipe-r b { text-align: right; } .pipe-r small { color: var(--muted); text-align: right; }
.pipe-bar { height: 10px; background: var(--sunken); } .pipe-bar i { display: block; height: 100%; background: var(--line-strong); }
.pipe-bar i.s-quoted, .pipe-bar i.s-interested { background: var(--accent); } .pipe-bar i.s-won { background: var(--success); } .pipe-bar i.s-lost { background: var(--danger); } .pipe-bar i.s-nurture { background: var(--warn); }
.ptable { font-size: 14px; }
.prow { display: grid; grid-template-columns: minmax(120px, 1.6fr) repeat(6, minmax(0, 1fr)); gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.prow span { text-align: right; font-variant-numeric: tabular-nums; } .prow .zero { color: var(--subtle); }
.phead { font: 600 11px/1.3 var(--sans); letter-spacing: .6px; text-transform: uppercase; color: var(--muted); }

/* ---------------- Account and admin ---------------- */
.sig-pv { margin: 16px 0; padding: 14px; background: var(--sunken); font: 400 14px/1.6 var(--sans); white-space: pre-wrap; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin: 14px 0; }
.step { padding: 14px; border: 1px solid var(--line); } .step h3 { margin: 0 0 6px; font-size: 15px; } .step p { margin: 0 0 8px; color: var(--muted); font-size: 14px; }
.toks { margin: 8px 0 14px; }
.tok, .prsn, .tpl { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.tok b, .prsn b, .tpl b { display: block; } .tok small, .prsn small, .tpl small { display: block; color: var(--muted); font-size: 13px; }
.prsn.off { opacity: .6; } .prsn-a { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.log { max-height: 360px; overflow-y: auto; font-size: 13px; }
.log-r { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); } .log-r time { color: var(--muted); }
/* Claude consent page */
.ask-list { margin: 16px 0 0; padding: 0; list-style: none; }
.ask-list li { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; font-size: 14px; }
.ask-list li svg { flex: none; margin-top: 3px; color: var(--success); } .ask-list li.no svg { color: var(--danger); } .ask-list li.no { color: var(--muted); }
.auth-card h2 em { font-style: normal; color: var(--accent-text); }
/* send queue */
.q-top { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--muted); } .q-top b { color: var(--ink); }
.q-bar { height: 4px; margin: 8px 0 16px; background: var(--sunken); } .q-bar i { display: block; height: 100%; background: var(--accent); transition: width .3s var(--ease); }
.q-co { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; } .q-co div { flex: 1; min-width: 0; } .q-co b { display: block; } .q-co small { color: var(--muted); }
.q-host .fld + .fld { margin-top: 12px; } .q-host .linkb { display: inline-block; margin-top: 8px; }
.q-done { padding: 32px 0; text-align: center; font: 700 22px/1.3 var(--sans); }
/* call script and settings editors */
.script { margin: 14px 0 0; padding: 12px 14px; background: var(--sunken); }
.script summary { cursor: pointer; font: 600 14px/1.4 var(--sans); }
.script-t { margin-top: 10px; white-space: pre-wrap; font-size: 14px; line-height: 1.65; unicode-bidi: plaintext; }
.preset { border-top: 1px solid var(--line); padding: 10px 0; } .preset summary { cursor: pointer; font: 600 14px/1.4 var(--sans); }
.preset .ord, .preset textarea { margin-top: 10px; } .preset .btn { margin-top: 8px; }
.sep { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
.steps-list { margin: 12px 0 16px; padding-left: 20px; font-size: 14px; line-height: 1.6; } .steps-list li { margin-bottom: 6px; }
.adv { margin-top: 12px; font-size: 14px; } .adv summary { cursor: pointer; color: var(--muted); } .adv .fld { margin-top: 10px; }
.rs-key { padding: 14px; margin: 14px 0; background: var(--sunken); } .rs-key p { margin: 0 0 10px; }
.brief { display: flex; justify-content: space-between; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); } .brief.off { opacity: .6; }
.brief b { display: block; } .brief small { color: var(--muted); font-size: 13px; } .brief p { margin: 6px 0 0; font-size: 14px; color: var(--muted); max-width: 70ch; }
