Carcinoma of cervix ppt Definition Etiology Pathogenesis Risk factors lesions Route of spread
ls /home/daytona/workspace/ 2>/dev/null || mkdir -p /home/daytona/workspace/
~/cervix-ca-ppt/cervix_ca.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Carcinoma of the Cervix";
pres.author = "Medical Education";
// ─── COLOR PALETTE ───────────────────────────────────────────────
const COL = {
bg_dark: "1A1A2E", // deep navy – title / section slides
bg_mid: "16213E", // mid navy
bg_light: "F5F7FA", // near-white – content slides
accent: "E94560", // crimson-red accent
accent2: "0F3460", // medium navy
accent3: "533483", // purple accent
gold: "F5A623", // gold highlight
white: "FFFFFF",
text_dark: "1A1A2E",
text_mid: "2D3561",
text_light: "E8ECF0",
bullet_line:"E94560",
};
// ─── HELPER: red left-border accent bar ──────────────────────────
function accentBar(slide, yStart = 1.1, height = 3.8) {
slide.addShape(pres.ShapeType.rect, {
x: 0.18, y: yStart, w: 0.06, h: height,
fill: { color: COL.accent }, line: { color: COL.accent }
});
}
// ─── HELPER: dark header band ────────────────────────────────────
function headerBand(slide, title, subtitle = "") {
slide.addShape(pres.ShapeType.rect, {
x: 0, y: 0, w: 10, h: 1.05,
fill: { color: COL.bg_dark }, line: { color: COL.bg_dark }
});
slide.addShape(pres.ShapeType.rect, {
x: 0, y: 1.05, w: 10, h: 0.06,
fill: { color: COL.accent }, line: { color: COL.accent }
});
slide.addText(title, {
x: 0.4, y: 0.08, w: 9.2, h: 0.75,
fontSize: 26, bold: true, color: COL.white,
fontFace: "Calibri", valign: "middle", margin: 0
});
if (subtitle) {
slide.addText(subtitle, {
x: 0.4, y: 0.76, w: 9.2, h: 0.3,
fontSize: 12, color: COL.gold, fontFace: "Calibri", valign: "top", margin: 0
});
}
// footer
slide.addText("Carcinoma of the Cervix | Pathology", {
x: 0, y: 5.35, w: 10, h: 0.27,
fontSize: 8, color: "888888", fontFace: "Calibri",
align: "right", valign: "middle", margin: [0,0,0,8]
});
}
// ─── HELPER: build bullet array ──────────────────────────────────
function bullets(items, mainOpts = {}) {
return items.map((item, idx) => {
const isLast = idx === items.length - 1;
const isSubBullet = item.startsWith(" ") || item.startsWith("\t");
return {
text: item.replace(/^(\s+)/, ""),
options: {
bullet: isSubBullet ? { indent: 20 } : true,
breakLine: !isLast,
fontSize: isSubBullet ? 13 : 15,
color: isSubBullet ? "555555" : COL.text_dark,
bold: item.startsWith("●"),
...mainOpts
}
};
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 1 — TITLE
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color: COL.bg_dark}, line:{color:COL.bg_dark} });
// decorative diagonal strip
slide.addShape(pres.ShapeType.rect, { x:6.8, y:0, w:3.2, h:5.625, fill:{color: COL.bg_mid}, line:{color:COL.bg_mid} });
// accent bars
slide.addShape(pres.ShapeType.rect, { x:0.35, y:1.2, w:0.1, h:3.2, fill:{color:COL.accent}, line:{color:COL.accent} });
slide.addShape(pres.ShapeType.rect, { x:0, y:4.8, w:10, h:0.1, fill:{color:COL.accent}, line:{color:COL.accent} });
// subtitle label
slide.addText("PATHOLOGY • GYNECOLOGICAL ONCOLOGY", {
x:0.6, y:1.3, w:6, h:0.4,
fontSize:11, color:COL.gold, bold:true, charSpacing:3, fontFace:"Calibri", margin:0
});
// main title
slide.addText("Carcinoma of\nthe Cervix", {
x:0.6, y:1.7, w:6, h:2.2,
fontSize:46, bold:true, color:COL.white, fontFace:"Calibri",
valign:"middle", margin:0
});
// topics list
slide.addText([
{ text: "Definition • Etiology • Pathogenesis", options:{ breakLine:true } },
{ text: "Risk Factors • Lesions • Routes of Spread", options:{ breakLine:false } }
], {
x:0.6, y:3.95, w:6.1, h:0.9,
fontSize:13, color:"B0BEC5", fontFace:"Calibri", valign:"top", margin:0
});
// right-panel decoration
slide.addText("🔬", { x:7.2, y:1.5, w:2, h:2, fontSize:90, align:"center", valign:"middle" });
slide.addText("Source: Robbins Basic Pathology, Robbins Pathologic Basis of Disease", {
x:0, y:5.3, w:10, h:0.28,
fontSize:8, color:"888888", fontFace:"Calibri", align:"right", margin:[0,0,0,8]
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 2 — OUTLINE
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Lecture Outline");
accentBar(slide, 1.25, 3.9);
const topics = [
["01", "Definition", COL.accent],
["02", "Etiology", COL.accent3],
["03", "Pathogenesis", COL.accent2],
["04", "Risk Factors", COL.accent],
["05", "Lesions (CIN / SIL / Invasive)", COL.accent3],
["06", "Routes of Spread", COL.accent2],
];
const startY = 1.3;
const rowH = 0.6;
topics.forEach(([num, label, color], i) => {
const y = startY + i * rowH;
slide.addShape(pres.ShapeType.rect, { x:0.35, y:y+0.05, w:0.5, h:0.42, fill:{color}, line:{color} });
slide.addText(num, { x:0.35, y:y+0.05, w:0.5, h:0.42, fontSize:13, bold:true, color:COL.white, align:"center", valign:"middle", margin:0 });
slide.addText(label, { x:0.95, y:y+0.05, w:8.5, h:0.42, fontSize:17, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:0 });
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 3 — DEFINITION
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Definition", "What is Carcinoma of the Cervix?");
accentBar(slide, 1.25, 3.9);
// Definition box
slide.addShape(pres.ShapeType.rect, { x:0.35, y:1.3, w:9.3, h:1.4, fill:{color:COL.accent+"15"}, line:{color:COL.accent, pt:1.5} });
slide.addText(
"Carcinoma of the cervix is a malignant epithelial neoplasm arising from the uterine cervix, predominantly at the squamocolumnar junction (transformation zone), caused in virtually all cases by persistent infection with high-risk strains of Human Papillomavirus (HPV).",
{ x:0.5, y:1.35, w:9.0, h:1.3, fontSize:14, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:5 }
);
// Key facts
slide.addText("Key Facts", { x:0.35, y:2.85, w:9.3, h:0.35, fontSize:16, bold:true, color:COL.accent2, fontFace:"Calibri", margin:0 });
slide.addText(bullets([
"Most common cervical carcinoma: Squamous cell carcinoma (SCC) — ~80% of cases",
"Adenocarcinoma & mixed adenosquamous carcinoma — ~15% of cases",
"Small cell neuroendocrine carcinoma — <5% (very poor prognosis)",
"3rd most common gynecologic cancer worldwide; 2nd in developing countries",
"Peak incidence at ~45 years of age (10–15 years after peak of precursor lesions)",
]), { x:0.45, y:3.2, w:9.1, h:2.1, fontFace:"Calibri", valign:"top", margin:[4,0,0,4] });
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 4 — ETIOLOGY
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Etiology", "Role of Human Papillomavirus (HPV)");
accentBar(slide, 1.25, 3.9);
// Two-column layout
// Left column: HPV types
slide.addShape(pres.ShapeType.rect, { x:0.35, y:1.3, w:4.5, h:3.95, fill:{color:COL.accent2+"12"}, line:{color:COL.accent2, pt:1} });
slide.addText("HPV — The Primary Cause", { x:0.45, y:1.35, w:4.3, h:0.4, fontSize:14, bold:true, color:COL.accent2, fontFace:"Calibri", margin:0 });
slide.addText(bullets([
"HPV detected in >99% of cervical carcinomas",
"High-risk strains: HPV 16, 18, 31, 33, 45",
" HPV 16 → Squamous cell carcinoma",
" HPV 18 → Adenocarcinoma (glandular)",
"Low-risk strains: HPV 6, 11 → Condyloma (benign warts)",
"HPV is a DNA virus (double-stranded, circular)",
"Viral DNA integrates into host genome",
]), { x:0.45, y:1.75, w:4.3, h:3.4, fontFace:"Calibri", valign:"top", margin:[4,0,0,4] });
// Right column: other etiologic factors
slide.addShape(pres.ShapeType.rect, { x:5.1, y:1.3, w:4.55, h:3.95, fill:{color:COL.accent3+"12"}, line:{color:COL.accent3, pt:1} });
slide.addText("Co-factors in Etiology", { x:5.2, y:1.35, w:4.3, h:0.4, fontSize:14, bold:true, color:COL.accent3, fontFace:"Calibri", margin:0 });
slide.addText(bullets([
"Persistent HPV infection (most critical)",
"Cigarette smoking",
"Immunosuppression (e.g., HIV/AIDS)",
"Long-term oral contraceptive use",
"High parity (multiple pregnancies)",
"Co-infection with other STIs",
" (Chlamydia, HSV-2, gonorrhoea)",
"Absence of circumcision in male partner",
]), { x:5.2, y:1.75, w:4.3, h:3.4, fontFace:"Calibri", valign:"top", margin:[4,0,0,4] });
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 5 — PATHOGENESIS (part 1 — HPV molecular mechanism)
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Pathogenesis — HPV Molecular Mechanism", "How HPV drives malignant transformation");
accentBar(slide, 1.25, 3.9);
// Step boxes
const steps = [
{ num:"1", title:"HPV Infection", body:"HPV infects immature basal squamous cells in the transformation zone. Viral replication occurs in maturing squamous cells.", color: COL.accent },
{ num:"2", title:"Viral Integration", body:"Viral DNA integrates into the host genome → disrupts the E2 gene → loss of E2-mediated suppression of E6 and E7 oncoproteins.", color: COL.accent3 },
{ num:"3", title:"E6 Oncoprotein", body:"E6 binds and degrades p53 tumour suppressor → blocks apoptosis and allows DNA damage to accumulate.", color: COL.accent2 },
{ num:"4", title:"E7 Oncoprotein", body:"E7 binds and inactivates pRB (retinoblastoma protein) → releases E2F transcription factor → uncontrolled cell cycle progression.", color: COL.gold },
];
const boxW = 2.2, boxH = 1.78, startX = 0.35, gapX = 0.12;
steps.forEach((s, i) => {
const x = startX + i * (boxW + gapX);
slide.addShape(pres.ShapeType.rect, { x, y:1.3, w:boxW, h:boxH, fill:{color: s.color + "20"}, line:{color: s.color, pt:1.5} });
slide.addShape(pres.ShapeType.rect, { x, y:1.3, w:boxW, h:0.38, fill:{color: s.color}, line:{color: s.color} });
slide.addText(`${s.num}. ${s.title}`, { x, y:1.3, w:boxW, h:0.38, fontSize:12, bold:true, color:COL.white, align:"center", valign:"middle", fontFace:"Calibri", margin:0 });
slide.addText(s.body, { x:x+0.06, y:1.72, w:boxW-0.12, h:1.3, fontSize:11.5, color:COL.text_dark, fontFace:"Calibri", valign:"top", margin:4 });
});
// Arrow connectors (simple shapes)
[0,1,2].forEach(i => {
const ax = startX + (i+1) * (boxW + gapX) - gapX + 0.01;
slide.addShape(pres.ShapeType.rect, { x:ax-0.04, y:1.98, w:0.12, h:0.14, fill:{color:COL.text_dark}, line:{color:COL.text_dark} });
});
// Outcomes
slide.addShape(pres.ShapeType.rect, { x:0.35, y:3.22, w:9.3, h:0.06, fill:{color:COL.accent}, line:{color:COL.accent} });
slide.addText("Net Result of E6 + E7 Action →", { x:0.35, y:3.32, w:3.2, h:0.3, fontSize:13, bold:true, color:COL.accent, fontFace:"Calibri", margin:0 });
slide.addText(bullets([
"Immortalization of cervical epithelial cells",
"Accumulation of mutations during rapid proliferation → genomic instability → invasive carcinoma",
"HPV infection is necessary but NOT sufficient → additional mutations required for full malignant transformation",
]), { x:0.45, y:3.6, w:9.1, h:1.7, fontFace:"Calibri", valign:"top", margin:[3,0,0,4] });
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 6 — PATHOGENESIS (part 2 — transformation zone)
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Pathogenesis — The Transformation Zone", "Site of origin of virtually all cervical carcinomas");
accentBar(slide, 1.25, 3.9);
slide.addText(bullets([
"At puberty, the squamocolumnar junction (SCJ) undergoes eversion",
"Columnar epithelium of endocervix shifts outward to ectocervical surface",
"Exposed columnar cells undergo squamous metaplasia → forms the transformation zone (TZ)",
"Immature squamous cells in the TZ are MOST SUSCEPTIBLE to HPV infection",
"HPV infects basal cells through microabrasions during intercourse",
"Viral particles enter immature cells → productive infection or latent infection",
"Persistent high-risk HPV → dysplasia → CIN → invasive carcinoma (over 10–15 years)",
"Regression of HPV possible if immune system clears the virus (most infections transient)",
]), { x:0.45, y:1.3, w:9.1, h:3.3, fontFace:"Calibri", valign:"top", fontSize:15, margin:[6,0,0,4] });
// Progression timeline
slide.addShape(pres.ShapeType.rect, { x:0.35, y:4.65, w:9.3, h:0.7, fill:{color:COL.accent2+"15"}, line:{color:COL.accent2, pt:1} });
slide.addText(
"Progression: Normal Epithelium → HPV Infection → CIN 1 → CIN 2 → CIN 3 / CIS → Invasive Carcinoma",
{ x:0.45, y:4.67, w:9.1, h:0.66, fontSize:13, bold:true, color:COL.accent2, align:"center", valign:"middle", fontFace:"Calibri", margin:0 }
);
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 7 — RISK FACTORS
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Risk Factors", "Factors that increase susceptibility to cervical carcinoma");
accentBar(slide, 1.25, 3.9);
// Two columns
const leftItems = [
["HPV Exposure-Related", [
"Early age at first intercourse (<16 yrs)",
"Multiple sexual partners",
"Partner with multiple prior sexual partners",
"Persistent infection by high-risk HPV strains",
"History of other sexually transmitted infections",
], COL.accent],
["Host / Immunologic", [
"Immunosuppression (HIV, transplant patients)",
"Failure to receive HPV vaccination",
"Long-term oral contraceptive use (>5 yrs)",
], COL.accent3],
];
const rightItems = [
["Behavioural / Environmental", [
"Cigarette smoking",
"High parity (≥3 pregnancies)",
"Low socioeconomic status",
"Lack of cervical cancer screening (Pap smear)",
], COL.accent2],
["Male Partner Factors", [
"Partner who is uncircumcised",
"Partner with history of penile or anal HPV",
], COL.gold],
];
let curY = 1.3;
leftItems.forEach(([heading, items, color]) => {
slide.addShape(pres.ShapeType.rect, { x:0.35, y:curY, w:0.06, h:0.32, fill:{color}, line:{color} });
slide.addText(heading, { x:0.5, y:curY, w:4.5, h:0.32, fontSize:13, bold:true, color, fontFace:"Calibri", margin:0 });
curY += 0.34;
items.forEach((item, idx) => {
slide.addText([{ text:item, options:{ bullet:true, breakLine:false } }], {
x:0.55, y:curY, w:4.35, h:0.31, fontSize:13, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:[2,0,0,2]
});
curY += 0.31;
});
curY += 0.12;
});
curY = 1.3;
rightItems.forEach(([heading, items, color]) => {
slide.addShape(pres.ShapeType.rect, { x:5.05, y:curY, w:0.06, h:0.32, fill:{color}, line:{color} });
slide.addText(heading, { x:5.2, y:curY, w:4.5, h:0.32, fontSize:13, bold:true, color, fontFace:"Calibri", margin:0 });
curY += 0.34;
items.forEach((item) => {
slide.addText([{ text:item, options:{ bullet:true, breakLine:false } }], {
x:5.25, y:curY, w:4.3, h:0.31, fontSize:13, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:[2,0,0,2]
});
curY += 0.31;
});
curY += 0.12;
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 8 — LESIONS: CIN / SIL Precursor Lesions
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Precursor Lesions: CIN / SIL", "Cervical Intraepithelial Neoplasia — the continuum before invasion");
accentBar(slide, 1.25, 3.9);
// Comparison table header
const cols = ["Feature", "LSIL / CIN 1", "HSIL / CIN 2", "HSIL / CIN 3 (CIS)"];
const colW = [2.3, 2.3, 2.3, 2.4];
const tableX = 0.35;
let tx = tableX;
cols.forEach((c, i) => {
const bg = i === 0 ? COL.accent2 : i === 1 ? COL.gold+"AA" : i === 2 ? COL.accent3 : COL.accent;
slide.addShape(pres.ShapeType.rect, { x:tx, y:1.28, w:colW[i]-0.04, h:0.42, fill:{color:bg}, line:{color:bg} });
slide.addText(c, { x:tx, y:1.28, w:colW[i]-0.04, h:0.42, fontSize:12, bold:true, color:COL.white, align:"center", valign:"middle", fontFace:"Calibri", margin:0 });
tx += colW[i];
});
// Table rows
const rows = [
["HPV type", "Low-risk (6,11) or transient high-risk", "High-risk (16, 18)", "High-risk (16, 18, 31)"],
["Dysplasia extent", "Lower 1/3 of epithelium", "Lower 2/3 of epithelium", "Full-thickness involvement"],
["Koilocytes", "Prominent (viral CPE)", "Moderate", "Rare / absent"],
["Mitoses", "Basal only", "Lower 2/3", "Throughout all layers"],
["Nuclear atypia", "Mild", "Moderate", "Severe"],
["Outcome", "~60% regress spontaneously", "~20% regress; ~5% → invasive", "~12% → invasive in 10 yrs if untreated"],
];
rows.forEach((row, ri) => {
tx = tableX;
const bgRow = ri % 2 === 0 ? "F0F4F8" : "FFFFFF";
row.forEach((cell, ci) => {
slide.addShape(pres.ShapeType.rect, { x:tx, y:1.7+ri*0.6, w:colW[ci]-0.04, h:0.58, fill:{color:bgRow}, line:{color:"CCCCCC", pt:0.5} });
slide.addText(cell, { x:tx+0.05, y:1.72+ri*0.6, w:colW[ci]-0.1, h:0.54, fontSize:11, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:2 });
tx += colW[ci];
});
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 9 — INVASIVE LESIONS
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Invasive Carcinoma — Lesion Types", "Morphological types and features of invasive cervical cancer");
accentBar(slide, 1.25, 3.9);
// Three type cards
const cards = [
{
title: "Squamous Cell Carcinoma (~80%)",
color: COL.accent,
points: [
"Arises from transformation zone ectocervix",
"Tongues and nests of squamous cells → desmoplastic stroma",
"Ranges from keratinizing (well-diff) to non-keratinizing (poorly-diff)",
"Keratin pearls in well-differentiated tumours",
"Exophytic, endophytic, or ulcerative macroscopic forms",
"Barrel cervix: tumour encircles and expands the cervix",
]
},
{
title: "Adenocarcinoma (~15%)",
color: COL.accent3,
points: [
"Arises from endocervical glandular epithelium",
"Driven mainly by HPV 18",
"Increasing proportion (Pap smear misses glandular precursors)",
"Endocervical (mucinous) type most common",
"Clear cell, serous, and minimal deviation types also seen",
"May present with no visible lesion on ectocervix",
]
},
{
title: "Small Cell Neuroendocrine (<5%)",
color: COL.gold,
points: [
"Morphologically similar to small cell carcinoma of lung",
"Highly aggressive — worst prognosis",
"Early systemic dissemination",
"Neuroendocrine markers: chromogranin, synaptophysin +ve",
"Poor response to standard surgery alone",
]
}
];
const cW = 3.1, cX = [0.35, 3.5, 6.65];
cards.forEach((card, i) => {
slide.addShape(pres.ShapeType.rect, { x:cX[i], y:1.28, w:cW, h:4.1, fill:{color:card.color+"12"}, line:{color:card.color, pt:1.5} });
slide.addShape(pres.ShapeType.rect, { x:cX[i], y:1.28, w:cW, h:0.48, fill:{color:card.color}, line:{color:card.color} });
slide.addText(card.title, { x:cX[i]+0.06, y:1.28, w:cW-0.12, h:0.48, fontSize:11.5, bold:true, color:COL.white, fontFace:"Calibri", align:"center", valign:"middle", margin:0 });
slide.addText(bullets(card.points), { x:cX[i]+0.1, y:1.8, w:cW-0.2, h:3.5, fontFace:"Calibri", fontSize:12, valign:"top", margin:[4,0,0,2] });
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 10 — ROUTES OF SPREAD
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "Routes of Spread", "Local, lymphatic, haematogenous, and perineural dissemination");
accentBar(slide, 1.25, 3.9);
const routes = [
{
icon: "🔴",
title: "1. Direct / Local Extension",
color: COL.accent,
body: [
"Most common initial route",
"Superiorly → body of uterus",
"Inferiorly → vagina",
"Laterally → parametrium, ureteral obstruction → hydronephrosis (most common cause of death)",
"Anteriorly → urinary bladder → vesicovaginal fistula",
"Posteriorly → rectum → rectovaginal fistula",
"'Barrel cervix' from circumferential growth",
]
},
{
icon: "🟣",
title: "2. Lymphatic Spread",
color: COL.accent3,
body: [
"Second most common route",
"1st echelon: Obturator, internal/external iliac, parametrial nodes",
"2nd echelon: Common iliac nodes",
"3rd echelon: Para-aortic lymph nodes",
"Risk of nodal metastasis correlates with depth of invasion:",
" < 3 mm invasion → <1% nodal spread",
" > 3 mm invasion → >10% nodal spread",
]
},
{
icon: "🔵",
title: "3. Haematogenous Spread",
color: COL.accent2,
body: [
"Occurs in advanced disease",
"Common distant sites: Lungs, liver, bones",
"Vascular/lymphovascular space invasion (LVSI) is an adverse prognostic feature",
"Risk increases with higher FIGO stage",
]
},
{
icon: "🟡",
title: "4. Transperitoneal / Perineural",
color: COL.gold,
body: [
"Less common",
"Transperitoneal seeding possible with advanced disease",
"Perineural invasion contributes to pelvic pain",
]
},
];
const rW = 4.6, gap = 0.1;
const positions = [
{ x: 0.35, y: 1.3 },
{ x: 0.35 + rW + gap, y: 1.3 },
{ x: 0.35, y: 3.3 },
{ x: 0.35 + rW + gap, y: 3.3 },
];
routes.forEach((r, i) => {
const { x, y } = positions[i];
const h = 1.9;
slide.addShape(pres.ShapeType.rect, { x, y, w:rW, h, fill:{color:r.color+"12"}, line:{color:r.color, pt:1.5} });
slide.addShape(pres.ShapeType.rect, { x, y, w:rW, h:0.36, fill:{color:r.color}, line:{color:r.color} });
slide.addText(r.title, { x:x+0.08, y, w:rW-0.12, h:0.36, fontSize:12, bold:true, color:COL.white, fontFace:"Calibri", valign:"middle", margin:0 });
slide.addText(bullets(r.body), { x:x+0.1, y:y+0.38, w:rW-0.18, h:h-0.42, fontFace:"Calibri", fontSize:11.5, valign:"top", margin:[3,0,0,2] });
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 11 — FIGO STAGING SUMMARY
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_light}, line:{color:COL.bg_light} });
headerBand(slide, "FIGO Staging Summary (2018)", "Staging determines prognosis and treatment selection");
accentBar(slide, 1.25, 3.9);
const stages = [
["Stage I", "Confined to cervix uteri", COL.gold],
[" IA", "Microscopic invasive carcinoma; max depth 5 mm", COL.gold+"99"],
[" IB", "Clinically visible or >5 mm depth, confined to cervix", COL.gold+"99"],
["Stage II", "Beyond cervix but not pelvic wall or lower 1/3 vagina", COL.accent3],
[" IIA", "Without parametrial invasion", COL.accent3+"99"],
[" IIB", "With parametrial invasion", COL.accent3+"99"],
["Stage III", "Extends to pelvic wall or lower 1/3 vagina or hydronephrosis", COL.accent2],
["Stage IV", "Extends beyond true pelvis or invades bladder/rectum (IVA) or distant metastasis (IVB)", COL.accent],
];
stages.forEach((s, i) => {
const isMain = s[0].startsWith("Stage");
slide.addShape(pres.ShapeType.rect, { x:0.35, y:1.3+i*0.53, w:2.2, h:0.51, fill:{color:s[2]}, line:{color:s[2]} });
slide.addText(s[0], { x:0.35, y:1.3+i*0.53, w:2.2, h:0.51, fontSize:isMain?13:12, bold:isMain, color:COL.white, align:"center", valign:"middle", fontFace:"Calibri", margin:0 });
slide.addShape(pres.ShapeType.rect, { x:2.58, y:1.3+i*0.53, w:7.07, h:0.51, fill:{color: isMain ? s[2]+"30" : "F8F9FA"}, line:{color:"DDDDDD", pt:0.5} });
slide.addText(s[1], { x:2.68, y:1.32+i*0.53, w:6.9, h:0.47, fontSize:12.5, color:COL.text_dark, fontFace:"Calibri", valign:"middle", margin:2 });
});
slide.addText("5-year survival: Stage I ~90% | Stage II ~65% | Stage III ~35% | Stage IV <15%", {
x:0.35, y:5.28, w:9.3, h:0.28, fontSize:11, bold:true, color:COL.accent, fontFace:"Calibri", align:"center", margin:0
});
}
// ═══════════════════════════════════════════════════════════════
// SLIDE 12 — SUMMARY / TAKE-HOME
// ═══════════════════════════════════════════════════════════════
{
const slide = pres.addSlide();
slide.addShape(pres.ShapeType.rect, { x:0, y:0, w:10, h:5.625, fill:{color:COL.bg_dark}, line:{color:COL.bg_dark} });
slide.addShape(pres.ShapeType.rect, { x:0, y:1.05, w:10, h:0.06, fill:{color:COL.accent}, line:{color:COL.accent} });
slide.addText("Key Takeaways", {
x:0.4, y:0.12, w:9.2, h:0.88,
fontSize:30, bold:true, color:COL.white, fontFace:"Calibri", valign:"middle", margin:0
});
const pts = [
["HPV is the cause", "Virtually all cervical carcinomas are caused by high-risk HPV (types 16, 18). E6 inactivates p53; E7 inactivates pRB."],
["Transformation zone", "The squamocolumnar junction / transformation zone is the origin of virtually all cervical tumours."],
["Precursor lesions", "CIN (LSIL → HSIL) are the precursors. HSIL / CIN 3 can progress to invasive carcinoma over 10–15 years."],
["Histologic types", "SCC 80%, Adenocarcinoma 15%, Small cell <5%."],
["Routes of spread", "Direct extension (commonest — may cause hydronephrosis), lymphatic (obturator → iliac → para-aortic), haematogenous (lung, liver, bone)."],
["Stage = prognosis", "FIGO staging guides treatment. Hydronephrosis alone upstages to Stage III."],
];
pts.forEach(([h, b], i) => {
const y = 1.2 + i * 0.72;
slide.addShape(pres.ShapeType.rect, { x:0.3, y:y, w:0.08, h:0.55, fill:{color:COL.accent}, line:{color:COL.accent} });
slide.addText(h + ": ", { x:0.5, y, w:2.0, h:0.55, fontSize:13, bold:true, color:COL.gold, fontFace:"Calibri", valign:"middle", margin:0 });
slide.addText(b, { x:2.45, y, w:7.2, h:0.55, fontSize:13, color:COL.text_light, fontFace:"Calibri", valign:"middle", margin:0 });
});
slide.addText("Source: Robbins & Kumar Basic Pathology • Robbins Pathologic Basis of Disease • Harrison's Principles of Internal Medicine", {
x:0, y:5.3, w:10, h:0.28,
fontSize:8, color:"888888", fontFace:"Calibri", align:"center", margin:0
});
}
// ─── WRITE FILE ──────────────────────────────────────────────
pres.writeFile({ fileName: "/home/daytona/workspace/cervix-ca-ppt/Carcinoma_of_the_Cervix.pptx" })
.then(() => console.log("✅ PPTX created: Carcinoma_of_the_Cervix.pptx"))
.catch(err => { console.error("ERROR:", err); process.exit(1); });
cd /home/daytona/workspace/cervix-ca-ppt && node cervix_ca.js 2>&1
cd /home/daytona/workspace/cervix-ca-ppt && sed -i \ 's/color:COL\.accent+\"15…
~/cervix-ca-ppt/cervix_ca2.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Carcinoma of the Cervix";
pres.author = "Medical Education";
// ─── COLOR PALETTE ───────────────────────────────────────────────
const COL = {
bg_dark: "1A1A2E",
bg_mid: "16213E",
bg_light: "F5F7FA",
accent: "E94560", // crimson
accent2: "0F3460", // navy
accent3: "533483", // purple
gold: "F5A623", // gold
white: "FFFFFF",
text_dark: "1A1A2E",
text_light: "E8ECF0",
// tint variants (proper 6-digit hex)
accent_tint: "FDEAEE",
accent2_tint: "E8EEF7",
accent3_tint: "EDE8F5",
gold_tint: "FEF5E4",
row_alt: "F0F4F8",
};
function accentBar(slide, yStart=1.1, height=3.8){
slide.addShape(pres.ShapeType.rect,{x:0.18,y:yStart,w:0.06,h:height,fill:{color:COL.accent},line:{color:COL.accent}});
}
function headerBand(slide, title, subtitle=""){
slide.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:1.05,fill:{color:COL.bg_dark},line:{color:COL.bg_dark}});
slide.addShape(pres.ShapeType.rect,{x:0,y:1.05,w:10,h:0.06,fill:{color:COL.accent},line:{color:COL.accent}});
slide.addText(title,{x:0.4,y:0.08,w:9.2,h:subtitle?0.68:0.88,fontSize:26,bold:true,color:COL.white,fontFace:"Calibri",valign:"middle",margin:0});
if(subtitle) slide.addText(subtitle,{x:0.4,y:0.74,w:9.2,h:0.3,fontSize:12,color:COL.gold,fontFace:"Calibri",valign:"top",margin:0});
slide.addText("Carcinoma of the Cervix | Pathology",{x:0,y:5.35,w:10,h:0.27,fontSize:8,color:"888888",fontFace:"Calibri",align:"right",valign:"middle",margin:[0,0,0,8]});
}
function mkBullets(items){
return items.map((item,idx)=>{
const isSub = item.startsWith(" ");
const isLast = idx===items.length-1;
return {text:item.replace(/^ /,""),options:{bullet:isSub?{indent:18}:true,breakLine:!isLast,fontSize:isSub?12:14,color:isSub?"555555":COL.text_dark}};
});
}
// ═══ SLIDE 1 — TITLE ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_dark},line:{color:COL.bg_dark}});
s.addShape(pres.ShapeType.rect,{x:6.7,y:0,w:3.3,h:5.625,fill:{color:COL.bg_mid},line:{color:COL.bg_mid}});
s.addShape(pres.ShapeType.rect,{x:0.35,y:1.1,w:0.1,h:3.3,fill:{color:COL.accent},line:{color:COL.accent}});
s.addShape(pres.ShapeType.rect,{x:0,y:4.8,w:10,h:0.1,fill:{color:COL.accent},line:{color:COL.accent}});
s.addText("PATHOLOGY • GYNECOLOGICAL ONCOLOGY",{x:0.6,y:1.2,w:6,h:0.38,fontSize:11,color:COL.gold,bold:true,charSpacing:3,fontFace:"Calibri",margin:0});
s.addText("Carcinoma of\nthe Cervix",{x:0.6,y:1.6,w:6,h:2.3,fontSize:46,bold:true,color:COL.white,fontFace:"Calibri",valign:"middle",margin:0});
s.addText("Definition • Etiology • Pathogenesis\nRisk Factors • Lesions • Routes of Spread",{x:0.6,y:3.95,w:6,h:0.85,fontSize:13,color:"B0BEC5",fontFace:"Calibri",valign:"top",margin:0});
s.addText("🔬",{x:7.1,y:1.4,w:2.2,h:2.2,fontSize:95,align:"center",valign:"middle"});
s.addText("Source: Robbins Basic Pathology • Harrison's Principles of Internal Medicine",{x:0,y:5.32,w:10,h:0.25,fontSize:8,color:"888888",fontFace:"Calibri",align:"right",margin:[0,0,0,8]});
}
// ═══ SLIDE 2 — OUTLINE ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Lecture Outline");
accentBar(s,1.28,3.9);
const topics=[["01","Definition",COL.accent],["02","Etiology",COL.accent3],["03","Pathogenesis",COL.accent2],["04","Risk Factors",COL.accent],["05","Lesions (CIN / SIL / Invasive Carcinoma)",COL.accent3],["06","Routes of Spread",COL.accent2]];
topics.forEach(([num,label,color],i)=>{
const y=1.35+i*0.62;
s.addShape(pres.ShapeType.rect,{x:0.35,y:y+0.04,w:0.5,h:0.44,fill:{color},line:{color}});
s.addText(num,{x:0.35,y:y+0.04,w:0.5,h:0.44,fontSize:13,bold:true,color:COL.white,align:"center",valign:"middle",margin:0});
s.addText(label,{x:0.95,y:y+0.04,w:8.5,h:0.44,fontSize:17,color:COL.text_dark,fontFace:"Calibri",valign:"middle",margin:0});
});
}
// ═══ SLIDE 3 — DEFINITION ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Definition","What is Carcinoma of the Cervix?");
accentBar(s,1.25,3.9);
s.addShape(pres.ShapeType.rect,{x:0.35,y:1.3,w:9.3,h:1.45,fill:{color:COL.accent_tint},line:{color:COL.accent,pt:1.5}});
s.addText("Carcinoma of the cervix is a malignant epithelial neoplasm arising from the uterine cervix, predominantly at the squamocolumnar junction (transformation zone). Virtually all cases are caused by persistent infection with high-risk strains of Human Papillomavirus (HPV).",
{x:0.5,y:1.35,w:9.0,h:1.35,fontSize:14,color:COL.text_dark,fontFace:"Calibri",valign:"middle",margin:6});
s.addText("Key Facts",{x:0.35,y:2.9,w:9.3,h:0.35,fontSize:16,bold:true,color:COL.accent2,fontFace:"Calibri",margin:0});
s.addText(mkBullets([
"Most common type: Squamous cell carcinoma (SCC) — ~80% of all cervical carcinomas",
"Adenocarcinoma and mixed adenosquamous carcinoma — ~15% of cases",
"Small cell neuroendocrine carcinoma — <5% (most aggressive, worst prognosis)",
"3rd most common gynecologic cancer globally; 2nd most common cancer in women in developing countries",
"SCC incidence peaks at ~45 years — 10 to 15 years after peak incidence of precursor lesions",
]),{x:0.45,y:3.27,w:9.1,h:2.08,fontFace:"Calibri",valign:"top",margin:[4,0,0,4]});
}
// ═══ SLIDE 4 — ETIOLOGY ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Etiology","Role of Human Papillomavirus (HPV) and co-factors");
accentBar(s,1.25,3.9);
// Left box
s.addShape(pres.ShapeType.rect,{x:0.35,y:1.3,w:4.5,h:4.0,fill:{color:COL.accent2_tint},line:{color:COL.accent2,pt:1}});
s.addText("HPV — Primary Cause",{x:0.45,y:1.35,w:4.3,h:0.38,fontSize:14,bold:true,color:COL.accent2,fontFace:"Calibri",margin:0});
s.addText(mkBullets([
"HPV detected in >99% of all cervical carcinomas",
"High-risk (oncogenic) strains: HPV 16, 18, 31, 33, 45",
" HPV 16 → Squamous cell carcinoma (most common)",
" HPV 18 → Adenocarcinoma (glandular type)",
"Low-risk strains: HPV 6, 11 → condylomata (benign)",
"HPV is a double-stranded circular DNA virus",
"Viral DNA integrates into host genome",
"Most infections transient; cleared by immune system",
"Only persistent infection leads to carcinoma",
]),{x:0.45,y:1.76,w:4.3,h:3.46,fontFace:"Calibri",valign:"top",margin:[4,0,0,4]});
// Right box
s.addShape(pres.ShapeType.rect,{x:5.1,y:1.3,w:4.55,h:4.0,fill:{color:COL.accent3_tint},line:{color:COL.accent3,pt:1}});
s.addText("Co-Factors in Etiology",{x:5.2,y:1.35,w:4.3,h:0.38,fontSize:14,bold:true,color:COL.accent3,fontFace:"Calibri",margin:0});
s.addText(mkBullets([
"Persistent HPV infection (most critical co-factor)",
"Cigarette smoking (alters local immunity)",
"Immunosuppression (HIV/AIDS, transplant)",
"Long-term oral contraceptive use (>5 years)",
"High parity (≥3 pregnancies)",
"Co-infection with STIs: Chlamydia, HSV-2",
"Uncircumcised male partner",
"Absence of cervical cancer screening",
"Low socioeconomic status",
]),{x:5.2,y:1.76,w:4.3,h:3.46,fontFace:"Calibri",valign:"top",margin:[4,0,0,4]});
}
// ═══ SLIDE 5 — PATHOGENESIS (Molecular) ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Pathogenesis — HPV Molecular Mechanism","E6 and E7 oncoproteins drive malignant transformation");
accentBar(s,1.25,1.85);
const steps=[
{num:"1",title:"HPV Infection",body:"HPV infects immature basal squamous cells of transformation zone via microabrasions during intercourse",color:COL.accent},
{num:"2",title:"Viral Integration",body:"HPV DNA integrates into host genome; disrupts E2 → loss of E2-mediated suppression of E6 and E7 oncoproteins",color:COL.accent3},
{num:"3",title:"E6 Oncoprotein",body:"E6 binds and targets p53 for ubiquitin-mediated degradation → loss of apoptosis → DNA damage accumulates",color:COL.accent2},
{num:"4",title:"E7 Oncoprotein",body:"E7 binds and inactivates pRB → releases E2F transcription factor → uncontrolled cell cycle entry (G1→S)",color:COL.gold},
];
const bW=2.2,bH=1.82,sX=0.35,gap=0.12;
steps.forEach((st,i)=>{
const x=sX+i*(bW+gap);
const tint=[COL.accent_tint,COL.accent3_tint,COL.accent2_tint,COL.gold_tint][i];
s.addShape(pres.ShapeType.rect,{x,y:1.3,w:bW,h:bH,fill:{color:tint},line:{color:st.color,pt:1.5}});
s.addShape(pres.ShapeType.rect,{x,y:1.3,w:bW,h:0.4,fill:{color:st.color},line:{color:st.color}});
s.addText(`${st.num}. ${st.title}`,{x,y:1.3,w:bW,h:0.4,fontSize:12,bold:true,color:COL.white,align:"center",valign:"middle",fontFace:"Calibri",margin:0});
s.addText(st.body,{x:x+0.07,y:1.74,w:bW-0.14,h:1.32,fontSize:11.5,color:COL.text_dark,fontFace:"Calibri",valign:"top",margin:4});
});
s.addShape(pres.ShapeType.rect,{x:0.35,y:3.26,w:9.3,h:0.06,fill:{color:COL.accent},line:{color:COL.accent}});
s.addText("NET OUTCOME:",{x:0.4,y:3.36,w:2.2,h:0.3,fontSize:13,bold:true,color:COL.accent,fontFace:"Calibri",margin:0});
s.addText(mkBullets([
"Immortalization of cervical epithelial cells",
"Accumulation of oncogenic mutations during rapid cellular proliferation → genomic instability",
"HPV infection is NECESSARY but NOT SUFFICIENT — additional host mutations required for full malignant transformation",
]),{x:0.45,y:3.65,w:9.1,h:1.65,fontFace:"Calibri",valign:"top",margin:[4,0,0,4]});
}
// ═══ SLIDE 6 — PATHOGENESIS (Transformation Zone) ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Pathogenesis — The Transformation Zone","Site of origin of virtually all cervical carcinomas");
accentBar(s,1.25,3.9);
s.addText(mkBullets([
"Squamocolumnar junction (SCJ): where columnar endocervical epithelium meets squamous ectocervical epithelium",
"At puberty, under estrogen influence, SCJ undergoes eversion outward to ectocervical surface",
"Exposed columnar cells undergo squamous metaplasia → forms the TRANSFORMATION ZONE (TZ)",
"Immature metaplastic squamous cells in the TZ are MOST SUSCEPTIBLE to HPV infection",
"HPV enters basal cells through microabrasions → productive infection OR latent infection",
"Persistent high-risk HPV → progressive dysplasia → CIN → invasive carcinoma",
"Regression is possible if the immune system clears the virus (most HPV infections are transient)",
"Tumours predominantly arise within this transformation zone (Robbins Basic Pathology)",
]),{x:0.45,y:1.3,w:9.1,h:3.35,fontFace:"Calibri",valign:"top",fontSize:14,margin:[6,0,0,4]});
s.addShape(pres.ShapeType.rect,{x:0.35,y:4.68,w:9.3,h:0.68,fill:{color:COL.accent2_tint},line:{color:COL.accent2,pt:1}});
s.addText("Progression pathway: Normal → HPV Infection → CIN 1 (LSIL) → CIN 2 (HSIL) → CIN 3/CIS (HSIL) → Invasive Carcinoma",
{x:0.45,y:4.7,w:9.1,h:0.64,fontSize:13,bold:true,color:COL.accent2,align:"center",valign:"middle",fontFace:"Calibri",margin:0});
}
// ═══ SLIDE 7 — RISK FACTORS ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Risk Factors","Factors that predispose to cervical intraepithelial neoplasia and invasive carcinoma");
accentBar(s,1.25,3.9);
const groups=[
{heading:"HPV Exposure-Related",items:["Early age at first intercourse (<16 years)","Multiple sexual partners","Partner with multiple prior sexual partners","Persistent infection by high-risk HPV strains","History of other sexually transmitted infections (STIs)"],color:COL.accent,side:"L"},
{heading:"Host / Immunologic Factors",items:["Immunosuppression (HIV/AIDS, organ transplant)","Failure to receive HPV vaccination","Long-term oral contraceptive use (>5 years)"],color:COL.accent3,side:"L"},
{heading:"Behavioural / Environmental",items:["Cigarette smoking (alters local cervical immunity)","High parity (3 or more pregnancies)","Low socioeconomic status / lack of screening"],color:COL.accent2,side:"R"},
{heading:"Male Partner Factors",items:["Uncircumcised partner","Partner with history of HPV-associated penile lesions"],color:COL.gold,side:"R"},
];
let curLY=1.3, curRY=1.3;
groups.forEach(g=>{
const x = g.side==="L" ? 0.35 : 5.1;
const w = 4.55;
let curY = g.side==="L" ? curLY : curRY;
s.addShape(pres.ShapeType.rect,{x,y:curY,w:0.06,h:0.34,fill:{color:g.color},line:{color:g.color}});
s.addText(g.heading,{x:x+0.14,y:curY,w:w-0.18,h:0.34,fontSize:13,bold:true,color:g.color,fontFace:"Calibri",margin:0});
curY+=0.36;
g.items.forEach(item=>{
s.addText([{text:item,options:{bullet:true,breakLine:false}}],{x:x+0.14,y:curY,w:w-0.18,h:0.32,fontSize:13,color:COL.text_dark,fontFace:"Calibri",valign:"middle",margin:[2,0,0,2]});
curY+=0.32;
});
curY+=0.14;
if(g.side==="L") curLY=curY; else curRY=curY;
});
}
// ═══ SLIDE 8 — PRECURSOR LESIONS (CIN/SIL) ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Precursor Lesions: CIN / SIL","Cervical intraepithelial neoplasia — the dysplastic continuum before invasion");
accentBar(s,1.25,0.44);
const cols=["Feature","LSIL / CIN 1","HSIL / CIN 2","HSIL / CIN 3 / CIS"];
const colW=[2.35,2.3,2.3,2.35];
const colC=[COL.accent2,COL.gold,"F5A623",COL.accent];
const colCb=[COL.accent2,COL.gold,COL.accent3,COL.accent];
let tx=0.35;
cols.forEach((c,i)=>{
s.addShape(pres.ShapeType.rect,{x:tx,y:1.28,w:colW[i]-0.04,h:0.44,fill:{color:colCb[i]},line:{color:colCb[i]}});
s.addText(c,{x:tx,y:1.28,w:colW[i]-0.04,h:0.44,fontSize:12,bold:true,color:COL.white,align:"center",valign:"middle",fontFace:"Calibri",margin:0});
tx+=colW[i];
});
const rows=[
["HPV type","Low-risk (6,11) or transient high-risk","High-risk (16,18)","High-risk (16,18,31,33)"],
["Dysplasia extent","Lower 1/3 of epithelium","Lower 2/3 of epithelium","Full-thickness (≥2/3)"],
["Koilocytes","Prominent (cytopathic effect)","Moderate","Rare / absent"],
["Mitotic activity","Basal layer only","Lower 2/3","Throughout all layers"],
["Nuclear atypia","Mild","Moderate","Severe, pleomorphism"],
["Natural history","~60% spontaneous regression","~20% regress; ~5% → invasive","~12% → invasive at 10 yrs if untreated"],
];
rows.forEach((row,ri)=>{
tx=0.35;
const bg=ri%2===0 ? COL.row_alt : COL.white;
row.forEach((cell,ci)=>{
s.addShape(pres.ShapeType.rect,{x:tx,y:1.72+ri*0.62,w:colW[ci]-0.04,h:0.6,fill:{color:bg},line:{color:"CCCCCC",pt:0.5}});
s.addText(cell,{x:tx+0.05,y:1.74+ri*0.62,w:colW[ci]-0.12,h:0.56,fontSize:11.5,color:COL.text_dark,fontFace:"Calibri",valign:"middle",margin:2});
tx+=colW[ci];
});
});
}
// ═══ SLIDE 9 — INVASIVE CARCINOMA TYPES ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Invasive Carcinoma — Histological Types","Morphological types and key microscopic features");
accentBar(s,1.25,3.9);
const cards=[
{title:"Squamous Cell Carcinoma (~80%)",color:COL.accent,tint:COL.accent_tint,pts:["Arises from transformation zone ectocervix","Tongues and nests of squamous cells with desmoplastic stroma","Grading: well-diff (keratin pearls) to poorly-diff","Exophytic, endophytic, or ulcerative macroscopic forms","Barrel cervix: tumour encircles and expands the cervix","Risk of nodal metastasis: <1% if invasion <3mm; >10% if >3mm"]},
{title:"Adenocarcinoma (~15%)",color:COL.accent3,tint:COL.accent3_tint,pts:["Arises from endocervical glandular epithelium","Primarily driven by HPV 18","Proportion increasing (Pap smear misses glandular precursors)","Endocervical (mucinous) type most common","Clear cell, serous, minimal deviation types also occur","May present with no visible ectocervical lesion"]},
{title:"Small Cell Neuroendocrine (<5%)",color:COL.accent2,tint:COL.accent2_tint,pts:["Morphologically similar to small cell carcinoma of lung","Most aggressive type — worst prognosis","Early systemic dissemination at presentation","Positive for neuroendocrine markers (chromogranin, synaptophysin)","Poor response to surgery alone; requires multimodal therapy"]},
];
const cW=3.1, cXs=[0.35,3.5,6.65];
cards.forEach((c,i)=>{
s.addShape(pres.ShapeType.rect,{x:cXs[i],y:1.28,w:cW,h:4.1,fill:{color:c.tint},line:{color:c.color,pt:1.5}});
s.addShape(pres.ShapeType.rect,{x:cXs[i],y:1.28,w:cW,h:0.48,fill:{color:c.color},line:{color:c.color}});
s.addText(c.title,{x:cXs[i]+0.07,y:1.28,w:cW-0.14,h:0.48,fontSize:11.5,bold:true,color:COL.white,fontFace:"Calibri",align:"center",valign:"middle",margin:0});
s.addText(mkBullets(c.pts),{x:cXs[i]+0.1,y:1.8,w:cW-0.2,h:3.5,fontFace:"Calibri",fontSize:12,valign:"top",margin:[4,0,0,2]});
});
}
// ═══ SLIDE 10 — ROUTES OF SPREAD ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"Routes of Spread","Local, lymphatic, haematogenous, and perineural dissemination");
accentBar(s,1.25,3.9);
const routes=[
{title:"1. Direct / Local Extension",color:COL.accent,tint:COL.accent_tint,pts:["MOST COMMON initial route","Superiorly → body of uterus","Inferiorly → vagina","Laterally → parametrium → ureteral obstruction → hydronephrosis (leading cause of death)","Anteriorly → urinary bladder → vesicovaginal fistula","Posteriorly → rectum → rectovaginal fistula","'Barrel cervix' from circumferential tumour growth"]},
{title:"2. Lymphatic Spread",color:COL.accent3,tint:COL.accent3_tint,pts:["Second most common route","1st echelon: Obturator, internal & external iliac, parametrial nodes","2nd echelon: Common iliac nodes","3rd echelon: Para-aortic lymph nodes"," Risk <1% if depth <3 mm; >10% if depth >3 mm"," LVSI (lymphovascular space invasion) is adverse prognostic feature"]},
{title:"3. Haematogenous Spread",color:COL.accent2,tint:COL.accent2_tint,pts:["Occurs mainly in advanced (Stage III/IV) disease","Common distant sites: Lungs, liver, bone","Vascular invasion (LVSI) facilitates haematogenous spread","Associated with poorer prognosis"]},
{title:"4. Transcoelomic / Perineural",color:COL.gold,tint:COL.gold_tint,pts:["Least common routes","Transperitoneal seeding in very advanced disease","Perineural invasion contributes to pelvic and sciatic pain","May involve pelvic side wall structures"]},
];
const rW=4.62, gap=0.06;
const positions=[{x:0.35,y:1.3},{x:0.35+rW+gap,y:1.3},{x:0.35,y:3.28},{x:0.35+rW+gap,y:3.28}];
routes.forEach((r,i)=>{
const {x,y}=positions[i];
const h=1.9;
s.addShape(pres.ShapeType.rect,{x,y,w:rW,h,fill:{color:r.tint},line:{color:r.color,pt:1.5}});
s.addShape(pres.ShapeType.rect,{x,y,w:rW,h:0.38,fill:{color:r.color},line:{color:r.color}});
s.addText(r.title,{x:x+0.08,y,w:rW-0.14,h:0.38,fontSize:12.5,bold:true,color:COL.white,fontFace:"Calibri",valign:"middle",margin:0});
s.addText(mkBullets(r.pts),{x:x+0.1,y:y+0.4,w:rW-0.18,h:h-0.44,fontFace:"Calibri",fontSize:11.5,valign:"top",margin:[3,0,0,2]});
});
}
// ═══ SLIDE 11 — FIGO STAGING ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_light},line:{color:COL.bg_light}});
headerBand(s,"FIGO Staging (2018)","Staging determines treatment plan and prognosis");
accentBar(s,1.25,3.9);
const stages=[
["Stage I","Confined to cervix uteri",COL.gold,true],
[" IA","Microscopic invasion; maximum depth 5 mm",COL.gold,false],
[" IB","Clinically visible lesion or microscopic >5 mm, confined to cervix",COL.gold,false],
["Stage II","Beyond cervix but not pelvic wall / lower 1/3 vagina",COL.accent3,true],
[" IIA","Without parametrial invasion (upper 2/3 vagina involved)",COL.accent3,false],
[" IIB","With parametrial invasion",COL.accent3,false],
["Stage III","Pelvic wall / lower 1/3 vagina / hydronephrosis or non-functioning kidney",COL.accent2,true],
["Stage IV","Beyond true pelvis: IVA = bladder/rectum; IVB = distant metastasis",COL.accent,true],
];
stages.forEach((st,i)=>{
const isMain=st[3];
s.addShape(pres.ShapeType.rect,{x:0.35,y:1.3+i*0.52,w:2.1,h:0.5,fill:{color:st[2]},line:{color:st[2]}});
s.addText(st[0],{x:0.35,y:1.3+i*0.52,w:2.1,h:0.5,fontSize:isMain?13:12,bold:isMain,color:COL.white,align:"center",valign:"middle",fontFace:"Calibri",margin:0});
s.addShape(pres.ShapeType.rect,{x:2.48,y:1.3+i*0.52,w:7.17,h:0.5,fill:{color:isMain?COL.row_alt:COL.white},line:{color:"CCCCCC",pt:0.5}});
s.addText(st[1],{x:2.57,y:1.32+i*0.52,w:7.0,h:0.46,fontSize:12.5,color:COL.text_dark,fontFace:"Calibri",valign:"middle",margin:2});
});
s.addText("5-year survival: Stage I ~90% | Stage II ~65% | Stage III ~35% | Stage IV <15%",{
x:0.35,y:5.28,w:9.3,h:0.28,fontSize:11,bold:true,color:COL.accent,fontFace:"Calibri",align:"center",margin:0
});
}
// ═══ SLIDE 12 — SUMMARY ═══
{
const s=pres.addSlide();
s.addShape(pres.ShapeType.rect,{x:0,y:0,w:10,h:5.625,fill:{color:COL.bg_dark},line:{color:COL.bg_dark}});
s.addShape(pres.ShapeType.rect,{x:0,y:1.05,w:10,h:0.06,fill:{color:COL.accent},line:{color:COL.accent}});
s.addText("Key Takeaways",{x:0.4,y:0.1,w:9.2,h:0.9,fontSize:30,bold:true,color:COL.white,fontFace:"Calibri",valign:"middle",margin:0});
const pts=[
["HPV is the cause","Virtually all cervical carcinomas caused by high-risk HPV (16,18). E6 degrades p53; E7 inactivates pRB."],
["Transformation zone","Squamocolumnar junction/TZ is the origin of virtually all cervical tumours due to susceptible immature metaplastic cells."],
["Precursor lesions","CIN 1 (LSIL) → CIN 2 → CIN 3 (HSIL/CIS) is a progressive dysplastic continuum; HSIL can progress to invasive ca over 10–15 years."],
["Histologic types","SCC ~80%, Adenocarcinoma ~15%, Small cell neuroendocrine <5% (most aggressive)."],
["Routes of spread","Direct extension (commonest; hydronephrosis = leading cause of death) → lymphatic → haematogenous → perineural."],
["Staging & survival","FIGO stage at diagnosis is the key prognostic determinant. Hydronephrosis alone upstages to Stage III."],
];
pts.forEach(([h,b],i)=>{
const y=1.18+i*0.72;
s.addShape(pres.ShapeType.rect,{x:0.3,y:y+0.05,w:0.08,h:0.5,fill:{color:COL.accent},line:{color:COL.accent}});
s.addText(h+":",{x:0.5,y,w:2.1,h:0.6,fontSize:13,bold:true,color:COL.gold,fontFace:"Calibri",valign:"middle",margin:0});
s.addText(b,{x:2.55,y,w:7.1,h:0.6,fontSize:12.5,color:COL.text_light,fontFace:"Calibri",valign:"middle",margin:0});
});
s.addText("Source: Robbins & Kumar Basic Pathology • Robbins Pathologic Basis of Disease • Harrison's Principles of Internal Medicine (22E)",{
x:0,y:5.32,w:10,h:0.26,fontSize:8,color:"888888",fontFace:"Calibri",align:"center",margin:0
});
}
// WRITE
pres.writeFile({fileName:"/home/daytona/workspace/cervix-ca-ppt/Carcinoma_of_the_Cervix.pptx"})
.then(()=>console.log("✅ Done: Carcinoma_of_the_Cervix.pptx"))
.catch(e=>{console.error("ERROR:",e);process.exit(1);});
cd /home/daytona/workspace/cervix-ca-ppt && node cervix_ca2.js 2>&1
ls -lh /home/daytona/workspace/cervix-ca-ppt/Carcinoma_of_the_Cervix.pptx
Carcinoma of the Cervix
Presentation · PPTX
| Slide | Content |
|---|---|
| 1 | Title slide — full topic and author info |
| 2 | Lecture outline (numbered, color-coded) |
| 3 | Definition — what cervical carcinoma is + key epidemiological facts |
| 4 | Etiology — HPV as the primary cause; high-risk vs. low-risk strains; co-factors |
| 5 | Pathogenesis (Molecular) — HPV integration, E6/p53 pathway, E7/pRB pathway, step-by-step boxes |
| 6 | Pathogenesis (Transformation Zone) — squamocolumnar junction, metaplasia, progression timeline |
| 7 | Risk Factors — four color-coded groups (HPV-exposure, immunologic, behavioural, partner-related) |
| 8 | Precursor Lesions (CIN/SIL) — full comparison table: CIN 1 vs. CIN 2 vs. CIN 3/CIS |
| 9 | Invasive Carcinoma types — SCC (~80%), Adenocarcinoma (~15%), Small Cell NEC (<5%) |
| 10 | Routes of Spread — four quadrant cards: direct extension, lymphatic, haematogenous, perineural |
| 11 | FIGO Staging (2018) — all stages with descriptions + 5-year survival rates |
| 12 | Key Takeaways summary (dark background) |