attachment
attachment

This disease report and allopathic medicine prescribe by patient

Reading File
Finding Sources
Searching PubMed

"chronic lymphocytic leukemia" treatment guidelines

Reading File
Reading File
Reading File
Reading File
I now have comprehensive information. Let me compile the full answer.

Disease Report Analysis - Mr. Chiranjee Lal (58 Y/Male)

Report Summary (Peripheral Blood Film - PBF Examination)

ParameterFinding
RBCNormocytic hypochromic with mild anisocytosis; few macrocytes; NRBCs 2/100 WBC; no parasites
WBCIncreased (lymphocytosis); DLC: P-05%, L-80%, M-01%, E-00%; few smudge cells; atypical lymphoid cells / ?prolymphocytes 04%
PlateletsReduced in number, normal morphology (thrombocytopenia)
ImpressionChronic Lymphocytic Leukemia (CLL)
AdviceImmunophenotyping for final confirmation

Diagnosis: Chronic Lymphocytic Leukemia (CLL)

CLL is a mature B-cell malignancy. This report's classic triad - marked lymphocytosis (80%), smudge cells on smear, and thrombocytopenia - is highly characteristic. The atypical lymphoid/?prolymphocyte population at 4% is notable.

What Immunophenotyping Will Confirm

Flow cytometry (immunophenotyping) will look for the CLL-specific pattern:
  • CD5+, CD19+, CD23+ (co-expression of CD5 with B-cell markers is the hallmark)
  • Dim surface immunoglobulin (IgM/IgD)
  • Dim or negative CD20, CD79b
  • Negative FMC-7
Note: An absolute clonal B-lymphocyte count of ≥5 × 10⁹/L on immunophenotyping is required for a definitive CLL diagnosis.

Allopathic (Modern) Treatment Options

Step 1: Staging First (Before Treatment)

Two staging systems are used:
  • Rai staging (USA): Stage 0-IV based on lymphocytosis, lymphadenopathy, organomegaly, anemia, thrombocytopenia
  • Binet staging (Europe): Stage A/B/C
This patient has thrombocytopenia + lymphocytosis - likely Rai Stage III / Binet Stage C (high risk), but formal staging requires clinical exam + CBC values.

Step 2: Treatment Indications (IWCLL Criteria)

Treatment is NOT started in all patients - only when:
  • Symptomatic disease (B symptoms: fever, night sweats, weight loss)
  • Progressive marrow failure (worsening anemia/thrombocytopenia)
  • Massive/progressive splenomegaly or lymphadenopathy
  • Lymphocyte doubling time < 6 months
  • Autoimmune hemolytic anemia or ITP not responding to steroids

First-Line Allopathic Medicines (Current 2025-2026 Guidelines)

A. BTK (Bruton Tyrosine Kinase) Inhibitors - PREFERRED FIRST LINE

DrugDoseNotes
Ibrutinib (Imbruvica)420 mg orally once daily, continuousFirst-generation; risk of AF, bleeding, hypertension
Acalabrutinib (Calquence)100 mg orally twice daily, continuousBetter cardiac profile than ibrutinib
Zanubrutinib (Brukinsa)160 mg orally twice daily, continuousMost selective; preferred in high-risk patients
The NCCN Guidelines Version 2.2026 (PMID: 41825137) recommend BTK inhibitors as preferred therapy for most patients, regardless of fitness status.

B. BCL2 Inhibitor - Fixed Duration Option

RegimenDurationNotes
Venetoclax + Obinutuzumab (VO)1 year fixed durationPreferred in older/less fit patients; CLL14 trial: median PFS 76.2 months
Venetoclax + Ibrutinib (IV)1 year fixed durationApproved in Europe; GLOW trial data (42-month PFS: 74.6%)
  • Venetoclax dose: 400 mg/day orally (after 5-week ramp-up to prevent tumor lysis syndrome)
  • Obinutuzumab: IV infusion, 28-day cycles

C. Chemoimmunotherapy (Older regimen, now less preferred)

RegimenNotes
FCR (Fludarabine + Cyclophosphamide + Rituximab)Still used in younger, fit patients with IGHV-mutated CLL; ~20% can achieve very long-term remission
BR (Bendamustine + Rituximab)For older/less fit patients; less toxic than FCR
Chlorambucil + ObinutuzumabElderly/very unfit patients

Supportive / Adjunct Medications

DrugPurpose
Acyclovir (400 mg BD)Herpes/viral prophylaxis during active treatment
Cotrimoxazole (TMP-SMX)PCP prophylaxis if on venetoclax or steroid combinations
Fluconazole / PosaconazoleAntifungal prophylaxis (ECIL 2025 guidelines, PMID: 40200079)
IVIG (intravenous immunoglobulin)For recurrent infections with hypogammaglobulinemia
PrednisoloneFor autoimmune hemolytic anemia (AIHA) or ITP complicating CLL

Monitoring Parameters

  • CBC every 3-6 months
  • Watch for tumor lysis syndrome (TLS) with venetoclax
  • Monitor for cardiac arrhythmias with ibrutinib
  • Check for Richter's transformation (sudden aggressive lymphoma)

Important Next Steps for This Patient

  1. Immunophenotyping (flow cytometry) - as already advised
  2. FISH cytogenetics - check for del(17p), del(11q), trisomy 12, del(13q) - critical for prognosis and drug choice
  3. IGHV mutational status - unmutated = worse prognosis
  4. CT scan of chest/abdomen/pelvis - full staging
  5. Refer to a haematologist/oncologist - this is a specialist-managed condition

Important Disclaimer: This analysis is for educational purposes only. Actual treatment decisions for Mr. Chiranjee Lal must be made by a qualified haematologist after complete staging workup, including immunophenotyping (as already recommended in the report), FISH cytogenetics, IGHV mutational status, and thorough clinical assessment.
Sources: Harrison's Principles of Internal Medicine 22E (2025); Goldman-Cecil Medicine; NCCN Guidelines CLL/SLL Version 2.2026 (PMID: 41825137); GELLC Spanish CLL Guidelines 2025 (PMID: 39799061)

Generate a clinical reference card showing CLL staging, prognostic markers, and treatment algorithms

Reading File
Reading File
Running Command

mkdir -p /home/daytona/workspace/cll-reference && ls /home/daytona/workspace/cll-reference/

Writing File

~/cll-reference/cll_card.js

const pptxgen = require("pptxgenjs");

const pres = new pptxgen();
pres.layout = "LAYOUT_WIDE"; // 13.3" x 7.5"
pres.title = "CLL Clinical Reference Card";
pres.author = "Orris Medical";

