Drug drug interactions presentation for ug mbbs for 2 hour make ppt and mcq exercise

Reading File
Reading File
Reading File
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Reading File
Reading File
Finding Sources
Reading File
Finding Sources
Finding Sources
Reading File
Finding Sources
Reading File
Finding Sources
Running Command

mkdir -p /home/daytona/workspace/ddi-presentation && ls /home/daytona/workspace/ddi-presentation/

Writing File

~/ddi-presentation/create_ddi_ppt.js

const pptxgen = require("pptxgenjs");

const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.author = "Pharmacology Department";
pres.title = "Drug-Drug Interactions";

// ─── THEME ────────────────────────────────────────────────────────────────────
const C = {
  navy:    "0D2B55",  // dominant dark navy
  teal:    "007F8C",  // supporting teal
  amber:   "F4A022",  // accent amber
  white:   "FFFFFF",
  light:   "E8F4F8",
  muted:   "8FB0C0",
  red:     "C0392B",
  green:   "1A7A4A",
  orange:  "E67E22",
  text:    "1A2A3A",
};

const FF = "Calibri";

// ─── HELPER FUNCTIONS ─────────────────────────────────────────────────────────

function addTitleSlide(pres) {
  const sl = pres.addSlide();
  // Full-bleed background
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.navy } });
  // Accent stripe
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 4.2, w: 10, h: 0.18, fill: { color: C.amber } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 4.4, w: 10, h: 0.08, fill: { color: C.teal } });
  // Main title
  sl.addText("Drug–Drug Interactions", {
    x: 0.6, y: 0.7, w: 8.8, h: 1.4,
    fontSize: 46, bold: true, color: C.white, fontFace: FF,
    align: "center", valign: "middle",
  });
  // Subtitle
  sl.addText("A Comprehensive Lecture for Undergraduate MBBS", {
    x: 0.6, y: 2.2, w: 8.8, h: 0.6,
    fontSize: 20, color: C.amber, fontFace: FF,
    align: "center", italic: true,
  });
  // Details
  sl.addText("Department of Pharmacology  |  2-Hour Lecture Session  |  May 2026", {
    x: 0.6, y: 3.0, w: 8.8, h: 0.45,
    fontSize: 14, color: C.muted, fontFace: FF, align: "center",
  });
  // Bottom note
  sl.addText("Sources: Goodman & Gilman • Lippincott Pharmacology • Katzung • Tintinalli's EM", {
    x: 0.6, y: 4.8, w: 8.8, h: 0.35,
    fontSize: 10, color: C.muted, fontFace: FF, align: "center", italic: true,
  });
}

function addSectionDivider(pres, sectionNum, title, subtitle) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.teal } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 0.45, h: 5.625, fill: { color: C.amber } });
  sl.addText(`SECTION ${sectionNum}`, {
    x: 0.8, y: 1.0, w: 8.5, h: 0.55,
    fontSize: 18, color: C.amber, fontFace: FF, bold: true, charSpacing: 6,
  });
  sl.addText(title, {
    x: 0.8, y: 1.6, w: 8.5, h: 1.4,
    fontSize: 38, bold: true, color: C.white, fontFace: FF, valign: "middle",
  });
  if (subtitle) {
    sl.addText(subtitle, {
      x: 0.8, y: 3.1, w: 8.5, h: 0.7,
      fontSize: 18, color: C.light, fontFace: FF, italic: true,
    });
  }
}

function addContentSlide(pres, title, bullets, opts = {}) {
  const sl = pres.addSlide();
  // Top banner
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.85, fill: { color: C.navy } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0.85, w: 10, h: 0.06, fill: { color: C.amber } });
  sl.addText(title, {
    x: 0.3, y: 0, w: 9.4, h: 0.85,
    fontSize: 22, bold: true, color: C.white, fontFace: FF, valign: "middle",
  });
  // Bullets
  const items = bullets.map((b, i) => ({
    text: b.text || b,
    options: {
      bullet: b.sub ? { type: "number", indent: 30 } : { indent: 10 },
      fontSize: b.sub ? 14 : (opts.fontSize || 16),
      color: b.color || C.text,
      bold: b.bold || false,
      italic: b.italic || false,
      breakLine: true,
      indentLevel: b.sub ? 1 : 0,
    },
  }));
  // ensure last has no breakLine
  if (items.length > 0) items[items.length - 1].options.breakLine = false;

  sl.addText(items, {
    x: 0.3, y: 1.1, w: 9.4, h: 4.2,
    fontFace: FF, valign: "top",
    lineSpacingMultiple: 1.2,
  });
  if (opts.source) {
    sl.addText(opts.source, {
      x: 0.3, y: 5.25, w: 9.4, h: 0.3,
      fontSize: 9, color: C.muted, fontFace: FF, italic: true,
    });
  }
  return sl;
}

function addTwoColumnSlide(pres, title, col1Title, col1Items, col2Title, col2Items, opts = {}) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.85, fill: { color: C.navy } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0.85, w: 10, h: 0.06, fill: { color: C.amber } });
  sl.addText(title, {
    x: 0.3, y: 0, w: 9.4, h: 0.85,
    fontSize: 22, bold: true, color: C.white, fontFace: FF, valign: "middle",
  });
  // Col 1 header
  sl.addShape(pres.ShapeType.rect, { x: 0.3, y: 1.05, w: 4.3, h: 0.45, fill: { color: C.teal } });
  sl.addText(col1Title, { x: 0.3, y: 1.05, w: 4.3, h: 0.45, fontSize: 14, bold: true, color: C.white, fontFace: FF, align: "center", valign: "middle" });
  // Col 2 header
  sl.addShape(pres.ShapeType.rect, { x: 5.3, y: 1.05, w: 4.4, h: 0.45, fill: { color: C.orange } });
  sl.addText(col2Title, { x: 5.3, y: 1.05, w: 4.4, h: 0.45, fontSize: 14, bold: true, color: C.white, fontFace: FF, align: "center", valign: "middle" });

  const makeItems = (arr) => arr.map((b, i) => ({
    text: b.text || b,
    options: {
      bullet: { indent: 10 },
      fontSize: opts.fontSize || 14,
      color: b.color || C.text,
      bold: b.bold || false,
      breakLine: i < arr.length - 1,
    },
  }));
  sl.addText(makeItems(col1Items), { x: 0.3, y: 1.6, w: 4.3, h: 3.7, fontFace: FF, valign: "top", lineSpacingMultiple: 1.25 });
  sl.addText(makeItems(col2Items), { x: 5.3, y: 1.6, w: 4.4, h: 3.7, fontFace: FF, valign: "top", lineSpacingMultiple: 1.25 });
  // Divider line
  sl.addShape(pres.ShapeType.line, { x: 4.75, y: 1.1, w: 0, h: 4.2, line: { color: C.muted, width: 1.5, dashType: "dash" } });
  return sl;
}

function addTableSlide(pres, title, headers, rows, opts = {}) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.85, fill: { color: C.navy } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0.85, w: 10, h: 0.06, fill: { color: C.amber } });
  sl.addText(title, {
    x: 0.3, y: 0, w: 9.4, h: 0.85,
    fontSize: 21, bold: true, color: C.white, fontFace: FF, valign: "middle",
  });
  const tableRows = [
    headers.map(h => ({ text: h, options: { bold: true, color: C.white, fill: C.teal, align: "center", fontSize: 12 } })),
    ...rows.map((row, ri) => row.map(cell => ({
      text: cell,
      options: { fontSize: 11, color: C.text, fill: ri % 2 === 0 ? C.light : C.white, align: "center" },
    }))),
  ];
  sl.addTable(tableRows, {
    x: 0.25, y: 1.05, w: 9.5, h: 4.4,
    fontFace: FF,
    border: { type: "solid", color: C.muted, pt: 0.5 },
    rowH: opts.rowH || 0.45,
  });
  return sl;
}

function addHighlightBox(pres, title, mainText, bgColor, textColor, note) {
  const sl = pres.addSlide();
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: bgColor } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.06, fill: { color: C.amber } });
  sl.addShape(pres.ShapeType.rect, { x: 0, y: 5.555, w: 10, h: 0.07, fill: { color: C.amber } });
  sl.addText("⚠  CLINICAL ALERT", {
    x: 0.5, y: 0.3, w: 9, h: 0.5,
    fontSize: 16, bold: true, color: C.amber, fontFace: FF, align: "center", charSpacing: 4,
  });
  sl.addText(title, {
    x: 0.5, y: 0.9, w: 9, h: 0.8,
    fontSize: 30, bold: true, color: textColor, fontFace: FF, align: "center",
  });
  sl.addText(mainText, {
    x: 0.8, y: 1.8, w: 8.4, h: 2.8,
    fontSize: 16, color: textColor, fontFace: FF, align: "left", valign: "top",
    lineSpacingMultiple: 1.4,
  });
  if (note) {
    sl.addText(note, {
      x: 0.5, y: 5.0, w: 9, h: 0.4,
      fontSize: 10, color: C.amber, fontFace: FF, italic: true, align: "center",
    });
  }
}

// ═══════════════════════════════════════════════════════════════════════════════
//  SLIDES
// ═══════════════════════════════════════════════════════════════════════════════

// 1. Title
addTitleSlide(pres);

// 2. Learning Objectives
addContentSlide(pres, "Learning Objectives", [
  { text: "Define drug–drug interactions (DDIs) and classify them", bold: false },
  { text: "Explain pharmacokinetic mechanisms: ADME-based interactions", bold: false },
  { text: "Describe pharmacodynamic interactions: synergism, antagonism, additive effects", bold: false },
  { text: "Identify high-risk drug combinations encountered in clinical practice", bold: false },
  { text: "Recognise classic DDI toxidromes: serotonin syndrome, QTc prolongation, bleeding", bold: false },
  { text: "Apply strategies to predict, prevent, and manage DDIs", bold: false },
  { text: "Interpret CYP450 substrate/inhibitor/inducer tables", bold: false },
], { source: "Session Duration: 2 Hours | Theory + MCQ Exercise" });

// 3. Session Outline
addContentSlide(pres, "Session Outline (2 Hours)", [
  { text: "Section 1 — Introduction & Definitions (15 min)", bold: true, color: C.teal },
  { text: "Section 2 — Pharmacokinetic DDIs: Absorption & Distribution (20 min)", bold: true, color: C.teal },
  { text: "Section 3 — Pharmacokinetic DDIs: Metabolism — CYP450 (25 min)", bold: true, color: C.teal },
  { text: "Section 4 — Pharmacokinetic DDIs: Excretion (10 min)", bold: true, color: C.teal },
  { text: "Section 5 — Pharmacodynamic DDIs (20 min)", bold: true, color: C.teal },
  { text: "Section 6 — Clinically Important DDI Examples (20 min)", bold: true, color: C.teal },
  { text: "Section 7 — Prevention & Management (10 min)", bold: true, color: C.teal },
  { text: "MCQ Exercise — 20 Questions (20 min)", bold: true, color: C.amber },
]);

// ─── SECTION 1 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 1, "Introduction & Definitions", "Understanding the scope and significance of DDIs");

// 4. What is a DDI?
addContentSlide(pres, "What is a Drug–Drug Interaction (DDI)?", [
  { text: "A DDI is an in vivo phenomenon that occurs when administration of one drug alters the effects or kinetics of another drug (Miller's Anesthesia, 10e)", bold: false },
  { text: "In vitro physical/chemical incompatibilities are NOT considered DDIs", bold: false, color: C.red },
  { text: "Result: Increased efficacy, decreased efficacy, or enhanced toxicity", bold: false },
  { text: "DDIs are one of the most preventable causes of adverse drug events", bold: true, color: C.teal },
  { text: "Incidence: Up to 30% of hospitalised patients experience a clinically relevant DDI", bold: false },
  { text: "High-risk groups: Elderly, polypharmacy patients, narrow therapeutic index drugs", bold: false },
], { source: "Sources: Miller's Anesthesia 10e; Goodman & Gilman's Pharmacological Basis of Therapeutics" });

// 5. Classification Overview
addTwoColumnSlide(pres,
  "Classification of Drug–Drug Interactions",
  "PHARMACOKINETIC DDIs",
  [
    "One drug alters ADME of another",
    "Absorption-based interactions",
    "Distribution (protein binding) interactions",
    "Metabolism (CYP450) interactions — most common",
    "Excretion (renal/biliary) interactions",
    "Predictable using PK principles",
  ],
  "PHARMACODYNAMIC DDIs",
  [
    "Drugs act on same receptor/target",
    "Additive effects (1+1 = 2)",
    "Synergistic effects (1+1 > 2)",
    "Antagonistic effects (1+1 < 2 or 0)",
    "Independent/summative effects",
    "Examples: CNS depression, QTc prolongation",
  ]
);

// 6. Outcomes of DDIs
addContentSlide(pres, "Possible Outcomes of DDIs", [
  { text: "THERAPEUTIC BENEFIT — Intentional combinations for enhanced efficacy:", bold: true, color: C.green },
  { text: "Co-trimoxazole (trimethoprim + sulfamethoxazole) — synergistic antibacterial", bold: false, sub: true },
  { text: "Levodopa + carbidopa — blocks peripheral DOPA decarboxylase, increases CNS levodopa", bold: false, sub: true },
  { text: "HIV triple therapy — prevents resistance", bold: false, sub: true },
  { text: "HARMFUL EFFECTS — Unintentional, potentially dangerous:", bold: true, color: C.red },
  { text: "Increased toxicity (e.g., warfarin + NSAIDs → GI bleed)", bold: false, sub: true },
  { text: "Decreased efficacy (e.g., rifampicin + OCP → contraceptive failure)", bold: false, sub: true },
  { text: "Life-threatening reactions (e.g., MAOI + meperidine → serotonin syndrome)", bold: false, sub: true },
], { source: "Source: Lippincott Illustrated Reviews Pharmacology; Katzung Basic & Clinical Pharmacology 16e" });

// ─── SECTION 2 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 2, "Pharmacokinetic DDIs\nAbsorption & Distribution", "How drugs interfere with each other's entry and spread in the body");

// 7. Absorption DDIs
addContentSlide(pres, "Absorption-Based DDIs", [
  { text: "1. Chelation / Complex Formation", bold: true, color: C.teal },
  { text: "Antacids (Ca²⁺, Mg²⁺, Al³⁺) + tetracyclines/fluoroquinolones → insoluble chelates → ↓ absorption", sub: true },
  { text: "Iron salts + tetracyclines / levodopa → chelation → ↓ absorption", sub: true },
  { text: "Rule: Separate administration by ≥ 2 hours", sub: true, bold: true },
  { text: "2. Altered Gastric pH", bold: true, color: C.teal },
  { text: "PPIs / H2 blockers → ↑ gastric pH → ↓ absorption of ketoconazole, itraconazole, atazanavir", sub: true },
  { text: "Omeprazole: potent inhibitor of CYP isozymes involved in warfarin metabolism → ↑ warfarin effect", sub: true },
  { text: "3. Altered GI Motility", bold: true, color: C.teal },
  { text: "Metoclopramide → ↑ gastric emptying → ↑ paracetamol absorption (faster onset)", sub: true },
  { text: "Anticholinergics → ↓ motility → ↓ absorption of drugs from intestine", sub: true },
  { text: "4. Adsorption", bold: true, color: C.teal },
  { text: "Cholestyramine binds digoxin, warfarin, thyroid hormones → ↓ absorption", sub: true },
], { source: "Sources: Lippincott Pharmacology; Goodman & Gilman's; Tintinalli's Emergency Medicine" });

// 8. Distribution DDIs
addContentSlide(pres, "Distribution-Based DDIs — Protein Binding Displacement", [
  { text: "Most drugs are bound to plasma proteins (mainly albumin)", bold: false },
  { text: "Only FREE (unbound) drug is pharmacologically active", bold: true, color: C.teal },
  { text: "Displacement interaction: Drug A displaces Drug B from protein → ↑ free Drug B", bold: false },
  { text: "CLASSIC EXAMPLE:", bold: true, color: C.amber },
  { text: "Warfarin (99% protein-bound) displaced by NSAIDs, sulfonamides, valproate → ↑ free warfarin → ↑ bleeding risk", sub: true },
  { text: "Sulfonamides displace bilirubin from albumin in neonates → kernicterus", sub: true, color: C.red },
  { text: "CLINICAL NOTE:", bold: true, color: C.teal },
  { text: "Effect is usually transient — compensated by increased clearance", sub: true },
  { text: "Most significant for drugs with: Narrow TI, high protein binding (>90%), low Vd, impaired elimination", sub: true },
  { text: "P-GLYCOPROTEIN (P-gp) transporter interactions also affect distribution:", bold: true, color: C.teal },
  { text: "Digoxin is a P-gp substrate; clarithromycin/verapamil inhibit P-gp → ↑ digoxin levels → toxicity", sub: true },
], { source: "Source: Goodman & Gilman's Pharmacological Basis of Therapeutics; Lippincott Pharmacology" });

// ─── SECTION 3 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 3, "Pharmacokinetic DDIs\nMetabolism & CYP450", "The most important and clinically relevant mechanism");

// 9. CYP450 Overview
addContentSlide(pres, "Cytochrome P450 — The Key Metabolic Machinery", [
  { text: "CYP450 enzymes are located primarily in liver (also intestine, lung, kidney, placenta)", bold: false },
  { text: "CYP3A4: metabolises ~50% of all drugs in clinical use; most abundant hepatic CYP", bold: true, color: C.teal },
  { text: "Other key isoforms: CYP2D6, CYP1A2, CYP2C9, CYP2C19, CYP2E1", bold: false },
  { text: "Two mechanisms of metabolic DDIs:", bold: true, color: C.amber },
  { text: "INHIBITION — competitor blocks enzyme → ↓ metabolism of substrate → ↑ plasma level → toxicity", sub: true, color: C.red },
  { text: "INDUCTION — inducer ↑ enzyme synthesis → ↑ metabolism of substrate → ↓ plasma level → therapeutic failure", sub: true, color: C.orange },
  { text: "Inhibition: rapid onset (hours); Induction: delayed onset (days to weeks)", bold: false },
  { text: "Significant interindividual variability — up to 20-fold in CYP3A4 activity (Dermatology 5e)", bold: false },
  { text: "Genetic polymorphisms add further complexity (poor vs ultrarapid metabolisers)", bold: false },
], { source: "Sources: Dermatology 2-Vol Set 5e; Lippincott Pharmacology; Goodman & Gilman's" });

// 10. CYP Isozyme Table
addTableSlide(pres,
  "Key CYP450 Isozymes — Substrates, Inhibitors, Inducers",
  ["Isozyme", "Key Substrates", "Inhibitors", "Inducers"],
  [
    ["CYP3A4/5", "Cyclosporine, simvastatin, nifedipine, erythromycin, carbamazepine, HIV protease inhibitors", "Ketoconazole, ritonavir, clarithromycin, diltiazem, grapefruit juice", "Rifampicin, phenytoin, phenobarbitone, carbamazepine, dexamethasone"],
    ["CYP2D6", "Fluoxetine, haloperidol, paroxetine, propranolol, tramadol, codeine", "Fluoxetine, paroxetine, amiodarone, quinidine", "None significant (not inducible)"],
    ["CYP1A2", "Theophylline, caffeine, clozapine, warfarin (R)", "Fluvoxamine, ciprofloxacin, cimetidine", "Rifampicin, smoking, omeprazole"],
    ["CYP2C9", "Warfarin (S), phenytoin, NSAIDs (celecoxib), glipizide", "Fluconazole, amiodarone, valproate", "Rifampicin, carbamazepine"],
    ["CYP2C19", "Omeprazole, diazepam, clopidogrel (prodrug), citalopram", "Fluoxetine, fluvoxamine, esomeprazole", "Rifampicin, carbamazepine"],
  ],
  { rowH: 0.62 }
);

// 11. Enzyme Inhibition — Key Examples
addContentSlide(pres, "Enzyme Inhibition — Clinically Important Examples", [
  { text: "KETOCONAZOLE / ITRACONAZOLE + STATINS (simvastatin, atorvastatin):", bold: true, color: C.red },
  { text: "CYP3A4 inhibition → ↑ statin levels → risk of rhabdomyolysis (avoid co-use)", sub: true },
  { text: "CLARITHROMYCIN / ERYTHROMYCIN + DIGOXIN:", bold: true, color: C.red },
  { text: "CYP3A4 + P-gp inhibition → ↑ digoxin → arrhythmias, toxicity", sub: true },
  { text: "OMEPRAZOLE + WARFARIN:", bold: true, color: C.orange },
  { text: "Omeprazole inhibits CYP isozymes metabolising warfarin → ↑ warfarin → ↑ bleeding risk (Lippincott)", sub: true },
  { text: "CLOPIDOGREL + PPIs (especially omeprazole):", bold: true, color: C.red },
  { text: "Clopidogrel requires CYP2C19 for activation (prodrug); PPI inhibits CYP2C19 → ↓ active metabolite → ↓ antiplatelet effect (Lippincott, p. Clinical App 42.1)", sub: true },
  { text: "RITONAVIR (HIV): the 'boosting' agent — potent CYP3A4 inhibitor → used intentionally to boost levels of other antiretrovirals (lopinavir/r)", bold: false, color: C.green },
], { source: "Sources: Lippincott Pharmacology; Tintinalli's EM; Goodman & Gilman's; Fuster & Hurst's The Heart 15e" });

