Polyendocrine metabolic ovarian syndrome the new name for pcod , make a ppt of 30 slides from standard journals and articles and books ( lancet )

Reading File
Reading File
Reading File
Finding Sources
Searching PubMed

"polycystic ovary syndrome" AND "polyendocrine metabolic syndrome"

Searching the Web

polyendocrine metabolic ovarian syndrome PCOS new name 2024 2025 Lancet

Reading Article

PMID: 42119588

Reading Web Page

https://news.cuanschutz.edu/news-stories/pcos-new-name

Finding Sources
Finding Sources
Reading File
Reading File
Finding Sources
Finding Sources
Reading File
Finding Sources
Searching Images

polycystic ovary syndrome ultrasound follicles hormonal

Running Command

mkdir -p /home/daytona/workspace/pmos-pptx && ls /home/daytona/workspace/pmos-pp…

Writing File

~/pmos-pptx/build_pmos.js

const pptxgen = require("pptxgenjs");
const { execSync } = require("child_process");

// ─── Color Palette ─────────────────────────────────────────────────────────────
const C = {
  deepPurple:  "2D1B69",
  purple:      "5B2D8E",
  magenta:     "9B2C82",
  rose:        "C2185B",
  pink:        "F06292",
  lightPink:   "FCE4EC",
  lavender:    "EDE7F6",
  white:       "FFFFFF",
  offWhite:    "FFF9FB",
  textDark:    "1A0033",
  textGray:    "4A4A6A",
  accent:      "FF6F91",
  gold:        "FFB300",
  teal:        "00897B",
};

// ─── Fetch images ──────────────────────────────────────────────────────────────
const imageUrls = [
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_f5e4a83ac2461495e69a52d3f28ed913da2f8c22ad8cefc7616b00c6c70a29be.jpg",
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_8e489aa98558ee445ba5d5239e7b3e7ffdff0b72b27fbbd990cdcd5473fce6bf.jpg",
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_b33b2ccdd016f69a30904eb1fc1d8cef71a69bedf5da5db120e1fc850b09471c.jpg",
];

let images = [];
try {
  const result = execSync(
    `node /home/daytona/skills/shared/scripts/fetch_images.js ${imageUrls.map(u => `"${u}"`).join(" ")}`,
    { timeout: 30000 }
  ).toString();
  images = JSON.parse(result);
} catch (e) {
  console.warn("Image fetch failed:", e.message);
  images = imageUrls.map(() => ({ base64: null, error: "fetch failed" }));
}

// ─── Presentation setup ───────────────────────────────────────────────────────
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.author = "PMOS Global Consensus";
pres.title = "Polyendocrine Metabolic Ovarian Syndrome (PMOS)";

// ─── Helper functions ─────────────────────────────────────────────────────────

function addGradientBG(slide, color1, color2) {
  slide.addShape(pres.ShapeType.rect, {
    x: 0, y: 0, w: "100%", h: "100%",
    fill: { type: "gradient", stops: [{ color: color1, pos: 0 }, { color: color2, pos: 100 }], angle: 135 }
  });
}

function addDecorCircle(slide, x, y, size, color, alpha) {
  slide.addShape(pres.ShapeType.ellipse, {
    x, y, w: size, h: size,
    fill: { color, alpha: alpha || 30 }, line: { color, alpha: 0 }
  });
}

function titleSlide(slide) {
  // Big gradient background
  addGradientBG(slide, C.deepPurple, C.magenta);
  // Decorative circles
  addDecorCircle(slide, 8.5, -0.5, 3, C.pink, 25);
  addDecorCircle(slide, -1.0, 3.5, 4, C.purple, 20);
  addDecorCircle(slide, 5, 3, 1.5, C.accent, 15);
}

function contentSlideBG(slide, dark) {
  if (dark) {
    addGradientBG(slide, C.deepPurple, C.purple);
  } else {
    addGradientBG(slide, C.lavender, C.offWhite);
  }
}

function addSlideHeader(slide, title, dark) {
  const bg = dark ? C.magenta : C.purple;
  const fg = C.white;
  slide.addShape(pres.ShapeType.rect, {
    x: 0, y: 0, w: "100%", h: 1.0,
    fill: { color: bg }, line: { color: bg }
  });
  slide.addText(title, {
    x: 0.3, y: 0.08, w: 9.4, h: 0.82,
    fontSize: 22, bold: true, color: fg, fontFace: "Calibri",
    valign: "middle", margin: 0
  });
}

function addFooter(slide, ref) {
  slide.addShape(pres.ShapeType.rect, {
    x: 0, y: 5.35, w: "100%", h: 0.28,
    fill: { color: C.deepPurple }, line: { color: C.deepPurple }
  });
  slide.addText(ref, {
    x: 0.2, y: 5.36, w: 9.6, h: 0.25,
    fontSize: 7, color: C.lightPink, italic: true, fontFace: "Calibri",
    valign: "middle", margin: 0
  });
}

function bullet(text, sub) {
  return { text, options: { bullet: { code: "25B6", color: C.magenta }, breakLine: true, fontSize: sub ? 13 : 15, color: sub ? C.textGray : C.textDark, bold: !sub, indent: sub ? 20 : 0 } };
}

function subbullet(text) {
  return { text: "  " + text, options: { bullet: { code: "2013", color: C.pink }, breakLine: true, fontSize: 13, color: C.textGray, indent: 20 } };
}

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDES
// ─────────────────────────────────────────────────────────────────────────────

// ── SLIDE 1: Title ──────────────────────────────────────────────────────────
let s = pres.addSlide();
titleSlide(s);
s.addText("POLYENDOCRINE METABOLIC\nOVARIAN SYNDROME", {
  x: 0.5, y: 0.7, w: 9, h: 2.2,
  fontSize: 36, bold: true, color: C.white, fontFace: "Calibri",
  align: "center", valign: "middle", charSpacing: 2
});
s.addText("(PMOS)", {
  x: 0.5, y: 2.7, w: 9, h: 0.7,
  fontSize: 30, bold: true, color: C.gold, fontFace: "Calibri", align: "center"
});
s.addText("The New Name for Polycystic Ovary Syndrome (PCOS)", {
  x: 0.5, y: 3.3, w: 9, h: 0.5,
  fontSize: 18, color: C.lightPink, fontFace: "Calibri", align: "center"
});
s.addShape(pres.ShapeType.rect, { x: 2.5, y: 3.9, w: 5, h: 0.04, fill: { color: C.accent }, line: { color: C.accent } });
s.addText("Lancet 2026 | Teede HJ et al. | International PCOS Network", {
  x: 0.5, y: 4.05, w: 9, h: 0.4,
  fontSize: 13, color: C.pink, fontFace: "Calibri", align: "center", italic: true
});
s.addText("Multistep Global Consensus Process", {
  x: 0.5, y: 4.55, w: 9, h: 0.4,
  fontSize: 12, color: C.lavender, fontFace: "Calibri", align: "center"
});

// ── SLIDE 2: The Landmark Name Change ──────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "A Historic Renaming — May 12, 2026", true);
addFooter(s, "Source: Teede HJ et al. Lancet 2026. DOI: 10.1016/S0140-6736(26)00717-8");

s.addText("PCOS → PMOS", {
  x: 0.4, y: 1.05, w: 9.2, h: 0.6,
  fontSize: 32, bold: true, color: C.gold, align: "center", fontFace: "Calibri"
});

const boxData = [
  { label: "Condition", val: "Polycystic Ovary Syndrome (PCOS)", x: 0.3 },
  { label: "New Name", val: "Polyendocrine Metabolic Ovarian Syndrome (PMOS)", x: 5.2 },
];
for (const b of boxData) {
  const isnew = b.label === "New Name";
  s.addShape(pres.ShapeType.roundRect, {
    x: b.x, y: 1.8, w: 4.6, h: 1.3,
    fill: { color: isnew ? C.magenta : C.purple }, line: { color: isnew ? C.accent : C.pink, pt: 2 },
    rectRadius: 0.12
  });
  s.addText(b.label, { x: b.x + 0.1, y: 1.85, w: 4.4, h: 0.35, fontSize: 11, color: C.lightPink, bold: true, fontFace: "Calibri" });
  s.addText(b.val, { x: b.x + 0.1, y: 2.2, w: 4.4, h: 0.8, fontSize: 14, color: C.white, bold: true, fontFace: "Calibri", wrap: true });
}

s.addText([
  { text: "Published in ", options: { color: C.lavender, fontSize: 14 } },
  { text: "The Lancet", options: { color: C.gold, bold: true, fontSize: 14 } },
  { text: " on May 12, 2026 — a multistep global consensus involving ", options: { color: C.lavender, fontSize: 14 } },
  { text: "56 leading academic, clinical, and patient organisations", options: { color: C.accent, bold: true, fontSize: 14 } },
  { text: " worldwide.", options: { color: C.lavender, fontSize: 14 } },
], { x: 0.3, y: 3.25, w: 9.4, h: 0.9, fontFace: "Calibri", wrap: true });

s.addText("Expected ICD coding transition: 2028", {
  x: 0.3, y: 4.2, w: 9.4, h: 0.5, fontSize: 13, color: C.pink, italic: true, fontFace: "Calibri", align: "center"
});

// ── SLIDE 3: Why the Name Had to Change ─────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Why the Old Name (PCOS) Had to Change", false);
addFooter(s, "Teede HJ et al. Lancet 2026 | Tietz Textbook of Lab Medicine 7e");

s.addText([
  bullet('"Polycystic" is a misnomer — no true pathological cysts exist'),
  bullet("Name implied purely ovarian disease, ignoring broader multisystem involvement"),
  bullet("Contributed to delayed diagnosis in up to 70% of women"),
  bullet("Fragmented care — patients bounced between specialists"),
  bullet("Stigma from fertility-focused labelling"),
  bullet("Curtailed research into metabolic and cardiovascular aspects"),
  bullet("Misled clinicians and patients about underlying disease mechanisms"),
], {
  x: 0.4, y: 1.1, w: 9.2, h: 4.1,
  fontFace: "Calibri", fontSize: 15, color: C.textDark
});

// ── SLIDE 4: The Consensus Process ──────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "The Global Consensus Process", true);
addFooter(s, "Teede HJ et al. Lancet 2026 | International PCOS Network");

const steps = [
  { n: "1", t: "Mandate", d: "International mandate established; governance & funding set up" },
  { n: "2", t: "Surveys", d: "14,360 responses from patients + multidisciplinary HCPs, all world regions" },
  { n: "3", t: "Delphi", d: "Modified Delphi methodology — iterative expert consensus rounds" },
  { n: "4", t: "Workshops", d: "Nominal group technique workshops; marketing & implementation analysis" },
  { n: "5", t: "Consensus", d: "56 global organisations endorsed PMOS as the new name" },
  { n: "6", t: "Implementation", d: "Co-designed global strategy: education, ICD update (2028), guidelines update" },
];

