/* =====================================================================
   ClientManager design tokens
   Source of truth for update emails, PDFs and a small frontend site.
   Values are taken from the v3 email template and the November 2026
   beta PDF — do not invent close-enough colours or type.
   ===================================================================== */

:root {
  /* ----- Brand core (from the logo and app UI) ----- */
  --cm-ink: #0A0E1F;                 /* hero base, CTA/avatar fill, wordmark */
  --cm-glow-top: #30167A;            /* hero top-left glow */
  --cm-glow-bottom: #1A2F78;         /* hero bottom-right glow */
  --cm-blue: #0B6EF5;                /* links, accent start, logo ring top+left */
  --cm-violet: #6A1BEA;              /* accent mid, logo ring right+bottom, headline bar */
  --cm-violet-text: #5B1BD6;         /* Improved / Headline pill text; email Improved heading */
  --cm-magenta: #D0328A;             /* accent end, PDF eyebrow dot, tip dot, magenta glow */
  --cm-magenta-check: #C2308F;       /* check mark inside the logo ring (not the same as magenta) */
  --cm-cyan: #0A9CC9;                /* Fixed section dot */
  --cm-cyan-text: #08789C;           /* Fixed pill text */

  /* ----- Surfaces ----- */
  --cm-page: #F4F6F9;                /* email page background */
  --cm-white: #FFFFFF;
  --cm-lavender: #F4F0FF;            /* tip / AI card; app prompt colour */
  --cm-lavender-border: #E4DCFF;     /* tip card border */
  --cm-headline-bg: #F3F1FF;         /* email headline card (solid, Gmail-safe) */
  --cm-headline-border: #E2DDFB;
  --cm-fixes-bg: #FAFBFC;
  --cm-border: #E7E9F0;
  --cm-divider: #EEF0F4;

  /* ----- Text ----- */
  --cm-text: #3F4658;                /* default body, logo tagline on light */
  --cm-text-secondary: #4A5163;      /* card body; email footer brand */
  --cm-muted: #6B7286;               /* section labels, “Kind regards” */
  --cm-footer: #8A90A2;              /* captions, notes, light footer */
  --cm-footer-on-dark: #8A90B4;      /* footer on the dark closing bar (PDF) */
  --cm-hero-text: #D9DCEA;           /* PDF hero / closing body */
  --cm-hero-text-email: #C9CEE3;     /* email hero intro */
  --cm-hero-eyebrow: #B9A8FF;        /* eyebrow, CTA arrow */
  --cm-hero-eyebrow-dot-email: #7FB2FF; /* email eyebrow dot (PDF uses magenta) */
  --cm-on-dark-muted: #B9B4D6;       /* logo tagline on dark */
  --cm-sig-muted: #A9AEC4;           /* sign-off small print on dark */
  --cm-initials: #DCD3FF;            /* avatar letters; month-pill text */
  --cm-tip-text: #2E2A4A;            /* body text on the lavender tip card */
  --cm-month-pill-border: rgba(185, 168, 255, 0.45);
  --cm-shot-shadow-color: rgba(10, 14, 31, 0.08);

  /* ----- Pills ----- */
  --cm-pill-new-bg: #EAF2FF;
  --cm-pill-new-text: #0B5ED7;       /* slightly darker than --cm-blue */
  --cm-pill-imp-bg: #F1EBFF;
  --cm-pill-imp-text: #5B1BD6;
  --cm-pill-fix-bg: #E3F5FB;
  --cm-pill-fix-text: #08789C;
  --cm-pill-head-bg: #FFFFFF;
  --cm-pill-head-border: #DCD3FB;
  --cm-pill-head-text: #5B1BD6;

  /* ----- Accent bar stops (email: six 12×4px cells) ----- */
  --cm-accent-1: #0B6EF5;
  --cm-accent-2: #2F5AF2;
  --cm-accent-3: #5338EE;
  --cm-accent-4: #6A1BEA;
  --cm-accent-5: #9A26BA;
  --cm-accent-6: #D0328A;

  /* ----- Gradients (PDF and site only — emails cannot use these) ----- */
  --cm-hero-bg:
    radial-gradient(120% 70% at 0% 0%, rgba(48, 22, 122, 0.95) 0%, rgba(48, 22, 122, 0) 60%),
    radial-gradient(90% 60% at 100% 100%, rgba(26, 47, 120, 0.95) 0%, rgba(26, 47, 120, 0) 65%),
    radial-gradient(40% 35% at 88% 12%, rgba(208, 50, 138, 0.35) 0%, rgba(208, 50, 138, 0) 70%),
    #0A0E1F;
  --cm-closing-bg:
    radial-gradient(90% 120% at 0% 0%, rgba(48, 22, 122, 0.95), rgba(48, 22, 122, 0) 65%),
    radial-gradient(80% 120% at 100% 100%, rgba(26, 47, 120, 0.95), rgba(26, 47, 120, 0) 70%),
    #0A0E1F;
  --cm-headline-gradient: linear-gradient(135deg, #EEF4FF 0%, #F4F0FF 60%, #FBF0F7 100%);
  --cm-accent-bar: linear-gradient(90deg, #0B6EF5, #6A1BEA 55%, #D0328A);
  --cm-num-bg: linear-gradient(135deg, #0B6EF5, #6A1BEA);

  /* ----- Effects ----- */
  --cm-shot-shadow: 0 4px 14px rgba(10, 14, 31, 0.08);

  /* ----- Radii ----- */
  --cm-radius-shell: 24px;     /* email outer white shell (top and bottom) */
  --cm-radius-hero: 18px;      /* email hero; email headline/tip cards */
  --cm-radius-card: 16px;      /* email feature cards; PDF headline + closing */
  --cm-radius-card-pdf: 14px;  /* PDF feature / fixes cards */
  --cm-radius-shot: 10px;      /* screenshots and mock-ups */
  --cm-radius-pill: 999px;
  --cm-radius-accent: 4px;
  --cm-radius-swatch: 8px;

  /* ----- Logo ring (4-colour border: top, right, bottom, left) ----- */
  --cm-ring-border: #0B6EF5 #6A1BEA #6A1BEA #0B6EF5;

  /* ----- Type stacks ----- */
  --cm-font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --cm-font-email: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  --cm-font-outlook: "Segoe UI", Arial, Helvetica, sans-serif;
  --cm-font-mono: "Roboto Mono", ui-monospace, Menlo, Consolas, monospace;
}

/* Optional starter classes for a PDF or small site. Emails sent through the
   Gmail connector cannot use a <style> block — keep those styles inline. */

.cm-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: var(--cm-hero-bg);
}

.cm-accent {
  height: 4px;
  width: 64px;
  border-radius: var(--cm-radius-accent);
  background: var(--cm-accent-bar);
}

.cm-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--cm-radius-pill);
  font-size: 0.7em;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.cm-pill-new  { background: var(--cm-pill-new-bg);  color: var(--cm-pill-new-text); }
.cm-pill-imp  { background: var(--cm-pill-imp-bg);  color: var(--cm-pill-imp-text); }
.cm-pill-fix  { background: var(--cm-pill-fix-bg);  color: var(--cm-pill-fix-text); }
.cm-pill-head {
  background: var(--cm-pill-head-bg);
  color: var(--cm-pill-head-text);
  border: 1px solid var(--cm-pill-head-border);
}

.cm-card {
  background: var(--cm-white);
  border: 1px solid var(--cm-border);
  border-radius: var(--cm-radius-card-pdf);
  padding: 18px 20px;
}

.cm-cta {
  display: inline-block;
  padding: 15px 32px;
  border-radius: var(--cm-radius-pill);
  background: var(--cm-ink);
  border: 2px solid;
  border-color: var(--cm-ring-border);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.cm-cta span { color: var(--cm-hero-eyebrow); }

.cm-shot {
  display: block;
  width: 100%;
  border-radius: var(--cm-radius-shot);
  border: 1px solid var(--cm-border);
  box-shadow: var(--cm-shot-shadow);
  background: var(--cm-white);
}