// 12. Enzyme Induction
addContentSlide(pres, "Enzyme Induction — Clinically Important Examples", [
  { text: "RIFAMPICIN — the classic 'super-inducer' (CYP3A4, CYP2C9, CYP1A2):", bold: true, color: C.orange },
  { text: "Rifampicin + OCP → ↑ oestrogen metabolism → contraceptive failure (unintended pregnancy)", sub: true, color: C.red },
  { text: "Rifampicin + warfarin → ↑ warfarin metabolism → subtherapeutic anticoagulation, thrombosis", sub: true },
  { text: "Rifampicin + cyclosporine → transplant rejection due to ↓ cyclosporine levels", sub: true },
  { text: "Rifampicin + HIV protease inhibitors → ↓ drug levels → treatment failure", sub: true },
  { text: "CARBAMAZEPINE / PHENYTOIN / PHENOBARBITONE (Antiepileptics):", bold: true, color: C.orange },
  { text: "Induce CYP3A4 → reduce levels of: corticosteroids, OCPs, cyclosporine, statins, warfarin", sub: true },
  { text: "GRAPEFRUIT JUICE — unique inhibitor:", bold: true, color: C.teal },
  { text: "Irreversibly inhibits intestinal CYP3A4 → ↑ bioavailability of: simvastatin, nifedipine, cyclosporine", sub: true },
  { text: "Effect lasts 24–72 hours after ingestion; avoid with statin/CCB therapy", sub: true },
], { source: "Sources: Lippincott Pharmacology; Dermatology 2-Vol 5e; Goodman & Gilman's" });

// 13. The 'CRACK MEPS' mnemonic
addContentSlide(pres, "Memory Aid — CYP3A4 Inducers: \"PC BRAS\"", [
  { text: "Phenytoin", bold: true, color: C.amber },
  { text: "Carbamazepine", bold: true, color: C.amber },
  { text: "Barbiturates (phenobarbitone)", bold: true, color: C.amber },
  { text: "Rifampicin", bold: true, color: C.amber },
  { text: "Alcohol (chronic)", bold: true, color: C.amber },
  { text: "Smoking (CYP1A2)", bold: true, color: C.amber },
  { text: "─────────────────────────────────────────────────────────────────────", bold: false, color: C.muted },
  { text: "CYP3A4 Inhibitors — \"CRACK\":", bold: true, color: C.teal },
  { text: "Cimetidine, Ritonavir, Azole antifungals, Clarithromycin/erythromycin, Ketoconazole (+ grapefruit juice)", bold: false, color: C.teal },
  { text: "Key: Inhibitors → drug toxicity | Inducers → therapeutic failure", bold: true, color: C.red },
], { source: "Mnemonic aids for undergraduate exam preparation" });

// ─── SECTION 4 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 4, "Pharmacokinetic DDIs\nExcretion", "Renal and biliary clearance interactions");

// 14. Excretion DDIs
addContentSlide(pres, "Excretion-Based DDIs — Renal Mechanisms", [
  { text: "Renal drug excretion involves: Glomerular filtration + Active tubular secretion + Tubular reabsorption", bold: false },
  { text: "1. Competition for Tubular Secretion (OAT/OCT transporters):", bold: true, color: C.teal },
  { text: "Classic: Probenecid + penicillin → blocks tubular secretion of penicillin → prolonged penicillin effect (historical 'intentional' interaction)", sub: true },
  { text: "Methotrexate + NSAIDs → NSAIDs reduce renal blood flow AND compete for tubular secretion → ↑ methotrexate toxicity (myelosuppression, mucositis)", sub: true, color: C.red },
  { text: "2. Alteration of Urine pH:", bold: true, color: C.teal },
  { text: "Alkaline urine: ↑ excretion of acidic drugs (aspirin, barbiturates) — used in overdose management", sub: true },
  { text: "Acid urine: ↑ excretion of basic drugs (amphetamines)", sub: true },
  { text: "3. NSAIDs reduce renal prostaglandin synthesis → ↓ GFR → ↑ lithium, metformin, methotrexate levels", bold: true, color: C.red },
  { text: "Lithium + NSAIDs/thiazides → ↑ lithium reabsorption → lithium toxicity (tremor, confusion, cardiac arrhythmias)", sub: true },
], { source: "Sources: Tintinalli's EM 2e; Goodman & Gilman's; Lippincott Pharmacology" });

// ─── SECTION 5 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 5, "Pharmacodynamic DDIs", "Interactions at the site of drug action");

// 15. PD DDI Types
addContentSlide(pres, "Pharmacodynamic DDIs — Classification", [
  { text: "ADDITIVE EFFECT (1 + 1 = 2):", bold: true, color: C.teal },
  { text: "Two drugs with similar effects produce combined effect equal to sum of individual effects", sub: true },
  { text: "Example: Two CNS depressants (alcohol + benzodiazepine) → additive CNS depression", sub: true },
  { text: "SYNERGISM (1 + 1 > 2):", bold: true, color: C.green },
  { text: "Combined effect exceeds sum of individual effects", sub: true },
  { text: "Example: Co-trimoxazole (trimethoprim blocks DHFR, sulfonamide blocks PABA → folate synthesis blocked at 2 steps)", sub: true },
  { text: "Example: β-lactam + aminoglycoside → synergistic bactericidal effect", sub: true },
  { text: "POTENTIATION:", bold: true, color: C.green },
  { text: "One drug has no effect alone but enhances effect of another (1+0 > 1)", sub: true },
  { text: "ANTAGONISM (1 + 1 < 1 or = 0):", bold: true, color: C.red },
  { text: "One drug reduces effect of another", sub: true },
  { text: "Examples: Naloxone reverses opioid effect; flumazenil reverses benzodiazepine effect (competitive antagonism)", sub: true },
  { text: "Physiological antagonism: Adrenaline reverses anaphylaxis caused by histamine/allergens", sub: true },
], { source: "Source: Goodman & Gilman's Pharmacological Basis of Therapeutics" });

// 16. QTc Prolongation
addContentSlide(pres, "QTc Prolongation — A Critical PD Interaction", [
  { text: "QTc prolongation: Combined use of two QT-prolonging drugs → greater risk of Torsades de Pointes (TdP) polymorphic VT → sudden death", bold: false, color: C.red },
  { text: "Mechanism: Additive/synergistic blockade of IKr (hERG) potassium channels", bold: false },
  { text: "HIGH-RISK COMBINATIONS:", bold: true, color: C.red },
  { text: "Antipsychotics (haloperidol, quetiapine) + antibiotics (azithromycin, moxifloxacin)", sub: true },
  { text: "Methadone + fluoroquinolones", sub: true },
  { text: "Antiarrhythmics (amiodarone, sotalol) + any other QT-prolonging drug", sub: true },
  { text: "Ondansetron + antipsychotics", sub: true },
  { text: "Risk factors that amplify danger: Hypokalaemia, hypomagnesaemia, bradycardia, female sex, heart disease", bold: false },
  { text: "MANAGEMENT:", bold: true, color: C.teal },
  { text: "Avoid combinations where possible; monitor ECG; correct electrolytes; check CredibleMeds database", sub: true },
], { source: "Sources: Goodman & Gilman's; Fuster & Hurst's The Heart 15e" });

// ─── SECTION 6 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 6, "Clinically Important DDI Examples", "High-yield interactions for clinical practice");

// 17. Serotonin Syndrome
addHighlightBox(pres,
  "Serotonin Syndrome",
  "MECHANISM: Excess serotonergic activity in the CNS at 5-HT1A and 5-HT2A receptors\n\nCLASSIC TRIAD:\n• Mental status changes (agitation, confusion)\n• Autonomic hyperactivity (hyperthermia, tachycardia, diaphoresis)\n• Neuromuscular abnormalities (clonus, hyperreflexia, tremor)\n\nDEADLY COMBINATIONS:\n• MAOI + SSRIs/SNRIs → most dangerous — CONTRAINDICATED (Goodman & Gilman's)\n• MAOI + Meperidine (pethidine) → serotonin syndrome (Barash Clinical Anesthesia)\n• MAOI + Tramadol, tryptophan, fentanyl\n• Linezolid (has MAOI activity) + SSRIs\n\nWASHOUT: 14 days after stopping MAOI before starting SSRI; 5 weeks for fluoxetine",
  C.navy,
  C.white,
  "Source: Goodman & Gilman's; Barash Clinical Anesthesia 9e; Katzung 16e"
);

// 18. Warfarin Interactions
addContentSlide(pres, "Warfarin — The Prototypical High-Risk Drug", [
  { text: "Warfarin has a NARROW THERAPEUTIC INDEX → small changes in levels cause bleeding or thrombosis", bold: true, color: C.red },
  { text: "DRUGS THAT ↑ WARFARIN EFFECT (↑ bleeding risk):", bold: true, color: C.red },
  { text: "Amiodarone — CYP2C9 inhibitor → ↑ warfarin (monitor INR carefully)", sub: true },
  { text: "Azole antifungals (fluconazole) — CYP2C9 inhibitor", sub: true },
  { text: "Fluvoxamine — inhibits CYP1A2, CYP2C19, CYP3A4 → ↑ both R and S warfarin (Kaplan Sadock Psychiatry)", sub: true },
  { text: "NSAIDs — platelet inhibition + GI mucosal damage + protein displacement", sub: true },
  { text: "Antibiotics — ↓ intestinal Vit K synthesis → ↑ warfarin effect", sub: true },
  { text: "DRUGS THAT ↓ WARFARIN EFFECT (↑ thrombosis risk):", bold: true, color: C.orange },
  { text: "Rifampicin — potent CYP inducer → ↑ warfarin metabolism → subtherapeutic INR", sub: true },
  { text: "Carbamazepine, phenytoin, phenobarbitone — CYP inducers", sub: true },
  { text: "FOOD: Vitamin K-rich foods (green leafy vegetables) ↓ warfarin; Grapefruit juice ↑ warfarin", bold: false, color: C.teal },
], { source: "Sources: Goodman & Gilman's; Harrison's 22e; Kaplan Sadock; Tintinalli's EM; Lippincott" });

// 19. Table of Clinically Important DDIs
addTableSlide(pres,
  "High-Yield DDI Combinations — Clinical Summary",
  ["Drug A", "Drug B", "Mechanism", "Consequence", "Action"],
  [
    ["Warfarin", "NSAIDs", "PD: ↑ bleeding + PK: displacement", "↑ GI bleeding risk (4×)", "Avoid / monitor closely"],
    ["Simvastatin", "Ketoconazole", "CYP3A4 inhibition", "↑ statin levels → rhabdomyolysis", "Avoid combination"],
    ["Clopidogrel", "Omeprazole", "CYP2C19 inhibition (prodrug activation ↓)", "↓ antiplatelet effect", "Use pantoprazole instead"],
    ["MAOI", "Meperidine/SSRIs", "Excess serotonergic activity", "Serotonin syndrome (fatal)", "Absolute contraindication"],
    ["Digoxin", "Clarithromycin", "P-gp + CYP3A4 inhibition", "↑ Digoxin → toxicity", "Reduce digoxin dose/monitor"],
    ["Methotrexate", "NSAIDs", "↓ renal clearance + tubular competition", "↑ MTX toxicity (myelosuppression)", "Avoid/withhold NSAIDs"],
    ["OCP", "Rifampicin", "CYP3A4 induction → ↑ oestrogen metabolism", "Contraceptive failure", "Use barrier contraception"],
    ["Lithium", "Thiazides/NSAIDs", "↓ renal lithium clearance", "Lithium toxicity", "Monitor levels, adjust dose"],
    ["Nitrates", "Sildenafil/PDE5i", "Additive cGMP elevation → profound vasodilation", "Catastrophic hypotension", "Absolute contraindication"],
    ["Theophylline", "Ciprofloxacin", "CYP1A2 inhibition", "↑ Theophylline → seizures, arrhythmias", "Reduce theophylline dose"],
  ],
  { rowH: 0.38 }
);

// 20. More key interactions
addContentSlide(pres, "Additional High-Yield DDIs for MBBS", [
  { text: "ANTIEPILEPTICS + OCP: Carbamazepine, phenytoin induce CYP3A4 → ↓ OCP → use alternative contraception", bold: false },
  { text: "TETRACYCLINES / FLUOROQUINOLONES + ANTACIDS/IRON/DAIRY: Chelation → ↓ antibiotic absorption → treatment failure (separate by 2h)", bold: false },
  { text: "ALCOHOL + CNS DEPRESSANTS (benzodiazepines, opioids, antihistamines): Additive CNS/respiratory depression → potentially fatal", bold: false, color: C.red },
  { text: "ACE INHIBITORS + POTASSIUM-SPARING DIURETICS (spironolactone): Both ↑ serum K⁺ → hyperkalaemia → cardiac arrhythmias", bold: false },
  { text: "AMINOGLYCOSIDES + LOOP DIURETICS (furosemide): Both nephrotoxic & ototoxic → avoid concurrent use or monitor closely", bold: false },
  { text: "CYCLOSPORINE + RIFAMPICIN: CYP induction → ↓ cyclosporine → transplant rejection", bold: false },
  { text: "LEVODOPA + MAOIs: Hypertensive crisis", bold: false, color: C.red },
  { text: "SSRIs + ANTICOAGULANTS (DOACs/warfarin): Pharmacodynamic ↑ bleeding risk (serotonin-mediated platelet inhibition)", bold: false },
], { source: "Sources: Lippincott Pharmacology; Goodman & Gilman's; Katzung 16e; Tintinalli's EM" });

// ─── SECTION 7 ────────────────────────────────────────────────────────────────
addSectionDivider(pres, 7, "Prevention & Management of DDIs", "Clinical strategies to minimise harm");

// 21. Prevention
addContentSlide(pres, "Preventing and Managing DDIs", [
  { text: "PRESCRIBING STRATEGIES:", bold: true, color: C.teal },
  { text: "Minimise the number of drugs (polypharmacy review)", sub: true },
  { text: "Use narrowest effective dose for shortest duration", sub: true },
  { text: "Check drug interaction databases (Micromedex, CredibleMeds, BNF) before prescribing", sub: true },
  { text: "MONITORING:", bold: true, color: C.teal },
  { text: "Regular INR monitoring for warfarin users when new drug added/removed", sub: true },
  { text: "Serum drug levels: digoxin, lithium, theophylline, phenytoin, cyclosporine", sub: true },
  { text: "ECG monitoring in patients receiving QT-prolonging combinations", sub: true },
  { text: "DOSE ADJUSTMENT:", bold: true, color: C.teal },
  { text: "Reduce dose of affected drug when enzyme inhibitor added", sub: true },
  { text: "Increase dose (or switch) when enzyme inducer co-prescribed", sub: true },
  { text: "TIMING:", bold: true, color: C.teal },
  { text: "Separate administration by ≥2 hours for absorption interactions (antacids, iron)", sub: true },
  { text: "Allow adequate washout periods (e.g., 14 days after MAOI before SSRI)", sub: true },
], { source: "Sources: Harrison's Principles 22e; Goodman & Gilman's; BNF" });

// 22. Summary
addContentSlide(pres, "Summary — Key Take-Home Messages", [
  { text: "DDIs = pharmacokinetic (ADME) + pharmacodynamic (receptor-level) mechanisms", bold: true, color: C.navy },
  { text: "CYP3A4 is the most important metabolic enzyme — inhibition causes toxicity; induction causes failure", bold: true, color: C.teal },
  { text: "INHIBITORS (CRACK): Cimetidine, Ritonavir, Azoles, Clarithromycin, Ketoconazole", bold: false },
  { text: "INDUCERS (PC BRAS): Phenytoin, Carbamazepine, Barbiturates, Rifampicin, Alcohol, Smoking", bold: false },
  { text: "Warfarin is the highest-risk drug for clinically significant DDIs — always check", bold: true, color: C.red },
  { text: "Serotonin syndrome: MAOI + serotonergic drug → potentially fatal — ABSOLUTE contraindication", bold: true, color: C.red },
  { text: "QTc prolongation: Never combine two QT-prolonging drugs without ECG monitoring", bold: true, color: C.red },
  { text: "NSAID interactions: ↑ bleeding (warfarin), ↑ nephrotoxicity (lithium, methotrexate)", bold: false },
  { text: "Prevention: minimise polypharmacy, check databases, monitor levels, separate dosing times", bold: true, color: C.green },
], { source: "Sources: Goodman & Gilman's; Lippincott; Katzung 16e; Miller's Anesthesia 10e; Harrison's 22e" });

// 23. Thank You / Q&A
const sl23 = pres.addSlide();
sl23.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.navy } });
sl23.addShape(pres.ShapeType.rect, { x: 0, y: 4.6, w: 10, h: 0.18, fill: { color: C.amber } });
sl23.addShape(pres.ShapeType.rect, { x: 0, y: 4.8, w: 10, h: 0.08, fill: { color: C.teal } });
sl23.addText("MCQ Exercise", {
  x: 1, y: 0.8, w: 8, h: 0.6,
  fontSize: 18, color: C.amber, fontFace: FF, align: "center", charSpacing: 6, bold: true,
});
sl23.addText("Now proceed to the\n20-Question MCQ Exercise", {
  x: 1, y: 1.5, w: 8, h: 1.5,
  fontSize: 38, bold: true, color: C.white, fontFace: FF, align: "center", valign: "middle",
});
sl23.addText("Apply your knowledge — answers and explanations follow each question", {
  x: 1, y: 3.2, w: 8, h: 0.6,
  fontSize: 16, color: C.muted, fontFace: FF, align: "center", italic: true,
});
sl23.addText("\"The most dangerous drug is not the one you prescribe, but the one you forget to check against.\"", {
  x: 0.5, y: 4.0, w: 9, h: 0.45,
  fontSize: 11, color: C.muted, fontFace: FF, align: "center", italic: true,
});

// ─── MCQ SLIDES ───────────────────────────────────────────────────────────────