steps.forEach((st, i) => {
  const col = i < 3 ? 0 : 1;
  const row = i % 3;
  const x = 0.3 + col * 4.85;
  const y = 1.1 + row * 1.35;
  s.addShape(pres.ShapeType.roundRect, {
    x, y, w: 4.55, h: 1.22,
    fill: { color: i % 2 === 0 ? C.magenta : C.rose }, line: { color: C.accent, pt: 1.5 },
    rectRadius: 0.1
  });
  s.addShape(pres.ShapeType.ellipse, {
    x: x + 0.08, y: y + 0.28, w: 0.52, h: 0.52,
    fill: { color: C.gold }, line: { color: C.gold }
  });
  s.addText(st.n, { x: x + 0.08, y: y + 0.28, w: 0.52, h: 0.52, fontSize: 16, bold: true, color: C.deepPurple, align: "center", valign: "middle", fontFace: "Calibri" });
  s.addText(st.t, { x: x + 0.68, y: y + 0.06, w: 3.75, h: 0.35, fontSize: 14, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(st.d, { x: x + 0.68, y: y + 0.42, w: 3.75, h: 0.7, fontSize: 11.5, color: C.lightPink, fontFace: "Calibri", wrap: true });
});

// ── SLIDE 5: Definition of PMOS ─────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "What is PMOS? — Definition", false);
addFooter(s, "Teede HJ et al. Lancet 2026 | Harrison's Principles of Internal Medicine 22e, p.3135 | Berek & Novak's Gynecology");

s.addShape(pres.ShapeType.roundRect, {
  x: 0.3, y: 1.05, w: 9.4, h: 1.3,
  fill: { color: C.purple }, line: { color: C.accent, pt: 2 }, rectRadius: 0.12
});
s.addText("Polyendocrine Metabolic Ovarian Syndrome (PMOS) is a complex, chronic multisystem endocrine disorder affecting 1 in 8 women of reproductive age (>170 million worldwide), characterised by dysfunction across the endocrine, metabolic, reproductive, dermatological, and psychological systems.", {
  x: 0.45, y: 1.08, w: 9.1, h: 1.24,
  fontSize: 14, color: C.white, fontFace: "Calibri", wrap: true, valign: "middle", align: "center"
});

s.addText([
  bullet("Formerly known as Polycystic Ovary Syndrome (PCOS)"),
  bullet("Prevalence: 6–15% of women of reproductive age (up to 21% in some populations)"),
  bullet("Most common endocrine disorder in women — Kaplan & Sadock's Psychiatry"),
  bullet("Symptoms begin in adolescence, modified by obesity and age"),
  bullet("By the 4th decade, many women normalize menses and androgens"),
  bullet("Underdiagnosed: up to 70% are unaware of their diagnosis"),
], {
  x: 0.4, y: 2.45, w: 9.2, h: 2.75,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 6: Pathophysiology Overview ───────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Pathophysiology — Multisystem Disorder", true);
addFooter(s, "Harrison's Principles of Internal Medicine 22e | Guyton & Hall Medical Physiology | Berek & Novak's Gynecology");

const systems = [
  { icon: "🔬", title: "Neuroendocrine", desc: "Abnormal GnRH pulsatility → elevated LH → excess ovarian androgen production; normal to low FSH" },
  { icon: "⚡", title: "Hyperandrogenism", desc: "Elevated testosterone, DHEAS, androstenedione; 11-oxygenated androgens also elevated; theca cell dysfunction" },
  { icon: "🩸", title: "Insulin Resistance", desc: "50–80% prevalence; skeletal muscle & adipose IR stimulates ovarian androgen synthesis; compensatory hyperinsulinaemia" },
  { icon: "🌀", title: "Ovarian Dysfunction", desc: "Follicular arrest → anovulation; multiple small follicles (≥20, 2–9 mm) — 'string of pearls'; elevated AMH" },
  { icon: "🧬", title: "Genetic Basis", desc: "~19 GWAS loci identified across diverse populations; reproductive and metabolic cluster phenotypes" },
  { icon: "🫀", title: "Metabolic", desc: "Dyslipidemia, visceral adiposity, low-grade inflammation, prothrombotic state, impaired glucose tolerance" },
];

systems.forEach((sys, i) => {
  const col = i % 3;
  const row = Math.floor(i / 3);
  const x = 0.3 + col * 3.2;
  const y = 1.15 + row * 2.1;
  s.addShape(pres.ShapeType.roundRect, {
    x, y, w: 3.0, h: 1.9,
    fill: { type: "gradient", stops: [{ color: C.rose, pos: 0 }, { color: C.purple, pos: 100 }] },
    line: { color: C.accent, pt: 1.5 }, rectRadius: 0.12
  });
  s.addText(sys.icon + " " + sys.title, {
    x: x + 0.1, y: y + 0.08, w: 2.8, h: 0.4,
    fontSize: 13, bold: true, color: C.gold, fontFace: "Calibri"
  });
  s.addText(sys.desc, {
    x: x + 0.1, y: y + 0.5, w: 2.8, h: 1.3,
    fontSize: 11, color: C.lightPink, fontFace: "Calibri", wrap: true
  });
});

// ── SLIDE 7: The "Poly-Endocrine" Component ─────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "The 'Polyendocrine' Dimension", false);
addFooter(s, "Teede HJ et al. Lancet 2026 | Harrison's 22e | Creasy & Resnik's Maternal-Fetal Medicine");

s.addText("PMOS involves dysfunction across multiple endocrine axes simultaneously:", {
  x: 0.4, y: 1.1, w: 9.2, h: 0.45,
  fontSize: 15, color: C.purple, bold: true, fontFace: "Calibri"
});

const axes = [
  ["Hypothalamo-Pituitary-Ovarian Axis", "↑ LH pulse frequency; LH:FSH ratio often >2:1; impaired negative feedback from androgens"],
  ["Hypothalamo-Pituitary-Adrenal Axis", "DHEAS elevated in ~25–35% of cases; adrenal androgen excess component"],
  ["Pancreatic Axis", "Compensatory hyperinsulinism due to peripheral IR; ↑ insulin stimulates ovarian androgens"],
  ["Thyroid Axis", "Thyroid dysfunction must be excluded; co-occurrence of Hashimoto's thyroiditis higher"],
  ["Adipokine Signalling", "Adiponectin ↓, leptin resistance, visceral adiposity dysregulates all hormonal axes"],
];

axes.forEach(([title, desc], i) => {
  const y = 1.65 + i * 0.71;
  s.addShape(pres.ShapeType.rect, {
    x: 0.3, y, w: 0.12, h: 0.55,
    fill: { color: C.magenta }, line: { color: C.magenta }
  });
  s.addText(title, { x: 0.55, y: y + 0.02, w: 4.0, h: 0.28, fontSize: 13, bold: true, color: C.deepPurple, fontFace: "Calibri" });
  s.addText(desc, { x: 0.55, y: y + 0.28, w: 9.15, h: 0.32, fontSize: 12, color: C.textGray, fontFace: "Calibri" });
});

// ── SLIDE 8: Epidemiology ────────────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Epidemiology & Global Burden", true);
addFooter(s, "Teede HJ et al. Lancet 2026 | Kaplan & Sadock's Psychiatry 10e | Harrison's 22e");

const epidStats = [
  { val: "1 in 8", label: "Women affected worldwide" },
  { val: ">170M", label: "Women globally" },
  { val: "6–15%", label: "Reproductive-age prevalence" },
  { val: "Up to 21%", label: "Prevalence in some populations" },
  { val: "~70%", label: "Undiagnosed globally" },
  { val: "2028", label: "Expected ICD transition date" },
];

epidStats.forEach((st, i) => {
  const col = i % 3;
  const row = Math.floor(i / 3);
  const x = 0.3 + col * 3.2;
  const y = 1.15 + row * 2.1;
  s.addShape(pres.ShapeType.roundRect, {
    x, y, w: 3.0, h: 1.9,
    fill: { type: "gradient", stops: [{ color: C.magenta, pos: 0 }, { color: C.deepPurple, pos: 100 }] },
    line: { color: C.gold, pt: 2 }, rectRadius: 0.15
  });
  s.addText(st.val, {
    x: x + 0.1, y: y + 0.35, w: 2.8, h: 0.8,
    fontSize: 30, bold: true, color: C.gold, align: "center", fontFace: "Calibri"
  });
  s.addText(st.label, {
    x: x + 0.1, y: y + 1.2, w: 2.8, h: 0.5,
    fontSize: 12, color: C.lightPink, align: "center", fontFace: "Calibri", wrap: true
  });
});

// ── SLIDE 9: Diagnostic Criteria (Rotterdam Updated 2023) ────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Diagnostic Criteria — Updated Rotterdam (2023)", false);
addFooter(s, "Harrison's 22e p.3135 | Berek & Novak's Gynecology | Tietz Lab Medicine 7e | 2023 International PCOS Guidelines");

s.addShape(pres.ShapeType.roundRect, {
  x: 0.3, y: 1.05, w: 9.4, h: 0.55,
  fill: { color: C.purple }, line: { color: C.magenta, pt: 1 }, rectRadius: 0.08
});
s.addText("Diagnosis requires ≥2 of 3 criteria (after exclusion of other causes):", {
  x: 0.4, y: 1.08, w: 9.2, h: 0.5,
  fontSize: 14, bold: true, color: C.white, fontFace: "Calibri", align: "center"
});

const criteria = [
  {
    num: "1", color: C.rose,
    title: "Irregular / Absent Menses",
    points: ["<9 cycles/year (oligomenorrhoea) or amenorrhoea", "Anovulatory cycles", "In adolescents: irregular menses + hyperandrogenism only (AMH/US not established)"],
  },
  {
    num: "2", color: C.magenta,
    title: "Clinical or Biochemical Hyperandrogenism",
    points: ["↑ Total or free testosterone (most sensitive: free T)", "Modified Ferriman-Gallwey score ≥4–6 (ethnicity-dependent)", "Clinical: hirsutism, acne, androgenic alopecia"],
  },
  {
    num: "3", color: C.purple,
    title: "Polycystic Ovarian Morphology (PCOM) / Elevated AMH",
    points: ["≥20 antral follicles OR ovarian volume ≥10 cm³ in ≥1 ovary", "Elevated serum AMH (increasingly preferred over US)", "AMH: cheaper, no radiation, more accessible"],
  },
];

criteria.forEach((cr, i) => {
  const x = 0.3 + i * 3.2;
  s.addShape(pres.ShapeType.roundRect, {
    x, y: 1.68, w: 3.0, h: 3.6,
    fill: { type: "gradient", stops: [{ color: cr.color, pos: 0 }, { color: C.lavender, pos: 100 }] },
    line: { color: cr.color, pt: 2 }, rectRadius: 0.12
  });
  s.addShape(pres.ShapeType.ellipse, {
    x: x + 1.15, y: 1.72, w: 0.65, h: 0.65,
    fill: { color: C.gold }, line: { color: C.gold }
  });
  s.addText(cr.num, { x: x + 1.15, y: 1.72, w: 0.65, h: 0.65, fontSize: 18, bold: true, color: C.deepPurple, align: "center", valign: "middle", fontFace: "Calibri" });
  s.addText(cr.title, { x: x + 0.1, y: 2.45, w: 2.8, h: 0.6, fontSize: 12, bold: true, color: C.white, fontFace: "Calibri", wrap: true, align: "center" });
  cr.points.forEach((pt, j) => {
    s.addText("• " + pt, {
      x: x + 0.12, y: 3.1 + j * 0.65, w: 2.78, h: 0.62,
      fontSize: 11, color: C.textDark, fontFace: "Calibri", wrap: true
    });
  });
});

// ── SLIDE 10: Exclusion Criteria ─────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "PMOS: A Diagnosis of Exclusion", false);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Goldman-Cecil Medicine");

s.addText("The following conditions must be excluded before confirming PMOS:", {
  x: 0.4, y: 1.1, w: 9.2, h: 0.45,
  fontSize: 14, color: C.purple, bold: true, fontFace: "Calibri"
});

s.addText([
  bullet("Hypothyroidism or Hyperthyroidism — check TSH"),
  bullet("Hyperprolactinaemia — check serum prolactin"),
  bullet("Non-classical / Adult-onset Congenital Adrenal Hyperplasia (CAH)", false),
  subbullet("Check 17-hydroxyprogesterone (17-OHP) — esp. if rapid-onset virilisation"),
  bullet("Androgen-secreting tumours (adrenal or ovarian)", false),
  subbullet("Rapid-onset hirsutism + virilisation; very high testosterone/DHEAS"),
  bullet("Cushing Syndrome — check 24h urinary cortisol / overnight DST"),
  bullet("Primary ovarian insufficiency (POI) — FSH in menopausal range"),
  bullet("Significant drug-induced hyperandrogenism (e.g. anabolic steroids, valproate)"),
], {
  x: 0.4, y: 1.65, w: 9.2, h: 3.6,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 11: Clinical Phenotypes ────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Clinical Phenotypes of PMOS", true);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | 2023 International PCOS Guidelines");

s.addText("Rotterdam criteria produce 4 phenotypes (A–D):", {
  x: 0.4, y: 1.05, w: 9.2, h: 0.45,
  fontSize: 14, color: C.gold, bold: true, fontFace: "Calibri"
});

const phenotypes = [
  { ph: "A (Classic)", features: "Hyperandrogenism + Oligo-anovulation + PCOM", severity: "Most severe metabolic risk", color: C.rose },
  { ph: "B (Classic)", features: "Hyperandrogenism + Oligo-anovulation (no PCOM)", severity: "High metabolic risk", color: C.magenta },
  { ph: "C (Ovulatory)", features: "Hyperandrogenism + PCOM (regular cycles)", severity: "Milder metabolic risk", color: C.purple },
  { ph: "D (Non-androgenic)", features: "Oligo-anovulation + PCOM (no hyperandrogenism)", severity: "Lowest metabolic risk", color: C.deepPurple },
];

phenotypes.forEach((p, i) => {
  const y = 1.6 + i * 0.93;
  s.addShape(pres.ShapeType.roundRect, {
    x: 0.3, y, w: 9.4, h: 0.85,
    fill: { color: p.color }, line: { color: C.accent, pt: 1 }, rectRadius: 0.08
  });
  s.addText("Phenotype " + p.ph, { x: 0.45, y: y + 0.08, w: 2.2, h: 0.35, fontSize: 13, bold: true, color: C.gold, fontFace: "Calibri" });
  s.addText(p.features, { x: 2.7, y: y + 0.06, w: 4.5, h: 0.4, fontSize: 13, color: C.white, fontFace: "Calibri" });
  s.addText(p.severity, { x: 7.3, y: y + 0.06, w: 2.3, h: 0.4, fontSize: 12, color: C.lightPink, italic: true, fontFace: "Calibri", align: "right" });
  s.addText("HA: " + (p.ph.includes("A") || p.ph.includes("B") || p.ph.includes("C") ? "✓" : "✗") + "  Oligo: " + (p.ph.includes("A") || p.ph.includes("B") || p.ph.includes("D") ? "✓" : "✗") + "  PCOM: " + (p.ph.includes("A") || p.ph.includes("C") || p.ph.includes("D") ? "✓" : "✗"),
    { x: 0.45, y: y + 0.45, w: 9.0, h: 0.3, fontSize: 11, color: C.lightPink, fontFace: "Calibri" });
});

// ── SLIDE 12: Clinical Features ──────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Clinical Features of PMOS", false);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Fitzpatrick's Dermatology | Kaplan & Sadock's Psychiatry");

const columns = [
  {
    title: "Reproductive", color: C.rose,
    items: ["Oligomenorrhoea / amenorrhoea", "Anovulatory infertility", "Recurrent early miscarriage", "Gestational diabetes risk", "Preeclampsia risk ↑", "↑ Risk endometrial hyperplasia & cancer (2–6×)"],
  },
  {
    title: "Metabolic", color: C.teal,
    items: ["Insulin resistance (50–80%)", "Metabolic syndrome (12–60%)", "Type 2 diabetes risk ↑", "Dyslipidaemia", "Hypertension", "MAFLD/MASLD ↑ (independent of BMI)"],
  },
  {
    title: "Dermatological", color: C.magenta,
    items: ["Hirsutism (mFG score)", "Acne vulgaris", "Androgenic alopecia", "Acanthosis nigricans (IR)", "Seborrhoea", "Skin tags"],
  },
  {
    title: "Psychological", color: C.purple,
    items: ["Depression (↑ prevalence)", "Anxiety disorders", "Disordered eating", "Body image distress", "Low self-esteem", "Quality of life impaired"],
  },
];

columns.forEach((col, i) => {
  const x = 0.3 + i * 2.4;
  s.addShape(pres.ShapeType.roundRect, {
    x, y: 1.05, w: 2.25, h: 0.45,
    fill: { color: col.color }, line: { color: col.color }, rectRadius: 0.06
  });
  s.addText(col.title, { x: x + 0.05, y: 1.07, w: 2.15, h: 0.4, fontSize: 14, bold: true, color: C.white, align: "center", fontFace: "Calibri" });
  col.items.forEach((item, j) => {
    s.addShape(pres.ShapeType.rect, { x: x + 0.05, y: 1.62 + j * 0.62, w: 0.08, h: 0.08, fill: { color: col.color }, line: { color: col.color } });
    s.addText(item, { x: x + 0.18, y: 1.58 + j * 0.62, w: 2.0, h: 0.55, fontSize: 11, color: C.textDark, fontFace: "Calibri", wrap: true });
  });
});

// ── SLIDE 13: PCOS Ultrasound Image ──────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Imaging — Polycystic Ovarian Morphology (PCOM)", true);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Tietz Lab Medicine 7e | Image: PMC Clinical VQA");

if (images[0] && !images[0].error) {
  s.addImage({ data: images[0].base64, x: 0.4, y: 1.05, w: 5.0, h: 4.2 });
} else {
  s.addShape(pres.ShapeType.rect, { x: 0.4, y: 1.05, w: 5.0, h: 4.2, fill: { color: C.purple }, line: { color: C.accent } });
  s.addText("[Transvaginal Ultrasound Image]", { x: 0.4, y: 2.5, w: 5.0, h: 0.5, fontSize: 14, color: C.white, align: "center" });
}

s.addText([
  { text: "PCOM Criteria:\n", options: { bold: true, color: C.gold, fontSize: 14, breakLine: true } },
  { text: "≥20 antral follicles (2–9 mm) in ≥1 ovary OR\n", options: { color: C.lightPink, fontSize: 13, breakLine: true } },
  { text: "Ovarian volume ≥10 cm³\n", options: { color: C.lightPink, fontSize: 13, breakLine: true } },
  { text: "\nClassic 'string of pearls' appearance\n", options: { color: C.accent, fontSize: 13, bold: true, breakLine: true } },
  { text: "\nAMH increasingly preferred:\n", options: { bold: true, color: C.gold, fontSize: 13, breakLine: true } },
  { text: "• No internal ultrasound needed\n• Cheaper & more accessible\n• 60% of women don't need ovarian imaging\n", options: { color: C.lightPink, fontSize: 12, breakLine: true } },
  { text: "\nUS not recommended in adolescents\n(not yet validated in this group)", options: { color: C.pink, fontSize: 12, italic: true } },
], { x: 5.6, y: 1.1, w: 4.2, h: 4.1, fontFace: "Calibri", wrap: true });

// ── SLIDE 14: Hormonal & Lab Investigations ──────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Hormonal & Laboratory Investigations", false);
addFooter(s, "Harrison's 22e | Tietz Lab Medicine 7e | Fitzpatrick's Dermatology | Berek & Novak's");

const labs = [
  ["Serum Free Testosterone", "Most sensitive for biochemical hyperandrogenism; ↑ in PMOS", C.rose],
  ["Total Testosterone", "Useful; very high values suggest tumour (>200 ng/dL)", C.magenta],
  ["DHEAS", "Adrenal androgen; elevated in ~25–35% of PMOS; very high → CAH or adrenal tumour", C.purple],
  ["LH / FSH", "LH:FSH ratio often >2:1; not diagnostic criterion; useful when lean", C.deepPurple],
  ["Serum AMH", "Elevated (3–4× normal); emerging first-line diagnostic marker for PCOM", C.teal],
  ["Fasting glucose + OGTT", "Diagnose impaired glucose tolerance or T2DM; essential screening", C.rose],
  ["Fasting lipid profile", "Dyslipidaemia screening in overweight/obese at diagnosis", C.magenta],
  ["TSH + Prolactin", "Exclude hypothyroidism and hyperprolactinaemia (differentials)", C.purple],
  ["17-OHP", "Exclude non-classical CAH (especially with rapid-onset hirsutism)", C.deepPurple],
];

labs.forEach(([test, detail, color], i) => {
  const col = i < 5 ? 0 : 1;
  const row = i < 5 ? i : i - 5;
  if (i === 8) { return; } // skip last one for space
  const y = 1.1 + row * 0.82;
  const x = 0.3 + col * 5.0;
  s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.65, h: 0.75, fill: { color }, line: { color: C.accent, pt: 1 }, rectRadius: 0.07 });
  s.addText(test, { x: x + 0.1, y: y + 0.05, w: 4.45, h: 0.3, fontSize: 13, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(detail, { x: x + 0.1, y: y + 0.36, w: 4.45, h: 0.33, fontSize: 11, color: C.lightPink, fontFace: "Calibri", wrap: true });
});
// last lab
s.addShape(pres.ShapeType.roundRect, { x: 5.3, y: 1.1 + 3 * 0.82 + 0.05, w: 4.65, h: 0.75, fill: { color: C.deepPurple }, line: { color: C.accent, pt: 1 }, rectRadius: 0.07 });
s.addText("17-OHP", { x: 5.4, y: 1.1 + 3 * 0.82 + 0.1, w: 4.45, h: 0.28, fontSize: 13, bold: true, color: C.white, fontFace: "Calibri" });
s.addText("Exclude non-classical CAH (especially with rapid-onset hirsutism)", { x: 5.4, y: 1.1 + 3 * 0.82 + 0.4, w: 4.45, h: 0.3, fontSize: 11, color: C.lightPink, fontFace: "Calibri" });

// ── SLIDE 15: Metabolic Complications ───────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Metabolic & Cardiometabolic Complications", true);
addFooter(s, "Harrison's 22e | Guyton & Hall | Bailey & Love's Surgery 28e | Goldman-Cecil Medicine");

s.addText([
  { text: "Insulin Resistance — the Central Metabolic Defect\n", options: { bold: true, color: C.gold, fontSize: 16, breakLine: true } },
  { text: "Present in 50–80% of PMOS patients (independent of obesity)\n", options: { color: C.lightPink, fontSize: 14, breakLine: true } },
  { text: "Mechanism: skeletal muscle + adipose tissue IR → compensatory hyperinsulinaemia → ovarian androgen overproduction\n", options: { color: C.lightPink, fontSize: 13, breakLine: true } },
], { x: 0.3, y: 1.05, w: 9.4, h: 1.5, fontFace: "Calibri", wrap: true });

const metComps = [
  ["Type 2 Diabetes", "3.5× risk vs general population; impaired glucose tolerance in 30%", C.rose],
  ["Metabolic Syndrome", "Prevalence 12–60% depending on phenotype; IDF criteria", C.magenta],
  ["Cardiovascular Disease", "↑ Risk — endothelial dysfunction, atherogenic dyslipidaemia, hypertension", C.purple],
  ["MASLD / NAFLD", "Higher prevalence independent of BMI; linked to IR and hyperandrogenaemia", C.teal],
  ["Obstructive Sleep Apnoea", "3–10× risk; independent of BMI; bidirectional with IR", C.deepPurple],
  ["Endometrial Cancer", "2–6× increased risk from chronic anovulation + unopposed oestrogen", C.rose],
];

metComps.forEach(([comp, detail, color], i) => {
  const col = i % 2;
  const row = Math.floor(i / 2);
  const x = 0.3 + col * 4.8;
  const y = 2.65 + row * 0.9;
  s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.6, h: 0.82, fill: { color }, line: { color: C.accent, pt: 1 }, rectRadius: 0.07 });
  s.addText(comp, { x: x + 0.1, y: y + 0.04, w: 4.4, h: 0.3, fontSize: 13, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(detail, { x: x + 0.1, y: y + 0.36, w: 4.4, h: 0.4, fontSize: 11, color: C.lightPink, fontFace: "Calibri", wrap: true });
});

// ── SLIDE 16: Reproductive Complications ────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Reproductive Health Implications", false);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Creasy & Resnik's Maternal-Fetal Medicine");

s.addText([
  bullet("Anovulatory infertility — most common cause in women with PMOS"),
  bullet("Subfertility due to infrequent or absent ovulation (not absolute infertility)"),
  bullet("↑ Risk of early miscarriage — likely related to IR and hyperandrogenaemia"),
  bullet("Gestational diabetes — 3× higher risk; screen all PMOS pregnancies"),
  bullet("Gestational hypertension and pre-eclampsia — significantly elevated risk"),
  bullet("Preterm birth — higher incidence, especially with ART pregnancies"),
  bullet("Endometrial hyperplasia → endometrial cancer (2–6× risk from chronic anovulation)"),
  bullet("PMOS increases risk of hyperstimulation in ART — require cautious gonadotrophin dosing"),
], {
  x: 0.4, y: 1.1, w: 9.2, h: 4.15,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 17: Psychological & Quality of Life ────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Psychological Health & Quality of Life", true);
addFooter(s, "Kaplan & Sadock's Psychiatry 10e | Harrison's 22e | Teede HJ et al. Lancet 2026");

s.addText([
  { text: "High prevalence of mental health burden in PMOS — often under-recognised\n", options: { bold: true, color: C.gold, fontSize: 15, breakLine: true } },
], { x: 0.3, y: 1.05, w: 9.4, h: 0.55, fontFace: "Calibri" });

const psych = [
  { cond: "Depression", stat: "2–3× higher prevalence vs. general population", note: "Screen at diagnosis and regularly" },
  { cond: "Anxiety Disorders", stat: "Generalised anxiety most common; panic disorder also ↑", note: "Often co-occurs with depression" },
  { cond: "Disordered Eating", stat: "Binge eating, emotional eating — linked to body image distress", note: "Screen with validated tools" },
  { cond: "Body Image Distress", stat: "Hirsutism, acne, weight gain — significant psychosocial impact", note: "Address in patient counselling" },
  { cond: "Obstructive Sleep Apnoea", stat: "10× risk; poor sleep worsens IR and mood disorders", note: "Screen all patients" },
];

psych.forEach((p, i) => {
  const y = 1.65 + i * 0.72;
  s.addShape(pres.ShapeType.roundRect, { x: 0.3, y, w: 9.4, h: 0.65, fill: { color: i % 2 === 0 ? C.rose : C.purple }, line: { color: C.accent, pt: 1 }, rectRadius: 0.07 });
  s.addText(p.cond, { x: 0.45, y: y + 0.08, w: 2.2, h: 0.3, fontSize: 13, bold: true, color: C.gold, fontFace: "Calibri" });
  s.addText(p.stat, { x: 2.75, y: y + 0.08, w: 4.5, h: 0.45, fontSize: 12, color: C.white, fontFace: "Calibri", wrap: true });
  s.addText(p.note, { x: 7.35, y: y + 0.1, w: 2.3, h: 0.4, fontSize: 11, color: C.lightPink, italic: true, fontFace: "Calibri", align: "right" });
});

// ── SLIDE 18: PMOS in Adolescents ────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "PMOS in Adolescents — Special Considerations", false);
addFooter(s, "Harrison's 22e p.3135 | Berek & Novak's Gynecology | 2023 International PCOS Guidelines");

s.addText([
  bullet("Diagnosis should be deferred until ≥3 years after menarche"),
  bullet("Normal adolescent development mimics PMOS features"),
  bullet("In adolescents: only 2 criteria used — irregular menses + hyperandrogenism"),
  subbullet("PCOM (ultrasound) and AMH criteria are NOT validated for adolescents"),
  bullet("Irregular cycles are normal for 1–2 years post-menarche; caution with early labelling"),
  bullet("BMI, waist circumference, BP, and fasting glucose should be measured"),
  bullet("Psychological screening is especially important — depression and anxiety peak in adolescence"),
  bullet("Lifestyle intervention is the primary treatment — before pharmacotherapy"),
  bullet("Oral contraceptive pill (OCP) addresses menstrual irregularity + hyperandrogenism in adolescents"),
], {
  x: 0.4, y: 1.1, w: 9.2, h: 4.15,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 19: PMOS in Pregnancy ──────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "PMOS & Pregnancy — Fertility Management", true);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Creasy & Resnik's Maternal-Fetal Medicine");

s.addText("Ovulation Induction Ladder:", {
  x: 0.4, y: 1.05, w: 9.2, h: 0.45,
  fontSize: 16, bold: true, color: C.gold, fontFace: "Calibri"
});

const fertility = [
  { step: "1st Line", rx: "Letrozole (aromatase inhibitor)", detail: "Superior ovulation and live birth rates vs clomiphene; lower multiple pregnancy risk" },
  { step: "2nd Line", rx: "Clomiphene Citrate ± Metformin", detail: "Selective oestrogen receptor modulator; add metformin in obese / insulin-resistant women" },
  { step: "3rd Line", rx: "Injectable Gonadotrophins", detail: "By experienced practitioners; cautious dosing — PMOS ↑ hyperstimulation risk" },
  { step: "4th Line", rx: "IVF / ICSI", detail: "In vitro fertilisation; freeze-all embryos in PMOS to reduce OHSS risk; consider oocyte donation" },
];

fertility.forEach((f, i) => {
  const y = 1.6 + i * 0.9;
  s.addShape(pres.ShapeType.roundRect, { x: 0.3, y, w: 9.4, h: 0.82, fill: { color: i % 2 === 0 ? C.rose : C.purple }, line: { color: C.gold, pt: 1.5 }, rectRadius: 0.08 });
  s.addText(f.step, { x: 0.45, y: y + 0.04, w: 1.3, h: 0.7, fontSize: 13, bold: true, color: C.gold, fontFace: "Calibri", valign: "middle", align: "center" });
  s.addShape(pres.ShapeType.rect, { x: 1.85, y: y + 0.12, w: 0.03, h: 0.55, fill: { color: C.accent }, line: { color: C.accent } });
  s.addText(f.rx, { x: 2.0, y: y + 0.04, w: 3.0, h: 0.35, fontSize: 14, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(f.detail, { x: 2.0, y: y + 0.42, w: 7.55, h: 0.35, fontSize: 12, color: C.lightPink, fontFace: "Calibri" });
});

s.addText("Lifestyle management + pre-pregnancy counselling recommended prior to attempting conception in all PMOS patients.", {
  x: 0.3, y: 5.22, w: 9.4, h: 0.3,
  fontSize: 11, color: C.lightPink, italic: true, fontFace: "Calibri", align: "center"
});

// ── SLIDE 20: Lifestyle Management ──────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Lifestyle Management — First-Line Treatment", false);
addFooter(s, "Harrison's 22e | Bailey & Love's Surgery 28e | 2023 International PCOS Guidelines");

s.addShape(pres.ShapeType.roundRect, {
  x: 0.3, y: 1.05, w: 9.4, h: 0.55,
  fill: { color: C.teal }, line: { color: C.teal }, rectRadius: 0.08
});
s.addText("Lifestyle intervention is the first-line treatment for all women with PMOS, regardless of BMI.", {
  x: 0.4, y: 1.08, w: 9.2, h: 0.5,
  fontSize: 14, bold: true, color: C.white, fontFace: "Calibri", align: "center"
});

s.addText([
  bullet("Diet: Mediterranean or low-glycaemic-index diet preferred; caloric restriction in overweight"),
  bullet("Physical Activity: ≥150 min/week moderate aerobic + 2× resistance training; improves IR"),
  bullet("Weight Loss: 5–10% loss → significant improvement in cycle regularity, IR, androgens"),
  bullet("Behavioural Support: Motivational interviewing; mindfulness-based interventions"),
  bullet("Sleep: Address OSA — PAP therapy; improves IR and QoL"),
  bullet("Smoking cessation: Smoking worsens hyperandrogenism and cardiovascular risk"),
  bullet("Metformin: First-line pharmacological adjunct in overweight/obese women — prevents T2DM and metabolic syndrome; reduces miscarriage risk"),
], {
  x: 0.4, y: 1.7, w: 9.2, h: 3.55,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 21: Pharmacological Management ────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Pharmacological Management", true);
addFooter(s, "Harrison's 22e p.3135 | 2023 International PCOS Guidelines | Goldman-Cecil Medicine");

const drugs = [
  { drug: "Combined OCP", indication: "1st-line — menstrual regulation + hyperandrogenism", detail: "Lowest effective oestrogen dose; cyclic or continuous; increases SHBG → ↓ free testosterone", color: C.rose },
  { drug: "Metformin", indication: "IR, metabolic risk, prevention T2DM", detail: "Recommended in overweight/obese; adjunct with diet/exercise; NOT for endometrial protection alone or hyperandrogenic symptoms", color: C.magenta },
  { drug: "Spironolactone", indication: "Anti-androgen — hirsutism, acne (after 6 months OCP failure)", detail: "Requires contraception (teratogenic); 50–200 mg/day; monitor potassium and BP", color: C.purple },
  { drug: "Flutamide", indication: "Anti-androgen — 2nd line", detail: "Hepatotoxicity risk — monitor LFTs; requires contraception; less used than spironolactone", color: C.deepPurple },
  { drug: "Progestin (MPA/Prometrium)", indication: "Endometrial protection in anovulatory women", detail: "10–14 days every 3 months minimum OR levonorgestrel IUD if no OCP", color: C.teal },
  { drug: "Letrozole / Clomiphene", indication: "Ovulation induction for fertility", detail: "Letrozole is 1st-line (aromatase inhibitor); clomiphene + metformin 2nd-line", color: C.rose },
];

drugs.forEach((d, i) => {
  const col = i < 3 ? 0 : 1;
  const row = i < 3 ? i : i - 3;
  const x = 0.3 + col * 4.85;
  const y = 1.1 + row * 1.4;
  s.addShape(pres.ShapeType.roundRect, { x, y, w: 4.55, h: 1.32, fill: { color: d.color }, line: { color: C.accent, pt: 1.5 }, rectRadius: 0.1 });
  s.addText(d.drug, { x: x + 0.1, y: y + 0.05, w: 4.35, h: 0.32, fontSize: 15, bold: true, color: C.gold, fontFace: "Calibri" });
  s.addText(d.indication, { x: x + 0.1, y: y + 0.38, w: 4.35, h: 0.28, fontSize: 12, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(d.detail, { x: x + 0.1, y: y + 0.68, w: 4.35, h: 0.58, fontSize: 11, color: C.lightPink, fontFace: "Calibri", wrap: true });
});

// ── SLIDE 22: Anti-androgen Therapy & Dermatology ────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Hyperandrogenism — Dermatological Management", false);
addFooter(s, "Fitzpatrick's Dermatology 9e | Andrews' Diseases of the Skin | Dermatology 2-Vol Set 5e");

s.addText([
  bullet("Hirsutism Assessment: Modified Ferriman-Gallwey (mFG) scoring system — rate 9 androgen-sensitive areas"),
  bullet("Threshold: mFG ≥4–6 (varies by ethnicity); upper lip, chin, chest, abdomen, back, thighs"),
  bullet("1st-line: Combined OCP — increases SHBG → ↓ free testosterone; needs 6 months to assess hirsutism response"),
  bullet("Anti-androgens (after 6 months OCP failure):", false),
  subbullet("Spironolactone 50–200 mg/day (aldosterone antagonist; most used)"),
  subbullet("Flutamide (hepatotoxic — monitor LFTs), Bicalutamide, Cyproterone acetate"),
  bullet("Acne: Treat with OCP ± topical therapy; isotretinoin for severe/recalcitrant cases"),
  bullet("Alopecia: OCP + minoxidil (topical); spironolactone in non-pregnant women"),
  bullet("Mechanical hair removal: Laser/IPL (adjunct, not replacement for systemic treatment)"),
  bullet("Acanthosis nigricans: Treat underlying IR with metformin and lifestyle change"),
], {
  x: 0.4, y: 1.1, w: 9.2, h: 4.15,
  fontFace: "Calibri", fontSize: 13.5, color: C.textDark
});

// ── SLIDE 23: Screening & Monitoring Protocol ────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Screening & Monitoring Protocol", true);
addFooter(s, "Harrison's 22e | 2023 International PCOS Guidelines | Goldman-Cecil Medicine");

const monitoring = [
  { when: "AT DIAGNOSIS", items: ["BMI & waist circumference", "BP measurement", "Fasting glucose ± OGTT", "Fasting lipid profile (if overweight/obese)", "TSH + prolactin (to exclude differentials)", "Free testosterone + DHEAS", "Depression/anxiety screening (PHQ-9, GAD-7)"] },
  { when: "EVERY 1–2 YEARS", items: ["Repeat fasting glucose / HbA1c", "Lipid profile", "BP monitoring", "Weight management review", "Repeat psychological screening", "Review menstrual pattern & symptoms", "Endometrial assessment if anovulatory >6 months"] },
];

monitoring.forEach((m, i) => {
  const x = 0.3 + i * 4.85;
  s.addShape(pres.ShapeType.roundRect, { x, y: 1.05, w: 4.55, h: 0.5, fill: { color: i === 0 ? C.rose : C.purple }, line: { color: C.accent, pt: 1.5 }, rectRadius: 0.08 });
  s.addText(m.when, { x: x + 0.1, y: 1.07, w: 4.35, h: 0.45, fontSize: 14, bold: true, color: C.white, align: "center", fontFace: "Calibri" });
  m.items.forEach((item, j) => {
    s.addText("✓  " + item, { x: x + 0.15, y: 1.65 + j * 0.53, w: 4.25, h: 0.48, fontSize: 12.5, color: C.lightPink, fontFace: "Calibri" });
    if (j < m.items.length - 1) {
      s.addShape(pres.ShapeType.rect, { x: x + 0.15, y: 1.65 + (j + 1) * 0.53 - 0.05, w: 4.1, h: 0.01, fill: { color: "FFFFFF", alpha: 30 }, line: { color: "FFFFFF", alpha: 30 } });
    }
  });
});

// ── SLIDE 24: PMOS Ultrasound Image 2 ────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "Diagnostic Imaging — Bilateral Ovarian Assessment", false);
addFooter(s, "Harrison's 22e | Berek & Novak's Gynecology | Image: PMC Clinical VQA");

if (images[1] && !images[1].error) {
  s.addImage({ data: images[1].base64, x: 0.4, y: 1.05, w: 9.1, h: 4.2 });
} else {
  s.addShape(pres.ShapeType.rect, { x: 0.4, y: 1.05, w: 9.1, h: 4.2, fill: { color: C.lavender }, line: { color: C.purple } });
  s.addText("[Bilateral Ovaries + Uterus Ultrasound]\nPanel A: Bilateral multifollicular ovaries\nPanel B: Sagittal uterus view with thin endometrium", {
    x: 0.6, y: 2.5, w: 8.8, h: 1.5, fontSize: 14, color: C.textDark, align: "center"
  });
}

// ── SLIDE 25: The New PMOS Framework ─────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "The PMOS Framework — Why the New Name is Better", true);
addFooter(s, "Teede HJ et al. Lancet 2026 | Society for Endocrinology, 2026 | CU Anschutz, 2026");

const compare = [
  { aspect: "Accuracy", old: "Implies pathological ovarian cysts — misnomer", nw: "Reflects multisystem endocrine & metabolic reality" },
  { aspect: "Diagnosis", old: "Delayed in ~70% due to misconceptions", nw: "Earlier & more accurate recognition" },
  { aspect: "Treatment", old: "Fragmented; over-emphasis on ovaries/fertility", nw: "Holistic, patient-centred, multidisciplinary" },
  { aspect: "Research", old: "Limited to reproductive/gynaecology sphere", nw: "Expands to metabolic, cardiovascular, neurology" },
  { aspect: "Stigma", old: "Fertility stigma; 'cyst' misconception", nw: "Reduces stigma; empowers patients" },
  { aspect: "Funding", old: "Limited funding outside reproductive medicine", nw: "Opens doors to broader research funding" },
];

s.addText("Aspect", { x: 0.3, y: 1.07, w: 1.8, h: 0.35, fontSize: 12, bold: true, color: C.gold, fontFace: "Calibri" });
s.addText("PCOS (Old)", { x: 2.2, y: 1.07, w: 3.6, h: 0.35, fontSize: 12, bold: true, color: C.pink, fontFace: "Calibri", align: "center" });
s.addText("PMOS (New)", { x: 5.9, y: 1.07, w: 3.9, h: 0.35, fontSize: 12, bold: true, color: C.gold, fontFace: "Calibri", align: "center" });

compare.forEach((row, i) => {
  const y = 1.5 + i * 0.65;
  const bg = i % 2 === 0 ? C.purple : C.deepPurple;
  s.addShape(pres.ShapeType.rect, { x: 0.3, y, w: 9.4, h: 0.6, fill: { color: bg }, line: { color: C.accent, pt: 0.5 } });
  s.addText(row.aspect, { x: 0.4, y: y + 0.1, w: 1.7, h: 0.4, fontSize: 12, bold: true, color: C.gold, fontFace: "Calibri" });
  s.addText("✗ " + row.old, { x: 2.2, y: y + 0.08, w: 3.5, h: 0.45, fontSize: 11, color: C.pink, fontFace: "Calibri", wrap: true });
  s.addText("✓ " + row.nw, { x: 5.9, y: y + 0.08, w: 3.7, h: 0.45, fontSize: 11, color: C.lightPink, fontFace: "Calibri", wrap: true });
});

// ── SLIDE 26: PMOS in Special Populations ────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "PMOS in Special Populations", false);
addFooter(s, "Harrison's 22e | Creasy & Resnik's Maternal-Fetal Medicine | Berek & Novak's");

s.addText([
  { text: "Obese Women:\n", options: { bold: true, color: C.rose, fontSize: 15, breakLine: true } },
  { text: "  • Significantly ↑ metabolic comorbidities; lifestyle + metformin essential; fasting lipids mandatory\n", options: { color: C.textDark, fontSize: 13, breakLine: true } },
  { text: "Lean/Normal Weight Women:\n", options: { bold: true, color: C.magenta, fontSize: 15, breakLine: true } },
  { text: "  • Do not dismiss PMOS — lean IR present; high LH typical; AMH elevated\n", options: { color: C.textDark, fontSize: 13, breakLine: true } },
  { text: "Post-Menopausal Women:\n", options: { bold: true, color: C.purple, fontSize: 15, breakLine: true } },
  { text: "  • Ongoing metabolic risk persists post-menopause; continue CVD risk monitoring\n", options: { color: C.textDark, fontSize: 13, breakLine: true } },
  { text: "Transgender Men (AFAB):\n", options: { bold: true, color: C.teal, fontSize: 15, breakLine: true } },
  { text: "  • PMOS may be masked by testosterone therapy; reproductive history important\n", options: { color: C.textDark, fontSize: 13, breakLine: true } },
  { text: "Ethnic Variations:\n", options: { bold: true, color: C.rose, fontSize: 15, breakLine: true } },
  { text: "  • South Asian women: higher metabolic risk at lower BMI; use ethnicity-specific mFG thresholds\n  • Different AMH cut-offs may apply across ethnicities", options: { color: C.textDark, fontSize: 13 } },
], {
  x: 0.4, y: 1.1, w: 9.2, h: 4.15,
  fontFace: "Calibri", wrap: true
});

// ── SLIDE 27: Implementation Strategy ───────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Global Implementation Strategy", true);
addFooter(s, "Teede HJ et al. Lancet 2026 | Society for Endocrinology 2026 | BMJ 2026");

s.addText([
  { text: "Co-designed strategy — 'Evolution, not Transformation'\n", options: { bold: true, color: C.gold, fontSize: 16, breakLine: true } },
], { x: 0.3, y: 1.05, w: 9.4, h: 0.5, fontFace: "Calibri" });

const impl = [
  { phase: "2026", icon: "📢", title: "Name Launch", actions: "Lancet publication; Society endorsements; Patient education campaigns; Media engagement" },
  { phase: "2026–27", icon: "🏥", title: "Clinical Adoption", actions: "Update international guidelines; Medical education curriculum changes; Electronic health record updates" },
  { phase: "2027", icon: "🔬", title: "Research Realignment", actions: "Reframe research funding priorities; Integrate metabolic/cardiometabolic outcomes; New biomarker validation" },
  { phase: "2028", icon: "🌐", title: "ICD Update", actions: "PCOS replaced by PMOS in International Classification of Diseases; Global coding alignment" },
];

impl.forEach((it, i) => {
  const y = 1.6 + i * 0.93;
  s.addShape(pres.ShapeType.roundRect, { x: 0.3, y, w: 9.4, h: 0.85, fill: { color: i % 2 === 0 ? C.rose : C.purple }, line: { color: C.accent, pt: 1 }, rectRadius: 0.08 });
  s.addText(it.phase, { x: 0.45, y: y + 0.08, w: 1.0, h: 0.65, fontSize: 16, bold: true, color: C.gold, fontFace: "Calibri", align: "center", valign: "middle" });
  s.addText(it.icon + " " + it.title, { x: 1.6, y: y + 0.05, w: 2.4, h: 0.38, fontSize: 14, bold: true, color: C.white, fontFace: "Calibri" });
  s.addText(it.actions, { x: 1.6, y: y + 0.44, w: 8.0, h: 0.36, fontSize: 12, color: C.lightPink, fontFace: "Calibri" });
});

// ── SLIDE 28: Patient Perspective ────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, false);
addSlideHeader(s, "The Patient Perspective — Why This Matters", false);
addFooter(s, "Teede HJ et al. Lancet 2026 | Wu P et al. BMJ 2026 | Society for Endocrinology 2026");

s.addShape(pres.ShapeType.roundRect, {
  x: 0.4, y: 1.05, w: 9.2, h: 1.1,
  fill: { color: C.purple }, line: { color: C.accent, pt: 2 }, rectRadius: 0.1
});
s.addText('"This is about accountability and progress. It is about my daughters, their daughters, and the countless women yet to be born. We deserve clarity, understanding, and equitable healthcare from the very beginning."', {
  x: 0.6, y: 1.08, w: 8.9, h: 1.02,
  fontSize: 13, color: C.lightPink, italic: true, fontFace: "Calibri", wrap: true, valign: "middle"
});
s.addText("— Lorna Berry, patient advocate and key contributor to PMOS renaming process", {
  x: 0.4, y: 2.2, w: 9.2, h: 0.3,
  fontSize: 11, color: C.textGray, italic: true, fontFace: "Calibri"
});

s.addText([
  bullet("14,360 patients and health professionals surveyed worldwide in renaming process"),
  bullet("Patients reported: fertility stigma, confusion about cysts, delayed care, poor quality of life"),
  bullet("New name leads with hormones → shifting the narrative to whole-body health"),
  bullet("'Language matters in medicine' — Melanie Cree, MD PhD, CU Anschutz"),
  bullet("Expected benefits: earlier diagnosis, reduced stigma, multidisciplinary care"),
  bullet("BMJ (May 2026): calls for improved awareness and care with new name"),
], {
  x: 0.4, y: 2.6, w: 9.2, h: 2.65,
  fontFace: "Calibri", fontSize: 14, color: C.textDark
});

// ── SLIDE 29: Key References ─────────────────────────────────────────────────
s = pres.addSlide();
contentSlideBG(s, true);
addSlideHeader(s, "Key References", true);

const refs = [
  "1. Teede HJ, Khomami MB, Morman R, et al. Polyendocrine metabolic ovarian syndrome, the new name for polycystic ovary syndrome: a multistep global consensus process. Lancet. 2026 May 12. DOI: 10.1016/S0140-6736(26)00717-8 [PMID: 42119588]",
  "2. Wu P, Chew-Graham CA, Heera-Shergill N. Improving awareness and care in polyendocrine metabolic ovarian syndrome. BMJ. 2026 May 15. [PMID: 42140655]",
  "3. Harrison's Principles of Internal Medicine, 22nd Edition. McGraw Hill, 2025. Chapter 404/406 — Polycystic Ovary Syndrome, pp.3134–3136.",
  "4. Berek JS, Novak E. Berek & Novak's Gynecology, 16th Edition. Wolters Kluwer, 2020. Chapter 30 — Polycystic Ovarian Syndrome, pp.1879–1882.",
  "5. Creasy RK, Resnik R. Creasy & Resnik's Maternal-Fetal Medicine, 9th Edition. Elsevier, 2022. Chapter — PCOS and Insulin Resistance.",
  "6. Tietz NW. Tietz Textbook of Laboratory Medicine, 7th Edition. Elsevier. Secondary Amenorrhea / PCOS section, pp.2457–2475.",
  "7. Kasper DL, Fauci AS. Goldman-Cecil Medicine International Edition, 2 Vol Set. Elsevier, 2022. Chapter — PCOS.",
  "8. 2023 International Evidence-Based Guideline for Assessment & Management of PCOS. Teede HJ et al. Monash University / NHMRC.",
  "9. Guyton AC, Hall JE. Guyton & Hall Textbook of Medical Physiology, 14th Ed. Elsevier. Ch. 79 — Insulin Resistance.",
  "10. Fitzpatrick's Dermatology, 9th Edition / Andrews' Diseases of the Skin — Hyperandrogenism and PCOS sections.",
];

refs.forEach((ref, i) => {
  s.addText(ref, {
    x: 0.3, y: 1.1 + i * 0.42,
    w: 9.4, h: 0.42,
    fontSize: 9.5, color: i === 0 ? C.gold : C.lightPink, fontFace: "Calibri", wrap: true
  });
});

// ── SLIDE 30: Summary & Key Messages ────────────────────────────────────────
s = pres.addSlide();
titleSlide(s);
s.addText("Key Messages — PMOS 2026", {
  x: 0.5, y: 0.25, w: 9, h: 0.65,
  fontSize: 24, bold: true, color: C.gold, fontFace: "Calibri", align: "center", charSpacing: 1
});

const messages = [
  { n: "1", msg: "PCOS is now PMOS — polyendocrine metabolic ovarian syndrome", sub: "Lancet, May 12, 2026 | Global consensus, 56 organisations" },
  { n: "2", msg: "Affects 1 in 8 women (>170 million) — most common endocrine disorder in women", sub: "" },
  { n: "3", msg: "Multisystem: endocrine, metabolic, reproductive, dermatological, psychological", sub: "Not just an ovarian condition" },
  { n: "4", msg: "Diagnosis: ≥2 of 3 Rotterdam criteria (updated 2023) — exclusion diagnosis", sub: "Irregular menses, hyperandrogenism, PCOM/elevated AMH" },
  { n: "5", msg: "IR (50–80%), T2DM, CVD, MASLD, OSA, endometrial cancer — long-term risks", sub: "Require proactive screening and monitoring" },
  { n: "6", msg: "Treatment: lifestyle first, then OCP, metformin, anti-androgens, letrozole", sub: "Holistic, multidisciplinary care model" },
  { n: "7", msg: "ICD transition to PMOS expected by 2028", sub: "Language shapes diagnosis, care and research" },
];

messages.forEach((m, i) => {
  const y = 1.0 + i * 0.64;
  s.addShape(pres.ShapeType.roundRect, {
    x: 0.3, y, w: 9.4, h: 0.58,
    fill: { color: i % 2 === 0 ? C.magenta : C.purple }, line: { color: C.accent, pt: 1 }, rectRadius: 0.07
  });
  s.addShape(pres.ShapeType.ellipse, { x: 0.38, y: y + 0.1, w: 0.38, h: 0.38, fill: { color: C.gold }, line: { color: C.gold } });
  s.addText(m.n, { x: 0.38, y: y + 0.1, w: 0.38, h: 0.38, fontSize: 13, bold: true, color: C.deepPurple, align: "center", valign: "middle", fontFace: "Calibri" });
  s.addText(m.msg, { x: 0.88, y: y + 0.05, w: 8.7, h: 0.28, fontSize: 13.5, bold: true, color: C.white, fontFace: "Calibri" });
  if (m.sub) {
    s.addText(m.sub, { x: 0.88, y: y + 0.33, w: 8.7, h: 0.22, fontSize: 10.5, color: C.lightPink, italic: true, fontFace: "Calibri" });
  }
});

s.addText("Teede HJ et al. Lancet 2026 | Harrison's 22e | Berek & Novak's Gynecology | Goldman-Cecil Medicine", {
  x: 0.3, y: 5.3, w: 9.4, h: 0.25,
  fontSize: 9, color: C.pink, italic: true, fontFace: "Calibri", align: "center"
});

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

cd /home/daytona/workspace/pmos-pptx && node build_pmos.js 2>&1

Running Command

ls -lh /home/daytona/workspace/pmos-pptx/ && python3 -m markitdown /home/daytona…

Your 30-slide presentation is ready:

PMOS Polyendocrine Metabolic Ovarian Syndrome

Presentation · PPTX


What's Inside (30 Slides)

#Slide Title
1Title Slide — PMOS, The New Name for PCOS
2The Historic Renaming — Lancet, May 12, 2026
3Why PCOS Had to Change — misnomer, delayed diagnosis, stigma
4The Global Consensus Process — 6-step infographic
5Definition of PMOS — prevalence, scope
6Pathophysiology — 6-system overview cards
7The 'Polyendocrine' Dimension — all 5 endocrine axes
8Epidemiology — stat cards (1 in 8, >170 million, ~70% undiagnosed)
9Diagnostic Criteria — Updated Rotterdam 2023 (3 pillars)
10Exclusion Criteria — differential diagnoses
11Clinical Phenotypes A–D — severity stratification
12Clinical Features — 4-column table (reproductive, metabolic, dermatological, psychological)
13Imaging — PCOM ultrasound (string of pearls) + criteria
14Hormonal & Lab Investigations
15Metabolic & Cardiometabolic Complications
16Reproductive Health Implications
17Psychological Health & QoL
18PMOS in Adolescents
19PMOS & Pregnancy / Fertility Management
20Lifestyle Management — first-line treatment
21Pharmacological Management — OCP, metformin, anti-androgens, letrozole
22Hyperandrogenism / Dermatological Management
23Screening & Monitoring Protocol
24Imaging — Bilateral Ovarian Assessment (ultrasound image)
25PMOS vs PCOS Framework — comparison table
26PMOS in Special Populations
27Global Implementation Strategy — 2026–2028 roadmap
28Patient Perspective — patient quotes, BMJ 2026
29Key References — Lancet, Harrison's, Berek & Novak's, Cecil, Tietz, etc.
30Summary — 7 Key Messages

Sources used: Teede HJ et al. Lancet 2026 (PMID 42119588) · Wu P et al. BMJ 2026 · Harrison's Principles of Internal Medicine 22e · Berek & Novak's Gynecology · Goldman-Cecil Medicine · Creasy & Resnik's Maternal-Fetal Medicine · Tietz Textbook of Laboratory Medicine 7e · Guyton & Hall Medical Physiology · Fitzpatrick's Dermatology · 2023 International PCOS Guidelines

Make a ppt of 25 slides of detailed review of the latest lancet article on new name change of pcod into pmos

Reading Article

PMID: 42119588

Reading Article

PMID: 42140655

Searching the Web

Lancet 2026 PMOS polyendocrine metabolic ovarian syndrome Teede methodology consensus process findings

Searching the Web

PMOS Lancet 2026 "Delphi" "nominal group" "14360" survey methodology name change implementation

Reading Web Page

https://www.springermedicine.com/polyendocrine-metabolic-ova…

Reading Web Page

https://en.cefthailand.com/insights/pcos-is-now-pmos

Searching Images

PCOS PMOS renaming polycystic ovary polyendocrine metabolic ovarian syndrome hormonal

Writing File

~/pmos-pptx/build_lancet_review.js

const pptxgen = require("pptxgenjs");
const { execSync } = require("child_process");

// ─── Palette — deep teal/emerald/gold academic theme ──────────────────────────
const C = {
  ink:        "0D1B2A",   // near-black navy
  navy:       "1A3A5C",   // deep navy
  teal:       "0B6E6E",   // teal
  emerald:    "1B7A4A",   // emerald
  gold:       "D4A017",   // academic gold
  amber:      "F5A623",   // warm amber
  steel:      "3B7EA1",   // steel blue
  white:      "FFFFFF",
  cream:      "FDF8EE",
  paleGold:   "FFF3C4",
  paleTeal:   "DFF5F5",
  paleBlue:   "E8F4FD",
  textDark:   "0D1B2A",
  textMid:    "2C4A6E",
  textLight:  "6B8CAE",
  accent:     "E84393",   // lancet pink/red
  lancetRed:  "CC0033",   // official lancet red
};

// ─── Image fetch ──────────────────────────────────────────────────────────────
const imageUrls = [
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_cd4334324a4d9cb7b9f90c7babc0bc7f66e48010572632ad4ea7fb62864fe14f.jpg",
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_b33b2ccdd016f69a30904eb1fc1d8cef71a69bedf5da5db120e1fc850b09471c.jpg",
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_a75b5b12edebbd1e06550f96988c2495f2372b45a878f08b6bbc82720335e735.jpg",
];
let images = [];
try {
  const r = execSync(
    `node /home/daytona/skills/shared/scripts/fetch_images.js ${imageUrls.map(u => `"${u}"`).join(" ")}`,
    { timeout: 30000 }
  ).toString();
  images = JSON.parse(r);
} catch (e) {
  images = imageUrls.map(() => ({ base64: null, error: "fetch failed" }));
}

// ─── Presentation ─────────────────────────────────────────────────────────────
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.author = "Lancet 2026 Article Review";
pres.title = "PMOS — Lancet 2026 Detailed Review";

// ─── Helpers ──────────────────────────────────────────────────────────────────
const W = 10, H = 5.625;

function darkBG(s) {
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:H, fill:{color:C.ink}, line:{color:C.ink} });
}
function lightBG(s) {
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:H, fill:{color:C.cream}, line:{color:C.cream} });
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:0.06, fill:{color:C.lancetRed}, line:{color:C.lancetRed} });
}
function titleBG(s) {
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:H, fill:{type:"gradient",stops:[{color:C.ink,pos:0},{color:C.navy,pos:60},{color:C.teal,pos:100}],angle:135}, line:{color:C.ink} });
}
function sectionBG(s) {
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:H, fill:{type:"gradient",stops:[{color:C.navy,pos:0},{color:C.teal,pos:100}],angle:145}, line:{color:C.navy} });
}
function header(s, title, dark) {
  const c = dark ? C.lancetRed : C.lancetRed;
  const tc = dark ? C.white : C.white;
  s.addShape(pres.ShapeType.rect, { x:0,y:0,w:W,h:0.88, fill:{color:dark?C.navy:C.navy}, line:{color:dark?C.navy:C.navy} });
  s.addShape(pres.ShapeType.rect, { x:0,y:0.82,w:W,h:0.065, fill:{color:c}, line:{color:c} });
  s.addText(title, { x:0.35,y:0.07,w:9.3,h:0.75, fontSize:21,bold:true,color:tc,fontFace:"Calibri",valign:"middle",margin:0 });
}
function footer(s, txt) {
  s.addShape(pres.ShapeType.rect, { x:0,y:H-0.3,w:W,h:0.3, fill:{color:C.navy}, line:{color:C.navy} });
  s.addText(txt, { x:0.2,y:H-0.28,w:9.6,h:0.26, fontSize:7.5,color:C.paleGold,italic:true,fontFace:"Calibri",valign:"middle",margin:0 });
}
function lancetTag(s, x, y) {
  s.addShape(pres.ShapeType.roundRect, { x,y,w:1.9,h:0.32, fill:{color:C.lancetRed}, line:{color:C.lancetRed}, rectRadius:0.04 });
  s.addText("THE LANCET  |  2026", { x,y,w:1.9,h:0.32, fontSize:8.5,bold:true,color:C.white,align:"center",fontFace:"Calibri",valign:"middle" });
}
function statBox(s, x, y, val, label, color) {
  s.addShape(pres.ShapeType.roundRect, { x,y,w:2.85,h:1.6, fill:{color}, line:{color:C.gold,pt:1.8}, rectRadius:0.1 });
  s.addText(val,   { x:x+0.1,y:y+0.22,w:2.65,h:0.72, fontSize:28,bold:true,color:C.gold,align:"center",fontFace:"Calibri" });
  s.addText(label, { x:x+0.1,y:y+0.98,w:2.65,h:0.5,  fontSize:11,color:C.white,align:"center",fontFace:"Calibri",wrap:true });
}
function bullet(t, sub) {
  return { text: t, options:{ bullet:{code:sub?"2013":"25B8",color:sub?C.steel:C.lancetRed}, breakLine:true, fontSize:sub?12:13.5, color:sub?C.textMid:C.textDark, bold:!sub, indent:sub?18:0 } };
}
function sub(t) { return bullet(t, true); }

// ── Colour bar accent ──────────────────────────────────────────────────────────
function barAccent(s, x, y, w, color) {
  s.addShape(pres.ShapeType.rect, { x,y,w,h:0.055, fill:{color}, line:{color} });
}

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 1 — Title / Cover
// ─────────────────────────────────────────────────────────────────────────────
let s = pres.addSlide();
titleBG(s);
// Lancet red strip left
s.addShape(pres.ShapeType.rect, { x:0,y:0,w:0.18,h:H, fill:{color:C.lancetRed}, line:{color:C.lancetRed} });
// Decorative circles
s.addShape(pres.ShapeType.ellipse, { x:7.5,y:-0.8,w:4.5,h:4.5, fill:{color:C.teal,alpha:15}, line:{color:C.teal,alpha:0} });
s.addShape(pres.ShapeType.ellipse, { x:-1.5,y:2.8,w:3.5,h:3.5, fill:{color:C.lancetRed,alpha:12}, line:{color:C.lancetRed,alpha:0} });

s.addText("DETAILED ARTICLE REVIEW", { x:0.4,y:0.45,w:9.2,h:0.42, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri",charSpacing:4,align:"center" });
s.addShape(pres.ShapeType.rect, { x:1.5,y:0.9,w:7,h:0.04, fill:{color:C.lancetRed}, line:{color:C.lancetRed} });

s.addText("Polyendocrine Metabolic\nOvarian Syndrome (PMOS)", { x:0.4,y:1.0,w:9.2,h:1.8, fontSize:36,bold:true,color:C.white,align:"center",fontFace:"Calibri" });
s.addText("The New Name for Polycystic Ovary Syndrome", { x:0.4,y:2.75,w:9.2,h:0.5, fontSize:18,color:C.paleTeal,align:"center",fontFace:"Calibri" });

s.addShape(pres.ShapeType.rect, { x:1.5,y:3.35,w:7,h:0.04, fill:{color:C.gold}, line:{color:C.gold} });

s.addText("Teede HJ, Khomami MB, Morman R, Laven JSE, Joham AE, Costello MF, et al.", { x:0.4,y:3.45,w:9.2,h:0.38, fontSize:12.5,color:C.paleTeal,align:"center",fontFace:"Calibri",italic:true });
s.addText("The Lancet  •  Published Online May 12, 2026  •  DOI: 10.1016/S0140-6736(26)00717-8", { x:0.4,y:3.85,w:9.2,h:0.35, fontSize:12,color:C.gold,align:"center",fontFace:"Calibri",bold:true });
s.addText("Presented at European Congress of Endocrinology, Prague, May 2026", { x:0.4,y:4.28,w:9.2,h:0.3, fontSize:11,color:C.textLight,align:"center",fontFace:"Calibri",italic:true });
s.addText("PMID: 42119588", { x:0.4,y:4.62,w:9.2,h:0.28, fontSize:10.5,color:C.amber,align:"center",fontFace:"Calibri" });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 2 — Article at a Glance
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Article at a Glance", false);
footer(s, "Teede HJ et al. Lancet 2026; DOI: 10.1016/S0140-6736(26)00717-8  |  PMID: 42119588");

const meta = [
  ["Journal", "The Lancet (London, England)"],
  ["Publication Type", "Health Policy / Systematic Consensus Review"],
  ["Published", "Online May 12, 2026 (ahead of print)"],
  ["DOI", "10.1016/S0140-6736(26)00717-8"],
  ["PMID", "42119588"],
  ["Lead Author", "Helena J Teede, Monash University, Melbourne, Australia"],
  ["Co-leads", "Terhi Piltonen (Finland) | Anuja Dokras (USA) | Rachel Morman (Verity/PCOS UK)"],
  ["Consortium", "56 leading academic, clinical & patient organisations — all world regions"],
  ["Presented", "28th European Congress of Endocrinology, Prague, 12 May 2026"],
  ["Companion Papers", "Suite of papers on adolescents, maternal health, clinical practice, policy & research (same issue)"],
];

meta.forEach(([k,v], i) => {
  const y = 0.98 + i*0.44;
  s.addShape(pres.ShapeType.rect, { x:0.3,y,w:2.4,h:0.38, fill:{color:i%2===0?C.navy:C.teal}, line:{color:i%2===0?C.navy:C.teal} });
  s.addText(k, { x:0.35,y:y+0.04,w:2.3,h:0.3, fontSize:11,bold:true,color:C.gold,fontFace:"Calibri" });
  s.addText(v, { x:2.82,y:y+0.04,w:6.95,h:0.35, fontSize:12,color:C.textDark,fontFace:"Calibri" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 3 — Background: Why the Name Had to Change
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Background — Why PCOS Needed a New Name", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Tietz Lab Medicine 7e  |  WHO PCOS fact sheet");

// Pull quote
s.addShape(pres.ShapeType.roundRect, { x:0.3,y:0.95,w:9.4,h:0.9, fill:{color:C.lancetRed,alpha:85}, line:{color:C.lancetRed,pt:0}, rectRadius:0.1 });
s.addText([
  { text: '"', options:{fontSize:28,color:C.white,bold:true} },
  { text: "The term PCOS is inaccurate, implying pathological ovarian cysts, obscuring diverse endocrine and metabolic features, and contributing to delayed diagnosis, fragmented care, and stigma, while curtailing research and policy framing.", options:{fontSize:12.5,color:C.white,italic:true} },
  { text: '"', options:{fontSize:28,color:C.white,bold:true} },
], { x:0.45,y:0.97,w:9.1,h:0.85, fontFace:"Calibri",wrap:true,valign:"middle" });
s.addText("— Teede HJ et al., The Lancet 2026", { x:0.45,y:1.87,w:9.1,h:0.25, fontSize:10,color:C.paleGold,italic:true,fontFace:"Calibri" });

s.addText([
  bullet("The word 'polycystic' was coined by Stein & Leventhal in 1935 to describe ovarian histology — not a clinical entity"),
  bullet("Pathological ovarian cysts are NOT increased in PCOS/PMOS — the name has always been a misnomer"),
  bullet("Up to 70% of affected women worldwide remain undiagnosed (WHO) — the misleading name contributes directly"),
  bullet("Missed metabolic & cardiovascular risks: IR (50–80%), T2DM, dyslipidaemia, CVD, MASLD"),
  bullet("Fertility-focused framing → delayed referral → missed metabolic comorbidities in 30–40% of patients"),
  bullet("Research underfunding: condition framed as 'reproductive/gynaecological' → insufficient endocrine/metabolic research"),
  bullet("Patient surveys: 'cyst' terminology caused anxiety, shame, and confusion about actual disease mechanisms"),
], { x:0.35,y:2.18,w:9.3,h:3.1, fontFace:"Calibri",color:C.white });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 4 — 14-Year Journey to Renaming
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "The 14-Year Journey to Renaming", false);
footer(s, "Teede HJ et al. Lancet 2026  |  Springer Medicine / medwireNews 2026");

const timeline = [
  { yr:"2012", ev:"NIH Workshop", d:"US NIH Expert Panel first formally raises need to rename PCOS; agrees it is a misnomer" },
  { yr:"2017", ev:"Survey Round 1", d:"First global surveys (7,708 responses) document patient & clinician dissatisfaction with name" },
  { yr:"2018", ev:"International Guidelines", d:"PCOS International Evidence-Based Guidelines published — name change identified as priority" },
  { yr:"2023", ev:"Survey Round 2", d:"Second large survey round; principles for naming finalised (accuracy, stigma, culture, feasibility)" },
  { yr:"Apr 2025", ev:"Survey A", d:"10,411 patients + 3,949 health professionals surveyed on principles & preferred terminology" },
  { yr:"Nov 2025", ev:"Workshop A", d:"Nominal group technique workshops — test accuracy, acceptability & cultural fit of candidate names" },
  { yr:"Dec 2025", ev:"Shortlisting", d:"Candidate names formally assessed; 'polyendocrine', 'metabolic', 'ovarian' emerge as consensus terms" },
  { yr:"Jan 2026", ev:"Survey B", d:"Final survey — PMOS emerges as leading name; 82% of respondents favour accurate feature-based naming" },
  { yr:"Feb 2026", ev:"Workshop B + Final Agreement", d:"PMOS confirmed as consensus name; implementation roadmap co-designed" },
  { yr:"12 May 2026", ev:"Lancet Publication", d:"Published in The Lancet; announced at ECE 2026 Prague; ICD update planned for 2028" },
];

timeline.forEach((t, i) => {
  const col = i < 5 ? 0 : 1;
  const row = i < 5 ? i : i - 5;
  const x = 0.28 + col * 4.9;
  const y = 1.0 + row * 0.88;
  const even = i % 2 === 0;
  s.addShape(pres.ShapeType.roundRect, { x,y,w:4.55,h:0.8, fill:{color:even?C.navy:C.teal}, line:{color:C.gold,pt:0.5}, rectRadius:0.07 });
  s.addText(t.yr, { x:x+0.08,y:y+0.05,w:1.0,h:0.7, fontSize:11.5,bold:true,color:C.gold,fontFace:"Calibri",valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:x+1.12,y:y+0.1,w:0.04,h:0.6, fill:{color:C.lancetRed}, line:{color:C.lancetRed} });
  s.addText(t.ev, { x:x+1.22,y:y+0.04,w:3.22,h:0.3, fontSize:12,bold:true,color:C.white,fontFace:"Calibri" });
  s.addText(t.d, { x:x+1.22,y:y+0.35,w:3.25,h:0.4, fontSize:10,color:C.paleTeal,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 5 — Governance & Organisational Framework
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Governance & Organisational Framework", true);
footer(s, "Teede HJ et al. Lancet 2026  |  EurekAlert Press Release, Monash University 2026");

s.addText("56 Leading Organisations — International Governance Consortium", {
  x:0.3,y:0.95,w:9.4,h:0.42, fontSize:15,bold:true,color:C.gold,fontFace:"Calibri",align:"center"
});

const orgs = [
  { type:"Lead Institution", orgs:"Monash Centre for Health Research & Implementation, Monash University, Melbourne, Australia", color:C.lancetRed },
  { type:"International Co-lead", orgs:"Oulu University & Oulu University Hospital, Finland (Prof. Terhi Piltonen, AE-PCOS Society President)", color:C.teal },
  { type:"US Representation", orgs:"AE-PCOS Society Executive Director — Prof. Anuja Dokras, USA", color:C.steel },
  { type:"Patient Voice", orgs:"Rachel Morman, Chair of Verity (PCOS UK) — lived-experience expert and named co-author", color:C.emerald },
  { type:"Professional Bodies", orgs:"Endocrine Society, ESHRE, AE-PCOS Society, ASRM, ACOG, Menopause Society + 50 further bodies", color:C.navy },
  { type:"Patient Organisations", orgs:"PCOS Australia, Verity (UK), PCOS Challenge (USA), PCOS Society (India) + international advocacy groups", color:C.teal },
  { type:"Governance Structure", orgs:"Independent funding & governance; transparent COI management; iterative multi-round design with formal consensus thresholds", color:C.lancetRed },
];

orgs.forEach((o, i) => {
  const y = 1.47 + i * 0.58;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.52, fill:{color:o.color,alpha:80}, line:{color:o.color,pt:1.2}, rectRadius:0.06 });
  s.addText(o.type, { x:0.42,y:y+0.05,w:2.1,h:0.42, fontSize:11,bold:true,color:C.gold,fontFace:"Calibri",valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:2.6,y:y+0.1,w:0.04,h:0.32, fill:{color:C.amber}, line:{color:C.amber} });
  s.addText(o.orgs, { x:2.72,y:y+0.05,w:6.88,h:0.42, fontSize:11.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 6 — Study Methods Overview
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Study Methods — Rigorous Multistep Design", false);
footer(s, "Teede HJ et al. Lancet 2026  |  Springer Medicine medwireNews 2026");

const methods = [
  { icon:"📊", m:"Phase 1: Literature & Background Review", d:"Collated 7,708 responses from prior surveys (2017 + 2023 rounds). Systematic review of naming impact evidence. Documented harms of current name." },
  { icon:"🌐", m:"Phase 2: Survey A — Principles (April 2025)", d:"10,411 patients + 3,949 HCPs across all world regions. Assessed priorities: scientific accuracy vs. keeping PCOS acronym vs. generic name. 82% supported accurate feature-based naming." },
  { icon:"🔬", m:"Phase 3: Modified Delphi — Iterative Expert Consensus", d:"Structured consensus methodology across multiple expert rounds. Pre-specified consensus thresholds. Covered endocrine, metabolic & reproductive terminology options." },
  { icon:"🧠", m:"Phase 4: Nominal Group Technique Workshops (Nov 2025 & Feb 2026)", d:"Serial in-person/virtual workshops. Tested accuracy, acceptability, cultural appropriateness of candidate terms. Shortlisted: polyendocrine, metabolic, ovarian, reproductive, neuroendocrine." },
  { icon:"📈", m:"Phase 5: Marketing & Implementation Analysis", d:"Expert analysis of brand/communication feasibility. Tested across healthcare systems & languages. 'Evolution not transformation' principle adopted." },
  { icon:"✅", m:"Phase 6: Survey B + Final Agreement (Jan–Feb 2026)", d:"PMOS tested as leading combination. Final workshop confirmed polyendocrine metabolic ovarian syndrome. Implementation roadmap co-designed by all 56 organisations." },
];

methods.forEach((m, i) => {
  const col = i < 3 ? 0 : 1;
  const row = i < 3 ? i : i - 3;
  const x = 0.28 + col * 5.0;
  const y = 0.97 + row * 1.52;
  s.addShape(pres.ShapeType.roundRect, { x,y,w:4.7,h:1.44, fill:{color:C.navy}, line:{color:C.lancetRed,pt:1.5}, rectRadius:0.09 });
  s.addText(m.icon + " " + m.m, { x:x+0.12,y:y+0.08,w:4.46,h:0.42, fontSize:12.5,bold:true,color:C.gold,fontFace:"Calibri",wrap:true });
  s.addText(m.d, { x:x+0.12,y:y+0.55,w:4.46,h:0.82, fontSize:11,color:C.paleTeal,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 7 — Survey Scale & Participation Data
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Survey Scale — Unprecedented Patient & Clinician Participation", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Springer Medicine 2026  |  Lam Clinic 2026");

const stats = [
  { v:"22,068+", l:"Total survey responses\n(all rounds combined)" },
  { v:"14,360", l:"New responses\n(2025–2026 surveys)" },
  { v:"10,411", l:"Patients with PCOS/PMOS\n(new surveys)" },
  { v:"3,949", l:"Multidisciplinary\nhealthcare professionals" },
];

stats.forEach((st, i) => {
  statBox(s, 0.28 + i*2.38, 1.05, st.v, st.l, i%2===0?C.navy:C.teal);
});

s.addText("All world regions represented — global breadth ensured cultural and linguistic appropriateness", {
  x:0.3,y:2.78,w:9.4,h:0.38, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri",align:"center"
});

const breakdown = [
  "Survey A (April 2025): Assessed core principles — scientific accuracy, stigma avoidance, cultural fit, implementation feasibility",
  "Survey B (January 2026): Tested final candidate name combinations — PMOS emerged as the top choice",
  "Historical data: Prior rounds (2017 + 2023) contributed 7,708 responses used for background & framing",
  "Patient voice: 86% of people with PCOS specifically supported an accurate feature-based name over retaining 'PCOS' acronym",
  "HCP data: 70% of health professionals supported accurate new name (vs. 86% patients — still majority both groups)",
];

breakdown.forEach((b, i) => {
  s.addText("▸  " + b, { x:0.35,y:3.24+i*0.45,w:9.3,h:0.42, fontSize:11.5,color:C.paleTeal,fontFace:"Calibri" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 8 — The 5 Guiding Principles
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "The 5 Guiding Principles for the New Name", false);
footer(s, "Teede HJ et al. Lancet 2026  |  ESSI / internationalendo.com 2026");

const principles = [
  { n:"1", title:"Scientific Accuracy", icon:"🔬",
    detail:"The new name must accurately reflect the multisystem biology of the condition — endocrine, metabolic, and ovarian dysfunction — without implying pathology that does not exist (no increase in pathological ovarian cysts).",
    color:C.lancetRed },
  { n:"2", title:"Clarity & Communicability", icon:"💬",
    detail:"The name must be understandable to patients, clinicians, researchers, policy-makers, and media. Simple enough to communicate, yet medically descriptive. 'Evolution not transformation' — familiar structure retained.",
    color:C.teal },
  { n:"3", title:"Stigma Avoidance", icon:"🛡️",
    detail:"Terms evoking shame around fertility, weight, or reproductive failure were excluded. 'Reproductive' was considered but excluded due to stigma concerns — 'ovarian' was preferred as less stigmatising.",
    color:C.navy },
  { n:"4", title:"Cultural Appropriateness", icon:"🌍",
    detail:"Tested across all world regions for cultural and linguistic fit. Workshops in Nov 2025 and Feb 2026 explicitly assessed cross-cultural acceptability of each candidate term in the final name.",
    color:C.emerald },
  { n:"5", title:"Implementation Feasibility", icon:"⚙️",
    detail:"The name must work in electronic health records, ICD coding, insurance systems, clinical guidelines, medical education, and patient communication globally. Marketing analysis confirmed PMOS viability.",
    color:C.steel },
];

principles.forEach((p, i) => {
  const y = 0.96 + i * 0.9;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.82, fill:{color:C.navy}, line:{color:p.color,pt:2}, rectRadius:0.08 });
  s.addShape(pres.ShapeType.ellipse, { x:0.38,y:y+0.18,w:0.46,h:0.46, fill:{color:p.color}, line:{color:p.color} });
  s.addText(p.n, { x:0.38,y:y+0.18,w:0.46,h:0.46, fontSize:14,bold:true,color:C.white,align:"center",valign:"middle",fontFace:"Calibri" });
  s.addText(p.icon + "  " + p.title, { x:0.94,y:y+0.06,w:3.0,h:0.36, fontSize:14,bold:true,color:C.gold,fontFace:"Calibri" });
  s.addText(p.detail, { x:0.94,y:y+0.42,w:8.6,h:0.38, fontSize:11,color:C.paleTeal,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 9 — Term Selection Process: How PMOS Was Chosen
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Term Selection — How 'PMOS' Was Chosen", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Lam Clinic analysis 2026  |  ESSI commentary 2026");

s.addText("The naming decision involved three distinct debates:", { x:0.3,y:0.92,w:9.4,h:0.38, fontSize:14,bold:true,color:C.amber,fontFace:"Calibri" });

const decisions = [
  {
    q:"Decision 1: Keep 'PCOS' acronym, or use an accurate new name?",
    ans:"82% of total respondents → Accurate new name. 86% of patients with PCOS and 70% of HCPs. Retaining the acronym was rejected as it would perpetuate the 'cyst' misconception.",
    col:C.lancetRed
  },
  {
    q:"Decision 2: Which core terms best represent the condition?",
    ans:"'Polyendocrine' → captures hyperandrogenism, GnRH dysregulation, LH excess, adrenal contribution, insulin-mediated androgen excess — all endocrine axes involved.\n'Metabolic' → insulin resistance, T2DM risk, dyslipidaemia, cardiovascular risk — central to the condition's morbidity.\n'Ovarian' → preferred over 'reproductive' (less stigmatising); captures follicular, endocrine, and ovulatory ovarian dysfunction without over-emphasising fertility.",
    col:C.teal
  },
  {
    q:"Decision 3: 'Syndrome' vs. other descriptors?",
    ans:"'Syndrome' retained — accurately conveys a heterogeneous cluster of features that vary by individual phenotype. Allows for the spectrum of clinical presentations without requiring all features simultaneously.",
    col:C.steel
  },
];

decisions.forEach((d, i) => {
  const y = 1.38 + i * 1.36;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:1.28, fill:{color:d.col,alpha:75}, line:{color:d.col,pt:1.5}, rectRadius:0.09 });
  s.addText("Q:  " + d.q, { x:0.45,y:y+0.06,w:9.1,h:0.35, fontSize:12.5,bold:true,color:C.white,fontFace:"Calibri",wrap:true });
  barAccent(s, 0.45, y+0.42, 0.06, C.gold);
  s.addText("A:  " + d.ans, { x:0.6,y:y+0.47,w:8.95,h:0.72, fontSize:11.5,color:C.paleGold,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 10 — Anatomy of the Name: P.M.O.S.
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Anatomy of the New Name — P · M · O · S", false);
footer(s, "Teede HJ et al. Lancet 2026  |  ESSI commentary  |  Lam Clinic analysis 2026");

const letters = [
  {
    letter:"P", word:"Poly-\nendocrine", color:C.lancetRed,
    meaning:"Multiple endocrine axes involved:",
    points:["Hypothalamo-pituitary-ovarian axis: ↑ LH pulsatility, LH:FSH imbalance","Androgen excess: testosterone, DHEAS, androstenedione, 11-oxygenated androgens","Adrenal axis: elevated DHEAS in 25–35%","Insulin axis: hyperinsulinaemia → ovarian androgen stimulation","NOT limited to ovarian pathology"]
  },
  {
    letter:"M", word:"Metabolic", color:C.teal,
    meaning:"Central metabolic disturbance:",
    points:["Insulin resistance: 50–80% (independent of obesity)","Metabolic syndrome: 12–60% depending on phenotype","Type 2 diabetes risk: 3.5×","Dyslipidaemia, MASLD, cardiovascular risk","Adipokine dysregulation; visceral adiposity"]
  },
  {
    letter:"O", word:"Ovarian", color:C.emerald,
    meaning:"Ovarian dysfunction remains central:",
    points:["Follicular arrest → anovulation","PCOM: ≥20 antral follicles or volume ≥10 cm³","Elevated AMH — marker of follicular excess","Chosen over 'reproductive' (less stigmatising)","Captures endocrine, follicular, ovulatory dysfunction"]
  },
  {
    letter:"S", word:"Syndrome", color:C.steel,
    meaning:"Heterogeneous phenotypic spectrum:",
    points:["4 phenotypes (A–D) by Rotterdam criteria","Features vary by individual, age, weight","Not all features present simultaneously","Allows for clinical variability","Consistent with existing naming convention (metabolic syndrome, etc.)"]
  },
];

letters.forEach((L, i) => {
  const x = 0.22 + i*2.42;
  s.addShape(pres.ShapeType.roundRect, { x,y:0.95,w:2.3,h:4.4, fill:{color:C.navy}, line:{color:L.color,pt:2.5}, rectRadius:0.1 });
  s.addShape(pres.ShapeType.ellipse, { x:x+0.77,y:0.98,w:0.78,h:0.78, fill:{color:L.color}, line:{color:L.color} });
  s.addText(L.letter, { x:x+0.77,y:0.98,w:0.78,h:0.78, fontSize:26,bold:true,color:C.white,align:"center",valign:"middle",fontFace:"Calibri" });
  s.addText(L.word, { x:x+0.1,y:1.82,w:2.1,h:0.5, fontSize:13,bold:true,color:C.gold,align:"center",fontFace:"Calibri" });
  barAccent(s, x+0.1, 2.35, 2.1, L.color);
  s.addText(L.meaning, { x:x+0.1,y:2.42,w:2.1,h:0.35, fontSize:10.5,bold:true,color:C.amber,fontFace:"Calibri",wrap:true });
  L.points.forEach((pt, j) => {
    s.addText("• "+pt, { x:x+0.1,y:2.82+j*0.43,w:2.1,h:0.42, fontSize:9.5,color:C.paleTeal,fontFace:"Calibri",wrap:true });
  });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 11 — Survey A Key Findings
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Survey A (April 2025) — Key Findings on Naming Principles", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Lam Clinic synthesis 2026");

s.addText("N = 10,411 patients + 3,949 HCPs  |  All world regions  |  April 2025", {
  x:0.3,y:0.92,w:9.4,h:0.38, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri",align:"center"
});

const findingsA = [
  { pct:"82%", label:"Overall", detail:"of all respondents supported an accurate, feature-based new name over retaining 'PCOS' acronym or a generic name" },
  { pct:"86%", label:"Patients", detail:"of people with PCOS specifically supported an accurate new name — stronger preference than HCPs" },
  { pct:"70%", label:"HCPs", detail:"of multidisciplinary health professionals supported the accurate new name — majority across all specialties" },
];

findingsA.forEach((f, i) => {
  const x = 0.28 + i*3.2;
  s.addShape(pres.ShapeType.roundRect, { x,y:1.38,w:3.0,h:1.5, fill:{color:C.teal}, line:{color:C.gold,pt:2}, rectRadius:0.12 });
  s.addText(f.pct, { x:x+0.1,y:1.42,w:2.8,h:0.72, fontSize:34,bold:true,color:C.gold,align:"center",fontFace:"Calibri" });
  s.addText(f.label, { x:x+0.1,y:2.14,w:2.8,h:0.3, fontSize:13,bold:true,color:C.white,align:"center",fontFace:"Calibri" });
  s.addText(f.detail, { x:x+0.1,y:2.46,w:2.8,h:0.35, fontSize:10.5,color:C.paleTeal,fontFace:"Calibri",wrap:true,align:"center" });
});

const principlesRanked = [
  ["#1 Priority", "Scientific accuracy — the name must correctly describe the biology"],
  ["#2 Priority", "Clarity — easy to understand by patients, clinicians, media, and policy-makers"],
  ["#3 Priority", "Stigma avoidance — especially around fertility, cysts, and weight"],
  ["#4 Priority", "Cultural & linguistic appropriateness — must work across all regions and languages"],
  ["#5 Priority", "Implementation feasibility — must function in ICD, EHR, guidelines, and insurance systems"],
];
s.addText("Principles ranked by respondent priority:", { x:0.3,y:3.08,w:9.4,h:0.35, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri" });
principlesRanked.forEach(([rank, detail], i) => {
  s.addText(rank + ":  " + detail, { x:0.45,y:3.48+i*0.39,w:9.1,h:0.38, fontSize:11.5,color:i===0?C.gold:C.paleTeal,fontFace:"Calibri" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 12 — Nominal Group Workshops & Delphi Details
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Modified Delphi & Nominal Group Technique Workshops", false);
footer(s, "Teede HJ et al. Lancet 2026  |  Springer Medicine / medwireNews 2026");

s.addText([
  { text:"Modified Delphi Method:  ", options:{bold:true,color:C.lancetRed,fontSize:14} },
  { text:"Structured iterative process with pre-specified consensus thresholds; prevents premature closure; allows refinement of candidate terms across multiple rounds", options:{color:C.textDark,fontSize:13} },
], { x:0.3,y:0.93,w:9.4,h:0.55, fontFace:"Calibri",wrap:true });
barAccent(s, 0.3, 1.52, 9.4, C.lancetRed);

s.addText([
  { text:"Nominal Group Technique (NGT):  ", options:{bold:true,color:C.teal,fontSize:14} },
  { text:"Structured facilitated group process ensuring equal participation; prevents dominant voices from skewing consensus; used in WHO guideline development and NICE methodology", options:{color:C.textDark,fontSize:13} },
], { x:0.3,y:1.58,w:9.4,h:0.55, fontFace:"Calibri",wrap:true });
barAccent(s, 0.3, 2.17, 9.4, C.teal);

const workshops = [
  { wk:"Workshop A", date:"November 2025", focus:"Testing of endocrine, metabolic, and reproductive terms", outcome:"'Polyendocrine', 'metabolic', 'ovarian' identified as preferred building blocks; 'reproductive' excluded (stigma concerns)", color:C.navy },
  { wk:"Workshop B", date:"February 2026", focus:"Final name agreement and implementation planning", outcome:"'Polyendocrine Metabolic Ovarian Syndrome' (PMOS) formally agreed. Implementation roadmap co-designed by all 56 organisations", color:C.teal },
];

workshops.forEach((w, i) => {
  const y = 2.3 + i * 1.5;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:1.38, fill:{color:w.color}, line:{color:C.gold,pt:1.5}, rectRadius:0.09 });
  s.addText(w.wk + "  |  " + w.date, { x:0.45,y:y+0.07,w:9.0,h:0.35, fontSize:14,bold:true,color:C.gold,fontFace:"Calibri" });
  s.addText("Focus: " + w.focus, { x:0.45,y:y+0.45,w:9.0,h:0.32, fontSize:12,color:C.white,fontFace:"Calibri" });
  s.addText("Outcome: " + w.outcome, { x:0.45,y:y+0.78,w:9.0,h:0.5, fontSize:11.5,color:C.paleTeal,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 13 — Survey B & Final Selection
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Survey B (January 2026) — Final Name Selection", true);
footer(s, "Teede HJ et al. Lancet 2026  |  ESSI internationalendo.com 2026");

s.addText("Survey B tested shortlisted name combinations. PMOS emerged as the leading choice.", {
  x:0.3,y:0.93,w:9.4,h:0.4, fontSize:14,bold:true,color:C.amber,fontFace:"Calibri"
});

const candidates = [
  { name:"Polyendocrine Metabolic Ovarian Syndrome (PMOS)", rank:"🥇 WINNER", detail:"Top ranked — accurately captures endocrine complexity, metabolic burden, and ovarian role without fertility stigma", bg:C.lancetRed },
  { name:"Hyperandrogenic Metabolic Ovarian Syndrome", rank:"Considered", detail:"'Hyperandrogenic' too narrow — excludes non-hyperandrogenic phenotypes (Phenotype D); rejected", bg:C.navy },
  { name:"Ovulatory Dysfunction Metabolic Syndrome", rank:"Considered", detail:"'Ovulatory dysfunction' misses hyperandrogenic and non-ovulatory features; 'metabolic syndrome' has different clinical meaning", bg:C.teal },
  { name:"Neuroendocrine Metabolic Ovarian Syndrome", rank:"Considered", detail:"'Neuroendocrine' too specific to GnRH axis; missed adrenal, insulin & metabolic axes; excluded", bg:C.steel },
  { name:"Retaining PCOS acronym with new words", rank:"Rejected", detail:"Strong consensus against — perpetuates 'cyst' and 'polycystic' in public and medical terminology", bg:C.navy },
];

candidates.forEach((c, i) => {
  const y = 1.42 + i * 0.82;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.75, fill:{color:c.bg,alpha:i===0?100:70}, line:{color:i===0?C.gold:C.steel,pt:i===0?2:1}, rectRadius:0.07 });
  s.addText(c.rank, { x:0.42,y:y+0.08,w:1.0,h:0.55, fontSize:i===0?16:11,bold:true,color:C.gold,fontFace:"Calibri",valign:"middle",align:"center" });
  s.addText(c.name, { x:1.55,y:y+0.04,w:8.1,h:0.3, fontSize:i===0?13.5:12,bold:i===0,color:C.white,fontFace:"Calibri" });
  s.addText(c.detail, { x:1.55,y:y+0.36,w:8.1,h:0.35, fontSize:10.5,color:C.paleTeal,fontFace:"Calibri" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 14 — What PMOS Actually Is: Clinical Definition
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "What PMOS Is — Clinical Definition & Scope", false);
footer(s, "Teede HJ et al. Lancet 2026  |  Harrison's Principles of Internal Medicine 22e, 2025");

s.addShape(pres.ShapeType.roundRect, { x:0.3,y:0.93,w:9.4,h:0.95, fill:{color:C.navy}, line:{color:C.lancetRed,pt:2}, rectRadius:0.1 });
s.addText("PMOS is a complex, chronic, multisystem endocrine and metabolic disorder characterised by hormonal dysregulation with impacts across the endocrine, metabolic, reproductive, dermatological, and psychological systems — affecting 1 in 8 women of reproductive age (>170 million worldwide).", {
  x:0.45,y:0.96,w:9.1,h:0.9, fontSize:13.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle",align:"center"
});

s.addText([
  bullet("Prevalence: 6–15% of reproductive-age women; up to 21% in some populations"),
  bullet("Most common endocrine disorder in women globally"),
  bullet("Onset typically in adolescence; symptoms modified by BMI and age"),
  bullet("By the 4th decade: many women normalise menses and androgens (but metabolic risk persists)"),
  bullet("Symptoms begin at puberty — but average diagnostic delay is 2 years from first symptom"),
  bullet("PMOS is NOT a new condition — only the name and framing have changed"),
  bullet("The underlying diagnostic criteria (Rotterdam 2023) remain unchanged by the renaming"),
  bullet("'Evolution, not transformation' — core clinical knowledge transfers directly"),
], { x:0.35,y:1.98,w:9.3,h:3.35, fontFace:"Calibri",color:C.textDark });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 15 — The Multisystem Pathophysiology Framing
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "PMOS Pathophysiology — The Multisystem Framework", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Harrison's 22e  |  Guyton & Hall Medical Physiology 14e");

s.addText("The Lancet paper frames PMOS pathophysiology across 5 interconnected systems — each reflected in the new name:", {
  x:0.3,y:0.91,w:9.4,h:0.45, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri"
});

const pathSystems = [
  { sys:"① Neuroendocrine", key:"↑ GnRH pulsatility → ↑ LH → ↑ ovarian androgen production (theca cells). Lean women: LH:FSH often >2:1. Impaired negative feedback from androgens on hypothalamus.", col:C.lancetRed },
  { sys:"② Androgen Excess", key:"Elevated testosterone (total + free), DHEAS (adrenal), androstenedione. Increasingly: 11-oxygenated androgens also elevated. Clinical: hirsutism, acne, androgenic alopecia, seborrhoea.", col:C.teal },
  { sys:"③ Insulin Resistance", key:"50–80% prevalence; independent of BMI. Skeletal muscle + adipose IR → compensatory hyperinsulinaemia → insulin synergises with LH to stimulate ovarian androgen production. Also: ↑ free IGF-1.", col:C.steel },
  { sys:"④ Ovarian Dysfunction", key:"Follicular arrest at 2–9 mm diameter (↑ AMH, ↑ intraovarian androgens). Anovulation → oligomenorrhoea/amenorrhoea. Elevated AMH increasingly used as biomarker. PCOM on ultrasound: ≥20 antral follicles.", col:C.emerald },
  { sys:"⑤ Metabolic Disturbance", key:"Dyslipidaemia (↑ LDL, ↑ TG, ↓ HDL). Visceral adiposity. Low-grade inflammation (↑ CRP). Prothrombotic state. MASLD (independent of BMI). Gut microbiome dysbiosis (emerging evidence).", col:C.gold },
];

pathSystems.forEach((p, i) => {
  const y = 1.44 + i * 0.79;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.72, fill:{color:p.col,alpha:65}, line:{color:p.col,pt:1}, rectRadius:0.07 });
  s.addText(p.sys, { x:0.42,y:y+0.06,w:2.1,h:0.58, fontSize:12.5,bold:true,color:C.white,fontFace:"Calibri",valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:2.62,y:y+0.1,w:0.04,h:0.5, fill:{color:C.amber}, line:{color:C.amber} });
  s.addText(p.key, { x:2.74,y:y+0.06,w:6.9,h:0.6, fontSize:11.5,color:C.white,fontFace:"Calibri",wrap:true });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 16 — Ultrasound Image: PCOM Morphology
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Polycystic Ovarian Morphology (PCOM) — Sonographic Features", false);
footer(s, "Harrison's Principles of Internal Medicine 22e  |  Berek & Novak's Gynecology  |  Image: PMC Clinical VQA");

if (images[0] && !images[0].error) {
  s.addImage({ data:images[0].base64, x:0.3,y:0.95,w:5.3,h:4.35 });
} else {
  s.addShape(pres.ShapeType.rect, { x:0.3,y:0.95,w:5.3,h:4.35, fill:{color:C.paleTeal}, line:{color:C.teal} });
  s.addText("[Transvaginal Ultrasound — 4-panel PCOM morphology]", { x:0.3,y:2.5,w:5.3,h:0.5, fontSize:12,color:C.teal,align:"center" });
}

s.addText("PCOM Diagnostic Criteria (Updated 2023)", { x:5.75,y:0.95,w:4.1,h:0.4, fontSize:13.5,bold:true,color:C.navy,fontFace:"Calibri" });
barAccent(s, 5.75, 1.38, 4.1, C.lancetRed);

const pcomCriteria = [
  ["Follicle count", "≥20 antral follicles (2–9 mm) in at least 1 ovary"],
  ["Volume", "Ovarian volume ≥10 cm³ in at least 1 ovary"],
  ["AMH (preferred)", "Elevated serum AMH — no invasive imaging needed"],
  ["Pattern", "'String of pearls' — peripheral subcapsular distribution"],
  ["Stroma", "Hyperechogenic central stroma; increased stromal vascularity on Doppler"],
  ["Adolescents", "PCOM/AMH criteria NOT validated — do not use in adolescents"],
];
pcomCriteria.forEach(([k,v], i) => {
  const y = 1.48 + i*0.58;
  s.addShape(pres.ShapeType.roundRect, { x:5.75,y,w:4.1,h:0.52, fill:{color:i%2===0?C.navy:C.teal}, line:{color:C.navy,pt:0}, rectRadius:0.06 });
  s.addText(k, { x:5.85,y:y+0.05,w:1.3,h:0.42, fontSize:11,bold:true,color:C.gold,fontFace:"Calibri",valign:"middle" });
  s.addText(v, { x:7.22,y:y+0.05,w:2.55,h:0.42, fontSize:10.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
});
s.addText("Key insight from Lancet paper:\n60% of women don't need ovarian imaging — diagnosis achievable with menses + androgens alone", { x:5.75,y:4.97,w:4.1,h:0.32, fontSize:9.5,color:C.textMid,italic:true,fontFace:"Calibri",wrap:true });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 17 — Diagnostic Criteria Unchanged
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Diagnostic Criteria — Not Changed by the Renaming", true);
footer(s, "Harrison's 22e  |  Berek & Novak's Gynecology  |  2023 International PCOS Guidelines  |  Teede HJ et al. Lancet 2026");

s.addShape(pres.ShapeType.roundRect, { x:0.3,y:0.9,w:9.4,h:0.5, fill:{color:C.lancetRed,alpha:90}, line:{color:C.lancetRed,pt:0}, rectRadius:0.07 });
s.addText("IMPORTANT: The name change does NOT alter diagnostic criteria — Rotterdam 2023 criteria apply under the new name PMOS", {
  x:0.42,y:0.92,w:9.2,h:0.45, fontSize:13,bold:true,color:C.white,fontFace:"Calibri",valign:"middle",align:"center"
});

const diag = [
  { n:"1", title:"Irregular / Absent Menses", detail:"<9 cycles/year (oligomenorrhoea) OR amenorrhoea. Persistent anovulation. Normal for up to 2 yrs post-menarche — caution in adolescents.", col:C.lancetRed },
  { n:"2", title:"Clinical OR Biochemical Hyperandrogenism", detail:"Elevated free or total testosterone (free T = most sensitive). Clinical: modified Ferriman-Gallwey score ≥4–6 (ethnicity-adjusted). Acne, alopecia also count.", col:C.teal },
  { n:"3", title:"PCOM on Ultrasound OR Elevated AMH", detail:"≥20 antral follicles OR ovarian volume ≥10 cm³. AMH increasingly preferred — no internal exam needed. NOT applicable in adolescents.", col:C.steel },
];

diag.forEach((d, i) => {
  const y = 1.5 + i * 1.26;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:1.18, fill:{color:d.col,alpha:70}, line:{color:d.col,pt:1.5}, rectRadius:0.09 });
  s.addShape(pres.ShapeType.ellipse, { x:0.4,y:y+0.35,w:0.5,h:0.5, fill:{color:C.gold}, line:{color:C.gold} });
  s.addText(d.n, { x:0.4,y:y+0.35,w:0.5,h:0.5, fontSize:16,bold:true,color:C.ink,align:"center",valign:"middle",fontFace:"Calibri" });
  s.addText(d.title, { x:1.0,y:y+0.06,w:8.6,h:0.38, fontSize:14,bold:true,color:C.white,fontFace:"Calibri" });
  s.addText(d.detail, { x:1.0,y:y+0.48,w:8.6,h:0.64, fontSize:12,color:C.paleTeal,fontFace:"Calibri",wrap:true });
});
s.addText("Requires ≥ 2 of 3 criteria after exclusion of: hypothyroidism, hyperprolactinaemia, non-classical CAH, androgen-secreting tumours, Cushing syndrome", {
  x:0.3,y:5.3,w:9.4,h:0.24, fontSize:9,color:C.amber,italic:true,fontFace:"Calibri",align:"center"
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 18 — The Burden: Delayed Diagnosis & Fragmented Care
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "The Burden of the Old Name — Evidence of Harm", false);
footer(s, "Teede HJ et al. Lancet 2026  |  WHO PCOS data  |  TheCable 2026  |  Time Magazine 2026");

s.addText("The Lancet paper documents the clinical and social harms caused by the inaccurate name PCOS:", {
  x:0.3,y:0.9,w:9.4,h:0.4, fontSize:13.5,bold:true,color:C.navy,fontFace:"Calibri"
});

const harms = [
  { cat:"Diagnostic Harm", items:[
    "Up to 70% of affected women worldwide remain undiagnosed (WHO)",
    "Average 2-year diagnostic delay from first symptom",
    "JAMA Internal Medicine 2026: patients & clinicians still equate PCOS with 'cysts'",
    "Over-reliance on ovarian ultrasound — many women undergo unnecessary transvaginal US",
  ], col:C.lancetRed },
  { cat:"Clinical Care Harm", items:[
    "Fragmented care — patients bounce between gynaecology, endocrinology & dermatology",
    "Metabolic and cardiovascular risks under-assessed — not seen as 'part of PCOS'",
    "Mental health screening systematically omitted from gynaecology-focused consultations",
    "Insulin resistance not addressed in 60% of cases in primary care settings",
  ], col:C.navy },
  { cat:"Research & Policy Harm", items:[
    "Research funding skewed to fertility/reproductive outcomes — metabolic research underfunded",
    "Not recognised as a metabolic condition in health policy frameworks",
    "ICD coding under gynaecology → insurance gaps for metabolic care",
    "Academic publishing: majority of PCOS trials focus on fertility — minimal on CVD, T2DM prevention",
  ], col:C.teal },
];

harms.forEach((h, i) => {
  const x = 0.28 + i*3.24;
  s.addShape(pres.ShapeType.roundRect, { x,y:1.38,w:3.1,h:0.42, fill:{color:h.col}, line:{color:h.col}, rectRadius:0.06 });
  s.addText(h.cat, { x:x+0.08,y:1.41,w:2.95,h:0.36, fontSize:13,bold:true,color:C.white,align:"center",fontFace:"Calibri" });
  h.items.forEach((item, j) => {
    s.addText("▸ "+item, { x:x+0.1,y:1.88+j*0.88,w:2.95,h:0.82, fontSize:10.5,color:C.textDark,fontFace:"Calibri",wrap:true });
  });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 19 — Implementation Strategy in Detail
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Implementation Strategy — 'Evolution, Not Transformation'", true);
footer(s, "Teede HJ et al. Lancet 2026  |  Society for Endocrinology 2026  |  EurekAlert 2026");

s.addShape(pres.ShapeType.roundRect, { x:0.3,y:0.9,w:9.4,h:0.5, fill:{color:C.teal,alpha:85}, line:{color:C.teal,pt:0}, rectRadius:0.08 });
s.addText("Transition philosophy: PCOS/PMOS used in parallel during transition. 3-year roadmap with global alignment before full ICD switch in 2028.", {
  x:0.42,y:0.92,w:9.1,h:0.45, fontSize:12.5,color:C.white,fontFace:"Calibri",valign:"middle",align:"center"
});

const impl = [
  { phase:"NOW (2026)", steps:["Lancet publication + ECE Prague announcement","'PMOS, formerly known as PCOS' language in clinical use","Patient education campaigns launched by 56 partner organisations","Society websites and patient resources updated"], col:C.lancetRed },
  { phase:"2026–2027", steps:["International clinical guidelines updated to include PMOS terminology","Medical education curricula reviewed in >50 countries","Electronic health record (EHR) fields updated — PCOS/PMOS dual coding","Research granting bodies align funding categories to PMOS framework"], col:C.teal },
  { phase:"2027–2028", steps:["Full transition in scientific publishing — 'PMOS (formerly PCOS)' in abstracts","Suite of companion papers published: adolescents, maternal health, policy, research","Ongoing evaluation of implementation fidelity and patient outcomes"], col:C.steel },
  { phase:"2028 — ICD Update", steps:["PCOS formally replaced by PMOS in International Classification of Diseases (ICD)","Global coding, insurance, and registry alignment","2028 International PCOS/PMOS Guideline Update incorporates new name fully"], col:C.gold },
];

impl.forEach((im, i) => {
  const col = i < 2 ? 0 : 1;
  const row = i < 2 ? i : i - 2;
  const x = 0.28 + col * 4.9;
  const y = 1.5 + row * 2.0;
  s.addShape(pres.ShapeType.roundRect, { x,y,w:4.58,h:1.88, fill:{color:im.col,alpha:i===3?100:75}, line:{color:i===3?C.gold:im.col,pt:i===3?2:1}, rectRadius:0.09 });
  s.addText(im.phase, { x:x+0.1,y:y+0.06,w:4.38,h:0.35, fontSize:14,bold:true,color:C.white,fontFace:"Calibri" });
  barAccent(s, x+0.1, y+0.44, 4.3, C.white);
  im.steps.forEach((st, j) => {
    s.addText("• "+st, { x:x+0.1,y:y+0.52+j*0.33,w:4.38,h:0.32, fontSize:10,color:C.paleTeal,fontFace:"Calibri",wrap:true });
  });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 20 — What Changes & What Does Not
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "What Changes & What Does NOT Change", false);
footer(s, "Teede HJ et al. Lancet 2026  |  ESSI commentary 2026  |  Well Women Clinic 2026");

const changes = [
  { label:"CHANGES", color:C.teal, items:[
    "The name: PCOS → PMOS (Polyendocrine Metabolic Ovarian Syndrome)",
    "ICD coding: updated to PMOS in the International Classification of Diseases (2028)",
    "Clinical framing: from 'ovarian cyst disorder' to 'multisystem endocrine-metabolic condition'",
    "Research priorities: broader scope — metabolic, cardiovascular, neurological outcomes",
    "Patient narrative: from 'cyst problem / fertility problem' to 'hormonal and metabolic health'",
    "Insurance & funding categories: PMOS enables metabolic care reimbursement",
    "Medical education: updated curricula, textbooks, and CME programmes",
    "Dual coding during transition: PCOS/PMOS used in parallel 2026–2028",
  ]},
  { label:"DOES NOT CHANGE", color:C.lancetRed, items:[
    "The underlying condition — same biology, same patients",
    "Diagnostic criteria — Rotterdam 2023 criteria remain fully valid under PMOS",
    "Clinical symptoms — irregular menses, hyperandrogenism, PCOM, IR, metabolic risks",
    "Treatments — OCP, metformin, letrozole, lifestyle, anti-androgens all remain standard",
    "Evidence base — all prior PCOS research remains applicable under PMOS",
    "Who can be diagnosed — same clinical criteria, same patient population",
    "Pregnancy management protocols — same ovulation induction ladder",
    "Existing patient records — PCOS diagnoses remain valid; no re-testing required",
  ]},
];

changes.forEach((ch, i) => {
  const x = 0.28 + i*4.9;
  s.addShape(pres.ShapeType.roundRect, { x,y:0.93,w:4.6,h:0.45, fill:{color:ch.color}, line:{color:ch.color}, rectRadius:0.07 });
  s.addText(ch.label, { x:x+0.1,y:0.96,w:4.4,h:0.38, fontSize:15,bold:true,color:C.white,align:"center",fontFace:"Calibri" });
  ch.items.forEach((item, j) => {
    const bg = j % 2 === 0 ? { color:C.navy } : { color:C.teal };
    s.addShape(pres.ShapeType.rect, { x,y:1.45+j*0.52,w:4.6,h:0.5, fill:bg, line:{color:C.navy,pt:0} });
    s.addText((i===0?"✓  ":"✗  ")+item, { x:x+0.1,y:1.48+j*0.52,w:4.42,h:0.44, fontSize:11,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
  });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 21 — Companion Papers Published Alongside Lancet
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Companion Papers — The Full Publication Suite (2026)", true);
footer(s, "Teede HJ et al. Lancet 2026  |  EurekAlert / Monash University Press Release 2026");

s.addText("A suite of companion papers by the same expert group was published simultaneously — addressing implications across clinical domains:", {
  x:0.3,y:0.9,w:9.4,h:0.45, fontSize:13,bold:true,color:C.amber,fontFace:"Calibri"
});

const companions = [
  { title:"Core Consensus Paper", pub:"The Lancet", topic:"The multistep global consensus process for name change — rationale, methods, and findings", col:C.lancetRed },
  { title:"Improving Awareness & Care in PMOS", pub:"BMJ (Wu P et al., 2026)", topic:"Improving primary care recognition and holistic management under the new name", col:C.teal },
  { title:"Adolescent Health Paper", pub:"Companion suite", topic:"Implications of renaming for adolescent diagnosis — diagnostic caution, delayed confirmation, psychological impact", col:C.steel },
  { title:"Maternal Health Paper", pub:"Companion suite", topic:"PMOS in pregnancy: antenatal risk, gestational diabetes, ovulation induction, ART protocols", col:C.emerald },
  { title:"Clinical Practice Paper", pub:"Companion suite", topic:"Updated clinical practice guidance — investigation, treatment, monitoring under PMOS framework", col:C.gold },
  { title:"Policy Reform Paper", pub:"Companion suite", topic:"Health policy changes: ICD coding, insurance, research funding, disease classification alignment", col:C.navy },
  { title:"Research Priorities Paper", pub:"Companion suite", topic:"Reframing research agenda — metabolic, cardiovascular, psychological outcomes under PMOS", col:C.lancetRed },
];

companions.forEach((c, i) => {
  const y = 1.43 + i * 0.59;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.53, fill:{color:c.col,alpha:70}, line:{color:c.col,pt:1}, rectRadius:0.07 });
  s.addText(c.title, { x:0.42,y:y+0.05,w:3.0,h:0.42, fontSize:12,bold:true,color:C.gold,fontFace:"Calibri",valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:3.52,y:y+0.1,w:0.04,h:0.32, fill:{color:C.amber}, line:{color:C.amber} });
  s.addText("[" + c.pub + "] " + c.topic, { x:3.65,y:y+0.05,w:6.0,h:0.44, fontSize:11.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 22 — Clinical Impact: What Patients Will Notice
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Clinical Impact — What This Means for Patients", false);
footer(s, "Teede HJ et al. Lancet 2026  |  Wu P et al. BMJ 2026  |  Forbes / Time Magazine 2026");

const patImpact = [
  { area:"Diagnosis", before:"Delayed by 'no cysts found' response; over-reliance on ultrasound", after:"Earlier diagnosis using menses + androgen criteria alone (60% don't need ultrasound)" },
  { area:"Consultation", before:"'You have cysts on your ovaries and fertility issues'", after:"'You have a hormonal and metabolic condition affecting multiple body systems'" },
  { area:"Metabolic Care", before:"Metabolic risks often not discussed in gynaecology consultations", after:"Mandatory: BP, glucose, lipids, BMI screened at diagnosis and regularly" },
  { area:"Mental Health", before:"Rarely screened for depression/anxiety in standard PCOS care", after:"PHQ-9, GAD-7 screening at diagnosis and follow-up per updated guidelines" },
  { area:"Fertility", before:"IVF pushed early; underlying IR not treated first", after:"Lifestyle + metformin first; letrozole-based ovulation induction; treat metabolic causes" },
  { area:"Stigma", before:"'Cyst problem' → shame, anxiety, and fertility-focused distress", after:"Hormonal-metabolic condition framing → reduced stigma, better QoL" },
];

patImpact.forEach((p, i) => {
  const y = 0.96 + i*0.78;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:1.3,h:0.7, fill:{color:C.navy}, line:{color:C.navy}, rectRadius:0.06 });
  s.addText(p.area, { x:0.35,y:y+0.08,w:1.2,h:0.54, fontSize:11,bold:true,color:C.gold,align:"center",fontFace:"Calibri",valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:1.68,y,w:3.75,h:0.7, fill:{color:C.lancetRed,alpha:75}, line:{color:C.lancetRed,pt:0} });
  s.addText("Before (PCOS):  "+p.before, { x:1.74,y:y+0.06,w:3.62,h:0.58, fontSize:10.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
  s.addShape(pres.ShapeType.rect, { x:5.5,y,w:4.2,h:0.7, fill:{color:C.teal,alpha:75}, line:{color:C.teal,pt:0} });
  s.addText("After (PMOS):  "+p.after, { x:5.56,y:y+0.06,w:4.08,h:0.58, fontSize:10.5,color:C.white,fontFace:"Calibri",wrap:true,valign:"middle" });
});

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 23 — Strengths of the Lancet Paper
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
darkBG(s);
header(s, "Critical Appraisal — Strengths of the Lancet 2026 Paper", true);
footer(s, "Teede HJ et al. Lancet 2026  |  PMID: 42119588");

s.addText([
  bullet("Unprecedented scale: 22,068+ total survey responses — largest consensus effort in women's endocrinology"),
  bullet("Methodological rigour: combines multiple validated consensus techniques (Delphi + NGT + quantitative surveys)"),
  bullet("Global representativeness: all world regions; explicit cultural/linguistic sensitivity testing"),
  bullet("Patient-centred: named patient co-author (Rachel Morman); patients weighted equally with clinicians"),
  bullet("Transparent governance: independent funding; pre-specified consensus thresholds; COI management"),
  bullet("Broad stakeholder engagement: 56 organisations — academic, clinical, patient — all endorsing final outcome"),
  bullet("Companion suite: 7 parallel papers address implementation across clinical domains"),
  bullet("Practical implementation: not just a name proposal — full roadmap with 3-year timeline to ICD 2028"),
  bullet("Strong prior mandate: NIH 2012 workshop, 2023 international guidelines, and patient surveys all called for change"),
  bullet("Presented at high-impact forum: European Congress of Endocrinology 2026, Prague — simultaneous global launch"),
], { x:0.35,y:0.95,w:9.3,h:4.4, fontFace:"Calibri",color:C.white });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 24 — Limitations & Future Directions
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
lightBG(s);
header(s, "Limitations & Future Directions", false);
footer(s, "Teede HJ et al. Lancet 2026  |  ESSI commentary 2026  |  Lam Clinic 2026");

s.addText("Limitations Acknowledged by Authors:", { x:0.3,y:0.9,w:9.4,h:0.42, fontSize:15,bold:true,color:C.lancetRed,fontFace:"Calibri" });
barAccent(s, 0.3, 1.35, 9.4, C.lancetRed);
s.addText([
  bullet("Transition risk: PCOS persists in literature, EHRs, and patient knowledge — 2–3 year educational lag expected"),
  bullet("Self-selection bias in surveys: respondents more engaged with PCOS may disproportionately favour name change"),
  bullet("No formal hypothesis testing — this is a consensus paper, not an RCT; strength of recommendation based on participation breadth"),
  bullet("Language barriers: 'polyendocrine' is complex in non-English contexts — ongoing translation work needed"),
  bullet("HCP uptake uncertainty: institutional inertia, insurance systems, and educational curricula slow to change"),
], { x:0.35,y:1.44,w:9.3,h:2.05, fontFace:"Calibri",color:C.textDark });

s.addText("Future Directions (from the Paper):", { x:0.3,y:3.6,w:9.4,h:0.4, fontSize:15,bold:true,color:C.teal,fontFace:"Calibri" });
barAccent(s, 0.3, 4.02, 9.4, C.teal);
s.addText([
  bullet("2028: Full ICD transition — PCOS coded as PMOS across international disease classification systems"),
  bullet("2028: International PCOS/PMOS Guideline update — formally incorporates new name and expanded metabolic framing"),
  bullet("Subtype research: investigation of whether PMOS phenotypic subtypes warrant distinct future classification"),
  bullet("Biomarker research: refinement of AMH thresholds, androgenic panels, and emerging genetic/metabolic markers"),
], { x:0.35,y:4.1,w:9.3,h:1.35, fontFace:"Calibri",color:C.textDark });

// ─────────────────────────────────────────────────────────────────────────────
//  SLIDE 25 — Key Conclusions & Take-Home Messages
// ─────────────────────────────────────────────────────────────────────────────
s = pres.addSlide();
titleBG(s);
s.addShape(pres.ShapeType.rect, { x:0,y:0,w:0.18,h:H, fill:{color:C.lancetRed}, line:{color:C.lancetRed} });
s.addShape(pres.ShapeType.ellipse, { x:6.5,y:-1,w:5,h:5, fill:{color:C.teal,alpha:12}, line:{color:C.teal,alpha:0} });

s.addText("Key Conclusions", { x:0.35,y:0.18,w:9.3,h:0.55, fontSize:24,bold:true,color:C.gold,fontFace:"Calibri",charSpacing:2 });
lancetTag(s, 7.8, 0.2);

const conclusions = [
  { n:"1", msg:"PCOS is now officially PMOS — confirmed by the Lancet's landmark 2026 global consensus paper", detail:"14-year process; 22,068 responses; 56 organisations; announced ECE Prague, May 12 2026" },
  { n:"2", msg:"The rename corrects a 90-year misnomer — no increase in pathological cysts exists", detail:"Teede et al.: 'PCOS inaccurate, implying pathological cysts, contributing to delayed diagnosis and stigma'" },
  { n:"3", msg:"Rigorous methodology: iterative surveys + Delphi + NGT workshops + marketing analysis", detail:"82% overall; 86% patients; 70% HCPs support accurate feature-based name" },
  { n:"4", msg:"PMOS = Polyendocrine + Metabolic + Ovarian + Syndrome — each word chosen deliberately", detail:"Polyendocrine: multi-axis endocrine dysfunction | Metabolic: central IR/CVD risk | Ovarian: follicular/endocrine" },
  { n:"5", msg:"Diagnostic criteria unchanged — Rotterdam 2023 fully applicable under PMOS", detail:"'Evolution not transformation' — existing knowledge base transfers directly" },
  { n:"6", msg:"3-year transition underway — ICD update to PMOS expected 2028", detail:"Dual coding (PCOS/PMOS), guideline updates, EHR coding, medical education reform all in progress" },
  { n:"7", msg:"Expected outcomes: earlier diagnosis, reduced stigma, holistic care, expanded research funding", detail:"Language in medicine shapes care — renaming is the foundation for system-wide improvement" },
];

conclusions.forEach((c, i) => {
  const y = 0.85 + i*0.68;
  s.addShape(pres.ShapeType.roundRect, { x:0.3,y,w:9.4,h:0.62, fill:{color:i%2===0?C.navy:C.teal,alpha:90}, line:{color:i===0?C.gold:C.lancetRed,pt:i===0?2:1}, rectRadius:0.07 });
  s.addShape(pres.ShapeType.ellipse, { x:0.38,y:y+0.12,w:0.38,h:0.38, fill:{color:C.gold}, line:{color:C.gold} });
  s.addText(c.n, { x:0.38,y:y+0.12,w:0.38,h:0.38, fontSize:12,bold:true,color:C.ink,align:"center",valign:"middle",fontFace:"Calibri" });
  s.addText(c.msg, { x:0.86,y:y+0.04,w:8.75,h:0.28, fontSize:12.5,bold:true,color:i===0?C.gold:C.white,fontFace:"Calibri" });
  s.addText(c.detail, { x:0.86,y:y+0.33,w:8.75,h:0.26, fontSize:10,color:C.paleTeal,italic:true,fontFace:"Calibri" });
});

s.addText("Teede HJ et al. Lancet 2026 | DOI: 10.1016/S0140-6736(26)00717-8 | PMID: 42119588", {
  x:0.3,y:5.36,w:9.4,h:0.22, fontSize:8.5,color:C.paleGold,italic:true,fontFace:"Calibri",align:"center"
});

// ─── Write ─────────────────────────────────────────────────────────────────────
pres.writeFile({ fileName:"/home/daytona/workspace/pmos-pptx/PMOS_Lancet2026_Detailed_Review_25slides.pptx" })
  .then(() => console.log("SUCCESS"))
  .catch(err => { console.error("ERROR:", err); process.exit(1); });
Running Command

cd /home/daytona/workspace/pmos-pptx && node build_lancet_review.js 2>&1

Running Command

ls -lh /home/daytona/workspace/pmos-pptx/

Your 25-slide detailed review is ready:

PMOS Lancet2026 Detailed Review 25slides

Presentation · PPTX


Slide-by-Slide Contents

#SlideKey Content from Lancet Paper
1CoverFull citation, DOI, PMID, authors, ECE Prague announcement
2Article at a GlanceJournal, type, DOI, lead/co-leads, 56 organisations, companion papers
3Background — Why PCOS Had to ChangeLancet pull quote verbatim; 70% undiagnosed; 6 documented harms
414-Year Journey2012 NIH → 2017 → 2023 → Apr 2025 → Nov 2025 → Dec 2025 → Jan 2026 → Feb 2026 → May 12 2026 timeline
5Governance FrameworkLead institution, co-leads, AE-PCOS Society, Verity UK, 56 orgs detail
6Study Methods Overview6-phase methodology: literature review → Survey A → Delphi → NGT workshops → marketing → Survey B
7Survey Scale & Data22,068+ total; 14,360 new; 10,411 patients; 3,949 HCPs — with infographic stats
8The 5 Guiding PrinciplesScientific accuracy, clarity, stigma avoidance, cultural fit, implementation feasibility
9Term Selection Process3 key decisions: keep acronym?, which terms?, 'syndrome' vs other?
10Anatomy of PMOSP·M·O·S deconstructed — each letter's clinical meaning
11Survey A Key Findings82% overall / 86% patients / 70% HCPs — with % stat cards
12Delphi & NGT Workshop DetailsWorkshop A (Nov 2025) & B (Feb 2026) — exact terms tested, outcomes
13Survey B & Final SelectionPMOS vs. 4 rejected alternatives — with rationale for each rejection
14Clinical Definition of PMOSWhat it is, prevalence, scope — 'not a new condition' framing
15Multisystem Pathophysiology5 axes: neuroendocrine, androgen, insulin resistance, ovarian, metabolic
16PCOM Ultrasound Image4-panel Doppler + criteria table (follicle count, volume, AMH, pattern)
17Diagnostic Criteria — UnchangedRotterdam 2023 under PMOS; 3 pillars; exclusion criteria
18Burden of the Old NameDiagnostic, clinical care, and research/policy harms — 3-column evidence
19Implementation Strategy4-phase roadmap: 2026 → 2026–27 → 2027–28 → ICD 2028
20What Changes vs. What Doesn'tSide-by-side 8-point comparison
21Companion Papers7 companion publications — BMJ, adolescents, maternal, clinical, policy, research
22Clinical Impact for PatientsBefore/after: diagnosis, consultation, metabolic care, mental health, fertility, stigma
23Strengths of the Paper10 methodological and scientific strengths
24Limitations & Future DirectionsAcknowledged limitations + 2028 directions from the paper itself
25Key Conclusions7 take-home messages from the Lancet paper

Primary source: Teede HJ et al. The Lancet. 2026 May 12. DOI: 10.1016/S0140-6736(26)00717-8 | PMID: 42119588
This is a shared conversation. Sign in to Orris to start your own chat.