// ─── Color Palette ───────────────────────────────────────────────────────────
const C = {
  navy:    "0A1628",   // dominant dark bg
  deepBlue:"0D2137",
  blue:    "1A3A5C",
  midBlue: "1E5799",
  accent:  "00C2FF",  // vivid cyan accent
  gold:    "F4B942",  // warm gold
  green:   "2ECC71",
  red:     "E74C3C",
  orange:  "F39C12",
  white:   "FFFFFF",
  light:   "E8F4FF",
  muted:   "8BA8C4",
  panel:   "112240",
  panel2:  "0E1F38",
  panel3:  "163352",
  success: "27AE60",
  warn:    "E67E22",
};

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 1 — Title / Cover
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();

  // Full dark background
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });

  // Left accent bar
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.accent } });

  // Top accent strip
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.06, fill: { color: C.accent } });

  // Large hex decorative shape (background)
  s.addShape(pres.ShapeType.rect, { x: 8.5, y: 0.5, w: 4.5, h: 6.5,
    fill: { color: C.panel }, line: { color: C.midBlue, width: 1 } });

  // Blood cell icon placeholder (circle motif)
  s.addShape(pres.ShapeType.ellipse, { x: 9.2, y: 1.0, w: 3.1, h: 3.1,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 2 } });
  s.addShape(pres.ShapeType.ellipse, { x: 9.6, y: 1.4, w: 2.3, h: 2.3,
    fill: { color: C.deepBlue }, line: { color: C.midBlue, width: 1 } });
  s.addText("🩸", { x: 9.9, y: 1.7, w: 1.7, h: 1.7, fontSize: 54, align: "center", valign: "middle" });

  // Right panel info
  s.addText("HAEMATOLOGY", { x: 8.8, y: 4.4, w: 4.2, h: 0.45,
    fontSize: 11, bold: true, color: C.accent, charSpacing: 4, align: "center" });
  s.addText("QUICK REFERENCE", { x: 8.8, y: 4.85, w: 4.2, h: 0.38,
    fontSize: 9, color: C.muted, charSpacing: 3, align: "center" });
  s.addText("Based on NCCN v2.2026 & Harrison's 22E", { x: 8.5, y: 5.3, w: 4.7, h: 0.35,
    fontSize: 8, color: C.muted, align: "center", italic: true });

  // Main title
  s.addText("CLL", { x: 0.6, y: 1.0, w: 7.6, h: 2.0,
    fontSize: 110, bold: true, color: C.white, fontFace: "Arial Black", align: "left", margin: 0 });

  s.addText("Chronic Lymphocytic Leukemia", { x: 0.65, y: 3.0, w: 7.6, h: 0.7,
    fontSize: 24, bold: false, color: C.accent, align: "left", charSpacing: 1 });

  s.addText("Clinical Reference Card", { x: 0.65, y: 3.65, w: 7.6, h: 0.55,
    fontSize: 17, color: C.muted, align: "left" });

  // Divider line
  s.addShape(pres.ShapeType.rect, { x: 0.65, y: 4.35, w: 6.5, h: 0.04, fill: { color: C.midBlue } });

  // Key facts row
  const facts = [
    { label: "Most Common", value: "Leukemia in West" },
    { label: "Median Age", value: "70 years" },
    { label: "M:F Ratio", value: "2 : 1" },
    { label: "5-yr Survival", value: "~92%" },
  ];
  facts.forEach((f, i) => {
    const bx = 0.65 + i * 1.9;
    s.addShape(pres.ShapeType.rect, { x: bx, y: 4.55, w: 1.7, h: 0.9,
      fill: { color: C.panel }, line: { color: C.midBlue, width: 1 } });
    s.addText(f.value, { x: bx, y: 4.6, w: 1.7, h: 0.45,
      fontSize: 11, bold: true, color: C.gold, align: "center" });
    s.addText(f.label, { x: bx, y: 5.02, w: 1.7, h: 0.35,
      fontSize: 8, color: C.muted, align: "center" });
  });

  // Bottom tag
  s.addText("Staging  •  Prognostic Markers  •  Treatment Algorithms  •  Monitoring", {
    x: 0.65, y: 6.8, w: 11.0, h: 0.4,
    fontSize: 9, color: C.muted, align: "left", italic: true
  });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 2 — Diagnosis & Staging
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.accent } });

  // Slide title bar
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("DIAGNOSIS & STAGING", { x: 0.5, y: 0.05, w: 8, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 2 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // ── RAI STAGING ──────────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.9, w: 5.8, h: 0.4,
    fill: { color: C.midBlue }, line: { color: C.accent, width: 1 } });
  s.addText("RAI STAGING SYSTEM", { x: 0.45, y: 0.9, w: 5.8, h: 0.4,
    fontSize: 11, bold: true, color: C.white, align: "center", charSpacing: 2 });

  const raiRows = [
    ["Stage 0", "Lymphocytosis only", "Low Risk", C.green],
    ["Stage I", "Lymphocytosis + Lymphadenopathy", "Intermediate", C.gold],
    ["Stage II", "Lymphocytosis + Splenomegaly/Hepatomegaly", "Intermediate", C.gold],
    ["Stage III", "Lymphocytosis + Anemia (Hgb <11 g/dL)", "High Risk", C.red],
    ["Stage IV", "Lymphocytosis + Thrombocytopenia (Plt <100K)", "High Risk", C.red],
  ];

  raiRows.forEach((r, i) => {
    const ry = 1.38 + i * 0.72;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 5.8, h: 0.66, fill: { color: bg } });
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 0.9, h: 0.66, fill: { color: r[3] + "33" } });
    s.addText(r[0], { x: 0.45, y: ry, w: 0.9, h: 0.66, fontSize: 10, bold: true, color: r[3], align: "center", valign: "middle" });
    s.addText(r[1], { x: 1.38, y: ry, w: 3.4, h: 0.66, fontSize: 9, color: C.light, valign: "middle", margin: 4 });
    s.addShape(pres.ShapeType.rect, { x: 4.8, y: ry + 0.1, w: 1.3, h: 0.46,
      fill: { color: r[3] + "44" }, line: { color: r[3], width: 1 } });
    s.addText(r[2], { x: 4.8, y: ry + 0.1, w: 1.3, h: 0.46, fontSize: 8, bold: true, color: r[3], align: "center", valign: "middle" });
  });

  // ── BINET STAGING ────────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fill: { color: C.midBlue }, line: { color: C.gold, width: 1 } });
  s.addText("BINET STAGING SYSTEM", { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fontSize: 11, bold: true, color: C.white, align: "center", charSpacing: 2 });

  const binetRows = [
    ["A", "< 3 enlarged lymphoid areas; No anemia/thrombocytopenia", "Median Survival: >10 yrs", C.green],
    ["B", "≥ 3 enlarged lymphoid areas; No anemia/thrombocytopenia", "Median Survival: 7 yrs", C.gold],
    ["C", "Anemia (Hgb <10 g/dL) AND/OR Thrombocytopenia (<100K)", "Median Survival: 2-4 yrs", C.red],
  ];

  binetRows.forEach((r, i) => {
    const ry = 1.38 + i * 0.78;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 6.8, y: ry, w: 6.1, h: 0.72, fill: { color: bg } });
    s.addShape(pres.ShapeType.rect, { x: 6.8, y: ry, w: 0.6, h: 0.72, fill: { color: r[3] + "55" } });
    s.addText("Stage\n" + r[0], { x: 6.8, y: ry, w: 0.6, h: 0.72, fontSize: 9, bold: true, color: r[3], align: "center", valign: "middle" });
    s.addText(r[1], { x: 7.45, y: ry, w: 3.7, h: 0.72, fontSize: 9, color: C.light, valign: "middle", margin: 4 });
    s.addText(r[2], { x: 11.2, y: ry, w: 1.6, h: 0.72, fontSize: 8, bold: true, color: r[3], align: "center", valign: "middle" });
  });

  // ── DIAGNOSTIC CRITERIA ──────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 3.82, w: 6.1, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("DIAGNOSTIC CRITERIA", { x: 6.8, y: 3.82, w: 6.1, h: 0.38,
    fontSize: 10, bold: true, color: C.accent, align: "center", charSpacing: 1 });

  const diagCrit = [
    "Clonal B-lymphocytes ≥ 5 × 10⁹/L in peripheral blood",
    "Monoclonal B-cell lymphocytosis with CLL immunophenotype",
    "Immunophenotype: CD5+, CD19+, CD23+, dim CD20, dim sIg",
    "Smudge (smear) cells on peripheral blood film",
    "< 55% prolymphocytes (>55% = B-PLL, different entity)",
  ];

  diagCrit.forEach((d, i) => {
    const dy = 4.27 + i * 0.49;
    s.addShape(pres.ShapeType.ellipse, { x: 6.85, y: dy + 0.12, w: 0.22, h: 0.22,
      fill: { color: C.accent } });
    s.addText(d, { x: 7.15, y: dy, w: 5.65, h: 0.44,
      fontSize: 9, color: C.light, valign: "middle" });
  });

  // Footnote
  s.addText("*This patient (Chiranjee Lal): Lymphocytosis 80%, Smudge cells, Thrombocytopenia → Likely Rai Stage III-IV / Binet C. Awaiting immunophenotyping.", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34,
    fontSize: 7.5, color: C.gold, italic: true
  });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 3 — Prognostic Markers
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.gold } });

  // Title bar
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("PROGNOSTIC MARKERS", { x: 0.5, y: 0.05, w: 8, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 3 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // ── FISH CYTOGENETICS ─────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.9, w: 6.0, h: 0.4,
    fill: { color: C.midBlue } });
  s.addText("FISH CYTOGENETICS (Prognostic Impact)", { x: 0.45, y: 0.9, w: 6.0, h: 0.4,
    fontSize: 10, bold: true, color: C.white, align: "center", charSpacing: 1 });

  const fishData = [
    ["del(13q) sole", "55%", "Best", "Median OS >10 yrs", C.green],
    ["Normal", "18%", "Good", "Median OS ~7 yrs", C.green],
    ["Trisomy 12", "16%", "Intermediate", "Median OS ~7 yrs", C.gold],
    ["del(11q)", "18%", "Poor", "Median OS ~6 yrs", C.orange],
    ["del(17p)", "7%", "Very Poor", "Median OS ~2-3 yrs", C.red],
  ];

  fishData.forEach((r, i) => {
    const ry = 1.37 + i * 0.62;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 6.0, h: 0.58, fill: { color: bg } });
    s.addText(r[0], { x: 0.5, y: ry, w: 1.8, h: 0.58, fontSize: 9, bold: true, color: r[4], valign: "middle", margin: 3 });
    s.addText("Freq: " + r[1], { x: 2.35, y: ry, w: 0.9, h: 0.58, fontSize: 8, color: C.muted, valign: "middle", align: "center" });
    s.addShape(pres.ShapeType.rect, { x: 3.3, y: ry + 0.1, w: 1.2, h: 0.38,
      fill: { color: r[4] + "33" }, line: { color: r[4], width: 1 } });
    s.addText(r[2], { x: 3.3, y: ry + 0.1, w: 1.2, h: 0.38, fontSize: 8, bold: true, color: r[4], align: "center", valign: "middle" });
    s.addText(r[3], { x: 4.58, y: ry, w: 1.8, h: 0.58, fontSize: 8, color: C.light, valign: "middle" });
  });

  // ── IGHV MUTATION STATUS ──────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fill: { color: C.midBlue } });
  s.addText("IGHV MUTATION STATUS", { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fontSize: 10, bold: true, color: C.white, align: "center", charSpacing: 1 });

  // Mutated
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 1.37, w: 2.9, h: 2.4, fill: { color: C.panel }, line: { color: C.green, width: 2 } });
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 1.37, w: 2.9, h: 0.38, fill: { color: C.green + "55" } });
  s.addText("MUTATED IGHV", { x: 6.8, y: 1.37, w: 2.9, h: 0.38, fontSize: 9, bold: true, color: C.green, align: "center", valign: "middle" });
  const mutLines = ["≥ 2% divergence from germline", "Favorable prognosis", "Slower progression", "Possible cure with FCR*", "ZAP-70 negative", "CD38 negative"];
  mutLines.forEach((l, i) => {
    s.addShape(pres.ShapeType.rect, { x: 6.9, y: 1.85 + i * 0.32, w: 0.15, h: 0.15, fill: { color: C.green } });
    s.addText(l, { x: 7.1, y: 1.8 + i * 0.32, w: 2.5, h: 0.3, fontSize: 8.5, color: C.light });
  });

  // Unmutated
  s.addShape(pres.ShapeType.rect, { x: 9.8, y: 1.37, w: 3.1, h: 2.4, fill: { color: C.panel }, line: { color: C.red, width: 2 } });
  s.addShape(pres.ShapeType.rect, { x: 9.8, y: 1.37, w: 3.1, h: 0.38, fill: { color: C.red + "55" } });
  s.addText("UNMUTATED IGHV", { x: 9.8, y: 1.37, w: 3.1, h: 0.38, fontSize: 9, bold: true, color: C.red, align: "center", valign: "middle" });
  const unmutLines = ["< 2% divergence from germline", "Unfavorable prognosis", "Faster progression", "BTK/BCL2 inhibitors preferred", "ZAP-70 positive", "CD38 positive"];
  unmutLines.forEach((l, i) => {
    s.addShape(pres.ShapeType.rect, { x: 9.9, y: 1.85 + i * 0.32, w: 0.15, h: 0.15, fill: { color: C.red } });
    s.addText(l, { x: 10.1, y: 1.8 + i * 0.32, w: 2.7, h: 0.3, fontSize: 8.5, color: C.light });
  });

  // ── OTHER MARKERS ─────────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 4.55, w: 12.45, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("OTHER KEY PROGNOSTIC FACTORS", { x: 0.45, y: 4.55, w: 12.45, h: 0.38,
    fontSize: 10, bold: true, color: C.accent, align: "center", charSpacing: 1 });

  const otherMarkers = [
    { title: "TP53 Mutation", good: "Absent", bad: "Mutated / del(17p)", impact: "Resistance to chemo; mandate BTK/BCL2", color: C.red },
    { title: "β2-Microglobulin", good: "< 3.5 mg/L", bad: "> 3.5 mg/L", impact: "Independent poor prognosis marker", color: C.orange },
    { title: "Serum TK1", good: "Low", bad: "Elevated", impact: "Rapid disease progression predictor", color: C.gold },
    { title: "Lymphocyte DT", good: "> 12 months", bad: "< 6 months", impact: "Treatment trigger if < 6 months", color: C.gold },
  ];

  otherMarkers.forEach((m, i) => {
    const mx = 0.5 + i * 3.1;
    s.addShape(pres.ShapeType.rect, { x: mx, y: 5.0, w: 3.0, h: 2.2,
      fill: { color: C.panel }, line: { color: m.color, width: 1 } });
    s.addText(m.title, { x: mx, y: 5.02, w: 3.0, h: 0.38,
      fontSize: 9, bold: true, color: m.color, align: "center" });
    s.addText("Favorable: " + m.good, { x: mx + 0.1, y: 5.46, w: 2.8, h: 0.36,
      fontSize: 8, color: C.green });
    s.addText("Adverse: " + m.bad, { x: mx + 0.1, y: 5.82, w: 2.8, h: 0.36,
      fontSize: 8, color: C.red });
    s.addShape(pres.ShapeType.rect, { x: mx + 0.05, y: 6.22, w: 2.9, h: 0.04,
      fill: { color: C.midBlue } });
    s.addText(m.impact, { x: mx + 0.1, y: 6.28, w: 2.8, h: 0.7,
      fontSize: 7.5, color: C.muted, italic: true });
  });

  // CLL-IPI note
  s.addText("CLL-IPI Score integrates: IGHV status + TP53 status + β2-microglobulin + clinical stage + age → Stratifies into Low / Intermediate / High / Very High risk", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34,
    fontSize: 7.5, color: C.gold, italic: true
  });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 4 — Treatment Algorithm
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.green } });

  // Title bar
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("TREATMENT ALGORITHM — FIRST LINE", { x: 0.5, y: 0.05, w: 8, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 4 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // ── Decision Box: Treat or Watch ─────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 4.4, y: 0.85, w: 4.5, h: 0.65,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 2 } });
  s.addText("NEW CLL DIAGNOSIS — Assess Treatment Indication", {
    x: 4.4, y: 0.85, w: 4.5, h: 0.65, fontSize: 9, bold: true, color: C.accent, align: "center", valign: "middle" });

  // Arrow down
  s.addShape(pres.ShapeType.rect, { x: 6.4, y: 1.5, w: 0.5, h: 0.4, fill: { color: C.midBlue } });

  // Two branches
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 1.92, w: 5.5, h: 0.55,
    fill: { color: C.green + "33" }, line: { color: C.green, width: 2 } });
  s.addText("WATCH & WAIT (No treatment needed)", {
    x: 0.45, y: 1.92, w: 5.5, h: 0.55, fontSize: 9.5, bold: true, color: C.green, align: "center", valign: "middle" });

  s.addShape(pres.ShapeType.rect, { x: 7.35, y: 1.92, w: 5.5, h: 0.55,
    fill: { color: C.red + "33" }, line: { color: C.red, width: 2 } });
  s.addText("TREAT — Meets IWCLL Criteria", {
    x: 7.35, y: 1.92, w: 5.5, h: 0.55, fontSize: 9.5, bold: true, color: C.red, align: "center", valign: "middle" });

  // Watch & Wait indications
  s.addText("Indications for W&W:", { x: 0.5, y: 2.55, w: 5.3, h: 0.3, fontSize: 8.5, bold: true, color: C.muted });
  const wwItems = ["Early Rai 0-II / Binet A-B (asymptomatic)", "No anemia or thrombocytopenia", "Lymphocyte doubling time > 12 months", "No B symptoms (fever, night sweats, wt loss)"];
  wwItems.forEach((t, i) => {
    s.addShape(pres.ShapeType.ellipse, { x: 0.52, y: 2.9 + i * 0.4 + 0.07, w: 0.17, h: 0.17, fill: { color: C.green } });
    s.addText(t, { x: 0.76, y: 2.88 + i * 0.4, w: 5.0, h: 0.36, fontSize: 8.5, color: C.light });
  });
  s.addText("Monitor: CBC every 3-6 months", { x: 0.5, y: 4.5, w: 5.3, h: 0.35,
    fontSize: 8.5, color: C.gold, italic: true });

  // Treatment criteria
  s.addText("IWCLL Treatment Triggers:", { x: 7.4, y: 2.55, w: 5.3, h: 0.3, fontSize: 8.5, bold: true, color: C.muted });
  const txItems = ["B symptoms (fever/night sweats/wt loss >10%)", "Progressive marrow failure (↑ anemia/thrombocytopenia)", "Massive/progressive splenomegaly or lymphadenopathy", "Lymphocyte doubling time < 6 months", "AIHA/ITP not responsive to corticosteroids"];
  txItems.forEach((t, i) => {
    s.addShape(pres.ShapeType.rect, { x: 7.42, y: 2.9 + i * 0.38 + 0.07, w: 0.17, h: 0.17, fill: { color: C.red } });
    s.addText(t, { x: 7.66, y: 2.88 + i * 0.38, w: 5.0, h: 0.36, fontSize: 8.5, color: C.light });
  });

  // ── Treatment Options ─────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 4.55, w: 6.1, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("PREFERRED FIRST-LINE REGIMENS (NCCN v2.2026)", { x: 6.8, y: 4.55, w: 6.1, h: 0.38,
    fontSize: 9, bold: true, color: C.accent, align: "center" });

  const txOptions = [
    { drug: "Zanubrutinib", dose: "160 mg BID, continuous", cat: "BTK inhibitor", pref: "PREFERRED", color: C.green },
    { drug: "Acalabrutinib", dose: "100 mg BID ± obinutuzumab, continuous", cat: "BTK inhibitor", pref: "PREFERRED", color: C.green },
    { drug: "Ibrutinib", dose: "420 mg OD, continuous", cat: "BTK inhibitor", pref: "Acceptable", color: C.gold },
    { drug: "Venetoclax + Obinutuzumab", dose: "Ramp to 400 mg OD × 1 yr fixed", cat: "BCL2 + Anti-CD20", pref: "PREFERRED", color: C.green },
  ];

  txOptions.forEach((r, i) => {
    const rx = 6.85 + (i % 2) * 3.05;
    const ry = 5.02 + Math.floor(i / 2) * 0.92;
    s.addShape(pres.ShapeType.rect, { x: rx, y: ry, w: 2.95, h: 0.82,
      fill: { color: C.panel }, line: { color: r.color, width: 1.5 } });
    s.addShape(pres.ShapeType.rect, { x: rx, y: ry, w: 2.95, h: 0.26, fill: { color: r.color + "44" } });
    s.addText(r.drug, { x: rx + 0.05, y: ry, w: 2.2, h: 0.26, fontSize: 9, bold: true, color: r.color, valign: "middle", margin: 2 });
    s.addShape(pres.ShapeType.rect, { x: rx + 2.25, y: ry + 0.03, w: 0.65, h: 0.21,
      fill: { color: r.color + "88" } });
    s.addText(r.pref, { x: rx + 2.25, y: ry + 0.03, w: 0.65, h: 0.21,
      fontSize: 6, bold: true, color: C.white, align: "center", valign: "middle" });
    s.addText(r.cat, { x: rx + 0.05, y: ry + 0.28, w: 2.85, h: 0.24, fontSize: 7.5, color: C.muted });
    s.addText(r.dose, { x: rx + 0.05, y: ry + 0.52, w: 2.85, h: 0.28, fontSize: 7.5, color: C.light });
  });

  // Note
  s.addText("Note: For del(17p)/TP53-mutated CLL → BTK inhibitors are mandatory (chemo not effective). FCR still considered in fit young patients with mutated IGHV, favorable cytogenetics.", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34, fontSize: 7.5, color: C.gold, italic: true });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 5 — Drug Details & Monitoring
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.orange } });

  // Title bar
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("DRUG DETAILS, MONITORING & RELAPSED CLL", { x: 0.5, y: 0.05, w: 9, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 5 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // ── Drug Table ─────────────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.85, w: 12.45, h: 0.38,
    fill: { color: C.midBlue } });
  const drugHdrs = ["Drug", "Mechanism", "Dose", "Key Adverse Effects", "Monitoring"];
  const drugHdrW = [1.8, 1.9, 2.2, 3.5, 3.0];
  let hx = 0.45;
  drugHdrs.forEach((h, i) => {
    s.addText(h, { x: hx + 0.04, y: 0.85, w: drugHdrW[i], h: 0.38,
      fontSize: 9, bold: true, color: C.white, valign: "middle" });
    hx += drugHdrW[i];
  });

  const drugs = [
    ["Ibrutinib", "BTK inhibitor (1st gen)", "420 mg OD oral", "AF (10%), bleeding, HTN, rash, arthralgias", "ECG baseline, BP, CBC monthly", C.gold],
    ["Acalabrutinib", "BTK inhibitor (2nd gen)", "100 mg BID oral", "Headache, cough, less AF risk vs ibrutinib", "CBC, LFT q3 months", C.green],
    ["Zanubrutinib", "BTK inhibitor (3rd gen)", "160 mg BID oral", "Least cardiac risk; neutropenia, rash", "CBC, LFT q3 months", C.green],
    ["Venetoclax", "BCL2 inhibitor", "Ramp-up → 400 mg OD", "Tumor lysis syndrome (TLS!), neutropenia, N/V/D", "TLS labs D1, D8, D15; CBC weekly", C.red],
    ["Obinutuzumab", "Anti-CD20 monoclonal Ab", "IV per protocol cycles", "Infusion reactions, neutropenia, HBV reactivation", "HBV serology before; CBC each cycle", C.orange],
    ["Rituximab", "Anti-CD20 monoclonal Ab", "375-500 mg/m² IV", "Infusion reactions, PML risk", "HBV, CBC, LFT", C.orange],
    ["Bendamustine", "Alkylating agent", "70-90 mg/m² IV D1+2", "Myelosuppression, infections, nausea", "CBC day 21-28, LFT", C.muted],
    ["Fludarabine", "Purine analogue", "25 mg/m² IV D1-3", "Prolonged myelosuppression, autoimmune AIHA", "CBC; avoid if del(17p)", C.muted],
  ];

  drugs.forEach((d, i) => {
    const ry = 1.3 + i * 0.52;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 12.45, h: 0.5, fill: { color: bg } });
    let dx = 0.45;
    const vals = [d[0], d[1], d[2], d[3], d[4]];
    vals.forEach((v, j) => {
      const isFirst = j === 0;
      s.addText(v, { x: dx + 0.04, y: ry, w: drugHdrW[j] - 0.08, h: 0.5,
        fontSize: isFirst ? 9 : 8, bold: isFirst, color: isFirst ? d[5] : C.light, valign: "middle", margin: 2 });
      dx += drugHdrW[j];
    });
  });

  // ── Prophylaxis box ─────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 5.55, w: 5.9, h: 0.35,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("SUPPORTIVE PROPHYLAXIS", { x: 0.45, y: 5.55, w: 5.9, h: 0.35,
    fontSize: 9, bold: true, color: C.accent, align: "center" });
  const prophylaxis = [
    "Acyclovir 400 mg BID — Viral (HSV/VZV) prophylaxis during treatment",
    "TMP-SMX — PCP prophylaxis with venetoclax or steroid combos",
    "Posaconazole/Fluconazole — Antifungal prophylaxis (ECIL 2025)",
    "IVIG — Recurrent infections with hypogammaglobulinemia",
    "Prednisolone — AIHA or ITP complicating CLL",
  ];
  prophylaxis.forEach((p, i) => {
    s.addText("• " + p, { x: 0.55, y: 5.96 + i * 0.3, w: 5.7, h: 0.28,
      fontSize: 7.8, color: C.light });
  });

  // ── Relapsed CLL ───────────────────────────────────────────────────────────
  s.addShape(pres.ShapeType.rect, { x: 6.55, y: 5.55, w: 6.35, h: 0.35,
    fill: { color: C.red + "44" }, line: { color: C.red, width: 1 } });
  s.addText("RELAPSED / REFRACTORY CLL", { x: 6.55, y: 5.55, w: 6.35, h: 0.35,
    fontSize: 9, bold: true, color: C.red, align: "center" });
  const relapsedTx = [
    "Switch BTK inhibitor class (e.g. ibrutinib → acalabrutinib/zanubrutinib)",
    "Venetoclax + rituximab — If not previously used",
    "Pirtobrutinib (non-covalent BTK inhibitor) — After covalent BTK failure",
    "Allo-SCT — High-risk young patients, multiply relapsed",
    "CAR-T cell therapy — Investigational in R/R CLL with del(17p)",
  ];
  relapsedTx.forEach((p, i) => {
    s.addText("• " + p, { x: 6.65, y: 5.96 + i * 0.3, w: 6.1, h: 0.28,
      fontSize: 7.8, color: C.light });
  });

  // Final footer
  s.addText("Sources: Harrison's Principles of Internal Medicine 22E (2025) | Goldman-Cecil Medicine | NCCN CLL/SLL Guidelines v2.2026 | GELLC Spanish Guidelines 2025", {
    x: 0.45, y: 7.2, w: 12.7, h: 0.25, fontSize: 6.5, color: C.muted, italic: true });
}