const mcqs = [
  {
    q: "Q1. A 60-year-old man on warfarin is prescribed rifampicin for tuberculosis. His INR drops from 2.5 to 1.2 after 2 weeks. The most likely mechanism is:",
    opts: ["A. Decreased warfarin absorption", "B. CYP enzyme induction → ↑ warfarin metabolism", "C. Protein binding displacement of warfarin", "D. Rifampicin directly antagonises vitamin K"],
    ans: "B. CYP enzyme induction → ↑ warfarin metabolism",
    exp: "Rifampicin is a potent CYP3A4 and CYP2C9 inducer. It increases warfarin metabolism, reducing plasma levels and anticoagulant effect. The INR drops, increasing thrombosis risk. Dose escalation or alternative anticoagulation is required."
  },
  {
    q: "Q2. A patient on MAOI antidepressants presents with hyperthermia, agitation, clonus, and diaphoresis after being given pethidine (meperidine) for pain. What is the diagnosis?",
    opts: ["A. Neuroleptic malignant syndrome", "B. Anticholinergic toxidrome", "C. Serotonin syndrome", "D. Opioid toxicity"],
    ans: "C. Serotonin syndrome",
    exp: "MAOI + meperidine is the classic drug combination causing serotonin syndrome. Meperidine inhibits serotonin reuptake; combined with MAOI-mediated MAO inhibition, CNS serotonin accumulates massively. The triad: mental status changes + autonomic instability + neuromuscular findings (clonus). Treat with cyproheptadine, supportive care, stop offending drugs."
  },
  {
    q: "Q3. A transplant patient on cyclosporine develops acute rejection 3 weeks after starting TB treatment. Which drug is responsible?",
    opts: ["A. Pyrazinamide", "B. Ethambutol", "C. Rifampicin", "D. Isoniazid"],
    ans: "C. Rifampicin",
    exp: "Rifampicin is a potent CYP3A4 inducer. Cyclosporine is a CYP3A4 substrate. Rifampicin dramatically increases cyclosporine metabolism, reducing its plasma levels to subtherapeutic concentrations, leading to transplant rejection. This interaction requires careful monitoring and dose adjustment."
  },
  {
    q: "Q4. Omeprazole is prescribed to a patient on clopidogrel after a coronary stent. Which concern is most valid?",
    opts: ["A. Omeprazole reduces clopidogrel absorption", "B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation", "C. Omeprazole increases platelet aggregation directly", "D. Omeprazole competes with clopidogrel at platelet P2Y12 receptors"],
    ans: "B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation",
    exp: "Clopidogrel is a prodrug that requires CYP2C19 for conversion to its active antiplatelet metabolite. Omeprazole inhibits CYP2C19, reducing this activation and thus antiplatelet efficacy. Pantoprazole is preferred as it has minimal CYP2C19 inhibition."
  },
  {
    q: "Q5. A patient on simvastatin 40 mg develops severe myalgia and dark urine after starting a new antifungal. Which drug is most likely responsible?",
    opts: ["A. Fluconazole (CYP2C9 inhibitor)", "B. Terbinafine (CYP2D6 inhibitor)", "C. Ketoconazole (CYP3A4 inhibitor)", "D. Griseofulvin (CYP inducer)"],
    ans: "C. Ketoconazole (CYP3A4 inhibitor)",
    exp: "Simvastatin is primarily metabolised by CYP3A4. Ketoconazole, a potent CYP3A4 inhibitor, causes a large increase in simvastatin plasma levels, dramatically increasing the risk of myopathy and rhabdomyolysis. This combination is contraindicated. Azole antifungals as a class are a major risk with CYP3A4-metabolised statins."
  },
  {
    q: "Q6. A patient on tetracycline is advised to take it with milk and antacids. After 1 week, the infection is not improving. The reason is:",
    opts: ["A. Pharmacodynamic antagonism between calcium and tetracycline", "B. Tetracycline undergoes rapid phase I metabolism in the presence of calcium", "C. Chelation of tetracycline by divalent cations (Ca²⁺, Mg²⁺, Al³⁺) → ↓ absorption", "D. Antacid increases gastric motility, reducing tetracycline dwell time"],
    ans: "C. Chelation of tetracycline by divalent cations (Ca²⁺, Mg²⁺, Al³⁺) → ↓ absorption",
    exp: "Tetracyclines form insoluble chelates with divalent and trivalent cations including calcium (milk/antacids), magnesium, aluminium, and iron. These chelates cannot be absorbed from the GI tract, resulting in therapeutic failure. Tetracyclines should be taken on an empty stomach, 2 hours before or after dairy/antacids/iron."
  },
  {
    q: "Q7. A patient on warfarin is prescribed amiodarone for persistent AF. Expected consequence:",
    opts: ["A. Decreased INR due to CYP induction", "B. Increased INR due to CYP2C9 inhibition → warfarin toxicity", "C. No interaction — different mechanisms of action", "D. Increased warfarin protein binding → ↓ free drug"],
    ans: "B. Increased INR due to CYP2C9 inhibition → warfarin toxicity",
    exp: "Amiodarone is a potent inhibitor of CYP2C9, the main enzyme metabolising S-warfarin (the more potent enantiomer). Amiodarone also inhibits CYP1A2 and CYP3A4. This results in significantly increased warfarin levels and markedly elevated INR, with bleeding risk. Warfarin dose reduction and close INR monitoring are mandatory."
  },
  {
    q: "Q8. Which of the following antibiotic + drug combinations is most likely to cause serious nephrotoxicity and ototoxicity?",
    opts: ["A. Amoxicillin + metronidazole", "B. Gentamicin + furosemide", "C. Ciprofloxacin + ibuprofen", "D. Clindamycin + spironolactone"],
    ans: "B. Gentamicin + furosemide",
    exp: "Both aminoglycosides (gentamicin) and loop diuretics (furosemide) are independently nephrotoxic and ototoxic. Their combination produces additive/synergistic toxicity in the kidney (tubular damage) and inner ear (cochlear hair cell damage). This combination should be avoided when possible; if used, dose and renal function must be carefully monitored."
  },
  {
    q: "Q9. A patient takes sildenafil for erectile dysfunction and also has angina. He takes sublingual glyceryl trinitrate (GTN) during an attack. What happens?",
    opts: ["A. GTN reduces sildenafil efficacy", "B. Severe hypotension — potentially fatal", "C. Reflex tachycardia only, no severe haemodynamic effect", "D. Sildenafil blocks GTN's vasodilation"],
    ans: "B. Severe hypotension — potentially fatal",
    exp: "Nitrates produce vasodilation via NO → cGMP elevation. Sildenafil/PDE5 inhibitors prevent cGMP breakdown. Combined use causes profound additive vasodilation → severe, potentially catastrophic hypotension. This combination is an ABSOLUTE CONTRAINDICATION. Patients on PDE5 inhibitors should not use organic nitrates."
  },
  {
    q: "Q10. Probenecid + penicillin was historically used because:",
    opts: ["A. Probenecid enhances GI absorption of penicillin", "B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life", "C. Probenecid induces CYP enzymes that convert penicillin to active metabolite", "D. Probenecid displaces penicillin from protein binding → ↑ free drug"],
    ans: "B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life",
    exp: "Probenecid competes with penicillin for the organic anion transporter (OAT) in renal tubules, blocking active secretion and thereby reducing renal clearance of penicillin. This prolongs plasma levels. This was a deliberate therapeutic DDI used during penicillin shortage (WWII era) and is still used with some antiretrovirals."
  },
  {
    q: "Q11. A patient on lithium for bipolar disorder is started on naproxen for arthritis. Serum lithium levels rise and he develops tremor, confusion, and arrhythmia. Mechanism:",
    opts: ["A. Naproxen inhibits renal CYP enzymes that metabolise lithium", "B. NSAIDs inhibit renal prostaglandin synthesis → ↓ GFR → ↓ lithium clearance", "C. Naproxen competes with lithium for protein binding sites", "D. Naproxen increases lithium tubular secretion causing reabsorption"],
    ans: "B. NSAIDs inhibit renal prostaglandin synthesis → ↓ GFR → ↓ lithium clearance",
    exp: "Renal prostaglandins serve as vasodilators maintaining GFR. NSAIDs inhibit prostaglandin synthesis, reducing GFR and thus renal lithium clearance. Additionally, thiazide diuretics increase proximal tubular lithium reabsorption. Result: lithium accumulation → toxicity (narrow TI). Monitor lithium levels closely; avoid NSAIDs in lithium-treated patients."
  },
  {
    q: "Q12. Erythromycin and simvastatin are co-prescribed. The risk is:",
    opts: ["A. Erythromycin reduces simvastatin absorption", "B. Both drugs inhibit CYP2D6", "C. Erythromycin inhibits CYP3A4 → ↑ simvastatin levels → myopathy/rhabdomyolysis", "D. Erythromycin is a CYP inducer reducing simvastatin effect"],
    ans: "C. Erythromycin inhibits CYP3A4 → ↑ simvastatin levels → myopathy/rhabdomyolysis",
    exp: "Erythromycin (and clarithromycin) are CYP3A4 inhibitors. Simvastatin is a CYP3A4 substrate. The inhibition increases statin plasma levels substantially, raising the risk of myopathy and rhabdomyolysis. Temporarily holding the statin or using a non-CYP3A4-dependent statin (pravastatin, rosuvastatin) is advised."
  },
  {
    q: "Q13. Which statement about pharmacodynamic drug interactions is CORRECT?",
    opts: [
      "A. They always involve CYP450 enzyme inhibition or induction",
      "B. They occur when one drug alters the absorption of another",
      "C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes",
      "D. Pharmacodynamic interactions are less clinically significant than pharmacokinetic ones"
    ],
    ans: "C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes",
    exp: "Pharmacodynamic interactions occur at the receptor/physiological level. Two QTc-prolonging drugs (e.g., antipsychotic + fluoroquinolone) have additive risk of TdP. PD interactions do not involve CYP450 and can be as or more clinically significant than PK interactions."
  },
  {
    q: "Q14. A female epileptic patient on carbamazepine becomes pregnant despite using oral contraceptive pills. The most likely explanation is:",
    opts: ["A. Carbamazepine inhibits CYP3A4 → increases oestrogen levels", "B. Carbamazepine is a CYP3A4 inducer → reduces OCP oestrogen levels → contraceptive failure", "C. Carbamazepine interferes with progesterone receptor binding", "D. Carbamazepine reduces gastric pH impairing OCP absorption"],
    ans: "B. Carbamazepine is a CYP3A4 inducer → reduces OCP oestrogen levels → contraceptive failure",
    exp: "Carbamazepine and other enzyme-inducing antiepileptics (phenytoin, phenobarbitone) induce CYP3A4, accelerating the metabolism of oestrogen and progesterone in OCPs, reducing their plasma concentrations below effective levels. Women on enzyme-inducing AEDs must use alternative or additional contraception (barrier methods, Depo-Provera, copper IUD)."
  },
  {
    q: "Q15. A patient takes theophylline for asthma and is prescribed ciprofloxacin for a UTI. After 2 days he develops tachycardia, tremors, and seizures. Serum theophylline is markedly elevated. Mechanism:",
    opts: ["A. Ciprofloxacin is a CYP3A4 inducer increasing theophylline synthesis", "B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity", "C. Ciprofloxacin displaces theophylline from albumin → ↑ free drug", "D. Ciprofloxacin reduces renal theophylline excretion competitively"],
    ans: "B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity",
    exp: "Theophylline is primarily metabolised by CYP1A2. Ciprofloxacin is a potent CYP1A2 inhibitor. Co-administration raises theophylline levels significantly. Theophylline has a narrow therapeutic index (10–20 mg/L); toxicity (nausea, arrhythmias, seizures) appears at >20 mg/L. Reduce theophylline dose by ~30-50% and monitor levels."
  },
  {
    q: "Q16. Co-trimoxazole (trimethoprim + sulfamethoxazole) demonstrates which type of drug interaction?",
    opts: [
      "A. Pharmacokinetic — CYP inhibition",
      "B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)",
      "C. Pharmaceutical incompatibility",
      "D. Pharmacodynamic antagonism"
    ],
    ans: "B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)",
    exp: "Trimethoprim inhibits dihydrofolate reductase (DHFR); sulfamethoxazole inhibits dihydropteroate synthase (blocks PABA incorporation). Together they block folate synthesis at two sequential steps, producing synergistic bactericidal activity. This is an intentional pharmacodynamic synergism — not a PK interaction."
  },
  {
    q: "Q17. Which drug interaction can cause fatal hyperkalaemia?",
    opts: [
      "A. ACE inhibitor + loop diuretic",
      "B. ACE inhibitor + spironolactone",
      "C. Beta-blocker + calcium channel blocker",
      "D. Warfarin + aspirin"
    ],
    ans: "B. ACE inhibitor + spironolactone",
    exp: "ACE inhibitors reduce aldosterone → ↑ K⁺ retention. Spironolactone (potassium-sparing diuretic) antagonises aldosterone directly → also ↑ K⁺. Both drugs independently cause hyperkalaemia; combination in patients with renal impairment can be fatal. Serum potassium must be monitored. ACE inhibitor + loop diuretic, conversely, may cause hypokalaemia."
  },
  {
    q: "Q18. Grapefruit juice significantly increases the plasma level of simvastatin because:",
    opts: [
      "A. It induces CYP3A4 in the liver",
      "B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability",
      "C. It decreases renal simvastatin excretion",
      "D. It displaces simvastatin from plasma protein binding"
    ],
    ans: "B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability",
    exp: "Grapefruit juice contains furanocoumarins that irreversibly inhibit CYP3A4 in intestinal enterocytes. This reduces first-pass metabolism of CYP3A4 substrates like simvastatin, nifedipine, and cyclosporine, dramatically increasing oral bioavailability. The effect lasts 24–72 hours after a single glass. Patients on statin/CCB therapy should avoid grapefruit."
  },
  {
    q: "Q19. Which of the following drug pairs exemplifies physiological (indirect) antagonism?",
    opts: [
      "A. Naloxone + morphine (competitive opioid receptor antagonism)",
      "B. Adrenaline + histamine in anaphylaxis (opposing physiological effects)",
      "C. Propranolol + salbutamol at beta-2 receptors (competitive receptor antagonism)",
      "D. Flumazenil + diazepam (competitive benzodiazepine receptor antagonism)"
    ],
    ans: "B. Adrenaline + histamine in anaphylaxis (opposing physiological effects)",
    exp: "Physiological (functional/indirect) antagonism: two drugs with opposing effects acting through DIFFERENT receptors/mechanisms. Histamine causes bronchospasm, hypotension; adrenaline via adrenergic receptors causes bronchodilation, vasoconstriction — opposing effects without direct receptor competition. Options A, C, D are all direct competitive receptor antagonism."
  },
  {
    q: "Q20. Cholestyramine, when administered to a patient on warfarin, causes subtherapeutic anticoagulation because:",
    opts: [
      "A. Cholestyramine inhibits CYP2C9 reducing warfarin activation",
      "B. Cholestyramine binds warfarin in the GI tract, reducing its absorption",
      "C. Cholestyramine competes with warfarin for plasma protein binding",
      "D. Cholestyramine induces hepatic CYP3A4 increasing warfarin clearance"
    ],
    ans: "B. Cholestyramine binds warfarin in the GI tract, reducing its absorption",
    exp: "Cholestyramine is a bile acid sequestrant (anion exchange resin) that binds negatively charged molecules in the GI tract, including warfarin, digoxin, thyroid hormones, and fat-soluble vitamins. This adsorption reduces their absorption, leading to subtherapeutic plasma levels. To avoid this, give other drugs 1 hour before or 4–6 hours after cholestyramine."
  },
];

mcqs.forEach((mcq, i) => {
  // Question slide
  const qsl = pres.addSlide();
  qsl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.navy } });
  qsl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.06, fill: { color: C.amber } });
  qsl.addShape(pres.ShapeType.rect, { x: 0, y: 5.555, w: 10, h: 0.07, fill: { color: C.teal } });
  qsl.addText(`MCQ ${i + 1} of 20`, {
    x: 0.4, y: 0.15, w: 9.2, h: 0.4,
    fontSize: 13, color: C.amber, fontFace: FF, bold: true, charSpacing: 3,
  });
  qsl.addText(mcq.q, {
    x: 0.4, y: 0.65, w: 9.2, h: 1.3,
    fontSize: 16, color: C.white, fontFace: FF, bold: false, valign: "top",
    lineSpacingMultiple: 1.3,
  });
  const optItems = mcq.opts.map((o, oi) => ({
    text: o,
    options: {
      bullet: false,
      fontSize: 14,
      color: C.white,
      bold: false,
      breakLine: oi < mcq.opts.length - 1,
    },
  }));
  qsl.addText(optItems, {
    x: 0.6, y: 2.1, w: 8.8, h: 2.4,
    fontFace: FF, valign: "top", lineSpacingMultiple: 1.5,
  });
  qsl.addText("Think before turning to the answer →", {
    x: 0.4, y: 5.15, w: 9.2, h: 0.35,
    fontSize: 11, color: C.muted, fontFace: FF, italic: true, align: "center",
  });

  // Answer slide
  const asl = pres.addSlide();
  asl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: "0A3A28" } });
  asl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 0.06, fill: { color: C.green } });
  asl.addShape(pres.ShapeType.rect, { x: 0, y: 5.555, w: 10, h: 0.07, fill: { color: C.green } });
  asl.addText(`ANSWER — MCQ ${i + 1}`, {
    x: 0.4, y: 0.12, w: 9.2, h: 0.4,
    fontSize: 13, color: C.amber, fontFace: FF, bold: true, charSpacing: 3,
  });
  asl.addShape(pres.ShapeType.rect, { x: 0.4, y: 0.6, w: 9.2, h: 0.7, fill: { color: C.green }, rectRadius: 0.05 });
  asl.addText(`✔  ${mcq.ans}`, {
    x: 0.5, y: 0.62, w: 9.0, h: 0.65,
    fontSize: 15, bold: true, color: C.white, fontFace: FF, valign: "middle",
  });
  asl.addText("Explanation:", {
    x: 0.4, y: 1.45, w: 9.2, h: 0.35,
    fontSize: 13, color: C.amber, fontFace: FF, bold: true,
  });
  asl.addText(mcq.exp, {
    x: 0.4, y: 1.85, w: 9.2, h: 3.4,
    fontSize: 14, color: C.white, fontFace: FF, valign: "top",
    lineSpacingMultiple: 1.35,
  });
});

// Final slide
const finalSl = pres.addSlide();
finalSl.addShape(pres.ShapeType.rect, { x: 0, y: 0, w: 10, h: 5.625, fill: { color: C.navy } });
finalSl.addShape(pres.ShapeType.rect, { x: 0, y: 2.6, w: 10, h: 0.12, fill: { color: C.amber } });
finalSl.addText("Session Complete", {
  x: 0.5, y: 0.6, w: 9, h: 0.7,
  fontSize: 18, color: C.muted, fontFace: FF, align: "center", charSpacing: 6,
});
finalSl.addText("Drug–Drug Interactions", {
  x: 0.5, y: 1.3, w: 9, h: 1.1,
  fontSize: 42, bold: true, color: C.white, fontFace: FF, align: "center",
});
finalSl.addText([
  { text: "Key references: ", options: { bold: true, color: C.amber } },
  { text: "Goodman & Gilman's • Lippincott Pharmacology • Katzung 16e • Miller's Anesthesia 10e • Harrison's 22e • Tintinalli's EM", options: { color: C.muted } },
], { x: 0.5, y: 2.9, w: 9, h: 0.8, fontFace: FF, align: "center", fontSize: 12 });
finalSl.addText("Questions? Discussion? Next steps in clinical practice.", {
  x: 0.5, y: 3.9, w: 9, h: 0.5,
  fontSize: 15, color: C.teal, fontFace: FF, align: "center", italic: true,
});

// Save
pres.writeFile({ fileName: "/home/daytona/workspace/ddi-presentation/Drug_Drug_Interactions_MBBS.pptx" })
  .then(() => console.log("SUCCESS: PPTX saved"))
  .catch(e => console.error("ERROR:", e));
Running Command

cd /home/daytona/workspace/ddi-presentation && node create_ddi_ppt.js 2>&1

Writing File

~/ddi-presentation/DDI_MCQ_Exercise.md

# Drug–Drug Interactions — MCQ Exercise
### UG MBBS Pharmacology | 20 Questions | 20 Minutes

---

> **Instructions:** Each question has ONE best answer. Mark your answer before reading the explanation.
> Scoring: 1 mark per correct answer. No negative marking.

---

## QUESTIONS

---

**Q1.** A 60-year-old man on warfarin is prescribed rifampicin for tuberculosis. His INR drops from 2.5 to 1.2 after 2 weeks. The most likely mechanism is:

- A. Decreased warfarin absorption from the GI tract
- B. CYP enzyme induction → increased warfarin metabolism
- C. Protein binding displacement of warfarin by rifampicin
- D. Rifampicin directly antagonises vitamin K epoxide reductase

---

**Q2.** A patient on MAOI antidepressants presents with hyperthermia, agitation, clonus, and diaphoresis after being given pethidine (meperidine) for post-operative pain. What is the diagnosis?

- A. Neuroleptic malignant syndrome
- B. Anticholinergic toxidrome
- C. Serotonin syndrome
- D. Opioid toxicity

---

**Q3.** A transplant patient on cyclosporine develops acute rejection 3 weeks after starting TB treatment. Which drug is responsible?

- A. Pyrazinamide
- B. Ethambutol
- C. Rifampicin
- D. Isoniazid

---

**Q4.** Omeprazole is prescribed to a patient on clopidogrel after coronary stent placement. Which pharmacological concern is most valid?

- A. Omeprazole reduces clopidogrel absorption from the stomach
- B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation to its active metabolite
- C. Omeprazole increases platelet aggregation directly
- D. Omeprazole competes with clopidogrel at the platelet P2Y12 receptor

---

**Q5.** A patient on simvastatin 40 mg develops severe myalgia and dark urine after starting a new antifungal. Which drug is most likely responsible?

- A. Fluconazole (CYP2C9 inhibitor)
- B. Terbinafine (CYP2D6 inhibitor)
- C. Ketoconazole (CYP3A4 inhibitor)
- D. Griseofulvin (CYP inducer)

---

**Q6.** A patient is advised to take tetracycline with milk and antacids. After one week, the infection has not improved. The most likely reason is:

- A. Pharmacodynamic antagonism between calcium and tetracycline at the ribosome
- B. Tetracycline undergoes rapid phase I metabolism in the presence of calcium
- C. Chelation of tetracycline by divalent cations (Ca²⁺, Mg²⁺, Al³⁺) → decreased absorption
- D. Antacid increases gastric motility, reducing tetracycline contact time

---

**Q7.** A patient on warfarin is prescribed amiodarone for persistent atrial fibrillation. The expected consequence is:

- A. Decreased INR due to CYP enzyme induction
- B. Increased INR due to CYP2C9 inhibition → warfarin toxicity
- C. No significant interaction — different mechanisms of action
- D. Increased warfarin protein binding → decreased free drug levels

---

**Q8.** Which of the following antibiotic + drug combinations is most likely to cause additive nephrotoxicity and ototoxicity?

- A. Amoxicillin + metronidazole
- B. Gentamicin + furosemide
- C. Ciprofloxacin + ibuprofen
- D. Clindamycin + spironolactone

---

**Q9.** A patient takes sildenafil for erectile dysfunction and has ischaemic heart disease. He uses sublingual glyceryl trinitrate (GTN) during an anginal attack. What is the expected outcome?

- A. GTN reduces sildenafil efficacy
- B. Severe, potentially fatal hypotension
- C. Mild reflex tachycardia only
- D. Sildenafil blocks nitrate-mediated vasodilation

---

**Q10.** Probenecid was historically combined with penicillin because:

- A. Probenecid enhances GI absorption of penicillin
- B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life
- C. Probenecid induces CYP enzymes that convert penicillin to its active metabolite
- D. Probenecid displaces penicillin from plasma protein binding → increases free drug

---

**Q11.** A patient on lithium for bipolar disorder is started on naproxen for arthritis. Serum lithium rises and he develops tremor, confusion, and cardiac arrhythmias. The mechanism is:

- A. Naproxen inhibits renal CYP enzymes that metabolise lithium
- B. NSAIDs inhibit renal prostaglandin synthesis → reduced GFR → decreased lithium clearance
- C. Naproxen competes with lithium for plasma protein binding
- D. Naproxen increases lithium tubular secretion causing paradoxical reabsorption

---

**Q12.** Erythromycin and simvastatin are co-prescribed. The clinically significant risk is:

- A. Erythromycin reduces simvastatin absorption from the GI tract
- B. Both drugs independently inhibit CYP2D6
- C. Erythromycin inhibits CYP3A4 → increased simvastatin levels → myopathy/rhabdomyolysis
- D. Erythromycin is a CYP inducer reducing simvastatin plasma levels

---

**Q13.** Which statement about pharmacodynamic drug interactions is CORRECT?

- A. They always involve CYP450 enzyme inhibition or induction
- B. They occur when one drug alters the absorption of another drug
- C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes
- D. Pharmacodynamic interactions are always less clinically significant than pharmacokinetic ones

---

**Q14.** A female epileptic patient on carbamazepine becomes pregnant despite using oral contraceptive pills. The most likely explanation is:

- A. Carbamazepine inhibits CYP3A4, increasing oestrogen levels to supraphysiological levels
- B. Carbamazepine is a CYP3A4 inducer → reduces OCP oestrogen metabolism → contraceptive failure
- C. Carbamazepine interferes with progesterone receptor binding in the endometrium
- D. Carbamazepine reduces gastric pH, impairing OCP absorption

---

**Q15.** A patient on theophylline for asthma is prescribed ciprofloxacin for a urinary tract infection. Two days later he develops tachycardia, tremors, and seizures. Serum theophylline is markedly elevated. The mechanism is:

- A. Ciprofloxacin induces CYP3A4, increasing theophylline synthesis in the liver
- B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity
- C. Ciprofloxacin displaces theophylline from albumin, increasing free drug
- D. Ciprofloxacin competes with theophylline for renal tubular secretion

---

**Q16.** Co-trimoxazole (trimethoprim + sulfamethoxazole) demonstrates which type of pharmacological interaction?

- A. Pharmacokinetic — CYP450 enzyme inhibition
- B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)
- C. Pharmaceutical incompatibility
- D. Pharmacodynamic — functional antagonism