// ─── Write file ───────────────────────────────────────────────────────────────
pres.writeFile({ fileName: "/home/daytona/workspace/cll-reference/CLL_Clinical_Reference_Card.pptx" })
  .then(() => console.log("SUCCESS: CLL_Clinical_Reference_Card.pptx written"))
  .catch(e => { console.error("ERROR:", e); process.exit(1); });
Running Command

cd /home/daytona/workspace/cll-reference && node cll_card.js

Running Command

cd /home/daytona/workspace/cll-reference && node -e " // Fix: replace all 8-char hex colors (with alpha) with proper 6-char hex via transparency object const fs = require('fs'); let code = fs.readFileSync('cll_card.js', 'utf8'); // Replace color + '33' style with fill: { color: ..., transparency: 80 } // We need to do this in-place in the shapes - simpler: just replace the hex patterns // Pattern: C.xxx + '33' => use lighter solid color instead // Map our alpha shortcuts to solid approximations: const replacements = [ [/\{ color: r\[3\] \+ '33' \}/g, \"{ color: 'FFFFFF', transparency: 85 }\"], [/\{ color: r\[3\] \+ '44' \}/g, \"{ color: 'FFFFFF', transparency: 80 }\"], [/\{ color: r\[3\] \+ '55' \}/g, \"{ color: 'FFFFFF', transparency: 75 }\"], [/\{ color: r\[3\] \+ '88' \}/g, \"{ color: 'FFFFFF', transparency: 60 }\"], [/\{ color: C\.green \+ '33' \}/g, \"{ color: '1A5C34', transparency: 0 }\"], [/\{ color: C\.green \+ '44' \}/g, \"{ color: '1E6B3E' }\"], [/\{ color: C\.green \+ '55' \}/g, \"{ color: '1E7A45' }\"], [/\{ color: C\.green \+ '88' \}/g, \"{ color: '27AE60' }\"], [/\{ color: C\.red \+ '33' \}/g, \"{ color: '5C1A1A' }\"], [/\{ color: C\.red \+ '44' \}/g, \"{ color: '6B1E1E' }\"], [/\{ color: C\.red \+ '55' \}/g, \"{ color: '7A2020' }\"], [/\{ color: C\.red \+ '88' \}/g, \"{ color: 'A93226' }\"], [/\{ color: C\.gold \+ '33' \}/g, \"{ color: '4A3A10' }\"], [/\{ color: C\.gold \+ '44' \}/g, \"{ color: '5A4612' }\"], [/\{ color: C\.gold \+ '55' \}/g, \"{ color: '6B5215' }\"], [/\{ color: C\.gold \+ '88' \}/g, \"{ color: 'B8892E' }\"], [/\{ color: C\.orange \+ '33' \}/g, \"{ color: '4A2D08' }\"], [/\{ color: C\.orange \+ '44' \}/g, \"{ color: '5A3609' }\"], [/\{ color: C\.orange \+ '88' \}/g, \"{ color: 'B5770E' }\"], [/\{ color: C\.accent \+ '33' \}/g, \"{ color: '003B4D' }\"], [/\{ color: C\.midBlue \+ '33' \}/g, \"{ color: '0A2140' }\"], [/\{ color: r\[4\] \+ '33' \}/g, \"{ color: '0E2030' }\"], [/\{ color: r\[4\] \+ '44' \}/g, \"{ color: '0E2535' }\"], [/\{ color: r\[4\] \+ '88' \}/g, \"{ color: '1E4A6A' }\"], [/\{ color: m\.color \+ '33' \}/g, \"{ color: '0E2030' }\"], [/\{ color: r\.color \+ '33' \}/g, \"{ color: '0E2030' }\"], [/\{ color: r\.color \+ '44' \}/g, \"{ color: '0E2535' }\"], [/\{ color: r\.color \+ '88' \}/g, \"{ color: '1E4A6A' }\"], [/\{ color: C\.red \+ \"44\" \}/g, \"{ color: '6B1E1E' }\"], ]; replacements.forEach(([pat, repl]) => { code = code.replace(pat, repl); }); fs.writeFileSync('cll_card_fixed.js', code); console.log('Done writing fixed version'); "