---

**Q17.** Which drug combination can cause potentially fatal hyperkalaemia?

- A. ACE inhibitor + loop diuretic
- B. ACE inhibitor + spironolactone
- C. Beta-blocker + calcium channel blocker
- D. Warfarin + aspirin

---

**Q18.** Grapefruit juice significantly increases the plasma level of simvastatin because:

- A. It induces CYP3A4 in hepatocytes, increasing active metabolite formation
- B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability of simvastatin
- C. It decreases renal simvastatin excretion by inhibiting tubular secretion
- D. It displaces simvastatin from plasma protein binding sites

---

**Q19.** Which of the following drug pairs exemplifies physiological (indirect/functional) antagonism?

- A. Naloxone + morphine (competitive opioid receptor antagonism)
- B. Adrenaline + histamine in anaphylaxis (opposing effects via different receptors)
- C. Propranolol + salbutamol at beta-2 receptors (competitive receptor antagonism)
- D. Flumazenil + diazepam (competitive benzodiazepine receptor antagonism)

---

**Q20.** Cholestyramine, when administered to a patient on warfarin, causes subtherapeutic anticoagulation because:

- A. Cholestyramine inhibits CYP2C9 reducing warfarin activation
- B. Cholestyramine binds warfarin in the GI tract, reducing its oral absorption
- C. Cholestyramine competes with warfarin for plasma albumin binding
- D. Cholestyramine induces hepatic CYP3A4 increasing warfarin clearance

---
---

## ANSWER KEY

| Q | Answer | Q | Answer |
|---|--------|---|--------|
| 1 | **B** | 11 | **B** |
| 2 | **C** | 12 | **C** |
| 3 | **C** | 13 | **C** |
| 4 | **B** | 14 | **B** |
| 5 | **C** | 15 | **B** |
| 6 | **C** | 16 | **B** |
| 7 | **B** | 17 | **B** |
| 8 | **B** | 18 | **B** |
| 9 | **B** | 19 | **B** |
| 10 | **B** | 20 | **B** |

---

## DETAILED EXPLANATIONS

---

**Q1 — B.** Rifampicin is a potent inducer of CYP3A4 and CYP2C9 (the enzyme metabolising S-warfarin). Enzyme induction increases warfarin metabolism, reducing its plasma concentration and anticoagulant effect. INR falls, and the patient becomes subtherapeutically anticoagulated — risking thromboembolic events. Warfarin dose escalation and close INR monitoring are mandatory; upon rifampicin cessation, the dose must be reduced again.

---