Running Command

cd /home/daytona/workspace/cll-reference && node cll_card_fixed.js 2>&1 | head -30

Writing File

~/cll-reference/cll_final.js

const pptxgen = require("pptxgenjs");

const pres = new pptxgen();
pres.layout = "LAYOUT_WIDE"; // 13.3" x 7.5"
pres.title = "CLL Clinical Reference Card";
pres.author = "Orris Medical";

// ─── Color Palette (all 6-digit hex only) ───────────────────────────────────
const C = {
  navy:    "0A1628",
  deepBlue:"0D2137",
  blue:    "1A3A5C",
  midBlue: "1E5799",
  accent:  "00C2FF",
  gold:    "F4B942",
  green:   "2ECC71",
  red:     "E74C3C",
  orange:  "F39C12",
  white:   "FFFFFF",
  light:   "E8F4FF",
  muted:   "8BA8C4",
  panel:   "112240",
  panel2:  "0E1F38",
  panel3:  "163352",
  success: "27AE60",
  warn:    "E67E22",
  // Pre-mixed "tinted" solids for semi-transparent effects
  greenDark:  "1A5C34",
  greenMid:   "217A46",
  greenLight: "27AE60",
  redDark:    "5C1A1A",
  redMid:     "7A2020",
  redLight:   "A93226",
  goldDark:   "4A3A10",
  goldMid:    "6B5215",
  goldLight:  "B8892E",
  orangeDark: "4A2D08",
  orangeMid:  "5A3609",
  blueDark:   "0A2140",
  blueAccent: "003B4D",
};

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 1 — Title / Cover
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();

  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.accent } });
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.06, fill: { color: C.accent } });
  s.addShape(pres.ShapeType.rect, { x: 8.5, y: 0.5, w: 4.5, h: 6.5,
    fill: { color: C.panel }, line: { color: C.midBlue, width: 1 } });

  // Blood cell decorative circles
  s.addShape(pres.ShapeType.ellipse, { x: 9.2, y: 1.0, w: 3.1, h: 3.1,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 2 } });
  s.addShape(pres.ShapeType.ellipse, { x: 9.6, y: 1.4, w: 2.3, h: 2.3,
    fill: { color: C.deepBlue }, line: { color: C.midBlue, width: 1 } });
  s.addText("🩸", { x: 9.9, y: 1.7, w: 1.7, h: 1.7, fontSize: 54, align: "center", valign: "middle" });

  s.addText("HAEMATOLOGY", { x: 8.8, y: 4.4, w: 4.2, h: 0.45,
    fontSize: 11, bold: true, color: C.accent, charSpacing: 4, align: "center" });
  s.addText("QUICK REFERENCE", { x: 8.8, y: 4.85, w: 4.2, h: 0.38,
    fontSize: 9, color: C.muted, charSpacing: 3, align: "center" });
  s.addText("Based on NCCN v2.2026 & Harrison's 22E", { x: 8.5, y: 5.3, w: 4.7, h: 0.35,
    fontSize: 8, color: C.muted, align: "center", italic: true });

  s.addText("CLL", { x: 0.6, y: 1.0, w: 7.6, h: 2.0,
    fontSize: 110, bold: true, color: C.white, fontFace: "Arial Black", align: "left", margin: 0 });
  s.addText("Chronic Lymphocytic Leukemia", { x: 0.65, y: 3.0, w: 7.6, h: 0.7,
    fontSize: 24, color: C.accent, align: "left", charSpacing: 1 });
  s.addText("Clinical Reference Card", { x: 0.65, y: 3.65, w: 7.6, h: 0.55,
    fontSize: 17, color: C.muted, align: "left" });
  s.addShape(pres.ShapeType.rect, { x: 0.65, y: 4.35, w: 6.5, h: 0.04, fill: { color: C.midBlue } });

  const facts = [
    { label: "Most Common", value: "Leukemia in West" },
    { label: "Median Age", value: "70 years" },
    { label: "M:F Ratio", value: "2 : 1" },
    { label: "5-yr Survival", value: "~92%" },
  ];
  facts.forEach((f, i) => {
    const bx = 0.65 + i * 1.9;
    s.addShape(pres.ShapeType.rect, { x: bx, y: 4.55, w: 1.7, h: 0.9,
      fill: { color: C.panel }, line: { color: C.midBlue, width: 1 } });
    s.addText(f.value, { x: bx, y: 4.6, w: 1.7, h: 0.45,
      fontSize: 11, bold: true, color: C.gold, align: "center" });
    s.addText(f.label, { x: bx, y: 5.02, w: 1.7, h: 0.35,
      fontSize: 8, color: C.muted, align: "center" });
  });

  s.addText("Staging  •  Prognostic Markers  •  Treatment Algorithms  •  Monitoring", {
    x: 0.65, y: 6.8, w: 11.0, h: 0.4,
    fontSize: 9, color: C.muted, italic: true
  });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 2 — Diagnosis & Staging
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.accent } });
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("DIAGNOSIS & STAGING", { x: 0.5, y: 0.05, w: 8, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 2 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // RAI STAGING header
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.9, w: 5.8, h: 0.4,
    fill: { color: C.midBlue }, line: { color: C.accent, width: 1 } });
  s.addText("RAI STAGING SYSTEM", { x: 0.45, y: 0.9, w: 5.8, h: 0.4,
    fontSize: 11, bold: true, color: C.white, align: "center", charSpacing: 2 });

  // stage, description, risk-label, text-color, tint-bg-color
  const raiRows = [
    ["Stage 0", "Lymphocytosis only", "Low Risk", C.green, C.greenDark],
    ["Stage I", "Lymphocytosis + Lymphadenopathy", "Intermediate", C.gold, C.goldDark],
    ["Stage II", "Lymphocytosis + Splenomegaly / Hepatomegaly", "Intermediate", C.gold, C.goldDark],
    ["Stage III", "Lymphocytosis + Anemia (Hgb < 11 g/dL)", "High Risk", C.red, C.redDark],
    ["Stage IV", "Lymphocytosis + Thrombocytopenia (Plt < 100K)", "High Risk", C.red, C.redDark],
  ];
  raiRows.forEach((r, i) => {
    const ry = 1.38 + i * 0.72;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 5.8, h: 0.66, fill: { color: bg } });
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 0.9, h: 0.66, fill: { color: r[4] } });
    s.addText(r[0], { x: 0.45, y: ry, w: 0.9, h: 0.66, fontSize: 10, bold: true, color: r[3], align: "center", valign: "middle" });
    s.addText(r[1], { x: 1.38, y: ry, w: 3.3, h: 0.66, fontSize: 9, color: C.light, valign: "middle", margin: 4 });
    s.addShape(pres.ShapeType.rect, { x: 4.75, y: ry + 0.1, w: 1.4, h: 0.46,
      fill: { color: r[4] }, line: { color: r[3], width: 1 } });
    s.addText(r[2], { x: 4.75, y: ry + 0.1, w: 1.4, h: 0.46, fontSize: 8, bold: true, color: r[3], align: "center", valign: "middle" });
  });

  // BINET STAGING header
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fill: { color: C.midBlue }, line: { color: C.gold, width: 1 } });
  s.addText("BINET STAGING SYSTEM", { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fontSize: 11, bold: true, color: C.white, align: "center", charSpacing: 2 });

  const binetRows = [
    ["A", "< 3 enlarged lymphoid areas; No anemia / thrombocytopenia", "Median Survival: > 10 yrs", C.green, C.greenDark],
    ["B", ">= 3 enlarged lymphoid areas; No anemia / thrombocytopenia", "Median Survival: 7 yrs", C.gold, C.goldDark],
    ["C", "Anemia (Hgb < 10 g/dL) AND/OR Thrombocytopenia (< 100K)", "Median Survival: 2-4 yrs", C.red, C.redDark],
  ];
  binetRows.forEach((r, i) => {
    const ry = 1.38 + i * 0.78;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 6.8, y: ry, w: 6.1, h: 0.72, fill: { color: bg } });
    s.addShape(pres.ShapeType.rect, { x: 6.8, y: ry, w: 0.6, h: 0.72, fill: { color: r[4] } });
    s.addText("Stage\n" + r[0], { x: 6.8, y: ry, w: 0.6, h: 0.72, fontSize: 9, bold: true, color: r[3], align: "center", valign: "middle" });
    s.addText(r[1], { x: 7.45, y: ry, w: 3.7, h: 0.72, fontSize: 9, color: C.light, valign: "middle", margin: 4 });
    s.addText(r[2], { x: 11.2, y: ry, w: 1.6, h: 0.72, fontSize: 8, bold: true, color: r[3], align: "center", valign: "middle" });
  });

  // DIAGNOSTIC CRITERIA
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 3.82, w: 6.1, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("DIAGNOSTIC CRITERIA", { x: 6.8, y: 3.82, w: 6.1, h: 0.38,
    fontSize: 10, bold: true, color: C.accent, align: "center", charSpacing: 1 });

  const diagCrit = [
    "Clonal B-lymphocytes >= 5 x 10^9/L in peripheral blood",
    "Immunophenotype: CD5+, CD19+, CD23+, dim CD20, dim sIg",
    "Smudge (smear) cells on peripheral blood film",
    "< 55% prolymphocytes (>55% = B-PLL, different entity)",
    "Monoclonal B-cell lymphocytosis confirmed by flow cytometry",
  ];
  diagCrit.forEach((d, i) => {
    const dy = 4.27 + i * 0.49;
    s.addShape(pres.ShapeType.ellipse, { x: 6.85, y: dy + 0.12, w: 0.22, h: 0.22, fill: { color: C.accent } });
    s.addText(d, { x: 7.15, y: dy, w: 5.65, h: 0.44, fontSize: 9, color: C.light, valign: "middle" });
  });

  s.addText("* This patient (Chiranjee Lal): Lymphocytosis 80%, Smudge cells present, Thrombocytopenia -> Likely Rai Stage III-IV / Binet C. Awaiting immunophenotyping.", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34, fontSize: 7.5, color: C.gold, italic: true });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 3 — Prognostic Markers
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.gold } });
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("PROGNOSTIC MARKERS", { x: 0.5, y: 0.05, w: 8, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 3 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // FISH CYTOGENETICS
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.9, w: 6.0, h: 0.4, fill: { color: C.midBlue } });
  s.addText("FISH CYTOGENETICS (Prognostic Impact)", { x: 0.45, y: 0.9, w: 6.0, h: 0.4,
    fontSize: 10, bold: true, color: C.white, align: "center", charSpacing: 1 });

  // name, freq, risk-label, OS, text-color, bg-tint
  const fishData = [
    ["del(13q) sole", "55%", "Best", "OS > 10 yrs", C.green, C.greenDark],
    ["Normal", "18%", "Good", "OS ~7 yrs", C.green, C.greenDark],
    ["Trisomy 12", "16%", "Intermediate", "OS ~7 yrs", C.gold, C.goldDark],
    ["del(11q)", "18%", "Poor", "OS ~6 yrs", C.orange, C.orangeDark],
    ["del(17p)", "7%", "Very Poor", "OS ~2-3 yrs", C.red, C.redDark],
  ];
  fishData.forEach((r, i) => {
    const ry = 1.37 + i * 0.62;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 6.0, h: 0.58, fill: { color: bg } });
    s.addText(r[0], { x: 0.5, y: ry, w: 1.8, h: 0.58, fontSize: 9, bold: true, color: r[4], valign: "middle", margin: 3 });
    s.addText("Freq: " + r[1], { x: 2.35, y: ry, w: 0.9, h: 0.58, fontSize: 8, color: C.muted, valign: "middle", align: "center" });
    s.addShape(pres.ShapeType.rect, { x: 3.3, y: ry + 0.1, w: 1.2, h: 0.38, fill: { color: r[5] }, line: { color: r[4], width: 1 } });
    s.addText(r[2], { x: 3.3, y: ry + 0.1, w: 1.2, h: 0.38, fontSize: 8, bold: true, color: r[4], align: "center", valign: "middle" });
    s.addText(r[3], { x: 4.58, y: ry, w: 1.8, h: 0.58, fontSize: 8, color: C.light, valign: "middle" });
  });

  // IGHV MUTATION STATUS
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 0.9, w: 6.1, h: 0.4, fill: { color: C.midBlue } });
  s.addText("IGHV MUTATION STATUS", { x: 6.8, y: 0.9, w: 6.1, h: 0.4,
    fontSize: 10, bold: true, color: C.white, align: "center", charSpacing: 1 });

  // Mutated panel
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 1.37, w: 2.9, h: 2.4, fill: { color: C.panel }, line: { color: C.green, width: 2 } });
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 1.37, w: 2.9, h: 0.38, fill: { color: C.greenDark } });
  s.addText("MUTATED IGHV", { x: 6.8, y: 1.37, w: 2.9, h: 0.38, fontSize: 9, bold: true, color: C.green, align: "center", valign: "middle" });
  [">=2% divergence from germline", "Favorable prognosis", "Slower progression", "Possible cure with FCR*", "ZAP-70 negative", "CD38 negative"].forEach((l, i) => {
    s.addShape(pres.ShapeType.rect, { x: 6.9, y: 1.85 + i * 0.32, w: 0.15, h: 0.15, fill: { color: C.green } });
    s.addText(l, { x: 7.1, y: 1.8 + i * 0.32, w: 2.5, h: 0.3, fontSize: 8.5, color: C.light });
  });

  // Unmutated panel
  s.addShape(pres.ShapeType.rect, { x: 9.8, y: 1.37, w: 3.1, h: 2.4, fill: { color: C.panel }, line: { color: C.red, width: 2 } });
  s.addShape(pres.ShapeType.rect, { x: 9.8, y: 1.37, w: 3.1, h: 0.38, fill: { color: C.redDark } });
  s.addText("UNMUTATED IGHV", { x: 9.8, y: 1.37, w: 3.1, h: 0.38, fontSize: 9, bold: true, color: C.red, align: "center", valign: "middle" });
  ["<2% divergence from germline", "Unfavorable prognosis", "Faster progression", "BTK/BCL2 inhibitors preferred", "ZAP-70 positive", "CD38 positive"].forEach((l, i) => {
    s.addShape(pres.ShapeType.rect, { x: 9.9, y: 1.85 + i * 0.32, w: 0.15, h: 0.15, fill: { color: C.red } });
    s.addText(l, { x: 10.1, y: 1.8 + i * 0.32, w: 2.7, h: 0.3, fontSize: 8.5, color: C.light });
  });

  // OTHER MARKERS
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 4.55, w: 12.45, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("OTHER KEY PROGNOSTIC FACTORS", { x: 0.45, y: 4.55, w: 12.45, h: 0.38,
    fontSize: 10, bold: true, color: C.accent, align: "center", charSpacing: 1 });

  const otherMarkers = [
    { title: "TP53 Mutation", good: "Absent", bad: "Mutated / del(17p)", impact: "Resistance to chemo; mandate BTK/BCL2", color: C.red, tint: C.redDark },
    { title: "beta-2 Microglobulin", good: "< 3.5 mg/L", bad: "> 3.5 mg/L", impact: "Independent poor prognosis marker", color: C.orange, tint: C.orangeDark },
    { title: "Serum Thymidine Kinase", good: "Low", bad: "Elevated", impact: "Rapid disease progression predictor", color: C.gold, tint: C.goldDark },
    { title: "Lymphocyte DT", good: "> 12 months", bad: "< 6 months", impact: "Treatment trigger if < 6 months", color: C.gold, tint: C.goldDark },
  ];
  otherMarkers.forEach((m, i) => {
    const mx = 0.5 + i * 3.1;
    s.addShape(pres.ShapeType.rect, { x: mx, y: 5.0, w: 3.0, h: 2.2, fill: { color: C.panel }, line: { color: m.color, width: 1 } });
    s.addText(m.title, { x: mx, y: 5.02, w: 3.0, h: 0.38, fontSize: 9, bold: true, color: m.color, align: "center" });
    s.addText("Favorable: " + m.good, { x: mx + 0.1, y: 5.46, w: 2.8, h: 0.36, fontSize: 8, color: C.green });
    s.addText("Adverse: " + m.bad, { x: mx + 0.1, y: 5.82, w: 2.8, h: 0.36, fontSize: 8, color: C.red });
    s.addShape(pres.ShapeType.rect, { x: mx + 0.05, y: 6.22, w: 2.9, h: 0.04, fill: { color: C.midBlue } });
    s.addText(m.impact, { x: mx + 0.1, y: 6.28, w: 2.8, h: 0.7, fontSize: 7.5, color: C.muted, italic: true });
  });

  s.addText("CLL-IPI Score integrates: IGHV status + TP53 status + beta-2-microglobulin + clinical stage + age -> Stratifies into Low / Intermediate / High / Very High risk", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34, fontSize: 7.5, color: C.gold, italic: true });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 4 — Treatment Algorithm
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.green } });
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("TREATMENT ALGORITHM — FIRST LINE", { x: 0.5, y: 0.05, w: 9, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 4 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // Decision box
  s.addShape(pres.ShapeType.rect, { x: 4.4, y: 0.85, w: 4.5, h: 0.65,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 2 } });
  s.addText("NEW CLL DIAGNOSIS — Assess Treatment Indication", {
    x: 4.4, y: 0.85, w: 4.5, h: 0.65, fontSize: 9, bold: true, color: C.accent, align: "center", valign: "middle" });

  // Arrow
  s.addShape(pres.ShapeType.rect, { x: 6.4, y: 1.5, w: 0.5, h: 0.4, fill: { color: C.midBlue } });

  // Watch & Wait
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 1.92, w: 5.5, h: 0.55,
    fill: { color: C.greenDark }, line: { color: C.green, width: 2 } });
  s.addText("WATCH & WAIT (No treatment needed)", {
    x: 0.45, y: 1.92, w: 5.5, h: 0.55, fontSize: 9.5, bold: true, color: C.green, align: "center", valign: "middle" });

  // Treat
  s.addShape(pres.ShapeType.rect, { x: 7.35, y: 1.92, w: 5.5, h: 0.55,
    fill: { color: C.redDark }, line: { color: C.red, width: 2 } });
  s.addText("TREAT — Meets IWCLL Criteria", {
    x: 7.35, y: 1.92, w: 5.5, h: 0.55, fontSize: 9.5, bold: true, color: C.red, align: "center", valign: "middle" });

  // W&W items
  s.addText("Indications for W&W:", { x: 0.5, y: 2.55, w: 5.3, h: 0.3, fontSize: 8.5, bold: true, color: C.muted });
  ["Early Rai 0-II / Binet A-B (asymptomatic)", "No anemia or thrombocytopenia", "Lymphocyte doubling time > 12 months", "No B symptoms (fever, night sweats, wt loss)"].forEach((t, i) => {
    s.addShape(pres.ShapeType.ellipse, { x: 0.52, y: 2.9 + i * 0.4 + 0.07, w: 0.17, h: 0.17, fill: { color: C.green } });
    s.addText(t, { x: 0.76, y: 2.88 + i * 0.4, w: 5.0, h: 0.36, fontSize: 8.5, color: C.light });
  });
  s.addText("Monitor: CBC every 3-6 months", { x: 0.5, y: 4.5, w: 5.3, h: 0.35, fontSize: 8.5, color: C.gold, italic: true });

  // IWCLL triggers
  s.addText("IWCLL Treatment Triggers:", { x: 7.4, y: 2.55, w: 5.3, h: 0.3, fontSize: 8.5, bold: true, color: C.muted });
  ["B symptoms (fever / night sweats / wt loss > 10%)", "Progressive marrow failure (worsening anemia/thrombocytopenia)", "Massive/progressive splenomegaly or lymphadenopathy", "Lymphocyte doubling time < 6 months", "AIHA/ITP not responsive to corticosteroids"].forEach((t, i) => {
    s.addShape(pres.ShapeType.rect, { x: 7.42, y: 2.9 + i * 0.38 + 0.07, w: 0.17, h: 0.17, fill: { color: C.red } });
    s.addText(t, { x: 7.66, y: 2.88 + i * 0.38, w: 5.0, h: 0.36, fontSize: 8.5, color: C.light });
  });

  // Preferred regimens header
  s.addShape(pres.ShapeType.rect, { x: 6.8, y: 4.55, w: 6.1, h: 0.38,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("PREFERRED FIRST-LINE REGIMENS (NCCN v2.2026)", { x: 6.8, y: 4.55, w: 6.1, h: 0.38,
    fontSize: 9, bold: true, color: C.accent, align: "center" });

  const txOptions = [
    { drug: "Zanubrutinib", dose: "160 mg BID, continuous", cat: "BTK inhibitor (3rd gen)", pref: "PREFERRED", color: C.green, tint: C.greenDark },
    { drug: "Acalabrutinib", dose: "100 mg BID +/- obinutuzumab", cat: "BTK inhibitor (2nd gen)", pref: "PREFERRED", color: C.green, tint: C.greenDark },
    { drug: "Ibrutinib", dose: "420 mg OD, continuous", cat: "BTK inhibitor (1st gen)", pref: "Acceptable", color: C.gold, tint: C.goldDark },
    { drug: "Venetoclax + Obinutuzumab", dose: "Ramp to 400 mg OD x 1 yr", cat: "BCL2 inhibitor + Anti-CD20", pref: "PREFERRED", color: C.green, tint: C.greenDark },
  ];
  txOptions.forEach((r, i) => {
    const rx = 6.85 + (i % 2) * 3.05;
    const ry = 5.02 + Math.floor(i / 2) * 0.92;
    s.addShape(pres.ShapeType.rect, { x: rx, y: ry, w: 2.95, h: 0.82, fill: { color: C.panel }, line: { color: r.color, width: 1.5 } });
    s.addShape(pres.ShapeType.rect, { x: rx, y: ry, w: 2.95, h: 0.26, fill: { color: r.tint } });
    s.addText(r.drug, { x: rx + 0.05, y: ry, w: 2.2, h: 0.26, fontSize: 9, bold: true, color: r.color, valign: "middle", margin: 2 });
    s.addShape(pres.ShapeType.rect, { x: rx + 2.25, y: ry + 0.03, w: 0.65, h: 0.21, fill: { color: r.tint } });
    s.addText(r.pref, { x: rx + 2.25, y: ry + 0.03, w: 0.65, h: 0.21, fontSize: 6, bold: true, color: r.color, align: "center", valign: "middle" });
    s.addText(r.cat, { x: rx + 0.05, y: ry + 0.28, w: 2.85, h: 0.24, fontSize: 7.5, color: C.muted });
    s.addText(r.dose, { x: rx + 0.05, y: ry + 0.52, w: 2.85, h: 0.28, fontSize: 7.5, color: C.light });
  });

  s.addText("Note: For del(17p)/TP53-mutated CLL -> BTK inhibitors are mandatory (chemo ineffective). FCR still considered in fit young patients with mutated IGHV, favorable cytogenetics.", {
    x: 0.45, y: 7.1, w: 12.7, h: 0.34, fontSize: 7.5, color: C.gold, italic: true });
}

// ═══════════════════════════════════════════════════════════════════════════════
// SLIDE 5 — Drug Details & Monitoring
// ═══════════════════════════════════════════════════════════════════════════════
{
  const s = pres.addSlide();
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 13.3, h: 7.5, fill: { color: C.navy } });
  s.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.35, h: 7.5, fill: { color: C.orange } });
  s.addShape(pres.ShapeType.rect, { x: 0.35, y: 0, w: 12.95, h: 0.72, fill: { color: C.panel } });
  s.addText("DRUG DETAILS, MONITORING & RELAPSED CLL", { x: 0.5, y: 0.05, w: 9, h: 0.62,
    fontSize: 18, bold: true, color: C.white, charSpacing: 2, valign: "middle" });
  s.addText("Slide 5 of 5", { x: 11.5, y: 0.05, w: 1.6, h: 0.62,
    fontSize: 9, color: C.muted, align: "right", valign: "middle" });

  // Drug Table header
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 0.85, w: 12.45, h: 0.38, fill: { color: C.midBlue } });
  const drugHdrW = [1.8, 1.9, 2.2, 3.5, 3.05];
  ["Drug", "Mechanism", "Dose", "Key Adverse Effects", "Monitoring"].forEach((h, i) => {
    let hx = 0.45 + drugHdrW.slice(0, i).reduce((a, b) => a + b, 0);
    s.addText(h, { x: hx + 0.04, y: 0.85, w: drugHdrW[i], h: 0.38, fontSize: 9, bold: true, color: C.white, valign: "middle" });
  });

  const drugs = [
    ["Ibrutinib",       "BTK inhibitor (1st gen)", "420 mg OD oral",          "AF (10%), bleeding, HTN, rash, arthralgias",          "ECG baseline, BP, CBC monthly",        C.gold],
    ["Acalabrutinib",   "BTK inhibitor (2nd gen)", "100 mg BID oral",         "Headache, cough; less AF risk vs ibrutinib",          "CBC, LFT q3 months",                   C.green],
    ["Zanubrutinib",    "BTK inhibitor (3rd gen)", "160 mg BID oral",         "Least cardiac risk; neutropenia, rash",               "CBC, LFT q3 months",                   C.green],
    ["Venetoclax",      "BCL2 inhibitor",          "Ramp-up -> 400 mg OD",    "Tumor lysis syndrome (TLS!), neutropenia, N/V/D",     "TLS labs D1,D8,D15; CBC weekly",       C.red],
    ["Obinutuzumab",    "Anti-CD20 mAb",           "IV per protocol cycles",  "Infusion reactions, neutropenia, HBV reactivation",   "HBV serology before; CBC each cycle",  C.orange],
    ["Rituximab",       "Anti-CD20 mAb",           "375-500 mg/m2 IV",        "Infusion reactions, PML risk",                        "HBV, CBC, LFT",                        C.orange],
    ["Bendamustine",    "Alkylating agent",         "70-90 mg/m2 IV D1+D2",   "Myelosuppression, infections, nausea",                "CBC day 21-28, LFT",                   C.muted],
    ["Fludarabine",     "Purine analogue",          "25 mg/m2 IV D1-D3",      "Prolonged myelosuppression, autoimmune AIHA",         "CBC; avoid if del(17p)",               C.muted],
  ];

  drugs.forEach((d, i) => {
    const ry = 1.3 + i * 0.52;
    const bg = i % 2 === 0 ? C.panel : C.deepBlue;
    s.addShape(pres.ShapeType.rect, { x: 0.45, y: ry, w: 12.45, h: 0.5, fill: { color: bg } });
    d.slice(0, 5).forEach((v, j) => {
      let dx = 0.45 + drugHdrW.slice(0, j).reduce((a, b) => a + b, 0);
      s.addText(v, { x: dx + 0.04, y: ry, w: drugHdrW[j] - 0.08, h: 0.5,
        fontSize: j === 0 ? 9 : 8, bold: j === 0, color: j === 0 ? d[5] : C.light, valign: "middle", margin: 2 });
    });
  });

  // Prophylaxis
  s.addShape(pres.ShapeType.rect, { x: 0.45, y: 5.55, w: 5.9, h: 0.35,
    fill: { color: C.panel3 }, line: { color: C.accent, width: 1 } });
  s.addText("SUPPORTIVE PROPHYLAXIS", { x: 0.45, y: 5.55, w: 5.9, h: 0.35,
    fontSize: 9, bold: true, color: C.accent, align: "center" });
  [
    "Acyclovir 400 mg BID — HSV/VZV prophylaxis during treatment",
    "TMP-SMX — PCP prophylaxis with venetoclax / steroid combos",
    "Posaconazole/Fluconazole — Antifungal prophylaxis (ECIL 2025)",
    "IVIG — Recurrent infections with hypogammaglobulinemia",
    "Prednisolone — For AIHA or ITP complicating CLL",
  ].forEach((p, i) => {
    s.addText("• " + p, { x: 0.55, y: 5.96 + i * 0.3, w: 5.7, h: 0.28, fontSize: 7.8, color: C.light });
  });

  // Relapsed CLL
  s.addShape(pres.ShapeType.rect, { x: 6.55, y: 5.55, w: 6.35, h: 0.35,
    fill: { color: C.redDark }, line: { color: C.red, width: 1 } });
  s.addText("RELAPSED / REFRACTORY CLL", { x: 6.55, y: 5.55, w: 6.35, h: 0.35,
    fontSize: 9, bold: true, color: C.red, align: "center" });
  [
    "Switch BTK inhibitor class (e.g. ibrutinib -> zanubrutinib/acalabrutinib)",
    "Venetoclax + rituximab — If not previously used",
    "Pirtobrutinib (non-covalent BTK inhibitor) — After covalent BTK failure",
    "Allo-SCT — High-risk young patients, multiply relapsed disease",
    "CAR-T cell therapy — Investigational in R/R CLL with del(17p)",
  ].forEach((p, i) => {
    s.addText("• " + p, { x: 6.65, y: 5.96 + i * 0.3, w: 6.1, h: 0.28, fontSize: 7.8, color: C.light });
  });

  s.addText("Sources: Harrison's Principles of Internal Medicine 22E (2025) | Goldman-Cecil Medicine | NCCN CLL/SLL Guidelines v2.2026 | GELLC Spanish Guidelines 2025 (PMID: 39799061)", {
    x: 0.45, y: 7.2, w: 12.7, h: 0.25, fontSize: 6.5, color: C.muted, italic: true });
}