**Q2 — C.** MAOI + meperidine (pethidine) is the classic lethal interaction causing **serotonin syndrome**. MAOIs prevent serotonin breakdown; meperidine inhibits serotonin reuptake. The resulting CNS serotonin excess causes the classic triad: *(1) altered mental status, (2) autonomic instability (hyperthermia, tachycardia), (3) neuromuscular findings (clonus, hyperreflexia)*. Management: stop both drugs, cyproheptadine (5-HT2A antagonist), supportive care.
*(Source: Barash Clinical Anesthesia 9e; Goodman & Gilman's)*

---

**Q3 — C.** Cyclosporine is a CYP3A4 substrate. Rifampicin is a potent CYP3A4/2C9/1A2 inducer. Co-prescription leads to 3–5-fold increase in cyclosporine clearance, reducing plasma levels to subtherapeutic concentrations → acute rejection. This interaction is encountered in TB-post-transplant settings and requires either avoiding rifampicin (use rifabutin) or substantially increasing cyclosporine dose with frequent level monitoring.

---

**Q4 — B.** Clopidogrel is a **prodrug** requiring CYP2C19 for conversion to its active thiol metabolite which then irreversibly inhibits platelet P2Y12 receptors. Omeprazole is a CYP2C19 inhibitor. Co-administration reduces clopidogrel activation by ~40%, decreasing antiplatelet effect and increasing stent thrombosis risk. **Pantoprazole** has minimal CYP2C19 inhibition and is the preferred PPI in this context.
*(Source: Lippincott Pharmacology — Clinical Application 42.1)*

---

**Q5 — C.** Simvastatin (and lovastatin, atorvastatin) undergo extensive CYP3A4 metabolism. Ketoconazole is a potent CYP3A4 inhibitor. This interaction can increase simvastatin AUC up to 20-fold, vastly increasing the risk of myopathy and rhabdomyolysis (myoglobinuria → renal failure). This combination is **contraindicated**. Pravastatin and rosuvastatin are minimally affected by CYP3A4 and are safer choices when azole antifungals are needed.

---

**Q6 — C.** Tetracyclines contain multiple carbonyl and hydroxyl groups that form stable, insoluble **chelate complexes** with divalent (Ca²⁺, Mg²⁺, Fe²⁺, Zn²⁺) and trivalent (Al³⁺) cations. These chelates are not absorbed from the GI tract, resulting in treatment failure. Tetracyclines must be taken on an **empty stomach**, 2 hours before or after dairy products, antacids, and iron supplements.

---

**Q7 — B.** Amiodarone is a potent CYP2C9 inhibitor (also CYP1A2, CYP3A4). S-warfarin (the more potent enantiomer) is primarily metabolised by CYP2C9. Amiodarone inhibition leads to substantially increased warfarin levels → elevated INR → bleeding. This interaction may be delayed (amiodarone has a half-life of 40–55 days). Warfarin dose reduction of ~30–50% and **close INR monitoring** are essential.

---

**Q8 — B.** Both **aminoglycosides** (gentamicin, tobramycin) and **loop diuretics** (furosemide) are independently nephrotoxic (proximal tubule damage) and ototoxic (cochlear hair cell damage). Their combination produces additive/synergistic toxicity. Risk is amplified in pre-existing renal impairment, dehydration, or elderly patients. Avoid concurrent use where possible; if unavoidable, monitor renal function and audiometry.

---

**Q9 — B.** Nitrates (e.g., GTN) produce vasodilation via NO → guanylate cyclase → ↑cGMP in vascular smooth muscle. PDE5 inhibitors (sildenafil, tadalafil) prevent cGMP degradation. Combined use produces synergistic, profound vasodilation → **catastrophic hypotension, syncope, myocardial ischaemia**. This combination is an **absolute contraindication**. Patients on chronic nitrates should not take PDE5 inhibitors.
*(Source: Goodman & Gilman's Pharmacological Basis of Therapeutics)*

---

**Q10 — B.** Penicillin is eliminated via **active tubular secretion** (organic anion transporter, OAT1/OAT3) in the kidney. Probenecid competes for the same transporter, blocking penicillin secretion, reducing its renal clearance and prolonging plasma half-life. This was an intentional therapeutic DDI during WWII when penicillin was scarce. Still used to boost some antiviral levels (e.g., cidofovir).

---

**Q11 — B.** Renal prostaglandins (PGE2, PGI2) act as vasodilators to maintain afferent arteriolar tone and GFR. NSAIDs inhibit COX enzymes → reduced prostaglandin synthesis → afferent arteriolar vasoconstriction → decreased GFR → decreased renal lithium clearance → lithium accumulation. Lithium has a narrow therapeutic index (0.6–1.2 mEq/L). Toxicity manifests as neurological symptoms and cardiac arrhythmias.

---

**Q12 — C.** Erythromycin (and clarithromycin) are **CYP3A4 inhibitors**. Simvastatin is a CYP3A4 substrate with significant first-pass metabolism. CYP3A4 inhibition substantially increases simvastatin bioavailability → myopathy/rhabdomyolysis risk. Options: temporarily hold statin during antibiotic course, or switch to macrolide with less CYP interaction (azithromycin) or to a statin not metabolised by CYP3A4 (pravastatin, rosuvastatin).

---

**Q13 — C.** Pharmacodynamic interactions occur at the receptor or physiological level without altering drug concentrations. QTc prolongation via IKr (hERG channel) blockade is an additive PD interaction — combining two QTc-prolonging drugs increases the risk of TdP ventricular tachycardia. PD interactions do NOT involve CYP450 (that is pharmacokinetic). They can be equally or more clinically significant.

---

**Q14 — B.** The question contains a deliberate error to highlight a common mistake: carbamazepine *INDUCES* (not inhibits) CYP3A4. Oestrogen and progesterone in OCPs are CYP3A4 substrates. Enzyme induction accelerates their metabolism → subtherapeutic hormone levels → contraceptive failure. Enzyme-inducing AEDs (carbamazepine, phenytoin, phenobarbitone) require women to use barrier contraception or a progesterone IUD.

---

**Q15 — B.** Theophylline is primarily metabolised by **CYP1A2**. Ciprofloxacin (and other fluoroquinolones — enoxacin > ciprofloxacin > levofloxacin) inhibit CYP1A2. Theophylline has a **narrow therapeutic index** (10–20 mg/L); toxicity at >20 mg/L causes nausea, tachyarrhythmias, and seizures. Theophylline dose should be reduced ~30–50% when ciprofloxacin is co-prescribed, with level monitoring.

---

**Q16 — B.** Trimethoprim inhibits **dihydrofolate reductase (DHFR)** — the second step in folate synthesis. Sulfamethoxazole inhibits **dihydropteroate synthase** — the first step (blocks incorporation of PABA). Sequential blockade of the same pathway produces a synergistic effect far greater than either drug alone. This is **pharmacodynamic synergism** — an intentional interaction. No CYP or absorption mechanism is involved.

---

**Q17 — B.** ACE inhibitors block angiotensin II → reduced aldosterone → decreased renal K⁺ excretion → **hyperkalaemia**. Spironolactone directly antagonises aldosterone at the mineralocorticoid receptor → also increases K⁺ retention. Combined, particularly in patients with CKD, the hyperkalaemia can be severe and potentially fatal (cardiac arrest). This combination requires K⁺ monitoring; ACE inhibitor + loop diuretic causes **hypokalaemia** (opposite direction).

---

**Q18 — B.** Grapefruit juice contains **furanocoumarins** (bergamottin, dihydroxybergamottin) that **irreversibly inhibit CYP3A4** expressed in enterocytes (intestinal wall). This dramatically reduces first-pass metabolism of CYP3A4 substrates (simvastatin, nifedipine, cyclosporine, buspirone), increasing their oral bioavailability by 2–15-fold. Effect persists 24–72 hours — one glass is sufficient. Patients on affected drugs must avoid grapefruit entirely.

---

**Q19 — B.** **Physiological (functional) antagonism**: two drugs act through **different receptors** to produce opposing physiological effects. In anaphylaxis, histamine causes bronchoconstriction/hypotension via H1 receptors; adrenaline causes bronchodilation/vasoconstriction via adrenergic receptors — countering histamine's effects without competing at the same receptor. Options A, C, D are all **competitive direct receptor antagonism** — the drugs compete for the same receptor.

---

**Q20 — B.** Cholestyramine is an anion exchange resin that binds **negatively charged molecules** in the GI lumen. It adsorbs warfarin (and other drugs: digoxin, thyroid hormones, fat-soluble vitamins, bile acids) in the intestine, preventing their absorption → subtherapeutic levels. To minimise this interaction: take other medications **1 hour before or 4–6 hours after** cholestyramine. Not a CYP interaction — purely absorption-based.

---

## SCORING GUIDE

| Score | Performance |
|-------|-------------|
| 18–20 | Excellent — Ready for clinical pharmacology |
| 14–17 | Good — Review weaker areas |
| 10–13 | Average — Revisit CYP450 and key interactions |
| <10 | Needs revision — Re-attend the lecture |

---

*Sources: Goodman & Gilman's Pharmacological Basis of Therapeutics | Lippincott Illustrated Reviews Pharmacology | Katzung's Basic & Clinical Pharmacology 16e | Miller's Anesthesia 10e | Harrison's Principles of Internal Medicine 22e | Tintinalli's Emergency Medicine | Barash Clinical Anesthesia 9e*
Running Command

cd /home/daytona/workspace/ddi-presentation && ls -lh && echo "---" && python3 -m markitdown Drug_Drug_Interactions_MBBS.pptx 2>/dev/null | head -80

Running Command

cd /home/daytona/workspace/ddi-presentation && pandoc DDI_MCQ_Exercise.md -o DDI_MCQ_Exercise.pdf --pdf-engine=wkhtmltopdf -V margin-top=20mm -V margin-bottom=20mm -V margin-left=20mm -V margin-right=20mm 2>&1 || pandoc DDI_MCQ_Exercise.md -o DDI_MCQ_Exercise.pdf 2>&1 && ls -lh DDI_MCQ_Exercise.pdf

Running Command

cd /home/daytona/workspace/ddi-presentation && python3 -c " from reportlab.lib.pagesizes import A4 from reportlab.lib.units import mm from reportlab.platypus import SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle, HRFlowable from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle from reportlab.lib import colors from reportlab.lib.enums import TA_CENTER, TA_LEFT, TA_JUSTIFY import re doc = SimpleDocTemplate('DDI_MCQ_Exercise.pdf', pagesize=A4, rightMargin=20*mm, leftMargin=20*mm, topMargin=20*mm, bottomMargin=20*mm) styles = getSampleStyleSheet() navy = colors.HexColor('#0D2B55') teal = colors.HexColor('#007F8C') amber = colors.HexColor('#F4A022') red = colors.HexColor('#C0392B') green = colors.HexColor('#1A7A4A') light = colors.HexColor('#E8F4F8') h1 = ParagraphStyle('H1', parent=styles['Title'], textColor=navy, fontSize=18, spaceAfter=4) h2 = ParagraphStyle('H2', parent=styles['Heading2'], textColor=teal, fontSize=13, spaceAfter=3) h3 = ParagraphStyle('H3', parent=styles['Heading3'], textColor=amber, fontSize=11, spaceAfter=2) body = ParagraphStyle('body', parent=styles['Normal'], fontSize=10, leading=14, spaceAfter=3) bold_body = ParagraphStyle('bold', parent=body, fontName='Helvetica-Bold') answer_style = ParagraphStyle('answer', parent=body, textColor=green, fontName='Helvetica-Bold', fontSize=11) qstyle = ParagraphStyle('q', parent=body, fontName='Helvetica-Bold', textColor=navy, fontSize=11, leading=15, spaceAfter=4) opt_style = ParagraphStyle('opt', parent=body, leftIndent=15) exp_style = ParagraphStyle('exp', parent=body, backColor=light, leftIndent=10, rightIndent=10, borderPad=5) subtitle = ParagraphStyle('sub', parent=styles['Normal'], fontSize=10, textColor=teal, alignment=TA_CENTER, spaceAfter=6) center_style = ParagraphStyle('center', parent=styles['Normal'], alignment=TA_CENTER, fontSize=9, textColor=colors.grey) story = [] # Title story.append(Paragraph('Drug–Drug Interactions — MCQ Exercise', h1)) story.append(Paragraph('UG MBBS Pharmacology &nbsp;|&nbsp; 20 Questions &nbsp;|&nbsp; 20 Minutes', subtitle)) story.append(HRFlowable(width='100%', thickness=2, color=amber, spaceAfter=6)) story.append(Paragraph('<b>Instructions:</b> Each question has ONE best answer. Mark your answer before reading the explanation. No negative marking.', body)) story.append(Spacer(1, 6*mm)) mcqs = [ { 'n': 1, 'q': 'A 60-year-old man on warfarin is prescribed rifampicin for tuberculosis. His INR drops from 2.5 to 1.2 after 2 weeks. The most likely mechanism is:', 'opts': ['A. Decreased warfarin absorption from the GI tract', 'B. CYP enzyme induction → increased warfarin metabolism', 'C. Protein binding displacement of warfarin by rifampicin', 'D. Rifampicin directly antagonises vitamin K epoxide reductase'], 'ans': 'B. CYP enzyme induction → increased warfarin metabolism', 'exp': 'Rifampicin is a potent inducer of CYP3A4 and CYP2C9 (metabolising S-warfarin). Induction increases warfarin metabolism, reducing plasma concentration and anticoagulant effect. INR falls, increasing thrombosis risk. Warfarin dose escalation and close INR monitoring are mandatory.' }, { 'n': 2, 'q': 'A patient on MAOI antidepressants presents with hyperthermia, agitation, clonus, and diaphoresis after being given pethidine (meperidine) post-operatively. What is the diagnosis?', 'opts': ['A. Neuroleptic malignant syndrome', 'B. Anticholinergic toxidrome', 'C. Serotonin syndrome', 'D. Opioid toxicity'], 'ans': 'C. Serotonin syndrome', 'exp': 'MAOI + meperidine is the classic lethal interaction causing serotonin syndrome. MAOIs prevent serotonin breakdown; meperidine inhibits serotonin reuptake. CNS serotonin excess causes the triad: altered mental status + autonomic instability (hyperthermia, tachycardia) + neuromuscular findings (clonus, hyperreflexia). ABSOLUTE contraindication. (Barash Anesthesia 9e; Goodman & Gilman\\'s)' }, { 'n': 3, 'q': 'A transplant patient on cyclosporine develops acute rejection 3 weeks after starting TB treatment. Which drug is responsible?', 'opts': ['A. Pyrazinamide', 'B. Ethambutol', 'C. Rifampicin', 'D. Isoniazid'], 'ans': 'C. Rifampicin', 'exp': 'Cyclosporine is a CYP3A4 substrate. Rifampicin is a potent CYP3A4 inducer. Co-prescription increases cyclosporine clearance 3-5-fold → subtherapeutic levels → acute rejection. Use rifabutin instead if possible, or substantially increase cyclosporine dose with frequent level monitoring.' }, { 'n': 4, 'q': 'Omeprazole is prescribed to a patient on clopidogrel after coronary stent placement. Which concern is most valid?', 'opts': ['A. Omeprazole reduces clopidogrel absorption from the stomach', 'B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation to its active metabolite', 'C. Omeprazole increases platelet aggregation directly', 'D. Omeprazole competes with clopidogrel at the P2Y12 receptor'], 'ans': 'B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation', 'exp': 'Clopidogrel is a prodrug requiring CYP2C19 for conversion to its active antiplatelet metabolite. Omeprazole inhibits CYP2C19, reducing clopidogrel activation by ~40%, decreasing antiplatelet efficacy and increasing stent thrombosis risk. Pantoprazole (minimal CYP2C19 inhibition) is the preferred PPI. (Lippincott — Clinical Application 42.1)' }, { 'n': 5, 'q': 'A patient on simvastatin 40 mg develops severe myalgia and dark urine after starting a new antifungal. Which drug is most likely responsible?', 'opts': ['A. Fluconazole (CYP2C9 inhibitor)', 'B. Terbinafine (CYP2D6 inhibitor)', 'C. Ketoconazole (CYP3A4 inhibitor)', 'D. Griseofulvin (CYP inducer)'], 'ans': 'C. Ketoconazole (CYP3A4 inhibitor)', 'exp': 'Simvastatin is primarily metabolised by CYP3A4. Ketoconazole, a potent CYP3A4 inhibitor, can increase simvastatin AUC up to 20-fold → myopathy/rhabdomyolysis risk. CONTRAINDICATED. Pravastatin and rosuvastatin are safer alternatives when azole antifungals are required.' }, { 'n': 6, 'q': 'A patient is advised to take tetracycline with milk and antacids. After one week, the infection has not improved. The most likely reason:', 'opts': ['A. Pharmacodynamic antagonism between calcium and tetracycline at the ribosome', 'B. Tetracycline undergoes rapid phase I metabolism in the presence of calcium', 'C. Chelation of tetracycline by divalent cations (Ca2+, Mg2+, Al3+) → decreased absorption', 'D. Antacid increases gastric motility, reducing tetracycline contact time'], 'ans': 'C. Chelation of tetracycline by divalent cations (Ca2+, Mg2+, Al3+) → decreased absorption', 'exp': 'Tetracyclines form insoluble chelate complexes with divalent/trivalent cations (calcium in milk/antacids, magnesium, aluminium, iron). These chelates are not absorbed, causing treatment failure. Take tetracyclines on empty stomach, 2 hours before or after dairy/antacids/iron.' }, { 'n': 7, 'q': 'A patient on warfarin is prescribed amiodarone for persistent atrial fibrillation. The expected consequence is:', 'opts': ['A. Decreased INR due to CYP enzyme induction', 'B. Increased INR due to CYP2C9 inhibition → warfarin toxicity', 'C. No significant interaction — different mechanisms of action', 'D. Increased warfarin protein binding → decreased free drug'], 'ans': 'B. Increased INR due to CYP2C9 inhibition → warfarin toxicity', 'exp': 'Amiodarone inhibits CYP2C9 (metabolising S-warfarin) and CYP1A2/CYP3A4. This increases warfarin levels substantially → elevated INR → bleeding risk. The interaction may be delayed (amiodarone half-life 40-55 days). Warfarin dose reduction (~30-50%) and close INR monitoring are essential.' }, { 'n': 8, 'q': 'Which antibiotic + drug combination is most likely to cause additive nephrotoxicity and ototoxicity?', 'opts': ['A. Amoxicillin + metronidazole', 'B. Gentamicin + furosemide', 'C. Ciprofloxacin + ibuprofen', 'D. Clindamycin + spironolactone'], 'ans': 'B. Gentamicin + furosemide', 'exp': 'Both aminoglycosides (gentamicin) and loop diuretics (furosemide) are independently nephrotoxic and ototoxic. Combined, additive/synergistic toxicity occurs in kidneys (tubular damage) and inner ear (cochlear hair cell damage). Avoid concurrent use when possible; monitor renal function carefully.' }, { 'n': 9, 'q': 'A patient takes sildenafil for erectile dysfunction and has ischaemic heart disease. He uses sublingual GTN during an anginal attack. The expected outcome is:', 'opts': ['A. GTN reduces sildenafil efficacy', 'B. Severe, potentially fatal hypotension', 'C. Mild reflex tachycardia only', 'D. Sildenafil blocks nitrate-mediated vasodilation'], 'ans': 'B. Severe, potentially fatal hypotension', 'exp': 'Nitrates (GTN) raise cGMP via NO/guanylate cyclase. PDE5 inhibitors (sildenafil) prevent cGMP degradation. Combined, cGMP accumulates massively → profound vasodilation → catastrophic hypotension. This combination is an ABSOLUTE CONTRAINDICATION. (Goodman & Gilman\\'s)' }, { 'n': 10, 'q': 'Probenecid was historically combined with penicillin because:', 'opts': ['A. Probenecid enhances GI absorption of penicillin', 'B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life', 'C. Probenecid induces CYP enzymes converting penicillin to active metabolite', 'D. Probenecid displaces penicillin from plasma protein binding'], 'ans': 'B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life', 'exp': 'Penicillin is eliminated by active tubular secretion (OAT1/OAT3 transporters). Probenecid competes for these transporters, blocking penicillin secretion, reducing renal clearance and prolonging plasma levels. This was an intentional therapeutic DDI used when penicillin was scarce (WWII era).' }, { 'n': 11, 'q': 'A patient on lithium is started on naproxen for arthritis. Serum lithium rises; he develops tremor, confusion, and arrhythmia. The mechanism is:', 'opts': ['A. Naproxen inhibits renal CYP enzymes metabolising lithium', 'B. NSAIDs inhibit renal prostaglandin synthesis → reduced GFR → decreased lithium clearance', 'C. Naproxen competes with lithium for plasma protein binding', 'D. Naproxen increases lithium tubular secretion causing paradoxical reabsorption'], 'ans': 'B. NSAIDs inhibit renal prostaglandin synthesis → reduced GFR → decreased lithium clearance', 'exp': 'Renal prostaglandins (PGE2, PGI2) maintain GFR via afferent arteriolar dilation. NSAIDs inhibit COX → reduced prostaglandins → afferent vasoconstriction → decreased GFR → lithium retention. Lithium has a narrow therapeutic index. Toxicity: neurological symptoms, cardiac arrhythmias. Avoid NSAIDs; use paracetamol instead.' }, { 'n': 12, 'q': 'Erythromycin and simvastatin are co-prescribed. The clinically significant risk is:', 'opts': ['A. Erythromycin reduces simvastatin absorption from GI tract', 'B. Both drugs independently inhibit CYP2D6', 'C. Erythromycin inhibits CYP3A4 → increased simvastatin → myopathy/rhabdomyolysis', 'D. Erythromycin is a CYP inducer reducing simvastatin plasma levels'], 'ans': 'C. Erythromycin inhibits CYP3A4 → increased simvastatin → myopathy/rhabdomyolysis', 'exp': 'Erythromycin/clarithromycin are CYP3A4 inhibitors. Simvastatin (CYP3A4 substrate) levels increase substantially with CYP3A4 inhibition → myopathy/rhabdomyolysis. Option: temporarily hold statin or use non-CYP3A4-dependent statin (pravastatin, rosuvastatin) during antibiotic course.' }, { 'n': 13, 'q': 'Which statement about pharmacodynamic drug interactions is CORRECT?', 'opts': ['A. They always involve CYP450 enzyme inhibition or induction', 'B. They occur when one drug alters the absorption of another drug', 'C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes', 'D. Pharmacodynamic interactions are always less clinically significant than pharmacokinetic ones'], 'ans': 'C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes', 'exp': 'Pharmacodynamic interactions occur at the receptor/physiological level without altering drug concentrations. QTc prolongation (IKr/hERG channel blockade) is an additive PD interaction — combining two QTc-prolonging drugs increases TdP risk. PD interactions do NOT involve CYP450 and can be equally or more clinically significant than PK interactions.' }, { 'n': 14, 'q': 'A female epileptic on carbamazepine becomes pregnant despite using oral contraceptive pills. The most likely explanation is:', 'opts': ['A. Carbamazepine inhibits CYP3A4, increasing oestrogen to supraphysiological levels', 'B. Carbamazepine is a CYP3A4 inducer → reduces OCP hormone levels → contraceptive failure', 'C. Carbamazepine interferes with progesterone receptor binding in the endometrium', 'D. Carbamazepine reduces gastric pH, impairing OCP absorption'], 'ans': 'B. Carbamazepine is a CYP3A4 inducer → reduces OCP hormone levels → contraceptive failure', 'exp': 'Carbamazepine (and phenytoin, phenobarbitone) are CYP3A4 inducers. They accelerate metabolism of oestrogen/progesterone in OCPs → subtherapeutic hormone levels → contraceptive failure. Women on enzyme-inducing AEDs must use alternative contraception (barrier methods, copper IUD, Depo-Provera).' }, { 'n': 15, 'q': 'A patient on theophylline for asthma is prescribed ciprofloxacin for UTI. Two days later he develops tachycardia, tremors, and seizures. Serum theophylline is elevated. The mechanism is:', 'opts': ['A. Ciprofloxacin induces CYP3A4, increasing theophylline synthesis', 'B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity', 'C. Ciprofloxacin displaces theophylline from albumin, increasing free drug', 'D. Ciprofloxacin competes with theophylline for renal tubular secretion'], 'ans': 'B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity', 'exp': 'Theophylline is primarily metabolised by CYP1A2. Ciprofloxacin inhibits CYP1A2, raising theophylline levels. Theophylline has a narrow therapeutic index (10-20 mg/L); toxicity at >20 mg/L causes nausea, arrhythmias, and seizures. Reduce theophylline dose 30-50% and monitor levels when co-prescribing ciprofloxacin.' }, { 'n': 16, 'q': 'Co-trimoxazole (trimethoprim + sulfamethoxazole) demonstrates which type of pharmacological interaction?', 'opts': ['A. Pharmacokinetic — CYP450 enzyme inhibition', 'B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)', 'C. Pharmaceutical incompatibility', 'D. Pharmacodynamic — functional antagonism'], 'ans': 'B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)', 'exp': 'Sulfamethoxazole inhibits dihydropteroate synthase (step 1: blocks PABA incorporation). Trimethoprim inhibits dihydrofolate reductase (step 2). Sequential blockade of the same pathway produces synergistic bactericidal activity far greater than either drug alone. This is intentional pharmacodynamic synergism — no CYP mechanism involved.' }, { 'n': 17, 'q': 'Which drug combination can cause potentially fatal hyperkalaemia?', 'opts': ['A. ACE inhibitor + loop diuretic', 'B. ACE inhibitor + spironolactone', 'C. Beta-blocker + calcium channel blocker', 'D. Warfarin + aspirin'], 'ans': 'B. ACE inhibitor + spironolactone', 'exp': 'ACE inhibitors reduce aldosterone → increased K+ retention. Spironolactone directly antagonises aldosterone → also increases K+. Combined, especially in CKD, this can cause severe, fatal hyperkalaemia. Monitor serum K+ regularly. Note: ACE inhibitor + loop diuretic causes the opposite (hypokalaemia).' }, { 'n': 18, 'q': 'Grapefruit juice significantly increases the plasma level of simvastatin because:', 'opts': ['A. It induces CYP3A4 in hepatocytes, increasing active metabolite formation', 'B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability of simvastatin', 'C. It decreases renal simvastatin excretion by inhibiting tubular secretion', 'D. It displaces simvastatin from plasma protein binding sites'], 'ans': 'B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability of simvastatin', 'exp': 'Grapefruit juice contains furanocoumarins (bergamottin) that irreversibly inhibit CYP3A4 in intestinal enterocytes. This reduces first-pass metabolism of CYP3A4 substrates (simvastatin, nifedipine, cyclosporine), increasing bioavailability 2-15-fold. Effect lasts 24-72 hours. Avoid grapefruit with statin/CCB therapy.' }, { 'n': 19, 'q': 'Which drug pair exemplifies physiological (indirect/functional) antagonism?', 'opts': ['A. Naloxone + morphine (competitive opioid receptor antagonism)', 'B. Adrenaline + histamine in anaphylaxis (opposing effects via different receptors)', 'C. Propranolol + salbutamol at beta-2 receptors (competitive receptor antagonism)', 'D. Flumazenil + diazepam (competitive benzodiazepine receptor antagonism)'], 'ans': 'B. Adrenaline + histamine in anaphylaxis (opposing effects via different receptors)', 'exp': 'Physiological antagonism: drugs act through DIFFERENT receptors to produce opposing effects. Histamine causes bronchoconstriction/hypotension (H1 receptors); adrenaline causes bronchodilation/vasoconstriction (adrenergic receptors) — countering histamine\\'s effects without receptor competition. Options A, C, D are all direct competitive receptor antagonism.' }, { 'n': 20, 'q': 'Cholestyramine, when administered to a patient on warfarin, causes subtherapeutic anticoagulation because:', 'opts': ['A. Cholestyramine inhibits CYP2C9, reducing warfarin activation', 'B. Cholestyramine binds warfarin in the GI tract, reducing its oral absorption', 'C. Cholestyramine competes with warfarin for plasma albumin binding', 'D. Cholestyramine induces hepatic CYP3A4 increasing warfarin clearance'], 'ans': 'B. Cholestyramine binds warfarin in the GI tract, reducing its oral absorption', 'exp': 'Cholestyramine (anion exchange resin) adsorbs negatively charged molecules in the GI lumen including warfarin, digoxin, thyroid hormones, and fat-soluble vitamins, preventing absorption → subtherapeutic levels. Give other medications 1 hour before or 4-6 hours after cholestyramine. Not a CYP interaction — purely absorption-based.' }, ] for mcq in mcqs: story.append(HRFlowable(width='100%', thickness=0.5, color=colors.lightgrey, spaceAfter=3)) story.append(Paragraph(f'<b>Q{mcq[\"n\"]}.</b> {mcq[\"q\"]}', qstyle)) for opt in mcq['opts']: story.append(Paragraph(opt, opt_style)) story.append(Spacer(1, 2*mm)) story.append(HRFlowable(width='100%', thickness=2, color=amber, spaceBefore=8, spaceAfter=6)) story.append(Paragraph('ANSWER KEY', h2)) ak_data = [['Q', 'Ans', 'Q', 'Ans', 'Q', 'Ans', 'Q', 'Ans', 'Q', 'Ans']] nums = list(range(1, 21)) answers = ['B','C','C','B','C','C','B','B','B','B','B','C','C','B','B','B','B','B','B','B'] row = [] for i, (n, a) in enumerate(zip(nums, answers)): row.extend([str(n), a]) if (i+1) % 5 == 0: ak_data.append(row) row = [] t = Table(ak_data, colWidths=[12*mm]*10) t.setStyle(TableStyle([ ('BACKGROUND', (0,0), (-1,0), teal), ('TEXTCOLOR', (0,0), (-1,0), colors.white), ('FONTNAME', (0,0), (-1,0), 'Helvetica-Bold'), ('FONTSIZE', (0,0), (-1,-1), 10), ('ALIGN', (0,0), (-1,-1), 'CENTER'), ('ROWBACKGROUNDS', (0,1), (-1,-1), [light, colors.white]), ('GRID', (0,0), (-1,-1), 0.5, colors.grey), ])) story.append(t) story.append(Spacer(1, 6*mm)) story.append(HRFlowable(width='100%', thickness=2, color=teal, spaceBefore=8, spaceAfter=6)) story.append(Paragraph('DETAILED EXPLANATIONS', h2)) for mcq in mcqs: story.append(Spacer(1, 2*mm)) story.append(Paragraph(f'<b>Q{mcq[\"n\"]} — Correct Answer: {mcq[\"ans\"]}</b>', answer_style)) story.append(Paragraph(mcq['exp'], body)) story.append(HRFlowable(width='100%', thickness=1, color=amber, spaceBefore=8, spaceAfter=4)) story.append(Paragraph('Sources: Goodman &amp; Gilman\\'s • Lippincott Pharmacology • Katzung 16e • Miller\\'s Anesthesia 10e • Harrison\\'s 22e • Tintinalli\\'s EM • Barash Anesthesia 9e', center_style)) doc.build(story) print('PDF created successfully') " 2>&1

Running Command

ls -lh /home/daytona/workspace/ddi-presentation/

Both files are ready. Here's a complete summary of what was created:

Downloads

📊 PPTX Presentation:

Drug Drug Interactions MBBS

Presentation · PPTX

📝 MCQ Exercise (PDF — printable):

DDI MCQ Exercise

PDF Document · PDF


What's Inside

PPTX Presentation (~65 slides, navy/teal/amber theme)

SectionSlidesTime
1 — Introduction & DefinitionsTitle, objectives, outline, what is DDI, classification, outcomes15 min
2 — PK: Absorption & DistributionChelation, pH, motility, adsorption, protein binding displacement, P-gp20 min
3 — PK: Metabolism (CYP450)CYP450 overview, isozyme table, inhibition examples, induction examples, PC BRAS / CRACK mnemonic25 min
4 — PK: ExcretionTubular secretion, urinary pH, NSAIDs + lithium/MTX10 min
5 — Pharmacodynamic DDIsAdditive, synergism, antagonism, QTc prolongation20 min
6 — Clinically Important DDIsSerotonin syndrome (alert slide), warfarin interactions, high-yield table, additional DDIs20 min
7 — Prevention & ManagementPrescribing strategies, monitoring, dose adjustment, timing10 min
MCQ Slides20 Q+A pairs with full explanations20 min

MCQ Exercise (20 Questions)

  • Clinical vignette-style, single-best-answer format
  • Topics: rifampicin/warfarin, serotonin syndrome, clopidogrel/PPI, statins/azoles, tetracycline chelation, sildenafil/nitrates, lithium/NSAIDs, co-trimoxazole synergism, QTc prolongation, grapefruit juice, and more
  • Full answer key + detailed explanations with textbook sources
Sources used: Goodman & Gilman's, Lippincott Pharmacology, Katzung 16e, Miller's Anesthesia 10e, Harrison's 22e, Tintinalli's EM, Barash Clinical Anesthesia 9e, Fuster & Hurst's The Heart 15e

can you make script for that in word file

Reading File
Running Command

ls /home/daytona/workspace/ddi-presentation/

Writing File

~/ddi-presentation/create_ddi_script.js

const {
  Document, Packer, Paragraph, TextRun, Table, TableRow, TableCell,
  Header, Footer, AlignmentType, HeadingLevel, BorderStyle, WidthType,
  ShadingType, VerticalAlign, PageNumber, NumberFormat,
  convertInchesToTwip, UnderlineType, TableLayoutType
} = require('docx');
const fs = require('fs');

// ─── COLOUR PALETTE ──────────────────────────────────────────────────────────
const NAVY  = "0D2B55";
const TEAL  = "007F8C";
const AMBER = "F4A022";
const WHITE = "FFFFFF";
const LIGHT = "E8F4F8";
const RED   = "C0392B";
const GREEN = "1A7A4A";
const DKGRAY= "444444";
const LGRAY = "AAAAAA";

// ─── HELPERS ─────────────────────────────────────────────────────────────────

function heading1(text) {
  return new Paragraph({
    heading: HeadingLevel.HEADING_1,
    spacing: { before: 360, after: 120 },
    children: [
      new TextRun({
        text,
        bold: true,
        color: WHITE,
        size: 36,
        font: "Calibri",
      }),
    ],
    shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
    indent: { left: convertInchesToTwip(0.1), right: convertInchesToTwip(0.1) },
  });
}

function heading2(text) {
  return new Paragraph({
    heading: HeadingLevel.HEADING_2,
    spacing: { before: 280, after: 80 },
    children: [
      new TextRun({
        text,
        bold: true,
        color: WHITE,
        size: 28,
        font: "Calibri",
      }),
    ],
    shading: { type: ShadingType.SOLID, color: TEAL, fill: TEAL },
    indent: { left: convertInchesToTwip(0.1) },
  });
}

function heading3(text) {
  return new Paragraph({
    spacing: { before: 200, after: 60 },
    children: [
      new TextRun({
        text,
        bold: true,
        color: AMBER,
        size: 24,
        font: "Calibri",
        underline: { type: UnderlineType.SINGLE, color: AMBER },
      }),
    ],
  });
}

function sectionBanner(num, title) {
  return [
    new Paragraph({
      spacing: { before: 400, after: 160 },
      shading: { type: ShadingType.SOLID, color: TEAL, fill: TEAL },
      indent: { left: convertInchesToTwip(0.15), right: convertInchesToTwip(0.15) },
      children: [
        new TextRun({ text: `SECTION ${num}  `, bold: true, color: AMBER, size: 22, font: "Calibri", allCaps: true }),
        new TextRun({ text: `— ${title}`, bold: true, color: WHITE, size: 22, font: "Calibri" }),
      ],
    }),
  ];
}

function bodyPara(text, opts = {}) {
  return new Paragraph({
    spacing: { before: 60, after: 60, line: 340, lineRule: "auto" },
    indent: opts.indent ? { left: convertInchesToTwip(opts.indent) } : undefined,
    children: [
      new TextRun({
        text,
        size: opts.size || 22,
        color: opts.color || DKGRAY,
        bold: opts.bold || false,
        italic: opts.italic || false,
        font: "Calibri",
      }),
    ],
  });
}

function bullet(text, opts = {}) {
  return new Paragraph({
    bullet: { level: opts.level || 0 },
    spacing: { before: 40, after: 40, line: 320, lineRule: "auto" },
    children: [
      new TextRun({
        text,
        size: opts.size || 21,
        color: opts.color || DKGRAY,
        bold: opts.bold || false,
        italic: opts.italic || false,
        font: "Calibri",
      }),
    ],
  });
}

function speakerNote(text) {
  return new Paragraph({
    spacing: { before: 120, after: 120, line: 300 },
    shading: { type: ShadingType.SOLID, color: LIGHT, fill: LIGHT },
    indent: { left: convertInchesToTwip(0.2), right: convertInchesToTwip(0.2) },
    children: [
      new TextRun({ text: "🎤 SPEAKER: ", bold: true, color: TEAL, size: 20, font: "Calibri" }),
      new TextRun({ text, size: 20, color: DKGRAY, italic: true, font: "Calibri" }),
    ],
  });
}

function timing(text) {
  return new Paragraph({
    spacing: { before: 80, after: 60 },
    children: [
      new TextRun({ text: `⏱ ${text}`, bold: true, color: AMBER, size: 20, font: "Calibri" }),
    ],
  });
}

function keyPoint(text) {
  return new Paragraph({
    spacing: { before: 100, after: 60 },
    shading: { type: ShadingType.SOLID, color: "FFF3CD", fill: "FFF3CD" },
    indent: { left: convertInchesToTwip(0.15) },
    children: [
      new TextRun({ text: "★ KEY POINT: ", bold: true, color: AMBER, size: 21, font: "Calibri" }),
      new TextRun({ text, size: 21, color: DKGRAY, bold: true, font: "Calibri" }),
    ],
  });
}

function clinicalAlert(text) {
  return new Paragraph({
    spacing: { before: 120, after: 120 },
    shading: { type: ShadingType.SOLID, color: "FDECEA", fill: "FDECEA" },
    indent: { left: convertInchesToTwip(0.15) },
    children: [
      new TextRun({ text: "⚠ CLINICAL ALERT: ", bold: true, color: RED, size: 21, font: "Calibri" }),
      new TextRun({ text, size: 21, color: RED, font: "Calibri" }),
    ],
  });
}

function divider() {
  return new Paragraph({
    spacing: { before: 160, after: 160 },
    border: { bottom: { style: BorderStyle.SINGLE, size: 6, color: TEAL } },
    children: [],
  });
}

function emptyLine() {
  return new Paragraph({ children: [new TextRun({ text: "" })] });
}

function makeTable(headers, rows, colWidths) {
  const headerRow = new TableRow({
    tableHeader: true,
    children: headers.map((h, i) => new TableCell({
      width: { size: colWidths[i], type: WidthType.DXA },
      shading: { type: ShadingType.SOLID, color: TEAL, fill: TEAL },
      verticalAlign: VerticalAlign.CENTER,
      children: [new Paragraph({
        alignment: AlignmentType.CENTER,
        children: [new TextRun({ text: h, bold: true, color: WHITE, size: 19, font: "Calibri" })],
      })],
    })),
  });
  const dataRows = rows.map((row, ri) => new TableRow({
    children: row.map((cell, ci) => new TableCell({
      width: { size: colWidths[ci], type: WidthType.DXA },
      shading: { type: ShadingType.SOLID, color: ri % 2 === 0 ? LIGHT : WHITE, fill: ri % 2 === 0 ? LIGHT : WHITE },
      verticalAlign: VerticalAlign.CENTER,
      children: [new Paragraph({
        alignment: AlignmentType.CENTER,
        spacing: { before: 40, after: 40 },
        children: [new TextRun({ text: cell, size: 17, color: DKGRAY, font: "Calibri" })],
      })],
    })),
  }));
  return new Table({
    layout: TableLayoutType.FIXED,
    rows: [headerRow, ...dataRows],
    width: { size: 9360, type: WidthType.DXA },
    borders: {
      top: { style: BorderStyle.SINGLE, size: 4, color: LGRAY },
      bottom: { style: BorderStyle.SINGLE, size: 4, color: LGRAY },
      left: { style: BorderStyle.SINGLE, size: 4, color: LGRAY },
      right: { style: BorderStyle.SINGLE, size: 4, color: LGRAY },
      insideH: { style: BorderStyle.SINGLE, size: 2, color: LGRAY },
      insideV: { style: BorderStyle.SINGLE, size: 2, color: LGRAY },
    },
  });
}

// ─── CONTENT ─────────────────────────────────────────────────────────────────

const children = [];

// ═══════════════════════════════════════════════════════════════════════════
// TITLE PAGE
// ═══════════════════════════════════════════════════════════════════════════
children.push(
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 800, after: 200 },
    shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
    children: [
      new TextRun({ text: "LECTURE SCRIPT", bold: true, color: AMBER, size: 28, font: "Calibri", allCaps: true }),
    ],
  }),
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 100, after: 100 },
    shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
    children: [
      new TextRun({ text: "Drug–Drug Interactions", bold: true, color: WHITE, size: 52, font: "Calibri" }),
    ],
  }),
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 80, after: 80 },
    shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
    children: [
      new TextRun({ text: "UG MBBS Pharmacology  |  2-Hour Lecture Session", color: AMBER, size: 24, italic: true, font: "Calibri" }),
    ],
  }),
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 60, after: 400 },
    shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
    children: [
      new TextRun({ text: "Sources: Goodman & Gilman's  •  Lippincott  •  Katzung 16e  •  Harrison's 22e  •  Tintinalli's EM", color: LGRAY, size: 18, font: "Calibri" }),
    ],
  }),
  emptyLine(),
  bodyPara("HOW TO USE THIS SCRIPT", { bold: true, color: TEAL, size: 24 }),
  bullet("Each section begins with a TIMING guide and learning objective for that block.", { level: 0 }),
  bullet("Blue 🎤 SPEAKER boxes contain suggested spoken words — adapt freely to your style.", { level: 0 }),
  bullet("Amber ★ KEY POINT boxes highlight the most exam-relevant facts.", { level: 0 }),
  bullet("Red ⚠ CLINICAL ALERT boxes flag dangerous or life-threatening interactions.", { level: 0 }),
  bullet("Pause for questions at the end of each section.", { level: 0 }),
  divider(),
);

// ═══════════════════════════════════════════════════════════════════════════
// SESSION OUTLINE
// ═══════════════════════════════════════════════════════════════════════════
children.push(heading1("SESSION OUTLINE"));
children.push(
  makeTable(
    ["Section", "Topic", "Duration"],
    [
      ["1", "Introduction & Definitions", "15 min"],
      ["2", "PK DDIs: Absorption & Distribution", "20 min"],
      ["3", "PK DDIs: Metabolism — CYP450", "25 min"],
      ["4", "PK DDIs: Excretion", "10 min"],
      ["5", "Pharmacodynamic DDIs", "20 min"],
      ["6", "Clinically Important DDI Examples", "20 min"],
      ["7", "Prevention & Management", "10 min"],
      ["MCQ", "20-Question MCQ Exercise", "20 min"],
    ],
    [2200, 4960, 2200]
  ),
  emptyLine(),
  divider(),
);

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 1 — INTRODUCTION
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(1, "Introduction & Definitions"));
children.push(timing("15 minutes"));
children.push(emptyLine());

children.push(heading2("Opening — Setting the Scene"));
children.push(speakerNote(
  "Good morning everyone. Today we're spending two hours on one of the most clinically important topics in pharmacology — drug-drug interactions, or DDIs. " +
  "This is not just an exam topic. Every practising doctor encounters DDIs. Studies show that up to 30% of hospitalised patients experience at least one clinically relevant drug interaction. " +
  "Many of these are preventable. By the end of today, you will be able to identify, predict, and manage the most important DDIs — and that will directly protect your future patients."
));
children.push(emptyLine());

children.push(heading2("What is a Drug–Drug Interaction?"));
children.push(speakerNote(
  "Let's start with the definition. A drug-drug interaction is an in vivo phenomenon — meaning it occurs inside the body — where administration of one drug alters the effects or kinetics of another drug. " +
  "That phrase 'in vivo' is important. We are NOT talking about in vitro mixing of drugs in a syringe or IV bag — those are called pharmaceutical incompatibilities, not drug interactions."
));
children.push(bullet("Definition (Miller's Anesthesia, 10e): An in vivo phenomenon where one drug alters the effects or kinetics of another.", { bold: false }));
children.push(bullet("In vitro physical/chemical incompatibilities — NOT drug interactions.", { bold: false, color: RED }));
children.push(bullet("Result: Increased efficacy, decreased efficacy, OR enhanced toxicity.", { bold: false }));
children.push(keyPoint("DDIs are one of the most preventable causes of adverse drug events."));
children.push(emptyLine());

children.push(heading2("Why Do DDIs Matter? — Scope"));
children.push(speakerNote(
  "Now, you might ask — how common are these? The numbers are alarming. Up to 30% of hospitalised patients experience a clinically relevant drug interaction. " +
  "Which patients are at highest risk? The elderly — because they are often on many drugs simultaneously, a situation we call polypharmacy. " +
  "Drugs with a narrow therapeutic index, like warfarin, digoxin, lithium, and theophylline, are particularly dangerous because small changes in drug levels can tip from therapeutic to toxic."
));
children.push(bullet("Up to 30% of hospitalised patients experience a clinically relevant DDI.", { bold: true }));
children.push(bullet("HIGH-RISK GROUPS:", { bold: true, color: TEAL }));
children.push(bullet("Elderly patients on polypharmacy regimens", { level: 1 }));
children.push(bullet("Drugs with narrow therapeutic index (NTI): warfarin, digoxin, lithium, theophylline, phenytoin", { level: 1 }));
children.push(bullet("Patients with hepatic or renal impairment (reduced drug clearance)", { level: 1 }));
children.push(bullet("HIV/TB/cancer patients on complex multi-drug regimens", { level: 1 }));
children.push(emptyLine());

children.push(heading2("Classification of DDIs"));
children.push(speakerNote(
  "We classify DDIs into two broad categories — pharmacokinetic and pharmacodynamic. Write these down. " +
  "Pharmacokinetic interactions are the most common and important for your exams. They occur when one drug changes the absorption, distribution, metabolism, or excretion — remember ADME — of another drug. " +
  "Pharmacodynamic interactions are when two drugs act on the same target or produce opposing or additive physiological effects, without necessarily changing each other's blood levels."
));
children.push(heading3("PHARMACOKINETIC DDIs"));
children.push(bullet("One drug alters ADME of another drug (Absorption, Distribution, Metabolism, Excretion)", { bold: false }));
children.push(bullet("Most common and best understood type", { bold: false }));
children.push(bullet("Mechanism is predictable from pharmacokinetic principles", { bold: false }));
children.push(heading3("PHARMACODYNAMIC DDIs"));
children.push(bullet("Drugs act on the same receptor, enzyme, or physiological system", { bold: false }));
children.push(bullet("Results: Additive, synergistic, or antagonistic effects", { bold: false }));
children.push(bullet("Drug plasma levels may remain unchanged", { bold: false }));
children.push(emptyLine());