// Write file
pres.writeFile({ fileName: "/home/daytona/workspace/cll-reference/CLL_Clinical_Reference_Card.pptx" })
  .then(() => console.log("SUCCESS"))
  .catch(e => { console.error("ERROR:", e); process.exit(1); });
Running Command

cd /home/daytona/workspace/cll-reference && node cll_final.js 2>&1

Your CLL Clinical Reference Card is ready:

CLL Clinical Reference Card

Presentation · PPTX


What's Inside (5 slides, wide-format dark theme)

SlideContent
1 - CoverTitle slide with key stats (5-yr survival 92%, median age 70, M:F ratio, etc.)
2 - Diagnosis & StagingFull Rai (Stage 0-IV) + Binet (A/B/C) staging tables with color-coded risk levels; diagnostic criteria checklist; patient-specific annotation
3 - Prognostic MarkersFISH cytogenetics table (del13q to del17p with survival data); IGHV mutated vs unmutated comparison panels; TP53, beta-2 microglobulin, TK1, lymphocyte doubling time cards; CLL-IPI note
4 - Treatment AlgorithmWatch & Wait vs. Treat decision pathway; IWCLL treatment triggers; NCCN v2.2026 preferred regimens (Zanubrutinib, Acalabrutinib, Venetoclax+Obinutuzumab, Ibrutinib) with doses
5 - Drugs & Monitoring8-drug reference table (mechanism, dose, adverse effects, monitoring); Supportive prophylaxis (Acyclovir, TMP-SMX, antifungals, IVIG); Relapsed/refractory CLL pathway including Pirtobrutinib and CAR-T
This is a shared conversation. Sign in to Orris to start your own chat.