children.push(heading2("Outcomes of DDIs — Beneficial vs Harmful"));
children.push(speakerNote(
  "Not all drug interactions are bad. Some are deliberately used for therapeutic benefit. Let me give you three great examples. " +
  "Co-trimoxazole combines trimethoprim and sulfamethoxazole — each drug blocks a different step in bacterial folate synthesis, producing synergistic bactericidal activity. " +
  "Levodopa plus carbidopa — carbidopa blocks peripheral DOPA decarboxylase, so more levodopa reaches the brain. " +
  "And in HIV, we intentionally use ritonavir as a 'booster' — it is a CYP3A4 inhibitor that raises levels of other antiretrovirals. These are all intentional, beneficial DDIs. " +
  "But most DDIs we worry about are unintentional and harmful."
));
children.push(bullet("BENEFICIAL (intentional):", { bold: true, color: GREEN }));
children.push(bullet("Co-trimoxazole: trimethoprim + sulfamethoxazole → synergistic folate pathway blockade", { level: 1 }));
children.push(bullet("Levodopa + carbidopa → carbidopa blocks peripheral conversion → more levodopa reaches CNS", { level: 1 }));
children.push(bullet("HIV therapy: ritonavir as CYP3A4 'booster' to raise other antiretroviral levels", { level: 1 }));
children.push(bullet("HARMFUL (unintentional):", { bold: true, color: RED }));
children.push(bullet("Warfarin + NSAIDs → GI bleeding", { level: 1 }));
children.push(bullet("Rifampicin + OCP → contraceptive failure", { level: 1 }));
children.push(bullet("MAOI + meperidine → serotonin syndrome (potentially fatal)", { level: 1, color: RED }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 2 — ABSORPTION & DISTRIBUTION
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(2, "Pharmacokinetic DDIs — Absorption & Distribution"));
children.push(timing("20 minutes"));
children.push(emptyLine());

children.push(heading2("Absorption-Based DDIs"));
children.push(speakerNote(
  "Let's go through the four main mechanisms of absorption-based interactions. The first — and probably the most high-yield for your exams — is chelation. " +
  "Think about tetracyclines and fluoroquinolones. These antibiotics form insoluble complexes — chelates — with divalent cations like calcium in milk or antacids, magnesium, aluminium, and iron. " +
  "The chelate cannot be absorbed. The drug doesn't reach the bloodstream. The infection doesn't get treated. The student fails the question. " +
  "The solution is simple: take tetracyclines on an empty stomach, at least two hours before or after any dairy, antacids, or iron tablets."
));

children.push(heading3("1. Chelation / Complex Formation"));
children.push(bullet("Tetracyclines + Ca²⁺, Mg²⁺, Al³⁺ (antacids, dairy, iron) → insoluble chelates → ↓ absorption → treatment failure", { bold: false }));
children.push(bullet("Fluoroquinolones (ciprofloxacin, norfloxacin) + antacids/iron → same mechanism", { bold: false }));
children.push(keyPoint("Separate tetracyclines/fluoroquinolones from antacids/iron by at least 2 hours."));

children.push(heading3("2. Altered Gastric pH"));
children.push(speakerNote(
  "PPIs and H2 blockers raise the gastric pH. Many drugs require an acidic environment for absorption. " +
  "Ketoconazole and itraconazole require low pH to dissolve. Atazanavir, an HIV drug, requires acidic pH. " +
  "If you add a PPI, you create an alkaline environment and these drugs cannot be absorbed. This is clinically very relevant in HIV patients who are also on a PPI for gastroprotection."
));
children.push(bullet("PPIs / H2-blockers → ↑ gastric pH → ↓ dissolution of: ketoconazole, itraconazole, atazanavir", { bold: false }));
children.push(bullet("Omeprazole: also inhibits CYP2C9/CYP1A2 → ↑ warfarin levels → ↑ bleeding risk (Lippincott)", { bold: false, color: RED }));

children.push(heading3("3. Altered GI Motility"));
children.push(bullet("Metoclopramide → ↑ gastric emptying → faster absorption (↑ peak Cmax) of paracetamol", { bold: false }));
children.push(bullet("Anticholinergics (atropine, hyoscine) → ↓ motility → delayed/reduced absorption of some drugs", { bold: false }));

children.push(heading3("4. Adsorption (Drug Binding in GI Tract)"));
children.push(speakerNote(
  "Cholestyramine is a resin that acts like a sponge in the gut. It non-specifically binds many drugs including warfarin, digoxin, and thyroid hormones. " +
  "The rule is: give other drugs one hour before or four to six hours after cholestyramine to avoid this interaction."
));
children.push(bullet("Cholestyramine (bile acid sequestrant) binds: warfarin, digoxin, thyroid hormones, fat-soluble vitamins", { bold: false }));
children.push(bullet("Rule: Take other medications 1 hour BEFORE or 4–6 hours AFTER cholestyramine.", { bold: true, color: TEAL }));
children.push(emptyLine());

children.push(heading2("Distribution-Based DDIs — Protein Binding Displacement"));
children.push(speakerNote(
  "Here's a concept that sounds dramatic but is often overemphasised in practice. Most drugs are bound to plasma proteins, mainly albumin. Only the free, unbound fraction is pharmacologically active. " +
  "When Drug A displaces Drug B from albumin, more of Drug B is suddenly free. In theory, this should amplify its effect — and it does, transiently. " +
  "But in practice, the increased free drug is also more available for metabolism and elimination, so the effect is short-lived. " +
  "The most important clinical example is warfarin displacement — especially by NSAIDs, valproate, and sulfonamides. " +
  "A truly dangerous displacement is sulfonamides given to neonates — they displace bilirubin from albumin, and free bilirubin deposits in the brain causing kernicterus."
));
children.push(bullet("Only FREE (unbound) drug is pharmacologically active.", { bold: true, color: TEAL }));
children.push(bullet("Displacement: Drug A displaces Drug B from albumin → transient ↑ free Drug B → ↑ effect/toxicity", { bold: false }));
children.push(bullet("WARFARIN (99% protein bound) displaced by: NSAIDs, sulfonamides, valproate → ↑ free warfarin → ↑ bleeding", { bold: false, color: RED }));
children.push(clinicalAlert("Sulfonamides in neonates displace bilirubin from albumin → kernicterus. NEVER give sulfonamides to neonates or late pregnancy."));
children.push(keyPoint("Protein binding displacement effects are usually transient. Most significant with narrow TI drugs, high binding (>90%), low Vd, impaired clearance."));

children.push(heading3("P-Glycoprotein (P-gp) Transporter Interactions"));
children.push(speakerNote(
  "A newer and increasingly important mechanism involves efflux transporters, particularly P-glycoprotein, or P-gp. " +
  "This transporter pumps drugs OUT of cells. Digoxin is a substrate for P-gp. " +
  "Clarithromycin and verapamil inhibit P-gp — so digoxin is not effluxed from cells, it accumulates, and digoxin toxicity can result. " +
  "This explains why you must monitor digoxin levels when adding macrolide antibiotics or verapamil."
));
children.push(bullet("P-gp is an efflux transporter that pumps substrates out of enterocytes and other cells", { bold: false }));
children.push(bullet("Digoxin (P-gp substrate) + clarithromycin or verapamil (P-gp inhibitors) → ↑ digoxin levels → toxicity (arrhythmias, nausea, visual disturbances)", { bold: false, color: RED }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 3 — METABOLISM / CYP450
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(3, "Pharmacokinetic DDIs — Metabolism & CYP450"));
children.push(timing("25 minutes — THE MOST IMPORTANT SECTION"));
children.push(emptyLine());

children.push(heading2("CYP450 — The Metabolic Machinery"));
children.push(speakerNote(
  "This is the most important section of today's lecture, and it's worth spending the most time here. " +
  "The cytochrome P450 enzyme system is a family of enzymes located mainly in the liver and intestinal wall. They are responsible for phase I metabolism — oxidation, reduction, hydrolysis — of most drugs. " +
  "CYP3A4 is the king. It metabolises approximately 50% of all drugs in clinical use. CYP3A4 is also found in the intestine, which is important for first-pass metabolism and drug bioavailability. " +
  "There is enormous variability between individuals — up to 20-fold in CYP3A4 activity. This explains why the same dose of a drug can be therapeutic in one patient and toxic in another."
));
children.push(bullet("CYP450 enzymes: mainly in liver (also intestine, kidney, lung, placenta)", { bold: false }));
children.push(bullet("CYP3A4: metabolises ~50% of all drugs in clinical use — the most important isoform", { bold: true, color: TEAL }));
children.push(bullet("Other key isoforms: CYP2D6, CYP1A2, CYP2C9, CYP2C19, CYP2E1", { bold: false }));
children.push(bullet("Interindividual variability: up to 20-fold in CYP3A4 activity (Dermatology 5e)", { bold: false }));
children.push(bullet("Genetic polymorphisms: Poor metabolisers vs Ultrarapid metabolisers — key for drugs like codeine (CYP2D6)", { bold: false }));
children.push(emptyLine());

children.push(heading2("Two Mechanisms: Inhibition vs Induction"));
children.push(speakerNote(
  "There are exactly two ways a drug can alter CYP450 activity — inhibition and induction. Remember these clearly. " +
  "Inhibition: Drug A blocks the enzyme. Drug B cannot be metabolised. Drug B accumulates in the plasma. Toxicity results. " +
  "Inhibition is usually rapid — within hours of starting the inhibitor drug. " +
  "Induction: Drug A increases the synthesis of more CYP enzyme. Drug B is now metabolised faster. Drug B plasma levels fall. Therapeutic failure results. " +
  "Induction is SLOW — it takes days to weeks, because we have to wait for new enzyme protein to be synthesised."
));

children.push(heading3("INHIBITION — Drug Toxicity"));
children.push(bullet("Inhibitor blocks CYP enzyme → substrate drug NOT metabolised → plasma levels RISE → toxicity", { bold: false, color: RED }));
children.push(bullet("Onset: RAPID — hours after starting the inhibitor", { bold: true }));
children.push(bullet("Most common mechanism: competition for the same enzyme active site", { bold: false }));

children.push(heading3("INDUCTION — Therapeutic Failure"));
children.push(bullet("Inducer upregulates CYP enzyme synthesis → substrate drug metabolised FASTER → plasma levels FALL → failure", { bold: false, color: "E67E22" }));
children.push(bullet("Onset: SLOW — days to weeks (new enzyme protein synthesis required)", { bold: true }));
children.push(bullet("On stopping the inducer, enzyme levels normalise over similar time frame → watch for rebound toxicity", { bold: false }));
children.push(emptyLine());

children.push(heading2("CYP Isozyme Reference Table"));
children.push(speakerNote(
  "Here is the table you need to memorise for exams. Focus on CYP3A4 and CYP2D6 first, as they are the most high-yield. " +
  "Look at the inhibitors column — notice that ketoconazole, ritonavir, clarithromycin, and erythromycin all inhibit CYP3A4. " +
  "Look at the inducers column — rifampicin, phenytoin, carbamazepine, and phenobarbitone all induce CYP3A4. " +
  "One key exception — CYP2D6 is NOT inducible. This matters clinically because CYP2D6 inhibitors like fluoxetine and paroxetine can accumulate to much higher degrees."
));
children.push(
  makeTable(
    ["Isozyme", "Key Substrates", "Inhibitors", "Inducers"],
    [
      ["CYP3A4/5", "Cyclosporine, simvastatin, nifedipine, erythromycin, HIV PIs, carbamazepine", "Ketoconazole, ritonavir, clarithromycin, diltiazem, grapefruit juice", "Rifampicin, phenytoin, phenobarbitone, carbamazepine, dexamethasone"],
      ["CYP2D6", "Fluoxetine, haloperidol, paroxetine, propranolol, tramadol, codeine", "Fluoxetine, paroxetine, amiodarone, quinidine", "None (not inducible)"],
      ["CYP1A2", "Theophylline, caffeine, clozapine, R-warfarin", "Fluvoxamine, ciprofloxacin, cimetidine", "Rifampicin, smoking, omeprazole"],
      ["CYP2C9", "S-warfarin, phenytoin, NSAIDs, glipizide", "Fluconazole, amiodarone, valproate", "Rifampicin, carbamazepine"],
      ["CYP2C19", "Omeprazole, diazepam, clopidogrel (prodrug), citalopram", "Fluoxetine, fluvoxamine, esomeprazole", "Rifampicin, carbamazepine"],
    ],
    [1100, 2900, 2700, 2700]
  )
);
children.push(emptyLine());

children.push(heading2("Memory Mnemonics"));
children.push(speakerNote(
  "Let me give you two mnemonics that will save you in the exam. " +
  "For CYP3A4 INDUCERS — remember PC BRAS: Phenytoin, Carbamazepine, Barbiturates (phenobarbitone), Rifampicin, Alcohol chronic, Smoking. " +
  "For CYP3A4 INHIBITORS — remember CRACK: Cimetidine, Ritonavir, Azole antifungals, Clarithromycin/erythromycin, Ketoconazole. Plus grapefruit juice. " +
  "Remember the consequences — inhibitors cause TOXICITY because drug levels rise. Inducers cause THERAPEUTIC FAILURE because drug levels fall."
));
children.push(bullet("CYP3A4 INDUCERS — PC BRAS:", { bold: true, color: "E67E22" }));
children.push(bullet("Phenytoin, Carbamazepine, Barbiturates, Rifampicin, Alcohol (chronic), Smoking", { level: 1 }));
children.push(bullet("CYP3A4 INHIBITORS — CRACK (+Grapefruit):", { bold: true, color: RED }));
children.push(bullet("Cimetidine, Ritonavir, Azole antifungals, Clarithromycin/erythromycin, Ketoconazole", { level: 1 }));
children.push(keyPoint("INHIBITORS → drug TOXICITY (levels rise) | INDUCERS → therapeutic FAILURE (levels fall)"));
children.push(emptyLine());

children.push(heading2("CYP Inhibition — Key Clinical Examples"));
children.push(speakerNote(
  "Let me walk you through the most important CYP inhibition interactions. These are the ones most likely to appear in your exams and cause harm in clinical practice."
));
children.push(bullet("KETOCONAZOLE + SIMVASTATIN: CYP3A4 inhibition → ↑ statin up to 20-fold → rhabdomyolysis. CONTRAINDICATED.", { bold: false, color: RED }));
children.push(bullet("CLARITHROMYCIN + DIGOXIN: CYP3A4 + P-gp inhibition → ↑ digoxin → arrhythmias, toxicity. Reduce digoxin dose.", { bold: false, color: RED }));
children.push(bullet("OMEPRAZOLE + WARFARIN: Omeprazole inhibits CYP isozymes metabolising warfarin → ↑ warfarin → ↑ bleeding (Lippincott).", { bold: false }));
children.push(bullet("OMEPRAZOLE + CLOPIDOGREL: Inhibits CYP2C19 → clopidogrel (a prodrug) not activated → ↓ antiplatelet effect → stent thrombosis. Use pantoprazole instead.", { bold: false, color: RED }));
children.push(bullet("RITONAVIR as BOOSTER: Potent CYP3A4 inhibitor used INTENTIONALLY to boost lopinavir levels in HIV therapy.", { bold: false, color: GREEN }));
children.push(emptyLine());

children.push(heading2("CYP Induction — Key Clinical Examples"));
children.push(speakerNote(
  "Now for induction. Rifampicin is the classic enzyme inducer — it is so potent that it can reduce cyclosporine levels to subtherapeutic concentrations, causing organ rejection. " +
  "The oral contraceptive interaction with rifampicin is extremely high-yield. When a woman on OCPs starts rifampicin for TB, the oestrogen and progesterone in the pill are metabolised faster. " +
  "Plasma hormone levels drop below the threshold needed to suppress ovulation. Contraceptive failure. Unplanned pregnancy. " +
  "She must be counselled to use additional barrier contraception throughout the rifampicin course and for at least one month after stopping."
));
children.push(bullet("RIFAMPICIN + OCP: CYP3A4 induction → ↑ oestrogen/progesterone metabolism → contraceptive FAILURE → unintended pregnancy.", { bold: false, color: RED }));
children.push(bullet("RIFAMPICIN + WARFARIN: ↑ warfarin metabolism → INR falls → subtherapeutic anticoagulation → thrombosis.", { bold: false }));
children.push(bullet("RIFAMPICIN + CYCLOSPORINE: ↑ cyclosporine metabolism → subtherapeutic levels → transplant REJECTION.", { bold: false, color: RED }));
children.push(bullet("RIFAMPICIN + HIV PIs: ↓ protease inhibitor levels → treatment failure/resistance. Use rifabutin instead.", { bold: false }));
children.push(bullet("ANTIEPILEPTICS (carbamazepine, phenytoin, phenobarbitone) + OCP/warfarin/corticosteroids/cyclosporine → same induction problem.", { bold: false }));
children.push(heading3("Special Case: Grapefruit Juice"));
children.push(speakerNote(
  "Grapefruit juice deserves special mention. It contains compounds called furanocoumarins that IRREVERSIBLY inhibit CYP3A4 in the intestinal wall — not the liver. " +
  "This increases the oral bioavailability of CYP3A4 substrates, sometimes dramatically. One glass can increase simvastatin levels several-fold. " +
  "The effect is NOT about how much grapefruit juice you drink — even a small amount is enough. And the effect lasts 24 to 72 hours after consumption."
));
children.push(bullet("Grapefruit juice furanocoumarins irreversibly inhibit INTESTINAL CYP3A4 → ↑ bioavailability of: simvastatin, nifedipine, cyclosporine", { bold: false }));
children.push(bullet("Effect persists 24–72 hours after drinking. Even a small amount matters. Avoid entirely with affected drugs.", { bold: true, color: AMBER }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 4 — EXCRETION
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(4, "Pharmacokinetic DDIs — Excretion"));
children.push(timing("10 minutes"));
children.push(emptyLine());

children.push(heading2("Renal Excretion DDIs"));
children.push(speakerNote(
  "Renal drug excretion involves three processes: glomerular filtration, active tubular secretion, and passive tubular reabsorption. " +
  "DDIs can occur at any of these steps. The most important mechanism is competition for active tubular secretion transporters."
));

children.push(heading3("1. Competition for Tubular Secretion"));
children.push(bullet("Classic: PROBENECID + PENICILLIN — probenecid blocks OAT-mediated penicillin secretion → prolonged penicillin half-life. Historical intentional DDI.", { bold: false, color: GREEN }));
children.push(bullet("METHOTREXATE + NSAIDs — NSAIDs reduce renal blood flow AND compete for tubular secretion → ↑ methotrexate → myelosuppression, mucositis. DANGEROUS.", { bold: false, color: RED }));
children.push(clinicalAlert("NSAIDs + methotrexate: NSAIDs should be withheld during high-dose methotrexate therapy. Risk of fatal myelosuppression."));

children.push(heading3("2. Urinary pH Manipulation"));
children.push(speakerNote(
  "This is elegant pharmacology. Weak acids are excreted faster in alkaline urine because they are ionised and cannot be reabsorbed. " +
  "So in aspirin overdose, we alkalinise the urine with sodium bicarbonate — this traps the ionised salicylate in the tubule and increases its excretion. " +
  "Conversely, acidifying the urine (ammonium chloride) increases excretion of weak bases like amphetamines."
));
children.push(bullet("Alkaline urine (NaHCO₃) → ↑ ionisation and excretion of WEAK ACIDS: aspirin, barbiturates, methotrexate", { bold: false }));
children.push(bullet("Acid urine → ↑ excretion of WEAK BASES: amphetamines, quinine", { bold: false }));
children.push(bullet("Clinical use: Alkaline diuresis in salicylate/barbiturate overdose management", { bold: false, color: TEAL }));

children.push(heading3("3. NSAIDs and Renal Clearance of Multiple Drugs"));
children.push(bullet("NSAIDs inhibit prostaglandin synthesis → ↓ afferent arteriolar dilation → ↓ GFR → ↓ renal clearance", { bold: false }));
children.push(bullet("LITHIUM + NSAIDs/THIAZIDES → ↑ lithium reabsorption → lithium toxicity (tremor, confusion, arrhythmias)", { bold: false, color: RED }));
children.push(bullet("METFORMIN + NSAIDs → ↓ renal metformin excretion → ↑ lactic acidosis risk (especially in renal impairment)", { bold: false }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 5 — PHARMACODYNAMIC DDIs
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(5, "Pharmacodynamic Drug–Drug Interactions"));
children.push(timing("20 minutes"));
children.push(emptyLine());

children.push(heading2("Types of Pharmacodynamic Interactions"));
children.push(speakerNote(
  "Pharmacodynamic interactions are fundamentally different from pharmacokinetic ones. " +
  "Here, both drugs reach their sites of action perfectly well — no changes in absorption, metabolism, or elimination. " +
  "Instead, they interact at the level of receptors, enzymes, or physiological systems. " +
  "We classify them as additive, synergistic, potentiation, or antagonistic."
));

children.push(heading3("ADDITIVE EFFECT (1 + 1 = 2)"));
children.push(bullet("Combined effect equals sum of individual effects", { bold: false }));
children.push(bullet("Example: Two CNS depressants — alcohol + benzodiazepine → additive CNS and respiratory depression", { bold: false }));
children.push(bullet("Example: Two antihypertensives → additive blood pressure lowering", { bold: false }));

children.push(heading3("SYNERGISM (1 + 1 > 2)"));
children.push(bullet("Combined effect exceeds the sum — each drug enhances the other's action", { bold: false }));
children.push(bullet("Co-trimoxazole: trimethoprim (DHFR inhibitor) + sulfamethoxazole (PABA competitor) → sequential folate pathway blockade → synergistic kill", { bold: false }));
children.push(bullet("β-lactam + aminoglycoside → synergistic bactericidal effect", { bold: false }));

children.push(heading3("POTENTIATION"));
children.push(bullet("One drug has NO effect alone but enhances the other's effect (0 + 1 = >1)", { bold: false }));
children.push(bullet("Carbidopa potentiates levodopa — carbidopa alone has no antiparkinsonian effect", { bold: false }));

children.push(heading3("ANTAGONISM (1 + 1 < 1 or = 0)"));
children.push(bullet("One drug reduces or abolishes another's effect", { bold: false }));
children.push(bullet("COMPETITIVE ANTAGONISM: Naloxone (opioid antagonist) reverses morphine; flumazenil reverses benzodiazepines", { bold: false }));
children.push(bullet("PHYSIOLOGICAL ANTAGONISM: Adrenaline counter-acts histamine effects in anaphylaxis — opposing effects via DIFFERENT receptors", { bold: false, color: TEAL }));
children.push(bullet("PHARMACOKINETIC antagonism: rifampicin reduces warfarin levels (technically PK, but clinically looks like antagonism)", { bold: false }));
children.push(emptyLine());

children.push(heading2("QTc Prolongation — A Critical Pharmacodynamic DDI"));
children.push(speakerNote(
  "QTc prolongation is one of the most dangerous pharmacodynamic interactions, and it's incredibly common because so many drugs prolong the QT interval. " +
  "The mechanism: both drugs block the IKr potassium channel — the hERG channel — which is responsible for repolarisation. " +
  "Block this channel with two drugs simultaneously and the additive effect on QT prolongation greatly increases the risk of a potentially fatal arrhythmia called Torsades de Pointes — a polymorphic ventricular tachycardia. " +
  "High-risk combinations include: antipsychotics with antibiotics like azithromycin or moxifloxacin; methadone with fluoroquinolones; ondansetron with antipsychotics. " +
  "Risk factors that amplify danger include hypokalaemia, hypomagnesaemia, female sex, bradycardia, and pre-existing heart disease."
));
children.push(bullet("Mechanism: Additive blockade of IKr (hERG) K⁺ channels → ↑ QTc → Torsades de Pointes → sudden death", { bold: false, color: RED }));
children.push(bullet("HIGH-RISK COMBINATIONS:", { bold: true, color: RED }));
children.push(bullet("Antipsychotics (haloperidol, quetiapine) + fluoroquinolones (moxifloxacin) or macrolides (azithromycin)", { level: 1 }));
children.push(bullet("Methadone + fluoroquinolones", { level: 1 }));
children.push(bullet("Amiodarone/sotalol + any other QTc-prolonging drug", { level: 1 }));
children.push(bullet("Ondansetron + antipsychotics", { level: 1 }));
children.push(bullet("AMPLIFYING RISK FACTORS: Hypokalaemia, hypomagnesaemia, bradycardia, female sex, structural heart disease", { bold: true, color: AMBER }));
children.push(keyPoint("Always check QTc-prolonging potential before adding a second drug to a patient already on a QTc-prolonging agent. Use CredibleMeds database."));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 6 — CLINICAL EXAMPLES
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(6, "Clinically Important DDI Examples"));
children.push(timing("20 minutes"));
children.push(emptyLine());

children.push(heading2("Serotonin Syndrome — A Life-Threatening DDI"));
children.push(speakerNote(
  "I want to spend some time on serotonin syndrome because it is both high-yield for exams and genuinely life-threatening in clinical practice. " +
  "Serotonin syndrome occurs when there is excessive serotonergic activity in the central nervous system. " +
  "The CLASSIC combination causing the most severe form is: MAOI + meperidine. This is an absolute contraindication. " +
  "The MAOI prevents breakdown of serotonin via monoamine oxidase. Meperidine inhibits serotonin reuptake. Together, serotonin accumulates massively. " +
  "Other dangerous combinations include MAOI with any SSRI or SNRI — patients switching from an MAOI to an SSRI must have a 14-day washout period. For fluoxetine switching to an MAOI, it's 5 weeks because of fluoxetine's long half-life. " +
  "Linezolid — the antibiotic — has weak MAOI activity. Never combine linezolid with SSRIs. " +
  "The clinical triad: mental status changes (agitation, confusion), autonomic instability (hyperthermia, tachycardia, diaphoresis, hypertension), and neuromuscular abnormalities (clonus, hyperreflexia, tremor — clonus is the hallmark)."
));
children.push(clinicalAlert("MAOI + meperidine / SSRIs / SNRIs / tramadol → Serotonin Syndrome — ABSOLUTE CONTRAINDICATION. Can be FATAL."));
children.push(bullet("Mechanism: Excess CNS serotonin at 5-HT1A and 5-HT2A receptors", { bold: false }));
children.push(bullet("CLINICAL TRIAD:", { bold: true, color: TEAL }));
children.push(bullet("Mental status changes: agitation, confusion, restlessness", { level: 1 }));
children.push(bullet("Autonomic instability: hyperthermia, tachycardia, diaphoresis, hypertension", { level: 1 }));
children.push(bullet("Neuromuscular: CLONUS (hallmark), hyperreflexia, tremor, rigidity", { level: 1, bold: true }));
children.push(bullet("DANGEROUS COMBINATIONS:", { bold: true, color: RED }));
children.push(bullet("MAOI + meperidine (most classic)", { level: 1, color: RED }));
children.push(bullet("MAOI + any SSRI/SNRI", { level: 1, color: RED }));
children.push(bullet("MAOI + tramadol, tryptophan, fentanyl", { level: 1 }));
children.push(bullet("Linezolid (weak MAOI) + SSRIs", { level: 1, color: RED }));
children.push(bullet("WASHOUT RULES: 14 days after stopping MAOI before starting SSRI; 5 weeks for fluoxetine (long T½) before starting MAOI.", { bold: true, color: TEAL }));
children.push(emptyLine());

children.push(heading2("Warfarin — The Prototypical High-Risk Drug"));
children.push(speakerNote(
  "Warfarin deserves its own dedicated discussion. It has more clinically significant drug interactions than almost any other drug in clinical use. " +
  "Why? Three reasons. First, it has a very narrow therapeutic index — the difference between subtherapeutic, therapeutic, and toxic is tiny. " +
  "Second, it is extensively protein-bound. Third, it is metabolised by multiple CYP450 isoforms. " +
  "Every time you add or remove a drug in a warfarin-treated patient, you must check the interaction and monitor the INR more frequently. " +
  "Let me go through the most important interactions. Amiodarone is a very potent CYP2C9 inhibitor — it reduces S-warfarin metabolism significantly. Because amiodarone has an extremely long half-life of 40 to 55 days, this interaction can persist for months even after stopping amiodarone. " +
  "Rifampicin is at the other extreme — it dramatically reduces warfarin levels, and when you stop rifampicin, warfarin levels shoot up, potentially causing a bleeding event."
));
children.push(bullet("DRUGS THAT ↑ WARFARIN EFFECT → ↑ BLEEDING RISK:", { bold: true, color: RED }));
children.push(bullet("Amiodarone: CYP2C9 inhibitor (also CYP1A2, CYP3A4) — persistent effect due to very long T½ (40-55 days)", { level: 1 }));
children.push(bullet("Azole antifungals (fluconazole, ketoconazole): CYP2C9 inhibitors", { level: 1 }));
children.push(bullet("Fluvoxamine: inhibits CYP1A2, CYP2C19, CYP3A4 → ↑ both R and S warfarin (Kaplan Sadock)", { level: 1 }));
children.push(bullet("NSAIDs: platelet inhibition + GI mucosal damage + protein displacement → ↑ bleeding ~4-fold", { level: 1 }));
children.push(bullet("Antibiotics: ↓ intestinal Vitamin K synthesis by gut flora → ↑ warfarin response", { level: 1 }));
children.push(bullet("DRUGS THAT ↓ WARFARIN EFFECT → ↑ THROMBOSIS RISK:", { bold: true, color: "E67E22" }));
children.push(bullet("Rifampicin: potent CYP3A4/CYP2C9 inducer → ↑ warfarin metabolism → INR falls → subtherapeutic", { level: 1 }));
children.push(bullet("Carbamazepine, phenytoin, phenobarbitone: CYP inducers", { level: 1 }));
children.push(bullet("FOOD INTERACTIONS:", { bold: true, color: TEAL }));
children.push(bullet("Vitamin K-rich foods (spinach, kale, broccoli) → ↓ warfarin anticoagulant effect", { level: 1 }));
children.push(bullet("Grapefruit juice → inhibits CYP3A4 → ↑ warfarin levels", { level: 1 }));
children.push(emptyLine());

children.push(heading2("High-Yield DDI Summary Table"));
children.push(
  makeTable(
    ["Drug A", "Drug B", "Mechanism", "Consequence", "Management"],
    [
      ["Warfarin", "NSAIDs", "PD + protein displacement", "↑ bleeding (4×)", "Avoid / monitor INR"],
      ["Simvastatin", "Ketoconazole", "CYP3A4 inhibition", "Rhabdomyolysis", "Contraindicated"],
      ["Clopidogrel", "Omeprazole", "CYP2C19 inhibition (prodrug)", "↓ antiplatelet effect, stent thrombosis", "Use pantoprazole"],
      ["MAOI", "Meperidine/SSRIs", "Excess serotonin", "Serotonin syndrome — fatal", "ABSOLUTE contraindication"],
      ["Digoxin", "Clarithromycin", "P-gp + CYP3A4 inhibition", "↑ digoxin → toxicity", "Reduce dose, monitor"],
      ["Methotrexate", "NSAIDs", "↓ renal clearance", "↑ MTX toxicity (myelosuppression)", "Withhold NSAIDs"],
      ["OCP", "Rifampicin", "CYP3A4 induction", "Contraceptive failure", "Use barrier contraception"],
      ["Lithium", "Thiazides/NSAIDs", "↓ renal Li clearance", "Lithium toxicity", "Monitor levels"],
      ["Nitrates (GTN)", "Sildenafil/PDE5i", "Additive cGMP → vasodilation", "Catastrophic hypotension", "Absolute contraindication"],
      ["Theophylline", "Ciprofloxacin", "CYP1A2 inhibition", "↑ theophylline → seizures", "Reduce dose 30-50%"],
      ["Cyclosporine", "Rifampicin", "CYP3A4 induction", "Transplant rejection", "Use rifabutin, monitor"],
      ["ACE inhibitor", "Spironolactone", "Additive K⁺ retention", "Fatal hyperkalaemia", "Monitor K⁺, reduce dose"],
    ],
    [1100, 1100, 1700, 2200, 2160]
  )
);
children.push(emptyLine());

children.push(heading2("Additional High-Yield DDIs"));
children.push(speakerNote(
  "Let me run through a few more important interactions rapidly."
));
children.push(bullet("AMINOGLYCOSIDES + LOOP DIURETICS (furosemide): Additive nephrotoxicity AND ototoxicity. Avoid concurrent use.", { bold: false, color: RED }));
children.push(bullet("ALCOHOL + CNS DEPRESSANTS (benzos, opioids, antihistamines): Additive CNS/respiratory depression — potentially fatal.", { bold: false, color: RED }));
children.push(bullet("ACE INHIBITORS + K⁺-SPARING DIURETICS: Both ↑ serum K⁺ → hyperkalaemia → cardiac arrhythmias.", { bold: false }));
children.push(bullet("SSRIs + ANTICOAGULANTS: SSRIs inhibit platelet serotonin uptake → impaired platelet aggregation → ↑ bleeding risk with warfarin/DOACs. (Maudsley Prescribing Guidelines)", { bold: false }));
children.push(bullet("LEVODOPA + MAOIs: Hypertensive crisis due to excess dopamine/catecholamines.", { bold: false, color: RED }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SECTION 7 — PREVENTION & MANAGEMENT
// ═══════════════════════════════════════════════════════════════════════════
children.push(...sectionBanner(7, "Prevention & Management of DDIs"));
children.push(timing("10 minutes"));
children.push(emptyLine());

children.push(heading2("Strategies to Prevent DDIs"));
children.push(speakerNote(
  "Now let me summarise the practical strategies for preventing DDIs in clinical practice. These are equally important as knowing the interactions themselves. " +
  "First principle: rationalise the prescription. Every new drug you add increases the risk of a DDI exponentially. Before writing a prescription, ask yourself — is this drug truly necessary? " +
  "Second: use drug interaction databases. There are excellent free resources — the British National Formulary, Micromedex, CredibleMeds for QTc interactions. Make it a habit to check. " +
  "Third: monitor. When you add a new drug to a warfarin-treated patient, check the INR in a week. When you add ciprofloxacin to a theophylline patient, check theophylline levels. Monitoring catches problems before they become disasters."
));
children.push(heading3("1. Prescribing Strategies"));
children.push(bullet("Minimise polypharmacy — question every drug, add only if clearly necessary", { bold: false }));
children.push(bullet("Use the narrowest effective dose for the shortest duration", { bold: false }));
children.push(bullet("Prefer drugs with lower DDI potential when alternatives exist (e.g., pantoprazole over omeprazole in clopidogrel patients)", { bold: false }));

children.push(heading3("2. Monitoring"));
children.push(bullet("INR: monitor closely whenever any drug is added/removed in warfarin-treated patients", { bold: false }));
children.push(bullet("Serum levels: digoxin, lithium, theophylline, phenytoin, cyclosporine, aminoglycosides", { bold: false }));
children.push(bullet("Renal function: when adding nephrotoxic combinations (aminoglycoside + loop diuretic)", { bold: false }));
children.push(bullet("ECG: QTc monitoring when adding QT-prolonging drugs to at-risk patients", { bold: false }));
children.push(bullet("Serum electrolytes: K⁺ when adding K⁺-sparing drugs to ACE inhibitor therapy", { bold: false }));

children.push(heading3("3. Dose Adjustment"));
children.push(bullet("↓ dose of substrate when an enzyme INHIBITOR is added (levels will rise)", { bold: false }));
children.push(bullet("↑ dose of substrate when an enzyme INDUCER is added (levels will fall); reverse when inducer stopped", { bold: false }));

children.push(heading3("4. Timing and Administration"));
children.push(bullet("Chelation: separate tetracyclines/fluoroquinolones from antacids/iron/dairy by ≥2 hours", { bold: false }));
children.push(bullet("Cholestyramine: give other drugs 1 hour BEFORE or 4–6 hours AFTER", { bold: false }));
children.push(bullet("Washout: 14 days after stopping MAOI; 5 weeks for fluoxetine before starting MAOI", { bold: false }));

children.push(heading3("5. Patient Counselling"));
children.push(bullet("Advise on grapefruit juice avoidance with statins/CCBs/cyclosporine", { bold: false }));
children.push(bullet("Warn about vitamin K-rich foods and warfarin effect", { bold: false }));
children.push(bullet("Counsel epileptic women on OCP-antiepileptic interaction; recommend barrier contraception", { bold: false }));
children.push(divider());

// ═══════════════════════════════════════════════════════════════════════════
// SESSION SUMMARY
// ═══════════════════════════════════════════════════════════════════════════
children.push(heading1("SESSION SUMMARY — KEY TAKE-HOME POINTS"));
children.push(speakerNote(
  "Before we move to the MCQ exercise, let me summarise the ten most important points from today's session."
));
children.push(bullet("DDIs = pharmacokinetic (ADME) + pharmacodynamic (receptor-level) mechanisms.", { bold: true }));
children.push(bullet("CYP3A4 metabolises ~50% of all drugs — it is the most important isoform.", { bold: true }));
children.push(bullet("INHIBITORS (CRACK+G) → drug TOXICITY; INDUCERS (PC BRAS) → therapeutic FAILURE.", { bold: true, color: RED }));
children.push(bullet("Rifampicin is the most clinically dangerous inducer: OCP failure, transplant rejection, warfarin failure.", { bold: false }));
children.push(bullet("Warfarin: highest-risk drug for DDIs. ALWAYS check interactions when prescribing alongside warfarin.", { bold: true, color: RED }));
children.push(bullet("Serotonin syndrome: MAOI + serotonergic drug = potentially fatal. ABSOLUTE contraindication.", { bold: true, color: RED }));
children.push(bullet("QTc prolongation: never combine two QT-prolonging drugs without ECG monitoring.", { bold: true, color: RED }));
children.push(bullet("Chelation: tetracyclines + Ca²⁺/Mg²⁺/Al³⁺/Fe²⁺ → ↓ absorption → treatment failure.", { bold: false }));
children.push(bullet("NSAIDs interact with warfarin (↑ bleeding), lithium (↑ toxicity), methotrexate (↑ toxicity), antihypertensives (↓ effect).", { bold: false }));
children.push(bullet("Prevention: minimise polypharmacy, check databases, monitor levels, counsel patients.", { bold: true, color: GREEN }));
children.push(emptyLine());

// ═══════════════════════════════════════════════════════════════════════════
// MCQ EXERCISE
// ═══════════════════════════════════════════════════════════════════════════
children.push(heading1("MCQ EXERCISE — 20 QUESTIONS"));
children.push(speakerNote("Give students 20 minutes to answer all 20 questions independently. Then go through each answer with explanation. Allow 1 minute per explanation — total 20 minutes."));
children.push(emptyLine());

const mcqs = [
  {
    n: 1,
    q: "A 60-year-old man on warfarin is prescribed rifampicin for tuberculosis. His INR drops from 2.5 to 1.2 after 2 weeks. The most likely mechanism is:",
    opts: ["A. Decreased warfarin absorption", "B. CYP enzyme induction → increased warfarin metabolism", "C. Protein binding displacement of warfarin", "D. Rifampicin directly antagonises vitamin K"],
    ans: "B",
    exp: "Rifampicin induces CYP3A4 and CYP2C9 → ↑ warfarin metabolism → ↓ plasma levels → INR falls → thrombosis risk. Warfarin dose escalation and close monitoring essential. On stopping rifampicin, enzyme levels normalise — reduce warfarin dose to avoid bleeding."
  },
  {
    n: 2,
    q: "A patient on MAOI antidepressants presents with hyperthermia, agitation, clonus, and diaphoresis after being given pethidine (meperidine) for pain. What is the diagnosis?",
    opts: ["A. Neuroleptic malignant syndrome", "B. Anticholinergic toxidrome", "C. Serotonin syndrome", "D. Opioid toxicity"],
    ans: "C",
    exp: "MAOI + meperidine is the classic deadly combination causing serotonin syndrome. MAOIs prevent serotonin breakdown; meperidine inhibits serotonin reuptake. Triad: mental status changes + autonomic hyperactivity + neuromuscular abnormalities (clonus = hallmark). ABSOLUTE contraindication. Treat with cyproheptadine."
  },
  {
    n: 3,
    q: "A transplant patient on cyclosporine develops acute rejection 3 weeks after starting TB treatment. Which drug is responsible?",
    opts: ["A. Pyrazinamide", "B. Ethambutol", "C. Rifampicin", "D. Isoniazid"],
    ans: "C",
    exp: "Rifampicin induces CYP3A4, dramatically increasing cyclosporine clearance → subtherapeutic cyclosporine levels → acute rejection. Use rifabutin (weaker inducer) instead, or increase cyclosporine dose with frequent level monitoring."
  },
  {
    n: 4,
    q: "Omeprazole is prescribed to a patient on clopidogrel after coronary stent placement. Which concern is most valid?",
    opts: ["A. Omeprazole reduces clopidogrel absorption", "B. Omeprazole inhibits CYP2C19, reducing clopidogrel activation", "C. Omeprazole increases platelet aggregation directly", "D. Omeprazole competes with clopidogrel at P2Y12 receptors"],
    ans: "B",
    exp: "Clopidogrel is a prodrug requiring CYP2C19 activation. Omeprazole inhibits CYP2C19 → ↓ active metabolite → ↓ antiplatelet effect → ↑ stent thrombosis risk. Use pantoprazole (minimal CYP2C19 inhibition) instead. (Lippincott — Clinical Application 42.1)"
  },
  {
    n: 5,
    q: "A patient on simvastatin 40 mg develops severe myalgia and dark urine after starting a new antifungal. Which drug is most likely responsible?",
    opts: ["A. Fluconazole (CYP2C9 inhibitor)", "B. Terbinafine (CYP2D6 inhibitor)", "C. Ketoconazole (CYP3A4 inhibitor)", "D. Griseofulvin (CYP inducer)"],
    ans: "C",
    exp: "Simvastatin is metabolised by CYP3A4. Ketoconazole inhibits CYP3A4 → ↑ simvastatin up to 20-fold → myopathy/rhabdomyolysis. This combination is CONTRAINDICATED. Use pravastatin or rosuvastatin (not CYP3A4-dependent) if azole antifungal is required."
  },
  {
    n: 6,
    q: "A patient is advised to take tetracycline with milk and antacids. After one week, the infection has not improved. The most likely reason:",
    opts: ["A. Pharmacodynamic antagonism at the ribosome", "B. Phase I metabolism accelerated by calcium", "C. Chelation by divalent cations → decreased absorption", "D. Antacid increases gastric motility"],
    ans: "C",
    exp: "Tetracyclines form insoluble chelate complexes with Ca²⁺, Mg²⁺, Al³⁺, Fe²⁺, Zn²⁺. These chelates are not absorbed → treatment failure. Take tetracyclines on empty stomach, 2 hours before or after dairy/antacids/iron."
  },
  {
    n: 7,
    q: "A patient on warfarin is prescribed amiodarone for persistent atrial fibrillation. The expected consequence is:",
    opts: ["A. Decreased INR due to CYP enzyme induction", "B. Increased INR due to CYP2C9 inhibition → warfarin toxicity", "C. No significant interaction", "D. Increased warfarin protein binding → decreased free drug"],
    ans: "B",
    exp: "Amiodarone inhibits CYP2C9 (metabolises S-warfarin) + CYP1A2 + CYP3A4 → ↑ warfarin levels → elevated INR → bleeding risk. Delayed onset due to amiodarone's very long half-life (40-55 days). Reduce warfarin dose ~30-50% and monitor INR closely."
  },
  {
    n: 8,
    q: "Which antibiotic + drug combination is most likely to cause additive nephrotoxicity and ototoxicity?",
    opts: ["A. Amoxicillin + metronidazole", "B. Gentamicin + furosemide", "C. Ciprofloxacin + ibuprofen", "D. Clindamycin + spironolactone"],
    ans: "B",
    exp: "Aminoglycosides (gentamicin) and loop diuretics (furosemide) are both nephrotoxic and ototoxic independently. Combined: additive/synergistic toxicity to kidneys and cochlear hair cells. Avoid concurrent use; if unavoidable, monitor renal function and hearing."
  },
  {
    n: 9,
    q: "A patient takes sildenafil for erectile dysfunction and has ischaemic heart disease. He uses sublingual GTN during an anginal attack. The expected outcome:",
    opts: ["A. GTN reduces sildenafil efficacy", "B. Severe, potentially fatal hypotension", "C. Mild reflex tachycardia only", "D. Sildenafil blocks nitrate-mediated vasodilation"],
    ans: "B",
    exp: "Nitrates → NO → guanylate cyclase → ↑cGMP → vasodilation. Sildenafil (PDE5 inhibitor) prevents cGMP breakdown. Combined: massive cGMP accumulation → profound vasodilation → catastrophic hypotension. ABSOLUTE CONTRAINDICATION. Never combine nitrates with PDE5 inhibitors."
  },
  {
    n: 10,
    q: "Probenecid was historically combined with penicillin because:",
    opts: ["A. Probenecid enhances GI absorption of penicillin", "B. Probenecid blocks renal tubular secretion of penicillin → prolongs its half-life", "C. Probenecid induces CYP enzymes converting penicillin to active metabolite", "D. Probenecid displaces penicillin from protein binding"],
    ans: "B",
    exp: "Penicillin is actively secreted by OAT1/OAT3 renal tubular transporters. Probenecid competes for these transporters → blocks penicillin secretion → prolonged plasma levels. Intentional therapeutic DDI used during WWII when penicillin was scarce."
  },
  {
    n: 11,
    q: "A patient on lithium is started on naproxen for arthritis. Serum lithium rises; he develops tremor, confusion, and arrhythmia. The mechanism:",
    opts: ["A. Naproxen inhibits renal CYP enzymes metabolising lithium", "B. NSAIDs inhibit renal prostaglandin synthesis → reduced GFR → decreased lithium clearance", "C. Naproxen competes with lithium for protein binding", "D. Naproxen increases lithium tubular secretion causing paradoxical reabsorption"],
    ans: "B",
    exp: "Renal prostaglandins (PGE2, PGI2) maintain afferent arteriolar tone and GFR. NSAIDs inhibit COX → ↓ prostaglandins → afferent vasoconstriction → ↓ GFR → lithium retention → toxicity (narrow TI). Avoid NSAIDs in lithium patients; use paracetamol."
  },
  {
    n: 12,
    q: "Erythromycin and simvastatin are co-prescribed. The clinically significant risk is:",
    opts: ["A. Erythromycin reduces simvastatin GI absorption", "B. Both drugs inhibit CYP2D6", "C. Erythromycin inhibits CYP3A4 → increased simvastatin → myopathy/rhabdomyolysis", "D. Erythromycin is a CYP inducer reducing simvastatin"],
    ans: "C",
    exp: "Erythromycin/clarithromycin inhibit CYP3A4. Simvastatin (CYP3A4 substrate) levels rise substantially → myopathy/rhabdomyolysis. Temporarily hold statin or switch to non-CYP3A4 statin (pravastatin, rosuvastatin) during macrolide course."
  },
  {
    n: 13,
    q: "Which statement about pharmacodynamic drug interactions is CORRECT?",
    opts: ["A. They always involve CYP450 enzyme inhibition or induction", "B. They occur when one drug alters the absorption of another", "C. Two drugs with QTc-prolonging effects have additive risk of Torsades de Pointes", "D. Pharmacodynamic interactions are always less significant than pharmacokinetic ones"],
    ans: "C",
    exp: "Pharmacodynamic interactions occur at receptor/physiological level, NOT involving CYP450 changes in drug concentration. QTc prolongation is an additive PD interaction — two QTc-prolonging drugs greatly increase TdP risk. PD interactions can be as or more dangerous than PK interactions."
  },
  {
    n: 14,
    q: "A female epileptic on carbamazepine becomes pregnant despite using oral contraceptive pills. The most likely explanation:",
    opts: ["A. Carbamazepine inhibits CYP3A4, increasing oestrogen levels", "B. Carbamazepine is a CYP3A4 inducer → reduces OCP hormone levels → contraceptive failure", "C. Carbamazepine interferes with progesterone receptor binding", "D. Carbamazepine reduces gastric pH, impairing OCP absorption"],
    ans: "B",
    exp: "Carbamazepine INDUCES CYP3A4 → accelerates oestrogen/progesterone metabolism → subtherapeutic OCP levels → ovulation occurs → pregnancy. Enzyme-inducing AEDs (carbamazepine, phenytoin, phenobarbitone) require alternative contraception. Recommend barrier methods + OCP or copper IUD."
  },
  {
    n: 15,
    q: "A patient on theophylline for asthma is prescribed ciprofloxacin for UTI. He develops tachycardia, tremors, and seizures. Serum theophylline is elevated. The mechanism:",
    opts: ["A. Ciprofloxacin induces CYP3A4, increasing theophylline synthesis", "B. Ciprofloxacin inhibits CYP1A2 → reduces theophylline metabolism → toxicity", "C. Ciprofloxacin displaces theophylline from albumin", "D. Ciprofloxacin competes with theophylline for renal tubular secretion"],
    ans: "B",
    exp: "Theophylline is metabolised by CYP1A2. Ciprofloxacin inhibits CYP1A2 → theophylline accumulates (NTI: 10-20 mg/L) → toxicity: tachyarrhythmias, seizures at >20 mg/L. Reduce theophylline dose 30-50% and monitor levels when co-prescribing ciprofloxacin."
  },
  {
    n: 16,
    q: "Co-trimoxazole (trimethoprim + sulfamethoxazole) demonstrates which type of pharmacological interaction?",
    opts: ["A. Pharmacokinetic — CYP450 enzyme inhibition", "B. Pharmacodynamic — sequential blockade of folate synthesis (synergism)", "C. Pharmaceutical incompatibility", "D. Pharmacodynamic — functional antagonism"],
    ans: "B",
    exp: "Sulfamethoxazole inhibits dihydropteroate synthase (step 1). Trimethoprim inhibits dihydrofolate reductase (step 2). Sequential blockade of the same metabolic pathway = synergistic bactericidal activity. No CYP mechanism. Intentional pharmacodynamic synergism."
  },
  {
    n: 17,
    q: "Which drug combination can cause potentially fatal hyperkalaemia?",
    opts: ["A. ACE inhibitor + loop diuretic", "B. ACE inhibitor + spironolactone", "C. Beta-blocker + calcium channel blocker", "D. Warfarin + aspirin"],
    ans: "B",
    exp: "ACE inhibitor: ↓ aldosterone → ↑ K⁺ retention. Spironolactone: direct aldosterone antagonist → also ↑ K⁺. Combined in CKD → severe fatal hyperkalaemia → cardiac arrest. Monitor K⁺ regularly. ACE inhibitor + LOOP diuretic = hypokalaemia (opposite direction)."
  },
  {
    n: 18,
    q: "Grapefruit juice significantly increases the plasma level of simvastatin because:",
    opts: ["A. It induces CYP3A4 in hepatocytes", "B. It irreversibly inhibits intestinal CYP3A4, increasing oral bioavailability", "C. It decreases renal simvastatin excretion", "D. It displaces simvastatin from plasma protein binding"],
    ans: "B",
    exp: "Grapefruit furanocoumarins irreversibly inhibit intestinal (not hepatic) CYP3A4 → ↓ first-pass metabolism → ↑ oral bioavailability of CYP3A4 substrates (simvastatin, nifedipine, cyclosporine). One glass = effect for 24-72 hours. Patients on affected drugs: avoid grapefruit entirely."
  },
  {
    n: 19,
    q: "Which drug pair exemplifies physiological (indirect/functional) antagonism?",
    opts: ["A. Naloxone + morphine (competitive opioid receptor antagonism)", "B. Adrenaline + histamine in anaphylaxis (opposing effects via different receptors)", "C. Propranolol + salbutamol (competitive beta-2 antagonism)", "D. Flumazenil + diazepam (competitive benzodiazepine receptor antagonism)"],
    ans: "B",
    exp: "Physiological antagonism = opposing effects at DIFFERENT receptors/systems. Histamine → bronchoconstriction/hypotension (H1 receptors). Adrenaline → bronchodilation/vasoconstriction (adrenergic receptors). No receptor competition. Options A, C, D = direct competitive receptor antagonism at the SAME receptor."
  },
  {
    n: 20,
    q: "Cholestyramine causes subtherapeutic anticoagulation in a warfarin patient because:",
    opts: ["A. Cholestyramine inhibits CYP2C9, reducing warfarin activation", "B. Cholestyramine binds warfarin in the GI tract, reducing oral absorption", "C. Cholestyramine competes with warfarin for plasma albumin", "D. Cholestyramine induces hepatic CYP3A4 increasing warfarin clearance"],
    ans: "B",
    exp: "Cholestyramine (anion exchange resin) adsorbs negatively charged molecules in GI lumen including warfarin, digoxin, thyroid hormones, fat-soluble vitamins. Absorption-based interaction — NOT a CYP mechanism. Rule: give warfarin 1 hour BEFORE or 4-6 hours AFTER cholestyramine."
  }
];

mcqs.forEach(mcq => {
  children.push(
    new Paragraph({
      spacing: { before: 200, after: 60 },
      shading: { type: ShadingType.SOLID, color: NAVY, fill: NAVY },
      children: [
        new TextRun({ text: `Q${mcq.n}.  `, bold: true, color: AMBER, size: 21, font: "Calibri" }),
        new TextRun({ text: mcq.q, bold: false, color: WHITE, size: 21, font: "Calibri" }),
      ],
    })
  );
  mcq.opts.forEach(opt => {
    children.push(
      new Paragraph({
        indent: { left: convertInchesToTwip(0.3) },
        spacing: { before: 30, after: 30 },
        children: [
          new TextRun({
            text: opt,
            size: 20,
            color: DKGRAY,
            bold: opt.startsWith(mcq.ans + "."),
            font: "Calibri",
          }),
        ],
      })
    );
  });
  children.push(
    new Paragraph({
      spacing: { before: 60, after: 60 },
      shading: { type: ShadingType.SOLID, color: "E8F8F0", fill: "E8F8F0" },
      indent: { left: convertInchesToTwip(0.15) },
      children: [
        new TextRun({ text: `✔ ANSWER ${mcq.ans}:  `, bold: true, color: GREEN, size: 20, font: "Calibri" }),
        new TextRun({ text: mcq.exp, size: 20, color: DKGRAY, font: "Calibri" }),
      ],
    })
  );
});

children.push(divider());
children.push(
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 200, after: 100 },
    children: [
      new TextRun({ text: "END OF SESSION", bold: true, color: NAVY, size: 28, font: "Calibri", allCaps: true }),
    ],
  }),
  new Paragraph({
    alignment: AlignmentType.CENTER,
    spacing: { before: 60, after: 60 },
    children: [
      new TextRun({ text: "Sources: Goodman & Gilman's  •  Lippincott Pharmacology  •  Katzung 16e  •  Miller's Anesthesia 10e  •  Harrison's 22e  •  Tintinalli's EM  •  Barash Anesthesia 9e", size: 17, color: LGRAY, italic: true, font: "Calibri" }),
    ],
  })
);

// ─── BUILD DOCUMENT ──────────────────────────────────────────────────────────
const doc = new Document({
  creator: "Pharmacology Department",
  title: "Drug-Drug Interactions — Lecture Script",
  description: "Full lecture script for 2-hour UG MBBS DDI session",
  styles: {
    default: {
      document: {
        run: { font: "Calibri", size: 22, color: DKGRAY },
        paragraph: { spacing: { line: 340, lineRule: "auto" } },
      },
    },
  },
  sections: [
    {
      properties: {
        page: {
          margin: {
            top: convertInchesToTwip(1),
            bottom: convertInchesToTwip(1),
            left: convertInchesToTwip(1.1),
            right: convertInchesToTwip(1.1),
          },
        },
      },
      headers: {
        default: new Header({
          children: [
            new Paragraph({
              border: { bottom: { style: BorderStyle.SINGLE, size: 6, color: TEAL } },
              children: [
                new TextRun({ text: "Drug–Drug Interactions  |  UG MBBS Pharmacology  |  Lecture Script", size: 16, color: TEAL, font: "Calibri" }),
                new TextRun({ text: "\t\t\tPage ", size: 16, color: LGRAY, font: "Calibri" }),
              ],
              tabStops: [{ type: "right", position: convertInchesToTwip(6) }],
            }),
          ],
        }),
      },
      footers: {
        default: new Footer({
          children: [
            new Paragraph({
              border: { top: { style: BorderStyle.SINGLE, size: 4, color: LGRAY } },
              alignment: AlignmentType.CENTER,
              children: [
                new TextRun({ text: "Sources: Goodman & Gilman's • Lippincott • Katzung 16e • Harrison's 22e — For Educational Use", size: 15, color: LGRAY, italic: true, font: "Calibri" }),
              ],
            }),
          ],
        }),
      },
      children,
    },
  ],
});

Packer.toBuffer(doc).then(buffer => {
  fs.writeFileSync("/home/daytona/workspace/ddi-presentation/DDI_Lecture_Script.docx", buffer);
  console.log("SUCCESS: DOCX saved");
}).catch(e => {
  console.error("ERROR:", e.message);
  process.exit(1);
});
Running Command

cd /home/daytona/workspace/ddi-presentation && node create_ddi_script.js 2>&1

Running Command

ls -lh /home/daytona/workspace/ddi-presentation/ && python3 /home/daytona/skills/pptx/scripts/office/validate.py /home/daytona/workspace/ddi-presentation/DDI_Lecture_Script.docx 2>&1 || echo "Validate script not found, checking file size only"

Running Command

cd /home/daytona/workspace/ddi-presentation && python3 -c " import zipfile, os with zipfile.ZipFile('DDI_Lecture_Script.docx', 'r') as z: names = z.namelist() print('Files in docx:', names[:10]) # Check document.xml exists and is non-empty with z.open('word/document.xml') as f: content = f.read() print(f'document.xml size: {len(content)} bytes') print('First 300 chars:', content[:300].decode('utf-8', errors='ignore')) " 2>&1

The document is valid (259 KB of XML). Here's your file:

📄 Lecture Script (Word):

DDI Lecture Script

Word Document · DOCX


What's in the Script

The Word document is a fully formatted lecturer's script — not just notes, but spoken-word guidance matched to every slide in the presentation. Structure:
ElementWhat it contains
Title pageSession title, usage guide for the document
Session outline tableAll 7 sections with timings
🎤 SPEAKER boxes (blue-tinted)Suggested spoken words for every topic — natural, student-friendly language
Timing markersStart-of-section time reminders
KEY POINT boxes (amber)Highest-yield exam facts, highlighted
CLINICAL ALERT boxes (red)Life-threatening interactions flagged
TablesCYP isozyme table, high-yield DDI summary table
MnemonicsPC BRAS (inducers) and CRACK+G (inhibitors) with context
MCQ sectionAll 20 questions with answer key and explanations embedded
The script covers all 7 sections and the MCQ exercise, with full spoken text for:
  • Opening hook / clinical relevance
  • Every mechanism explanation (CYP inhibition vs induction, chelation, QTc, serotonin syndrome, etc.)
  • All key clinical examples
  • Session summary and closing
This is a shared conversation. Sign in to Orris to start your own chat.